mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-08 04:32:42 +00:00
Merge v189/quick into release/v1.18.9
Coach FAB glyph token softened from text-white to the on-accent text-background; sleep-debt and chronotype sections share an sm:grid-cols-2 row.
This commit is contained in:
commit
f600ee1ac3
3 files changed
+16
-21
No files matched your search
@@ -117,13 +117,16 @@ export default function InsightsSchlafPage() {
|
||||
/>
|
||||
|
||||
{/*
|
||||
v1.17.0 — sleep-debt headline. Server-authoritative (the same DTO iOS
|
||||
renders), gated on the data-bearing branch so a source-less account
|
||||
never fetches. v1.18.7 W-D — the chronotype moved out to the prominent
|
||||
bottom block (`<ChronotypeSection>` below); this section is the
|
||||
sleep-debt headline alone.
|
||||
v1.17.0 — sleep-debt headline + v1.18.7 W-D chronotype, paired in one
|
||||
shared row. Both read the same server-authoritative `["sleep-rhythm"]`
|
||||
cache (one fetch), so the grid adds no round-trip. They stack on narrow
|
||||
viewports and sit side-by-side from `sm` up; each card keeps its own
|
||||
internals (the debt headline and the chronotype band treatment).
|
||||
*/}
|
||||
<SleepRhythmSection enabled={!isEmpty} />
|
||||
<div className="grid gap-4 sm:grid-cols-2">
|
||||
<SleepRhythmSection enabled={!isEmpty} />
|
||||
<ChronotypeSection enabled={!isEmpty} />
|
||||
</div>
|
||||
|
||||
{/*
|
||||
v1.17.1 — "Sleep quality" block. Surfaces the WHOOP / Oura nightly
|
||||
@@ -137,15 +140,6 @@ export default function InsightsSchlafPage() {
|
||||
<SleepQualitySection enabled={!isEmpty} />
|
||||
|
||||
<MetricTargetSummary slug="sleep" />
|
||||
|
||||
{/*
|
||||
v1.18.7 W-D — chronotype as the PROMINENT bottom treatment of the
|
||||
Sleep view (maintainer directive): a large band label with the natural
|
||||
sleep-midpoint clock beneath it and an expandable disclosure for social
|
||||
jetlag + MSFsc. Reads the same `["sleep-rhythm"]` cache the debt section
|
||||
warmed, so it adds no round-trip; gated on the data-bearing branch.
|
||||
*/}
|
||||
<ChronotypeSection enabled={!isEmpty} />
|
||||
</SubPageShell>
|
||||
);
|
||||
}
|
||||
@@ -71,7 +71,7 @@ describe("<LayoutCoachFab>", () => {
|
||||
expect(html).not.toContain("lg:bottom-6");
|
||||
});
|
||||
|
||||
it("paints a white glyph + offset focus ring on the gradient", () => {
|
||||
it("paints the on-accent glyph + offset focus ring on the gradient", () => {
|
||||
mockPathname = "/";
|
||||
const html = render(
|
||||
<CoachLaunchProvider>
|
||||
@@ -79,10 +79,11 @@ describe("<LayoutCoachFab>", () => {
|
||||
</CoachLaunchProvider>,
|
||||
);
|
||||
// The glyph is decorative (aria-hidden) and the button carries its own
|
||||
// accessible name, so the text-contrast rule does not gate it; the
|
||||
// white glyph reads as a clean mark on the gradient. The button still
|
||||
// sets text-background for any non-glyph text it might hold.
|
||||
expect(html).toContain("text-white");
|
||||
// accessible name, so the text-contrast rule does not gate it; the glyph
|
||||
// shares the button's own on-accent token (text-background) rather than a
|
||||
// harsh pure white, so it reads as a softer mark on the gradient.
|
||||
expect(html).not.toContain("text-white");
|
||||
expect(html).toMatch(/lucide-sparkles[^"]*text-background/);
|
||||
// The offset ring draws a visible halo around the gradient circle and
|
||||
// provides the non-text UI-component contrast against the page.
|
||||
expect(html).toContain("focus-visible:ring-offset-2");
|
||||
|
||||
@@ -238,7 +238,7 @@ export function LayoutCoachFab() {
|
||||
"[body:has([data-testid=onboarding-tour])_&]:invisible",
|
||||
)}
|
||||
>
|
||||
<Sparkles className="size-6 text-white" aria-hidden="true" />
|
||||
<Sparkles className="text-background size-6" aria-hidden="true" />
|
||||
{unread ? (
|
||||
// v1.18.6 (CCH-03) — discreet "the Coach said something" dot.
|
||||
// Deliberately NOT an alarming red (the medication-card rule:
|
||||
|
||||
Reference in new issue
Block a user