Skip to content

Make the editor's section list readable at nine sections - #375

Merged
singhharsh1708 merged 1 commit into
mainfrom
fix/editor-section-list
Sep 5, 2026
Merged

Make the editor's section list readable at nine sections#375
singhharsh1708 merged 1 commit into
mainfrom
fix/editor-section-list

Conversation

@singhharsh1708

Copy link
Copy Markdown
Owner

Deepening the templates in #374 was the right change, but it broke something I built for four-section templates. Measured in Chrome on kiln-coffee:

before after
labels clipped 7 of 9 0 of 9
rows that are spacers labelled "Section N" 2 0
fields a spacer's Content tab offers 5 0

The list read:

Roasted t...    Two farm...    Light eno...    Section 4
Bags are ...    A recipe ...   Open at s...    Section 8    Subscrib...

Why the labels were starved

Not the panel width. The row's hover controls are opacity-0, which still occupies layout — four buttons reserving roughly 100px of a 224px panel while invisible. My first attempt made it worse by adding flex-shrink-0 to them, which pinned that width instead of letting it collapse.

They are now absolute right-1 top-1 over the right edge of the row, with the row as the containing block, so the label gets the full width across two lines.

Spacers

A spacer draws nothing. Labelling it "Section 4" and then offering an eyebrow, heading, body, CTA and image URL invites you to fill in five fields that do nothing. It now reads Spacer · 700px, dimmed and italic, and selecting it says what it is for and points at the height control on the Layout tab — the one thing it actually has.

Verified the controls still work

Lifting them out of the flow could easily have made them unclickable, so I checked rather than assumed:

controls hit-testable        yes, topmost element at the button's centre is the button
order before                 ["Roasted this morning…", "Two farms…", "Light enough…"]
after Move up                ["Two farms…", "Roasted this morning…", "Light enough…"]
after Duplicate              10 rows
after Undo                   9 rows, order preserved

Also checked at 390×844: full headings, spacer distinct, list scrolls within its cap.

Four new tests in appAccessibility.test.ts, all failing on main. Suite 369 passed.

Deepening the templates from four sections to nine turned two small annoyances
into an unusable list. Measured in Chrome on kiln-coffee: seven of the nine
labels were clipped to "Roasted t..." and "Light eno...", and two of the rows
were spacers labelled "Section 4" and "Section 8" whose Content tab offered an
eyebrow, a heading, a body, a button and an image - five fields a spacer does
not have.

The labels were starved because the row's hover controls are opacity-0 rather
than absent, so four buttons reserved roughly a hundred pixels of a
two-hundred-and-twenty-four pixel panel while invisible. They are now
positioned out of the flow, over the right edge of the row, and the label takes
the whole width across two lines. Zero of nine clip.

A spacer is named as one, dimmed and italic, and selecting it explains what it
does and points at the height control on the Layout tab rather than presenting
fields that go nowhere.

Verified that lifting the controls out of the flow did not break them:
elementFromPoint at the button's centre returns the button, and move up,
duplicate and undo all still work on the list.

Suite 369 passed; the four new tests fail on main.
@vercel

vercel Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
scrollcraft Ready Ready Preview Sep 5, 2026 4:02pm UTC

@singhharsh1708
singhharsh1708 merged commit 9ef77c3 into main Sep 5, 2026
3 checks passed
@singhharsh1708
singhharsh1708 deleted the fix/editor-section-list branch September 5, 2026 16:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant