Repository navigation
Tags
Tags
chore: readd early return if lines array is empty Add early return if no lines are found in the tree.
fix: keep the speculative diff baseline in sync when an update throws `currentlyHighlightedValue` is only advanced on the success path, so when speculativeHighlightUpdate() throws, the baseline keeps the pre-change text while the debounced highlight still re-renders the overlay with the new value. The baseline then no longer describes the overlay: the next edit diffs from the stale text, the result does not line up with the overlay's content, and the whole document ends up treated as "added" and replayed into the existing overlay HTML. The text is drawn twice (new value followed by the previous one) until the next debounce lands, and — since a successful patch is what advances the baseline — the state does not heal on its own. The failed patch leaves the overlay untouched and the debounced highlight is already on its way to render `value`, so sync the baseline there too.
PreviousNext