Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .agents/skills/verify-codeimage/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ The helper's `finally` closes its browser/context and terminates only its own Vi

## Helpers

Select `VERIFY_CASES=keyboard-scroll` for keyboard opening of scrollable-panel menus and selects across Inspector, Dock, and Studio at desktop and phone sizes. The Node watchdog interrupts a frozen renderer after five seconds. Read [keyboard coverage](features/keyboard.md) for discovery rules and evidence. Run `fnm exec --using=v24.14.0 node --test .agents/skills/verify-codeimage/scripts/keyboard-scroll.test.mjs` for the dependency traversal regression.
Select `VERIFY_CASES=keyboard-scroll` for keyboard opening of scrollable-panel menus and selects across Inspector, Dock, and Studio at desktop and phone sizes. The Node watchdog interrupts a frozen renderer after five seconds. Read [keyboard coverage](features/keyboard.md) for discovery rules and evidence.

`node .agents/skills/verify-codeimage/scripts/verify.mjs` runs the full baseline. It is executable and accepts `VERIFY_PORT` and `ARTIFACT_DIR` environment overrides. To re-run selected journeys, set `VERIFY_CASES=export-options,settings-persistence` together with `VERIFY_AUDIT=1`. Omit `VERIFY_CASES` for the complete pass. Unknown names fail the run. `audit.json` lists only the journeys actually selected and is flushed before recovery after a failure. On a shared machine, use short `VERIFY_CASES` batches, unique server/debugging ports, and retry a killed case at most twice. Never terminate another session’s processes.

Expand Down
2 changes: 2 additions & 0 deletions .agents/skills/verify-codeimage/features/export.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ Run `export-options` for actual 1x and 2x PNG dimensions, JPEG magic bytes and a

Run `VERIFY_AUDIT=1 VERIFY_CASES=export-dialog node .agents/skills/verify-codeimage/scripts/verify.mjs` for the Dialog export style. The case switches styles in Settings, checks the decoded preview, dismisses with Escape and checks trigger focus. It downloads and parses a one-off SVG, then checks that PNG remains the default until saving SVG with Remember as default. Each SVG must contain the editor text and have positive dimensions.

Run `export-notification` to check the notification after a PNG download. The case selects Copy alt text, checks that the success notification closes, and reads the exported code from the clipboard.

Run `export-fractional-geometry,export-padding-geometry` for fractional frame measurement and padding-only signature changes. The cases edit short, sample and long code through CodeMirror, fit the long document on desktop and phone, change padding and switch Card to Minimal through the signature controls. They compare live and export border boxes and decode real 1x/2x PNG downloads. At zoom 1, fractional geometry must match within 0.02 CSS pixels; fitted text allows one screen pixel of layout snapping. The signature case tolerates integer rounding but rejects stale reserved padding independently of fractional precision.

Each case saves its geometry JSON, screenshots, traces, downloaded PNGs and persisted document snapshots. To compare those actual downloads with the CLI, run `scripts/parity/cli-vs-web/index.ts` with the corresponding `<name>-1x.json` / `<name>-2x.json` inputs and `P10_WEB_EXPORTS=<audit artifact directory>`. `P10_WEB_OUT` selects the comparison directory. The runner records both sizes and pixelmatch percentages in `results.json`; a size mismatch fails without hiding later documents. Omit `P10_WEB_EXPORTS` for the existing static preview fixture comparison.
Expand Down
10 changes: 3 additions & 7 deletions .agents/skills/verify-codeimage/features/keyboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

`keyboard-scroll` opens menu and select triggers with Enter, Space, and ArrowDown. The matrix uses fresh contexts at 1440×900 and 390×844 for Inspector, Dock, and Studio. Each context sets `codeimage:editor-settings` before loading the editor. The legacy `inspector` and `studio` values exercise their migration to the accordion and rail sidebar preferences.

The journey creates a preset through the UI, visits the sidebar sections, and opens the Signature overlay. Dock visits each More group and the Font and phone Language panels. Dock has no Presets panel. Discovery includes enabled menu, listbox, and combobox triggers inside the active control panel or overlay with a CSS `auto` or `scroll` ancestor. Closed accordion sections and controls behind an overlay are excluded. A CSS scroll container matters even when its contents currently fit, because Kobalte checks overflow styles rather than scroll dimensions.
The journey creates a preset through the UI, visits the sidebar sections, and opens the Signature overlay. Dock visits each More group and the Font and phone Language panels. Dock has no Presets panel. Discovery includes enabled menu, listbox, and combobox triggers inside the active control panel or overlay with a CSS `auto` or `scroll` ancestor. Closed accordion sections and controls behind an overlay are excluded.

Discovery waits for finite panel transitions and reads the candidate list in one browser evaluation. Every discovered trigger receives focus before each key. The journey asserts that its popup appears, `aria-expanded` becomes true, the renderer completes another animation frame, and Escape closes the popup and restores focus. An explicit control list for each layout prevents missing controls from silently passing.
Discovery waits for finite panel transitions and reads the candidate list in one browser evaluation. Every discovered trigger receives focus before each key. The journey asserts that its popup appears, `aria-expanded` becomes true, the renderer completes another animation frame, and Escape closes the popup and restores focus. After the Signature sweep, another Escape closes Signature and returns focus to its opener. An explicit control list for each layout prevents missing controls from silently passing.

Sidebar coverage includes Preset menu, Padding, Saved signatures, Avatar source, Border, Shadow, Language, Theme, Font, and Font weight. Dock coverage includes Saved signatures, Avatar source, Border, Shadow, Syntax theme, and Font weight. The Signature fixture selects Card and Profile to reveal Avatar source. This produces 156 key openings across the six layout and viewport combinations. Native segmented controls, standalone listboxes, disabled controls, and triggers outside scrollable control panels are outside this case.

Expand All @@ -20,8 +20,4 @@ VERIFY_AUDIT=1 VERIFY_CASES=keyboard-scroll VERIFY_BROWSER_CHANNEL=chrome VERIFY

`rail-interrupted-close` closes Themes and immediately opens Frame on a 390 px Sidebar Rail. Frame must stay open after the Themes exit would have finished. The case repeats with reduced motion and verifies that closing Frame returns focus to its rail button.

The dependency patch is `patches/@kobalte__utils@0.9.1.patch`. Both ESM and CommonJS bundles start each `scrollIntoViewport` lookup at the target's parent. Each iteration therefore reaches a strict ancestor and eventually the document root. The exported `getScrollParent` behavior remains unchanged. The editor's root overflow and the Animate trigger placement workaround remain unchanged.

`scripts/keyboard-scroll.test.mjs` runs the installed ESM utility against a hidden document root and nested CSS scroll containers. A visit limit fails the original loop without hanging the test process. The test also checks that `getScrollParent` keeps its exported behavior and that scrollable targets and detached elements terminate. `VERIFY_KOBALTE_UTILS` can point to the original package's `dist/index.cjs` to repeat the negative control; the test imports its adjacent ESM bundle.

Installed Kobalte versions are core 0.13.11 and utils 0.9.1. The app, UI package, and kit share that utils resolution. On November 16, 2026, published utils 0.9.2 still contains the loop; core 0.13.14 depends on utils ^0.9.2. Their changelogs contain no fix for this loop. [Upstream PR 750](https://github.com/kobaltedev/kobalte/pull/750) proposes the same parent traversal and remains open. Recheck published source before removing the patch or updating Kobalte.
`signatures` verifies nested dismissal. The first Escape closes Saved signatures and returns focus to its trigger. The second closes Signature and returns focus to its opener.
8 changes: 4 additions & 4 deletions .agents/skills/verify-codeimage/features/projects.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,16 @@ Ownership and failed-load fixtures use the existing MSW boundary. Navigation use

To isolate a snippet matrix lane, set `VERIFY_SNIPPET_LAYOUT=inspector`, `dock`, or `studio`, and `VERIFY_SNIPPET_WIDTH=1440` or `390`. The default remains all six combinations. Each run writes the lanes actually exercised to `<case>-matrix.json`; a selected lane does not establish full matrix coverage. All scenario assertions remain active. These selectors allow fresh Chrome processes when a long-lived local browser exits during repeated context changes.

## Bridged project actions
## Project actions from the dashboard

Run the dashboard case on Node 24 to exercise the Solid 2 project menu and its bridged Solid 1 CodeUI trigger.
Run the dashboard case on Node 24 to exercise the CodeUI project menu.

```sh
VERIFY_AUDIT=1 VERIFY_CASES=solid1-bridge-project-menu \
VERIFY_AUDIT=1 VERIFY_CASES=project-menu \
VERIFY_BROWSER_CHANNEL=chrome node .agents/skills/verify-codeimage/scripts/verify.mjs
```

The case creates a disposable MSW project, opens the menu by keyboard, checks Escape and focus, renames the project through the app dialog, clones it and follows the new URL, then deletes the original through the app dialog. It checks the mutation responses and verifies that the rename dialog blocks background clicks only while open.
The case creates a disposable project in MSW. It opens the menu with ArrowDown and checks that Escape returns focus to its trigger. It opens Rename with Enter and checks the rename response. Then it clones the project, follows the new URL, and deletes the original. It checks both mutation responses and confirms that the rename dialog blocks background clicks while open.

## Read-only notice

Expand Down
4 changes: 3 additions & 1 deletion .agents/skills/verify-codeimage/features/signatures.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ Open Frame then Signature (`#signature-options`); after creation the canvas sign

## Driving it with Playwright

The `signatures` case clicks `#signature-options` (the open overlay is `[data-control-overlay="signature"]`), fills @handle or profile link, chooses Saved signatures → Save as new → group Signature name → its textbox → Save. Assert `[data-frame-signature]` contains the handle; export PNG. Reload same context, open Saved signatures and apply named menuitem to prove persistence. Card exposes display name/avatar. Choose Initials for local proof.
The `signatures` case opens Signature with Enter and fills the handle. It opens Saved signatures with ArrowDown. Escape first dismisses the menu and returns focus to Saved signatures. A second Escape dismisses Signature and returns focus to its opener.

The case reopens Signature, saves a new signature, checks the canvas handle, and decodes the downloaded PNG. It reloads the same context and selects the saved signature to check persistence. Card exposes the display name and avatar. Choose Initials for a local check.

Source: `pages/UnifiedEditor/controls/SignatureFields.tsx`, `controls/SavedSignatures.tsx`, `state/signatures/bridge.ts`.

Expand Down
2 changes: 2 additions & 0 deletions .agents/skills/verify-codeimage/features/tabs.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ Run `VERIFY_AUDIT=1 VERIFY_CASES=tabs fnm exec --using=v24.14.0 node .agents/ski

The `tabs` case uses the Editor window style. The `tabs-classic` case runs the same journey in macOS chrome. Each enters distinct code in two tabs, selects their extensions with keyboard and pointer, and switches between them. It focuses a tab, uses Enter to activate it, then uses Space and ArrowRight to pick up and move it. Escape preserves order and focus. Space commits the next move. A pointer drag verifies that order stays stable until drop. The dragged tab follows the pointer inside the frame and keeps its background and shadow. The other tab stays in place. The audit renames a tab, checks the reordered names and decodes the image entries in the downloaded ZIP, then closes the active tab and checks the remaining document. The trace and drag screenshot capture the interaction.

The `plain-text-tab-icon` case renames a tab through filename completion, switches from a dark frame to XCode Light, and checks the icon's computed fill in both modes.

Source: `components/Terminal/Tabs/TerminalWindowTabList.tsx`, `Tab/WindowTab.tsx`, `Tab/DraggableWindowTab.tsx` (Close tab and dragging), `TabAddButton/TabAddButton.tsx` (Add tab), `TabName/TabName.tsx`, `hooks/export-tabs.ts`, `hooks/export-tab-name.ts`.

## Gotchas
Expand Down
2 changes: 2 additions & 0 deletions .agents/skills/verify-codeimage/features/whats-new.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ Case `whats-new` opens `[data-settings-section="whats-new"]`, asserts at least o

Case `whats-new-nudge` uses a fresh Inspector profile at 1440×900. The 2026-11-14 release is major, so a fresh profile gets the Showcase sheet first, not the Nudge. The case clicks Minimize what's new, waits for the collapsed Nudge, clicks See, checks the `Step N of M` indicator moves from 1 to 2 with Next, clicks Dismiss what's new, waits for the dismissal in IndexedDB (`keyval-store`, key `whats-new`, non-empty `dismissed`), reloads and asserts no announcement returns.

Case `whats-new-tooltip-escape` checks that Escape dismisses the Minimize tooltip, keeps the Showcase open and leaves focus on the button. A second press closes the Showcase.

`scripts/news.mjs` exports `dismissNews(page)`. The doctor and the baseline call it, because a fresh profile gets the announcement a moment after the editor settles and it covers the editor: the Showcase sheet for a major release, the Nudge otherwise. It closes the announcement with its own close button and waits for its exit. A `sessionStorage` flag keeps later doctor calls in the same tab from waiting for it again.

Case `whats-new-line-marks-dot` uses a fresh Inspector profile at 1440×900. It closes the announcement, waits for the Line marks dot (`[data-line-marks-news]`, a badge fixed to the viewport beside the marker of the cursor line), moves the inspector to the left in Settings → Appearance, and checks that the dot kept its offset from the marker cell and that the element under the dot is the dot itself. Before the move it turns line numbers on and checks the dot is still on screen at the same offset, then turns them off again. Moving the inspector moves the canvas without a resize or a scroll event, which is how the dot used to be left behind over other controls.
Expand Down
116 changes: 116 additions & 0 deletions .agents/skills/verify-codeimage/scripts/audit-whats-new.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
import assert from 'node:assert/strict';
import {resolve} from 'node:path';
import {verifyShowcaseAction} from './audit-line-marks-news.mjs';

export async function auditWhatsNew({base, out, feature, fresh}) {
await feature('whats-new-tooltip-escape', () =>
fresh(
{
name: 'whats-new-tooltip-escape',
layout: 'inspector',
viewport: {width: 1440, height: 900},
},
async ({page}) => {
await page.goto(base);
const dialog = page.getByRole('dialog', {
name: "What's new",
exact: true,
});
const label = "Minimize what's new";
const minimize = dialog.getByRole('button', {name: label, exact: true});
await dialog
.getByRole('heading', {name: "What's new", exact: true})
.waitFor();
await minimize.hover();
const tooltip = page.getByRole('tooltip').filter({hasText: label});
await tooltip.waitFor();
await minimize.press('Escape');
await tooltip.waitFor({state: 'hidden'});
assert.ok(await dialog.isVisible());
assert.ok(
await minimize.evaluate(node => node === document.activeElement),
);
await page.keyboard.press('Escape');
await dialog.waitFor({state: 'hidden'});
await page.locator('[data-whats-new-trigger]:focus').waitFor();
},
),
);
await feature('whats-new-nudge', () =>
fresh(
{
name: 'whats-new-nudge',
layout: 'inspector',
viewport: {width: 1440, height: 900},
},
async ({page}) => {
const ready = () =>
page.locator('.cm-content[contenteditable="true"]').waitFor();
await page.goto(base, {waitUntil: 'domcontentloaded'});
await ready();
const sheet = page.locator('[data-whats-new="showcase"]');
await verifyShowcaseAction(sheet);
await page
.getByRole('button', {name: "Minimize what's new", exact: true})
.click();
await sheet.waitFor({state: 'hidden'});
const nudge = page.locator('[data-whats-new="nudge"]');
await nudge.waitFor();
await page.screenshot({
path: resolve(out, 'whats-new-nudge-collapsed.png'),
});
await nudge.getByRole('button', {name: 'See', exact: true}).click();
const step = n =>
nudge
.getByRole('img', {name: new RegExp(`^Step ${n} of \\d+$`)})
.waitFor();
await step(1);
await nudge.getByRole('button', {name: 'Next', exact: true}).click();
await step(2);
await page.screenshot({path: resolve(out, 'whats-new-nudge.png')});
await nudge
.getByRole('button', {name: "Dismiss what's new", exact: true})
.click();
await nudge.waitFor({state: 'hidden'});
const dismissed = () =>
page.evaluate(
() =>
new Promise(done => {
const open = indexedDB.open('keyval-store');
open.onerror = () => done([]);
open.onsuccess = () => {
const db = open.result;
const read = db
.transaction('keyval')
.objectStore('keyval')
.get('whats-new');
read.onsuccess = () => {
db.close();
done(read.result?.dismissed ?? []);
};
read.onerror = () => {
db.close();
done([]);
};
};
}),
);
const until = Date.now() + 5000;
while ((await dismissed()).length === 0) {
assert.ok(Date.now() < until, 'the dismissal reaches IndexedDB');
await page.waitForTimeout(100);
}
await page.reload({waitUntil: 'domcontentloaded'});
await ready();
await page.waitForTimeout(3000);
assert.equal(
await page
.locator('[data-whats-new="showcase"], [data-whats-new="nudge"]')
.count(),
0,
'a dismissed announcement stays away after a reload',
);
},
),
);
}
Loading
Loading