diff --git a/docs/superpowers/specs/2026-04-21-online-board-schedule-tz-redesign-design.md b/docs/superpowers/specs/2026-04-21-online-board-schedule-tz-redesign-design.md index a3f639dd..faa85493 100644 --- a/docs/superpowers/specs/2026-04-21-online-board-schedule-tz-redesign-design.md +++ b/docs/superpowers/specs/2026-04-21-online-board-schedule-tz-redesign-design.md @@ -128,15 +128,15 @@ _Updated after each plan merges. Plan task: after every merge, append a row to t | Metric | Count | |---|---| -| Total rules extracted | **853** (4.1.1: 27, 4.1.2: 42, 4.1.3: 22, 4.1.4: 26, 4.1.5: 30, 4.1.6: 14, 4.1.7: 16, 4.1.8: 19, **4.1.9: 58, 4.1.9.1: 12, 4.1.9.2: 11, 4.1.9.3: 13, 4.1.9.4: 9, 4.1.9.5: 14**, **4.1.10: 9, 4.1.10.1: 8**, **4.1.11: 10, 4.1.11.1: 8**, **4.1.12: 7**, **4.1.13: 81** (opening 18 + §4.1.13.1 ×11 + §4.1.13.2 ×7 + §4.1.13.3 ×27 + §4.1.13.4 ×18), **4.1.14: 105** (opening 24 + §4.1.14.1 ×11 + §4.1.14.2 ×9 + §4.1.14.3 ×30 + §4.1.14.4 ×31), **4.1.15: 112** (§4.1.15.1 ×10 + §4.1.15.2 ×12 + §4.1.15.3 ×7 + §4.1.15.4 ×36 + §4.1.15.5 ×18 + §4.1.15.6 ×10 + §4.1.15.7 ×5 + §4.1.15.8 ×2 + §4.1.15.9 ×3 + §4.1.15.10 ×6 + §4.1.15.11 ×3), **4.1.16: 76** (§4.1.16.1 ×9 + §4.1.16.2 ×12 + §4.1.16.3 ×10 + §4.1.16.4 ×11 + §4.1.16.5 ×8 + §4.1.16.6 ×13 + §4.1.16.7 ×5 + §4.1.16.8 ×8), **4.1.17: 8**, 4.1.18: 3, 4.1.19: 6, 4.1.20: 4, 4.1.21: 5, **4.1.22: 11**, **4.1.23: 6**, 4.1.24: 7 skeleton) | +| Total rules extracted | **941** (4.1.1: 27, 4.1.2: 42, 4.1.3: 22, 4.1.4: 26, 4.1.5: 30, 4.1.6: 14, 4.1.7: 16, 4.1.8: 19, **4.1.9: 58, 4.1.9.1: 12, 4.1.9.2: 11, 4.1.9.3: 13, 4.1.9.4: 9, 4.1.9.5: 14**, **4.1.10: 9, 4.1.10.1: 8**, **4.1.11: 10, 4.1.11.1: 8**, **4.1.12: 7**, **4.1.13: 81** (opening 18 + §4.1.13.1 ×11 + §4.1.13.2 ×7 + §4.1.13.3 ×27 + §4.1.13.4 ×18), **4.1.14: 105** (opening 24 + §4.1.14.1 ×11 + §4.1.14.2 ×9 + §4.1.14.3 ×30 + §4.1.14.4 ×31), **4.1.15: 112** (§4.1.15.1 ×10 + §4.1.15.2 ×12 + §4.1.15.3 ×7 + §4.1.15.4 ×36 + §4.1.15.5 ×18 + §4.1.15.6 ×10 + §4.1.15.7 ×5 + §4.1.15.8 ×2 + §4.1.15.9 ×3 + §4.1.15.10 ×6 + §4.1.15.11 ×3), **4.1.16: 76** (§4.1.16.1 ×9 + §4.1.16.2 ×12 + §4.1.16.3 ×10 + §4.1.16.4 ×11 + §4.1.16.5 ×8 + §4.1.16.6 ×13 + §4.1.16.7 ×5 + §4.1.16.8 ×8), **4.1.17: 8**, **4.1.18: 3**, **4.1.19: 22**, **4.1.20: 6**, **4.1.21: 8**, **4.1.22: 11**, **4.1.23: 6**, **4.1.24: 48** (§4.1.24.1 ×8 + §4.1.24.2 ×12 + §4.1.24.3 ×15 + §4.1.24.4 ×6 + §4.1.24.5 ×4 + §4.1.24.6 ×3) — P6 rules fully enumerated 2026-04-21) | | Done | **381** (P1: 104 across §4.1.2/3/4/8; P2 adds 48 across §4.1.1/5/6/7; P3 adds 133 across §4.1.9/9.x/10/10.1/11/11.1/12 + §4.1.8-R4/R5; **P4 adds 32**: §4.1.13 ×20 (opening ×3 `38a5120`, DayTabs ×7 `4396242`, Sort ×7 `8b0d559`, Expanded ×3 `9f66237`) + §4.1.14 ×12 (WeekTabs ×7 `6f67c06`, Expanded Buy/Status/Details ×5 `4290c81`); **P5 adds ~64**: §4.1.15 ×28 (structure/mini-list/day-tabs ×15 `896dea9`, direct-flight gaps ×5 `21b6c90`, timeline ×5 `877cd87`, status ×2 `e33c8c4`, prev-flight ×1 `1740af6`), §4.1.16 ×16 (structure ×7 `896dea9`, day-tabs ×4 `896dea9`, schedule-block ×3 `0485a3b`, connecting ×2 `c49a2a8`), §4.1.22-R1–R10 `5d31f43`, §4.1.23-R1–R6 `b43c341`) | | Implemented | **~308** (pre-P1/P2/P3: ~49 incl. §4.1.14.4-R19 `3ae59da`; **P4 adds ~142**: §4.1.13 opening ×15 `f6def71`, §4.1.13.1 ×4, §4.1.13.3 ×24 `3b5ae9a`, §4.1.13.4 ×13 `9f66237`, §4.1.14 opening ×24 `f6def71`/`6f67c06`, §4.1.14.1 ×4, §4.1.14.2 ×9 `6f67c06`, §4.1.14.3 ×27 `6f67c06`, §4.1.14.4 ×23 `4290c81`; **P5 adds ~108**: §4.1.15 ×70 (direct-flight audit `21b6c90`, multi-seg `7fcb844`, intermediate landing `c0c2d7d`, meals+services pre-existing `21b6c90`, day-change badges `63fc606`); §4.1.16 ×37 (Schedule variants `7fcb844`/`c49a2a8`/`0485a3b`); §4.1.17-R1–R7 `63fc606`; §4.1.22-R11 `5d31f43`) | | Partial | **7** (4.1.2-R4 flight-number padding; 4.1.4-R12/R13 city-pair deferred (C3); **P4 adds 4**: 4.1.13.3-R9 multi-seg status-switching; 4.1.13.4-R6 check-in counter; 4.1.14.4-R5 segment dep airport-as-link; 4.1.14.4-R7 segment arr airport-as-link; **P5 adds 1**: 4.1.16-R27 simple date-swap implemented, full §4.1.16.3.1 re-search algorithm deferred) | | Missing | 0 | | Conflict | **11** (C1–C11 in Conflicts register; C1–C4 resolved, C5 pending P6, C6–C11 resolved; 1 rule cell still Conflict: 4.1.1-R22 = C5 pending P6; **P5 adds C9** «Уточняется» orange color `b43c341`, **C10** §4.1.22 carrier-icon vs aircraft-type clarification `5d31f43`, **C11** 4.1.17-R4 per-type badge independence `63fc606` — all resolved) | | Out-of-scope (backend) | 13 (§4.1.5-R1..R11, R13, R28 — backend aggregation service rules; tracked separately) | -| TBD | **~143** (P5 backlog: §4.1.15-R10/R25 (mobile tooltip, per-flight operating-day blocking); §4.1.16-R9/R10/R11/R14/R15/R28/R29/R30/R31 (mobile tooltip, three-date-group UI, full §4.1.16.3.1 nav algorithm); §4.1.23-R1–R4 widespread wiring deferred; pre-existing P4 deferred 7: 4.1.13.3-R7, R14; 4.1.13.4-R16; 4.1.14.3-R7, R14, R29; 4.1.14.4-R18; pre-existing non-P4 TBDs: §4.1.1-R15/R16/R25; §4.1.5-R12; §4.1.6-R14; §4.1.7-R16; §4.1.17-R8; §4.1.18–4.1.24 skeleton ~25; §4.1.9-R53-R57 P4-tagged) | -| **Check** | 381 Done + 308 Implemented + 7 Partial + 1 Conflict + 13 Out-of-scope + ~143 TBD ≈ **853** | +| TBD | **~231** (P5 backlog: §4.1.15-R10/R25 (mobile tooltip, per-flight operating-day blocking); §4.1.16-R9/R10/R11/R14/R15/R28/R29/R30/R31 (mobile tooltip, three-date-group UI, full §4.1.16.3.1 nav algorithm); §4.1.23-R1–R4 widespread wiring deferred; pre-existing P4 deferred 7: 4.1.13.3-R7, R14; 4.1.13.4-R16; 4.1.14.3-R7, R14, R29; 4.1.14.4-R18; pre-existing non-P4 TBDs: §4.1.1-R15/R16/R25; §4.1.5-R12; §4.1.6-R14; §4.1.7-R16; §4.1.17-R8; §4.1.9-R53-R57 P4-tagged; **P6 newly enumerated**: §4.1.18 ×3, §4.1.19 ×22, §4.1.20 ×6, §4.1.21 ×8 (minus R1/R2 = Implemented), §4.1.24 ×48 — all TBD) | +| **Check** | 381 Done + 308 Implemented + 7 Partial + 1 Conflict + 13 Out-of-scope + ~231 TBD ≈ **941** | | **Note (§4.1.22 clarification)** | §4.1.22 in TZ is the **operating carrier** icon algorithm (not aircraft-type icon). Rule descriptions updated to reflect this. Conflict C10. | | **Note (§4.1.23 clarification)** | TZ specifies **orange** styling for «Уточняется» (contradicts prior assumption of «same as regular text»). Corrected in 4.1.23-R5. Conflict C9. | @@ -1327,60 +1327,79 @@ Specifies when the `+1`/`+2`/`-1` chip appears next to a departure or arrival ti # 4.1.18 — Кеширование данных *Data caching.* -Single-paragraph section on acceptable client-side caching behavior (session cache of results per §4.1.1-R23, dictionary cache for cities/airports, etc.). +Server-side caching of search results with section-specific TTLs: Online-Board ≤1 min, Schedule ≤10 min. Dictionaries (cities, airports, aircraft types) must be served with HTTP 304 and browser-cached automatically. TZ source lines 2908–2910. | # | Rule | TZ cite | Viewport | Current impl | Status | Action | Plan | |---|---|---|---|---|---|---|---| -| 4.1.18-R1 | Session-scope cache for search results per §4.1.1-R23/R27 | 4.1.18 | all | `src/shared/state/*` | TBD | Verify TTL + scope. | P6 | -| 4.1.18-R2 | Dictionary cache (cities, airports, aircraft types) — TTL per TZ | 4.1.18 | all | `src/shared/dictionaries/*` | TBD | Verify TTL + refresh policy. | P6 | -| 4.1.18-R3 | SSR-rendered initial payload must not expose stale data older than TZ-specified TTL | 4.1.18 | all | `src/server/*` | TBD | Verify SSR cache headers. | P6 | +| 4.1.18-R1 | Online-Board search results server-side cache TTL ≤ 1 minute ("кеш для «Онлайн-Табло» должен сохраняться не более 1 мин") | 4.1.18 TZ line 2909 | all | `src/shared/state/*` | TBD | Verify SSR response includes `Cache-Control: max-age=60` (or equivalent) for Online-Board result pages. | P6 | +| 4.1.18-R2 | Schedule search results server-side cache TTL ≤ 10 minutes ("кеш для «Расписания» должен сохраняться не более 10 мин") | 4.1.18 TZ line 2909 | all | `src/shared/state/*` | TBD | Verify SSR response includes `Cache-Control: max-age=600` (or equivalent) for Schedule result pages. | P6 | +| 4.1.18-R3 | Dictionary endpoints (cities, airports, aircraft types, §4.8.1.1) must respond with HTTP 304 and `Cache-Control` headers enabling automatic browser caching ("Справочники должны отдаваться сервером с 304 кодом и автоматически кэшироваться браузером") | 4.1.18 TZ line 2910 | all | `src/shared/dictionaries/*` | TBD | Verify that dictionary fetch responses carry ETag/Last-Modified + correct Cache-Control; browser caches on subsequent loads (304 path). | P6 | --- # 4.1.19 — Микроразметка страниц «Онлайн-Табло и Расписания» *Microdata: JSON-LD + OpenGraph.* -Each page must emit JSON-LD (schema.org types per TZ table) and OpenGraph meta tags. CLAUDE.md contract #6 lists this as binding. +Each unique page in the section must emit a `