@solidxai/core-ui 0.1.12-beta.3 → 0.1.12-beta.6
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/dist/components/auth/AuthLayout.d.ts.map +1 -1
- package/dist/components/auth/AuthLayout.js +12 -5
- package/dist/components/auth/AuthLayout.js.map +1 -1
- package/dist/components/auth/AuthLayout.tsx +15 -4
- package/dist/components/auth/AuthSettingsContext.js +1 -1
- package/dist/components/auth/AuthSettingsContext.js.map +1 -1
- package/dist/components/auth/AuthSettingsContext.tsx +1 -1
- package/dist/components/core/chatter/SolidChatterHeader.d.ts.map +1 -1
- package/dist/components/core/chatter/SolidChatterHeader.js +18 -4
- package/dist/components/core/chatter/SolidChatterHeader.js.map +1 -1
- package/dist/components/core/chatter/SolidChatterHeader.tsx +17 -3
- package/dist/components/core/common/SolidGenericImport/SolidImportTransaction.d.ts.map +1 -1
- package/dist/components/core/common/SolidGenericImport/SolidImportTransaction.js +12 -2
- package/dist/components/core/common/SolidGenericImport/SolidImportTransaction.js.map +1 -1
- package/dist/components/core/common/SolidGenericImport/SolidImportTransaction.tsx +12 -1
- package/dist/components/core/extension/solid-core/metadata/MetadataExplorerFormWidget.d.ts +2 -0
- package/dist/components/core/extension/solid-core/metadata/MetadataExplorerFormWidget.d.ts.map +1 -1
- package/dist/components/core/extension/solid-core/metadata/MetadataExplorerFormWidget.js +4 -2
- package/dist/components/core/extension/solid-core/metadata/MetadataExplorerFormWidget.js.map +1 -1
- package/dist/components/core/extension/solid-core/metadata/MetadataExplorerFormWidget.tsx +11 -3
- package/dist/components/core/form/SolidFormView.js +1 -1
- package/dist/components/core/form/SolidFormView.js.map +1 -1
- package/dist/components/core/form/SolidFormView.tsx +1 -1
- package/dist/components/core/form/fields/relations/RolesGroupedByModuleWidget.d.ts.map +1 -1
- package/dist/components/core/form/fields/relations/RolesGroupedByModuleWidget.js +11 -1
- package/dist/components/core/form/fields/relations/RolesGroupedByModuleWidget.js.map +1 -1
- package/dist/components/core/form/fields/relations/RolesGroupedByModuleWidget.tsx +26 -19
- package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.d.ts.map +1 -1
- package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.js +13 -5
- package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.js.map +1 -1
- package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.tsx +16 -9
- package/dist/components/core/json/SolidJsonEditor.css +7 -0
- package/dist/components/core/list/SolidDataTable.d.ts.map +1 -1
- package/dist/components/core/list/SolidDataTable.js +2 -2
- package/dist/components/core/list/SolidDataTable.js.map +1 -1
- package/dist/components/core/list/SolidDataTable.tsx +2 -1
- package/dist/components/core/list/SolidListView.d.ts.map +1 -1
- package/dist/components/core/list/SolidListView.js +58 -58
- package/dist/components/core/list/SolidListView.js.map +1 -1
- package/dist/components/core/list/SolidListView.tsx +5 -4
- package/dist/components/core/model/FieldMetaDataForm.d.ts +1 -1
- package/dist/components/core/model/FieldMetaDataForm.d.ts.map +1 -1
- package/dist/components/core/model/FieldMetaDataForm.js +119 -102
- package/dist/components/core/model/FieldMetaDataForm.js.map +1 -1
- package/dist/components/core/model/FieldMetaDataForm.tsx +82 -39
- package/dist/components/core/model/FieldSelector.d.ts +5 -1
- package/dist/components/core/model/FieldSelector.d.ts.map +1 -1
- package/dist/components/core/model/FieldSelector.js +25 -6
- package/dist/components/core/model/FieldSelector.js.map +1 -1
- package/dist/components/core/model/FieldSelector.tsx +50 -5
- package/dist/components/core/module/CreateModule.css +60 -6
- package/dist/components/core/module/CreateModule.d.ts.map +1 -1
- package/dist/components/core/module/CreateModule.js +2 -2
- package/dist/components/core/module/CreateModule.js.map +1 -1
- package/dist/components/core/module/CreateModule.tsx +56 -37
- package/dist/components/layout/AdminTopHeader.js +1 -1
- package/dist/components/layout/AdminTopHeader.js.map +1 -1
- package/dist/components/layout/AdminTopHeader.tsx +2 -2
- package/dist/components/shad-cn-ui/SolidSelect.d.ts +2 -1
- package/dist/components/shad-cn-ui/SolidSelect.d.ts.map +1 -1
- package/dist/components/shad-cn-ui/SolidSelect.js +12 -4
- package/dist/components/shad-cn-ui/SolidSelect.js.map +1 -1
- package/dist/components/shad-cn-ui/SolidSelect.tsx +13 -1
- package/dist/helpers/modelViewPersistence.d.ts.map +1 -1
- package/dist/helpers/modelViewPersistence.js +3 -2
- package/dist/helpers/modelViewPersistence.js.map +1 -1
- package/dist/helpers/modelViewPersistence.ts +3 -2
- package/dist/redux/api/datasourceIntrospectionApi.d.ts +43 -1
- package/dist/redux/api/datasourceIntrospectionApi.d.ts.map +1 -1
- package/dist/redux/api/datasourceIntrospectionApi.js +34 -1
- package/dist/redux/api/datasourceIntrospectionApi.js.map +1 -1
- package/dist/redux/api/datasourceIntrospectionApi.ts +61 -0
- package/dist/redux/store/defaultStoreConfig.d.ts +11 -0
- package/dist/redux/store/defaultStoreConfig.d.ts.map +1 -1
- package/dist/resources/solid-custom.css +3 -86
- package/dist/resources/solid-tailwind-generated.css +1 -1
- package/dist/resources/themes/solid-dark-purple/theme-variables.css +226 -0
- package/dist/resources/themes/solid-dark-purple/theme.css +1 -185
- package/dist/resources/themes/solid-light-purple/theme-variables.css +237 -0
- package/dist/resources/themes/solid-light-purple/theme.css +1 -206
- package/dist/routes/pages/admin/core/DatasourceIntrospectionPage.css +396 -31
- package/dist/routes/pages/admin/core/DatasourceIntrospectionPage.d.ts.map +1 -1
- package/dist/routes/pages/admin/core/DatasourceIntrospectionPage.js +680 -152
- package/dist/routes/pages/admin/core/DatasourceIntrospectionPage.js.map +1 -1
- package/dist/routes/pages/admin/core/DatasourceIntrospectionPage.tsx +1358 -441
- package/package.json +1 -1
|
@@ -560,8 +560,8 @@ var createValidationSchema = function (currentFields, selectedType, allFields, f
|
|
|
560
560
|
};
|
|
561
561
|
var FieldMetaDataForm = function (_a) {
|
|
562
562
|
var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
563
|
-
var _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45, _46, _47, _48, _49, _50, _51, _52, _53, _54, _55, _56, _57, _58, _59, _60, _61, _62, _63, _64, _65, _66, _67, _68, _69, _70, _71, _72, _73, _74, _75, _76, _77, _78, _79, _80, _81, _82;
|
|
564
|
-
var setIsDirty = _a.setIsDirty, modelMetaData = _a.modelMetaData, fieldMetaData = _a.fieldMetaData, setFieldMetaData = _a.setFieldMetaData, allFields = _a.allFields, deleteModelFunction = _a.deleteModelFunction, setVisiblePopup = _a.setVisiblePopup, params = _a.params, setIsRequiredPopUp = _a.setIsRequiredPopUp, showToaster = _a.showToaster;
|
|
563
|
+
var _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45, _46, _47, _48, _49, _50, _51, _52, _53, _54, _55, _56, _57, _58, _59, _60, _61, _62, _63, _64, _65, _66, _67, _68, _69, _70, _71, _72, _73, _74, _75, _76, _77, _78, _79, _80, _81, _82, _83;
|
|
564
|
+
var setIsDirty = _a.setIsDirty, modelMetaData = _a.modelMetaData, fieldMetaData = _a.fieldMetaData, setFieldMetaData = _a.setFieldMetaData, allFields = _a.allFields, deleteModelFunction = _a.deleteModelFunction, setVisiblePopup = _a.setVisiblePopup, params = _a.params, setIsRequiredPopUp = _a.setIsRequiredPopUp, showToaster = _a.showToaster, onDraftSubmit = _a.onDraftSubmit, onClose = _a.onClose, availableFieldTypes = _a.availableFieldTypes, _84 = _a.forceShowTypeSelector, forceShowTypeSelector = _84 === void 0 ? false : _84, _85 = _a.selectorRequireContinue, selectorRequireContinue = _85 === void 0 ? false : _85, _86 = _a.selectorContinueLabel, selectorContinueLabel = _86 === void 0 ? "Next" : _86, _87 = _a.selectorInitialFieldType, selectorInitialFieldType = _87 === void 0 ? null : _87, _88 = _a.disableIdentityEditingForExisting, disableIdentityEditingForExisting = _88 === void 0 ? true : _88, _89 = _a.submitLabel, submitLabel = _89 === void 0 ? "Finish" : _89;
|
|
565
565
|
var booleanOptions = ["false", "true"];
|
|
566
566
|
var booleanSegmentedOptions = booleanOptions.map(function (value) { return ({
|
|
567
567
|
label: capitalize(value),
|
|
@@ -570,39 +570,53 @@ var FieldMetaDataForm = function (_a) {
|
|
|
570
570
|
var resolveBooleanOptionValue = function (value) {
|
|
571
571
|
return typeof value === "string" ? value : value ? "true" : "false";
|
|
572
572
|
};
|
|
573
|
-
var
|
|
574
|
-
var
|
|
573
|
+
var _90 = useState(false), isBackPopupVisible = _90[0], setIsBackPopupVisible = _90[1];
|
|
574
|
+
var _91 = useState(false), showColumnName = _91[0], setShowColumnName = _91[1];
|
|
575
575
|
var pathname = usePathname();
|
|
576
|
-
var
|
|
577
|
-
var
|
|
578
|
-
var
|
|
579
|
-
var
|
|
580
|
-
var
|
|
581
|
-
var
|
|
582
|
-
var
|
|
583
|
-
var
|
|
584
|
-
var
|
|
585
|
-
var
|
|
576
|
+
var _92 = useGetFieldDefaultMetaDataQuery(null), fieldDefaultMetaData = _92.data, isLoading = _92.isLoading, error = _92.error, refetch = _92.refetch;
|
|
577
|
+
var _93 = useState(fetchCurrentFields(fieldMetaData && fieldMetaData.type, fieldDefaultMetaData)), currentFields = _93[0], setCurrentFields = _93[1];
|
|
578
|
+
var _94 = useLazyGetMediaStorageProvidersQuery(), triggerGetMediaStorageProvider = _94[0], _95 = _94[1], MediaStorageProviderData = _95.data, isMediaStorageProviderFetching = _95.isFetching, MediaStorageProviderError = _95.error;
|
|
579
|
+
var _96 = useLazyGetmodulesQuery(), triggerGetModules = _96[0], _97 = _96[1], moduleData = _97.data, isModuleFetching = _97.isFetching, moduleError = _97.error;
|
|
580
|
+
var _98 = useLazyGetModelsQuery(), triggerGetModels = _98[0], _99 = _98[1], modelData = _99.data, ismodelFetching = _99.isFetching, modelError = _99.error;
|
|
581
|
+
var _100 = useUpdateUserKeyMutation(), updateUserKey = _100[0], _101 = _100[1], isUpdateUserKeyLoading = _101.isLoading, isUpdateUserKeySuccess = _101.isSuccess, isUpdateUserKeyError = _101.isError, UpdateUserKeyError = _101.error, newModel = _101.data;
|
|
582
|
+
var _102 = useState(), markdownText = _102[0], setMarkdownText = _102[1];
|
|
583
|
+
var _103 = useState(Boolean(fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.encrypt)), encryptState = _103[0], setEncryptState = _103[1];
|
|
584
|
+
var _104 = useState(forceShowTypeSelector || !fieldMetaData), showTypeFilter = _104[0], setShowTypeFilter = _104[1];
|
|
585
|
+
var _105 = useState((fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.type)
|
|
586
|
+
? { label: fieldMetaData.type, value: fieldMetaData.type }
|
|
587
|
+
: selectorInitialFieldType
|
|
588
|
+
? { label: selectorInitialFieldType, value: selectorInitialFieldType }
|
|
589
|
+
: null), selectedType = _105[0], setSelectedType = _105[1];
|
|
586
590
|
var selectedTypeValue = (selectedType === null || selectedType === void 0 ? void 0 : selectedType.value) || "";
|
|
587
|
-
var
|
|
588
|
-
var
|
|
591
|
+
var _106 = useState((fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.computedFieldValueType) && { label: fieldMetaData.computedFieldValueType, value: fieldMetaData.computedFieldValueType }), selectedComputedFieldValueType = _106[0], setSelectedComputedFieldValueType = _106[1];
|
|
592
|
+
var _107 = useState((fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.selectionDynamicProvider) && { label: fieldMetaData.selectionDynamicProvider, value: fieldMetaData.selectionDynamicProvider }), selectionDynamicProvider = _107[0], setSelectionDynamicProvider = _107[1];
|
|
589
593
|
// const [externalIdProvider, setExternalIdProvider] = useState(fieldMetaData?.externalIdProvider && { label: fieldMetaData.externalIdProvider, value: fieldMetaData.externalIdProvider });
|
|
590
|
-
var
|
|
591
|
-
var
|
|
592
|
-
var
|
|
593
|
-
var
|
|
594
|
-
var
|
|
595
|
-
var
|
|
596
|
-
var
|
|
597
|
-
var
|
|
598
|
-
var
|
|
594
|
+
var _108 = useState([]), filteredComputedFieldValueTypes = _108[0], setFilteredComputedFieldValueTypes = _108[1];
|
|
595
|
+
var _109 = useState([]), filteredSelectionDynamicProvider = _109[0], setFilteredSelectionDynamicProvider = _109[1];
|
|
596
|
+
var _110 = useState([]), ormTypeOptions = _110[0], setOrmTypeOptions = _110[1];
|
|
597
|
+
var _111 = useState(fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.ormType), selectedOrmType = _111[0], setSelectedOrmType = _111[1];
|
|
598
|
+
var _112 = useState(false), askForUserKeyField = _112[0], setAskForUserKeyField = _112[1];
|
|
599
|
+
var _113 = useState([]), userKeyFieldData = _113[0], setUserKeyFieldData = _113[1];
|
|
600
|
+
var _114 = useState([]), filteredExternalIdProvider = _114[0], setFilteredExternalIdProvider = _114[1];
|
|
601
|
+
var _115 = useState([]), filteredSelectionEncryptionType = _115[0], setFilteredSelectionEncryptionType = _115[1];
|
|
602
|
+
var _116 = useState([]), filteredSelectionDecryptWhen = _116[0], setFilteredSelectionDecryptWhen = _116[1];
|
|
599
603
|
var validationSchema = React.useMemo(function () { return createValidationSchema(currentFields, selectedType, allFields, fieldMetaData, encryptState); }, [currentFields, encryptState]);
|
|
600
|
-
var
|
|
604
|
+
var _117 = useState(false), typeSelected = _117[0], setTypeSelected = _117[1];
|
|
601
605
|
var showRegexFields = currentFields.includes("regexPattern");
|
|
602
606
|
var showMinFields = currentFields.includes("min");
|
|
603
607
|
var showMaxFields = currentFields.includes("max");
|
|
604
608
|
var showOrmOptions = currentFields.includes("ormType") && Boolean(ormTypeOptions && ormTypeOptions.length);
|
|
605
609
|
var showValidationSection = selectedTypeValue !== "relation" && (showRegexFields || showMinFields || showMaxFields || showOrmOptions);
|
|
610
|
+
var isExistingFieldReadOnly = disableIdentityEditingForExisting && Boolean(fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.id);
|
|
611
|
+
var closeForm = useCallback(function () {
|
|
612
|
+
if (typeof onClose === "function") {
|
|
613
|
+
onClose();
|
|
614
|
+
return;
|
|
615
|
+
}
|
|
616
|
+
if (typeof setVisiblePopup === "function") {
|
|
617
|
+
setVisiblePopup(false);
|
|
618
|
+
}
|
|
619
|
+
}, [onClose, setVisiblePopup]);
|
|
606
620
|
var searchMediaStorageProvIderId = function (event) { return __awaiter(void 0, void 0, void 0, function () {
|
|
607
621
|
var query, queryData, queryString, result, updatedSuggestion, error_1;
|
|
608
622
|
return __generator(this, function (_a) {
|
|
@@ -970,7 +984,7 @@ var FieldMetaDataForm = function (_a) {
|
|
|
970
984
|
{ label: "False", value: "false" },
|
|
971
985
|
];
|
|
972
986
|
var defaultPasswordPolicy = fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.regexPattern;
|
|
973
|
-
var
|
|
987
|
+
var _118 = useState(defaultPasswordPolicy), selectedPasswordPolicy = _118[0], setSelectedPasswordPolicy = _118[1];
|
|
974
988
|
var passwordPolicyOptions = [
|
|
975
989
|
{ label: 'Lowercase and Uppercase Alphabets Required', value: '^(?=.*[a-z])(?=.*[A-Z]).*$' },
|
|
976
990
|
{ label: 'Lowercase and Uppercase Alphabets and Numbers Required', value: '^(?=.*[a-z])(?=.*[A-Z])(?=.*\d).*$' },
|
|
@@ -984,7 +998,7 @@ var FieldMetaDataForm = function (_a) {
|
|
|
984
998
|
{ label: 'File (Supports PDF, DOCX, TXT, etc.)', value: 'file' }
|
|
985
999
|
];
|
|
986
1000
|
var resolvedMediaTypeOptions = useMemo(function () { var _a, _b; return (_b = (_a = fieldDefaultMetaData === null || fieldDefaultMetaData === void 0 ? void 0 : fieldDefaultMetaData.data) === null || _a === void 0 ? void 0 : _a.mediaTypes) !== null && _b !== void 0 ? _b : mediaTypesOptions; }, [(_m = fieldDefaultMetaData === null || fieldDefaultMetaData === void 0 ? void 0 : fieldDefaultMetaData.data) === null || _m === void 0 ? void 0 : _m.mediaTypes]);
|
|
987
|
-
var
|
|
1001
|
+
var _119 = useState(resolvedMediaTypeOptions), filteredMediaTypes = _119[0], setFilteredMediaTypes = _119[1];
|
|
988
1002
|
useEffect(function () {
|
|
989
1003
|
setFilteredMediaTypes(resolvedMediaTypeOptions);
|
|
990
1004
|
}, [resolvedMediaTypeOptions]);
|
|
@@ -1070,37 +1084,40 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1070
1084
|
validationSchema: validationSchema,
|
|
1071
1085
|
enableReinitialize: true,
|
|
1072
1086
|
onSubmit: function (values) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1073
|
-
var data;
|
|
1087
|
+
var newFieldData, formtatedFieldPayload_1, data;
|
|
1074
1088
|
return __generator(this, function (_a) {
|
|
1075
1089
|
try {
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
setIsRequiredPopUp(true);
|
|
1090
|
+
newFieldData = __assign(__assign({}, values), { isSystem: values.isSystem == true ? true : '' });
|
|
1091
|
+
formtatedFieldPayload_1 = fieldBasedPayloadFormating(newFieldData, currentFields, fieldMetaData);
|
|
1092
|
+
if (typeof onDraftSubmit === "function") {
|
|
1093
|
+
onDraftSubmit(formtatedFieldPayload_1);
|
|
1094
|
+
}
|
|
1095
|
+
else {
|
|
1096
|
+
setFieldMetaData(function (prevItems) {
|
|
1097
|
+
var existingIndex = prevItems.findIndex(function (item) { return item.identifier === formtatedFieldPayload_1.identifier; });
|
|
1098
|
+
var updatedItems;
|
|
1099
|
+
if (existingIndex !== -1) {
|
|
1100
|
+
updatedItems = __spreadArray([], prevItems, true);
|
|
1101
|
+
updatedItems[existingIndex] = formtatedFieldPayload_1;
|
|
1102
|
+
return updatedItems;
|
|
1090
1103
|
}
|
|
1091
|
-
|
|
1104
|
+
else {
|
|
1105
|
+
updatedItems = __spreadArray(__spreadArray([], prevItems, true), [formtatedFieldPayload_1], false);
|
|
1106
|
+
if ((params === null || params === void 0 ? void 0 : params.id) !== 'new' && (formtatedFieldPayload_1 === null || formtatedFieldPayload_1 === void 0 ? void 0 : formtatedFieldPayload_1.required) && !(formtatedFieldPayload_1 === null || formtatedFieldPayload_1 === void 0 ? void 0 : formtatedFieldPayload_1.defaultValue)) {
|
|
1107
|
+
setIsRequiredPopUp(true);
|
|
1108
|
+
}
|
|
1109
|
+
}
|
|
1110
|
+
return updatedItems;
|
|
1111
|
+
});
|
|
1112
|
+
if (values.userKey) {
|
|
1113
|
+
data = {
|
|
1114
|
+
modelName: values.relationCoModelSingularName,
|
|
1115
|
+
fieldName: values.userKey
|
|
1116
|
+
};
|
|
1117
|
+
updateUserKey(data);
|
|
1092
1118
|
}
|
|
1093
|
-
return updatedItems;
|
|
1094
|
-
});
|
|
1095
|
-
if (values.userKey) {
|
|
1096
|
-
data = {
|
|
1097
|
-
modelName: values.relationCoModelSingularName,
|
|
1098
|
-
fieldName: values.userKey
|
|
1099
|
-
};
|
|
1100
|
-
updateUserKey(data);
|
|
1101
1119
|
}
|
|
1102
|
-
|
|
1103
|
-
setVisiblePopup(false);
|
|
1120
|
+
closeForm();
|
|
1104
1121
|
}
|
|
1105
1122
|
catch (err) {
|
|
1106
1123
|
console.error(ERROR_MESSAGES.CREATE_MODEL, err);
|
|
@@ -1408,9 +1425,9 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1408
1425
|
event.preventDefault();
|
|
1409
1426
|
resetFormStateForTypeSelection();
|
|
1410
1427
|
}, children: showTypeFilter === true ?
|
|
1411
|
-
_jsx(FieldSelector, { handleTypeSelect: handleTypeSelect, modelMetaData: modelMetaData })
|
|
1428
|
+
_jsx(FieldSelector, { handleTypeSelect: handleTypeSelect, modelMetaData: modelMetaData, availableFieldTypes: availableFieldTypes, initialSelectedValue: (_q = selectedType === null || selectedType === void 0 ? void 0 : selectedType.value) !== null && _q !== void 0 ? _q : selectorInitialFieldType, requireExplicitContinue: selectorRequireContinue, continueLabel: selectorContinueLabel })
|
|
1412
1429
|
:
|
|
1413
|
-
_jsx("div", { className: "p-3", style: { maxHeight: '80vh', overflowY: 'auto', overflowX: 'hidden' }, children: _jsx("div", { className: "flex justify-center creat-field-for form-dem", children: _jsxs("div", { className: "solid-fluid", style: { position: 'relative' }, children: [_jsxs(TabView, { panelContainerClassName: "px-0", children: [_jsx(TabPanel, { header: "Basic Info", className: (formik.touched.hasOwnProperty("name") && formik.errors.hasOwnProperty("name")) || (formik.touched.hasOwnProperty("displayName") && formik.errors.hasOwnProperty("displayName")) || (formik.touched.hasOwnProperty("displayName") && formik.errors.hasOwnProperty("ormType")) ? "tab-error-heading" : "", children: _jsxs("div", { className: "flex flex-wrap -mx-2 -mt-2", children: [currentFields.includes("displayName") && (_jsxs("div", { className: "field mt-2 w-full px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "displayName", className: classNames("form-field-label", styles.fieldLabel), children: "Display Name" }), _jsx(SolidInput, { type: "text", disabled:
|
|
1430
|
+
_jsx("div", { className: "p-3", style: { maxHeight: '80vh', overflowY: 'auto', overflowX: 'hidden' }, children: _jsx("div", { className: "flex justify-center creat-field-for form-dem", children: _jsxs("div", { className: "solid-fluid", style: { position: 'relative' }, children: [_jsxs(TabView, { panelContainerClassName: "px-0", children: [_jsx(TabPanel, { header: "Basic Info", className: (formik.touched.hasOwnProperty("name") && formik.errors.hasOwnProperty("name")) || (formik.touched.hasOwnProperty("displayName") && formik.errors.hasOwnProperty("displayName")) || (formik.touched.hasOwnProperty("displayName") && formik.errors.hasOwnProperty("ormType")) ? "tab-error-heading" : "", children: _jsxs("div", { className: "flex flex-wrap -mx-2 -mt-2", children: [currentFields.includes("displayName") && (_jsxs("div", { className: "field mt-2 w-full px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "displayName", className: classNames("form-field-label", styles.fieldLabel), children: "Display Name" }), _jsx(SolidInput, { type: "text", disabled: isExistingFieldReadOnly, id: "displayName", name: "displayName", onChange: function (e) {
|
|
1414
1431
|
formik.setFieldValue("displayName", e.target.value);
|
|
1415
1432
|
var _a = getSingularAndPlural(e.target.value), toCamelCase = _a.toCamelCase, toSnakeCase = _a.toSnakeCase;
|
|
1416
1433
|
formik.setFieldValue("name", toCamelCase);
|
|
@@ -1419,11 +1436,11 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1419
1436
|
}
|
|
1420
1437
|
}, value: formik.values.displayName, className: classNames(styles.fieldInput, {
|
|
1421
1438
|
"p-invalid": isFormFieldValid(formik, "displayName"),
|
|
1422
|
-
}) }), isFormFieldValid(formik, "displayName") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1439
|
+
}) }), isFormFieldValid(formik, "displayName") && (_jsx("p", { className: styles.fieldError, children: (_s = (_r = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _r === void 0 ? void 0 : _r.displayName) === null || _s === void 0 ? void 0 : _s.toString() }))] })), currentFields.includes("name") && (_jsxs("div", { className: "field mt-1 w-full px-2 pt-2 md:mt-0 md:w-1/2", children: [_jsx("label", { htmlFor: "name", className: classNames("form-field-label", styles.fieldLabel), children: "Name" }), _jsx(SolidInput, { disabled: isExistingFieldReadOnly, type: "text", id: "name", name: "name", onChange: formik.handleChange, value: formik.values.name, className: classNames(styles.fieldInput, {
|
|
1423
1440
|
"p-invalid": isFormFieldValid(formik, "name"),
|
|
1424
|
-
}) }), isFormFieldValid(formik, "name") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1441
|
+
}) }), isFormFieldValid(formik, "name") && (_jsx("p", { className: styles.fieldError, children: (_u = (_t = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _t === void 0 ? void 0 : _t.name) === null || _u === void 0 ? void 0 : _u.toString() }))] })), currentFields.includes("description") && (_jsxs("div", { className: "field mt-1 w-full px-2 pt-2 md:mt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "description", className: classNames("form-field-label", styles.fieldLabel), children: "Description" }), _jsx(SolidTextarea, { "aria-describedby": "Description of your field", id: "description", name: "description", onChange: formik.handleChange, value: formik.values.description, rows: 5, cols: 30, className: classNames(styles.fieldTextarea, {
|
|
1425
1442
|
"p-invalid": isFormFieldValid(formik, "description"),
|
|
1426
|
-
}) }), isFormFieldValid(formik, "description") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1443
|
+
}) }), isFormFieldValid(formik, "description") && (_jsx("p", { className: styles.fieldError, children: (_w = (_v = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _v === void 0 ? void 0 : _v.description) === null || _w === void 0 ? void 0 : _w.toString() }))] })), currentFields.includes("columnName") && (_jsxs("div", { className: "field mt-2 w-full px-2 pt-2 md:w-1/2", children: [_jsxs("div", { className: "flex items-center gap-2", children: [_jsx(SolidCheckbox, { onChange: function (event) {
|
|
1427
1444
|
var checked = event.currentTarget.checked;
|
|
1428
1445
|
setShowColumnName(checked);
|
|
1429
1446
|
if (checked === true) {
|
|
@@ -1435,11 +1452,11 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1435
1452
|
else {
|
|
1436
1453
|
formik.setFieldValue("columnName", null);
|
|
1437
1454
|
}
|
|
1438
|
-
}, checked: showColumnName, disabled:
|
|
1455
|
+
}, checked: showColumnName, disabled: isExistingFieldReadOnly }), _jsx("label", { htmlFor: "ingredient1", className: "form-field-label", children: "Set Column Name" })] }), showColumnName && (_jsxs("div", { className: "field mt-4 w-full gap-2", children: [_jsx("label", { htmlFor: "columnName", className: classNames("form-field-label", styles.fieldLabel), children: "Column Name" }), _jsx(SolidInput, { disabled: isExistingFieldReadOnly, type: "text", id: "columnName", name: "columnName", onChange: formik.handleChange, value: formik.values.columnName, className: classNames(styles.fieldInput, {
|
|
1439
1456
|
"p-invalid": isFormFieldValid(formik, "columnName"),
|
|
1440
|
-
}) }), isFormFieldValid(formik, "columnName") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1457
|
+
}) }), isFormFieldValid(formik, "columnName") && (_jsx("p", { className: styles.fieldError, children: (_y = (_x = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _x === void 0 ? void 0 : _x.columnName) === null || _y === void 0 ? void 0 : _y.toString() }))] }))] }))] }) }), _jsxs(TabPanel, { header: "Advanced Config", children: [((_0 = (_z = formik === null || formik === void 0 ? void 0 : formik.values) === null || _z === void 0 ? void 0 : _z.type) === null || _0 === void 0 ? void 0 : _0.length) > 0 && (_jsxs("div", { className: "flex flex-wrap -mx-2 -mt-2", children: [currentFields.includes("length") && (_jsxs("div", { className: "field flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsx("label", { htmlFor: "length", className: classNames("form-field-label", styles.fieldLabel), children: "Length" }), _jsx("div", { className: styles.fieldNumberWrapper, children: _jsx(SolidNumberInput, { id: "length", name: "length", value: formik.values.length, onChange: function (event) { return formik.setFieldValue("length", event.value); }, className: classNames({
|
|
1441
1458
|
"p-invalid": isFormFieldValid(formik, "length"),
|
|
1442
|
-
}) }) }), isFormFieldValid(formik, "length") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1459
|
+
}) }) }), isFormFieldValid(formik, "length") && (_jsx("p", { className: styles.fieldError, children: (_2 = (_1 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _1 === void 0 ? void 0 : _1.length) === null || _2 === void 0 ? void 0 : _2.toString() }))] })), currentFields.includes("defaultValue") && selectedTypeValue === "boolean" &&
|
|
1443
1460
|
_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { style: { marginBottom: "0px" }, htmlFor: "defaultValue", className: classNames("form-field-label", styles.fieldLabel), children: "Default Value" }), _jsx(SolidSegmentedControl, { value: resolveBooleanOptionValue(formik.values.defaultValue), onChange: function (value) { return formik.setFieldValue("defaultValue", value); }, options: booleanSegmentedOptions, className: classNames("", {
|
|
1444
1461
|
"p-invalid": isFormFieldValid(formik, "defaultValue"),
|
|
1445
1462
|
}) })] }), currentFields.includes("defaultValue") && selectedTypeValue !== "boolean" && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { style: { marginBottom: "0px" }, htmlFor: "defaultValue", className: classNames("form-field-label", styles.fieldLabel), children: "Default Value" }), (selectedTypeValue === "shortText" || selectedTypeValue === "longText" || selectedTypeValue === "richText" || selectedTypeValue === "json" || selectedTypeValue === "password" || selectedTypeValue === "selectionStatic") &&
|
|
@@ -1463,7 +1480,7 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1463
1480
|
return (_jsx(SolidDatePicker, { id: "defaultValue", selected: formik.values.defaultValue ? new Date(formik.values.defaultValue) : undefined, onChange: function (date) { return formik.setFieldValue("defaultValue", date); }, showTimeSelect: showTimeSelect, timeOnly: timeOnly, dateFormat: dateFormat, timeFormat: timeFormat, inputClassName: classNames({
|
|
1464
1481
|
"p-invalid": isFormFieldValid(formik, "defaultValue"),
|
|
1465
1482
|
}) }));
|
|
1466
|
-
})(), isFormFieldValid(formik, "defaultValue") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1483
|
+
})(), isFormFieldValid(formik, "defaultValue") && (_jsx("p", { className: styles.fieldError, children: (_4 = (_3 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _3 === void 0 ? void 0 : _3.defaultValue) === null || _4 === void 0 ? void 0 : _4.toString() }))] })), currentFields.includes("mediaTypes") && (_jsxs("div", { className: "field flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "mediaTypes", className: classNames("form-field-label", styles.fieldLabel), children: "Media Type" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_b = {},
|
|
1467
1484
|
_b[styles.fieldInvalidControl] = isFormFieldValid(formik, "mediaTypes"),
|
|
1468
1485
|
_b)), children: _jsx(SolidAutocomplete, { multiple: true, dropdown: true, field: "label", value: mediaTypeSelectedItems, suggestions: filteredMediaTypes, completeMethod: handleMediaTypesSearch, maxVisibleChips: 3, onChange: function (_a) {
|
|
1469
1486
|
var value = _a.value;
|
|
@@ -1480,69 +1497,69 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1480
1497
|
})
|
|
1481
1498
|
.filter(Boolean);
|
|
1482
1499
|
formik.setFieldValue("mediaTypes", normalizedValues);
|
|
1483
|
-
}, placeholder: "Select media types", className: "w-full" }) }), isFormFieldValid(formik, "mediaTypes") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1500
|
+
}, placeholder: "Select media types", className: "w-full" }) }), isFormFieldValid(formik, "mediaTypes") && (_jsx("p", { className: styles.fieldError, children: (_6 = (_5 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _5 === void 0 ? void 0 : _5.mediaTypes) === null || _6 === void 0 ? void 0 : _6.toString() }))] })), currentFields.includes("mediaMaxSizeKb") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:mt-0 md:w-1/2", children: [_jsx("label", { htmlFor: "mediaMaxSizeKb", className: classNames("form-field-label", styles.fieldLabel), children: "Media Max Size (Mb)" }), _jsx("div", { className: styles.fieldNumberWrapper, children: _jsx(SolidNumberInput, { id: "mediaMaxSizeKb", name: "mediaMaxSizeKb", value: formik.values.mediaMaxSizeKb, onChange: function (event) { return formik.setFieldValue("mediaMaxSizeKb", event.value); }, className: classNames({
|
|
1484
1501
|
"p-invalid": isFormFieldValid(formik, "mediaMaxSizeKb"),
|
|
1485
|
-
}) }) }), isFormFieldValid(formik, "mediaMaxSizeKb") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1502
|
+
}) }) }), isFormFieldValid(formik, "mediaMaxSizeKb") && (_jsx("p", { className: styles.fieldError, children: (_8 = (_7 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _7 === void 0 ? void 0 : _7.mediaMaxSizeKb) === null || _8 === void 0 ? void 0 : _8.toString() }))] })), currentFields.includes("mediaStorageProviderId") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "mediaStorageProviderId", className: classNames("form-field-label", styles.fieldLabel), children: "Media Storage Provider" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_c = {},
|
|
1486
1503
|
_c[styles.fieldInvalidControl] = isFormFieldValid(formik, "mediaStorageProvider"),
|
|
1487
|
-
_c)), children: _jsx(SolidAutocomplete, { value: mediaStorageProviderField.selectedItem, suggestions: mediaStorageProviderField.filteredItems, completeMethod: mediaStorageProviderField.searchItems, onChange: mediaStorageProviderField.handleChange, dropdown: true, field: "name", className: "w-full" }) }), isFormFieldValid(formik, "mediaStorageProvider") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1504
|
+
_c)), children: _jsx(SolidAutocomplete, { value: mediaStorageProviderField.selectedItem, suggestions: mediaStorageProviderField.filteredItems, completeMethod: mediaStorageProviderField.searchItems, onChange: mediaStorageProviderField.handleChange, dropdown: true, field: "name", className: "w-full" }) }), isFormFieldValid(formik, "mediaStorageProvider") && (_jsx("p", { className: styles.fieldError, children: (_10 = (_9 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _9 === void 0 ? void 0 : _9.mediaStorageProviderId) === null || _10 === void 0 ? void 0 : _10.toString() }))] })), currentFields.includes("mediaEmbedded") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "mediaEmbedded", className: classNames("form-field-label", styles.fieldLabel), children: "Media Embedded" }), _jsx(SolidSegmentedControl, { value: resolveBooleanOptionValue(formik.values.mediaEmbedded), onChange: function (value) {
|
|
1488
1505
|
formik.setFieldValue("mediaEmbedded", value);
|
|
1489
1506
|
}, options: booleanSegmentedOptions, className: classNames("", {
|
|
1490
1507
|
"p-invalid": isFormFieldValid(formik, "mediaEmbedded"),
|
|
1491
|
-
}) }), isFormFieldValid(formik, "mediaEmbedded") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1508
|
+
}) }), isFormFieldValid(formik, "mediaEmbedded") && (_jsx("p", { className: styles.fieldError, children: (_12 = (_11 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _11 === void 0 ? void 0 : _11.mediaEmbedded) === null || _12 === void 0 ? void 0 : _12.toString() }))] })), currentFields.includes("relationType") && (_jsxs("div", { className: "field mt-1 flex w-full items-center gap-2 px-2 pt-2", children: [_jsx("label", { style: { marginBottom: "0px" }, htmlFor: "relationType", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Type" }), _jsx(SolidSegmentedControl, { value: formik.values.relationType, options: fieldDefaultMetaData.data.relationTypes, onChange: function (value) {
|
|
1492
1509
|
formik.setFieldValue("relationType", value);
|
|
1493
1510
|
if (value === "one-to-many") {
|
|
1494
1511
|
formik.setFieldValue("relationCreateInverse", true);
|
|
1495
1512
|
}
|
|
1496
1513
|
}, className: classNames("", {
|
|
1497
1514
|
"p-invalid": isFormFieldValid(formik, "relationType"),
|
|
1498
|
-
}) }), isFormFieldValid(formik, "relationType") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1515
|
+
}) }), isFormFieldValid(formik, "relationType") && (_jsx("p", { className: styles.fieldError, children: (_14 = (_13 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _13 === void 0 ? void 0 : _13.relationType) === null || _14 === void 0 ? void 0 : _14.toString() }))] })), currentFields.includes("relationType") && (formik.values.relationType === "many-to-one" || formik.values.relationType === "one-to-many") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationCascade", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Cascade" }), _jsx(SolidSelect, { value: formik.values.relationCascade, options: fieldDefaultMetaData.data.cascadeTypes, optionLabel: "label", optionValue: "value", onChange: function (_a) {
|
|
1499
1516
|
var value = _a.value;
|
|
1500
1517
|
return formik.setFieldValue("relationCascade", value);
|
|
1501
1518
|
}, placeholder: "Cascade", className: classNames("w-full", {
|
|
1502
1519
|
"p-invalid": isFormFieldValid(formik, "relationCascade"),
|
|
1503
|
-
}) }), isFormFieldValid(formik, "relationCascade") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1520
|
+
}) }), isFormFieldValid(formik, "relationCascade") && (_jsx("p", { className: styles.fieldError, children: (_16 = (_15 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _15 === void 0 ? void 0 : _15.relationCascade) === null || _16 === void 0 ? void 0 : _16.toString() }))] })), currentFields.includes("relationModelModuleName") && (_jsxs("div", { className: "field mt-1 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationModelModuleName", className: classNames("form-field-label", styles.fieldLabel), children: "Co-Module Name" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_d = {},
|
|
1504
1521
|
_d[styles.fieldInvalidControl] = isFormFieldValid(formik, "relationModelModuleName"),
|
|
1505
|
-
_d)), children: _jsx(SolidAutocomplete, { value: relationModelModuleField.selectedItem, suggestions: relationModelModuleField.filteredItems, completeMethod: relationModelModuleField.searchItems, onChange: relationModelModuleField.handleChange, dropdown: true, field: "name", className: "w-full" }) }), isFormFieldValid(formik, "relationModelModuleName") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1522
|
+
_d)), children: _jsx(SolidAutocomplete, { value: relationModelModuleField.selectedItem, suggestions: relationModelModuleField.filteredItems, completeMethod: relationModelModuleField.searchItems, onChange: relationModelModuleField.handleChange, dropdown: true, field: "name", className: "w-full" }) }), isFormFieldValid(formik, "relationModelModuleName") && (_jsx("p", { className: styles.fieldError, children: (_18 = (_17 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _17 === void 0 ? void 0 : _17.relationModelModuleName) === null || _18 === void 0 ? void 0 : _18.toString() }))] })), currentFields.includes("relationCoModelSingularName") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationCoModelSingularName", className: classNames("form-field-label", styles.fieldLabel), children: "Co-Model Name" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_e = {},
|
|
1506
1523
|
_e[styles.fieldInvalidControl] = isFormFieldValid(formik, "relationCoModelSingularName"),
|
|
1507
|
-
_e)), children: _jsx(SolidAutocomplete, { value: relationCoModelField.selectedItem, suggestions: relationCoModelField.filteredItems, completeMethod: relationCoModelField.searchItems, onChange: relationCoModelField.handleChange, dropdown: true, field: "displayName", className: "w-full" }) }), isFormFieldValid(formik, "relationCoModelSingularName") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1524
|
+
_e)), children: _jsx(SolidAutocomplete, { value: relationCoModelField.selectedItem, suggestions: relationCoModelField.filteredItems, completeMethod: relationCoModelField.searchItems, onChange: relationCoModelField.handleChange, dropdown: true, field: "displayName", className: "w-full" }) }), isFormFieldValid(formik, "relationCoModelSingularName") && (_jsx("p", { className: styles.fieldError, children: (_20 = (_19 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _19 === void 0 ? void 0 : _19.relationCoModelSingularName) === null || _20 === void 0 ? void 0 : _20.toString() })), formik.values.relationType === "one-to-many" &&
|
|
1508
1525
|
_jsx("p", { className: "fieldSubTitle", children: "This is the child model." }), formik.values.relationType === "many-to-one" &&
|
|
1509
|
-
_jsx("p", { className: "fieldSubTitle", children: "This is the parent model." })] })), currentFields.includes("relationCoModelColumnName") && (formik.values.relationType === "many-to-many" || formik.values.relationType === "many-to-one") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationCoModelColumnName", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Co-Model Column Name" }), _jsx(SolidInput, { type: "text", id: "relationCoModelColumnName", name: "relationCoModelColumnName", onChange: formik.handleChange, disabled:
|
|
1526
|
+
_jsx("p", { className: "fieldSubTitle", children: "This is the parent model." })] })), currentFields.includes("relationCoModelColumnName") && (formik.values.relationType === "many-to-many" || formik.values.relationType === "many-to-one") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationCoModelColumnName", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Co-Model Column Name" }), _jsx(SolidInput, { type: "text", id: "relationCoModelColumnName", name: "relationCoModelColumnName", onChange: formik.handleChange, disabled: isExistingFieldReadOnly, value: formik.values.relationCoModelColumnName, className: classNames(styles.fieldInput, {
|
|
1510
1527
|
"p-invalid": isFormFieldValid(formik, "relationCoModelColumnName"),
|
|
1511
|
-
}) }), isFormFieldValid(formik, "relationCoModelColumnName") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1528
|
+
}) }), isFormFieldValid(formik, "relationCoModelColumnName") && (_jsx("p", { className: styles.fieldError, children: (_22 = (_21 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _21 === void 0 ? void 0 : _21.relationCoModelColumnName) === null || _22 === void 0 ? void 0 : _22.toString() })), _jsx("p", { className: "fieldSubTitle", children: "Allows you to control the column name of the foreign key. Eg. when adding a country field to state model, by default foreign key column in the state table will be called country_id, use this field to create a foreign key with a different name. " })] })), askForUserKeyField && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "userKey", className: classNames("form-field-label", styles.fieldLabel), children: "Set User Key" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_f = {},
|
|
1512
1529
|
_f[styles.fieldInvalidControl] = isFormFieldValid(formik, "userKey"),
|
|
1513
|
-
_f)), children: _jsx(SolidAutocomplete, { value: userKeyField.selectedItem, suggestions: userKeyField.filteredItems, completeMethod: userKeyField.searchItems, onChange: userKeyField.handleChange, dropdown: true, field: "displayName", className: "w-full" }) }), _jsx("p", { className: "fieldSubTitle", children: "The co-model you have selected does not have a user key specified. Use the above dropdown to choose from one of the \"unique\" fields in this co-model to be set as its userkey. User keys are required in co-models being used in many-to-one or one-to-many relations as in SolidX when a many-to-one field is rendered it uses an autocomplete dropdown, and the user key value is what is displayed as the label in the dropdown." }), isFormFieldValid(formik, "userKey") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1530
|
+
_f)), children: _jsx(SolidAutocomplete, { value: userKeyField.selectedItem, suggestions: userKeyField.filteredItems, completeMethod: userKeyField.searchItems, onChange: userKeyField.handleChange, dropdown: true, field: "displayName", className: "w-full" }) }), _jsx("p", { className: "fieldSubTitle", children: "The co-model you have selected does not have a user key specified. Use the above dropdown to choose from one of the \"unique\" fields in this co-model to be set as its userkey. User keys are required in co-models being used in many-to-one or one-to-many relations as in SolidX when a many-to-one field is rendered it uses an autocomplete dropdown, and the user key value is what is displayed as the label in the dropdown." }), isFormFieldValid(formik, "userKey") && (_jsx("p", { className: styles.fieldError, children: (_24 = (_23 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _23 === void 0 ? void 0 : _23.userKey) === null || _24 === void 0 ? void 0 : _24.toString() }))] })), currentFields.includes("relationFieldFixedFilter") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2", children: [_jsx("label", { htmlFor: "relationFieldFixedFilter", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Field Fixed Filter" }), _jsx(SolidTextarea, { "aria-describedby": "Fixed Filter", id: "relationFieldFixedFilter", name: "relationFieldFixedFilter", onChange: formik.handleChange, value: formik.values.relationFieldFixedFilter, rows: 5, cols: 30, className: classNames(styles.fieldTextarea, {
|
|
1514
1531
|
"p-invalid": isFormFieldValid(formik, "relationFieldFixedFilter"),
|
|
1515
|
-
}) }), isFormFieldValid(formik, "relationFieldFixedFilter") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1532
|
+
}) }), isFormFieldValid(formik, "relationFieldFixedFilter") && (_jsx("p", { className: styles.fieldError, children: (_26 = (_25 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _25 === void 0 ? void 0 : _25.relationFieldFixedFilter) === null || _26 === void 0 ? void 0 : _26.toString() })), _jsx("p", { className: "fieldSubTitle", children: "Many to one fields are rendered as autocomplete dropdown on the SolidX ui. Use the fixed filter to load a pre-filtered set of records from the co-model. Please note user input entered in the autocomplete is used to apply a dynamic filter." })] })), currentFields.includes("relationCreateInverse") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationCreateInverse", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Create Inverse" }), _jsxs("div", { className: "flex items-center", children: [_jsx(SolidCheckbox, { id: "relationCreateInverse", name: "relationCreateInverse", checked: formik.values.relationCreateInverse, disabled: formik.values.relationType === "one-to-many", onChange: function (event) { return formik.setFieldValue("relationCreateInverse", event.currentTarget.checked); } }), _jsx("label", { htmlFor: "relationCreateInverse", className: classNames("ml-2", "form-field-label", styles.fieldLabel), children: "Create Inverse" })] }), isFormFieldValid(formik, "relationCreateInverse") && (_jsx("p", { className: styles.fieldError, children: (_28 = (_27 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _27 === void 0 ? void 0 : _27.relationCreateInverse) === null || _28 === void 0 ? void 0 : _28.toString() }))] })), currentFields.includes("relationCoModelFieldName") && formik.values.relationCreateInverse && !formik.values.relationCoModelSingularName && (_jsx("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: _jsx(SolidMessage, { text: "Please select Co-model" }) })), currentFields.includes("relationCoModelFieldName") && formik.values.relationCreateInverse && formik.values.relationCoModelSingularName && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsxs("label", { htmlFor: "relationCoModelFieldName", className: classNames("form-field-label", styles.fieldLabel), children: ["Field Name In ", formik.values.relationCoModelSingularName, " Model"] }), _jsx(SolidInput, { type: "text", id: "relationCoModelFieldName", name: "relationCoModelFieldName", onChange: formik.handleChange, disabled: isExistingFieldReadOnly, value: formik.values.relationCoModelFieldName, className: classNames(styles.fieldInput, {
|
|
1516
1533
|
"p-invalid": isFormFieldValid(formik, "relationCoModelFieldName"),
|
|
1517
1534
|
}) }), formik.values.relationType === "one-to-many" &&
|
|
1518
|
-
_jsxs("p", { className: "fieldSubTitle", children: ["This is a field that is created in the child model. In this case a ", _jsx("span", { style: { fontWeight: "700" }, children: (
|
|
1519
|
-
_jsxs("p", { className: "fieldSubTitle", children: ["This is a field that is created in the parent model. In this case a ", _jsx("span", { style: { fontWeight: "700" }, children: (
|
|
1520
|
-
_jsxs("p", { className: "fieldSubTitle", children: ["In this case a ", formik.values.relationCoModelFieldName, " field will be created in the ", _jsx("span", { style: { fontWeight: "700" }, children: (
|
|
1535
|
+
_jsxs("p", { className: "fieldSubTitle", children: ["This is a field that is created in the child model. In this case a ", _jsx("span", { style: { fontWeight: "700" }, children: (_29 = formik.values.relationCoModelFieldName) !== null && _29 !== void 0 ? _29 : formik.values.relationCoModelSingularName }), " field will be created in the ", formik.values.relationCoModelSingularName, " when setting create inverse true."] }), formik.values.relationType === "many-to-one" &&
|
|
1536
|
+
_jsxs("p", { className: "fieldSubTitle", children: ["This is a field that is created in the parent model. In this case a ", _jsx("span", { style: { fontWeight: "700" }, children: (_30 = formik.values.relationCoModelFieldName) !== null && _30 !== void 0 ? _30 : "".concat(formik.values.relationCoModelSingularName, "s") }), " field will be created in the ", formik.values.relationCoModelSingularName, " when setting create inverse true."] }), formik.values.relationType === "many-to-many" &&
|
|
1537
|
+
_jsxs("p", { className: "fieldSubTitle", children: ["In this case a ", formik.values.relationCoModelFieldName, " field will be created in the ", _jsx("span", { style: { fontWeight: "700" }, children: (_31 = formik.values.relationCoModelSingularName) !== null && _31 !== void 0 ? _31 : '{{}}' }), " when setting create inverse true."] }), isFormFieldValid(formik, "relationCoModelFieldName") && (_jsx("p", { className: styles.fieldError, children: (_33 = (_32 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _32 === void 0 ? void 0 : _32.relationCoModelFieldName) === null || _33 === void 0 ? void 0 : _33.toString() }))] })), currentFields.includes("relationJoinTableName") && formik.values.relationType === "many-to-many" && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "relationJoinTableName", className: classNames("form-field-label", styles.fieldLabel), children: "Relation Join Table Name" }), _jsx(SolidInput, { type: "text", id: "relationJoinTableName", name: "relationJoinTableName", onChange: formik.handleChange, disabled: isExistingFieldReadOnly, value: formik.values.relationJoinTableName, className: classNames(styles.fieldInput, {
|
|
1521
1538
|
"p-invalid": isFormFieldValid(formik, "relationJoinTableName"),
|
|
1522
|
-
}) }), isFormFieldValid(formik, "relationJoinTableName") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1539
|
+
}) }), isFormFieldValid(formik, "relationJoinTableName") && (_jsx("p", { className: styles.fieldError, children: (_35 = (_34 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _34 === void 0 ? void 0 : _34.relationJoinTableName) === null || _35 === void 0 ? void 0 : _35.toString() }))] })), currentFields.includes("selectionDynamicProvider") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "selectionDynamicProvider", className: classNames("form-field-label", styles.fieldLabel), children: "Selection Dynamic Provider" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_g = {},
|
|
1523
1540
|
_g[styles.fieldInvalidControl] = isFormFieldValid(formik, "selectionDynamicProvider"),
|
|
1524
|
-
_g)), children: _jsx(SolidAutocomplete, { value: selectionDynamicProviderField.selectedItem, suggestions: selectionDynamicProviderField.filteredItems, completeMethod: selectionDynamicProviderField.searchItems, onChange: selectionDynamicProviderField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "selectionDynamicProvider") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1541
|
+
_g)), children: _jsx(SolidAutocomplete, { value: selectionDynamicProviderField.selectedItem, suggestions: selectionDynamicProviderField.filteredItems, completeMethod: selectionDynamicProviderField.searchItems, onChange: selectionDynamicProviderField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "selectionDynamicProvider") && (_jsx("p", { className: styles.fieldError, children: (_37 = (_36 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _36 === void 0 ? void 0 : _36.selectionDynamicProvider) === null || _37 === void 0 ? void 0 : _37.toString() }))] })), currentFields.includes("selectionValueType") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "selectionValueType", className: classNames("form-field-label", styles.fieldLabel), children: "Select Value Type" }), _jsx(SolidSelect, { value: formik.values.selectionValueType, options: selctionValueTypes, optionLabel: "label", optionValue: "value", onChange: function (_a) {
|
|
1525
1542
|
var value = _a.value;
|
|
1526
1543
|
return formik.setFieldValue("selectionValueType", value);
|
|
1527
1544
|
}, placeholder: "Select Value Type", className: classNames("w-full", {
|
|
1528
1545
|
"p-invalid": isFormFieldValid(formik, "selectionValueType"),
|
|
1529
|
-
}) }), isFormFieldValid(formik, "selectionValueType") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1546
|
+
}) }), isFormFieldValid(formik, "selectionValueType") && (_jsx("p", { className: styles.fieldError, children: (_39 = (_38 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _38 === void 0 ? void 0 : _38.selectionValueType) === null || _39 === void 0 ? void 0 : _39.toString() }))] })), currentFields.includes("selectionStaticValues") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "selectionStaticValues", className: classNames("form-field-label", styles.fieldLabel), children: "Selection Static Values" }), formik.values.selectionStaticValues.map(function (enumValue, index) { return (_jsx(SelectionStaticValues, { enumValue: enumValue, onUpdate: function (updatedString) { return updateEnumValues(index, updatedString); }, onDelete: function () { return deleteEnumValue(index); }, onAdd: addEnumValue }, index)); }), isFormFieldValid(formik, "selectionStaticValues") && (_jsx("p", { className: styles.fieldError, children: (_41 = (_40 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _40 === void 0 ? void 0 : _40.selectionStaticValues) === null || _41 === void 0 ? void 0 : _41.toString() }))] })), currentFields.includes("computedFieldValueType") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "computedFieldValueType", className: classNames("form-field-label", styles.fieldLabel), children: "Computed Field Value Type" }), _jsx(SolidAutocomplete, { value: selectedComputedFieldValueType, suggestions: filteredComputedFieldValueTypes, completeMethod: searchComputedFieldValueType, field: "label", dropdown: true, className: classNames("solid-standard-autocomplete", (_h = {},
|
|
1530
1547
|
_h[styles.fieldInvalidControl] = isFormFieldValid(formik, "computedFieldValueType"),
|
|
1531
1548
|
_h)), onChange: function (e) {
|
|
1532
1549
|
setSelectedComputedFieldValueType(e.value);
|
|
1533
1550
|
formik.setFieldValue("computedFieldValueType", e.value.value);
|
|
1534
|
-
} }), isFormFieldValid(formik, "computedFieldValueType") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1551
|
+
} }), isFormFieldValid(formik, "computedFieldValueType") && (_jsx("p", { className: styles.fieldError, children: (_43 = (_42 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _42 === void 0 ? void 0 : _42.computedFieldValueType) === null || _43 === void 0 ? void 0 : _43.toString() }))] })), currentFields.includes("computedFieldValueProvider") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "computedFieldValueProvider", className: classNames("form-field-label", styles.fieldLabel), children: "Computed Field Provider" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_j = {},
|
|
1535
1552
|
_j[styles.fieldInvalidControl] = isFormFieldValid(formik, "computedFieldValueProvider"),
|
|
1536
|
-
_j)), children: _jsx(SolidAutocomplete, { value: computedFieldValueProviderField.selectedItem, suggestions: computedFieldValueProviderField.filteredItems, completeMethod: computedFieldValueProviderField.searchItems, onChange: computedFieldValueProviderField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "computedFieldValueProvider") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1553
|
+
_j)), children: _jsx(SolidAutocomplete, { value: computedFieldValueProviderField.selectedItem, suggestions: computedFieldValueProviderField.filteredItems, completeMethod: computedFieldValueProviderField.searchItems, onChange: computedFieldValueProviderField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "computedFieldValueProvider") && (_jsx("p", { className: styles.fieldError, children: (_45 = (_44 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _44 === void 0 ? void 0 : _44.computedFieldValueProvider) === null || _45 === void 0 ? void 0 : _45.toString() }))] })), currentFields.includes("computedFieldTriggerConfig") && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2", children: [(fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.computedFieldTriggerConfig) === null
|
|
1537
1554
|
&&
|
|
1538
1555
|
_jsx("div", { className: "mb-3", children: _jsx(SolidMessage, { severity: "error", text: "You seem to be using an old configuration of ComputedFieldProvider. Please change your current computed field provider i.e ".concat(fieldMetaData === null || fieldMetaData === void 0 ? void 0 : fieldMetaData.computedFieldValueProvider, " to implement IEntityComputedFieldProvider before continuing.") }) }), _jsxs("div", { className: "flex items-center gap-2", children: [_jsx("label", { htmlFor: "computedFieldTriggerConfig", className: classNames("form-field-label", styles.fieldLabel), children: "Computed Field Trigger Config" }), _jsx("div", { children: _jsx(SolidButton, { icon: "si si-plus", size: "small", onClick: handleAdd, type: "button", className: "ml-2" }) })] }), formik.values.computedFieldTriggerConfig.map(function (row, index) {
|
|
1539
1556
|
var _a;
|
|
1540
1557
|
return (_jsx(SelectComputedFieldTriggerValues, { index: index, row: row, onChange: handleChange, onDelete: handleDelete, isLastRow: index === formik.values.computedFieldTriggerConfig.length - 1, disableDelete: formik.values.computedFieldTriggerConfig.length === 1, formik: formik, isFormFieldValid: isFormFieldValid, searchModuleName: searchModuleName, searchModelName: computedFieldSearchHandlers[index], modelMetaData: modelMetaData, errors: (_a = formik.errors.computedFieldTriggerConfig) === null || _a === void 0 ? void 0 : _a[index] }, index));
|
|
1541
|
-
}), typeof formik.errors.computedFieldTriggerConfig === 'string' && (_jsx("p", { className: styles.fieldError, children: formik.errors.computedFieldTriggerConfig }))] })), currentFields.includes("selectionDynamicProviderCtxt") && (_jsxs("div", { className: "field mt-4 flex w-full flex-col gap-2 px-2 pt-2", children: [_jsx("label", { htmlFor: "selectionDynamicProviderCtxt", className: classNames("form-field-label", styles.fieldLabel), children: "Selection Dynamic Provider Context" }), _jsx(SolidCodeEditor, { value: (
|
|
1558
|
+
}), typeof formik.errors.computedFieldTriggerConfig === 'string' && (_jsx("p", { className: styles.fieldError, children: formik.errors.computedFieldTriggerConfig }))] })), currentFields.includes("selectionDynamicProviderCtxt") && (_jsxs("div", { className: "field mt-4 flex w-full flex-col gap-2 px-2 pt-2", children: [_jsx("label", { htmlFor: "selectionDynamicProviderCtxt", className: classNames("form-field-label", styles.fieldLabel), children: "Selection Dynamic Provider Context" }), _jsx(SolidCodeEditor, { value: (_46 = formik.values.selectionDynamicProviderCtxt) !== null && _46 !== void 0 ? _46 : "", onChange: function (value) {
|
|
1542
1559
|
formik.setFieldValue("selectionDynamicProviderCtxt", value !== null && value !== void 0 ? value : "");
|
|
1543
|
-
}, language: "json", height: "300px" }), _jsx("div", { className: " form-field-label mt-2", children: markdownText }), isFormFieldValid(formik, "selectionDynamicProviderCtxt") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1560
|
+
}, language: "json", height: "300px" }), _jsx("div", { className: " form-field-label mt-2", children: markdownText }), isFormFieldValid(formik, "selectionDynamicProviderCtxt") && (_jsx("p", { className: styles.fieldError, children: (_48 = (_47 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _47 === void 0 ? void 0 : _47.selectionDynamicProviderCtxt) === null || _48 === void 0 ? void 0 : _48.toString() }))] })), currentFields.includes("computedFieldValueProviderCtxt") && (_jsxs("div", { className: "field mt-4 flex w-full flex-col gap-2 px-2 pt-2", children: [_jsx("label", { htmlFor: "computedFieldValueProviderCtxt", className: classNames("form-field-label", styles.fieldLabel), children: "Computed Field Value Provider Context" }), _jsx(SolidCodeEditor, { value: (_49 = formik.values.computedFieldValueProviderCtxt) !== null && _49 !== void 0 ? _49 : "", onChange: function (value) {
|
|
1544
1561
|
formik.setFieldValue("computedFieldValueProviderCtxt", value !== null && value !== void 0 ? value : "");
|
|
1545
|
-
}, language: "json", height: "300px" }), _jsx("div", { className: "form-field-label mt-4", children: markdownText }), isFormFieldValid(formik, "computedFieldValueProviderCtxt") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1562
|
+
}, language: "json", height: "300px" }), _jsx("div", { className: "form-field-label mt-4", children: markdownText }), isFormFieldValid(formik, "computedFieldValueProviderCtxt") && (_jsx("p", { className: styles.fieldError, children: (_51 = (_50 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _50 === void 0 ? void 0 : _50.computedFieldValueProviderCtxt) === null || _51 === void 0 ? void 0 : _51.toString() }))] }))] })), showValidationSection && (_jsxs(_Fragment, { children: [_jsx("p", { className: "form-wrapper-heading", children: "Validations" }), _jsxs("div", { className: "flex flex-wrap -mx-2 -mt-2", children: [(showRegexFields && selectedTypeValue === "password") &&
|
|
1546
1563
|
_jsx(_Fragment, { children: _jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "regexPattern", className: classNames("form-field-label", styles.fieldLabel), children: "Password Policy" }), _jsx(SolidSelect, { value: selectedPasswordPolicy, options: passwordPolicyOptions, optionLabel: "label", optionValue: "value", onChange: function (_a) {
|
|
1547
1564
|
var value = _a.value;
|
|
1548
1565
|
setSelectedPasswordPolicy(value);
|
|
@@ -1551,25 +1568,25 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1551
1568
|
}
|
|
1552
1569
|
}, placeholder: "Select a Password Policy", className: "w-full" })] }) }), showRegexFields && (_jsxs(_Fragment, { children: [_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "regexPattern", className: classNames("form-field-label", styles.fieldLabel), children: "Regex Pattern" }), _jsx(SolidInput, { type: "text", id: "regexPattern", name: "regexPattern", onChange: formik.handleChange, value: formik.values.regexPattern, className: classNames(styles.fieldInput, {
|
|
1553
1570
|
"p-invalid": isFormFieldValid(formik, "regexPattern"),
|
|
1554
|
-
}) }), isFormFieldValid(formik, "regexPattern") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1571
|
+
}) }), isFormFieldValid(formik, "regexPattern") && (_jsx("p", { className: styles.fieldError, children: (_53 = (_52 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _52 === void 0 ? void 0 : _52.regexPattern) === null || _53 === void 0 ? void 0 : _53.toString() }))] }), showRegexFields && (_jsxs("div", { className: "field mt-2 mb-3 flex w-full flex-col gap-2 px-2 pt-2 md:mb-3 md:w-1/2", children: [_jsx("label", { htmlFor: "regexPatternNotMatchingErrorMsg", className: classNames("form-field-label", styles.fieldLabel), children: "Regex Pattern Not Matching Error Msg" }), _jsx(SolidInput, { type: "text", id: "regexPatternNotMatchingErrorMsg", name: "regexPatternNotMatchingErrorMsg", onChange: formik.handleChange, value: formik.values.regexPatternNotMatchingErrorMsg, className: classNames(styles.fieldInput, {
|
|
1555
1572
|
"p-invalid": isFormFieldValid(formik, "regexPatternNotMatchingErrorMsg"),
|
|
1556
|
-
}) }), isFormFieldValid(formik, "regexPatternNotMatchingErrorMsg") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1573
|
+
}) }), isFormFieldValid(formik, "regexPatternNotMatchingErrorMsg") && (_jsx("p", { className: styles.fieldError, children: (_55 = (_54 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _54 === void 0 ? void 0 : _54.regexPatternNotMatchingErrorMsg) === null || _55 === void 0 ? void 0 : _55.toString() }))] }))] })), (showMinFields || showMaxFields) &&
|
|
1557
1574
|
_jsxs(_Fragment, { children: [showMinFields && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsxs("label", { htmlFor: "min", className: classNames("form-field-label", styles.fieldLabel), children: ["Min ", (selectedTypeValue !== "int" && selectedTypeValue !== "decimal") && "(Characters Allowed)"] }), _jsx("div", { className: styles.fieldNumberWrapper, children: _jsx(SolidNumberInput, { id: "min", name: "min", step: "0.00001", value: formik.values.min, onChange: function (event) { return formik.setFieldValue("min", event.value); }, className: classNames({
|
|
1558
1575
|
"p-invalid": isFormFieldValid(formik, "min"),
|
|
1559
|
-
}), disabled:
|
|
1576
|
+
}), disabled: isExistingFieldReadOnly }) }), isFormFieldValid(formik, "min") && (_jsx("p", { className: styles.fieldError, children: (_57 = (_56 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _56 === void 0 ? void 0 : _56.min) === null || _57 === void 0 ? void 0 : _57.toString() }))] })), showMaxFields && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsxs("label", { htmlFor: "max", className: classNames("form-field-label", styles.fieldLabel), children: ["Max ", (selectedTypeValue !== "int" &&
|
|
1560
1577
|
selectedTypeValue !== "decimal") && "(Characters allowed)"] }), _jsx("div", { className: styles.fieldNumberWrapper, children: _jsx(SolidNumberInput, { id: "max", name: "max", step: "0.00001", value: formik.values.max, onChange: function (event) { return formik.setFieldValue("max", event.value); }, className: classNames({
|
|
1561
1578
|
"p-invalid": isFormFieldValid(formik, "max"),
|
|
1562
|
-
}), disabled:
|
|
1579
|
+
}), disabled: isExistingFieldReadOnly }) }), isFormFieldValid(formik, "max") && (_jsx("p", { className: styles.fieldError, children: (_59 = (_58 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _58 === void 0 ? void 0 : _58.max) === null || _59 === void 0 ? void 0 : _59.toString() }))] }))] }), showOrmOptions && (_jsxs("div", { className: "field mt-2 flex w-full flex-col gap-2 px-2 pt-2 md:w-1/2", children: [_jsx("label", { htmlFor: "ormType", className: classNames("form-field-label", styles.fieldLabel), children: "Type" }), _jsx(SolidRadioGroup, { name: "ormType", value: selectedOrmType, onChange: function (value) {
|
|
1563
1580
|
formik.setFieldValue("ormType", value);
|
|
1564
1581
|
setSelectedOrmType(value);
|
|
1565
1582
|
}, options: (ormTypeOptions || []).map(function (ormType) { return ({
|
|
1566
1583
|
value: ormType.label,
|
|
1567
1584
|
label: (_jsxs("span", { className: classNames("ml-2", "form-field-label"), children: [ormType.label, _jsx("br", {}), _jsx("span", { className: "fieldSubTitle mt-0", children: "(".concat(ormType.description, ")") })] })),
|
|
1568
|
-
}); }), className: "ormTypeflex", itemClassName: "mr-4 items-center" }), isFormFieldValid(formik, "ormType") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1585
|
+
}); }), className: "ormTypeflex", itemClassName: "mr-4 items-center" }), isFormFieldValid(formik, "ormType") && (_jsx("p", { className: styles.fieldError, children: (_61 = (_60 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _60 === void 0 ? void 0 : _60.ormType) === null || _61 === void 0 ? void 0 : _61.toString() }))] }))] })] })), (formik.values.relationType !== "many-to-many" && formik.values.relationType !== "one-to-many") && _jsx("p", { className: "form-wrapper-heading", children: "Settings" }), _jsxs("div", { className: "mt-1 flex flex-wrap -mx-2 -mt-2 md:mt-0", children: [currentFields.includes("required") && (formik.values.relationType !== "many-to-many" && formik.values.relationType !== "one-to-many") && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center", children: [_jsx(SolidCheckbox, { id: "required", name: "required", onChange: function (event) {
|
|
1569
1586
|
if (!formik.values.isPrimaryKey && !formik.values.unique) {
|
|
1570
1587
|
formik.setFieldValue("required", event.currentTarget.checked);
|
|
1571
1588
|
}
|
|
1572
|
-
}, checked: formik.values.required, disabled: formik.values.isPrimaryKey || formik.values.unique }), _jsxs("label", { htmlFor: "required", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: ["Required ", formik.values.isPrimaryKey && "(Auto-enabled for Primary Key)", !formik.values.isPrimaryKey && formik.values.unique && "(Auto-enabled for Unique)"] })] }), _jsx("p", { className: "text-xs mt-2", children: "You won't be able to create an entry if this field is empty" }), isFormFieldValid(formik, "required") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1589
|
+
}, checked: formik.values.required, disabled: formik.values.isPrimaryKey || formik.values.unique }), _jsxs("label", { htmlFor: "required", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: ["Required ", formik.values.isPrimaryKey && "(Auto-enabled for Primary Key)", !formik.values.isPrimaryKey && formik.values.unique && "(Auto-enabled for Unique)"] })] }), _jsx("p", { className: "text-xs mt-2", children: "You won't be able to create an entry if this field is empty" }), isFormFieldValid(formik, "required") && (_jsx("p", { className: styles.fieldError, children: (_63 = (_62 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _62 === void 0 ? void 0 : _62.required) === null || _63 === void 0 ? void 0 : _63.toString() }))] })), currentFields.includes("unique") && selectedTypeValue !== 'relation' && (_jsxs("div", { className: "field flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center", children: [_jsx(SolidCheckbox, { id: "unique", name: "unique", onChange: function (event) {
|
|
1573
1590
|
// Prevent unchecking if isPrimaryKey is true
|
|
1574
1591
|
if (!formik.values.isPrimaryKey) {
|
|
1575
1592
|
var nextValue = event.currentTarget.checked;
|
|
@@ -1583,20 +1600,20 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1583
1600
|
formik.setFieldValue("required", false);
|
|
1584
1601
|
}
|
|
1585
1602
|
}
|
|
1586
|
-
}, checked: formik.values.unique, disabled: formik.values.isPrimaryKey }), _jsxs("label", { htmlFor: "unique", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: ["Unique ", formik.values.isPrimaryKey && "(Auto-enabled for Primary Key)"] })] }), _jsx("p", { className: "text-xs mt-2", children: "You won't be able to create an entry if there is an existing entry with identical content" }), isFormFieldValid(formik, "unique") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1603
|
+
}, checked: formik.values.unique, disabled: formik.values.isPrimaryKey }), _jsxs("label", { htmlFor: "unique", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: ["Unique ", formik.values.isPrimaryKey && "(Auto-enabled for Primary Key)"] })] }), _jsx("p", { className: "text-xs mt-2", children: "You won't be able to create an entry if there is an existing entry with identical content" }), isFormFieldValid(formik, "unique") && (_jsx("p", { className: styles.fieldError, children: (_65 = (_64 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _64 === void 0 ? void 0 : _64.unique) === null || _65 === void 0 ? void 0 : _65.toString() }))] })), currentFields.includes("index") && selectedTypeValue !== 'relation' && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center", children: [_jsx(SolidCheckbox, { id: "index", name: "index", onChange: function (event) {
|
|
1587
1604
|
formik.setFieldValue("index", event.currentTarget.checked);
|
|
1588
|
-
}, checked: formik.values.index }), _jsx("label", { htmlFor: "index", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: "Index" })] }), isFormFieldValid(formik, "index") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1605
|
+
}, checked: formik.values.index }), _jsx("label", { htmlFor: "index", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: "Index" })] }), isFormFieldValid(formik, "index") && (_jsx("p", { className: styles.fieldError, children: (_67 = (_66 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _66 === void 0 ? void 0 : _66.index) === null || _67 === void 0 ? void 0 : _67.toString() }))] })), currentFields.includes("private") && selectedTypeValue !== 'relation' && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center", children: [_jsx(SolidCheckbox, { id: "private", name: "private", onChange: function (event) {
|
|
1589
1606
|
formik.setFieldValue("private", event.currentTarget.checked);
|
|
1590
|
-
}, checked: formik.values.private }), _jsx("label", { htmlFor: "private", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: "Private" })] }), _jsx("p", { className: "text-xs mt-2", children: "This field will not show up in the API response" }), isFormFieldValid(formik, "private") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1607
|
+
}, checked: formik.values.private }), _jsx("label", { htmlFor: "private", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: "Private" })] }), _jsx("p", { className: "text-xs mt-2", children: "This field will not show up in the API response" }), isFormFieldValid(formik, "private") && (_jsx("p", { className: styles.fieldError, children: (_69 = (_68 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _68 === void 0 ? void 0 : _68.private) === null || _69 === void 0 ? void 0 : _69.toString() }))] })), currentFields.includes("encrypt") && selectedTypeValue !== 'relation' && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center gap-2", children: [_jsx(SolidCheckbox, { id: "encrypt", name: "encrypt", onChange: function (event) {
|
|
1591
1608
|
formik.setFieldValue("encrypt", event.currentTarget.checked);
|
|
1592
1609
|
setEncryptState(event.currentTarget.checked);
|
|
1593
|
-
}, checked: formik.values.encrypt }), _jsx("label", { htmlFor: "encrypt", className: classNames("form-field-label", styles.fieldLabel), children: "Encrypt" })] }), isFormFieldValid(formik, "encrypt") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1610
|
+
}, checked: formik.values.encrypt }), _jsx("label", { htmlFor: "encrypt", className: classNames("form-field-label", styles.fieldLabel), children: "Encrypt" })] }), isFormFieldValid(formik, "encrypt") && (_jsx("p", { className: styles.fieldError, children: (_71 = (_70 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _70 === void 0 ? void 0 : _70.encrypt) === null || _71 === void 0 ? void 0 : _71.toString() }))] })), currentFields.includes("isMultiSelect") && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center", children: [_jsx(SolidCheckbox, { id: "isMultiSelect", name: "isMultiSelect", onChange: function (event) {
|
|
1594
1611
|
formik.setFieldValue("isMultiSelect", event.currentTarget.checked);
|
|
1595
|
-
}, checked: formik.values.isMultiSelect }), _jsx("label", { htmlFor: "isMultiSelect", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: "Is MultiSelect" })] }), isFormFieldValid(formik, "isMultiSelect") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1612
|
+
}, checked: formik.values.isMultiSelect }), _jsx("label", { htmlFor: "isMultiSelect", className: classNames("form-field-label", styles.fieldLabel, "ml-2"), children: "Is MultiSelect" })] }), isFormFieldValid(formik, "isMultiSelect") && (_jsx("p", { className: styles.fieldError, children: (_73 = (_72 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _72 === void 0 ? void 0 : _72.isMultiSelect) === null || _73 === void 0 ? void 0 : _73.toString() }))] })), currentFields.includes("enableAuditTracking") && formik.values.relationType !== "one-to-many" && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center gap-2", children: [_jsx(SolidCheckbox, { id: "enableAuditTracking", name: "enableAuditTracking", onChange: function (event) {
|
|
1596
1613
|
formik.setFieldValue("enableAuditTracking", event.currentTarget.checked);
|
|
1597
|
-
}, checked: formik.values.enableAuditTracking }), _jsx("label", { htmlFor: "enableAuditTracking", className: classNames("form-field-label", styles.fieldLabel), children: "Enable Audit Tracking" })] }), _jsx("p", { className: "fieldSubTitle", children: "By selecting this option, you are setting audit trail for this field." }), isFormFieldValid(formik, "enableAuditTracking") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1614
|
+
}, checked: formik.values.enableAuditTracking }), _jsx("label", { htmlFor: "enableAuditTracking", className: classNames("form-field-label", styles.fieldLabel), children: "Enable Audit Tracking" })] }), _jsx("p", { className: "fieldSubTitle", children: "By selecting this option, you are setting audit trail for this field." }), isFormFieldValid(formik, "enableAuditTracking") && (_jsx("p", { className: styles.fieldError, children: (_75 = (_74 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _74 === void 0 ? void 0 : _74.enableAuditTracking) === null || _75 === void 0 ? void 0 : _75.toString() }))] })), currentFields.includes("isUserKey") && formik.values.unique && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center gap-2", children: [_jsx(SolidCheckbox, { id: "isUserKey", name: "isUserKey", onChange: function (event) {
|
|
1598
1615
|
formik.setFieldValue("isUserKey", event.currentTarget.checked);
|
|
1599
|
-
}, checked: formik.values.isUserKey }), _jsx("label", { htmlFor: "isUserKey", className: classNames("form-field-label", styles.fieldLabel), children: "Is Userkey" })] }), _jsx("p", { className: "fieldSubTitle", children: "By selecting this option, you are setting this field as the model's user key. Any existing user key configuration will be overwritten" }), isFormFieldValid(formik, "isUserKey") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1616
|
+
}, checked: formik.values.isUserKey }), _jsx("label", { htmlFor: "isUserKey", className: classNames("form-field-label", styles.fieldLabel), children: "Is Userkey" })] }), _jsx("p", { className: "fieldSubTitle", children: "By selecting this option, you are setting this field as the model's user key. Any existing user key configuration will be overwritten" }), isFormFieldValid(formik, "isUserKey") && (_jsx("p", { className: styles.fieldError, children: (_77 = (_76 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _76 === void 0 ? void 0 : _76.isUserKey) === null || _77 === void 0 ? void 0 : _77.toString() }))] })), currentFields.includes("isPrimaryKey") && (modelMetaData === null || modelMetaData === void 0 ? void 0 : modelMetaData.isLegacyTable) && (_jsxs("div", { className: "field mt-2 flex w-1/2 flex-col gap-2 px-2 pt-2", children: [_jsxs("div", { className: "flex items-center gap-2", children: [_jsx(SolidCheckbox, { id: "isPrimaryKey", name: "isPrimaryKey", onChange: function (event) {
|
|
1600
1617
|
var checked = event.currentTarget.checked;
|
|
1601
1618
|
formik.setFieldValue("isPrimaryKey", checked);
|
|
1602
1619
|
// Auto-set required and unique when isPrimaryKey is checked
|
|
@@ -1604,11 +1621,11 @@ var FieldMetaDataForm = function (_a) {
|
|
|
1604
1621
|
formik.setFieldValue("required", true);
|
|
1605
1622
|
formik.setFieldValue("unique", true);
|
|
1606
1623
|
}
|
|
1607
|
-
}, checked: formik.values.isPrimaryKey }), _jsx("label", { htmlFor: "isPrimaryKey", className: classNames("form-field-label", styles.fieldLabel), children: "Is Primary Key" })] }), _jsx("p", { className: "fieldSubTitle", children: "By selecting this option, you are setting this field as the primary key for this legacy table." }), isFormFieldValid(formik, "isPrimaryKey") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1624
|
+
}, checked: formik.values.isPrimaryKey }), _jsx("label", { htmlFor: "isPrimaryKey", className: classNames("form-field-label", styles.fieldLabel), children: "Is Primary Key" })] }), _jsx("p", { className: "fieldSubTitle", children: "By selecting this option, you are setting this field as the primary key for this legacy table." }), isFormFieldValid(formik, "isPrimaryKey") && (_jsx("p", { className: styles.fieldError, children: (_79 = (_78 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _78 === void 0 ? void 0 : _78.isPrimaryKey) === null || _79 === void 0 ? void 0 : _79.toString() }))] }))] }), formik.values.encrypt === true && (_jsxs("div", { className: "mt-2 flex flex-wrap -mx-2 -mt-2", children: [_jsx("div", { className: "w-full px-2 pt-2 md:w-1/2", children: _jsxs("div", { className: "field flex w-full flex-col gap-2", children: [_jsx("label", { htmlFor: "encryptionType", className: classNames("form-field-label", styles.fieldLabel), children: "Encryption Type" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_k = {},
|
|
1608
1625
|
_k[styles.fieldInvalidControl] = isFormFieldValid(formik, "encryptionType"),
|
|
1609
|
-
_k)), children: _jsx(SolidAutocomplete, { value: encryptionTypeField.selectedItem, suggestions: encryptionTypeField.filteredItems, completeMethod: encryptionTypeField.searchItems, onChange: encryptionTypeField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "encryptionType") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1626
|
+
_k)), children: _jsx(SolidAutocomplete, { value: encryptionTypeField.selectedItem, suggestions: encryptionTypeField.filteredItems, completeMethod: encryptionTypeField.searchItems, onChange: encryptionTypeField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "encryptionType") && (_jsx("p", { className: styles.fieldError, children: (_81 = (_80 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _80 === void 0 ? void 0 : _80.encryptionType) === null || _81 === void 0 ? void 0 : _81.toString() }))] }) }), _jsx("div", { className: "w-full px-2 pt-2 md:w-1/2", children: _jsxs("div", { className: "field flex w-full flex-col gap-2", children: [_jsx("label", { htmlFor: "decryptWhen", className: classNames("form-field-label", styles.fieldLabel), children: "Decrypt When" }), _jsx("div", { className: classNames("solid-standard-autocomplete", (_l = {},
|
|
1610
1627
|
_l[styles.fieldInvalidControl] = isFormFieldValid(formik, "decryptWhen"),
|
|
1611
|
-
_l)), children: _jsx(SolidAutocomplete, { value: decryptWhenField.selectedItem, suggestions: decryptWhenField.filteredItems, completeMethod: decryptWhenField.searchItems, onChange: decryptWhenField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "decryptWhen") && (_jsx("p", { className: styles.fieldError, children: (
|
|
1628
|
+
_l)), children: _jsx(SolidAutocomplete, { value: decryptWhenField.selectedItem, suggestions: decryptWhenField.filteredItems, completeMethod: decryptWhenField.searchItems, onChange: decryptWhenField.handleChange, dropdown: true, field: "label", className: "w-full" }) }), isFormFieldValid(formik, "decryptWhen") && (_jsx("p", { className: styles.fieldError, children: (_83 = (_82 = formik === null || formik === void 0 ? void 0 : formik.errors) === null || _82 === void 0 ? void 0 : _82.decryptWhen) === null || _83 === void 0 ? void 0 : _83.toString() }))] }) })] }))] })] }), _jsxs("div", { className: "mt-4 flex gap-4", children: [_jsx("div", { children: _jsx(SolidButton, { label: submitLabel, size: "small", onClick: function () { return showError(); }, type: "submit" }) }), _jsx("div", { children: _jsx(SolidButton, { label: "Cancel", size: "small", severity: "secondary", type: "reset", onClick: closeForm, outlined: true }) })] })] }) }) }) }) }), _jsx(SolidDialog, { open: isBackPopupVisible, onOpenChange: function (next) {
|
|
1612
1629
|
if (!next) {
|
|
1613
1630
|
setIsBackPopupVisible(false);
|
|
1614
1631
|
}
|