42 parent::__construct( $config );
45 $this->selectedArray = $config[
'default'] ?? [];
46 $this->inputName = $config[
'name'] ??
null;
47 $this->inputPlaceholder = $config[
'placeholder'] ??
null;
48 $this->input = $config[
'input'] ?? [];
49 $this->tagLimit = $config[
'tagLimit'] ??
null;
50 $this->allowArbitrary = $config[
'allowArbitrary'] ??
false;
51 $this->allowedValues = $config[
'allowedValues'] ??
null;
53 $textarea =
new MultilineTextInputWidget( array_merge( [
54 'name' => $this->inputName,
55 'value' => implode(
"\n", $this->selectedArray ),
56 'rows' => min( $this->tagLimit, 10 ) ?? 10,
58 'mw-widgets-tagMultiselectWidget-multilineTextInputWidget'
64 $this->appendContent( $textarea, $pending );
65 $this->addClasses( [
'mw-widgets-tagMultiselectWidget' ] );