Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / ckeditor / tests / modules / src / Plugin / CKEditorPlugin / LlamaButton.php
1 <?php
2
3 namespace Drupal\ckeditor_test\Plugin\CKEditorPlugin;
4
5 use Drupal\ckeditor\CKEditorPluginButtonsInterface;
6
7 /**
8  * Defines a "LlamaButton" plugin, with a toolbar builder-enabled "llama" feature.
9  *
10  * @CKEditorPlugin(
11  *   id = "llama_button",
12  *   label = @Translation("Llama Button")
13  * )
14  */
15 class LlamaButton extends Llama implements CKEditorPluginButtonsInterface {
16
17   /**
18    * {@inheritdoc}
19    */
20   public function getButtons() {
21     return [
22       'Llama' => [
23         'label' => t('Insert Llama'),
24       ],
25     ];
26   }
27
28   /**
29    * {@inheritdoc}
30    */
31   public function getFile() {
32     return drupal_get_path('module', 'ckeditor_test') . '/js/llama_button.js';
33   }
34
35 }