@layers-app/shared 0.4.6 → 0.4.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/AnimatedFigurePage/AnimatedFigurePage.module.css.js +13 -13
- package/dist/components/AppContainer/AppContainer.d.ts.map +1 -1
- package/dist/components/AppContainer/AppContainer.js +79 -72
- package/dist/components/AppContainer/AppContainer.module.css.js +20 -10
- package/dist/components/AppContainer/components/AppsSidebar/DesktopUpdateButton.d.ts +6 -0
- package/dist/components/AppContainer/components/AppsSidebar/DesktopUpdateButton.d.ts.map +1 -0
- package/dist/components/AppContainer/components/AppsSidebar/DesktopUpdateButton.js +161 -0
- package/dist/components/AppContainer/components/AppsSidebar/UserSection.d.ts.map +1 -1
- package/dist/components/AppContainer/components/AppsSidebar/UserSection.js +238 -105
- package/dist/components/AppContainer/components/Main.js +4 -4
- package/dist/components/AppContainer/components/SlideAnimation.js +4 -4
- package/dist/components/AppContainer/components/ToolSidebar.js +9 -9
- package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.d.ts +62 -1
- package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.d.ts.map +1 -1
- package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.js +1107 -137
- package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.module.css.js +158 -6
- package/dist/components/AppShell/AppShell.module.css.js +5 -5
- package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.d.ts +2 -0
- package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.d.ts.map +1 -1
- package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.js +22 -17
- package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.d.ts +15 -0
- package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.d.ts.map +1 -0
- package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.js +36 -0
- package/dist/components/AttachmentsGalleryModal/components/GallerySlide.js +22 -22
- package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.d.ts +14 -0
- package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.d.ts.map +1 -0
- package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.js +31 -0
- package/dist/components/AttachmentsGalleryModal/components/ModalHeader.d.ts.map +1 -1
- package/dist/components/AttachmentsGalleryModal/components/ModalHeader.js +172 -120
- package/dist/components/AttachmentsGalleryModal/components/ShakePlayer/ShakaPlayer.module.css.js +4 -4
- package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.d.ts +18 -0
- package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.d.ts.map +1 -0
- package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.js +35 -0
- package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.d.ts +33 -0
- package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.d.ts.map +1 -0
- package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.js +70 -0
- package/dist/components/AttachmentsGalleryModal/styles.module.css.js +32 -28
- package/dist/components/AttachmentsPreview/AttachmentsPreview.module.css.js +12 -12
- package/dist/components/BouncingLogo/BouncingLogo.module.css.js +4 -4
- package/dist/components/Chat/CallMessage/CallMessage.module.css.js +8 -8
- package/dist/components/Chat/ChatBubble/ChatBubble.module.css.js +1 -1
- package/dist/components/Chat/ChatHeader/ChatHeader.module.css.js +1 -1
- package/dist/components/Chat/ChatInput/ChatInput.module.css.js +44 -44
- package/dist/components/Chat/ChatLayout/ChatLayout.module.css.js +4 -4
- package/dist/components/Chat/ChatMessage/ChatMessage.module.css.js +10 -10
- package/dist/components/Chat/ChatPill/ChatPill.module.css.js +1 -1
- package/dist/components/Chat/DialogItem/DialogItem.module.css.js +4 -4
- package/dist/components/Chat/DialogList/DialogList.module.css.js +1 -1
- package/dist/components/Chat/MediaDocument/MediaDocument.module.css.js +4 -4
- package/dist/components/Chat/MessageActions/MessageActions.module.css.js +1 -1
- package/dist/components/Chat/MessageActions/index.d.ts.map +1 -1
- package/dist/components/Chat/MessageActions/index.js +38 -37
- package/dist/components/Chat/MessageForward/MessageForward.module.css.js +1 -1
- package/dist/components/Chat/MessageList/MessageList.module.css.js +5 -5
- package/dist/components/Chat/MessageMeta/MessageMeta.module.css.js +3 -3
- package/dist/components/Chat/MessageMeta/index.d.ts.map +1 -1
- package/dist/components/Chat/MessageMeta/index.js +21 -19
- package/dist/components/Chat/MessageReactions/MessageReactions.module.css.js +12 -12
- package/dist/components/Chat/MessageReply/MessageReply.module.css.js +7 -7
- package/dist/components/Chat/MessageStatus/MessageStatus.module.css.js +8 -8
- package/dist/components/Chat/ServiceMessage/ServiceMessage.module.css.js +1 -1
- package/dist/components/CollapsibleContainer/CollapsibleContainer.module.css.js +1 -1
- package/dist/components/ColorPicker/ColorPicker.d.ts +3 -0
- package/dist/components/ColorPicker/ColorPicker.d.ts.map +1 -1
- package/dist/components/ColorPicker/ColorPicker.js +81 -76
- package/dist/components/ColorPicker/ColorPicker.module.css.js +26 -32
- package/dist/components/ColorPicker/ColorPickerList.d.ts.map +1 -1
- package/dist/components/ColorPicker/ColorPickerList.js +72 -83
- package/dist/components/ColorPicker/ColorPickerToolbar.d.ts.map +1 -1
- package/dist/components/ColorPicker/ColorPickerToolbar.js +64 -67
- package/dist/components/ColorPicker/icons.js +5 -5
- package/dist/components/ColorPicker/types.d.ts +0 -6
- package/dist/components/ColorPicker/types.d.ts.map +1 -1
- package/dist/components/ColorPicker/types.js +11 -53
- package/dist/components/ColorPicker/useRecentColors.d.ts +1 -3
- package/dist/components/ColorPicker/useRecentColors.d.ts.map +1 -1
- package/dist/components/ColorPicker/useRecentColors.js +20 -43
- package/dist/components/CommentComposer/CommentComposer.module.css.js +4 -4
- package/dist/components/CommunitiesDialog/styles.module.css.js +1 -1
- package/dist/components/Copyright/Copyright.module.css.js +1 -1
- package/dist/components/CustomKBD/CustomKBD.module.css.js +1 -1
- package/dist/components/EmojiPicker/EmojiPicker.module.css.js +8 -8
- package/dist/components/EntityTitle/EntityTitle.module.css.js +1 -1
- package/dist/components/ErrorPage/components/Error404.d.ts.map +1 -1
- package/dist/components/FeatureProgress/FeatureProgress.module.css.js +49 -49
- package/dist/components/FilePicker/FilePicker.module.css.js +7 -7
- package/dist/components/FormViewer/FormViewer.module.css.js +20 -20
- package/dist/components/FormViewer/components/fields/DragOptions/DragOptions.module.css.js +1 -1
- package/dist/components/FormViewer/components/fields/DropdownField/DropdownField.module.css.js +1 -1
- package/dist/components/FormViewer/components/fields/EditableContent/EditableContent.module.css.js +1 -1
- package/dist/components/FormViewer/components/fields/SelectableCard/SelectableCard.module.css.js +8 -8
- package/dist/components/FormViewer/components/fields/UploadField/UploadFile/UploadFile.module.css.js +4 -4
- package/dist/components/FormViewer/store/formStore.d.ts.map +1 -1
- package/dist/components/ImageCropper/ImageCropper.module.css.js +38 -38
- package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.d.ts +3 -1
- package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.d.ts.map +1 -1
- package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.js +26 -25
- package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.module.css.js +11 -11
- package/dist/components/LanguagePicker/LanguagePicker.module.css.js +1 -1
- package/dist/components/Loaders/styles.module.css.js +6 -6
- package/dist/components/MediaLibrary/MediaLibrary.module.css.js +2 -2
- package/dist/components/MusicPlayerBar/MusicPlayerBar.module.css.js +23 -23
- package/dist/components/NavMenu/NavMenu.module.css.js +12 -12
- package/dist/components/NavbarResizer/NavbarResizer.module.css.js +2 -2
- package/dist/components/NewToolbar/utils.d.ts +12 -0
- package/dist/components/NewToolbar/utils.d.ts.map +1 -0
- package/dist/components/NotPublicPanel/NotPublicPanel.module.css.js +11 -11
- package/dist/components/Notification/Notification.module.css.js +1 -1
- package/dist/components/OnboardingTour/index.d.ts +1 -1
- package/dist/components/OnboardingTour/index.d.ts.map +1 -1
- package/dist/components/OnboardingTour/useOnboardingTour.d.ts +2 -0
- package/dist/components/OnboardingTour/useOnboardingTour.d.ts.map +1 -1
- package/dist/components/OnboardingTour/useOnboardingTour.js +63 -51
- package/dist/components/PillTabs/PillTabs.module.css.js +1 -1
- package/dist/components/SearchFilters/SearchFilters.module.css.js +1 -1
- package/dist/components/SettingsSection/styles.module.css.js +1 -1
- package/dist/components/StorageUsageProgress/StorageUsageProgress.module.css.js +1 -1
- package/dist/components/TreeIndent/TreeIndent.module.css.js +4 -4
- package/dist/components/VideoPlayer/VideoPlayer.d.ts +24 -0
- package/dist/components/VideoPlayer/VideoPlayer.d.ts.map +1 -0
- package/dist/components/VideoPlayer/VideoPlayer.js +727 -0
- package/dist/components/VideoPlayer/components/MobileDrawer/index.d.ts +8 -0
- package/dist/components/VideoPlayer/components/MobileDrawer/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/MobileDrawer/index.js +67 -0
- package/dist/components/VideoPlayer/components/SelectListOptionButton.d.ts +7 -0
- package/dist/components/VideoPlayer/components/SelectListOptionButton.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/SelectListOptionButton.js +44 -0
- package/dist/components/VideoPlayer/components/StoryboardPreview.d.ts +9 -0
- package/dist/components/VideoPlayer/components/StoryboardPreview.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/StoryboardPreview.js +38 -0
- package/dist/components/VideoPlayer/components/VideoCustomControls.d.ts +33 -0
- package/dist/components/VideoPlayer/components/VideoCustomControls.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoCustomControls.js +601 -0
- package/dist/components/VideoPlayer/components/VideoIcons.d.ts +25 -0
- package/dist/components/VideoPlayer/components/VideoIcons.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoIcons.js +145 -0
- package/dist/components/VideoPlayer/components/VideoMenu.d.ts +27 -0
- package/dist/components/VideoPlayer/components/VideoMenu.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoMenu.js +77 -0
- package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.d.ts +17 -0
- package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.js +289 -0
- package/dist/components/VideoPlayer/components/VideoQualityMenu/index.d.ts +10 -0
- package/dist/components/VideoPlayer/components/VideoQualityMenu/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoQualityMenu/index.js +55 -0
- package/dist/components/VideoPlayer/components/VideoSelect.d.ts +10 -0
- package/dist/components/VideoPlayer/components/VideoSelect.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSelect.js +168 -0
- package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.d.ts +12 -0
- package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.js +48 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.d.ts +25 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.js +384 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.d.ts +21 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.js +264 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.d.ts +10 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.js +39 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.d.ts +14 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.js +360 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitleTrackRow.d.ts +16 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitleTrackRow.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitlesSection.d.ts +14 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitlesSection.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/context.d.ts +4 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/context.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/context.js +14 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/index.d.ts +22 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSettingsModal/index.js +211 -0
- package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.d.ts +11 -0
- package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.js +41 -0
- package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.d.ts +10 -0
- package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.js +69 -0
- package/dist/components/VideoPlayer/hooks/useStoryboard.d.ts +21 -0
- package/dist/components/VideoPlayer/hooks/useStoryboard.d.ts.map +1 -0
- package/dist/components/VideoPlayer/hooks/useStoryboard.js +91 -0
- package/dist/components/VideoPlayer/index.d.ts +11 -0
- package/dist/components/VideoPlayer/index.d.ts.map +1 -0
- package/dist/components/VideoPlayer/types.d.ts +101 -0
- package/dist/components/VideoPlayer/types.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/chapters.d.ts +8 -0
- package/dist/components/VideoPlayer/utils/chapters.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/chapters.js +38 -0
- package/dist/components/VideoPlayer/utils/storyboard.d.ts +5 -0
- package/dist/components/VideoPlayer/utils/storyboard.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/storyboard.js +47 -0
- package/dist/components/VideoPlayer/utils/subtitles.d.ts +18 -0
- package/dist/components/VideoPlayer/utils/subtitles.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/subtitles.js +23 -0
- package/dist/components/VideoPlayer/utils/touch.d.ts +3 -0
- package/dist/components/VideoPlayer/utils/touch.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/touch.js +5 -0
- package/dist/components/VideoPlayer/utils/videoPlayerUtils.d.ts +10 -0
- package/dist/components/VideoPlayer/utils/videoPlayerUtils.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/videoPlayerUtils.js +22 -0
- package/dist/components/VideoPlayer/utils/videoSettings.d.ts +69 -0
- package/dist/components/VideoPlayer/utils/videoSettings.d.ts.map +1 -0
- package/dist/components/VideoPlayer/utils/videoSettings.js +90 -0
- package/dist/components/table/FrontTable.d.ts.map +1 -1
- package/dist/components/table/hooks/useColumnsResizing.d.ts.map +1 -1
- package/dist/config/brand.d.ts.map +1 -1
- package/dist/config/brand.js +29 -29
- package/dist/config/envConfig.d.ts +2 -0
- package/dist/config/envConfig.d.ts.map +1 -1
- package/dist/helpers/showFeatureFeedback.module.css.js +4 -4
- package/dist/helpers/showNotifications.d.ts +8 -14
- package/dist/helpers/showNotifications.d.ts.map +1 -1
- package/dist/helpers/showNotifications.js +107 -111
- package/dist/helpers/showNotifications.module.css.js +4 -16
- package/dist/hooks/useDateUtils.d.ts.map +1 -1
- package/dist/hooks/useDateUtils.js +19 -23
- package/dist/index.css +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +589 -575
- package/dist/lang/locales/ui_en.json.js +1 -1
- package/dist/lang/locales/ui_es.json.js +1 -1
- package/dist/lang/locales/ui_ru.json.js +1 -1
- package/dist/videoSettings/createVideoSettingsDataSource.d.ts +19 -0
- package/dist/videoSettings/createVideoSettingsDataSource.d.ts.map +1 -0
- package/dist/videoSettings/createVideoSettingsDataSource.js +127 -0
- package/docs/README.md +499 -499
- package/package.json +79 -78
|
@@ -6,6 +6,13 @@ export interface NotificationAction {
|
|
|
6
6
|
onClick: () => void;
|
|
7
7
|
variant?: 'filled' | 'default';
|
|
8
8
|
}
|
|
9
|
+
export interface ChatToastData {
|
|
10
|
+
id?: string;
|
|
11
|
+
title: ReactNode;
|
|
12
|
+
body: ReactNode;
|
|
13
|
+
icon?: ReactNode;
|
|
14
|
+
onClick?: () => void;
|
|
15
|
+
}
|
|
9
16
|
export type ExtendedNotificationData = Omit<NotificationData, 'message'> & {
|
|
10
17
|
message?: ReactNode;
|
|
11
18
|
actions?: NotificationAction[];
|
|
@@ -17,20 +24,7 @@ export declare const showRequestNotifications: <Response, Request extends Promis
|
|
|
17
24
|
errorMsg?: ((err: any) => MessageType) | MessageType;
|
|
18
25
|
}) => Promise<any>;
|
|
19
26
|
export declare const showMessageNotification: (props: ExtendedNotificationData) => void;
|
|
20
|
-
export
|
|
21
|
-
id: string;
|
|
22
|
-
title: ReactNode;
|
|
23
|
-
body: ReactNode;
|
|
24
|
-
icon?: ReactNode;
|
|
25
|
-
onClick: () => void;
|
|
26
|
-
}
|
|
27
|
-
/**
|
|
28
|
-
* Chat/mention toast: a single clickable card (icon + 1-line title + 2-line
|
|
29
|
-
* clamped body). Clicking anywhere opens the conversation; the X dismisses.
|
|
30
|
-
* No action button — one tap, like a native notification. Re-showing the same
|
|
31
|
-
* id swaps the content in place rather than spamming a new card.
|
|
32
|
-
*/
|
|
33
|
-
export declare const showChatToast: ({ id, title, body, icon, onClick }: ChatToastProps) => void;
|
|
27
|
+
export declare const showChatToast: ({ id, title, body, icon, onClick, }: ChatToastData) => void;
|
|
34
28
|
export declare const updateMessageNotification: (props: ExtendedNotificationData & {
|
|
35
29
|
id: string;
|
|
36
30
|
}) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"showNotifications.d.ts","sourceRoot":"","sources":["../../src/helpers/showNotifications.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAUlC,OAAO,EAAE,gBAAgB,EAAiB,MAAM,wBAAwB,CAAC;AAOzE,KAAK,WAAW,GAAG,MAAM,GAAG,MAAM,GAAG,gBAAgB,CAAC;AAetD,MAAM,WAAW,kBAAkB;IACjC,KAAK,EAAE,SAAS,CAAC;IACjB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAChC;AAED,MAAM,MAAM,wBAAwB,GAAG,IAAI,CAAC,gBAAgB,EAAE,SAAS,CAAC,GAAG;IACzE,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,kBAAkB,EAAE,CAAC;IAC/B,wBAAwB,CAAC,EAAE,OAAO,CAAC;CACpC,CAAC;AA4BF,eAAO,MAAM,wBAAwB,GACnC,QAAQ,EACR,OAAO,SAAS,OAAO,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,QAAQ,CAAC,EAErD,SAAS,OAAO,EAChB,UAAS;IACP,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,CAAC,CAAC,GAAG,EAAE,QAAQ,KAAK,WAAW,CAAC,GAAG,WAAW,CAAC;IAC5D,QAAQ,CAAC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,KAAK,WAAW,CAAC,GAAG,WAAW,CAAC;CACjD,iBA+BP,CAAC;
|
|
1
|
+
{"version":3,"file":"showNotifications.d.ts","sourceRoot":"","sources":["../../src/helpers/showNotifications.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAUlC,OAAO,EAAE,gBAAgB,EAAiB,MAAM,wBAAwB,CAAC;AAOzE,KAAK,WAAW,GAAG,MAAM,GAAG,MAAM,GAAG,gBAAgB,CAAC;AAetD,MAAM,WAAW,kBAAkB;IACjC,KAAK,EAAE,SAAS,CAAC;IACjB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;CAChC;AAED,MAAM,WAAW,aAAa;IAC5B,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,SAAS,CAAC;IACjB,IAAI,EAAE,SAAS,CAAC;IAChB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,MAAM,MAAM,wBAAwB,GAAG,IAAI,CAAC,gBAAgB,EAAE,SAAS,CAAC,GAAG;IACzE,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,kBAAkB,EAAE,CAAC;IAC/B,wBAAwB,CAAC,EAAE,OAAO,CAAC;CACpC,CAAC;AA4BF,eAAO,MAAM,wBAAwB,GACnC,QAAQ,EACR,OAAO,SAAS,OAAO,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,QAAQ,CAAC,EAErD,SAAS,OAAO,EAChB,UAAS;IACP,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,CAAC,CAAC,GAAG,EAAE,QAAQ,KAAK,WAAW,CAAC,GAAG,WAAW,CAAC;IAC5D,QAAQ,CAAC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,KAAK,WAAW,CAAC,GAAG,WAAW,CAAC;CACjD,iBA+BP,CAAC;AAyCF,eAAO,MAAM,uBAAuB,GAAI,OAAO,wBAAwB,SAKtE,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,qCAM3B,aAAa,SA6Bf,CAAC;AAwBF,eAAO,MAAM,yBAAyB,GACpC,OAAO,wBAAwB,GAAG;IAAE,EAAE,EAAE,MAAM,CAAA;CAAE,SAMjD,CAAC;AAEF,eAAO,MAAM,uBAAuB,GAAI,OAAO,wBAAwB,SAKtE,CAAC;AAEF,eAAO,MAAM,uBAAuB,GAAI,OAAO,wBAAwB,SAKtE,CAAC;AAEF,eAAO,MAAM,qBAAqB,GAAI,OAAO,wBAAwB,SAMpE,CAAC"}
|
|
@@ -1,157 +1,153 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { InformationCircleIcon as
|
|
3
|
-
import { HugeiconsIcon as
|
|
4
|
-
import {
|
|
5
|
-
import { notifications as
|
|
6
|
-
import { isFunction as
|
|
7
|
-
import { isOfflineSuppressed as
|
|
8
|
-
import
|
|
9
|
-
let
|
|
10
|
-
const
|
|
11
|
-
/* @__PURE__ */
|
|
12
|
-
/* @__PURE__ */
|
|
13
|
-
|
|
1
|
+
import { jsxs as N, jsx as c } from "react/jsx-runtime";
|
|
2
|
+
import { InformationCircleIcon as b, CheckmarkCircle02Icon as O, Alert01Icon as S, Alert02Icon as B } from "@hugeicons/core-free-icons";
|
|
3
|
+
import { HugeiconsIcon as u } from "@hugeicons/react";
|
|
4
|
+
import { Box as f, Button as x } from "@mantine/core";
|
|
5
|
+
import { notifications as w } from "@mantine/notifications";
|
|
6
|
+
import { isFunction as h, isObject as p } from "lodash-es";
|
|
7
|
+
import { isOfflineSuppressed as z } from "./offlineSuppression.js";
|
|
8
|
+
import l from "./showNotifications.module.css.js";
|
|
9
|
+
let M = 0;
|
|
10
|
+
const k = /* @__PURE__ */ c(u, { icon: O, size: 14, color: "white" }), j = /* @__PURE__ */ c(u, { icon: B, size: 14, color: "white" }), E = /* @__PURE__ */ c(u, { icon: S, size: 14, color: "white" }), m = /* @__PURE__ */ c(u, { icon: b, size: 14, color: "white" }), g = (o, t) => t?.length ? /* @__PURE__ */ N(f, { children: [
|
|
11
|
+
/* @__PURE__ */ c(f, { children: o }),
|
|
12
|
+
/* @__PURE__ */ c(f, { className: l.actions, children: t.map((i, e) => /* @__PURE__ */ c(
|
|
13
|
+
x,
|
|
14
14
|
{
|
|
15
15
|
size: "compact-sm",
|
|
16
|
-
variant:
|
|
17
|
-
onClick:
|
|
16
|
+
variant: i.variant ?? "default",
|
|
17
|
+
onClick: i.onClick,
|
|
18
18
|
radius: "md",
|
|
19
|
-
children:
|
|
19
|
+
children: i.label
|
|
20
20
|
},
|
|
21
21
|
e
|
|
22
22
|
)) })
|
|
23
|
-
] }) : o,
|
|
24
|
-
const { successMsg:
|
|
25
|
-
return o.then((
|
|
26
|
-
if (
|
|
27
|
-
const n =
|
|
23
|
+
] }) : o, _ = (o, t = {}) => {
|
|
24
|
+
const { successMsg: i, errorMsg: e } = t;
|
|
25
|
+
return o.then((s) => {
|
|
26
|
+
if (i) {
|
|
27
|
+
const n = h(i) ? i(s) : i, r = {
|
|
28
28
|
id: t.notifyId,
|
|
29
|
-
...
|
|
29
|
+
...p(n) ? n : { message: n }
|
|
30
30
|
};
|
|
31
|
-
|
|
31
|
+
v(r);
|
|
32
32
|
}
|
|
33
|
-
return
|
|
34
|
-
}).catch((
|
|
33
|
+
return s;
|
|
34
|
+
}).catch((s) => {
|
|
35
35
|
if (e) {
|
|
36
|
-
const n =
|
|
36
|
+
const n = h(e) ? e(s) : e, r = {
|
|
37
37
|
id: t.notifyId,
|
|
38
|
-
...
|
|
38
|
+
...p(n) ? n : { message: n }
|
|
39
39
|
};
|
|
40
|
-
|
|
40
|
+
A(r);
|
|
41
41
|
}
|
|
42
|
-
return
|
|
42
|
+
return s;
|
|
43
43
|
});
|
|
44
|
-
},
|
|
45
|
-
root:
|
|
46
|
-
icon:
|
|
47
|
-
title:
|
|
48
|
-
description:
|
|
49
|
-
},
|
|
44
|
+
}, I = {
|
|
45
|
+
root: l.root,
|
|
46
|
+
icon: l.icon,
|
|
47
|
+
title: l.title,
|
|
48
|
+
description: l.description
|
|
49
|
+
}, a = (o, t) => {
|
|
50
50
|
const {
|
|
51
|
-
actions:
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
51
|
+
actions: i,
|
|
52
|
+
icon: e,
|
|
53
|
+
message: s,
|
|
54
|
+
onClose: n,
|
|
55
|
+
bypassOfflineSuppression: r,
|
|
56
|
+
...d
|
|
57
|
+
} = o, C = `ntf-${++M}`, y = d.id ?? C;
|
|
58
|
+
w.show({
|
|
58
59
|
color: t.color,
|
|
59
60
|
radius: 12,
|
|
60
61
|
p: "sm",
|
|
61
|
-
...
|
|
62
|
-
id:
|
|
63
|
-
|
|
64
|
-
// fall back to the status icon (info/success/etc.) when none is supplied.
|
|
65
|
-
icon: a.icon ?? t.icon,
|
|
62
|
+
...d,
|
|
63
|
+
id: y,
|
|
64
|
+
icon: e ?? t.icon,
|
|
66
65
|
withCloseButton: !0,
|
|
67
66
|
withBorder: !0,
|
|
68
|
-
classNames:
|
|
67
|
+
classNames: I,
|
|
69
68
|
onClose: () => {
|
|
70
|
-
|
|
69
|
+
n?.(o);
|
|
71
70
|
},
|
|
72
|
-
message:
|
|
71
|
+
message: g(s, i)
|
|
73
72
|
});
|
|
74
|
-
},
|
|
75
|
-
|
|
73
|
+
}, $ = (o) => {
|
|
74
|
+
a(o, {
|
|
76
75
|
color: "blue",
|
|
77
|
-
icon:
|
|
76
|
+
icon: m
|
|
78
77
|
});
|
|
79
|
-
},
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
78
|
+
}, G = ({
|
|
79
|
+
id: o,
|
|
80
|
+
title: t,
|
|
81
|
+
body: i,
|
|
82
|
+
icon: e,
|
|
83
|
+
onClick: s
|
|
84
|
+
}) => {
|
|
85
|
+
a(
|
|
84
86
|
{
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
p: "sm",
|
|
101
|
-
withCloseButton: !0,
|
|
102
|
-
withBorder: !0,
|
|
103
|
-
autoClose: 6e3,
|
|
104
|
-
classNames: {
|
|
105
|
-
root: c.chatToastRoot,
|
|
106
|
-
closeButton: c.chatToastClose
|
|
87
|
+
id: o,
|
|
88
|
+
title: t,
|
|
89
|
+
message: s ? /* @__PURE__ */ c(
|
|
90
|
+
f,
|
|
91
|
+
{
|
|
92
|
+
role: "button",
|
|
93
|
+
tabIndex: 0,
|
|
94
|
+
onClick: s,
|
|
95
|
+
onKeyDown: (n) => {
|
|
96
|
+
(n.key === "Enter" || n.key === " ") && (n.preventDefault(), s());
|
|
97
|
+
},
|
|
98
|
+
children: i
|
|
99
|
+
}
|
|
100
|
+
) : i,
|
|
101
|
+
icon: e
|
|
107
102
|
},
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
103
|
+
{
|
|
104
|
+
color: "blue",
|
|
105
|
+
icon: m
|
|
106
|
+
}
|
|
107
|
+
);
|
|
108
|
+
}, q = (o, t) => {
|
|
109
|
+
const { actions: i, icon: e, message: s, onClose: n, ...r } = o;
|
|
110
|
+
w.update({
|
|
115
111
|
color: t.color,
|
|
116
112
|
radius: 12,
|
|
117
113
|
p: "sm",
|
|
118
|
-
...
|
|
119
|
-
icon: t.icon,
|
|
114
|
+
...r,
|
|
115
|
+
icon: e ?? t.icon,
|
|
120
116
|
withCloseButton: !0,
|
|
121
117
|
withBorder: !0,
|
|
122
|
-
classNames:
|
|
118
|
+
classNames: I,
|
|
123
119
|
onClose: () => {
|
|
124
|
-
|
|
120
|
+
n?.(o);
|
|
125
121
|
},
|
|
126
|
-
message:
|
|
122
|
+
message: g(s, i)
|
|
127
123
|
});
|
|
128
|
-
},
|
|
129
|
-
|
|
124
|
+
}, J = (o) => {
|
|
125
|
+
q(o, {
|
|
130
126
|
color: "var(--mantine-color-blue-outline)",
|
|
131
|
-
icon:
|
|
127
|
+
icon: m
|
|
132
128
|
});
|
|
133
|
-
},
|
|
134
|
-
|
|
129
|
+
}, v = (o) => {
|
|
130
|
+
a(o, {
|
|
135
131
|
color: "green",
|
|
136
|
-
icon:
|
|
132
|
+
icon: k
|
|
137
133
|
});
|
|
138
|
-
},
|
|
139
|
-
|
|
134
|
+
}, L = (o) => {
|
|
135
|
+
a(o, {
|
|
140
136
|
color: "yellow",
|
|
141
|
-
icon:
|
|
137
|
+
icon: E
|
|
142
138
|
});
|
|
143
|
-
},
|
|
144
|
-
!o.bypassOfflineSuppression &&
|
|
139
|
+
}, A = (o) => {
|
|
140
|
+
!o.bypassOfflineSuppression && z() || a(o, {
|
|
145
141
|
color: "red",
|
|
146
|
-
icon:
|
|
142
|
+
icon: j
|
|
147
143
|
});
|
|
148
144
|
};
|
|
149
145
|
export {
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
146
|
+
G as showChatToast,
|
|
147
|
+
A as showErrorNotification,
|
|
148
|
+
$ as showMessageNotification,
|
|
149
|
+
_ as showRequestNotifications,
|
|
150
|
+
v as showSuccessNotification,
|
|
151
|
+
L as showWarningNotification,
|
|
152
|
+
J as updateMessageNotification
|
|
157
153
|
};
|
|
@@ -1,25 +1,13 @@
|
|
|
1
|
-
const t = "
|
|
1
|
+
const t = "_root_15gxq_1", o = "_icon_15gxq_8", c = "_title_15gxq_40", s = "_description_15gxq_44", i = "_actions_15gxq_48", n = {
|
|
2
2
|
root: t,
|
|
3
3
|
icon: o,
|
|
4
4
|
title: c,
|
|
5
5
|
description: s,
|
|
6
|
-
actions:
|
|
7
|
-
chatToastRoot: _,
|
|
8
|
-
chatToast: n,
|
|
9
|
-
chatToastIcon: w,
|
|
10
|
-
chatToastTitle: T,
|
|
11
|
-
chatToastBody: d,
|
|
12
|
-
chatToastClose: h
|
|
6
|
+
actions: i
|
|
13
7
|
};
|
|
14
8
|
export {
|
|
15
|
-
|
|
16
|
-
n as
|
|
17
|
-
d as chatToastBody,
|
|
18
|
-
h as chatToastClose,
|
|
19
|
-
w as chatToastIcon,
|
|
20
|
-
_ as chatToastRoot,
|
|
21
|
-
T as chatToastTitle,
|
|
22
|
-
i as default,
|
|
9
|
+
i as actions,
|
|
10
|
+
n as default,
|
|
23
11
|
s as description,
|
|
24
12
|
o as icon,
|
|
25
13
|
t as root,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useDateUtils.d.ts","sourceRoot":"","sources":["../../src/hooks/useDateUtils.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,qBAAqB,EACrB,0BAA0B,EAS3B,MAAM,UAAU,CAAC;AAMlB,eAAO,MAAM,YAAY;;
|
|
1
|
+
{"version":3,"file":"useDateUtils.d.ts","sourceRoot":"","sources":["../../src/hooks/useDateUtils.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,qBAAqB,EACrB,0BAA0B,EAS3B,MAAM,UAAU,CAAC;AAMlB,eAAO,MAAM,YAAY;;uBAOf,IAAI,GAAG,MAAM,gCAET;QAAE,MAAM,CAAC,EAAE,OAAO,CAAA;KAAE,KAC7B,MAAM;iCAoDD,IAAI,GAAG,MAAM,yBAElB,MAAM;+BAKD,IAAI,GAAG,MAAM,YACT,0BAA0B,KACnC,MAAM;mCAQA,IAAI,GAAG,MAAM,SACb,IAAI,GAAG,MAAM,KACnB,OAAO;wCAQD,IAAI,GAAG,MAAM,SACb,IAAI,GAAG,MAAM,YACV,qBAAqB,KAC9B,MAAM;oCArED,IAAI,GAAG,MAAM,YACT;QAAE,KAAK,CAAC,EAAE,OAAO,CAAA;KAAE,KAC5B,MAAM;CAmFV,CAAC"}
|
|
@@ -1,47 +1,43 @@
|
|
|
1
|
-
import { useTranslation as
|
|
2
|
-
import { differenceInDays as
|
|
3
|
-
import { toZonedTime as s, formatInTimeZone as
|
|
4
|
-
import { useLocalTimezone as
|
|
5
|
-
import { dateFnsLocales as
|
|
6
|
-
const
|
|
7
|
-
const { timezone: o } =
|
|
1
|
+
import { useTranslation as h } from "react-i18next";
|
|
2
|
+
import { differenceInDays as v, differenceInHours as p, differenceInMinutes as U, differenceInSeconds as w, formatDistance as C, isSameDay as S, formatDistanceToNow as H, format as d } from "date-fns";
|
|
3
|
+
import { toZonedTime as s, formatInTimeZone as I } from "date-fns-tz";
|
|
4
|
+
import { useLocalTimezone as M } from "../store/timezoneStore.js";
|
|
5
|
+
import { dateFnsLocales as y } from "./useDateFnsLocale.js";
|
|
6
|
+
const k = () => {
|
|
7
|
+
const { timezone: o } = M(), { t: a, i18n: z } = h("ui"), f = y[z.language] || y.en;
|
|
8
8
|
return {
|
|
9
9
|
timezone: o,
|
|
10
10
|
formatDate: (e, t = "yyyy-MM-dd HH:mm:ss", n) => {
|
|
11
11
|
const r = typeof e == "string" ? new Date(e) : e, i = s(r, o || "UTC");
|
|
12
|
-
|
|
13
|
-
const f = d[y.language] || d.en;
|
|
14
|
-
return l(i, t, { locale: f });
|
|
15
|
-
}
|
|
16
|
-
return l(i, t);
|
|
12
|
+
return n?.locale ?? !1 ? d(i, t, { locale: f }) : d(i, t);
|
|
17
13
|
},
|
|
18
|
-
formatDateInTimezone: (e, t = "yyyy-MM-dd HH:mm:ss") =>
|
|
14
|
+
formatDateInTimezone: (e, t = "yyyy-MM-dd HH:mm:ss") => I(e, o || "UTC", t),
|
|
19
15
|
formatRelativeTime: (e, t) => {
|
|
20
16
|
const n = typeof e == "string" ? new Date(e) : e, r = s(n, o || "UTC");
|
|
21
|
-
return
|
|
17
|
+
return H(r, { ...t });
|
|
22
18
|
},
|
|
23
19
|
isSameDayWithTimezone: (e, t) => {
|
|
24
20
|
const n = s(e, o || "UTC"), r = s(t, o || "UTC");
|
|
25
|
-
return
|
|
21
|
+
return S(n, r);
|
|
26
22
|
},
|
|
27
23
|
formatDistanceWithTimezone: (e, t, n) => {
|
|
28
24
|
const r = s(e, o || "UTC"), i = s(t, o || "UTC");
|
|
29
|
-
return
|
|
25
|
+
return C(r, i, { ...n, locale: f });
|
|
30
26
|
},
|
|
31
27
|
formatRelativeShortTime: (e, t) => {
|
|
32
|
-
const n = typeof e == "string" ? new Date(e) : e, r = /* @__PURE__ */ new Date(), i = s(n, o || "UTC"), m = s(r, o || "UTC"),
|
|
33
|
-
return
|
|
34
|
-
count: f
|
|
35
|
-
}) : T >= 1 ? a(c ? "relativeTime.shortHour" : "relativeTime.hour", {
|
|
28
|
+
const n = typeof e == "string" ? new Date(e) : e, r = /* @__PURE__ */ new Date(), i = s(n, o || "UTC"), m = s(r, o || "UTC"), T = v(m, i), u = p(m, i), D = U(m, i), l = w(m, i), c = t?.short ?? !1;
|
|
29
|
+
return T >= 1 ? a(c ? "relativeTime.shortDay" : "relativeTime.day", {
|
|
36
30
|
count: T
|
|
37
|
-
}) : u >= 1 ? a(c ? "relativeTime.
|
|
31
|
+
}) : u >= 1 ? a(c ? "relativeTime.shortHour" : "relativeTime.hour", {
|
|
38
32
|
count: u
|
|
39
|
-
}) : D >= 1 ? a(c ? "relativeTime.
|
|
33
|
+
}) : D >= 1 ? a(c ? "relativeTime.shortMinute" : "relativeTime.minute", {
|
|
40
34
|
count: D
|
|
35
|
+
}) : l >= 1 ? a(c ? "relativeTime.shortSecond" : "relativeTime.second", {
|
|
36
|
+
count: l
|
|
41
37
|
}) : a(c ? "relativeTime.shortJustNow" : "relativeTime.justNow");
|
|
42
38
|
}
|
|
43
39
|
};
|
|
44
40
|
};
|
|
45
41
|
export {
|
|
46
|
-
|
|
42
|
+
k as useDateUtils
|
|
47
43
|
};
|