Skip to content

実装: combat HUD の配置・safe-zone・情報優先度を実装する #1958

Closed

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: implementation
parent_issue: "#1370"
goal_ref: "#1936 の採用結果に従い、combat HUD を左下 status・上中央 elapsed・conditional edge control に配置し safe-zone/priority/accessibility を実装する"
change_kind: mixed

Parent Issue

#1370

Parent Goal Ref

  • Goal: Canvas world layer と DOM player-facing control を分離した battle-stage を完成する。
  • Desired Destination: primary status/control は DOM HUD、Canvas は world/visual cue に限定する。

Current Validated Scope

  • HULL/critical warning を左下 persistent status とし、elapsed を上中央 low-prominence にする。
  • weapon recharging と Assist command を conditional とし、space不足時に先に collapse する。
  • Pause を stat cluster から分離し、Esc と focusable/pointer-operable DOM affordance を残す。
  • inner 16 CSS px containment、protected action zone、pointer-through と focus/keyboard を E2E/VRT で検証する。

Dependency

Remaining Parent Gaps

Outcome

指定した HUD placement/priority/safe-zone が DOM overlay として実装され、全主要 fragment/control が内側16 CSS pxに収まり、keyboard/pointer/focus とVRT runtime evidenceが最新headでpassする状態。375×667 を含む既知の未修正ケースが解消され、safe-margin/protected-zone の検証契約が false-green にならない状態。

本 Issue は 2026-08-02 起票時点から main が進んでおり、着手時点の main head SHA(起票時点参照: 1c4f938、PR #1998 で command rail 削除・battle-stage 単列化・keyboard-only E2E の実 Tab 化が反映済み)を基準に実装・検証すること。

In Scope

  • combat HUD placement、progressive disclosure、safe-zone、priority
  • safe-margin false-green assertion の内側 containment 修正(assertWithinSafeMargin() の epsilon 方向修正を含む)
  • major HUD fragment/interactive control geometry、protected action zone(static hard invariant と dynamic observation の分離)、pointer-through
  • keyboard/focus/pointer Pause/Assist accessibility(実 pointer click、実 Tab/Shift+Tab、Enter/Space、200%zoom)、VRT/runtime evidence
  • 375×667 の HUD overflow 解消と tests/e2e/hud-hull-overflow.spec.ts の該当 test.fixme 解除
  • critical warning、Kills、Weapon、Assist の状態契約(threshold・表示条件・collapse順位)の確定

Out of Scope

Acceptance Criteria

  • AC1: HULL、critical、elapsed、Kills、Weapon、Assist、Pause について、表示条件・配置・collapse順位・copyを表形式で固定した semantic state table を実装/テストへ反映する。
  • AC2: exact container thresholds と縮退順を固定し、375×667を含む全境界ケースでHULL/active warning/Pauseを維持する。tests/e2e/hud-hull-overflow.spec.ts の375×667 test.fixme を解除する。980×720、800×720 は継続サポートし、Supported minimum viewport を375×667に確定する。
  • AC3: visible opaque fragment と interactive control が Canvas 内側16 CSS px に完全包含される(透明な HUD root 自体は対象外)。assertWithinSafeMargin() を outer 拡張ではなく inner を epsilon 込みで縮めた比較に修正する。running HUD は内部 scroll を必要としない(.battle-hud-layer の scrollHeight <= clientHeight + epsilon)。
  • AC4: persistent な opaque/interactive fragment は Canvas 中央60%×60%の static protected zone と交差しない(透明な layout root は判定対象外)。動的観測領域(player/aim corridor/enemy cluster)は指定 fixture・sampling時点・epsilon・opacity条件を明記した証跡(deterministic fixture E2E または manual runtime review)で扱う。
  • AC5: Assist/Pause を通常の getByRole(...).click() で操作でき、Canvas上のcontrol外座標への実 page.mouse.click() をCanvas/input側が受信し、実 Tab/Shift+Tab でAssist/Pauseに到達し、Enter/Space でactivateでき、200% zoom時もfocused controlとfocus indicatorが隠れず、pause表示中はCanvas/combat HUDがinertでResume後にfocusが正しく復帰する。
  • AC6: Assist/Pauseのhit targetが24×24 CSS px以上(規定spacing例外を除く)、tabindex > 0 を使わない、DOM順序と実Tab順序が一致する、hidden/collapsed controlがTab順序に残らない、disabled controlの理由が隣接copyまたはaccessible descriptionで判別できる、critical warningが色だけに依存しない(text/shape/iconを併用し状態遷移時のみARIA通知を更新する)。current codeの意味に沿ったplayer-facing copyを使い、raw internal stateを露出しない。
  • AC7: 1280x720、1366x768、1920x1080、1437x1365、375x667 の全viewportで、viewport・DPR・実Chrome tab zoom・userAgent・head SHAを証跡化したE2Eをindividual diff review付きでpassする。
  • AC8: representative boundary cellsのみをVRT baseline化し、expected/actual/diffを個別確認する。pixel-diversity/negative controlを維持し、Canvas exclusionをmask全面被覆方式へ戻さない。legacy-current/provisional candidateのみ更新し、snapshot directoryの一括更新は行わず変更PNGを列挙する。
  • AC9: tests/e2e/product-pause.spec.ts の既存 pause 回帰(Canvas/combat HUD inert化、Resumeへのfocus移動、Escapeの単発処理)を非回帰として維持し、かつ 実装: PR #1984 pause-dialog/result-surface 変更に既存 E2E テストを追従させる #1986(pause/result architecture変更への既存E2E追従)が解消済みであるか、解消前の場合は 実装: PR #1984 pause-dialog/result-surface 変更に既存 E2E テストを追従させる #1986 の既知failure fingerprintを記録し実装head と clean main を同一環境で比較して新規failureがないことを証跡化する。

Verification Commands

# AC1
$ pnpm test
# AC2
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/hud-hull-overflow.spec.ts
# AC3
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/hud-hull-overflow.spec.ts
# AC4
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/hud-hull-overflow.spec.ts
# AC5
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/assist-player-affordance.spec.ts
# AC6
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/assist-player-affordance.spec.ts
# AC7
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/hud-hull-overflow.spec.ts
# AC8
# preflight-scope: pr_review_only
$ pnpm test:vrt
# AC9
# preflight-scope: pr_review_only
$ pnpm test:e2e -- tests/e2e/product-pause.spec.ts

pnpm test:e2e を単独実行する場合は VITE_E2E_MODE=true pnpm build を先に実行する CI 前提コマンドである。hermetic なローカル/独立VCとしては pnpm test:vrt(build込み)を用いる。pnpm typecheck/typecheck:e2e/lint/test/build は project-constitution の必須検証としてPRレビュー時に別途実行する。

Runtime Verification Applicability

decision: immediate
reason: placement、occlusion、focus、pointer-through、VRTは browser runtimeでのみ検証できる。
applicable_acs: [AC2, AC3, AC4, AC5, AC6, AC7, AC8, AC9]
execution_environment: Chromium Playwright with VITE_E2E_MODE=true production build
skip_conditions: browser runtime unavailable; record failure and do not update/freeze snapshots
fallback_policy: unit checks may prove view-model/copy only(AC1); runtime proof remains merge blocker
artifact_requirements: expected/actual/diff review, viewport, DPR, zoom, browser, run ID, artifact ID, head SHA

Allowed Paths

  • src/ui/combatHud.ts
  • src/ui/HudController.ts
  • src/style.css
  • tests/hud-controller.test.ts
  • tests/player-facing-hp-policy.test.ts
  • tests/e2e/hud-hull-overflow.spec.ts
  • tests/e2e/assist-player-affordance.spec.ts
  • tests/e2e/visual-overlay.spec.ts
  • tests/e2e/visual-utils.ts
  • tests/e2e/__screenshots__/visual-overlay.spec.ts/
  • docs/dev/visual-baseline-registry.md
  • .github/workflows/ci.yml
  • playwright.config.ts
  • scripts/check-visual-artifact-pipeline.py
  • tests/e2e/__screenshots__/m2-combat-mvp.spec.ts/m2-running-hud-baseline.png

tests/e2e/product-pause.spec.ts は selector contract を変更しない限り実行対象のみとし、markup再構成に伴いselectorを変更する場合に限り Allowed Paths へ追加する。

Required Design References

Required Skills

  • TypeScript / DOM UI / CSS overlay / Playwright / visual regression testing

Delivery Rule

Stop Conditions

  • destructive_operation
  • secret_required
  • external_billing
  • insufficient_permission

テンプレート互換の次の旧定型文は上記4分類へ正規化し、追加の停止条件にはしない。

  • Allowed Paths 外の変更が必要と判明した場合
  • In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
  • 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
  • 後続 Phase / 別スコープへの波及が判明した場合
  • nested SubAgent delegation が必要になった場合
  • 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合

Activity

  1. added
    phase/implementation
    agent/implementer
    enhancement
    on Aug 2, 2026
  2. squne121 commented on Aug 5, 2026

    @squne121
    OwnerAuthor

    判定

    REQUEST_CHANGES — 現状の #1958 は implementation-ready ではありません。

    方向性自体は妥当です。左下の機体状態、上中央の経過時間、DOMによる Assist/Pause、Canvasとの入力責務分離は、#1936 と UI IA に整合します。しかし現契約には、実装者が判断できない情報状態、既知の未修正ケース、false-green になる検証、現在の main とずれた前提が残っています。#1958 自体にはコメントがなく、実質的な決定根拠は #1936、PR #1964、PR #1998 側に分散しています。

    verdict: REQUEST_CHANGES
    implementation_ready: false
    dependency_preflight:
      blocked_by_1956: satisfied
    blockers:
      - inherited_375x667_case_missing_from_AC6
      - pointer_and_keyboard_tests_are_false_green
      - protected_action_zone_is_not_executable_as_written
      - critical_warning_and_kills_semantics_are_undefined
      - VRT_command_does_not_cover_declared_matrix
      - current_main_and_known_red_E2E_state_are_not_reflected
    

    Native dependency は正しく #1956 を指しており、#1956 は PR #1964 で完了済みです。ただし #1958 本文の Dependency 欄は依然として番号未解決の定型文なので、Depends on: #1956 (closed by #1964) へ更新すべきです。

    P0 — マージ阻害事項

    1. PR #1964 から明示的に委譲された 375×667 が AC6 から消えている

    PR #1964 は、モバイル用の transform: scale(0.5) を不適切なスコープ横断として削除し、375×667 の HUD overflow を #1958 に委譲しています。現行テストにも、そのケースだけ test.fixme とする明示的なコメントがあります。ところが #1958 の AC6 は 1280×720、1366×768、1920×1080、1437×1365 しか列挙していません。

    これは単なる追加ケースではありません。現時点で約130px下にはみ出すことが既知であり、#1958 が閉じるべき具体的な欠陥です。

    必要な修正は次のとおりです。

    • AC6 に 375×667 を必須ケースとして追加する。

    • 現行の 980×720、800×720 を継続サポートするか明記する。

    • Supported minimum viewport を確定する。UI IA でも未決事項のままです。

    • test.fixme を解除することを独立ACにする。

    • 縮小は transform: scale() ではなく conditional fragment の非表示、gap/padding調整、再配置で行う。

    2. AC4 の Verification Command は pointer / keyboard を実際には検証していない

    assist-player-affordance.spec.ts は Assist を次の方法で操作しています。

    • button.evaluate(button.click()) によるDOMメソッド直接呼び出し

    • assistButton.focus() によるプログラム的focus注入

    前者はhit-testingを迂回し、後者はTab順序と到達可能性を迂回します。ファイル内コメントも、これは manual pointer hit-testing を検証していないと認めています。

    Playwrightの通常の locator.click() は、対象が可視、安定、enabledであり、実際にpointer eventを受け取れることまで検査します。直接 HTMLElement.click() を呼ぶと、この重要な検査がありません。 (Playwright)

    さらに、直近の PR #1998 では、まさに .focus() によるkeyboard-only検証が敵対的レビューで却下され、実際の Tab / Shift+Tab に書き換えられています。#1958 が古い方式を再採用するのは明確な後退です。

    AC4 は少なくとも以下を分離して検証する必要があります。

    1. Assist/Pause を通常の getByRole(...).click() で操作できる。

    2. Canvas上のcontrol外座標を実 page.mouse.click() し、Canvas/input側が受信する。

    3. 実際の Tab / Shift+Tab で Assist/Pause に到達する。

    4. Enter と Space でbuttonをactivateできる。

    5. 200% zoom時にもfocused controlとfocus indicatorが隠れない。

    6. pause表示中はCanvas/combat HUDがinertとなり、Resume後にfocusが正しく復帰する。

    pointer-events:none はhit-testingから外すだけであり、sequential focus navigationから要素を除外しません。pointer-throughとkeyboard/focusは別々のテストが必要です。 (W3C)

    3. protected action zone が実行可能な契約になっていない

    #1936 の採用決定は、次の二種類のzoneを定義しています。

    • Canvas中央 60%×60% の静的zone

    • player、aim corridor、enemy/projectile cluster の動的観測領域

    同時に「動的追従HUD」は視線予測性を壊すとして棄却されています。

    一方、#1958 AC3 は「HUD root、主要fragment、interactive control が protected action zone と不適切に交差しない」としか書いていません。ここには二つの問題があります。

    第一に、分散配置を実装するため .combat-hud をCanvas全面の透明layout rootにした場合、rootは中央60%×60%と必ず交差します。検査対象はrootのbounding boxではなく、実際に描画されるopaque fragmentとinteractive hit target でなければなりません。

    第二に、動的zoneを全ゲーム状態で避けるにはruntime occupancy-aware repositioningが必要ですが、それは #1936 が棄却した動的追従に近づきます。固定HUDである以上、playerが左下へ移動すればHULL fragmentと重なる可能性は残ります。

    したがって契約を次のように分離すべきです。

    • 自動化するhard invariant: opaque/interactive fragmentが中央60%×60%に交差しない。

    • 自動化するgeometry: 各fragmentがCanvas内側16pxに完全包含される。

    • 動的zone: deterministic fixture数件での観測証跡、またはmanual runtime reviewとする。

    • Canvas全面の透明rootはprotected-zone判定から除外する。

    • 「不適切に交差」の代わりに、対象rect、sampling時点、許容epsilon、opacity条件を定義する。

    4. critical warning、Kills、Weapon、Assist の状態契約が欠落している

    現行 combatHud.ts は一枚のsection内に次の六要素を持っています。

    • Hull

    • Kills

    • Elapsed

    • Weapon

    • Assist

    • Pause

    critical warning用のview-model field、threshold、copy、DOM fragmentは存在しません。Weaponは Ready または Recharging として常時出力され、Assistもrunning中は基本的に表示されます。

    対して #1958 は以下を決めていません。

    情報 | 未確定事項 -- | -- Critical warning | 発火threshold、hysteresis、解除条件、文言、icon、ARIA通知方式 Kills | 配置、常時表示かconditionalか、collapse順位 Weapon | Ready を隠して Recharging のみ出すのか Assist | ally不在、enemy不在、送信済み、pause時の表示・disabled・hidden条件 Elapsed | “low-prominence” の測定可能な定義 HULL | critical時の表現と通常時のnumeric/visual cue併用方針

    critical warningを色だけで表現してはいけません。text、shape、icon等を併用し、状態変化を通知する場合はthreshold遷移時だけ更新すべきです。毎frame aria-live を更新する実装は避けるべきです。 (W3C)

    5. AC3のsafe-margin検証とAC6のVRTがともに false-green

    現行 assertWithinSafeMargin() は説明と逆で、Canvasを16px外側へ拡張して判定しています。

    inner.left >= outer.left - 16
    inner.right <= outer.right + 16
    

    正しくは内側へ縮めたrectです。

    inner.left >= outer.left + 16 - epsilon
    inner.top >= outer.top + 16 - epsilon
    inner.right <= outer.right - 16 + epsilon
    inner.bottom <= outer.bottom - 16 + epsilon
    

    この既知欠陥は #1936 と #1958 のIn Scopeにも記載されていますが、現行テストはまだ誤ったままです。さらに Assist/Pause に対する toBeInViewport() は「viewportと一部でも交差する」ことしか保証せず、完全包含を保証しません。各required fragment/controlについてbounding boxを比較する必要があります。 (Playwright)

    VRT側にも契約不一致があります。visual-overlay.spec.ts のrunning HUD fixtureは desktop-1280x720 一件であり、Issueのzoom/DPR matrixを走査しません。

    加えて pnpm test:vrt:e2e は、既に VITE_E2E_MODE=true でbuildされた dist が存在することを前提とするCI用コマンドです。単独実行ではhermeticではありません。ローカルまたは独立VCにはbuild込みの pnpm test:vrt を使うべきです。

    必要な修正は以下です。

    • geometry E2Eのexact scenario tableを定義する。

    • 「zoom/DPR matrix」がCartesian productなのかpairwiseなのか明記する。

    • 全matrix cellではpredicate-based geometry/inputを検査する。

    • VRTは境界セルに絞った明示的subsetとする。

    • test:vrt:e2e を使う場合はbuild preconditionをVCに書く。単独VCは pnpm test:vrt。

    • required fragmentは toBeVisible()、non-zero bounding box、完全包含、no-scrollを順に検査する。

    • .battle-hud-layer 自体についても scrollHeight <= clientHeight + epsilon を検査する。現行CSSの overflow-y:auto を成功条件の逃げ道にしてはいけません。

    6. #1958 起票後の main 変更と既知red gateが契約へ反映されていない

    現在の main は 1c4f938… で、PR #1998 によりcommand railが削除され、battle-stageが単列化され、keyboard-only E2Eは実Tab方式へ修正されています。#1958 はそれ以前の2026年8月2日に起票されたため、最新レイアウトとテスト規約を再baseした記述が必要です。

    また #1986 がopenであり、pause/result architecture変更に追従していない既存E2EとVRTがmain上で既知redです。

    したがって #1958 のmerge gateは次のどちらかに固定すべきです。

    単に「current-head CI pass」と書くと、requiredではないred E2Eを無視したのか、差分が本当にpre-existingなのか判別できません。

    P1 — 重大な品質不足

    Pause回帰テストがVCにない

    #1376 は、pause dialog表示時のCanvas/combat HUD inert化、Resumeへのfocus移動、invokerまたはCanvasへのfocus復帰、Escapeの単発処理を明示的に契約しています。#1958 はPauseのDOM位置、markup、CSS、controllerを変更し得るため、tests/e2e/product-pause.spec.ts を必須回帰に含めるべきです。

    IssueのOut of Scopeが「#1376を変更しない」であることは、「#1376を検証しなくてよい」という意味ではありません。

    VRTのcapture semanticsを再破壊する危険がある

    #1980では、Canvas maskがcapture rootの約99.8%を覆い、HUDを実質的に一切検証していないのにVRTが通り得る欠陥が見つかっています。そのため現在は canvasVisibility:'hidden'、pixel diversity、negative controlが導入されています。

    #1958 のVRT変更では、以下を非回帰条件にすべきです。

    • pixel diversity testを維持する。

    • negative controlを維持する。

    • Canvas exclusionをmask全面被覆方式へ戻さない。

    • #1391が所有する frozen 昇格を行わない。

    • #1958では legacy-current / provisional candidateのみ更新する。

    • snapshot directoryの一括更新を禁止し、変更PNGを列挙する。

    viewport media queryよりCanvas container基準にすべき

    現在のCanvas表示幅はブラウザviewportそのものではなく、単列 .app-shell 内のactual container幅で決まります。したがってHUDのcollapse breakpointも window ベースの @media より、.battle-stage__viewport をnamed query containerにした @container を優先すべきです。container queryは実際のcontainerのinline sizeに応じてdescendant styleを切り替えられます。 (W3C)

    推奨構造は次です。

    .battle-stage__viewport {
      container-type: inline-size;
      container-name: battle-viewport;
    }
    

    .combat-hud {
    position: absolute;
    inset: 16px;
    pointer-events: none;
    }

    .combat-hud [data-hud-fragment] {
    position: absolute;
    pointer-events: none;
    }

    .combat-hud [data-battle-interactive='true'] {
    pointer-events: auto;
    }

    @container battle-viewport (inline-size < /* explicit threshold /) {
    /
    weapon -> Assist の順で縮退 */
    }

    threshold値は実測で決めるべきであり、Issue本文で固定する必要があります。

    accessibility ACが最低条件まで落ちていない

    Assist/Pauseのhit targetは、少なくとも24×24 CSS pxを満たすか、規定されたspacing例外を満たす必要があります。focused componentはauthor-created contentに完全に隠されてはならず、focus orderは意味と操作性を維持しなければなりません。 (W3C)

    ACに次を追加するのが妥当です。

    • Assist/Pause targetが24×24 CSS px以上。

    • tabindex > 0 を使わない。

    • DOM orderと実Tab orderを明示する。

    • 200% zoomでcontrolとfocus indicatorがCanvas clip境界から隠れない。

    • critical warningは色だけに依存しない。

    • hidden/collapsed controlがTab順序に残らない。

    • disabled controlの理由を隣接copyまたはaccessible descriptionで判別できる。

    推奨する実装境界

    combatHud.ts を一枚のcompact cardから、透明root配下の独立fragmentへ変更するのが妥当です。

    <section data-combat-hud hidden inert>
    <div data-hud-fragment="status">
    <span data-field="combat-hud-hull"></span>
    <span data-field="combat-hud-critical-warning"></span>
    </div>

    <p data-hud-fragment="elapsed" data-field="combat-hud-elapsed"></p>

    <div data-hud-fragment="kills"><!-- owner decision --></div>
    <div data-hud-fragment="weapon" hidden></div>

    <div data-hud-fragment="assist">
    <button data-action="assist-player">Assist allies</button>
    <p role="status"></p>
    </div>

    <button data-hud-fragment="pause" data-action="toggle-pause">Pause</button>
    </section>

    重要なのは以下です。

    • rootは透明・全面配置でもよいが、protected-zone検査対象にしない。

    • fragment単位でplacement、opacity、visibility、priorityを持つ。

    • static text fragmentは pointer-events:none。

    • buttonだけ pointer-events:auto。

    • visual placementとDOM focus orderを分離しても、実Tab順序は論理的に保つ。

    • transform:scale() で文字とtargetを縮小しない。

    • critical warningのARIA通知は毎renderではなく状態遷移時に限定する。

    改訂AC案

    1. AC1 — Semantic state table
      HULL、critical、elapsed、Kills、Weapon、Assist、Pauseについて、表示条件、配置、collapse順位、copyを表形式で固定する。

    2. AC2 — Deterministic disclosure
      exact container thresholdsと縮退順を固定し、375×667を含む全境界ケースでHULL、active warning、Pauseを維持する。

    3. AC3 — Geometry
      visible opaque fragmentとinteractive controlがCanvas内側16pxに完全包含される。透明rootは対象外。running HUDは内部scrollを必要としない。

    4. AC4 — Protected zone
      persistent fragmentは中央60%×60%と交差しない。dynamic observationは指定fixtureとcapture時点に限定して証跡化する。

    5. AC5 — Real input
      real pointer click、Canvas pointer-through、Tab/Shift+Tab、Enter/Space、focus-visible、pause inert/focus returnを検証する。

    6. AC6 — Copy/numeric/accessibility
      実装: Player 向け HP / HULL 表示ポリシーを通常 UI に適用する #788 integer bucketを維持し、raw stateを露出せず、critical warningを色だけに依存させない。

    7. AC7 — Exact runtime matrix
      少なくとも現在の四viewportに375×667を追加し、各scenarioのviewport、DPR、実Chrome tab zoom、userAgent、head SHAを証跡化する。

    8. AC8 — VRT governance
      representative boundary cellsのみbaseline化し、expected/actual/diffを個別確認する。pixel-diversity/negative-controlを維持し、frozenへ昇格しない。

    9. AC9 — Regression gate
      product-pause.spec.ts、#1986対応済みfull E2E、またはclean-main differentialを通す。

    修正版Verification Commands

    # semantic/copy/numeric policy
    pnpm test --
    tests/hud-controller.test.ts
    tests/player-facing-hp-policy.test.ts

    production-build browser geometry/input/pause regression

    pnpm test:e2e --
    tests/e2e/hud-hull-overflow.spec.ts
    tests/e2e/assist-player-affordance.spec.ts
    tests/e2e/product-pause.spec.ts

    hermetic local VRT: build included

    pnpm test:vrt

    static/full gates

    pnpm typecheck
    pnpm typecheck:e2e
    pnpm lint
    pnpm test
    pnpm build

    Allowed Pathsには、matrix/capture helperの再利用が必要になる可能性が高いため、少なくとも tests/e2e/visual-utils.ts を追加すべきです。product-pause.spec.ts は変更不要なら実行対象だけでよいですが、markup再構成に伴いselector contractを更新する場合だけAllowed Pathsへ追加します。

    最終結論

    #1958 は、配置方針は採用可能だが、実装契約と検証契約がまだ一致していません。特に以下を直さず着手すると、見た目を変えただけでACを通す実装、pointer操作できないのに通るテスト、375×667を未修正のまま閉じる実装が成立します。

    最優先の修正順は次です。

    1. 375×667をACへ復帰。

    2. critical/Kills/Weapon/Assistの状態表を確定。

    3. protected-zoneを静的invariantと観測証跡へ分離。

    4. direct click / .focus() を実pointer / Tab操作へ置換。

    5. VRTとgeometry matrixを分離し、exact scenarioを列挙。

    6. #1986またはclean-main differential gateを明記。

    7. 最新 main 1c4f938… を基準にIssue本文を再bind。

    本レビューは最新 main とGitHub上のIssue、PR、コメント、現行資産に対する静的レビューです。このセッションではPlaywright/VRTを実行していないため、実際の現行failure数や生成画像の目視確認までは行っていません。

    # 判定

    REQUEST_CHANGES — 現状の #1958 は implementation-ready ではありません。

    方向性自体は妥当です。左下の機体状態、上中央の経過時間、DOMによる Assist/Pause、Canvasとの入力責務分離は、#1936 と UI IA に整合します。しかし現契約には、実装者が判断できない情報状態、既知の未修正ケース、false-green になる検証、現在の main とずれた前提が残っています。#1958 自体にはコメントがなく、実質的な決定根拠は #1936、PR #1964、PR #1998 側に分散しています。

    verdict: REQUEST_CHANGES
    implementation_ready: false
    dependency_preflight:
      blocked_by_1956: satisfied
    blockers:
      - inherited_375x667_case_missing_from_AC6
      - pointer_and_keyboard_tests_are_false_green
      - protected_action_zone_is_not_executable_as_written
      - critical_warning_and_kills_semantics_are_undefined
      - VRT_command_does_not_cover_declared_matrix
      - current_main_and_known_red_E2E_state_are_not_reflected

    Native dependency は正しく #1956 を指しており、#1956 は PR #1964 で完了済みです。ただし #1958 本文の Dependency 欄は依然として番号未解決の定型文なので、Depends on: #1956 (closed by #1964) へ更新すべきです。

    P0 — マージ阻害事項

    1. PR #1964 から明示的に委譲された 375×667 が AC6 から消えている

    PR #1964 は、モバイル用の transform: scale(0.5) を不適切なスコープ横断として削除し、375×667 の HUD overflow を #1958 に委譲しています。現行テストにも、そのケースだけ test.fixme とする明示的なコメントがあります。ところが #1958 の AC6 は 1280×720、1366×768、1920×1080、1437×1365 しか列挙していません。

    これは単なる追加ケースではありません。現時点で約130px下にはみ出すことが既知であり、#1958 が閉じるべき具体的な欠陥です。

    必要な修正は次のとおりです。

    • AC6 に 375×667 を必須ケースとして追加する。
    • 現行の 980×720、800×720 を継続サポートするか明記する。
    • Supported minimum viewport を確定する。UI IA でも未決事項のままです。
    • test.fixme を解除することを独立ACにする。
    • 縮小は transform: scale() ではなく conditional fragment の非表示、gap/padding調整、再配置で行う。

    2. AC4 の Verification Command は pointer / keyboard を実際には検証していない

    assist-player-affordance.spec.ts は Assist を次の方法で操作しています。

    • button.evaluate(button.click()) によるDOMメソッド直接呼び出し
    • assistButton.focus() によるプログラム的focus注入

    前者はhit-testingを迂回し、後者はTab順序と到達可能性を迂回します。ファイル内コメントも、これは manual pointer hit-testing を検証していないと認めています。

    Playwrightの通常の locator.click() は、対象が可視、安定、enabledであり、実際にpointer eventを受け取れることまで検査します。直接 HTMLElement.click() を呼ぶと、この重要な検査がありません。 (Playwright)

    さらに、直近の PR #1998 では、まさに .focus() によるkeyboard-only検証が敵対的レビューで却下され、実際の Tab / Shift+Tab に書き換えられています。#1958 が古い方式を再採用するのは明確な後退です。

    AC4 は少なくとも以下を分離して検証する必要があります。

    1. Assist/Pause を通常の getByRole(...).click() で操作できる。
    2. Canvas上のcontrol外座標を実 page.mouse.click() し、Canvas/input側が受信する。
    3. 実際の Tab / Shift+Tab で Assist/Pause に到達する。
    4. Enter と Space でbuttonをactivateできる。
    5. 200% zoom時にもfocused controlとfocus indicatorが隠れない。
    6. pause表示中はCanvas/combat HUDがinertとなり、Resume後にfocusが正しく復帰する。

    pointer-events:none はhit-testingから外すだけであり、sequential focus navigationから要素を除外しません。pointer-throughとkeyboard/focusは別々のテストが必要です。 ([W3C]2)

    3. protected action zone が実行可能な契約になっていない

    #1936 の採用決定は、次の二種類のzoneを定義しています。

    • Canvas中央 60%×60% の静的zone
    • player、aim corridor、enemy/projectile cluster の動的観測領域

    同時に「動的追従HUD」は視線予測性を壊すとして棄却されています。

    一方、#1958 AC3 は「HUD root、主要fragment、interactive control が protected action zone と不適切に交差しない」としか書いていません。ここには二つの問題があります。

    第一に、分散配置を実装するため .combat-hud をCanvas全面の透明layout rootにした場合、rootは中央60%×60%と必ず交差します。検査対象はrootのbounding boxではなく、実際に描画されるopaque fragmentとinteractive hit target でなければなりません。

    第二に、動的zoneを全ゲーム状態で避けるにはruntime occupancy-aware repositioningが必要ですが、それは #1936 が棄却した動的追従に近づきます。固定HUDである以上、playerが左下へ移動すればHULL fragmentと重なる可能性は残ります。

    したがって契約を次のように分離すべきです。

    • 自動化するhard invariant: opaque/interactive fragmentが中央60%×60%に交差しない。
    • 自動化するgeometry: 各fragmentがCanvas内側16pxに完全包含される。
    • 動的zone: deterministic fixture数件での観測証跡、またはmanual runtime reviewとする。
    • Canvas全面の透明rootはprotected-zone判定から除外する。
    • 「不適切に交差」の代わりに、対象rect、sampling時点、許容epsilon、opacity条件を定義する。

    4. critical warning、Kills、Weapon、Assist の状態契約が欠落している

    現行 combatHud.ts は一枚のsection内に次の六要素を持っています。

    • Hull
    • Kills
    • Elapsed
    • Weapon
    • Assist
    • Pause

    critical warning用のview-model field、threshold、copy、DOM fragmentは存在しません。Weaponは Ready または Recharging として常時出力され、Assistもrunning中は基本的に表示されます。

    対して #1958 は以下を決めていません。

    情報 未確定事項
    Critical warning 発火threshold、hysteresis、解除条件、文言、icon、ARIA通知方式
    Kills 配置、常時表示かconditionalか、collapse順位
    Weapon Ready を隠して Recharging のみ出すのか
    Assist ally不在、enemy不在、送信済み、pause時の表示・disabled・hidden条件
    Elapsed “low-prominence” の測定可能な定義
    HULL critical時の表現と通常時のnumeric/visual cue併用方針

    UI IA はHULLをinteger-only summary、critical warningをcombat常時情報として扱い、major HUD textは1080pで18 CSS px以上、critical warningは200% zoomでも可視としています。

    また #788 により、通常UIのHULLは 0 < value < 1 を "1" に丸め、<1 や小数を出さない契約が既に確定しています。#1958 AC5にはこの不変条件を直接記載すべきです。

    最低限、以下の状態表をIssue本文に追加する必要があります。

    fragment placement visibility collapse
    HULL left-bottom running中常時 never
    critical warning HULLと同一status領域 threshold成立時に表示。thresholdは明記必須 never while active
    elapsed top-center running中常時 HULL/Pauseより後
    Kills owner decision required owner decision required owner decision required
    weapon edge contextual recharging 時のみ、または別の明示条件 first
    Assist edge contextual commandable条件を明記 second
    Pause stat cluster外 running中常時 never

    critical warningを色だけで表現してはいけません。text、shape、icon等を併用し、状態変化を通知する場合はthreshold遷移時だけ更新すべきです。毎frame aria-live を更新する実装は避けるべきです。 ([W3C]3)

    5. AC3のsafe-margin検証とAC6のVRTがともに false-green

    現行 assertWithinSafeMargin() は説明と逆で、Canvasを16px外側へ拡張して判定しています。

    inner.left >= outer.left - 16
    inner.right <= outer.right + 16

    正しくは内側へ縮めたrectです。

    inner.left >= outer.left + 16 - epsilon
    inner.top >= outer.top + 16 - epsilon
    inner.right <= outer.right - 16 + epsilon
    inner.bottom <= outer.bottom - 16 + epsilon

    この既知欠陥は #1936 と #1958 のIn Scopeにも記載されていますが、現行テストはまだ誤ったままです。さらに Assist/Pause に対する toBeInViewport() は「viewportと一部でも交差する」ことしか保証せず、完全包含を保証しません。各required fragment/controlについてbounding boxを比較する必要があります。 ([Playwright]1)

    VRT側にも契約不一致があります。visual-overlay.spec.ts のrunning HUD fixtureは desktop-1280x720 一件であり、Issueのzoom/DPR matrixを走査しません。

    加えて pnpm test:vrt:e2e は、既に VITE_E2E_MODE=true でbuildされた dist が存在することを前提とするCI用コマンドです。単独実行ではhermeticではありません。ローカルまたは独立VCにはbuild込みの pnpm test:vrt を使うべきです。

    必要な修正は以下です。

    • geometry E2Eのexact scenario tableを定義する。
    • 「zoom/DPR matrix」がCartesian productなのかpairwiseなのか明記する。
    • 全matrix cellではpredicate-based geometry/inputを検査する。
    • VRTは境界セルに絞った明示的subsetとする。
    • test:vrt:e2e を使う場合はbuild preconditionをVCに書く。単独VCは pnpm test:vrt。
    • required fragmentは toBeVisible()、non-zero bounding box、完全包含、no-scrollを順に検査する。
    • .battle-hud-layer 自体についても scrollHeight <= clientHeight + epsilon を検査する。現行CSSの overflow-y:auto を成功条件の逃げ道にしてはいけません。

    6. #1958 起票後の main 変更と既知red gateが契約へ反映されていない

    現在の main は 1c4f938… で、PR #1998 によりcommand railが削除され、battle-stageが単列化され、keyboard-only E2Eは実Tab方式へ修正されています。#1958 はそれ以前の2026年8月2日に起票されたため、最新レイアウトとテスト規約を再baseした記述が必要です。

    また #1986 がopenであり、pause/result architecture変更に追従していない既存E2EとVRTがmain上で既知redです。

    したがって #1958 のmerge gateは次のどちらかに固定すべきです。

    単に「current-head CI pass」と書くと、requiredではないred E2Eを無視したのか、差分が本当にpre-existingなのか判別できません。

    P1 — 重大な品質不足

    Pause回帰テストがVCにない

    #1376 は、pause dialog表示時のCanvas/combat HUD inert化、Resumeへのfocus移動、invokerまたはCanvasへのfocus復帰、Escapeの単発処理を明示的に契約しています。#1958 はPauseのDOM位置、markup、CSS、controllerを変更し得るため、tests/e2e/product-pause.spec.ts を必須回帰に含めるべきです。

    IssueのOut of Scopeが「#1376を変更しない」であることは、「#1376を検証しなくてよい」という意味ではありません。

    VRTのcapture semanticsを再破壊する危険がある

    #1980では、Canvas maskがcapture rootの約99.8%を覆い、HUDを実質的に一切検証していないのにVRTが通り得る欠陥が見つかっています。そのため現在は canvasVisibility:'hidden'、pixel diversity、negative controlが導入されています。

    #1958 のVRT変更では、以下を非回帰条件にすべきです。

    • pixel diversity testを維持する。
    • negative controlを維持する。
    • Canvas exclusionをmask全面被覆方式へ戻さない。
    • #1391が所有する frozen 昇格を行わない。
    • #1958では legacy-current / provisional candidateのみ更新する。
    • snapshot directoryの一括更新を禁止し、変更PNGを列挙する。

    viewport media queryよりCanvas container基準にすべき

    現在のCanvas表示幅はブラウザviewportそのものではなく、単列 .app-shell 内のactual container幅で決まります。したがってHUDのcollapse breakpointも window ベースの @media より、.battle-stage__viewport をnamed query containerにした @container を優先すべきです。container queryは実際のcontainerのinline sizeに応じてdescendant styleを切り替えられます。 ([W3C]4)

    推奨構造は次です。

    .battle-stage__viewport {
      container-type: inline-size;
      container-name: battle-viewport;
    }
    
    .combat-hud {
      position: absolute;
      inset: 16px;
      pointer-events: none;
    }
    
    .combat-hud [data-hud-fragment] {
      position: absolute;
      pointer-events: none;
    }
    
    .combat-hud [data-battle-interactive='true'] {
      pointer-events: auto;
    }
    
    @container battle-viewport (inline-size < /* explicit threshold */) {
      /* weapon -> Assist の順で縮退 */
    }

    threshold値は実測で決めるべきであり、Issue本文で固定する必要があります。

    accessibility ACが最低条件まで落ちていない

    Assist/Pauseのhit targetは、少なくとも24×24 CSS pxを満たすか、規定されたspacing例外を満たす必要があります。focused componentはauthor-created contentに完全に隠されてはならず、focus orderは意味と操作性を維持しなければなりません。 ([W3C]5)

    ACに次を追加するのが妥当です。

    • Assist/Pause targetが24×24 CSS px以上。
    • tabindex > 0 を使わない。
    • DOM orderと実Tab orderを明示する。
    • 200% zoomでcontrolとfocus indicatorがCanvas clip境界から隠れない。
    • critical warningは色だけに依存しない。
    • hidden/collapsed controlがTab順序に残らない。
    • disabled controlの理由を隣接copyまたはaccessible descriptionで判別できる。

    推奨する実装境界

    combatHud.ts を一枚のcompact cardから、透明root配下の独立fragmentへ変更するのが妥当です。

    <section data-combat-hud hidden inert>
      <div data-hud-fragment="status">
        <span data-field="combat-hud-hull"></span>
        <span data-field="combat-hud-critical-warning"></span>
      </div>
    
      <p data-hud-fragment="elapsed" data-field="combat-hud-elapsed"></p>
    
      <div data-hud-fragment="kills"><!-- owner decision --></div>
      <div data-hud-fragment="weapon" hidden></div>
    
      <div data-hud-fragment="assist">
        <button data-action="assist-player">Assist allies</button>
        <p role="status"></p>
      </div>
    
      <button data-hud-fragment="pause" data-action="toggle-pause">Pause</button>
    </section>

    重要なのは以下です。

    • rootは透明・全面配置でもよいが、protected-zone検査対象にしない。
    • fragment単位でplacement、opacity、visibility、priorityを持つ。
    • static text fragmentは pointer-events:none。
    • buttonだけ pointer-events:auto。
    • visual placementとDOM focus orderを分離しても、実Tab順序は論理的に保つ。
    • transform:scale() で文字とtargetを縮小しない。
    • critical warningのARIA通知は毎renderではなく状態遷移時に限定する。

    改訂AC案

    1. AC1 — Semantic state table
      HULL、critical、elapsed、Kills、Weapon、Assist、Pauseについて、表示条件、配置、collapse順位、copyを表形式で固定する。

    2. AC2 — Deterministic disclosure
      exact container thresholdsと縮退順を固定し、375×667を含む全境界ケースでHULL、active warning、Pauseを維持する。

    3. AC3 — Geometry
      visible opaque fragmentとinteractive controlがCanvas内側16pxに完全包含される。透明rootは対象外。running HUDは内部scrollを必要としない。

    4. AC4 — Protected zone
      persistent fragmentは中央60%×60%と交差しない。dynamic observationは指定fixtureとcapture時点に限定して証跡化する。

    5. AC5 — Real input
      real pointer click、Canvas pointer-through、Tab/Shift+Tab、Enter/Space、focus-visible、pause inert/focus returnを検証する。

    6. AC6 — Copy/numeric/accessibility
      実装: Player 向け HP / HULL 表示ポリシーを通常 UI に適用する #788 integer bucketを維持し、raw stateを露出せず、critical warningを色だけに依存させない。

    7. AC7 — Exact runtime matrix
      少なくとも現在の四viewportに375×667を追加し、各scenarioのviewport、DPR、実Chrome tab zoom、userAgent、head SHAを証跡化する。

    8. AC8 — VRT governance
      representative boundary cellsのみbaseline化し、expected/actual/diffを個別確認する。pixel-diversity/negative-controlを維持し、frozenへ昇格しない。

    9. AC9 — Regression gate
      product-pause.spec.ts、#1986対応済みfull E2E、またはclean-main differentialを通す。

    修正版Verification Commands

    # semantic/copy/numeric policy
    pnpm test -- \
      tests/hud-controller.test.ts \
      tests/player-facing-hp-policy.test.ts
    
    # production-build browser geometry/input/pause regression
    pnpm test:e2e -- \
      tests/e2e/hud-hull-overflow.spec.ts \
      tests/e2e/assist-player-affordance.spec.ts \
      tests/e2e/product-pause.spec.ts
    
    # hermetic local VRT: build included
    pnpm test:vrt
    
    # static/full gates
    pnpm typecheck
    pnpm typecheck:e2e
    pnpm lint
    pnpm test
    pnpm build

    Allowed Pathsには、matrix/capture helperの再利用が必要になる可能性が高いため、少なくとも tests/e2e/visual-utils.ts を追加すべきです。product-pause.spec.ts は変更不要なら実行対象だけでよいですが、markup再構成に伴いselector contractを更新する場合だけAllowed Pathsへ追加します。

    最終結論

    #1958 は、配置方針は採用可能だが、実装契約と検証契約がまだ一致していません。特に以下を直さず着手すると、見た目を変えただけでACを通す実装、pointer操作できないのに通るテスト、375×667を未修正のまま閉じる実装が成立します。

    最優先の修正順は次です。

    1. 375×667をACへ復帰。
    2. critical/Kills/Weapon/Assistの状態表を確定。
    3. protected-zoneを静的invariantと観測証跡へ分離。
    4. direct click / .focus() を実pointer / Tab操作へ置換。
    5. VRTとgeometry matrixを分離し、exact scenarioを列挙。
    6. #1986またはclean-main differential gateを明記。
    7. 最新 main 1c4f938… を基準にIssue本文を再bind。

    本レビューは最新 main とGitHub上のIssue、PR、コメント、現行資産に対する静的レビューです。このセッションではPlaywright/VRTを実行していないため、実際の現行failure数や生成画像の目視確認までは行っていません。

  3. squne121 commented on Aug 5, 2026

    @squne121
    OwnerAuthor

    issue-refinement-loop: approved

    OWNER の REQUEST_CHANGES レビュー(comment)を反映し、本文を全面改訂しました。

    反映した主な変更

    検証結果

    • Step 1 investigation(codebase-investigator): OWNER コメントの技術的主張(combatHud.ts の critical warning field 欠落、product-pause.spec.ts の既存回帰テスト実在、visual-overlay.spec.ts の単一 viewport fixture、visual-utils.ts 実在、Supported minimum viewport 未決)をすべて裏付け
    • Step 2 review(issue-reviewer → 独立で check_issue_contract.py 直接実行により再検証): verdict: approve(3 iteration。1回目は issue-reviewer SubAgent の誤検知を独立検証で否定・訂正、2回目は <!-- runtime-verification: true --> タグ欠落を修正、3回目は contract-review の pnpm allowlist に合わせて VC を調整)
    • 最終 Step 0f preflight: STATUS: pass / NEXT_ACTION: proceed
    • issue-contract-review(run_contract_review_once.py --mode static): status: go(vc_preflight_status: pass、AC1 は pnpm test regression gate で実際に pass、AC2-AC9 は pr_review_only で PR review へ委譲)
    LOOP_HANDOFF_RESULT_V1:
      status: impl_ready
      routing_action: run_impl_review_loop
      contract_review:
        status: go
        gate_result: fresh_go
        latest_comment_url: null
        generated_at: "2026-08-05T22:23:57.001244Z"
        body_sha256: "sha256:73db232438a1b39700f51b3802c28fd4b5b4c5ed63647db8135758607e96cca9"
      metadata:
        title_prefix_ready: true
        phase_label_ready: true
      auto_fixes:
        result: auto_fixed
        required: []
        skipped: []
      blockers: []
      permissions:
        unavailable: []
      generated_at: "2026-08-05T22:23:57.001244Z"
      checked_body_sha256: "sha256:73db232438a1b39700f51b3802c28fd4b5b4c5ed63647db8135758607e96cca9"
      checker_exit_code: 0
      missing_sections: []
      missing_contract_keys: []

    latest_comment_url は本 termination report コメント自体を Contract Snapshot の代替根拠とする(contract_snapshot.publish による別コメント投稿は未実行のため null)。impl-review-loop / implement-issue 側の issue-contract-review 呼び出し時に freshness(body_sha256 一致)を再確認すること。

    FOLLOW_UP_MATERIALIZATION_RESULT_V1:
      schema_version: 1
      materialized_by: issue-refinement-loop
      follow_up_issues: []
      note_only_observations: []
  4. squne121 commented on Aug 6, 2026

    @squne121
    OwnerAuthor

    implement-issue: 実装完了(部分実装、詳細は PR 参照)

  5. squne121 commented on Aug 6, 2026

    @squne121
    OwnerAuthor

    Owner Decision on Issue #1958 (in response to PR #2006 iteration 1 HUMAN_REVIEW_REQUIRED verdict, reviewed_head_sha 5e2054e)

    1. AC4 is maintained including at 375x667 — no blanket exception

    A comprehensive exception for the Canvas center 60%x60% static protected zone at 375x667 is NOT granted.

    However, AC1's "bottom-left-status" does NOT mean the current ~85px stacked-card chrome must stay fixed. Placement, player-facing copy, and information priority must be preserved, but the concrete representation may change to a compact form specific to the supported minimum viewport.

    At 375x667, collapse must follow the semantic state table in this order:

    1. Weapon / Assist
    2. Kills
    3. Elapsed

    HULL, active critical warning, and Pause must be preserved.

    The 375x667 status may be changed to a single line or equivalent minimal display that:

    • may remove non-semantic chrome (card background, eyebrow labels, excess padding)
    • may place the HULL value and a critical icon + "Hull critical" text on the same line
    • must not represent critical warning by color alone
    • must not expose raw internal state
    • must not shrink via transform: scale()
    • must not clip/ellipsis/shrink text below legible font size
    • must not leave hidden fragments in Tab order
    • must keep Pause as a separate focusable/pointer-operable control from status

    The current "~85px status card doesn't fit" measurement is evidence that the CURRENT stacked representation doesn't fit — it is NOT proof that every allowed compact representation is impossible.

    2. AC1 placement must be runtime-verified

    The prior review's conclusion that "AC1 is independently verified" is reverted to unconfirmed. Current CSS uses .battle-hud-layer { align-content: start; } with a content-sized .combat-hud, and align-self: end may only be positioning within an auto-sized grid row — semantic-state-table strings alone do not prove actual bottom-left placement.

    tests/e2e/hud-hull-overflow.spec.ts must add runtime geometry assertions that:

    • confirm the status zone anchors to the Canvas inner-safe left edge
    • confirm the status zone anchors to the Canvas lower region
    • confirm elapsed is in the top-center region on viewports where it is shown
    • confirm Pause and edge-control are in their declared edge regions
    • do NOT use a transparent root's position as evidence of fragment placement
    • emit diagnostics including Canvas rect, fragment rect, safe margin, protected-zone rect, and epsilon

    "Bottom-left" must be proven via bounding box, not CSS class/grid-area names. If this new check reveals placement inconsistencies beyond 375x667, fix them per the Issue contract rather than preserving the prior AC1 PASS finding.

    3. The 375x667 known failure must be resolved

    test.fail() must not remain in the final deliverable. At minimum two fixtures at 375x667 must be exercised — normal HULL state, and critical-warning-triggered state — and both must verify: AC1 placement, Canvas inner 16 CSS px containment, static protected-zone non-intersection, HULL display, icon+text display in the critical fixture, Pause pointer/keyboard/focus reachability, no hidden/collapsed fragment in Tab order, no-scroll on HUD/.battle-hud-layer, and recorded viewport/DPR/zoom/userAgent/head SHA. Available dimensions outside the protected zone must be derived from actual measurements, not hard-coded viewport-specific guesses.

    4. AC8 must be completed in this same Issue/PR — no follow-up split

    Scope Delta — Allowed Paths addition

    .github/workflows/ci.yml
    

    Add .github/workflows/ci.yml to Issue #1958's Allowed Paths. The edit authority is limited to the minimal diff needed to register AC8's representative VRT captures in ACTIVE_VRT_CAPTURES and the corresponding CI summary/artifact contract. No unrelated workflow cleanup, Action version bumps, or job restructuring is authorized.

    Representative boundary cells to re-confirm against the Issue contract and current implementation, adding only necessary baselines:

    • 1366x768
    • 1920x1080
    • 1437x1365 (or low-DPR approximation)
    • 375x667
    • existing 1280x720 baseline if needed

    Each PNG must have expected/actual/diff individually reviewed; changed PNGs must be enumerated in the PR body and the visual baseline registry. Blanket snapshot-directory updates remain prohibited. scripts/check-visual-artifact-pipeline.py cross-validation against .github/workflows/ci.yml must actually run and prove no missing declarations.

    5. Update to latest main

    PR #2006 is BEHIND, and Issue #1986 closed after the prior PR body was written. Use the repo's authorized branch-update path (not raw gh api or an ad hoc merge/rebase that bypasses repository policy) to catch up to latest main. Record previous head SHA, previous base/main SHA, updated main SHA, updated PR head SHA, and any conflict resolution. After updating, confirm Issue #1986's closed state and its resolving PR/main landing, and re-run AC9 against latest main (not a stale clean-main comparison).

    6. Verification independence requirement

    Two prior test-runner subagent reports incorrectly claimed AC4/AC8 were PASS when they were not. Future subagent reports are candidate evidence only — the verdict author must directly confirm: current head diff, the actual test bodies, executed commands and exit codes, test counts, presence of expected-failure/skip/fixme markers, generated artifacts, expected/actual/diff, workflow capture declarations, and reviewed head SHA. test.fail(), test.fixme(), skip, and vacuous assertions must not be counted as ordinary PASS.


    Attribution: recorded via impl-review-loop orchestrator at the explicit direction of the human operator (owner) in response to PR #2006 iteration 1 HUMAN_REVIEW_REQUIRED verdict. Date: 2026-08-06.

  6. added a commit that references this issue on Aug 6, 2026
  7. squne121 commented on Aug 6, 2026

    @squne121
    OwnerAuthor

    Owner Decision 2 on Issue #1958 (AC8 scope expansion, in response to PR #2006 iteration 2 HUMAN_REVIEW_REQUIRED verdict, reviewed_head_sha cf740a1)

    The owner authorizes BOTH of the two options presented by the iteration-2 pr-review-judge verdict:

    1. Allowed Paths expansion (authorized)

    Add to Issue #1958's Allowed Paths:

    • playwright.config.ts
    • scripts/check-visual-artifact-pipeline.py

    Edit authority for these two files remains scoped strictly to what's needed to support true multi-viewport VRT capture registration for AC8 (e.g. additional Playwright projects/viewports, and per-call-site viewport parsing/validation in the artifact pipeline checker). No unrelated config changes, no removal of existing project/browser coverage, no unrelated validator rule changes.

    2. CI matrix / fingerprint-schema restructuring (authorized)

    The owner authorizes restructuring the VRT evidence pipeline's fingerprint schema and/or CI job matrix as needed so that each individual VRT capture can carry and be validated against its own declared viewport (rather than the current single run-wide viewport fingerprint token), specifically to register the AC8 representative boundary-cell baselines: 1366x768, 1920x1080, 1437x1365 (or low-DPR approximation), 375x667, and the existing 1280x720 if still needed.

    This authorization is scoped to the minimal schema/matrix change needed for AC8's baselines — do not use this as license for a broader visual-testing-pipeline rewrite. Preserve the existing hard-fail contract properties in docs/dev/visual-baseline-registry.md §5 (uses/if/id/with.name/with.path/if-no-files-found/retention-days exact-value checks) for whichever CI job(s) end up producing the required uploads; extend rather than relax them.

    All other constraints from Owner Decision 1 (2026-08-06) remain in force: representative boundary cells only, individual expected/actual/diff review per PNG, changed PNGs enumerated individually in the PR body and visual baseline registry (no blanket snapshot-directory update), scripts/check-visual-artifact-pipeline.py cross-validation must actually pass proving no missing declarations, and AC8 must still be completed in this same Issue/PR (no follow-up split).


    Attribution: recorded via impl-review-loop orchestrator at the explicit direction of the human operator (owner), who replied "1,2 Y" confirming both options presented in the iteration-2 pr-review-judge HUMAN_REVIEW_REQUIRED verdict. Date: 2026-08-07.

  8. added 2 commits that reference this issue on Aug 6, 2026
  9. squne121 commented on Aug 7, 2026

    @squne121
    OwnerAuthor

    implement-issue: fix_delta iteration 3 実装完了 (2026-08-07)

    OWNER の PR #2006 REQUEST_CHANGES(reviewed_head_sha 465774a、コメント)で指摘された 4 件の merge blocker に対応し、既存ブランチへ push しました。

    対応内容

    1. AC8 VRT baseline(P0): pinned CI Docker image(mcr.microsoft.com/playwright@sha256:9bd26ad9...)内で 4 つの boundary-cell baseline(1366x768, 1920x1080, 1437x1365 DPR0.667, 375x667)と既存の legacy-current/paused/result-timeout baseline を再生成。個別 diff review 済み(すべてホスト Chromium とコンテナ間のフォントレンダリング差分のみで構造的差分なし)。tolerance widening は行っていません。
    2. AC5 実操作(P1): assistButton.evaluate(...click()) / .focus() を実 getByRole(...).click() / 実 Tab/Shift+Tab/Enter/Space に置換。専用の Tab 順序+focus indicator テストを追加。調査の過程で commandIntentRuntime.activeIntent(assistPlayerTtlTicks 133ms TTL、src/state/GameState.ts、Allowed Paths 外につき変更なし)が一発性の短命 transient であり、実クリックの actionability wait が 50ms poll interval の観測点をすり抜けることを発見・修正(10ms 間隔の atomic poll に変更)。
    3. AC1/AC3/AC4 geometry(P1): assertSemanticPlacement() を全可視 opaque fragment(elapsed/status/critical/edge-control/Assist/Pause)個別の 16px safe-margin containment チェックに書き換え(透明な [data-combat-hud] root への適用を除去)。"lower region"/"top region" を実測ジオメトリに基づく明示的 canvas-normalized 閾値に固定。null boundingBox は fail に変更。
    4. AC7 evidence head_sha(P1): 両 spec ファイルが EXPECTED_PR_HEAD_SHA(workflow 側で github.event.pull_request.head.sha || github.sha を設定)の 40-hex SHA 検証を必須化し、GITHUB_SHA の synthetic merge-ref や 'unknown' フォールバックを廃止。

    検証

    • host: typecheck / typecheck:e2e / lint / test(1864 pass)/ build 全 pass

    • pinned CI Docker image 内: hud-hull-overflow.spec.ts(23)/ assist-player-affordance.spec.ts(4、real-click テストは 5 回連続実行で再現性確認)/ product-pause.spec.ts(14)/ visual-overlay.spec.ts(10)全 pass

    • scripts/check-visual-artifact-pipeline.py: pass

    • PR: 実装: combat HUD の配置・safe-zone・情報優先度を実装する (#1958) #2006

    • Worktree: .claude/worktrees/issue-1958-combat-hud-safe-zone

    • Branch: worktree-issue-1958-combat-hud-safe-zone

    • head: ee7d0d4

    • 後続: 実 CI(e2e / ci-verdict-summary 含む)結果待ち → pr-review-judge 再レビュー

  10. squne121 commented on Aug 7, 2026

    @squne121
    OwnerAuthor

    OWNER approved Scope Delta: Allowed Paths extended to include tests/e2e/__screenshots__/m2-combat-mvp.spec.ts/m2-running-hud-baseline.png per #1958 (comment) finding, to unblock the required e2e CI job for PR #2006.

  11. added a commit that references this issue on Aug 7, 2026
  12. added a commit that references this issue on Aug 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/implementerenhancementphase/implementation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions