You are here

public function SettingsForm::buildForm in File Upload Secure Validator 8

Form constructor.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form structure.

Overrides ConfigFormBase::buildForm

File

src/Form/SettingsForm.php, line 68

Class

SettingsForm
A configuration settings form.

Namespace

Drupal\file_upload_secure_validator\Form

Code

public function buildForm(array $form, FormStateInterface $form_state) {
  $form['mime_types_equivalence_groups'] = [
    '#type' => 'textarea',
    '#title' => $this
      ->t('MIME types equivalence group(s)'),
    '#description' => $this
      ->t('A CSV-like list of MIME types groups; if two MIME types are part of the same group, then, File Upload Secure Validator will not protest.'),
    '#default_value' => $this
      ->getConfigurationAsCsvString(),
  ];
  return parent::buildForm($form, $form_state);
}