ZDDC/tests
ZDDC 7fd96c7c78 feat(shared): clickable logo links every tool's header to project home
The .app-header__logo SVG was decorative on every tool. Web's
strongest convention is "click logo → go home" — so users tapping
it expecting that fallback got nothing. Now the logo is wrapped in
an anchor whose href reflects the URL the page was loaded from:

  file://                    → no wrap (no server home to point at)
  /                          → wrap, href=/         (deployment root)
  /index.html / /<tool>.html → wrap, href=/         (root, no project)
  /<project>/...             → wrap, href=/<project> (project landing)

The wrap happens client-side at DOMContentLoaded via shared/logo.js,
loaded by every tool's build.sh after toast/nav. Idempotent — a
template-supplied anchor or a second mount call is a no-op.

The companion shared/logo.css adds a subtle hover/focus affordance
(opacity 0.82, focus ring) so the logo reads as clickable without
otherwise altering its visual weight. Tools opt out by setting
window.zddc.logo.disabled = true before DOMContentLoaded (e.g. for
deployments that pin the logo to an external destination).

Five Playwright tests (tests/logo.spec.js) lock the contract:
no-wrap on file://, href=/ at root, href=/<project> in project
subtree, aria-label matches target, idempotent re-mount.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-10 07:34:28 -05:00
..
data test: add tests/data/test-archive.sh — synthetic ZDDC fixture builder 2026-05-08 09:03:38 -05:00
fixtures Initial commit 2026-04-27 11:05:47 -05:00
lib test: server-backed Playwright harness + /.tokens spec 2026-05-08 10:09:54 -05:00
archive-cascade.spec.js feat: lockstep release infra + cascade/.archive fixes + profile perf + page redesign 2026-05-01 20:11:38 -05:00
archive.spec.js feat(tools,build): in-flight HTML-tool reworks and build-infra updates 2026-04-29 12:52:27 -05:00
browse.spec.js test(browse): smoke test for empty state and mock-fs row render 2026-05-09 18:39:17 -05:00
build-label.spec.js refactor: HTML tools live in website/releases/ as static files + symlink hierarchy 2026-04-30 09:40:16 -05:00
classifier.spec.js Initial commit 2026-04-27 11:05:47 -05:00
form-safety.spec.js refactor(tables): in-dir convention + unified table+form HTML bundle 2026-05-09 09:15:26 -05:00
landing.spec.js feat(landing): single-project click navigates to <project>/archive.html 2026-05-09 19:46:14 -05:00
logo.spec.js feat(shared): clickable logo links every tool's header to project home 2026-05-10 07:34:28 -05:00
mdedit.spec.js feat(tables): new sortable/filterable grid tool for directories of YAML files 2026-05-05 20:32:01 -05:00
nav.spec.js style(nav): mount stage strip above the header instead of below 2026-05-09 20:27:23 -05:00
schema.spec.js Initial commit 2026-04-27 11:05:47 -05:00
tables.spec.js feat(tables): editable cells phase 5 — undo + multi-cell ops 2026-05-09 10:39:26 -05:00
toast.spec.js feat(shared): non-blocking toast helper available to every tool 2026-05-09 19:04:41 -05:00
tokens.spec.js test: server-backed Playwright harness + /.tokens spec 2026-05-08 10:09:54 -05:00
transmittal-drag-drop.spec.js Initial commit 2026-04-27 11:05:47 -05:00
transmittal-init-check.spec.js Initial commit 2026-04-27 11:05:47 -05:00
transmittal.spec.js Initial commit 2026-04-27 11:05:47 -05:00
zddc-filter.spec.js Initial commit 2026-04-27 11:05:47 -05:00
zddc-source.spec.js test(shared): smoke tests for the zddc-source.js FS-Access polyfill 2026-05-09 18:49:11 -05:00
zddc.spec.js Initial commit 2026-04-27 11:05:47 -05:00