2 Commits

Author SHA1 Message Date
lyrathorpe 65f97d2707 Merge pull request 'feat: present theme switch as a segmented control' (#15) from feat/segmented-theme-switch into main
Build and publish container / build (push) Successful in 6m7s
Reviewed-on: #15
2026-06-12 11:45:08 +01:00
Emma Thorpe ad90451846 feat: present theme switch as a segmented control
Build and publish container / build (pull_request) Successful in 4m49s
Join the two theme options into a single rounded container with the active
segment filled and a divider between them, replacing the two separate pills.
Markup and aria-pressed behaviour are unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-12 11:34:32 +01:00
+13 -7
View File
@@ -63,10 +63,13 @@ body {
padding: 1.5rem;
}
/* Segmented control: both options joined in one rounded container,
with the active segment filled. */
.theme-toggle {
display: flex;
gap: 0.5rem;
border: none;
display: inline-flex;
border: 2px solid var(--button-bg);
border-radius: 999px;
overflow: hidden;
margin: 0;
padding: 0;
}
@@ -75,19 +78,22 @@ body {
font-family: inherit;
font-size: 0.9rem;
font-weight: 600;
padding: 0.5rem 1rem;
border: 2px solid var(--button-bg);
border-radius: 999px;
padding: 0.5rem 1.1rem;
border: none;
background: transparent;
color: var(--text);
cursor: pointer;
transition: background 0.2s ease, color 0.2s ease;
}
/* Divider between the two segments. */
.theme-button + .theme-button {
border-left: 2px solid var(--button-bg);
}
.theme-button[aria-pressed="true"] {
background: var(--button-active-bg);
color: var(--button-active-text);
border-color: var(--button-active-bg);
}
.stage {