feat(merge): unify planning conflicts onto the resolver + 3-pane VM foundation
Route planning unit-merge conflicts through ConflictResolverViewModel (OpenForPlanningAsync) and delete the old ConflictResolutionViewModel dialog. Add active-file 3-pane reconstruction (MergeFile OursText/TheirsText/ResultText, ActiveFile, SelectFileCommand, active-file readout) as the VM foundation for the Rider-style editor. Seam preserved; Ui.Tests 128/128.
This commit is contained in:
@@ -75,4 +75,16 @@ public sealed class MergeFile
|
||||
/// <summary>Reassemble the file: stable text verbatim, each conflict replaced by its resolution.</summary>
|
||||
public string Compose() => string.Concat(
|
||||
Segments.Select(s => s.IsConflict ? (s.Conflict!.Resolution ?? s.Conflict.Ours) : s.StableText));
|
||||
|
||||
/// <summary>Left pane document: stable regions verbatim, conflict regions show Ours text.</summary>
|
||||
public string OursText => string.Concat(
|
||||
Segments.Select(s => s.IsConflict ? s.Conflict!.Ours : s.StableText));
|
||||
|
||||
/// <summary>Right pane document: stable regions verbatim, conflict regions show Theirs text.</summary>
|
||||
public string TheirsText => string.Concat(
|
||||
Segments.Select(s => s.IsConflict ? s.Conflict!.Theirs : s.StableText));
|
||||
|
||||
/// <summary>Middle (result) pane document: stable regions verbatim, conflict regions show Resolution if set, else Ours.</summary>
|
||||
public string ResultText => string.Concat(
|
||||
Segments.Select(s => s.IsConflict ? (s.Conflict!.Resolution ?? s.Conflict.Ours) : s.StableText));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user