@robot-admin/naive-ui-components 0.10.2 → 0.11.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/CHANGELOG.md +111 -94
- package/LICENSE +21 -21
- package/README.md +463 -315
- package/README_EN.md +404 -0
- package/SECURITY.md +23 -0
- package/dist/C_ActionBar.cjs +1 -1
- package/dist/C_ActionBar.css +46 -48
- package/dist/C_ActionBar.d.cts +1 -1
- package/dist/C_ActionBar.js +1 -1
- package/dist/C_ActionBar2.cjs +1 -0
- package/dist/C_ActionBar2.js +1 -2
- package/dist/C_AntV.cjs +1 -1
- package/dist/C_AntV.css +3 -3
- package/dist/C_AntV.d.cts +1 -1
- package/dist/C_AntV.js +1 -1
- package/dist/C_AntV2.cjs +4 -0
- package/dist/C_AntV2.js +3 -4
- package/dist/C_AudioPlayer.cjs +1 -1
- package/dist/C_AudioPlayer.css +15 -7
- package/dist/C_AudioPlayer.d.cts +1 -1
- package/dist/C_AudioPlayer.js +1 -1
- package/dist/C_AudioPlayer2.cjs +1 -0
- package/dist/C_AudioPlayer2.js +1 -2
- package/dist/C_AvatarGroup.cjs +1 -1
- package/dist/C_AvatarGroup.css +15 -7
- package/dist/C_AvatarGroup.d.cts +1 -1
- package/dist/C_AvatarGroup2.cjs +1 -0
- package/dist/C_AvatarGroup2.js +1 -2
- package/dist/C_Barcode.cjs +1 -1
- package/dist/C_Barcode.css +0 -2
- package/dist/C_Barcode.d.cts +1 -1
- package/dist/C_Barcode2.cjs +1 -0
- package/dist/C_Barcode2.js +1 -2
- package/dist/C_Breadcrumb.cjs +1 -1
- package/dist/C_Breadcrumb.css +0 -2
- package/dist/C_Breadcrumb.d.cts +2 -2
- package/dist/C_Breadcrumb.d.ts +1 -1
- package/dist/C_Breadcrumb.js +1 -1
- package/dist/C_Breadcrumb2.cjs +1 -0
- package/dist/C_Breadcrumb2.js +1 -2
- package/dist/C_Captcha.cjs +1 -1
- package/dist/C_Captcha.css +46 -21
- package/dist/C_Captcha.d.cts +3 -2
- package/dist/C_Captcha.d.ts +3 -2
- package/dist/C_Captcha.js +1 -1
- package/dist/C_Captcha2.cjs +1 -0
- package/dist/C_Captcha2.js +1 -2
- package/dist/C_Cascade.cjs +1 -1
- package/dist/C_Cascade.css +0 -2
- package/dist/C_Cascade.d.cts +1 -1
- package/dist/C_Cascade.d.ts +1 -1
- package/dist/C_Cascade2.cjs +1 -0
- package/dist/C_Cascade2.js +1 -2
- package/dist/C_Chat.cjs +1 -1
- package/dist/C_Chat.css +0 -2
- package/dist/C_Chat.d.cts +1 -1
- package/dist/C_Chat.d.ts +1 -1
- package/dist/C_Chat.js +1 -1
- package/dist/C_Chat2.cjs +1 -0
- package/dist/C_Chat2.js +1 -2
- package/dist/C_City.cjs +1 -1
- package/dist/C_City.css +28 -30
- package/dist/C_City.d.cts +1 -1
- package/dist/C_City.d.ts +1 -1
- package/dist/C_City2.cjs +1 -0
- package/dist/C_City2.js +1 -2
- package/dist/C_Code.cjs +1 -1
- package/dist/C_Code.css +241 -4
- package/dist/C_Code.d.cts +1 -1
- package/dist/C_Code.d.ts +1 -1
- package/dist/C_Code.js +1 -1
- package/dist/C_Code2.cjs +1 -0
- package/dist/C_Code2.js +1 -2
- package/dist/C_CollapsePanel.cjs +1 -1
- package/dist/C_CollapsePanel.css +12 -6
- package/dist/C_CollapsePanel.d.cts +1 -1
- package/dist/C_CollapsePanel.js +1 -1
- package/dist/C_CollapsePanel2.cjs +1 -0
- package/dist/C_CollapsePanel2.js +1 -2
- package/dist/C_ContextMenu.cjs +1 -1
- package/dist/C_ContextMenu.css +16 -18
- package/dist/C_ContextMenu.d.cts +1 -1
- package/dist/C_ContextMenu.d.ts +1 -1
- package/dist/C_ContextMenu.js +1 -1
- package/dist/C_ContextMenu2.cjs +1 -0
- package/dist/C_ContextMenu2.js +1 -2
- package/dist/C_Cron.cjs +1 -1
- package/dist/C_Cron.css +18 -8
- package/dist/C_Cron.d.cts +1 -1
- package/dist/C_Cron.js +1 -1
- package/dist/C_Cron2.cjs +1 -0
- package/dist/C_Cron2.js +1 -2
- package/dist/C_Date.cjs +1 -1
- package/dist/C_Date.css +1 -0
- package/dist/C_Date.d.cts +2 -2
- package/dist/C_Date.d.ts +2 -2
- package/dist/C_Date2.cjs +1 -0
- package/dist/C_Date2.js +1 -2
- package/dist/C_Draggable.cjs +1 -1
- package/dist/C_Draggable.css +9 -5
- package/dist/C_Draggable.d.cts +1 -1
- package/dist/C_Draggable2.cjs +1 -0
- package/dist/C_Draggable2.js +1 -2
- package/dist/C_Editor.cjs +1 -1
- package/dist/C_Editor.css +80 -67
- package/dist/C_Editor.d.cts +1 -1
- package/dist/C_Editor.d.ts +1 -1
- package/dist/C_Editor2.cjs +1 -0
- package/dist/C_Editor2.js +1 -2
- package/dist/C_FilePreview.cjs +1 -1
- package/dist/C_FilePreview.css +0 -2
- package/dist/C_FilePreview.d.cts +1 -1
- package/dist/C_FilePreview.js +1 -1
- package/dist/C_FilePreview2.cjs +1 -0
- package/dist/C_FilePreview2.js +1 -2
- package/dist/C_Form.base.css +980 -0
- package/dist/C_Form.cjs +1 -1
- package/dist/C_Form.css +256 -155
- package/dist/C_Form.d.cts +2 -2
- package/dist/C_Form.d.ts +2 -2
- package/dist/C_Form.js +1 -1
- package/dist/C_Form2.cjs +1 -0
- package/dist/C_Form2.js +1 -2
- package/dist/C_FormSearch.cjs +1 -1
- package/dist/C_FormSearch.css +47 -47
- package/dist/C_FormSearch.d.cts +2 -2
- package/dist/C_FormSearch.d.ts +2 -2
- package/dist/C_FormSearch2.cjs +1 -0
- package/dist/C_FormSearch2.js +1 -2
- package/dist/C_FormulaEditor.cjs +1 -1
- package/dist/C_FormulaEditor.css +64 -38
- package/dist/C_FormulaEditor.d.cts +1 -1
- package/dist/C_FormulaEditor.js +1 -1
- package/dist/C_FormulaEditor2.cjs +2 -0
- package/dist/C_FormulaEditor2.js +2 -2
- package/dist/C_FullCalendar.cjs +1 -1
- package/dist/C_FullCalendar.css +0 -2
- package/dist/C_FullCalendar.d.cts +1 -1
- package/dist/C_FullCalendar2.cjs +1 -0
- package/dist/C_FullCalendar2.js +1 -2
- package/dist/C_GlobalSearch.cjs +1 -1
- package/dist/C_GlobalSearch.css +111 -113
- package/dist/C_GlobalSearch.d.cts +1 -1
- package/dist/C_GlobalSearch2.cjs +1 -0
- package/dist/C_GlobalSearch2.js +1 -2
- package/dist/C_Guide.cjs +1 -1
- package/dist/C_Guide.css +1 -0
- package/dist/C_Guide.d.cts +1 -1
- package/dist/C_Guide.d.ts +1 -1
- package/dist/C_Guide.js +1 -1
- package/dist/C_Guide2.cjs +1 -0
- package/dist/C_Guide2.js +1 -2
- package/dist/C_Icon.cjs +1 -1
- package/dist/C_Icon.css +58 -0
- package/dist/C_Icon.d.cts +1 -1
- package/dist/C_Icon.d.ts +1 -1
- package/dist/C_Icon2.cjs +1 -0
- package/dist/C_Icon2.js +1 -2
- package/dist/C_ImageCropper.cjs +1 -1
- package/dist/C_ImageCropper.css +0 -2
- package/dist/C_ImageCropper.d.cts +1 -1
- package/dist/C_ImageCropper.js +1 -1
- package/dist/C_ImageCropper2.cjs +1 -0
- package/dist/C_ImageCropper2.js +1 -2
- package/dist/C_Language.cjs +1 -1
- package/dist/C_Language.css +1 -0
- package/dist/C_Language.d.cts +1 -1
- package/dist/C_Language.d.ts +1 -1
- package/dist/C_Language.js +1 -1
- package/dist/C_Language2.cjs +1 -0
- package/dist/C_Language2.js +1 -2
- package/dist/C_Login.cjs +1 -1
- package/dist/C_Login.css +92 -76
- package/dist/C_Login.d.cts +1 -1
- package/dist/C_Login.d.ts +1 -1
- package/dist/C_Login.js +1 -1
- package/dist/C_Login2.cjs +1 -0
- package/dist/C_Login2.js +1 -2
- package/dist/C_Map.cjs +1 -1
- package/dist/C_Map.css +665 -5
- package/dist/C_Map.d.cts +1 -1
- package/dist/C_Map2.cjs +1 -0
- package/dist/C_Map2.js +1 -2
- package/dist/C_Markdown.cjs +1 -1
- package/dist/C_Markdown.css +940 -35
- package/dist/C_Markdown.d.cts +1 -1
- package/dist/C_Markdown.d.ts +1 -1
- package/dist/C_Markdown2.cjs +1 -0
- package/dist/C_Markdown2.js +1 -2
- package/dist/C_Menu.cjs +1 -1
- package/dist/C_Menu.css +1 -0
- package/dist/C_Menu.d.cts +3 -3
- package/dist/C_Menu.d.ts +3 -3
- package/dist/C_Menu2.cjs +1 -0
- package/dist/C_Menu2.js +1 -2
- package/dist/C_NotificationCenter.cjs +1 -1
- package/dist/C_NotificationCenter.css +95 -47
- package/dist/C_NotificationCenter.d.cts +1 -1
- package/dist/C_NotificationCenter.js +1 -1
- package/dist/C_NotificationCenter2.cjs +1 -0
- package/dist/C_NotificationCenter2.js +1 -2
- package/dist/C_OrgChart.cjs +1 -1
- package/dist/C_OrgChart.css +6 -4
- package/dist/C_OrgChart.d.cts +1 -1
- package/dist/C_OrgChart.d.ts +1 -1
- package/dist/C_OrgChart2.cjs +1 -0
- package/dist/C_OrgChart2.js +1 -2
- package/dist/C_Progress.cjs +1 -1
- package/dist/C_Progress.css +1 -0
- package/dist/C_Progress.d.cts +1 -1
- package/dist/C_Progress.d.ts +1 -1
- package/dist/C_Progress2.cjs +1 -0
- package/dist/C_Progress2.js +1 -2
- package/dist/C_QRCode.cjs +1 -1
- package/dist/C_QRCode.css +8 -10
- package/dist/C_QRCode.d.cts +1 -1
- package/dist/C_QRCode2.cjs +1 -0
- package/dist/C_QRCode2.js +1 -2
- package/dist/C_Signature.cjs +1 -1
- package/dist/C_Signature.css +0 -2
- package/dist/C_Signature.d.cts +1 -1
- package/dist/C_Signature.js +1 -1
- package/dist/C_Signature2.cjs +1 -0
- package/dist/C_Signature2.js +1 -2
- package/dist/C_Skeleton.cjs +1 -1
- package/dist/C_Skeleton.css +0 -2
- package/dist/C_Skeleton.d.cts +1 -1
- package/dist/C_Skeleton.d.ts +1 -1
- package/dist/C_Skeleton2.cjs +1 -0
- package/dist/C_Skeleton2.js +1 -2
- package/dist/C_SplitPane.cjs +1 -1
- package/dist/C_SplitPane.css +27 -11
- package/dist/C_SplitPane.d.cts +1 -1
- package/dist/C_SplitPane.js +1 -1
- package/dist/C_SplitPane2.cjs +1 -0
- package/dist/C_SplitPane2.js +1 -2
- package/dist/C_Steps.cjs +1 -1
- package/dist/C_Steps.css +37 -39
- package/dist/C_Steps.d.cts +1 -1
- package/dist/C_Steps.d.ts +1 -1
- package/dist/C_Steps2.cjs +1 -0
- package/dist/C_Steps2.js +1 -2
- package/dist/C_Table.base.css +1588 -0
- package/dist/C_Table.cjs +1 -1
- package/dist/C_Table.css +1202 -112
- package/dist/C_Table.d.cts +2 -2
- package/dist/C_Table.d.ts +11 -2
- package/dist/C_Table.js +1 -1
- package/dist/C_TagsView.cjs +1 -1
- package/dist/C_TagsView.css +44 -40
- package/dist/C_TagsView.d.cts +2 -2
- package/dist/C_TagsView.d.ts +2 -2
- package/dist/C_TagsView.js +1 -1
- package/dist/C_TagsView2.cjs +1 -0
- package/dist/C_TagsView2.js +1 -2
- package/dist/C_Theme.cjs +1 -1
- package/dist/C_Theme.css +1 -0
- package/dist/C_Theme.d.cts +1 -1
- package/dist/C_Theme.d.ts +1 -1
- package/dist/C_Theme.js +1 -1
- package/dist/C_Theme2.cjs +1 -0
- package/dist/C_Theme2.js +1 -2
- package/dist/C_Time.cjs +1 -1
- package/dist/C_Time.css +0 -2
- package/dist/C_Time.d.cts +2 -2
- package/dist/C_Time.d.ts +2 -2
- package/dist/C_Time2.cjs +1 -0
- package/dist/C_Time2.js +1 -2
- package/dist/C_Timeline.cjs +1 -1
- package/dist/C_Timeline.css +44 -46
- package/dist/C_Timeline.d.cts +1 -1
- package/dist/C_Timeline.js +1 -1
- package/dist/C_Timeline2.cjs +1 -0
- package/dist/C_Timeline2.js +1 -2
- package/dist/C_Transfer.cjs +1 -1
- package/dist/C_Transfer.css +21 -9
- package/dist/C_Transfer.d.cts +1 -1
- package/dist/C_Transfer.js +1 -1
- package/dist/C_Transfer2.cjs +1 -0
- package/dist/C_Transfer2.js +1 -2
- package/dist/C_Tree.cjs +1 -1
- package/dist/C_Tree.css +0 -2
- package/dist/C_Tree.d.cts +1 -1
- package/dist/C_Tree.js +1 -1
- package/dist/C_Tree2.cjs +1 -0
- package/dist/C_Tree2.js +1 -2
- package/dist/C_Upload.cjs +1 -1
- package/dist/C_Upload.css +17 -17
- package/dist/C_Upload.d.cts +1 -1
- package/dist/C_Upload.js +1 -1
- package/dist/C_Upload2.cjs +1 -0
- package/dist/C_Upload2.js +1 -25
- package/dist/C_VideoPlayer.cjs +1 -1
- package/dist/C_VideoPlayer.css +35 -24
- package/dist/C_VideoPlayer.d.cts +2 -2
- package/dist/C_VideoPlayer.d.ts +2 -2
- package/dist/C_VideoPlayer.js +1 -1
- package/dist/C_VideoPlayer2.cjs +3 -0
- package/dist/C_VideoPlayer2.js +3 -4
- package/dist/C_VtableGantt.cjs +1 -1
- package/dist/C_VtableGantt.css +15 -7
- package/dist/C_VtableGantt.d.cts +1 -1
- package/dist/C_VtableGantt.d.ts +1 -1
- package/dist/C_VtableGantt.js +1 -1
- package/dist/C_VtableGantt2.cjs +1 -0
- package/dist/C_VtableGantt2.js +1 -2
- package/dist/C_WaterFall.cjs +1 -1
- package/dist/C_WaterFall.css +15 -17
- package/dist/C_WaterFall.d.cts +1 -1
- package/dist/C_WaterFall2.cjs +1 -0
- package/dist/C_WaterFall2.js +1 -2
- package/dist/C_WorkFlow.cjs +1 -1
- package/dist/C_WorkFlow.css +257 -197
- package/dist/C_WorkFlow.d.cts +1 -1
- package/dist/C_WorkFlow.js +1 -1
- package/dist/C_WorkFlow2.cjs +1 -0
- package/dist/C_WorkFlow2.js +1 -2
- package/dist/city.cjs +1 -0
- package/dist/city.js +1 -2
- package/dist/config.cjs +1 -0
- package/dist/config.d.cts +33 -0
- package/dist/config.d.ts +33 -0
- package/dist/config.js +1 -0
- package/dist/constants.d.cts +272 -0
- package/dist/constants.d.ts +2 -3
- package/dist/constants2.d.cts +177 -0
- package/dist/constants2.d.ts +3 -4
- package/dist/constants3.d.cts +479 -0
- package/dist/constants3.d.ts +16 -12
- package/dist/constants4.d.cts +420 -0
- package/dist/constants4.d.ts +27 -37
- package/dist/constants5.d.cts +491 -0
- package/dist/constants5.d.ts +20 -4
- package/dist/data.cjs +1 -0
- package/dist/data.d.cts +67 -0
- package/dist/data.d.ts +12 -12
- package/dist/data.js +1 -0
- package/dist/export-helper.cjs +1 -0
- package/dist/helpers.cjs +1 -0
- package/dist/helpers.js +1 -0
- package/dist/html.cjs +1 -0
- package/dist/html.js +1 -0
- package/dist/images/marker-icon-2x.png +0 -0
- package/dist/images/marker-icon.png +0 -0
- package/dist/images/marker-shadow.png +0 -0
- package/dist/index.cjs +1 -2
- package/dist/index.d.cts +60 -99
- package/dist/index.d.ts +75 -164
- package/dist/index.js +1 -2
- package/dist/index.vue.d.cts +79 -0
- package/dist/index.vue.d.ts +3 -4
- package/dist/index10.vue.d.cts +47 -0
- package/dist/index10.vue.d.ts +80 -40
- package/dist/index11.vue.d.cts +88 -0
- package/dist/index11.vue.d.ts +68 -78
- package/dist/index12.vue.d.cts +79 -0
- package/dist/index12.vue.d.ts +49 -45
- package/dist/index13.vue.d.cts +64 -0
- package/dist/index13.vue.d.ts +99 -34
- package/dist/index14.vue.d.cts +106 -0
- package/dist/index14.vue.d.ts +82 -99
- package/dist/index15.vue.d.cts +91 -0
- package/dist/index15.vue.d.ts +25 -83
- package/dist/index16.vue.d.cts +34 -0
- package/dist/index16.vue.d.ts +113 -24
- package/dist/index17.vue.d.cts +124 -0
- package/dist/index17.vue.d.ts +76 -110
- package/dist/index18.vue.d.cts +83 -0
- package/dist/index18.vue.d.ts +67 -73
- package/dist/index19.vue.d.cts +101 -0
- package/dist/index19.vue.d.ts +93 -59
- package/dist/index2.vue.d.cts +82 -0
- package/dist/index2.vue.d.ts +7 -8
- package/dist/index20.vue.d.cts +54 -0
- package/dist/index20.vue.d.ts +40 -88
- package/dist/index21.vue.d.cts +103 -0
- package/dist/index21.vue.d.ts +89 -41
- package/dist/index22.vue.d.cts +45 -0
- package/dist/index22.vue.d.ts +37 -96
- package/dist/index23.vue.d.cts +19 -0
- package/dist/index23.vue.d.ts +8 -35
- package/dist/{index28.vue.d.ts → index24.vue.d.cts} +4 -5
- package/dist/index24.vue.d.ts +650 -86
- package/dist/index25.vue.d.cts +96 -0
- package/dist/index25.vue.d.ts +86 -10
- package/dist/index26.vue.d.cts +111 -0
- package/dist/index26.vue.d.ts +4 -5
- package/dist/index27.vue.d.cts +80 -0
- package/dist/index27.vue.d.ts +2 -3
- package/dist/index3.vue.d.cts +87 -0
- package/dist/index3.vue.d.ts +4 -5
- package/dist/index4.vue.d.cts +37 -0
- package/dist/index4.vue.d.ts +6 -7
- package/dist/index5.vue.d.cts +133 -0
- package/dist/index5.vue.d.ts +2 -3
- package/dist/index6.vue.d.cts +29 -0
- package/dist/index6.vue.d.ts +25 -38
- package/dist/index7.vue.d.cts +32 -0
- package/dist/index7.vue.d.ts +117 -23
- package/dist/index8.vue.d.cts +127 -0
- package/dist/index8.vue.d.ts +17 -111
- package/dist/index9.vue.d.cts +34 -0
- package/dist/index9.vue.d.ts +38 -26
- package/dist/public.d.ts +166 -0
- package/dist/resolver.cjs +1 -2
- package/dist/resolver.d.cts +6 -4
- package/dist/resolver.d.ts +6 -4
- package/dist/resolver.js +1 -2
- package/dist/storage.cjs +1 -0
- package/dist/storage.js +1 -2
- package/dist/style.css +9864 -7702
- package/dist/types.d.cts +107 -0
- package/dist/types.d.ts +52 -102
- package/dist/types2.d.cts +58 -0
- package/dist/useCalendarEvents.d.cts +150 -0
- package/dist/useCalendarEvents.d.ts +3 -4
- package/dist/useCollapsePanel.d.cts +133 -0
- package/dist/useCollapsePanel.d.ts +2 -3
- package/dist/useCropperCore.d.cts +104 -0
- package/dist/useCropperCore.d.ts +11 -9
- package/dist/useDraggableLayout.d.cts +196 -0
- package/dist/useDraggableLayout.d.ts +17 -15
- package/dist/useDynamicFormState.d.cts +749 -0
- package/dist/useDynamicFormState.d.ts +234 -112
- package/dist/useEdgeInteraction.d.cts +324 -0
- package/dist/useEdgeInteraction.d.ts +6 -7
- package/dist/useFullscreen.d.cts +165 -0
- package/dist/useFullscreen.d.ts +1 -2
- package/dist/useGlobalSearch.d.cts +110 -0
- package/dist/useGlobalSearch.d.ts +17 -9
- package/dist/useInfiniteScroll.d.cts +177 -0
- package/dist/useInfiniteScroll.d.ts +13 -5
- package/dist/useQRCode.d.cts +89 -0
- package/dist/useQRCode.d.ts +5 -3
- package/dist/useSearchState.d.cts +871 -0
- package/dist/useSearchState.d.ts +830 -30
- package/dist/useSignatureHistory.d.cts +197 -0
- package/dist/useSignatureHistory.d.ts +10 -5
- package/dist/useSplitResize.d.cts +157 -0
- package/dist/useSplitResize.d.ts +3 -4
- package/dist/useTableQuery.cjs +3 -0
- package/dist/{useModalEdit.d.ts → useTableQuery.d.cts} +624 -211
- package/dist/useTableQuery.d.ts +1721 -0
- package/dist/useTableQuery.js +3 -0
- package/dist/useTimeSelection.d.cts +116 -0
- package/dist/useTimeSelection.d.ts +20 -9
- package/dist/useTreeOperations.d.cts +185 -0
- package/dist/useTreeOperations.d.ts +13 -11
- package/dist/useWorkflowValidation.d.cts +1051 -0
- package/dist/useWorkflowValidation.d.ts +62 -63
- package/dist/verification.d.cts +58 -0
- package/dist/verification.d.ts +58 -0
- package/package.json +102 -69
- package/dist/C_ActionBar-BAcfOfRw.css.map +0 -1
- package/dist/C_ActionBar-DG2HW7t5.css.map +0 -1
- package/dist/C_ActionBar.js.map +0 -1
- package/dist/C_ActionBar2.js.map +0 -1
- package/dist/C_AntV-D_jTK8oZ.css.map +0 -1
- package/dist/C_AntV-DanTAq22.css.map +0 -1
- package/dist/C_AntV.js.map +0 -1
- package/dist/C_AntV2.js.map +0 -1
- package/dist/C_AudioPlayer-BnYIJXPD.css.map +0 -1
- package/dist/C_AudioPlayer-Cj4lUdZo.css.map +0 -1
- package/dist/C_AudioPlayer.js.map +0 -1
- package/dist/C_AudioPlayer2.js.map +0 -1
- package/dist/C_AvatarGroup-B9d-GJ9c.css.map +0 -1
- package/dist/C_AvatarGroup-D3PwsKME.css.map +0 -1
- package/dist/C_AvatarGroup.js.map +0 -1
- package/dist/C_AvatarGroup2.js.map +0 -1
- package/dist/C_Barcode-CAU2mFcx.css.map +0 -1
- package/dist/C_Barcode-D2oJaEg3.css.map +0 -1
- package/dist/C_Barcode.js.map +0 -1
- package/dist/C_Barcode2.js.map +0 -1
- package/dist/C_Breadcrumb-BiH0d9AI.css.map +0 -1
- package/dist/C_Breadcrumb-DOcLt9uX.css.map +0 -1
- package/dist/C_Breadcrumb.js.map +0 -1
- package/dist/C_Breadcrumb2.js.map +0 -1
- package/dist/C_Captcha-B3yrtG7t.css.map +0 -1
- package/dist/C_Captcha-D4hDdWDu.css.map +0 -1
- package/dist/C_Captcha.js.map +0 -1
- package/dist/C_Captcha2.js.map +0 -1
- package/dist/C_Cascade-CmCrLVft.css.map +0 -1
- package/dist/C_Cascade-U6A5AJJb.css.map +0 -1
- package/dist/C_Cascade.js.map +0 -1
- package/dist/C_Cascade2.js.map +0 -1
- package/dist/C_Chat-DeUv6uuI.css.map +0 -1
- package/dist/C_Chat-DwatUQqu.css.map +0 -1
- package/dist/C_Chat.js.map +0 -1
- package/dist/C_Chat2.js.map +0 -1
- package/dist/C_City-DdkX6u64.css.map +0 -1
- package/dist/C_City-iP-dIvui.css.map +0 -1
- package/dist/C_City.js.map +0 -1
- package/dist/C_City2.js.map +0 -1
- package/dist/C_Code-BWmJMNS7.css.map +0 -1
- package/dist/C_Code-k14vjgVl.css.map +0 -1
- package/dist/C_Code.js.map +0 -1
- package/dist/C_Code2.js.map +0 -1
- package/dist/C_CollapsePanel-BSKcWSmY.css.map +0 -1
- package/dist/C_CollapsePanel-DRvRq8tB.css.map +0 -1
- package/dist/C_CollapsePanel.js.map +0 -1
- package/dist/C_CollapsePanel2.js.map +0 -1
- package/dist/C_ContextMenu-C9iuxG2n.css.map +0 -1
- package/dist/C_ContextMenu-CD0iaSju.css.map +0 -1
- package/dist/C_ContextMenu.js.map +0 -1
- package/dist/C_ContextMenu2.js.map +0 -1
- package/dist/C_Cron-BIQ2By9v.css.map +0 -1
- package/dist/C_Cron-BNSAGD6A.css.map +0 -1
- package/dist/C_Cron.js.map +0 -1
- package/dist/C_Cron2.js.map +0 -1
- package/dist/C_Date.js.map +0 -1
- package/dist/C_Date2.js.map +0 -1
- package/dist/C_Draggable-BDAbk4s5.css.map +0 -1
- package/dist/C_Draggable-UhfDLXop.css.map +0 -1
- package/dist/C_Draggable.js.map +0 -1
- package/dist/C_Draggable2.js.map +0 -1
- package/dist/C_Editor-CZOaChru.css.map +0 -1
- package/dist/C_Editor-kJAQq5z6.css.map +0 -1
- package/dist/C_Editor.js.map +0 -1
- package/dist/C_Editor2.js.map +0 -1
- package/dist/C_FilePreview-Bs_omgJS.css.map +0 -1
- package/dist/C_FilePreview-DbwoyF2j.css.map +0 -1
- package/dist/C_FilePreview.js.map +0 -1
- package/dist/C_FilePreview2.js.map +0 -1
- package/dist/C_Form-B_2ql62V.css.map +0 -1
- package/dist/C_Form-CX-7xsz3.css.map +0 -1
- package/dist/C_Form.js.map +0 -1
- package/dist/C_Form2.js.map +0 -1
- package/dist/C_FormSearch-C3F8peAY.css.map +0 -1
- package/dist/C_FormSearch-qW56bJPo.css.map +0 -1
- package/dist/C_FormSearch.js.map +0 -1
- package/dist/C_FormSearch2.js.map +0 -1
- package/dist/C_FormulaEditor-ChOvDbsZ.css.map +0 -1
- package/dist/C_FormulaEditor-mfiIUDY4.css.map +0 -1
- package/dist/C_FormulaEditor.js.map +0 -1
- package/dist/C_FormulaEditor2.js.map +0 -1
- package/dist/C_FullCalendar-C2nsqrgS.css.map +0 -1
- package/dist/C_FullCalendar-DdFtXVhy.css.map +0 -1
- package/dist/C_FullCalendar.js.map +0 -1
- package/dist/C_FullCalendar2.js.map +0 -1
- package/dist/C_GlobalSearch-Dq4Wo01K.css.map +0 -1
- package/dist/C_GlobalSearch-RB7J43gu.css.map +0 -1
- package/dist/C_GlobalSearch.js.map +0 -1
- package/dist/C_GlobalSearch2.js.map +0 -1
- package/dist/C_Guide.js.map +0 -1
- package/dist/C_Guide2.js.map +0 -1
- package/dist/C_Icon.js.map +0 -1
- package/dist/C_Icon2.js.map +0 -1
- package/dist/C_ImageCropper-CdTX2nxU.css.map +0 -1
- package/dist/C_ImageCropper-ilOqPklJ.css.map +0 -1
- package/dist/C_ImageCropper.js.map +0 -1
- package/dist/C_ImageCropper2.js.map +0 -1
- package/dist/C_Language.js.map +0 -1
- package/dist/C_Language2.js.map +0 -1
- package/dist/C_Login-BrQBs_m4.css.map +0 -1
- package/dist/C_Login-xMI1_ojE.css.map +0 -1
- package/dist/C_Login.js.map +0 -1
- package/dist/C_Login2.js.map +0 -1
- package/dist/C_Map-CWMMN58_.css.map +0 -1
- package/dist/C_Map-xSR2H-9o.css.map +0 -1
- package/dist/C_Map.js.map +0 -1
- package/dist/C_Map2.js.map +0 -1
- package/dist/C_Markdown-C7lTVJ1S.css.map +0 -1
- package/dist/C_Markdown-CZDm_baQ.css.map +0 -1
- package/dist/C_Markdown.js.map +0 -1
- package/dist/C_Markdown2.js.map +0 -1
- package/dist/C_Menu.js.map +0 -1
- package/dist/C_Menu2.js.map +0 -1
- package/dist/C_NotificationCenter-D7GGGWg7.css.map +0 -1
- package/dist/C_NotificationCenter-SSmeHA45.css.map +0 -1
- package/dist/C_NotificationCenter.js.map +0 -1
- package/dist/C_NotificationCenter2.js.map +0 -1
- package/dist/C_OrgChart-BXEp4i4w.css.map +0 -1
- package/dist/C_OrgChart-DqBufOv5.css.map +0 -1
- package/dist/C_OrgChart.js.map +0 -1
- package/dist/C_OrgChart2.js.map +0 -1
- package/dist/C_Progress.js.map +0 -1
- package/dist/C_Progress2.js.map +0 -1
- package/dist/C_QRCode-B_1lHUdx.css.map +0 -1
- package/dist/C_QRCode-CuQRYu0s.css.map +0 -1
- package/dist/C_QRCode.js.map +0 -1
- package/dist/C_QRCode2.js.map +0 -1
- package/dist/C_Signature-Bp-RBpAl.css.map +0 -1
- package/dist/C_Signature-Cb2VW1ok.css.map +0 -1
- package/dist/C_Signature.js.map +0 -1
- package/dist/C_Signature2.js.map +0 -1
- package/dist/C_Skeleton-BJoFYwrF.css.map +0 -1
- package/dist/C_Skeleton-Djsjw8XY.css.map +0 -1
- package/dist/C_Skeleton.js.map +0 -1
- package/dist/C_Skeleton2.js.map +0 -1
- package/dist/C_SplitPane-CgGWYsRE.css.map +0 -1
- package/dist/C_SplitPane-DGf6WEeR.css.map +0 -1
- package/dist/C_SplitPane.js.map +0 -1
- package/dist/C_SplitPane2.js.map +0 -1
- package/dist/C_Steps-27Exh7PM.css.map +0 -1
- package/dist/C_Steps-DU9ZsFrs.css.map +0 -1
- package/dist/C_Steps.js.map +0 -1
- package/dist/C_Steps2.js.map +0 -1
- package/dist/C_Table--kbQaaBv.css.map +0 -1
- package/dist/C_Table-D631kdXC.css.map +0 -1
- package/dist/C_Table.js.map +0 -1
- package/dist/C_Table2.js +0 -4
- package/dist/C_Table2.js.map +0 -1
- package/dist/C_TagsView-DtGtYhBH.css.map +0 -1
- package/dist/C_TagsView-s1dnSJAV.css.map +0 -1
- package/dist/C_TagsView.js.map +0 -1
- package/dist/C_TagsView2.js.map +0 -1
- package/dist/C_Theme.js.map +0 -1
- package/dist/C_Theme2.js.map +0 -1
- package/dist/C_Time-BQ9PGy8B.css.map +0 -1
- package/dist/C_Time-CO73krC6.css.map +0 -1
- package/dist/C_Time.js.map +0 -1
- package/dist/C_Time2.js.map +0 -1
- package/dist/C_Timeline-DdESmqwL.css.map +0 -1
- package/dist/C_Timeline-irQcO-b7.css.map +0 -1
- package/dist/C_Timeline.js.map +0 -1
- package/dist/C_Timeline2.js.map +0 -1
- package/dist/C_Transfer-11y3k-WD.css.map +0 -1
- package/dist/C_Transfer-EzdHzZNv.css.map +0 -1
- package/dist/C_Transfer.js.map +0 -1
- package/dist/C_Transfer2.js.map +0 -1
- package/dist/C_Tree-CsXgGfhn.css.map +0 -1
- package/dist/C_Tree-P7eRpnOa.css.map +0 -1
- package/dist/C_Tree.js.map +0 -1
- package/dist/C_Tree2.js.map +0 -1
- package/dist/C_Upload-CHjiVVh7.css.map +0 -1
- package/dist/C_Upload-DE3OLsZD.css.map +0 -1
- package/dist/C_Upload.js.map +0 -1
- package/dist/C_Upload2.js.map +0 -1
- package/dist/C_VideoPlayer-CnaNOFtW.css.map +0 -1
- package/dist/C_VideoPlayer-cnP88zNV.css.map +0 -1
- package/dist/C_VideoPlayer.js.map +0 -1
- package/dist/C_VideoPlayer2.js.map +0 -1
- package/dist/C_VtableGantt-CZlJgvpC.css.map +0 -1
- package/dist/C_VtableGantt-DKfQkql0.css.map +0 -1
- package/dist/C_VtableGantt.js.map +0 -1
- package/dist/C_VtableGantt2.js.map +0 -1
- package/dist/C_WaterFall-BJ_39ext.css.map +0 -1
- package/dist/C_WaterFall-cYc1vntE.css.map +0 -1
- package/dist/C_WaterFall.js.map +0 -1
- package/dist/C_WaterFall2.js.map +0 -1
- package/dist/C_WorkFlow-BFzRGGhJ.css.map +0 -1
- package/dist/C_WorkFlow-DSyCOvRp.css.map +0 -1
- package/dist/C_WorkFlow.js.map +0 -1
- package/dist/C_WorkFlow2.js.map +0 -1
- package/dist/city.js.map +0 -1
- package/dist/index.cjs.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/index2.d.ts +0 -120
- package/dist/resolver.cjs.map +0 -1
- package/dist/resolver.js.map +0 -1
- package/dist/storage.js.map +0 -1
- /package/dist/{chunk.js → chunk.cjs} +0 -0
|
@@ -0,0 +1,479 @@
|
|
|
1
|
+
import * as vue from "vue";
|
|
2
|
+
|
|
3
|
+
//#region src/components/C_NotificationCenter/types.d.ts
|
|
4
|
+
/** 消息类别 */
|
|
5
|
+
type NotificationCategory = 'system' | 'business' | 'alarm';
|
|
6
|
+
/** 消息优先级 */
|
|
7
|
+
type NotificationPriority = 'low' | 'normal' | 'high' | 'urgent';
|
|
8
|
+
/** 消息状态 */
|
|
9
|
+
type NotificationStatus = 'unread' | 'read' | 'archived';
|
|
10
|
+
/** 单条通知消息 */
|
|
11
|
+
interface NotificationMessage {
|
|
12
|
+
/** 消息唯一 ID */
|
|
13
|
+
id: string;
|
|
14
|
+
/** 消息标题 */
|
|
15
|
+
title: string;
|
|
16
|
+
/** 消息摘要(列表中展示) */
|
|
17
|
+
summary: string;
|
|
18
|
+
/** 消息详情(富文本 / 纯文本) */
|
|
19
|
+
content?: string;
|
|
20
|
+
/** 消息类别 */
|
|
21
|
+
category: NotificationCategory;
|
|
22
|
+
/** 优先级 */
|
|
23
|
+
priority: NotificationPriority;
|
|
24
|
+
/** 消息状态 */
|
|
25
|
+
status: NotificationStatus;
|
|
26
|
+
/** 发送时间(ISO 8601) */
|
|
27
|
+
timestamp: string;
|
|
28
|
+
/** 发送者信息 */
|
|
29
|
+
sender?: NotificationSender;
|
|
30
|
+
/** 关联操作链接 */
|
|
31
|
+
actionUrl?: string;
|
|
32
|
+
/** 关联操作按钮文本 */
|
|
33
|
+
actionText?: string;
|
|
34
|
+
/** 附加数据(业务扩展) */
|
|
35
|
+
extra?: Record<string, unknown>;
|
|
36
|
+
}
|
|
37
|
+
/** 发送者信息 */
|
|
38
|
+
interface NotificationSender {
|
|
39
|
+
/** 发送者名称 */
|
|
40
|
+
name: string;
|
|
41
|
+
/** 发送者头像 URL */
|
|
42
|
+
avatar?: string;
|
|
43
|
+
}
|
|
44
|
+
/** 拉取消息列表函数 */
|
|
45
|
+
type FetchNotificationsFn = (params: {
|
|
46
|
+
category?: NotificationCategory;
|
|
47
|
+
status?: NotificationStatus;
|
|
48
|
+
page?: number;
|
|
49
|
+
pageSize?: number;
|
|
50
|
+
}) => Promise<{
|
|
51
|
+
list: NotificationMessage[];
|
|
52
|
+
total: number;
|
|
53
|
+
unreadCount: number;
|
|
54
|
+
}>;
|
|
55
|
+
/** 标记已读函数 */
|
|
56
|
+
type MarkAsReadFn = (ids: string[]) => Promise<void>;
|
|
57
|
+
/** 标记全部已读函数 */
|
|
58
|
+
type MarkAllReadFn = (category?: NotificationCategory) => Promise<void>;
|
|
59
|
+
/** 删除消息函数 */
|
|
60
|
+
type DeleteNotificationFn = (ids: string[]) => Promise<void>;
|
|
61
|
+
/** 清空消息函数 */
|
|
62
|
+
type ClearNotificationsFn = (category?: NotificationCategory) => Promise<void>;
|
|
63
|
+
/** WebSocket 配置 */
|
|
64
|
+
interface NotificationWSConfig {
|
|
65
|
+
/** WebSocket 地址(ws:// 或 wss://) */
|
|
66
|
+
url: string;
|
|
67
|
+
/** 自动重连 */
|
|
68
|
+
autoReconnect?: boolean;
|
|
69
|
+
/** 重连间隔(ms) */
|
|
70
|
+
reconnectInterval?: number;
|
|
71
|
+
/** 最大重连次数 */
|
|
72
|
+
maxReconnectAttempts?: number;
|
|
73
|
+
/** 心跳间隔(ms),0 表示不发心跳 */
|
|
74
|
+
heartbeatInterval?: number;
|
|
75
|
+
/** 心跳消息内容 */
|
|
76
|
+
heartbeatMessage?: string;
|
|
77
|
+
/** 鉴权 token 获取函数 */
|
|
78
|
+
getToken?: () => string | undefined;
|
|
79
|
+
}
|
|
80
|
+
/** WebSocket 连接状态 */
|
|
81
|
+
type WSConnectionStatus = 'connecting' | 'connected' | 'disconnected' | 'reconnecting';
|
|
82
|
+
/** WebSocket 推送消息负载 */
|
|
83
|
+
interface WSNotificationPayload {
|
|
84
|
+
/** 事件类型 */
|
|
85
|
+
type: 'new_message' | 'read_sync' | 'count_update';
|
|
86
|
+
/** 推送的消息数据 */
|
|
87
|
+
data: NotificationMessage | NotificationMessage[] | {
|
|
88
|
+
unreadCount: number;
|
|
89
|
+
};
|
|
90
|
+
}
|
|
91
|
+
/** 组件 Props */
|
|
92
|
+
interface NotificationCenterProps {
|
|
93
|
+
/** 拉取消息列表 */
|
|
94
|
+
fetchNotifications?: FetchNotificationsFn;
|
|
95
|
+
/** 标记已读 */
|
|
96
|
+
markAsRead?: MarkAsReadFn;
|
|
97
|
+
/** 标记全部已读 */
|
|
98
|
+
markAllRead?: MarkAllReadFn;
|
|
99
|
+
/** 删除消息 */
|
|
100
|
+
deleteNotification?: DeleteNotificationFn;
|
|
101
|
+
/** 清空消息 */
|
|
102
|
+
clearNotifications?: ClearNotificationsFn;
|
|
103
|
+
/** WebSocket 配置 */
|
|
104
|
+
wsConfig?: NotificationWSConfig;
|
|
105
|
+
/** 是否启用桌面通知 */
|
|
106
|
+
desktopNotification?: boolean;
|
|
107
|
+
/** 角标最大显示数 */
|
|
108
|
+
maxBadgeCount?: number;
|
|
109
|
+
/** 自动轮询间隔(ms),0 表示不轮询 */
|
|
110
|
+
pollingInterval?: number;
|
|
111
|
+
/** 每页条数 */
|
|
112
|
+
pageSize?: number;
|
|
113
|
+
/** 消息持久化缓存 key */
|
|
114
|
+
storageKey?: string;
|
|
115
|
+
/** 异步操作失败回调 */
|
|
116
|
+
onError?: (error: unknown, operation: string) => void;
|
|
117
|
+
}
|
|
118
|
+
/** 组件 Emits */
|
|
119
|
+
interface NotificationCenterEmits {
|
|
120
|
+
/** 点击消息 */
|
|
121
|
+
itemClick: [message: NotificationMessage];
|
|
122
|
+
/** 消息已读 */
|
|
123
|
+
read: [ids: string[]];
|
|
124
|
+
/** 全部已读 */
|
|
125
|
+
allRead: [category?: NotificationCategory];
|
|
126
|
+
/** 删除消息 */
|
|
127
|
+
delete: [ids: string[]];
|
|
128
|
+
/** 未读数变化 */
|
|
129
|
+
unreadChange: [count: number];
|
|
130
|
+
/** WebSocket 连接状态变化 */
|
|
131
|
+
wsStatusChange: [status: WSConnectionStatus];
|
|
132
|
+
/** 收到新消息 */
|
|
133
|
+
newMessage: [message: NotificationMessage];
|
|
134
|
+
}
|
|
135
|
+
/** 组件 Expose */
|
|
136
|
+
interface NotificationCenterExpose {
|
|
137
|
+
/** 刷新消息列表 */
|
|
138
|
+
refresh: () => Promise<void>;
|
|
139
|
+
/** 手动连接 WebSocket */
|
|
140
|
+
connectWS: () => void;
|
|
141
|
+
/** 手动断开 WebSocket */
|
|
142
|
+
disconnectWS: () => void;
|
|
143
|
+
/** 获取未读数 */
|
|
144
|
+
getUnreadCount: () => number;
|
|
145
|
+
/** 获取当前消息列表 */
|
|
146
|
+
getMessages: () => NotificationMessage[];
|
|
147
|
+
/** 手动标记已读 */
|
|
148
|
+
markRead: (ids: string[]) => Promise<void>;
|
|
149
|
+
/** 手动标记全部已读 */
|
|
150
|
+
markAllAsRead: (category?: NotificationCategory) => Promise<void>;
|
|
151
|
+
/** 由用户手势主动申请桌面通知权限 */
|
|
152
|
+
requestDesktopPermission: () => Promise<NotificationPermission | 'unsupported'>;
|
|
153
|
+
}
|
|
154
|
+
//#endregion
|
|
155
|
+
//#region src/components/C_NotificationCenter/index.vue.d.ts
|
|
156
|
+
declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, NotificationCenterExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
157
|
+
itemClick: (message: NotificationMessage) => any;
|
|
158
|
+
delete: (ids: string[]) => any;
|
|
159
|
+
read: (ids: string[]) => any;
|
|
160
|
+
allRead: (category?: NotificationCategory | undefined) => any;
|
|
161
|
+
unreadChange: (count: number) => any;
|
|
162
|
+
wsStatusChange: (status: string) => any;
|
|
163
|
+
newMessage: (message: NotificationMessage) => any;
|
|
164
|
+
navigate: (url: string) => any;
|
|
165
|
+
}, string, vue.PublicProps, Readonly<NotificationCenterProps> & Readonly<{
|
|
166
|
+
onItemClick?: ((message: NotificationMessage) => any) | undefined;
|
|
167
|
+
onDelete?: ((ids: string[]) => any) | undefined;
|
|
168
|
+
onRead?: ((ids: string[]) => any) | undefined;
|
|
169
|
+
onAllRead?: ((category?: NotificationCategory | undefined) => any) | undefined;
|
|
170
|
+
onUnreadChange?: ((count: number) => any) | undefined;
|
|
171
|
+
onWsStatusChange?: ((status: string) => any) | undefined;
|
|
172
|
+
onNewMessage?: ((message: NotificationMessage) => any) | undefined;
|
|
173
|
+
onNavigate?: ((url: string) => any) | undefined;
|
|
174
|
+
}>, {
|
|
175
|
+
storageKey: string;
|
|
176
|
+
pageSize: number;
|
|
177
|
+
desktopNotification: boolean;
|
|
178
|
+
maxBadgeCount: number;
|
|
179
|
+
pollingInterval: number;
|
|
180
|
+
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
181
|
+
declare const _default: typeof __VLS_export;
|
|
182
|
+
//#endregion
|
|
183
|
+
//#region src/components/C_NotificationCenter/composables/useNotificationCore.d.ts
|
|
184
|
+
/**
|
|
185
|
+
* 通知中心核心状态管理
|
|
186
|
+
*
|
|
187
|
+
* 统一管理消息列表、未读数、分类过滤、已读标记、
|
|
188
|
+
* API 交互、WebSocket 桥接、轮询调度和本地缓存。
|
|
189
|
+
*/
|
|
190
|
+
declare function useNotificationCore(props: NotificationCenterProps): {
|
|
191
|
+
messages: vue.Ref<{
|
|
192
|
+
id: string;
|
|
193
|
+
title: string;
|
|
194
|
+
summary: string;
|
|
195
|
+
content?: string | undefined;
|
|
196
|
+
category: NotificationCategory;
|
|
197
|
+
priority: NotificationPriority;
|
|
198
|
+
status: NotificationStatus;
|
|
199
|
+
timestamp: string;
|
|
200
|
+
sender?: {
|
|
201
|
+
name: string;
|
|
202
|
+
avatar?: string | undefined;
|
|
203
|
+
} | undefined;
|
|
204
|
+
actionUrl?: string | undefined;
|
|
205
|
+
actionText?: string | undefined;
|
|
206
|
+
extra?: Record<string, unknown> | undefined;
|
|
207
|
+
}[], NotificationMessage[] | {
|
|
208
|
+
id: string;
|
|
209
|
+
title: string;
|
|
210
|
+
summary: string;
|
|
211
|
+
content?: string | undefined;
|
|
212
|
+
category: NotificationCategory;
|
|
213
|
+
priority: NotificationPriority;
|
|
214
|
+
status: NotificationStatus;
|
|
215
|
+
timestamp: string;
|
|
216
|
+
sender?: {
|
|
217
|
+
name: string;
|
|
218
|
+
avatar?: string | undefined;
|
|
219
|
+
} | undefined;
|
|
220
|
+
actionUrl?: string | undefined;
|
|
221
|
+
actionText?: string | undefined;
|
|
222
|
+
extra?: Record<string, unknown> | undefined;
|
|
223
|
+
}[]>;
|
|
224
|
+
activeCategory: vue.Ref<NotificationCategory | "all", NotificationCategory | "all">;
|
|
225
|
+
loading: vue.Ref<boolean, boolean>;
|
|
226
|
+
total: vue.Ref<number, number>;
|
|
227
|
+
page: vue.Ref<number, number>;
|
|
228
|
+
selectedMessage: vue.Ref<{
|
|
229
|
+
id: string;
|
|
230
|
+
title: string;
|
|
231
|
+
summary: string;
|
|
232
|
+
content?: string | undefined;
|
|
233
|
+
category: NotificationCategory;
|
|
234
|
+
priority: NotificationPriority;
|
|
235
|
+
status: NotificationStatus;
|
|
236
|
+
timestamp: string;
|
|
237
|
+
sender?: {
|
|
238
|
+
name: string;
|
|
239
|
+
avatar?: string | undefined;
|
|
240
|
+
} | undefined;
|
|
241
|
+
actionUrl?: string | undefined;
|
|
242
|
+
actionText?: string | undefined;
|
|
243
|
+
extra?: Record<string, unknown> | undefined;
|
|
244
|
+
} | null, NotificationMessage | {
|
|
245
|
+
id: string;
|
|
246
|
+
title: string;
|
|
247
|
+
summary: string;
|
|
248
|
+
content?: string | undefined;
|
|
249
|
+
category: NotificationCategory;
|
|
250
|
+
priority: NotificationPriority;
|
|
251
|
+
status: NotificationStatus;
|
|
252
|
+
timestamp: string;
|
|
253
|
+
sender?: {
|
|
254
|
+
name: string;
|
|
255
|
+
avatar?: string | undefined;
|
|
256
|
+
} | undefined;
|
|
257
|
+
actionUrl?: string | undefined;
|
|
258
|
+
actionText?: string | undefined;
|
|
259
|
+
extra?: Record<string, unknown> | undefined;
|
|
260
|
+
} | null>;
|
|
261
|
+
popoverVisible: vue.Ref<boolean, boolean>;
|
|
262
|
+
wsStatus: vue.Ref<WSConnectionStatus, WSConnectionStatus>;
|
|
263
|
+
unreadCount: vue.ComputedRef<number>;
|
|
264
|
+
unreadByCategory: vue.ComputedRef<Record<string, number>>;
|
|
265
|
+
filteredMessages: vue.ComputedRef<{
|
|
266
|
+
id: string;
|
|
267
|
+
title: string;
|
|
268
|
+
summary: string;
|
|
269
|
+
content?: string | undefined;
|
|
270
|
+
category: NotificationCategory;
|
|
271
|
+
priority: NotificationPriority;
|
|
272
|
+
status: NotificationStatus;
|
|
273
|
+
timestamp: string;
|
|
274
|
+
sender?: {
|
|
275
|
+
name: string;
|
|
276
|
+
avatar?: string | undefined;
|
|
277
|
+
} | undefined;
|
|
278
|
+
actionUrl?: string | undefined;
|
|
279
|
+
actionText?: string | undefined;
|
|
280
|
+
extra?: Record<string, unknown> | undefined;
|
|
281
|
+
}[]>;
|
|
282
|
+
hasMore: vue.ComputedRef<boolean>;
|
|
283
|
+
fetchMessages: (reset?: boolean) => Promise<void>;
|
|
284
|
+
loadMore: () => Promise<void>;
|
|
285
|
+
markAsRead: (ids: string[]) => Promise<void>;
|
|
286
|
+
markAllAsRead: (category?: NotificationCategory) => Promise<void>;
|
|
287
|
+
deleteMessages: (ids: string[]) => Promise<void>;
|
|
288
|
+
clearMessages: (category?: NotificationCategory) => Promise<void>;
|
|
289
|
+
selectMessage: (msg: NotificationMessage) => void;
|
|
290
|
+
clearSelection: () => void;
|
|
291
|
+
switchCategory: (category: NotificationCategory | "all") => void;
|
|
292
|
+
requestDesktopPermission: () => Promise<NotificationPermission | "unsupported">;
|
|
293
|
+
connectWS: (config: NotificationWSConfig) => void;
|
|
294
|
+
disconnectWS: () => void;
|
|
295
|
+
};
|
|
296
|
+
//#endregion
|
|
297
|
+
//#region src/components/C_NotificationCenter/composables/useNotificationFormat.d.ts
|
|
298
|
+
/**
|
|
299
|
+
* 通知时间格式化(单例)
|
|
300
|
+
*
|
|
301
|
+
* 将 ISO 时间戳格式化为人类友好的相对时间描述,
|
|
302
|
+
* 如 "刚刚"、"5分钟前"、"昨天 14:30" 等。
|
|
303
|
+
*/
|
|
304
|
+
declare function useNotificationFormat(): {
|
|
305
|
+
formatRelativeTime: (timestamp: string) => string;
|
|
306
|
+
formatFullDate: (date: Date) => string;
|
|
307
|
+
};
|
|
308
|
+
//#endregion
|
|
309
|
+
//#region src/components/C_NotificationCenter/composables/useNotificationWS.d.ts
|
|
310
|
+
/**
|
|
311
|
+
* WebSocket 连接管理
|
|
312
|
+
*
|
|
313
|
+
* 管理 WebSocket 的建连、重连、心跳保活、消息解析。
|
|
314
|
+
* 支持自动重连、鉴权 token、心跳检测。
|
|
315
|
+
*/
|
|
316
|
+
declare function useNotificationWS(onMessage: (payload: WSNotificationPayload) => void, onStatusChange?: (status: WSConnectionStatus) => void): {
|
|
317
|
+
/** WebSocket 连接状态 */status: Readonly<vue.Ref<WSConnectionStatus, WSConnectionStatus>>;
|
|
318
|
+
connect: (config: NotificationWSConfig) => void;
|
|
319
|
+
disconnect: () => void;
|
|
320
|
+
reconnect: () => void;
|
|
321
|
+
};
|
|
322
|
+
//#endregion
|
|
323
|
+
//#region src/components/C_NotificationCenter/constants.d.ts
|
|
324
|
+
/** 默认角标最大显示数 */
|
|
325
|
+
declare const DEFAULT_MAX_BADGE_COUNT = 99;
|
|
326
|
+
/** 默认每页条数 */
|
|
327
|
+
declare const DEFAULT_PAGE_SIZE = 20;
|
|
328
|
+
/** 默认轮询间隔(ms):60 秒 */
|
|
329
|
+
declare const DEFAULT_POLLING_INTERVAL = 60000;
|
|
330
|
+
/** 默认缓存 key */
|
|
331
|
+
declare const DEFAULT_STORAGE_KEY = "notification_center";
|
|
332
|
+
/** WebSocket 默认重连间隔(ms) */
|
|
333
|
+
declare const DEFAULT_WS_RECONNECT_INTERVAL = 3000;
|
|
334
|
+
/** WebSocket 默认最大重连次数 */
|
|
335
|
+
declare const DEFAULT_WS_MAX_RECONNECT = 5;
|
|
336
|
+
/** WebSocket 默认心跳间隔(ms) */
|
|
337
|
+
declare const DEFAULT_WS_HEARTBEAT_INTERVAL = 30000;
|
|
338
|
+
/** WebSocket 默认心跳消息 */
|
|
339
|
+
declare const DEFAULT_WS_HEARTBEAT_MESSAGE = "ping";
|
|
340
|
+
/** 分类标签映射 */
|
|
341
|
+
declare const CATEGORY_MAP: Record<NotificationCategory, {
|
|
342
|
+
label: string;
|
|
343
|
+
icon: string;
|
|
344
|
+
color: string;
|
|
345
|
+
}>;
|
|
346
|
+
/** 分类 Tab 列表 */
|
|
347
|
+
declare const CATEGORY_TABS: {
|
|
348
|
+
key: NotificationCategory | 'all';
|
|
349
|
+
label: string;
|
|
350
|
+
}[];
|
|
351
|
+
/** 优先级标签映射 */
|
|
352
|
+
declare const PRIORITY_MAP: Record<NotificationPriority, {
|
|
353
|
+
label: string;
|
|
354
|
+
type: 'default' | 'info' | 'success' | 'warning' | 'error';
|
|
355
|
+
}>;
|
|
356
|
+
/** 模拟消息列表 */
|
|
357
|
+
declare const MOCK_MESSAGES: ({
|
|
358
|
+
id: string;
|
|
359
|
+
title: string;
|
|
360
|
+
summary: string;
|
|
361
|
+
content: string;
|
|
362
|
+
category: "system";
|
|
363
|
+
priority: "high";
|
|
364
|
+
status: "unread";
|
|
365
|
+
timestamp: string;
|
|
366
|
+
sender: {
|
|
367
|
+
name: string;
|
|
368
|
+
avatar: string;
|
|
369
|
+
};
|
|
370
|
+
actionUrl?: undefined;
|
|
371
|
+
actionText?: undefined;
|
|
372
|
+
} | {
|
|
373
|
+
id: string;
|
|
374
|
+
title: string;
|
|
375
|
+
summary: string;
|
|
376
|
+
category: "business";
|
|
377
|
+
priority: "urgent";
|
|
378
|
+
status: "unread";
|
|
379
|
+
timestamp: string;
|
|
380
|
+
sender: {
|
|
381
|
+
name: string;
|
|
382
|
+
avatar: string;
|
|
383
|
+
};
|
|
384
|
+
actionUrl: string;
|
|
385
|
+
actionText: string;
|
|
386
|
+
content?: undefined;
|
|
387
|
+
} | {
|
|
388
|
+
id: string;
|
|
389
|
+
title: string;
|
|
390
|
+
summary: string;
|
|
391
|
+
category: "alarm";
|
|
392
|
+
priority: "urgent";
|
|
393
|
+
status: "unread";
|
|
394
|
+
timestamp: string;
|
|
395
|
+
sender: {
|
|
396
|
+
name: string;
|
|
397
|
+
avatar?: undefined;
|
|
398
|
+
};
|
|
399
|
+
actionUrl: string;
|
|
400
|
+
actionText: string;
|
|
401
|
+
content?: undefined;
|
|
402
|
+
} | {
|
|
403
|
+
id: string;
|
|
404
|
+
title: string;
|
|
405
|
+
summary: string;
|
|
406
|
+
category: "system";
|
|
407
|
+
priority: "normal";
|
|
408
|
+
status: "unread";
|
|
409
|
+
timestamp: string;
|
|
410
|
+
sender: {
|
|
411
|
+
name: string;
|
|
412
|
+
avatar?: undefined;
|
|
413
|
+
};
|
|
414
|
+
content?: undefined;
|
|
415
|
+
actionUrl?: undefined;
|
|
416
|
+
actionText?: undefined;
|
|
417
|
+
} | {
|
|
418
|
+
id: string;
|
|
419
|
+
title: string;
|
|
420
|
+
summary: string;
|
|
421
|
+
category: "business";
|
|
422
|
+
priority: "high";
|
|
423
|
+
status: "read";
|
|
424
|
+
timestamp: string;
|
|
425
|
+
sender: {
|
|
426
|
+
name: string;
|
|
427
|
+
avatar?: undefined;
|
|
428
|
+
};
|
|
429
|
+
content?: undefined;
|
|
430
|
+
actionUrl?: undefined;
|
|
431
|
+
actionText?: undefined;
|
|
432
|
+
} | {
|
|
433
|
+
id: string;
|
|
434
|
+
title: string;
|
|
435
|
+
summary: string;
|
|
436
|
+
category: "alarm";
|
|
437
|
+
priority: "high";
|
|
438
|
+
status: "read";
|
|
439
|
+
timestamp: string;
|
|
440
|
+
sender: {
|
|
441
|
+
name: string;
|
|
442
|
+
avatar?: undefined;
|
|
443
|
+
};
|
|
444
|
+
content?: undefined;
|
|
445
|
+
actionUrl?: undefined;
|
|
446
|
+
actionText?: undefined;
|
|
447
|
+
} | {
|
|
448
|
+
id: string;
|
|
449
|
+
title: string;
|
|
450
|
+
summary: string;
|
|
451
|
+
category: "business";
|
|
452
|
+
priority: "normal";
|
|
453
|
+
status: "read";
|
|
454
|
+
timestamp: string;
|
|
455
|
+
sender: {
|
|
456
|
+
name: string;
|
|
457
|
+
avatar?: undefined;
|
|
458
|
+
};
|
|
459
|
+
content?: undefined;
|
|
460
|
+
actionUrl?: undefined;
|
|
461
|
+
actionText?: undefined;
|
|
462
|
+
} | {
|
|
463
|
+
id: string;
|
|
464
|
+
title: string;
|
|
465
|
+
summary: string;
|
|
466
|
+
category: "system";
|
|
467
|
+
priority: "high";
|
|
468
|
+
status: "unread";
|
|
469
|
+
timestamp: string;
|
|
470
|
+
sender: {
|
|
471
|
+
name: string;
|
|
472
|
+
avatar?: undefined;
|
|
473
|
+
};
|
|
474
|
+
content?: undefined;
|
|
475
|
+
actionUrl?: undefined;
|
|
476
|
+
actionText?: undefined;
|
|
477
|
+
})[];
|
|
478
|
+
//#endregion
|
|
479
|
+
export { NotificationWSConfig as A, NotificationCenterEmits as C, NotificationPriority as D, NotificationMessage as E, WSNotificationPayload as M, NotificationSender as O, NotificationCategory as S, NotificationCenterProps as T, ClearNotificationsFn as _, DEFAULT_POLLING_INTERVAL as a, MarkAllReadFn as b, DEFAULT_WS_HEARTBEAT_MESSAGE as c, MOCK_MESSAGES as d, PRIORITY_MAP as f, _default as g, useNotificationCore as h, DEFAULT_PAGE_SIZE as i, WSConnectionStatus as j, NotificationStatus as k, DEFAULT_WS_MAX_RECONNECT as l, useNotificationFormat as m, CATEGORY_TABS as n, DEFAULT_STORAGE_KEY as o, useNotificationWS as p, DEFAULT_MAX_BADGE_COUNT as r, DEFAULT_WS_HEARTBEAT_INTERVAL as s, CATEGORY_MAP as t, DEFAULT_WS_RECONNECT_INTERVAL as u, DeleteNotificationFn as v, NotificationCenterExpose as w, MarkAsReadFn as x, FetchNotificationsFn as y };
|
package/dist/constants3.d.ts
CHANGED
|
@@ -2,11 +2,11 @@ import * as vue from "vue";
|
|
|
2
2
|
|
|
3
3
|
//#region src/components/C_NotificationCenter/types.d.ts
|
|
4
4
|
/** 消息类别 */
|
|
5
|
-
type NotificationCategory =
|
|
5
|
+
type NotificationCategory = 'system' | 'business' | 'alarm';
|
|
6
6
|
/** 消息优先级 */
|
|
7
|
-
type NotificationPriority =
|
|
7
|
+
type NotificationPriority = 'low' | 'normal' | 'high' | 'urgent';
|
|
8
8
|
/** 消息状态 */
|
|
9
|
-
type NotificationStatus =
|
|
9
|
+
type NotificationStatus = 'unread' | 'read' | 'archived';
|
|
10
10
|
/** 单条通知消息 */
|
|
11
11
|
interface NotificationMessage {
|
|
12
12
|
/** 消息唯一 ID */
|
|
@@ -78,11 +78,11 @@ interface NotificationWSConfig {
|
|
|
78
78
|
getToken?: () => string | undefined;
|
|
79
79
|
}
|
|
80
80
|
/** WebSocket 连接状态 */
|
|
81
|
-
type WSConnectionStatus =
|
|
81
|
+
type WSConnectionStatus = 'connecting' | 'connected' | 'disconnected' | 'reconnecting';
|
|
82
82
|
/** WebSocket 推送消息负载 */
|
|
83
83
|
interface WSNotificationPayload {
|
|
84
84
|
/** 事件类型 */
|
|
85
|
-
type:
|
|
85
|
+
type: 'new_message' | 'read_sync' | 'count_update';
|
|
86
86
|
/** 推送的消息数据 */
|
|
87
87
|
data: NotificationMessage | NotificationMessage[] | {
|
|
88
88
|
unreadCount: number;
|
|
@@ -112,6 +112,8 @@ interface NotificationCenterProps {
|
|
|
112
112
|
pageSize?: number;
|
|
113
113
|
/** 消息持久化缓存 key */
|
|
114
114
|
storageKey?: string;
|
|
115
|
+
/** 异步操作失败回调 */
|
|
116
|
+
onError?: (error: unknown, operation: string) => void;
|
|
115
117
|
}
|
|
116
118
|
/** 组件 Emits */
|
|
117
119
|
interface NotificationCenterEmits {
|
|
@@ -146,12 +148,14 @@ interface NotificationCenterExpose {
|
|
|
146
148
|
markRead: (ids: string[]) => Promise<void>;
|
|
147
149
|
/** 手动标记全部已读 */
|
|
148
150
|
markAllAsRead: (category?: NotificationCategory) => Promise<void>;
|
|
151
|
+
/** 由用户手势主动申请桌面通知权限 */
|
|
152
|
+
requestDesktopPermission: () => Promise<NotificationPermission | 'unsupported'>;
|
|
149
153
|
}
|
|
150
154
|
//#endregion
|
|
151
155
|
//#region src/components/C_NotificationCenter/index.vue.d.ts
|
|
152
156
|
declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, NotificationCenterExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
153
|
-
delete: (ids: string[]) => any;
|
|
154
157
|
itemClick: (message: NotificationMessage) => any;
|
|
158
|
+
delete: (ids: string[]) => any;
|
|
155
159
|
read: (ids: string[]) => any;
|
|
156
160
|
allRead: (category?: NotificationCategory | undefined) => any;
|
|
157
161
|
unreadChange: (count: number) => any;
|
|
@@ -159,8 +163,8 @@ declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, Notific
|
|
|
159
163
|
newMessage: (message: NotificationMessage) => any;
|
|
160
164
|
navigate: (url: string) => any;
|
|
161
165
|
}, string, vue.PublicProps, Readonly<NotificationCenterProps> & Readonly<{
|
|
162
|
-
onDelete?: ((ids: string[]) => any) | undefined;
|
|
163
166
|
onItemClick?: ((message: NotificationMessage) => any) | undefined;
|
|
167
|
+
onDelete?: ((ids: string[]) => any) | undefined;
|
|
164
168
|
onRead?: ((ids: string[]) => any) | undefined;
|
|
165
169
|
onAllRead?: ((category?: NotificationCategory | undefined) => any) | undefined;
|
|
166
170
|
onUnreadChange?: ((count: number) => any) | undefined;
|
|
@@ -168,8 +172,8 @@ declare const __VLS_export: vue.DefineComponent<NotificationCenterProps, Notific
|
|
|
168
172
|
onNewMessage?: ((message: NotificationMessage) => any) | undefined;
|
|
169
173
|
onNavigate?: ((url: string) => any) | undefined;
|
|
170
174
|
}>, {
|
|
171
|
-
pageSize: number;
|
|
172
175
|
storageKey: string;
|
|
176
|
+
pageSize: number;
|
|
173
177
|
desktopNotification: boolean;
|
|
174
178
|
maxBadgeCount: number;
|
|
175
179
|
pollingInterval: number;
|
|
@@ -285,6 +289,7 @@ declare function useNotificationCore(props: NotificationCenterProps): {
|
|
|
285
289
|
selectMessage: (msg: NotificationMessage) => void;
|
|
286
290
|
clearSelection: () => void;
|
|
287
291
|
switchCategory: (category: NotificationCategory | "all") => void;
|
|
292
|
+
requestDesktopPermission: () => Promise<NotificationPermission | "unsupported">;
|
|
288
293
|
connectWS: (config: NotificationWSConfig) => void;
|
|
289
294
|
disconnectWS: () => void;
|
|
290
295
|
};
|
|
@@ -340,13 +345,13 @@ declare const CATEGORY_MAP: Record<NotificationCategory, {
|
|
|
340
345
|
}>;
|
|
341
346
|
/** 分类 Tab 列表 */
|
|
342
347
|
declare const CATEGORY_TABS: {
|
|
343
|
-
key: NotificationCategory |
|
|
348
|
+
key: NotificationCategory | 'all';
|
|
344
349
|
label: string;
|
|
345
350
|
}[];
|
|
346
351
|
/** 优先级标签映射 */
|
|
347
352
|
declare const PRIORITY_MAP: Record<NotificationPriority, {
|
|
348
353
|
label: string;
|
|
349
|
-
type:
|
|
354
|
+
type: 'default' | 'info' | 'success' | 'warning' | 'error';
|
|
350
355
|
}>;
|
|
351
356
|
/** 模拟消息列表 */
|
|
352
357
|
declare const MOCK_MESSAGES: ({
|
|
@@ -471,5 +476,4 @@ declare const MOCK_MESSAGES: ({
|
|
|
471
476
|
actionText?: undefined;
|
|
472
477
|
})[];
|
|
473
478
|
//#endregion
|
|
474
|
-
export { NotificationWSConfig as A, NotificationCenterEmits as C, NotificationPriority as D, NotificationMessage as E, WSNotificationPayload as M, NotificationSender as O, NotificationCategory as S, NotificationCenterProps as T, ClearNotificationsFn as _, DEFAULT_POLLING_INTERVAL as a, MarkAllReadFn as b, DEFAULT_WS_HEARTBEAT_MESSAGE as c, MOCK_MESSAGES as d, PRIORITY_MAP as f, _default as g, useNotificationCore as h, DEFAULT_PAGE_SIZE as i, WSConnectionStatus as j, NotificationStatus as k, DEFAULT_WS_MAX_RECONNECT as l, useNotificationFormat as m, CATEGORY_TABS as n, DEFAULT_STORAGE_KEY as o, useNotificationWS as p, DEFAULT_MAX_BADGE_COUNT as r, DEFAULT_WS_HEARTBEAT_INTERVAL as s, CATEGORY_MAP as t, DEFAULT_WS_RECONNECT_INTERVAL as u, DeleteNotificationFn as v, NotificationCenterExpose as w, MarkAsReadFn as x, FetchNotificationsFn as y };
|
|
475
|
-
//# sourceMappingURL=constants3.d.ts.map
|
|
479
|
+
export { NotificationWSConfig as A, NotificationCenterEmits as C, NotificationPriority as D, NotificationMessage as E, WSNotificationPayload as M, NotificationSender as O, NotificationCategory as S, NotificationCenterProps as T, ClearNotificationsFn as _, DEFAULT_POLLING_INTERVAL as a, MarkAllReadFn as b, DEFAULT_WS_HEARTBEAT_MESSAGE as c, MOCK_MESSAGES as d, PRIORITY_MAP as f, _default as g, useNotificationCore as h, DEFAULT_PAGE_SIZE as i, WSConnectionStatus as j, NotificationStatus as k, DEFAULT_WS_MAX_RECONNECT as l, useNotificationFormat as m, CATEGORY_TABS as n, DEFAULT_STORAGE_KEY as o, useNotificationWS as p, DEFAULT_MAX_BADGE_COUNT as r, DEFAULT_WS_HEARTBEAT_INTERVAL as s, CATEGORY_MAP as t, DEFAULT_WS_RECONNECT_INTERVAL as u, DeleteNotificationFn as v, NotificationCenterExpose as w, MarkAsReadFn as x, FetchNotificationsFn as y };
|