Commit graph

57 commits

Author SHA1 Message Date
Frederic Jung
4e95b9b397
CI: translation coverage job
A separate 'translations' job runs the i18n checker on every push and
PR and writes a coverage table per language to the run summary, with
the missing, broken and unused keys listed. The checker now also fails
when a language file is not offered in SOT_LANGS or cached in sw.js.
2026-10-26 06:04:28 +01:00
Frederic Jung
5786f76ed9
Rework the phone layout and make the game installable
Phones get a one-row status strip, a bottom tab bar (play, speed, goals,
deals, NOC, networks) and draggable bottom sheets; in landscape the sheets
slide in from the side. Toasts can be tapped away, dialogs become bottom
sheets and the title screen keeps its start button in reach.

Adds a service worker for offline play and an install button (the
browser prompt on Android, instructions on iOS).
2026-10-24 22:52:55 +02:00
Danilo Carbonaro
42711456e2 Tidy the i18n layer after review
- Badges that react to sharks, anchors, crocodiles and llamas read the
  English text of the incident again, so they unlock in every language.
- Scenario names are looked up when shown, so they follow a language switch.
- Fall back to English (and lang="en") when the dictionary did not load,
  and version the dictionary URL so a release never pairs with a stale one.
- Share the segmented-button helper between settings and the title screen,
  merge keys that only differed in a placeholder name, and slim the check
  script.
- Tests: guard the hooks the tour patches into fireFailure/fireEvent, and
  cover the dictionary fallback and the scenario name.
2026-10-24 21:52:27 +02:00
Danilo Carbonaro
04eb32e0a5 Add Italian translation and a language switch
English stays the source text and the default. Player-facing strings go
through tr()/trn(), which look the English up in a per-language dictionary
(site/i18n/<lang>.js) and fall back to it unchanged. The dictionary is only
loaded when the game runs in that language. The language follows the
browser on the first visit and can be switched under Settings or on the
title screen; the choice is remembered.

- site/i18n/it.js: complete Italian translation (~1900 entries)
- scripts/i18n-check.js / npm run i18n:check: lists missing or stale entries
  and translations that drop a {placeholder} or HTML tag
- tests/i18n.test.js: language selection, fallback, dictionary integrity,
  and a tour of every screen, failure and event in English and Italian
2026-10-24 21:52:27 +02:00
Frederic Jung
494d71793e
Fix map wrap, touch and keyboard input; harden build and release workflow; docs 2026-10-23 17:56:34 +02:00
Frederic Jung
e082d6fc60
Persist games across reloads and announce new releases
- Autosave every five seconds while playing, plus on pagehide and when
  the tab is hidden. On load, a saved game resumes immediately (same
  speed and camera) instead of waiting behind the title screen.
- The build turns this version's CHANGELOG section into release notes:
  baked into the page for a one-time "What's new" card for returning
  players, and published as /version.json.
- Open games poll /version.json every 10 minutes and when the tab comes
  back into view; if a newer release is out, a banner offers to save
  and reload.
- "Start a new network" moves into the help screen, behind a confirm.
2026-10-23 11:42:28 +02:00
Frederic Jung
1685a045e6
Series of Tubes 1.0.0
A cartoon browser game about building the internet, deployed to
https://seriesoftub.es from published releases only.

- site/: the single-file game plus favicons, app icons, manifest,
  social image, robots.txt, sitemap.xml, llms.txt and a 404 page.
- Full SEO head: canonical URL, Open Graph and Twitter cards,
  WebSite and VideoGame structured data, noscript fallback.
- Cookieless Ridiculytics analytics via stats.seriesoftub.es, pinned
  with SRI and active only on the production domain.
- Headless test suite (node:test + jsdom), CI on every push, and a
  release workflow that verifies the tag, tests, builds, deploys to
  GitHub Pages and pings IndexNow.
2026-10-23 09:01:39 +02:00