feat(editor): customize-sidebar pass — pill toggles, color mode, shared theme helpers#113
Merged
Conversation
…ed theme helpers Editor customization redesign: drag-able PillToggle/ToggleSelect controls, a dedicated editor color-mode store (use-editor-color-mode), elastic-slider and share-summary refinements, and eager sidebar imports (drop lazy-modules split). Review cleanups folded in: - extract shared clamp() to lib/utils (was duplicated 3×) - extract resolveEffectiveMode() shared by useFormCustomization + customize-sidebar - cache PillToggle track rect on pointerDown (no per-frame layout read)
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
Editor customization redesign plus review cleanups.
PillToggle/ToggleSelectsegmented controls in the Customize sidebaruse-editor-color-mode) scoping light/dark to the preview (not the app theme)lazy-modules.tscode-splitReview cleanups (from /code-review)
clamp()intolib/utils(was duplicated in 3 files)resolveEffectiveMode()shared byuseFormCustomization+customize-sidebar(mode-precedence was duplicated)PillToggletrack rect on pointerDown so pointerMove no longer forces a layout read each frameVerification
tsc --noEmitcleanLeft for human decision (review findings NOT auto-applied)
These are intentional design changes in the diff, not bugs — flagging rather than reverting:
textAlignis still consumed (CSS var, Pro key, header render). Either re-add the control or remove the now-orphaned consumers — a product call.