feat: SmartArt text pane UI for all editors - #3205
Open
MGRAFF2006 wants to merge 4 commits into
Open
Conversation
…Editor Add Common.Views.SmartArtTextPane - a shared Backbone view that displays SmartArt data as a bulleted text outline with inline editing support: - Contenteditable text entries synced bidirectionally with SmartArt shapes - Toolbar: Add/Remove node, Promote/Demote, Move Up/Down - Keyboard shortcuts: Tab/Shift+Tab/Enter/Backspace - Live sync via asc_onSmartArtDataChanged callback Register SmartArtText (14) in documentSettingsType enum. Integrate into Document Editor: - Add panel div and button to RightMenu template - Register SmartArt text pane in RightMenu view and controller - Auto-show panel when SmartArt is selected (onFocusObject)
…Editors Apply the same SmartArt text pane integration pattern to both editors: - Add panel div and button to RightMenu templates - Register SmartArtText settings in RightMenu views with button, panel, setApi - Add SmartArt detection in RightMenu controllers (onFocusObject) to auto-show the text pane when SmartArt shapes are selected - Add setButtons registration and localization strings
Add comprehensive styling for the SmartArt text pane in common.less: - Flexbox layout for header, toolbar, and scrollable content - Bulleted text items with hover/active states - Contenteditable input spans with proper line height - Empty state placeholder styling - Consistent with existing panel design patterns
The btn-ins-smartart icon class had no CSS sprite definition, making the sidebar button invisible. Switch to btn-smart-hierarchy which exists in all editors' small icon sprite sheets.
|
|
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
Changes
Shared Components
apps/common/main/lib/view/SmartArtTextPane.js(NEW) - Backbone view that displays SmartArt data as a bulleted text outline with contenteditable spans, toolbar buttons (Add/Remove/Promote/Demote/Move), keyboard shortcuts (Tab/Shift+Tab/Enter/Backspace), and bidirectional sync viaasc_onSmartArtDataChangedcallbackapps/common/main/lib/util/utils.js- AddSmartArtText: 14todocumentSettingsTypeenumapps/common/main/resources/less/common.less- Add SmartArt text pane stylesDocument Editor
RightMenu.templateRightMenu.jsview (button, settings entry, setApi)RightMenu.jscontroller (onFocusObject) to auto-show panelPresentation Editor
presentationeditor/filesSpreadsheet Editor
spreadsheeteditor/filesRelated PR
SDK core changes: ONLYOFFICE/sdkjs#4876