@evoke-platform/ui-components 1.10.0-dev.35 → 1.10.0-dev.37
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.
|
@@ -8,7 +8,7 @@ import { Body } from './components/Body';
|
|
|
8
8
|
import { Footer, FooterActions } from './components/Footer';
|
|
9
9
|
import { FormContext } from './components/FormContext';
|
|
10
10
|
import Header, { AccordionActions, Title } from './components/Header';
|
|
11
|
-
import { assignIdsToSectionsAndRichText, convertDocToParameters, convertPropertiesToParams, entryIsVisible, getEntryId, getNestedParameterIds, isAddressProperty, } from './components/utils';
|
|
11
|
+
import { assignIdsToSectionsAndRichText, convertDocToParameters, convertPropertiesToParams, entryIsVisible, getEntryId, getNestedParameterIds, isAddressProperty, obfuscateValue, } from './components/utils';
|
|
12
12
|
import { handleValidation } from './components/ValidationFiles/Validation';
|
|
13
13
|
import ValidationErrors from './components/ValidationFiles/ValidationErrors';
|
|
14
14
|
const FormRendererInternal = (props) => {
|
|
@@ -79,6 +79,15 @@ const FormRendererInternal = (props) => {
|
|
|
79
79
|
if (value) {
|
|
80
80
|
for (const key of Object.keys(currentValues)) {
|
|
81
81
|
if (!isEqual(currentValues[key], value[key])) {
|
|
82
|
+
// For protected properties, don't validate initial obfuscated value
|
|
83
|
+
const property = object?.properties?.find((prop) => prop.id === key);
|
|
84
|
+
const isProtectedProperty = property?.protection?.maskChar;
|
|
85
|
+
if (isProtectedProperty) {
|
|
86
|
+
if (value[key] === obfuscateValue(value[key], property)) {
|
|
87
|
+
setValue(key, value[key], { shouldValidate: false });
|
|
88
|
+
continue;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
82
91
|
setValue(key, value[key], { shouldValidate: true });
|
|
83
92
|
}
|
|
84
93
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@evoke-platform/ui-components",
|
|
3
|
-
"version": "1.10.0-dev.
|
|
3
|
+
"version": "1.10.0-dev.37",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/published/index.js",
|
|
6
6
|
"module": "dist/published/index.js",
|
|
@@ -96,7 +96,7 @@
|
|
|
96
96
|
"yalc": "^1.0.0-pre.53"
|
|
97
97
|
},
|
|
98
98
|
"peerDependencies": {
|
|
99
|
-
"@evoke-platform/context": "^1.5.0
|
|
99
|
+
"@evoke-platform/context": "^1.5.0",
|
|
100
100
|
"react": "^18.1.0",
|
|
101
101
|
"react-dom": "^18.1.0"
|
|
102
102
|
},
|