Let the canvas endpoints be moved, and lift them on hover

Three things they were missing: they could not be dragged out of the lane
they were placed in, they stayed the same weight whether or not you were
reaching for one, and the label sat right against its connector dot.

Where one has been dragged to is a view preference, not part of the flow —
writing a position for a dashboard widget into flow.json would be a lie
about what the document holds — so it lives in the browser, keyed by flow.

Also folds the dashboard shot into `make verify` and drops the one-off
scripts that had accumulated beside it; the durable coverage is the
Playwright specs, which all pass.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011LF61rxW1FG5YCD2J9YqjY
This commit is contained in:
2026-08-16 16:07:07 +02:00
co-authored by Claude Fable 5
parent 75c26ef000
commit c70359af67
9 changed files with 129 additions and 318 deletions
+26 -1
View File
@@ -62,15 +62,40 @@ for (const theme of ["light", "dark"]) {
await page.screenshot({ path: `${dir}/app-dashboard.png` })
await captureFlows(page, dir)
await captureDashboards(page, dir)
await context.close()
console.log(
` wrote ${dir}/{website-hero,app-login,app-dashboard,app-flows,app-flow-panel}.png`,
` wrote ${dir}/{website-hero,app-login,app-dashboard,app-flows,app-flow-panel,app-panel}.png`,
)
}
await browser.close()
/**
* A dashboard as a wall panel sees it. Seeds one if the instance has none, so
* the shot shows the grid rather than an empty-state message.
*/
async function captureDashboards(page, dir) {
await page.goto(`${APP_URL}/dashboards`, { waitUntil: "networkidle" })
if (!(await page.getByTestId("dashboard-card").count())) {
await page.getByTestId("new-dashboard-name").fill("panel")
await page.getByTestId("create-dashboard").click()
await page.waitForURL(/\/dashboards\/.+/, { timeout: 15000 })
// A widget, so the grid has something in it worth photographing.
await page.getByTestId("add-widget-stat").click()
await page.waitForSelector("[data-testid=widget-settings]")
await page.getByTestId("toggle-edit").click()
} else {
await page.getByTestId("dashboard-card").first().click()
await page.waitForURL(/\/dashboards\/.+/, { timeout: 15000 })
}
await page.waitForTimeout(1500)
await page.screenshot({ path: `${dir}/app-panel.png` })
}
/**
* The flow editor, empty-handed if the instance has no flows yet: seeds one
* with a node so the canvas and the node panel are both worth looking at.