Skip to content

Releases: codex-team/editor.js

v2.28.0-rc.0

06 Jul 21:18
41dc652
Compare
Choose a tag to compare
v2.28.0-rc.0 Pre-release
Pre-release
  • New - Block ids now displayed in DOM via a data-id attribute. Could be useful for plugins that want access a Block's element by id.
  • Improvement - The Delete keydown at the end of the Block will now work opposite a Backspace at the start. Next Block will be removed (if empty) or merged with the current one.
  • Improvement - The Delete keydown will work like a Backspace when several Blocks are selected.
  • Improvement - If we have two empty Blocks, and press Backspace at the start of the second one, the previous will be removed instead of current.

v2.27.2

22 Jun 17:44
9e64003
Compare
Choose a tag to compare
  • Fix - onChange won't be called when element marked by data-mutation-free changes some attribute

v2.27.1

21 Jun 17:34
c899333
Compare
Choose a tag to compare
  • Fix - onChange will be called on removing the whole text in a block

v2.27.0

15 May 20:46
1f74c5b
Compare
Choose a tag to compare

New Features

  • Toolbar API — Added a new method for toggling the toolbox.
  • Types — Added types for block mutation events
  • onChange — Batching added to the onChange callback. Now the second argument can contain an array of CustomEvents as well as a single one. Multiple changes made in a short period of time will be batched under a single onChange call.

Improvements

  • Toolbox — Number of close() method calls optimized.
  • onChange — The onChange callback can be muted if all mutations contain nodes with the data-mutation-free attribute.
  • onChange — Pressing "Enter" at the end of a Block won't lead to redundant block-changed event triggering. Only block-added event will be dispatched.
  • onChange — The block mutation handler is now called on every block change (including background changes), instead of only when a block is focused
  • Optimization — Number of caret saving method calls optimized for Block Tunes opening/closing.
  • Bundle — Package size reduced by removing redundant files.

Refactorings

  • Popover — Refactored the Popover class for better performance and maintenance.
  • Build System — Switched from Webpack to Vite as the build system.
  • Event BusEventDispatcher types improved. Now we can pass EventsMap via generic to specify a map of event names and their payloads that can be used in a particular EventDispatcher instance.
  • Event Bus — All events in common editor Event Bus now have own type declarations.
  • Mutation Observer — Removed the block mutation observer from blocks and attached a single observer to the editor's blocks wrapper element.
  • Mutation Batching — Removed the debounce from the block mutation handler and used batching instead.
  • Dependencies — Upgraded Cypress to v12 and related libraries to the latest versions.
  • Dependencies — Upgraded TypeScript to v5.
  • CI — Ubuntu container is now used for Edge tests runner.
  • CI — Node 16 is used for GitHib Actions.

Bug Fixes

  • Fixed several bugs caused by browser extensions. Removed the search for a block's container in the DOM on saving and kept it in memory instead, updating it when the tool changes a container element.
  • The onChange callback won't trigger when block tunes are opened or closed.
  • Resolved a compiler error caused by importing the BlockToolData type.
  • Resolved a problem where the document would scroll to the beginning after moving a block above the viewport.
  • Tools APIpasteConfig getter with false value could be used to disable paste handling by Editor.js core. Could be useful if your tool has its own paste handler.

v2.27.0-rc.5

12 May 18:26
26dce94
Compare
Choose a tag to compare
v2.27.0-rc.5 Pre-release
Pre-release
  • ImprovementBreaking Change — Batching added to the onChange callback. Now the second argument can contain an array of CustomEvents as well as a single one. If several changes will be made in short period of time, they will be batched under the single onChange call
  • Improvement — Pressing "Enter" at the end of a Block won't lead to redundant block-changed event triggering. Only block-added event will be dispatched.
  • Fix — The onChange won't be triggered with Block Tunes opening and closing.
  • RefactoringEventDispatcher types improved. Now we can pass EventsMap via generic to specify a map of event names and their payloads that can be used in a particular EventDispatcher instance.
  • Refactoring — All events in common editor Event Bus now have own type declarations.
  • Refactoring — Now Blocks don't have own Mutation Observer. The single observer attached to the editor's blocks wrapper element. ModificationsObserver listens blocks wrapper changes, then emits an event into the common editor Event Bus. Each Block subscribes to such events and handle those who related to a particular Block.
  • Improvement — Block's mutation handler now will be called on every block change (including background changes). Previously, it have worked only if a particular Block have been focused.
  • Refactoring — Debounce have been removed from Block's mutation handler. The batching in ModificationObserver used instead.
  • Improvement — Number of caret saving method calls optimized for Block Tunes opening/closing.
  • New — Types for Block mutation events added.
  • Fix- Several bugs caused by random browser extensions. Now we are not searching for a block's container in the DOM on saving. Instead, we keep it in memory and update it when the tool changes a container element.

v2.27.0-rc.4

20 Mar 20:31
5257b06
Compare
Choose a tag to compare
v2.27.0-rc.4 Pre-release
Pre-release
  • Fix- Several bugs caused by random browser extensions

v2.27.0-rc.3

16 Mar 15:36
e9e0146
Compare
Choose a tag to compare
v2.27.0-rc.3 Pre-release
Pre-release
  • Improvement — Package size reduced by removing redundant files.

v2.27.0-rc.2

15 Mar 13:01
7cf5266
Compare
Choose a tag to compare
v2.27.0-rc.2 Pre-release
Pre-release
  • Fix — Resolve compiler error from importing the BlockToolData type.
  • Fix — Resolved a problem when document was being scrolled to the beginning after moving up a Block above the viewport.
  • Improvement — Package size reduced by removing redundant files.
  • Fix- Entire block being deleted on backspace key press when the browser has 3rd party grammar checker extension.

v2.27.0-rc.1

20 Feb 20:02
58d6869
Compare
Choose a tag to compare
v2.27.0-rc.1 Pre-release
Pre-release
  • Improvement — The onChange callback won't be triggered only if all mutations contain nodes with the data-mutation-free attributes.

v2.27.0-rc.0

10 Feb 18:33
07b1ce2
Compare
Choose a tag to compare
v2.27.0-rc.0 Pre-release
Pre-release
  • Refactoring — Popover class refactored.
  • ImprovementToolbox — Number of close() method calls optimized.