walkthrough
Back to blog

What to capture before rebuilding a dropdown

Capture opening, closing and keyboard behaviour before handing a dropdown reference to Claude Code or Codex.

By 2 min read

Three illustrative menu states: closed, opening, open. A screenshot covers only the last state.
Three illustrative menu states: closed, opening, open. A screenshot covers only the last state.

The menu looks right. Same colour. Same corners. Then you click it, and something feels off.

Maybe it opens too fast. Maybe the panel starts in the wrong place. Or the button loses focus when you close it.

This is the awkward part of using a screenshot as a reference. It shows one result. It does not show the steps that made that result.

One frame, many questions

Look at the drawing above. It is an example, not a measurement from a customer site. The open menu could appear instantly, slide down, or fade in. All three versions could end on the same screenshot.

A video adds the order of events and visible movement. That helps a lot. But watching a video is not the same as reading the animation settings from the browser.

What each reference can tell you
ReferenceUseful forStill missing
ScreenshotLayout, colour, visible stateTiming and the path to that state
VideoVisible motion and action orderExact CSS values and hidden rules
Recorded DOM + motionCaptured structure, styles and timing dataOriginal handlers and unvisited behaviour
Source + running appImplementation and live checksYou still need to test the paths that matter

Read what the browser knows

The browser has APIs for this. getAnimations() returns animations affecting an element. getKeyframes() can return their computed keyframes. These are more useful than asking a model to guess a duration from a still image.

There is a catch. Not everything on a page is an inspectable CSS animation. A canvas drawing is different. So is a frame from another origin. A tool needs to say what it missed.

Record the return trip

If you want to reuse a menu, do more than open it once:

  1. Open it with the mouse.
  2. Close it with Escape.
  3. Open it again and click outside.
  4. Try the keyboard path you expect your own app to support.

This gives the agent evidence for more than the pretty part. If you did not record a keyboard path, write it down as a requirement. Do not pretend the recording proved it.

Where Walkthrough fits

Walkthrough lets you replay a recording, select an element, and export the available structure, style and motion evidence. Your agent can use that reference while working in your own app.

It does not recover the site's original React component. It cannot promise every hidden state. Even Figma's capture FAQ says captured code may not fully reproduce the original interactions.

Export the selected evidence with your target component and the changes you want. Ask your agent to adapt it to your app, then test opening, closing and focus return.

Try this on one menu

Keep your screenshot. Add the opening and closing flow. Ask the agent to list what it knows, what it inferred, and what it still needs to test. Compare the result with your old screenshot-only workflow.

We have not published a controlled speed or accuracy benchmark for this yet. That comparison is a useful test, not a promised improvement.

Sources

  1. MDN: Element.getAnimations()developer.mozilla.org
  2. MDN: KeyframeEffect.getKeyframes()developer.mozilla.org
  3. Figma Chrome extension: capture limitsfigma.com

Reference links for this article.

Bring one interaction to your app.

Choose a menu or dialog you want to adapt. Capture it in Walkthrough, export the selected evidence to your coding agent, and check the result in your own app.

Open Walkthrough