Lattice
연구를 위한 작업공간
Countdown and music
README 전체를 불러오는 중입니다.
README 전문 보기 ↗A full-screen countdown with your own music — a desktop web app. Live at ticktune.net · GPL-3.0-only · Vietnamese, English and Japanese
Set a countdown, bring your own music — local files or YouTube links — and get a big seven-segment clock behind smoked glass, styled like a piece of broadcast studio hardware. When it reaches zero, a configurable End Behavior fires.
Your files never leave your browser.
Alt+↑/↓, shuffle and repeat) and
YouTube (up to 50 links, played through YouTube's own embedded player,
with each link's length looked up so "Match queue length" works there too).endAt − now on every
tick, so it does not drift. Below 60 s it shows milliseconds.docs/04 §2)./app/ installs as an app, and once
visited it opens without a network; local files play as ever (YouTube needs
one).Space play/pause, ←/→ tracks, ↑/↓ volume, M mute,
F fullscreen, H Focus, S settings — the full table is in the app.Desktop only, by design. Phones and tablets get a notice instead of the app
(docs/07) — the experience is a large clock on a large screen.
| Mode | Items | Per track | Total | Countdown |
|---|---|---|---|---|
| Single | 1 local file | ≤ 10:02 | — | 1 s – 24 h |
| Playlist | ≤ 95 local files | ≤ 10:02 | ≤ 91:00 | 1 s – 24 h |
| YouTube | ≤ 50 links | — | — | 1 s – 24 h |
Missing metadata shows as N/A (text) or – (numbers), never as a blank.
youtube-nocookie.com; link
titles and lengths are looked up through this site's own /api/yt/oembed
and /api/yt/durations routes, which forward only the video IDs — from the
server, with its own key — and cache each answer for a day. Pasted playlists
(up to ten) go through /api/yt/playlists, which forwards only the playlist
IDs and keeps what each holds for an hour.Requirements: Node 26 LTS and pnpm 11 (npm install -g pnpm@11; Node 26 ships no
corepack).
pnpm install
pnpm dev # astro dev → http://localhost:4321
pnpm build # astro build + CSP hash + third-party notices + size budget
pnpm lint # eslint + prettier --check
pnpm check # astro check + svelte-check + worker tsc
pnpm knip # unused files, exports and dependencies
pnpm test # Vitest: unit + component + worker, with coverage
pnpm test:e2e # Playwright: Chromium, Firefox, WebKit + the mobile gate
pnpm verify:csp # the real CSP in a browser, under wrangler dev
pnpm lhci # Lighthouse CI on the built static pages
pnpm test:visual:docker # screenshots, in the pinned Playwright image (--update to rewrite)
pnpm perf:render # the countdown's frame cost, headed (TT_PERF_SOFTWARE=1: no GPU)
pnpm fixtures regenerates the audio fixtures, pnpm demo re-records the
landing page's hero video, and node scripts/make-brand-assets.mjs rasterises
the favicon and the social card. The test/ folder is a local-only audio corpus
for the audio spikes; it is git-ignored and guarded out of every commit.
Astro 7 static pages, plus one Svelte 5 island at /app/, mounted by hand
behind the mobile gate rather than with a client directive (docs/01 §3). The
engines — timer, audio, import, queue, YouTube — are pure TypeScript under
src/app/engine/; state lives in Svelte 5 runes stores. It is served by
Cloudflare Workers Static Assets with three Worker routes —
GET /api/yt/oembed, GET /api/yt/durations and GET /api/yt/playlists — the
last two holding the YouTube Data API key as a Worker secret.
Production changes only when a signed vX.Y.Z tag is pushed: deploy.yml
verifies the signature and that the tag is on main, runs the gates, deploys,
and publishes the GitHub Release. Every other push only uploads a preview
version (docs/14).
The docs/ suite is authoritative; CLAUDE.md is its condensed contract.
| Chapter | Contents |
|---|---|
01-ARCHITECTURE | System shape, module map, the island mount |
02-DATA-FLOW | State machine, track model, import pipeline, settings schema |
03-UI-SPEC | The "Rack Unit" design system, layout zones, ToS carve-out |
04-TIMER-ENGINE | Derived time, the worker tick, the background-tab promise |
05-AUDIO-ENGINE | Web Audio graph, End Behavior, visualizer |
06-YOUTUBE-INTEGRATION | IFrame Player, ToS constraints, error causes, oEmbed |
07-MOBILE-GATE | The site-wide desktop gate |
08-I18N | VI/EN/JA for the static pages and the app |
09-SECURITY | Threat model, headers, CSP |
10-CLOUDFLARE-SETUP | Zone, Worker and dashboard configuration |
11-DEPENDENCIES | Versions, licences, the notices rule |
12-CODE-STANDARDS | Conventions and the log-code registry |
13-TESTING | Test tiers and the live-site checklists |
14-CI-CD | Workflows, permissions, the release path |
15-SPIKES | The validation spikes and their results |
16-ROADMAP | Phases, exit reviews, what is next |
TickTune is built with Claude Code, Anthropic's coding assistant: the
Claude Opus 4.8 model for 0.2.0–1.0.0 (July 2026), Claude Opus 5.5 from
1.1.0 (October 2026). The developer directs and reviews every change, and each
commit made with the assistant carries a Co-Authored-By trailer, so the
history shows which. CLAUDE.md is the contract it works under. The
app itself has no AI features and sends nothing to any AI service — the
Disclaimer §7 says the same.
Read CONTRIBUTING.md first — especially the hard invariants in
CLAUDE.md, which no change may break.
ACCESSIBILITY.md is the accessibility statement: what is built in, what has been tested, what is known not to work, and how to report a barrier — the Accessibility barrier issue form, or [email protected].
Please report vulnerabilities privately: [email protected], or GitHub's private vulnerability reporting. Details in SECURITY.md.
| For | Address |
|---|---|
| Press | [email protected] |
| Collaboration | [email protected] |
| Privacy | [email protected] |
| Terms and legal | [email protected] |
| Licensing and attribution | [email protected] |
| Accessibility barriers | [email protected] |
Copyright © 2026 poli0981.
TickTune is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License, version 3 only, as published by the Free Software Foundation. It is distributed in the hope that it will be useful, but without any warranty; without even the implied warranty of merchantability or fitness for a particular purpose. See LICENSE.
Bundled fonts are under the SIL Open Font License 1.1; every third-party
component is listed in
Third-Party Notices, and the full
licence texts ship at /THIRD-PARTY-NOTICES.txt.