Updated to Drupal 8.6.4, which is PHP 7.3 friendly. Also updated HTMLaw library....
[yaffs-website] / web / core / modules / ckeditor / src / CKEditorPluginContextualInterface.php
1 <?php
2
3 namespace Drupal\ckeditor;
4
5 use Drupal\editor\Entity\Editor;
6
7 /**
8  * Defines an interface for contextually enabled CKEditor plugins.
9  *
10  * Contextually enabled CKEditor plugins can be enabled via an explicit setting,
11  * or enable themselves based on the configuration of another setting, such as
12  * enabling based on a particular button being present in the toolbar.
13  *
14  * If a contextually enabled CKEditor plugin must also be configurable (for
15  * instance, in the case where it must be enabled based on an explicit setting),
16  * then one must also implement the CKEditorPluginConfigurableInterface
17  * interface.
18  *
19  * @see \Drupal\ckeditor\CKEditorPluginInterface
20  * @see \Drupal\ckeditor\CKEditorPluginButtonsInterface
21  * @see \Drupal\ckeditor\CKEditorPluginConfigurableInterface
22  * @see \Drupal\ckeditor\CKEditorPluginCssInterface
23  * @see \Drupal\ckeditor\CKEditorPluginBase
24  * @see \Drupal\ckeditor\CKEditorPluginManager
25  * @see \Drupal\ckeditor\Annotation\CKEditorPlugin
26  * @see plugin_api
27  */
28 interface CKEditorPluginContextualInterface extends CKEditorPluginInterface {
29
30   /**
31    * Checks if this plugin should be enabled based on the editor configuration.
32    *
33    * The editor's settingsĀ can be retrieved via $editor->getSettings().
34    *
35    * @param \Drupal\editor\Entity\Editor $editor
36    *   A configured text editor object.
37    *
38    * @return bool
39    */
40   public function isEnabled(Editor $editor);
41
42 }