File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src/Component/FormField/JSONEditor Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -37,6 +37,8 @@ import _isNil from 'lodash/isNil';
3737
3838import * as monacoEditor from 'monaco-editor' ;
3939
40+ import config from 'shogunApplicationConfig' ;
41+
4042import {
4143 useTranslation
4244} from 'react-i18next' ;
@@ -85,6 +87,8 @@ export const JSONEditor: React.FC<JSONEditorProps> = ({
8587 const originalValues = useAppSelector ( state => state . originalConfigValues ) ;
8688 const originalValue = originalValues [ `${ entityType } .${ dataField } ` ] ;
8789
90+ const historyEnabled = config . entityHistory ?. enabled ;
91+
8892 const {
8993 t
9094 } = useTranslation ( ) ;
@@ -234,7 +238,7 @@ export const JSONEditor: React.FC<JSONEditorProps> = ({
234238 />
235239 </ div >
236240 {
237- isConfigEqual ? (
241+ ( isConfigEqual || ! historyEnabled ) ? (
238242 < Editor
239243 onMount = { onMount }
240244 value = { currentValue }
You can’t perform that action at this time.
0 commit comments