You are here

public function RegisterFormPopup::blockForm in Login Popup 2.x

Overrides BlockPluginTrait::blockForm

File

src/Plugin/Block/RegisterFormPopup.php, line 105

Class

RegisterFormPopup
Provides a 'RegisterFormPopup' block.

Namespace

Drupal\login_popup\Plugin\Block

Code

public function blockForm($form, FormStateInterface $form_state) {
  $form = parent::blockForm($form, $form_state);
  $config = $this
    ->getConfiguration();
  $form['show_logout_link'] = [
    '#type' => 'checkbox',
    '#title' => $this
      ->t('Show Logout Link'),
    '#default_value' => !empty($config['show_logout_link']) ? $config['show_logout_link'] : FALSE,
  ];
  return $form;
}