Skip to content

fix(ui): first-child, not first-of-type, for dialog headings - #762

Merged
hokiepokedad2 merged 1 commit into
developfrom
fix/delivery-tab-heading-spacing
Aug 20, 2026
Merged

fix(ui): first-child, not first-of-type, for dialog headings#762
hokiepokedad2 merged 1 commit into
developfrom
fix/delivery-tab-heading-spacing

Conversation

@hokiepokedad2

Copy link
Copy Markdown
Contributor

Found while screenshotting the Delivery tab for the documentation refresh: "Message Settings" sits flush against the scope picker above it. Measured in the browser — margin-top: 0px, gap above 0px.

The heading margin from #750 exempts the first heading in a tab so it can start flush. :first-of-type matches the first h4 among its siblings regardless of what precedes it, so the Delivery tab's heading — which follows app-scope-picker — was exempted too. :first-child is what the exemption meant.

Trialled in the browser before changing anything: with the corrected predicate the gap measures 24px.

The other :first-of-type in the codebase (profile-overview.component.scss) is a different, correct case — sibling panels of the same type, where the first one genuinely wants the different margin. Left alone.

https://claude.ai/code/session_01Nah4N2sGFs1TU2t7DXfKzJ

Spotted while taking a documentation screenshot of the Delivery tab: "Message
Settings" was flush against the scope picker, measured 0px of gap.

The heading margin added in #750 exempts the first heading in a tab, which is
right when that heading starts the tab and wrong otherwise. :first-of-type
matches the first h4 among its siblings whatever precedes it, so a heading that
follows a control still lost its margin. :first-child is the predicate that
matches the intent.

Refs #730

Claude-Session: https://claude.ai/code/session_01Nah4N2sGFs1TU2t7DXfKzJ
@github-actions github-actions Bot added the fix label Aug 19, 2026
@hokiepokedad2
hokiepokedad2 merged commit 08c72bf into develop Aug 20, 2026
5 checks passed
@hokiepokedad2
hokiepokedad2 deleted the fix/delivery-tab-heading-spacing branch August 20, 2026 01:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant