Skip to content

Releases

folio for VS Code 0.5.13

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:13
a068188

The folio VS Code extension 0.5.13, built from a068188.

@stll/folio-vue@0.28.1

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:12
a068188

Patch Changes

  • #2506 059c99f Thanks @jan-kubica! - A change the experimental canonical session cannot make yet now shows a translated message from the folio catalog ("This change can't be made here yet.") instead of the session's internal description. canonicalRefusalNotice(ground, translate) no longer takes the session's message: every ground reads a catalog key, and the new editor.changeUnavailable message is in every shipped locale. The session's message stays on the error passed to onError.

  • #2501 fa82c15 Thanks @jan-kubica! - Typing in the experimental canonical session no longer copies the whole document after each edit to bring the header, footer and note editors up to date: they read the session's document, which each edit replaces. A change notification now makes one copy for the host instead of three.

  • #2510 d97919f Thanks @jan-kubica! - Dragging a table's column border, right edge or row border now resizes the table in the experimental canonical session, in React and Vue, instead of being refused. A resize is a command (columnResizeCommand, rightEdgeResizeCommand, rowResizeCommand) that the hosts run through the editor; the session applies it as the grid and row and cell formatting edits it makes, records it as a revision while suggesting, and undoes it.

  • #2465 cbce650 Thanks @jan-kubica! - Comment edits are part of the editor's undo history. Deleting a thread (with its replies and anchors), resolving or reopening it, replying and adding a comment can each be undone and redone, in React and Vue, and the save writes the restored threads. Accepting or rejecting a change that removes everything a comment covers removes the comment with it, in the same undo step, and each accept or reject is an undo step of its own. Comments that document operations add join the editor's threads in the operation's own transaction, so undoing the operation removes them too. With a controlled comments prop, undo and redo report the restored list through onCommentsChange. New in core: @stll/folio-core/prosemirror/commentRecords.

  • #2525 b922b4f Thanks @jan-kubica! - The editor positions a painted element carries are read and written through one module, utils/paintedPositions, and a lint rule keeps every other reader off the attributes. Painted output is unchanged, except that a table cell whose last block has no end position no longer carries the text "undefined" as its end.

  • #2469 018198e Thanks @jan-kubica! - A comment that a pending suggestion proposes is no longer saved on its own. The saved package holds back the suggested text, and now the comment's thread too, so reopening the file no longer shows a card with nothing to point at. Accepting the suggestion saves both. withHostCommentThreads takes the comment ids the editor's document anchors, and leaves out a thread that the editor anchors but the saved document does not.

  • #2515 2fb46d6 Thanks @jan-kubica! - Typing in a canonical Vue editor no longer copies the whole document on every keystroke, and a change notification makes one copy for the host instead of up to six.

  • #2464 b3176d2 Thanks @jan-kubica! - The Vue editor saves the comment threads its sidebar shows: added comments, replies, resolutions and deleted threads now reach the saved document, and getDocument() returns them, as in React. Both editors write their threads through one helper, withHostCommentThreads.

  • #2536 d426a7c Thanks @jan-kubica! - scrollToParaId finds a paragraph on a page that is not painted yet: it looks the paragraph up in the document, scrolls to it, and flashes it once its page is painted, as the React editor does.

  • Updated dependencies [a2afcb1, c850dcd, 348cc23, 46dda37, c850dcd, cb82e3a, bcee67a, 17f7f28, 9fad4c9, c850dcd, 059bb5c, 5679c59, 892aafa, 7924362, 059c99f, 217941f, 49a28c4, aaa7474, 95488ec, bf42917, fa82c15, d97919f, 97b5ca5, a42d8ee, ce6733d, cbce650, 8aba24a, 0b98ce9, 32e7052, ff9b892, 46dd26f, a31cf4c, 038646b, 83eca02, 5e5824b, 97167fc, cdf13e7, 4e28f6b, aa33ac1, 4fef6cc, 9c33010, b922b4f, 018198e, 49dab25, a5c78ac, bb6a653, 2711d93, 0df0787, 3420da1, 50448ad, d8eb0ed, [b6be1b9](https://github.com/stella/folio/commit/b6be1b92...

Read more

@stll/folio-react@0.34.1

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:12
a068188

Patch Changes

  • #2506 059c99f Thanks @jan-kubica! - A change the experimental canonical session cannot make yet now shows a translated message from the folio catalog ("This change can't be made here yet.") instead of the session's internal description. canonicalRefusalNotice(ground, translate) no longer takes the session's message: every ground reads a catalog key, and the new editor.changeUnavailable message is in every shipped locale. The session's message stays on the error passed to onError.

  • #2501 fa82c15 Thanks @jan-kubica! - Typing in the experimental canonical session no longer copies the whole document after each edit to bring the header, footer and note editors up to date: they read the session's document, which each edit replaces. A change notification now makes one copy for the host instead of three.

  • #2510 d97919f Thanks @jan-kubica! - Dragging a table's column border, right edge or row border now resizes the table in the experimental canonical session, in React and Vue, instead of being refused. A resize is a command (columnResizeCommand, rightEdgeResizeCommand, rowResizeCommand) that the hosts run through the editor; the session applies it as the grid and row and cell formatting edits it makes, records it as a revision while suggesting, and undoes it.

  • #2494 a42d8ee Thanks @jan-kubica! - A keystroke in the React editor no longer re-renders the editor to hide the caret while the typed text lays out again: the selection overlay is hidden directly and shown again with the next caret. getFolioCaretViewportRect returns null while the caret is hidden this way, as it did when the caret was cleared.

  • #2465 cbce650 Thanks @jan-kubica! - Comment edits are part of the editor's undo history. Deleting a thread (with its replies and anchors), resolving or reopening it, replying and adding a comment can each be undone and redone, in React and Vue, and the save writes the restored threads. Accepting or rejecting a change that removes everything a comment covers removes the comment with it, in the same undo step, and each accept or reject is an undo step of its own. Comments that document operations add join the editor's threads in the operation's own transaction, so undoing the operation removes them too. With a controlled comments prop, undo and redo report the restored list through onCommentsChange. New in core: @stll/folio-core/prosemirror/commentRecords.

  • #2514 038646b Thanks @jan-kubica! - Typing no longer makes the browser rebuild paint data for the whole hidden editor twice per keystroke: the input anchor that follows the caret removed its transform to measure and set it again, and now measures in place and writes only when its offset changes.

  • #2530 83eca02 Thanks @jan-kubica! - The input method's candidate window stays beside the text being composed. The box that clips the hidden editor is now kept at its scroll origin, so the browser revealing the caret no longer moves the composition away from where it is painted.

  • #2525 b922b4f Thanks @jan-kubica! - The editor positions a painted element carries are read and written through one module, utils/paintedPositions, and a lint rule keeps every other reader off the attributes. Painted output is unchanged, except that a table cell whose last block has no end position no longer carries the text "undefined" as its end.

  • #2469 018198e Thanks @jan-kubica! - A comment that a pending suggestion proposes is no longer saved on its own. The saved package holds back the suggested text, and now the comment's thread too, so reopening the file no longer shows a card with nothing to point at. Accepting the suggestion saves both. withHostCommentThreads takes the comment ids the editor's document anchors, and leaves out a thread that the editor anchors but the saved document does not.

  • #2474 67b4185 Thanks @jan-kubica! - Typing in the React editor commits React updates less often: about 2 commits per keystroke instead of 5 on a long contract. Caret and selection geometry, overlay rectangles, toolbar context and the outline keep the value they hold when a keystroke produces an equal one, so an unchanged value no longer re-renders and commits. Each commit made while the editor has focus reads the editor's whole document structure to save the selection, so fewer commits make typing in long documents faster.

  • #2464 b3176d2 Thanks @jan-kubica! - The Vue editor saves the comment threads its sidebar shows: added comments, replies, resolutions and deleted threads now reach the saved document, and getDocument() returns them, as in React. Both editors write their threads through one helper, withHostCommentThreads.

  • Updated dependencies [a2afcb1, c850dcd, 348cc23, 46dda37, c850dcd, cb82e3a, bcee67a, 17f7f28, 9fad4c9, c850dcd, 059bb5c, 5679c59, 892aafa, 7924362, 059c99f, 217941f, 49a28c4, aaa7474, 95488ec, bf42917, fa82c15, d97919f, 97b5ca5, a42d8ee, ce6733d, cbce650, 8aba24a, 0b98ce9, 32e7052, ff9b892, 46dd26f, a31cf4c, 038646b, 83eca02, 5e5824b, 97167fc, cdf13e7, [4e28f6b](https://...

Read more

@stll/folio-core@0.69.0

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:12
a068188

Minor Changes

  • #2506 059c99f Thanks @jan-kubica! - A change the experimental canonical session cannot make yet now shows a translated message from the folio catalog ("This change can't be made here yet.") instead of the session's internal description. canonicalRefusalNotice(ground, translate) no longer takes the session's message: every ground reads a catalog key, and the new editor.changeUnavailable message is in every shipped locale. The session's message stays on the error passed to onError.

Patch Changes

  • #2484 a2afcb1 Thanks @jan-kubica! - Typing no longer walks every node of the document to check bookmark ranges before each layout; only the parts of the document that hold a bookmark are walked.

  • #2447 c850dcd Thanks @jan-kubica! - A comment on insertAfterBlock, insertBeforeBlock or deleteBlock now applies in the experimental canonical session where the default engine puts it. On an insertion it covers the inserted paragraphs. On a tracked deletion it covers the deleted words. An insertion with no text and a direct deletion skip, as in the default engine.

  • #2449 348cc23 Thanks @jan-kubica! - Tracked block moves now apply in the experimental canonical session. A deleteBlock and an insertAfterBlock or insertBeforeBlock that share a moveId in one batch are recorded as w:moveFrom and w:moveTo, paired as the default engine pairs them, and an unpaired id is reported as unpairedMove. INSERT_BLOCKS and DELETE_BLOCKS take move. A block deletion the following paragraph survives now removes the paragraph by its identity.

  • #2450 46dda37 Thanks @jan-kubica! - A newList numbering request on insertAfterBlock, insertBeforeBlock or setBlockParagraphProperties now applies in the experimental canonical session. It mints a list instance per operation and kind, as the default engine does. The insertParagraphs and formatParagraph editor intents take the new instance and create it first. NewListInstance is exported from @stll/docx-core/ops.

  • #2447 c850dcd Thanks @jan-kubica! - Stated numbering on insertAfterBlock, insertBeforeBlock and setBlockParagraphProperties now applies in the experimental canonical session: a list reference, a level, a cancellation, or inheritance.

  • #2503 cb82e3a Thanks @jan-kubica! - In the experimental canonical session the editor creates its body view when the host syncs, instead of when a header, footer or note editor first reads a story. Reading a story's projection no longer creates the view.

  • #2454 bcee67a Thanks @jan-kubica! - A commented public operation on a paragraph inside a table cell or a block content control now applies in the experimental canonical session. It no longer refuses with "The comment anchor no longer exists." A commented insertion beside such a paragraph now carries its comment too. storyParagraphs is exported from @stll/docx-core/ops.

  • #2527 17f7f28 Thanks @jan-kubica! - Typing in the canonical session applies each keystroke's edit once: the compiled edit hands back what it applied, and the session no longer applies it again.

  • #2532 9fad4c9 Thanks @jan-kubica! - The canonical session's conversion of the main story validates and continues only the top-level blocks an edit changed, keeping what the pass before gave the others, so each keystroke does less work in a long document.

  • #2447 c850dcd Thanks @jan-kubica! - A tracked deleteBlock of a paragraph that a table follows now applies in the experimental canonical session, as the default engine records it: its words and its own mark are marked deleted. DELETE_BLOCKS records this with a revision when the block list still ends with a paragraph. A new deleteParagraphs editor intent compiles to it.

  • #2452 059bb5c Thanks @jan-kubica! - mergeBlockWithNext with a separator or mergedParagraphProperties now applies in the experimental canonical session, as the default engine applies it. A direct merge keeps the first paragraph's identity.

  • #2531 5679c59 Thanks @jan-kubica! - The canonical session maps editor positions to the document from the blocks an edit changed, keeping the addresses of every other block from the projection before it, so the cost of a keystroke no longer grows with every paragraph of a long document.

  • #2479 892aafa Thanks @jan-kubica! - Canonical public operations: an inline insertion reads CRLF and CR as one line break; an insertion beside a paragraph in a table cell goes beside the table; an insertion beside a paragraph the same batch deletes applies when a block follows that paragraph; a move whose other half does not apply saves as a plain insertion or deletion, reported unpaired; an undone insertion's paragraph id is not reused; and an open header, footer or note editor keeps its caret through an operation on its story. A list reference that names no list stays out of lists started later.

  • #2451 7924362 Thanks @jan-kubica! - Public operation batches in the experimental canonical session now apply to headers, footers, footnotes and endnotes, and no longer refuse with publicOps.secondaryStories. A story edit publishes through the same story path that editing and history use. An open editor on that story shows the change, and undo works per story.

  • #2470 217941f Thanks @jan-kubica! - In the experimental canonical session, a tracked replacement now reads as a redline: the struck text comes first and the new text follows it, as the default editor saves it. This holds for typing, pasting and pressing Enter over a selection, and for public replacements. Text replacing a selection that ends inside a content control stays inside that control instead of splitting it, and replacing exactly the words a comment covers keeps the comment on the new text.

  • #2512 49a28c4 Thanks @jan-kubica! - Saving in the experimental canonical session while a suggestion that adds paragraphs is pending no longer rewrites the whole document body: the paragraphs the suggestion adds are not in the file, so they no longer count as changes for the save to write.

  • #2513 aaa7474 Thanks @jan-kubica! - The experimental canonical session's save keeps the source XML of every paragraph an edit did not touch in more documents:

    • When word/document.xml starts with a byte order mark, the body is no longer written whole from the model, which could drop formatting the model does not carry.
    • A structural edit in a body that holds comment anchors is now spliced into the source part instead of rewriting the whole body, as long as the spliced body carries exactly the serialized body's comment anchors.
  • #2435 95488ec Thanks @jan-kubica! - The experimental canonical session now opens documents whose text holds a literal tab character, and documents with a header, footer or note that holds no blocks. The session reads a literal tab as a tab element and gives an empty story an empty paragraph, in its own...

Read more

@stll/folio-cli@0.5.13

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:12
a068188

Patch Changes


@stll/folio-cli@0.5.13 is published through npm trusted publishing with provenance. The attached tarball is the artifact submitted by this release workflow.

@stll/folio-agents@0.16.12

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:12
a068188

Patch Changes


@stll/folio-agents@0.16.12 is published through npm trusted publishing with provenance. The attached tarball is the artifact submitted by this release workflow.

@stll/docx-core@0.43.1

Choose a tag to compare

@github-actions github-actions released this 09 Nov 14:12
a068188

Patch Changes

  • #2449 348cc23 Thanks @jan-kubica! - Tracked block moves now apply in the experimental canonical session. A deleteBlock and an insertAfterBlock or insertBeforeBlock that share a moveId in one batch are recorded as w:moveFrom and w:moveTo, paired as the default engine pairs them, and an unpaired id is reported as unpairedMove. INSERT_BLOCKS and DELETE_BLOCKS take move. A block deletion the following paragraph survives now removes the paragraph by its identity.

  • #2450 46dda37 Thanks @jan-kubica! - A newList numbering request on insertAfterBlock, insertBeforeBlock or setBlockParagraphProperties now applies in the experimental canonical session. It mints a list instance per operation and kind, as the default engine does. The insertParagraphs and formatParagraph editor intents take the new instance and create it first. NewListInstance is exported from @stll/docx-core/ops.

  • #2479 892aafa Thanks @jan-kubica! - Tracked paragraph insertions and deletions next to tables, block-level range boundaries and a container's final paragraph now resolve one record at a time without reminting the anchor's record ids, and a tracked deletion before a table that cannot take its mark is refused up front. Direct joins and paragraph deletions now leave the caret in a paragraph the edit keeps.

  • #2454 bcee67a Thanks @jan-kubica! - A commented public operation on a paragraph inside a table cell or a block content control now applies in the experimental canonical session. It no longer refuses with "The comment anchor no longer exists." A commented insertion beside such a paragraph now carries its comment too. storyParagraphs is exported from @stll/docx-core/ops.

  • #2527 17f7f28 Thanks @jan-kubica! - Typing in the canonical session applies each keystroke's edit once: the compiled edit hands back what it applied, and the session no longer applies it again.

  • #2447 c850dcd Thanks @jan-kubica! - A tracked deleteBlock of a paragraph that a table follows now applies in the experimental canonical session, as the default engine records it: its words and its own mark are marked deleted. DELETE_BLOCKS records this with a revision when the block list still ends with a paragraph. A new deleteParagraphs editor intent compiles to it.

  • #2479 892aafa Thanks @jan-kubica! - Canonical public operations: an inline insertion reads CRLF and CR as one line break; an insertion beside a paragraph in a table cell goes beside the table; an insertion beside a paragraph the same batch deletes applies when a block follows that paragraph; a move whose other half does not apply saves as a plain insertion or deletion, reported unpaired; an undone insertion's paragraph id is not reused; and an open header, footer or note editor keeps its caret through an operation on its story. A list reference that names no list stays out of lists started later.

  • #2470 217941f Thanks @jan-kubica! - In the experimental canonical session, a tracked replacement now reads as a redline: the struck text comes first and the new text follows it, as the default editor saves it. This holds for typing, pasting and pressing Enter over a selection, and for public replacements. Text replacing a selection that ends inside a content control stays inside that control instead of splitting it, and replacing exactly the words a comment covers keeps the comment on the new text.

  • #2435 95488ec Thanks @jan-kubica! - The experimental canonical session now opens documents whose text holds a literal tab character, and documents with a header, footer or note that holds no blocks. The session reads a literal tab as a tab element and gives an empty story an empty paragraph, in its own model only. A part whose story is unedited saves exactly as it was read; a story the user edits saves in the session's spelling. replaceStoryBody is exported from @stll/docx-core/ops.

  • #2504 97b5ca5 Thanks @jan-kubica! - A tracked batch that deletes the paragraph ending the body and inserts beside it now applies both operations in the experimental canonical session, as the default engine does. DELETE_BLOCKS with a revision now removes a paragraph mark that the same author's pending insertion added, joining that paragraph to the next one, instead of refusing the deletion.

  • #2475 05bfbdf Thanks @jan-kubica! - In the experimental canonical session, consecutive tracked typing and deletion by one author now read as one change, as in the default editor. A word typed while suggesting saves as one insertion instead of one per character, and a run of Backspace or Delete saves as one deletion. Text typed beside the author's own pending insertion goes into it, and a deletion beside the author's own pending deletion continues it, also when that change came with the file. Another author's change is never continued. Undo still takes back each edit, and rejecting gives the original text back with its runs whole.

  • #2493 963c5f6 Thanks @jan-kubica! - Checking a document's comments after an edit reads only the paragraphs the edit replaced: each paragraph's comment anchors, text edges and text boxes are read once per paragraph.

  • #2489 76afe3a Thanks @jan-kubica! - The comment anchor check reads each comment's anchors from one pass over the document's anchors instead of filtering all of them once per comment, so documents with many comments check in time proportional to their anchors.

  • #2522 02b6a24 Thanks @jan-kubica! - Replacing a range directly whose deletion keeps a bookmark or another range boundary inside a wrapper or inline content control now puts the new text in that wrapper, after the boundary, instead of splitting the wrapper in two. The direct edit now gives what accepting the same edit made with tracked changes gives.

  • #2472 32e7052 Thanks @jan-kubica! - @stll/docx-core and @stll/folio-core no longer depend on @stll/docx-utils. The OOXML namespace table they read from it, OOXML_NS (with its OoxmlPrefix type), now comes from @stll/docx-core/xml/namespaces, with the same entries. Installing folio no longer brings in @stll/docx-utils or jszip.

  • #2495 e205e8f Thanks @jan-kubica! - An edit no longer counts every revision and content-control id of the package to check the ids it creates: the checks ask the package's id index for the ids in question.

  • #2528 466d3b7 Thanks @jan-kubica! - Edits look up revision and content-control ids without counting the whole document again when the previous version they were counted from is gone.

  • #2490 eb1ca54 Thanks @jan-kubica! - Adds a per-package index of revision and content-control ids that is derived from the previously indexed package by walking only the records an edit replaced.

  • #2532 9fad4c9 Thanks @jan-kubica! - Applying an operation decides whether it removed a note's last reference from the top-level blocks the operation changed, instead of ...

Read more

folio for VS Code 0.5.12

Choose a tag to compare

@github-actions github-actions released this 08 Nov 14:56
5df383f

The folio VS Code extension 0.5.12, built from 5df383f.

@stll/folio-vue@0.28.0

Choose a tag to compare

@github-actions github-actions released this 08 Nov 14:55
5df383f

Minor Changes

  • #2376 755cce9 Thanks @jan-kubica! - A refusal from the experimental canonical session now says why: CanonicalSessionRefusalError carries a ground, either { gap } for a capability the session does not have yet or { rule } for a rule the document states, starting with contentControlLock. The editor shows a rule refusal as its own translated message, "This part of the document is locked." in English, which hosts can translate through the editor messages. CanonicalSessionRefusalError no longer has a top-level gap; read error.ground.gap.

Patch Changes

  • #2414 bb3018d Thanks @jan-kubica! - The experimental canonical session supports pending suggestions. A document operation batch in suggested mode records tracked changes that carry the operation's suggestion id, never folding into a suggestion already pending. The review surface lists them as suggestions, including formatting suggestions. Accepting one adopts it as ordinary tracked changes by the accepting author; rejecting one rejects its revisions. Both are journalled, so undo restores the suggestion, and the React and Vue editors route accept and reject to the session. The engine gains setRevisionInfo, which rewrites revision metadata with an exact inverse, suggestionRevisionInfos and pendingSuggestionIdsIn.

  • #2380 0ee8fd2 Thanks @jan-kubica! - Accepting or rejecting a tracked change now honours a content control's w:lock. A change stays pending as it is when resolving it would change the content of a control locked with contentLocked or sdtContentLocked, or remove one locked with sdtLocked or sdtContentLocked.

    • FolioDocxReviewer.acceptChange and rejectChange return false for such a change.
    • acceptAll() and rejectAll() resolve every other change and now return { resolved, skipped }, listing each held change with the reason contentControlLock. They previously returned the number of changes resolved, which is now resolved.
    • The editor commands acceptChange, rejectChange, acceptAIEditRevision, rejectAIEditRevision, acceptAllChanges and rejectAllChanges refuse the same changes. changeResolutionLockViolation and lockHeldRevisions tell a host which changes a lock holds.
    • In the React editor, the toolbar's accept and reject buttons and the context menu's Accept Change and Reject Change are disabled for such a change, with the reason. In the Vue editor, the change card's buttons are.
  • #2416 d3dc5fd Thanks @jan-kubica! - A read-only editor no longer changes comment threads from the review sidebar in the ProseMirror session: resolve, reopen, reply and delete report a read-only edit attempt and publish nothing, as the canonical session already did. Template preview reads only the values the host set itself, so a marker named after an inherited property such as {{constructor}}, or a value that is neither text nor text spans, keeps its authored text.

  • Updated dependencies [15a57b5, 0f183b9, 092679b, 51443e1, d80f8be, 1f78c5a, c059c72, 6dd481b, 6b17597, b305fdf, d0a0fc7, 43583a8, cf290cf, 06a61cb, 904374b, fa3b0bf, eee1b05, 5051d11, 1dd7133, f21b924, 5b5bf69, 755cce9, 05285fc, bb3018d, 06c4073, 229f36f, 544fb6d, d4c8b0d, 1e274a9, 49f92f8, 347abca, db7686a, 33c708f, 0ee8fd2, e53e82a, c8e91a8, d83837b, 082dd7f, 9ccf3b0, 48777e9, 2d9d34c, 682b38b, 8b3264b, 89f01cf, 87d19aa, 3fea100, 3dfa847, 0ac64d2, 44185f7, 38fefb9, 780dbc1, 77b4891, f537fc8, 81df722, 9283e80, d7de454, 6ff1721, d3dc5fd, 5e57e40, 05463ce, 1786d7f, 0bedd8c, e903801, 6453655, aa961c5, 4d553c2, 8477a98, [11d6ed2](https://github.com/stella/folio/commit/11d6ed256a0940ad101df81795...

Read more

@stll/folio-react@0.34.0

Choose a tag to compare

@github-actions github-actions released this 08 Nov 14:55
5df383f

Minor Changes

  • #2376 755cce9 Thanks @jan-kubica! - A refusal from the experimental canonical session now says why: CanonicalSessionRefusalError carries a ground, either { gap } for a capability the session does not have yet or { rule } for a rule the document states, starting with contentControlLock. The editor shows a rule refusal as its own translated message, "This part of the document is locked." in English, which hosts can translate through the editor messages. CanonicalSessionRefusalError no longer has a top-level gap; read error.ground.gap.

Patch Changes

  • #2414 bb3018d Thanks @jan-kubica! - The experimental canonical session supports pending suggestions. A document operation batch in suggested mode records tracked changes that carry the operation's suggestion id, never folding into a suggestion already pending. The review surface lists them as suggestions, including formatting suggestions. Accepting one adopts it as ordinary tracked changes by the accepting author; rejecting one rejects its revisions. Both are journalled, so undo restores the suggestion, and the React and Vue editors route accept and reject to the session. The engine gains setRevisionInfo, which rewrites revision metadata with an exact inverse, suggestionRevisionInfos and pendingSuggestionIdsIn.

  • #2380 0ee8fd2 Thanks @jan-kubica! - Accepting or rejecting a tracked change now honours a content control's w:lock. A change stays pending as it is when resolving it would change the content of a control locked with contentLocked or sdtContentLocked, or remove one locked with sdtLocked or sdtContentLocked.

    • FolioDocxReviewer.acceptChange and rejectChange return false for such a change.
    • acceptAll() and rejectAll() resolve every other change and now return { resolved, skipped }, listing each held change with the reason contentControlLock. They previously returned the number of changes resolved, which is now resolved.
    • The editor commands acceptChange, rejectChange, acceptAIEditRevision, rejectAIEditRevision, acceptAllChanges and rejectAllChanges refuse the same changes. changeResolutionLockViolation and lockHeldRevisions tell a host which changes a lock holds.
    • In the React editor, the toolbar's accept and reject buttons and the context menu's Accept Change and Reject Change are disabled for such a change, with the reason. In the Vue editor, the change card's buttons are.
  • #2416 d3dc5fd Thanks @jan-kubica! - A read-only editor no longer changes comment threads from the review sidebar in the ProseMirror session: resolve, reopen, reply and delete report a read-only edit attempt and publish nothing, as the canonical session already did. Template preview reads only the values the host set itself, so a marker named after an inherited property such as {{constructor}}, or a value that is neither text nor text spans, keeps its authored text.

  • #2350 d1774b2 Thanks @jan-kubica! - Track Changes turned on before the first click into a document now applies to the edits that follow. They used to go in untracked while the button showed tracking on.

  • Updated dependencies [15a57b5, 0f183b9, 092679b, 51443e1, d80f8be, 1f78c5a, c059c72, 6dd481b, 6b17597, b305fdf, d0a0fc7, 43583a8, cf290cf, 06a61cb, 904374b, fa3b0bf, eee1b05, 5051d11, 1dd7133, f21b924, 5b5bf69, 755cce9, 05285fc, bb3018d, 06c4073, 229f36f, 544fb6d, d4c8b0d, 1e274a9, 49f92f8, 347abca, db7686a, 33c708f, 0ee8fd2, e53e82a, c8e91a8, d83837b, 082dd7f, 9ccf3b0, 48777e9, 2d9d34c, 682b38b, 8b3264b, 89f01cf, 87d19aa, 3fea100, 3dfa847, 0ac64d2, 44185f7, 38fefb9, 780dbc1, 77b4891, f537fc8, 81df722, 9283e80, d7de454, 6ff1721, d3dc5fd, 5e57e40, 05463ce, 1786d7f, 0bedd8c, e903801, [6453655](https://github.com/stella/folio/commit/6453655281e34573a3802cf8a167706f3...

Read more