Fix a bug that hid the accept/reject buttons for insertions in the unified merge view.
The lines shown around collapsed unchanged lines are now css :before
/:after
elements, so that they can be customized more easily.
Render deleted lines in the unified merge view as block elements, for easier styling.
In the unified diff view, fix an issue where empty deleted lines were rendered for chunks that deleted nothing.
Fix a bug that made the diff algorithm miss some obvious opportunities to align changes on line boundaries.
Fix an issue where the last line of a deleted chunk, if there is no text on it, was collapsed by the browser and not visible.
Fix a bug in presentableDiff
that could cause it to produce corrupted diffs.
Improve the way presentableDiff
aligns changes to line boundaries when possible.
unifiedMergeView
now supports the collapseUnchanged
option the way the split view does.
Fix a bug in the way spacers were inserted at the top of the viewport.
Improve vertical alignment of huge unchanged chunks in the side-by-side view.
Fix an issue that would corrupt the text displayed for some deleted lines in the unified merge view.
Fix syntax and change highlighting in deleted lines in the unified merge view.
Fix originalDocChangeEffect
to apply the changes to the appropriate document.
Restore the default scan limit when diffing for chunks, which looks like it was accidentally dropped when it was made configurable in 6.3.0.
Fix a bug that could cause the set of changed chunks to be updated incorrectly on some types of changes.
Fix a bug where big deletions could corrupt the merge state.
The state effect used to change the original document in a unified merge view is now available to client code as updateOriginalDoc
.
The new changeOriginalDocEffect
function can be used to update the reference document in a unified merge editor.
The getOriginalDoc
function extracts the original document from a unified merge editor.
Add a userEvent
annotation to transactions that accept a change in the unified merge view.
Fix CSS selectors in the merge view base theme to avoid affecting the style of non-merge view editors.
Merge views (and Chunk
building methods) now take an optional diff config object to allow precision to be configured.
The package now exports goToNextChunk
and goToPreviousChunk
commands that allow by-changed-chunk document navigation.
Create alignment spacers for the whole document, not just the viewport, to avoid scroll position popping and misalignment.
Fall back to treating entire documents as changed when they are too large to compute a diff in a reasonable timeframe.
Fix a crash when unifiedMergeView
is added to an existing state by reconfiguration.
Add <ins>
/<del>
tags around inserted and deleted lines to give screen readers a chance to communicate their role.
The new unifiedMergeView
extension can be used to display a diff inside a single editor, by inserting deleted content as widgets in the document.
Fix a bug that could cause diff
to loop endlessly when the input contains astral characters in specific positions.
Fix a bug that would cause diffing to loop infinitely with some inputs.
Improve performance of the merge view when the inputs are almost entirely different.
diff
and presentableDiff
now take an optional scanLimit
option that can be used to trade speed for accuracy on very different inputs.
Fix a bug where changed chunks could be found in equal documents.
Chunk
now exposes static methods for building an updating sets of chunks directly.
Fix a bug that caused an extra stray newline to be inserted when pressing the merge button for a change at the end of the document.
Avoid generating incorrect chunks for insertions or deletions at the end of the document.
It is now possible to change the configuration of a merge view with its reconfigure
method.
The Chunk
data structure, and the set of chunks kept by the merge view, are now part of the public interface.
The new orientation
option makes it possible to show editor B first.
Color changed chunks in editor A red by default.
First numbered release.