Skip to content

kit-206-viewer-reload-hint: The artifact viewer's reload button shows an orange outline when the artifact changed since it was loaded - #242

Merged
hhff merged 10 commits into
mainfrom
ticket/kit-206-viewer-reload-hint
Nov 15, 2026
Merged

hhff merged 10 commits into
mainfrom
ticket/kit-206-viewer-reload-hint

Conversation

@hhff

@hhff hhff commented Nov 15, 2026

Copy link
Copy Markdown
Member

The artifact viewer's reload button now says when the artifact on the stage has changed since its frame loaded it. It gets a 2px outline in the warning colour (--amber, light and dark) and the title "A newer version is ready: reload to see it". Pressing reload loads the new version and clears the outline. Nothing reloads by itself. This holds until kit-106's live reload of drafts takes over.

  • The dashboard checks the fingerprint on its normal /api/data poll, using the Library's rows for the draft or main shown.
  • A viewer tab asks /api/view every 10 s while the tab is visible, for main or a draft only, one ask at a time, with a 15 s abort. A published tree and a preview are never checked.
  • TS.fp stays the fingerprint the frame loaded. TS.fpNow and TS.mainFpNow hold the latest seen. Reload moves fp and mainFp forward, and only to values it knows.

Records: docs/devteam-dev/tickets/kit-206-viewer-reload-hint/ (spec, plan, reviews, verification, and screenshots in light and dark).

How to verify

  • node --test --test-name-pattern "reload button says" test/dashboard.test.mjs (needs Chrome and a Node with WebSocket, 22+). It opens a draft on the dashboard and in a viewer tab, changes the file, and waits for the outline within one poll. It checks the colour in light and dark, checks that nothing reloads by itself, and checks that the press loads the change. It also checks that a tree is never polled.
  • CI: test.yml, every job.

One-way doors

None.

🤖 Generated with Claude Code

hhff and others added 10 commits November 15, 2026 01:29
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…iew (changes), fixes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@hhff
hhff merged commit 07f7d1b into main Nov 15, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant