@@ -162,7 +162,6 @@ export const EditorUI = (props: EditorUIProps) => {
162
162
const pendingCustomDiff = useRef ( { } )
163
163
const [ , setCurrentBreakpoints ] = useState ( { } )
164
164
const [ isSplit , setIsSplit ] = useState ( true )
165
- const [ isDiff , setIsDiff ] = useState ( props . isDiff || false )
166
165
const [ currentDiffFile , setCurrentDiffFile ] = useState ( props . currentDiffFile || '' )
167
166
const [ decoratorListCollection , setDecoratorListCollection ] = useState < Record < string , monacoTypes . editor . IEditorDecorationsCollection > > ( { } )
168
167
const [ disposedWidgets , setDisposedWidgets ] = useState < Record < string , Record < string , monacoTypes . IRange [ ] > > > ( { } )
@@ -1473,12 +1472,13 @@ export const EditorUI = (props: EditorUIProps) => {
1473
1472
onMount = { handleDiffEditorDidMount }
1474
1473
options = { { readOnly : false , renderSideBySide : isSplit } }
1475
1474
width = '100%'
1476
- height = { isDiff ? '100%' : '0%' }
1477
- className = { isDiff ? "d-block" : "d-none" }
1475
+ height = { props . isDiff ? '100%' : '0%' }
1476
+ className = { props . isDiff ? "d-block" : "d-none" }
1477
+ data-id = "diffEditor"
1478
1478
/>
1479
1479
< Editor
1480
1480
width = "100%"
1481
- height = { isDiff ? '0%' : '100%' }
1481
+ height = { props . isDiff ? '0%' : '100%' }
1482
1482
path = { props . currentFile }
1483
1483
language = { editorModelsState [ props . currentFile ] ? editorModelsState [ props . currentFile ] . language : 'text' }
1484
1484
onMount = { handleEditorDidMount }
@@ -1494,7 +1494,7 @@ export const EditorUI = (props: EditorUIProps) => {
1494
1494
}
1495
1495
} }
1496
1496
defaultValue = { defaultEditorValue }
1497
- className = { isDiff ? "d-none" : "d-block" }
1497
+ className = { props . isDiff ? "d-none" : "d-block" }
1498
1498
/>
1499
1499
{ editorModelsState [ props . currentFile ] ?. readOnly && (
1500
1500
< span className = "pl-4 h6 mb-0 w-100 alert-info position-absolute bottom-0 end-0" >
0 commit comments