Command Palette

Search for a command to run...

Hectal
Phase 14: Agents in the UI
AI Frontend · Exercise 2 of 5 PreviousNext
Intermediate

Show Progress from a Data Part

The route sends a plan as a data-plan part and updates it after every step. Its data is a list of { label, done } objects. When #start is clicked, send Refund ORD-1042.

Show #progress as N of 3 done, where N is the number of plan items with done: true, using the latest data-plan part of the assistant message. When all three are done, show Finished in #status; before that, show Working.

What Check tests

  1. Before the click, #progress says 0 of 3 done
  2. After the run, #progress says 3 of 3 done
  3. #status says Finished
  4. The code reads data-plan parts

Stuck? One hint at a time

The solution unlocks after your first Check. Try first: that is where the learning happens.

Runs in your browser. Your code is saved here.

Your page

Press Run to see the page.

Console

Nothing logged yet.