Conversation
Adds insertSection(view) to editor-utils/blocks.js, appending a single horizontal_rule node at the end of the doc to create a new empty section. Wires an "Add section" button into ew-page-outline.js's outline list, dispatched via the extensions bridge like other outline mutations. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
3 tasks
# Conflicts: # blocks/canvas/ew-page-outline/ew-page-outline.js # test/unit/blocks/canvas/editor-utils/blocks.test.js
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
insertSection(view)toblocks/canvas/editor-utils/blocks.js, which appends a singlehorizontal_rulenode at the end of the doc to create a new empty section (mirrors the node-creation pattern already used indeleteSection/moveSection).ew-page-outline.js, rendered after the outline list, using the existings2-icon-addcircle-20-n.svgicon (already used elsewhere, e.g.ew-block-library-modal.js). Click handler pulls the live view viagetExtensionsBridge()and callsinsertSection(view), letting the existingeditorHtmlChange→parseSectionspipeline re-render the outline.ew-page-outline.css.https://addsect--da-live--adobe.aem.live/
Co-Authored-By: Claude Sonnet 5 noreply@anthropic.com