You are here

public function Language::getButtons in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/ckeditor/src/Plugin/CKEditorPlugin/Language.php \Drupal\ckeditor\Plugin\CKEditorPlugin\Language::getButtons()
  2. 9 core/modules/ckeditor/src/Plugin/CKEditorPlugin/Language.php \Drupal\ckeditor\Plugin\CKEditorPlugin\Language::getButtons()

File

core/modules/ckeditor/src/Plugin/CKEditorPlugin/Language.php, line 83

Class

Language
Defines the "language" plugin.

Namespace

Drupal\ckeditor\Plugin\CKEditorPlugin

Code

public function getButtons() {
  $label = $this
    ->t('Language');
  return [
    'Language' => [
      'label' => $label,
      'image_alternative' => [
        '#type' => 'inline_template',
        '#template' => '<a href="#" class="cke-icon-only" role="button" title="' . $label . '" aria-label="' . $label . '"><span class="cke_button_icon cke_button__language_icon">' . $label . '</span></a>',
      ],
    ],
  ];
}