Skip to lesson
Exit
Motion, Interaction & Prototyping1 / 3

1 min lesson

Inline diffs and accept/reject

For each case in "Inline diffs and accept/reject", name the signal and the response you would use.

Step 1 of 3

Inline diffs and accept/rejectmake AI edits legible and reversible

Legibility

Show exactly what changed, in place, not in a side panel the eye must reconcile

Added vs removed must be instantly scannable

Large diffs need structure: collapse, jump-to-next-hunk

Reversibility

Accept and reject at the right granularity: hunk, file, all

Reject must be one keystroke and leave zero residue

Nothing the AI does should be hard to undo

Reject deserves as much design care as accept. If dismissing an AI suggestion is slow or leaves the buffer altered, users stop trusting the feature and stop inviting the AI in at all.

Learn more

Full explanation

Tab / ghost-text prediction

Tab / ghost-text predictionlatency, dismissal and trust

Ghost text is a high-frequency interaction - it fires on nearly every keystroke - so its rules are unforgiving. It must be visually distinct from real code, it must never block typing and it must vanish the instant the user types something else.

What ghost text must get right
Distinct
Dimmed/styled so it never reads as committed code
Non-blocking
Typing always wins; the prediction never fights the cursor
Latency-tolerant
Appears when ready, never makes the user wait to type
Instant dismissal
Keep typing and it’s gone - no modal, no confirm
Calibrated
Wrong suggestions erode trust fast; restraint beats volume