5 * Definition of \Drupal\ckeditor_widgets\Plugin\CKEditorPlugin\AnchorLink.
7 namespace Drupal\ckeditor_widgets\Plugin\CKEditorPlugin;
9 use Drupal\editor\Entity\Editor;
10 use Drupal\ckeditor\CKEditorPluginBase;
13 * Defines the "widgetcommon" plugin.
16 * id = "widgetcommon",
17 * label = @Translation("CKEditor Common Widgets"),
18 * module = "ckeditor_widgets"
21 class WidgetCommon extends CKEditorPluginBase {
24 * Implements \Drupal\ckeditor\Plugin\CKEditorPluginInterface::getFile().
27 return drupal_get_path('module', 'ckeditor_widgets') . '/js/plugins/widgetcommon/plugin.js';
33 public function getDependencies(Editor $editor) {
39 public function getLibraries(Editor $editor) {
46 public function isInternal() {
51 * Implements \Drupal\ckeditor\Plugin\CKEditorPluginButtonsInterface::getButtons().
53 function getButtons() {
55 'widgetcommonBox' => array(
56 'label' => $this->t('Insert box'),
57 'image' => drupal_get_path('module', 'ckeditor_widgets') . '/js/plugins/widgetcommon/icons/widgetcommonBox.png',
59 'widgetcommonQuotebox' => array(
60 'image' => drupal_get_path('module', 'ckeditor_widgets') . '/js/plugins/widgetcommon/icons/widgetcommonQuotebox.png',
61 'label' => $this->t('Insert quote box'),
69 public function getConfig(Editor $editor) {