KQ-551 · DIFF/LINES

Diff Lines

An inline word diff you can read and apply in place. Removed words fade to a ghost while a strike draws through each one with pathLength on flick, added words wipe in from the left on a clip tween under a success wash that cools over a second, and accepting a hunk drops its ghost on the exit ease while the measured passage glides to its new height. Each accept is a real toggle button, so Tab reaches it and Enter or Space applies the change or puts it back; arrows move between the change and result stops.

KQ-551 · DIFF/LINES
Release note2/2

Waylight 2.4 adds an offline queue that retries failed uploads everyfewminutes onashortbackoff and logseachattempt. recordstheoutcome.

2 of 2 changes left to review

2 of 2 changes to review

Install

One command — the source lands in your repo. Or copy it from the Code tab.

$ pnpm dlx shadcn@latest add @kinetiq/diff-lines

Props

before
string
default
The original text; the diff is computed by word.
after
string
default
The edited text; the diff is computed by word.
view / defaultView
"change" | "result"
default "change"
Whether the passage shows the change or the result.
onViewChange
(view: "change" | "result") => void
default
Fires when the view switch moves.
onAccept
(index: number) => void
default
Fires when a hunk is accepted.
onAcceptedChange
(indexes: number[]) => void
default
Fires whenever the accepted set changes, restores included.
label
string
default "Suggested edit"
Visible label above the passage.