@gen-epix/ui-client-common 4.0.0
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/LICENSE +287 -0
- package/README.md +93 -0
- package/dist/@types/environment.d.ts +7 -0
- package/dist/@types/mui.d.ts +9 -0
- package/dist/@types/ui.d.ts +4 -0
- package/dist/@types/vite-env.d.ts +3 -0
- package/dist/_chunks/ApplicationFooter.js +119 -0
- package/dist/_chunks/ApplicationFooter.js.map +1 -0
- package/dist/_chunks/Breadcrumbs.js +40 -0
- package/dist/_chunks/Breadcrumbs.js.map +1 -0
- package/dist/_chunks/CrudPage.js +535 -0
- package/dist/_chunks/CrudPage.js.map +1 -0
- package/dist/_chunks/GeoFilter.js +38 -0
- package/dist/_chunks/GeoFilter.js.map +1 -0
- package/dist/_chunks/Notifications.js +152 -0
- package/dist/_chunks/Notifications.js.map +1 -0
- package/dist/_chunks/OutageList.js +78 -0
- package/dist/_chunks/OutageList.js.map +1 -0
- package/dist/_chunks/OutageUtil.js +47 -0
- package/dist/_chunks/OutageUtil.js.map +1 -0
- package/dist/_chunks/QueryClientProvider.js +18 -0
- package/dist/_chunks/QueryClientProvider.js.map +1 -0
- package/dist/_chunks/QueryClientService.js +655 -0
- package/dist/_chunks/QueryClientService.js.map +1 -0
- package/dist/_chunks/Table.js +4565 -0
- package/dist/_chunks/Table.js.map +1 -0
- package/dist/_chunks/TableUtil.js +626 -0
- package/dist/_chunks/TableUtil.js.map +1 -0
- package/dist/_chunks/TextFilter.js +249 -0
- package/dist/_chunks/TextFilter.js.map +1 -0
- package/dist/_chunks/UserInvitationsAdminPage.js +273 -0
- package/dist/_chunks/UserInvitationsAdminPage.js.map +1 -0
- package/dist/_chunks/_baseAssignValue.js +19 -0
- package/dist/_chunks/_baseAssignValue.js.map +1 -0
- package/dist/_chunks/_baseFlatten.js +27 -0
- package/dist/_chunks/_baseFlatten.js.map +1 -0
- package/dist/_chunks/_baseGet.js +280 -0
- package/dist/_chunks/_baseGet.js.map +1 -0
- package/dist/_chunks/_baseIteratee.js +275 -0
- package/dist/_chunks/_baseIteratee.js.map +1 -0
- package/dist/_chunks/_baseUnset.js +37 -0
- package/dist/_chunks/_baseUnset.js.map +1 -0
- package/dist/_chunks/_cacheHas.js +65 -0
- package/dist/_chunks/_cacheHas.js.map +1 -0
- package/dist/_chunks/_setToString.js +71 -0
- package/dist/_chunks/_setToString.js.map +1 -0
- package/dist/_chunks/chunk-KS7C4IRE.js +3829 -0
- package/dist/_chunks/chunk-KS7C4IRE.js.map +1 -0
- package/dist/_chunks/format.js +1135 -0
- package/dist/_chunks/format.js.map +1 -0
- package/dist/_chunks/index.esm.js +1179 -0
- package/dist/_chunks/index.esm.js.map +1 -0
- package/dist/_chunks/isArrayLike.js +255 -0
- package/dist/_chunks/isArrayLike.js.map +1 -0
- package/dist/_chunks/isObject.js +13 -0
- package/dist/_chunks/isObject.js.map +1 -0
- package/dist/_chunks/isObjectLike.js +43 -0
- package/dist/_chunks/isObjectLike.js.map +1 -0
- package/dist/_chunks/isSymbol.js +14 -0
- package/dist/_chunks/isSymbol.js.map +1 -0
- package/dist/_chunks/last.js +13 -0
- package/dist/_chunks/last.js.map +1 -0
- package/dist/_chunks/middleware.js +111 -0
- package/dist/_chunks/middleware.js.map +1 -0
- package/dist/_chunks/oidc-client-ts.js +1843 -0
- package/dist/_chunks/oidc-client-ts.js.map +1 -0
- package/dist/_chunks/omit.js +293 -0
- package/dist/_chunks/omit.js.map +1 -0
- package/dist/_chunks/query.js +769 -0
- package/dist/_chunks/query.js.map +1 -0
- package/dist/_chunks/react-oidc-context.js +201 -0
- package/dist/_chunks/react-oidc-context.js.map +1 -0
- package/dist/_chunks/react.js +11 -0
- package/dist/_chunks/react.js.map +1 -0
- package/dist/_chunks/rolldown-runtime.js +13 -0
- package/dist/_chunks/tableStore.js +822 -0
- package/dist/_chunks/tableStore.js.map +1 -0
- package/dist/_chunks/toDate.js +18 -0
- package/dist/_chunks/toDate.js.map +1 -0
- package/dist/_chunks/uniq.js +44 -0
- package/dist/_chunks/uniq.js.map +1 -0
- package/dist/_chunks/useColumnsMenu.js +159 -0
- package/dist/_chunks/useColumnsMenu.js.map +1 -0
- package/dist/_chunks/useMutation.js +110 -0
- package/dist/_chunks/useMutation.js.map +1 -0
- package/dist/_chunks/useQueryMemo.js +325 -0
- package/dist/_chunks/useQueryMemo.js.map +1 -0
- package/dist/_chunks/vanilla.js +20 -0
- package/dist/_chunks/vanilla.js.map +1 -0
- package/dist/_chunks/yup.js +73 -0
- package/dist/_chunks/yup.js.map +1 -0
- package/dist/classes/TableEventBus/TableEventBus.d.ts +12 -0
- package/dist/classes/TableEventBus/index.d.ts +1 -0
- package/dist/classes/TableEventBus/index.js +7 -0
- package/dist/classes/TableEventBus/index.js.map +1 -0
- package/dist/classes/abstracts/FilterAbstract/FilterAbstract.d.ts +27 -0
- package/dist/classes/abstracts/FilterAbstract/index.d.ts +1 -0
- package/dist/classes/abstracts/FilterAbstract/index.js +37 -0
- package/dist/classes/abstracts/FilterAbstract/index.js.map +1 -0
- package/dist/classes/filters/BooleanFilter.d.ts +11 -0
- package/dist/classes/filters/DateFilter.d.ts +26 -0
- package/dist/classes/filters/GeoFilter.d.ts +17 -0
- package/dist/classes/filters/MultiSelectFilter.d.ts +19 -0
- package/dist/classes/filters/NumberRangeFilter.d.ts +17 -0
- package/dist/classes/filters/TextFilter.d.ts +10 -0
- package/dist/classes/filters/index.d.ts +6 -0
- package/dist/classes/filters/index.js +3 -0
- package/dist/classes/services/ApiService/ApiService.d.ts +19 -0
- package/dist/classes/services/ApiService/index.d.ts +1 -0
- package/dist/classes/services/ApiService/index.js +21 -0
- package/dist/classes/services/ApiService/index.js.map +1 -0
- package/dist/classes/services/AuthenticationService/AuthenticationService.d.ts +18 -0
- package/dist/classes/services/AuthenticationService/index.d.ts +1 -0
- package/dist/classes/services/AuthenticationService/index.js +694 -0
- package/dist/classes/services/AuthenticationService/index.js.map +1 -0
- package/dist/classes/services/AuthorizationService/AuthorizationService.d.ts +15 -0
- package/dist/classes/services/AuthorizationService/index.d.ts +1 -0
- package/dist/classes/services/AuthorizationService/index.js +36 -0
- package/dist/classes/services/AuthorizationService/index.js.map +1 -0
- package/dist/classes/services/BackendVersionService/BackendVersionService.d.ts +8 -0
- package/dist/classes/services/BackendVersionService/index.d.ts +1 -0
- package/dist/classes/services/BackendVersionService/index.js +17 -0
- package/dist/classes/services/BackendVersionService/index.js.map +1 -0
- package/dist/classes/services/BreadcrumbService/BreadcrumbService.d.ts +10 -0
- package/dist/classes/services/BreadcrumbService/index.d.ts +1 -0
- package/dist/classes/services/BreadcrumbService/index.js +50 -0
- package/dist/classes/services/BreadcrumbService/index.js.map +1 -0
- package/dist/classes/services/ConfigService/ConfigService.d.ts +9 -0
- package/dist/classes/services/ConfigService/index.d.ts +1 -0
- package/dist/classes/services/ConfigService/index.js +21 -0
- package/dist/classes/services/ConfigService/index.js.map +1 -0
- package/dist/classes/services/EmotionCacheService/EmotionCacheService.d.ts +7 -0
- package/dist/classes/services/EmotionCacheService/index.d.ts +1 -0
- package/dist/classes/services/EmotionCacheService/index.js +24 -0
- package/dist/classes/services/EmotionCacheService/index.js.map +1 -0
- package/dist/classes/services/FeatureFlagsService/FeatureFlagsService.d.ts +9 -0
- package/dist/classes/services/FeatureFlagsService/index.d.ts +1 -0
- package/dist/classes/services/FeatureFlagsService/index.js +21 -0
- package/dist/classes/services/FeatureFlagsService/index.js.map +1 -0
- package/dist/classes/services/I18nService/I18nService.d.ts +28 -0
- package/dist/classes/services/I18nService/index.d.ts +1 -0
- package/dist/classes/services/I18nService/index.js +67 -0
- package/dist/classes/services/I18nService/index.js.map +1 -0
- package/dist/classes/services/InactivityService/InactivityService.d.ts +25 -0
- package/dist/classes/services/InactivityService/index.d.ts +1 -0
- package/dist/classes/services/InactivityService/index.js +172 -0
- package/dist/classes/services/InactivityService/index.js.map +1 -0
- package/dist/classes/services/LogService/LogService.d.ts +22 -0
- package/dist/classes/services/LogService/index.d.ts +1 -0
- package/dist/classes/services/LogService/index.js +92 -0
- package/dist/classes/services/LogService/index.js.map +1 -0
- package/dist/classes/services/NavigationHistoryService/NavigationHistoryService.d.ts +6 -0
- package/dist/classes/services/NavigationHistoryService/index.d.ts +1 -0
- package/dist/classes/services/NavigationHistoryService/index.js +14 -0
- package/dist/classes/services/NavigationHistoryService/index.js.map +1 -0
- package/dist/classes/services/NotificationService/NotificationService.d.ts +14 -0
- package/dist/classes/services/NotificationService/index.d.ts +1 -0
- package/dist/classes/services/NotificationService/index.js +63 -0
- package/dist/classes/services/NotificationService/index.js.map +1 -0
- package/dist/classes/services/PageEventBusService/PageEventBusService.d.ts +28 -0
- package/dist/classes/services/PageEventBusService/index.d.ts +1 -0
- package/dist/classes/services/PageEventBusService/index.js +66 -0
- package/dist/classes/services/PageEventBusService/index.js.map +1 -0
- package/dist/classes/services/QueryClientService/QueryClientService.d.ts +25 -0
- package/dist/classes/services/QueryClientService/index.d.ts +1 -0
- package/dist/classes/services/QueryClientService/index.js +2 -0
- package/dist/classes/services/RouterService/RouterService.d.ts +19 -0
- package/dist/classes/services/RouterService/index.d.ts +1 -0
- package/dist/classes/services/RouterService/index.js +22 -0
- package/dist/classes/services/RouterService/index.js.map +1 -0
- package/dist/classes/services/UserSettingsService/UserSettingsService.d.ts +6 -0
- package/dist/classes/services/UserSettingsService/index.d.ts +1 -0
- package/dist/classes/services/UserSettingsService/index.js +14 -0
- package/dist/classes/services/UserSettingsService/index.js.map +1 -0
- package/dist/components/app/App/App.d.ts +1 -0
- package/dist/components/app/App/index.d.ts +1 -0
- package/dist/components/app/App/index.js +106 -0
- package/dist/components/app/App/index.js.map +1 -0
- package/dist/components/app/ApplicationBootstrap/ApplicationBootstrap.d.ts +2 -0
- package/dist/components/app/ApplicationBootstrap/index.d.ts +1 -0
- package/dist/components/app/ApplicationBootstrap/index.js +135 -0
- package/dist/components/app/ApplicationBootstrap/index.js.map +1 -0
- package/dist/components/app/AuthenticationWrapper/AuthenticationWrapper.d.ts +2 -0
- package/dist/components/app/AuthenticationWrapper/index.d.ts +1 -0
- package/dist/components/app/AuthenticationWrapper/index.js +126 -0
- package/dist/components/app/AuthenticationWrapper/index.js.map +1 -0
- package/dist/components/app/AuthorizationWrapper/AuthorizationWrapper.d.ts +2 -0
- package/dist/components/app/AuthorizationWrapper/index.d.ts +1 -0
- package/dist/components/app/AuthorizationWrapper/index.js +46 -0
- package/dist/components/app/AuthorizationWrapper/index.js.map +1 -0
- package/dist/components/app/RouterRoot/RouterRoot.d.ts +1 -0
- package/dist/components/app/RouterRoot/index.d.ts +1 -0
- package/dist/components/app/RouterRoot/index.js +118 -0
- package/dist/components/app/RouterRoot/index.js.map +1 -0
- package/dist/components/epi/EpiContactDetailsDialog/EpiContactDetailsDialog.d.ts +9 -0
- package/dist/components/epi/EpiContactDetailsDialog/index.d.ts +1 -0
- package/dist/components/epi/EpiContactDetailsDialog/index.js +81 -0
- package/dist/components/epi/EpiContactDetailsDialog/index.js.map +1 -0
- package/dist/components/filters/BooleanFilterField/BooleanFilterField.d.ts +5 -0
- package/dist/components/filters/BooleanFilterField/index.d.ts +1 -0
- package/dist/components/filters/BooleanFilterField/index.js +23 -0
- package/dist/components/filters/BooleanFilterField/index.js.map +1 -0
- package/dist/components/filters/DateFilterField/DateFilterField.d.ts +5 -0
- package/dist/components/filters/DateFilterField/index.d.ts +1 -0
- package/dist/components/filters/DateFilterField/index.js +15 -0
- package/dist/components/filters/DateFilterField/index.js.map +1 -0
- package/dist/components/filters/GeoFilterField/GeoFilterField.d.ts +5 -0
- package/dist/components/filters/GeoFilterField/index.d.ts +1 -0
- package/dist/components/filters/GeoFilterField/index.js +20 -0
- package/dist/components/filters/GeoFilterField/index.js.map +1 -0
- package/dist/components/filters/MultiSelectFilterField/MultiSelectFilterField.d.ts +5 -0
- package/dist/components/filters/MultiSelectFilterField/index.d.ts +1 -0
- package/dist/components/filters/MultiSelectFilterField/index.js +19 -0
- package/dist/components/filters/MultiSelectFilterField/index.js.map +1 -0
- package/dist/components/filters/NumberRangeFilterField/NumberRangeFilterField.d.ts +5 -0
- package/dist/components/filters/NumberRangeFilterField/index.d.ts +1 -0
- package/dist/components/filters/NumberRangeFilterField/index.js +14 -0
- package/dist/components/filters/NumberRangeFilterField/index.js.map +1 -0
- package/dist/components/filters/TextFilterField/TextFilterField.d.ts +5 -0
- package/dist/components/filters/TextFilterField/index.d.ts +1 -0
- package/dist/components/filters/TextFilterField/index.js +12 -0
- package/dist/components/filters/TextFilterField/index.js.map +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBar.d.ts +6 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActions.d.ts +4 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActionsFeedbackItem.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActionsInfotem.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActionsNotificationsItem.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActionsOrganizationSwitcherItem.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActionsOutagesItem.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarActionsUserItem.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/ApplicationBarNavigationMenu.d.ts +4 -0
- package/dist/components/ui/ApplicationBar/InfoMenu.d.ts +7 -0
- package/dist/components/ui/ApplicationBar/UserMenu.d.ts +7 -0
- package/dist/components/ui/ApplicationBar/UserOrganizationAdminMenuItem.d.ts +4 -0
- package/dist/components/ui/ApplicationBar/UserOwnOrganizationMenuItem.d.ts +4 -0
- package/dist/components/ui/ApplicationBar/index.d.ts +1 -0
- package/dist/components/ui/ApplicationBar/index.js +661 -0
- package/dist/components/ui/ApplicationBar/index.js.map +1 -0
- package/dist/components/ui/ApplicationFooter/ApplicationFooter.d.ts +4 -0
- package/dist/components/ui/ApplicationFooter/ApplicationFooterLink.d.ts +7 -0
- package/dist/components/ui/ApplicationFooter/ApplicationFooterLinkSection.d.ts +5 -0
- package/dist/components/ui/ApplicationFooter/index.d.ts +1 -0
- package/dist/components/ui/ApplicationFooter/index.js +2 -0
- package/dist/components/ui/BackdropSpinner/BackdropSpinner.d.ts +5 -0
- package/dist/components/ui/BackdropSpinner/index.d.ts +1 -0
- package/dist/components/ui/BackdropSpinner/index.js +19 -0
- package/dist/components/ui/BackdropSpinner/index.js.map +1 -0
- package/dist/components/ui/Breadcrumbs/Breadcrumb.d.ts +9 -0
- package/dist/components/ui/Breadcrumbs/Breadcrumbs.d.ts +1 -0
- package/dist/components/ui/Breadcrumbs/index.d.ts +1 -0
- package/dist/components/ui/Breadcrumbs/index.js +2 -0
- package/dist/components/ui/Confirmation/Confirmation.d.ts +2 -0
- package/dist/components/ui/Confirmation/ConfirmationRender.d.ts +11 -0
- package/dist/components/ui/Confirmation/index.d.ts +2 -0
- package/dist/components/ui/Confirmation/index.js +58 -0
- package/dist/components/ui/Confirmation/index.js.map +1 -0
- package/dist/components/ui/ConsentDialog/ConsentDialog.d.ts +8 -0
- package/dist/components/ui/ConsentDialog/index.d.ts +1 -0
- package/dist/components/ui/ConsentDialog/index.js +36 -0
- package/dist/components/ui/ConsentDialog/index.js.map +1 -0
- package/dist/components/ui/CopyToClipboardButton/CopyToClipboardButton.d.ts +13 -0
- package/dist/components/ui/CopyToClipboardButton/index.d.ts +1 -0
- package/dist/components/ui/CopyToClipboardButton/index.js +101 -0
- package/dist/components/ui/CopyToClipboardButton/index.js.map +1 -0
- package/dist/components/ui/Dialog/Dialog.d.ts +27 -0
- package/dist/components/ui/Dialog/index.d.ts +1 -0
- package/dist/components/ui/Dialog/index.js +83 -0
- package/dist/components/ui/Dialog/index.js.map +1 -0
- package/dist/components/ui/GenericErrorMessage/GenericErrorMessage.d.ts +5 -0
- package/dist/components/ui/GenericErrorMessage/index.d.ts +1 -0
- package/dist/components/ui/GenericErrorMessage/index.js +91 -0
- package/dist/components/ui/GenericErrorMessage/index.js.map +1 -0
- package/dist/components/ui/LicensesDialog/LicensesDialog.d.ts +7 -0
- package/dist/components/ui/LicensesDialog/index.d.ts +1 -0
- package/dist/components/ui/LicensesDialog/index.js +117 -0
- package/dist/components/ui/LicensesDialog/index.js.map +1 -0
- package/dist/components/ui/LinearProgressWithLabel/LinearProgressWithLabel.d.ts +5 -0
- package/dist/components/ui/LinearProgressWithLabel/index.d.ts +1 -0
- package/dist/components/ui/LinearProgressWithLabel/index.js +31 -0
- package/dist/components/ui/LinearProgressWithLabel/index.js.map +1 -0
- package/dist/components/ui/LoadingIndicator/LoadingIndicator.d.ts +2 -0
- package/dist/components/ui/LoadingIndicator/index.d.ts +1 -0
- package/dist/components/ui/LoadingIndicator/index.js +12 -0
- package/dist/components/ui/LoadingIndicator/index.js.map +1 -0
- package/dist/components/ui/MyPermissionsDialog/MyPermissionsDialog.d.ts +7 -0
- package/dist/components/ui/MyPermissionsDialog/index.d.ts +1 -0
- package/dist/components/ui/MyPermissionsDialog/index.js +41 -0
- package/dist/components/ui/MyPermissionsDialog/index.js.map +1 -0
- package/dist/components/ui/NavLink/NavLink.d.ts +7 -0
- package/dist/components/ui/NavLink/index.d.ts +1 -0
- package/dist/components/ui/NavLink/index.js +23 -0
- package/dist/components/ui/NavLink/index.js.map +1 -0
- package/dist/components/ui/NestedMenu/IconMenuItem.d.ts +18 -0
- package/dist/components/ui/NestedMenu/NestedDropdown.d.ts +17 -0
- package/dist/components/ui/NestedMenu/NestedMenuItem.d.ts +22 -0
- package/dist/components/ui/NestedMenu/index.d.ts +4 -0
- package/dist/components/ui/NestedMenu/index.js +240 -0
- package/dist/components/ui/NestedMenu/index.js.map +1 -0
- package/dist/components/ui/NestedMenu/nestedMenuItemsFromObject.d.ts +11 -0
- package/dist/components/ui/Notifications/NotificationItem.d.ts +8 -0
- package/dist/components/ui/Notifications/NotificationsDrawer.d.ts +5 -0
- package/dist/components/ui/Notifications/NotificationsStack.d.ts +2 -0
- package/dist/components/ui/Notifications/index.d.ts +2 -0
- package/dist/components/ui/Notifications/index.js +2 -0
- package/dist/components/ui/OrganizationSwitcherDialog/OrganizationSwitcherDialog.d.ts +7 -0
- package/dist/components/ui/OrganizationSwitcherDialog/index.d.ts +1 -0
- package/dist/components/ui/OrganizationSwitcherDialog/index.js +123 -0
- package/dist/components/ui/OrganizationSwitcherDialog/index.js.map +1 -0
- package/dist/components/ui/OutageList/OutageItem.d.ts +9 -0
- package/dist/components/ui/OutageList/OutageList.d.ts +7 -0
- package/dist/components/ui/OutageList/OutageSection.d.ts +10 -0
- package/dist/components/ui/OutageList/index.d.ts +1 -0
- package/dist/components/ui/OutageList/index.js +2 -0
- package/dist/components/ui/OutagesDialog/OutagesDialog.d.ts +7 -0
- package/dist/components/ui/OutagesDialog/index.d.ts +1 -0
- package/dist/components/ui/OutagesDialog/index.js +43 -0
- package/dist/components/ui/OutagesDialog/index.js.map +1 -0
- package/dist/components/ui/PageContainer/PageContainer.d.ts +14 -0
- package/dist/components/ui/PageContainer/index.d.ts +1 -0
- package/dist/components/ui/PageContainer/index.js +135 -0
- package/dist/components/ui/PageContainer/index.js.map +1 -0
- package/dist/components/ui/ResponseHandler/ResponseHandler.d.ts +16 -0
- package/dist/components/ui/ResponseHandler/index.d.ts +1 -0
- package/dist/components/ui/ResponseHandler/index.js +28 -0
- package/dist/components/ui/ResponseHandler/index.js.map +1 -0
- package/dist/components/ui/Sidebar/SidebarItem.d.ts +13 -0
- package/dist/components/ui/Sidebar/SidebarMenu.d.ts +3 -0
- package/dist/components/ui/Sidebar/SidebarMenuItem.d.ts +12 -0
- package/dist/components/ui/Sidebar/index.d.ts +3 -0
- package/dist/components/ui/Sidebar/index.js +128 -0
- package/dist/components/ui/Sidebar/index.js.map +1 -0
- package/dist/components/ui/SortableList/SortableList.d.ts +14 -0
- package/dist/components/ui/SortableList/SortableListItem.d.ts +8 -0
- package/dist/components/ui/SortableList/SortableListItemDragHandle.d.ts +4 -0
- package/dist/components/ui/SortableList/SortableOverlay.d.ts +2 -0
- package/dist/components/ui/SortableList/context/SortableListItemContext.d.ts +7 -0
- package/dist/components/ui/SortableList/context/SortableListItemContextProvider.d.ts +6 -0
- package/dist/components/ui/SortableList/context/useSortableListItemContext.d.ts +1 -0
- package/dist/components/ui/Spinner/Spinner.d.ts +11 -0
- package/dist/components/ui/Spinner/index.d.ts +1 -0
- package/dist/components/ui/Spinner/index.js +63 -0
- package/dist/components/ui/Spinner/index.js.map +1 -0
- package/dist/components/ui/Stepper/Stepper.d.ts +17 -0
- package/dist/components/ui/Stepper/index.d.ts +2 -0
- package/dist/components/ui/Stepper/index.js +126 -0
- package/dist/components/ui/Stepper/index.js.map +1 -0
- package/dist/components/ui/Stepper/stepperModel.d.ts +4 -0
- package/dist/components/ui/Table/Table.d.ts +30 -0
- package/dist/components/ui/Table/TableActionsCell.d.ts +6 -0
- package/dist/components/ui/Table/TableCaption.d.ts +7 -0
- package/dist/components/ui/Table/TableCell.d.ts +27 -0
- package/dist/components/ui/Table/TableCellAsyncContent.d.ts +4 -0
- package/dist/components/ui/Table/TableCheckboxCell.d.ts +8 -0
- package/dist/components/ui/Table/TableCheckboxHeader.d.ts +5 -0
- package/dist/components/ui/Table/TableColumnsEditorDialog.d.ts +9 -0
- package/dist/components/ui/Table/TableFilter.d.ts +6 -0
- package/dist/components/ui/Table/TableFiltersSidebarItem.d.ts +9 -0
- package/dist/components/ui/Table/TableHeader.d.ts +8 -0
- package/dist/components/ui/Table/TableHeaderCell.d.ts +9 -0
- package/dist/components/ui/Table/TableHeaderFilter.d.ts +7 -0
- package/dist/components/ui/Table/TableMenu.d.ts +5 -0
- package/dist/components/ui/Table/TableReadableIndexCell.d.ts +8 -0
- package/dist/components/ui/Table/TableSidebarMenu.d.ts +5 -0
- package/dist/components/ui/Table/classNames.d.ts +8 -0
- package/dist/components/ui/Table/index.d.ts +12 -0
- package/dist/components/ui/Table/index.js +2 -0
- package/dist/components/ui/UserFeedbackDialog/UserFeedbackDialog.d.ts +7 -0
- package/dist/components/ui/UserFeedbackDialog/index.d.ts +1 -0
- package/dist/components/ui/UserFeedbackDialog/index.js +117 -0
- package/dist/components/ui/UserFeedbackDialog/index.js.map +1 -0
- package/dist/components/ui/UserInactivityConfirmation/UserInactivityConfirmation.d.ts +1 -0
- package/dist/components/ui/UserInactivityConfirmation/index.d.ts +1 -0
- package/dist/components/ui/UserInactivityConfirmation/index.js +40 -0
- package/dist/components/ui/UserInactivityConfirmation/index.js.map +1 -0
- package/dist/constants/query.d.ts +21 -0
- package/dist/constants/query.js +46 -0
- package/dist/constants/query.js.map +1 -0
- package/dist/dataHooks/useIdentifierIssuerOwnOrganizationQuery/index.d.ts +1 -0
- package/dist/dataHooks/useIdentifierIssuerOwnOrganizationQuery/index.js +26 -0
- package/dist/dataHooks/useIdentifierIssuerOwnOrganizationQuery/index.js.map +1 -0
- package/dist/dataHooks/useIdentifierIssuerOwnOrganizationQuery/useIdentifierIssuerOwnOrganizationQuery.d.ts +5 -0
- package/dist/dataHooks/useIdentifierIssuerQuery/index.d.ts +1 -0
- package/dist/dataHooks/useIdentifierIssuerQuery/index.js +22 -0
- package/dist/dataHooks/useIdentifierIssuerQuery/index.js.map +1 -0
- package/dist/dataHooks/useIdentifierIssuerQuery/useIdentifierIssuerQuery.d.ts +8 -0
- package/dist/dataHooks/useInviteUserConstraintsQuery/index.d.ts +1 -0
- package/dist/dataHooks/useInviteUserConstraintsQuery/index.js +21 -0
- package/dist/dataHooks/useInviteUserConstraintsQuery/index.js.map +1 -0
- package/dist/dataHooks/useInviteUserConstraintsQuery/useInviteUserConstraintsQuery.d.ts +3 -0
- package/dist/dataHooks/useOrganizationAdminPoliciesQuery/index.d.ts +1 -0
- package/dist/dataHooks/useOrganizationAdminPoliciesQuery/index.js +32 -0
- package/dist/dataHooks/useOrganizationAdminPoliciesQuery/index.js.map +1 -0
- package/dist/dataHooks/useOrganizationAdminPoliciesQuery/useOrganizationAdminPoliciesQuery.d.ts +7 -0
- package/dist/dataHooks/useOrganizationIdentifierIssuerLinksQuery/index.d.ts +1 -0
- package/dist/dataHooks/useOrganizationIdentifierIssuerLinksQuery/index.js +13 -0
- package/dist/dataHooks/useOrganizationIdentifierIssuerLinksQuery/index.js.map +1 -0
- package/dist/dataHooks/useOrganizationIdentifierIssuerLinksQuery/useOrganizationIdentifierIssuerLinksQuery.d.ts +3 -0
- package/dist/dataHooks/useOrganizationsQuery/index.d.ts +1 -0
- package/dist/dataHooks/useOrganizationsQuery/index.js +22 -0
- package/dist/dataHooks/useOrganizationsQuery/index.js.map +1 -0
- package/dist/dataHooks/useOrganizationsQuery/useOrganizationsQuery.d.ts +6 -0
- package/dist/dataHooks/useUsersQuery/index.d.ts +1 -0
- package/dist/dataHooks/useUsersQuery/index.js +23 -0
- package/dist/dataHooks/useUsersQuery/index.js.map +1 -0
- package/dist/dataHooks/useUsersQuery/useUsersQuery.d.ts +6 -0
- package/dist/hoc/withDialog/index.d.ts +1 -0
- package/dist/hoc/withDialog/index.js +69 -0
- package/dist/hoc/withDialog/index.js.map +1 -0
- package/dist/hoc/withDialog/withDialog.d.ts +33 -0
- package/dist/hoc/withPermissions/index.d.ts +1 -0
- package/dist/hoc/withPermissions/index.js +21 -0
- package/dist/hoc/withPermissions/index.js.map +1 -0
- package/dist/hoc/withPermissions/withPermissions.d.ts +10 -0
- package/dist/hooks/useColumnsMenu/index.d.ts +1 -0
- package/dist/hooks/useColumnsMenu/index.js +2 -0
- package/dist/hooks/useColumnsMenu/useColumnsMenu.d.ts +6 -0
- package/dist/hooks/useCreateMutation/index.d.ts +1 -0
- package/dist/hooks/useCreateMutation/index.js +50 -0
- package/dist/hooks/useCreateMutation/index.js.map +1 -0
- package/dist/hooks/useCreateMutation/useCreateMutation.d.ts +21 -0
- package/dist/hooks/useDeleteMutation/index.d.ts +1 -0
- package/dist/hooks/useDeleteMutation/index.js +41 -0
- package/dist/hooks/useDeleteMutation/index.js.map +1 -0
- package/dist/hooks/useDeleteMutation/useDeleteMutation.d.ts +20 -0
- package/dist/hooks/useEditMutation/index.d.ts +1 -0
- package/dist/hooks/useEditMutation/index.js +57 -0
- package/dist/hooks/useEditMutation/index.js.map +1 -0
- package/dist/hooks/useEditMutation/useEditMutation.d.ts +23 -0
- package/dist/hooks/useInitializeTableStore/index.d.ts +1 -0
- package/dist/hooks/useInitializeTableStore/index.js +28 -0
- package/dist/hooks/useInitializeTableStore/index.js.map +1 -0
- package/dist/hooks/useInitializeTableStore/useInitializeTableStore.d.ts +11 -0
- package/dist/hooks/useItemQuery/index.d.ts +1 -0
- package/dist/hooks/useItemQuery/index.js +61 -0
- package/dist/hooks/useItemQuery/index.js.map +1 -0
- package/dist/hooks/useItemQuery/useItemQuery.d.ts +15 -0
- package/dist/hooks/useQueryMemo/index.d.ts +1 -0
- package/dist/hooks/useQueryMemo/index.js +2 -0
- package/dist/hooks/useQueryMemo/useQueryMemo.d.ts +2 -0
- package/dist/hooks/useUpdateBreadcrumb/index.d.ts +1 -0
- package/dist/hooks/useUpdateBreadcrumb/index.js +15 -0
- package/dist/hooks/useUpdateBreadcrumb/index.js.map +1 -0
- package/dist/hooks/useUpdateBreadcrumb/useUpdateBreadcrumb.d.ts +1 -0
- package/dist/hooks/useUpdateDocumentTitle/index.d.ts +1 -0
- package/dist/hooks/useUpdateDocumentTitle/index.js +12 -0
- package/dist/hooks/useUpdateDocumentTitle/index.js.map +1 -0
- package/dist/hooks/useUpdateDocumentTitle/useUpdateDocumentTitle.d.ts +1 -0
- package/dist/locale/en.json +294 -0
- package/dist/locale/nl.json +294 -0
- package/dist/models/admin.d.ts +7 -0
- package/dist/models/admin.js +8 -0
- package/dist/models/admin.js.map +1 -0
- package/dist/models/api.d.ts +9 -0
- package/dist/models/api.js +0 -0
- package/dist/models/auth.d.ts +11 -0
- package/dist/models/auth.js +0 -0
- package/dist/models/config.d.ts +77 -0
- package/dist/models/config.js +0 -0
- package/dist/models/data.d.ts +10 -0
- package/dist/models/data.js +0 -0
- package/dist/models/dataHooks.d.ts +17 -0
- package/dist/models/dataHooks.js +0 -0
- package/dist/models/filter.d.ts +34 -0
- package/dist/models/filter.js +0 -0
- package/dist/models/nestedMenu.d.ts +17 -0
- package/dist/models/nestedMenu.js +0 -0
- package/dist/models/notification.d.ts +11 -0
- package/dist/models/notification.js +0 -0
- package/dist/models/outage.d.ts +6 -0
- package/dist/models/outage.js +0 -0
- package/dist/models/reactRouter.d.ts +25 -0
- package/dist/models/reactRouter.js +0 -0
- package/dist/models/table.d.ts +149 -0
- package/dist/models/table.js +10 -0
- package/dist/models/table.js.map +1 -0
- package/dist/models/theme.d.ts +17 -0
- package/dist/models/theme.js +0 -0
- package/dist/pages/AcceptInvitationPage/AcceptInvitationPage.d.ts +1 -0
- package/dist/pages/AcceptInvitationPage/index.d.ts +1 -0
- package/dist/pages/AcceptInvitationPage/index.js +61 -0
- package/dist/pages/AcceptInvitationPage/index.js.map +1 -0
- package/dist/pages/AdminPage/AdminPage.d.ts +1 -0
- package/dist/pages/AdminPage/index.d.ts +1 -0
- package/dist/pages/AdminPage/index.js +83 -0
- package/dist/pages/AdminPage/index.js.map +1 -0
- package/dist/pages/ChooseIdentityProviderPage/ChooseIdentityProviderPage.d.ts +5 -0
- package/dist/pages/ChooseIdentityProviderPage/index.d.ts +1 -0
- package/dist/pages/ChooseIdentityProviderPage/index.js +85 -0
- package/dist/pages/ChooseIdentityProviderPage/index.js.map +1 -0
- package/dist/pages/CrudPage/CrudPage.d.ts +75 -0
- package/dist/pages/CrudPage/CrudPageDeleteDialog.d.ts +12 -0
- package/dist/pages/CrudPage/CrudPageEditDialog.d.ts +23 -0
- package/dist/pages/CrudPage/index.d.ts +1 -0
- package/dist/pages/CrudPage/index.js +2 -0
- package/dist/pages/ErrorPage/ErrorPage.d.ts +4 -0
- package/dist/pages/ErrorPage/index.d.ts +1 -0
- package/dist/pages/ErrorPage/index.js +19 -0
- package/dist/pages/ErrorPage/index.js.map +1 -0
- package/dist/pages/IdentifierIssuersAdminPage/IdentifierIssuersAdminPage.d.ts +1 -0
- package/dist/pages/IdentifierIssuersAdminPage/index.d.ts +1 -0
- package/dist/pages/IdentifierIssuersAdminPage/index.js +69 -0
- package/dist/pages/IdentifierIssuersAdminPage/index.js.map +1 -0
- package/dist/pages/OrganizationAdminPoliciesAdminPage/OrganizationAdminPoliciesAdminPage.d.ts +1 -0
- package/dist/pages/OrganizationAdminPoliciesAdminPage/index.d.ts +1 -0
- package/dist/pages/OrganizationAdminPoliciesAdminPage/index.js +98 -0
- package/dist/pages/OrganizationAdminPoliciesAdminPage/index.js.map +1 -0
- package/dist/pages/OrganizationContactsAdminPage/OrganizationContactsAdminPage.d.ts +1 -0
- package/dist/pages/OrganizationContactsAdminPage/index.d.ts +1 -0
- package/dist/pages/OrganizationContactsAdminPage/index.js +86 -0
- package/dist/pages/OrganizationContactsAdminPage/index.js.map +1 -0
- package/dist/pages/OrganizationSitesAdminPage/OrganizationSitesAdminPage.d.ts +1 -0
- package/dist/pages/OrganizationSitesAdminPage/index.d.ts +1 -0
- package/dist/pages/OrganizationSitesAdminPage/index.js +68 -0
- package/dist/pages/OrganizationSitesAdminPage/index.js.map +1 -0
- package/dist/pages/OrganizationsAdminPage/OrganizationsAdminPage.d.ts +1 -0
- package/dist/pages/OrganizationsAdminPage/index.d.ts +1 -0
- package/dist/pages/OrganizationsAdminPage/index.js +132 -0
- package/dist/pages/OrganizationsAdminPage/index.js.map +1 -0
- package/dist/pages/OutagesAdminPage/OutagesAdminPage.d.ts +1 -0
- package/dist/pages/OutagesAdminPage/index.d.ts +1 -0
- package/dist/pages/OutagesAdminPage/index.js +133 -0
- package/dist/pages/OutagesAdminPage/index.js.map +1 -0
- package/dist/pages/PostLoginPage/PostLoginPage.d.ts +1 -0
- package/dist/pages/PostLoginPage/index.d.ts +1 -0
- package/dist/pages/PostLoginPage/index.js +26 -0
- package/dist/pages/PostLoginPage/index.js.map +1 -0
- package/dist/pages/PostLogoutPage/PostLogoutPage.d.ts +1 -0
- package/dist/pages/PostLogoutPage/index.d.ts +1 -0
- package/dist/pages/PostLogoutPage/index.js +32 -0
- package/dist/pages/PostLogoutPage/index.js.map +1 -0
- package/dist/pages/RouterErrorPage/RouterErrorPage.d.ts +1 -0
- package/dist/pages/RouterErrorPage/index.d.ts +1 -0
- package/dist/pages/RouterErrorPage/index.js +20 -0
- package/dist/pages/RouterErrorPage/index.js.map +1 -0
- package/dist/pages/UserInvitationsAdminPage/UserInvitationConsumeDialog.d.ts +9 -0
- package/dist/pages/UserInvitationsAdminPage/UserInvitationShareDialog.d.ts +9 -0
- package/dist/pages/UserInvitationsAdminPage/UserInvitationsAdminPage.d.ts +1 -0
- package/dist/pages/UserInvitationsAdminPage/index.d.ts +1 -0
- package/dist/pages/UserInvitationsAdminPage/index.js +2 -0
- package/dist/pages/UsersAdminPage/UsersAdminPage.d.ts +7 -0
- package/dist/pages/UsersAdminPage/index.d.ts +1 -0
- package/dist/pages/UsersAdminPage/index.js +206 -0
- package/dist/pages/UsersAdminPage/index.js.map +1 -0
- package/dist/routes/adminRoutes.d.ts +9 -0
- package/dist/routes/index.d.ts +2 -0
- package/dist/routes/index.js +258 -0
- package/dist/routes/index.js.map +1 -0
- package/dist/routes/routes.d.ts +8 -0
- package/dist/setup/setup.d.ts +1 -0
- package/dist/setup/setup.js +9 -0
- package/dist/setup/setup.js.map +1 -0
- package/dist/stores/oidcStore/index.d.ts +1 -0
- package/dist/stores/oidcStore/index.js +18 -0
- package/dist/stores/oidcStore/index.js.map +1 -0
- package/dist/stores/oidcStore/oidcStore.d.ts +22 -0
- package/dist/stores/outagesStore/index.d.ts +1 -0
- package/dist/stores/outagesStore/index.js +16 -0
- package/dist/stores/outagesStore/index.js.map +1 -0
- package/dist/stores/outagesStore/outagesStore.d.ts +12 -0
- package/dist/stores/tableStore/TableStoreContext.d.ts +3 -0
- package/dist/stores/tableStore/TableStoreContextProvider.d.ts +7 -0
- package/dist/stores/tableStore/index.d.ts +4 -0
- package/dist/stores/tableStore/index.js +2 -0
- package/dist/stores/tableStore/tableStore.d.ts +102 -0
- package/dist/stores/tableStore/useTableStoreContext.d.ts +3 -0
- package/dist/test/lib/index.d.ts +1 -0
- package/dist/test/lib/render.d.ts +2 -0
- package/dist/theme/demoTheme/demoTheme.d.ts +3 -0
- package/dist/theme/demoTheme/index.d.ts +1 -0
- package/dist/theme/demoTheme/index.js +337 -0
- package/dist/theme/demoTheme/index.js.map +1 -0
- package/dist/utils/AxiosUtil/AxiosUtil.d.ts +13 -0
- package/dist/utils/AxiosUtil/index.d.ts +1 -0
- package/dist/utils/AxiosUtil/index.js +38 -0
- package/dist/utils/AxiosUtil/index.js.map +1 -0
- package/dist/utils/DataHookUtil/DataHookUtil.d.ts +8 -0
- package/dist/utils/DataHookUtil/index.d.ts +1 -0
- package/dist/utils/DataHookUtil/index.js +77 -0
- package/dist/utils/DataHookUtil/index.js.map +1 -0
- package/dist/utils/LoadableUtil/LoadableUtil.d.ts +9 -0
- package/dist/utils/LoadableUtil/index.d.ts +1 -0
- package/dist/utils/LoadableUtil/index.js +25 -0
- package/dist/utils/LoadableUtil/index.js.map +1 -0
- package/dist/utils/MenuDataUtil/MenuDataUtil.d.ts +5 -0
- package/dist/utils/MenuDataUtil/index.d.ts +1 -0
- package/dist/utils/MenuDataUtil/index.js +19 -0
- package/dist/utils/MenuDataUtil/index.js.map +1 -0
- package/dist/utils/NotificationUtil/NotificationUtil.d.ts +4 -0
- package/dist/utils/NotificationUtil/index.d.ts +1 -0
- package/dist/utils/NotificationUtil/index.js +12 -0
- package/dist/utils/NotificationUtil/index.js.map +1 -0
- package/dist/utils/OutageUtil/OutageUtil.d.ts +5 -0
- package/dist/utils/OutageUtil/index.d.ts +1 -0
- package/dist/utils/OutageUtil/index.js +2 -0
- package/dist/utils/StandardConfigUtil/StandardConfigUtil.d.ts +4 -0
- package/dist/utils/StandardConfigUtil/index.d.ts +1 -0
- package/dist/utils/StandardConfigUtil/index.js +76 -0
- package/dist/utils/StandardConfigUtil/index.js.map +1 -0
- package/dist/utils/TableUtil/TableUtil.d.ts +90 -0
- package/dist/utils/TableUtil/index.d.ts +1 -0
- package/dist/utils/TableUtil/index.js +2 -0
- package/dist/utils/TimeUtil/TimeUtil.d.ts +3 -0
- package/dist/utils/TimeUtil/index.d.ts +1 -0
- package/dist/utils/TimeUtil/index.js +19 -0
- package/dist/utils/TimeUtil/index.js.map +1 -0
- package/dist/utils/UserManagerUtil/UserManagerUtil.d.ts +6 -0
- package/dist/utils/UserManagerUtil/index.d.ts +1 -0
- package/dist/utils/UserManagerUtil/index.js +31 -0
- package/dist/utils/UserManagerUtil/index.js.map +1 -0
- package/dist/utils/UserUtil/UserUtil.d.ts +5 -0
- package/dist/utils/UserUtil/index.d.ts +1 -0
- package/dist/utils/UserUtil/index.js +10 -0
- package/dist/utils/UserUtil/index.js.map +1 -0
- package/package.json +585 -0
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
import { TimeUtil as e } from "../utils/TimeUtil/index.js";
|
|
2
|
+
import { NotificationService as t } from "../classes/services/NotificationService/index.js";
|
|
3
|
+
import { Alert as n, AlertTitle as r, Box as i, Button as a, CircularProgress as o, Divider as s, Drawer as c, IconButton as l, Snackbar as u, Typography as d, useTheme as f } from "@mui/material";
|
|
4
|
+
import { useCallback as p, useMemo as m } from "react";
|
|
5
|
+
import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
6
|
+
import { useTranslation as v } from "react-i18next";
|
|
7
|
+
import { TestIdUtil as y } from "@gen-epix/ui-core/utils/TestIdUtil";
|
|
8
|
+
import { useSubscribable as b } from "@gen-epix/ui-core/hooks/useSubscribable";
|
|
9
|
+
import x from "@mui/icons-material/Close";
|
|
10
|
+
import S from "@mui/icons-material/Notifications";
|
|
11
|
+
//#region src/components/ui/Notifications/NotificationItem.tsx
|
|
12
|
+
var C = ({ allowClose: t, notification: a, onClose: s, showTimestamp: c }) => {
|
|
13
|
+
let { t: l } = v(), u = p(() => {
|
|
14
|
+
s(a.key);
|
|
15
|
+
}, [a.key, s]), d = m(() => (/* @__PURE__ */ new Date()).getTime(), []);
|
|
16
|
+
return /* @__PURE__ */ _(n, {
|
|
17
|
+
...y.createAttributes("NotificationItem", { key: a.key }),
|
|
18
|
+
closeText: l`Clear notification`,
|
|
19
|
+
icon: a.isLoading ? /* @__PURE__ */ g(o, { size: 16 }) : void 0,
|
|
20
|
+
onClose: t ? u : void 0,
|
|
21
|
+
severity: a.isLoading ? "info" : a.severity,
|
|
22
|
+
slotProps: { message: { sx: { flexGrow: 1 } } },
|
|
23
|
+
sx: {
|
|
24
|
+
backgroundColor: "background.paper",
|
|
25
|
+
boxShadow: 1,
|
|
26
|
+
marginBottom: 1
|
|
27
|
+
},
|
|
28
|
+
children: [/* @__PURE__ */ g(r, {
|
|
29
|
+
sx: { width: "100%" },
|
|
30
|
+
children: a.message
|
|
31
|
+
}), c && /* @__PURE__ */ _(i, {
|
|
32
|
+
sx: { textAlign: "right" },
|
|
33
|
+
children: [
|
|
34
|
+
e.getReadableTimeRemaining(d - a.timestamp, !0),
|
|
35
|
+
" ",
|
|
36
|
+
l("ago")
|
|
37
|
+
]
|
|
38
|
+
})]
|
|
39
|
+
});
|
|
40
|
+
}, w = ({ onDrawerClose: e, open: n }) => {
|
|
41
|
+
let { t: r } = v(), o = f(), u = b(t.getInstance()), m = p((e) => {
|
|
42
|
+
t.getInstance().clearNotification(e);
|
|
43
|
+
}, []), h = p(() => {
|
|
44
|
+
t.getInstance().clearNotifications(), e();
|
|
45
|
+
}, [e]);
|
|
46
|
+
return /* @__PURE__ */ g(c, {
|
|
47
|
+
anchor: "right",
|
|
48
|
+
onClose: e,
|
|
49
|
+
open: n,
|
|
50
|
+
children: /* @__PURE__ */ _(i, {
|
|
51
|
+
sx: {
|
|
52
|
+
padding: o.spacing(2),
|
|
53
|
+
[o.breakpoints.up("xl")]: { width: "620px" },
|
|
54
|
+
width: "520px"
|
|
55
|
+
},
|
|
56
|
+
children: [
|
|
57
|
+
/* @__PURE__ */ _(i, {
|
|
58
|
+
sx: {
|
|
59
|
+
alignItems: "center",
|
|
60
|
+
display: "flex",
|
|
61
|
+
justifyContent: "space-between",
|
|
62
|
+
marginBottom: 2
|
|
63
|
+
},
|
|
64
|
+
children: [/* @__PURE__ */ g(d, {
|
|
65
|
+
component: "h6",
|
|
66
|
+
variant: "h3",
|
|
67
|
+
children: r`Notifications`
|
|
68
|
+
}), /* @__PURE__ */ g(l, {
|
|
69
|
+
"aria-label": r`Close notifications drawer`,
|
|
70
|
+
onClick: e,
|
|
71
|
+
children: /* @__PURE__ */ g(x, { sx: {
|
|
72
|
+
"&:hover": { color: o.palette.text.primary },
|
|
73
|
+
color: o.palette.text.secondary
|
|
74
|
+
} })
|
|
75
|
+
})]
|
|
76
|
+
}),
|
|
77
|
+
u.length === 0 && /* @__PURE__ */ _(i, { children: [/* @__PURE__ */ g(i, {
|
|
78
|
+
sx: {
|
|
79
|
+
display: "flex",
|
|
80
|
+
justifyContent: "center",
|
|
81
|
+
marginBottom: 2
|
|
82
|
+
},
|
|
83
|
+
children: /* @__PURE__ */ g(S, { sx: {
|
|
84
|
+
color: o.palette.text.disabled,
|
|
85
|
+
fontSize: 100
|
|
86
|
+
} })
|
|
87
|
+
}), /* @__PURE__ */ g(i, {
|
|
88
|
+
sx: {
|
|
89
|
+
display: "flex",
|
|
90
|
+
justifyContent: "center"
|
|
91
|
+
},
|
|
92
|
+
children: /* @__PURE__ */ g(d, { children: r`No new notifications in this session` })
|
|
93
|
+
})] }),
|
|
94
|
+
u.length > 0 && /* @__PURE__ */ _(i, { children: [
|
|
95
|
+
/* @__PURE__ */ g(i, {
|
|
96
|
+
sx: {
|
|
97
|
+
display: "flex",
|
|
98
|
+
justifyContent: "flex-end"
|
|
99
|
+
},
|
|
100
|
+
children: /* @__PURE__ */ g(a, {
|
|
101
|
+
"aria-label": r`Clear all notifications`,
|
|
102
|
+
color: "primary",
|
|
103
|
+
onClick: h,
|
|
104
|
+
variant: "outlined",
|
|
105
|
+
children: r`Clear all notifications`
|
|
106
|
+
})
|
|
107
|
+
}),
|
|
108
|
+
/* @__PURE__ */ g(i, {
|
|
109
|
+
sx: { marginY: 2 },
|
|
110
|
+
children: /* @__PURE__ */ g(s, {})
|
|
111
|
+
}),
|
|
112
|
+
/* @__PURE__ */ g(i, {
|
|
113
|
+
sx: { overflowY: "hidden" },
|
|
114
|
+
children: /* @__PURE__ */ g(i, {
|
|
115
|
+
sx: {
|
|
116
|
+
maxHeight: "100%",
|
|
117
|
+
overflowY: "auto"
|
|
118
|
+
},
|
|
119
|
+
children: u.map((e) => /* @__PURE__ */ g(C, {
|
|
120
|
+
allowClose: !e.isLoading,
|
|
121
|
+
notification: e,
|
|
122
|
+
onClose: m,
|
|
123
|
+
showTimestamp: !0
|
|
124
|
+
}, e.key))
|
|
125
|
+
})
|
|
126
|
+
})
|
|
127
|
+
] })
|
|
128
|
+
]
|
|
129
|
+
})
|
|
130
|
+
});
|
|
131
|
+
}, T = () => {
|
|
132
|
+
let e = b(t.getInstance(), { select: (e) => e.filter((e) => e.visible) }), n = p((e) => {
|
|
133
|
+
t.getInstance().hideNotification(e);
|
|
134
|
+
}, []);
|
|
135
|
+
return /* @__PURE__ */ g(h, { children: e.length > 0 && /* @__PURE__ */ g(u, {
|
|
136
|
+
...y.createAttributes("NotificationsStack"),
|
|
137
|
+
anchorOrigin: {
|
|
138
|
+
horizontal: "right",
|
|
139
|
+
vertical: "top"
|
|
140
|
+
},
|
|
141
|
+
open: !0,
|
|
142
|
+
children: /* @__PURE__ */ g(i, { children: e.map((e) => /* @__PURE__ */ g(C, {
|
|
143
|
+
allowClose: !0,
|
|
144
|
+
notification: e,
|
|
145
|
+
onClose: n
|
|
146
|
+
}, e.key)) })
|
|
147
|
+
}) });
|
|
148
|
+
};
|
|
149
|
+
//#endregion
|
|
150
|
+
export { w as n, T as t };
|
|
151
|
+
|
|
152
|
+
//# sourceMappingURL=Notifications.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Notifications.js","names":[],"sources":["../../src/components/ui/Notifications/NotificationItem.tsx","../../src/components/ui/Notifications/NotificationsDrawer.tsx","../../src/components/ui/Notifications/NotificationsStack.tsx"],"sourcesContent":["import {\n Alert,\n AlertTitle,\n Box,\n CircularProgress,\n} from '@mui/material';\nimport {\n useCallback,\n useMemo,\n} from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { TestIdUtil } from '@gen-epix/ui-core/utils/TestIdUtil';\n\nimport { TimeUtil } from '../../../utils/TimeUtil';\nimport type { Notification } from '../../../models/notification';\n\nexport type NotificationItemProps = {\n readonly allowClose: boolean;\n readonly notification: Notification;\n readonly onClose: (key: string) => void;\n readonly showTimestamp?: boolean;\n};\n\nexport const NotificationItem = ({ allowClose, notification, onClose, showTimestamp }: NotificationItemProps) => {\n const { t } = useTranslation();\n\n const onCloseButtonClick = useCallback(() => {\n onClose(notification.key);\n }, [notification.key, onClose]);\n\n const now = useMemo(() => new Date().getTime(), []);\n\n return (\n <Alert\n {...TestIdUtil.createAttributes('NotificationItem', { key: notification.key })}\n closeText={t`Clear notification`}\n icon={notification.isLoading ? <CircularProgress size={16} /> : undefined}\n onClose={allowClose ? onCloseButtonClick : undefined}\n severity={notification.isLoading ? 'info' : notification.severity}\n slotProps={{\n message: {\n sx: {\n flexGrow: 1,\n },\n },\n }}\n sx={{\n backgroundColor: 'background.paper',\n boxShadow: 1,\n marginBottom: 1,\n }}\n >\n <AlertTitle\n sx={{\n width: '100%',\n }}\n >\n {notification.message}\n </AlertTitle>\n {showTimestamp && (\n <Box\n sx={{\n textAlign: 'right',\n }}\n >\n {TimeUtil.getReadableTimeRemaining(now - notification.timestamp, true)}\n {' '}\n {t('ago')}\n </Box>\n )}\n </Alert>\n );\n};\n","import {\n Box,\n Button,\n Divider,\n Drawer,\n IconButton,\n Typography,\n useTheme,\n} from '@mui/material';\nimport CloseIcon from '@mui/icons-material/Close';\nimport NotificationsIcon from '@mui/icons-material/Notifications';\nimport { useCallback } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { useSubscribable } from '@gen-epix/ui-core/hooks/useSubscribable';\n\nimport { NotificationService } from '../../../classes/services/NotificationService';\n\nimport { NotificationItem } from './NotificationItem';\n\nexport type NotificationsDrawerProps = {\n readonly onDrawerClose: () => void;\n readonly open: boolean;\n};\n\nexport const NotificationsDrawer = ({ onDrawerClose, open }: NotificationsDrawerProps) => {\n const { t } = useTranslation();\n const theme = useTheme();\n const notifications = useSubscribable(NotificationService.getInstance());\n\n const onNotificationItemClose = useCallback((key: string) => {\n NotificationService.getInstance().clearNotification(key);\n }, []);\n\n const onClearAllButtonClick = useCallback(() => {\n NotificationService.getInstance().clearNotifications();\n onDrawerClose();\n }, [onDrawerClose]);\n\n return (\n <Drawer\n anchor={'right'}\n onClose={onDrawerClose}\n open={open}\n >\n <Box\n sx={{\n padding: theme.spacing(2),\n [theme.breakpoints.up('xl')]: {\n width: '620px',\n },\n width: '520px',\n }}\n >\n <Box\n sx={{\n alignItems: 'center',\n display: 'flex',\n justifyContent: 'space-between',\n marginBottom: 2,\n }}\n >\n <Typography\n component={'h6'}\n variant={'h3'}\n >\n {t`Notifications`}\n </Typography>\n <IconButton\n aria-label={t`Close notifications drawer`}\n onClick={onDrawerClose}\n >\n <CloseIcon\n sx={{\n '&:hover': {\n color: theme.palette.text.primary,\n },\n color: theme.palette.text.secondary,\n }}\n />\n </IconButton>\n </Box>\n {notifications.length === 0 && (\n <Box>\n <Box\n sx={{\n display: 'flex',\n justifyContent: 'center',\n marginBottom: 2,\n }}\n >\n <NotificationsIcon\n sx={{\n color: theme.palette.text.disabled,\n fontSize: 100,\n }}\n />\n </Box>\n <Box\n sx={{\n display: 'flex',\n justifyContent: 'center',\n }}\n >\n <Typography>\n {t`No new notifications in this session`}\n </Typography>\n </Box>\n </Box>\n )}\n {notifications.length > 0 && (\n <Box>\n <Box\n sx={{\n display: 'flex',\n justifyContent: 'flex-end',\n }}\n >\n <Button\n aria-label={t`Clear all notifications`}\n color={'primary'}\n onClick={onClearAllButtonClick}\n variant={'outlined'}\n >\n {t`Clear all notifications`}\n </Button>\n </Box>\n <Box\n sx={{\n marginY: 2,\n }}\n >\n <Divider />\n </Box>\n <Box\n sx={{\n overflowY: 'hidden',\n }}\n >\n <Box\n sx={{\n maxHeight: '100%',\n overflowY: 'auto',\n }}\n >\n {notifications.map(notification => (\n <NotificationItem\n allowClose={!notification.isLoading}\n key={notification.key}\n notification={notification}\n onClose={onNotificationItemClose}\n showTimestamp\n />\n ))}\n </Box>\n </Box>\n </Box>\n )}\n </Box>\n </Drawer>\n );\n};\n","import type { ReactElement } from 'react';\nimport { useCallback } from 'react';\nimport {\n Box,\n Snackbar,\n} from '@mui/material';\nimport { TestIdUtil } from '@gen-epix/ui-core/utils/TestIdUtil';\nimport { useSubscribable } from '@gen-epix/ui-core/hooks/useSubscribable';\n\nimport { NotificationService } from '../../../classes/services/NotificationService';\n\nimport { NotificationItem } from './NotificationItem';\n\nexport const NotificationsStack = (): ReactElement => {\n const visibleNotifications = useSubscribable(NotificationService.getInstance(), {\n select: (notifications) => notifications.filter(notification => notification.visible),\n });\n\n const onNotificationItemClose = useCallback((key: string) => {\n NotificationService.getInstance().hideNotification(key);\n }, []);\n\n return (\n <>\n {visibleNotifications.length > 0 && (\n <Snackbar\n {...TestIdUtil.createAttributes('NotificationsStack')}\n anchorOrigin={{ horizontal: 'right', vertical: 'top' }}\n open\n >\n <Box>\n {visibleNotifications.map(notification => (\n <NotificationItem\n allowClose\n key={notification.key}\n notification={notification}\n onClose={onNotificationItemClose}\n />\n ))}\n </Box>\n </Snackbar>\n )}\n </>\n );\n};\n"],"mappings":";;;;;;;;;;;AAuBA,IAAa,KAAoB,EAAE,eAAY,iBAAc,YAAS,uBAA2C;CAC/G,IAAM,EAAE,SAAM,EAAe,GAEvB,IAAqB,QAAkB;EAC3C,EAAQ,EAAa,GAAG;CAC1B,GAAG,CAAC,EAAa,KAAK,CAAO,CAAC,GAExB,IAAM,yBAAc,IAAI,KAAK,EAAA,CAAE,QAAQ,GAAG,CAAC,CAA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kB,EAAc,QAAO,MAAgB,EAAa,OAAO,EACtF,CAAC,GAEK,IAA0B,GAAa,MAAgB;EAC3D,EAAoB,YAAY,CAAC,CAAC,iBAAiB,CAAG;CACxD,GAAG,CAAC,CAAC;CAEL,OACE,kBAAA,GAAA,EAAA,UACG,EAAqB,SAAS,KAC7B,kBAAC,GAAD;EACE,GAAI,EAAW,iBAAiB,oBAAoB;EACpD,cAAc;GAAE,YAAY;GAAS,UAAU;EAAM;EACrD,MAAA;YAEA,kBAAC,GAAD,EAAA,UACG,EAAqB,KAAI,MACxB,kBAAC,GAAD;GACE,YAAA;GAEc;GACd,SAAS;EACV,GAHM,EAAa,GAGnB,CACF,EACE,CAAA;CACG,CAAA,EAEZ,CAAA;AAEN"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { t as e } from "./format.js";
|
|
2
|
+
import { DATE_FORMAT as t } from "@gen-epix/ui-core/constants/date";
|
|
3
|
+
import { Alert as n, AlertTitle as r, Box as i, Typography as a } from "@mui/material";
|
|
4
|
+
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
5
|
+
import { useTranslation as c } from "react-i18next";
|
|
6
|
+
//#region src/components/ui/OutageList/OutageItem.tsx
|
|
7
|
+
var l = ({ outage: l, severity: u, title: d }) => {
|
|
8
|
+
let { t: f } = c();
|
|
9
|
+
return /* @__PURE__ */ s(n, {
|
|
10
|
+
severity: u,
|
|
11
|
+
children: [
|
|
12
|
+
/* @__PURE__ */ o(r, { children: d }),
|
|
13
|
+
/* @__PURE__ */ o(i, { children: l.description }),
|
|
14
|
+
/* @__PURE__ */ o(i, { children: /* @__PURE__ */ s(a, {
|
|
15
|
+
component: "p",
|
|
16
|
+
children: [
|
|
17
|
+
f`Expected start: `,
|
|
18
|
+
" ",
|
|
19
|
+
l.active_from ? e(new Date(l.active_from), t.DATE_TIME) : f`Unknown`
|
|
20
|
+
]
|
|
21
|
+
}) }),
|
|
22
|
+
/* @__PURE__ */ o(i, { children: /* @__PURE__ */ s(a, {
|
|
23
|
+
component: "p",
|
|
24
|
+
children: [
|
|
25
|
+
f`Expected end: `,
|
|
26
|
+
" ",
|
|
27
|
+
l.active_to ? e(new Date(l.active_to), t.DATE_TIME) : f`Unknown`
|
|
28
|
+
]
|
|
29
|
+
}) })
|
|
30
|
+
]
|
|
31
|
+
});
|
|
32
|
+
}, u = ({ itemTitle: e, outages: t, severity: n, title: r }) => /* @__PURE__ */ s(i, {
|
|
33
|
+
sx: { marginBottom: 2 },
|
|
34
|
+
children: [/* @__PURE__ */ o(i, {
|
|
35
|
+
sx: { marginBottom: 1 },
|
|
36
|
+
children: /* @__PURE__ */ o(a, {
|
|
37
|
+
component: "p",
|
|
38
|
+
children: r
|
|
39
|
+
})
|
|
40
|
+
}), t.map((t) => /* @__PURE__ */ o(i, {
|
|
41
|
+
sx: { marginBottom: 1 },
|
|
42
|
+
children: /* @__PURE__ */ o(l, {
|
|
43
|
+
outage: t,
|
|
44
|
+
severity: n,
|
|
45
|
+
title: e
|
|
46
|
+
})
|
|
47
|
+
}, t.id))]
|
|
48
|
+
}), d = ({ activeOutages: e, soonActiveOutages: t, visibleOutages: n }) => {
|
|
49
|
+
let { t: r } = c();
|
|
50
|
+
return /* @__PURE__ */ s(i, { children: [
|
|
51
|
+
n.length === 0 && e.length === 0 && t.length === 0 && /* @__PURE__ */ o(i, { children: /* @__PURE__ */ o(a, {
|
|
52
|
+
component: "p",
|
|
53
|
+
children: r`There no current or scheduled outages.`
|
|
54
|
+
}) }),
|
|
55
|
+
e.length > 0 && /* @__PURE__ */ o(u, {
|
|
56
|
+
itemTitle: r`Active outage`,
|
|
57
|
+
outages: e,
|
|
58
|
+
severity: "error",
|
|
59
|
+
title: r`Our platform is experiencing an active outing.`
|
|
60
|
+
}),
|
|
61
|
+
t.length > 0 && /* @__PURE__ */ o(u, {
|
|
62
|
+
itemTitle: r`Upcoming outage`,
|
|
63
|
+
outages: t,
|
|
64
|
+
severity: "warning",
|
|
65
|
+
title: r`Our platform will soon go down for a planned outage.`
|
|
66
|
+
}),
|
|
67
|
+
n.length > 0 && /* @__PURE__ */ o(u, {
|
|
68
|
+
itemTitle: r`Planned outage`,
|
|
69
|
+
outages: n,
|
|
70
|
+
severity: "info",
|
|
71
|
+
title: r`There are scheduled outages. Our platform will be disrupted during these times.`
|
|
72
|
+
})
|
|
73
|
+
] });
|
|
74
|
+
};
|
|
75
|
+
//#endregion
|
|
76
|
+
export { d as t };
|
|
77
|
+
|
|
78
|
+
//# sourceMappingURL=OutageList.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OutageList.js","names":[],"sources":["../../src/components/ui/OutageList/OutageItem.tsx","../../src/components/ui/OutageList/OutageSection.tsx","../../src/components/ui/OutageList/OutageList.tsx"],"sourcesContent":["import type { AlertProps } from '@mui/material';\nimport {\n Alert,\n AlertTitle,\n Box,\n Typography,\n} from '@mui/material';\nimport { useTranslation } from 'react-i18next';\nimport { format } from 'date-fns';\nimport type { CommonDbOutage } from '@gen-epix/api-commondb';\nimport { DATE_FORMAT } from '@gen-epix/ui-core/constants/date';\n\ntype OutageItemProps = {\n readonly outage: CommonDbOutage;\n readonly severity: AlertProps['severity'];\n readonly title: string;\n};\nexport const OutageItem = ({ outage, severity, title }: OutageItemProps) => {\n const { t } = useTranslation();\n\n return (\n <Alert\n severity={severity}\n >\n <AlertTitle>\n {title}\n </AlertTitle>\n <Box>\n {outage.description}\n </Box>\n <Box>\n <Typography component={'p'}>\n {t`Expected start: `}\n {' '}\n {outage.active_from ? format(new Date(outage.active_from), DATE_FORMAT.DATE_TIME) : t`Unknown`}\n </Typography>\n </Box>\n <Box>\n <Typography component={'p'}>\n {t`Expected end: `}\n {' '}\n {outage.active_to ? format(new Date(outage.active_to), DATE_FORMAT.DATE_TIME) : t`Unknown`}\n </Typography>\n </Box>\n </Alert>\n );\n};\n","import type { AlertProps } from '@mui/material';\nimport {\n Box,\n Typography,\n} from '@mui/material';\nimport type { CommonDbOutage } from '@gen-epix/api-commondb';\n\nimport { OutageItem } from './OutageItem';\n\ntype OutageSectionProps = {\n readonly itemTitle: string;\n readonly outages: CommonDbOutage[];\n readonly severity: AlertProps['severity'];\n readonly title: string;\n};\nexport const OutageSection = ({ itemTitle, outages, severity, title }: OutageSectionProps) => {\n return (\n <Box\n sx={{\n marginBottom: 2,\n }}\n >\n <Box\n sx={{\n marginBottom: 1,\n }}\n >\n <Typography component={'p'}>\n {title}\n </Typography>\n </Box>\n {outages.map((outage) => (\n <Box\n key={outage.id}\n sx={{\n marginBottom: 1,\n }}\n >\n <OutageItem\n outage={outage}\n severity={severity}\n title={itemTitle}\n />\n </Box>\n ))}\n </Box>\n );\n};\n","import {\n Box,\n Typography,\n} from '@mui/material';\nimport { useTranslation } from 'react-i18next';\nimport type { CommonDbOutage } from '@gen-epix/api-commondb';\n\nimport { OutageSection } from './OutageSection';\n\nexport type OutageListProps = {\n readonly activeOutages: CommonDbOutage[];\n readonly soonActiveOutages: CommonDbOutage[];\n readonly visibleOutages: CommonDbOutage[];\n};\nexport const OutageList = ({ activeOutages, soonActiveOutages, visibleOutages }: OutageListProps) => {\n const { t } = useTranslation();\n\n return (\n <Box>\n {visibleOutages.length === 0 && activeOutages.length === 0 && soonActiveOutages.length === 0 && (\n <Box>\n <Typography component={'p'}>\n {t`There no current or scheduled outages.`}\n </Typography>\n </Box>\n )}\n {activeOutages.length > 0 && (\n <OutageSection\n itemTitle={t`Active outage`}\n outages={activeOutages}\n severity={'error'}\n title={t`Our platform is experiencing an active outing.`}\n />\n )}\n {soonActiveOutages.length > 0 && (\n <OutageSection\n itemTitle={t`Upcoming outage`}\n outages={soonActiveOutages}\n severity={'warning'}\n title={t`Our platform will soon go down for a planned outage.`}\n />\n )}\n {visibleOutages.length > 0 && (\n <OutageSection\n itemTitle={t`Planned outage`}\n outages={visibleOutages}\n severity={'info'}\n title={t`There are scheduled outages. Our platform will be disrupted during these times.`}\n />\n )}\n </Box>\n );\n};\n"],"mappings":";;;;;;AAiBA,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ACV,OAAO,CAAC;EACT,CAAA;EAEF,EAAkB,SAAS,KAC1B,kBAAC,GAAD;GACE,WAAW,CAAC;GACZ,SAAS;GACT,UAAU;GACV,OAAO,CAAC;EACT,CAAA;EAEF,EAAe,SAAS,KACvB,kBAAC,GAAD;GACE,WAAW,CAAC;GACZ,SAAS;GACT,UAAU;GACV,OAAO,CAAC;EACT,CAAA;CAEA,EAAA,CAAA;AAET"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { i as e, n as t, t as n } from "./toDate.js";
|
|
2
|
+
import { ConfigService as r } from "../classes/services/ConfigService/index.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/date-fns@4.4.0/node_modules/date-fns/addMilliseconds.js
|
|
4
|
+
function i(e, r, i) {
|
|
5
|
+
return t(i?.in || e, +n(e) + r);
|
|
6
|
+
}
|
|
7
|
+
//#endregion
|
|
8
|
+
//#region ../../node_modules/.pnpm/date-fns@4.4.0/node_modules/date-fns/addHours.js
|
|
9
|
+
function a(t, n, r) {
|
|
10
|
+
return i(t, n * e, r);
|
|
11
|
+
}
|
|
12
|
+
//#endregion
|
|
13
|
+
//#region src/utils/OutageUtil/OutageUtil.ts
|
|
14
|
+
var o = class {
|
|
15
|
+
static getCategorizedOutages(e) {
|
|
16
|
+
let t = e.filter((e) => {
|
|
17
|
+
if (e.is_active) return !0;
|
|
18
|
+
if (e.active_from || e.active_to) {
|
|
19
|
+
let t = /* @__PURE__ */ new Date();
|
|
20
|
+
return e.active_from && e.active_to ? t >= new Date(e.active_from) && t < new Date(e.active_to) : !!(e.active_from && t >= new Date(e.active_from) || e.active_to && t < new Date(e.active_to));
|
|
21
|
+
}
|
|
22
|
+
}), n = t.map((e) => e.id), i = e.filter((e) => {
|
|
23
|
+
if (n.includes(e.id)) return !1;
|
|
24
|
+
if (e.is_visible) return !0;
|
|
25
|
+
if (e.visible_from || e.visible_to) {
|
|
26
|
+
let t = /* @__PURE__ */ new Date();
|
|
27
|
+
return e.visible_from && e.visible_to ? t >= new Date(e.visible_from) && t < new Date(e.visible_to) : !!(e.visible_from && t >= new Date(e.visible_from) || e.visible_to && t < new Date(e.visible_to));
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
return {
|
|
31
|
+
activeOutages: t,
|
|
32
|
+
soonActiveOutages: e.filter((e) => {
|
|
33
|
+
if (n.includes(e.id)) return !1;
|
|
34
|
+
if (e.is_active) return !0;
|
|
35
|
+
if (e.active_from || e.active_to) {
|
|
36
|
+
let t = /* @__PURE__ */ new Date(), n = a(t, r.getInstance().config.outages.NUM_HOURS_TO_SHOW_SOON_ACTIVE_OUTAGES);
|
|
37
|
+
return e.active_from && e.active_to ? n >= new Date(e.active_from) && t < new Date(e.active_to) : !!(e.active_from && n >= new Date(e.active_from) || e.active_to && t < new Date(e.active_to));
|
|
38
|
+
}
|
|
39
|
+
}),
|
|
40
|
+
visibleOutages: i
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
//#endregion
|
|
45
|
+
export { o as t };
|
|
46
|
+
|
|
47
|
+
//# sourceMappingURL=OutageUtil.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OutageUtil.js","names":[],"sources":["../../../../node_modules/.pnpm/date-fns@4.4.0/node_modules/date-fns/addMilliseconds.js","../../../../node_modules/.pnpm/date-fns@4.4.0/node_modules/date-fns/addHours.js","../../src/utils/OutageUtil/OutageUtil.ts"],"sourcesContent":["import { constructFrom } from \"./constructFrom.js\";\nimport { toDate } from \"./toDate.js\";\n\n/**\n * The {@link addMilliseconds} function options.\n */\n\n/**\n * @name addMilliseconds\n * @category Millisecond Helpers\n * @summary Add the specified number of milliseconds to the given date.\n *\n * @description\n * Add the specified number of milliseconds to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param amount - The amount of milliseconds to be added.\n * @param options - The options object\n *\n * @returns The new date with the milliseconds added\n *\n * @example\n * // Add 750 milliseconds to 10 July 2014 12:45:30.000:\n * const result = addMilliseconds(new Date(2014, 6, 10, 12, 45, 30, 0), 750)\n * //=> Thu Jul 10 2014 12:45:30.750\n */\nexport function addMilliseconds(date, amount, options) {\n return constructFrom(options?.in || date, +toDate(date) + amount);\n}\n\n// Fallback for modularized imports:\nexport default addMilliseconds;\n","import { addMilliseconds } from \"./addMilliseconds.js\";\nimport { millisecondsInHour } from \"./constants.js\";\n\n/**\n * The {@link addHours} function options.\n */\n\n/**\n * @name addHours\n * @category Hour Helpers\n * @summary Add the specified number of hours to the given date.\n *\n * @description\n * Add the specified number of hours to the given date.\n *\n * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).\n * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.\n *\n * @param date - The date to be changed\n * @param amount - The amount of hours to be added\n * @param options - An object with options\n *\n * @returns The new date with the hours added\n *\n * @example\n * // Add 2 hours to 10 July 2014 23:00:00:\n * const result = addHours(new Date(2014, 6, 10, 23, 0), 2)\n * //=> Fri Jul 11 2014 01:00:00\n */\nexport function addHours(date, amount, options) {\n return addMilliseconds(date, amount * millisecondsInHour, options);\n}\n\n// Fallback for modularized imports:\nexport default addHours;\n","import { addHours } from 'date-fns';\nimport type { CommonDbOutage } from '@gen-epix/api-commondb';\n\nimport { ConfigService } from '../../classes/services/ConfigService';\nimport type { CategorizedOutages } from '../../models/outage';\n\nexport class OutageUtil {\n public static getCategorizedOutages(outages: CommonDbOutage[]): CategorizedOutages {\n\n const activeOutages = outages.filter((outage) => {\n if (outage.is_active) {\n return true;\n }\n if (outage.active_from || outage.active_to) {\n const now = new Date();\n if (outage.active_from && outage.active_to) {\n return now >= new Date(outage.active_from) && now < new Date(outage.active_to);\n }\n if (outage.active_from && now >= new Date(outage.active_from)) {\n return true;\n }\n if (outage.active_to && now < new Date(outage.active_to)) {\n return true;\n }\n return false;\n }\n });\n const activeOutageIds = activeOutages.map((outage) => outage.id);\n\n const visibleOutages = outages.filter((outage) => {\n if (activeOutageIds.includes(outage.id)) {\n return false;\n }\n if (outage.is_visible) {\n return true;\n }\n if (outage.visible_from || outage.visible_to) {\n const now = new Date();\n if (outage.visible_from && outage.visible_to) {\n return now >= new Date(outage.visible_from) && now < new Date(outage.visible_to);\n }\n if (outage.visible_from && now >= new Date(outage.visible_from)) {\n return true;\n }\n if (outage.visible_to && now < new Date(outage.visible_to)) {\n return true;\n }\n return false;\n }\n });\n\n const soonActiveOutages = outages.filter((outage) => {\n if (activeOutageIds.includes(outage.id)) {\n return false;\n }\n if (outage.is_active) {\n return true;\n }\n if (outage.active_from || outage.active_to) {\n const now = new Date();\n const soon = addHours(now, ConfigService.getInstance().config.outages.NUM_HOURS_TO_SHOW_SOON_ACTIVE_OUTAGES);\n if (outage.active_from && outage.active_to) {\n return soon >= new Date(outage.active_from) && now < new Date(outage.active_to);\n }\n if (outage.active_from && soon >= new Date(outage.active_from)) {\n return true;\n }\n if (outage.active_to && now < new Date(outage.active_to)) {\n return true;\n }\n return false;\n }\n });\n\n return {\n activeOutages,\n soonActiveOutages,\n visibleOutages,\n };\n }\n}\n"],"x_google_ignoreList":[0,1],"mappings":";;;AA6BA,SAAgB,EAAgB,GAAM,GAAQ,GAAS;CACrD,OAAO,EAAc,GAAS,MAAM,GAAM,CAAC,EAAO,CAAI,IAAI,CAAM;AAClE;;;ACFA,SAAgB,EAAS,GAAM,GAAQ,GAAS;CAC9C,OAAO,EAAgB,GAAM,IAAS,GAAoB,CAAO;AACnE;;;ACzBA,IAAa,IAAb,MAAwB;CACtB,OAAc,sBAAsB,GAA+C;EAEjF,IAAM,IAAgB,EAAQ,QAAQ,MAAW;GAC/C,IAAI,EAAO,WACT,OAAO;GAET,IAAI,EAAO,eAAe,EAAO,WA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|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import * as e from "react";
|
|
2
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@tanstack+react-query@5.101.2_react@19.2.7/node_modules/@tanstack/react-query/build/modern/QueryClientProvider.js
|
|
4
|
+
var n = e.createContext(void 0), r = (t) => {
|
|
5
|
+
let r = e.useContext(n);
|
|
6
|
+
if (t) return t;
|
|
7
|
+
if (!r) throw Error("No QueryClient set, use QueryClientProvider to set one");
|
|
8
|
+
return r;
|
|
9
|
+
}, i = ({ client: r, children: i }) => (e.useEffect(() => (r.mount(), () => {
|
|
10
|
+
r.unmount();
|
|
11
|
+
}), [r]), /* @__PURE__ */ t(n.Provider, {
|
|
12
|
+
value: r,
|
|
13
|
+
children: i
|
|
14
|
+
}));
|
|
15
|
+
//#endregion
|
|
16
|
+
export { r as n, i as t };
|
|
17
|
+
|
|
18
|
+
//# sourceMappingURL=QueryClientProvider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QueryClientProvider.js","names":["React"],"sources":["../../../../node_modules/.pnpm/@tanstack+react-query@5.101.2_react@19.2.7/node_modules/@tanstack/react-query/build/modern/QueryClientProvider.js"],"sourcesContent":["\"use client\";\n\n// src/QueryClientProvider.tsx\nimport * as React from \"react\";\nimport { jsx } from \"react/jsx-runtime\";\nvar QueryClientContext = React.createContext(\n void 0\n);\nvar useQueryClient = (queryClient) => {\n const client = React.useContext(QueryClientContext);\n if (queryClient) {\n return queryClient;\n }\n if (!client) {\n throw new Error(\"No QueryClient set, use QueryClientProvider to set one\");\n }\n return client;\n};\nvar QueryClientProvider = ({\n client,\n children\n}) => {\n React.useEffect(() => {\n client.mount();\n return () => {\n client.unmount();\n };\n }, [client]);\n return /* @__PURE__ */ jsx(QueryClientContext.Provider, { value: client, children });\n};\nexport {\n QueryClientContext,\n QueryClientProvider,\n useQueryClient\n};\n//# sourceMappingURL=QueryClientProvider.js.map"],"x_google_ignoreList":[0],"mappings":";;;AAKA,IAAI,IAAqBA,EAAM,cAC7B,KAAK,CACP,GACI,KAAkB,MAAgB;CACpC,IAAM,IAASA,EAAM,WAAW,CAAkB;CAClD,IAAI,GACF,OAAO;CAET,IAAI,CAAC,GACH,MAAU,MAAM,wDAAwD;CAE1E,OAAO;AACT,GACI,KAAuB,EACzB,WACA,mBAEA,EAAM,iBACJ,EAAO,MAAM,SACA;CACX,EAAO,QAAQ;AACjB,IACC,CAAC,CAAM,CAAC,GACY,kBAAI,EAAmB,UAAU;CAAE,OAAO;CAAQ;AAAS,CAAC"}
|