How To: Replace A UI Element in Warp (Rust Codebase)
Learn how to use Warp’s AI coding features to make live code changes — in this example, replacing an icon throughout Warp’s massive Rust codebase using an agentic workflow.
Define the Task
The goal here is to replace all instances of the sparkle icon with the new agent icon, especially within the history menu.
Open your project in Warp and start by prompting the agent directly (either by typing or speaking):
Please create a new branch for me according to the format in the attached Linear URL.
I’ve attached screenshots of what the agent mode and sparkle icons look like.
I would like you to understand those icons, search for their use in the code,
and wherever we’re using sparkles, replace them with the agent mode icon.
Specifically, make sure this happens in the history menu.
Please give me a plan before making any coding changes.
Attach any relevant Linear issue links or screenshots to help the agent identify assets accurately.
Review the Plan
Warp’s agent parses your request and generates a plan for code edits. It identifies files and functions where the sparkle icon is used.
If the plan looks correct, approve it to proceed.
Follow-up prompt example:
Yes, proceed — and please rename the function from renderAISparklesIcon
to something like renderAgentModeIcon.
Warp automatically updates function names, asset references, and component usage.
Last updated
Was this helpful?