/** * {@inheritdoc} */ public function settingsForm(array $form, FormStateInterface $form_state) { $form = parent::settingsForm($form, $form_state); $form['native_language'] = array('#title' => $this->t('Display in native language'), '#type' => 'checkbox', '#default_value' => $this->getSetting('native_language')); return $form; }
/** * {@inheritdoc} */ public function settingsForm(array $form, FormStateInterface $form_state) { $form = parent::settingsForm($form, $form_state); $form['format'] = array('#type' => 'checkboxes', '#title' => t('Display'), '#description' => t('Select the elements you want to show. The elements will be concatenated when showing the field.'), '#default_value' => $this->getSetting('format'), '#options' => LanguageItem::_settingsOptions('formatter')); return $form; }