Skip to content

feat(home): Hero 캐러셀 자동회전 정지/제어 (WCAG 2.2.2) (#848)#916

Merged
thxforall merged 1 commit into
devfrom
feat/848-hero-pause
Jul 11, 2026
Merged

feat(home): Hero 캐러셀 자동회전 정지/제어 (WCAG 2.2.2) (#848)#916
thxforall merged 1 commit into
devfrom
feat/848-hero-pause

Conversation

@thxforall

Copy link
Copy Markdown
Contributor

배경

HeroCarouselsetInterval(5000)로 무한 자동회전하며 정지/제어 수단이 전무 → WCAG 2.2.2 (Pause, Stop, Hide) 위반.

구현 (이 PR = #848의 (c) Hero-pause만)

  • paused/interacting(hover·focus) 상태 + isRotating = n>1 && !paused && !interacting.
  • 가시적 pause/play 토글 버튼(lucide, aria-label swap — W3C APG rotation-control 패턴).
  • prefers-reduced-motion 존중: 초기 정지 + 라이브 matchMedia change 리스너(세션 중 OS 설정 플립 반영).
  • hydration 안전: useState(false) 초기화 후 mount effect에서 matchMedia 반영(SSR/client 일치).
  • 단일 슬라이드 시 토글 미렌더.

스코프 (중요)

이 PR은 #848(c) Hero-pause만 구현. (a)홈 개인화 피드 · (b)섹션 타이틀 정직화 · (d)홈 Suspense 스트리밍은 app/[locale]/(shell)/page.tsx가 열린 draft PR #872(#840)와 충돌 → #840 머지 후 후속 슬라이스. → #848 이슈는 이 PR로 완전 close하지 않음(부분).

검증

  • typecheck 0 · eslint clean · vitest 8/8(pause 6 + locale 2) · i18n parity 7/7
  • en/ko.json = Hero 네임스페이스 키만 추가(격리, ko/en parity).
  • 독립 2축 리뷰: Standards가 hydration mismatch regression(reduced-motion 유저 타겟) 발견 → 수정·재검증 완료. aria-pressed 이중 semantics → APG label-swap alone으로 정리.

Refs #848


2축 독립 리뷰 완료(작성/리뷰 분리).

🤖 Generated with Claude Code

HeroDecodeBand의 HeroCarousel이 5초 간격으로 무한 자동회전하지만
사용자가 멈출 방법이 없었다(WCAG 2.2.2 Pause, Stop, Hide 위반).

- 도트 옆에 보이는 pause/play 토글 버튼 추가 (aria-label + aria-pressed)
- prefers-reduced-motion: reduce 시 기본 정지 + 런타임 변경 리스닝
- 포커스/호버 시(focus-within, hover) 자동회전 일시정지
- 회전 로직은 그대로(5s interval), 정지 조건만 추가

이 커밋은 #848 중 Hero-pause만; 개인화 피드·타이틀·streaming은
별도(#840 머지 후).

리뷰 반영: hydration 안전 초기화(paused 초기값 false + 마운트 후
matchMedia 반영) + APG aria(aria-pressed 제거, aria-label swap만 유지)

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@thxforall thxforall added the bump:patch Bug fixes / internal refactor label Jul 11, 2026
@vercel

vercel Bot commented Jul 11, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
decoded-app Ready Ready Preview, Comment Jul 11, 2026 1:04pm

@thxforall thxforall moved this from Todo to In Progress in decoded-monorepo Jul 11, 2026
@thxforall thxforall merged commit ffba352 into dev Jul 11, 2026
11 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in decoded-monorepo Jul 11, 2026
github-actions Bot pushed a commit that referenced this pull request Jul 11, 2026
@thxforall thxforall deleted the feat/848-hero-pause branch July 11, 2026 13:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bump:patch Bug fixes / internal refactor

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant