@solidstarters/solid-core-ui 1.1.5 → 1.1.7

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.
Files changed (157) hide show
  1. package/dist/components/auth/SolidChangeForcePassword.d.ts.map +1 -1
  2. package/dist/components/auth/SolidChangeForcePassword.js +7 -7
  3. package/dist/components/auth/SolidChangeForcePassword.js.map +1 -1
  4. package/dist/components/auth/SolidForgotPassword.d.ts.map +1 -1
  5. package/dist/components/auth/SolidForgotPassword.js +9 -4
  6. package/dist/components/auth/SolidForgotPassword.js.map +1 -1
  7. package/dist/components/auth/SolidLogin.d.ts.map +1 -1
  8. package/dist/components/auth/SolidLogin.js +14 -7
  9. package/dist/components/auth/SolidLogin.js.map +1 -1
  10. package/dist/components/common/BackButton.d.ts +2 -0
  11. package/dist/components/common/BackButton.d.ts.map +1 -0
  12. package/dist/components/common/BackButton.js +17 -0
  13. package/dist/components/common/BackButton.js.map +1 -0
  14. package/dist/components/common/CancelButton.js +2 -2
  15. package/dist/components/common/CancelButton.js.map +1 -1
  16. package/dist/components/common/DropzonePlaceholder.d.ts.map +1 -1
  17. package/dist/components/common/DropzonePlaceholder.js +2 -1
  18. package/dist/components/common/DropzonePlaceholder.js.map +1 -1
  19. package/dist/components/common/FileReaderExt.d.ts +4 -0
  20. package/dist/components/common/FileReaderExt.d.ts.map +1 -0
  21. package/dist/components/common/FileReaderExt.js +15 -0
  22. package/dist/components/common/FileReaderExt.js.map +1 -0
  23. package/dist/components/common/GeneralSettings.d.ts +4 -0
  24. package/dist/components/common/GeneralSettings.d.ts.map +1 -0
  25. package/dist/components/common/GeneralSettings.js +139 -0
  26. package/dist/components/common/GeneralSettings.js.map +1 -0
  27. package/dist/components/common/SingleSelectAutoCompleteField.d.ts.map +1 -1
  28. package/dist/components/common/SingleSelectAutoCompleteField.js +1 -1
  29. package/dist/components/common/SingleSelectAutoCompleteField.js.map +1 -1
  30. package/dist/components/common/SocialMediaLogin.js +1 -1
  31. package/dist/components/common/SocialMediaLogin.js.map +1 -1
  32. package/dist/components/common/SolidFormStepper.d.ts +2 -0
  33. package/dist/components/common/SolidFormStepper.d.ts.map +1 -0
  34. package/dist/components/common/SolidFormStepper.js +6 -0
  35. package/dist/components/common/SolidFormStepper.js.map +1 -0
  36. package/dist/components/core/form/SolidFormView.d.ts.map +1 -1
  37. package/dist/components/core/form/SolidFormView.js +83 -54
  38. package/dist/components/core/form/SolidFormView.js.map +1 -1
  39. package/dist/components/core/form/fields/SolidBooleanField.d.ts.map +1 -1
  40. package/dist/components/core/form/fields/SolidBooleanField.js +4 -4
  41. package/dist/components/core/form/fields/SolidBooleanField.js.map +1 -1
  42. package/dist/components/core/form/fields/SolidDateField.d.ts.map +1 -1
  43. package/dist/components/core/form/fields/SolidDateField.js +7 -7
  44. package/dist/components/core/form/fields/SolidDateField.js.map +1 -1
  45. package/dist/components/core/form/fields/SolidDateTimeField.d.ts.map +1 -1
  46. package/dist/components/core/form/fields/SolidDateTimeField.js +7 -7
  47. package/dist/components/core/form/fields/SolidDateTimeField.js.map +1 -1
  48. package/dist/components/core/form/fields/SolidDecimalField.d.ts.map +1 -1
  49. package/dist/components/core/form/fields/SolidDecimalField.js +4 -4
  50. package/dist/components/core/form/fields/SolidDecimalField.js.map +1 -1
  51. package/dist/components/core/form/fields/SolidIntegerField.d.ts.map +1 -1
  52. package/dist/components/core/form/fields/SolidIntegerField.js +4 -4
  53. package/dist/components/core/form/fields/SolidIntegerField.js.map +1 -1
  54. package/dist/components/core/form/fields/SolidJsonField.d.ts.map +1 -1
  55. package/dist/components/core/form/fields/SolidJsonField.js +2 -2
  56. package/dist/components/core/form/fields/SolidJsonField.js.map +1 -1
  57. package/dist/components/core/form/fields/SolidLongTextField.d.ts.map +1 -1
  58. package/dist/components/core/form/fields/SolidLongTextField.js +2 -2
  59. package/dist/components/core/form/fields/SolidLongTextField.js.map +1 -1
  60. package/dist/components/core/form/fields/SolidMediaMultipleField.d.ts.map +1 -1
  61. package/dist/components/core/form/fields/SolidMediaMultipleField.js +11 -11
  62. package/dist/components/core/form/fields/SolidMediaMultipleField.js.map +1 -1
  63. package/dist/components/core/form/fields/SolidMediaSingleField.d.ts.map +1 -1
  64. package/dist/components/core/form/fields/SolidMediaSingleField.js +13 -13
  65. package/dist/components/core/form/fields/SolidMediaSingleField.js.map +1 -1
  66. package/dist/components/core/form/fields/SolidRichTextField.d.ts.map +1 -1
  67. package/dist/components/core/form/fields/SolidRichTextField.js +2 -2
  68. package/dist/components/core/form/fields/SolidRichTextField.js.map +1 -1
  69. package/dist/components/core/form/fields/SolidSelectionDynamicField.d.ts.map +1 -1
  70. package/dist/components/core/form/fields/SolidSelectionDynamicField.js +4 -4
  71. package/dist/components/core/form/fields/SolidSelectionDynamicField.js.map +1 -1
  72. package/dist/components/core/form/fields/SolidSelectionStaticField.d.ts.map +1 -1
  73. package/dist/components/core/form/fields/SolidSelectionStaticField.js +4 -4
  74. package/dist/components/core/form/fields/SolidSelectionStaticField.js.map +1 -1
  75. package/dist/components/core/form/fields/SolidShortTextField.d.ts.map +1 -1
  76. package/dist/components/core/form/fields/SolidShortTextField.js +2 -2
  77. package/dist/components/core/form/fields/SolidShortTextField.js.map +1 -1
  78. package/dist/components/core/form/fields/SolidTimeField.d.ts.map +1 -1
  79. package/dist/components/core/form/fields/SolidTimeField.js +7 -7
  80. package/dist/components/core/form/fields/SolidTimeField.js.map +1 -1
  81. package/dist/components/core/form/fields/relations/SolidRelationManyToManyField.d.ts.map +1 -1
  82. package/dist/components/core/form/fields/relations/SolidRelationManyToManyField.js +15 -14
  83. package/dist/components/core/form/fields/relations/SolidRelationManyToManyField.js.map +1 -1
  84. package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.d.ts.map +1 -1
  85. package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.js +2 -2
  86. package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.js.map +1 -1
  87. package/dist/components/core/form/fields/relations/SolidRelationOneToManyField.js +2 -2
  88. package/dist/components/core/form/fields/relations/SolidRelationOneToManyField.js.map +1 -1
  89. package/dist/components/core/model/CreateModel.d.ts.map +1 -1
  90. package/dist/components/core/model/CreateModel.js +15 -11
  91. package/dist/components/core/model/CreateModel.js.map +1 -1
  92. package/dist/components/core/model/FieldMetaData.d.ts.map +1 -1
  93. package/dist/components/core/model/FieldMetaData.js +6 -6
  94. package/dist/components/core/model/FieldMetaData.js.map +1 -1
  95. package/dist/components/core/model/FieldMetaDataForm.d.ts.map +1 -1
  96. package/dist/components/core/model/FieldMetaDataForm.js +167 -152
  97. package/dist/components/core/model/FieldMetaDataForm.js.map +1 -1
  98. package/dist/components/core/model/FieldSelector.d.ts.map +1 -1
  99. package/dist/components/core/model/FieldSelector.js +1 -1
  100. package/dist/components/core/model/FieldSelector.js.map +1 -1
  101. package/dist/components/core/model/ModelMetaData.d.ts.map +1 -1
  102. package/dist/components/core/model/ModelMetaData.js +46 -42
  103. package/dist/components/core/model/ModelMetaData.js.map +1 -1
  104. package/dist/components/core/module/CreateModule.d.ts.map +1 -1
  105. package/dist/components/core/module/CreateModule.js +98 -60
  106. package/dist/components/core/module/CreateModule.js.map +1 -1
  107. package/dist/components/core/users/CreateUser.d.ts.map +1 -1
  108. package/dist/components/core/users/CreateUser.js +18 -15
  109. package/dist/components/core/users/CreateUser.js.map +1 -1
  110. package/dist/index.d.ts +5 -0
  111. package/dist/index.d.ts.map +1 -1
  112. package/dist/index.js +5 -0
  113. package/dist/index.js.map +1 -1
  114. package/dist/redux/api/solidSettingsApi.d.ts +9 -0
  115. package/dist/redux/api/solidSettingsApi.d.ts.map +1 -0
  116. package/dist/redux/api/solidSettingsApi.js +40 -0
  117. package/dist/redux/api/solidSettingsApi.js.map +1 -0
  118. package/package.json +1 -1
  119. package/src/components/auth/SolidChangeForcePassword.tsx +2 -3
  120. package/src/components/auth/SolidForgotPassword.tsx +9 -4
  121. package/src/components/auth/SolidLogin.tsx +22 -13
  122. package/src/components/common/BackButton.tsx +27 -0
  123. package/src/components/common/CancelButton.tsx +2 -2
  124. package/src/components/common/DropzonePlaceholder.tsx +11 -3
  125. package/src/components/common/FileReaderExt.tsx +18 -0
  126. package/src/components/common/GeneralSettings.tsx +286 -0
  127. package/src/components/common/SingleSelectAutoCompleteField.tsx +0 -1
  128. package/src/components/common/SocialMediaLogin.tsx +1 -1
  129. package/src/components/common/SolidFormStepper.tsx +12 -0
  130. package/src/components/core/form/SolidFormView.tsx +201 -186
  131. package/src/components/core/form/fields/SolidBooleanField.tsx +3 -7
  132. package/src/components/core/form/fields/SolidDateField.tsx +2 -8
  133. package/src/components/core/form/fields/SolidDateTimeField.tsx +19 -24
  134. package/src/components/core/form/fields/SolidDecimalField.tsx +2 -7
  135. package/src/components/core/form/fields/SolidIntegerField.tsx +17 -22
  136. package/src/components/core/form/fields/SolidJsonField.tsx +15 -19
  137. package/src/components/core/form/fields/SolidLongTextField.tsx +19 -24
  138. package/src/components/core/form/fields/SolidMediaMultipleField.tsx +47 -51
  139. package/src/components/core/form/fields/SolidMediaSingleField.tsx +47 -51
  140. package/src/components/core/form/fields/SolidRichTextField.tsx +3 -7
  141. package/src/components/core/form/fields/SolidSelectionDynamicField.tsx +2 -7
  142. package/src/components/core/form/fields/SolidSelectionStaticField.tsx +20 -25
  143. package/src/components/core/form/fields/SolidShortTextField.tsx +18 -23
  144. package/src/components/core/form/fields/SolidTimeField.tsx +19 -24
  145. package/src/components/core/form/fields/relations/SolidRelationManyToManyField.tsx +51 -52
  146. package/src/components/core/form/fields/relations/SolidRelationManyToOneField.tsx +20 -25
  147. package/src/components/core/form/fields/relations/SolidRelationOneToManyField.tsx +6 -5
  148. package/src/components/core/model/CreateModel.tsx +68 -53
  149. package/src/components/core/model/FieldMetaData.tsx +16 -21
  150. package/src/components/core/model/FieldMetaDataForm.tsx +802 -896
  151. package/src/components/core/model/FieldSelector.tsx +10 -15
  152. package/src/components/core/model/ModelMetaData.tsx +364 -356
  153. package/src/components/core/module/CreateModule.tsx +327 -295
  154. package/src/components/core/users/CreateUser.tsx +175 -167
  155. package/src/index.ts +5 -2
  156. package/src/redux/api/solidSettingsApi.tsx +47 -0
  157. package/solidstarters-solid-core-ui-1.1.2.tgz +0 -0
@@ -968,6 +968,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
968
968
  };
969
969
 
970
970
 
971
+
971
972
  const handleTypeSelect = (e: any) => {
972
973
 
973
974
 
@@ -1028,58 +1029,79 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1028
1029
  };
1029
1030
 
1030
1031
  return (
1031
- <div className="field-popup" >
1032
+ <div>
1032
1033
  <Toast ref={toast} />
1033
1034
  <div>
1034
1035
  <form onSubmit={formik.handleSubmit}>
1035
- <div className="field-popup-navigation">
1036
+ <div className="solid-field-metadata-form-header">
1036
1037
  {pathname.includes('create') ?
1037
- <div className="flex gap-3 justify-content-between ">
1038
- {showTypeFilter === false ?
1039
- <div className="flex text-2xl font-bold align-items-center" style={{ color: '#000' }}>
1040
- <Button icon="pi pi-arrow-left" rounded text type="reset" aria-label="Cancel" size="small" onClick={() => {
1041
- if (!formik.values.displayName) {
1042
- setShowTypeFilter(true)
1043
- } else {
1044
- setIsBackPopupVisible(true)
1045
- }
1046
- }
1047
- } />
1048
- <p className="field-popup-nav-heading">{capitalize(modelMetaData?.displayName)}</p>
1049
- </div> :
1050
- <div className="flex text-2xl font-bold align-items-center ml-4" style={{ color: '#000' }}>
1051
- <p className="field-popup-nav-heading">Model - {capitalize(modelMetaData?.displayName)}</p>
1052
- </div>
1053
- }
1038
+ <>
1039
+ <div className="flex align-items-center gap-3">
1040
+ {showTypeFilter === false ?
1041
+ <>
1042
+ <Button
1043
+ text
1044
+ icon='pi pi-arrow-left'
1045
+ size="small"
1046
+ type="button"
1047
+ aria-label="Back"
1048
+ className='max-w-2rem bg-primary-reverse text-color'
1049
+ onClick={() => {
1050
+ if (!formik.values.displayName) {
1051
+ setShowTypeFilter(true)
1052
+ } else {
1053
+ setIsBackPopupVisible(true)
1054
+ }
1055
+ }
1056
+ }
1057
+ />
1058
+ <div className="form-wrapper-title text-base">{capitalize(modelMetaData?.displayName)}</div>
1059
+ </>
1060
+ :
1061
+ <div className="flex text-2xl font-bold align-items-center ml-4" style={{ color: '#000' }}>
1062
+ <div className="form-wrapper-title text-base">Model - {capitalize(modelMetaData?.displayName)}</div>
1063
+ </div>
1064
+ }
1065
+ </div>
1054
1066
  <div className="flex align-items-center gap-3 close-popup">
1055
- <Button icon="pi pi-times" rounded text aria-label="Cancel" type="reset" size="small" onClick={() => setVisiblePopup(false)} />
1067
+ <Button icon="pi pi-times" rounded text aria-label="Cancel" type="reset" size="small" onClick={() => setVisiblePopup(false)}
1068
+ className='max-w-2rem bg-primary-reverse text-color' />
1056
1069
  </div>
1057
- </div> :
1058
- <div className="flex gap-3 justify-content-between ">
1059
- <div className="flex text-2xl font-bold align-items-center" style={{ color: '#000' }}>
1070
+ </>
1071
+ :
1072
+ <>
1073
+ <div className="flex align-items-center gap-3">
1060
1074
  {!fieldMetaData?.id &&
1061
- < Button icon="pi pi-arrow-left" rounded text type="reset" aria-label="Cancel" size="small" onClick={() => {
1062
- if (!formik.values.displayName) {
1063
- setShowTypeFilter(true)
1064
- } else {
1065
- setIsBackPopupVisible(true)
1075
+ <Button
1076
+ text
1077
+ icon='pi pi-arrow-left'
1078
+ size="small"
1079
+ type="button"
1080
+ aria-label="Back"
1081
+ className='max-w-2rem bg-primary-reverse text-color'
1082
+ onClick={() => {
1083
+ if (!formik.values.displayName) {
1084
+ setShowTypeFilter(true)
1085
+ } else {
1086
+ setIsBackPopupVisible(true)
1087
+ }
1066
1088
  }
1067
- }
1068
- } />
1089
+ } />
1069
1090
  }
1070
1091
  {fieldMetaData ?
1071
1092
 
1072
- <p className="field-popup-nav-heading ml-2">{capitalize(modelMetaData?.displayName)} &gt; {capitalize(fieldMetaData?.displayName)}</p>
1093
+ <div className="form-wrapper-title text-base">{capitalize(modelMetaData?.displayName)} &gt; {capitalize(fieldMetaData?.displayName)}</div>
1073
1094
 
1074
1095
  :
1075
- <p className="field-popup-nav-heading ml-2">Add New Field to {capitalize(modelMetaData?.displayName)}</p>
1096
+ <div className="form-wrapper-title text-base">Add New Field to {capitalize(modelMetaData?.displayName)}</div>
1076
1097
  }
1077
-
1078
1098
  </div>
1079
1099
  <div className="flex align-items-center gap-3 close-popup">
1080
- <Button icon="pi pi-times" rounded text aria-label="Cancel" type="reset" size="small" onClick={() => setVisiblePopup(false)} />
1100
+ <Button icon="pi pi-times" text aria-label="Cancel" type="reset" size="small" onClick={() => setVisiblePopup(false)}
1101
+ className='max-w-2rem bg-primary-reverse text-color'
1102
+ />
1081
1103
  </div>
1082
- </div>
1104
+ </>
1083
1105
  }
1084
1106
  </div>
1085
1107
  {showTypeFilter === true ?
@@ -1091,139 +1113,128 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1091
1113
  <div className="field-popup-form" >
1092
1114
  <div className="p-d-flex p-jc-center creat-field-for form-dem">
1093
1115
  <div className="p-fluid" style={{ position: 'relative' }}>
1094
- <div className="field-popup-heading">
1095
- <p>Add a new {capitalize(selectedType.value)} Field</p>
1116
+ <div className="mb-3">
1117
+ <div className="form-wrapper-title">Add a new {capitalize(selectedType.value)} Field</div>
1096
1118
  </div>
1097
1119
 
1098
1120
 
1099
- <TabView panelContainerClassName="px-0 pb-0">
1121
+ <TabView>
1100
1122
  <TabPanel
1101
1123
  header="Basic Info"
1102
1124
  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" : ""}
1103
1125
  // rightIcon="pi pi-info-circle ml-2"
1104
1126
  >
1105
- <div className="grid p-nogutter">
1127
+ <div className="formgrid grid">
1106
1128
  {currentFields.includes("displayName") && (
1107
- <div className="md:col-6 sm:col-12">
1108
- <div className="field">
1109
- <label htmlFor="displayName" className="form-label form-field-label">
1110
- Display Name
1111
- </label>
1112
- <InputText
1113
- type="text"
1114
- disabled={fieldMetaData?.id}
1115
- id="displayName"
1116
- name="displayName"
1117
- onChange={(e) => {
1118
- formik.setFieldValue("displayName", e.target.value);
1119
- const { toCamelCase, toSnakeCase, toPluralCamelCase } = getSingularAndPlural(e.target.value);
1120
- formik.setFieldValue("name", toCamelCase);
1121
- if (showColumnName) {
1122
- formik.setFieldValue("columnName", toSnakeCase);
1123
- }
1129
+ <div className="field col-6 flex-flex-column gap-2">
1130
+ <label htmlFor="displayName" className="form-field-label">
1131
+ Display Name
1132
+ </label>
1133
+ <InputText
1134
+ type="text"
1135
+ disabled={fieldMetaData?.id}
1136
+ id="displayName"
1137
+ name="displayName"
1138
+ onChange={(e) => {
1139
+ formik.setFieldValue("displayName", e.target.value);
1140
+ const { toCamelCase, toSnakeCase, toPluralCamelCase } = getSingularAndPlural(e.target.value);
1141
+ formik.setFieldValue("name", toCamelCase);
1142
+ if (showColumnName) {
1143
+ formik.setFieldValue("columnName", toSnakeCase);
1144
+ }
1124
1145
 
1125
- }}
1126
- value={formik.values.displayName}
1127
- className={classNames("p-inputtext-sm w-full small-input", {
1128
- "p-invalid": isFormFieldValid(
1129
- formik,
1130
- "displayName"
1131
- ),
1132
- })}
1146
+ }}
1147
+ value={formik.values.displayName}
1148
+ className={classNames("", {
1149
+ "p-invalid": isFormFieldValid(
1150
+ formik,
1151
+ "displayName"
1152
+ ),
1153
+ })}
1154
+ />
1155
+ {isFormFieldValid(formik, "displayName") && (
1156
+ <Message
1157
+ severity="error"
1158
+ text={formik?.errors?.displayName?.toString()}
1133
1159
  />
1134
- {isFormFieldValid(formik, "displayName") && (
1135
- <Message
1136
- severity="error"
1137
- text={formik?.errors?.displayName?.toString()}
1138
- />
1139
- )}
1140
- </div>
1160
+ )}
1141
1161
  </div>
1142
1162
  )}
1143
1163
 
1144
1164
 
1145
1165
  {currentFields.includes("name") && (
1146
- <div className="md:col-6 sm:col-12">
1147
- <div className="field">
1148
- <label htmlFor="name" className="form-label form-field-label">
1149
- Name
1150
- </label>
1151
- <InputText
1152
- disabled={fieldMetaData?.id}
1153
- type="text"
1154
- id="name"
1155
- name="name"
1156
- onChange={formik.handleChange}
1157
- value={formik.values.name}
1158
- className={classNames("p-inputtext-sm w-full small-input", {
1159
- "p-invalid": isFormFieldValid(formik, "name"),
1160
- })}
1166
+ <div className="field col-6 flex-flex-column gap-2">
1167
+ <label htmlFor="name" className="form-field-label">
1168
+ Name
1169
+ </label>
1170
+ <InputText
1171
+ disabled={fieldMetaData?.id}
1172
+ type="text"
1173
+ id="name"
1174
+ name="name"
1175
+ onChange={formik.handleChange}
1176
+ value={formik.values.name}
1177
+ className={classNames("", {
1178
+ "p-invalid": isFormFieldValid(formik, "name"),
1179
+ })}
1180
+ />
1181
+ {isFormFieldValid(formik, "name") && (
1182
+ <Message
1183
+ severity="error"
1184
+ text={formik?.errors?.name?.toString()}
1161
1185
  />
1162
- {isFormFieldValid(formik, "name") && (
1163
- <Message
1164
- severity="error"
1165
- text={formik?.errors?.name?.toString()}
1166
- />
1167
- )}
1168
- </div>
1186
+ )}
1169
1187
  </div>
1170
1188
  )}
1171
1189
  {currentFields.includes("description") && (
1172
- <div className="md:col-6 sm:col-12">
1173
- <div className="field">
1174
- <label htmlFor="description" className="form-label form-field-label">
1175
- Description
1176
- </label>
1177
- <InputTextarea
1178
- aria-describedby="Description of your field"
1179
- id="description"
1180
- name="description"
1181
- onChange={formik.handleChange}
1182
- value={formik.values.description}
1183
- rows={5}
1184
- cols={30}
1185
- className={classNames("p-inputtext-sm w-full", {
1186
- "p-invalid": isFormFieldValid(
1187
- formik,
1188
- "description"
1189
- ),
1190
- })}
1190
+ <div className="field col-6 flex-flex-column gap-2 mt-4">
1191
+ <label htmlFor="description" className="form-field-label">
1192
+ Description
1193
+ </label>
1194
+ <InputTextarea
1195
+ aria-describedby="Description of your field"
1196
+ id="description"
1197
+ name="description"
1198
+ onChange={formik.handleChange}
1199
+ value={formik.values.description}
1200
+ rows={5}
1201
+ cols={30}
1202
+ className={classNames("", {
1203
+ "p-invalid": isFormFieldValid(
1204
+ formik,
1205
+ "description"
1206
+ ),
1207
+ })}
1208
+ />
1209
+ {isFormFieldValid(formik, "description") && (
1210
+ <Message
1211
+ severity="error"
1212
+ text={formik?.errors?.description?.toString()}
1191
1213
  />
1192
- {isFormFieldValid(formik, "description") && (
1193
- <Message
1194
- severity="error"
1195
- text={formik?.errors?.description?.toString()}
1196
- />
1197
- )}
1198
- </div>
1214
+ )}
1199
1215
  </div>
1200
1216
  )}
1201
1217
 
1202
1218
  {currentFields.includes("columnName") && (
1203
- <div className="md:col-6 sm:col-12">
1204
- <div className="field mt-5">
1205
- <div className="flex align-items-center">
1206
-
1207
- <div className="flex align-items-center">
1208
- <Checkbox onChange={e => {
1209
- setShowColumnName(e.checked);
1210
- if (e.checked === true) {
1211
- const { toCamelCase, toSnakeCase, toPluralCamelCase } = getSingularAndPlural(formik.values.displayName);
1212
- if (pathname.includes('create')) {
1213
- formik.setFieldValue("columnName", toSnakeCase);
1214
- }
1215
- }
1219
+ <div className="field col-6 mt-4">
1220
+ <div className="flex align-items-center gap-2">
1221
+ <Checkbox onChange={e => {
1222
+ setShowColumnName(e.checked);
1223
+ if (e.checked === true) {
1224
+ const { toCamelCase, toSnakeCase, toPluralCamelCase } = getSingularAndPlural(formik.values.displayName);
1225
+ if (pathname.includes('create')) {
1226
+ formik.setFieldValue("columnName", toSnakeCase);
1227
+ }
1228
+ }
1216
1229
 
1217
- }} checked={showColumnName}></Checkbox>
1218
- <label htmlFor="ingredient1" className="ml-2">
1219
- Set Column Name
1220
- </label>
1221
- </div>
1222
- </div>
1230
+ }} checked={showColumnName}></Checkbox>
1231
+ <label htmlFor="ingredient1" className="form-field-label">
1232
+ Set Column Name
1233
+ </label>
1223
1234
  </div>
1224
1235
  {showColumnName &&
1225
- <div className="field mt-3">
1226
- <label htmlFor="columnName" className="form-label form-field-label">
1236
+ <div className="field col-12 flex-flex-column gap-2 mt-4">
1237
+ <label htmlFor="columnName" className="form-field-label">
1227
1238
  Column Name
1228
1239
  </label>
1229
1240
  <InputText
@@ -1233,7 +1244,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1233
1244
  name="columnName"
1234
1245
  onChange={formik.handleChange}
1235
1246
  value={formik.values.columnName}
1236
- className={classNames("p-inputtext-sm w-full small-input", {
1247
+ className={classNames("", {
1237
1248
  "p-invalid": isFormFieldValid(formik, "columnName"),
1238
1249
  })}
1239
1250
  />
@@ -1251,8 +1262,8 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1251
1262
 
1252
1263
  {/* {currentFields.includes("type") && (
1253
1264
  <div className="md:col-6 sm:col-12">
1254
- <div className="field">
1255
- <label htmlFor="type" className="form-label form-field-label">
1265
+ <div className="field col-6 flex-flex-column gap-2">
1266
+ <label htmlFor="type" className="form-field-label">
1256
1267
  Type
1257
1268
  </label>
1258
1269
  <AutoComplete
@@ -1304,145 +1315,136 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1304
1315
  // rightIcon="pi pi-cog ml-2"
1305
1316
  >
1306
1317
  {formik?.values?.type?.length > 0 && (
1307
- <div className="grid p-nogutter">
1318
+ <div className="formgrid grid">
1308
1319
  {currentFields.includes("length") && (
1309
- <div className="md:col-6 sm:col-12">
1310
- <div className="field">
1311
- <label htmlFor="length" className="form-label form-field-label">
1312
- Length
1313
- </label>
1314
- <InputNumber
1315
- // type="text"
1316
- id="length"
1317
- name="length"
1318
- onValueChange={formik.handleChange}
1319
- value={formik.values.length}
1320
- className={classNames("p-inputtext-sm w-full small-input", {
1321
- "p-invalid": isFormFieldValid(
1322
- formik,
1323
- "length"
1324
- ),
1325
- })}
1320
+ <div className="field col-6 flex-flex-column gap-2">
1321
+ <label htmlFor="length" className="form-field-label">
1322
+ Length
1323
+ </label>
1324
+ <InputNumber
1325
+ // type="text"
1326
+ id="length"
1327
+ name="length"
1328
+ onValueChange={formik.handleChange}
1329
+ value={formik.values.length}
1330
+ className={classNames("", {
1331
+ "p-invalid": isFormFieldValid(
1332
+ formik,
1333
+ "length"
1334
+ ),
1335
+ })}
1336
+ />
1337
+ {isFormFieldValid(formik, "length") && (
1338
+ <Message
1339
+ severity="error"
1340
+ text={formik?.errors?.length?.toString()}
1326
1341
  />
1327
- {isFormFieldValid(formik, "length") && (
1328
- <Message
1329
- severity="error"
1330
- text={formik?.errors?.length?.toString()}
1331
- />
1332
- )}
1333
- </div>
1342
+ )}
1334
1343
  </div>
1335
1344
  )}
1336
1345
  {currentFields.includes("defaultValue") && (
1337
- <div className="md:col-6 sm:col-12">
1338
- <div className="field">
1339
- <label
1340
- htmlFor="defaultValue"
1341
- className="form-label form-field-label"
1342
- >
1343
- Default Value
1344
- </label>
1345
- {/* <InputText
1346
+ <div className="field col-6 flex-flex-column gap-2">
1347
+ <label
1348
+ htmlFor="defaultValue"
1349
+ className="form-field-label"
1350
+ >
1351
+ Default Value
1352
+ </label>
1353
+ {/* <InputText
1346
1354
  type="text"
1347
1355
  id="defaultValue"
1348
1356
  name="defaultValue"
1349
1357
  onChange={formik.handleChange}
1350
1358
  value={formik.values.defaultValue}
1351
- className={classNames("p-inputtext-sm w-full small-input", {
1359
+ className={classNames("", {
1352
1360
  "p-invalid": isFormFieldValid(
1353
1361
  formik,
1354
1362
  "defaultValue"
1355
1363
  ),
1356
1364
  })}
1357
1365
  /> */}
1358
- {(selectedType.value === "shortText" || selectedType.value === "longText" || selectedType.value === "richText" || selectedType.value === "json" || selectedType.value === "password" || selectedType.value === "selectionStatic") &&
1359
- <InputText
1360
- type="text"
1361
- id="defaultValue"
1362
- name="defaultValue"
1363
- onChange={formik.handleChange}
1364
- value={formik.values.defaultValue}
1365
- className={classNames("p-inputtext-sm w-full small-input", {
1366
- "p-invalid": isFormFieldValid(
1367
- formik,
1368
- "defaultValue"
1369
- ),
1370
- })}
1371
- />
1372
- }
1373
- {(selectedType.value === "float" || selectedType.value === "decimal") &&
1374
- <InputNumber
1375
- id="defaultValue"
1376
- name="defaultValue"
1377
- minFractionDigits={2}
1378
- maxFractionDigits={5}
1379
- value={formik.values.defaultValue}
1380
- onValueChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Ensure correct value change handling
1381
- className={classNames("p-inputtext-sm w-full small-input", {
1382
- "p-invalid": isFormFieldValid(formik, "defaultValue"),
1383
- })}
1384
- />
1385
- }
1386
- {(selectedType.value === "int" || selectedType.value === "bigint") &&
1387
- <InputNumber
1388
- id="defaultValue"
1389
- name="defaultValue"
1390
- value={formik.values.defaultValue}
1391
- onValueChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Ensure correct value change handling
1392
- className={classNames("p-inputtext-sm w-full small-input", {
1393
- "p-invalid": isFormFieldValid(formik, "defaultValue"),
1394
- })}
1395
- />
1396
- }
1397
- {selectedType.value === "boolean" &&
1398
- <SelectButton
1399
- value={formik.values.defaultValue ? formik.values.defaultValue : "false"}
1400
- onChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Custom handling for boolean input
1401
- options={booleanOptions}
1402
- className={classNames("p-inputtext-sm w-full small-input flex boolean-switch", {
1403
- "p-invalid": isFormFieldValid(formik, "defaultValue"),
1404
- })}
1405
- />
1406
- }
1407
- {(selectedType.value === "date" || selectedType.value === "datetime" || selectedType.value === "time") &&
1408
- <Calendar
1409
- id="defaultValue"
1410
- name="defaultValue"
1411
- value={formik.values.defaultValue ? new Date(formik.values.defaultValue) : new Date()}
1412
- onChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Use setFieldValue for proper handling
1413
- showTime={formik.values.type === "datetime"} // Show time picker for datetime
1414
- timeOnly={formik.values.type === "time"} // Time-only for time
1415
- dateFormat="yy-mm-dd"
1416
- hourFormat="24" // 24-hour format for time
1417
- className={classNames("p-inputtext-sm w-full small-input", {
1418
- "p-invalid": isFormFieldValid(formik, "defaultValue"),
1419
- })}
1420
- />
1421
- }
1422
- {isFormFieldValid(formik, "defaultValue") && (
1423
- <Message
1424
- severity="error"
1425
- text={formik?.errors?.defaultValue?.toString()}
1426
- />
1427
- )}
1428
- </div>
1366
+ {(selectedType.value === "shortText" || selectedType.value === "longText" || selectedType.value === "richText" || selectedType.value === "json" || selectedType.value === "password" || selectedType.value === "selectionStatic") &&
1367
+ <InputText
1368
+ type="text"
1369
+ id="defaultValue"
1370
+ name="defaultValue"
1371
+ onChange={formik.handleChange}
1372
+ value={formik.values.defaultValue}
1373
+ className={classNames("", {
1374
+ "p-invalid": isFormFieldValid(
1375
+ formik,
1376
+ "defaultValue"
1377
+ ),
1378
+ })}
1379
+ />
1380
+ }
1381
+ {(selectedType.value === "float" || selectedType.value === "decimal") &&
1382
+ <InputNumber
1383
+ id="defaultValue"
1384
+ name="defaultValue"
1385
+ minFractionDigits={2}
1386
+ maxFractionDigits={5}
1387
+ value={formik.values.defaultValue}
1388
+ onValueChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Ensure correct value change handling
1389
+ className={classNames("", {
1390
+ "p-invalid": isFormFieldValid(formik, "defaultValue"),
1391
+ })}
1392
+ />
1393
+ }
1394
+ {(selectedType.value === "int" || selectedType.value === "bigint") &&
1395
+ <InputNumber
1396
+ id="defaultValue"
1397
+ name="defaultValue"
1398
+ value={formik.values.defaultValue}
1399
+ onValueChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Ensure correct value change handling
1400
+ className={classNames("", {
1401
+ "p-invalid": isFormFieldValid(formik, "defaultValue"),
1402
+ })}
1403
+ />
1404
+ }
1405
+ {selectedType.value === "boolean" &&
1406
+ <SelectButton
1407
+ value={formik.values.defaultValue ? formik.values.defaultValue : "false"}
1408
+ onChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Custom handling for boolean input
1409
+ options={booleanOptions}
1410
+ className={classNames(" flex boolean-switch", {
1411
+ "p-invalid": isFormFieldValid(formik, "defaultValue"),
1412
+ })}
1413
+ />
1414
+ }
1415
+ {(selectedType.value === "date" || selectedType.value === "datetime" || selectedType.value === "time") &&
1416
+ <Calendar
1417
+ id="defaultValue"
1418
+ name="defaultValue"
1419
+ value={formik.values.defaultValue ? new Date(formik.values.defaultValue) : new Date()}
1420
+ onChange={(e) => formik.setFieldValue("defaultValue", e.value)} // Use setFieldValue for proper handling
1421
+ showTime={formik.values.type === "datetime"} // Show time picker for datetime
1422
+ timeOnly={formik.values.type === "time"} // Time-only for time
1423
+ dateFormat="yy-mm-dd"
1424
+ hourFormat="24" // 24-hour format for time
1425
+ className={classNames("", {
1426
+ "p-invalid": isFormFieldValid(formik, "defaultValue"),
1427
+ })}
1428
+ />
1429
+ }
1430
+ {isFormFieldValid(formik, "defaultValue") && (
1431
+ <Message
1432
+ severity="error"
1433
+ text={formik?.errors?.defaultValue?.toString()}
1434
+ />
1435
+ )}
1429
1436
  </div>
1430
1437
  )}
1431
1438
 
1432
-
1433
-
1434
-
1435
-
1436
1439
  {currentFields.includes("mediaTypes") && (
1437
- <div className="md:col-6 sm:col-12">
1438
- <div className="field">
1439
- <label
1440
- htmlFor="mediaTypes"
1441
- className="form-label form-field-label"
1442
- >
1443
- Media Type
1444
- </label>
1445
- {/* <MultipleSelectAutoCompleteField
1440
+ <div className="field col-6 flex-flex-column gap-2">
1441
+ <label
1442
+ htmlFor="mediaTypes"
1443
+ className="form-field-label"
1444
+ >
1445
+ Media Type
1446
+ </label>
1447
+ {/* <MultipleSelectAutoCompleteField
1446
1448
  key="mediaTypes"
1447
1449
  formik={formik}
1448
1450
  isFormFieldValid={isFormFieldValid}
@@ -1454,7 +1456,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1454
1456
  existingData={formik.values.mediaTypes}
1455
1457
  /> */}
1456
1458
 
1457
- {/* {selectedType.value === "mediaSingle" &&
1459
+ {/* {selectedType.value === "mediaSingle" &&
1458
1460
  <SingleSelectAutoCompleteField
1459
1461
  key="mediaTypes"
1460
1462
  formik={formik}
@@ -1468,17 +1470,17 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1468
1470
  />
1469
1471
  } */}
1470
1472
 
1471
- {isFormFieldValid(formik, "mediaTypes") && (
1472
- <Message
1473
- severity="error"
1474
- text={formik?.errors?.mediaTypes?.toString()}
1475
- />
1476
- )}
1477
- <MultiSelect value={formik.values.mediaTypes} onChange={(e) => formik.setFieldValue("mediaTypes", e.value)} options={mediaTypesOptions} optionLabel="label"
1478
- placeholder="Select Media Types" maxSelectedLabels={3} display="chip" className="p-inputtext-sm w-full small-input" />
1473
+ {isFormFieldValid(formik, "mediaTypes") && (
1474
+ <Message
1475
+ severity="error"
1476
+ text={formik?.errors?.mediaTypes?.toString()}
1477
+ />
1478
+ )}
1479
+ <MultiSelect value={formik.values.mediaTypes} onChange={(e) => formik.setFieldValue("mediaTypes", e.value)} options={mediaTypesOptions} optionLabel="label"
1480
+ placeholder="Select Media Types" maxSelectedLabels={3} display="chip" className="" />
1479
1481
 
1480
1482
 
1481
- {/* <Dropdown
1483
+ {/* <Dropdown
1482
1484
  id="mediaTypes"
1483
1485
  name="mediaTypes"
1484
1486
  multiple
@@ -1488,7 +1490,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1488
1490
  formik.setFieldValue("mediaTypes", e.value)
1489
1491
  }
1490
1492
  placeholder="Select a Media Type"
1491
- className={classNames("p-inputtext-sm w-full small-input", {
1493
+ className={classNames("", {
1492
1494
  "p-invalid": isFormFieldValid(
1493
1495
  formik,
1494
1496
  "mediaTypes"
@@ -1497,127 +1499,119 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1497
1499
  /> */}
1498
1500
 
1499
1501
 
1500
- </div>
1501
1502
  </div>
1502
1503
  )}
1503
1504
  {currentFields.includes("mediaMaxSizeKb") && (
1504
- <div className="md:col-6 sm:col-12">
1505
- <div className="field">
1506
- <label
1507
- htmlFor="mediaMaxSizeKb"
1508
- className="form-label form-field-label"
1509
- >
1510
- Media Max Size (Mb)
1511
- </label>
1512
- <InputNumber
1513
- id="mediaMaxSizeKb"
1514
- name="mediaMaxSizeKb"
1515
- onValueChange={formik.handleChange}
1516
- value={formik.values.mediaMaxSizeKb}
1517
- className={classNames("p-inputtext-sm w-full small-input", {
1518
- "p-invalid": isFormFieldValid(
1519
- formik,
1520
- "mediaMaxSizeKb"
1521
- ),
1522
- })}
1523
- />
1505
+ <div className="field col-6 flex-flex-column gap-2">
1506
+ <label
1507
+ htmlFor="mediaMaxSizeKb"
1508
+ className="form-field-label"
1509
+ >
1510
+ Media Max Size (Mb)
1511
+ </label>
1512
+ <InputNumber
1513
+ id="mediaMaxSizeKb"
1514
+ name="mediaMaxSizeKb"
1515
+ onValueChange={formik.handleChange}
1516
+ value={formik.values.mediaMaxSizeKb}
1517
+ className={classNames("", {
1518
+ "p-invalid": isFormFieldValid(
1519
+ formik,
1520
+ "mediaMaxSizeKb"
1521
+ ),
1522
+ })}
1523
+ />
1524
1524
 
1525
- {isFormFieldValid(formik, "mediaMaxSizeKb") && (
1526
- <Message
1527
- severity="error"
1528
- text={formik?.errors?.mediaMaxSizeKb?.toString()}
1529
- />
1530
- )}
1531
- </div>
1525
+ {isFormFieldValid(formik, "mediaMaxSizeKb") && (
1526
+ <Message
1527
+ severity="error"
1528
+ text={formik?.errors?.mediaMaxSizeKb?.toString()}
1529
+ />
1530
+ )}
1532
1531
  </div>
1533
1532
  )}
1534
1533
  {currentFields.includes("mediaStorageProviderId") && (
1535
- <div className="md:col-6 sm:col-12">
1536
- <div className="field form-dropdown-select">
1537
- <label
1538
- htmlFor="mediaStorageProviderId"
1539
- className="form-label form-field-label"
1540
- >
1541
- Media Storage Provider
1542
- </label>
1534
+ <div className="field col-6 flex-flex-column gap-2 mt-3">
1535
+ <label
1536
+ htmlFor="mediaStorageProviderId"
1537
+ className="form-field-label"
1538
+ >
1539
+ Media Storage Provider
1540
+ </label>
1543
1541
 
1544
- <SingleSelectAutoCompleteField
1545
- key="mediaStorageProviderId"
1546
- formik={formik}
1547
- isFormFieldValid={isFormFieldValid}
1548
- relationField={true}
1549
- fieldName="mediaStorageProvider"
1550
- fieldNameId="mediaStorageProviderId"
1551
- labelKey="name"
1552
- valueKey="value"
1553
- searchData={searchMediaStorageProvIderId}
1554
- existingData={formik.values.mediaStorageProvider}
1555
- />
1542
+ <SingleSelectAutoCompleteField
1543
+ key="mediaStorageProviderId"
1544
+ formik={formik}
1545
+ isFormFieldValid={isFormFieldValid}
1546
+ relationField={true}
1547
+ fieldName="mediaStorageProvider"
1548
+ fieldNameId="mediaStorageProviderId"
1549
+ labelKey="name"
1550
+ valueKey="value"
1551
+ searchData={searchMediaStorageProvIderId}
1552
+ existingData={formik.values.mediaStorageProvider}
1553
+ />
1556
1554
 
1557
- {isFormFieldValid(
1558
- formik,
1559
- "mediaStorageProvider"
1560
- ) && (
1561
- <Message
1562
- severity="error"
1563
- text={formik?.errors?.mediaStorageProviderId?.toString()}
1564
- />
1565
- )}
1566
- </div>
1555
+ {isFormFieldValid(
1556
+ formik,
1557
+ "mediaStorageProvider"
1558
+ ) && (
1559
+ <Message
1560
+ severity="error"
1561
+ text={formik?.errors?.mediaStorageProviderId?.toString()}
1562
+ />
1563
+ )}
1567
1564
  </div>
1568
1565
  )}
1569
1566
 
1570
1567
  {currentFields.includes("mediaEmbedded") && (
1571
- <div className="md:col-6 sm:col-12">
1572
- <div className="field">
1573
- <label
1574
- htmlFor="mediaEmbedded"
1575
- className="form-label form-field-label"
1576
- >
1577
- Media Embedded
1578
- </label>
1579
- {/* <InputText
1568
+ <div className="field col-6 flex-flex-column gap-2">
1569
+ <label
1570
+ htmlFor="mediaEmbedded"
1571
+ className="form-field-label"
1572
+ >
1573
+ Media Embedded
1574
+ </label>
1575
+ {/* <InputText
1580
1576
  type="text"
1581
1577
  id="mediaEmbedded"
1582
1578
  name="mediaEmbedded"
1583
1579
  onChange={formik.handleChange}
1584
1580
  value={formik.values.mediaEmbedded}
1585
- className={classNames("p-inputtext-sm w-full small-input", {
1581
+ className={classNames("", {
1586
1582
  "p-invalid": isFormFieldValid(
1587
1583
  formik,
1588
1584
  "mediaEmbedded"
1589
1585
  ),
1590
1586
  })}
1591
1587
  /> */}
1592
- <SelectButton
1593
- value={formik.values.mediaEmbedded}
1594
- // onChange={formik.handleChange}
1595
- onChange={(e) => {
1596
- formik.setFieldValue("mediaEmbedded", e.value);
1597
- }}
1598
- options={booleanOptions}
1599
- className={classNames("p-inputtext-sm w-full small-input flex boolean-switch", {
1600
- "p-invalid": isFormFieldValid(
1601
- formik,
1602
- "mediaEmbedded"
1603
- ),
1604
- })}
1588
+ <SelectButton
1589
+ value={formik.values.mediaEmbedded}
1590
+ // onChange={formik.handleChange}
1591
+ onChange={(e) => {
1592
+ formik.setFieldValue("mediaEmbedded", e.value);
1593
+ }}
1594
+ options={booleanOptions}
1595
+ className={classNames(" flex boolean-switch", {
1596
+ "p-invalid": isFormFieldValid(
1597
+ formik,
1598
+ "mediaEmbedded"
1599
+ ),
1600
+ })}
1601
+ />
1602
+ {isFormFieldValid(formik, "mediaEmbedded") && (
1603
+ <Message
1604
+ severity="error"
1605
+ text={formik?.errors?.mediaEmbedded?.toString()}
1605
1606
  />
1606
- {isFormFieldValid(formik, "mediaEmbedded") && (
1607
- <Message
1608
- severity="error"
1609
- text={formik?.errors?.mediaEmbedded?.toString()}
1610
- />
1611
- )}
1612
- </div>
1607
+ )}
1613
1608
  </div>
1614
1609
  )}
1615
1610
  {currentFields.includes("relationType") && (
1616
- <div className="md:col-6 sm:col-12">
1617
- <div className="field">
1618
- {/* <label
1611
+ <div className="field col-6 flex-flex-column gap-2">
1612
+ {/* <label
1619
1613
  htmlFor="relationType"
1620
- className="form-label form-field-label"
1614
+ className="form-field-label"
1621
1615
  >
1622
1616
  Relation Type
1623
1617
  </label>
@@ -1630,7 +1624,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1630
1624
  formik.setFieldValue("relationType", e.value)
1631
1625
  }
1632
1626
  placeholder="Select a Data Source"
1633
- className={classNames("p-inputtext-sm w-full small-input", {
1627
+ className={classNames("", {
1634
1628
  "p-invalid": isFormFieldValid(
1635
1629
  formik,
1636
1630
  "relationType"
@@ -1638,25 +1632,25 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1638
1632
  })}
1639
1633
  /> */}
1640
1634
 
1641
- <label
1642
- htmlFor="relationType"
1643
- className="form-label form-field-label "
1644
- >
1645
- Relation Type
1646
- </label>
1647
- <SelectButton
1648
- value={formik.values.relationType}
1649
- options={fieldDefaultMetaData.data.relationTypes}
1650
- onChange={(e) =>
1651
- formik.setFieldValue("relationType", e.value)
1652
- }
1653
- className={classNames("p-inputtext-sm w-full small-input flex boolean-switch", {
1654
- "p-invalid": isFormFieldValid(formik, "relationType"),
1655
- })}
1656
- optionLabel="label"
1657
- />
1635
+ <label
1636
+ htmlFor="relationType"
1637
+ className="form-field-label "
1638
+ >
1639
+ Relation Type
1640
+ </label>
1641
+ <SelectButton
1642
+ value={formik.values.relationType}
1643
+ options={fieldDefaultMetaData.data.relationTypes}
1644
+ onChange={(e) =>
1645
+ formik.setFieldValue("relationType", e.value)
1646
+ }
1647
+ className={classNames(" flex boolean-switch", {
1648
+ "p-invalid": isFormFieldValid(formik, "relationType"),
1649
+ })}
1650
+ optionLabel="label"
1651
+ />
1658
1652
 
1659
- {/* <div className="align-items-center">
1653
+ {/* <div className="align-items-center">
1660
1654
  <div className="flex mt-3">
1661
1655
  {fieldDefaultMetaData?.data?.relationTypes.map((i: any) => (
1662
1656
  <div key={i.value} className="mr-3">
@@ -1667,162 +1661,152 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1667
1661
  onChange={(e) => formik.setFieldValue("relationType", e.value)}
1668
1662
  checked={formik.values.relationType === i.value}
1669
1663
  />
1670
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">{i.value}</label>
1664
+ <label htmlFor="ingredient1" className="form-field-label ml-2">{i.value}</label>
1671
1665
  </div>
1672
1666
  ))}
1673
1667
  </div>
1674
1668
  </div> */}
1675
1669
 
1676
- {isFormFieldValid(formik, "relationType") && (
1677
- <Message
1678
- severity="error"
1679
- text={formik?.errors?.relationType?.toString()}
1680
- />
1681
- )}
1682
- </div>
1670
+ {isFormFieldValid(formik, "relationType") && (
1671
+ <Message
1672
+ severity="error"
1673
+ text={formik?.errors?.relationType?.toString()}
1674
+ />
1675
+ )}
1683
1676
  </div>
1684
1677
  )}
1685
1678
  {currentFields.includes("relationType") && formik.values.relationType === "many-to-one" && (
1686
- <div className="md:col-6 sm:col-12">
1687
- <div className="field">
1688
- <label
1689
- htmlFor="relationCascade"
1690
- className="form-label form-field-label"
1691
- >
1692
- Relation Cascade
1693
- </label>
1694
- <Dropdown
1695
- id="relationCascade"
1696
- name="relationCascade"
1697
- value={formik.values.relationCascade}
1698
- options={fieldDefaultMetaData.data.cascadeTypes}
1699
- onChange={(e) =>
1700
- formik.setFieldValue(
1701
- "relationCascade",
1702
- e.value
1703
- )
1704
- }
1705
- placeholder="Cascade"
1706
- className={classNames("small-input p-inputtext-sm w-full", {
1707
- "p-invalid": isFormFieldValid(
1708
- formik,
1709
- "relationCascade"
1710
- ),
1711
- })}
1679
+ <div className="field col-6 flex-flex-column gap-2">
1680
+ <label
1681
+ htmlFor="relationCascade"
1682
+ className="form-field-label"
1683
+ >
1684
+ Relation Cascade
1685
+ </label>
1686
+ <Dropdown
1687
+ id="relationCascade"
1688
+ name="relationCascade"
1689
+ value={formik.values.relationCascade}
1690
+ options={fieldDefaultMetaData.data.cascadeTypes}
1691
+ onChange={(e) =>
1692
+ formik.setFieldValue(
1693
+ "relationCascade",
1694
+ e.value
1695
+ )
1696
+ }
1697
+ placeholder="Cascade"
1698
+ className={classNames("small-input p-inputtext-sm w-full", {
1699
+ "p-invalid": isFormFieldValid(
1700
+ formik,
1701
+ "relationCascade"
1702
+ ),
1703
+ })}
1704
+ />
1705
+ {isFormFieldValid(formik, "relationCascade") && (
1706
+ <Message
1707
+ severity="error"
1708
+ text={formik?.errors?.relationCascade?.toString()}
1712
1709
  />
1713
- {isFormFieldValid(formik, "relationCascade") && (
1714
- <Message
1715
- severity="error"
1716
- text={formik?.errors?.relationCascade?.toString()}
1717
- />
1718
- )}
1719
- </div>
1710
+ )}
1720
1711
  </div>
1721
1712
  )}
1722
1713
 
1723
1714
 
1724
1715
  {currentFields.includes("relationModelFieldName") && formik.values.relationType === "many-to-many" && (
1725
- <div className="md:col-6 sm:col-12">
1726
- <div className="field">
1727
- <label
1728
- htmlFor="relationModelFieldName"
1729
- className="form-label form-field-label"
1730
- >
1731
- Relation Model Field Name
1732
- </label>
1733
- <InputText
1734
- type="text"
1735
- id="relationModelFieldName"
1736
- name="relationModelFieldName"
1737
- onChange={formik.handleChange}
1738
- value={formik.values.relationModelFieldName}
1739
- className={classNames("p-inputtext-sm w-full small-input", {
1740
- "p-invalid": isFormFieldValid(
1741
- formik,
1742
- "relationModelFieldName"
1743
- ),
1744
- })}
1716
+ <div className="field col-6 flex-flex-column gap-2">
1717
+ <label
1718
+ htmlFor="relationModelFieldName"
1719
+ className="form-field-label"
1720
+ >
1721
+ Relation Model Field Name
1722
+ </label>
1723
+ <InputText
1724
+ type="text"
1725
+ id="relationModelFieldName"
1726
+ name="relationModelFieldName"
1727
+ onChange={formik.handleChange}
1728
+ value={formik.values.relationModelFieldName}
1729
+ className={classNames("", {
1730
+ "p-invalid": isFormFieldValid(
1731
+ formik,
1732
+ "relationModelFieldName"
1733
+ ),
1734
+ })}
1735
+ />
1736
+ {isFormFieldValid(formik, "relationModelFieldName") && (
1737
+ <Message
1738
+ severity="error"
1739
+ text={formik?.errors?.relationModelFieldName?.toString()}
1745
1740
  />
1746
- {isFormFieldValid(formik, "relationModelFieldName") && (
1747
- <Message
1748
- severity="error"
1749
- text={formik?.errors?.relationModelFieldName?.toString()}
1750
- />
1751
- )}
1741
+ )}
1752
1742
 
1753
- </div>
1754
1743
  </div>
1755
1744
  )}
1756
1745
 
1757
1746
 
1758
1747
  {currentFields.includes("relationCreateInverse") && formik.values.relationType === "many-to-many" && (
1759
- <div className="md:col-6 sm:col-12">
1760
- <div className="field">
1761
- <label
1762
- htmlFor="relationCreateInverse"
1763
- className="form-label form-field-label"
1764
- >
1765
- Relation Create Inverse
1766
- </label>
1767
- <Dropdown
1768
- id="relationCreateInverse"
1769
- name="relationCreateInverse"
1770
- value={formik.values.relationCreateInverse}
1771
- options={relationCreateInverses}
1772
- onChange={(e) =>
1773
- formik.setFieldValue(
1774
- "relationCreateInverse",
1775
- e.value
1776
- )
1777
- }
1778
- placeholder="Select a Data Source"
1779
- className={classNames("p-inputtext-sm w-full small-input", {
1780
- "p-invalid": isFormFieldValid(
1781
- formik,
1782
- "relationCreateInverse"
1783
- ),
1784
- })}
1785
- />
1786
- {isFormFieldValid(
1787
- formik,
1788
- "relationCreateInverse"
1789
- ) && (
1790
- <Message
1791
- severity="error"
1792
- text={formik?.errors?.relationCreateInverse?.toString()}
1793
- />
1794
- )}
1795
- </div>
1748
+ <div className="field col-6 flex-flex-column gap-2">
1749
+ <label
1750
+ htmlFor="relationCreateInverse"
1751
+ className="form-field-label"
1752
+ >
1753
+ Relation Create Inverse
1754
+ </label>
1755
+ <Dropdown
1756
+ id="relationCreateInverse"
1757
+ name="relationCreateInverse"
1758
+ value={formik.values.relationCreateInverse}
1759
+ options={relationCreateInverses}
1760
+ onChange={(e) =>
1761
+ formik.setFieldValue(
1762
+ "relationCreateInverse",
1763
+ e.value
1764
+ )
1765
+ }
1766
+ placeholder="Select a Data Source"
1767
+ className={classNames("", {
1768
+ "p-invalid": isFormFieldValid(
1769
+ formik,
1770
+ "relationCreateInverse"
1771
+ ),
1772
+ })}
1773
+ />
1774
+ {isFormFieldValid(
1775
+ formik,
1776
+ "relationCreateInverse"
1777
+ ) && (
1778
+ <Message
1779
+ severity="error"
1780
+ text={formik?.errors?.relationCreateInverse?.toString()}
1781
+ />
1782
+ )}
1796
1783
  </div>
1797
1784
  )}
1798
1785
 
1799
1786
 
1800
- <div className="md:col-12 sm:col-12">
1801
- <div className="grid p-nogutter">
1802
- {currentFields.includes("relationModelModuleName") && (
1803
- <div className="md:col-6 sm:col-12">
1804
- <div className="field">
1805
- <label
1806
- htmlFor="relationModelModuleName"
1807
- className="form-label form-field-label"
1808
- >
1809
- Relation Model Module Name
1810
- </label>
1787
+ {currentFields.includes("relationModelModuleName") && (
1788
+ <div className="field col-6 flex-flex-column gap-2">
1789
+ <label
1790
+ htmlFor="relationModelModuleName"
1791
+ className="form-field-label"
1792
+ >
1793
+ Relation Model Module Name
1794
+ </label>
1811
1795
 
1812
- <SingleSelectAutoCompleteField
1813
- key="relationModelModuleName"
1814
- formik={formik}
1815
- isFormFieldValid={isFormFieldValid}
1816
- fieldName="relationModelModuleName"
1817
- fieldNameId="relationModelModuleName"
1818
- labelKey="name"
1819
- valueKey="name"
1820
- searchData={searchRelationModelModuleNames}
1821
- existingData={formik.values.relationModelModuleName}
1822
- additionalAction={(e: any) => formik.setFieldValue("relationModelSingularName", "")}
1823
- />
1796
+ <SingleSelectAutoCompleteField
1797
+ key="relationModelModuleName"
1798
+ formik={formik}
1799
+ isFormFieldValid={isFormFieldValid}
1800
+ fieldName="relationModelModuleName"
1801
+ fieldNameId="relationModelModuleName"
1802
+ labelKey="name"
1803
+ valueKey="name"
1804
+ searchData={searchRelationModelModuleNames}
1805
+ existingData={formik.values.relationModelModuleName}
1806
+ additionalAction={(e: any) => formik.setFieldValue("relationModelSingularName", "")}
1807
+ />
1824
1808
 
1825
- {/* <AutoComplete
1809
+ {/* <AutoComplete
1826
1810
  value={selectedRelationModelModuleName}
1827
1811
  suggestions={filteredRelationModelModuleNames}
1828
1812
  invalid={isFormFieldValid(
@@ -1843,101 +1827,92 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1843
1827
  }}
1844
1828
  /> */}
1845
1829
 
1846
- {isFormFieldValid(
1847
- formik,
1848
- "relationModelModuleName"
1849
- ) && (
1850
- <Message
1851
- severity="error"
1852
- text={formik?.errors?.relationModelModuleName?.toString()}
1853
- />
1854
- )}
1855
- </div>
1856
- </div>
1857
- )}
1858
-
1859
- {currentFields.includes(
1860
- "relationModelSingularName"
1830
+ {isFormFieldValid(
1831
+ formik,
1832
+ "relationModelModuleName"
1861
1833
  ) && (
1862
- <div className="md:col-6 sm:col-12">
1863
- <div className="field">
1864
- <label
1865
- htmlFor="relationModelSingularName"
1866
- className="form-label form-field-label"
1867
- >
1868
- Relation Model Singular Name
1869
- </label>
1834
+ <Message
1835
+ severity="error"
1836
+ text={formik?.errors?.relationModelModuleName?.toString()}
1837
+ />
1838
+ )}
1839
+ </div>
1840
+ )}
1841
+
1842
+ {currentFields.includes(
1843
+ "relationModelSingularName"
1844
+ ) && (
1845
+ <div className="field col-6 flex-flex-column gap-2">
1846
+ <label
1847
+ htmlFor="relationModelSingularName"
1848
+ className="form-field-label"
1849
+ >
1850
+ Relation Model Singular Name
1851
+ </label>
1870
1852
 
1871
1853
 
1872
- <SingleSelectAutoCompleteField
1873
- key="relationModelSingularName"
1874
- formik={formik}
1875
- isFormFieldValid={isFormFieldValid}
1876
- fieldName="relationModelSingularName"
1877
- fieldNameId="relationModelSingularName"
1878
- labelKey="displayName"
1879
- valueKey="singularName"
1880
- searchData={searchRelationModelSingularNames}
1881
- existingData={formik.values.relationModelSingularName}
1882
- />
1854
+ <SingleSelectAutoCompleteField
1855
+ key="relationModelSingularName"
1856
+ formik={formik}
1857
+ isFormFieldValid={isFormFieldValid}
1858
+ fieldName="relationModelSingularName"
1859
+ fieldNameId="relationModelSingularName"
1860
+ labelKey="displayName"
1861
+ valueKey="singularName"
1862
+ searchData={searchRelationModelSingularNames}
1863
+ existingData={formik.values.relationModelSingularName}
1864
+ />
1883
1865
 
1884
- {/* <InputText
1866
+ {/* <InputText
1885
1867
  type="text"
1886
1868
  id="relationModelSingularName"
1887
1869
  name="relationModelSingularName"
1888
1870
  onChange={formik.handleChange}
1889
1871
  value={formik.values.relationModelSingularName}
1890
- className={classNames("p-inputtext-sm w-full small-input", {
1872
+ className={classNames("", {
1891
1873
  "p-invalid": isFormFieldValid(
1892
1874
  formik,
1893
1875
  "relationModelSingularName"
1894
1876
  ),
1895
1877
  })}
1896
1878
  /> */}
1897
- {isFormFieldValid(
1898
- formik,
1899
- "relationModelSingularName"
1900
- ) && (
1901
- <Message
1902
- severity="error"
1903
- text={formik?.errors?.relationModelSingularName?.toString()}
1904
- />
1905
- )}
1906
- </div>
1907
- </div>
1908
- )}
1909
-
1910
-
1911
- </div>
1912
- </div>
1913
-
1914
-
1915
- {currentFields.includes("selectionDynamicProvider") && (
1916
- <div className="md:col-6 sm:col-12">
1917
- <div className="field">
1918
- <label
1919
- htmlFor="selectionDynamicProvider"
1920
- className="form-label form-field-label"
1921
- >
1922
- Selection Dynamic Provider
1923
- </label>
1879
+ {isFormFieldValid(
1880
+ formik,
1881
+ "relationModelSingularName"
1882
+ ) && (
1883
+ <Message
1884
+ severity="error"
1885
+ text={formik?.errors?.relationModelSingularName?.toString()}
1886
+ />
1887
+ )}
1888
+ </div>
1889
+ )}
1924
1890
 
1925
- <SingleSelectAutoCompleteField
1926
- key="selectionDynamicProvider"
1927
- formik={formik}
1928
- isFormFieldValid={isFormFieldValid}
1929
- // relationField={false}
1930
- fieldName="selectionDynamicProvider"
1931
- fieldNameId={null}
1932
- labelKey="label"
1933
- valueKey="value"
1934
- searchData={searchSelectionDynamicProvider}
1935
- existingData={formik.values.selectionDynamicProvider}
1936
- additionalAction={(e: any) => setMarkdownText(e.target.value.help)}
1937
- />
1891
+ {currentFields.includes("selectionDynamicProvider") && (
1892
+ <div className="field col-6 flex-flex-column gap-2">
1893
+ <label
1894
+ htmlFor="selectionDynamicProvider"
1895
+ className="form-field-label"
1896
+ >
1897
+ Selection Dynamic Provider
1898
+ </label>
1899
+
1900
+ <SingleSelectAutoCompleteField
1901
+ key="selectionDynamicProvider"
1902
+ formik={formik}
1903
+ isFormFieldValid={isFormFieldValid}
1904
+ // relationField={false}
1905
+ fieldName="selectionDynamicProvider"
1906
+ fieldNameId={null}
1907
+ labelKey="label"
1908
+ valueKey="value"
1909
+ searchData={searchSelectionDynamicProvider}
1910
+ existingData={formik.values.selectionDynamicProvider}
1911
+ additionalAction={(e: any) => setMarkdownText(e.target.value.help)}
1912
+ />
1938
1913
 
1939
1914
 
1940
- {/* <AutoComplete
1915
+ {/* <AutoComplete
1941
1916
  value={selectionDynamicProvider}
1942
1917
  suggestions={filteredSelectionDynamicProvider}
1943
1918
  invalid={isFormFieldValid(
@@ -1958,69 +1933,65 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
1958
1933
  }}
1959
1934
  /> */}
1960
1935
 
1961
- {isFormFieldValid(
1962
- formik,
1963
- "selectionDynamicProvider"
1964
- ) && (
1965
- <Message
1966
- severity="error"
1967
- text={formik?.errors?.selectionDynamicProvider?.toString()}
1968
- />
1969
- )}
1970
- </div>
1936
+ {isFormFieldValid(
1937
+ formik,
1938
+ "selectionDynamicProvider"
1939
+ ) && (
1940
+ <Message
1941
+ severity="error"
1942
+ text={formik?.errors?.selectionDynamicProvider?.toString()}
1943
+ />
1944
+ )}
1971
1945
  </div>
1972
1946
  )}
1973
1947
  {currentFields.includes("selectionValueType") && (
1974
- <div className="md:col-6 sm:col-12">
1975
- <div className="field form-dropdown-select">
1976
- <label
1977
- htmlFor="selectionValueType"
1978
- className="form-label form-field-label"
1979
- >
1980
- Selection Value Type
1981
- </label>
1982
- <Dropdown
1983
- id="selectionValueType"
1984
- name="selectionValueType"
1985
- value={formik.values.selectionValueType}
1986
- options={selctionValueTypes}
1987
- onChange={(e) =>
1988
- formik.setFieldValue(
1989
- "selectionValueType",
1990
- e.value
1991
- )
1992
- }
1993
- placeholder="Select a Data Source"
1994
- className={classNames("p-inputtext-sm w-full small-input", {
1995
- "p-invalid": isFormFieldValid(
1996
- formik,
1997
- "selectionValueType"
1998
- ),
1999
- })}
2000
- />
2001
- {isFormFieldValid(
2002
- formik,
2003
- "selectionValueType"
2004
- ) && (
2005
- <Message
2006
- severity="error"
2007
- text={formik?.errors?.selectionValueType?.toString()}
2008
- />
2009
- )}
2010
- </div>
1948
+ <div className="field col-6 flex-flex-column gap-2">
1949
+ <label
1950
+ htmlFor="selectionValueType"
1951
+ className="form-field-label"
1952
+ >
1953
+ Selection Value Type
1954
+ </label>
1955
+ <Dropdown
1956
+ id="selectionValueType"
1957
+ name="selectionValueType"
1958
+ value={formik.values.selectionValueType}
1959
+ options={selctionValueTypes}
1960
+ onChange={(e) =>
1961
+ formik.setFieldValue(
1962
+ "selectionValueType",
1963
+ e.value
1964
+ )
1965
+ }
1966
+ placeholder="Select a Data Source"
1967
+ className={classNames("", {
1968
+ "p-invalid": isFormFieldValid(
1969
+ formik,
1970
+ "selectionValueType"
1971
+ ),
1972
+ })}
1973
+ />
1974
+ {isFormFieldValid(
1975
+ formik,
1976
+ "selectionValueType"
1977
+ ) && (
1978
+ <Message
1979
+ severity="error"
1980
+ text={formik?.errors?.selectionValueType?.toString()}
1981
+ />
1982
+ )}
2011
1983
  </div>
2012
1984
  )}
2013
1985
 
2014
1986
  {currentFields.includes("selectionStaticValues") && (
2015
- <div className="md:col-6 sm:col-12">
2016
- <div className="field">
2017
- <label
2018
- htmlFor="selectionStaticValues"
2019
- className="form-label form-field-label"
2020
- >
2021
- Selection Static Values
2022
- </label>
2023
- {/* <InputTextarea
1987
+ <div className="field col-6 flex-flex-column gap-2">
1988
+ <label
1989
+ htmlFor="selectionStaticValues"
1990
+ className="form-field-label"
1991
+ >
1992
+ Selection Static Values
1993
+ </label>
1994
+ {/* <InputTextarea
2024
1995
  value={selectionStaticValues}
2025
1996
  placeholder="male:Male"
2026
1997
  onChange={(e) => {
@@ -2037,54 +2008,52 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2037
2008
  rows={5}
2038
2009
  cols={30}
2039
2010
  /> */}
2040
- {formik.values.selectionStaticValues.map((enumValue: string, index: number) => (
2041
- <SelectionStaticValues
2042
- key={index}
2043
- enumValue={enumValue}
2044
- onUpdate={(updatedString: any) => updateEnumValues(index, updatedString)}
2045
- onDelete={() => deleteEnumValue(index)}
2046
- onAdd={addEnumValue}
2011
+ {formik.values.selectionStaticValues.map((enumValue: string, index: number) => (
2012
+ <SelectionStaticValues
2013
+ key={index}
2014
+ enumValue={enumValue}
2015
+ onUpdate={(updatedString: any) => updateEnumValues(index, updatedString)}
2016
+ onDelete={() => deleteEnumValue(index)}
2017
+ onAdd={addEnumValue}
2018
+ />
2019
+ ))
2020
+ }
2021
+ {isFormFieldValid(
2022
+ formik,
2023
+ "selectionStaticValues"
2024
+ ) && (
2025
+ <Message
2026
+ severity="error"
2027
+ text={formik?.errors?.selectionStaticValues?.toString()}
2047
2028
  />
2048
- ))
2049
- }
2050
- {isFormFieldValid(
2051
- formik,
2052
- "selectionStaticValues"
2053
- ) && (
2054
- <Message
2055
- severity="error"
2056
- text={formik?.errors?.selectionStaticValues?.toString()}
2057
- />
2058
- )}
2059
- </div>
2029
+ )}
2060
2030
  </div>
2061
2031
  )}
2062
2032
  {currentFields.includes("computedFieldValueType") && (
2063
- <div className="md:col-6 sm:col-12">
2064
- <div className="field">
2065
- <label
2066
- htmlFor="computedFieldValueType"
2067
- className="form-label form-field-label"
2068
- >
2069
- Computed Field Value Type
2070
- </label>
2071
- <AutoComplete
2033
+ <div className="field col-6 flex-flex-column gap-2">
2034
+ <label
2035
+ htmlFor="computedFieldValueType"
2036
+ className="form-field-label"
2037
+ >
2038
+ Computed Field Value Type
2039
+ </label>
2040
+ <AutoComplete
2072
2041
 
2073
- value={selectedComputedFieldValueType}
2074
- invalid={isFormFieldValid(formik, "computedFieldValueType")}
2075
- suggestions={filteredComputedFieldValueTypes}
2076
- completeMethod={searchComputedFieldValueType}
2077
- virtualScrollerOptions={{ itemSize: 38 }}
2078
- field="label"
2079
- dropdown
2080
- className="small-input"
2081
- onChange={(e) => {
2082
- setSelectedComputedFieldValueType(e.value);
2083
- formik.setFieldValue("computedFieldValueType", e.value.value);
2084
- }}
2085
- />
2042
+ value={selectedComputedFieldValueType}
2043
+ invalid={isFormFieldValid(formik, "computedFieldValueType")}
2044
+ suggestions={filteredComputedFieldValueTypes}
2045
+ completeMethod={searchComputedFieldValueType}
2046
+ virtualScrollerOptions={{ itemSize: 38 }}
2047
+ field="label"
2048
+ dropdown
2049
+ className="small-input"
2050
+ onChange={(e) => {
2051
+ setSelectedComputedFieldValueType(e.value);
2052
+ formik.setFieldValue("computedFieldValueType", e.value.value);
2053
+ }}
2054
+ />
2086
2055
 
2087
- {/* <Dropdown
2056
+ {/* <Dropdown
2088
2057
  id="mediaTypes"
2089
2058
  name="mediaTypes"
2090
2059
  value={formik.values.mediaTypes}
@@ -2093,80 +2062,77 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2093
2062
  formik.setFieldValue("mediaTypes", e.value)
2094
2063
  }
2095
2064
  placeholder="Select a Data Source"
2096
- className={classNames("p-inputtext-sm w-full small-input", {
2065
+ className={classNames("", {
2097
2066
  "p-invalid": isFormFieldValid(
2098
2067
  formik,
2099
2068
  "mediaTypes"
2100
2069
  ),
2101
2070
  })}
2102
2071
  /> */}
2103
- {isFormFieldValid(formik, "computedFieldValueType") && (
2104
- <Message
2105
- severity="error"
2106
- text={formik?.errors?.computedFieldValueType?.toString()}
2107
- />
2108
- )}
2109
- </div>
2072
+ {isFormFieldValid(formik, "computedFieldValueType") && (
2073
+ <Message
2074
+ severity="error"
2075
+ text={formik?.errors?.computedFieldValueType?.toString()}
2076
+ />
2077
+ )}
2110
2078
  </div>
2111
2079
  )}
2112
2080
 
2113
2081
  {currentFields.includes(
2114
2082
  "computedFieldValueProvider"
2115
2083
  ) && (
2116
- <div className="md:col-6 sm:col-12">
2117
- <div className="field">
2118
- <label
2119
- htmlFor="computedFieldValueProvider"
2120
- className="form-label form-field-label"
2121
- >
2122
- Computed Field Provider
2123
- </label>
2084
+ <div className="field col-6 flex-flex-column gap-2">
2085
+ <label
2086
+ htmlFor="computedFieldValueProvider"
2087
+ className="form-field-label"
2088
+ >
2089
+ Computed Field Provider
2090
+ </label>
2124
2091
 
2125
- <SingleSelectAutoCompleteField
2126
- key="computedFieldValueProvider"
2127
- formik={formik}
2128
- isFormFieldValid={isFormFieldValid}
2129
- // relationField={false}
2130
- fieldName="computedFieldValueProvider"
2131
- fieldNameId={null}
2132
- labelKey="label"
2133
- valueKey="value"
2134
- searchData={searchComputedProvider}
2135
- existingData={formik.values.computedFieldValueProvider}
2136
- additionalAction={(e: any) => setMarkdownText(e.target.value.help)}
2092
+ <SingleSelectAutoCompleteField
2093
+ key="computedFieldValueProvider"
2094
+ formik={formik}
2095
+ isFormFieldValid={isFormFieldValid}
2096
+ // relationField={false}
2097
+ fieldName="computedFieldValueProvider"
2098
+ fieldNameId={null}
2099
+ labelKey="label"
2100
+ valueKey="value"
2101
+ searchData={searchComputedProvider}
2102
+ existingData={formik.values.computedFieldValueProvider}
2103
+ additionalAction={(e: any) => setMarkdownText(e.target.value.help)}
2137
2104
 
2138
- />
2139
- {/* <InputText
2105
+ />
2106
+ {/* <InputText
2140
2107
  type="text"
2141
2108
  id="computedFieldValueProvider"
2142
2109
  name="computedFieldValueProvider"
2143
2110
  onChange={formik.handleChange}
2144
2111
  value={formik.values.computedFieldValueProvider}
2145
- className={classNames("p-inputtext-sm w-full small-input", {
2112
+ className={classNames("", {
2146
2113
  "p-invalid": isFormFieldValid(
2147
2114
  formik,
2148
2115
  "computedFieldValueProvider"
2149
2116
  ),
2150
2117
  })}
2151
2118
  /> */}
2152
- {isFormFieldValid(
2153
- formik,
2154
- "computedFieldValueProvider"
2155
- ) && (
2156
- <Message
2157
- severity="error"
2158
- text={formik?.errors?.computedFieldValueProvider?.toString()}
2159
- />
2160
- )}
2161
- </div>
2119
+ {isFormFieldValid(
2120
+ formik,
2121
+ "computedFieldValueProvider"
2122
+ ) && (
2123
+ <Message
2124
+ severity="error"
2125
+ text={formik?.errors?.computedFieldValueProvider?.toString()}
2126
+ />
2127
+ )}
2162
2128
  </div>
2163
2129
  )}
2164
2130
  {/* {currentFields.includes("externalIdProvider") && (
2165
2131
  <div className="md:col-6 sm:col-12">
2166
- <div className="field">
2132
+ <div className="field col-6 flex-flex-column gap-2">
2167
2133
  <label
2168
2134
  htmlFor="externalIdProvider"
2169
- className="form-label form-field-label"
2135
+ className="form-field-label"
2170
2136
  >
2171
2137
  External Id Provider
2172
2138
  </label>
@@ -2199,98 +2165,72 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2199
2165
  )} */}
2200
2166
 
2201
2167
  {currentFields.includes("selectionDynamicProviderCtxt") && (
2202
- <div className="md:col-12 sm:col-12">
2203
-
2204
- <div className="grid p-nogutter">
2205
- {/* {markdownText &&
2206
- <div className="md:col-12 sm:col-12">
2207
- <div className="field">
2208
- <label htmlFor="name" className="form-label form-field-label">
2209
- Markdown
2210
- </label>
2211
- <MarkdownViewer data={markdownText}></MarkdownViewer>
2212
- </div>
2213
- </div>
2214
- } */}
2215
-
2216
- <div className="md:col-12 sm:col-12">
2217
- <div className="field">
2218
- <label htmlFor="selectionDynamicProviderCtxt" className="form-label form-field-label">
2219
- Selection Dynamic Provider Context
2220
- </label>
2221
- <CodeEditor
2222
- formik={formik}
2223
- field="selectionDynamicProviderCtxt" >
2224
- </CodeEditor>
2225
- <div className=" form-field-label mt-4">{markdownText}</div>
2226
-
2227
- {isFormFieldValid(
2228
- formik,
2229
- "selectionDynamicProviderCtxt"
2230
- ) && (
2231
- <Message
2232
- severity="error"
2233
- text={formik?.errors?.selectionDynamicProviderCtxt?.toString()}
2234
- />
2235
- )}
2236
- </div>
2237
- </div>
2238
- {/* {currentFields.includes("markdown") && ( */}
2168
+ // {/* {markdownText &&
2169
+ // <div className="md:col-12 sm:col-12">
2170
+ // <div className="field col-6 flex-flex-column gap-2">
2171
+ // <label htmlFor="name" className="form-field-label">
2172
+ // Markdown
2173
+ // </label>
2174
+ // <MarkdownViewer data={markdownText}></MarkdownViewer>
2175
+ // </div>
2176
+ // </div>
2177
+ // } */}
2178
+
2179
+ <div className="field col-12 flex-flex-column gap-2 mt-4">
2180
+ <label htmlFor="selectionDynamicProviderCtxt" className="form-field-label">
2181
+ Selection Dynamic Provider Context
2182
+ </label>
2183
+ <CodeEditor
2184
+ formik={formik}
2185
+ field="selectionDynamicProviderCtxt" >
2186
+ </CodeEditor>
2187
+ <div className=" form-field-label mt-4">{markdownText}</div>
2239
2188
 
2240
- </div>
2189
+ {isFormFieldValid(
2190
+ formik,
2191
+ "selectionDynamicProviderCtxt"
2192
+ ) && (
2193
+ <Message
2194
+ severity="error"
2195
+ text={formik?.errors?.selectionDynamicProviderCtxt?.toString()}
2196
+ />
2197
+ )}
2241
2198
  </div>
2199
+ // {/* {currentFields.includes("markdown") && ( */}
2200
+
2242
2201
  )}
2243
2202
 
2244
2203
  {currentFields.includes("computedFieldValueProviderCtxt") && (
2245
- <div className="md:col-12 sm:col-12">
2246
-
2247
- <div className="grid p-nogutter">
2248
- {/* {markdownText &&
2249
- <div className="md:col-12 sm:col-12">
2250
- <div className="field">
2251
- <label htmlFor="name" className="form-label form-field-label">
2252
- Markdown
2253
- </label>
2254
- <MarkdownViewer data={markdownText}></MarkdownViewer>
2255
- </div>
2256
- </div>
2257
- } */}
2258
- <div className="md:col-12 sm:col-12">
2259
- <div className="field">
2260
- <label htmlFor="computedFieldValueProviderCtxt" className="form-label form-field-label">
2261
- Computed Field Value Provider Context
2262
- </label>
2263
- <CodeEditor
2264
- formik={formik}
2265
- field="computedFieldValueProviderCtxt" >
2266
- </CodeEditor>
2267
- <div className="form-field-label mt-4">{markdownText}</div>
2268
-
2269
- {isFormFieldValid(
2270
- formik,
2271
- "computedFieldValueProviderCtxt"
2272
- ) && (
2273
- <Message
2274
- severity="error"
2275
- text={formik?.errors?.computedFieldValueProviderCtxt?.toString()}
2276
- />
2277
- )}
2278
- </div>
2279
- </div>
2280
- {/* {currentFields.includes("markdown") && ( */}
2204
+ <div className="field col-12 flex-flex-column gap-2 mt-4">
2205
+ <label htmlFor="computedFieldValueProviderCtxt" className="form-field-label">
2206
+ Computed Field Value Provider Context
2207
+ </label>
2208
+ <CodeEditor
2209
+ formik={formik}
2210
+ field="computedFieldValueProviderCtxt" >
2211
+ </CodeEditor>
2212
+ <div className="form-field-label mt-4">{markdownText}</div>
2281
2213
 
2282
- </div>
2214
+ {isFormFieldValid(
2215
+ formik,
2216
+ "computedFieldValueProviderCtxt"
2217
+ ) && (
2218
+ <Message
2219
+ severity="error"
2220
+ text={formik?.errors?.computedFieldValueProviderCtxt?.toString()}
2221
+ />
2222
+ )}
2283
2223
  </div>
2284
2224
  )}
2285
2225
 
2286
2226
  {/* {currentFields.includes("externalIdProviderCtxt") && (
2287
2227
  <div className="md:col-12 sm:col-12">
2288
2228
 
2289
- <div className="grid p-nogutter">
2229
+ <div className="formgrid grid">
2290
2230
  {markdownText &&
2291
2231
  <div className="md:col-12 sm:col-12">
2292
- <div className="field">
2293
- <label htmlFor="name" className="form-label form-field-label">
2232
+ <div className="field col-6 flex-flex-column gap-2">
2233
+ <label htmlFor="name" className="form-field-label">
2294
2234
  Markdown
2295
2235
  </label>
2296
2236
  <MarkdownViewer data={markdownText}></MarkdownViewer>
@@ -2298,8 +2238,8 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2298
2238
  </div>
2299
2239
  }
2300
2240
  <div className="md:col-12 sm:col-12">
2301
- <div className="field">
2302
- <label htmlFor="name" className="form-label form-field-label">
2241
+ <div className="field col-6 flex-flex-column gap-2">
2242
+ <label htmlFor="name" className="form-field-label">
2303
2243
  External Id Provider Context
2304
2244
  </label>
2305
2245
  <CodeEditor
@@ -2326,19 +2266,14 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2326
2266
  )}
2327
2267
  {(currentFields.includes("regexPattern") || currentFields.includes("min") || currentFields.includes("max") || currentFields.includes("ormType")) && ormTypeOptions &&
2328
2268
  <>
2329
- <div className="grid p-nogutter section-sub-heading">
2330
- <div className="md:col-12 sm:col-12">
2331
- <p className="form-subheading">Validations</p>
2332
- </div>
2333
- </div>
2334
- <div className="grid p-nogutter">
2269
+ <p className="form-wrapper-heading text-base">Validations</p>
2270
+ <div className="formgrid grid">
2335
2271
  {(currentFields.includes("regexPattern") && selectedType.value === "password") &&
2336
2272
  <>
2337
- <div className="md:col-6 sm:col-12">
2338
- <div className="field">
2273
+ <div className="field col-6 flex-flex-column gap-2">
2339
2274
  <label
2340
2275
  htmlFor="regexPattern"
2341
- className="form-label form-field-label"
2276
+ className="form-field-label"
2342
2277
  >
2343
2278
  Password Policy
2344
2279
  </label>
@@ -2350,20 +2285,18 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2350
2285
  }} options={passwordPolicyOptions} optionLabel="label"
2351
2286
  placeholder="Select a Password Policy"
2352
2287
  // className="w-full md:w-14rem"
2353
- className="p-inputtext-sm w-full small-input"
2288
+ className=""
2354
2289
  checkmark={true} highlightOnSelect={false} />
2355
2290
 
2356
2291
  </div>
2357
- </div>
2358
2292
  </>
2359
2293
  }
2360
2294
  {currentFields.includes("regexPattern") && (
2361
2295
  <>
2362
- <div className="md:col-6 sm:col-12">
2363
- <div className="field">
2296
+ <div className="field col-6 flex-flex-column gap-2">
2364
2297
  <label
2365
2298
  htmlFor="regexPattern"
2366
- className="form-label form-field-label"
2299
+ className="form-field-label"
2367
2300
  >
2368
2301
  Regex Pattern
2369
2302
  </label>
@@ -2373,7 +2306,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2373
2306
  name="regexPattern"
2374
2307
  onChange={formik.handleChange}
2375
2308
  value={formik.values.regexPattern}
2376
- className={classNames("p-inputtext-sm w-full small-input", {
2309
+ className={classNames("", {
2377
2310
  "p-invalid": isFormFieldValid(
2378
2311
  formik,
2379
2312
  "regexPattern"
@@ -2387,14 +2320,11 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2387
2320
  />
2388
2321
  )}
2389
2322
  </div>
2390
- </div>
2391
2323
  {currentFields.includes("regexPattern") && (
2392
-
2393
- <div className="md:col-6 sm:col-12">
2394
- <div className="field">
2324
+ <div className="field col-6 flex-flex-column gap-2">
2395
2325
  <label
2396
2326
  htmlFor="regexPatternNotMatchingErrorMsg"
2397
- className="form-label form-field-label"
2327
+ className="form-field-label"
2398
2328
  >
2399
2329
  Regex Pattern Not Matching Error Msg
2400
2330
  </label>
@@ -2404,7 +2334,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2404
2334
  name="regexPatternNotMatchingErrorMsg"
2405
2335
  onChange={formik.handleChange}
2406
2336
  value={formik.values.regexPatternNotMatchingErrorMsg}
2407
- className={classNames("p-inputtext-sm w-full small-input", {
2337
+ className={classNames("", {
2408
2338
  "p-invalid": isFormFieldValid(
2409
2339
  formik,
2410
2340
  "regexPatternNotMatchingErrorMsg"
@@ -2418,18 +2348,15 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2418
2348
  />
2419
2349
  )}
2420
2350
  </div>
2421
- </div>
2422
2351
  )}
2423
2352
  </>
2424
2353
 
2425
2354
  )}
2426
2355
  {(currentFields.includes("min") || currentFields.includes("max")) &&
2427
- <div className="md:col-12 sm:col-12">
2428
- <div className="grid p-nogutter">
2356
+ <>
2429
2357
  {currentFields.includes("min") && (
2430
- <div className="md:col-6 sm:col-12">
2431
- <div className="field">
2432
- <label htmlFor="min" className="form-label form-field-label">
2358
+ <div className="field col-6 flex-flex-column gap-2">
2359
+ <label htmlFor="min" className="form-field-label">
2433
2360
  Min (Characters Allowed)
2434
2361
 
2435
2362
  </label>
@@ -2439,7 +2366,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2439
2366
  name="min"
2440
2367
  onChange={formik.handleChange}
2441
2368
  value={formik.values.min}
2442
- className={classNames("p-inputtext-sm w-full small-input", {
2369
+ className={classNames("", {
2443
2370
  "p-invalid": isFormFieldValid(formik, "min"),
2444
2371
  })}
2445
2372
  /> */}
@@ -2457,7 +2384,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2457
2384
  name="min"
2458
2385
  onValueChange={formik.handleChange}
2459
2386
  value={formik.values.min}
2460
- className={classNames("p-inputtext-sm w-full small-input", {
2387
+ className={classNames("", {
2461
2388
  "p-invalid": isFormFieldValid(
2462
2389
  formik,
2463
2390
  "min"
@@ -2473,12 +2400,10 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2473
2400
  />
2474
2401
  )}
2475
2402
  </div>
2476
- </div>
2477
2403
  )}
2478
2404
  {currentFields.includes("max") && (
2479
- <div className="md:col-6 sm:col-12">
2480
- <div className="field">
2481
- <label htmlFor="max" className="form-label form-field-label">
2405
+ <div className="field col-6 flex-flex-column gap-2">
2406
+ <label htmlFor="max" className="form-field-label">
2482
2407
  Max (Character allowed)
2483
2408
  </label>
2484
2409
  {/* <InputText
@@ -2487,7 +2412,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2487
2412
  name="max"
2488
2413
  onChange={formik.handleChange}
2489
2414
  value={formik.values.max}
2490
- className={classNames("p-inputtext-sm w-full small-input", {
2415
+ className={classNames("", {
2491
2416
  "p-invalid": isFormFieldValid(formik, "max"),
2492
2417
  })}
2493
2418
  /> */}
@@ -2504,7 +2429,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2504
2429
  name="max"
2505
2430
  onValueChange={formik.handleChange}
2506
2431
  value={formik.values.max}
2507
- className={classNames("p-inputtext-sm w-full small-input", {
2432
+ className={classNames("", {
2508
2433
  "p-invalid": isFormFieldValid(
2509
2434
  formik,
2510
2435
  "max"
@@ -2520,16 +2445,14 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2520
2445
  />
2521
2446
  )}
2522
2447
  </div>
2523
- </div>
2524
2448
  )}
2525
- </div>
2526
- </div>
2449
+ </>
2527
2450
  }
2528
2451
  {currentFields.includes("ormType") && (
2529
2452
  <div className="md:col-12 sm:col-12">
2530
2453
  {ormTypeOptions && ormTypeOptions.length > 1 &&
2531
- <div className="field">
2532
- <label htmlFor="ormType" className="form-label form-field-label">
2454
+ <div className="field col-6 flex-flex-column gap-2">
2455
+ <label htmlFor="ormType" className="form-field-label">
2533
2456
  Type
2534
2457
  </label>
2535
2458
  {/* <SingleSelectAutoCompleteField
@@ -2579,15 +2502,10 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2579
2502
  </>
2580
2503
  }
2581
2504
 
2582
- <div className="grid p-nogutter section-sub-heading">
2583
- <div className="md:col-12 sm:col-12">
2584
- <p className="form-subheading">Settings</p>
2585
- </div>
2586
- </div>
2587
- <div className="grid p-nogutter">
2505
+ <p className="form-wrapper-heading text-base">Settings</p>
2506
+ <div className="formgrid grid">
2588
2507
  {currentFields.includes("required") && (
2589
- <div className="md:col-6 sm:col-12">
2590
- <div className="field">
2508
+ <div className="field col-6 flex-flex-column gap-2">
2591
2509
  <div className="flex align-items-center">
2592
2510
  <Checkbox
2593
2511
  name="required"
@@ -2596,11 +2514,11 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2596
2514
  }}
2597
2515
  checked={formik.values.required}
2598
2516
  ></Checkbox>
2599
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2517
+ <label htmlFor="ingredient1" className="form-field-label ml-2">
2600
2518
  Required
2601
2519
  </label>
2602
2520
  </div>
2603
- <p className="fieldSubTitle">You won't be able to create an entry if this field is empty</p>
2521
+ <p className="text-xs mt-2">You won't be able to create an entry if this field is empty</p>
2604
2522
 
2605
2523
  {isFormFieldValid(formik, "required") && (
2606
2524
  <Message
@@ -2609,11 +2527,9 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2609
2527
  />
2610
2528
  )}
2611
2529
  </div>
2612
- </div>
2613
2530
  )}
2614
2531
  {currentFields.includes("unique") && (
2615
- <div className="md:col-6 sm:col-12">
2616
- <div className="field">
2532
+ <div className="field col-6 flex-flex-column gap-2">
2617
2533
  <div className="flex align-items-center">
2618
2534
  <Checkbox
2619
2535
  name="unique"
@@ -2622,11 +2538,11 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2622
2538
  }}
2623
2539
  checked={formik.values.unique}
2624
2540
  ></Checkbox>
2625
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2541
+ <label htmlFor="ingredient1" className="form-field-label ml-2">
2626
2542
  Unique
2627
2543
  </label>
2628
2544
  </div>
2629
- <p className="fieldSubTitle">You won't be able to create an entry if there is an existing entry with identical content</p>
2545
+ <p className="text-xs mt-2">You won't be able to create an entry if there is an existing entry with identical content</p>
2630
2546
 
2631
2547
  {isFormFieldValid(formik, "unique") && (
2632
2548
  <Message
@@ -2635,11 +2551,9 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2635
2551
  />
2636
2552
  )}
2637
2553
  </div>
2638
- </div>
2639
2554
  )}
2640
2555
  {currentFields.includes("index") && (
2641
- <div className="md:col-6 sm:col-12">
2642
- <div className="field">
2556
+ <div className="field col-6 flex-flex-column gap-2 mt-3">
2643
2557
  <div className="flex align-items-center">
2644
2558
  <Checkbox
2645
2559
  name="index"
@@ -2648,7 +2562,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2648
2562
  }}
2649
2563
  checked={formik.values.index}
2650
2564
  ></Checkbox>
2651
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2565
+ <label htmlFor="ingredient1" className="form-field-label ml-2">
2652
2566
  Index
2653
2567
  </label>
2654
2568
  </div>
@@ -2659,11 +2573,9 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2659
2573
  />
2660
2574
  )}
2661
2575
  </div>
2662
- </div>
2663
2576
  )}
2664
2577
  {currentFields.includes("private") && (
2665
- <div className="md:col-6 sm:col-12">
2666
- <div className="field">
2578
+ <div className="field col-6 flex-flex-column gap-2 mt-3">
2667
2579
  <div className="flex align-items-center">
2668
2580
  <Checkbox
2669
2581
  name="private"
@@ -2672,11 +2584,11 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2672
2584
  }}
2673
2585
  checked={formik.values.private}
2674
2586
  ></Checkbox>
2675
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2587
+ <label htmlFor="ingredient1" className="form-field-label ml-2">
2676
2588
  Private
2677
2589
  </label>
2678
2590
  </div>
2679
- <p className="fieldSubTitle">This field will not show up in the API response</p>
2591
+ <p className="text-xs mt-2">This field will not show up in the API response</p>
2680
2592
 
2681
2593
 
2682
2594
  {isFormFieldValid(formik, "private") && (
@@ -2686,12 +2598,10 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2686
2598
  />
2687
2599
  )}
2688
2600
  </div>
2689
- </div>
2690
2601
  )}
2691
2602
  {currentFields.includes("encrypt") && (
2692
- <div className="md:col-6 sm:col-12">
2693
- <div className="field">
2694
- <div className="flex align-items-center">
2603
+ <div className="field col-6 flex-flex-column gap-2 mt-3">
2604
+ <div className="flex align-items-center gap-2">
2695
2605
  <Checkbox
2696
2606
  name="encrypt"
2697
2607
  onChange={(e) => {
@@ -2700,7 +2610,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2700
2610
  }}
2701
2611
  checked={formik.values.encrypt}
2702
2612
  ></Checkbox>
2703
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2613
+ <label htmlFor="ingredient1" className="form-field-label">
2704
2614
  Encrypt
2705
2615
  </label>
2706
2616
  </div>
@@ -2711,12 +2621,10 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2711
2621
  />
2712
2622
  )}
2713
2623
  </div>
2714
- </div>
2715
2624
  )}
2716
2625
  {currentFields.includes("isSystem") && (
2717
- <div className="md:col-6 sm:col-12">
2718
- <div className="field">
2719
- <div className="flex align-items-center">
2626
+ <div className="field col-6 flex-flex-column gap-2 mt-3">
2627
+ <div className="flex align-items-center gap-2">
2720
2628
  <Checkbox
2721
2629
  name="isSystem"
2722
2630
  onChange={(e) => {
@@ -2724,7 +2632,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2724
2632
  }}
2725
2633
  checked={formik.values.isSystem}
2726
2634
  ></Checkbox>
2727
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2635
+ <label htmlFor="ingredient1" className="form-field-label">
2728
2636
  isSystem
2729
2637
  </label>
2730
2638
  </div>
@@ -2735,12 +2643,10 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2735
2643
  />
2736
2644
  )}
2737
2645
  </div>
2738
- </div>
2739
2646
  )}
2740
2647
  {currentFields.includes("isUserKey") && (
2741
- <div className="md:col-6 sm:col-12">
2742
- <div className="field">
2743
- <div className="flex align-items-center">
2648
+ <div className="field col-6 flex-flex-column gap-2 mt-3">
2649
+ <div className="flex align-items-center gap-2">
2744
2650
  <Checkbox
2745
2651
  name="isUserKey"
2746
2652
  onChange={(e) => {
@@ -2748,7 +2654,7 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2748
2654
  }}
2749
2655
  checked={formik.values.isUserKey}
2750
2656
  ></Checkbox>
2751
- <label htmlFor="ingredient1" className="form-label form-field-label ml-2">
2657
+ <label htmlFor="ingredient1" className="form-field-label">
2752
2658
  Is Userkey
2753
2659
  </label>
2754
2660
  </div>
@@ -2761,18 +2667,17 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2761
2667
  />
2762
2668
  )}
2763
2669
  </div>
2764
- </div>
2765
2670
  )}
2766
2671
  </div>
2767
2672
 
2768
2673
 
2769
2674
  {formik.values.encrypt === true && (
2770
- <div className="grid p-nogutter mt-2">
2675
+ <div className="formgrid grid mt-2">
2771
2676
  <div className="md:col-6 sm:col-12">
2772
- <div className="field">
2677
+ <div className="field col-6 flex-flex-column gap-2">
2773
2678
  <label
2774
2679
  htmlFor="encryptionType"
2775
- className="form-label form-field-label"
2680
+ className="form-field-label"
2776
2681
  >
2777
2682
  Encryption Type
2778
2683
  </label>
@@ -2814,8 +2719,8 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2814
2719
  </div>
2815
2720
  </div>
2816
2721
  <div className="md:col-6 sm:col-12">
2817
- <div className="field">
2818
- <label htmlFor="decryptWhen" className="form-label form-field-label">
2722
+ <div className="field col-6 flex-flex-column gap-2">
2723
+ <label htmlFor="decryptWhen" className="form-field-label">
2819
2724
  Decrypt When
2820
2725
  </label>
2821
2726
  {/* <AutoComplete
@@ -2901,4 +2806,5 @@ const FieldMetaDataForm = ({ modelMetaData, fieldMetaData, setFieldMetaData, all
2901
2806
  );
2902
2807
  };
2903
2808
 
2809
+
2904
2810
  export default FieldMetaDataForm;