ubc-web-services / ubc_ckeditor_widgets
A Drupal module to add some common widgets to CKeditor
Installs: 15 277
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 8
Forks: 2
Open Issues: 2
Language:JavaScript
Type:drupal-module
- dev-master
- 4.0.3
- 4.0.2
- 4.0.1
- 4.0.0
- 3.x-dev
- 3.1.22
- 3.1.21
- 3.1.20
- 3.1.19
- 3.1.18
- 3.1.17
- 3.1.16
- 3.1.15
- 3.1.14
- 3.1.13
- 3.1.12
- 3.1.11
- 3.1.10
- 3.1.9
- 3.1.8
- 3.1.7
- 3.1.6
- 3.1.5
- 3.1.4
- 3.1.3
- 3.1.2
- 3.1.1
- 3.1
- 3.1-beta2
- 3.1-beta1
- v3.0-beta17
- v3.0-beta16
- v3.0-beta15
- v3.0-beta14
- v3.0-beta13
- v3.0-beta12
- v3.0-beta11
- v3.0-beta10
- v3.0-beta9
- v3.0-beta8
- v3.0-beta7
- v3.0-beta6
- v3.0-beta5
- v3.0-beta4
- v3.0-beta3
- v3.0-beta2
- v3.0-beta1
- v2.0-beta4
- v2.0-beta3
- v2.0-beta2
- 2.0-beta1
- 1.0
- dev-CKE5
- dev-apsc
- dev-dependabot/npm_and_yarn/ckeditor5-43.1.1
- dev-dependabot/npm_and_yarn/webpack-5.94.0
- dev-CKE5-41.3-fix
- dev-vanilla-js
This package is auto-updated.
Last update: 2024-12-19 17:54:04 UTC
README
A Drupal module to add some common widgets to CKeditor
Working with the javascript
Plugin source should be added to
js/ckeditor5_plugins/{pluginNameDirectory}/src
and the build tools expect this
directory to include an index.js
file that exports one or more CKEditor 5
plugins. Note that requiring index.js
to be inside
{pluginNameDirectory}/src
is not a fixed requirement of CKEditor 5 or Drupal,
but a requirement of this starter template that can be changed in
webpack.config.js
as needed.
In the module directory, run yarn install
to set up the necessary assets. The
initial run of install
may take a few minutes, but subsequent builds will be
faster.
After installing dependencies, plugins can be built with yarn build
or yarn watch
. They will be built to js/build/{pluginNameDirectory}.js
. co
CKEditor 5 widgets
Goals:
- make editor widgets for CKEditor 5 that retain feature parity tothose from CKEditor 4
- CKE4 and CKE5 widgets should exist in one module
- CKE5 widgets from repo #2 and #3 should be moved to repo #1 (can leave repo #2 and #3 as is)
- final markup in CKE5 widgets should be the same as is currently used by the CKE4 widgets
Version 4 widget repos:
- https://github.com/ubc-web-services/ubc_ckeditor_widgets/tree/vanilla-js
- https://github.com/ubc-web-services/ubc-column-options-widget
- https://github.com/ubc-web-services/ubc-color-box-widget
CKE 4 widgets [CKE 5 widget status]:
- accordion [complete]
- accordion toggle [complete]
- card-horizontal [complete]
- card-one [complete]
- card-two [complete]
- card-three [complete]
- 2 columns [deprecated]
- 2 columns 1 2 [deprecated]
- 2 columns 2 1 [deprecated]
- 3 columns [deprecated]
- fontawesome icon [deprecated - no cke5 equivalent]
- 2 columns with options [complete]
- 3 columns with options [complete]
- 4 columns with options [complete]
- Color Box [complete]
Net new CKE5 widgets:
- UBC Table Class (adds presentational classes to table elements) [complete]
- UBC Table Cell Class (adds width classes to TD elements) [complete]
CKEditor API
- v4: https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR.html
- custom widget example:
- v5: https://ckeditor.com/docs/ckeditor5/latest/api/index.html
Drupal resources
- Dev Tools for CKE5 - https://www.drupal.org/project/ckeditor5_dev
- CKE5 Drupal API - https://www.drupal.org/docs/drupal-apis/ckeditor-5-api/overview
- Development guide - https://www.drupal.org/docs/core-modules-and-themes/core-modules/ckeditor-5-module/ckeditor-5-development