@solidstarters/solid-core-ui 1.1.211 → 1.1.212
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/Svg/DevDocs.tsx +9 -0
- package/dist/components/Svg/DocsSvg.tsx +9 -0
- package/dist/components/Svg/ExcelSvg.tsx +15 -0
- package/dist/components/Svg/FieldSvg.tsx +9 -0
- package/dist/components/Svg/FileSvg.tsx +18 -0
- package/dist/components/Svg/HomePageModuleSvg.tsx +179 -0
- package/dist/components/Svg/ModelSvg.tsx +9 -0
- package/dist/components/Svg/ModuleSvg.tsx +9 -0
- package/dist/components/Svg/PDFSvg.tsx +15 -0
- package/dist/components/Svg/RightArrowSvg.tsx +9 -0
- package/dist/components/Svg/SettingsSvg.tsx +9 -0
- package/dist/components/auth/AuthLayout.tsx +223 -0
- package/dist/components/auth/ForgotPasswordThankYou.tsx +33 -0
- package/dist/components/auth/GoogleAuthChecking.tsx +63 -0
- package/dist/components/auth/SolidChangeForcePassword.tsx +222 -0
- package/dist/components/auth/SolidForgotPassword.tsx +127 -0
- package/dist/components/auth/SolidInitialLoginOtp.tsx +271 -0
- package/dist/components/auth/SolidInitiateRegisterOtp.tsx +218 -0
- package/dist/components/auth/SolidLogin.d.ts.map +1 -1
- package/dist/components/auth/SolidLogin.js +14 -8
- package/dist/components/auth/SolidLogin.js.map +1 -1
- package/dist/components/auth/SolidLogin.tsx +428 -0
- package/dist/components/auth/SolidOTPVerify.tsx +133 -0
- package/dist/components/auth/SolidRegister.tsx +454 -0
- package/dist/components/auth/SolidResetPassword.tsx +194 -0
- package/dist/components/common/AuthBanner.tsx +41 -0
- package/dist/components/common/AutoCompleteField.tsx +79 -0
- package/dist/components/common/BackButton.tsx +72 -0
- package/dist/components/common/CancelButton.tsx +61 -0
- package/dist/components/common/CodeEditor.tsx +38 -0
- package/dist/components/common/CreateButton.tsx +17 -0
- package/dist/components/common/DownloadProgressToast.tsx +55 -0
- package/dist/components/common/DropzonePlaceholder.tsx +31 -0
- package/dist/components/common/DropzoneUpload.tsx +11 -0
- package/dist/components/common/FileReaderExt.tsx +20 -0
- package/dist/components/common/GeneralSettings.tsx +1225 -0
- package/dist/components/common/HeaderDynamicTitles.tsx +13 -0
- package/dist/components/common/MarkdownViewer.tsx +84 -0
- package/dist/components/common/MultipleSelectAutoCompleteField.tsx +64 -0
- package/dist/components/common/NotFound.tsx +22 -0
- package/dist/components/common/SingleSelectAutoCompleteField.tsx +73 -0
- package/dist/components/common/SocialMediaLogin.tsx +53 -0
- package/dist/components/common/SolidAdmin.tsx +6 -0
- package/dist/components/common/SolidBreadcrumb.tsx +129 -0
- package/dist/components/common/SolidExport.tsx +563 -0
- package/dist/components/common/SolidExportStepper.tsx +135 -0
- package/dist/components/common/SolidFieldTooltip.tsx +23 -0
- package/dist/components/common/SolidFormHeader.tsx +25 -0
- package/dist/components/common/SolidFormStepper.tsx +350 -0
- package/dist/components/common/SolidModuleHome.tsx +128 -0
- package/dist/components/common/SolidPopupContainer.tsx +37 -0
- package/dist/components/common/SolidSettings/LlmSettings/AnthropicProviderComponent.tsx +45 -0
- package/dist/components/common/SolidSettings/LlmSettings/OpenAiProviderComponent.tsx +45 -0
- package/dist/components/common/SolidSettings/SettingDropzoneActivePlaceholder.tsx +20 -0
- package/dist/components/common/SolidSettings/SettingsImageRemoveButton.tsx +15 -0
- package/dist/components/common/SolidSettings/SolidUploadedImage.tsx +16 -0
- package/dist/components/common/SolidThemeLink.tsx +6 -0
- package/dist/components/common/SolidThemeProvider.tsx +44 -0
- package/dist/components/common/StepperArrows/ActiveArrowStep.tsx +18 -0
- package/dist/components/common/StepperArrows/ActiveBeforeStepArrow.tsx +18 -0
- package/dist/components/common/StepperArrows/InactiveStepArrow.tsx +19 -0
- package/dist/components/common/error.tsx +30 -0
- package/dist/components/common/useHandleFormCustomButtonClick.ts +40 -0
- package/dist/components/common/useHandleListCustomButtonClick.ts +42 -0
- package/dist/components/core/chatter/SolidChatter.tsx +248 -0
- package/dist/components/core/chatter/SolidChatterAuditMessage.tsx +35 -0
- package/dist/components/core/chatter/SolidChatterCustomMessage.tsx +46 -0
- package/dist/components/core/chatter/SolidChatterDateDivider.tsx +16 -0
- package/dist/components/core/chatter/SolidChatterHeader.tsx +218 -0
- package/dist/components/core/chatter/SolidChatterMessageBox.tsx +163 -0
- package/dist/components/core/chatter/SolidMessageComposer.tsx +146 -0
- package/dist/components/core/common/AvatarWidget.tsx +55 -0
- package/dist/components/core/common/DateFieldViewComponent.tsx +36 -0
- package/dist/components/core/common/FilterComponent.tsx +458 -0
- package/dist/components/core/common/LoadDynamicJsxComponent.tsx +70 -0
- package/dist/components/core/common/PDFViewer.tsx +117 -0
- package/dist/components/core/common/SolidAccountSettings/SolidAccountSettings.tsx +89 -0
- package/dist/components/core/common/SolidAccountSettings/SolidChangePassword.tsx +188 -0
- package/dist/components/core/common/SolidAccountSettings/SolidNotifications.tsx +139 -0
- package/dist/components/core/common/SolidAccountSettings/SolidPersonalInfo.tsx +311 -0
- package/dist/components/core/common/SolidCreateButton.tsx +48 -0
- package/dist/components/core/common/SolidGenericImport/DocumentSvg.tsx +15 -0
- package/dist/components/core/common/SolidGenericImport/SolidGenericImport.tsx +64 -0
- package/dist/components/core/common/SolidGenericImport/SolidImportDropzone.tsx +125 -0
- package/dist/components/core/common/SolidGenericImport/SolidImportInstructions.tsx +122 -0
- package/dist/components/core/common/SolidGenericImport/SolidImportStepper.tsx +217 -0
- package/dist/components/core/common/SolidGenericImport/SolidImportTransaction.tsx +205 -0
- package/dist/components/core/common/SolidGenericImport/SolidImportTransactionStatus.tsx +158 -0
- package/dist/components/core/common/SolidGenericImport/SolidImportWrapper.tsx +29 -0
- package/dist/components/core/common/SolidGlobalSearchElement.tsx +1470 -0
- package/dist/components/core/common/SolidLayoutViews.tsx +87 -0
- package/dist/components/core/common/SolidListViewOptions.tsx +31 -0
- package/dist/components/core/common/SolidLoaders/SolidCircularLoader.tsx +7 -0
- package/dist/components/core/common/SolidPasswordHelperText.tsx +34 -0
- package/dist/components/core/common/SolidSaveCustomFilterForm.tsx +75 -0
- package/dist/components/core/common/SolidSearchBox.tsx +17 -0
- package/dist/components/core/common/SolidViewLayoutManager.ts +421 -0
- package/dist/components/core/common/SolidXAiIframe.tsx +77 -0
- package/dist/components/core/dashboard/SolidDashboard.tsx +332 -0
- package/dist/components/core/dashboard/SolidDashboardBody.tsx +117 -0
- package/dist/components/core/dashboard/SolidDashboardFilterRequired.tsx +28 -0
- package/dist/components/core/dashboard/SolidDashboardHeader.tsx +10 -0
- package/dist/components/core/dashboard/SolidDashboardLoading.tsx +55 -0
- package/dist/components/core/dashboard/SolidDashboardNotAvailable.tsx +32 -0
- package/dist/components/core/dashboard/SolidDashboardRenderError.tsx +29 -0
- package/dist/components/core/dashboard/SolidDashboardVariable.tsx +256 -0
- package/dist/components/core/dashboard/SolidQuestionRenderer.tsx +78 -0
- package/dist/components/core/dashboard/chart-renderers/ChartJsRenderer.tsx +18 -0
- package/dist/components/core/dashboard/chart-renderers/PrimeReactDatatableRenderer.tsx +54 -0
- package/dist/components/core/dashboard/chart-renderers/init-chartjs.ts +25 -0
- package/dist/components/core/dashboard/dashboard-utils.ts +39 -0
- package/dist/components/core/extension/solid-core/CustomIcon/StatusIcon.tsx +17 -0
- package/dist/components/core/extension/solid-core/dashboardQuestion/ChartFormPreviewWidget.tsx +36 -0
- package/dist/components/core/extension/solid-core/emailTemplate/emailFormTypeChangeHandler.ts +18 -0
- package/dist/components/core/extension/solid-core/emailTemplate/emailFormTypeLoad.ts +18 -0
- package/dist/components/core/extension/solid-core/modelMetadata/list/DeleteModelRowAction.tsx +114 -0
- package/dist/components/core/extension/solid-core/modelMetadata/list/GenerateModelCodeRowAction.tsx +213 -0
- package/dist/components/core/extension/solid-core/moduleMetadata/list/DeleteModuleRowAction.tsx +138 -0
- package/dist/components/core/extension/solid-core/moduleMetadata/list/GenerateModuleCodeRowAction.tsx +209 -0
- package/dist/components/core/extension/solid-core/roleMetadata/RolePermissionsManyToManyFieldWidget.tsx +131 -0
- package/dist/components/core/field/FieldListViewData.tsx +313 -0
- package/dist/components/core/filter/SolidBooleanFilterElement.tsx +30 -0
- package/dist/components/core/filter/SolidFilterFields.tsx +131 -0
- package/dist/components/core/filter/SolidManyToManyFilterElement.tsx +64 -0
- package/dist/components/core/filter/SolidManyToOneFilterElement.tsx +61 -0
- package/dist/components/core/filter/SolidSelectionDynamicFilterElement.tsx +50 -0
- package/dist/components/core/filter/SolidSelectionStaticFilterElement.tsx +32 -0
- package/dist/components/core/filter/SolidVarInputsFilterElement.tsx +209 -0
- package/dist/components/core/filter/fields/SolidBigintField.tsx +9 -0
- package/dist/components/core/filter/fields/SolidBooleanField.tsx +68 -0
- package/dist/components/core/filter/fields/SolidComputedField.tsx +23 -0
- package/dist/components/core/filter/fields/SolidDateField.tsx +63 -0
- package/dist/components/core/filter/fields/SolidDatetimeField.tsx +54 -0
- package/dist/components/core/filter/fields/SolidDecimalField.tsx +9 -0
- package/dist/components/core/filter/fields/SolidExternalIdField.tsx +52 -0
- package/dist/components/core/filter/fields/SolidFloatField.tsx +9 -0
- package/dist/components/core/filter/fields/SolidIdField.tsx +46 -0
- package/dist/components/core/filter/fields/SolidIntField.tsx +61 -0
- package/dist/components/core/filter/fields/SolidLongTextField.tsx +9 -0
- package/dist/components/core/filter/fields/SolidMediaMultipleField.tsx +60 -0
- package/dist/components/core/filter/fields/SolidMediaSingleField.tsx +62 -0
- package/dist/components/core/filter/fields/SolidRelationField.tsx +17 -0
- package/dist/components/core/filter/fields/SolidRichTextField.tsx +9 -0
- package/dist/components/core/filter/fields/SolidSelectionDynamicField.tsx +52 -0
- package/dist/components/core/filter/fields/SolidSelectionStaticField.tsx +54 -0
- package/dist/components/core/filter/fields/SolidShortTextField.tsx +60 -0
- package/dist/components/core/filter/fields/SolidTimeField.tsx +48 -0
- package/dist/components/core/filter/fields/SolidUuidField.tsx +51 -0
- package/dist/components/core/filter/fields/relations/SolidRelationManyToManyField.tsx +62 -0
- package/dist/components/core/filter/fields/relations/SolidRelationManyToOneField.tsx +84 -0
- package/dist/components/core/form/SolidFormActionHeader.tsx +497 -0
- package/dist/components/core/form/SolidFormFieldRender.tsx +53 -0
- package/dist/components/core/form/SolidFormFieldRenderExtension.tsx +26 -0
- package/dist/components/core/form/SolidFormFooter.tsx +162 -0
- package/dist/components/core/form/SolidFormLayouts.tsx +104 -0
- package/dist/components/core/form/SolidFormUserViewLayout.tsx +84 -0
- package/dist/components/core/form/SolidFormView.tsx +1856 -0
- package/dist/components/core/form/SolidFormViewContextMenuHeaderButton.tsx +52 -0
- package/dist/components/core/form/SolidFormViewNormalHeaderButton.tsx +52 -0
- package/dist/components/core/form/SolidFormViewShimmerLoading.tsx +109 -0
- package/dist/components/core/form/fields/ISolidField.tsx +71 -0
- package/dist/components/core/form/fields/SolidBooleanField.tsx +434 -0
- package/dist/components/core/form/fields/SolidDateField.tsx +247 -0
- package/dist/components/core/form/fields/SolidDateTimeField.tsx +229 -0
- package/dist/components/core/form/fields/SolidDecimalField.tsx +171 -0
- package/dist/components/core/form/fields/SolidEmailField.tsx +176 -0
- package/dist/components/core/form/fields/SolidIntegerField.tsx +282 -0
- package/dist/components/core/form/fields/SolidJsonField.tsx +185 -0
- package/dist/components/core/form/fields/SolidLongTextField.tsx +618 -0
- package/dist/components/core/form/fields/SolidMediaMultipleField.tsx +663 -0
- package/dist/components/core/form/fields/SolidMediaSingleField.tsx +547 -0
- package/dist/components/core/form/fields/SolidPasswordField.tsx +390 -0
- package/dist/components/core/form/fields/SolidRelationField.tsx +56 -0
- package/dist/components/core/form/fields/SolidRichTextField.tsx +188 -0
- package/dist/components/core/form/fields/SolidSelectionDynamicField.tsx +340 -0
- package/dist/components/core/form/fields/SolidSelectionStaticField.tsx +462 -0
- package/dist/components/core/form/fields/SolidShortTextField.tsx +399 -0
- package/dist/components/core/form/fields/SolidTimeField.tsx +245 -0
- package/dist/components/core/form/fields/relations/SolidRelationManyToManyField.tsx +453 -0
- package/dist/components/core/form/fields/relations/SolidRelationManyToOneField.tsx +1036 -0
- package/dist/components/core/form/fields/relations/SolidRelationOneToManyField.tsx +627 -0
- package/dist/components/core/form/fields/relations/widgets/helpers/InlineRelationEntityDialog.tsx +38 -0
- package/dist/components/core/form/fields/relations/widgets/helpers/useRelationEntityHandler.ts +64 -0
- package/dist/components/core/form/fields/widgets/SolidAiInteractionMessageFieldFormWidget.tsx +135 -0
- package/dist/components/core/form/fields/widgets/SolidAiInteractionMetadataFieldFormWidget.tsx +144 -0
- package/dist/components/core/form/fields/widgets/SolidIconEditWidget.tsx +265 -0
- package/dist/components/core/form/fields/widgets/SolidIconViewWidget.tsx +32 -0
- package/dist/components/core/form/fields/widgets/SolidRelationFieldAvatarFormWidget.tsx +50 -0
- package/dist/components/core/form/fields/widgets/SolidS3FileViewerWidget.tsx +222 -0
- package/dist/components/core/form/fields/widgets/SolidShortTextFieldAvatarWidget.tsx +70 -0
- package/dist/components/core/form/widgets/CustomHtml.tsx +20 -0
- package/dist/components/core/kanban/KanbanBoard.tsx +150 -0
- package/dist/components/core/kanban/KanbanCard.tsx +279 -0
- package/dist/components/core/kanban/KanbanColumn.tsx +139 -0
- package/dist/components/core/kanban/KanbanUserViewLayout.tsx +84 -0
- package/dist/components/core/kanban/SolidKanbanView.tsx +894 -0
- package/dist/components/core/kanban/SolidKanbanViewConfigure.tsx +154 -0
- package/dist/components/core/kanban/SolidKanbanViewFields.tsx +164 -0
- package/dist/components/core/kanban/SolidManyToOneFilterElement.tsx +59 -0
- package/dist/components/core/kanban/SolidSelectionDynamicFilterElement.tsx +50 -0
- package/dist/components/core/kanban/SolidSelectionStaticFilterElement.tsx +32 -0
- package/dist/components/core/kanban/SolidVarInputsFilterElement.tsx +184 -0
- package/dist/components/core/kanban/kanban-fields/SolidBigintKanbanField.tsx +9 -0
- package/dist/components/core/kanban/kanban-fields/SolidBooleanKanbanField.tsx +16 -0
- package/dist/components/core/kanban/kanban-fields/SolidComputedKanbanField.tsx +23 -0
- package/dist/components/core/kanban/kanban-fields/SolidDateKanbanField.tsx +14 -0
- package/dist/components/core/kanban/kanban-fields/SolidDatetimeKanbanField.tsx +13 -0
- package/dist/components/core/kanban/kanban-fields/SolidDecimalKanbanField.tsx +9 -0
- package/dist/components/core/kanban/kanban-fields/SolidExternalIdKanbanField.tsx +12 -0
- package/dist/components/core/kanban/kanban-fields/SolidFloatKanbanField.tsx +9 -0
- package/dist/components/core/kanban/kanban-fields/SolidIdKanbanField.tsx +14 -0
- package/dist/components/core/kanban/kanban-fields/SolidIntKanbanField.tsx +20 -0
- package/dist/components/core/kanban/kanban-fields/SolidLongTextKanbanField.tsx +9 -0
- package/dist/components/core/kanban/kanban-fields/SolidMediaMultipleKanbanField.tsx +140 -0
- package/dist/components/core/kanban/kanban-fields/SolidMediaSingleKanbanField.tsx +164 -0
- package/dist/components/core/kanban/kanban-fields/SolidRelationKanbanField.tsx +13 -0
- package/dist/components/core/kanban/kanban-fields/SolidRichTextKanbanField.tsx +9 -0
- package/dist/components/core/kanban/kanban-fields/SolidSelectionDynamicKanbanField.tsx +14 -0
- package/dist/components/core/kanban/kanban-fields/SolidSelectionStaticKanbanField.tsx +14 -0
- package/dist/components/core/kanban/kanban-fields/SolidShortTextKanbanField.tsx +121 -0
- package/dist/components/core/kanban/kanban-fields/SolidTimeKanbanField.tsx +12 -0
- package/dist/components/core/kanban/kanban-fields/SolidUuidKanbanField.tsx +13 -0
- package/dist/components/core/kanban/kanban-fields/relations/SolidRelationManyToOneKanbanField.tsx +16 -0
- package/dist/components/core/list/ListViewRowActionPopup.tsx +41 -0
- package/dist/components/core/list/SolidColumnSelector/SolidListColumnSelector.tsx +242 -0
- package/dist/components/core/list/SolidEmptyListViewPlaceholder.tsx +111 -0
- package/dist/components/core/list/SolidListView.tsx +2007 -0
- package/dist/components/core/list/SolidListViewColumn.tsx +165 -0
- package/dist/components/core/list/SolidListViewConfigure.tsx +339 -0
- package/dist/components/core/list/SolidListViewHeaderButton.tsx +31 -0
- package/dist/components/core/list/SolidListViewHeaderContextMenuButton.tsx +30 -0
- package/dist/components/core/list/SolidListViewRowButtonContextMenu.tsx +41 -0
- package/dist/components/core/list/SolidListViewShimmerLoading.tsx +78 -0
- package/dist/components/core/list/SolidListingHeader.tsx +42 -0
- package/dist/components/core/list/SolidManyToOneFilterElement.tsx +60 -0
- package/dist/components/core/list/SolidSelectionDynamicFilterElement.tsx +50 -0
- package/dist/components/core/list/SolidSelectionStaticFilterElement.tsx +32 -0
- package/dist/components/core/list/SolidTableRowCell.tsx +35 -0
- package/dist/components/core/list/SolidVarInputsFilterElement.tsx +184 -0
- package/dist/components/core/list/columns/SolidBigintColumn.tsx +9 -0
- package/dist/components/core/list/columns/SolidBooleanColumn.tsx +90 -0
- package/dist/components/core/list/columns/SolidComputedColumn.tsx +27 -0
- package/dist/components/core/list/columns/SolidDateColumn.tsx +90 -0
- package/dist/components/core/list/columns/SolidDatetimeColumn.tsx +79 -0
- package/dist/components/core/list/columns/SolidDecimalColumn.tsx +9 -0
- package/dist/components/core/list/columns/SolidExternalIdColumn.tsx +80 -0
- package/dist/components/core/list/columns/SolidFloatColumn.tsx +9 -0
- package/dist/components/core/list/columns/SolidIdColumn.tsx +79 -0
- package/dist/components/core/list/columns/SolidIntColumn.tsx +87 -0
- package/dist/components/core/list/columns/SolidLongTextColumn.tsx +9 -0
- package/dist/components/core/list/columns/SolidMediaMultipleColumn.tsx +301 -0
- package/dist/components/core/list/columns/SolidMediaSingleColumn.tsx +170 -0
- package/dist/components/core/list/columns/SolidRelationColumn.tsx +21 -0
- package/dist/components/core/list/columns/SolidRichTextColumn.tsx +9 -0
- package/dist/components/core/list/columns/SolidSelectionDynamicColumn.tsx +80 -0
- package/dist/components/core/list/columns/SolidSelectionStaticColumn.tsx +81 -0
- package/dist/components/core/list/columns/SolidShortTextColumn.tsx +160 -0
- package/dist/components/core/list/columns/SolidTimeColumn.tsx +78 -0
- package/dist/components/core/list/columns/SolidUuidColumn.tsx +79 -0
- package/dist/components/core/list/columns/relations/SolidRelationManyToManyColumn.tsx +106 -0
- package/dist/components/core/list/columns/relations/SolidRelationManyToOneColumn.tsx +117 -0
- package/dist/components/core/list/columns/relations/SolidRelationOneToManyColumn.tsx +110 -0
- package/dist/components/core/list/widgets/SolidManyToManyRelationAvatarListWidget.tsx +30 -0
- package/dist/components/core/list/widgets/SolidManyToOneRelationAvatarListWidget.tsx +30 -0
- package/dist/components/core/list/widgets/SolidShortTextAvatarWidget.tsx +70 -0
- package/dist/components/core/list/widgets/SolidShortTextFieldImageRenderModeWidget.tsx +21 -0
- package/dist/components/core/locales/SolidChatterLocaleTabView.tsx +91 -0
- package/dist/components/core/locales/SolidLocale.tsx +127 -0
- package/dist/components/core/model/CreateModel.tsx +495 -0
- package/dist/components/core/model/FieldMetaData.tsx +263 -0
- package/dist/components/core/model/FieldMetaDataForm.tsx +3509 -0
- package/dist/components/core/model/FieldSelector.tsx +62 -0
- package/dist/components/core/model/ModelListViewData.tsx +384 -0
- package/dist/components/core/model/ModelMetaData.tsx +921 -0
- package/dist/components/core/module/CreateModule.tsx +617 -0
- package/dist/components/core/module/ModuleListViewData.tsx +431 -0
- package/dist/components/core/solid-ai/SolidAiMainWrapper.tsx +8 -0
- package/dist/components/core/solid-ai/SolidXAIIcon.tsx +37 -0
- package/dist/components/core/users/CreateUser.tsx +467 -0
- package/dist/components/core/users/CreateUserRole.tsx +212 -0
- package/dist/components/core/users/UserListView.tsx +376 -0
- package/dist/components/layout/AdminLayout.tsx +57 -0
- package/dist/components/layout/AdminSidebar.tsx +65 -0
- package/dist/components/layout/AppConfig.tsx +104 -0
- package/dist/components/layout/AppSidebar.tsx +232 -0
- package/dist/components/layout/ButtonLoader.tsx +7 -0
- package/dist/components/layout/CustomPagination.tsx +55 -0
- package/dist/components/layout/DashboardHeader.tsx +89 -0
- package/dist/components/layout/FilterMenu.tsx +122 -0
- package/dist/components/layout/Footer.tsx +13 -0
- package/dist/components/layout/GlobalSearch.tsx +37 -0
- package/dist/components/layout/Header.tsx +8 -0
- package/dist/components/layout/Layout.tsx +205 -0
- package/dist/components/layout/ListingHeader.tsx +204 -0
- package/dist/components/layout/Loader.tsx +16 -0
- package/dist/components/layout/UserSidebar.tsx +53 -0
- package/dist/components/layout/context/layoutcontext.tsx +52 -0
- package/dist/components/layout/navbar-one.tsx +258 -0
- package/dist/components/layout/navbar-two-menu.tsx +72 -0
- package/dist/components/layout/navbar-two.tsx +37 -0
- package/dist/components/layout/user-profile-menu.tsx +213 -0
- package/dist/components/layout/user-profile.tsx +7 -0
- package/dist/components/modelsComponents/filterIcon.tsx +9 -0
- package/dist/constants/error-messages.ts +238 -0
- package/dist/declarations.d.ts +22 -0
- package/dist/helpers/AppTitle.tsx +12 -0
- package/dist/helpers/ToastContainer.tsx +94 -0
- package/dist/helpers/autoCompleteVirtualScroll.ts +41 -0
- package/dist/helpers/countries.tsx +260 -0
- package/dist/helpers/downloadFileWithProgress.ts +91 -0
- package/dist/helpers/downloadMediaFile.tsx +21 -0
- package/dist/helpers/getAcceptedFileTypes.tsx +22 -0
- package/dist/helpers/getRandomColors.tsx +68 -0
- package/dist/helpers/helpers.ts +61 -0
- package/dist/helpers/hydrateRelationRules.ts +120 -0
- package/dist/helpers/permissions.ts +7 -0
- package/dist/helpers/registry.ts +337 -0
- package/dist/helpers/resendOtpHelper.tsx +5 -0
- package/dist/helpers/revalidate.ts +7 -0
- package/dist/helpers/rolesHelper.ts +17 -0
- package/dist/helpers/solidIcons.tsx +1831 -0
- package/dist/helpers/updatePasswordField.ts +41 -0
- package/dist/index.ts +421 -0
- package/dist/nextAuth/authProviders.d.ts.map +1 -1
- package/dist/nextAuth/authProviders.js +6 -5
- package/dist/nextAuth/authProviders.js.map +1 -1
- package/dist/nextAuth/authProviders.tsx +232 -0
- package/dist/nextAuth/handleLogout.tsx +39 -0
- package/dist/nextAuth/refreshAccessToken.tsx +28 -0
- package/dist/redux/api/aiInteractionApi.ts +59 -0
- package/dist/redux/api/authApi.ts +131 -0
- package/dist/redux/api/dashboardApi.ts +56 -0
- package/dist/redux/api/dashboardQuestionApi.ts +17 -0
- package/dist/redux/api/exportTemplateApi.tsx +59 -0
- package/dist/redux/api/fetchBaseQuery.tsx +118 -0
- package/dist/redux/api/fieldApi.ts +86 -0
- package/dist/redux/api/importTransactionApi.tsx +69 -0
- package/dist/redux/api/mediaApi.ts +55 -0
- package/dist/redux/api/mediaStorageProviderApi.ts +55 -0
- package/dist/redux/api/modelApi.ts +80 -0
- package/dist/redux/api/moduleApi.ts +72 -0
- package/dist/redux/api/permissionApi.ts +32 -0
- package/dist/redux/api/pincodeApi.tsx +56 -0
- package/dist/redux/api/roleApi.ts +58 -0
- package/dist/redux/api/solidActionApi.ts +66 -0
- package/dist/redux/api/solidChatterMessageApi.ts +25 -0
- package/dist/redux/api/solidEntityApi.tsx +164 -0
- package/dist/redux/api/solidMenuApi.ts +71 -0
- package/dist/redux/api/solidServiceApi.ts +31 -0
- package/dist/redux/api/solidSettingsApi.tsx +83 -0
- package/dist/redux/api/solidViewApi.ts +73 -0
- package/dist/redux/api/stateApi.tsx +56 -0
- package/dist/redux/api/testApi.ts +21 -0
- package/dist/redux/api/userApi.ts +135 -0
- package/dist/redux/features/authSlice.ts +19 -0
- package/dist/redux/features/dataViewSlice.ts +26 -0
- package/dist/redux/features/navbarSlice.ts +21 -0
- package/dist/redux/features/popupSlice.ts +37 -0
- package/dist/redux/features/settingsSlice.ts +60 -0
- package/dist/redux/features/themeSlice.ts +17 -0
- package/dist/redux/features/userSlice.ts +28 -0
- package/dist/redux/hooks/useSolidPopup.ts +20 -0
- package/dist/redux/store/defaultStoreConfig.ts +62 -0
- package/dist/styles.ts +4 -0
- package/dist/types/handlebars.d.ts +4 -0
- package/dist/types/index.d.ts +76 -0
- package/dist/types/layout.d.ts +94 -0
- package/dist/types/next-auth.d.ts +0 -0
- package/dist/types/next.d.ts +46 -0
- package/dist/types/solid-core.d.ts +320 -0
- package/package.json +1 -1
- package/src/components/auth/SolidLogin.tsx +26 -13
- package/src/nextAuth/authProviders.tsx +9 -5
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { usePathname } from 'next/navigation';
|
|
4
|
+
export const HeaderDynamicTitles = () => {
|
|
5
|
+
const path = usePathname();
|
|
6
|
+
const getHeading = path.split('/').slice(-2, -1)[0].replace(/-/g, ' ').replace(/\b\w/g, char => char.toUpperCase());
|
|
7
|
+
|
|
8
|
+
return (
|
|
9
|
+
<div className='text-xl font-bold'>
|
|
10
|
+
All {getHeading}s
|
|
11
|
+
</div>
|
|
12
|
+
)
|
|
13
|
+
}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import ReactMarkdown from 'react-markdown';
|
|
5
|
+
import remarkGfm from 'remark-gfm';
|
|
6
|
+
import { Prism as SyntaxHighlighter } from 'react-syntax-highlighter';
|
|
7
|
+
import { oneDark } from 'react-syntax-highlighter/dist/esm/styles/prism';
|
|
8
|
+
|
|
9
|
+
type MarkdownViewerProps = { data: string };
|
|
10
|
+
|
|
11
|
+
// Custom CodeBlock renderer
|
|
12
|
+
const CodeBlock = ({ inline, className, children, ...props }: any) => {
|
|
13
|
+
const codeString = String(children).replace(/\n$/, '');
|
|
14
|
+
const isFenced = !inline && /language-(\w+)/.test(className || '');
|
|
15
|
+
const match = /language-(\w+)/.exec(className || '');
|
|
16
|
+
const language = match?.[1] ?? '';
|
|
17
|
+
|
|
18
|
+
if (inline || !isFenced) {
|
|
19
|
+
// Inline code or non-fenced code
|
|
20
|
+
return (
|
|
21
|
+
<code className="bg-gray-100 px-1 py-0.5 rounded text-sm">
|
|
22
|
+
{children}
|
|
23
|
+
</code>
|
|
24
|
+
);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
// Fenced code block
|
|
28
|
+
return (
|
|
29
|
+
<div className="relative group my-4">
|
|
30
|
+
<button
|
|
31
|
+
className="absolute right-2 top-2 px-2 py-1 text-xs rounded bg-white text-black transition"
|
|
32
|
+
style={{ cursor: 'pointer',right:0 }}
|
|
33
|
+
onClick={() => navigator.clipboard.writeText(codeString)}
|
|
34
|
+
>
|
|
35
|
+
Copy
|
|
36
|
+
</button>
|
|
37
|
+
<SyntaxHighlighter
|
|
38
|
+
language={language}
|
|
39
|
+
style={oneDark}
|
|
40
|
+
PreTag="div"
|
|
41
|
+
customStyle={{
|
|
42
|
+
borderRadius: '0.5rem',
|
|
43
|
+
padding: '1rem',
|
|
44
|
+
fontSize: '0.85rem',
|
|
45
|
+
background: '#282c34',
|
|
46
|
+
}}
|
|
47
|
+
{...props}
|
|
48
|
+
>
|
|
49
|
+
{codeString}
|
|
50
|
+
</SyntaxHighlighter>
|
|
51
|
+
</div>
|
|
52
|
+
);
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
const MarkdownViewer: React.FC<MarkdownViewerProps> = ({ data }) => (
|
|
56
|
+
<ReactMarkdown
|
|
57
|
+
remarkPlugins={[remarkGfm]} // Enable GitHub-style tables
|
|
58
|
+
className="markdown-view prose prose-invert max-w-none"
|
|
59
|
+
components={{
|
|
60
|
+
code: CodeBlock,
|
|
61
|
+
table: (props) => (
|
|
62
|
+
<div className="overflow-x-auto my-4">
|
|
63
|
+
<table className="min-w-full border border-gray-700 text-sm">
|
|
64
|
+
{props.children}
|
|
65
|
+
</table>
|
|
66
|
+
</div>
|
|
67
|
+
),
|
|
68
|
+
th: (props) => (
|
|
69
|
+
<th className="border border-gray-700 px-3 py-1 font-semibold text-left bg-gray-800" style={{color:"#fff"}}>
|
|
70
|
+
{props.children}
|
|
71
|
+
</th>
|
|
72
|
+
),
|
|
73
|
+
td: (props) => (
|
|
74
|
+
<td className="border border-gray-700 px-3 py-1 align-top">
|
|
75
|
+
{props.children}
|
|
76
|
+
</td>
|
|
77
|
+
),
|
|
78
|
+
}}
|
|
79
|
+
>
|
|
80
|
+
{data}
|
|
81
|
+
</ReactMarkdown>
|
|
82
|
+
);
|
|
83
|
+
|
|
84
|
+
export default MarkdownViewer;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { AutoComplete } from "primereact/autocomplete";
|
|
3
|
+
import { useEffect, useState } from "react";
|
|
4
|
+
import { getVirtualScrollerOptions } from "../../helpers/autoCompleteVirtualScroll";
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
// UsesCases
|
|
8
|
+
// Suppose you have a moduelId field In create Dto then you need to creaate a module key in firmik and use that to store the autocomplete state and along with it update the moduleId Field with id
|
|
9
|
+
// In case of relationType the Id field will always will be id
|
|
10
|
+
// Else the value will be whatever valuekey use passed
|
|
11
|
+
|
|
12
|
+
export const MultipleSelectAutoCompleteField = ({ formik, isFormFieldValid, relationField, fieldName, fieldNameId, labelKey, valueKey, searchData, existingData, additionalAction }: any) => {
|
|
13
|
+
|
|
14
|
+
const [selectedItem, setSelectedItem] = useState(existingData && existingData.length > 0 && existingData.map((i: any) => ({ label: i, value: i })));
|
|
15
|
+
const [filteredItem, setFilteredItem] = useState([]);
|
|
16
|
+
useEffect(() => {
|
|
17
|
+
// if (existingData) {
|
|
18
|
+
setSelectedItem(existingData && existingData.length > 0 && existingData.map((i: any) => ({ label: i, value: i })))
|
|
19
|
+
// formik.setFieldValue(fieldName, existingData);
|
|
20
|
+
|
|
21
|
+
// }
|
|
22
|
+
}, [existingData])
|
|
23
|
+
const searchItems = async (event: any) => {
|
|
24
|
+
const data = await searchData(event);
|
|
25
|
+
setFilteredItem(data);
|
|
26
|
+
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
return (
|
|
32
|
+
|
|
33
|
+
<AutoComplete
|
|
34
|
+
multiple
|
|
35
|
+
value={selectedItem}
|
|
36
|
+
suggestions={filteredItem}
|
|
37
|
+
invalid={isFormFieldValid(formik, fieldName)}
|
|
38
|
+
completeMethod={searchItems}
|
|
39
|
+
// virtualScrollerOptions={{ itemSize: 38 }}
|
|
40
|
+
virtualScrollerOptions={getVirtualScrollerOptions({
|
|
41
|
+
itemsLength: filteredItem.length,
|
|
42
|
+
})}
|
|
43
|
+
className="solid-standard-autocomplete w-full"
|
|
44
|
+
// style={{
|
|
45
|
+
// maxHeight: 39.67
|
|
46
|
+
// }}
|
|
47
|
+
field={labelKey}
|
|
48
|
+
dropdown
|
|
49
|
+
onChange={(e) => {
|
|
50
|
+
setSelectedItem(e.value);
|
|
51
|
+
if (additionalAction) {
|
|
52
|
+
additionalAction(e);
|
|
53
|
+
}
|
|
54
|
+
if (relationField === true) {
|
|
55
|
+
formik.setFieldValue(fieldName, e.value);
|
|
56
|
+
// formik.setFieldValue(fieldNameId, e.value.id);
|
|
57
|
+
} else {
|
|
58
|
+
const mediaTypes = e.value.map((i: any) => i[valueKey]);
|
|
59
|
+
formik.setFieldValue(fieldName, mediaTypes);
|
|
60
|
+
}
|
|
61
|
+
}}
|
|
62
|
+
/>
|
|
63
|
+
)
|
|
64
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import Link from "next/link";
|
|
4
|
+
|
|
5
|
+
export const NotFound = () => {
|
|
6
|
+
return (
|
|
7
|
+
<div>
|
|
8
|
+
<div className="d-flex align-items-center justify-content-center vh-100">
|
|
9
|
+
<div className="text-center">
|
|
10
|
+
<h1 className="display-1 fw-bold">404</h1>
|
|
11
|
+
<p className="fs-3">
|
|
12
|
+
<span className="text-danger">Opps!</span> Page not found.
|
|
13
|
+
</p>
|
|
14
|
+
<p className="lead">The page you are looking for does not exist.</p>
|
|
15
|
+
<Link href="/" className="btn btn-primary">
|
|
16
|
+
Go Home
|
|
17
|
+
</Link>
|
|
18
|
+
</div>
|
|
19
|
+
</div>
|
|
20
|
+
</div>
|
|
21
|
+
);
|
|
22
|
+
};
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { AutoComplete } from "primereact/autocomplete";
|
|
3
|
+
import { useEffect, useState } from "react";
|
|
4
|
+
import { getVirtualScrollerOptions } from "../../helpers/autoCompleteVirtualScroll";
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
// UsesCases
|
|
9
|
+
// Suppose you have a moduelId field In create Dto then you need to creaate a module key in firmik and use that to store the autocomplete state and along with it update the moduleId Field with id
|
|
10
|
+
// In case of relationType the Id field will always will be id
|
|
11
|
+
// Else the value will be whatever valuekey use passed
|
|
12
|
+
|
|
13
|
+
export const SingleSelectAutoCompleteField = ({ disabled, formik, isFormFieldValid, relationField, fieldName, fieldNameId, labelKey, valueKey, searchData, existingData, additionalAction, formErrors }: any) => {
|
|
14
|
+
|
|
15
|
+
const [selectedItem, setSelectedItem] = useState(existingData);
|
|
16
|
+
const [filteredItem, setFilteredItem] = useState([]);
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
// if (existingData) {
|
|
19
|
+
setSelectedItem(existingData)
|
|
20
|
+
// formik.setFieldValue(fieldName, existingData);
|
|
21
|
+
|
|
22
|
+
// }
|
|
23
|
+
}, [existingData])
|
|
24
|
+
const searchItems = async (event: any) => {
|
|
25
|
+
const data = await searchData(event);
|
|
26
|
+
setFilteredItem(data);
|
|
27
|
+
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
return (
|
|
32
|
+
<>
|
|
33
|
+
<AutoComplete
|
|
34
|
+
disabled={disabled ? disabled : false}
|
|
35
|
+
value={selectedItem}
|
|
36
|
+
suggestions={filteredItem}
|
|
37
|
+
// invalid={(isFormFieldValid(formik, fieldName) || (formErrors[fieldName]))}
|
|
38
|
+
invalid={isFormFieldValid(formik, fieldName)}
|
|
39
|
+
|
|
40
|
+
completeMethod={searchItems}
|
|
41
|
+
// virtualScrollerOptions={{ itemSize: 38 }}
|
|
42
|
+
virtualScrollerOptions={getVirtualScrollerOptions({
|
|
43
|
+
itemsLength: filteredItem.length,
|
|
44
|
+
})}
|
|
45
|
+
|
|
46
|
+
// style={{
|
|
47
|
+
// maxHeight: 39.67
|
|
48
|
+
// }}
|
|
49
|
+
field={labelKey}
|
|
50
|
+
dropdown
|
|
51
|
+
onChange={(e) => {
|
|
52
|
+
// formik.handleChange(e)
|
|
53
|
+
setSelectedItem(e.value);
|
|
54
|
+
if (additionalAction) {
|
|
55
|
+
additionalAction(e);
|
|
56
|
+
}
|
|
57
|
+
if (relationField === true) {
|
|
58
|
+
formik.setFieldValue(fieldName, e.value);
|
|
59
|
+
formik.setFieldValue(fieldNameId, e.value.id);
|
|
60
|
+
} else {
|
|
61
|
+
formik.setFieldValue(fieldName, e.value[valueKey]);
|
|
62
|
+
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
}}
|
|
66
|
+
className="solid-standard-autocomplete"
|
|
67
|
+
/>
|
|
68
|
+
|
|
69
|
+
</>
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
)
|
|
73
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use client"
|
|
2
|
+
import { signIn } from 'next-auth/react'
|
|
3
|
+
import { usePathname, useRouter } from 'next/navigation';
|
|
4
|
+
import { Button } from 'primereact/button'
|
|
5
|
+
import React from 'react'
|
|
6
|
+
|
|
7
|
+
export const SocialMediaLogin = () => {
|
|
8
|
+
const router = useRouter();
|
|
9
|
+
const pathname = usePathname();
|
|
10
|
+
return (
|
|
11
|
+
<div className="flex justify-content-center mt-4 gap-3">
|
|
12
|
+
<Button
|
|
13
|
+
className='flex justify-content-center gap-3 w-full google-auth-button'
|
|
14
|
+
outlined
|
|
15
|
+
severity="secondary"
|
|
16
|
+
onClick={() => router.push(`${process.env.NEXT_PUBLIC_BACKEND_API_URL}/api/iam/google/connect`)}
|
|
17
|
+
// onClick={()=>signIn('google', {callbackUrl :'https://uat-api.lm.solidxai.com/api/iam/google/connect'})}
|
|
18
|
+
>
|
|
19
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
|
|
20
|
+
<g clipPath="url(#clip0_3520_3825)">
|
|
21
|
+
<path d="M23.0938 9.91355L13.3044 9.91309C12.8721 9.91309 12.5217 10.2634 12.5217 10.6957V13.823C12.5217 14.2552 12.8721 14.6056 13.3044 14.6056H18.8171C18.2135 16.1722 17.0868 17.4842 15.6493 18.3178L18 22.387C21.7707 20.2062 24 16.3799 24 12.0965C24 11.4866 23.955 11.0506 23.8651 10.5597C23.7968 10.1867 23.4729 9.91355 23.0938 9.91355Z" fill="#167EE6" />
|
|
22
|
+
<path d="M12 19.3047C9.30218 19.3047 6.94699 17.8306 5.68207 15.6494L1.61304 17.9948C3.68374 21.5836 7.56283 24.0003 12 24.0003C14.1768 24.0003 16.2307 23.4143 18 22.3929V22.3873L15.6494 18.3181C14.5742 18.9417 13.3299 19.3047 12 19.3047Z" fill="#12B347" />
|
|
23
|
+
<path d="M18 22.3922V22.3866L15.6494 18.3174C14.5741 18.941 13.33 19.304 12 19.304V23.9996C14.1767 23.9996 16.2308 23.4135 18 22.3922Z" fill="#0F993E" />
|
|
24
|
+
<path d="M4.69566 12.0003C4.69566 10.6705 5.05856 9.42637 5.68205 8.3512L1.61302 6.00586C0.586031 7.76962 0 9.81797 0 12.0003C0 14.1826 0.586031 16.2309 1.61302 17.9947L5.68205 15.6494C5.05856 14.5742 4.69566 13.3301 4.69566 12.0003Z" fill="#FFD500" />
|
|
25
|
+
<path d="M12 4.69566C13.7593 4.69566 15.3753 5.32078 16.6375 6.36061C16.9488 6.61711 17.4014 6.59859 17.6867 6.31336L19.9024 4.09758C20.2261 3.77395 20.203 3.24422 19.8573 2.94431C17.7425 1.10967 14.991 0 12 0C7.56283 0 3.68374 2.41673 1.61304 6.00558L5.68207 8.35092C6.94699 6.16969 9.30218 4.69566 12 4.69566Z" fill="#FF4B26" />
|
|
26
|
+
<path d="M16.6374 6.36061C16.9488 6.61711 17.4015 6.59859 17.6866 6.31336L19.9024 4.09758C20.226 3.77395 20.2029 3.24422 19.8573 2.94431C17.7425 1.10963 14.991 0 12 0V4.69566C13.7592 4.69566 15.3752 5.32078 16.6374 6.36061Z" fill="#D93F21" />
|
|
27
|
+
</g>
|
|
28
|
+
<defs>
|
|
29
|
+
<clipPath id="clip0_3520_3825">
|
|
30
|
+
<rect width="24" height="24" fill="white" />
|
|
31
|
+
</clipPath>
|
|
32
|
+
</defs>
|
|
33
|
+
</svg>
|
|
34
|
+
{pathname.includes("register") ? "Continue With Google" : "Sign In with Google"}
|
|
35
|
+
</Button>
|
|
36
|
+
{/* <Button icon={() => (
|
|
37
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" xlinkHref="http://www.w3.org/1999/xlink">
|
|
38
|
+
<rect width="24" height="24" fill="url(#pattern0_3520_3835)" />
|
|
39
|
+
<defs>
|
|
40
|
+
<pattern id="pattern0_3520_3835" patternContentUnits="objectBoundingBox" width="1" height="1">
|
|
41
|
+
<use xlinkHref="#image0_3520_3835" transform="scale(0.00195312)" />
|
|
42
|
+
</pattern>
|
|
43
|
+
<image id="image0_3520_3835" width="512" height="512" xlinkHref="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAMAAADDpiTIAAAAA3NCSVQICAjb4U/gAAAACXBIWXMAATcvAAE3LwE2dZYYAAAAGXRFWHRTb2Z0d2FyZQB3d3cuaW5rc2NhcGUub3Jnm+48GgAAAwBQTFRF////AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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kBKuJKyXY8jRdxD2Y43s5EqHqf8lyW7IWVkzqL8zIY2SCEF71N+ovJXSClNv6T82G+QYg5cTfl/Y5Byjiyl/GAcUlCXUsp/PICUdNz3lH8bjxTVYS2FnICU1fZbykSksJbLGYEtC2Y9M3XCPTcNu/isXice1fW8q++dOnN+SSUjMQkprflihqny06dvOb1VBrYnbbe2p4+Zu5XhmoQUt/ubDEflG3efd1g2diWn4zUzShiaB9KQ6rIfo3srHunXADXX/NyJyxmCrYMgwNVVdKli9oh2qLW0Y+5bTMeWHw35t54b6MrGaX3yUVft7/iUDr2+O+Q/Dv6SLlQ8d2YuktNm1Ed0ZEwG5AeNnmXQql+/pCGC0P6BdQze5rMhPzZgA4M0/9q9EZjsfi9WMVhftoP81L6vMSirxh6KgO113WcM0PMNID+XNmwLA1Ax45RMuNBxykYGo+QsyPYc/D6T9f4VjeFM3vmvVjNpVeMKIduXOXQNk/Dt6LZwbL9Ri5mcdzpAdqzwzjLWzdane2UgBGknTi1lnc3vA9m5vR+rZu0V/6YRQpN/7jObWRcf9oXsWruXWTsr72uDkOX1nf49ayfx2ulpkBo59pFNrKHqd0cdkYYoZPV4eDVrbMUd+0NqLn/gm9y1DU9f2BQRSj/x1lnfcddWPdEzHVJLre79ljtR/cmYk7IQvbTWF06eX8kd2jr7uvZpkLrIPP66ojX8b1WLpg/7RQEMqfeLEdNnvr90E3+sevGLowd1qgdJSsuBjyxK8AeVC6de0akerMreq12XMy6/dvB5fTofcVAuzPpfTkq1f/bQtVEAAAAASUVORK5CYII=" />
|
|
44
|
+
</defs>
|
|
45
|
+
</svg>
|
|
46
|
+
)}
|
|
47
|
+
outlined
|
|
48
|
+
severity="secondary"
|
|
49
|
+
>
|
|
50
|
+
</Button> */}
|
|
51
|
+
</div>
|
|
52
|
+
)
|
|
53
|
+
}
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import Link from "next/link";
|
|
4
|
+
import { usePathname, useRouter, useSearchParams } from "next/navigation";
|
|
5
|
+
import { BreadCrumb } from "primereact/breadcrumb";
|
|
6
|
+
import { useEffect, useState } from "react";
|
|
7
|
+
|
|
8
|
+
interface BreadcrumbItem {
|
|
9
|
+
label: string;
|
|
10
|
+
link?: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
interface Props {
|
|
14
|
+
solidFormViewMetaData?: any;
|
|
15
|
+
initialEntityData?: any;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const toTitleCase = (str: string) => {
|
|
19
|
+
return str
|
|
20
|
+
.replace(/[-_]/g, " ")
|
|
21
|
+
.replace(/([a-z])([A-Z])/g, "$1 $2")
|
|
22
|
+
.replace(/\b\w/g, (char) => char.toUpperCase());
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
const truncateText = (text: string, maxLength: number = 15) => {
|
|
26
|
+
if (text.length <= maxLength) return text;
|
|
27
|
+
return `${text.substring(0, maxLength)}...`;
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
export const SolidBreadcrumb = (props: Props) => {
|
|
31
|
+
const { solidFormViewMetaData, initialEntityData } = props;
|
|
32
|
+
|
|
33
|
+
const modelMetadata = solidFormViewMetaData?.data?.solidView?.model;
|
|
34
|
+
const pathname = usePathname();
|
|
35
|
+
const router = useRouter();
|
|
36
|
+
const searchParams = useSearchParams();
|
|
37
|
+
const segments = pathname.split("/").filter(Boolean);
|
|
38
|
+
|
|
39
|
+
let userKeyFieldValue: string | null = null;
|
|
40
|
+
|
|
41
|
+
if (modelMetadata?.userKeyField) {
|
|
42
|
+
const userKeyFieldName = modelMetadata.userKeyField.name;
|
|
43
|
+
if (userKeyFieldName && initialEntityData?.[userKeyFieldName] !== undefined) {
|
|
44
|
+
userKeyFieldValue = initialEntityData[userKeyFieldName];
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
const queryUserKeyField = searchParams.get("userKeyField");
|
|
49
|
+
const isNewForm = pathname.endsWith("/new");
|
|
50
|
+
|
|
51
|
+
useEffect(() => {
|
|
52
|
+
if (!isNewForm && userKeyFieldValue && !queryUserKeyField) {
|
|
53
|
+
const params = new URLSearchParams(searchParams.toString());
|
|
54
|
+
params.set("userKeyField", userKeyFieldValue);
|
|
55
|
+
const newUrl = `${pathname}?${params.toString()}`;
|
|
56
|
+
router.push(newUrl, { scroll: false });
|
|
57
|
+
}
|
|
58
|
+
}, [pathname, userKeyFieldValue, queryUserKeyField, isNewForm, router]);
|
|
59
|
+
|
|
60
|
+
const [fromView, setFromView] = useState<"list" | "kanban" | null>(null);
|
|
61
|
+
|
|
62
|
+
useEffect(() => {
|
|
63
|
+
if (typeof window !== "undefined") {
|
|
64
|
+
const storedView = sessionStorage.getItem("fromView");
|
|
65
|
+
if (storedView === "list" || storedView === "kanban") {
|
|
66
|
+
setFromView(storedView);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}, []);
|
|
70
|
+
|
|
71
|
+
const breadcrumbItems: BreadcrumbItem[] = [];
|
|
72
|
+
|
|
73
|
+
if (segments.length >= 4 && segments[0] === "admin" && segments[1] === "core") {
|
|
74
|
+
const moduleName = segments[2];
|
|
75
|
+
const modelName = segments[3];
|
|
76
|
+
const modelDisplayName = modelMetadata?.displayName || toTitleCase(modelName);
|
|
77
|
+
|
|
78
|
+
// Link to model list or kanban view based on stored view
|
|
79
|
+
breadcrumbItems.push({
|
|
80
|
+
label: modelDisplayName,
|
|
81
|
+
link: `/admin/core/${moduleName}/${modelName}/${fromView || "list"}`,
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
breadcrumbItems.push({
|
|
85
|
+
label: isNewForm
|
|
86
|
+
? `Add ${modelDisplayName} Details`
|
|
87
|
+
: decodeURIComponent(queryUserKeyField || userKeyFieldValue || segments[segments.length - 1] || ""),
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
const items = breadcrumbItems.map((item, index) => ({
|
|
92
|
+
label: item.label,
|
|
93
|
+
...(item.link
|
|
94
|
+
? {
|
|
95
|
+
template: () => {
|
|
96
|
+
const fullLabel = item.label;
|
|
97
|
+
const truncatedLabel = truncateText(fullLabel, 10);
|
|
98
|
+
const shouldTruncate = fullLabel.length > 10;
|
|
99
|
+
|
|
100
|
+
const handleClick = (e: any) => {
|
|
101
|
+
e.preventDefault();
|
|
102
|
+
// prefer stored full return url which preserves query params (action/menu)
|
|
103
|
+
if (typeof window !== "undefined") {
|
|
104
|
+
const storedFullUrl = sessionStorage.getItem("fromViewUrl");
|
|
105
|
+
if (storedFullUrl) {
|
|
106
|
+
router.push(storedFullUrl);
|
|
107
|
+
return;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
router.push(item.link!);
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
return (
|
|
114
|
+
<a onClick={handleClick}>
|
|
115
|
+
<p
|
|
116
|
+
className={`${index === 1 ? 'font-bold' : 'font-normal'} ${shouldTruncate ? 'cursor-pointer' : ''}`}
|
|
117
|
+
title={shouldTruncate ? fullLabel : undefined}
|
|
118
|
+
>
|
|
119
|
+
{truncatedLabel}
|
|
120
|
+
</p>
|
|
121
|
+
</a>
|
|
122
|
+
);
|
|
123
|
+
},
|
|
124
|
+
}
|
|
125
|
+
: {}),
|
|
126
|
+
}));
|
|
127
|
+
|
|
128
|
+
return <BreadCrumb model={items} className="solid-breadcrumb" />;
|
|
129
|
+
};
|