Skip to content

feat: add accessible Storybook UX contracts - #246

Open
seonghobae wants to merge 728 commits into
mainfrom
feat/storybook-ux-contracts
Open

feat: add accessible Storybook UX contracts#246
seonghobae wants to merge 728 commits into
mainfrom
feat/storybook-ux-contracts

Conversation

@seonghobae

@seonghobae seonghobae commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

Purpose

Deliver the accessible Storybook/desktop UX contract while keeping provider, cleanup, release, scan-navigation, and destructive authority in their canonical owners.

Exact current state

  • base: protected main@79067c1160ddedf7fc962cbf8067ce7e83c4564a
  • exact source head: 1a8ca96116f34720501a0f6c94e29dd48af2741d
  • open, Draft, mergeable
  • current delta: 38 files after owner-boundary cleanup; pending/queued/in-progress checks are non-passing

Ownership convergence in this head

A stale 58-file branch had accumulated release-verifier, release-version/provenance, canonical product-baseline, provider/cloud, TopFiles, and scan-page changes owned by other DiskSage lanes. The branch was converged non-destructively against current main and those foreign-to-this-PR deltas were restored to protected-main truth. In particular:

The remaining source is the Storybook/design-token/accessibility shell, preferred initial scan-root UX, focused customer-copy/error-feedback contracts, and the supporting provider-status presentation helpers.

Current product repair

A current review finding showed Duplicates.svelte rendering raw per-item backend errors ({r.error}) directly in customer markup. The repair was test-first:

  1. strengthen cleanupCustomerCopyContract.test.ts so Inventory/Duplicates may not render raw caught or per-item errors;
  2. replace the raw duplicate-item error with bounded actionable customer copy while retaining the affected path.

The finding remains unresolved until the unchanged exact head obtains current hosted GREEN evidence.

UX / authority boundary

  • Storybook/provider-status surfaces do not grant provider-write, source-eviction, release, or filesystem-mutation authority;
  • the exported list_roots Tauri command keeps its external name while the UX preference lives in preferred_scan_roots;
  • default non-Windows ordering prefers Downloads, then HOME, then /, avoiding accidental whole-filesystem-first scanning without removing explicit root access;
  • accessibility, dark-mode, viewport-isolation, bounded customer-copy, and Svelte 5 layout contracts remain in this owner.

Required before integration

Do not merge until this exact unchanged head has terminal-success applicable Test/Release/Security/SAST/accessibility and central required workflows, zero valid unresolved findings, the live review/ruleset requirements are satisfied, and repository-wide exact production coverage/package/SBOM/provenance requirements remain intact. Predecessor, pending, skipped-required, failed, stale, synthetic, status-only, or model-only evidence is non-passing.

Summary by CodeRabbit

  • 새 기능

    • Storybook 기반 UI 미리보기와 접근성·상호작용 검증 환경을 추가했습니다.
    • 데스크톱·모바일 화면 크기와 다크 모드를 지원하는 디자인 토큰을 적용했습니다.
    • 공급자 동기화 상태, 진행 상황, 취소 가능 여부를 보여주는 상태 카드를 추가했습니다.
    • 초기 스캔 시 운영체제별 권장 경로를 우선 제안합니다.
  • 개선 사항

    • 오류 메시지를 내부 정보 대신 이해하기 쉬운 한국어 안내와 재시도 방법으로 표시합니다.
    • 정리·복구 화면에서 민감한 경로와 구현 세부정보 노출을 줄였습니다.
    • 키보드 건너뛰기 링크와 향상된 포커스·대비 표시를 지원합니다.
  • 문서

    • 접근 가능한 Storybook UX 기준과 이벤트 검토 지침을 추가했습니다.

@coderabbitai

coderabbitai Bot commented Aug 21, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

Next included review available in 1 minute.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: de29454e-eaad-4e8f-a032-b8363549046c

📥 Commits

Reviewing files that changed from the base of the PR and between fbe72f6 and 6571447.

📒 Files selected for processing (7)
  • docs/design/storybook-event-inventory.md
  • src/lib/cleanupCustomerCopyContract.test.ts
  • src/lib/ui/design-tokens.css
  • src/lib/ux/ProviderStatusCard.stories.ts
  • src/lib/ux/ProviderStatusCard.svelte
  • src/lib/uxContract.test.ts
  • src/routes/+page.svelte
📝 Walkthrough

Walkthrough

Storybook 접근성 설정과 Provider 상태 카드가 추가되었습니다. 디자인 토큰과 전역 접근성 스타일을 도입했습니다. 고객용 화면은 내부 오류와 구현 세부정보를 숨기도록 갱신했습니다. iCloud stall clock과 선호 스캔 루트를 추가했습니다.

Changes

UX 및 플랫폼 변경

Layer / File(s) Summary
Provider 상태와 iCloud stall clock
src/lib/icloudHealthStallClock.ts, src/lib/icloudHealthStallClock.test.ts
admission, 전송 진행률, 인덱싱 backlog, persisted blocker age를 사용해 stall clock을 계산하고 테스트합니다.
ProviderStatusCard 계약과 상태 스토리
src/lib/ux/ProviderStatusCard.svelte, src/lib/ux/ProviderStatusCard.stories.ts
상태별 라벨, 메타데이터, 접근성 제목, 조건부 취소 버튼과 Storybook 상호작용 스토리를 추가합니다.
디자인 토큰과 접근성 Svelte 셸
src/lib/ui/design-tokens.css, src/routes/+layout.svelte, src/app.html, src/lib/*Contract.test.ts
디자인 토큰, 다크 모드, skip-link, 포커스, reduced-motion, forced-colors 규칙과 전역 레이아웃을 추가합니다.
Storybook 실행과 Chromium 검증
.storybook/*, .github/workflows/storybook-accessibility.yml, package.json, docs/design/storybook-event-inventory.md, docs/architecture/adr/*
Storybook 설정, viewport 테스트 러너, npm 명령, 정적 빌드, Chromium 검증 워크플로와 관련 문서를 추가합니다.
선호 스캔 루트 등록
src-tauri/src/commands.rs, src-tauri/src/lib.rs, src-tauri/src/preferred_scan_roots.rs
기존 list_roots 구현을 선호 스캔 루트 모듈로 교체하고 플랫폼별 루트 순서를 검증합니다.
고객용 오류 문구와 상태 표시
src/lib/*.svelte, src/lib/cloudArchiveErrorFeedback.ts, src/lib/*Privacy.test.ts, src/lib/*SafetyUiContract.test.ts
내부 오류 문자열, fingerprint, provider 세부정보와 구현 용어를 제거하고 사용자용 안내와 테마 토큰을 적용합니다.

Estimated code review effort: 4 (Complex) | ~45 minutes

Merge Risk: 🟡 Moderate · up to fbe72

The PR currently has a compile-time contract error in iCloud stall handling and presents an incomplete description of the files Homebrew cleanup may remove. Merge should wait until the type/fallback behavior and cleanup-scope wording are corrected.

Sequence Diagram(s)

sequenceDiagram
  participant GitHubActions
  participant Storybook
  participant Chromium
  participant TestRunner
  participant ProviderStatusCard

  GitHubActions->>Storybook: 정적 빌드와 로컬 서버 시작
  Chromium->>Storybook: 스토리 페이지 로드
  TestRunner->>Chromium: 스토리 전역 viewport 적용
  Chromium->>ProviderStatusCard: 상태 카드 렌더링
  ProviderStatusCard-->>TestRunner: 접근성 및 취소 동작 결과 반환
Loading
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 14.29% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 21 functions across 28 files. (12 skipped… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed 제목은 접근 가능한 Storybook UX 계약 추가라는 PR의 주요 변경 사항을 정확하고 간결하게 요약합니다.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 14.29% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 21 functions across 28 files. (12 skipped: 12 unsupported.)

✨ Finishing Touches 💡 2
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/storybook-ux-contracts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

* feat: add ontology-bound orphan cache cleanup

* docs: bind orphan baseline to live provider evidence

* test: cover orphan cache and support roots

* docs: record orphan rust test evidence

* test: reject orphan object identity replacements

* docs: bind orphan identity test evidence

* docs: record repeated provider stall evidence

* docs: bind baseline to latest orphan head

* fix: fail closed on deep app inventory scans

* fix: propagate incomplete orphan scan evidence

* docs: bind orphan scan safety to current head

* test: pin orphan cleanup authority and privacy regressions

* fix: align orphan cleanup UI with fail-closed authority

* fix: harden orphan planning authority and privacy

* test: bind orphan cleanup regressions to repaired boundaries

* test: prevent orphan plan fingerprints from encoding HOME

* test: cover general reverse-DNS orphan bundle identities

* fix: remove HOME-derived orphan authority metadata

* test: require HOME-free orphan wire contract

* fix: align orphan API with path-free runtime contract

* test: require orphan batch preflight before mutation

* fix: preflight orphan cleanup batches before mutation

* fix: avoid recursive read directory binding

* docs: refresh orphan current-head evidence

* docs: distinguish orphan implementation head

* test: separate orphan cleanup success from refresh failure

* fix: preserve orphan cleanup success across refresh failure

* fix: distinguish orphan cleanup from refresh failure

* test: bind orphan refresh outcome to UI contract

* docs: refresh orphan frontend test evidence

* docs: record orphan refresh authority boundary

* docs: record live iCloud transfer evidence

* docs: track orphan safety follow-ups

* docs: bind orphan audit to merged base head

* docs: record orphan audit documentation head

* docs: label orphan evidence snapshot

* fix: harden orphan evidence and goal commands

* fix: harden installed app inventory evidence

* fix: fail closed on recursive lsof diagnostics

* test: require orphan cleanup component-owned styles

* fix: scope orphan cleanup presentation styles

* test: decouple orphan bundle fixture from host Spotlight completeness

* test: distinguish benign lsof warnings from target traversal failures

* fix: classify benign lsof warning continuations

* test: remove host-dependent Spotlight assertion

* fix: bound orphan probes and revalidate metadata

* docs: record orphan deadline and manifest revalidation

* fix: terminate launch services descendants on timeout

* docs: record launch services timeout isolation

* docs: record exact-head stacked PR audit

* docs: bind orphan audit to pushed head

* docs: label orphan implementation snapshot
devin-ai-integration[bot]

This comment was marked as resolved.

@seonghobae
seonghobae force-pushed the feat/storybook-ux-contracts branch from 41fa888 to eb89d67 Compare August 21, 2026 09:19
devin-ai-integration[bot]

This comment was marked as resolved.

devin-ai-integration[bot]

This comment was marked as resolved.

devin-ai-integration[bot]

This comment was marked as resolved.

@seonghobae
seonghobae marked this pull request as draft August 27, 2026 10:14
@seonghobae
seonghobae marked this pull request as ready for review August 28, 2026 09:19

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note

This report is out of date. Scroll down for Devin Review's latest report on this PR.

Devin Review found 2 new potential issues.

Devin Review

Comment thread src/routes/+layout.svelte
Comment thread src/lib/icloudHealthStallClock.ts Outdated
return [admissionFingerprint(report), progressFingerprint(report)].join("|");
}

export function updateIcloudHealthStallClock(

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔍 Stall-clock module wired only to its test

updateIcloudHealthStallClock and its fingerprint helper are imported only by the test file; no component uses them. The logic ships as dead code. Confirm whether integration was intended here or deferred.

Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed against the fresh branch: this module was no longer integrated by any production component after CloudArchive/provider ownership had already converged out of #246; it was imported only by its own test and did not exist on protected main. The root-cause repair is ownership convergence, not another provider workaround in the Storybook UX owner: icloudHealthStallClock.test.ts and icloudHealthStallClock.ts were removed from this branch in 3f4f878fc9dcbcbed8d2559e0ee8e26861937a5c and e1856c096c033d5afa492d9d367d6b09ca4fdbab. Exact-head checks are queued, so the thread stays unresolved pending terminal verification.

coderabbitai[bot]

This comment was marked as resolved.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note

This report is out of date. Scroll down for Devin Review's latest report on this PR.

Devin Review found 1 new potential issue.

Devin Review

Comment thread src/lib/Cleanup.svelte
Comment on lines +30 to +34
function podmanActionLabel(action: { kind: string }): string {
return action.kind === "dangling-image"
? "재생성 가능한 미사용 이미지 정리"
: "Podman 저장 공간 확인";
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Podman recommended actions all show one generic label

podmanActionLabel compares the action kind to "dangling-image", but the backend never emits that value; its kinds serialize as snake_case like review_unused_images. The first branch is dead, so every recommended action renders the same generic "Podman 저장 공간 확인" label instead of describing what it recommends.

Prompt for agents
In src/lib/Cleanup.svelte, podmanActionLabel checks action.kind === "dangling-image", but the recommended-action kind values coming from the Rust backend (PodmanRecommendedActionKind in src-tauri/src/podman_reclaim.rs, serialized snake_case) are review_unused_images, review_unused_volumes, restore_guest_headroom, investigate_api, review_guest_trim, and review_stopped_containers. Because none of these equals "dangling-image", the first branch is unreachable and every recommended action gets the generic fallback label. Map each real kind string to appropriate customer-facing copy (the "재생성 가능한 미사용 이미지 정리" label likely belongs to review_unused_images), so the displayed label matches the actual recommendation.
Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

Devin Review

}: Props = $props();

const stateLabel: Record<ProviderStatusState, string> = {
clear: "지금 복사 가능",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Clear status overstates copy readiness

When provider observation is clear, stateLabel declares copying possible now despite the required per-file review. Users can proceed before the remaining safety decision.

Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@seonghobae seonghobae added the enhancement New feature or request label Sep 7, 2026 — with ChatGPT Codex Connector
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: api API, protocol, event, or external contract area: ui-ux Frontend, interaction, design, or user experience enhancement New feature or request priority: medium Normal-priority or P2 work status: mergeable GitHub reports a mechanically clean merge state; policy gates may remain type: feature New or expanded product capability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants