@dative-gpi/foundation-shared-components 1.0.139-reportV1 → 1.0.139-richtextfield
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -501,11 +501,11 @@ export default defineComponent({
|
|
|
501
501
|
return;
|
|
502
502
|
}
|
|
503
503
|
const editorModelValue = JSON.stringify(editorState.toJSON());
|
|
504
|
-
if(editorModelValue === emptyLexicalState) {
|
|
504
|
+
if(editorModelValue === emptyLexicalState && props.modelValue !== null) {
|
|
505
505
|
emit("update:modelValue", null);
|
|
506
506
|
return;
|
|
507
507
|
}
|
|
508
|
-
if(editorModelValue !== props.modelValue) {
|
|
508
|
+
if(editorModelValue !== emptyLexicalState && editorModelValue !== props.modelValue) {
|
|
509
509
|
emit("update:modelValue", editorModelValue);
|
|
510
510
|
}
|
|
511
511
|
});
|
|
@@ -674,21 +674,16 @@ export default defineComponent({
|
|
|
674
674
|
return;
|
|
675
675
|
}
|
|
676
676
|
if (props.modelValue != null) {
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
}
|
|
686
|
-
});
|
|
687
|
-
return;
|
|
677
|
+
if (typeof props.modelValue === "string" && props.modelValue !== "") {
|
|
678
|
+
editor.setEditorState(editor.parseEditorState(props.modelValue!));
|
|
679
|
+
return;
|
|
680
|
+
}
|
|
681
|
+
if (typeof props.modelValue === "object") {
|
|
682
|
+
editor.setEditorState(editor.parseEditorState(JSON.stringify(props.modelValue)));
|
|
683
|
+
return;
|
|
684
|
+
}
|
|
688
685
|
}
|
|
689
|
-
editor.
|
|
690
|
-
editor.setEditorState(editor.parseEditorState(emptyLexicalState));
|
|
691
|
-
});
|
|
686
|
+
editor.setEditorState(editor.parseEditorState(emptyLexicalState));
|
|
692
687
|
}
|
|
693
688
|
|
|
694
689
|
watch(() => props.modelValue, () => {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dative-gpi/foundation-shared-components",
|
|
3
3
|
"sideEffects": false,
|
|
4
|
-
"version": "1.0.139-
|
|
4
|
+
"version": "1.0.139-richtextfield",
|
|
5
5
|
"description": "",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"author": "",
|
|
11
11
|
"license": "ISC",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@dative-gpi/foundation-shared-domain": "1.0.139-
|
|
14
|
-
"@dative-gpi/foundation-shared-services": "1.0.139-
|
|
13
|
+
"@dative-gpi/foundation-shared-domain": "1.0.139-richtextfield",
|
|
14
|
+
"@dative-gpi/foundation-shared-services": "1.0.139-richtextfield"
|
|
15
15
|
},
|
|
16
16
|
"peerDependencies": {
|
|
17
17
|
"@dative-gpi/bones-ui": "^1.0.0",
|
|
@@ -35,5 +35,5 @@
|
|
|
35
35
|
"sass": "1.71.1",
|
|
36
36
|
"sass-loader": "13.3.2"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "c8a5d32db0ce90ea1abf7ebbe6a5d4c4dde89f4a"
|
|
39
39
|
}
|