fix: close scene 9 acceptance gaps

This commit is contained in:
lda
2026-07-12 07:27:41 +07:00 Verified
parent 7fcc469564
commit 4505e9bf7f
4 changed files with 24 additions and 2 deletions
@@ -34,6 +34,20 @@ describe("SceneProgress", () => {
expect(screen.getByText("3 / 3")).toBeInTheDocument(); expect(screen.getByText("3 / 3")).toBeInTheDocument();
}); });
it("shows the single Scene 8 beat position", () => {
const location: MainLocation = {
kind: "main",
sceneId: "agent-handoff",
beatId: "request",
focusPath: [],
};
render(<SceneProgress location={location} />);
expect(screen.getByText("8 / 14")).toBeInTheDocument();
expect(screen.getByText("1 / 1")).toBeInTheDocument();
});
it("has an accessible label", () => { it("has an accessible label", () => {
const location: MainLocation = { const location: MainLocation = {
kind: "main", kind: "main",
@@ -18,7 +18,7 @@ export const SceneProgress = ({ location }: SceneProgressProps) => {
{sceneIndex + 1} / {totalScenes} {sceneIndex + 1} / {totalScenes}
</span> </span>
)} )}
{totalBeats > 1 && ( {(totalBeats > 1 || location.sceneId === "agent-handoff") && (
<span className="scene-progress__beat"> <span className="scene-progress__beat">
{beatIndex >= 0 ? beatIndex + 1 : 1} / {totalBeats} {beatIndex >= 0 ? beatIndex + 1 : 1} / {totalBeats}
</span> </span>
@@ -45,6 +45,14 @@ describe("presentation.css", () => {
expect(css).not.toMatch(/prepared-lifecycle-scene__dock[\s\S]*position:\s*(absolute|fixed)/); expect(css).not.toMatch(/prepared-lifecycle-scene__dock[\s\S]*position:\s*(absolute|fixed)/);
}); });
it("keeps every Scene 9 surface override on the clarity-focused 35/65 split", () => {
const scene9Rules = css.match(/\.prepared-lifecycle-scene[^{}]*\{[^}]*\}/g) ?? [];
expect(scene9Rules.filter((rule) => rule.includes("grid-template-columns:")).length).toBeGreaterThan(0);
expect(scene9Rules.join("\n")).not.toContain("1.65fr");
expect(scene9Rules.join("\n")).toMatch(/minmax\(15rem, 0\.35fr\)\s+minmax\(0, 0\.65fr\)/);
});
it("keeps evidence inside a substrate stack from wide desktop through the 1080px breakpoint", () => { it("keeps evidence inside a substrate stack from wide desktop through the 1080px breakpoint", () => {
expect(css).toMatch(/\.conclusion-map__flow\s*\{\s*display: grid;\s*grid-template-columns: repeat\(3, minmax\(0, 1fr\)\);/); expect(css).toMatch(/\.conclusion-map__flow\s*\{\s*display: grid;\s*grid-template-columns: repeat\(3, minmax\(0, 1fr\)\);/);
expect(css).toMatch(/\.conclusion-map__flow-unit--substrate-stack\s*\{[\s\S]*?grid-template-rows: auto auto;/); expect(css).toMatch(/\.conclusion-map__flow-unit--substrate-stack\s*\{[\s\S]*?grid-template-rows: auto auto;/);
@@ -3313,7 +3313,7 @@
--authoring-ink: var(--color-editorial-ink, oklch(0.19 0.015 65)); --authoring-ink: var(--color-editorial-ink, oklch(0.19 0.015 65));
--authoring-muted: var(--color-editorial-muted, oklch(0.48 0.025 65)); --authoring-muted: var(--color-editorial-muted, oklch(0.48 0.025 65));
--authoring-rule: color-mix(in oklch, var(--authoring-muted) 32%, transparent); --authoring-rule: color-mix(in oklch, var(--authoring-muted) 32%, transparent);
grid-template-columns: minmax(15rem, 0.35fr) minmax(0, 1.65fr); grid-template-columns: minmax(15rem, 0.35fr) minmax(0, 0.65fr);
gap: 0.8rem; gap: 0.8rem;
background: var(--authoring-paper); background: var(--authoring-paper);
color: var(--authoring-ink); color: var(--authoring-ink);