I accept, then make a small manual edit (e.g. relabelling, changing an icon, tweaking a class)
I continue prompting Cursor to modify the component
But 3 will often immediately suggest reverting the change I make in 2, which is highly frustrating. My current workaround is to make a new chat after 2, so that 3 has my change in context and does not try to change it.
Is there a better way to do this? Could Cursor become aware of my change (e.g. update its context version of a file if I save it)?
Why don’t you add it in the context of the last step? In the first step you added the original file before any modifications. The context doesn’t know your extra changes, it will see the Agent’s changes only and expect to rewrite the file appending that version with new text and overwrite it.
Another option that works less and less lately is to prompt the Agent to provide DIFF only, no context. That is, ask it to give back only line changes with number and sign, no context lines before or after. This way, only changed lines are returned, not the whole file.