Skip to content

Challenges: agent window sequence and Revenue AI tab progress follow the prototype #319

Open

Description

@wab

Parent

#212 (PRD: website redesign v2, delivery steps J1 to J6)

Context

Each challenge page has an AI bridge section with an agent window (app/components/challenges/agent-window.tsx). The Revenue AI day scenes reuse it. In the prototype (pw-* classes in every enjeux-*.html page of the prototype repo), the window plays a short sequence when it enters the viewport. In production it shows its final state at once.

Prototype sequence, once the window is in view:

  1. Three typing dots bounce (hwDot, 1s loop, staggered by 0.15s), then hide after 0.9s (hwHide).
  2. The message lines fade and slide up into place (pw-s: opacity and 5px translate, 0.4s).
  3. Score bars fill from the left (iw-bar2, pw-score: scaleX 0 to 1).
  4. Hovering the window lifts it by 4px with a deeper shadow.

What to build

  • Play this sequence once when the window enters the viewport, with useInView from J2: reveal and scroll progress hooks that respect reduced motion #226 (J2: reveal and scroll progress hooks that respect reduced motion).
  • On the Revenue AI day (challenge-ai-day.tsx), each tab change replays the sequence for the new scene. Each tab also shows the progress bar of the prototype (dyProg: fills over the tab duration).
  • Reduced motion: final state at once, no typing dots, no progress fill.
  • Server-rendered HTML keeps the full text, so the content does not depend on JavaScript.

Acceptance criteria

  • On the six challenge pages, the agent window plays the sequence once in view. Checked against the prototype on the Vercel preview.
  • On Revenue AI, each tab replays the sequence and shows its progress bar.
  • With reduced motion on, the window shows its final state and nothing moves.
  • The full text is in the server-rendered HTML.
  • pnpm typecheck, pnpm check and pnpm test:run pass.

Blocked by

None. Can start now.

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

    enhancementNew feature or requestready-for-agentFully specified, AFK-ready for an agent

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions