From 7470a6dd5357865807d4331e5416929fdc401917 Mon Sep 17 00:00:00 2001 From: Ian Storm Taylor Date: Tue, 5 Sep 2017 18:03:41 -0700 Subject: [PATCH] Expose transforms (#836) * refactor to extract applyOperation util * change handlers to receive transform instead of state * change onChange to receive a transform, update rich-text example * fix stack iterationg, convert check-list example * convert code-highlighting, embeds, emojis examples * change operations to use full paths, not indexes * switch split and join to be recursive * fix linter * fix onChange calls * make all operations invertable, add src/operations/* logic * rename "join" to "merge" * remove .length property of nodes * fix node.getFragmentAtRange logic * convert remaining examples, fix existing changes * fix .apply() calls and tests * change setSave and setIsNative transforms * fix insert_text operations to include marks always * cleanup and fixes * fix node inheritance * fix core onCut handler * skip constructor in node inheritance * cleanup * change updateDescendant to updateNode * add and update docs * eliminate need for .apply(), change history to mutable * add missing file * add deprecation support to Transform objects * rename "transform" to "change" * update benchmark * add deprecation util to logger * update transform isNative attr * fix remaining warn use * simplify history checkpointing logic * fix tests * revert history to being immutable * fix history * fix normalize * fix syntax error from merge --- .eslintrc | 1 - .gitignore | 5 +- .../index.js | 2 +- .../input.yaml | 0 .../transforms/delete-backward/index.js | 7 +- .../fixtures/transforms/insert-text/index.js | 7 +- .../fixtures/transforms/normalize/index.js | 3 +- .../fixtures/transforms/split-block/index.js | 7 +- docs/Readme.md | 8 +- docs/Summary.md | 2 +- .../statelessness-and-immutability.md | 8 +- docs/concepts/the-selection-model.md | 4 +- docs/general/comparisons.md | 4 +- docs/guides/schemas.md | 2 +- docs/reference/Readme.md | 2 +- docs/reference/components/editor.md | 19 +- docs/reference/models/block.md | 6 - docs/reference/models/document.md | 6 - docs/reference/models/inline.md | 6 - docs/reference/models/node.md | 6 - docs/reference/models/schema.md | 10 +- docs/reference/models/state.md | 12 +- docs/reference/models/text.md | 6 - docs/reference/models/transform.md | 256 +++++---- docs/reference/plugins/plugin.md | 32 +- docs/walkthroughs/adding-event-handlers.md | 4 +- .../applying-custom-formatting.md | 10 +- .../defining-custom-block-nodes.md | 8 +- docs/walkthroughs/using-plugins.md | 6 +- examples/check-lists/index.js | 28 +- examples/code-highlighting/index.js | 34 +- examples/dev/large-document/index.js | 17 +- examples/dev/performance-plain/index.js | 4 +- examples/dev/performance-rich/index.js | 39 +- examples/embeds/index.js | 6 +- examples/embeds/video.js | 12 +- examples/emojis/index.js | 28 +- examples/focus-blur/index.js | 13 +- examples/forced-layout/index.js | 20 +- examples/hovering-menu/index.js | 16 +- examples/iframes/index.js | 37 +- examples/images/index.js | 97 ++-- examples/index.css | 5 + examples/links/index.js | 80 +-- examples/markdown-preview/index.js | 4 +- examples/markdown-shortcuts/index.js | 71 +-- examples/paste-html/index.js | 16 +- examples/plain-text/index.js | 6 +- examples/plugins/index.js | 4 +- examples/read-only/index.js | 4 +- examples/rich-text/index.js | 54 +- examples/rtl/index.js | 15 +- examples/tables/index.js | 42 +- src/Readme.md | 3 +- src/changes/Readme.md | 2 + src/changes/at-current-range.js | 457 +++++++++++++++ src/{transforms => changes}/at-range.js | 471 ++++++++------- src/{transforms => changes}/by-key.js | 331 +++++++---- src/{transforms => changes}/index.js | 8 +- src/{transforms => changes}/normalize.js | 102 +--- src/changes/on-history.js | 80 +++ src/changes/on-selection.js | 293 ++++++++++ src/changes/on-state.js | 47 ++ src/components/content.js | 49 +- src/components/editor.js | 76 +-- src/components/void.js | 20 +- src/constants/model-types.js | 16 +- src/index.js | 22 +- src/models/Readme.md | 14 +- src/models/block.js | 77 +-- src/models/change.js | 219 +++++++ src/models/character.js | 47 +- src/models/data.js | 12 +- src/models/document.js | 46 +- src/models/history.js | 189 ++++++ src/models/inline.js | 61 +- src/models/mark.js | 54 +- src/models/node.js | 538 +++++++++--------- src/models/range.js | 33 +- src/models/schema.js | 36 +- src/models/selection.js | 82 +-- src/models/stack.js | 117 ++-- src/models/state.js | 94 +-- src/models/text.js | 74 +-- src/models/transform.js | 172 ------ src/operations/Readme.md | 2 + src/operations/apply.js | 498 ++++++++++++++++ src/operations/index.js | 14 + src/operations/invert.js | 199 +++++++ src/plugins/core.js | 415 +++++--------- src/schemas/Readme.md | 2 +- src/schemas/core.js | 67 +-- src/serializers/raw.js | 72 +-- src/transforms/Readme.md | 2 - src/transforms/apply-operation.js | 501 ---------------- src/transforms/at-current-range.js | 511 ----------------- src/transforms/call.js | 30 - src/transforms/on-history.js | 122 ---- src/transforms/on-selection.js | 233 -------- src/transforms/operations.js | 532 ----------------- src/utils/logger.js | 55 ++ src/utils/normalize.js | 169 ++++-- src/utils/warn.js | 27 - test/Readme.md | 2 +- .../add-mark/across-blocks/index.js | 4 +- .../add-mark/across-blocks/input.yaml | 0 .../add-mark/across-blocks/output.yaml | 0 .../add-mark/across-inlines/index.js | 4 +- .../add-mark/across-inlines/input.yaml | 0 .../add-mark/across-inlines/output.yaml | 0 .../add-mark/collapsed-selection/index.js | 4 +- .../add-mark/collapsed-selection/input.yaml | 0 .../add-mark/collapsed-selection/output.yaml | 0 .../add-mark/existing-marks/index.js | 4 +- .../add-mark/existing-marks/input.yaml | 0 .../add-mark/existing-marks/output.yaml | 0 .../add-mark/first-character/index.js | 4 +- .../add-mark/first-character/input.yaml | 0 .../add-mark/first-character/output.yaml | 0 .../add-mark/last-character/index.js | 8 +- .../add-mark/last-character/input.yaml | 0 .../add-mark/last-character/output.yaml | 0 .../add-mark/middle-character/index.js | 4 +- .../add-mark/middle-character/input.yaml | 0 .../add-mark/middle-character/output.yaml | 0 .../add-mark/whole-word/index.js | 6 +- .../add-mark/whole-word/input.yaml | 0 .../add-mark/whole-word/output.yaml | 0 .../add-mark/with-mark-object/index.js | 4 +- .../add-mark/with-mark-object/input.yaml | 0 .../add-mark/with-mark-object/output.yaml | 0 .../add-mark/with-plain-object/index.js | 4 +- .../add-mark/with-plain-object/input.yaml | 0 .../add-mark/with-plain-object/output.yaml | 0 .../before-inline-sibling/index.js | 8 +- .../before-inline-sibling/input.yaml | 0 .../before-inline-sibling/output.yaml | 0 .../empty-after-void-block/index.js | 4 +- .../empty-after-void-block/input.yaml | 0 .../empty-after-void-block/output.yaml | 0 .../delete-backward/first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../inside-inline-sibling/index.js | 10 +- .../inside-inline-sibling/input.yaml | 0 .../inside-inline-sibling/output.yaml | 0 .../join-blocks-with-inlines/index.js | 8 +- .../join-blocks-with-inlines/input.yaml | 0 .../join-blocks-with-inlines/output.yaml | 0 .../delete-backward/join-blocks}/index.js | 8 +- .../delete-backward/join-blocks/input.yaml | 0 .../delete-backward/join-blocks/output.yaml | 0 .../join-nested-blocks}/index.js | 8 +- .../join-nested-blocks/input.yaml | 0 .../join-nested-blocks/output.yaml | 0 .../delete-backward/last-character/index.js | 8 +- .../delete-backward/last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../delete-backward/middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../multiple-characters/index.js | 8 +- .../multiple-characters/input.yaml | 0 .../multiple-characters/output.yaml | 0 .../single-non-void-block}/index.js | 4 +- .../single-non-void-block/input.yaml | 0 .../single-non-void-block/output.yaml | 0 .../single-void-block}/index.js | 4 +- .../single-void-block/input.yaml | 0 .../single-void-block/output.yaml | 0 .../start-of-document/index.js | 4 +- .../start-of-document/input.yaml | 0 .../start-of-document/output.yaml | 0 .../before-inline-sibling/index.js | 4 +- .../before-inline-sibling/input.yaml | 0 .../before-inline-sibling/output.yaml | 0 .../empty-before-void-block}/index.js | 4 +- .../empty-before-void-block/input.yaml | 0 .../empty-before-void-block/output.yaml | 0 .../delete-forward/end-of-document/index.js | 8 +- .../delete-forward/end-of-document/input.yaml | 0 .../end-of-document/output.yaml | 0 .../delete-forward/first-character/index.js | 4 +- .../delete-forward/first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../inside-inline-sibling/index.js | 6 +- .../inside-inline-sibling/input.yaml | 0 .../inside-inline-sibling/output.yaml | 0 .../join-blocks-with-inlines/index.js | 8 +- .../join-blocks-with-inlines/input.yaml | 0 .../join-blocks-with-inlines/output.yaml | 0 .../delete-forward/join-blocks/index.js | 8 +- .../delete-forward/join-blocks/input.yaml | 0 .../delete-forward/join-blocks/output.yaml | 0 .../join-nested-blocks/index.js | 27 + .../join-nested-blocks/input.yaml | 0 .../join-nested-blocks/output.yaml | 0 .../delete-forward/last-character/index.js | 27 + .../delete-forward/last-character/input.yaml | 0 .../delete-forward/last-character/output.yaml | 0 .../delete-forward/middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../multiple-characters/index.js | 4 +- .../multiple-characters/input.yaml | 0 .../multiple-characters/output.yaml | 0 .../single-non-void-block/index.js | 4 +- .../single-non-void-block/input.yaml | 0 .../single-non-void-block/output.yaml | 0 .../single-void-block}/index.js | 4 +- .../single-void-block/input.yaml | 0 .../single-void-block/output.yaml | 0 .../start-text-middle-inline/index.js | 4 +- .../start-text-middle-inline/input.yaml | 0 .../start-text-middle-inline/output.yaml | 0 .../delete/across-blocks-inlines/index.js | 4 +- .../delete/across-blocks-inlines/input.yaml | 0 .../delete/across-blocks-inlines/output.yaml | 0 .../delete/across-nested-blocks/index.js | 6 +- .../delete/across-nested-blocks/input.yaml | 0 .../delete/across-nested-blocks/output.yaml | 0 .../delete/before-inline-sibling/index.js | 12 +- .../delete/before-inline-sibling/input.yaml | 0 .../delete/before-inline-sibling/output.yaml | 0 .../delete/first-character/index.js | 4 +- .../delete/first-character/input.yaml | 0 .../delete/first-character/output.yaml | 0 .../delete/inside-inline-sibling/index.js | 12 +- .../delete/inside-inline-sibling/input.yaml | 0 .../delete/inside-inline-sibling/output.yaml | 0 .../delete/join-blocks-and-trim/index.js | 4 +- .../delete/join-blocks-and-trim/input.yaml | 0 .../delete/join-blocks-and-trim/output.yaml | 0 .../delete/join-blocks-with-inlines/index.js | 6 +- .../join-blocks-with-inlines/input.yaml | 0 .../join-blocks-with-inlines/output.yaml | 0 .../delete/join-blocks/index.js | 6 +- .../delete/join-blocks/input.yaml | 0 .../delete/join-blocks/output.yaml | 0 .../delete/last-character/index.js | 8 +- .../delete/last-character/input.yaml | 0 .../delete/last-character/output.yaml | 0 .../delete/middle-character/index.js | 4 +- .../delete/middle-character/input.yaml | 0 .../delete/middle-character/output.yaml | 0 .../delete/nested-block/index.js | 4 +- .../delete/nested-block/input.yaml | 0 .../delete/nested-block/output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../delete/void-block-as-only/index.js | 4 +- .../delete/void-block-as-only/input.yaml | 0 .../delete/void-block-as-only/output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 5 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../delete/whole-inline/index.js | 6 +- .../delete/whole-inline/input.yaml | 0 .../delete/whole-inline/output.yaml | 0 .../delete/whole-word/index.js | 6 +- .../delete/whole-word/input.yaml | 0 .../delete/whole-word/output.yaml | 0 .../insert-block/block-end/index.js | 8 +- .../insert-block/block-end/input.yaml | 0 .../insert-block/block-end/output.yaml | 0 .../insert-block/block-middle/index.js | 4 +- .../insert-block/block-middle/input.yaml | 0 .../insert-block/block-middle/output.yaml | 0 .../insert-block/block-start}/index.js | 4 +- .../insert-block/block-start/input.yaml | 0 .../insert-block/block-start/output.yaml | 0 .../insert-block/is-empty}/index.js | 4 +- .../insert-block/is-empty/input.yaml | 0 .../insert-block/is-empty/output.yaml | 0 .../insert-block/is-void/index.js | 6 +- .../insert-block/is-void/input.yaml | 2 +- .../insert-block/is-void/output.yaml | 4 +- .../insert-block/with-block/index.js | 4 +- .../insert-block/with-block/input.yaml | 0 .../insert-block/with-block/output.yaml | 0 .../insert-block/with-object/index.js | 4 +- .../insert-block/with-object/input.yaml | 0 .../insert-block/with-object/output.yaml | 0 .../end-block-multiple-blocks/fragment.yaml | 0 .../end-block-multiple-blocks/index.js | 12 +- .../end-block-multiple-blocks/input.yaml | 0 .../end-block-multiple-blocks/output.yaml | 0 .../insert-fragment/end-block/fragment.yaml | 0 .../insert-fragment/end-block/index.js | 12 +- .../insert-fragment/end-block/input.yaml | 0 .../insert-fragment/end-block/output.yaml | 0 .../insert-fragment/end-inline/fragment.yaml | 0 .../insert-fragment/end-inline/index.js | 12 +- .../insert-fragment/end-inline/input.yaml | 0 .../insert-fragment/end-inline/output.yaml | 0 .../fragment-multiple-blocks/fragment.yaml | 0 .../fragment-multiple-blocks/index.js | 8 +- .../fragment-multiple-blocks/input.yaml | 0 .../fragment-multiple-blocks/output.yaml | 0 .../fragment-nested-blocks/fragment.yaml | 0 .../fragment-nested-blocks/index.js | 8 +- .../fragment-nested-blocks/input.yaml | 0 .../fragment-nested-blocks/output.yaml | 0 .../middle-block/fragment.yaml | 0 .../insert-fragment/middle-block/index.js | 8 +- .../insert-fragment/middle-block/input.yaml | 0 .../insert-fragment/middle-block/output.yaml | 0 .../fragment.yaml | 0 .../middle-inline-fragment-inline/index.js | 4 +- .../middle-inline-fragment-inline/input.yaml | 0 .../middle-inline-fragment-inline/output.yaml | 0 .../middle-inline/fragment.yaml | 0 .../insert-fragment/middle-inline/index.js | 8 +- .../insert-fragment/middle-inline/input.yaml | 0 .../insert-fragment/middle-inline/output.yaml | 0 .../start-block-multiple-blocks/fragment.yaml | 0 .../start-block-multiple-blocks/index.js | 8 +- .../start-block-multiple-blocks/input.yaml | 0 .../start-block-multiple-blocks/output.yaml | 0 .../insert-fragment/start-block/fragment.yaml | 0 .../insert-fragment/start-block/index.js | 8 +- .../insert-fragment/start-block/input.yaml | 0 .../insert-fragment/start-block/output.yaml | 0 .../start-inline/fragment.yaml | 0 .../insert-fragment/start-inline}/index.js | 8 +- .../insert-fragment/start-inline/input.yaml | 0 .../insert-fragment/start-inline/output.yaml | 0 .../start-second-block/fragment.yaml | 0 .../start-second-block}/index.js | 8 +- .../start-second-block/input.yaml | 0 .../start-second-block/output.yaml | 0 .../with-delete-across-blocks/fragment.yaml | 0 .../with-delete-across-blocks/index.js | 8 +- .../with-delete-across-blocks/input.yaml | 0 .../with-delete-across-blocks/output.yaml | 0 .../insert-inline/block-end/index.js | 8 +- .../insert-inline/block-end/input.yaml | 0 .../insert-inline/block-end/output.yaml | 0 .../insert-inline/block-middle/index.js | 4 +- .../insert-inline/block-middle/input.yaml | 0 .../insert-inline/block-middle/output.yaml | 0 .../insert-inline/block-start}/index.js | 4 +- .../insert-inline/block-start/input.yaml | 0 .../insert-inline/block-start/output.yaml | 0 .../insert-inline/inline-middle/index.js | 4 +- .../insert-inline/inline-middle/input.yaml | 0 .../insert-inline/inline-middle/output.yaml | 0 .../insert-inline/is-empty}/index.js | 4 +- .../insert-inline/is-empty/input.yaml | 0 .../insert-inline/is-empty/output.yaml | 0 .../insert-inline/is-void/index.js | 4 +- .../insert-inline/is-void/input.yaml | 0 .../insert-inline/is-void/output.yaml | 0 .../insert-text/after-mark/index.js | 4 +- .../insert-text/after-mark/input.yaml | 0 .../insert-text/after-mark/output.yaml | 0 .../insert-text/before-mark}/index.js | 4 +- .../insert-text/before-mark/input.yaml | 0 .../insert-text/before-mark/output.yaml | 0 .../insert-text/during-mark/index.js | 4 +- .../insert-text/during-mark/input.yaml | 0 .../insert-text/during-mark/output.yaml | 0 .../insert-text/first-character/index.js | 4 +- .../insert-text/first-character/input.yaml | 0 .../insert-text/first-character/output.yaml | 0 .../insert-text/first-space/index.js | 4 +- .../insert-text/first-space/input.yaml | 0 .../insert-text/first-space/output.yaml | 0 .../insert-text/first-words/index.js | 4 +- .../insert-text/first-words/input.yaml | 0 .../insert-text/first-words/output.yaml | 0 .../insert-text/inside-void/index.js | 4 +- .../insert-text/inside-void/input.yaml | 0 .../insert-text/inside-void/output.yaml | 0 .../insert-text/last-character/index.js | 27 + .../insert-text/last-character/input.yaml | 0 .../insert-text/last-character/output.yaml | 0 .../insert-text/last-space/index.js | 8 +- .../insert-text/last-space/input.yaml | 0 .../insert-text/last-space/output.yaml | 0 .../insert-text/last-words/index.js | 8 +- .../insert-text/last-words/input.yaml | 0 .../insert-text/last-words/output.yaml | 0 .../insert-text/middle-character}/index.js | 4 +- .../insert-text/middle-character/input.yaml | 0 .../insert-text/middle-character/output.yaml | 0 .../insert-text/middle-space/index.js | 4 +- .../insert-text/middle-space/input.yaml | 0 .../insert-text/middle-space/output.yaml | 0 .../insert-text/middle-words/index.js | 4 +- .../insert-text/middle-words/input.yaml | 0 .../insert-text/middle-words/output.yaml | 0 .../insert-text/with-marks/index.js | 8 +- .../insert-text/with-marks/input.yaml | 0 .../insert-text/with-marks/output.yaml | 0 .../remove-mark/across-blocks/index.js | 4 +- .../remove-mark/across-blocks/input.yaml | 0 .../remove-mark/across-blocks/output.yaml | 0 .../remove-mark/across-inlines/index.js | 4 +- .../remove-mark/across-inlines/input.yaml | 0 .../remove-mark/across-inlines/output.yaml | 0 .../remove-mark/collapsed-selection/index.js | 4 +- .../collapsed-selection/input.yaml | 0 .../collapsed-selection/output.yaml | 0 .../remove-mark/existing-marks/index.js | 4 +- .../remove-mark/existing-marks/input.yaml | 0 .../remove-mark/existing-marks/output.yaml | 0 .../remove-mark/first-character/index.js | 4 +- .../remove-mark/first-character/input.yaml | 0 .../remove-mark/first-character/output.yaml | 0 .../remove-mark/last-character/index.js | 8 +- .../remove-mark/last-character/input.yaml | 0 .../remove-mark/last-character/output.yaml | 0 .../remove-mark/middle-character/index.js | 4 +- .../remove-mark/middle-character/input.yaml | 0 .../remove-mark/middle-character/output.yaml | 0 .../remove-mark/whole-word/index.js | 6 +- .../remove-mark/whole-word/input.yaml | 0 .../remove-mark/whole-word/output.yaml | 0 .../remove-mark/with-mark-object/index.js | 4 +- .../remove-mark/with-mark-object/input.yaml | 0 .../remove-mark/with-mark-object/output.yaml | 0 .../remove-mark/with-plain-object/index.js | 4 +- .../remove-mark/with-plain-object/input.yaml | 0 .../remove-mark/with-plain-object/output.yaml | 0 .../set-block/across-blocks/index.js | 4 +- .../set-block/across-blocks/input.yaml | 0 .../set-block/across-blocks/output.yaml | 0 .../set-block/across-inlines/index.js | 4 +- .../set-block/across-inlines/input.yaml | 0 .../set-block/across-inlines/output.yaml | 0 .../set-block/data-only/index.js | 4 +- .../set-block/data-only/input.yaml | 0 .../set-block/data-only/output.yaml | 0 .../set-block/nested-block/index.js | 4 +- .../set-block/nested-block/input.yaml | 0 .../set-block/nested-block/output.yaml | 0 .../single-block-string-shorthand/index.js | 4 +- .../single-block-string-shorthand/input.yaml | 0 .../single-block-string-shorthand/output.yaml | 0 .../set-block/single-block/index.js | 4 +- .../set-block/single-block/input.yaml | 0 .../set-block/single-block/output.yaml | 0 .../set-block/with-data-object/index.js | 4 +- .../set-block/with-data-object/input.yaml | 0 .../set-block/with-data-object/output.yaml | 0 .../set-block/with-data/index.js | 4 +- .../set-block/with-data/input.yaml | 0 .../set-block/with-data/output.yaml | 0 .../set-block/with-is-void/index.js | 4 +- .../set-block/with-is-void/input.yaml | 0 .../set-block/with-is-void/output.yaml | 0 .../set-inline/across-inlines/index.js | 4 +- .../set-inline/across-inlines/input.yaml | 0 .../set-inline/across-inlines/output.yaml | 0 .../set-inline/data-only/index.js | 4 +- .../set-inline/data-only/input.yaml | 0 .../set-inline/data-only/output.yaml | 0 .../set-inline/nested-inline/index.js | 4 +- .../set-inline/nested-inline/input.yaml | 0 .../set-inline/nested-inline/output.yaml | 0 .../single-inline-string-shorthand/index.js | 4 +- .../single-inline-string-shorthand/input.yaml | 0 .../output.yaml | 0 .../set-inline/single-inline/index.js | 4 +- .../set-inline/single-inline/input.yaml | 0 .../set-inline/single-inline/output.yaml | 0 .../set-inline/with-data-object/index.js | 4 +- .../set-inline/with-data-object/input.yaml | 0 .../set-inline/with-data-object/output.yaml | 0 .../set-inline/with-data/index.js | 4 +- .../set-inline/with-data/input.yaml | 0 .../set-inline/with-data/output.yaml | 0 .../set-inline/with-is-void/index.js | 4 +- .../set-inline/with-is-void/input.yaml | 0 .../set-inline/with-is-void/output.yaml | 0 .../split-block/after-inline/index.js | 4 +- .../split-block/after-inline/input.yaml | 0 .../split-block/after-inline/output.yaml | 0 .../split-block/before-inline/index.js | 4 +- .../split-block/before-inline/input.yaml | 0 .../split-block/before-inline/output.yaml | 0 .../split-block/block-end/index.js | 8 +- .../split-block/block-end/input.yaml | 0 .../split-block/block-end/output.yaml | 0 .../split-block/block-middle/index.js | 4 +- .../split-block/block-middle/input.yaml | 0 .../split-block/block-middle/output.yaml | 0 .../split-block/block-start/index.js | 4 +- .../split-block/block-start/input.yaml | 0 .../split-block/block-start/output.yaml | 0 .../split-block/depth/index.js | 4 +- .../split-block/depth/input.yaml | 0 .../split-block/depth/output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../with-delete-across-blocks/index.js | 4 +- .../with-delete-across-blocks/input.yaml | 0 .../with-delete-across-blocks/output.yaml | 0 .../split-block/with-delete/index.js | 4 +- .../split-block/with-delete/input.yaml | 0 .../split-block/with-delete/output.yaml | 0 .../split-block/with-inline/index.js | 4 +- .../split-block/with-inline/input.yaml | 0 .../split-block/with-inline/output.yaml | 0 .../split-inline/block-end/index.js | 8 +- .../split-inline/block-end/input.yaml | 0 .../split-inline/block-end/output.yaml | 0 .../split-inline/block-middle}/index.js | 4 +- .../split-inline/block-middle/input.yaml | 0 .../split-inline/block-middle/output.yaml | 0 .../split-inline/block-start/index.js | 4 +- .../split-inline/block-start/input.yaml | 0 .../split-inline/block-start/output.yaml | 0 .../split-inline/depth/index.js | 4 +- .../split-inline/depth/input.yaml | 0 .../split-inline/depth/output.yaml | 0 .../split-inline/with-delete/index.js | 4 +- .../split-inline/with-delete/input.yaml | 0 .../split-inline/with-delete/output.yaml | 0 .../split-inline/with-marks}/index.js | 4 +- .../split-inline/with-marks/input.yaml | 0 .../split-inline/with-marks/output.yaml | 0 .../toggle-mark/add-across-blocks/index.js | 4 +- .../toggle-mark/add-across-blocks/input.yaml | 0 .../toggle-mark/add-across-blocks/output.yaml | 0 .../toggle-mark/add-across-inlines/index.js | 4 +- .../toggle-mark/add-across-inlines/input.yaml | 0 .../add-across-inlines/output.yaml | 0 .../add-collapsed-selection/index.js | 4 +- .../add-collapsed-selection/input.yaml | 0 .../add-collapsed-selection/output.yaml | 0 .../toggle-mark/add-existing-marks}/index.js | 4 +- .../toggle-mark/add-existing-marks/input.yaml | 0 .../add-existing-marks/output.yaml | 0 .../toggle-mark/add-first-character/index.js | 4 +- .../add-first-character/input.yaml | 0 .../add-first-character/output.yaml | 0 .../toggle-mark/add-last-character/index.js | 8 +- .../toggle-mark/add-last-character/input.yaml | 0 .../add-last-character/output.yaml | 0 .../toggle-mark/add-middle-character/index.js | 4 +- .../add-middle-character/input.yaml | 0 .../add-middle-character/output.yaml | 0 .../toggle-mark/add-whole-word/index.js | 6 +- .../toggle-mark/add-whole-word/input.yaml | 0 .../toggle-mark/add-whole-word/output.yaml | 0 .../toggle-mark/add-with-mark-object/index.js | 4 +- .../add-with-mark-object/input.yaml | 0 .../add-with-mark-object/output.yaml | 0 .../add-with-plain-object/index.js | 4 +- .../add-with-plain-object/input.yaml | 0 .../add-with-plain-object/output.yaml | 0 .../toggle-mark/remove-across-blocks/index.js | 4 +- .../remove-across-blocks/input.yaml | 0 .../remove-across-blocks/output.yaml | 0 .../remove-across-inlines/index.js | 4 +- .../remove-across-inlines/input.yaml | 0 .../remove-across-inlines/output.yaml | 0 .../remove-collapsed-selection/index.js | 4 +- .../remove-collapsed-selection/input.yaml | 0 .../remove-collapsed-selection/output.yaml | 0 .../remove-existing-marks}/index.js | 4 +- .../remove-existing-marks/input.yaml | 0 .../remove-existing-marks/output.yaml | 0 .../remove-first-character/index.js | 4 +- .../remove-first-character/input.yaml | 0 .../remove-first-character/output.yaml | 0 .../remove-last-character/index.js | 24 + .../remove-last-character/input.yaml | 0 .../remove-last-character/output.yaml | 0 .../remove-middle-character/index.js | 4 +- .../remove-middle-character/input.yaml | 0 .../remove-middle-character/output.yaml | 0 .../toggle-mark/remove-whole-word/index.js | 24 + .../toggle-mark/remove-whole-word/input.yaml | 0 .../toggle-mark/remove-whole-word/output.yaml | 0 .../remove-with-mark-object/index.js | 4 +- .../remove-with-mark-object/input.yaml | 0 .../remove-with-mark-object/output.yaml | 0 .../remove-with-plain-object/index.js | 4 +- .../remove-with-plain-object/input.yaml | 0 .../remove-with-plain-object/output.yaml | 0 .../unwrap-block/across-blocks/index.js | 4 +- .../unwrap-block/across-blocks/input.yaml | 0 .../unwrap-block/across-blocks/output.yaml | 0 .../unwrap-block/across-inlines/index.js | 4 +- .../unwrap-block/across-inlines/input.yaml | 0 .../unwrap-block/across-inlines/output.yaml | 0 .../unwrap-block/ending-child-blocks/index.js | 4 +- .../ending-child-blocks/input.yaml | 0 .../ending-child-blocks/output.yaml | 0 .../unwrap-block/middle-child-blocks/index.js | 4 +- .../middle-child-blocks/input.yaml | 0 .../middle-child-blocks/output.yaml | 0 .../unwrap-block/nested-block/index.js | 4 +- .../unwrap-block/nested-block/input.yaml | 0 .../unwrap-block/nested-block/output.yaml | 0 .../unwrap-block/single-block/index.js | 4 +- .../unwrap-block/single-block/input.yaml | 0 .../unwrap-block/single-block/output.yaml | 0 .../starting-child-blocks/index.js | 4 +- .../starting-child-blocks/input.yaml | 0 .../starting-child-blocks/output.yaml | 0 .../unwrap-block/with-object/index.js | 4 +- .../unwrap-block/with-object/input.yaml | 0 .../unwrap-block/with-object/output.yaml | 0 .../unwrap-inline/across-blocks/index.js | 4 +- .../unwrap-inline/across-blocks/input.yaml | 0 .../unwrap-inline/across-blocks/output.yaml | 0 .../unwrap-inline/across-inlines/index.js | 4 +- .../unwrap-inline/across-inlines/input.yaml | 0 .../unwrap-inline/across-inlines/output.yaml | 0 .../unwrap-inline/nested-block}/index.js | 4 +- .../unwrap-inline/nested-block/input.yaml | 0 .../unwrap-inline/nested-block/output.yaml | 0 .../unwrap-inline/only-one/index.js | 4 +- .../unwrap-inline/only-one/input.yaml | 0 .../unwrap-inline/only-one/output.yaml | 0 .../unwrap-inline/single-block}/index.js | 4 +- .../unwrap-inline/single-block/input.yaml | 0 .../unwrap-inline/single-block/output.yaml | 0 .../unwrap-inline/with-object/index.js | 4 +- .../unwrap-inline/with-object/input.yaml | 0 .../unwrap-inline/with-object/output.yaml | 0 .../wrap-block/across-blocks/index.js | 4 +- .../wrap-block/across-blocks/input.yaml | 0 .../wrap-block/across-blocks/output.yaml | 0 .../wrap-block/across-inlines/index.js | 4 +- .../wrap-block/across-inlines/input.yaml | 0 .../wrap-block/across-inlines/output.yaml | 0 .../wrap-block/nested-block/index.js | 4 +- .../wrap-block/nested-block/input.yaml | 0 .../wrap-block/nested-block/output.yaml | 0 .../wrap-block/single-block/index.js | 4 +- .../wrap-block/single-block/input.yaml | 0 .../wrap-block/single-block/output.yaml | 0 .../wrap-block/with-object/index.js | 4 +- .../wrap-block/with-object/input.yaml | 0 .../wrap-block/with-object/output.yaml | 0 .../wrap-inline/across-blocks/index.js | 10 +- .../wrap-inline/across-blocks/input.yaml | 0 .../wrap-inline/across-blocks/output.yaml | 0 .../wrap-inline/across-inlines/index.js | 15 +- .../wrap-inline/across-inlines/input.yaml | 0 .../wrap-inline/across-inlines/output.yaml | 0 .../wrap-inline/inline-void/index.js | 4 +- .../wrap-inline/inline-void/input.yaml | 0 .../wrap-inline/inline-void/output.yaml | 0 .../wrap-inline/nested-block}/index.js | 14 +- .../wrap-inline/nested-block/input.yaml | 0 .../wrap-inline/nested-block/output.yaml | 0 .../wrap-inline/single-block}/index.js | 14 +- .../wrap-inline/single-block/input.yaml | 0 .../wrap-inline/single-block/output.yaml | 0 .../wrap-inline/twice/index.js | 8 +- .../wrap-inline/twice/input.yaml | 0 .../wrap-inline/twice/output.yaml | 0 .../wrap-inline/whole-block/index.js | 6 +- .../wrap-inline/whole-block/input.yaml | 0 .../wrap-inline/whole-block/output.yaml | 0 .../wrap-inline/with-object/index.js | 14 +- .../wrap-inline/with-object/input.yaml | 0 .../wrap-inline/with-object/output.yaml | 0 .../wrap-text/across-blocks/index.js | 4 +- .../wrap-text/across-blocks/input.yaml | 0 .../wrap-text/across-blocks/output.yaml | 0 .../wrap-text/across-inlines/index.js | 4 +- .../wrap-text/across-inlines/input.yaml | 0 .../wrap-text/across-inlines/output.yaml | 0 .../wrap-text/backwards-selection/index.js | 4 +- .../wrap-text/backwards-selection/input.yaml | 0 .../wrap-text/backwards-selection/output.yaml | 0 .../wrap-text/empty-block/index.js | 4 +- .../wrap-text/empty-block/input.yaml | 0 .../wrap-text/empty-block/output.yaml | 0 .../wrap-text/end-of-block/index.js | 4 +- .../wrap-text/end-of-block/input.yaml | 0 .../wrap-text/end-of-block/output.yaml | 0 .../wrap-text/middle-of-block/index.js | 4 +- .../wrap-text/middle-of-block/input.yaml | 0 .../wrap-text/middle-of-block/output.yaml | 0 .../wrap-text/start-of-block/index.js | 4 +- .../wrap-text/start-of-block/input.yaml | 0 .../wrap-text/start-of-block/output.yaml | 0 .../wrap-text/whole-block/index.js | 4 +- .../wrap-text/whole-block/input.yaml | 0 .../wrap-text/whole-block/output.yaml | 0 .../wrap-text/without-suffix/index.js | 4 +- .../wrap-text/without-suffix/input.yaml | 0 .../wrap-text/without-suffix/output.yaml | 0 .../add-mark-at-range/across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../add-mark-at-range/across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../add-mark-at-range/existing-marks/index.js | 4 +- .../existing-marks/input.yaml | 0 .../existing-marks/output.yaml | 0 .../first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../add-mark-at-range/last-character/index.js | 8 +- .../last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../add-mark-at-range/whole-word/index.js | 6 +- .../add-mark-at-range/whole-word/input.yaml | 0 .../add-mark-at-range/whole-word/output.yaml | 0 .../with-mark-object/index.js | 4 +- .../with-mark-object/input.yaml | 0 .../with-mark-object/output.yaml | 0 .../with-plain-object/index.js | 4 +- .../with-plain-object/input.yaml | 0 .../with-plain-object/output.yaml | 0 .../across-blocks-inlines/index.js | 4 +- .../across-blocks-inlines/input.yaml | 0 .../across-blocks-inlines/output.yaml | 0 .../delete-at-range/across-depths/index.js | 6 +- .../delete-at-range/across-depths/input.yaml | 0 .../delete-at-range/across-depths/output.yaml | 0 .../across-inline-texts/index.js | 6 +- .../across-inline-texts/input.yaml | 0 .../across-inline-texts/output.yaml | 0 .../before-inline-sibling/index.js | 8 +- .../before-inline-sibling/input.yaml | 0 .../before-inline-sibling/output.yaml | 0 .../double-nested-block/index.js | 4 +- .../double-nested-block/input.yaml | 0 .../double-nested-block/output.yaml | 0 .../delete-at-range/first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../inside-inline-sibling/index.js | 8 +- .../inside-inline-sibling/input.yaml | 0 .../inside-inline-sibling/output.yaml | 0 .../join-across-nested-blocks/index.js | 6 +- .../join-across-nested-blocks/input.yaml | 0 .../join-across-nested-blocks/output.yaml | 0 .../join-blocks-and-trim/index.js | 4 +- .../join-blocks-and-trim/input.yaml | 0 .../join-blocks-and-trim/output.yaml | 0 .../join-blocks-with-inlines/index.js | 6 +- .../join-blocks-with-inlines/input.yaml | 0 .../join-blocks-with-inlines/output.yaml | 0 .../delete-at-range/join-blocks/index.js | 6 +- .../delete-at-range/join-blocks/input.yaml | 0 .../delete-at-range/join-blocks/output.yaml | 0 .../join-nested-blocks/index.js | 6 +- .../join-nested-blocks/input.yaml | 0 .../join-nested-blocks/output.yaml | 0 .../delete-at-range/last-character/index.js | 8 +- .../delete-at-range/last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../delete-at-range/middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../delete-at-range/nested-block/index.js | 4 +- .../delete-at-range/nested-block/input.yaml | 0 .../delete-at-range/nested-block/output.yaml | 0 .../delete-at-range/whole-inline/index.js | 6 +- .../delete-at-range/whole-inline/input.yaml | 0 .../delete-at-range/whole-inline/output.yaml | 0 .../delete-at-range/whole-word/index.js | 6 +- .../delete-at-range/whole-word/input.yaml | 0 .../delete-at-range/whole-word/output.yaml | 0 .../after-inline-sibling-across}/index.js | 8 +- .../after-inline-sibling-across/input.yaml | 0 .../after-inline-sibling-across/output.yaml | 0 .../after-inline-sibling}/index.js | 8 +- .../after-inline-sibling/input.yaml | 0 .../after-inline-sibling/output.yaml | 0 .../first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../inside-inline-sibling/index.js | 8 +- .../inside-inline-sibling/input.yaml | 0 .../inside-inline-sibling/output.yaml | 0 .../join-blocks-with-inline-void/index.js | 4 +- .../join-blocks-with-inline-void/input.yaml | 0 .../join-blocks-with-inline-void/output.yaml | 0 .../join-blocks-with-inlines/index.js | 4 +- .../join-blocks-with-inlines/input.yaml | 0 .../join-blocks-with-inlines/output.yaml | 0 .../join-blocks}/index.js | 4 +- .../join-blocks/input.yaml | 0 .../join-blocks/output.yaml | 0 .../join-nested-blocks}/index.js | 4 +- .../join-nested-blocks/input.yaml | 0 .../join-nested-blocks/output.yaml | 0 .../last-character/index.js | 8 +- .../last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../multiple-characters/index.js | 8 +- .../multiple-characters/input.yaml | 0 .../multiple-characters/output.yaml | 0 .../start-of-document/index.js | 4 +- .../start-of-document/input.yaml | 0 .../start-of-document/output.yaml | 0 .../emoji-after-inline/index.js | 8 +- .../emoji-after-inline/input.yaml | 0 .../emoji-after-inline/output.yaml | 0 .../emoji-end-of-inline/index.js | 8 +- .../emoji-end-of-inline/input.yaml | 0 .../emoji-end-of-inline/output.yaml | 0 .../emoji-inside-inline/index.js | 8 +- .../emoji-inside-inline/input.yaml | 0 .../emoji-inside-inline/output.yaml | 0 .../end-of-word/index.js | 8 +- .../end-of-word/input.yaml | 0 .../end-of-word/output.yaml | 0 .../middle-of-word/index.js | 8 +- .../middle-of-word/input.yaml | 0 .../middle-of-word/output.yaml | 0 .../emoji-before-inline}/index.js | 4 +- .../emoji-before-inline/input.yaml | 0 .../emoji-before-inline/output.yaml | 0 .../emoji-inside-inline/index.js | 4 +- .../emoji-inside-inline/input.yaml | 0 .../emoji-inside-inline/output.yaml | 0 .../emoji-start-of-inline}/index.js | 4 +- .../emoji-start-of-inline/input.yaml | 0 .../emoji-start-of-inline/output.yaml | 0 .../middle-of-word/index.js | 4 +- .../middle-of-word/input.yaml | 0 .../middle-of-word/output.yaml | 0 .../start-of-word}/index.js | 4 +- .../start-of-word/input.yaml | 0 .../start-of-word/output.yaml | 0 .../before-inline-sibling-into/index.js | 4 +- .../before-inline-sibling-into/input.yaml | 0 .../before-inline-sibling-into/output.yaml | 0 .../before-inline-sibling/index.js | 4 +- .../before-inline-sibling/input.yaml | 0 .../before-inline-sibling/output.yaml | 0 .../end-of-document/index.js | 8 +- .../end-of-document/input.yaml | 0 .../end-of-document/output.yaml | 0 .../first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../inside-inline-sibling/index.js | 4 +- .../inside-inline-sibling/input.yaml | 0 .../inside-inline-sibling/output.yaml | 0 .../join-blocks-with-inline-void/index.js | 17 + .../join-blocks-with-inline-void/input.yaml | 0 .../join-blocks-with-inline-void/output.yaml | 0 .../join-blocks-with-inlines/index.js | 17 + .../join-blocks-with-inlines/input.yaml | 0 .../join-blocks-with-inlines/output.yaml | 0 .../join-blocks/index.js | 17 + .../join-blocks/input.yaml | 0 .../join-blocks/output.yaml | 0 .../join-nested-blocks/index.js | 17 + .../join-nested-blocks/input.yaml | 0 .../join-nested-blocks/output.yaml | 0 .../last-character/index.js | 17 + .../last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../multiple-characters/index.js | 4 +- .../multiple-characters/input.yaml | 0 .../multiple-characters/output.yaml | 0 .../emoji-after-inline/index.js | 8 +- .../emoji-after-inline/input.yaml | 0 .../emoji-after-inline/output.yaml | 0 .../emoji-inside-inline/index.js | 8 +- .../emoji-inside-inline/input.yaml | 0 .../emoji-inside-inline/output.yaml | 0 .../end-of-word/index.js | 8 +- .../end-of-word/input.yaml | 0 .../end-of-word/output.yaml | 0 .../middle-of-word/index.js | 8 +- .../middle-of-word/input.yaml | 0 .../middle-of-word/output.yaml | 0 .../emoji-after-inline/index.js | 4 +- .../emoji-after-inline/input.yaml | 0 .../emoji-after-inline/output.yaml | 0 .../emoji-inside-inline/index.js | 4 +- .../emoji-inside-inline/input.yaml | 0 .../emoji-inside-inline/output.yaml | 0 .../middle-of-word/index.js | 4 +- .../middle-of-word/input.yaml | 0 .../middle-of-word/output.yaml | 0 .../start-of-word/index.js | 4 +- .../start-of-word/input.yaml | 0 .../start-of-word/output.yaml | 0 .../insert-block-at-range/block-end/index.js | 8 +- .../block-end/input.yaml | 0 .../block-end/output.yaml | 0 .../block-middle/index.js | 4 +- .../block-middle/input.yaml | 0 .../block-middle/output.yaml | 0 .../block-start/index.js | 4 +- .../block-start/input.yaml | 0 .../block-start/output.yaml | 0 .../insert-block-at-range/is-empty/index.js | 4 +- .../insert-block-at-range/is-empty/input.yaml | 0 .../is-empty/output.yaml | 0 .../is-void-focus-end/index.js | 4 +- .../is-void-focus-end/input.yaml | 0 .../is-void-focus-end/output.yaml | 0 .../is-void-focus-start/index.js | 4 +- .../is-void-focus-start/input.yaml | 0 .../is-void-focus-start/output.yaml | 0 .../insert-block-at-range/with-block/index.js | 4 +- .../with-block/input.yaml | 0 .../with-block/output.yaml | 0 .../with-object/index.js | 4 +- .../with-object/input.yaml | 0 .../with-object/output.yaml | 0 .../end-block/fragment.yaml | 0 .../end-block/index.js | 8 +- .../end-block/input.yaml | 0 .../end-block/output.yaml | 0 .../end-inline/fragment.yaml | 0 .../end-inline/index.js | 8 +- .../end-inline/input.yaml | 0 .../end-inline/output.yaml | 0 .../fragment.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../fragment-multiple-blocks/fragment.yaml | 0 .../fragment-multiple-blocks}/index.js | 4 +- .../fragment-multiple-blocks/input.yaml | 0 .../fragment-multiple-blocks/output.yaml | 0 .../fragment-nested-blocks/fragment.yaml | 0 .../fragment-nested-blocks}/index.js | 4 +- .../fragment-nested-blocks/input.yaml | 0 .../fragment-nested-blocks/output.yaml | 0 .../middle-block/fragment.yaml | 0 .../middle-block}/index.js | 4 +- .../middle-block/input.yaml | 0 .../middle-block/output.yaml | 0 .../fragment.yaml | 0 .../middle-inline-fragment-inline/index.js | 4 +- .../middle-inline-fragment-inline/input.yaml | 0 .../middle-inline-fragment-inline/output.yaml | 0 .../middle-inline/fragment.yaml | 0 .../middle-inline/index.js | 4 +- .../middle-inline/input.yaml | 0 .../middle-inline/output.yaml | 0 .../start-block-multiple-blocks/fragment.yaml | 0 .../start-block-multiple-blocks/index.js | 4 +- .../start-block-multiple-blocks/input.yaml | 0 .../start-block-multiple-blocks/output.yaml | 0 .../start-block/fragment.yaml | 0 .../start-block/index.js | 4 +- .../start-block/input.yaml | 0 .../start-block/output.yaml | 0 .../start-inline/fragment.yaml | 0 .../start-inline}/index.js | 4 +- .../start-inline/input.yaml | 0 .../start-inline/output.yaml | 0 .../start-second-block/fragment.yaml | 0 .../start-second-block}/index.js | 4 +- .../start-second-block/input.yaml | 0 .../start-second-block/output.yaml | 0 .../with-delete-across-blocks/fragment.yaml | 0 .../with-delete-across-blocks/index.js | 4 +- .../with-delete-across-blocks/input.yaml | 0 .../with-delete-across-blocks/output.yaml | 0 .../insert-inline-at-range/block-end/index.js | 8 +- .../block-end/input.yaml | 0 .../block-end/output.yaml | 0 .../block-middle/index.js | 4 +- .../block-middle/input.yaml | 0 .../block-middle/output.yaml | 0 .../block-start}/index.js | 4 +- .../block-start/input.yaml | 0 .../block-start/output.yaml | 0 .../inside-inline/index.js | 4 +- .../inside-inline/input.yaml | 0 .../inside-inline/output.yaml | 0 .../insert-inline-at-range/is-empty}/index.js | 4 +- .../is-empty/input.yaml | 0 .../is-empty/output.yaml | 0 .../insert-inline-at-range/is-void}/index.js | 4 +- .../insert-inline-at-range/is-void/input.yaml | 0 .../is-void/output.yaml | 0 .../with-inline/index.js | 4 +- .../with-inline/input.yaml | 0 .../with-inline/output.yaml | 0 .../insert-text-at-range/after-mark/index.js | 4 +- .../after-mark/input.yaml | 0 .../after-mark/output.yaml | 0 .../insert-text-at-range/before-mark/index.js | 4 +- .../before-mark/input.yaml | 0 .../before-mark/output.yaml | 0 .../insert-text-at-range/during-mark/index.js | 4 +- .../during-mark/input.yaml | 0 .../during-mark/output.yaml | 0 .../first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../insert-text-at-range/first-space/index.js | 4 +- .../first-space/input.yaml | 0 .../first-space/output.yaml | 0 .../insert-text-at-range/first-words/index.js | 4 +- .../first-words/input.yaml | 0 .../first-words/output.yaml | 0 .../insert-text-at-range/inside-void/index.js | 4 +- .../inside-void/input.yaml | 0 .../inside-void/output.yaml | 0 .../last-character/index.js | 17 + .../last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../insert-text-at-range/last-space/index.js | 8 +- .../last-space/input.yaml | 0 .../last-space/output.yaml | 0 .../insert-text-at-range/last-words/index.js | 8 +- .../last-words/input.yaml | 0 .../last-words/output.yaml | 0 .../middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../middle-space/index.js | 4 +- .../middle-space/input.yaml | 0 .../middle-space/output.yaml | 0 .../middle-words/index.js | 4 +- .../middle-words/input.yaml | 0 .../middle-words/output.yaml | 0 .../insert-text-at-range/with-marks/index.js | 8 +- .../with-marks/input.yaml | 0 .../with-marks/output.yaml | 0 .../across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../existing-marks/index.js | 4 +- .../existing-marks/input.yaml | 0 .../existing-marks/output.yaml | 0 .../first-character/index.js | 4 +- .../first-character/input.yaml | 0 .../first-character/output.yaml | 0 .../last-character/index.js | 8 +- .../last-character/input.yaml | 0 .../last-character/output.yaml | 0 .../middle-character/index.js | 4 +- .../middle-character/input.yaml | 0 .../middle-character/output.yaml | 0 .../remove-mark-at-range/whole-word/index.js | 6 +- .../whole-word/input.yaml | 0 .../whole-word/output.yaml | 0 .../with-mark-object/index.js | 4 +- .../with-mark-object/input.yaml | 0 .../with-mark-object/output.yaml | 0 .../with-plain-object/index.js | 4 +- .../with-plain-object/input.yaml | 0 .../with-plain-object/output.yaml | 0 .../set-block-at-range/across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../set-block-at-range/data-only/index.js | 4 +- .../set-block-at-range/data-only/input.yaml | 0 .../set-block-at-range/data-only/output.yaml | 0 .../set-block-at-range/nested-block/index.js | 4 +- .../nested-block/input.yaml | 0 .../nested-block/output.yaml | 0 .../single-block-string-shorthand/index.js | 4 +- .../single-block-string-shorthand/input.yaml | 0 .../single-block-string-shorthand/output.yaml | 0 .../set-block-at-range/single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../with-data-object/index.js | 4 +- .../with-data-object/input.yaml | 0 .../with-data-object/output.yaml | 0 .../set-block-at-range/with-data/index.js | 4 +- .../set-block-at-range/with-data/input.yaml | 0 .../set-block-at-range/with-data/output.yaml | 0 .../set-block-at-range/with-is-void/index.js | 4 +- .../with-is-void/input.yaml | 0 .../with-is-void/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../set-inline-at-range/data-only/index.js | 4 +- .../set-inline-at-range/data-only/input.yaml | 0 .../set-inline-at-range/data-only/output.yaml | 0 .../nested-inline/index.js | 4 +- .../nested-inline/input.yaml | 0 .../nested-inline/output.yaml | 0 .../single-inline-string-shorthand/index.js | 4 +- .../single-inline-string-shorthand/input.yaml | 0 .../output.yaml | 0 .../single-inline/index.js | 4 +- .../single-inline/input.yaml | 0 .../single-inline/output.yaml | 0 .../with-data-object/index.js | 4 +- .../with-data-object/input.yaml | 0 .../with-data-object/output.yaml | 0 .../set-inline-at-range/with-data/index.js | 4 +- .../set-inline-at-range/with-data/input.yaml | 0 .../set-inline-at-range/with-data/output.yaml | 0 .../set-inline-at-range/with-is-void/index.js | 4 +- .../with-is-void/input.yaml | 0 .../with-is-void/output.yaml | 0 .../after-inline-void/index.js | 4 +- .../after-inline-void/input.yaml | 0 .../after-inline-void/output.yaml | 0 .../split-block-at-range/block-end/index.js | 8 +- .../split-block-at-range/block-end/input.yaml | 0 .../block-end/output.yaml | 0 .../block-middle/index.js | 4 +- .../block-middle/input.yaml | 0 .../block-middle/output.yaml | 0 .../split-block-at-range/block-start/index.js | 4 +- .../block-start/input.yaml | 0 .../block-start/output.yaml | 0 .../split-block-at-range/depth/index.js | 4 +- .../split-block-at-range/depth/input.yaml | 0 .../split-block-at-range/depth/output.yaml | 0 .../index.js | 4 +- .../input.yaml | 0 .../output.yaml | 0 .../with-delete-across-blocks/index.js | 4 +- .../with-delete-across-blocks/input.yaml | 0 .../with-delete-across-blocks/output.yaml | 0 .../split-block-at-range/with-delete/index.js | 4 +- .../with-delete/input.yaml | 0 .../with-delete/output.yaml | 0 .../split-block-at-range/with-inline/index.js | 4 +- .../with-inline/input.yaml | 0 .../with-inline/output.yaml | 0 .../split-inline-at-range/block-end/index.js | 8 +- .../block-end/input.yaml | 0 .../block-end/output.yaml | 0 .../block-middle/index.js | 4 +- .../block-middle/input.yaml | 0 .../block-middle/output.yaml | 0 .../block-start/index.js | 4 +- .../block-start/input.yaml | 0 .../block-start/output.yaml | 0 .../split-inline-at-range/depth/index.js | 4 +- .../split-inline-at-range/depth/input.yaml | 0 .../split-inline-at-range/depth/output.yaml | 0 .../with-delete/index.js | 4 +- .../with-delete/input.yaml | 0 .../with-delete/output.yaml | 0 .../split-inline-at-range/with-marks/index.js | 4 +- .../with-marks/input.yaml | 0 .../with-marks/output.yaml | 0 .../add-across-blocks}/index.js | 4 +- .../add-across-blocks/input.yaml | 0 .../add-across-blocks/output.yaml | 0 .../add-across-inlines}/index.js | 4 +- .../add-across-inlines/input.yaml | 0 .../add-across-inlines/output.yaml | 0 .../add-existing-marks}/index.js | 4 +- .../add-existing-marks/input.yaml | 0 .../add-existing-marks/output.yaml | 0 .../add-first-character/index.js | 4 +- .../add-first-character/input.yaml | 0 .../add-first-character/output.yaml | 0 .../add-last-character/index.js | 8 +- .../add-last-character/input.yaml | 0 .../add-last-character/output.yaml | 0 .../add-middle-character/index.js | 4 +- .../add-middle-character/input.yaml | 0 .../add-middle-character/output.yaml | 0 .../add-whole-word/index.js | 6 +- .../add-whole-word/input.yaml | 0 .../add-whole-word/output.yaml | 0 .../add-with-mark-object/index.js | 4 +- .../add-with-mark-object/input.yaml | 0 .../add-with-mark-object/output.yaml | 0 .../add-with-plain-object}/index.js | 4 +- .../add-with-plain-object/input.yaml | 0 .../add-with-plain-object/output.yaml | 0 .../remove-across-blocks}/index.js | 4 +- .../remove-across-blocks/input.yaml | 0 .../remove-across-blocks/output.yaml | 0 .../remove-across-inlines}/index.js | 4 +- .../remove-across-inlines/input.yaml | 0 .../remove-across-inlines/output.yaml | 0 .../remove-existing-marks}/index.js | 4 +- .../remove-existing-marks/input.yaml | 0 .../remove-existing-marks/output.yaml | 0 .../remove-first-character/index.js | 4 +- .../remove-first-character/input.yaml | 0 .../remove-first-character/output.yaml | 0 .../remove-last-character/index.js | 17 + .../remove-last-character/input.yaml | 0 .../remove-last-character/output.yaml | 0 .../remove-middle-character/index.js | 4 +- .../remove-middle-character/input.yaml | 0 .../remove-middle-character/output.yaml | 0 .../remove-whole-word/index.js | 17 + .../remove-whole-word/input.yaml | 0 .../remove-whole-word/output.yaml | 0 .../remove-with-mark-object/index.js | 4 +- .../remove-with-mark-object/input.yaml | 0 .../remove-with-mark-object/output.yaml | 0 .../remove-with-plain-object}/index.js | 4 +- .../remove-with-plain-object/input.yaml | 0 .../remove-with-plain-object/output.yaml | 0 .../across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../ending-child-blocks/index.js | 4 +- .../ending-child-blocks/input.yaml | 0 .../ending-child-blocks/output.yaml | 0 .../middle-child-blocks/index.js | 4 +- .../middle-child-blocks/input.yaml | 0 .../middle-child-blocks/output.yaml | 0 .../nested-block/index.js | 4 +- .../nested-block/input.yaml | 0 .../nested-block/output.yaml | 0 .../single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../starting-child-blocks/index.js | 4 +- .../starting-child-blocks/input.yaml | 0 .../starting-child-blocks/output.yaml | 0 .../with-object/index.js | 4 +- .../with-object/input.yaml | 0 .../with-object/output.yaml | 0 .../across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../nested-block/index.js | 4 +- .../nested-block/input.yaml | 0 .../nested-block/output.yaml | 0 .../single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../with-object/index.js | 4 +- .../with-object/input.yaml | 0 .../with-object/output.yaml | 0 .../with-text-between/index.js | 4 +- .../with-text-between/input.yaml | 0 .../with-text-between/output.yaml | 0 .../across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../double-nested-block/index.js | 4 +- .../double-nested-block/input.yaml | 0 .../double-nested-block/output.yaml | 0 .../wrap-block-at-range/nested-block/index.js | 4 +- .../nested-block/input.yaml | 0 .../nested-block/output.yaml | 0 .../wrap-block-at-range/single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../wrap-block-at-range/with-object/index.js | 4 +- .../with-object/input.yaml | 0 .../with-object/output.yaml | 0 .../across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../nested-block/index.js | 4 +- .../nested-block/input.yaml | 0 .../nested-block/output.yaml | 0 .../single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../wrap-inline-at-range/with-object/index.js | 4 +- .../with-object/input.yaml | 0 .../with-object/output.yaml | 0 .../wrap-inline-void/index.js | 4 +- .../wrap-inline-void/input.yaml | 0 .../wrap-inline-void/output.yaml | 0 .../wrap-text-at-range/across-blocks/index.js | 4 +- .../across-blocks/input.yaml | 0 .../across-blocks/output.yaml | 0 .../across-inlines/index.js | 4 +- .../across-inlines/input.yaml | 0 .../across-inlines/output.yaml | 0 .../backwards-selection/index.js | 4 +- .../backwards-selection/input.yaml | 0 .../backwards-selection/output.yaml | 0 .../wrap-text-at-range/empty-block/index.js | 4 +- .../wrap-text-at-range/empty-block/input.yaml | 0 .../empty-block/output.yaml | 0 .../wrap-text-at-range/end-of-block/index.js | 4 +- .../end-of-block/input.yaml | 0 .../end-of-block/output.yaml | 0 .../middle-of-block/index.js | 4 +- .../middle-of-block/input.yaml | 0 .../middle-of-block/output.yaml | 0 .../start-of-block/index.js | 4 +- .../start-of-block/input.yaml | 0 .../start-of-block/output.yaml | 0 .../wrap-text-at-range/whole-block/index.js | 4 +- .../wrap-text-at-range/whole-block/input.yaml | 0 .../whole-block/output.yaml | 0 .../without-suffix/index.js | 4 +- .../without-suffix/input.yaml | 0 .../without-suffix/output.yaml | 0 .../end-of-target/fragment.yaml | 0 .../end-of-target/index.js | 4 +- .../end-of-target/input.yaml | 0 .../end-of-target/output.yaml | 0 .../middle-of-target/fragment.yaml | 0 .../middle-of-target/index.js | 4 +- .../middle-of-target/input.yaml | 0 .../middle-of-target/output.yaml | 0 .../start-of-target/fragment.yaml | 0 .../start-of-target/index.js | 4 +- .../start-of-target/input.yaml | 0 .../start-of-target/output.yaml | 0 .../by-key/insert-node-by-key/block/index.js | 6 +- .../insert-node-by-key/block/input.yaml | 0 .../insert-node-by-key/block/output.yaml | 0 .../insert-node-by-key/duplicate/index.js | 4 +- .../insert-node-by-key/duplicate/input.yaml | 0 .../insert-node-by-key/duplicate/output.yaml | 0 .../by-key/insert-node-by-key/inline/index.js | 4 +- .../insert-node-by-key/inline/input.yaml | 0 .../insert-node-by-key/inline/output.yaml | 0 .../insert-text-by-key/end-text/index.js | 4 +- .../insert-text-by-key/end-text/input.yaml | 0 .../insert-text-by-key/end-text/output.yaml | 0 .../middle-text-with-marks/index.js | 4 +- .../middle-text-with-marks/input.yaml | 0 .../middle-text-with-marks/output.yaml | 0 .../insert-text-by-key/middle-text/index.js | 4 +- .../insert-text-by-key/middle-text/input.yaml | 0 .../middle-text/output.yaml | 0 .../selection-after/index.js | 4 +- .../selection-after/input.yaml | 0 .../selection-after/output.yaml | 0 .../selection-before/index.js | 4 +- .../selection-before/input.yaml | 0 .../selection-before/output.yaml | 0 .../insert-text-by-key/selection-end/index.js | 4 +- .../selection-end/input.yaml | 0 .../selection-end/output.yaml | 0 .../selection-start/index.js | 4 +- .../selection-start/input.yaml | 0 .../selection-start/output.yaml | 0 .../selection-wrap/index.js | 4 +- .../selection-wrap/input.yaml | 0 .../selection-wrap/output.yaml | 0 .../insert-text-by-key/start-text/index.js | 4 +- .../insert-text-by-key/start-text/input.yaml | 0 .../insert-text-by-key/start-text/output.yaml | 0 .../by-key/join-node-by-key/block/index.js | 12 +- .../by-key/join-node-by-key/block}/input.yaml | 6 +- .../by-key/join-node-by-key/block/output.yaml | 3 +- .../by-key/move-node-by-key/block/index.js | 4 +- .../by-key/move-node-by-key/block/input.yaml | 0 .../by-key/move-node-by-key/block/output.yaml | 0 .../by-key/move-node-by-key/inline/index.js | 4 +- .../by-key/move-node-by-key/inline/input.yaml | 0 .../move-node-by-key/inline/output.yaml | 0 .../by-key/move-node-by-key/text/index.js | 4 +- .../by-key/move-node-by-key/text/input.yaml | 0 .../by-key/move-node-by-key/text/output.yaml | 0 .../move-node-by-key/to-sibling/index.js | 6 +- .../move-node-by-key/to-sibling/input.yaml | 0 .../move-node-by-key/to-sibling/output.yaml | 0 .../by-key/remove-node-by-key/block}/index.js | 4 +- .../remove-node-by-key/block/input.yaml | 0 .../remove-node-by-key/block/output.yaml | 0 .../by-key/remove-node-by-key/inline/index.js | 4 +- .../remove-node-by-key/inline/input.yaml | 0 .../remove-node-by-key/inline/output.yaml | 0 .../selection-inside/index.js | 4 +- .../selection-inside/input.yaml | 0 .../selection-inside/output.yaml | 0 .../by-key/remove-node-by-key/text}/index.js | 4 +- .../by-key/remove-node-by-key/text/input.yaml | 0 .../remove-node-by-key/text/output.yaml | 0 .../adjacent-non-void-inlines/index.js | 4 +- .../adjacent-non-void-inlines/input.yaml | 0 .../adjacent-non-void-inlines/output.yaml | 0 .../inline-last-character-deep/index.js | 4 +- .../inline-last-character-deep/input.yaml | 0 .../inline-last-character-deep/output.yaml | 0 .../inline-last-character/index.js | 4 +- .../inline-last-character/input.yaml | 0 .../inline-last-character/output.yaml | 0 .../remove-text-by-key/inline-void/index.js | 4 +- .../remove-text-by-key/inline-void/input.yaml | 0 .../inline-void/output.yaml | 0 .../by-key/remove-text-by-key/inline/index.js | 4 +- .../remove-text-by-key/inline/input.yaml | 0 .../remove-text-by-key/inline/output.yaml | 0 .../next-void-inline/index.js | 4 +- .../next-void-inline/input.yaml | 0 .../next-void-inline/output.yaml | 0 .../previous-void-inline/index.js | 4 +- .../previous-void-inline/input.yaml | 0 .../previous-void-inline/output.yaml | 0 .../selection-after/index.js | 4 +- .../selection-after/input.yaml | 0 .../selection-after/output.yaml | 0 .../selection-before/index.js | 4 +- .../selection-before/input.yaml | 0 .../selection-before/output.yaml | 0 .../selection-start/index.js | 4 +- .../selection-start/input.yaml | 0 .../selection-start/output.yaml | 0 .../selection-wrap/index.js | 4 +- .../selection-wrap/input.yaml | 0 .../selection-wrap/output.yaml | 0 .../by-key/remove-text-by-key/text/index.js | 4 +- .../by-key/remove-text-by-key/text/input.yaml | 0 .../remove-text-by-key/text/output.yaml | 0 .../by-key/set-mark-by-key/set-data/index.js | 6 +- .../set-mark-by-key/set-data/input.yaml | 0 .../set-mark-by-key/set-data/output.yaml | 0 .../set-node-by-key/inline-void/index.js | 4 +- .../set-node-by-key/inline-void/input.yaml | 0 .../set-node-by-key/inline-void/output.yaml | 0 .../single-block-string-shorthand/index.js | 4 +- .../single-block-string-shorthand/input.yaml | 0 .../single-block-string-shorthand/output.yaml | 0 .../set-node-by-key/single-block/index.js | 4 +- .../set-node-by-key/single-block/input.yaml | 0 .../set-node-by-key/single-block/output.yaml | 0 .../block-with-selection}/index.js | 16 +- .../block-with-selection}/input.yaml | 6 +- .../block-with-selection}/output.yaml | 10 +- .../split-descendants-by-key/block/index.js | 9 + .../split-descendants-by-key/block/input.yaml | 9 + .../block}/output.yaml | 10 +- .../block-with-selection/index.js | 31 + .../block-with-selection/input.yaml | 9 + .../block-with-selection/output.yaml | 16 + .../by-key/split-node-by-key/block/index.js | 9 + .../by-key/split-node-by-key/block/input.yaml | 9 + .../split-node-by-key/block/output.yaml | 16 + .../by-key/split-node-by-key/text/index.js | 10 +- .../by-key/split-node-by-key/text/input.yaml | 5 +- .../by-key/split-node-by-key/text/output.yaml | 3 +- .../unwrap-block-by-key/single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../single-block/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../first-sibling}/index.js | 4 +- .../first-sibling/input.yaml | 0 .../first-sibling/output.yaml | 0 .../unwrap-node-by-key/last-sibling}/index.js | 4 +- .../last-sibling/input.yaml | 0 .../last-sibling/output.yaml | 0 .../unwrap-node-by-key/single-block}/index.js | 4 +- .../single-block/input.yaml | 0 .../single-block/output.yaml | 0 .../with-siblings}/index.js | 4 +- .../with-siblings/input.yaml | 0 .../with-siblings/output.yaml | 0 .../wrap-block-by-key/block-node/index.js | 4 +- .../wrap-block-by-key/block-node/input.yaml | 0 .../wrap-block-by-key/block-node/output.yaml | 0 .../wrap-block-by-key/text-node/index.js | 4 +- .../wrap-block-by-key/text-node/input.yaml | 0 .../wrap-block-by-key/text-node/output.yaml | 0 .../fixtures/call/call-no-arguments/index.js | 8 +- .../call/call-no-arguments/input.yaml | 0 .../call/call-no-arguments/output.yaml | 0 .../call/call-with-arguments/index.js | 8 +- .../call/call-with-arguments/input.yaml | 0 .../call/call-with-arguments/output.yaml | 0 .../fixtures/general/set-data/index.js | 7 + .../fixtures/general}/set-data/input.yaml | 0 .../fixtures/general}/set-data/output.yaml | 3 +- .../on-history/undo/add-mark/index.js | 8 +- .../on-history/undo/add-mark/input.yaml | 0 .../on-history/undo/add-mark/output.yaml | 0 .../undo/delete-text-across-block/index.js | 16 +- .../undo/delete-text-across-block}/input.yaml | 4 +- .../delete-text-across-block}/output.yaml | 0 .../undo/delete-text-with-marks/index.js | 27 + .../undo/delete-text-with-marks/input.yaml | 0 .../undo/delete-text-with-marks/output.yaml | 0 .../on-history/undo/delete-text/index.js | 31 + .../on-history/undo/delete-text/input.yaml | 0 .../on-history/undo/delete-text/output.yaml | 0 .../on-history/undo/insert-node/index.js | 8 +- .../on-history/undo/insert-node/input.yaml | 0 .../on-history/undo/insert-node}/output.yaml | 0 .../undo/insert-text-many-contiguous/index.js | 12 +- .../insert-text-many-contiguous/input.yaml | 0 .../insert-text-many-contiguous/output.yaml | 0 .../index.js | 12 +- .../input.yaml | 0 .../output.yaml | 0 .../index.js | 24 +- .../input.yaml | 0 .../output.yaml | 0 .../insert-text-many-non-contiguous/index.js | 16 +- .../input.yaml | 0 .../output.yaml | 0 .../on-history/undo/insert-text/index.js | 8 +- .../on-history/undo/insert-text/input.yaml | 0 .../on-history/undo/insert-text/output.yaml | 0 .../on-history/undo/join-node-block/index.js | 10 +- .../undo/join-node-block/input.yaml | 0 .../undo/join-node-block}/output.yaml | 0 .../on-history/undo/move-node/index.js | 17 +- .../on-history/undo/move-node/input.yaml | 20 + .../on-history/undo/move-node/output.yaml | 20 + .../on-history/undo/remove-mark/index.js | 8 +- .../on-history/undo/remove-mark/input.yaml | 0 .../on-history/undo/remove-mark/output.yaml | 0 .../undo/remove-middle-void/index.js | 8 +- .../undo/remove-middle-void/input.yaml | 0 .../undo/remove-middle-void/output.yaml | 0 .../undo/remove-nested-middle-void/index.js | 8 +- .../undo/remove-nested-middle-void/input.yaml | 0 .../remove-nested-middle-void/output.yaml | 0 .../on-history/undo/remove-node/index.js | 8 +- .../on-history/undo/remove-node}/input.yaml | 0 .../on-history/undo/remove-node}/output.yaml | 0 .../on-history/undo/set-mark/index.js | 8 +- .../on-history/undo/set-mark/input.yaml | 0 .../on-history/undo/set-mark/output.yaml | 0 .../on-history/undo/set-node-data/index.js | 8 +- .../on-history/undo/set-node-data/input.yaml | 0 .../on-history/undo/set-node-data/output.yaml | 0 .../on-history/undo/set-selection/index.js | 17 +- .../on-history/undo/set-selection}/input.yaml | 0 .../on-history/undo/set-selection/output.yaml | 0 .../on-history/undo/split-node-block/index.js | 8 +- .../undo/split-node-block/input.yaml | 0 .../undo/split-node-block/output.yaml | 0 .../undo/unwrap-node-by-key/index.js | 8 +- .../undo/unwrap-node-by-key/input.yaml | 0 .../undo/unwrap-node-by-key/output.yaml | 0 .../fixtures/on-selection/blur/basic/index.js | 4 +- .../on-selection/blur/basic/input.yaml | 0 .../fixtures/on-selection/blur/marks/index.js | 4 +- .../on-selection/blur/marks/input.yaml | 0 .../already-collapsed/index.js | 4 +- .../already-collapsed/input.yaml | 0 .../collapse-to-anchor/basic/index.js | 6 +- .../collapse-to-anchor/basic/input.yaml | 0 .../already-collapsed/index.js | 4 +- .../already-collapsed/input.yaml | 0 .../collapse-to-end/basic/index.js | 10 +- .../collapse-to-end/basic/input.yaml | 0 .../collapse-to-end/void/index.js | 6 +- .../collapse-to-end/void/input.yaml | 0 .../already-collapsed/index.js | 4 +- .../already-collapsed/input.yaml | 0 .../collapse-to-focus/basic/index.js | 10 +- .../collapse-to-focus/basic/input.yaml | 0 .../already-collapsed/index.js | 4 +- .../already-collapsed/input.yaml | 0 .../collapse-to-start/basic/index.js | 6 +- .../collapse-to-start/basic/input.yaml | 0 .../collapse-to-start/void/index.js | 6 +- .../collapse-to-start/void/input.yaml | 0 .../on-selection/focus/basic/index.js | 4 +- .../on-selection/focus/basic/input.yaml | 0 .../on-selection/focus/marks/index.js | 4 +- .../on-selection/focus/marks/input.yaml | 0 .../on-selection/move-to/with-object/index.js | 6 +- .../move-to/with-object/input.yaml | 0 .../move-to/with-selection/index.js | 6 +- .../move-to/with-selection/input.yaml | 0 .../on-selection/select-all/basic/index.js | 4 +- .../on-selection/select-all/basic/input.yaml | 0 .../fixtures/split-block/with-void/index.js | 4 +- .../fixtures/split-block/with-void/input.yaml | 0 .../split-block/with-void/output.yaml | 0 test/{transforms => changes}/index.js | 76 +-- test/helpers/simulate.js | 17 +- test/index.js | 2 +- test/schema/index.js | 3 +- .../raw/serialize/block-with-data/input.js | 2 +- .../join-nested-blocks/index.js | 27 - .../delete-forward/last-character/index.js | 27 - .../insert-text/last-character/index.js | 27 - .../remove-last-character/index.js | 24 - .../toggle-mark/remove-whole-word/index.js | 24 - .../join-blocks-with-inline-void/index.js | 17 - .../join-blocks-with-inlines/index.js | 17 - .../join-blocks/index.js | 17 - .../join-nested-blocks/index.js | 17 - .../last-character/index.js | 17 - .../last-character/index.js | 17 - .../remove-last-character/index.js | 17 - .../remove-whole-word/index.js | 17 - .../by-key/join-node-by-key/block/input.yaml | 16 - .../by-key/join-node-by-key/text/index.js | 29 - .../by-key/join-node-by-key/text/input.yaml | 16 - .../by-key/join-node-by-key/text/output.yaml | 15 - .../undo/delete-text-with-marks/index.js | 26 - .../on-history/undo/delete-text/index.js | 26 - .../fixtures/state-data/set-data/index.js | 14 - 1635 files changed, 5963 insertions(+), 5968 deletions(-) rename benchmark/fixtures/models/{update-descendant => update-node}/index.js (90%) rename benchmark/fixtures/models/{update-descendant => update-node}/input.yaml (100%) create mode 100644 src/changes/Readme.md create mode 100644 src/changes/at-current-range.js rename src/{transforms => changes}/at-range.js (72%) rename src/{transforms => changes}/by-key.js (51%) rename src/{transforms => changes}/index.js (70%) rename src/{transforms => changes}/normalize.js (63%) create mode 100644 src/changes/on-history.js create mode 100644 src/changes/on-selection.js create mode 100644 src/changes/on-state.js create mode 100644 src/models/change.js create mode 100644 src/models/history.js delete mode 100644 src/models/transform.js create mode 100644 src/operations/Readme.md create mode 100644 src/operations/apply.js create mode 100644 src/operations/index.js create mode 100644 src/operations/invert.js delete mode 100644 src/transforms/Readme.md delete mode 100644 src/transforms/apply-operation.js delete mode 100644 src/transforms/at-current-range.js delete mode 100644 src/transforms/call.js delete mode 100644 src/transforms/on-history.js delete mode 100644 src/transforms/on-selection.js delete mode 100644 src/transforms/operations.js create mode 100644 src/utils/logger.js delete mode 100644 src/utils/warn.js rename test/{transforms => changes}/fixtures/at-current-range/add-mark/across-blocks/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/across-inlines/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/collapsed-selection/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/collapsed-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/collapsed-selection/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/existing-marks/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/last-character/index.js (79%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/whole-word/index.js (87%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/with-mark-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/with-mark-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/with-plain-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/add-mark/with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/before-inline-sibling/index.js (83%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/before-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/before-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/empty-after-void-block/index.js (86%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/empty-after-void-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/empty-after-void-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/inside-inline-sibling/index.js (73%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/inside-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/inside-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-blocks-with-inlines/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-blocks-with-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-blocks-with-inlines/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete-backward/join-nested-blocks => changes/fixtures/at-current-range/delete-backward/join-blocks}/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-blocks/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete-backward/join-blocks => changes/fixtures/at-current-range/delete-backward/join-nested-blocks}/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/join-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/last-character/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/multiple-characters/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/multiple-characters/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/multiple-characters/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete-backward/single-void-block => changes/fixtures/at-current-range/delete-backward/single-non-void-block}/index.js (86%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/single-non-void-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/single-non-void-block/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete-backward/single-non-void-block => changes/fixtures/at-current-range/delete-backward/single-void-block}/index.js (86%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/single-void-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/single-void-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/start-of-document/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/start-of-document/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-backward/start-of-document/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/before-inline-sibling/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/before-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/before-inline-sibling/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete-forward/single-void-block => changes/fixtures/at-current-range/delete-forward/empty-before-void-block}/index.js (86%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/empty-before-void-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/empty-before-void-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/end-of-document/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/end-of-document/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/end-of-document/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/inside-inline-sibling/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/inside-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/inside-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-blocks-with-inlines/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-blocks-with-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-blocks-with-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-blocks/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-blocks/output.yaml (100%) create mode 100644 test/changes/fixtures/at-current-range/delete-forward/join-nested-blocks/index.js rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/join-nested-blocks/output.yaml (100%) create mode 100644 test/changes/fixtures/at-current-range/delete-forward/last-character/index.js rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/multiple-characters/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/multiple-characters/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/multiple-characters/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/single-non-void-block/index.js (86%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/single-non-void-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/single-non-void-block/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete-forward/empty-before-void-block => changes/fixtures/at-current-range/delete-forward/single-void-block}/index.js (86%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/single-void-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/single-void-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/start-text-middle-inline/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/start-text-middle-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete-forward/start-text-middle-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/across-blocks-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/delete/across-blocks-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/across-blocks-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/across-nested-blocks/index.js (88%) rename test/{transforms => changes}/fixtures/at-current-range/delete/across-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/across-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/before-inline-sibling/index.js (74%) rename test/{transforms => changes}/fixtures/at-current-range/delete/before-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/before-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/inside-inline-sibling/index.js (75%) rename test/{transforms => changes}/fixtures/at-current-range/delete/inside-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/inside-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks-and-trim/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks-and-trim/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks-and-trim/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks-with-inlines/index.js (88%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks-with-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks-with-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks/index.js (88%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/join-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/last-character/index.js (80%) rename test/{transforms => changes}/fixtures/at-current-range/delete/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/delete/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/nested-block/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/delete/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/non-void-block-as-first-with-void-siblings-only-non-void/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/non-void-block-as-first-with-void-siblings-only-non-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/non-void-block-as-first-with-void-siblings-only-non-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-all/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-all/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-all/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-backward-selection-all/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-backward-selection-all/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-backward-selection-all/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-first-void => changes/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-only-void}/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-only-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-only-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-select-void-and-next-word/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-select-void-and-next-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-select-void-and-next-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-select-void-end-and-next-word/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-select-void-end-and-next-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-select-void-end-and-next-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-only/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-only/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-block-as-only/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/delete/void-block-as-first-with-non-void-siblings-only-void => changes/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-first-void}/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-first-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-first-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-voids/index.js (91%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-voids/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-blocks-as-first-with-non-void-siblings-only-voids/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-inline-as-first-with-non-void-sibling/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-inline-as-first-with-non-void-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/void-inline-as-first-with-non-void-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/whole-inline/index.js (89%) rename test/{transforms => changes}/fixtures/at-current-range/delete/whole-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/whole-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/whole-word/index.js (88%) rename test/{transforms => changes}/fixtures/at-current-range/delete/whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/delete/whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-end/index.js (83%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-middle/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-middle/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-block/is-empty => changes/fixtures/at-current-range/insert-block/block-start}/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/block-start/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-block/block-start => changes/fixtures/at-current-range/insert-block/is-empty}/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/is-empty/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/is-empty/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/is-void/index.js (90%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/is-void/input.yaml (86%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/is-void/output.yaml (81%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/with-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/with-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/with-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/with-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-block/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block-multiple-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block-multiple-blocks/index.js (82%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block-multiple-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block-multiple-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block/index.js (79%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-inline/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-inline/index.js (82%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/end-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-multiple-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-multiple-blocks/index.js (89%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-multiple-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-multiple-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-nested-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-nested-blocks/index.js (89%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/fragment-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-block/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-block/index.js (85%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline-fragment-inline/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline-fragment-inline/index.js (96%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline-fragment-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline-fragment-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline/index.js (90%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/middle-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block-multiple-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block-multiple-blocks/index.js (85%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block-multiple-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block-multiple-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block/index.js (90%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-inline/fragment.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-fragment/start-second-block => changes/fixtures/at-current-range/insert-fragment/start-inline}/index.js (90%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-second-block/fragment.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-fragment/start-inline => changes/fixtures/at-current-range/insert-fragment/start-second-block}/index.js (90%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-second-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/start-second-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/with-delete-across-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/with-delete-across-blocks/index.js (85%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/with-delete-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-fragment/with-delete-across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-end/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-middle/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-middle/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-inline/is-empty => changes/fixtures/at-current-range/insert-inline/block-start}/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/inline-middle/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/inline-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/inline-middle/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-inline/block-start => changes/fixtures/at-current-range/insert-inline/is-empty}/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/is-empty/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/is-empty/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/is-void/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/is-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-inline/is-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/after-mark/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/after-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/after-mark/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-text/middle-character => changes/fixtures/at-current-range/insert-text/before-mark}/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/before-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/before-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/during-mark/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/during-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/during-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-space/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-space/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-space/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-words/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-words/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/first-words/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/inside-void/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/inside-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/inside-void/output.yaml (100%) create mode 100644 test/changes/fixtures/at-current-range/insert-text/last-character/index.js rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-space/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-space/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-space/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-words/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-words/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/last-words/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/insert-text/before-mark => changes/fixtures/at-current-range/insert-text/middle-character}/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-space/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-space/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-space/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-words/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-words/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/middle-words/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/with-marks/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/with-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/insert-text/with-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/across-inlines/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/collapsed-selection/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/collapsed-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/collapsed-selection/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/existing-marks/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/last-character/index.js (79%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/whole-word/index.js (87%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/with-mark-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/with-mark-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/with-plain-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/remove-mark/with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/across-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/data-only/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/data-only/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/data-only/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/nested-block/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/single-block-string-shorthand/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/single-block-string-shorthand/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/single-block-string-shorthand/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/single-block/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-data-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-data-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-data-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-data/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-data/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-data/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-is-void/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-is-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-block/with-is-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/across-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/data-only/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/data-only/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/data-only/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/nested-inline/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/nested-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/nested-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/single-inline-string-shorthand/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/single-inline-string-shorthand/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/single-inline-string-shorthand/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/single-inline/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/single-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/single-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-data-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-data-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-data-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-data/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-data/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-data/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-is-void/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-is-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/set-inline/with-is-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/after-inline/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/after-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/after-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/before-inline/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/before-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/before-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-end/index.js (83%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-middle/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-middle/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-start/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/depth/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/depth/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/depth/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete-across-blocks-and-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete-across-blocks-and-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete-across-blocks-and-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete-across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete-across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-delete/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-inline/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-block/with-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-end/index.js (83%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-end/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/split-inline/with-marks => changes/fixtures/at-current-range/split-inline/block-middle}/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-middle/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-start/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/depth/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/depth/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/depth/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/with-delete/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/with-delete/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/with-delete/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/split-inline/block-middle => changes/fixtures/at-current-range/split-inline/with-marks}/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/with-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/split-inline/with-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-across-inlines/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-collapsed-selection/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-collapsed-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-collapsed-selection/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/toggle-mark/remove-existing-marks => changes/fixtures/at-current-range/toggle-mark/add-existing-marks}/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-last-character/index.js (79%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-whole-word/index.js (87%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-with-mark-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-with-mark-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-with-plain-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/add-with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-across-inlines/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-collapsed-selection/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-collapsed-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-collapsed-selection/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/toggle-mark/add-existing-marks => changes/fixtures/at-current-range/toggle-mark/remove-existing-marks}/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-first-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-first-character/output.yaml (100%) create mode 100644 test/changes/fixtures/at-current-range/toggle-mark/remove-last-character/index.js rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-middle-character/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-middle-character/output.yaml (100%) create mode 100644 test/changes/fixtures/at-current-range/toggle-mark/remove-whole-word/index.js rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-with-mark-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-with-mark-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-with-plain-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/toggle-mark/remove-with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/across-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/ending-child-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/ending-child-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/ending-child-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/middle-child-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/middle-child-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/middle-child-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/nested-block/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/single-block/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/starting-child-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/starting-child-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/starting-child-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/with-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-block/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/across-blocks/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/across-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/across-inlines/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/unwrap-inline/single-block => changes/fixtures/at-current-range/unwrap-inline/nested-block}/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/only-one/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/only-one/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/only-one/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/unwrap-inline/nested-block => changes/fixtures/at-current-range/unwrap-inline/single-block}/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/with-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/unwrap-inline/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/across-blocks/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/across-inlines/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/nested-block/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/single-block/index.js (93%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/with-object/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-block/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/across-blocks/index.js (81%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/across-inlines/index.js (68%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/inline-void/index.js (94%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/inline-void/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/wrap-inline/single-block => changes/fixtures/at-current-range/wrap-inline/nested-block}/index.js (71%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/nested-block/output.yaml (100%) rename test/{transforms/fixtures/at-current-range/wrap-inline/nested-block => changes/fixtures/at-current-range/wrap-inline/single-block}/index.js (71%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/twice/index.js (84%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/twice/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/twice/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/whole-block/index.js (89%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/whole-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/whole-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/with-object/index.js (73%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-inline/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/across-blocks/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/across-inlines/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/backwards-selection/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/backwards-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/backwards-selection/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/empty-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/empty-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/empty-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/end-of-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/end-of-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/end-of-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/middle-of-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/middle-of-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/middle-of-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/start-of-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/start-of-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/start-of-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/whole-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/whole-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/whole-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/without-suffix/index.js (95%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/without-suffix/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-current-range/wrap-text/without-suffix/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/existing-marks/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/last-character/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/whole-word/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/with-mark-object/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/with-mark-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/with-plain-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/add-mark-at-range/with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-blocks-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-blocks-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-blocks-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-depths/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-depths/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-depths/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-inline-texts/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-inline-texts/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/across-inline-texts/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/before-inline-sibling/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/before-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/before-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/double-nested-block/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/double-nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/double-nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/inside-inline-sibling/index.js (72%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/inside-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/inside-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-across-nested-blocks/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-across-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-across-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks-and-trim/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks-and-trim/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks-and-trim/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks-with-inlines/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks-with-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks-with-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-nested-blocks/index.js (85%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/join-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/last-character/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/nested-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/whole-inline/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/whole-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/whole-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/whole-word/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-at-range/whole-word/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-backward-at-range/after-inline-sibling => changes/fixtures/at-range/delete-backward-at-range/after-inline-sibling-across}/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/after-inline-sibling-across/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/after-inline-sibling-across/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-backward-at-range/after-inline-sibling-across => changes/fixtures/at-range/delete-backward-at-range/after-inline-sibling}/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/after-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/after-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/inside-inline-sibling/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/inside-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/inside-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks-with-inline-void/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks-with-inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks-with-inline-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks-with-inlines/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks-with-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks-with-inlines/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-backward-at-range/join-nested-blocks => changes/fixtures/at-range/delete-backward-at-range/join-blocks}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-blocks/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-backward-at-range/join-blocks => changes/fixtures/at-range/delete-backward-at-range/join-nested-blocks}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/join-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/last-character/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/multiple-characters/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/multiple-characters/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/multiple-characters/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/start-of-document/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/start-of-document/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-backward-at-range/start-of-document/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-after-inline/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-after-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-after-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-end-of-inline/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-end-of-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-end-of-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-inside-inline/index.js (72%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-inside-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/emoji-inside-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/end-of-word/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/end-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/end-of-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/middle-of-word/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/middle-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-backward-at-range/middle-of-word/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-char-forward-at-range/start-of-word => changes/fixtures/at-range/delete-char-forward-at-range/emoji-before-inline}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-before-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-before-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-inside-inline/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-inside-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-inside-inline/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-char-forward-at-range/emoji-before-inline => changes/fixtures/at-range/delete-char-forward-at-range/emoji-start-of-inline}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-start-of-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/emoji-start-of-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/middle-of-word/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/middle-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/middle-of-word/output.yaml (100%) rename test/{transforms/fixtures/at-range/delete-char-forward-at-range/emoji-start-of-inline => changes/fixtures/at-range/delete-char-forward-at-range/start-of-word}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/start-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-char-forward-at-range/start-of-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/before-inline-sibling-into/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/before-inline-sibling-into/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/before-inline-sibling-into/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/before-inline-sibling/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/before-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/before-inline-sibling/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/end-of-document/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/end-of-document/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/end-of-document/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/inside-inline-sibling/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/inside-inline-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/inside-inline-sibling/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/delete-forward-at-range/join-blocks-with-inline-void/index.js rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-blocks-with-inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-blocks-with-inline-void/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/delete-forward-at-range/join-blocks-with-inlines/index.js rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-blocks-with-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-blocks-with-inlines/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/delete-forward-at-range/join-blocks/index.js rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-blocks/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/delete-forward-at-range/join-nested-blocks/index.js rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/join-nested-blocks/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/delete-forward-at-range/last-character/index.js rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/multiple-characters/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/multiple-characters/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-forward-at-range/multiple-characters/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/emoji-after-inline/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/emoji-after-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/emoji-after-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/emoji-inside-inline/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/emoji-inside-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/emoji-inside-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/end-of-word/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/end-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/end-of-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/middle-of-word/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/middle-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-backward-at-range/middle-of-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/emoji-after-inline/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/emoji-after-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/emoji-after-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/emoji-inside-inline/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/emoji-inside-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/emoji-inside-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/middle-of-word/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/middle-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/middle-of-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/start-of-word/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/start-of-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/delete-word-forward-at-range/start-of-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-end/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-middle/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-middle/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-start/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-empty/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-empty/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-empty/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-void-focus-end/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-void-focus-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-void-focus-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-void-focus-start/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-void-focus-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/is-void-focus-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/with-block/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/with-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/with-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/with-object/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-block-at-range/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-block/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-block/index.js (85%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-inline/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-inline/index.js (85%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/end-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks-in-nested-block/fragment.yaml (100%) rename test/{transforms/fixtures/at-range/insert-fragment-at-range/fragment-nested-blocks => changes/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks-in-nested-block}/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks-in-nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks-in-nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks/fragment.yaml (100%) rename test/{transforms/fixtures/at-range/insert-fragment-at-range/middle-block => changes/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks}/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-nested-blocks/fragment.yaml (100%) rename test/{transforms/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks => changes/fixtures/at-range/insert-fragment-at-range/fragment-nested-blocks}/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-nested-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/fragment-nested-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-block/fragment.yaml (100%) rename test/{transforms/fixtures/at-range/insert-fragment-at-range/fragment-multiple-blocks-in-nested-block => changes/fixtures/at-range/insert-fragment-at-range/middle-block}/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline-fragment-inline/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline-fragment-inline/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline-fragment-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline-fragment-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/middle-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block-multiple-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block-multiple-blocks/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block-multiple-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block-multiple-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-inline/fragment.yaml (100%) rename test/{transforms/fixtures/at-range/insert-fragment-at-range/start-second-block => changes/fixtures/at-range/insert-fragment-at-range/start-inline}/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-second-block/fragment.yaml (100%) rename test/{transforms/fixtures/at-range/insert-fragment-at-range/start-inline => changes/fixtures/at-range/insert-fragment-at-range/start-second-block}/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-second-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/start-second-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/with-delete-across-blocks/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/with-delete-across-blocks/index.js (95%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/with-delete-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-fragment-at-range/with-delete-across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-end/index.js (77%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-middle/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-middle/output.yaml (100%) rename test/{transforms/fixtures/at-range/insert-inline-at-range/is-void => changes/fixtures/at-range/insert-inline-at-range/block-start}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/inside-inline/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/inside-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/inside-inline/output.yaml (100%) rename test/{transforms/fixtures/at-range/insert-inline-at-range/block-start => changes/fixtures/at-range/insert-inline-at-range/is-empty}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/is-empty/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/is-empty/output.yaml (100%) rename test/{transforms/fixtures/at-range/insert-inline-at-range/is-empty => changes/fixtures/at-range/insert-inline-at-range/is-void}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/is-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/is-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/with-inline/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/with-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-inline-at-range/with-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/after-mark/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/after-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/after-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/before-mark/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/before-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/before-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/during-mark/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/during-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/during-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-space/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-space/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-space/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-words/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-words/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/first-words/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/inside-void/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/inside-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/inside-void/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/insert-text-at-range/last-character/index.js rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-space/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-space/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-space/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-words/index.js (75%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-words/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/last-words/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-space/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-space/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-space/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-words/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-words/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/middle-words/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/with-marks/index.js (81%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/with-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/insert-text-at-range/with-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/existing-marks/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/last-character/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/whole-word/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/with-mark-object/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/with-mark-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/with-plain-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/remove-mark-at-range/with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/data-only/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/data-only/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/data-only/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/nested-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/single-block-string-shorthand/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/single-block-string-shorthand/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/single-block-string-shorthand/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/single-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-data-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-data-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-data-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-data/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-data/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-data/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-is-void/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-is-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-block-at-range/with-is-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/data-only/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/data-only/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/data-only/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/nested-inline/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/nested-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/nested-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/single-inline-string-shorthand/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/single-inline-string-shorthand/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/single-inline-string-shorthand/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/single-inline/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/single-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/single-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-data-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-data-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-data-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-data/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-data/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-data/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-is-void/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-is-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/set-inline-at-range/with-is-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/after-inline-void/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/after-inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/after-inline-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-end/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-middle/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-middle/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-start/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/depth/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/depth/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/depth/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete-across-blocks-and-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete-across-blocks-and-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete-across-blocks-and-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete-across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete-across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-delete/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-inline/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-block-at-range/with-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-end/index.js (74%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-middle/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-middle/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-middle/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-start/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/block-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/depth/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/depth/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/depth/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/with-delete/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/with-delete/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/with-delete/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/with-marks/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/with-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/split-inline-at-range/with-marks/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/remove-across-blocks => changes/fixtures/at-range/toggle-mark-at-range/add-across-blocks}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-across-blocks/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/remove-across-inlines => changes/fixtures/at-range/toggle-mark-at-range/add-across-inlines}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-across-inlines/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/remove-existing-marks => changes/fixtures/at-range/toggle-mark-at-range/add-existing-marks}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-first-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-last-character/index.js (73%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-middle-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-whole-word/index.js (83%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-with-mark-object/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-with-mark-object/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/remove-with-plain-object => changes/fixtures/at-range/toggle-mark-at-range/add-with-plain-object}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/add-with-plain-object/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/add-across-blocks => changes/fixtures/at-range/toggle-mark-at-range/remove-across-blocks}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-across-blocks/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/add-across-inlines => changes/fixtures/at-range/toggle-mark-at-range/remove-across-inlines}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-across-inlines/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/add-existing-marks => changes/fixtures/at-range/toggle-mark-at-range/remove-existing-marks}/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-existing-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-existing-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-first-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-first-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-first-character/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/toggle-mark-at-range/remove-last-character/index.js rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-middle-character/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-middle-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-middle-character/output.yaml (100%) create mode 100644 test/changes/fixtures/at-range/toggle-mark-at-range/remove-whole-word/index.js rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-whole-word/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-whole-word/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-with-mark-object/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-with-mark-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-with-mark-object/output.yaml (100%) rename test/{transforms/fixtures/at-range/toggle-mark-at-range/add-with-plain-object => changes/fixtures/at-range/toggle-mark-at-range/remove-with-plain-object}/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-with-plain-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/toggle-mark-at-range/remove-with-plain-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/ending-child-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/ending-child-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/ending-child-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/middle-child-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/middle-child-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/middle-child-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/nested-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/single-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/starting-child-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/starting-child-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/starting-child-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/with-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-block-at-range/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/nested-block/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/single-block/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/with-object/index.js (93%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/with-text-between/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/with-text-between/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/unwrap-inline-at-range/with-text-between/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/double-nested-block/index.js (89%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/double-nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/double-nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/nested-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/single-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/with-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-block-at-range/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/nested-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/nested-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/nested-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/single-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/with-object/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/with-object/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/wrap-inline-void/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/wrap-inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-inline-at-range/wrap-inline-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/across-blocks/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/across-blocks/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/across-blocks/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/across-inlines/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/across-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/across-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/backwards-selection/index.js (92%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/backwards-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/backwards-selection/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/empty-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/empty-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/empty-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/end-of-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/end-of-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/end-of-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/middle-of-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/middle-of-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/middle-of-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/start-of-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/start-of-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/start-of-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/whole-block/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/whole-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/whole-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/without-suffix/index.js (91%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/without-suffix/input.yaml (100%) rename test/{transforms => changes}/fixtures/at-range/wrap-text-at-range/without-suffix/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/end-of-target/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/end-of-target/index.js (93%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/end-of-target/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/end-of-target/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/middle-of-target/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/middle-of-target/index.js (93%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/middle-of-target/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/middle-of-target/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/start-of-target/fragment.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/start-of-target/index.js (93%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/start-of-target/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-fragment-by-key/start-of-target/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/block/index.js (70%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/block/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/duplicate/index.js (93%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/duplicate/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/duplicate/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/inline/index.js (90%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-node-by-key/inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/end-text/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/end-text/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/end-text/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/middle-text-with-marks/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/middle-text-with-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/middle-text-with-marks/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/middle-text/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/middle-text/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/middle-text/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-after/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-after/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-after/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-before/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-before/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-before/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-end/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-end/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-end/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-start/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-wrap/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-wrap/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/selection-wrap/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/start-text/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/start-text/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/insert-text-by-key/start-text/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/join-node-by-key/block/index.js (70%) rename test/{transforms/fixtures/on-history/undo/set-selection => changes/fixtures/by-key/join-node-by-key/block}/input.yaml (77%) rename test/{transforms => changes}/fixtures/by-key/join-node-by-key/block/output.yaml (78%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/block/index.js (86%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/block/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/inline/index.js (88%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/text/index.js (88%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/text/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/text/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/to-sibling/index.js (72%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/to-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/move-node-by-key/to-sibling/output.yaml (100%) rename test/{transforms/fixtures/by-key/remove-node-by-key/text => changes/fixtures/by-key/remove-node-by-key/block}/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/block/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/inline/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/selection-inside/index.js (95%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/selection-inside/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/selection-inside/output.yaml (100%) rename test/{transforms/fixtures/by-key/remove-node-by-key/block => changes/fixtures/by-key/remove-node-by-key/text}/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/text/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-node-by-key/text/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/adjacent-non-void-inlines/index.js (84%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/adjacent-non-void-inlines/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/adjacent-non-void-inlines/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-last-character-deep/index.js (84%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-last-character-deep/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-last-character-deep/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-last-character/index.js (84%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-last-character/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-last-character/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-void/index.js (85%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline/index.js (85%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/next-void-inline/index.js (84%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/next-void-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/next-void-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/previous-void-inline/index.js (85%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/previous-void-inline/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/previous-void-inline/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-after/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-after/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-after/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-before/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-before/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-before/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-start/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-start/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-start/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-wrap/index.js (94%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-wrap/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/selection-wrap/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/text/index.js (85%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/text/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/remove-text-by-key/text/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-mark-by-key/set-data/index.js (85%) rename test/{transforms => changes}/fixtures/by-key/set-mark-by-key/set-data/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-mark-by-key/set-data/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/inline-void/index.js (87%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/inline-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/inline-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/single-block-string-shorthand/index.js (84%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/single-block-string-shorthand/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/single-block-string-shorthand/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/single-block/index.js (85%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/set-node-by-key/single-block/output.yaml (100%) rename test/{transforms/fixtures/by-key/split-node-by-key/block => changes/fixtures/by-key/split-descendants-by-key/block-with-selection}/index.js (67%) rename test/{transforms/fixtures/by-key/split-node-by-key/block => changes/fixtures/by-key/split-descendants-by-key/block-with-selection}/input.yaml (55%) rename test/{transforms/fixtures/on-history/undo/remove-node => changes/fixtures/by-key/split-descendants-by-key/block-with-selection}/output.yaml (61%) create mode 100644 test/changes/fixtures/by-key/split-descendants-by-key/block/index.js create mode 100644 test/changes/fixtures/by-key/split-descendants-by-key/block/input.yaml rename test/{transforms/fixtures/on-history/undo/move-node => changes/fixtures/by-key/split-descendants-by-key/block}/output.yaml (61%) create mode 100644 test/changes/fixtures/by-key/split-node-by-key/block-with-selection/index.js create mode 100644 test/changes/fixtures/by-key/split-node-by-key/block-with-selection/input.yaml create mode 100644 test/changes/fixtures/by-key/split-node-by-key/block-with-selection/output.yaml create mode 100644 test/changes/fixtures/by-key/split-node-by-key/block/index.js create mode 100644 test/changes/fixtures/by-key/split-node-by-key/block/input.yaml create mode 100644 test/changes/fixtures/by-key/split-node-by-key/block/output.yaml rename test/{transforms => changes}/fixtures/by-key/split-node-by-key/text/index.js (78%) rename test/{transforms => changes}/fixtures/by-key/split-node-by-key/text/input.yaml (68%) rename test/{transforms => changes}/fixtures/by-key/split-node-by-key/text/output.yaml (83%) rename test/{transforms => changes}/fixtures/by-key/unwrap-block-by-key/single-block/index.js (84%) rename test/{transforms => changes}/fixtures/by-key/unwrap-block-by-key/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-block-by-key/single-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-inline-by-key/single-block/index.js (88%) rename test/{transforms => changes}/fixtures/by-key/unwrap-inline-by-key/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-inline-by-key/single-block/output.yaml (100%) rename test/{transforms/fixtures/by-key/unwrap-node-by-key/with-siblings => changes/fixtures/by-key/unwrap-node-by-key/first-sibling}/index.js (74%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/first-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/first-sibling/output.yaml (100%) rename test/{transforms/fixtures/by-key/unwrap-node-by-key/single-block => changes/fixtures/by-key/unwrap-node-by-key/last-sibling}/index.js (74%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/last-sibling/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/last-sibling/output.yaml (100%) rename test/{transforms/fixtures/by-key/unwrap-node-by-key/first-sibling => changes/fixtures/by-key/unwrap-node-by-key/single-block}/index.js (74%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/single-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/single-block/output.yaml (100%) rename test/{transforms/fixtures/by-key/unwrap-node-by-key/last-sibling => changes/fixtures/by-key/unwrap-node-by-key/with-siblings}/index.js (74%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/with-siblings/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/unwrap-node-by-key/with-siblings/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/wrap-block-by-key/block-node/index.js (74%) rename test/{transforms => changes}/fixtures/by-key/wrap-block-by-key/block-node/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/wrap-block-by-key/block-node/output.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/wrap-block-by-key/text-node/index.js (74%) rename test/{transforms => changes}/fixtures/by-key/wrap-block-by-key/text-node/input.yaml (100%) rename test/{transforms => changes}/fixtures/by-key/wrap-block-by-key/text-node/output.yaml (100%) rename test/{transforms => changes}/fixtures/call/call-no-arguments/index.js (58%) rename test/{transforms => changes}/fixtures/call/call-no-arguments/input.yaml (100%) rename test/{transforms => changes}/fixtures/call/call-no-arguments/output.yaml (100%) rename test/{transforms => changes}/fixtures/call/call-with-arguments/index.js (59%) rename test/{transforms => changes}/fixtures/call/call-with-arguments/input.yaml (100%) rename test/{transforms => changes}/fixtures/call/call-with-arguments/output.yaml (100%) create mode 100644 test/changes/fixtures/general/set-data/index.js rename test/{transforms/fixtures/state-data => changes/fixtures/general}/set-data/input.yaml (100%) rename test/{transforms/fixtures/state-data => changes/fixtures/general}/set-data/output.yaml (87%) rename test/{transforms => changes}/fixtures/on-history/undo/add-mark/index.js (80%) rename test/{transforms => changes}/fixtures/on-history/undo/add-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/add-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/delete-text-across-block/index.js (68%) rename test/{transforms/fixtures/on-history/undo/remove-node => changes/fixtures/on-history/undo/delete-text-across-block}/input.yaml (84%) rename test/{transforms/fixtures/by-key/split-node-by-key/block => changes/fixtures/on-history/undo/delete-text-across-block}/output.yaml (100%) create mode 100644 test/changes/fixtures/on-history/undo/delete-text-with-marks/index.js rename test/{transforms => changes}/fixtures/on-history/undo/delete-text-with-marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/delete-text-with-marks/output.yaml (100%) create mode 100644 test/changes/fixtures/on-history/undo/delete-text/index.js rename test/{transforms => changes}/fixtures/on-history/undo/delete-text/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/delete-text/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-node/index.js (83%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-node/input.yaml (100%) rename test/{transforms/fixtures/on-history/undo/delete-text-across-block => changes/fixtures/on-history/undo/insert-node}/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-contiguous/index.js (76%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-contiguous/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-contiguous/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-nested-contiguous/index.js (77%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-nested-contiguous/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-nested-contiguous/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-nested-non-contiguous/index.js (67%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-nested-non-contiguous/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-nested-non-contiguous/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-non-contiguous/index.js (64%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-non-contiguous/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text-many-non-contiguous/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text/index.js (88%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/insert-text/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/join-node-block/index.js (68%) rename test/{transforms => changes}/fixtures/on-history/undo/join-node-block/input.yaml (100%) rename test/{transforms/fixtures/on-history/undo/insert-node => changes/fixtures/on-history/undo/join-node-block}/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/move-node/index.js (54%) create mode 100644 test/changes/fixtures/on-history/undo/move-node/input.yaml create mode 100644 test/changes/fixtures/on-history/undo/move-node/output.yaml rename test/{transforms => changes}/fixtures/on-history/undo/remove-mark/index.js (80%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-middle-void/index.js (60%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-middle-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-middle-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-nested-middle-void/index.js (66%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-nested-middle-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-nested-middle-void/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/remove-node/index.js (61%) rename test/{transforms/fixtures/on-history/undo/move-node => changes/fixtures/on-history/undo/remove-node}/input.yaml (100%) rename test/{transforms/fixtures/on-history/undo/join-node-block => changes/fixtures/on-history/undo/remove-node}/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/set-mark/index.js (82%) rename test/{transforms => changes}/fixtures/on-history/undo/set-mark/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/set-mark/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/set-node-data/index.js (77%) rename test/{transforms => changes}/fixtures/on-history/undo/set-node-data/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/set-node-data/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/set-selection/index.js (57%) rename test/{transforms/fixtures/on-history/undo/delete-text-across-block => changes/fixtures/on-history/undo/set-selection}/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/set-selection/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/split-node-block/index.js (80%) rename test/{transforms => changes}/fixtures/on-history/undo/split-node-block/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/split-node-block/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/unwrap-node-by-key/index.js (62%) rename test/{transforms => changes}/fixtures/on-history/undo/unwrap-node-by-key/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-history/undo/unwrap-node-by-key/output.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/blur/basic/index.js (88%) rename test/{transforms => changes}/fixtures/on-selection/blur/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/blur/marks/index.js (93%) rename test/{transforms => changes}/fixtures/on-selection/blur/marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-anchor/already-collapsed/index.js (93%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-anchor/already-collapsed/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-anchor/basic/index.js (89%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-anchor/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-end/already-collapsed/index.js (93%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-end/already-collapsed/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-end/basic/index.js (77%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-end/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-end/void/index.js (87%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-end/void/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-focus/already-collapsed/index.js (93%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-focus/already-collapsed/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-focus/basic/index.js (77%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-focus/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-start/already-collapsed/index.js (93%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-start/already-collapsed/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-start/basic/index.js (89%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-start/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-start/void/index.js (87%) rename test/{transforms => changes}/fixtures/on-selection/collapse-to-start/void/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/focus/basic/index.js (89%) rename test/{transforms => changes}/fixtures/on-selection/focus/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/focus/marks/index.js (93%) rename test/{transforms => changes}/fixtures/on-selection/focus/marks/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/move-to/with-object/index.js (84%) rename test/{transforms => changes}/fixtures/on-selection/move-to/with-object/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/move-to/with-selection/index.js (83%) rename test/{transforms => changes}/fixtures/on-selection/move-to/with-selection/input.yaml (100%) rename test/{transforms => changes}/fixtures/on-selection/select-all/basic/index.js (91%) rename test/{transforms => changes}/fixtures/on-selection/select-all/basic/input.yaml (100%) rename test/{transforms => changes}/fixtures/split-block/with-void/index.js (93%) rename test/{transforms => changes}/fixtures/split-block/with-void/input.yaml (100%) rename test/{transforms => changes}/fixtures/split-block/with-void/output.yaml (100%) rename test/{transforms => changes}/index.js (70%) delete mode 100644 test/transforms/fixtures/at-current-range/delete-forward/join-nested-blocks/index.js delete mode 100644 test/transforms/fixtures/at-current-range/delete-forward/last-character/index.js delete mode 100644 test/transforms/fixtures/at-current-range/insert-text/last-character/index.js delete mode 100644 test/transforms/fixtures/at-current-range/toggle-mark/remove-last-character/index.js delete mode 100644 test/transforms/fixtures/at-current-range/toggle-mark/remove-whole-word/index.js delete mode 100644 test/transforms/fixtures/at-range/delete-forward-at-range/join-blocks-with-inline-void/index.js delete mode 100644 test/transforms/fixtures/at-range/delete-forward-at-range/join-blocks-with-inlines/index.js delete mode 100644 test/transforms/fixtures/at-range/delete-forward-at-range/join-blocks/index.js delete mode 100644 test/transforms/fixtures/at-range/delete-forward-at-range/join-nested-blocks/index.js delete mode 100644 test/transforms/fixtures/at-range/delete-forward-at-range/last-character/index.js delete mode 100644 test/transforms/fixtures/at-range/insert-text-at-range/last-character/index.js delete mode 100644 test/transforms/fixtures/at-range/toggle-mark-at-range/remove-last-character/index.js delete mode 100644 test/transforms/fixtures/at-range/toggle-mark-at-range/remove-whole-word/index.js delete mode 100644 test/transforms/fixtures/by-key/join-node-by-key/block/input.yaml delete mode 100644 test/transforms/fixtures/by-key/join-node-by-key/text/index.js delete mode 100644 test/transforms/fixtures/by-key/join-node-by-key/text/input.yaml delete mode 100644 test/transforms/fixtures/by-key/join-node-by-key/text/output.yaml delete mode 100644 test/transforms/fixtures/on-history/undo/delete-text-with-marks/index.js delete mode 100644 test/transforms/fixtures/on-history/undo/delete-text/index.js delete mode 100644 test/transforms/fixtures/state-data/set-data/index.js diff --git a/.eslintrc b/.eslintrc index e01221b3f..e78569c57 100644 --- a/.eslintrc +++ b/.eslintrc @@ -21,7 +21,6 @@ "arrow-parens": ["error", "as-needed", { "requireForBlockBody": true }], "arrow-spacing": "error", "block-spacing": "error", - "capitalized-comments": ["error", "always", { "ignoreConsecutiveComments": true, "ignoreInlineComments": true }], "comma-dangle": ["error", "only-multiline"], "comma-spacing": ["error", { "before": false, "after": true }], "comma-style": ["error", "last"], diff --git a/.gitignore b/.gitignore index 1ef5431fa..b6af211e9 100644 --- a/.gitignore +++ b/.gitignore @@ -11,9 +11,10 @@ tmp # Gitbook files. _book -# NPM files. +# Package files. node_modules npm-debug.log +yarn-error.log -# Mac stuff. +# OS files. .DS_Store diff --git a/benchmark/fixtures/models/update-descendant/index.js b/benchmark/fixtures/models/update-node/index.js similarity index 90% rename from benchmark/fixtures/models/update-descendant/index.js rename to benchmark/fixtures/models/update-node/index.js index 0a5ffe7a1..86704a0f1 100644 --- a/benchmark/fixtures/models/update-descendant/index.js +++ b/benchmark/fixtures/models/update-node/index.js @@ -2,7 +2,7 @@ import { __clear } from '../../../../lib/utils/memoize' export default function ({ state, next }) { - state.document.updateDescendant(next) + state.document.updateNode(next) } export function before(state) { diff --git a/benchmark/fixtures/models/update-descendant/input.yaml b/benchmark/fixtures/models/update-node/input.yaml similarity index 100% rename from benchmark/fixtures/models/update-descendant/input.yaml rename to benchmark/fixtures/models/update-node/input.yaml diff --git a/benchmark/fixtures/transforms/delete-backward/index.js b/benchmark/fixtures/transforms/delete-backward/index.js index 00e8d020f..5725bf0e9 100644 --- a/benchmark/fixtures/transforms/delete-backward/index.js +++ b/benchmark/fixtures/transforms/delete-backward/index.js @@ -1,19 +1,18 @@ export default function (state) { state - .transform() + .change() .deleteBackward() - .apply() } export function before(state) { return state - .transform() + .change() .select({ anchorKey: '_cursor_', anchorOffset: 10, focusKey: '_cursor_', focusOffset: 10 }) - .apply() + .state } diff --git a/benchmark/fixtures/transforms/insert-text/index.js b/benchmark/fixtures/transforms/insert-text/index.js index dd6052383..e0bf7f67c 100644 --- a/benchmark/fixtures/transforms/insert-text/index.js +++ b/benchmark/fixtures/transforms/insert-text/index.js @@ -1,19 +1,18 @@ export default function (state) { state - .transform() + .change() .insertText('a') - .apply() } export function before(state) { return state - .transform() + .change() .select({ anchorKey: '_cursor_', anchorOffset: 10, focusKey: '_cursor_', focusOffset: 10 }) - .apply() + .state } diff --git a/benchmark/fixtures/transforms/normalize/index.js b/benchmark/fixtures/transforms/normalize/index.js index 787fe8398..68be79321 100644 --- a/benchmark/fixtures/transforms/normalize/index.js +++ b/benchmark/fixtures/transforms/normalize/index.js @@ -3,7 +3,6 @@ import SCHEMA from '../../../../lib/schemas/core' export default function (state) { state - .transform({ normalized: false }) + .change() .normalize(SCHEMA) - .apply() } diff --git a/benchmark/fixtures/transforms/split-block/index.js b/benchmark/fixtures/transforms/split-block/index.js index 64c08d444..6dcb23a4f 100644 --- a/benchmark/fixtures/transforms/split-block/index.js +++ b/benchmark/fixtures/transforms/split-block/index.js @@ -1,19 +1,18 @@ export default function (state) { state - .transform() + .change() .splitBlock() - .apply() } export function before(state) { return state - .transform() + .change() .select({ anchorKey: '_cursor_', anchorOffset: 10, focusKey: '_cursor_', focusOffset: 10 }) - .apply() + .state } diff --git a/docs/Readme.md b/docs/Readme.md index 720576035..976c9ebae 100644 --- a/docs/Readme.md +++ b/docs/Readme.md @@ -20,9 +20,9 @@ Before creating Slate, I tried a lot of the other rich text libraries out there. Here's how Slate compares to some of the existing editors out there: -- [**Draft.js**](https://facebook.github.io/draft-js/) — Slate borrowed a few concepts from Draft.js, namely its event system, its use of Immutable.js and React, and its goal of being a "framework" for creating editors. It also borrowed its plugin-centric design from the [Draft.js Plugins](https://github.com/draft-js-plugins/draft-js-plugins) project. But the issues I ran into while using Draft.js were: that lots of the logic around the schema is hardcoded in "core" and difficult to customize, that the transform API is complex to use and not suited to collaborative editing in the future, that serialization isn't considered by the core library in a nice way, that the flat document model made certain behaviors impossible, and that lots of the API feels very heavy to work with. +- [**Draft.js**](https://facebook.github.io/draft-js/) — Slate borrowed a few concepts from Draft.js, namely its event system, its use of Immutable.js and React, and its goal of being a "framework" for creating editors. It also borrowed its plugin-centric design from the [Draft.js Plugins](https://github.com/draft-js-plugins/draft-js-plugins) project. But the issues I ran into while using Draft.js were: that lots of the logic around the schema is hardcoded in "core" and difficult to customize, that the change API is complex to use and not suited to collaborative editing in the future, that serialization isn't considered by the core library in a nice way, that the flat document model made certain behaviors impossible, and that lots of the API feels very heavy to work with. -- [**Prosemirror**](http://prosemirror.net/) — Slate borrowed a few concepts from Prosemirror, namely its nested document tree, and its transform model. But the issues I ran into while using it were: that the API is hard to understand, that the codebase wasn't structured around common node module practices, that lots of magic was built into the core library that was hard to customize, that toolbars and buttons are too tied to the editor itself, and that the documentation isn't great. (It's still in beta though!) +- [**Prosemirror**](http://prosemirror.net/) — Slate borrowed a few concepts from Prosemirror, namely its nested document tree, and its change model. But the issues I ran into while using it were: that the API is hard to understand, that the codebase wasn't structured around common node module practices, that lots of magic was built into the core library that was hard to customize, that toolbars and buttons are too tied to the editor itself, and that the documentation isn't great. (It's still in beta though!) - [**Quill**](http://quilljs.com/) — I never used Quill directly, so my hesitations about it are solely from considering it in early stages. The issues I see with it are: that the concept of "toolbars" is too coupled with the editor itself, that the configuration is too coupled to HTML classes and DOM nodes, that the idea of "formats" and "toolbars" being linked is limiting, and generally that too much "core" logic is given special privileges and is hard to customize. @@ -51,9 +51,9 @@ Slate tries to solve the question of "[Why?](#why)" with a few principles: 4. **Stateless and immutable data.** By using React and Immutable.js, the Slate editor is built in a stateless fashion using immutable data structures, which leads to much easier to reason about code, and a much easier time writing plugins. -5. **Intuitive transforms.** Slate's content is edited using "transforms", that are designed to be high level and extremely intuitive to use, so that writing plugins and custom functionality is as simple as possible. +5. **Intuitive changes.** Slate's content is edited using "changes", that are designed to be high level and extremely intuitive to use, so that writing plugins and custom functionality is as simple as possible. -6. **Collaboration-ready data model.** The data model Slate uses—specifically how transforms are applied to the document—has been designed to allow for collaborative editing to be layered on top, so you won't need to rethink everything if you decide to make your editor collaborative. (More work is required on this!) +6. **Collaboration-ready data model.** The data model Slate uses—specifically how changes are applied to the document—has been designed to allow for collaborative editing to be layered on top, so you won't need to rethink everything if you decide to make your editor collaborative. (More work is required on this!) 7. **Clear "core" boundaries.** With a plugin-first architecture, and a schema-less core, it becomes a lot clearer where the boundary is between "core" and "custom", which means that the core experience doesn't get bogged down in edge cases. diff --git a/docs/Summary.md b/docs/Summary.md index 109d1e880..8771b7eaa 100644 --- a/docs/Summary.md +++ b/docs/Summary.md @@ -32,7 +32,7 @@ - [Schema](./reference/models/schema.md) - [State](./reference/models/state.md) - [Text](./reference//models/text.md) -- [Transform](./reference/models/transform.md) +- [Change](./reference/models/change.md) ## Serializer Reference diff --git a/docs/concepts/statelessness-and-immutability.md b/docs/concepts/statelessness-and-immutability.md index bf40dff19..2d76ac728 100644 --- a/docs/concepts/statelessness-and-immutability.md +++ b/docs/concepts/statelessness-and-immutability.md @@ -15,10 +15,10 @@ Instead, the new state is propagated to the Slate editor's parent component, who _To learn more, check out the [`` component reference](../reference/components/editor.md)._ -### Transforms +### Changes -All of the changes in Slate are applied via [`Transforms`](../reference/models/transform.md). This makes it possible to enforce some of the constraints that Slate needs to enforce, like requiring that [all leaf nodes be text nodes](./the-document-model.md#leaf-text-nodes). This also makes it possible to implement collaborative editing, where information about changes must be serialized and sent over the network to other editors. +All of the changes in Slate are applied via [`Changes`](../reference/models/change.md). This makes it possible to enforce some of the constraints that Slate needs to enforce, like requiring that [all leaf nodes be text nodes](./the-document-model.md#leaf-text-nodes). This also makes it possible to implement collaborative editing, where information about changes must be serialized and sent over the network to other editors. -You should never update the `selection` or `document` of an editor other than by using the [`transform()`](../reference/models/state.md#transform) method of a `State`. +You should never update the `selection` or `document` of an editor other than by using the [`change()`](../reference/models/state.md#change) method of a `State`. -_To learn more, check out the [`Transform` model reference](../reference/models/transform.md)._ +_To learn more, check out the [`Change` model reference](../reference/models/change.md)._ diff --git a/docs/concepts/the-selection-model.md b/docs/concepts/the-selection-model.md index fc0f49209..f3f9ef89c 100644 --- a/docs/concepts/the-selection-model.md +++ b/docs/concepts/the-selection-model.md @@ -1,7 +1,7 @@ # The Selection Model -Slate keeps track of the user's selection in the editor in an immutable data store called a [`Selection`](../reference/models/selection.md). By doing this, it lets Slate manipulate the selection with transforms, but still update it in the DOM on `render`. +Slate keeps track of the user's selection in the editor in an immutable data store called a [`Selection`](../reference/models/selection.md). By doing this, it lets Slate manipulate the selection with changes, but still update it in the DOM on `render`. ### Always References Text @@ -17,7 +17,7 @@ This makes selections easier to reason about, while still giving us the benefits When a selection is used to compute a set of [`Block`](../reference/models/block.md) nodes, by convention those nodes are always the leaf-most `Block` nodes (ie. the lowest `Block` nodes in the tree at their location). This is important, because the nested document model allows for nested `Block` nodes. -This convention makes it much simpler to implement selection and transformation logic, since the user's actions are very often supposed to effect the leaf blocks. +This convention makes it much simpler to implement selection and changeation logic, since the user's actions are very often supposed to effect the leaf blocks. ### Trunk Inlines diff --git a/docs/general/comparisons.md b/docs/general/comparisons.md index 9882d70d5..7ca98cb85 100644 --- a/docs/general/comparisons.md +++ b/docs/general/comparisons.md @@ -3,9 +3,9 @@ A series of comparisons with other rich text editors, in a highly-opinionated way, and some of which without actual use. If these things mesh with your own experiences with those editors, then you might understand some of the reasons behind why Slate was created. If not, I'm sorry, feel free to contribute edits. -- [**Draft.js**](https://facebook.github.io/draft-js/) — Slate borrowed a few concepts from Draft.js, namely its event system, its use of Immutable.js and React, and its goal of being a "framework" for creating editors. It also borrowed its plugin-centric design from the [Draft.js Plugins](https://github.com/draft-js-plugins/draft-js-plugins) project. But the issues I ran into while using Draft.js were: that lots of the logic around the schema is hardcoded in "core" and difficult to customize, that the transform API is complex to use and not suited to collaborative editing in the future, that serialization isn't considered by the core library in a nice way, that the flat document model made certain behaviors impossible, and that lots of the API feels very heavy to work with. +- [**Draft.js**](https://facebook.github.io/draft-js/) — Slate borrowed a few concepts from Draft.js, namely its event system, its use of Immutable.js and React, and its goal of being a "framework" for creating editors. It also borrowed its plugin-centric design from the [Draft.js Plugins](https://github.com/draft-js-plugins/draft-js-plugins) project. But the issues I ran into while using Draft.js were: that lots of the logic around the schema is hardcoded in "core" and difficult to customize, that the change API is complex to use and not suited to collaborative editing in the future, that serialization isn't considered by the core library in a nice way, that the flat document model made certain behaviors impossible, and that lots of the API feels very heavy to work with. -- [**Prosemirror**](http://prosemirror.net/) — Slate borrowed a few concepts from Prosemirror, namely its nested document tree, and its transform model. But the issues I ran into while using it were: that the API is hard to understand, that the codebase wasn't structured around common node module practices, that lots of magic was built into the core library that was hard to customize, that toolbars and buttons are too tied to the editor itself, and that the documentation isn't great. (It's still in beta though!) +- [**Prosemirror**](http://prosemirror.net/) — Slate borrowed a few concepts from Prosemirror, namely its nested document tree, and its change model. But the issues I ran into while using it were: that the API is hard to understand, that the codebase wasn't structured around common node module practices, that lots of magic was built into the core library that was hard to customize, that toolbars and buttons are too tied to the editor itself, and that the documentation isn't great. (It's still in beta though!) - [**Quill**](http://quilljs.com/) — I never used Quill directly, so my hesitations about it are solely from considering it in early stages. The issues I see with it are: that the concept of "toolbars" is too coupled with the editor itself, that the configuration is too coupled to HTML classes and DOM nodes, that the idea of "formats" and "toolbars" being linked is limiting, and generally that too much "core" logic is given special privileges and is hard to customize. diff --git a/docs/guides/schemas.md b/docs/guides/schemas.md index 771fa7048..0daba1deb 100644 --- a/docs/guides/schemas.md +++ b/docs/guides/schemas.md @@ -19,7 +19,7 @@ Slate schemas are built up of a set of rules. Every rule has a few properties: render: Component || Function || Object || String, decorate: Function, validate: Function || Object, - transform: Function + change: Function } ``` diff --git a/docs/reference/Readme.md b/docs/reference/Readme.md index 1a7e67f03..260514bcb 100644 --- a/docs/reference/Readme.md +++ b/docs/reference/Readme.md @@ -17,7 +17,7 @@ This is the full reference documentation for all of the pieces of Slate, broken - [Selection](./models/selection.md) - [State](./models/state.md) - [Text](./models/text.md) - - [Transform](./models/transform.md) + - [Change](./models/change.md) - **Serializers** - [Html](./serializers/html.md) - [Plain](./serializers/plain.md) diff --git a/docs/reference/components/editor.md b/docs/reference/components/editor.md index 91353a0d4..7270ec85d 100644 --- a/docs/reference/components/editor.md +++ b/docs/reference/components/editor.md @@ -42,7 +42,8 @@ The top-level React component that renders the Slate editor itself. - [`focus`](#focus) - [`getSchema()`](#getschema) - [`getState()`](#getstate) - - [`onChange(state)`](#onchange) + - [`onChange(change)`](#onchange) + - [`change`](#change) ## Properties @@ -80,19 +81,19 @@ An optional attribute that, when set to true, attempts to give the content edita An optional class name to apply to the content editable element. ### `onChange` -`Function onChange(state: State)` +`Function onChange(change: Change)` -A change handler that will be called with the newly-changed editor `state`. You should usually pass the newly changed `state` back into the editor through its `state` property. This hook allows you to add persistence logic to your editor. +A change handler that will be called with the `change` that applied the change. You should usually pass the newly changed `change.state` back into the editor through its `state` property. This hook allows you to add persistence logic to your editor. ### `onDocumentChange` -`Function onDocumentChange(document: Document, state: State)` +`Function onDocumentChange(document: Document, change: Change)` -A convenience handler property that will only be called for changes in state where the document has changed. It is called with the changed `document` and `state`. +A convenience handler property that will only be called for changes in state where the document has changed. It is called with the changed `document` and `change`. ### `onSelectionChange` -`Function onSelectionChange(selection: Selection, state: State)` +`Function onSelectionChange(selection: Selection, change: Change)` -A convenience handler property that will only be called for changes in state where the selection has changed. It is called with the changed `selection` and `state`. +A convenience handler property that will only be called for changes in state where the selection has changed. It is called with the changed `selection` and `change`. ### `plugins` `Array` @@ -229,6 +230,6 @@ Return the editor's current schema. Return the editor's current state. ### `onChange` -`onChange(state: State) => Void` +`onChange(change: Change) => Void` -Effectively the same as `setState`. Invoking this method will update the state of the editor, running it through all of it's plugins, and passing it the parent component, before it cycles back down as the new `state` property of the editor. +Invoking this method will update the state of the editor with the `change`, running it through all of it's plugins, and passing it the parent component, before it cycles back down as the new `state` property of the editor. diff --git a/docs/reference/models/block.md b/docs/reference/models/block.md index 1e2b2b024..a76349402 100644 --- a/docs/reference/models/block.md +++ b/docs/reference/models/block.md @@ -17,7 +17,6 @@ Block nodes may contain nested block nodes, inline nodes, and text nodes—just - [`type`](#type) - [Computed Properties](#computed-properties) - [`kind`](#kind) - - [`length`](#length) - [`text`](#text) - [Static Methods](#static-methods) - [`Block.create`](#blockcreate) @@ -73,11 +72,6 @@ The custom type of the node (eg. `blockquote` or `list-item`). An immutable string value of `'block'` for easily separating this node from [`Inline`](./inline.md) or [`Text`](./text.md) nodes. -### `length` -`Number` - -The sum of the lengths of all of the descendant [`Text`](./text.md) nodes of this node. - ### `text` `String` diff --git a/docs/reference/models/document.md b/docs/reference/models/document.md index 931073458..81332e1ef 100644 --- a/docs/reference/models/document.md +++ b/docs/reference/models/document.md @@ -16,7 +16,6 @@ In some places, you'll see mention of "fragments", which are also `Document` obj - [`nodes`](#nodes) - [Computed Properties](#computed-properties) - [`kind`](#kind) - - [`length`](#length) - [`text`](#text) - [Static Methods](#static-methods) - [`Document.create`](#documentcreate) @@ -50,11 +49,6 @@ A list of child nodes. An immutable string value of `'document'` for easily separating this node from [`Block`](./block.md), [`Inline`](./inline.md) or [`Text`](./text.md) nodes. -### `length` -`Number` - -The sum of the lengths of all of the descendant [`Text`](./text.md) nodes of this node. - ### `text` `String` diff --git a/docs/reference/models/inline.md b/docs/reference/models/inline.md index 6b352a20b..e1927146e 100644 --- a/docs/reference/models/inline.md +++ b/docs/reference/models/inline.md @@ -17,7 +17,6 @@ Inline nodes may contain nested inline nodes and text nodes—just like in the D - [`type`](#type) - [Computed Properties](#computed-properties) - [`kind`](#kind) - - [`length`](#length) - [`text`](#text) - [Static Methods](#static-methods) - [`Inline.create`](#inlinecreate) @@ -73,11 +72,6 @@ The custom type of the node (eg. `link` or `hashtag`). An immutable string value of `'inline'` for easily separating this node from [`Block`](./block.md) or [`Text`](./text.md) nodes. -### `length` -`Number` - -The sum of the lengths of all of the descendant [`Text`](./text.md) nodes of this node. - ### `text` `String` diff --git a/docs/reference/models/node.md b/docs/reference/models/node.md index 9cb8b028d..f4183a239 100644 --- a/docs/reference/models/node.md +++ b/docs/reference/models/node.md @@ -7,7 +7,6 @@ - [`nodes`](#nodes) - [Computed Properties](#computed-properties) - [`kind`](#kind) - - [`length`](#length) - [`text`](#text) - [Methods](#methods) - [`filterDescendants`](#filterdescendants) @@ -68,11 +67,6 @@ A list of child nodes. Defaults to a list with a single text node child. An immutable string value of `'block'` for easily separating this node from [`Inline`](./inline.md) or [`Text`](./text.md) nodes. -### `length` -`Number` - -The sum of the lengths of all of the descendant [`Text`](./text.md) nodes of this node. - ### `text` `String` diff --git a/docs/reference/models/schema.md b/docs/reference/models/schema.md index 31ddf7ed8..e9baabb53 100644 --- a/docs/reference/models/schema.md +++ b/docs/reference/models/schema.md @@ -136,21 +136,21 @@ The `match` property is the only required property of a rule. It determines whic The `decorate` property allows you define a function that will apply extra marks to all of the ranges of text inside a node. It is called with a [`Text`](./text.md) node and the matched node. It should return a list of characters with the desired marks, which will then be added to the text before rendering. ### `normalize` -`Function normalize(transform: Transform, object: Node, failure: Any) => Transform` +`Function normalize(change: Change, object: Node, failure: Any) => Change` ```js { - normalize: (transform, node, invalidChildren) => { + normalize: (change, node, invalidChildren) => { invalidChildren.forEach((child) => { - transform.removeNodeByKey(child.key) + change.removeNodeByKey(child.key) }) - return transform + return change } } ``` -The `normalize` property is a function to run that recovers the editor's state after the `validate` property of a rule has determined that an object is invalid. It is passed a [`Transform`](./transform.md) that it can use to make modifications. It is also passed the return value of the `validate` function, which makes it easy to quickly determine the failure reason from the validation. +The `normalize` property is a function to run that recovers the editor's state after the `validate` property of a rule has determined that an object is invalid. It is passed a [`Change`](./change.md) that it can use to make modifications. It is also passed the return value of the `validate` function, which makes it easy to quickly determine the failure reason from the validation. ### `render` `Component`
diff --git a/docs/reference/models/state.md b/docs/reference/models/state.md index 0f6700ef5..8ac288258 100644 --- a/docs/reference/models/state.md +++ b/docs/reference/models/state.md @@ -7,9 +7,9 @@ import { State } from 'slate' A `State` is the top-level representation of data in Slate, containing both a [`Document`](./document.md) and a [`Selection`](./selection.md). It's what you need to paste into the Slate [``](../components/editor.md) to render something onto the page. -All transforms to the document and selection are also performed through the state object, so that they can stay in sync, and be propagated to its internal history of undo/redo state. +All changes to the document and selection are also performed through the state object, so that they can stay in sync, and be propagated to its internal history of undo/redo state. -For convenience, in addition to transforms, many of the [`Selection`](./selection.md) and [`Document`](./document.md) properties are exposed as proxies on the `State` object. +For convenience, in addition to changes, many of the [`Selection`](./selection.md) and [`Document`](./document.md) properties are exposed as proxies on the `State` object. - [Properties](#properties) - [`document`](#document) @@ -39,7 +39,7 @@ For convenience, in addition to transforms, many of the [`Selection`](./selectio - [`State.create`](#statecreate) - [`State.isState`](#stateisstate) - [Methods](#methods) - - [`transform`](#transform) + - [`change`](#change) ## Properties @@ -186,7 +186,7 @@ Returns a boolean if the passed in argument is a `State`. ## Methods -### `transform` -`transform() => Transform` +### `change` +`change() => Change` -Create a new [`Transform`](./transform.md) that acts on the current state. +Create a new [`Change`](./change.md) that acts on the current state. diff --git a/docs/reference/models/text.md b/docs/reference/models/text.md index 677e9ff90..7f4742c40 100644 --- a/docs/reference/models/text.md +++ b/docs/reference/models/text.md @@ -12,7 +12,6 @@ A text node in a Slate [`Document`](./document.md). Text nodes are always the bo - [`key`](#key) - [Computed Properties](#computed-properties) - [`kind`](#kind) - - [`length`](#length) - [`text`](#text) - [Static Methods](#static-methods) - [`Text.create`](#textcreate) @@ -46,11 +45,6 @@ A unique identifier for the node. An immutable string value of `'text'` for easily separating this node from [`Inline`](./inline.md) or [`Block`](./block.md) nodes. -### `length` -`Number` - -The length of all of the characters in the text node. - ### `text` `String` diff --git a/docs/reference/models/transform.md b/docs/reference/models/transform.md index de57a41fd..59c8287fd 100644 --- a/docs/reference/models/transform.md +++ b/docs/reference/models/transform.md @@ -1,22 +1,22 @@ -# `Transform` +# `Change` ```js -import { Transform } from 'slate' +import { Change } from 'slate' ``` -A transform allows you to define a series of changes you'd like to make to the current [`Document`](./document.md) or [`Selection`](./selection.md) in a [`State`](./state.md). +A change allows you to define a series of changes you'd like to make to the current [`Document`](./document.md) or [`Selection`](./selection.md) in a [`State`](./state.md). -All changes are performed through `Transform` objects, so that a history of changes can be preserved for use in undo/redo operations, and to make collaborative editing possible. +All changes are performed through `Change` objects, so that a history of changes can be preserved for use in undo/redo operations, and to make collaborative editing possible. -Transform methods can either operate on the [`Document`](./document.md), the [`Selection`](./selection.md), or both at once. +Change methods can either operate on the [`Document`](./document.md), the [`Selection`](./selection.md), or both at once. - [Properties](#properties) - [`state`](#state) - [Methods](#methods) - [`apply`](#apply) - [`call`](#call) -- [Current State Transforms](#current-state-transforms) +- [Current State Changes](#current-state-changes) - [`deleteBackward`](#deletebackward) - [`deleteForward`](#deleteforward) - [`delete`](#delete) @@ -36,7 +36,7 @@ Transform methods can either operate on the [`Document`](./document.md), the [`S - [`wrapBlock`](#wrapblock) - [`wrapInline`](#wrapinline) - [`wrapText`](#wraptext) -- [Selection Transforms](#selection-transforms) +- [Selection Changes](#selection-changes) - [`blur`](#blur) - [`collapseTo{Edge}Of`](#collapsetoedgeof) - [`collapseTo{Edge}Of{Direction}Block`](#collapsetoedgeofdirectionblock) @@ -53,7 +53,7 @@ Transform methods can either operate on the [`Document`](./document.md), the [`S - [`select`](#select) - [`selectAll`](#selectall) - [`deselect`](#deselect) -- [Node Transforms](#node-transforms) +- [Node Changes](#node-changes) - [`addMarkByKey`](#addmarkbykey) - [`insertNodeByKey`](#insertnodebykey) - [`insertFragmentByKey`](#insertfragmentbykey) @@ -70,7 +70,7 @@ Transform methods can either operate on the [`Document`](./document.md), the [`S - [`unwrapNodeByKey`](#unwrapnodebykey) - [`wrapBlockByKey`](#wrapblockbykey) - [`wrapInlineByKey`](#wrapinlinebykey) -- [Document Transforms](#document-transforms) +- [Document Changes](#document-changes) - [`deleteAtRange`](#deleteatrange) - [`deleteBackwardAtRange`](#deletebackwardatrange) - [`deleteForwardAtRange`](#deleteforwardatrange) @@ -90,7 +90,7 @@ Transform methods can either operate on the [`Document`](./document.md), the [`S - [`wrapBlockAtRange`](#wrapblockatrange) - [`wrapInlineAtRange`](#wrapinlineatrange) - [`wrapTextAtRange`](#wraptextatrange) -- [History Transforms](#history-transforms) +- [History Changes](#history-changes) - [`redo`](#redo) - [`undo`](#undo) @@ -99,237 +99,235 @@ Transform methods can either operate on the [`Document`](./document.md), the [`S ### `state` -A [`State`](./state.md) with the transform's current operations applied. Each time you run a new transform function this property will be updated. +A [`State`](./state.md) with the change's current operations applied. Each time you run a new change function this property will be updated. ## Methods ### `apply` -`apply(options: Object) => State` +`apply(options: Object) => Change` -Applies all of the current transform steps, returning the newly transformed [`State`](./state.md). An `options` object is optional, containing values of: - -- `save: Boolean` — override the editor's built-in logic of whether to create a new snapshot in the history, that can be reverted to later. +Applies current change steps, saving them to the history if needed. ### `call` -`call(customTransform: Function, ...arguments) => Transform` +`call(customChange: Function, ...arguments) => Change` -This method calls the provided function argument `customTransform` with the current instance of the `Transform` object as the first argument and passes through the remaining arguments. +This method calls the provided function argument `customChange` with the current instance of the `Change` object as the first argument and passes through the remaining arguments. -The function signature for `customTransform` is: +The function signature for `customChange` is: -`customTransform(transform: Transform, ...arguments)` +`customChange(change: Change, ...arguments)` -The purpose of `call` is to enable custom transform methods to exist and called in a chain. For example: +The purpose of `call` is to enable custom change methods to exist and called in a chain. For example: ``` -return state.transform() - .call(myCustomInsertTableTransform, columns, rows) +return state.change() + .call(myCustomInsertTableChange, columns, rows) .focus() .apply() ``` -## Current State Transforms +## Current State Changes ### `deleteBackward` -`deleteBackward(n: Number) => Transform` +`deleteBackward(n: Number) => Change` Delete backward `n` characters at the current cursor. If the selection is expanded, this method is equivalent to a regular [`delete()`](#delete). `n` defaults to `1`. ### `deleteForward` -`deleteForward(n: Number) => Transform` +`deleteForward(n: Number) => Change` Delete forward `n` characters at the current cursor. If the selection is expanded, this method is equivalent to a regular [`delete()`](#delete). `n` defaults to `1`. ### `delete` -`delete() => Transform` +`delete() => Change` Delete everything in the current selection. ### `insertBlock` -`insertBlock(block: Block) => Transform`
-`insertBlock(properties: Object) => Transform`
-`insertBlock(type: String) => Transform` +`insertBlock(block: Block) => Change`
+`insertBlock(properties: Object) => Change`
+`insertBlock(type: String) => Change` Insert a new block at the same level as the current block, splitting the current block to make room if it is non-empty. If the selection is expanded, it will be deleted first. ### `insertFragment` -`insertFragment(fragment: Document) => Transform` +`insertFragment(fragment: Document) => Change` Insert a [`fragment`](./document.md) at the current selection. If the selection is expanded, it will be deleted first. ### `insertInline` -`insertInline(inline: Inline) => Transform`
-`insertInline(properties: Object) => Transform` +`insertInline(inline: Inline) => Change`
+`insertInline(properties: Object) => Change` Insert a new inline at the current cursor position, splitting the text to make room if it is non-empty. If the selection is expanded, it will be deleted first. ### `insertText` -`insertText(text: String) => Transform` +`insertText(text: String) => Change` Insert a string of `text` at the current selection. If the selection is expanded, it will be deleted first. ### `addMark` -`addMark(mark: Mark) => Transform`
-`addMark(properties: Object) => Transform`
-`addMark(type: String) => Transform` +`addMark(mark: Mark) => Change`
+`addMark(properties: Object) => Change`
+`addMark(type: String) => Change` Add a [`mark`](./mark.md) to the characters in the current selection. For convenience, you can pass a `type` string or `properties` object to implicitly create a [`Mark`](./mark.md) of that type. ### `setBlock` -`setBlock(properties: Object) => Transform`
-`setBlock(type: String) => Transform` +`setBlock(properties: Object) => Change`
+`setBlock(type: String) => Change` Set the `properties` of the [`Block`](./block.md) in the current selection. For convenience, you can pass a `type` string to set the blocks's type only. ### `setInline` -`setInline(properties: Object) => Transform`
-`setInline(type: String) => Transform` +`setInline(properties: Object) => Change`
+`setInline(type: String) => Change` Set the `properties` of the [`Inline`](./inline.md) nodes in the current selection. For convenience, you can pass a `type` string to set the inline's type only. ### `splitBlock` -`splitBlock(depth: Number) => Transform` +`splitBlock(depth: Number) => Change` Split the [`Block`](./block.md) in the current selection by `depth` levels. If the selection is expanded, it will be deleted first. `depth` defaults to `1`. ### `splitInline` -`splitInline(depth: Number) => Transform` +`splitInline(depth: Number) => Change` Split the [`Inline`](./inline.md) node in the current selection by `depth` levels. If the selection is expanded, it will be deleted first. `depth` defaults to `Infinity`. ### `removeMark` -`removeMark(mark: Mark) => Transform`
-`removeMark(properties: Object) => Transform`
-`removeMark(type: String) => Transform` +`removeMark(mark: Mark) => Change`
+`removeMark(properties: Object) => Change`
+`removeMark(type: String) => Change` Remove a [`mark`](./mark.md) from the characters in the current selection. For convenience, you can pass a `type` string or `properties` object to implicitly create a [`Mark`](./mark.md) of that type. ### `toggleMark` -`toggleMark(mark: Mark) => Transform`
-`toggleMark(properties: Object) => Transform`
-`toggleMark(type: String) => Transform` +`toggleMark(mark: Mark) => Change`
+`toggleMark(properties: Object) => Change`
+`toggleMark(type: String) => Change` Add or remove a [`mark`](./mark.md) from the characters in the current selection, depending on it already exists on any or not. For convenience, you can pass a `type` string or `properties` object to implicitly create a [`Mark`](./mark.md) of that type. ### `unwrapBlock` -`unwrapBlock([type: String], [data: Data]) => Transform` +`unwrapBlock([type: String], [data: Data]) => Change` Unwrap all [`Block`](./block.md) nodes in the current selection that match a `type` and/or `data`. ### `unwrapInline` -`unwrapInline([type: String], [data: Data]) => Transform` +`unwrapInline([type: String], [data: Data]) => Change` Unwrap all [`Inline`](./inline.md) nodes in the current selection that match a `type` and/or `data`. ### `wrapBlock` -`wrapBlock(type: String, [data: Data]) => Transform` +`wrapBlock(type: String, [data: Data]) => Change` Wrap the [`Block`](./block.md) nodes in the current selection with a new [`Block`](./block.md) node of `type`, with optional `data`. ### `wrapInline` -`wrapInline(type: String, [data: Data]) => Transform` +`wrapInline(type: String, [data: Data]) => Change` Wrap the [`Inline`](./inline.md) nodes in the current selection with a new [`Inline`](./inline.md) node of `type`, with optional `data`. ### `wrapText` -`wrapText(prefix: String, [suffix: String]) => Transform` +`wrapText(prefix: String, [suffix: String]) => Change` Surround the text in the current selection with `prefix` and `suffix` strings. If the `suffix` is ommitted, the `prefix` will be used instead. -## Selection Transforms +## Selection Changes ### `blur` -`blur() => Transform` +`blur() => Change` Blur the current selection. ### `collapseTo{Edge}` -`collapseTo{Edge}() => Transform` +`collapseTo{Edge}() => Change` Collapse the current selection to its `{Edge}`. Where `{Edge}` is either `Anchor`, `Focus`, `Start` or `End`. ### `collapseTo{Edge}Of` -`collapseTo{Edge}Of(node: Node) => Transform` +`collapseTo{Edge}Of(node: Node) => Change` Collapse the current selection to the `{Edge}` of `node`. Where `{Edge}` is either `Start` or `End`. ### `collapseTo{Edge}Of{Direction}Block` -`collapseTo{Edge}Of{Direction}Block() => Transform` +`collapseTo{Edge}Of{Direction}Block() => Change` Collapse the current selection to the `{Edge}` of the next [`Block`](./block.md) node in `{Direction}`. Where `{Edge}` is either `{Start}` or `{End}` and `{Direction}` is either `Next` or `Previous`. ### `collapseTo{Edge}Of{Direction}Text` -`collapseTo{Edge}Of{Direction}Text() => Transform` +`collapseTo{Edge}Of{Direction}Text() => Change` Collapse the current selection to the `{Edge}` of the next [`Text`](./text.md) node in `{Direction}`. Where `{Edge}` is either `{Start}` or `{End}` and `{Direction}` is either `Next` or `Previous`. ### `extend` -`extend(n: Number) => Transform` +`extend(n: Number) => Change` Extend the current selection's points by `n` characters. `n` can be positive or negative to indicate direction. ### `extendTo{Edge}Of` -`extendTo{Edge}Of(node: Node) => Transform` +`extendTo{Edge}Of(node: Node) => Change` Extend the current selection to the `{Edge}` of a `node`. Where `{Edge}` is either `Start` or `End`. ### `flip` -`flip() => Transform` +`flip() => Change` Flip the selection. ### `focus` -`focus() => Transform` +`focus() => Change` Focus the current selection. ### `move` -`move(n: Number) => Transform` +`move(n: Number) => Change` Move the current selection's offsets by `n`. ### `move{Edge}` -`move{Edge}(n: Number) => Transform` +`move{Edge}(n: Number) => Change` Move the current selection's `edge` offset by `n`. `edge` can be one of `Start`, `End`. ### `moveOffsetsTo` -`moveOffsetsTo(anchorOffset: Number, focusOffset: Number) => Transform` +`moveOffsetsTo(anchorOffset: Number, focusOffset: Number) => Change` Move the current selection's offsets to a new `anchorOffset` and `focusOffset`. ### `moveToRangeOf` -`moveToRangeOf(node: Node) => Transform` +`moveToRangeOf(node: Node) => Change` Move the current selection's anchor point to the start of a `node` and its focus point to the end of the `node`. ### `select` -`select(properties: Selection || Object) => Transform` +`select(properties: Selection || Object) => Change` Set the current selection to a selection with merged `properties`. The `properties` can either be a [`Selection`](./selection.md) object or a plain Javascript object of selection properties. ### `selectAll` -`selectAll() => Transform` +`selectAll() => Change` Select the entire document and focus the selection. ### `deselect` -`deselect() => Transform` +`deselect() => Change` Unset the selection. -## Node Transforms +## Node Changes ### `addMarkByKey` -`addMarkByKey(key: String, offset: Number, length: Number, mark: Mark) => Transform` +`addMarkByKey(key: String, offset: Number, length: Number, mark: Mark) => Change` Add a `mark` to `length` characters starting at an `offset` in a [`Node`](./node.md) by its `key`. ### `insertNodeByKey` -`insertNodeByKey(key: String, index: Number, node: Node) => Transform` +`insertNodeByKey(key: String, index: Number, node: Node) => Change` Insert a `node` at `index` inside a parent [`Node`](./node.md) by its `key`. @@ -339,196 +337,196 @@ Insert a `node` at `index` inside a parent [`Node`](./node.md) by its `key`. Insert a [`Fragment`](./fragment.md) at `index` inside a parent [`Node`](./node.md) by its `key`. ### `insertTextByKey` -`insertTextByKey(key: String, offset: Number, text: String, [marks: Set]) => Transform` +`insertTextByKey(key: String, offset: Number, text: String, [marks: Set]) => Change` Insert `text` at an `offset` in a [`Text Node`](./text.md) with optional `marks`. ### `moveNodeByKey` -`moveNodeByKey(key: String, newKey: String, newIndex: Number) => Transform` +`moveNodeByKey(key: String, newKey: String, newIndex: Number) => Change` Move a [`Node`](./node.md) by its `key` to a new parent node with its `newKey` and at a `newIndex`. ### `removeMarkByKey` -`removeMarkByKey(key: String, offset: Number, length: Number, mark: Mark) => Transform` +`removeMarkByKey(key: String, offset: Number, length: Number, mark: Mark) => Change` Remove a `mark` from `length` characters starting at an `offset` in a [`Node`](./node.md) by its `key`. ### `removeNodeByKey` -`removeNodeByKey(key: String) => Transform` +`removeNodeByKey(key: String) => Change` Remove a [`Node`](./node.md) from the document by its `key`. ### `removeTextByKey` -`removeTextByKey(key: String, offset: Number, length: Number) => Transform` +`removeTextByKey(key: String, offset: Number, length: Number) => Change` Remove `length` characters of text starting at an `offset` in a [`Node`](./node.md) by its `key`. ### `setMarkByKey` -`setMarkByKey(key: String, offset: Number, length: Number, mark: Mark, properties: Object) => Transform` +`setMarkByKey(key: String, offset: Number, length: Number, mark: Mark, properties: Object) => Change` Set a dictionary of `properties` on a [`mark`](./mark.md) on a [`Node`](./node.md) by its `key`. ### `setNodeByKey` -`setNodeByKey(key: String, properties: Object) => Transform`
-`setNodeByKey(key: String, type: String) => Transform` +`setNodeByKey(key: String, properties: Object) => Change`
+`setNodeByKey(key: String, type: String) => Change` Set a dictionary of `properties` on a [`Node`](./node.md) by its `key`. For convenience, you can pass a `type` string or `properties` object. ### `splitNodeByKey` -`splitNodeByKey(key: String, offset: Number) => Transform` +`splitNodeByKey(key: String, offset: Number) => Change` Split a node by its `key` at an `offset`. ### `unwrapInlineByKey` -`unwrapInlineByKey(key: String, properties: Object) => Transform`
-`unwrapInlineByKey(key: String, type: String) => Transform` +`unwrapInlineByKey(key: String, properties: Object) => Change`
+`unwrapInlineByKey(key: String, type: String) => Change` Unwrap all inner content of an [`Inline`](./inline.md) node that match `properties`. For convenience, you can pass a `type` string or `properties` object. ### `unwrapBlockByKey` -`unwrapBlockByKey(key: String, properties: Object) => Transform`
-`unwrapBlockByKey(key: String, type: String) => Transform` +`unwrapBlockByKey(key: String, properties: Object) => Change`
+`unwrapBlockByKey(key: String, type: String) => Change` Unwrap all inner content of a [`Block`](./block.md) node that match `properties`. For convenience, you can pass a `type` string or `properties` object. ### `unwrapNodeByKey` -`unwrapNodeByKey(key: String) => Transform` +`unwrapNodeByKey(key: String) => Change` Unwrap a single node from its parent. If the node is surrounded with siblings, its parent will be split. If the node is the only child, the parent is removed, and simply replaced by the node itself. Cannot unwrap a root node. ### `wrapBlockByKey` -`wrapBlockByKey(key: String, properties: Object) => Transform`
-`wrapBlockByKey(key: String, type: String) => Transform` +`wrapBlockByKey(key: String, properties: Object) => Change`
+`wrapBlockByKey(key: String, type: String) => Change` Wrap the given node in a [`Block`](./block.md) node that match `properties`. For convenience, you can pass a `type` string or `properties` object. ### `wrapInlineByKey` -`wrapInlineByKey(key: String, properties: Object) => Transform`
-`wrapInlineByKey(key: String, type: String) => Transform` +`wrapInlineByKey(key: String, properties: Object) => Change`
+`wrapInlineByKey(key: String, type: String) => Change` Wrap the given node in a [`Inline`](./inline.md) node that match `properties`. For convenience, you can pass a `type` string or `properties` object. -## Document Transforms +## Document Changes ### `deleteBackwardAtRange` -`deleteBackwardAtRange(range: Selection, n: Number) => Transform` +`deleteBackwardAtRange(range: Selection, n: Number) => Change` Delete backward `n` characters at a `range`. If the `range` is expanded, this method is equivalent to a regular [`delete()`](#delete). `n` defaults to `1`. ### `deleteForwardAtRange` -`deleteForwardAtRange(range: Selection, n: Number) => Transform` +`deleteForwardAtRange(range: Selection, n: Number) => Change` Delete forward `n` characters at a `range`. If the `range` is expanded, this method is equivalent to a regular [`delete()`](#delete). `n` defaults to `1`. ### `deleteAtRange` -`deleteAtRange(range: Selection, ) => Transform` +`deleteAtRange(range: Selection, ) => Change` Delete everything in a `range`. ### `insertBlockAtRange` -`insertBlockAtRange(range: Selection, block: Block) => Transform`
-`insertBlockAtRange(range: Selection, properties: Object) => Transform`
-`insertBlockAtRange(range: Selection, type: String) => Transform` +`insertBlockAtRange(range: Selection, block: Block) => Change`
+`insertBlockAtRange(range: Selection, properties: Object) => Change`
+`insertBlockAtRange(range: Selection, type: String) => Change` Insert a new block at the same level as the leaf block at a `range`, splitting the current block to make room if it is non-empty. If the selection is expanded, it will be deleted first. ### `insertFragmentAtRange` -`insertFragmentAtRange(range: Selection, fragment: Document) => Transform` +`insertFragmentAtRange(range: Selection, fragment: Document) => Change` Insert a [`fragment`](./document.md) at a `range`. If the selection is expanded, it will be deleted first. ### `insertInlineAtRange` -`insertInlineAtRange(range: Selection, inline: Inline) => Transform`
-`insertInlineAtRange(range: Selection, properties: Object) => Transform` +`insertInlineAtRange(range: Selection, inline: Inline) => Change`
+`insertInlineAtRange(range: Selection, properties: Object) => Change` Insert a new inline at a `range`, splitting the text to make room if it is non-empty. If the selection is expanded, it will be deleted first. ### `insertTextAtRange` -`insertTextAtRange(range: Selection, text: String) => Transform` +`insertTextAtRange(range: Selection, text: String) => Change` Insert a string of `text` at a `range`. If the selection is expanded, it will be deleted first. ### `addMarkAtRange` -`addMarkAtRange(range: Selection, mark: Mark) => Transform`
-`addMarkAtRange(range: Selection, properties: Object) => Transform`
-`addMarkAtRange(range: Selection, type: String) => Transform` +`addMarkAtRange(range: Selection, mark: Mark) => Change`
+`addMarkAtRange(range: Selection, properties: Object) => Change`
+`addMarkAtRange(range: Selection, type: String) => Change` Add a [`mark`](./mark.md) to the characters in a `range`. For convenience, you can pass a `type` string or `properties` object to implicitly create a [`Mark`](./mark.md) of that type. ### `setBlockAtRange` -`setBlockAtRange(range: Selection, properties: Object) => Transform`
-`setBlock(range: Selection, type: String) => Transform` +`setBlockAtRange(range: Selection, properties: Object) => Change`
+`setBlock(range: Selection, type: String) => Change` Set the `properties` of the [`Block`](./block.md) in a `range`. For convenience, you can pass a `type` string to set the blocks's type only. ### `setInlineAtRange` -`setInlineAtRange(range: Selection, properties: Object) => Transform`
-`setInline(range: Selection, type: String) => Transform` +`setInlineAtRange(range: Selection, properties: Object) => Change`
+`setInline(range: Selection, type: String) => Change` Set the `properties` of the [`Inline`](./inline.md) nodes in a `range`. For convenience, you can pass a `type` string to set the inline's type only. ### `splitBlockAtRange` -`splitBlockAtRange(range: Selection, depth: Number) => Transform` +`splitBlockAtRange(range: Selection, depth: Number) => Change` Split the [`Block`](./block.md) in a `range` by `depth` levels. If the selection is expanded, it will be deleted first. `depth` defaults to `1`. ### `splitInlineAtRange` -`splitInlineAtRange(range: Selection, depth: Number) => Transform` +`splitInlineAtRange(range: Selection, depth: Number) => Change` Split the [`Inline`](./inline.md) node in a `range` by `depth` levels. If the selection is expanded, it will be deleted first. `depth` defaults to `Infinity`. ### `removeMarkAtRange` -`removeMarkAtRange(range: Selection, mark: Mark) => Transform`
-`removeMarkAtRange(range: Selection, properties: Object) => Transform`
-`removeMarkAtRange(range: Selection, type: String) => Transform` +`removeMarkAtRange(range: Selection, mark: Mark) => Change`
+`removeMarkAtRange(range: Selection, properties: Object) => Change`
+`removeMarkAtRange(range: Selection, type: String) => Change` Remove a [`mark`](./mark.md) from the characters in a `range`. For convenience, you can pass a `type` string or `properties` object to implicitly create a [`Mark`](./mark.md) of that type. ### `toggleMarkAtRange` -`toggleMarkAtRange(range: Selection, mark: Mark) => Transform`
-`toggleMarkAtRange(range: Selection, properties: Object) => Transform`
-`toggleMarkAtRange(range: Selection, type: String) => Transform` +`toggleMarkAtRange(range: Selection, mark: Mark) => Change`
+`toggleMarkAtRange(range: Selection, properties: Object) => Change`
+`toggleMarkAtRange(range: Selection, type: String) => Change` Add or remove a [`mark`](./mark.md) from the characters in a `range`, depending on whether any of them already have the mark. For convenience, you can pass a `type` string or `properties` object to implicitly create a [`Mark`](./mark.md) of that type. ### `unwrapBlockAtRange` -`unwrapBlockAtRange(range: Selection, properties: Object) => Transform`
-`unwrapBlockAtRange(range: Selection, type: String) => Transform` +`unwrapBlockAtRange(range: Selection, properties: Object) => Change`
+`unwrapBlockAtRange(range: Selection, type: String) => Change` Unwrap all [`Block`](./block.md) nodes in a `range` that match `properties`. For convenience, you can pass a `type` string or `properties` object. ### `unwrapInlineAtRange` -`unwrapInlineAtRange(range: Selection, properties: Object) => Transform`
-`unwrapInlineAtRange(range: Selection, type: String) => Transform` +`unwrapInlineAtRange(range: Selection, properties: Object) => Change`
+`unwrapInlineAtRange(range: Selection, type: String) => Change` Unwrap all [`Inline`](./inline.md) nodes in a `range` that match `properties`. For convenience, you can pass a `type` string or `properties` object. ### `wrapBlockAtRange` -`wrapBlockAtRange(range: Selection, properties: Object) => Transform`
-`wrapBlockAtRange(range: Selection, type: String) => Transform` +`wrapBlockAtRange(range: Selection, properties: Object) => Change`
+`wrapBlockAtRange(range: Selection, type: String) => Change` Wrap the [`Block`](./block.md) nodes in a `range` with a new [`Block`](./block.md) node with `properties`. For convenience, you can pass a `type` string or `properties` object. ### `wrapInlineAtRange` -`wrapInlineAtRange(range: Selection, properties: Object) => Transform`
-`wrapInlineAtRange(range: Selection, type: String) => Transform` +`wrapInlineAtRange(range: Selection, properties: Object) => Change`
+`wrapInlineAtRange(range: Selection, type: String) => Change` Wrap the [`Inline`](./inline.md) nodes in a `range` with a new [`Inline`](./inline.md) node with `properties`. For convenience, you can pass a `type` string or `properties` object. ### `wrapTextAtRange` -`wrapTextAtRange(range: Selection, prefix: String, [suffix: String]) => Transform` +`wrapTextAtRange(range: Selection, prefix: String, [suffix: String]) => Change` Surround the text in a `range` with `prefix` and `suffix` strings. If the `suffix` is ommitted, the `prefix` will be used instead. -## History Transforms +## History Changes ### `redo` -`redo() => Transform` +`redo() => Change` Move forward one step in the history. ### `undo` -`undo() => Transform` +`undo() => Change` Move backward one step in the history. diff --git a/docs/reference/plugins/plugin.md b/docs/reference/plugins/plugin.md index 77ccf3541..34b9815ba 100644 --- a/docs/reference/plugins/plugin.md +++ b/docs/reference/plugins/plugin.md @@ -5,7 +5,7 @@ Plugins can be attached to an editor to alter its behavior in different ways. Pl Each editor has a "middleware stack" of plugins, which has a specific order. -When the editor needs to resolve a plugin-related handler, it will loop through its plugin stack, searching for the first plugin that successfully returns a value. After receiving that value, the editor will **not** continue to search the remaining plugins; it returns early. +When the editor needs to resolve a plugin-related handler, it will loop through its plugin stack, searching for the first plugin that successfully returns a value. After receiving that value, the editor will **not** continue to search the remaining plugins; it returns early. If you'd like for the stack to continue, a plugin handler should return `undefined`. - [Conventions](#conventions) - [Event Handler Properties](#event-handle-properties) @@ -65,21 +65,17 @@ Each event handler can choose to return a new `state` object, in which case the This handler is called right before a string of text is inserted into the `contenteditable` element. -Make sure to `event.preventDefault()` (and return `state`) if you do not want the default insertion behavior to occur! If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). +Make sure to `event.preventDefault()` if you do not want the default insertion behavior to occur! If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). ### `onBlur` `Function onBlur(event: Event, data: Object, state: State, editor: Editor) => State || Void` -This handler is called when the editor's `contenteditable` element is blurred. - -If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). +This handler is called when the editor's `contenteditable` element is blurred. If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). ### `onFocus` `Function onFocus(event: Event, data: Object, state: State, editor: Editor) => State || Void` -This handler is called when the editor's `contenteditable` element is focused. - -If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). +This handler is called when the editor's `contenteditable` element is focused. If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). ### `onCopy` `Function onCopy(event: Event, data: Object, state: State, editor: Editor) => State || Void` @@ -100,9 +96,7 @@ If no other plugin handles this event, it will be handled by the [Core plugin](. ### `onCut` `Function onCut(event: Event, data: Object, state: State, editor: Editor) => State || Void` -This handler is equivalent to the `onCopy` handler. - -If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). +This handler is equivalent to the `onCopy` handler. If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). ### `onDrop` `Function onDrop(event: Event, data: Object, state: State, editor: Editor) => State || Void` @@ -163,7 +157,7 @@ The `isModAlt` boolean is `true` if the `control` key was pressed on Windows or The `isLine` and `isWord` booleans represent whether the "line modifier" or "word modifier" hotkeys are pressed when deleting or moving the cursor. For example, on a Mac `option + right` moves the cursor to the right one word at a time. -Make sure to `event.preventDefault()` (and return `state`) if you do not want the default insertion behavior to occur! If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). +Make sure to `event.preventDefault()` if you do not want the default insertion behavior to occur! If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). ### `onKeyUp` `Function onKeUp(event: Event, data: Object, state: State, editor: Editor) => State || Void` @@ -208,7 +202,7 @@ The `data` object contains a State [`Selection`](../models/selection.md) object If no other plugin handles this event, it will be handled by the [Core plugin](./core.md). -_Note: This is **not** Slate's internal selection representation (although it mirrors it). If you want to get notified when Slate's selection changes, use the [`onSelectionChange`](../components/editor.md#onselectionchange) property of the ``. This handler is instead meant to give you lower-level access to the DOM selection handling._ +_Note: This is **not** Slate's internal selection representation (although it mirrors it). If you want to get notified when Slate's selection changes, use the [`onSelectionChange`](../components/editor.md#onselectionchange) property of the ``. This handler is instead meant to give you lower-level access to the DOM selection handling, which **is not always triggered** as you'd expect._ ## Other Properties @@ -220,20 +214,14 @@ _Note: This is **not** Slate's internal selection representation (although it mi ``` ### `onChange` -`Function onChange(state: State) => State || Void` +`Function onChange(change: Change) => Any || Void` -The `onChange` handler isn't a native browser event handler. Instead, it is invoked whenever the editor state changes. Returning a new state will update the editor's state, continuing down the plugin stack. - -Unlike the native event handlers, results from the `onChange` handler **are cumulative**! This means that every plugin in the stack that defines an `onChange` handler will have its handler resolved for every change the editor makes; the editor will not return early after the first plugin's handler is called. - -This allows you to stack up changes across the entire plugin stack. +The `onChange` handler isn't a native browser event handler. Instead, it is invoked whenever the editor state changes. This allows plugins to augment a change however they want. ### `onBeforeChange` `Function onBeforeChange(state: State) => State || Void` -The `onBeforeChange` handler isn't a native browser event handler. Instead, it is invoked whenever the editor receives a new state and before propagating a new state to `onChange`. Returning a new state will update the editor's state before rendering, continuing down the plugin stack. - -Like `onChange`, `onBeforeChange` is cumulative. +The `onBeforeChange` handler isn't a native browser event handler. Instead, it is invoked whenever the editor receives a new state and before propagating a new state to `onChange`. ### `render` `Function render(props: Object, state: State, editor: Editor) => Object || Void` diff --git a/docs/walkthroughs/adding-event-handlers.md b/docs/walkthroughs/adding-event-handlers.md index b26557c1b..1eed56c7f 100644 --- a/docs/walkthroughs/adding-event-handlers.md +++ b/docs/walkthroughs/adding-event-handlers.md @@ -91,9 +91,9 @@ class App extends React.Component { // Prevent the ampersand character from being inserted. event.preventDefault() - // Transform the state by inserting "and" at the cursor's position. + // Change the state by inserting "and" at the cursor's position. const newState = state - .transform() + .change() .insertText('and') .apply() diff --git a/docs/walkthroughs/applying-custom-formatting.md b/docs/walkthroughs/applying-custom-formatting.md index 868bfb2b5..93684fdee 100644 --- a/docs/walkthroughs/applying-custom-formatting.md +++ b/docs/walkthroughs/applying-custom-formatting.md @@ -33,7 +33,7 @@ class App extends React.Component { const isCode = state.blocks.some(block => block.type == 'code') return state - .transform() + .change() .setBlock(isCode ? 'paragraph' : 'code') .apply() } @@ -79,7 +79,7 @@ class App extends React.Component { case 66: { event.preventDefault() return state - .transform() + .change() .addMark('bold') .apply() } @@ -89,7 +89,7 @@ class App extends React.Component { const isCode = state.blocks.some(block => block.type == 'code') event.preventDefault() return state - .transform() + .change() .setBlock(isCode ? 'paragraph' : 'code') .apply() } @@ -158,7 +158,7 @@ class App extends React.Component { case 66: { event.preventDefault() return state - .transform() + .change() .toggleMark('bold') .apply() } @@ -167,7 +167,7 @@ class App extends React.Component { const isCode = state.blocks.some(block => block.type == 'code') event.preventDefault() return state - .transform() + .change() .setBlock(isCode ? 'paragraph' : 'code') .apply() } diff --git a/docs/walkthroughs/defining-custom-block-nodes.md b/docs/walkthroughs/defining-custom-block-nodes.md index 35fa4706b..5e3124748 100644 --- a/docs/walkthroughs/defining-custom-block-nodes.md +++ b/docs/walkthroughs/defining-custom-block-nodes.md @@ -28,7 +28,7 @@ class App extends React.Component { event.preventDefault() const newState = state - .transform() + .change() .insertText('and') .apply() @@ -96,7 +96,7 @@ class App extends React.Component { event.preventDefault() const newState = state - .transform() + .change() .insertText('and') .apply() @@ -149,7 +149,7 @@ class App extends React.Component { // Otherwise, set the currently selected blocks type to "code". return state - .transform() + .change() .setBlock('code') .apply() } @@ -202,7 +202,7 @@ class App extends React.Component { // Toggle the block type depending on `isCode`. return state - .transform() + .change() .setBlock(isCode ? 'paragraph' : 'code') .apply() diff --git a/docs/walkthroughs/using-plugins.md b/docs/walkthroughs/using-plugins.md index fce27239f..0665d539d 100644 --- a/docs/walkthroughs/using-plugins.md +++ b/docs/walkthroughs/using-plugins.md @@ -33,7 +33,7 @@ class App extends React.Component { if (!event.metaKey || event.which != 66) return event.preventDefault() return state - .transform() + .change() .toggleMark('bold') .apply() } @@ -82,7 +82,7 @@ function MarkHotkey(options) { // Toggle the mark `type`. return state - .transform() + .change() .toggleMark(type) .apply() } @@ -220,7 +220,7 @@ function MarkHotkey(options) { if (!event.metaKey || keycode(event.which) != key || event.altKey != isAltKey) return event.preventDefault() return state - .transform() + .change() .toggleMark(type) .apply() } diff --git a/examples/check-lists/index.js b/examples/check-lists/index.js index 34524e42f..a68d0b6dd 100644 --- a/examples/check-lists/index.js +++ b/examples/check-lists/index.js @@ -20,13 +20,7 @@ class CheckListItem extends React.Component { onChange = (e) => { const checked = e.target.checked const { editor, node } = this.props - const state = editor - .getState() - .transform() - .setNodeByKey(node.key, { data: { checked }}) - .apply() - - editor.onChange(state) + editor.change(c => c.setNodeByKey(node.key, { data: { checked }})) } /** @@ -41,7 +35,7 @@ class CheckListItem extends React.Component { const checked = node.data.get('checked') return (
@@ -94,10 +88,10 @@ class CheckLists extends React.Component { /** * On change, save the new state. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -112,20 +106,20 @@ class CheckLists extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change * @return {State|Void} */ - onKeyDown = (e, data, state) => { + onKeyDown = (e, data, change) => { + const { state } = change + if ( data.key == 'enter' && state.startBlock.type == 'check-list-item' ) { - return state - .transform() + return change .splitBlock() .setBlock({ data: { checked: false }}) - .apply() } if ( @@ -134,10 +128,8 @@ class CheckLists extends React.Component { state.startBlock.type == 'check-list-item' && state.selection.startOffset == 0 ) { - return state - .transform() + return change .setBlock('paragraph') - .apply() } } diff --git a/examples/code-highlighting/index.js b/examples/code-highlighting/index.js index 244c30e74..160655931 100644 --- a/examples/code-highlighting/index.js +++ b/examples/code-highlighting/index.js @@ -16,16 +16,7 @@ function CodeBlock(props) { const language = node.data.get('language') function onChange(e) { - const state = editor.getState() - const next = state - .transform() - .setNodeByKey(node.key, { - data: { - language: e.target.value - } - }) - .apply() - editor.onChange(next) + editor.change(c => c.setNodeByKey(node.key, { data: { language: e.target.value }})) } return ( @@ -128,15 +119,15 @@ class CodeHighlighting extends React.Component { state = { state: Raw.deserialize(initialState, { terse: true }) - }; + } /** * On change, save the new state. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -145,20 +136,17 @@ class CodeHighlighting extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state - * @return {State} + * @param {Change} change + * @return {Change} */ - onKeyDown = (e, data, state) => { - if (data.key != 'enter') return + onKeyDown = (e, data, change) => { + const { state } = change const { startBlock } = state + if (data.key != 'enter') return if (startBlock.type != 'code') return - - const transform = state.transform() - if (state.isExpanded) transform.delete() - transform.insertText('\n') - - return transform.apply() + if (state.isExpanded) change.delete() + return change.insertText('\n') } /** diff --git a/examples/dev/large-document/index.js b/examples/dev/large-document/index.js index cfc939dec..a34f6a55b 100644 --- a/examples/dev/large-document/index.js +++ b/examples/dev/large-document/index.js @@ -79,10 +79,10 @@ class LargeDocument extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -91,11 +91,10 @@ class LargeDocument extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state - * @return {State} + * @param {Change} change */ - onKeyDown = (e, data, state) => { + onKeyDown = (e, data, change) => { if (!data.isMod) return let mark @@ -116,13 +115,9 @@ class LargeDocument extends React.Component { return } - state = state - .transform() - .toggleMark(mark) - .apply() - e.preventDefault() - return state + change.toggleMark(mark) + return true } /** diff --git a/examples/dev/performance-plain/index.js b/examples/dev/performance-plain/index.js index 4a0fe5f24..a90e7c972 100644 --- a/examples/dev/performance-plain/index.js +++ b/examples/dev/performance-plain/index.js @@ -24,10 +24,10 @@ class PlainText extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } diff --git a/examples/dev/performance-rich/index.js b/examples/dev/performance-rich/index.js index 026f24a3a..4f43f8d3a 100644 --- a/examples/dev/performance-rich/index.js +++ b/examples/dev/performance-rich/index.js @@ -88,10 +88,10 @@ class RichText extends React.Component { /** * On change, save the new state. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -100,11 +100,11 @@ class RichText extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change * @return {State} */ - onKeyDown = (e, data, state) => { + onKeyDown = (e, data, change) => { if (!data.isMod) return let mark @@ -125,13 +125,9 @@ class RichText extends React.Component { return } - state = state - .transform() - [this.hasMark(mark) ? 'removeMark' : 'addMark'](mark) - .apply() - + change[this.hasMark(mark) ? 'removeMark' : 'addMark'](mark) e.preventDefault() - return state + return true } /** @@ -144,14 +140,12 @@ class RichText extends React.Component { onClickMark = (e, type) => { e.preventDefault() const isActive = this.hasMark(type) - let { state } = this.state - - state = state - .transform() + const change = this.state.state + .change() [isActive ? 'removeMark' : 'addMark'](type) .apply() - this.setState({ state }) + this.onChange(change) } /** @@ -164,20 +158,18 @@ class RichText extends React.Component { onClickBlock = (e, type) => { e.preventDefault() const isActive = this.hasBlock(type) - let { state } = this.state - - const transform = state - .transform() + const change = this.state.state + .change() .setBlock(isActive ? 'paragraph' : type) // Handle the extra wrapping required for list buttons. if (type == 'bulleted-list' || type == 'numbered-list') { if (this.hasBlock('list-item')) { - transform + change .setBlock(DEFAULT_NODE) .unwrapBlock(type) } else { - transform + change .setBlock('list-item') .wrapBlock(type) } @@ -185,11 +177,10 @@ class RichText extends React.Component { // Handle everything but list buttons. else { - transform.setBlock(isActive ? DEFAULT_NODE : type) + change.setBlock(isActive ? DEFAULT_NODE : type) } - state = transform.apply() - this.setState({ state }) + this.onChange(change) } /** diff --git a/examples/embeds/index.js b/examples/embeds/index.js index cad129c8c..31a17169b 100644 --- a/examples/embeds/index.js +++ b/examples/embeds/index.js @@ -32,15 +32,15 @@ class Embeds extends React.Component { state = { state: Raw.deserialize(initialState, { terse: true }) - }; + } /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } diff --git a/examples/embeds/video.js b/examples/embeds/video.js index 2f5ac9231..1ef464667 100644 --- a/examples/embeds/video.js +++ b/examples/embeds/video.js @@ -30,17 +30,7 @@ class Video extends React.Component { onChange = (e) => { const video = e.target.value const { node, editor } = this.props - const properties = { - data: { video } - } - - const next = editor - .getState() - .transform() - .setNodeByKey(node.key, properties) - .apply() - - editor.onChange(next) + editor.transform(t => t.setNodeByKey(node.key, { data: { video }})) } /** diff --git a/examples/emojis/index.js b/examples/emojis/index.js index a97468659..6c5270329 100644 --- a/examples/emojis/index.js +++ b/examples/emojis/index.js @@ -3,10 +3,17 @@ import { Editor, Raw } from '../..' import React from 'react' import initialState from './state.json' -const EMOJIS = [ - '😃', '😬', '😂', '😅', '😆', '😍', '😱', '👋', '👏', '👍', '🙌', '👌', '🙏', '👻', '🍔', '🍑', '🍆', '🔑' -] +/** + * Emojis. + * + * @type {Array} + */ +const EMOJIS = [ + '😃', '😬', '😂', '😅', '😆', '😍', + '😱', '👋', '👏', '👍', '🙌', '👌', + '🙏', '👻', '🍔', '🍑', '🍆', '🔑', +] /** * Define a schema. @@ -43,15 +50,15 @@ class Emojis extends React.Component { state = { state: Raw.deserialize(initialState, { terse: true }) - }; + } /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -63,18 +70,15 @@ class Emojis extends React.Component { onClickEmoji = (e, code) => { e.preventDefault() - let { state } = this.state - - state = state - .transform() + const change = this.state.state + .change() .insertInline({ type: 'emoji', isVoid: true, data: { code } }) - .apply() - this.setState({ state }) + this.onChange(change) } /** diff --git a/examples/focus-blur/index.js b/examples/focus-blur/index.js index 31973b5af..c7978584e 100644 --- a/examples/focus-blur/index.js +++ b/examples/focus-blur/index.js @@ -36,15 +36,15 @@ class FocusBlur extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } /** - * Apply a focus or blur transform by `name` after a `timeout`. + * Apply a focus or blur change by `name` after a `timeout`. * * @param {String} name * @param {Number} timeout @@ -54,12 +54,11 @@ class FocusBlur extends React.Component { e.preventDefault() setTimeout(() => { - const state = this.state.state - .transform() + const change = this.state.state + .change() [name]() - .apply() - this.setState({ state }) + this.onChange(change) }, timeout) } diff --git a/examples/forced-layout/index.js b/examples/forced-layout/index.js index 03ae61342..5ba63e252 100644 --- a/examples/forced-layout/index.js +++ b/examples/forced-layout/index.js @@ -30,13 +30,13 @@ class ForcedLayout extends React.Component { { match: node => node.kind === 'document', validate: document => !document.nodes.size || document.nodes.first().type !== 'title' ? document.nodes : null, - normalize: (transform, document, nodes) => { + normalize: (change, document, nodes) => { if (!nodes.size) { const title = Block.create({ type: 'title', data: {}}) - return transform.insertNodeByKey(document.key, 0, title) + return change.insertNodeByKey(document.key, 0, title) } - return transform.setNodeByKey(nodes.first().key, 'title') + return change.setNodeByKey(nodes.first().key, 'title') } }, @@ -48,10 +48,10 @@ class ForcedLayout extends React.Component { const invalidChildren = document.nodes.filter((child, index) => child.type === 'title' && index !== 0) return invalidChildren.size ? invalidChildren : null }, - normalize: (transform, document, invalidChildren) => { - let updatedTransform = transform + normalize: (change, document, invalidChildren) => { + let updatedTransform = change invalidChildren.forEach((child) => { - updatedTransform = transform.setNodeByKey(child.key, 'paragraph') + updatedTransform = change.setNodeByKey(child.key, 'paragraph') }) return updatedTransform @@ -63,9 +63,9 @@ class ForcedLayout extends React.Component { { match: node => node.kind === 'document', validate: document => document.nodes.size < 2 ? true : null, - normalize: (transform, document) => { + normalize: (change, document) => { const paragraph = Block.create({ type: 'paragraph', data: {}}) - return transform.insertNodeByKey(document.key, 1, paragraph) + return change.insertNodeByKey(document.key, 1, paragraph) } } ] @@ -75,10 +75,10 @@ class ForcedLayout extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } diff --git a/examples/hovering-menu/index.js b/examples/hovering-menu/index.js index 73ebc62a8..eee57a654 100644 --- a/examples/hovering-menu/index.js +++ b/examples/hovering-menu/index.js @@ -62,12 +62,12 @@ class HoveringMenu extends React.Component { } /** - * On change, save the new state. + * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -80,14 +80,10 @@ class HoveringMenu extends React.Component { onClickMark = (e, type) => { e.preventDefault() - let { state } = this.state - - state = state - .transform() + const change = this.state.state + .change() .toggleMark(type) - .apply() - - this.setState({ state }) + this.onChange(change) } /** diff --git a/examples/iframes/index.js b/examples/iframes/index.js index 1103bf2a4..c3c379665 100644 --- a/examples/iframes/index.js +++ b/examples/iframes/index.js @@ -81,12 +81,12 @@ class Iframes extends React.Component { } /** - * On change, save the new state. + * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -95,11 +95,11 @@ class Iframes extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change * @return {State} */ - onKeyDown = (e, data, state) => { + onKeyDown = (e, data, change) => { if (!data.isMod) return let mark @@ -114,13 +114,8 @@ class Iframes extends React.Component { return } - state = state - .transform() - .toggleMark(mark) - .apply() - e.preventDefault() - return state + return change.toggleMark(mark) } /** @@ -132,14 +127,10 @@ class Iframes extends React.Component { onClickMark = (e, type) => { e.preventDefault() - let { state } = this.state - - state = state - .transform() + const change = this.state.state + .change() .toggleMark(type) - .apply() - - this.setState({ state }) + this.onChange(change) } /** @@ -151,15 +142,11 @@ class Iframes extends React.Component { onClickBlock = (e, type) => { e.preventDefault() - let { state } = this.state const isActive = this.hasBlock(type) - - state = state - .transform() + const change = this.state.state + .change() .setBlock(isActive ? DEFAULT_NODE : type) - .apply() - - this.setState({ state }) + this.onChange(change) } /** diff --git a/examples/images/index.js b/examples/images/index.js index 53262b146..42bb129b4 100644 --- a/examples/images/index.js +++ b/examples/images/index.js @@ -48,9 +48,9 @@ const schema = { validate: (document) => { return document.nodes.size ? null : true }, - normalize: (transform, document) => { + normalize: (change, document) => { const block = Block.create(defaultBlock) - transform.insertNodeByKey(document.key, 0, block) + change.insertNodeByKey(document.key, 0, block) } }, // Rule to insert a paragraph below a void node (the image) if that node is @@ -63,14 +63,34 @@ const schema = { const lastNode = document.nodes.last() return lastNode && lastNode.isVoid ? true : null }, - normalize: (transform, document) => { + normalize: (change, document) => { const block = Block.create(defaultBlock) - transform.insertNodeByKey(document.key, document.nodes.size, block) + change.insertNodeByKey(document.key, document.nodes.size, block) } } ] } +/** + * A change function to standardize inserting images. + * + * @param {Change} change + * @param {String} src + * @param {Selection} target + */ + +function insertImage(change, src, target) { + if (target) { + change.select(target) + } + + change.insertBlock({ + type: 'image', + isVoid: true, + data: { src } + }) +} + /** * The images example. * @@ -143,10 +163,10 @@ class Images extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -160,9 +180,12 @@ class Images extends React.Component { e.preventDefault() const src = window.prompt('Enter the URL of the image:') if (!src) return - let { state } = this.state - state = this.insertImage(state, null, src) - this.onChange(state) + + const change = this.state.state + .change() + .call(insertImage, src) + + this.onChange(change) } /** @@ -170,14 +193,13 @@ class Images extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change * @param {Editor} editor - * @return {State} */ - onDrop = (e, data, state, editor) => { + onDrop = (e, data, change, editor) => { switch (data.type) { - case 'files': return this.onDropOrPasteFiles(e, data, state, editor) + case 'files': return this.onDropOrPasteFiles(e, data, change, editor) } } @@ -186,21 +208,20 @@ class Images extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change * @param {Editor} editor - * @return {State} */ - onDropOrPasteFiles = (e, data, state, editor) => { + onDropOrPasteFiles = (e, data, change, editor) => { for (const file of data.files) { const reader = new FileReader() const [ type ] = file.type.split('/') if (type != 'image') continue reader.addEventListener('load', () => { - state = editor.getState() - state = this.insertImage(state, data.target, reader.result) - editor.onChange(state) + editor.change((t) => { + t.call(insertImage, reader.result, data.target) + }) }) reader.readAsDataURL(file) @@ -212,15 +233,14 @@ class Images extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change * @param {Editor} editor - * @return {State} */ - onPaste = (e, data, state, editor) => { + onPaste = (e, data, change, editor) => { switch (data.type) { - case 'files': return this.onDropOrPasteFiles(e, data, state, editor) - case 'text': return this.onPasteText(e, data, state) + case 'files': return this.onDropOrPasteFiles(e, data, change, editor) + case 'text': return this.onPasteText(e, data, change) } } @@ -229,36 +249,13 @@ class Images extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state - * @return {State} + * @param {Change} change */ - onPasteText = (e, data, state) => { + onPasteText = (e, data, change) => { if (!isUrl(data.text)) return if (!isImage(data.text)) return - return this.insertImage(state, data.target, data.text) - } - - /** - * Insert an image with `src` at the current selection. - * - * @param {State} state - * @param {String} src - * @return {State} - */ - - insertImage = (state, target, src) => { - const transform = state.transform() - - if (target) transform.select(target) - - return transform - .insertBlock({ - type: 'image', - isVoid: true, - data: { src } - }) - .apply() + change.call(insertImage, data.text, data.target) } } diff --git a/examples/index.css b/examples/index.css index 237f32e3f..e347c70a3 100644 --- a/examples/index.css +++ b/examples/index.css @@ -214,6 +214,11 @@ input:focus { align-items: center; } +.check-list-item.checked { + opacity: 0.666; + text-decoration: line-through; +} + .check-list-item > span:first-child { margin-right: 0.75em; } diff --git a/examples/links/index.js b/examples/links/index.js index 2dceb04da..deeba2202 100644 --- a/examples/links/index.js +++ b/examples/links/index.js @@ -21,6 +21,32 @@ const schema = { } } +/** + * A change helper to standardize wrapping links. + * + * @param {Change} change + * @param {String} href + */ + +function wrapLink(change, href) { + change.wrapInline({ + type: 'link', + data: { href } + }) + + change.collapseToEnd() +} + +/** + * A change helper to standardize unwrapping links. + * + * @param {Change} change + */ + +function unwrapLink(change) { + change.unwrapInline('link') +} + /** * The links example. * @@ -53,10 +79,10 @@ class Links extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -69,44 +95,29 @@ class Links extends React.Component { onClickLink = (e) => { e.preventDefault() - let { state } = this.state + const { state } = this.state const hasLinks = this.hasLinks() + const change = state.change() if (hasLinks) { - state = state - .transform() - .unwrapInline('link') - .apply() + change.call(unwrapLink) } else if (state.isExpanded) { const href = window.prompt('Enter the URL of the link:') - state = state - .transform() - .wrapInline({ - type: 'link', - data: { href } - }) - .collapseToEnd() - .apply() + change.call(wrapLink, href) } else { const href = window.prompt('Enter the URL of the link:') const text = window.prompt('Enter the text for the link:') - state = state - .transform() + change .insertText(text) .extend(0 - text.length) - .wrapInline({ - type: 'link', - data: { href } - }) - .collapseToEnd() - .apply() + .call(wrapLink, href) } - this.setState({ state }) + this.onChange(change) } /** @@ -114,29 +125,20 @@ class Links extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change */ - onPaste = (e, data, state) => { - if (state.isCollapsed) return + onPaste = (e, data, change) => { + if (change.state.isCollapsed) return if (data.type != 'text' && data.type != 'html') return if (!isUrl(data.text)) return - const transform = state.transform() - if (this.hasLinks()) { - transform.unwrapInline('link') + change.call(unwrapLink) } - return transform - .wrapInline({ - type: 'link', - data: { - href: data.text - } - }) - .collapseToEnd() - .apply() + change.call(wrapLink, data.text) + return true } /** diff --git a/examples/markdown-preview/index.js b/examples/markdown-preview/index.js index f4d98e68e..db63c4867 100644 --- a/examples/markdown-preview/index.js +++ b/examples/markdown-preview/index.js @@ -140,10 +140,10 @@ class MarkdownPreview extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } diff --git a/examples/markdown-shortcuts/index.js b/examples/markdown-shortcuts/index.js index a549bea18..b70f58ac7 100644 --- a/examples/markdown-shortcuts/index.js +++ b/examples/markdown-shortcuts/index.js @@ -87,10 +87,10 @@ class MarkdownShortcuts extends React.Component { /** * On change. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -99,15 +99,14 @@ class MarkdownShortcuts extends React.Component { * * @param {Event} e * @param {Data} data - * @param {State} state - * @return {State or Null} state + * @param {Change} change */ - onKeyDown = (e, data, state) => { + onKeyDown = (e, data, change) => { switch (data.key) { - case 'space': return this.onSpace(e, state) - case 'backspace': return this.onBackspace(e, state) - case 'enter': return this.onEnter(e, state) + case 'space': return this.onSpace(e, change) + case 'backspace': return this.onBackspace(e, change) + case 'enter': return this.onEnter(e, change) } } @@ -116,12 +115,14 @@ class MarkdownShortcuts extends React.Component { * node into the shortcut's corresponding type. * * @param {Event} e - * @param {State} state + * @param {State} change * @return {State or Null} state */ - onSpace = (e, state) => { + onSpace = (e, change) => { + const { state } = change if (state.isExpanded) return + const { startBlock, startOffset } = state const chars = startBlock.text.slice(0, startOffset).replace(/\s*/g, '') const type = this.getType(chars) @@ -130,18 +131,17 @@ class MarkdownShortcuts extends React.Component { if (type == 'list-item' && startBlock.type == 'list-item') return e.preventDefault() - const transform = state - .transform() - .setBlock(type) + change.setBlock(type) - if (type == 'list-item') transform.wrapBlock('bulleted-list') + if (type == 'list-item') { + change.wrapBlock('bulleted-list') + } - state = transform + change .extendToStartOf(startBlock) .delete() - .apply() - return state + return true } /** @@ -149,26 +149,26 @@ class MarkdownShortcuts extends React.Component { * paragraph node. * * @param {Event} e - * @param {State} state + * @param {State} change * @return {State or Null} state */ - onBackspace = (e, state) => { + onBackspace = (e, change) => { + const { state } = change if (state.isExpanded) return if (state.startOffset != 0) return + const { startBlock } = state - if (startBlock.type == 'paragraph') return + e.preventDefault() + change.setBlock('paragraph') - const transform = state - .transform() - .setBlock('paragraph') + if (startBlock.type == 'list-item') { + change.unwrapBlock('bulleted-list') + } - if (startBlock.type == 'list-item') transform.unwrapBlock('bulleted-list') - - state = transform.apply() - return state + return true } /** @@ -176,15 +176,17 @@ class MarkdownShortcuts extends React.Component { * create a new paragraph below it. * * @param {Event} e - * @param {State} state + * @param {State} change * @return {State or Null} state */ - onEnter = (e, state) => { + onEnter = (e, change) => { + const { state } = change if (state.isExpanded) return + const { startBlock, startOffset, endOffset } = state - if (startOffset == 0 && startBlock.length == 0) return this.onBackspace(e, state) - if (endOffset != startBlock.length) return + if (startOffset == 0 && startBlock.text.length == 0) return this.onBackspace(e, change) + if (endOffset != startBlock.text.length) return if ( startBlock.type != 'heading-one' && @@ -199,11 +201,12 @@ class MarkdownShortcuts extends React.Component { } e.preventDefault() - return state - .transform() + + change .splitBlock() .setBlock('paragraph') - .apply() + + return true } } diff --git a/examples/paste-html/index.js b/examples/paste-html/index.js index 98f3c63f5..96aafa69d 100644 --- a/examples/paste-html/index.js +++ b/examples/paste-html/index.js @@ -161,10 +161,10 @@ class PasteHtml extends React.Component { /** * On change, save the new state. * - * @param {State} state + * @param {Change} change */ - onChange = (state) => { + onChange = ({ state }) => { this.setState({ state }) } @@ -173,19 +173,15 @@ class PasteHtml extends React.Component { * * @param {Event} e * @param {Object} data - * @param {State} state + * @param {Change} change */ - onPaste = (e, data, state) => { + onPaste = (e, data, change) => { if (data.type != 'html') return if (data.isShift) return - const { document } = serializer.deserialize(data.html) - - return state - .transform() - .insertFragment(document) - .apply() + change.insertFragment(document) + return true } /** diff --git a/examples/plain-text/index.js b/examples/plain-text/index.js index 11ab99e40..da0182d16 100644 --- a/examples/plain-text/index.js +++ b/examples/plain-text/index.js @@ -18,15 +18,15 @@ class PlainText extends React.Component { state = { state: Plain.deserialize('This is editable plain text, just like a