Skip to content

fix(bin): correct no-mistakes brief contract - #73

Merged
kunchenguid merged 2 commits into
mainfrom
fm/nm-brief-contract-w5
Jun 24, 2026
Merged

kunchenguid merged 2 commits into
mainfrom
fm/nm-brief-contract-w5

Conversation

@kunchenguid

Copy link
Copy Markdown
Owner

Intent

Fix firstmate's own driving instructions so crewmates stop deadlocking the no-mistakes gate. The misleading no-mistakes Definition-of-Done line in bin/fm-brief.sh ('fix auto-fix findings yourself') read as the crewmate self-committing fixes, which contradicts the pipeline contract (the pipeline owns the fixes). Replaced it with an explicit four-point contract: the crewmate drives the gates and never edits or commits code while a run is active; advances auto-fix findings with 'no-mistakes axi respond --action fix --findings '; escalates ask-user findings; and understands the run blocks synchronously for many minutes and often auto-fixes with no gate, so it must not cancel, abort, re-run, background, or idle-wait. Also fixed the supervisor-facing AGENTS.md line so the pipeline-fixes / crewmate-responds model is correct, and scoped the 'background long foreground-blocking work' guidance to firstmate's own session, clarifying that a crewmate driving its own no-mistakes validation runs it in the foreground synchronously. Deliberate scope decisions: touched ONLY bin/fm-brief.sh and AGENTS.md (recommendations P1-P3 from the root-cause report data/nm-gate-deadlock-x6/report.md); the no-mistakes tool, SKILL.md, and anything under projects/ were intentionally left out of scope (P4-P6 are a separate follow-up). The wording change applies only to the no-mistakes delivery-mode brief path; the direct-PR, local-only, scout, and secondmate brief shapes are intentionally unchanged. The new DOD is rendered as markdown bullets inside the heredoc with escaped backticks to preserve shell-correctness.

What Changed

  • Updated the no-mistakes brief contract so crewmates drive gate responses without editing or committing while a run is active.
  • Documented the corrected pipeline ownership model in AGENTS, README, and CONTRIBUTING, including foreground validation expectations for crewmates.
  • Captured that the validated pipeline passed after the test gate re-check confirmed the generated brief no longer includes the stale auto-fix wording.

Risk Assessment

✅ Low: Captain, the branch only adjusts instruction text in two files, aligns with the no-mistakes gate contract, and introduces no executable behavior changes.

Testing

Generated the actual crewmate-facing no-mistakes brief, verified it contains the new four-point synchronous gate-driving contract and not the old misleading self-fix wording, then ran ShellCheck, every tests/*.test.sh script, the CI invariant checks, and confirmed the worktree stayed clean.

Evidence: Generated no-mistakes crewmate brief
You are a crewmate: an autonomous worker agent managed by firstmate. Work on your own; do not wait for a human.

# Task
{TASK}

# Setup
You are in a disposable git worktree of firstmate, at a detached HEAD on a clean default branch.
1. First action: create your branch: `git checkout -b fm/nm-contract-e2e`
2. Run `no-mistakes doctor`; if it reports the repo is not initialized here, run `no-mistakes init`.

# Rules
1. Never push to the default branch. Never merge a PR.
2. Stay inside this worktree; modify nothing outside it.
3. Use gh-axi for GitHub operations and chrome-devtools-axi for browser operations.
4. Report status by appending one line:
   `echo "{state}: {one short line}" >> '/var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/fm-home-for-brief/state/nm-contract-e2e.status'`
   States: working, needs-decision, blocked, done, failed.
   Each append wakes firstmate, so report sparingly: only phase changes a supervisor
   would act on (setup done, bug reproduced, fix implemented, validation passed) and the
   needs-decision/blocked/done/failed states. No step-by-step FYI progress lines;
   firstmate reads your pane for that.
5. If you hit the same obstacle twice, append `blocked: {why}` and stop; firstmate will help.
6. If a decision belongs to a human (product choices, destructive actions, ask-user findings),
   append `needs-decision: {summary of options}` and stop. Firstmate will reply with the decision.

# Project memory
If `AGENTS.md` or `CLAUDE.md` already exists, or if this task produced durable project-intrinsic knowledge, run `/Users/kunchen/.no-mistakes/worktrees/016d88035d58/01KVXVDBQZC20QQTPTJRNJSZZA/bin/fm-ensure-agents-md.sh .` in the worktree.
If this task produced durable project-intrinsic knowledge, record it in `AGENTS.md` as part of your change.
Keep it proportionate: skip `AGENTS.md` edits for trivial tasks that produced no durable project knowledge.

# Definition of done
The task is complete only when committed on your branch.
When you believe it is complete, append `done: {summary}` to the status file and stop.
Firstmate will then instruct you to run /no-mistakes to validate and ship a PR.

During validation you drive the gates while the pipeline owns the fixes. Run it in the foreground and follow this contract:
- Never edit or `git commit` code yourself while a run is active; the pipeline applies every fix in its own worktree.
- When a gate shows auto-fix findings, advance it with `no-mistakes axi respond --action fix --findings <ids>` (the pipeline applies the fix and re-reviews). Escalate ask-user findings per rule 6.
- `no-mistakes axi run` and `axi respond` block synchronously for many minutes (test and CI especially); the pipeline often fixes findings itself with no gate, so when a call returns no `gate:` object that is normal - just let it return.
- Never cancel, abort, re-run, or background the run, and never idle-wait for a background notification: the call is in the foreground and returns on its own.

After /no-mistakes reports CI green, append `done: PR {url} checks green` and stop. You are finished.
Evidence: Behavior test transcript
### tests/fm-afk-inject-e2e.test.sh
ok - Scenario A: partial input defers injection; digest arrives clean after idle
ok - Scenario B: swallowed Enter produces exactly one clean digest
all e2e injection tests passed
### tests/fm-bootstrap.test.sh
ok - bootstrap accepts treehouse get --lease support
ok - bootstrap reports treehouse without get --lease support
ok - bootstrap reports compatible optional tasks-axi availability
ok - bootstrap ignores incompatible optional tasks-axi
### tests/fm-composer-ghost.test.sh
ok - fm_tmux_strip_ghost drops dim/faint runs, keeps normal and bold text
ok - fm_tmux_strip_ghost handles combined SGR, ESC[22m, and reset-then-dim
ok - fm_tmux_strip_ghost keeps colored text with 2 payloads
ok - fm_pane_input_pending: a dim ghost-only composer is NOT pending
ok - fm_pane_input_pending: dim ghost inside a bordered composer is NOT pending
ok - fm_pane_input_pending: normal-intensity typed text is still pending
ok - fm_pane_input_pending: colored text with 2 payloads is still pending
ok - fm_pane_input_pending: real text plus a trailing ghost run is still pending
ok - fm-peek output is escape-free (no raw -e bytes reach firstmate context)
### tests/fm-secondmate.test.sh
ok - FM_HOME parameterizes data and state paths
ok - fm-lock status is scoped per home
ok - secondmates registry records scopes and allows overlapping project clone lists
ok - home seeding records routing scope from filled charter briefs
ok - home seed validation rejects duplicate home routes
ok - home seed validation rejects duplicate id routes
ok - home seed validation rejects nested home routes
leased worktree for dash
ok - home seeding durably leases treehouse-acquired dash homes under the secondmate id
ok - home seeding returns rejected acquired homes through treehouse
ok - home seed rollback warns when treehouse-acquired return fails
ok - home seeding leaves unsafe acquired active homes untouched
ok - home seeding rolls back failed clone attempts without residue
ok - home seeding refuses direct seed without filled charter text
ok - home seeding refuses unfilled placeholder charters
ok - home seeding refuses empty normalized charter fields
ok - home seeding refuses local-only projects
ok - home seeding refuses registry delimiter home paths
ok - home seeding refuses active home and repo root
ok - home seeding refuses homes marked for another id
ok - home seeding refuses homes registered to another id
ok - home seeding refuses same-id reassignment to a different home
ok - home seeding refuses registered home overlaps
ok - remote-backed subhome seeding requires a source origin
ok - remote-backed subhome seeding validates existing destination origins
ok - home seeding resolves relative source origins against the source project
ok - home seeding skips initialized existing no-mistakes clones
ok - home seeding refuses uninitialized existing no-mistakes clones
ok - home seeding refuses project destinations outside the subhome
ok - home seeding refuses operational directories outside the subhome
ok - home seeding refuses symlinked leaf files
ok - kind=secondmate spawn launches in the home and records routing meta
ok - secondmate spawn validates homes before launch
ok - secondmate spawn refuses operational directories outside the subhome
ok - fm-send resolves bare firstmate windows through this home
ok - restart recovery can respawn a secondmate from durable registry and charter
ok - secondmate teardown retires empty homes and releases routing
ok - secondmate teardown refuses to hide failed leased-home return
ok - secondmate teardown raw-removes plain-clone homes
ok - secondmate force teardown discards child work
ok - force teardown allows operational directory symlinks inside the subhome
ok - force teardown refuses operational directory symlinks outside the subhome
ok - secondmate teardown requires seeded home marker
ok - secondmate teardown refuses homes containing registered nested homes
ok - secondmate teardown refuses nested homes from the child registry
ok - force teardown validates subhome before child cleanup
ok - force teardown refuses child worktrees inside the active home
ok - force teardown refuses child worktrees inside the firstmate repo
ok - force teardown refuses unregistered child worktree paths
ok - secondmate teardown refuses ancestor homes
ok - secondmate teardown refuses descendant homes
ok - idle kind=secondmate pane is healthy and not stale
ok - secondmate charter brief is idle by default and does not self-initiate work
ok - fm-backlog-handoff moves in-scope items, is idempotent, and aborts safely
ok - fm-backlog-handoff creates absent sections and refuses unsafe homes
### tests/fm-spawn-batch.test.sh
ok - batch dispatch re-execs and reports every id=repo pair
ok - a single id=repo pair routes through batch dispatch
ok - single-task invocation (no '=') is untouched by batch detection
ok - batch dispatch rejects an argument that is not id=repo
ok - an arg whose id part contains '/' is not treated as a batch pair
ok - FM_HOME scopes projects/ paths for single-task spawn
ok - FM_PROJECTS_OVERRIDE scopes projects/ paths for single-task spawn
### tests/fm-teardown.test.sh
ok - local-only worktree with HEAD on a fork remote is torn down (fix holds)
ok - teardown prompts tasks-axi backlog refresh when compatible
ok - local-only worktree with truly unpushed work is refused (safety preserved)
ok - local-only worktree with work merged into local main is torn down (no regression)
ok - no-mistakes worktree with HEAD on origin is torn down (no regression)
ok - no-mistakes worktree with truly unpushed work is refused (no regression)
ok - local-only worktree with unpushed work is torn down under --force (escape hatch)
### tests/fm-update.test.sh
ok - T1 main + secondmate fast-forward, reread + nudge signalled
ok - T2 advance is a fast-forward, not a merge commit
ok - T3 reread gates on instruction surface, nudge on advancement
ok - T4 dirty secondmate skipped, local edit preserved
ok - T5 diverged secondmate skipped, local commit preserved
ok - T6 idempotent: a second run is a no-op
ok - T7 secondmate resolved from registry without inventing a window
ok - T8 deduped homes and excluded the firstmate repo itself
ok - T9 firstmate off its default branch is skipped, not forced
ok - T10 firstmate detached HEAD is skipped
ok - T11 unsafe secondmate home is not fast-forwarded
# all fm-update tests passed
### tests/fm-wake-queue.test.sh
ok - supervise daemon state root is scoped by FM_HOME
ok - concurrent append plus drain preserves queue records
ok - signal written while no watcher runs is caught on next run
ok - stale wake is queued before suppressor state is advanced
ok - check output is queued before cadence suppression
ok - simultaneous watcher starts leave exactly one live process
ok - two atomic drains cannot consume the same records twice
ok - drain collapses obvious duplicate heartbeat and signal records
ok - killed watcher stale lock is reclaimed
ok - live watcher lock with stale heartbeat is actionable
ok - concurrent fm_lock_try_acquire yields exactly one winner
ok - dead-pid stale lock is reclaimed by a single acquirer
ok - concurrent stale-lock steal yields exactly one winner
ok - live steal mutex is not reclaimed
ok - live-held lock is not stolen
ok - empty mid-acquire lock keeps a minimum grace
ok - late original claimant cannot claim a recreated lock
ok - paused mid-acquire claimant backs off to active stealer
ok - watch restart refuses to signal a reused pid
ok - watcher self-evicts when the lock pid no longer names it
ok - guard warns when queued wakes are pending
ok - guard orders watcher re-arm after queued wake drain
ok - routine signal self-handles
ok - captain-relevant status verbs escalate
ok - check + unknown escalate; heartbeat self-handles
ok - transient stale self-handles and records a persistence marker
ok - stale + terminal status escalates immediately
ok - persistent stale escalates after threshold and clears its marker
ok - resumed (busy) stale clears its marker without escalating
ok - multiple escalations flush as a single batched digest
ok - batch flush measures max-delay from the first append, not the last
ok - catch-all scan escalates a missed terminal once, not twice
ok - handle_wake routes routine->self and captain->escalate
ok - INJECT_SKIP forces self-handle, bypassing captain-relevant classification
ok - is_wake_reason distinguishes watcher wake reasons from singleton-status stdout
ok - terminal-stale escalate removes its marker so housekeeping does not re-escalate
ok - captain signal escalate marks seen so the catch-all scan does not re-fire
ok - _collapse_newlines replaces newlines with literal separator
ok - afk flag absent: daemon does not inject, buffer preserved
ok - afk flag present: daemon injects with sentinel marker prefix
ok - injected digest is single-line (no embedded newlines)
ok - busy-guard defers injection when supervisor pane is busy
ok - marker detection: marker -> stay afk, no marker -> exit afk
ok - /afk invocation is exempt from afk exit (no self-cancel)
ok - should_exit_afk returns false when afk is not active
ok - strip_injection_marker removes the sentinel marker cleanly
ok - pane_input_pending detects partial input on the cursor line
ok - pane_input_pending: blank cursor line is not pending
ok - pane_input_pending: bare prompts are not pending (idle)
ok - pane_input_pending honors FM_COMPOSER_IDLE_RE after border stripping
ok - composer guard defers injection when pane has pending input
ok - swallowed Enter: type-once + Enter-retry, no concatenation
ok - normal inject: exactly one digest, one Enter, no duplicates
ok - classify_signal dedupes against the catch-all scan seen marker
ok - classify_stale dedupes against the signal path seen marker
ok - pane_input_pending: an idle bordered composer is NOT pending (afk-invx-i5)
ok - pane_input_pending: text inside a bordered composer is still pending
ok - submit-ACK confirms a submit when the composer returns to a bordered-empty box
ok - submit-ACK reports pending on a persistently swallowed Enter (type-once)
ok - max-defer on an empty stuck pane types once, alarms, and preserves the buffer
ok - max-defer flushes and clears the buffer on an empty bordered pane
ok - max-defer on a pending composer alarms without typing
ok - normal flush clears a stale wedge marker
ok - below MAX_DEFER: no inject, no alarm, buffer preserved
ok - max-defer does not flush or alarm while afk is inactive
ok - fm-send exits non-zero on a confirmed swallow, zero on a clean submit
ok - fm-send exits non-zero when initial text send fails
- Outcome: 🔧 1 issue found → auto-fixed ✅ across 2 runs (14m25s)

Pipeline

Updates from git push no-mistakes

✅ **intent** - passed

✅ No issues found.

✅ **Rebase** - passed

✅ No issues found.

✅ **Review** - passed

✅ No issues found.

🔧 **Test** - 1 issue found → auto-fixed ✅
  • ⚠️ Blocked before testing: repository instructions require firstmate to delegate project-specific work to a crewmate and not perform the validation directly, but this testing prompt explicitly asks me to run the tests myself inside this worktree and to confine writes to the worktree/evidence directory. These instructions conflict, so I did not execute tests or create evidence.
  • Instruction reconciliation only; no repository commands were run.

🔧 Fix: Tests pass without code changes
✅ Re-checked - no issues remain.

  • FM_HOME=/var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/fm-home-for-brief ./bin/fm-brief.sh nm-contract-e2e firstmate
  • sed -n '1,260p' /var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/fm-home-for-brief/data/nm-contract-e2e/brief.md
  • Confirmed grep -F &#34;fix auto-fix findings yourself&#34; /var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/fm-home-for-brief/data/nm-contract-e2e/brief.md returned no matches.
  • grep -n -E "pipeline owns the fixes|Never edit|no-mistakes axi respond --action fix|block synchronously|Never cancel" /var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/fm-home-for-brief/data/nm-contract-e2e/brief.md
  • shellcheck bin/*.sh tests/*.sh > /var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/shellcheck.log 2>&1
  • bash -c 'set -euo pipefail; log=/var/folders/5x/4nqprlbx0518k3ybcb1sz6gr0000gn/T/no-mistakes-evidence/01KVXVDBQZC20QQTPTJRNJSZZA/tests-transcript.log; : > "$log"; for test_script in tests/*.test.sh; do printf "### %s\n" "$test_script" | tee -a "$log"; "$test_script" 2>&1 | tee -a "$log"; done'
  • bash -c 'set -eu; [ "$(readlink CLAUDE.md)" = "AGENTS.md" ]; [ "$(readlink .claude/skills)" = "../.agents/skills" ]'
  • bash -c 'set -eu; tracked=$(git ls-files -- data state config projects .no-mistakes); [ -z "$tracked" ]'
  • git status --short
✅ **Document** - passed

✅ No issues found.

✅ **Lint** - passed

✅ No issues found.

✅ **Push** - passed

✅ No issues found.

The no-mistakes definition-of-done told crewmates to "fix auto-fix
findings yourself", which reads as self-committing fixes - the exact
behavior the pipeline forbids. Crewmates anchored on it self-committed
or aborted a healthy long run, tangling git state and stalling the fleet.

- fm-brief.sh: the crewmate drives the gates and never edits or commits
  code while a run is active; it advances auto-fix findings with
  `no-mistakes axi respond --action fix`; the run blocks for minutes and
  auto-fixes itself with no gate, so do not cancel, abort, re-run, or
  background it, or idle-wait for a notification.
- AGENTS.md: fix the supervisor-facing line (the pipeline fixes, the
  crewmate responds and never edits during a run) and scope the
  "background long work" guidance to firstmate's own session, so a
  crewmate runs its own validation in the foreground.
@kunchenguid
kunchenguid merged commit 88b8fa0 into main Jun 24, 2026
4 checks passed
@kunchenguid
kunchenguid deleted the fm/nm-brief-contract-w5 branch June 24, 2026 22:48
leo1oel added a commit to leo1oel/nemo that referenced this pull request Jun 25, 2026
…uid#73, kunchenguid#72) (#3)

- kunchenguid#73: correct the no-mistakes definition-of-done in fm-brief.sh. The crewmate
  drives the gates and never edits/commits code while a run is active (the
  pipeline applies fixes in its own worktree); it advances auto-fix findings via
  `no-mistakes axi respond --action fix` and runs its own validation in the
  foreground. Sync the supervisor-facing line and the firstmate-session-scoped
  background guidance in AGENTS.md.
- kunchenguid#72: drop the redundant vendored .agents/skills/no-mistakes (no-mistakes is a
  user-level skill, not firstmate-shipped); add a Built-in skills table to README
  listing only /afk and /updatefirstmate (Claude-only fork, no codex row).
stoneevenson-biz added a commit to stoneevenson-biz/firstmate that referenced this pull request Aug 27, 2026
Post-rebase reconciliation after upstream restructured the test suite (kunchenguid#80)
and the brief contract (kunchenguid#73):

- bin/fm-brief.sh: collapse the gate-check definition-of-done clause, which had
  landed once per delivery-mode heredoc (3x), into a single GATE_CHECK variable
  appended once after the mode DOD. Identical brief output, no duplication.
- tests/fm-secondmate-lifecycle-e2e.test.sh: re-land the scoped-watch coverage
  on the relocated spawn phase — stub the watch start via FM_CTX_WATCH_START_CMD
  (no leaked daemon) and assert a secondmate spawn starts a context-watch scoped
  to its own home; stub the recovery respawn's watch start too.
- tests/fm-tangle-guard.test.sh: assert the crew-launch FM_HOME pin on the
  existing genuine-isolated-worktree success path (the post-kunchenguid#83 harness that can
  actually reach a successful ship launch), proving a crew launch pins FM_HOME to
  the spawning home for context-sentinel routing; teach its fake tmux to log
  send-keys so the launch env is observable.

Full suite green (24 files), shellcheck clean, zero leaked daemons.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@Julian-Dasilva

Copy link
Copy Markdown

No description provided.

pranaypratyush pushed a commit to pranaypratyush/firstmate that referenced this pull request Aug 31, 2026
* feat: port trusted condition-action watcher

* fix(procevent): harden unattended action policy

Keep remote lifecycle, merge, teardown, source-control, and public-reply entrypoints behind their existing authority gates. Cover direct and byte-identical alias rejection through the public watcher interface.

* no-mistakes(review): Hardened allowlist, immutable execution staging, and fired-state ambiguity

* no-mistakes(review): Replaced deny-list policy with explicit executable allowlisting

* no-mistakes(document): Document process-event timeout helper

* no-mistakes(review): Removed deny-list trust gating; preserved signal failures in Perl timeout

* no-mistakes(document): Refresh process-event documentation ownership and verification
@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

방법

코드 읽기와 계산만 했다. 시뮬레이터·기기 실행 없음, 스크린샷 열지 않음.

색 값은 lib/theme.dart 와 화면에 남은 하드코딩 hex 에서 그대로 읽었고, 대비는 WCAG 2.x 공식(상대 휘도 → (L1+0.05)/(L2+0.05))으로 계산했다. 알파 겹침은 Flutter 의 Color.withValues(alpha:) 와 같게 sRGB 8bit 에서 out = a*fg + (1-a)*bg 로 합성했다.

Theme.of(context) 가 정하는 값(칩 라벨색 등)은 코드에 없으므로 flutter test 로 buildTheme().colorScheme 을 한 번 찍어 실측했다(Flutter 3.47.2, 2026-09-06) — onSurfaceVariant #47464F, surfaceContainerLow #F6F2FA. 그 프로브 테스트 파일은 지웠고 워크트리에 남긴 변경은 없다.

전체 스크립트와 실행 출력은 이 문서 맨 아래 부록에 있다.

1. 현황 목록 — 색과 글자 크기가 어디서 오는가

값의 출처는 넷이다: ① 테마 토큰(AppColors.*), ② Theme.of(context)(M3 기본값, 코드에 값 없음), ③ 화면 로컬 상수(그 파일에서만 정한 알파·크기), ④ 하드코딩 hex.

배지 모양의 위젯 여섯 벌

위젯 파일:줄 바탕 글자색 크기·굵기 padding / radius 출처
StatusBadge lib/widgets/status_badge.dart:16 forStatus(s) @0.12 forStatus(s) 12 / dense 11 · w700 10·4 / dense 8·2 / r20 ① + ③(알파·크기)
KindBadge lib/widgets/status_badge.dart:47 forKind(k) @0.12 forKind(k) 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
UnconfirmedBadge lib/widgets/status_badge.dart:160 faint @0.18 subtle 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
2b 라벨 바 _LabelBar lib/screens/calendar_screen.dart:853 forKind(k, confirmed) @0.16 확정 = 종류색 · 미확정 = subtle 10 · w700 4·0, height 18 / r4 ① + ③
표 이름 알약 _tableSection lib/widgets/record_editor_sheet.dart:855 accentFaint(불투명) accent 12 · w700 10·4 / r20 ①
_ExternalBadge lib/widgets/record_editor_sheet.dart:1174 accentFaint + line 테두리 accent 11 · w400 10·6 / r8 ①

반경이 4·6·8·20 넷, 알파가 0.12·0.16·0.18·불투명 넷, 글자 10~12px 셋이다. 같은 "알약"인데 공유하는 상수가 하나도 없다.

칩

자리 파일:줄 켜짐 꺼짐 크기 출처
포착 화면 감지 칩 lib/widgets/capture_composer.dart:424 accent / accentFaint subtle / bg 14(기본) w600 ①
구조화 감지 칩 lib/screens/structure_screen.dart:334 ok / #EAF7EF accent / accentFaint 13 w600 ① + ④
구조화 "태스크로" lib/screens/structure_screen.dart:376 forKind(task) / 그 색 @0.12 accent / bg 13 w600 ① + ③
표 종류 필터 ChoiceChip lib/screens/table_screen.dart:262 라벨색 없음 → onSurfaceVariant / forKind(k) @0.16 〃 / surfaceContainerLow 12 ② + ① + ③
표 마일스톤·프로젝트 필터 lib/screens/table_screen.dart:309·327 〃 @0.16 〃 12 ② + ① + ③
상태 필터 lib/screens/table_screen.dart:355 〃 / accentFaint 〃 12 ② + ①

상태 표시·비활성 표시

자리 파일:줄 값 출처
상태 색 규칙 lib/theme.dart:24 done→ok · in_progress→warn · 그 외 accent ① (한 곳, 좋다)
종류 색 규칙 lib/theme.dart:34 종류별 hex 4 개 + confirmed:false → faint ① (한 곳, 좋다)
칸반 컬럼 바탕(Done) lib/screens/table_screen.dart:940 #F2F2EF ④
칸반 카드 흐리기(Done) lib/screens/table_screen.dart:1052 Opacity(0.65) — 카드 전체 ③
칸반 드래그 중 원본 lib/screens/table_screen.dart:1065 Opacity(0.3) ③
후보 타일 비선택 아이콘 lib/widgets/record_editor_sheet.dart:1035 faint ①
기한 지남 OverdueMark lib/screens/table_screen.dart:397 danger, 11px w700 ① (한 곳, 좋다)
저장 표시 lib/screens/capture_screen.dart:227 idle faint · saving subtle · saved ok · failed danger ①
삭제 lib/widgets/record_editor_sheet.dart:397·412 danger 글자·아이콘만. 삭제된 행을 표시하는 배지는 없다 — 삭제 표시(deleted_at)된 행은 조회에서 아예 빠진다 ①

하드코딩 hex 다섯 곳

파일:줄 값 비고
lib/screens/schema_screen.dart:409 #6B6B76 AppColors.subtle 과 같은 값을 다시 적었다
lib/screens/schema_screen.dart:429 #3B82C4 forKind(task) 와 같은 값을 다시 적었다
lib/screens/graph_screen.dart:439 #3B82C4 〃 (같은 값이 세 곳)
lib/screens/structure_screen.dart:343 #EAF7EF 초록 틴트. 토큰 없음
lib/screens/table_screen.dart:940 #F2F2EF 칸반 Done 바탕. 토큰 없음

글자 크기

크기는 전부 위젯 안의 리터럴이다 — theme.dart 에는 appBarTheme.titleTextStyle(20) 과 navigationBarTheme.labelTextStyle(11) 둘뿐이고 textTheme 은 손대지 않는다. 앱 전체에서 fontSize: 리터럴이 9·10·11·12·13·14·15·16·18·20 열 종류로 흩어져 있다.

2. 규칙 일치 여부

미확정은 규칙이 하나다 — 잘 되어 있다. 판정의 원본이 레코드 필드 하나(AppState.isCaptureConfirmed)이고, 캘린더 아젠다(calendar_screen.dart:601)·구조화 카드(structure_screen.dart:269)·표 카드(table_screen.dart:535)·표 셀(:662)·칸반 카드(:1030)·포착 화면 최근 줄(capture_screen.dart:323)이 모두 같은 UnconfirmedBadge 를 쓴다. 배지를 못 놓는 2b 라벨 바만 색으로 말한다(calendar_screen.dart:853).

확정은 규칙이 둘이고, 서로 뜻이 뒤집혀 있다. 포착 화면의 감지 칩은 확정 이 accent 글자 + accentFaint 바탕이고(capture_composer.dart:424), 구조화 탭의 감지 칩은 똑같은 accent/accentFaint 가 미확정이며 확정은 초록(ok/#EAF7EF)이다(structure_screen.dart:334). 같은 픽셀이 한 화면에서는 "확정", 다른 화면에서는 "아직 아님"을 뜻한다.

체크 아이콘도 갈린다: 꺼진 상태가 포착 화면은 add_circle_outline, 구조화는 radio_button_unchecked 다. 켜진 상태만 둘 다 check_circle 이다.

종류 배지는 색 규칙은 하나(forKind)인데 그 색을 쓰는 방식이 화면마다 다르다. 배지·6a 카드 머리는 @0.12(status_badge.dart:54, schema_screen.dart:516), 2b 라벨 바와 표 필터 칩은 @0.16(calendar_screen.dart:869, table_screen.dart:264), 칸반 드롭 하이라이트와 4b 링크 칩은 @0.1(table_screen.dart:939, record_editor_sheet.dart:995), 6a 점선 테두리는 @0.5(schema_screen.dart:502). 여섯 자리에 네 알파다.

삭제 표시는 규칙이랄 것이 없다. 삭제된 행은 화면에서 사라지므로 표시가 필요 없고, 삭제 동작 만 danger 로 통일돼 있다(record_editor_sheet.dart:397·412, name_edit_sheet.dart:133·167, data_card.dart:146). 여기는 손댈 것이 없다.

비활성은 규칙이 없다. 칸반 Done 은 Opacity(0.65) 로 카드 전체를 흐리고(table_screen.dart:1052), 4b 후보 타일은 faint 아이콘으로(record_editor_sheet.dart:1035), 2b 미확정 바는 forKind(confirmed:false) 로, 저장 표시 idle 은 faint 로 말한다. 넷 다 "덜 중요함"인데 네 가지 길이다.

한 가지 반전이 눈에 띈다. Theme.of(context) 에 맡긴 자리(ChoiceChip 라벨)는 대비가 7.2~8.4:1 로 전부 넉넉하고, AppColors 에서 손으로 고른 자리가 무너진다. M3 는 틴트 바탕 위에 어두운 중립색(onSurfaceVariant #47464F)을 얹는데, 이 앱은 틴트와 같은 색조를 얹기 때문이다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 2/5 — 질문 3 대비 계산 · 질문 4 제안 팔레트.

3. 대비 계산

밝은 화면 기준, WCAG 2.x. 4.5:1 기준(모든 항목이 18.66px 미만이라 "큰 글자" 예외에 해당하지 않는다).

4.5:1 미달 (25 / 39)

자리 파일:줄 전경 배경(합성 결과) 크기 대비
미확정 배지(칸반 Done, Opacity .65) table_screen.dart:1030 #9A9AA0 #F2F2F2 10 2.50
미확정 배지(앱 배경 위 카드) status_badge.dart:176 #6B6B76 #EDEDED 10 4.50 (경계)
2b 라벨 바 · 미확정(선택된 날) calendar_screen.dart:854 #6B6B76 #E4E4F1 10 4.18
2b 라벨 바 · 확정 Record calendar_screen.dart:853 #5B5BD6 #E1E1F2 10 4.15
2b 라벨 바 · 확정 Task 〃 #3B82C4 #DBE7EF 10 3.22
2b 라벨 바 · 확정 Milestone 〃 #B4508E #EFDFE6 10 3.65
2b 라벨 바 · 확정 TimeEntry 〃 #2E9E5B #D9EBDE 10 2.74
종류 배지 Task status_badge.dart:46 #3B82C4 #E7F0F8 10 3.52
종류 배지 Milestone 〃 #B4508E #F6EAF1 10 4.01
종류 배지 TimeEntry 〃 #2E9E5B #E6F3EB 10 2.99
상태 배지 In progress status_badge.dart:15 #D98A00 #FAF1E0 11 2.47
상태 배지 Done 〃 #2E9E5B #E6F3EB 11 2.99
감지 칩 · 확정(구조화) structure_screen.dart:338 #2E9E5B #EAF7EF 13 3.09
"태스크로" 칩 · 켜짐 structure_screen.dart:410 #3B82C4 #E7F0F8 13 3.52
구조화 카드 #id · 시각 structure_screen.dart:254 #B4B4BE #FFFFFF 12 2.06
구조화 "감지된 것 없음" structure_screen.dart:279 #B4B4BE #FFFFFF 12 2.06
구조화 미확정 구역 설명 structure_screen.dart:210 #B4B4BE #FAFAF7 11 1.97
구조화 타입 필드 이름 structure_screen.dart:492 #B4B4BE #FAFAF7 12 1.97
아젠다 사영 주석 calendar_screen.dart:618 #B4B4BE #FFFFFF 11 2.06
마일스톤 상태 요약 status_badge.dart:137 #B4B4BE #FFFFFF 11 2.06
저장 표시 idle capture_screen.dart:227 #B4B4BE #FAFAF7 12 1.97
DB 오류 배너 제목 db_error_banner.dart:86 #C4444D #FDEEEF 14 4.36
그래프 노드 제목 Task graph_screen.dart:666 #FFFFFF #3B82C4 12 4.06
그래프 노드 제목 TimeEntry 〃 #FFFFFF #2E9E5B 12 3.41
그래프 노드 제목 Project 〃 #FFFFFF #D98A00 12 2.77

통과 (14 / 39) — 주요 항목만

자리 전경 / 배경 대비
미확정 배지(흰 카드 위) #6B6B76 / #F2F2F3 4.70
2b 라벨 바 · 미확정(보통 날) #6B6B76 / #EFEFEE 4.57
종류 배지 Record · 상태 배지 To do #5B5BD6 / #EBEBFA 4.55
감지 칩(포착 화면, 양쪽 상태) #5B5BD6/#EDEDFB · #6B6B76/#FAFAF7 4.63 · 5.03
보조 텍스트 subtle #6B6B76 / #FFFFFF 5.26
기한 지남 표시 #C4444D / #FFFFFF 4.91
본문 ink #1D1D22 / #FFFFFF 16.79
ChoiceChip 라벨(테마가 정함) #47464F / 각 틴트 7.20 ~ 8.42

대장이 본 것 — 왜 구조화 탭 미확정 카드가 더 안 읽히나

배지끼리만 보면 구조화가 오히려 낫다. 구조화 카드의 미확정 배지는 흰 카드 위라 4.70:1 이고, 2b 라벨 바의 미확정 글자는 4.57:1 이다. PR #72 리뷰가 지적한 1.85:1 은 이미 고쳐졌다(리뷰가 본 것은 바탕과 글자에 같은 회색을 쓰던 판이고, 지금은 calendar_screen.dart:854 가 글자를 subtle 로 따로 뽑는다).

차이는 배지가 아니라 그 배지가 앉아 있는 카드다. 구조화 카드에서 배지 말고 눈에 들어오는 글자는 넷인데 전부 faint 다 — #id(2.06), 포착 시각(2.06), "감지된 것 없음"(2.06), 타입 필드 이름(1.97). 그 카드를 이끄는 구역 머리글의 설명("확정된 일시가 없어 포착한 날에…")도 1.97 이다. 사람은 배지 하나가 아니라 카드를 읽으므로, 배지만 4.70 이고 나머지가 2.0 이면 "카드가 안 읽힌다"가 된다.

세 가지가 겹친다. ① 색 — faint #B4B4BE 는 흰 바탕에서 2.06:1 로, 앱에서 가장 낮은 값이다. ② 크기와 굵기 — 구조화의 그 글자들은 11~12px 보통 굵기이고, 2b 바의 글자는 10px 이지만 w700 이다. 얇은 획이 밝은 회색일 때 훨씬 빨리 사라진다. ③ 배경 겹침 — 2b 바는 회색 바탕이 글자를 받쳐 주어 글자가 면으로 잡히는데, 구조화의 faint 글자들은 순백(#FFFFFF) 위에 아무 받침 없이 떠 있다. 흰 카드는 앱 배경(#FAFAF7)보다 밝아서 같은 회색이라도 여기서 가장 흐리다.

앱 전체에서 가장 안 읽히는 자리는 따로 있다 — 칸반 Done 컬럼의 미확정 배지 2.50:1. table_screen.dart:1052 가 카드 전체를 Opacity(0.65) 로 감싸므로 배지의 글자와 바탕이 함께 컬럼 바탕(#F2F2EF)에 섞인다. 색을 아무리 고쳐도 이 자리는 팔레트로 못 고친다(제안 색으로도 2.69, 4.5:1 을 넘으려면 불투명도 0.82 이상이 필요하다).

4. 제안 팔레트

새 시스템이 아니라 AppColors 에 토큰 다섯 개를 더하고 하나의 뜻을 좁히는 것이다.

무채색 — 미확정 전경 · 비활성 · 보조 텍스트

토큰 값 뜻 흰 카드 앱 배경 미확정 바탕
ink #1D1D22 (그대로) 본문 16.79 — —
subtle #6B6B76 → #5C5C68 배지 글자·구역 머리글·강한 보조 6.59 6.30 5.39
muted (새 토큰) #6B6B76 지금 faint 가 쓰이던 글자 자리 5.26 5.03 4.31
faint #B4B4BE (그대로) 글자 금지 — 아이콘·선·플레이스홀더 전용 2.06 1.97 1.68
mutedBg (새 토큰) #E8E8EC 미확정 배지 바탕(불투명) — — —

subtle 의 현재 값이 사라지지 않고 muted 라는 이름으로 한 단 아래로 내려간다 — 그래서 지금 subtle 인 자리는 조금 진해지고, 지금 faint 글자 인 자리는 #B4B4BE → #6B6B76 로 확실히 진해진다. faint 는 값 그대로 남아 line 대용 아이콘·비활성 아이콘 자리를 계속 맡는다.

muted 는 미확정 배지 바탕 위에서 4.31 로 모자라므로, 배지 글자는 subtle 이다. 위 표의 굵은 값이 그 규칙을 지킨다.

틴트 — 배지·라벨 바·칩 바탕

바탕을 알파가 아니라 불투명 상수로 바꾼다. 알파를 남기면 같은 배지가 흰 카드·앱 배경·선택된 날 셀·칸반 컬럼에서 각각 다른 색이 되고, 그 넷 중 어디서 4.5:1 이 깨지는지 화면마다 따로 세야 한다.

tint(c)   = c 를 12% 로 흰 카드 위에 미리 합성한 불투명 값
onTint(c) = 그 틴트 위에서 4.5:1 을 넘는, c 를 어둡게 한 잉크
종류·상태 원색(그대로 씀) tint onTint 대비 원색이었다면
Record · To do #5B5BD6 #EBEBFA #4F4FC9 5.40 4.55
Task #3B82C4 #E7F0F8 #30699F 5.00 3.52
Milestone #B4508E #F6EAF1 #9E467D 4.95 4.01
TimeEntry · Done #2E9E5B #E6F3EB #247B47 4.60 2.99
In progress (warn) #D98A00 #FAF1E0 #8F5B00 5.11 2.47
danger #C4444D #F8E9EA #B03B44 5.02 4.17
미확정 — #E8E8EC #5C5C68 5.39 4.70 (현행)

원색(forKind·forStatus)은 점·테두리·그래프 노드 바탕·진척 막대처럼 색 면으로 쓰는 자리에 그대로 남는다. 바뀌는 것은 "틴트 위에 얹는 글자"뿐이다. #EAF7EF(구조화 확정 칩)와 #F2F2EF(칸반 Done)는 각각 tint(ok) 와 mutedBg 계열로 흡수되어 하드코딩 hex 다섯 곳 중 셋이 사라진다.

덤으로 그래프 노드도 낫다. 노드 바탕을 원색 대신 onTint(c) 로 칠하면 흰 글자 대비가 Task 4.06 → 5.76, TimeEntry 3.41 → 5.61, Milestone 4.69 → 5.79 가 된다. 다만 그래프는 Issue #73 의 "배지" 범위 밖이라 별도 판단이 필요하다(아래 "대장 결정 필요").

팔레트로 못 고치는 것 하나

칸반 Done 카드의 Opacity(0.65)(table_screen.dart:1052) 는 색 문제가 아니다. 권고는 그룹 Opacity 를 없애고 "물러남"을 이미 있는 것들로 말하는 것이다 — 저채도 컬럼 바탕(#F2F2EF)과 제목 글자색만 한 단 낮추기. 그러면 그 카드의 배지는 다른 컬럼과 같은 5.39 가 된다. Opacity(0.3)(드래그 중 원본, :1065)은 일시적 상태라 그대로 둔다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 3/5 — 질문 5 중앙화 설계와 위험 · 한계.

5. 중앙화 설계와 위험

바뀌는 파일

A. 토큰과 배지 규칙 (시각 변화 있음)

파일 무엇 예상 줄
lib/theme.dart muted·mutedBg 추가, subtle 값 변경, tint()·onTint()·forKindInk() 추가, faint 주석에 "글자 금지" 명시 +45
lib/widgets/status_badge.dart StatusBadge·KindBadge·UnconfirmedBadge 를 공통 _Pill(padding·radius·크기 한 벌) 위에 다시 세운다. 클래스 이름 셋은 그대로 둔다 ±60
lib/screens/calendar_screen.dart _LabelBar 를 tint/onTint 로 (:853·:869) ±10
lib/screens/table_screen.dart 칸반 Opacity 제거(:1052), Done 컬럼 하드코딩 hex → 토큰(:940), 필터 칩 알파 통일(:264·:310·:327) ±20
lib/screens/structure_screen.dart 감지 칩 규칙을 포착 화면과 일치시키고 #EAF7EF → tint(ok), "태스크로" 칩 알파 통일 (:334·:343·:410) ±15
lib/widgets/capture_composer.dart 감지 칩을 같은 규칙으로 (:424·:443) ±8
lib/widgets/record_editor_sheet.dart _ExternalBadge·표 이름 알약을 같은 _Pill 로 (:855·:1174) ±20
test/contrast_test.dart (새 파일) 토큰 짝의 대비를 코드로 못 박는다 — 이 프로젝트가 l10n_test.dart 의 길이 예산으로 하는 것과 같은 방식 +70

합계 약 250 줄, 8 개 파일.

B. faint → muted 일괄 치환 (기계적)

AppColors.faint 47 곳 중 글자에 쓰인 29 곳만 muted 로 바꾼다. 파일은 capture_screen(4)·graph_screen(3)·table_screen(7)·schema_screen(5)·calendar_screen(4)·structure_screen(6)·record_editor_sheet(7)·field_editors(4)·data_card(2)·status_badge(2)·new_record_sheet(1)·name_edit_sheet(1)·language_card(1). 남는 18 곳(아이콘·선·_EdgePainter 선색·플레이스홀더)은 손대지 않는다. 하드코딩 hex 두 곳(schema_screen.dart:409·:429, graph_screen.dart:439)도 여기서 토큰으로 바꾼다.

한 줄 치환 약 32 곳, 13 개 파일, 약 80 줄.

시각 변화가 생기는 화면

전부다 — 다만 방향이 하나다(회색이 진해지고, 틴트 위 글자가 어두워진다).

  • 구조화 탭 — 가장 크게 바뀐다. 카드 머리·"감지된 것 없음"·타입 필드 이름·구역 설명이 #B4B4BE → #6B6B76. 감지 칩의 확정 색이 초록에서 포착 화면과 같은 규칙으로 바뀐다(뜻이 뒤집혀 있던 것을 고치는 것이라 의도적인 재학습이 필요하다).
  • 캘린더 2b — 라벨 바 글자가 종류색에서 그 색의 잉크로. 바 바탕이 불투명해져 선택된 날 셀 위에서도 같은 색이다.
  • 표 카드·칸반 — 칸반 Done 카드가 흐릿하지 않고 또렷해진다(가장 눈에 띄는 변화). 종류·상태 배지 글자가 어두워진다.
  • 6a 스키마 · 5b 그래프 — 보조 글자가 진해진다. (그래프 노드 바탕까지 바꿀지는 결정 사항)
  • 4b 시트 · 포착 화면 — 보조 글자만 진해진다.

Maestro 흐름에 미치는 영향

색만 바꾸면 영향 없다. ui/flows/*.yaml 은 보이는 글자·tooltip·Semantics(identifier:) 로만 요소를 집는다.

구조를 바꾸면 깨진다. 13-unconfirmed.yaml 은 접근성 노드 안의 글자 차례에 의존한다 — :45 (?s).*All day.*장보기.*Unconfirmed.*, :64 (?s)#[0-9]+.*Unconfirmed.*장보기.*, :82 (?s).*Just captured.*장보기.*Unconfirmed.*, :104 (?s).*All day.*견적 회의 1시간반.*Unconfirmed.*1 h 30 min.*. 따라서 배지를 한 벌로 모을 때 지켜야 할 선은 셋이다.

  1. 배지는 Container + Text 하나 그대로 — Semantics·Tooltip·ExcludeSemantics·MergeSemantics 를 새로 두르지 않는다(Issue docs: restructure firstmate documentation #82 가 같은 함정을 이미 기록했다: ChoiceChip 바깥의 Semantics 가 노드를 둘로 갈랐다).
  2. 배지가 카드 안에서 그려지는 차례를 바꾸지 않는다.
  3. UnconfirmedBadge·KindBadge·StatusBadge 세 클래스 이름은 유지한다 — test/capture_visibility_test.dart 가 find.byType 으로 잡는다.

그 밖의 위험

  • test/db_open_failure_test.dart:106 이 label.style?.color == AppColors.danger 를 못 박는다. DB 오류 배너를 onTint(danger) 로 바꾸면 이 테스트가 깨진다(4.36:1 이라 바꿀 이유는 있다) — 바꾼다면 테스트도 같이 고친다.
  • test/l10n_test.dart:99 의 unconfirmedBadge 12 열 예산은 그대로다. 배지 padding 을 늘리면 실제 폭만 늘고 이 테스트는 못 잡는다 — padding 은 지금 값(dense 6·1)을 유지하기를 권고한다.
  • theme.dart 는 models.dart 를 import 하고 있어(RecordKind) 토큰을 늘려도 의존 방향은 그대로다. AppColors 는 abstract final class 라 인스턴스화 위험도 없다.
  • 다크 모드는 범위 밖이지만, 여기서 만드는 tint/onTint 짝은 나중에 다크 값을 옆에 붙이기 좋은 모양이다. 지금 알파로 두면 그때 다시 같은 계산을 해야 한다.

작업을 하나로 할지 둘로 할지 — 둘로 나누기를 권고

  • 작업 1(먼저): 위 A. 규칙을 세우는 일이다. 시각 변화가 크고 화면별 눈 확인이 필요하며, test/contrast_test.dart 가 이 PR 의 계약이 된다. Issue fix(bin): correct no-mistakes brief contract #73 이 물은 것의 답이 여기 다 들어 있다.
  • 작업 2(뒤에): 위 B. faint → muted 기계적 치환. 리뷰가 "훑어보기"라 A 와 섞으면 A 의 규칙 논의가 32 줄의 치환에 묻힌다. A 가 muted 를 정의한 뒤라야 시작할 수 있다.

한 PR 로 묶으면 330 줄에 14 개 파일이 되고, 되돌릴 일이 생겼을 때 "규칙"과 "청소"를 갈라 되돌릴 수 없다.

한계

  • 기기에서 보지 않았다. 계산은 sRGB 값이고, 실제 iPhone 화면은 True Tone·밝기·주변광에 따라 체감이 달라진다. 특히 "얇은 획이 더 빨리 사라진다"는 3번의 설명은 대비 수치가 아니라 렌더링 특성의 문제라 수치로 증명하지 않았다.
  • WCAG 2.x 로만 쟀다. APCA(WCAG 3 초안)는 밝은 바탕의 회색 글자를 더 엄하게 본다. 지금 통과로 나온 4.54.7 구간(미확정 배지 4.70, 2b 바 4.57)은 APCA 로는 미달일 수 있다 — 제안 팔레트는 그 구간을 5.35.4 로 올려 여유를 둔다.
  • 모든 조합을 세지 않았다. 39 개는 배지·칩·라벨 바·보조 텍스트의 대표 조합이고, Theme.of(context) 가 정하는 자리(버튼·다이얼로그·TextField 힌트·NavigationBar)는 M3 기본값을 신뢰해 표본만 확인했다(칩 여섯 조합, 7.2~8.4:1).
  • 줄 수 추정은 읽어서 센 것이지 실제로 고쳐 본 것이 아니다. status_badge.dart 를 공통 _Pill 로 다시 세우는 부분(±60)이 가장 불확실하다.
  • 대비 계산 스크립트는 브랜치에 올리지 않고 이 문서 부록과 Issue 댓글에 그대로 실었다 — 이 작업의 실행 규칙이 원격 push 를 금지한다. 브랜치가 필요하면 대장이 지시해 주면 된다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 4/5 — 대장 결정 필요. 구현 작업을 열기 전에 셋을 골라 주면 된다. 백로그에는 alpha-73-theme-tokens 한 건으로 잡혀 있다.

대장 결정 필요

결정 1 — subtle 값을 바꿀 것인가.

  • (A) 권고: subtle 을 #6B6B76 → #5C5C68 로 어둡게 하고, 비워진 #6B6B76 을 muted 라는 새 이름으로 쓴다. 이유: 미확정 배지 글자가 배지 바탕 위에서 4.31 → 5.39 가 되어 여유가 생기고, 토큰 값이 하나도 버려지지 않는다.
  • (B) subtle 을 그대로 두고 muted 를 #63636E 같은 새 값으로 넣는다. 이유: 지금 subtle 인 자리(구역 머리글·아젠다 날짜 등)의 색이 안 바뀌어 변화 폭이 작다. 대신 subtle(5.26)과 muted(5.93)의 밝기 차가 뒤집혀 이름이 헷갈린다.

결정 2 — 그래프 노드(graph_screen.dart:666)를 이 작업에 넣을 것인가.

  • (A) 권고: 넣지 않는다. 노드는 배지가 아니고 Issue Issue fix(bin): correct no-mistakes brief contract #73 의 범위 밖이며, 노드 바탕색을 바꾸면 5b 지도의 인상이 크게 달라진다. 세 노드가 2.77~4.06 이라는 사실만 별도 Issue 로 남긴다.
  • (B) 같이 넣는다. onTint(c) 를 노드 바탕으로 쓰면 한 줄이고 흰 글자가 3.41 → 5.61 이 된다.

결정 3 — 구조화 감지 칩의 확정 색.

  • (A) 권고: 포착 화면에 맞춘다(확정 = onTint(accent)/tint(accent), 미확정 = muted/bg). 이유: 두 화면이 같은 뜻에 같은 색을 쓰게 되고, 초록은 상태 Done 이 이미 쓰고 있어 뜻이 겹친다.
  • (B) 구조화에 맞춘다(확정 = 초록). 이유: 구조화 탭에서는 "체크됨"이 초록이라는 것이 직관적이다. 대신 포착 화면 칩도 함께 바꿔야 하고 Done 과 색이 겹친다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

방법

코드 읽기와 계산만 했다. 시뮬레이터·기기 실행 없음, 스크린샷 열지 않음.

색 값은 lib/theme.dart 와 화면에 남은 하드코딩 hex 에서 그대로 읽었고, 대비는 WCAG 2.x 공식(상대 휘도 → (L1+0.05)/(L2+0.05))으로 계산했다. 알파 겹침은 Flutter 의 Color.withValues(alpha:) 와 같게 sRGB 8bit 에서 out = a*fg + (1-a)*bg 로 합성했다.

Theme.of(context) 가 정하는 값(칩 라벨색 등)은 코드에 없으므로 flutter test 로 buildTheme().colorScheme 을 한 번 찍어 실측했다(Flutter 3.47.2, 2026-09-06) — onSurfaceVariant #47464F, surfaceContainerLow #F6F2FA. 그 프로브 테스트 파일은 지웠고 워크트리에 남긴 변경은 없다.

전체 스크립트와 실행 출력은 이 문서 맨 아래 부록에 있다.

1. 현황 목록 — 색과 글자 크기가 어디서 오는가

값의 출처는 넷이다: ① 테마 토큰(AppColors.*), ② Theme.of(context)(M3 기본값, 코드에 값 없음), ③ 화면 로컬 상수(그 파일에서만 정한 알파·크기), ④ 하드코딩 hex.

배지 모양의 위젯 여섯 벌

위젯 파일:줄 바탕 글자색 크기·굵기 padding / radius 출처
StatusBadge lib/widgets/status_badge.dart:16 forStatus(s) @0.12 forStatus(s) 12 / dense 11 · w700 10·4 / dense 8·2 / r20 ① + ③(알파·크기)
KindBadge lib/widgets/status_badge.dart:47 forKind(k) @0.12 forKind(k) 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
UnconfirmedBadge lib/widgets/status_badge.dart:160 faint @0.18 subtle 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
2b 라벨 바 _LabelBar lib/screens/calendar_screen.dart:853 forKind(k, confirmed) @0.16 확정 = 종류색 · 미확정 = subtle 10 · w700 4·0, height 18 / r4 ① + ③
표 이름 알약 _tableSection lib/widgets/record_editor_sheet.dart:855 accentFaint(불투명) accent 12 · w700 10·4 / r20 ①
_ExternalBadge lib/widgets/record_editor_sheet.dart:1174 accentFaint + line 테두리 accent 11 · w400 10·6 / r8 ①

반경이 4·6·8·20 넷, 알파가 0.12·0.16·0.18·불투명 넷, 글자 10~12px 셋이다. 같은 "알약"인데 공유하는 상수가 하나도 없다.

칩

자리 파일:줄 켜짐 꺼짐 크기 출처
포

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 �

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 **배지 자체가 여섯

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 �

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

방법

코드 읽기와 계산만 했다. 시뮬레이터·기기 실행 없음, 스크린샷 열지 않음.

색 값은 lib/theme.dart 와 화면에 남은 하드코딩 hex 에서 그대로 읽었고, 대비는 WCAG 2.x 공식(상대 휘도 → (L1+0.05)/(L2+0.05))으로 계산했다. 알파 겹침은 Flutter 의 Color.withValues(alpha:) 와 같게 sRGB 8bit 에서 out = a*fg + (1-a)*bg 로 합성했다.

Theme.of(context) 가 정하는 값(칩 라벨색 등)은 코드에 없으므로 flutter test 로 buildTheme().colorScheme 을 한 번 찍어 실측했다(Flutter 3.47.2, 2026-09-06) — onSurfaceVariant #47464F, surfaceContainerLow #F6F2FA. 그 프로브 테스트 파일은 지웠고 워크트리에 남긴 변경은 없다.

전체 스크립트와 실행 출력은 이 문서 맨 아래 부록에 있다.

1. 현황 목록 — 색과 글자 크기가 어디서 오는가

값의 출처는 넷이다: ① 테마 토큰(AppColors.*), ② Theme.of(context)(M3 기본값, 코드에 값 없음), ③ 화면 로컬 상수(그 파일에서만 정한 알파·크기), ④ 하드코딩 hex.

배지 모양의 위젯 여섯 벌

위젯 파일:줄 바탕 글자색 크기·굵기 padding / radius 출처
StatusBadge lib/widgets/status_badge.dart:16 forStatus(s) @0.12 forStatus(s) 12 / dense 11 · w700 10·4 / dense 8·2 / r20 ① + ③(알파·크기)
KindBadge lib/widgets/status_badge.dart:47 forKind(k) @0.12 forKind(k) 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
UnconfirmedBadge lib/widgets/status_badge.dart:160 faint @0.18 subtle 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
2b 라벨 바 _LabelBar lib/screens/calendar_screen.dart:853 forKind(k, confirmed) @0.16 확정 = 종류색 · 미확정 = subtle 10 · w700 4·0, height 18 / r4 ① + ③
표 이름 알약 _tableSection lib/widgets/record_editor_sheet.dart:855 accentFaint(불투명) accent 12 · w700 10·4 / r20 ①
_ExternalBadge lib/widgets/record_editor_sheet.dart:1174 accentFaint + line 테두리 accent 11 · w400 10·6 / r8 ①

반경이 4·6·8·20 넷, 알파가 0.12·0.16·0.18·불투명 넷, 글자 10~12px 셋이다. 같은 "알약"인데 공유하는 상수가 하나도 없다.

칩

자리 파일:줄 켜짐 꺼짐 크기 출처
포착 화면 감지 칩 lib/widgets/capture_composer.dart:424 accent / accentFaint subtle / bg 14(기본) w600 ①
구조화 감지 칩 lib/screens/structure_screen.dart:334 ok / #EAF7EF accent / accentFaint 13 w600 ① + ④
구조화 "태스크로" lib/screens/structure_screen.dart:376 forKind(task) / 그 색 @0.12 accent / bg 13 w600 ① + ③
표 종류 필터 ChoiceChip lib/screens/table_screen.dart:262 라벨색 없음 → onSurfaceVariant / forKind(k) @0.16 〃 / surfaceContainerLow 12 ② + ① + ③
표 마일스톤·프로젝트 필터 lib/screens/table_screen.dart:309·327 〃 @0.16 〃 12 ② + ① + ③
상태 필터 lib/screens/table_screen.dart:355 〃 / accentFaint 〃 12 ② + ①

상태 표시·비활성 표시

자리 파일:줄 값 출처
상태 색 규칙 lib/theme.dart:24 done→ok · in_progress→warn · 그 외 accent ① (한 곳, 좋다)
종류 색 규칙 lib/theme.dart:34 종류별 hex 4 개 + confirmed:false → faint ① (한 곳, 좋다)
칸반 컬럼 바탕(Done) lib/screens/table_screen.dart:940 #F2F2EF ④
칸반 카드 흐리기(Done) lib/screens/table_screen.dart:1052 Opacity(0.65) — 카드 전체 ③
칸반 드래그 중 원본 lib/screens/table_screen.dart:1065 Opacity(0.3) ③
후보 타일 비선택 아이콘 lib/widgets/record_editor_sheet.dart:1035 faint ①
기한 지남 OverdueMark lib/screens/table_screen.dart:397 danger, 11px w700 ① (한 곳, 좋다)
저장 표시 lib/screens/capture_screen.dart:227 idle faint · saving subtle · saved ok · failed danger ①
삭제 lib/widgets/record_editor_sheet.dart:397·412 danger 글자·아이콘만. 삭제된 행을 표시하는 배지는 없다 — 삭제 표시(deleted_at)된 행은 조회에서 아예 빠진다 ①

하드코딩 hex 다섯 곳

파일:줄 값 비고
lib/screens/schema_screen.dart:409 #6B6B76 AppColors.subtle 과 같은 값을 다시 적었다
lib/screens/schema_screen.dart:429 #3B82C4 forKind(task) 와 같은 값을 다시 적었다
lib/screens/graph_screen.dart:439 #3B82C4 〃 (같은 값이 세 곳)
lib/screens/structure_screen.dart:343 #EAF7EF 초록 틴트. 토큰 없음
lib/screens/table_screen.dart:940 #F2F2EF 칸반 Done 바탕. 토큰 없음

글자 크기

크기는 전부 위젯 안의 리터럴이다 — theme.dart 에는 appBarTheme.titleTextStyle(20) 과 navigationBarTheme.labelTextStyle(11) 둘뿐이고 textTheme 은 손대지 않는다. 앱 전체에서 fontSize: 리터럴이 9·10·11·12·13·14·15·16·18·20 열 종류로 흩어져 있다.

2. 규칙 일치 여부

미확정은 규칙이 하나다 — 잘 되어 있다. 판정의 원본이 레코드 필드 하나(AppState.isCaptureConfirmed)이고, 캘린더 아젠다(calendar_screen.dart:601)·구조화 카드(structure_screen.dart:269)·표 카드(table_screen.dart:535)·표 셀(:662)·칸반 카드(:1030)·포착 화면 최근 줄(capture_screen.dart:323)이 모두 같은 UnconfirmedBadge 를 쓴다. 배지를 못 놓는 2b 라벨 바만 색으로 말한다(calendar_screen.dart:853).

확정은 규칙이 둘이고, 서로 뜻이 뒤집혀 있다. 포착 화면의 감지 칩은 확정 이 accent 글자 + accentFaint 바탕이고(capture_composer.dart:424), 구조화 탭의 감지 칩은 똑같은 accent/accentFaint 가 미확정이며 확정은 초록(ok/#EAF7EF)이다(structure_screen.dart:334). 같은 픽셀이 한 화면에서는 "확정", 다른 화면에서는 "아직 아님"을 뜻한다.

체크 아이콘도 갈린다: 꺼진 상태가 포착 화면은 add_circle_outline, 구조화는 radio_button_unchecked 다. 켜진 상태만 둘 다 check_circle 이다.

종류 배지는 색 규칙은 하나(forKind)인데 그 색을 쓰는 방식이 화면마다 다르다. 배지·6a 카드 머리는 @0.12(status_badge.dart:54, schema_screen.dart:516), 2b 라벨 바와 표 필터 칩은 @0.16(calendar_screen.dart:869, table_screen.dart:264), 칸반 드롭 하이라이트와 4b 링크 칩은 @0.1(table_screen.dart:939, record_editor_sheet.dart:995), 6a 점선 테두리는 @0.5(schema_screen.dart:502). 여섯 자리에 네 알파다.

삭제 표시는 규칙이랄 것이 없다. 삭제된 행은 화면에서 사라지므로 표시가 필요 없고, 삭제 동작 만 danger 로 통일돼 있다(record_editor_sheet.dart:397·412, name_edit_sheet.dart:133·167, data_card.dart:146). 여기는 손댈 것이 없다.

비활성은 규칙이 없다. 칸반 Done 은 Opacity(0.65) 로 카드 전체를 흐리고(table_screen.dart:1052), 4b 후보 타일은 faint 아이콘으로(record_editor_sheet.dart:1035), 2b 미확정 바는 forKind(confirmed:false) 로, 저장 표시 idle 은 faint 로 말한다. 넷 다 "덜 중요함"인데 네 가지 길이다.

한 가지 반전이 눈에 띈다. Theme.of(context) 에 맡긴 자리(ChoiceChip 라벨)는 대비가 7.2~8.4:1 로 전부 넉넉하고, AppColors 에서 손으로 고른 자리가 무너진다. M3 는 틴트 바탕 위에 어두운 중립색(onSurfaceVariant #47464F)을 얹는데, 이 앱은 틴트와 같은 색조를 얹기 때문이다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

방법

코드 읽기와 계산만 했다. 시뮬레이터·기기 실행 없음, 스크린샷 열지 않음.

색 값은 lib/theme.dart 와 화면에 남은 하드코딩 hex 에서 그대로 읽었고, 대비는 WCAG 2.x 공식(상대 휘도 → (L1+0.05)/(L2+0.05))으로 계산했다. 알파 겹침은 Flutter 의 Color.withValues(alpha:) 와 같게 sRGB 8bit 에서 out = a*fg + (1-a)*bg 로 합성했다.

Theme.of(context) 가 정하는 값(칩 라벨색 등)은 코드에 없으므로 flutter test 로 buildTheme().colorScheme 을 한 번 찍어 실측했다(Flutter 3.47.2, 2026-09-06) — onSurfaceVariant #47464F, surfaceContainerLow #F6F2FA. 그 프로브 테스트 파일은 지웠고 워크트리에 남긴 변경은 없다.

전체 스크립트와 실행 출력은 이 문서 맨 아래 부록에 있다.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

방법

코드 읽기와 계산만 했다. 시뮬레이터·기기 실행 없음, 스크린샷 열지 않음.

색 값은 lib/theme.dart 와 화면에 남은 하드코딩 hex 에서 그대로 읽었고, 대비는 WCAG 2.x 공식(상대 휘도 → (L1+0.05)/(L2+0.05))으로 계산했다. 알파 겹침은 Flutter 의 Color.withValues(alpha:) 와 같게 sRGB 8bit 에서 out = a*fg + (1-a)*bg 로 합성했다.

Theme.of(context) 가 정하는 값(칩 라벨색 등)은 코드에 없으므로 flutter test 로 buildTheme().colorScheme 을 한 번 찍어 실측했다(Flutter 3.47.2, 2026-09-06) — onSurfaceVariant #47464F, surfaceContainerLow #F6F2FA. 그 프로브 테스트 파일은 지웠고 워크트리에 남긴 변경은 없다.

전체 스크립트와 실행 출력은 이 문서 맨 아래 부록에 있다.

1. 현황 목록 — 색과 글자 크기가 어디서 오는가

값의 출처는 넷이다: ① 테마 토큰(AppColors.*), ② Theme.of(context)(M3 기본값, 코드에 값 없음), ③ 화면 로컬 상수(그 파일에서만 정한 알파·크기), ④ 하드코딩 hex.

배지 모양의 위젯 여섯 벌

위젯 파일:줄 바탕 글자색 크기·굵기 padding / radius 출처
StatusBadge lib/widgets/status_badge.dart:16 forStatus(s) @0.12 forStatus(s) 12 / dense 11 · w700 10·4 / dense 8·2 / r20 ① + ③(알파·크기)
KindBadge lib/widgets/status_badge.dart:47 forKind(k) @0.12 forKind(k) 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

밝은 화면에서 39 개 조합을 WCAG 로 계산해 보니 25 개가 4.5:1 에 못 미친다. 미확정 배지 자체는 4.70:1 로 이미 통과하고 2b 라벨 바도 PR #72 뒤 4.57:1 인데, 대장이 본 "구조화 탭 미확정 카드"는 배지를 뺀 카드의 나머지 글자가 전부 faint(1.97~2.06:1) 여서 카드 전체가 안 읽힌다 — 배지의 문제가 아니라 AppColors.faint 를 글자에 쓴 47 곳 중 29 곳의 문제다.

권고는 새 디자인 시스템이 아니라 기존 토큰의 확장 세 줄기다: (1) faint 를 글자에서 빼고 그 자리에 muted #6B6B76 를 새로 둔다, (2) 배지 바탕을 알파 대신 불투명 tint(color) 로 미리 계산하고 그 위에 얹을 onTint(color) 잉크를 짝으로 둔다, (3) 여섯 벌의 배지를 status_badge.dart 의 한 위젯으로 모은다. 구현은 둘로 나누기를 권고한다 — 규칙을 세우는 작업(약 120 줄, 시각 변화 있음)과 faint → muted 일괄 치환(12 개 파일, 약 80 줄).

방법

코드 읽기와 계산만 했다. 시뮬레이터·기기 실행 없음, 스크린샷 열지 않음.

색 값은 lib/theme.dart 와 화면에 남은 하드코딩 hex 에서 그대로 읽었고, 대비는 WCAG 2.x 공식(상대 휘도 → (L1+0.05)/(L2+0.05))으로 계산했다. 알파 겹침은 Flutter 의 Color.withValues(alpha:) 와 같게 sRGB 8bit 에서 out = a*fg + (1-a)*bg 로 합성했다.

Theme.of(context) 가 정하는 값(칩 라벨색 등)은 코드에 없으므로 flutter test 로 buildTheme().colorScheme 을 한 번 찍어 실측했다(Flutter 3.47.2, 2026-09-06) — onSurfaceVariant #47464F, surfaceContainerLow #F6F2FA. 그 프로브 테스트 파일은 지웠고 워크트리에 남긴 변경은 없다.

전체 스크립트와 실행 출력은 이 문서 맨 아래 부록에 있다.

1. 현황 목록 — 색과 글자 크기가 어디서 오는가

값의 출처는 넷이다: ① 테마 토큰(AppColors.*), ② Theme.of(context)(M3 기본값, 코드에 값 없음), ③ 화면 로컬 상수(그 파일에서만 정한 알파·크기), ④ 하드코딩 hex.

배지 모양의 위젯 여섯 벌

위젯 파일:줄 바탕 글자색 크기·굵기 padding / radius 출처
StatusBadge lib/widgets/status_badge.dart:16 forStatus(s) @0.12 forStatus(s) 12 / dense 11 · w700 10·4 / dense 8·2 / r20 ① + ③(알파·크기)
KindBadge lib/widgets/status_badge.dart:47 forKind(k) @0.12 forKind(k) 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
UnconfirmedBadge lib/widgets/status_badge.dart:160 faint @0.18 subtle 11 / dense 10 · w700 8·3 / dense 6·1 / r6 ① + ③
2b 라벨 바 _LabelBar lib/screens/calendar_screen.dart:853 forKind(k, confirmed) @0.16 확정 = 종류색 · 미확정 = subtle 10 · w700 4·0, height 18 / r4 ① + ③
표 이름 알약 _tableSection lib/widgets/record_editor_sheet.dart:855 accentFaint(불투명) accent 12 · w700 10·4 / r20 ①
_ExternalBadge lib/widgets/record_editor_sheet.dart:1174 accentFaint + line 테두리 accent 11 · w400 10·6 / r8 ①

반경이 4·6·8·20 넷, 알파가 0.12·0.16·0.18·불투명 넷, 글자 10~12px 셋이다. 같은 "알약"인데 공유하는 상수가 하나도 없다.

칩

| 자리 | 파일:줄 | 켜짐 | 꺼짐 | 크기 | 출처 |

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

1 similar comment
@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

1 similar comment
@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

@gyute

gyute commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

— fm

Issue #73 조사 보고서 1/5 — 결론 · 방법 · 질문 1 현황 목록 · 질문 2 규칙 일치 여부.

색은 이미 거의 다 AppColors 에서 오지만 배지 자체가 여섯 벌로 따로 만들어져 있고, 배지의 바탕이 불투명한 값이 아니라 알파(0.1·0.12·0.16·0.18·0.5 다섯 가지)라서 같은 배지가 놓인 자리마다 다른 색이 된다.

@spirispark

Copy link
Copy Markdown

Thanks - both focus areas checked against the actual tree at the final head 0564469; no code change is needed. Evidence below.

Inconsistent Version Counts - recomputed from the pinned list itself. nix/chrome-devtools-axi.nix has 97 dep rows, and 94 distinct tarballs (name+version) among them: [email protected] is the only tarball appearing in more than one row (the 4 nested rows), so 97 - 3 = 94. The package tarball itself is not one of the 97 - [email protected] is the derivation's own src - which is why the header reads "the single npm tarball plus the 97 per-dep tarball rows below". The closure is therefore 1 + 94 = 95 distinct tarballs. The 94 that is also countable on disk is a different quantity: 94 top-level directories under node_modules = 93 dep dirs + the package dir itself (lavish-axi likewise: 90 rows, 91 top-level dirs).

Recursive Test Traversal - the walk cannot loop or duplicate. It recurses only into entries where fs.readdirSync(dir, {withFileTypes: true}) reports entry.isDirectory() === true, and for a symlink Node reports isDirectory() false, isSymbolicLink() true, so a symlinked package dir is skipped rather than followed. Verified on a tree that deliberately contains a symlinked package dir: the walk completes with exit 0, reporting no duplicate and no cycle. In this repo's install path there are no symlinks to skip anyway - the Nix install extracts npm tarballs with tar, producing real directories. Measured on the built store paths: 0 symlinks in both trees (573 dirs for chrome-devtools-axi with 5 content-type dirs, 305 dirs for lavish-axi with 1). The recursion is deliberate: the flat-shape assertion exists to catch a stray nested content-type copy anywhere in the tree, so checking only the known package paths would weaken the exact property the test was written to enforce.

Review coverage - the files outside this review's token budget were verified separately against upstream: treehouse 3.1.7 and Pi Launcher 1.2.18 hashes match the releases' own checksums.txt / .sha256 sidecars; the four npm src.hash values match npm view <pkg> dist.integrity; the kunchenguid/kun rev 37364f0b matches the built fetchFromGitHub NAR hash; backpass 0.1.41's DEFAULT_LADDERS are byte-identical to 0.1.32's, so the ladders in nix/user.nix are unchanged. The repo's behaviour tests (tests/kunchenguid_tools_test.sh, tests/backpass_nix_test.sh, tests/opencode_skills_test.sh) plus scripts/verify.sh pass at the final head, and CI on this PR is green.

fritznoff pushed a commit to fritznoff/starship that referenced this pull request Nov 2, 2026
* Verify the agent is up before a spawn reports success

fm-spawn submitted the launch and never asked whether an agent
appeared, so a launch that died in the pane's shell still reported
"spawned". The brief - inline on the launch line for every verified
adapter except kimi - became shell continuation input, no agent read
it, and the pane still looked alive, so a later steer "succeeded" into
that same shell.

After the launch is submitted, fm-spawn now waits on a hard bound for a
real agent to own the endpoint, reading the shared liveness owner
(fm_backend_agent_state) rather than a spawn-local sleep. kimi, whose
brief is typed into the pane after launch, demands positive proof
before typing: a bare shell, a gone endpoint, or an unreadable pane
refuses without delivering the brief. Every other adapter refuses only
on a proven agent-less endpoint, so backends and harnesses whose
liveness cannot be read behave exactly as before.

A refusal tears nothing down and prints the recovery: interrupt twice,
then send a one-line relaunch rendered from this task's own launch
template that points at the brief file instead of pasting it. One
renderer produces both the real launch and that recovery command, so
they cannot drift.

The bound defaults to 60 polls x 1s, matching the worktree settle
bound, and is named in every refusal.

Also fixes a herdr presentation fixture whose agent-get response was
missing a closing brace and had never parsed.

* Declare the spawn agent-up verification capability

The fork-surface gate refuses an owned path that no capability claims,
so the new spawn agent-up regression test needs its own declaration
rather than being folded into the worktree settle capability it sits
next to.

* no-mistakes(review): fix(bin): correct spawn agent-up refusal shapes and knob timing

* no-mistakes(review): fix(bin): render runnable re-spawn recovery and sync spawn help

* no-mistakes(document): docs: correct spawn agent-up refusal rules in owners

* test(lib): drop agent-up pacing for the suite

The agent-up wait paces its polls for production, where a spawn already
costs a minute of worktree settle and one second is nothing. The suite
pays that cost per spawn instead: a fake tmux or herdr returns a
liveness answer the shared owner cannot attribute, so the two-read
confirmation sleeps once on every fixture spawn.

Measured at ~21s on tests/fm-spawn-dispatch-profile.test.sh alone
(68s -> 47s). Multiplied across the files that drive a real spawn, that
is what pushed the portable-serial CI lane past its 20 minute hang
tripwire against a ~13 minute baseline, so the lane was cancelled at the
cap rather than failing an assertion.

Set the knob once in the suite's shared library, alongside the
gate-refuse and sentinel exports that exist for the same reason, rather
than in each of the ~38 files that drive a spawn. Production pacing is
untouched, the polling logic and poll counts are unchanged, and the
agent-up suite still sets its own bound explicitly.

* no-mistakes(document): Raise portable serial CI tripwire

* fix(ci): restore portable contracts

* fix(ci): raise the portable serial hang tripwire to 30m

The serial lane's cap was a tripwire set against a "~13 min wall" claim
that had gone stale. Measured on Ubuntu without the agent-up spawn
change: 19m10s on main at 98111e7 and 17m46s on
fm/fm-chart-room-build-b4, already 89-96 percent of the 20m cap. That is
a pre-existing capacity problem, exposed rather than introduced by the
one ~27s test file this branch adds.

At a 20m cap the lane was then cancelled at exactly 20m00s, so its true
wall is above 20m but unmeasured: the job was killed, not timed. The cap
has to clear an unknown tail rather than a measured one, so 30m covers
the 19m10s baseline, this change, the ~8 percent spread between the two
samples, and that unmeasured overshoot.

25m is deliberately not used. tests/fm-test-run.test.sh guards against
the retired interim full-suite timeout of exactly that value, so raising
the cap to 25 fails a different invariant.

The same test pins the serial tripwire by value, so that assertion moves
with the cap rather than being worked around by reverting the cap, which
would only restore the failure. The anti-25 guard is left untouched.

A full re-shard, which would cut this lane rather than widen its
tripwire, is tracked as its own task.

* no-mistakes(review): Warn on unverified spawn brief delivery

* no-mistakes(document): Update portable serial timeout documentation
@ChaO-0

ChaO-0 commented Nov 12, 2026

Copy link
Copy Markdown

Widget resize: proof on 45894be

Local stack as before: watchdog-api develop on a scratch database, Calibrain develop (371450b) on :4433 and this branch on :4430, same 3-page report of 18 GA4 line charts with fake GA4 data.

Typecheck and lint

$ pnpm typecheck
✓ Types generated successfully          (tsc --noEmit: exit 0)
$ pnpm lint
✖ 7 problems (0 errors, 7 warnings)    (same warnings as develop)

Resize: select a line chart, drag its east handle 160 px left, read the saved report back (harness/resize-check.mjs)

develop  handle {"width":0,"height":0}             widget width before 377 during 377
         FAIL resize east handle autosaved {"h":4,"w":6,"x":0,"y":2}
branch   handle {"width":28.3,"height":28.3}       widget width before 377 during 217
         PASS resize east handle autosaved {"h":4,"w":4,"x":0,"y":2}

In the video run, the branch then dragged the corner handle out and autosave stored {"w":6,"h":6}. On develop the same gesture moved the widget instead (saved x:2).

Drag frame rate is unchanged from 42fb933 (headed Chrome, device pixel ratio 2, GPU on, 120 Hz, continuous 3 s drag, medians of 3; harness/trace.mjs app=calfix reps=3)

42fb933 45894be
Dragged widget position updates per second 115.1 114.4
Frames drawn per second 115.3 119.7
Main thread busy 23% 31%

Builder still works (harness/check.mjs): props edit shows on the canvas and autosaves, undo and redo, move drag autosaves, drawer drop adds a widget and autosaves, undo removes it. All PASS.

The drop placeholder now uses react-grid-layout's default tint (light red), the same as the WatchDog dashboard.

Resize videos (before and after) follow.

fritznoff pushed a commit to fritznoff/starship that referenced this pull request Nov 18, 2026
…lds this code does not know (kunchenguid#73)

* fix(bin): keep a call's title on its own when a saved reading has fields this code does not know

A strip still running older code read a reading saved by newer code, and the
title, the last field it knew, took in the newer fields after it, tab and all,
so the next-call line showed the title run together with the calls signal.
Saved readings, the calls entry and the strip's own reading are now read with
one name past the known fields, so a field a newer writer adds is dropped.

* no-mistakes(review): Test the saved reading's extra field, drop strip's
@mamane19

Copy link
Copy Markdown

Shipped in e9f283d: a parked machine says when it last moved ("Parked since 18:40 yesterday", "Not moved yet today"), true at any hour. Proof: ios-final/ios-en-light-a01-today.png in the 1.0.4 review set.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants