From 49b77e0700ce4e6834578c57ce9a14f8e70974d5 Mon Sep 17 00:00:00 2001 From: BenStullsBets Date: Mon, 29 Jun 2026 18:47:03 -0700 Subject: [PATCH] feat(i18n): tag controls with data-i18n + add language dropdown Co-Authored-By: Claude Opus 4.8 (1M context) --- simulator/static/index.html | 28 ++++++++++++++++------------ simulator/unit/index-i18n.test.js | 19 +++++++++++++++++++ 2 files changed, 35 insertions(+), 12 deletions(-) create mode 100644 simulator/unit/index-i18n.test.js diff --git a/simulator/static/index.html b/simulator/static/index.html index f790bde..ce60563 100644 --- a/simulator/static/index.html +++ b/simulator/static/index.html @@ -9,11 +9,11 @@
-
Loading Universe
+
Loading Universe
-

Human Experience Filter — Alteration Preview

+

Human Experience Filter — Alteration Preview

@@ -31,39 +31,42 @@
- Output + Output + -
- Altitude + Altitude
-

Turn the knob (drag it, or scroll) to change altitude — endless: past the deepest it wraps back up to the highest. Click a label to jump there.

+

Turn the knob (drag it, or scroll) to change altitude — endless: past the deepest it wraps back up to the highest. Click a label to jump there.

- Experience knobs (0–4) - - - + Experience knobs (0–4) + + +
+ diff --git a/simulator/unit/index-i18n.test.js b/simulator/unit/index-i18n.test.js new file mode 100644 index 0000000..345c3c2 --- /dev/null +++ b/simulator/unit/index-i18n.test.js @@ -0,0 +1,19 @@ +"use strict"; +const test = require("node:test"); +const assert = require("node:assert/strict"); +const fs = require("node:fs"); +const path = require("node:path"); +const I = require("../static/i18n.js"); + +const html = fs.readFileSync(path.join(__dirname, "../static/index.html"), "utf8"); + +test("index.html includes the i18n script and a language select", () => { + assert.match(html, /