@stack-spot/portal-layout 0.0.65 → 1.0.0-stg.1768483038644
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/CHANGELOG.md +779 -0
- package/dist/Layout.d.ts +60 -8
- package/dist/Layout.d.ts.map +1 -1
- package/dist/Layout.js +59 -24
- package/dist/Layout.js.map +1 -1
- package/dist/LayoutOverlayManager.d.ts +274 -19
- package/dist/LayoutOverlayManager.d.ts.map +1 -1
- package/dist/LayoutOverlayManager.js +373 -82
- package/dist/LayoutOverlayManager.js.map +1 -1
- package/dist/WelcomeTour.d.ts +2 -0
- package/dist/WelcomeTour.d.ts.map +1 -0
- package/dist/WelcomeTour.js +8 -0
- package/dist/WelcomeTour.js.map +1 -0
- package/dist/components/Backdrop.d.ts +75 -0
- package/dist/components/Backdrop.d.ts.map +1 -0
- package/dist/components/Backdrop.js +69 -0
- package/dist/components/Backdrop.js.map +1 -0
- package/dist/components/Contact/show-contact-modal.d.ts +5 -0
- package/dist/components/Contact/show-contact-modal.d.ts.map +1 -0
- package/dist/components/Contact/show-contact-modal.js +37 -0
- package/dist/components/Contact/show-contact-modal.js.map +1 -0
- package/dist/components/ContactModal.d.ts +1 -0
- package/dist/components/ContactModal.d.ts.map +1 -0
- package/dist/components/ContactModal.js +2 -0
- package/dist/components/ContactModal.js.map +1 -0
- package/dist/components/Dialog.d.ts +54 -7
- package/dist/components/Dialog.d.ts.map +1 -1
- package/dist/components/Dialog.js +8 -2
- package/dist/components/Dialog.js.map +1 -1
- package/dist/components/Header.d.ts +38 -2
- package/dist/components/Header.d.ts.map +1 -1
- package/dist/components/Header.js +9 -4
- package/dist/components/Header.js.map +1 -1
- package/dist/components/NotificationCenter/NotificationPanel.d.ts +3 -0
- package/dist/components/NotificationCenter/NotificationPanel.d.ts.map +1 -0
- package/dist/components/NotificationCenter/NotificationPanel.js +19 -0
- package/dist/components/NotificationCenter/NotificationPanel.js.map +1 -0
- package/dist/components/NotificationCenter/NotificationPanelHeader.d.ts +3 -0
- package/dist/components/NotificationCenter/NotificationPanelHeader.d.ts.map +1 -0
- package/dist/components/NotificationCenter/NotificationPanelHeader.js +16 -0
- package/dist/components/NotificationCenter/NotificationPanelHeader.js.map +1 -0
- package/dist/components/NotificationCenter/NotificationsPanelFooter.d.ts +4 -0
- package/dist/components/NotificationCenter/NotificationsPanelFooter.d.ts.map +1 -0
- package/dist/components/NotificationCenter/NotificationsPanelFooter.js +12 -0
- package/dist/components/NotificationCenter/NotificationsPanelFooter.js.map +1 -0
- package/dist/components/NotificationCenter/dictionary.d.ts +2 -0
- package/dist/components/NotificationCenter/dictionary.d.ts.map +1 -0
- package/dist/components/NotificationCenter/dictionary.js +43 -0
- package/dist/components/NotificationCenter/dictionary.js.map +1 -0
- package/dist/components/NotificationCenter/index.d.ts +2 -0
- package/dist/components/NotificationCenter/index.d.ts.map +1 -0
- package/dist/components/NotificationCenter/index.js +34 -0
- package/dist/components/NotificationCenter/index.js.map +1 -0
- package/dist/components/NotificationCenter/styled.d.ts +3 -0
- package/dist/components/NotificationCenter/styled.d.ts.map +1 -0
- package/dist/components/NotificationCenter/styled.js +74 -0
- package/dist/components/NotificationCenter/styled.js.map +1 -0
- package/dist/components/NotificationCenter/types.d.ts +21 -0
- package/dist/components/NotificationCenter/types.d.ts.map +1 -0
- package/dist/components/NotificationCenter/types.js.map +1 -0
- package/dist/components/NotificationCenter/utils.d.ts +5 -0
- package/dist/components/NotificationCenter/utils.d.ts.map +1 -0
- package/dist/components/NotificationCenter/utils.js +18 -0
- package/dist/components/NotificationCenter/utils.js.map +1 -0
- package/dist/components/OverlayContent.d.ts +27 -1
- package/dist/components/OverlayContent.d.ts.map +1 -1
- package/dist/components/OverlayContent.js +8 -4
- package/dist/components/OverlayContent.js.map +1 -1
- package/dist/components/PortalSwitcher.d.ts +19 -1
- package/dist/components/PortalSwitcher.d.ts.map +1 -1
- package/dist/components/PortalSwitcher.js +16 -31
- package/dist/components/PortalSwitcher.js.map +1 -1
- package/dist/components/PrivacyPolicyMessage/hooks.d.ts +10 -0
- package/dist/components/PrivacyPolicyMessage/hooks.d.ts.map +1 -0
- package/dist/components/PrivacyPolicyMessage/hooks.js +33 -0
- package/dist/components/PrivacyPolicyMessage/hooks.js.map +1 -0
- package/dist/components/PrivacyPolicyMessage/index.d.ts +7 -0
- package/dist/components/PrivacyPolicyMessage/index.d.ts.map +1 -0
- package/dist/components/PrivacyPolicyMessage/index.js +5 -0
- package/dist/components/PrivacyPolicyMessage/index.js.map +1 -0
- package/dist/components/Rate/FeedbackModal.d.ts +8 -0
- package/dist/components/Rate/FeedbackModal.d.ts.map +1 -0
- package/dist/components/Rate/FeedbackModal.js +52 -0
- package/dist/components/Rate/FeedbackModal.js.map +1 -0
- package/dist/components/Rate/hook.d.ts +3 -0
- package/dist/components/Rate/hook.d.ts.map +1 -0
- package/dist/components/Rate/hook.js +48 -0
- package/dist/components/Rate/hook.js.map +1 -0
- package/dist/components/Rate/index.d.ts +10 -0
- package/dist/components/Rate/index.d.ts.map +1 -0
- package/dist/components/Rate/index.js +16 -0
- package/dist/components/Rate/index.js.map +1 -0
- package/dist/components/Rate/on-nps-submit.d.ts +7 -0
- package/dist/components/Rate/on-nps-submit.d.ts.map +1 -0
- package/dist/components/Rate/on-nps-submit.js +8 -0
- package/dist/components/Rate/on-nps-submit.js.map +1 -0
- package/dist/components/Rate/show-rate-us-modals.d.ts +17 -0
- package/dist/components/Rate/show-rate-us-modals.d.ts.map +1 -0
- package/dist/components/Rate/show-rate-us-modals.js +14 -0
- package/dist/components/Rate/show-rate-us-modals.js.map +1 -0
- package/dist/components/Rate/utils.d.ts +2 -0
- package/dist/components/Rate/utils.d.ts.map +1 -0
- package/dist/components/Rate/utils.js +10 -0
- package/dist/components/Rate/utils.js.map +1 -0
- package/dist/components/Toaster.d.ts +35 -0
- package/dist/components/Toaster.d.ts.map +1 -1
- package/dist/components/Toaster.js +32 -4
- package/dist/components/Toaster.js.map +1 -1
- package/dist/components/TypeForm/hook.d.ts +2 -0
- package/dist/components/TypeForm/hook.d.ts.map +1 -0
- package/dist/components/TypeForm/hook.js +11 -0
- package/dist/components/TypeForm/hook.js.map +1 -0
- package/dist/components/TypeForm/index.d.ts +6 -0
- package/dist/components/TypeForm/index.d.ts.map +1 -0
- package/dist/components/TypeForm/index.js +23 -0
- package/dist/components/TypeForm/index.js.map +1 -0
- package/dist/components/TypeForm/show-typeform-modal.d.ts +5 -0
- package/dist/components/TypeForm/show-typeform-modal.d.ts.map +1 -0
- package/dist/components/TypeForm/show-typeform-modal.js +11 -0
- package/dist/components/TypeForm/show-typeform-modal.js.map +1 -0
- package/dist/components/TypeForm/utils.d.ts +2 -0
- package/dist/components/TypeForm/utils.d.ts.map +1 -0
- package/dist/components/TypeForm/utils.js +9 -0
- package/dist/components/TypeForm/utils.js.map +1 -0
- package/dist/components/UserMenu.d.ts +19 -2
- package/dist/components/UserMenu.d.ts.map +1 -1
- package/dist/components/UserMenu.js +12 -6
- package/dist/components/UserMenu.js.map +1 -1
- package/dist/components/error/ErrorBoundary.d.ts +25 -4
- package/dist/components/error/ErrorBoundary.d.ts.map +1 -1
- package/dist/components/error/ErrorBoundary.js +10 -1
- package/dist/components/error/ErrorBoundary.js.map +1 -1
- package/dist/components/error/ErrorManager.d.ts +22 -6
- package/dist/components/error/ErrorManager.d.ts.map +1 -1
- package/dist/components/error/ErrorManager.js +21 -1
- package/dist/components/error/ErrorManager.js.map +1 -1
- package/dist/components/error/SilentErrorBoundary.d.ts +26 -5
- package/dist/components/error/SilentErrorBoundary.d.ts.map +1 -1
- package/dist/components/error/SilentErrorBoundary.js +10 -0
- package/dist/components/error/SilentErrorBoundary.js.map +1 -1
- package/dist/components/menu/MenuContent.d.ts +20 -4
- package/dist/components/menu/MenuContent.d.ts.map +1 -1
- package/dist/components/menu/MenuContent.js +89 -88
- package/dist/components/menu/MenuContent.js.map +1 -1
- package/dist/components/menu/MenuSectionGroup.d.ts +2 -0
- package/dist/components/menu/MenuSectionGroup.d.ts.map +1 -0
- package/dist/components/menu/MenuSectionGroup.js +121 -0
- package/dist/components/menu/MenuSectionGroup.js.map +1 -0
- package/dist/components/menu/MenuSections.d.ts +17 -0
- package/dist/components/menu/MenuSections.d.ts.map +1 -1
- package/dist/components/menu/MenuSections.js +159 -39
- package/dist/components/menu/MenuSections.js.map +1 -1
- package/dist/components/menu/PageSelector.d.ts +5 -0
- package/dist/components/menu/PageSelector.d.ts.map +1 -1
- package/dist/components/menu/PageSelector.js +9 -4
- package/dist/components/menu/PageSelector.js.map +1 -1
- package/dist/components/menu/types.d.ts +219 -8
- package/dist/components/menu/types.d.ts.map +1 -1
- package/dist/components/tour/StepContainer.d.ts +37 -0
- package/dist/components/tour/StepContainer.d.ts.map +1 -0
- package/dist/components/tour/StepContainer.js +51 -0
- package/dist/components/tour/StepContainer.js.map +1 -0
- package/dist/components/tour/StepNavigation.d.ts +29 -0
- package/dist/components/tour/StepNavigation.d.ts.map +1 -0
- package/dist/components/tour/StepNavigation.js +37 -0
- package/dist/components/tour/StepNavigation.js.map +1 -0
- package/dist/components/tour/StepTitle.d.ts +17 -0
- package/dist/components/tour/StepTitle.d.ts.map +1 -0
- package/dist/components/tour/StepTitle.js +10 -0
- package/dist/components/tour/StepTitle.js.map +1 -0
- package/dist/components/tour/hook.d.ts +3 -0
- package/dist/components/tour/hook.d.ts.map +1 -0
- package/dist/components/tour/hook.js +10 -0
- package/dist/components/tour/hook.js.map +1 -0
- package/dist/components/tour/index.d.ts +5 -0
- package/dist/components/tour/index.d.ts.map +1 -0
- package/dist/components/tour/index.js +5 -0
- package/dist/components/tour/index.js.map +1 -0
- package/dist/components/tour/manager.d.ts +34 -0
- package/dist/components/tour/manager.d.ts.map +1 -0
- package/dist/components/tour/manager.js +104 -0
- package/dist/components/tour/manager.js.map +1 -0
- package/dist/components/tour/utils.d.ts +67 -0
- package/dist/components/tour/utils.d.ts.map +1 -0
- package/dist/components/tour/utils.js +60 -0
- package/dist/components/tour/utils.js.map +1 -0
- package/dist/components/user-menu-manager.d.ts +13 -0
- package/dist/components/user-menu-manager.d.ts.map +1 -0
- package/dist/components/user-menu-manager.js +36 -0
- package/dist/components/user-menu-manager.js.map +1 -0
- package/dist/dictionary.d.ts +6 -1
- package/dist/dictionary.d.ts.map +1 -1
- package/dist/dictionary.js +7 -2
- package/dist/dictionary.js.map +1 -1
- package/dist/elements.d.ts +7 -0
- package/dist/elements.d.ts.map +1 -1
- package/dist/elements.js +7 -0
- package/dist/elements.js.map +1 -1
- package/dist/index.d.ts +15 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +15 -8
- package/dist/index.js.map +1 -1
- package/dist/layout.css +190 -35
- package/dist/svg/StarFillWithGradient.d.ts +6 -0
- package/dist/svg/StarFillWithGradient.d.ts.map +1 -0
- package/dist/svg/StarFillWithGradient.js +4 -0
- package/dist/svg/StarFillWithGradient.js.map +1 -0
- package/dist/toaster.d.ts +55 -9
- package/dist/toaster.d.ts.map +1 -1
- package/dist/toaster.js +34 -6
- package/dist/toaster.js.map +1 -1
- package/dist/types.d.ts +5 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +2 -0
- package/dist/types.js.map +1 -0
- package/dist/utils.d.ts +6 -69
- package/dist/utils.d.ts.map +1 -1
- package/dist/utils.js +9 -130
- package/dist/utils.js.map +1 -1
- package/package.dev.json +3 -0
- package/package.json +24 -13
- package/package.stg.json +3 -0
- package/readme.md +147 -0
- package/src/Layout.tsx +166 -58
- package/src/LayoutOverlayManager.tsx +499 -85
- package/src/WelcomeTour.tsx +8 -0
- package/src/components/Backdrop.tsx +116 -0
- package/src/components/Contact/show-contact-modal.tsx +71 -0
- package/src/components/Dialog.tsx +58 -9
- package/src/components/Header.tsx +53 -5
- package/src/components/NotificationCenter/NotificationPanel.tsx +40 -0
- package/src/components/NotificationCenter/NotificationPanelHeader.tsx +53 -0
- package/src/components/NotificationCenter/NotificationsPanelFooter.tsx +25 -0
- package/src/components/NotificationCenter/dictionary.ts +44 -0
- package/src/components/NotificationCenter/index.tsx +58 -0
- package/src/components/NotificationCenter/styled.ts +75 -0
- package/src/components/NotificationCenter/types.ts +24 -0
- package/src/components/NotificationCenter/utils.ts +20 -0
- package/src/components/OverlayContent.tsx +40 -5
- package/src/components/PortalSwitcher.tsx +33 -39
- package/src/components/PrivacyPolicyMessage/hooks.tsx +49 -0
- package/src/components/PrivacyPolicyMessage/index.tsx +21 -0
- package/src/components/Rate/FeedbackModal.tsx +86 -0
- package/src/components/Rate/hook.tsx +61 -0
- package/src/components/Rate/index.tsx +36 -0
- package/src/components/Rate/on-nps-submit.ts +18 -0
- package/src/components/Rate/show-rate-us-modals.tsx +29 -0
- package/src/components/Rate/utils.ts +11 -0
- package/src/components/Toaster.tsx +82 -3
- package/src/components/TypeForm/hook.tsx +13 -0
- package/src/components/TypeForm/index.tsx +50 -0
- package/src/components/TypeForm/show-typeform-modal.tsx +10 -0
- package/src/components/TypeForm/utils.ts +8 -0
- package/src/components/UserMenu.tsx +32 -8
- package/src/components/error/ErrorBoundary.tsx +11 -2
- package/src/components/error/ErrorManager.ts +22 -6
- package/src/components/error/SilentErrorBoundary.tsx +12 -2
- package/src/components/menu/MenuContent.tsx +102 -110
- package/src/components/menu/MenuSectionGroup.tsx +121 -0
- package/src/components/menu/MenuSections.tsx +342 -93
- package/src/components/menu/PageSelector.tsx +16 -4
- package/src/components/menu/types.ts +221 -9
- package/src/components/tour/StepContainer.tsx +92 -0
- package/src/components/tour/StepNavigation.tsx +72 -0
- package/src/components/tour/StepTitle.tsx +28 -0
- package/src/components/tour/hook.ts +12 -0
- package/src/components/tour/index.ts +6 -0
- package/src/components/tour/manager.tsx +119 -0
- package/src/components/tour/utils.tsx +119 -0
- package/src/components/user-menu-manager.ts +31 -0
- package/src/dictionary.ts +7 -2
- package/src/elements.ts +7 -0
- package/src/index.ts +15 -8
- package/src/layout.css +190 -35
- package/src/svg/StarFillWithGradient.tsx +14 -0
- package/src/toaster.tsx +90 -13
- package/src/types.ts +4 -0
- package/src/utils.ts +9 -142
- package/dist/components/BottomNotification.d.ts +0 -1
- package/dist/components/BottomNotification.d.ts.map +0 -1
- package/dist/components/BottomNotification.js +0 -2
- package/dist/components/BottomNotification.js.map +0 -1
- package/dist/components/BottomPanel.d.ts +0 -1
- package/dist/components/BottomPanel.d.ts.map +0 -1
- package/dist/components/BottomPanel.js +0 -2
- package/dist/components/BottomPanel.js.map +0 -1
- package/dist/components/SelectionList.d.ts +0 -36
- package/dist/components/SelectionList.d.ts.map +0 -1
- package/dist/components/SelectionList.js +0 -140
- package/dist/components/SelectionList.js.map +0 -1
- package/dist/components/error/ErrorFeedback.d.ts +0 -3
- package/dist/components/error/ErrorFeedback.d.ts.map +0 -1
- package/dist/components/error/ErrorFeedback.js +0 -66
- package/dist/components/error/ErrorFeedback.js.map +0 -1
- package/dist/components/menu/use-check-text-overflow.d.ts +0 -6
- package/dist/components/menu/use-check-text-overflow.d.ts.map +0 -1
- package/dist/components/menu/use-check-text-overflow.js +0 -20
- package/dist/components/menu/use-check-text-overflow.js.map +0 -1
- package/dist/components/menu/use-keyboard-controls.d.ts +0 -23
- package/dist/components/menu/use-keyboard-controls.d.ts.map +0 -1
- package/dist/components/menu/use-keyboard-controls.js +0 -49
- package/dist/components/menu/use-keyboard-controls.js.map +0 -1
- package/dist/components/tour/PortalSwitcherStep.d.ts +0 -3
- package/dist/components/tour/PortalSwitcherStep.d.ts.map +0 -1
- package/dist/components/tour/PortalSwitcherStep.js +0 -29
- package/dist/components/tour/PortalSwitcherStep.js.map +0 -1
- package/dist/components/types.d.ts +0 -15
- package/dist/components/types.d.ts.map +0 -1
- package/dist/components/types.js.map +0 -1
- package/dist/layout-context.d.ts +0 -10
- package/dist/layout-context.d.ts.map +0 -1
- package/dist/layout-context.js +0 -11
- package/dist/layout-context.js.map +0 -1
- package/dist/svg/AI.d.ts +0 -6
- package/dist/svg/AI.d.ts.map +0 -1
- package/dist/svg/AI.js +0 -9
- package/dist/svg/AI.js.map +0 -1
- package/dist/svg/EDP.d.ts +0 -6
- package/dist/svg/EDP.d.ts.map +0 -1
- package/dist/svg/EDP.js +0 -5
- package/dist/svg/EDP.js.map +0 -1
- package/dist/svg/Forbidden.d.ts +0 -6
- package/dist/svg/Forbidden.d.ts.map +0 -1
- package/dist/svg/Forbidden.js +0 -4
- package/dist/svg/Forbidden.js.map +0 -1
- package/dist/svg/HUB.d.ts +0 -6
- package/dist/svg/HUB.d.ts.map +0 -1
- package/dist/svg/HUB.js +0 -5
- package/dist/svg/HUB.js.map +0 -1
- package/dist/svg/Logo.d.ts +0 -2
- package/dist/svg/Logo.d.ts.map +0 -1
- package/dist/svg/Logo.js +0 -4
- package/dist/svg/Logo.js.map +0 -1
- package/dist/svg/NotFound.d.ts +0 -6
- package/dist/svg/NotFound.d.ts.map +0 -1
- package/dist/svg/NotFound.js +0 -4
- package/dist/svg/NotFound.js.map +0 -1
- package/dist/svg/ServerError.d.ts +0 -6
- package/dist/svg/ServerError.d.ts.map +0 -1
- package/dist/svg/ServerError.js +0 -4
- package/dist/svg/ServerError.js.map +0 -1
- package/dist/svg/Unauthenticated.d.ts +0 -6
- package/dist/svg/Unauthenticated.d.ts.map +0 -1
- package/dist/svg/Unauthenticated.js +0 -4
- package/dist/svg/Unauthenticated.js.map +0 -1
- package/src/components/BottomPanel.tsx +0 -0
- package/src/components/SelectionList.tsx +0 -272
- package/src/components/error/ErrorFeedback.tsx +0 -114
- package/src/components/menu/use-check-text-overflow.tsx +0 -26
- package/src/components/menu/use-keyboard-controls.tsx +0 -70
- package/src/components/tour/PortalSwitcherStep.tsx +0 -36
- package/src/components/types.ts +0 -15
- package/src/layout-context.tsx +0 -22
- package/src/svg/AI.tsx +0 -37
- package/src/svg/EDP.tsx +0 -35
- package/src/svg/Forbidden.tsx +0 -22
- package/src/svg/HUB.tsx +0 -35
- package/src/svg/Logo.tsx +0 -35
- package/src/svg/NotFound.tsx +0 -16
- package/src/svg/ServerError.tsx +0 -33
- package/src/svg/Unauthenticated.tsx +0 -16
- /package/dist/components/{types.js → NotificationCenter/types.js} +0 -0
- /package/src/components/{BottomNotification.tsx → ContactModal.tsx} +0 -0
|
@@ -1,17 +1,38 @@
|
|
|
1
|
+
import { ErrorDescription } from '@stack-spot/portal-components/error';
|
|
1
2
|
import { Component } from 'react';
|
|
2
|
-
import { ErrorDescription } from './ErrorManager.js';
|
|
3
3
|
interface State extends ErrorDescription {
|
|
4
4
|
hasError: boolean;
|
|
5
5
|
}
|
|
6
6
|
interface Props {
|
|
7
7
|
children: React.ReactNode;
|
|
8
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* An Error Boundary that renders an ErrorFeedback instead of its content if any of its children throws.
|
|
11
|
+
*
|
|
12
|
+
* To customize what properties are passed to the ErrorFeedback component, setup an error descriptor for the ErrorManager class. If you're
|
|
13
|
+
* using the component `Layout` or `RawLayout`, you can use the property `errorDescriptor`.
|
|
14
|
+
*
|
|
15
|
+
* To run an error handler every time an error is catch by this boundary, setup an error handler for the ErrorManager class. If you're
|
|
16
|
+
* using the component `Layout` or `RawLayout`, you can use the property `onError`.
|
|
17
|
+
*/
|
|
9
18
|
export declare class ErrorBoundary extends Component<Props, State> {
|
|
10
19
|
constructor(props: Props);
|
|
11
20
|
static getDerivedStateFromError(error: any): {
|
|
12
|
-
code?: number
|
|
13
|
-
message?: string
|
|
14
|
-
debug?: boolean
|
|
21
|
+
code?: number;
|
|
22
|
+
message?: string;
|
|
23
|
+
debug?: boolean;
|
|
24
|
+
title?: string;
|
|
25
|
+
description?: string;
|
|
26
|
+
help?: string;
|
|
27
|
+
action?: {
|
|
28
|
+
label: string;
|
|
29
|
+
onClick: () => void;
|
|
30
|
+
};
|
|
31
|
+
body?: React.ReactNode;
|
|
32
|
+
image?: React.ReactElement;
|
|
33
|
+
direction?: "row" | "column";
|
|
34
|
+
style?: React.CSSProperties;
|
|
35
|
+
className?: string;
|
|
15
36
|
hasError: boolean;
|
|
16
37
|
};
|
|
17
38
|
componentDidCatch(error: any, errorInfo: any): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ErrorBoundary.d.ts","sourceRoot":"","sources":["../../../src/components/error/ErrorBoundary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"ErrorBoundary.d.ts","sourceRoot":"","sources":["../../../src/components/error/ErrorBoundary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAiB,MAAM,qCAAqC,CAAA;AACrF,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGjC,UAAU,KAAM,SAAQ,gBAAgB;IACtC,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,UAAU,KAAK;IACb,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;;;;GAQG;AACH,qBAAa,aAAc,SAAQ,SAAS,CAAC,KAAK,EAAE,KAAK,CAAC;gBAC5C,KAAK,EAAE,KAAK;IAKxB,MAAM,CAAC,wBAAwB,CAAC,KAAK,EAAE,GAAG;;;;;;;;;;;;;;;;;;IAI1C,iBAAiB,CAAC,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG;IAM5C,kBAAkB,CAAC,SAAS,EAAE,QAAQ,CAAC,KAAK,CAAC;IAI7C,MAAM;CAKP"}
|
|
@@ -1,7 +1,16 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { ErrorFeedback } from '@stack-spot/portal-components/error';
|
|
2
3
|
import { Component } from 'react';
|
|
3
|
-
import { ErrorFeedback } from './ErrorFeedback.js';
|
|
4
4
|
import { ErrorManager } from './ErrorManager.js';
|
|
5
|
+
/**
|
|
6
|
+
* An Error Boundary that renders an ErrorFeedback instead of its content if any of its children throws.
|
|
7
|
+
*
|
|
8
|
+
* To customize what properties are passed to the ErrorFeedback component, setup an error descriptor for the ErrorManager class. If you're
|
|
9
|
+
* using the component `Layout` or `RawLayout`, you can use the property `errorDescriptor`.
|
|
10
|
+
*
|
|
11
|
+
* To run an error handler every time an error is catch by this boundary, setup an error handler for the ErrorManager class. If you're
|
|
12
|
+
* using the component `Layout` or `RawLayout`, you can use the property `onError`.
|
|
13
|
+
*/
|
|
5
14
|
export class ErrorBoundary extends Component {
|
|
6
15
|
constructor(props) {
|
|
7
16
|
super(props);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ErrorBoundary.js","sourceRoot":"","sources":["../../../src/components/error/ErrorBoundary.tsx"],"names":[],"mappings":";AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"ErrorBoundary.js","sourceRoot":"","sources":["../../../src/components/error/ErrorBoundary.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAoB,aAAa,EAAE,MAAM,qCAAqC,CAAA;AACrF,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAU7C;;;;;;;;GAQG;AACH,MAAM,OAAO,aAAc,SAAQ,SAAuB;IACxD,YAAY,KAAY;QACtB,KAAK,CAAC,KAAK,CAAC,CAAA;QACZ,IAAI,CAAC,KAAK,GAAG,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAA;IAClC,CAAC;IAED,MAAM,CAAC,wBAAwB,CAAC,KAAU;QACxC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,YAAY,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAA;IAC5D,CAAC;IAED,iBAAiB,CAAC,KAAU,EAAE,SAAc;QAC1C,sCAAsC;QACtC,OAAO,CAAC,KAAK,CAAC,KAAK,EAAE,SAAS,CAAC,CAAA;QAC/B,YAAY,CAAC,eAAe,CAAC,KAAK,CAAC,CAAA;IACrC,CAAC;IAED,kBAAkB,CAAC,SAA0B;QAC3C,IAAI,IAAI,CAAC,KAAK,CAAC,QAAQ,KAAK,SAAS,CAAC,QAAQ;YAAE,IAAI,CAAC,QAAQ,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC,CAAA;IACpF,CAAC;IAED,MAAM;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ;YACxB,CAAC,CAAC,KAAC,aAAa,IAAC,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,GAAI;YAChG,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAA;IACzB,CAAC;CACF"}
|
|
@@ -1,16 +1,32 @@
|
|
|
1
|
-
|
|
2
|
-
code?: number;
|
|
3
|
-
message?: string;
|
|
4
|
-
debug?: boolean;
|
|
5
|
-
}
|
|
1
|
+
import { ErrorDescription } from '@stack-spot/portal-components/error';
|
|
6
2
|
export type DescriptionFn = (error: any) => ErrorDescription;
|
|
7
3
|
export type ErrorHandler = (error: any) => void;
|
|
4
|
+
/**
|
|
5
|
+
* Setup how the Error Boundaries deal with errors.
|
|
6
|
+
*/
|
|
8
7
|
export declare class ErrorManager {
|
|
9
8
|
private static descriptionFunction;
|
|
10
9
|
private static errorHandler;
|
|
10
|
+
/**
|
|
11
|
+
* Sets a custom logic for generating error messages and codes. Also setups the environment (debug or not).
|
|
12
|
+
* @param fn a function that, given an error, generates its description.
|
|
13
|
+
*/
|
|
11
14
|
static setDescriptionFunction(fn: DescriptionFn): void;
|
|
15
|
+
/**
|
|
16
|
+
* Sets a custom error handler, i.e. a function to run every time an error is catch by an ErrorBoundary.
|
|
17
|
+
* @param fn a function that receives the error.
|
|
18
|
+
*/
|
|
12
19
|
static setErrorHandler(handler: ErrorHandler): void;
|
|
20
|
+
/**
|
|
21
|
+
* Uses the error descriptor to describe an error.
|
|
22
|
+
* @param error the error
|
|
23
|
+
* @returns the error description
|
|
24
|
+
*/
|
|
13
25
|
static describe(error: any): ErrorDescription;
|
|
14
|
-
|
|
26
|
+
/**
|
|
27
|
+
* Runs the error handler, if any has been setup.
|
|
28
|
+
* @param error the error
|
|
29
|
+
*/
|
|
30
|
+
static runErrorHandler(error: any): void;
|
|
15
31
|
}
|
|
16
32
|
//# sourceMappingURL=ErrorManager.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ErrorManager.d.ts","sourceRoot":"","sources":["../../../src/components/error/ErrorManager.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"ErrorManager.d.ts","sourceRoot":"","sources":["../../../src/components/error/ErrorManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAA;AAEtE,MAAM,MAAM,aAAa,GAAG,CAAC,KAAK,EAAE,GAAG,KAAK,gBAAgB,CAAA;AAC5D,MAAM,MAAM,YAAY,GAAG,CAAC,KAAK,EAAE,GAAG,KAAK,IAAI,CAAA;AAE/C;;GAEG;AACH,qBAAa,YAAY;IACvB,OAAO,CAAC,MAAM,CAAC,mBAAmB,CAEhC;IACF,OAAO,CAAC,MAAM,CAAC,YAAY,CAA0B;IAErD;;;OAGG;IACH,MAAM,CAAC,sBAAsB,CAAC,EAAE,EAAE,aAAa;IAI/C;;;OAGG;IACH,MAAM,CAAC,eAAe,CAAC,OAAO,EAAE,YAAY;IAI5C;;;;OAIG;IACH,MAAM,CAAC,QAAQ,CAAC,KAAK,EAAE,GAAG;IAI1B;;;OAGG;IACH,MAAM,CAAC,eAAe,CAAC,KAAK,EAAE,GAAG;CAGlC"}
|
|
@@ -1,15 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Setup how the Error Boundaries deal with errors.
|
|
3
|
+
*/
|
|
1
4
|
export class ErrorManager {
|
|
5
|
+
/**
|
|
6
|
+
* Sets a custom logic for generating error messages and codes. Also setups the environment (debug or not).
|
|
7
|
+
* @param fn a function that, given an error, generates its description.
|
|
8
|
+
*/
|
|
2
9
|
static setDescriptionFunction(fn) {
|
|
3
10
|
this.descriptionFunction = fn;
|
|
4
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* Sets a custom error handler, i.e. a function to run every time an error is catch by an ErrorBoundary.
|
|
14
|
+
* @param fn a function that receives the error.
|
|
15
|
+
*/
|
|
5
16
|
static setErrorHandler(handler) {
|
|
6
17
|
this.errorHandler = handler;
|
|
7
18
|
}
|
|
19
|
+
/**
|
|
20
|
+
* Uses the error descriptor to describe an error.
|
|
21
|
+
* @param error the error
|
|
22
|
+
* @returns the error description
|
|
23
|
+
*/
|
|
8
24
|
static describe(error) {
|
|
9
25
|
return this.descriptionFunction(error);
|
|
10
26
|
}
|
|
27
|
+
/**
|
|
28
|
+
* Runs the error handler, if any has been setup.
|
|
29
|
+
* @param error the error
|
|
30
|
+
*/
|
|
11
31
|
static runErrorHandler(error) {
|
|
12
|
-
|
|
32
|
+
this.errorHandler?.(error);
|
|
13
33
|
}
|
|
14
34
|
}
|
|
15
35
|
Object.defineProperty(ErrorManager, "descriptionFunction", {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ErrorManager.js","sourceRoot":"","sources":["../../../src/components/error/ErrorManager.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ErrorManager.js","sourceRoot":"","sources":["../../../src/components/error/ErrorManager.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,MAAM,OAAO,YAAY;IAMvB;;;OAGG;IACH,MAAM,CAAC,sBAAsB,CAAC,EAAiB;QAC7C,IAAI,CAAC,mBAAmB,GAAG,EAAE,CAAA;IAC/B,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,eAAe,CAAC,OAAqB;QAC1C,IAAI,CAAC,YAAY,GAAG,OAAO,CAAA;IAC7B,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,QAAQ,CAAC,KAAU;QACxB,OAAO,IAAI,CAAC,mBAAmB,CAAC,KAAK,CAAC,CAAA;IACxC,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,eAAe,CAAC,KAAU;QAC/B,IAAI,CAAC,YAAY,EAAE,CAAC,KAAK,CAAC,CAAA;IAC5B,CAAC;;AApCc;;;;WAAqC,KAAK,CAAC,EAAE,CAAC,CAAC;QAC5D,OAAO,EAAE,KAAK,CAAC,OAAO,IAAI,GAAG,KAAK,EAAE;KACrC,CAAC;GAAA"}
|
|
@@ -1,18 +1,39 @@
|
|
|
1
|
+
import { ErrorDescription } from '@stack-spot/portal-components/error';
|
|
1
2
|
import { Component } from 'react';
|
|
2
|
-
import { ErrorDescription } from './ErrorManager.js';
|
|
3
3
|
interface State extends ErrorDescription {
|
|
4
4
|
hasError: boolean;
|
|
5
|
-
message?: string;
|
|
6
5
|
}
|
|
7
6
|
interface Props {
|
|
8
7
|
children: React.ReactNode;
|
|
9
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* An Error Boundary that doesn't render anything if any of its children throws. If the environment is not production, a small error icon
|
|
11
|
+
* is rendered instead of nothing.
|
|
12
|
+
*
|
|
13
|
+
* To customize how the error is logged, setup an error descriptor for the ErrorManager class. If you're using the component `Layout` or
|
|
14
|
+
* `RawLayout`, you can use the property `errorDescriptor`.
|
|
15
|
+
*
|
|
16
|
+
* To run an error handler every time an error is catch by this boundary, setup an error handler for the ErrorManager class. If you're
|
|
17
|
+
* using the component `Layout` or `RawLayout`, you can use the property `onError`.
|
|
18
|
+
*/
|
|
10
19
|
export declare class SilentErrorBoundary extends Component<Props, State> {
|
|
11
20
|
constructor(props: Props);
|
|
12
21
|
static getDerivedStateFromError(error: any): {
|
|
13
|
-
code?: number
|
|
14
|
-
message?: string
|
|
15
|
-
debug?: boolean
|
|
22
|
+
code?: number;
|
|
23
|
+
message?: string;
|
|
24
|
+
debug?: boolean;
|
|
25
|
+
title?: string;
|
|
26
|
+
description?: string;
|
|
27
|
+
help?: string;
|
|
28
|
+
action?: {
|
|
29
|
+
label: string;
|
|
30
|
+
onClick: () => void;
|
|
31
|
+
};
|
|
32
|
+
body?: React.ReactNode;
|
|
33
|
+
image?: React.ReactElement;
|
|
34
|
+
direction?: "row" | "column";
|
|
35
|
+
style?: React.CSSProperties;
|
|
36
|
+
className?: string;
|
|
16
37
|
hasError: boolean;
|
|
17
38
|
};
|
|
18
39
|
componentDidCatch(error: any, errorInfo: any): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SilentErrorBoundary.d.ts","sourceRoot":"","sources":["../../../src/components/error/SilentErrorBoundary.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"SilentErrorBoundary.d.ts","sourceRoot":"","sources":["../../../src/components/error/SilentErrorBoundary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAA;AAEtE,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGjC,UAAU,KAAM,SAAQ,gBAAgB;IACtC,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,UAAU,KAAK;IACb,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;;;;;GASG;AACH,qBAAa,mBAAoB,SAAQ,SAAS,CAAC,KAAK,EAAE,KAAK,CAAC;gBAClD,KAAK,EAAE,KAAK;IAKxB,MAAM,CAAC,wBAAwB,CAAC,KAAK,EAAE,GAAG;;;;;;;;;;;;;;;;;;IAI1C,iBAAiB,CAAC,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG;IAM5C,kBAAkB,CAAC,SAAS,EAAE,QAAQ,CAAC,KAAK,CAAC;IAI7C,MAAM;CAoBP"}
|
|
@@ -2,6 +2,16 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { theme } from '@stack-spot/portal-theme';
|
|
3
3
|
import { Component } from 'react';
|
|
4
4
|
import { ErrorManager } from './ErrorManager.js';
|
|
5
|
+
/**
|
|
6
|
+
* An Error Boundary that doesn't render anything if any of its children throws. If the environment is not production, a small error icon
|
|
7
|
+
* is rendered instead of nothing.
|
|
8
|
+
*
|
|
9
|
+
* To customize how the error is logged, setup an error descriptor for the ErrorManager class. If you're using the component `Layout` or
|
|
10
|
+
* `RawLayout`, you can use the property `errorDescriptor`.
|
|
11
|
+
*
|
|
12
|
+
* To run an error handler every time an error is catch by this boundary, setup an error handler for the ErrorManager class. If you're
|
|
13
|
+
* using the component `Layout` or `RawLayout`, you can use the property `onError`.
|
|
14
|
+
*/
|
|
5
15
|
export class SilentErrorBoundary extends Component {
|
|
6
16
|
constructor(props) {
|
|
7
17
|
super(props);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SilentErrorBoundary.js","sourceRoot":"","sources":["../../../src/components/error/SilentErrorBoundary.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"SilentErrorBoundary.js","sourceRoot":"","sources":["../../../src/components/error/SilentErrorBoundary.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAU7C;;;;;;;;;GASG;AACH,MAAM,OAAO,mBAAoB,SAAQ,SAAuB;IAC9D,YAAY,KAAY;QACtB,KAAK,CAAC,KAAK,CAAC,CAAA;QACZ,IAAI,CAAC,KAAK,GAAG,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAA;IAClC,CAAC;IAED,MAAM,CAAC,wBAAwB,CAAC,KAAU;QACxC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,YAAY,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAA;IAC5D,CAAC;IAED,iBAAiB,CAAC,KAAU,EAAE,SAAc;QAC1C,sCAAsC;QACtC,OAAO,CAAC,KAAK,CAAC,KAAK,EAAE,SAAS,CAAC,CAAA;QAC/B,YAAY,CAAC,eAAe,CAAC,KAAK,CAAC,CAAA;IACrC,CAAC;IAED,kBAAkB,CAAC,SAA0B;QAC3C,IAAI,IAAI,CAAC,KAAK,CAAC,QAAQ,KAAK,SAAS,CAAC,QAAQ;YAAE,IAAI,CAAC,QAAQ,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC,CAAA;IACpF,CAAC;IAED,MAAM;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ;YACxB,CAAC,CAAC,cACA,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,UAAU,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,SAAS,EACtE,KAAK,EAAE;oBACL,KAAK,EAAE,MAAM;oBACb,MAAM,EAAE,MAAM;oBACd,MAAM,EAAE,MAAM;oBACd,UAAU,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC;oBACnC,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,YAAY;oBACtC,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM;oBAC3C,cAAc,EAAE,QAAQ;oBACxB,UAAU,EAAE,QAAQ;oBACpB,UAAU,EAAE,MAAM;oBAClB,QAAQ,EAAE,MAAM;oBAChB,YAAY,EAAE,KAAK;iBACpB,kBACK;YACR,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAA;IACzB,CAAC;CACF"}
|
|
@@ -1,7 +1,23 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { MenuAction, MenuSectionContent } from './types.js';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
/**
|
|
3
|
+
* The list (`<ul>`) used for grouping items in a menu.
|
|
4
|
+
*/
|
|
5
|
+
export declare const MenuGroup: React.FC<React.HTMLAttributes<HTMLUListElement>>;
|
|
6
|
+
/**
|
|
7
|
+
* The header (<header>) for a group of items in a menu. Contains the title of the group.
|
|
8
|
+
*/
|
|
9
|
+
export declare const Title: React.FC<React.HTMLAttributes<HTMLElement>>;
|
|
10
|
+
/**
|
|
11
|
+
* A menu item that performs an action.
|
|
12
|
+
* @param props the props for the component {@link MenuAction}.
|
|
13
|
+
*/
|
|
14
|
+
export declare const ActionItem: ({ label, onClick, href, active, icon, badge, target, overflow }: MenuAction) => import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
/**
|
|
16
|
+
* Renders a menu-content interface.
|
|
17
|
+
*
|
|
18
|
+
* Considering the Stackspot UI, this is the "menu content", not the "menu sections", i.e. it's the second menu from left to right, the
|
|
19
|
+
* one that changes according to section selected.
|
|
20
|
+
* @param props the props for the component {@link MenuSectionContent}.
|
|
21
|
+
*/
|
|
6
22
|
export declare const MenuContent: ({ pageSelector, goBack, title, subtitle, afterTitle, options, loading, error }: MenuSectionContent) => import("react/jsx-runtime").JSX.Element;
|
|
7
23
|
//# sourceMappingURL=MenuContent.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuContent.d.ts","sourceRoot":"","sources":["../../../src/components/menu/MenuContent.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MenuContent.d.ts","sourceRoot":"","sources":["../../../src/components/menu/MenuContent.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAa,UAAU,EAAY,kBAAkB,EAAE,MAAM,SAAS,CAAA;AAE7E;;GAEG;AAEH,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,cAAc,CAAC,gBAAgB,CAAC,CA8HtE,CAAA;AAED;;GAEG;AAEH,eAAO,MAAM,KAAK,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,cAAc,CAAC,WAAW,CAAC,CAI7D,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,UAAU,GAAI,iEAA0E,UAAU,4CAwB9G,CAAA;AAyDD;;;;;;GAMG;AACH,eAAO,MAAM,WAAW,GAAI,gFAAqF,kBAAkB,4CAwClI,CAAA"}
|
|
@@ -1,25 +1,19 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
4
|
-
import { Flex, IconBox, Text } from '@citric/core';
|
|
2
|
+
import { Box, Flex, IconBox, Text } from '@citric/core';
|
|
5
3
|
import { ArrowLeft, ChevronDown } from '@citric/icons';
|
|
6
4
|
import { LoadingCircular } from '@citric/ui';
|
|
5
|
+
import { useCheckTextOverflow } from '@stack-spot/portal-components';
|
|
6
|
+
import { useAnchorTag } from '@stack-spot/portal-components/anchor';
|
|
7
7
|
import { listToClass, theme } from '@stack-spot/portal-theme';
|
|
8
8
|
import { useMemo, useState } from 'react';
|
|
9
9
|
import { styled } from 'styled-components';
|
|
10
|
-
import { useAnchorTag } from '../../layout-context.js';
|
|
11
10
|
import { hideOverlayImmediately } from './MenuSections.js';
|
|
12
11
|
import { PageSelector } from './PageSelector.js';
|
|
13
12
|
import { MENU_CONTENT_ITEM_PADDING as ITEM_PADDING, MENU_CONTENT_PADDING as PADDING } from './constants.js';
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
align-items: center;
|
|
19
|
-
margin: ${PADDING}px;
|
|
20
|
-
margin-bottom: 16px;
|
|
21
|
-
gap: 6px;
|
|
22
|
-
`;
|
|
13
|
+
/**
|
|
14
|
+
* The list (`<ul>`) used for grouping items in a menu.
|
|
15
|
+
*/
|
|
16
|
+
// fixme: remove explicit type when TS is upgraded to 5.5 or greater
|
|
23
17
|
export const MenuGroup = styled.ul `
|
|
24
18
|
padding: 0 0 0 16px;
|
|
25
19
|
display: flex;
|
|
@@ -31,30 +25,18 @@ export const MenuGroup = styled.ul `
|
|
|
31
25
|
padding: 0;
|
|
32
26
|
}
|
|
33
27
|
|
|
34
|
-
.item-row-group > a {
|
|
35
|
-
padding: 0 16px;
|
|
36
|
-
margin: 0;
|
|
37
|
-
border-radius: 0;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
.item-row-group > a::before {
|
|
41
|
-
content: '';
|
|
42
|
-
position: absolute;
|
|
43
|
-
top: 0;
|
|
44
|
-
left: 0;
|
|
45
|
-
right: 0;
|
|
46
|
-
bottom: 0;
|
|
47
|
-
background-color: var(--light-300);
|
|
48
|
-
opacity: 0.24;
|
|
49
|
-
border-radius: inherit;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
28
|
.item-row {
|
|
53
29
|
display: flex;
|
|
54
30
|
flex-direction: row;
|
|
55
31
|
gap: 8px;
|
|
56
32
|
align-items: center;
|
|
57
33
|
|
|
34
|
+
&.root {
|
|
35
|
+
padding: 0 16px;
|
|
36
|
+
margin-top: 16px;
|
|
37
|
+
border-radius: 0;
|
|
38
|
+
}
|
|
39
|
+
|
|
58
40
|
.label {
|
|
59
41
|
flex: 1;
|
|
60
42
|
&.hidden, &.ellipsis {
|
|
@@ -66,73 +48,77 @@ export const MenuGroup = styled.ul `
|
|
|
66
48
|
}
|
|
67
49
|
}
|
|
68
50
|
}
|
|
69
|
-
|
|
70
|
-
.item-row-group {
|
|
71
|
-
margin-top: 16px;
|
|
72
|
-
}
|
|
73
51
|
|
|
74
|
-
li
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
transition: height 0.3s, background-color 0.2s;
|
|
79
|
-
margin-left: ${PADDING - ITEM_PADDING}px;
|
|
80
|
-
padding-left: ${ITEM_PADDING}px;
|
|
52
|
+
li {
|
|
53
|
+
.item-row-title {
|
|
54
|
+
opacity: 0.7;
|
|
55
|
+
}
|
|
81
56
|
|
|
82
|
-
|
|
83
|
-
|
|
57
|
+
.item-as-title {
|
|
58
|
+
position: relative;
|
|
59
|
+
overflow: hidden;
|
|
60
|
+
margin-left: ${PADDING - ITEM_PADDING}px;
|
|
84
61
|
}
|
|
85
62
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
63
|
+
a {
|
|
64
|
+
position: relative;
|
|
65
|
+
height: 0;
|
|
66
|
+
overflow: hidden;
|
|
67
|
+
transition: height 0.3s, background-color 0.2s;
|
|
68
|
+
margin-left: ${PADDING - ITEM_PADDING}px;
|
|
69
|
+
padding-left: ${ITEM_PADDING}px;
|
|
70
|
+
|
|
71
|
+
&:hover {
|
|
72
|
+
background-color: ${theme.color.light['500']};
|
|
95
73
|
}
|
|
74
|
+
|
|
75
|
+
&.action {
|
|
76
|
+
&:before {
|
|
77
|
+
content: '';
|
|
78
|
+
position: absolute;
|
|
79
|
+
left: 2px;
|
|
80
|
+
width: 2px;
|
|
81
|
+
height: 0;
|
|
82
|
+
background: inherit;
|
|
83
|
+
transition: height 0.2s;
|
|
84
|
+
}
|
|
96
85
|
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
86
|
+
&.active {
|
|
87
|
+
|
|
88
|
+
&:hover {
|
|
89
|
+
background-color: transparent;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
&:before {
|
|
93
|
+
background: ${theme.color.primary['500']};
|
|
94
|
+
height: 24px;
|
|
95
|
+
}
|
|
101
96
|
}
|
|
102
|
-
|
|
103
|
-
&:before {
|
|
104
|
-
background: ${theme.color.
|
|
97
|
+
|
|
98
|
+
&:not(.active):hover:before {
|
|
99
|
+
background: ${theme.color.light.contrastText};
|
|
105
100
|
height: 24px;
|
|
106
101
|
}
|
|
107
102
|
}
|
|
108
103
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
.chevron {
|
|
116
|
-
transition: transform 0.3s;
|
|
117
|
-
&:not(.open) {
|
|
118
|
-
transform: rotate(-90deg);
|
|
104
|
+
.chevron {
|
|
105
|
+
transition: transform 0.3s;
|
|
106
|
+
&:not(.open) {
|
|
107
|
+
transform: rotate(-90deg);
|
|
108
|
+
}
|
|
119
109
|
}
|
|
120
110
|
}
|
|
121
|
-
|
|
122
|
-
.item-row-title {
|
|
123
|
-
opacity: 0.7;
|
|
124
|
-
}
|
|
125
111
|
}
|
|
126
112
|
|
|
127
113
|
&.open {
|
|
128
114
|
visibility: visible;
|
|
129
115
|
transition: unset;
|
|
130
|
-
& > li > a, & > li > .item-
|
|
116
|
+
& > li > a, & > li > .item-as-title {
|
|
131
117
|
height: 40px;
|
|
132
118
|
}
|
|
133
119
|
}
|
|
134
120
|
|
|
135
|
-
&:not(.open) &.open > li > a {
|
|
121
|
+
&:not(.open) &.open > li > a, &:not(.open) &.open > li > .item-as-title {
|
|
136
122
|
height: 0;
|
|
137
123
|
}
|
|
138
124
|
|
|
@@ -155,12 +141,20 @@ export const MenuGroup = styled.ul `
|
|
|
155
141
|
}
|
|
156
142
|
}
|
|
157
143
|
`;
|
|
144
|
+
/**
|
|
145
|
+
* The header (<header>) for a group of items in a menu. Contains the title of the group.
|
|
146
|
+
*/
|
|
147
|
+
// fixme: remove explicit type when TS is upgraded to 5.5 or greater
|
|
158
148
|
export const Title = styled.header `
|
|
159
149
|
display: flex;
|
|
160
150
|
flex-direction: column;
|
|
161
151
|
margin: ${PADDING}px 0 24px ${PADDING}px;
|
|
162
152
|
`;
|
|
163
|
-
|
|
153
|
+
/**
|
|
154
|
+
* A menu item that performs an action.
|
|
155
|
+
* @param props the props for the component {@link MenuAction}.
|
|
156
|
+
*/
|
|
157
|
+
export const ActionItem = ({ label, onClick, href, active, icon, badge, target, overflow = 'wrap' }) => {
|
|
164
158
|
const Link = useAnchorTag();
|
|
165
159
|
const { ref, overflow: textOverflow } = useCheckTextOverflow();
|
|
166
160
|
const isTextLabel = typeof label === 'string';
|
|
@@ -170,28 +164,35 @@ export const ActionItem = ({ label, onClick, href, active, icon, badge, overflow
|
|
|
170
164
|
if (onClick)
|
|
171
165
|
onClick();
|
|
172
166
|
hideOverlayImmediately();
|
|
173
|
-
}, className: listToClass(['action', 'item-row', active ? 'active' : undefined]), ...(active ? { 'aria-current': 'page' } : undefined), ...(!href ? { 'tabIndex': 0 } : undefined), children: [icon, isTextLabel ?
|
|
167
|
+
}, target: target, className: listToClass(['action', 'item-row', active ? 'active' : undefined]), ...(active ? { 'aria-current': 'page' } : undefined), ...(!href ? { 'tabIndex': 0 } : undefined), children: [icon, isTextLabel ?
|
|
174
168
|
_jsx(Text, { ref: ref, appearance: "body2", className: `label ${overflow}`, title: textOverflow ? label : '', children: label }) :
|
|
175
169
|
label.element, badge] }));
|
|
176
170
|
};
|
|
177
|
-
|
|
171
|
+
/**
|
|
172
|
+
* A menu item that is actually a subgroup and can be collapsed/expanded.
|
|
173
|
+
* @param props the props for the component {@link ItemGroup} & { root: boolean }. Pass root=true to style this group as a root group.
|
|
174
|
+
* Root groups have slightly different visuals.
|
|
175
|
+
*/
|
|
176
|
+
const CollapsibleGroupItem = ({ label, showAsTitle, open: initiallyOpened, children, icon, badge, root, overflow = 'wrap' }) => {
|
|
178
177
|
const [open, setOpen] = useState(initiallyOpened ?? children?.some(c => 'active' in c && c.active) ?? false);
|
|
179
178
|
const items = useMemo(() => children?.filter(i => !i.hidden).map(renderOption), [children]);
|
|
180
179
|
const id = `menuGroup${label}`;
|
|
181
|
-
return (_jsxs(_Fragment, { children: [_jsxs("a", { onClick: () => setOpen(!open), onKeyDown: e => e.key === 'Enter' && setOpen(!open), className:
|
|
182
|
-
};
|
|
183
|
-
const RootGroupItem = (props) => {
|
|
184
|
-
const items = useMemo(() => props.children?.filter(i => !i.hidden).map(renderOption), [props.children]);
|
|
185
|
-
return _jsx(_Fragment, { children: items.length ? _jsx("div", { className: "item-row-group", children: _jsx(CollapsibleGroupItem, { ...props, open: true, root: true }) }) :
|
|
186
|
-
_jsxs(_Fragment, { children: [_jsxs("div", { className: "item-row", children: [props.icon, _jsx(Text, { appearance: "overheader2", colorScheme: "light.700", className: `group-title label ${props.overflow}`, children: props.label }), props.badge] }), _jsx(MenuGroup, { className: "open no-indentation", children: items })] }) });
|
|
180
|
+
return (_jsxs(_Fragment, { children: [showAsTitle ? _jsxs(Box, { className: listToClass(['item-row', root && 'root', 'item-as-title']), children: [icon, _jsx(Text, { appearance: root ? 'overheader2' : 'body2', colorScheme: "light.contrastText", className: `label ${overflow} ${root ? 'item-row-title' : ''}`, children: label })] }) : _jsxs("a", { onClick: () => setOpen(!open), onKeyDown: e => e.key === 'Enter' && setOpen(!open), className: listToClass(['item-row', root && 'root']), tabIndex: 0, "aria-controls": id, "aria-expanded": open, children: [icon, _jsx(Text, { appearance: root ? 'overheader2' : 'body2', colorScheme: "light.contrastText", className: `label ${overflow} ${root ? 'item-row-title' : ''}`, children: label }), badge, _jsx(IconBox, { sx: { mr: root ? undefined : '5' }, children: _jsx(ChevronDown, { className: listToClass(['chevron', open ? 'open' : '']) }) })] }), _jsx(MenuGroup, { id: id, className: `${open ? 'open' : ''} ${root ? 'no-indentation' : ''}`, "aria-hidden": !open, children: items })] }));
|
|
187
181
|
};
|
|
188
|
-
const GroupItem = ({ root, ...item }) => (root ? _jsx(RootGroupItem, { ...item }) : _jsx(CollapsibleGroupItem, { ...item }));
|
|
189
182
|
function renderOption({ root, ...option }) {
|
|
190
183
|
const labelText = typeof option.label === 'string' ? option.label : option.label.id;
|
|
191
|
-
return (_jsx("li", { role: "menuitem", "aria-selected": 'children' in option ? undefined : option.active, children: 'children' in option ? _jsx(
|
|
184
|
+
return (_jsx("li", { role: "menuitem", "aria-selected": 'children' in option ? undefined : option.active, children: 'children' in option ? _jsx(CollapsibleGroupItem, { ...option, root: root, open: option.open ?? root }) : _jsx(ActionItem, { ...option }) }, labelText));
|
|
192
185
|
}
|
|
186
|
+
/**
|
|
187
|
+
* Renders a menu-content interface.
|
|
188
|
+
*
|
|
189
|
+
* Considering the Stackspot UI, this is the "menu content", not the "menu sections", i.e. it's the second menu from left to right, the
|
|
190
|
+
* one that changes according to section selected.
|
|
191
|
+
* @param props the props for the component {@link MenuSectionContent}.
|
|
192
|
+
*/
|
|
193
193
|
export const MenuContent = ({ pageSelector, goBack, title, subtitle, afterTitle, options = [], loading, error }) => {
|
|
194
194
|
const items = useMemo(() => options.filter(o => !o.hidden).map(o => renderOption({ ...o, root: true })), [options]);
|
|
195
|
+
const Link = useAnchorTag();
|
|
195
196
|
function renderContent() {
|
|
196
197
|
if (loading) {
|
|
197
198
|
return (_jsx(Flex, { justifyContent: "center", alignItems: "center", flex: 1, sx: { padding: '40px' }, children: _jsx(LoadingCircular, {}) }));
|
|
@@ -200,7 +201,7 @@ export const MenuContent = ({ pageSelector, goBack, title, subtitle, afterTitle,
|
|
|
200
201
|
return _jsx(Text, { colorScheme: "danger", children: error });
|
|
201
202
|
return _jsx(MenuGroup, { className: "open root no-indentation", children: items });
|
|
202
203
|
}
|
|
203
|
-
return (_jsxs(_Fragment, { children: [goBack && (_jsxs(
|
|
204
|
+
return (_jsxs(_Fragment, { children: [goBack && (_jsxs(Link, { href: goBack.href, onClick: goBack.onClick, className: "goBackLink", children: [_jsx(IconBox, { colorIcon: "inverse.500", size: "sm", children: _jsx(ArrowLeft, {}) }), typeof goBack?.label === 'string' ?
|
|
204
205
|
_jsx(Text, { appearance: "body2", nowrapEllipsis: true, children: goBack.label }) :
|
|
205
206
|
goBack.label.element] })), title && (_jsxs(Title, { children: [_jsx(Text, { appearance: "overheader1", colorScheme: "primary", sx: { fontSize: '0.75rem', mt: 2, mb: 2 }, children: title }), subtitle && _jsx(Text, { appearance: "h5", children: subtitle })] })), afterTitle, pageSelector && _jsx(PageSelector, { ...pageSelector }), renderContent()] }));
|
|
206
207
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuContent.js","sourceRoot":"","sources":["../../../src/components/menu/MenuContent.tsx"],"names":[],"mappings":";AAAA,
|
|
1
|
+
{"version":3,"file":"MenuContent.js","sourceRoot":"","sources":["../../../src/components/menu/MenuContent.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI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