@abgov/jsonforms-components 2.32.2 → 2.32.3
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.
- package/index.esm.js +38 -34
- package/package.json +1 -1
package/index.esm.js
CHANGED
|
@@ -6943,6 +6943,7 @@ const GoAEmailInput = props => {
|
|
|
6943
6943
|
config,
|
|
6944
6944
|
id,
|
|
6945
6945
|
enabled,
|
|
6946
|
+
visible,
|
|
6946
6947
|
uischema,
|
|
6947
6948
|
errors,
|
|
6948
6949
|
schema,
|
|
@@ -6959,41 +6960,44 @@ const GoAEmailInput = props => {
|
|
|
6959
6960
|
const splintIndex = splitErrors.findIndex(e => e === 'is a required property');
|
|
6960
6961
|
splitErrors[splintIndex] = `${primaryLabel} is required`;
|
|
6961
6962
|
const finalErrors = splitErrors.join('\n');
|
|
6962
|
-
return jsx(
|
|
6963
|
-
|
|
6964
|
-
|
|
6965
|
-
|
|
6966
|
-
|
|
6967
|
-
|
|
6968
|
-
|
|
6969
|
-
|
|
6970
|
-
|
|
6971
|
-
|
|
6972
|
-
|
|
6973
|
-
|
|
6974
|
-
|
|
6975
|
-
|
|
6976
|
-
|
|
6977
|
-
|
|
6978
|
-
|
|
6979
|
-
|
|
6980
|
-
|
|
6981
|
-
|
|
6982
|
-
|
|
6983
|
-
|
|
6984
|
-
|
|
6985
|
-
|
|
6986
|
-
|
|
6987
|
-
|
|
6988
|
-
|
|
6989
|
-
|
|
6963
|
+
return jsx(Visible, {
|
|
6964
|
+
visible: visible,
|
|
6965
|
+
children: jsx(FormFieldWrapper, {
|
|
6966
|
+
children: jsx(GoAFormItem, {
|
|
6967
|
+
error: isVisited && finalErrors,
|
|
6968
|
+
testId: "form-email-input-wrapper",
|
|
6969
|
+
requirement: required ? 'required' : undefined,
|
|
6970
|
+
label: primaryLabel,
|
|
6971
|
+
children: jsx(GoAInput, {
|
|
6972
|
+
error: isVisited && finalErrors.length > 0,
|
|
6973
|
+
type: 'email',
|
|
6974
|
+
width: width,
|
|
6975
|
+
name: "Email address",
|
|
6976
|
+
value: data,
|
|
6977
|
+
testId: (appliedUiSchemaOptions === null || appliedUiSchemaOptions === void 0 ? void 0 : appliedUiSchemaOptions.testId) || `${id}-input`,
|
|
6978
|
+
disabled: !enabled,
|
|
6979
|
+
readonly: readOnly,
|
|
6980
|
+
onChange: (name, value) => {
|
|
6981
|
+
if (!isVisited) {
|
|
6982
|
+
setIsVisited(true);
|
|
6983
|
+
}
|
|
6984
|
+
onChangeForInputControl({
|
|
6985
|
+
name,
|
|
6986
|
+
value,
|
|
6987
|
+
controlProps: props
|
|
6988
|
+
});
|
|
6989
|
+
},
|
|
6990
|
+
onBlur: (name, value) => {
|
|
6991
|
+
if (!isVisited) {
|
|
6992
|
+
setIsVisited(true);
|
|
6993
|
+
}
|
|
6994
|
+
onBlurForTextControl({
|
|
6995
|
+
name,
|
|
6996
|
+
value,
|
|
6997
|
+
controlProps: props
|
|
6998
|
+
});
|
|
6990
6999
|
}
|
|
6991
|
-
|
|
6992
|
-
name,
|
|
6993
|
-
value,
|
|
6994
|
-
controlProps: props
|
|
6995
|
-
});
|
|
6996
|
-
}
|
|
7000
|
+
})
|
|
6997
7001
|
})
|
|
6998
7002
|
})
|
|
6999
7003
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abgov/jsonforms-components",
|
|
3
|
-
"version": "2.32.
|
|
3
|
+
"version": "2.32.3",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"description": "Government of Alberta - React renderers for JSON Forms based on the design system.",
|
|
6
6
|
"repository": "https://github.com/GovAlta/adsp-monorepo",
|