'id' => $this->mID,
'type' => $this->buttonType,
'name' => $this->mName,
- 'value' => $value,
+ 'value' => $this->getDefault(),
] + $this->getAttributes( [ 'disabled', 'tabindex' ] );
if ( $this->isBadIE() ) {
return Html::element( 'input', $attr );
} else {
- return Html::rawElement( 'button', $attr, $this->buttonLabel ?: htmlspecialchars( $value ) );
+ return Html::rawElement( 'button', $attr,
+ $this->buttonLabel ?: htmlspecialchars( $this->getDefault() ) );
}
}
public function getInputOOUI( $value ) {
return new OOUI\ButtonInputWidget( [
'name' => $this->mName,
- 'value' => $value,
+ 'value' => $this->getDefault(),
'label' => !$this->isBadIE() && $this->buttonLabel
? new OOUI\HtmlSnippet( $this->buttonLabel )
- : $value,
+ : $this->getDefault(),
'type' => $this->buttonType,
'classes' => [ 'mw-htmlform-submit', $this->mClass ],
'id' => $this->mID,