Commit Graph
3 Commits
Author SHA1 Message Date
bonaminandClaude Opus 5.5 e612e2436c feat(terminal): the signage player: playlists on a TV, offline, transitions, rotation (platform-v2 step 5.5a)
- terminal/src/apps/signage: plays the screen's playlist (or the one its
  schedule picks now, switching by itself) full screen: slides in order with
  their time, a video to its end (a 15 min safety limit), only in their days /
  hours / dates; transitions fade / slide / zoom / none (CSS, reduced motion
  respected); the frame turned 90/180/270 for a TV mounted sideways. Picture,
  video and text slides drawn; a first menu board (5.5b lays it out fully).
- Offline: the last GET /api/signage/screen kept in localStorage, every
  picture and video (up to 120 MB) as an in-memory copy; reads again on
  signage.changed / device.updated / reconnect / every 5 min.
- logic.js: the server's schedule pick ported (same test cases), slide windows,
  next slide, frame; tests/signage.test.mjs (6).
- Signage screens get no offline banner over the slides, a small mark instead
  (registry QUIET_OFFLINE).
- e2e signage.mjs (in run-all): a paired TV plays picture → text → video →
  menu in order, the text's slide transition, rotation, keeps playing with the
  server stopped (mark, no banner), catches up when it is back. terminal.mjs
  passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-17 19:40:35 +02:00
bonaminandClaude Opus 5.5 c24cb72640 feat(terminal): pairing, sign-in per mode, device app router and live states (platform-v2 3.1c)
- Pairing screen: requests a code, shows it big, polls with the secret, new code on
  expiry, keeps the device token; "removed from the venue" notice after a revoke.
- Sign-in per device mode: PIN (name + PinPad), tap your name, password (name +
  password), none (straight into the app). Names = holders of <app>.access, refreshed
  every 30 s and on reconnect. Slim bar with screen, user and Sign out; idle sign-out
  after the device's auto_sign_out_minutes; hourly token refresh (same session).
- DeviceProvider: GET /api/devices/me (retried while unreachable), session, the live
  connection with credentials in the first frame (device.updated -> reload, app moved ->
  sign out, device.revoked -> forget, session.ended -> sign out), offline banner;
  useLiveEvent for apps. Screen choice is pure (device/flow.js, unit-tested).
- Blocked screen: app turned off / not licensed / device refused, recovers by itself.
- @xenia/access AccessProvider: autoRetryMs (retry bootstrap while unreachable).
- Tests: terminal unit tests (screen choice, live actions, idle, pairing polls), new
  tests/e2e/terminal.mjs (18 checks), manager.mjs owner flow now pairs and signs in on
  the real terminal screen; run-all runs terminal.mjs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 17:29:18 +02:00
bonaminandClaude Opus 5.5 7ff3c3b48e feat(terminal): terminal app shell, pos-terminal image, LAN-only proxy port 8082 (platform-v2 3.1b)
- terminal/: new workspace app (Vite + React 19 + Router 7, Tailwind on the shared
  preset, @xenia/i18n namespace `terminal`, @xenia/api client sending X-Xenia-Device,
  @xenia/access bootstrap). Apps are lazy chunks by app_key (kds, pos_counter,
  customer_display placeholders); start screen; "unknown app" screen; dev-only
  /ui-gallery and /i18n-sample. Device + session tokens in a storage wrapper.
- Image pos-terminal (terminal/Dockerfile, context client-services/); every frontend
  Dockerfile copies terminal/package.json for npm ci.
- docker-compose(.dev).yml: service terminal; proxy publishes 8082.
- Proxy (nginx-proxy/nginx.conf == install.sh heredoc, CS-5): server :8082, LAN-only
  allow/deny, WebSocket upgrade; the terminal upstream is resolved per request so the
  proxy still starts on a stack without the terminal container.
- install.sh prints the screens address.
- Tests: terminal unit tests + lint in run-all; new tests/e2e/stack.mjs (release images
  on one compose stack: :8082 serves the app, /api + WebSocket through both hops,
  403 from a non-LAN docker network on 8082 and 8081, proxy up without terminal).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-14 17:02:20 +02:00