Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Release Notes for CKEditor for Craft CMS

## Unreleased

- The “Anchors” CKEditor plugin has been replaced with CKEditor’s new built-in [Bookmarks](https://ckeditor.com/docs/ckeditor5/latest/features/bookmarks.html) plugin. ([#397](https://github.com/craftcms/ckeditor/pull/397))
- Updated to CKEditor 5 45.0.0. ([#397](https://github.com/craftcms/ckeditor/pull/397))

## 3.12.0 - 2025-04-21

- JavaScript-based CKEditor configs can now access the CKEditor instance via an `instance` variable. ([#385](https://github.com/craftcms/ckeditor/pull/385))
Expand Down
21,992 changes: 4,700 additions & 17,292 deletions package-lock.json

Large diffs are not rendered by default.

66 changes: 33 additions & 33 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,44 +6,44 @@
"extends @craftcms/browserslist-config"
],
"devDependencies": {
"@ckeditor/ckeditor5-alignment": ">=44.0.0",
"@ckeditor/ckeditor5-autoformat": ">=44.0.0",
"@ckeditor/ckeditor5-basic-styles": ">=44.0.0",
"@ckeditor/ckeditor5-block-quote": ">=44.0.0",
"@ckeditor/ckeditor5-code-block": ">=44.0.0",
"@ckeditor/ckeditor5-core": ">=44.0.0",
"@ckeditor/ckeditor5-alignment": ">=45.0.0",
"@ckeditor/ckeditor5-autoformat": ">=45.0.0",
"@ckeditor/ckeditor5-basic-styles": ">=45.0.0",
"@ckeditor/ckeditor5-block-quote": ">=45.0.0",
"@ckeditor/ckeditor5-bookmark": ">=45.0.0",
"@ckeditor/ckeditor5-code-block": ">=45.0.0",
"@ckeditor/ckeditor5-core": ">=45.0.0",
"@ckeditor/ckeditor5-dev-translations": "^43.0.1",
"@ckeditor/ckeditor5-editor-classic": ">=44.0.0",
"@ckeditor/ckeditor5-essentials": ">=44.0.0",
"@ckeditor/ckeditor5-find-and-replace": ">=44.0.0",
"@ckeditor/ckeditor5-font": ">=44.0.0",
"@ckeditor/ckeditor5-heading": ">=44.0.0",
"@ckeditor/ckeditor5-horizontal-line": ">=44.0.0",
"@ckeditor/ckeditor5-html-embed": ">=44.0.0",
"@ckeditor/ckeditor5-html-support": ">=44.0.0",
"@ckeditor/ckeditor5-image": ">=44.0.0",
"@ckeditor/ckeditor5-indent": ">=44.0.0",
"@ckeditor/ckeditor5-editor-classic": ">=45.0.0",
"@ckeditor/ckeditor5-essentials": ">=45.0.0",
"@ckeditor/ckeditor5-find-and-replace": ">=45.0.0",
"@ckeditor/ckeditor5-font": ">=45.0.0",
"@ckeditor/ckeditor5-heading": ">=45.0.0",
"@ckeditor/ckeditor5-horizontal-line": ">=45.0.0",
"@ckeditor/ckeditor5-html-embed": ">=45.0.0",
"@ckeditor/ckeditor5-html-support": ">=45.0.0",
"@ckeditor/ckeditor5-image": ">=45.0.0",
"@ckeditor/ckeditor5-indent": ">=45.0.0",
"@ckeditor/ckeditor5-inspector": ">=4.1.0",
"@ckeditor/ckeditor5-language": "^44.0.0",
"@ckeditor/ckeditor5-link": ">=44.0.0",
"@ckeditor/ckeditor5-list": ">=44.0.0",
"@ckeditor/ckeditor5-media-embed": ">=44.0.0",
"@ckeditor/ckeditor5-language": "^45.0.0",
"@ckeditor/ckeditor5-link": ">=45.0.0",
"@ckeditor/ckeditor5-list": ">=45.0.0",
"@ckeditor/ckeditor5-media-embed": ">=45.0.0",
"@ckeditor/ckeditor5-package-tools": "^1.0.0",
"@ckeditor/ckeditor5-page-break": ">=44.0.0",
"@ckeditor/ckeditor5-paragraph": ">=44.0.0",
"@ckeditor/ckeditor5-paste-from-office": ">=44.0.0",
"@ckeditor/ckeditor5-remove-format": ">=44.0.0",
"@ckeditor/ckeditor5-select-all": ">=44.0.0",
"@ckeditor/ckeditor5-source-editing": ">=44.0.0",
"@ckeditor/ckeditor5-style": ">=44.0.0",
"@ckeditor/ckeditor5-table": ">=44.0.0",
"@ckeditor/ckeditor5-theme-lark": "^44.0.0",
"@ckeditor/ckeditor5-upload": ">=44.0.0",
"@ckeditor/ckeditor5-word-count": ">=44.0.0",
"@ckeditor/ckeditor5-page-break": ">=45.0.0",
"@ckeditor/ckeditor5-paragraph": ">=45.0.0",
"@ckeditor/ckeditor5-paste-from-office": ">=45.0.0",
"@ckeditor/ckeditor5-remove-format": ">=45.0.0",
"@ckeditor/ckeditor5-select-all": ">=45.0.0",
"@ckeditor/ckeditor5-source-editing": ">=45.0.0",
"@ckeditor/ckeditor5-style": ">=45.0.0",
"@ckeditor/ckeditor5-table": ">=45.0.0",
"@ckeditor/ckeditor5-theme-lark": "^45.0.0",
"@ckeditor/ckeditor5-upload": ">=45.0.0",
"@ckeditor/ckeditor5-word-count": ">=45.0.0",
"@craftcms/sass": "^1.1.0",
"@craftcms/webpack": "^1.1.2",
"@northernco/ckeditor5-anchor-drupal": "^0.5.0",
"ckeditor5": ">=44.0.0",
"ckeditor5": ">=45.0.0",
"copy-webpack-plugin": "^12.0.2",
"husky": "^9.1.7",
"lint-staged": "^15.2.10",
Expand Down
8 changes: 8 additions & 0 deletions src/CkeConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,14 @@ class CkeConfig extends Model

public function __construct($config = [])
{
if (isset($config['toolbar'])) {
// anchor → bookmark
$key = array_search('anchor', $config['toolbar']);
if ($key !== false) {
$config['toolbar'][$key] = 'bookmark';
}
}

if (!array_key_exists('options', $config)) {
// Only use `json` or `js`, not both
if (!empty($config['json'])) {
Expand Down
11 changes: 11 additions & 0 deletions src/helpers/CkeditorConfigSchema.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,16 @@ private static function interfaces(): array
'options' => ['left', 'right'],
],
],
'BookmarkConfig' => [
'description' => 'https://ckeditor.com/docs/ckeditor5/latest/api/module_bookmark_bookmarkconfig-BookmarkConfig.html',
'properties' => [
'enableNonEmptyAnchorConversion' => ['type' => 'boolean'],
'toolbar' => [
'type' => 'array',
'items' => ['type' => 'string'],
],
],
],
'ClassList' => [
'title' => 'Class name or list of class names',
'anyOf' => [
Expand Down Expand Up @@ -99,6 +109,7 @@ private static function interfaces(): array
'description' => 'https://ckeditor.com/docs/ckeditor5/latest/api/module_core_editor_editorconfig-EditorConfig.html',
'properties' => [
'alignment' => ['interface' => 'AlignmentConfig'],
'bookmark' => ['interface' => 'BookmarkConfig'],
'codeBlock' => ['interface' => 'CodeBlockConfig'],
'fontBackgroundColor' => ['interface' => 'FontColorConfig'],
'fontColor' => ['interface' => 'FontColorConfig'],
Expand Down
2 changes: 1 addition & 1 deletion src/web/assets/ckeconfig/dist/ckeconfig.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/ckeconfig/dist/ckeconfig.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/ckeditor/dist/ckeditor5-craftcms.js

Large diffs are not rendered by default.

21 changes: 10 additions & 11 deletions src/web/assets/ckeditor/dist/ckeditor5-craftcms.js.LICENSE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,20 @@

/* istanbul ignore next: static function definition -- @preserve */

/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */

/**
* @license Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/

/**
* @license Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
* For licensing, see LICENSE.md.
*/
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */

/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */

/**
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
* @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
*/

/**
Expand Down
2 changes: 1 addition & 1 deletion src/web/assets/ckeditor/dist/ckeditor5-craftcms.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/web/assets/ckeditor/dist/ckeditor5-dll.js

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*!
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
* @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
* For licensing, see LICENSE.md.
*/

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading