Release pass: wording, colour-blind-safe colours, map visibility, phone layout

Walked every tab on desktop and phone, clicked every link and button:
- Colours: new map inks and page colours, checked with simulated
  protanopia/deuteranopia/tritanopia (worst pair ~12 CIEDE2000, was 1.4 for
  Red/Green on the map and 9.7 for Orange/Brown on the page). Map label text
  is always dark ink; dragon colour goes on borders. docs/COLOURS.md and
  research/python/check_colours.py.
- Valley map: dragons get a paper halo and a visibility floor (faded ones never
  drop below 0.3; bonding dragons start at 0.5); "no shadow" roll labelled
  correctly.
- Wording: methods updated (strata, the newer form's questions, missing
  answers, a new section on the solver, The Odds cards and genuine attempts);
  findings use readable factor names and no longer claim a date adjustment;
  'Load a newer route export above'; code links include solver.js and
  explorer.js; The Odds shows 93% instead of '1 in 1'.
- Deep Dive route map treats all six dragons alike ('Bond a dragon' row,
  default 'Bond any dragon'; rare sightings separate).
- Phone: Deep Dive no longer overflows (sections and selects can shrink).
- scripts/qa/crawl.js and mapcheck.js for future release checks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UCzTd31GphpMXDhQqWrCMQ
This commit is contained in:
ekcSchiano
2026-11-02 17:57:51 +00:00
co-authored by Claude Opus 5.5
parent 0ac5dfd971
commit 7366af2f7d
11 changed files with 236 additions and 27 deletions
+11 -6
View File
@@ -188,9 +188,11 @@
const mx = (A.x + B.x) / 2 - (B.y - A.y) * bend, my = (A.y + B.y) / 2 + (B.x - A.x) * bend;
return { x: (1 - t) ** 2 * A.x + 2 * (1 - t) * t * mx + t * t * B.x, y: (1 - t) ** 2 * A.y + 2 * (1 - t) * t * my + t * t * B.y };
};
function pill(g, x, y, text, { ink = PAPER.ink, strong = false, bg = PAPER.halo } = {}) {
// label text is always dark ink (light dragon colours like Orange are unreadable as text on paper);
// the dragon's colour goes on the border instead
function pill(g, x, y, text, { ink = PAPER.ink, edge = null, strong = false, bg = PAPER.halo } = {}) {
const w = 10 + text.length * (strong ? 7.2 : 6.4), h = strong ? 20 : 17;
el("rect", { x: x - w / 2, y: y - h / 2, width: w, height: h, rx: h / 2, fill: bg, "fill-opacity": 0.95, stroke: ink, "stroke-opacity": 0.4 }, g);
el("rect", { x: x - w / 2, y: y - h / 2, width: w, height: h, rx: h / 2, fill: bg, "fill-opacity": 0.95, stroke: edge || ink, "stroke-opacity": edge ? 0.95 : 0.4, "stroke-width": edge ? 2 : 1 }, g);
el("text", { x, y: y + (strong ? 4.5 : 4), "text-anchor": "middle", "font-size": strong ? 12.5 : 11, "font-weight": strong ? 700 : 500, fill: ink, "font-family": "var(--font-data)" }, g).textContent = text;
}
@@ -201,15 +203,18 @@
const P = L[sp.place];
if (!P) return;
const n = st.counts[sp.place];
let op = n == null ? 0.85 : 0.22 + 0.78 * Math.sqrt(n / (sp.first ? maxF : maxN));
// faint = rarely met, but never so faint it disappears (bonding dragons keep a higher floor)
let op = n == null ? 0.85 : (sp.first ? 0.35 : 0.5) + (sp.first ? 0.65 : 0.5) * Math.sqrt(n / (sp.first ? maxF : maxN));
const isTarget = st.colour && !sp.first && (encColour(sp.enc) === st.colour || RESCUE[st.colour] === sp.enc);
if (st.colour && !isTarget) op *= 0.35;
if (st.colour && !isTarget) op = Math.max(0.3, op * 0.5); // faded, but never lost
if (isTarget) op = Math.max(op, 0.9);
const w = 200 * sp.sc, hgt = 160 * sp.sc;
const x = P.x - w / 2 + (sp.dx || 0), y = P.y - hgt * 0.7 + (sp.dy || 0);
const gg = el("g", { class: "ex-dragon", transform: `translate(${x} ${y}) scale(${sp.sc})`, opacity: op.toFixed(2), tabindex: sp.twin ? null : 0, role: sp.twin ? null : "button",
"aria-label": sp.first ? `${sp.colour} dragon, first sighting` : `${ENC_NAME[sp.enc]}. Show the routes to it.` }, g);
if (isTarget && routesOn) el("ellipse", { cx: 100, cy: 140, rx: 80, ry: 16, fill: INK[sp.colour], "fill-opacity": 0.25 }, gg);
// a soft paper-coloured halo keeps dark dragons readable on the dark canopy
gg.innerHTML += `<g stroke="${PAPER.halo}" stroke-width="9" stroke-linejoin="round" opacity="0.55">${D.svg(sp.pose, { fill: PAPER.halo, eyeFill: PAPER.halo, flip: sp.flip })}</g>`;
gg.innerHTML += D.svg(sp.pose, { fill: INK[sp.colour], flip: sp.flip });
el("rect", { x: 0, y: 0, width: 200, height: 160, fill: "transparent" }, gg);
if (sp.twin) return;
@@ -318,11 +323,11 @@
if (p > 0.995) return;
// the last roll leads straight into the dragon, whose own label sits there: put the roll under the fork point
const at = !ro.at ? { x: ro.P.x + 34, y: ro.P.y - 22 } : ro.at === pts.length - 1 ? { x: pts[ro.at - 1].P.x, y: pts[ro.at - 1].P.y + 24 } : mid(pts[ro.at - 1].P, pts[ro.at].P, 0.38);
pill(gLab, at.x, at.y, ro.s.var === "shadow" ? `shadow ${pct(p)}` : `roll ${pct(p)}`);
pill(gLab, at.x, at.y, ro.s.var === "shadow" ? (ro.s.taken === "yes" ? `shadow ${pct(p)}` : `no shadow ${pct(p)}`) : `roll ${pct(p)}`);
});
// destination label
const end = pts[pts.length - 1];
pill(gLab, end.P.x, end.P.y + 30, `${pct(r.value.x)} per attempt`, { ink: tc, strong: rel === 1 });
pill(gLab, end.P.x, end.P.y + 30, `${pct(r.value.x)} per attempt`, { edge: tc, strong: rel === 1 });
// choice points on the focused route
if (focus) marks.forEach((m) => {
if (!m.at || m.s.var === "encounter") return;