You are here

public function TestBlock::blockForm in Page Manager 8.4

Same name and namespace in other branches
  1. 8 tests/modules/page_manager_test/src/Plugin/Block/TestBlock.php \Drupal\page_manager_test\Plugin\Block\TestBlock::blockForm()

Overrides BlockPluginTrait::blockForm

File

tests/modules/page_manager_test/src/Plugin/Block/TestBlock.php, line 29

Class

TestBlock
Provides a block to test page_manager.

Namespace

Drupal\page_manager_test\Plugin\Block

Code

public function blockForm($form, FormStateInterface $form_state) {
  $form['example'] = [
    '#type' => 'textfield',
    '#title' => $this
      ->t('Example'),
    '#ajax' => [
      'callback' => [
        $this,
        'exampleAjaxCallback',
      ],
    ],
  ];
  return $form;
}