@vokril/ui-solid 0.29.0 → 0.32.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 +121 -0
- package/README.md +90 -0
- package/dist/AttributeGrid-CNkALmJq.cjs +1 -0
- package/dist/AttributeGrid-DnuTPJ_P.js +320 -0
- package/dist/Button-CX7mylBT.js +308 -0
- package/dist/Button-lMUW5P3O.cjs +1 -0
- package/dist/CommandPalette-DAR9VMqY.cjs +2 -0
- package/dist/CommandPalette-DlLcdd4o.js +4029 -0
- package/dist/CopyButton-BVvv5M8g.js +63 -0
- package/dist/CopyButton-Dnd8_2Lj.cjs +1 -0
- package/dist/DateRangePicker-BlJWtJBA.cjs +9 -0
- package/dist/DateRangePicker-CHmUU4PA.js +552 -0
- package/dist/GuidedTour-9rqvNB_m.js +483 -0
- package/dist/GuidedTour-DbXeuTc7.cjs +1 -0
- package/dist/{HostPortal-CXGUUhP8.js → HostPortal-De65s6CU.js} +1 -1
- package/dist/HostPortal-Dm4BmY8M.cjs +1 -0
- package/dist/{IconPicker-DYqNi5ud.js → IconPicker-CsYW8CXe.js} +4 -4
- package/dist/IconPicker-D-GU1mD3.cjs +1 -0
- package/dist/Input-C3rEQffK.js +382 -0
- package/dist/Input-CHtvL4_4.cjs +1 -0
- package/dist/Modal-3L6p7Dwt.js +599 -0
- package/dist/Modal-CtrWEnJ7.cjs +1 -0
- package/dist/OverlayScrollArea-Cr0VAApT.cjs +1 -0
- package/dist/OverlayScrollArea-CrrPFLq9.js +180 -0
- package/dist/{PageSkeleton-CLnJO6uD.js → PageSkeleton-BRuqaDzr.js} +372 -371
- package/dist/PageSkeleton-Cz2bckO4.cjs +30 -0
- package/dist/Popover-CLTXG8W0.cjs +1 -0
- package/dist/Popover-DkqGvMNy.js +207 -0
- package/dist/SearchableSelect-C-lV1vSv.cjs +1 -0
- package/dist/SearchableSelect-Du12kcI9.js +328 -0
- package/dist/StatusBarNotificationBell-CNs_obmZ.cjs +50 -0
- package/dist/{StatusBarNotificationBell-7Izs_msz.js → StatusBarNotificationBell-CgsYrrpj.js} +5205 -4850
- package/dist/Stepper-DzI-gtKd.js +586 -0
- package/dist/Stepper-rpu7lpzB.cjs +1 -0
- package/dist/{Textarea-CeAGf08O.cjs → Textarea-D4nYoQ0J.cjs} +1 -1
- package/dist/{Textarea-B5QqqKnI.js → Textarea-DOzZCc-O.js} +1 -1
- package/dist/TimeSeriesChart-BJqQpeEJ.cjs +1 -0
- package/dist/TimeSeriesChart-DvAhuyVl.js +442 -0
- package/dist/ToggleButton-B-hBpdzk.js +2144 -0
- package/dist/ToggleButton-BMH1A-IX.cjs +1 -0
- package/dist/_internal/app/onboarding/pageTourState.d.cts +0 -2
- package/dist/_internal/app/onboarding/pageTourState.d.ts +0 -2
- package/dist/_internal/app/onboarding/pageTourTypes.d.cts +2 -1
- package/dist/_internal/app/onboarding/pageTourTypes.d.ts +2 -1
- package/dist/_internal/contract/notification.d.cts +28 -3
- package/dist/_internal/contract/notification.d.ts +28 -3
- package/dist/_internal/contract/notificationCatalog.d.cts +2 -0
- package/dist/_internal/contract/notificationCatalog.d.ts +2 -0
- package/dist/_internal/platform/settings/settingsTypes.d.cts +0 -8
- package/dist/_internal/platform/settings/settingsTypes.d.ts +0 -8
- package/dist/a11y/index.cjs +1 -1
- package/dist/a11y/index.js +1 -1
- package/dist/anchoredLayout-CBjQ1etD.cjs +1 -0
- package/dist/anchoredLayout-E0mqCWxk.js +233 -0
- package/dist/base.css +3 -3
- package/dist/charts/index.cjs +1 -1
- package/dist/charts/index.js +1 -1
- package/dist/context/DesktopContextMenuContext.d.cts +8 -1
- package/dist/context/DesktopContextMenuContext.d.ts +8 -1
- package/dist/createDialogShellFocus-DI1rUvYf.js +282 -0
- package/dist/createDialogShellFocus-kzkNSLWS.cjs +1 -0
- package/dist/createResizableSidebar--Ve6DbDu.js +504 -0
- package/dist/createResizableSidebar-DlVAuq5t.cjs +1 -0
- package/dist/desktop/index.cjs +1 -1
- package/dist/desktop/index.js +229 -228
- package/dist/dialogFocusRestore-BhxVTSiP.js +10 -0
- package/dist/dialogFocusRestore-DP5b1bDo.cjs +1 -0
- package/dist/feedback/index.cjs +1 -1
- package/dist/feedback/index.js +4 -4
- package/dist/{focusModality-BISb6-yg.cjs → focusModality-D704CJVN.cjs} +1 -1
- package/dist/{focusModality-FoLPWF-_.js → focusModality-ROUF6YGR.js} +1 -1
- package/dist/forms/Input.d.cts +20 -0
- package/dist/forms/Input.d.ts +20 -0
- package/dist/forms/InputMessage.d.cts +19 -0
- package/dist/forms/InputMessage.d.ts +19 -0
- package/dist/forms/index.cjs +1 -1
- package/dist/forms/index.js +9 -9
- package/dist/grid/index.cjs +1 -1
- package/dist/grid/index.js +1 -1
- package/dist/host/index.cjs +1 -1
- package/dist/host/index.d.cts +1 -0
- package/dist/host/index.d.ts +1 -0
- package/dist/host/index.js +38 -39
- package/dist/host/kitHost.d.cts +8 -0
- package/dist/host/kitHost.d.ts +8 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +936 -928
- package/dist/kitHost-BMMWpU4w.js +47 -0
- package/dist/kitHost-u0-mKvEK.cjs +1 -0
- package/dist/layout/index.cjs +1 -1
- package/dist/layout/index.js +2 -2
- package/dist/layout/resizeCarry.d.cts +17 -0
- package/dist/layout/resizeCarry.d.ts +17 -0
- package/dist/mainRealmDom-BcPuVvcy.cjs +1 -0
- package/dist/mainRealmDom-DydRT2Us.js +54 -0
- package/dist/nativeTitleHold-A9jUISgQ.js +170 -0
- package/dist/nativeTitleHold-B7Ou-W9b.cjs +1 -0
- package/dist/navigation/index.cjs +1 -1
- package/dist/navigation/index.js +1 -1
- package/dist/notificationCatalog-CRERhjp6.js +168 -0
- package/dist/notificationCatalog-DqTkd7M6.cjs +1 -0
- package/dist/notifications/NotificationItem.d.cts +9 -0
- package/dist/notifications/NotificationItem.d.ts +9 -0
- package/dist/notifications/NotificationsCenter.d.cts +18 -0
- package/dist/notifications/NotificationsCenter.d.ts +18 -0
- package/dist/notifications/RunningProgressCards.d.cts +3 -0
- package/dist/notifications/RunningProgressCards.d.ts +3 -0
- package/dist/notifications/fireNotification.d.cts +35 -16
- package/dist/notifications/fireNotification.d.ts +35 -16
- package/dist/notifications/holdWhileShown.d.cts +18 -0
- package/dist/notifications/holdWhileShown.d.ts +18 -0
- package/dist/notifications/index.cjs +1 -1
- package/dist/notifications/index.d.cts +1 -0
- package/dist/notifications/index.d.ts +1 -0
- package/dist/notifications/index.js +55 -52
- package/dist/notifications/nativeEngine.d.cts +38 -5
- package/dist/notifications/nativeEngine.d.ts +38 -5
- package/dist/notifications/notificationEntryList.d.cts +104 -0
- package/dist/notifications/notificationEntryList.d.ts +104 -0
- package/dist/notifications/notificationService.d.cts +23 -2
- package/dist/notifications/notificationService.d.ts +23 -2
- package/dist/notifications/toast.d.cts +3 -0
- package/dist/notifications/toast.d.ts +3 -0
- package/dist/notifications/toastCorner.d.cts +8 -0
- package/dist/notifications/toastCorner.d.ts +8 -0
- package/dist/notifications/toastFilterPolicy.d.cts +33 -1
- package/dist/notifications/toastFilterPolicy.d.ts +33 -1
- package/dist/overlay/Modal.d.cts +19 -0
- package/dist/overlay/Modal.d.ts +19 -0
- package/dist/overlay/backgroundInert.d.cts +6 -2
- package/dist/overlay/backgroundInert.d.ts +6 -2
- package/dist/overlay/command-palette/CommandPalette.d.cts +12 -0
- package/dist/overlay/command-palette/CommandPalette.d.ts +12 -0
- package/dist/overlay/index.cjs +1 -1
- package/dist/overlay/index.d.cts +2 -1
- package/dist/overlay/index.d.ts +2 -1
- package/dist/overlay/index.js +80 -75
- package/dist/overlay/modalDefaults.d.cts +23 -0
- package/dist/overlay/modalDefaults.d.ts +23 -0
- package/dist/overlay/modalViewport.d.cts +16 -2
- package/dist/overlay/modalViewport.d.ts +16 -2
- package/dist/overlay/nativeTitleHold.d.cts +24 -0
- package/dist/overlay/nativeTitleHold.d.ts +24 -0
- package/dist/ownerAnimationFrame-DzFcMSmn.js +19 -0
- package/dist/ownerAnimationFrame-T6jf6qYC.cjs +1 -0
- package/dist/pageTourState-BuA-GBYO.cjs +5 -0
- package/dist/{pageTourState-BcBF8w89.js → pageTourState-DsSKdPOu.js} +160 -169
- package/dist/rowSource-BRGZHclZ.js +1231 -0
- package/dist/rowSource-C3zlzAtR.cjs +1 -0
- package/dist/server/AttributeGrid-B9j_c2wM.js +281 -0
- package/dist/server/AttributeGrid-BALCTvOI.cjs +1 -0
- package/dist/server/Button-DHefmmYz.cjs +1 -0
- package/dist/server/Button-ft_8RNJj.js +226 -0
- package/dist/server/CommandPalette-CHdfYtxs.js +3305 -0
- package/dist/server/CommandPalette-D0Prl7by.cjs +1 -0
- package/dist/server/CopyButton-CiYcsQcI.js +64 -0
- package/dist/server/CopyButton-D2q7tQ0m.cjs +1 -0
- package/dist/server/DateRangePicker-C6wZI7No.js +487 -0
- package/dist/server/DateRangePicker-CF70G2yr.cjs +9 -0
- package/dist/server/GuidedTour-BmDAWNfN.cjs +1 -0
- package/dist/server/GuidedTour-DYBhprVK.js +400 -0
- package/dist/server/{HostPortal-CXGUUhP8.js → HostPortal-C4xdfRyM.js} +1 -1
- package/dist/server/HostPortal-CwyePpDX.cjs +1 -0
- package/dist/server/{IconPicker-B4aXspLw.js → IconPicker--Xso9fUf.js} +5 -5
- package/dist/server/IconPicker-BTI4cNgf.cjs +1 -0
- package/dist/server/Input-UX0Hk53M.cjs +1 -0
- package/dist/server/Input-V9Szcw6w.js +249 -0
- package/dist/server/Modal-CBnNlaTx.cjs +1 -0
- package/dist/server/Modal-D9CjieKK.js +426 -0
- package/dist/server/OverlayScrollArea-DuwGRSMm.cjs +1 -0
- package/dist/server/OverlayScrollArea-h6G3yk6U.js +66 -0
- package/dist/server/{PageSkeleton-DoxlE_bD.js → PageSkeleton-CFs7AdTA.js} +267 -266
- package/dist/server/PageSkeleton-D0KOKLsb.cjs +30 -0
- package/dist/server/Popover-BBDBIpT6.cjs +1 -0
- package/dist/server/Popover-e9JpRh11.js +439 -0
- package/dist/server/SearchableSelect-B2ZFnp6i.js +205 -0
- package/dist/server/SearchableSelect-BBu5cP6P.cjs +1 -0
- package/dist/server/{StatusBarNotificationBell-D8Jt3PXI.js → StatusBarNotificationBell-CJJFE4rf.js} +5043 -4698
- package/dist/server/StatusBarNotificationBell-Cxs_bVKX.cjs +49 -0
- package/dist/server/Stepper-C04rOZcI.cjs +1 -0
- package/dist/server/Stepper-CVAOsf3o.js +381 -0
- package/dist/server/{Textarea-BQf2lL59.cjs → Textarea-BG6F8taO.cjs} +1 -1
- package/dist/server/{Textarea-BTH48NET.js → Textarea-DM4zpgWo.js} +1 -1
- package/dist/server/TimeSeriesChart-kuuqH7we.js +242 -0
- package/dist/server/TimeSeriesChart-tWbSF6fJ.cjs +1 -0
- package/dist/server/ToggleButton-BdqufQ7G.js +1344 -0
- package/dist/server/ToggleButton-Bo24NK3o.cjs +1 -0
- package/dist/server/{VpTrash-Dlq8o6Uv.js → VpTrash-CZMWCIpF.js} +84 -70
- package/dist/server/VpTrash-DiczWhwm.cjs +1 -0
- package/dist/server/a11y/index.cjs +1 -1
- package/dist/server/a11y/index.js +1 -1
- package/dist/server/charts/index.cjs +1 -1
- package/dist/server/charts/index.js +1 -1
- package/dist/server/createDialogShellFocus-DvoNWpIu.cjs +1 -0
- package/dist/server/createDialogShellFocus-J8wqPlsa.js +370 -0
- package/dist/server/{createResizableSidebar-BImbKlLe.js → createResizableSidebar-CIrhLNKW.js} +104 -102
- package/dist/server/createResizableSidebar-DcZ2Cnpf.cjs +1 -0
- package/dist/server/desktop/index.cjs +1 -1
- package/dist/server/desktop/index.js +154 -153
- package/dist/server/dialogFocusRestore-BhxVTSiP.js +10 -0
- package/dist/server/dialogFocusRestore-DP5b1bDo.cjs +1 -0
- package/dist/server/feedback/index.cjs +1 -1
- package/dist/server/feedback/index.js +4 -4
- package/dist/server/{focusModality-nWNVX3JG.js → focusModality-Bu4Kuwm4.js} +1 -1
- package/dist/server/{focusModality-D-nxv8Er.cjs → focusModality-G2i60_7y.cjs} +1 -1
- package/dist/server/forms/index.cjs +1 -1
- package/dist/server/forms/index.js +9 -9
- package/dist/server/grid/index.cjs +1 -1
- package/dist/server/grid/index.js +1 -1
- package/dist/server/host/index.cjs +1 -1
- package/dist/server/host/index.js +38 -39
- package/dist/server/{index-UIjsx3oJ.js → index-CPUZyKo7.js} +3604 -3617
- package/dist/server/index-CVbkasNJ.cjs +1 -0
- package/dist/server/index.cjs +1 -1
- package/dist/server/index.js +656 -649
- package/dist/server/kitHost-BMMWpU4w.js +47 -0
- package/dist/server/kitHost-u0-mKvEK.cjs +1 -0
- package/dist/server/layout/index.cjs +1 -1
- package/dist/server/layout/index.js +2 -2
- package/dist/server/mainRealmDom-BuGEeM_r.cjs +1 -0
- package/dist/server/{EmptyState-Csydyy_7.js → mainRealmDom-CzckS_ss.js} +12 -8
- package/dist/server/navigation/index.cjs +1 -1
- package/dist/server/navigation/index.js +1 -1
- package/dist/server/notificationCatalog-CEDltsJS.cjs +1 -0
- package/dist/server/notificationCatalog-Cl1dH4aJ.js +122 -0
- package/dist/server/notifications/index.cjs +1 -1
- package/dist/server/notifications/index.js +55 -52
- package/dist/server/overlay/index.cjs +1 -1
- package/dist/server/overlay/index.js +72 -68
- package/dist/server/pageTourState-BuA-GBYO.cjs +5 -0
- package/dist/server/{pageTourState-BcBF8w89.js → pageTourState-DsSKdPOu.js} +160 -169
- package/dist/server/rowSource-C1F4l0xZ.cjs +1 -0
- package/dist/server/rowSource-CoeHYNsV.js +1123 -0
- package/dist/server/tokens/index.cjs +1 -1
- package/dist/server/tokens/index.js +29 -26
- package/dist/server/tokens/palette/index.cjs +1 -0
- package/dist/server/tokens/palette/index.js +31 -0
- package/dist/server/tree/index.cjs +1 -1
- package/dist/server/tree/index.js +1 -1
- package/dist/solid/_internal/app/onboarding/PageTourHost.jsx +11 -10
- package/dist/solid/_internal/app/onboarding/pageTourState.js +12 -23
- package/dist/solid/charts/TimeSeriesChart.jsx +23 -22
- package/dist/solid/desktop/WindowControls.jsx +6 -3
- package/dist/solid/feedback/Badge.jsx +12 -19
- package/dist/solid/feedback/ErrorBoundary.jsx +18 -14
- package/dist/solid/forms/Button.jsx +18 -23
- package/dist/solid/forms/Checkbox.jsx +5 -4
- package/dist/solid/forms/Combobox.jsx +12 -10
- package/dist/solid/forms/CopyButton.jsx +7 -4
- package/dist/solid/forms/DatePicker.jsx +12 -7
- package/dist/solid/forms/Dropzone.jsx +17 -13
- package/dist/solid/forms/FilePickerButton.jsx +5 -4
- package/dist/solid/forms/HiddenFileInput.jsx +3 -1
- package/dist/solid/forms/Input.jsx +31 -5
- package/dist/solid/forms/Input.module.css.js +1 -0
- package/dist/solid/forms/InputMessage.jsx +87 -0
- package/dist/solid/forms/MultiSearchableSelect.jsx +8 -7
- package/dist/solid/forms/NumberInput.jsx +25 -19
- package/dist/solid/forms/Picker.jsx +8 -6
- package/dist/solid/forms/PressableSurface.jsx +17 -23
- package/dist/solid/forms/RadioGroup.jsx +4 -3
- package/dist/solid/forms/SearchInput.jsx +4 -3
- package/dist/solid/forms/SearchableSelect.jsx +4 -3
- package/dist/solid/forms/SegmentedControl.jsx +4 -3
- package/dist/solid/forms/TagInput.jsx +22 -16
- package/dist/solid/forms/ToggleButton.jsx +4 -3
- package/dist/solid/forms/date-range-picker/DateRangePicker.jsx +12 -10
- package/dist/solid/grid/Pagination.jsx +7 -3
- package/dist/solid/host/kitHost.jsx +5 -1
- package/dist/solid/layout/PageHeaderIcon.jsx +11 -9
- package/dist/solid/layout/ResizableSplitPane.jsx +4 -4
- package/dist/solid/layout/ResizeHandle.jsx +15 -4
- package/dist/solid/layout/resizeCarry.js +31 -0
- package/dist/solid/navigation/Accordion.jsx +8 -5
- package/dist/solid/navigation/Tabs.jsx +11 -8
- package/dist/solid/notifications/NotificationHost.jsx +5 -18
- package/dist/solid/notifications/NotificationItem.jsx +62 -58
- package/dist/solid/notifications/NotificationPanel.jsx +27 -9
- package/dist/solid/notifications/NotificationsCenter.jsx +72 -12
- package/dist/solid/notifications/RunningProgressCards.jsx +1 -1
- package/dist/solid/notifications/StatusBarNotificationBell.jsx +12 -6
- package/dist/solid/notifications/catalogAdapter.js +1 -0
- package/dist/solid/notifications/createNotificationPreviewRuntime.js +2 -0
- package/dist/solid/notifications/fireNotification.js +21 -16
- package/dist/solid/notifications/holdWhileShown.js +30 -0
- package/dist/solid/notifications/index.js +1 -0
- package/dist/solid/notifications/nativeEngine.js +52 -1
- package/dist/solid/notifications/notificationEntryList.js +184 -0
- package/dist/solid/notifications/notificationService.js +20 -4
- package/dist/solid/notifications/toast.js +58 -7
- package/dist/solid/notifications/toastCorner.js +3 -0
- package/dist/solid/notifications/toastFilterPolicy.js +12 -0
- package/dist/solid/overlay/ConfirmDialog.jsx +21 -16
- package/dist/solid/overlay/DangerousActionDialogParts.jsx +5 -3
- package/dist/solid/overlay/Disclosure.jsx +4 -3
- package/dist/solid/overlay/Drawer.jsx +2 -1
- package/dist/solid/overlay/DropdownMenu.jsx +6 -4
- package/dist/solid/overlay/FloatingWindow.jsx +3 -3
- package/dist/solid/overlay/HoverTooltip.jsx +9 -7
- package/dist/solid/overlay/Modal.jsx +81 -34
- package/dist/solid/overlay/OverlayScrollArea.jsx +5 -3
- package/dist/solid/overlay/Tooltip.jsx +5 -4
- package/dist/solid/overlay/command-palette/CommandPalette.jsx +11 -11
- package/dist/solid/overlay/context-menu/DesktopContextMenu.jsx +73 -57
- package/dist/solid/overlay/index.js +2 -1
- package/dist/solid/overlay/menu/MenuParts.jsx +11 -8
- package/dist/solid/overlay/modalDefaults.jsx +10 -0
- package/dist/solid/overlay/modalViewport.js +17 -4
- package/dist/solid/overlay/nativeTitleHold.js +33 -0
- package/dist/solid/overlay/popover/Popover.jsx +17 -11
- package/dist/solid/overlay/tooltipDirective.js +3 -11
- package/dist/solid/overlay/tour/GuidedTour.jsx +18 -14
- package/dist/solid/tokens/index.js +1 -0
- package/dist/solid/tokens/palette/index.js +1 -0
- package/dist/solid/tokens/palette/paletteContract.js +27 -0
- package/dist/solid/tree/TreeRow.jsx +19 -16
- package/dist/solid/tree/TreeSurface.jsx +15 -14
- package/dist/solid/widgets/SettingsField.jsx +11 -10
- package/dist/style.css +4 -3
- package/dist/theme.css +3 -2
- package/dist/tokens/index.cjs +1 -1
- package/dist/tokens/index.d.cts +1 -0
- package/dist/tokens/index.d.ts +1 -0
- package/dist/tokens/index.js +29 -26
- package/dist/tokens/palette/index.cjs +1 -0
- package/dist/tokens/palette/index.d.cts +12 -0
- package/dist/tokens/palette/index.d.ts +12 -0
- package/dist/tokens/palette/index.js +31 -0
- package/dist/tokens/palette/paletteContract.d.cts +17 -0
- package/dist/tokens/palette/paletteContract.d.ts +17 -0
- package/dist/tokens/tokens.css +3 -2
- package/dist/tree/index.cjs +1 -1
- package/dist/tree/index.js +1 -1
- package/dist/ui.css +1 -1
- package/package.json +25 -1
- package/dist/AttributeGrid-CASILa4u.js +0 -320
- package/dist/AttributeGrid-eND8YDby.cjs +0 -1
- package/dist/Button-Bb68ymNP.cjs +0 -1
- package/dist/Button-D-T0tyGF.js +0 -305
- package/dist/CommandPalette-5FQRgPG9.cjs +0 -2
- package/dist/CommandPalette-Cj618AOz.js +0 -4017
- package/dist/CopyButton-B5gS2ft3.cjs +0 -1
- package/dist/CopyButton-g-WSiBDZ.js +0 -63
- package/dist/DateRangePicker-CJD9ADgB.js +0 -550
- package/dist/DateRangePicker-Frc0HVxp.cjs +0 -9
- package/dist/EmptyState-B9TxGJ5v.cjs +0 -1
- package/dist/EmptyState-Dph6HU74.js +0 -50
- package/dist/GuidedTour-B6q7lYhn.cjs +0 -1
- package/dist/GuidedTour-CFCvRJN4.js +0 -483
- package/dist/HostPortal-CgJwxt-f.cjs +0 -1
- package/dist/IconPicker-CIbJb1ei.cjs +0 -1
- package/dist/Input-CZruORyy.cjs +0 -1
- package/dist/Input-DkPhsdfk.js +0 -227
- package/dist/Modal-CY6ePolt.cjs +0 -1
- package/dist/Modal-NzZzHSwb.js +0 -559
- package/dist/OverlayScrollArea-BSlaXG1h.cjs +0 -1
- package/dist/OverlayScrollArea-c8Za77qs.js +0 -180
- package/dist/PageSkeleton-BPbb28-H.cjs +0 -30
- package/dist/Popover-CWrR51eG.cjs +0 -1
- package/dist/Popover-Cttb6NYT.js +0 -206
- package/dist/SearchableSelect-BvCm4enQ.js +0 -327
- package/dist/SearchableSelect-CVqdVMOC.cjs +0 -1
- package/dist/StatusBarNotificationBell-BJiORN4s.cjs +0 -50
- package/dist/Stepper-Ci5JpLbS.cjs +0 -1
- package/dist/Stepper-D9i1Xclm.js +0 -583
- package/dist/TimeSeriesChart-DOwi2lJs.js +0 -441
- package/dist/TimeSeriesChart-huvheefm.cjs +0 -1
- package/dist/ToggleButton-BFWh1_o5.cjs +0 -1
- package/dist/ToggleButton-CFM8P3JY.js +0 -2137
- package/dist/anchoredLayout-Dstwa5OH.cjs +0 -1
- package/dist/anchoredLayout-FC-qv8xm.js +0 -250
- package/dist/createDialogShellFocus-B4piXDU4.js +0 -282
- package/dist/createDialogShellFocus-CJaw9-B9.cjs +0 -1
- package/dist/createResizableSidebar-BDUlX9-G.js +0 -472
- package/dist/createResizableSidebar-BVJBU2kP.cjs +0 -1
- package/dist/dialogFocusRestore--dH59ER2.js +0 -35
- package/dist/dialogFocusRestore-CL-ExfAA.cjs +0 -1
- package/dist/kitHost-BfJExE1G.cjs +0 -1
- package/dist/kitHost-CVAEi9sF.js +0 -23
- package/dist/mainRealmDom-C12lr9lm.js +0 -171
- package/dist/mainRealmDom-S6teqEr4.cjs +0 -1
- package/dist/pageTourState-CrbEU7QW.cjs +0 -5
- package/dist/rowSource-D__7o4h0.js +0 -1230
- package/dist/rowSource-DiwTu_r8.cjs +0 -1
- package/dist/server/AttributeGrid-B7sb3btp.cjs +0 -1
- package/dist/server/AttributeGrid-CMi-UtWb.js +0 -281
- package/dist/server/Button-0AXWRw9Q.cjs +0 -1
- package/dist/server/Button-3yNrnn4P.js +0 -220
- package/dist/server/CommandPalette-CozogFlk.js +0 -3265
- package/dist/server/CommandPalette-DQK6N98N.cjs +0 -1
- package/dist/server/CopyButton-B6xd9Z6j.js +0 -64
- package/dist/server/CopyButton-D8IN6Vnd.cjs +0 -1
- package/dist/server/DateRangePicker-C35q8BTw.js +0 -484
- package/dist/server/DateRangePicker-KLZzyuPJ.cjs +0 -9
- package/dist/server/EmptyState-BnAHklc5.cjs +0 -1
- package/dist/server/GuidedTour-DfV0yzqh.cjs +0 -1
- package/dist/server/GuidedTour-DmLbBttx.js +0 -400
- package/dist/server/HostPortal-CgJwxt-f.cjs +0 -1
- package/dist/server/IconPicker-B1soopAp.cjs +0 -1
- package/dist/server/Input-CjvD8w18.cjs +0 -1
- package/dist/server/Input-DaEN2JJd.js +0 -127
- package/dist/server/Modal-BheFQLs1.js +0 -415
- package/dist/server/Modal-BswxV8Pn.cjs +0 -1
- package/dist/server/OverlayScrollArea-221dfKyz.js +0 -65
- package/dist/server/OverlayScrollArea-D4e9D9Nd.cjs +0 -1
- package/dist/server/PageSkeleton-DBo7hQq-.cjs +0 -30
- package/dist/server/Popover-BsxIKBbl.cjs +0 -1
- package/dist/server/Popover-Cg28aPUZ.js +0 -439
- package/dist/server/SearchableSelect-09ECcDlB.cjs +0 -1
- package/dist/server/SearchableSelect-vjhS4c-H.js +0 -205
- package/dist/server/StatusBarNotificationBell-LJHLMT9F.cjs +0 -49
- package/dist/server/Stepper-DxNrskdq.cjs +0 -1
- package/dist/server/Stepper-n5f9r-ye.js +0 -375
- package/dist/server/TimeSeriesChart-BQVXUFoj.cjs +0 -1
- package/dist/server/TimeSeriesChart-PAb95s6x.js +0 -242
- package/dist/server/ToggleButton-FywO2CCI.js +0 -1335
- package/dist/server/ToggleButton-TE3Xf2yD.cjs +0 -1
- package/dist/server/VpTrash-D49oUUJh.cjs +0 -1
- package/dist/server/createDialogShellFocus-BFo8awdj.js +0 -369
- package/dist/server/createDialogShellFocus-BiBAZOCI.cjs +0 -1
- package/dist/server/createResizableSidebar-GFgZIj-5.cjs +0 -1
- package/dist/server/dialogFocusRestore--dH59ER2.js +0 -35
- package/dist/server/dialogFocusRestore-CL-ExfAA.cjs +0 -1
- package/dist/server/index-2mQPVEDR.cjs +0 -1
- package/dist/server/kitHost-BfJExE1G.cjs +0 -1
- package/dist/server/kitHost-CVAEi9sF.js +0 -23
- package/dist/server/mainRealmDom-DPNaDWtw.js +0 -121
- package/dist/server/mainRealmDom-DwZVMPnO.cjs +0 -1
- package/dist/server/pageTourState-CrbEU7QW.cjs +0 -5
- package/dist/server/rowSource-D-wcDmFU.js +0 -1122
- package/dist/server/rowSource-DltiY0o3.cjs +0 -1
- package/dist/tooltipCoordinator-BzxEyKhA.js +0 -144
- package/dist/tooltipCoordinator-DslqMlsI.cjs +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { createSignal } from 'solid-js';
|
|
1
|
+
import { createMemo, createSignal } from 'solid-js';
|
|
2
2
|
import { OverlayScrollArea } from '../overlay/OverlayScrollArea';
|
|
3
3
|
import styles from './ResizableSplitPane.module.css.js';
|
|
4
4
|
import { bestEffortFailed } from '../_internal/base/bestEffort';
|
|
5
5
|
import { isKey } from '../_internal/base/keys';
|
|
6
6
|
export function ResizableSplitPane(props) {
|
|
7
|
-
const direction = () => props.direction ?? 'horizontal';
|
|
8
|
-
const min = () => props.minSize ?? 15;
|
|
9
|
-
const max = () => props.maxSize ?? 85;
|
|
7
|
+
const direction = createMemo(() => props.direction ?? 'horizontal');
|
|
8
|
+
const min = createMemo(() => props.minSize ?? 15);
|
|
9
|
+
const max = createMemo(() => props.maxSize ?? 85);
|
|
10
10
|
const [size, setSize] = createSignal(Math.min(max(), Math.max(min(), props.initialSize ?? 50)));
|
|
11
11
|
const [isDragging, setIsDragging] = createSignal(false);
|
|
12
12
|
let containerRef;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { createSignal, onCleanup } from 'solid-js';
|
|
1
|
+
import { createMemo, createSignal, onCleanup } from 'solid-js';
|
|
2
2
|
import { isKey } from '../_internal/base/keys';
|
|
3
|
+
import { createResizeCarry } from './resizeCarry';
|
|
3
4
|
import styles from './ResizeHandle.module.css.js';
|
|
4
5
|
export function ResizeHandle(props) {
|
|
6
|
+
const value = createMemo(() => props.value);
|
|
5
7
|
const [isDragging, setIsDragging] = createSignal(false);
|
|
6
|
-
const orientation = () => props.orientation ?? 'horizontal';
|
|
8
|
+
const orientation = createMemo(() => props.orientation ?? 'horizontal');
|
|
7
9
|
let activeCleanup;
|
|
8
10
|
onCleanup(() => {
|
|
9
11
|
activeCleanup?.();
|
|
@@ -15,13 +17,22 @@ export function ResizeHandle(props) {
|
|
|
15
17
|
setIsDragging(true);
|
|
16
18
|
let lastX = e.clientX;
|
|
17
19
|
let lastY = e.clientY;
|
|
20
|
+
const { min, max } = props;
|
|
21
|
+
const carry = typeof min === 'number' && typeof max === 'number' && value() !== undefined
|
|
22
|
+
? createResizeCarry({ min, max })
|
|
23
|
+
: null;
|
|
18
24
|
const onPointerMove = (moveEvent) => {
|
|
19
25
|
const deltaX = moveEvent.clientX - lastX;
|
|
20
26
|
const deltaY = moveEvent.clientY - lastY;
|
|
21
27
|
lastX = moveEvent.clientX;
|
|
22
28
|
lastY = moveEvent.clientY;
|
|
23
29
|
const delta = orientation() === 'horizontal' ? deltaX : deltaY;
|
|
24
|
-
|
|
30
|
+
if (carry) {
|
|
31
|
+
carry.step(delta, () => value() ?? 0, (applied) => props.onResize?.(applied));
|
|
32
|
+
}
|
|
33
|
+
else {
|
|
34
|
+
props.onResize?.(delta);
|
|
35
|
+
}
|
|
25
36
|
};
|
|
26
37
|
const onPointerUp = (upEvent) => {
|
|
27
38
|
try {
|
|
@@ -67,7 +78,7 @@ export function ResizeHandle(props) {
|
|
|
67
78
|
}
|
|
68
79
|
}
|
|
69
80
|
};
|
|
70
|
-
return (<div role="separator" tabindex={0} aria-orientation={orientation()} aria-valuenow={
|
|
81
|
+
return (<div role="separator" tabindex={0} aria-orientation={orientation()} aria-valuenow={value()} aria-valuemin={props.min} aria-valuemax={props.max} aria-label={props.ariaLabel ?? 'Resize separator'} class={`${styles.handle} ${orientation() === 'horizontal' ? styles.horizontal : styles.vertical} ${isDragging() ? styles.dragging : ''} ${props.class ?? ''}`} onPointerDown={handlePointerDown} onDblClick={props.onDoubleClick} onKeyDown={handleKeyDown}>
|
|
71
82
|
<div class={styles.indicator} aria-hidden="true"/>
|
|
72
83
|
</div>);
|
|
73
84
|
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export function createResizeCarry(bounds) {
|
|
2
|
+
let carried = 0;
|
|
3
|
+
return {
|
|
4
|
+
step(delta, read, apply) {
|
|
5
|
+
let move = delta;
|
|
6
|
+
if (carried !== 0) {
|
|
7
|
+
const next = carried + move;
|
|
8
|
+
if (Math.sign(next) === Math.sign(carried)) {
|
|
9
|
+
carried = next;
|
|
10
|
+
return;
|
|
11
|
+
}
|
|
12
|
+
carried = 0;
|
|
13
|
+
move = next;
|
|
14
|
+
}
|
|
15
|
+
if (move === 0)
|
|
16
|
+
return;
|
|
17
|
+
const before = read();
|
|
18
|
+
apply(move);
|
|
19
|
+
const after = read();
|
|
20
|
+
const changed = after - before;
|
|
21
|
+
const atBound = after <= bounds.min || after >= bounds.max;
|
|
22
|
+
if (!atBound)
|
|
23
|
+
return;
|
|
24
|
+
const appliedInPointerSpace = changed === 0 ? 0 : Math.sign(changed) === Math.sign(move) ? changed : -changed;
|
|
25
|
+
const unapplied = move - appliedInPointerSpace;
|
|
26
|
+
if (unapplied !== 0 && Math.sign(unapplied) === Math.sign(move)) {
|
|
27
|
+
carried = unapplied;
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
};
|
|
31
|
+
}
|
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
import { For, Show, createSignal } from 'solid-js';
|
|
1
|
+
import { For, Show, createMemo, createSignal } from 'solid-js';
|
|
2
2
|
import { VpChevronDown } from '@vokril/icons';
|
|
3
3
|
import styles from './Accordion.module.css.js';
|
|
4
4
|
import { namedKeyOf } from '../_internal/base/keys';
|
|
5
5
|
export function Accordion(props) {
|
|
6
|
+
const expandedIds = createMemo(() => props.expandedIds);
|
|
7
|
+
const allowMultiple = createMemo(() => Boolean(props.allowMultiple));
|
|
6
8
|
const [internalExpanded, setInternalExpanded] = createSignal(new Set(props.defaultExpandedIds ?? []));
|
|
7
9
|
const isExpanded = (id) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
+
const ids = expandedIds();
|
|
11
|
+
if (ids !== undefined) {
|
|
12
|
+
return ids.includes(id);
|
|
10
13
|
}
|
|
11
14
|
return internalExpanded().has(id);
|
|
12
15
|
};
|
|
@@ -16,9 +19,9 @@ export function Accordion(props) {
|
|
|
16
19
|
if (props.onToggle) {
|
|
17
20
|
props.onToggle(id, nextExpanded);
|
|
18
21
|
}
|
|
19
|
-
if (
|
|
22
|
+
if (expandedIds() === undefined) {
|
|
20
23
|
setInternalExpanded((prev) => {
|
|
21
|
-
const next = new Set(
|
|
24
|
+
const next = new Set(allowMultiple() ? prev : []);
|
|
22
25
|
if (nextExpanded) {
|
|
23
26
|
next.add(id);
|
|
24
27
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { For, Show, createSignal } from 'solid-js';
|
|
1
|
+
import { For, Show, createMemo, createSignal } from 'solid-js';
|
|
2
2
|
import { createSelectionIndicator } from './createSelectionIndicator';
|
|
3
3
|
import styles from './Tabs.module.css.js';
|
|
4
4
|
import { rovingTabIndex } from './tablistKeyboardNavigation';
|
|
@@ -10,6 +10,9 @@ import { OverlayScrollArea } from '../overlay/OverlayScrollArea';
|
|
|
10
10
|
import { t } from '../i18n/i18n';
|
|
11
11
|
import { isKey } from '../_internal/base/keys';
|
|
12
12
|
export function Tabs(props) {
|
|
13
|
+
const tabs = createMemo(() => props.tabs);
|
|
14
|
+
const reorderable = createMemo(() => Boolean(props.reorderable));
|
|
15
|
+
const closable = createMemo(() => props.closable === true);
|
|
13
16
|
const selectedIndex = () => props.tabs.findIndex((tab) => tab.value === props.value);
|
|
14
17
|
const handleKeyDown = createTablistKeyboardHandler(props.orientation ? { orientation: props.orientation } : undefined);
|
|
15
18
|
let listEl;
|
|
@@ -46,21 +49,21 @@ export function Tabs(props) {
|
|
|
46
49
|
<For each={props.tabs}>
|
|
47
50
|
{(tab, index) => {
|
|
48
51
|
const selected = () => props.value === tab.value;
|
|
49
|
-
const isTabClosable = () => (
|
|
50
|
-
props.onClose !== undefined;
|
|
52
|
+
const isTabClosable = createMemo(() => (closable() || tab.closable === true) &&
|
|
53
|
+
props.onClose !== undefined);
|
|
51
54
|
return (<button type="button" role="tab" title={tab.title} aria-label={tab.ariaLabel ?? tab.title} id={props.idPrefix !== undefined
|
|
52
55
|
? tabId(props.idPrefix, tab.value)
|
|
53
56
|
: undefined} aria-controls={props.idPrefix !== undefined
|
|
54
57
|
? tabPanelId(props.idPrefix, tab.value)
|
|
55
58
|
: undefined} aria-selected={selected()} tabindex={rovingTabIndex(index(), selectedIndex())} class={`${styles.tab} ${selected()
|
|
56
59
|
? `${styles.active} ${tab.activeClass ?? ''}`.trim()
|
|
57
|
-
: ''} ${
|
|
58
|
-
if (!
|
|
60
|
+
: ''} ${reorderable() ? styles.draggableTab : ''} ${dragOverIndex() === index() ? styles.dragOver : ''} ${tab.class ?? ''}`.trim()} disabled={tab.disabled} draggable={reorderable() && !tab.disabled} onPointerDown={tab.onPointerDown} onContextMenu={tab.onContextMenu} {...(tab.dataAttributes ?? {})} onDragStart={(e) => {
|
|
61
|
+
if (!reorderable())
|
|
59
62
|
return;
|
|
60
63
|
e.dataTransfer?.setData('text/plain', String(index()));
|
|
61
64
|
e.dataTransfer?.setData('application/x-vokril-tab', String(index()));
|
|
62
65
|
}} onDragOver={(e) => {
|
|
63
|
-
if (
|
|
66
|
+
if (reorderable()) {
|
|
64
67
|
e.preventDefault();
|
|
65
68
|
setDragOverIndex(index());
|
|
66
69
|
}
|
|
@@ -70,7 +73,7 @@ export function Tabs(props) {
|
|
|
70
73
|
}
|
|
71
74
|
}} onDrop={(e) => {
|
|
72
75
|
setDragOverIndex(null);
|
|
73
|
-
if (!
|
|
76
|
+
if (!reorderable() || !props.onReorder)
|
|
74
77
|
return;
|
|
75
78
|
e.preventDefault();
|
|
76
79
|
const rawIdx = e.dataTransfer?.getData('application/x-vokril-tab') ||
|
|
@@ -78,7 +81,7 @@ export function Tabs(props) {
|
|
|
78
81
|
const fromIdx = Number(rawIdx);
|
|
79
82
|
const toIdx = index();
|
|
80
83
|
if (!Number.isNaN(fromIdx) && fromIdx !== toIdx) {
|
|
81
|
-
const next = [...
|
|
84
|
+
const next = [...tabs()];
|
|
82
85
|
const moved = next.splice(fromIdx, 1)[0];
|
|
83
86
|
if (moved) {
|
|
84
87
|
next.splice(toIdx, 0, moved);
|
|
@@ -18,6 +18,7 @@ import { FOCUS_CONTEXT_KEYS } from '../_internal/app/keybindings/contextKey/buil
|
|
|
18
18
|
import { registerNotificationCommands } from './notificationCommands';
|
|
19
19
|
import { appWindowNotificationOverlay, } from './notificationOverlayChannel';
|
|
20
20
|
import { createNotificationOverlaySync } from './notificationOverlaySync';
|
|
21
|
+
import { notificationListFocusStep } from './notificationEntryList';
|
|
21
22
|
import { modalBackgroundExemption } from '../overlay/backgroundInert';
|
|
22
23
|
import styles from './NotificationHost.module.css.js';
|
|
23
24
|
import { isKey } from '../_internal/base/keys';
|
|
@@ -110,24 +111,10 @@ export const NotificationHost = (props) => {
|
|
|
110
111
|
if (!hostEl()?.contains(eventTarget))
|
|
111
112
|
return;
|
|
112
113
|
const idx = focusIndex();
|
|
113
|
-
|
|
114
|
+
const step = notificationListFocusStep(event, idx, list.length, 'ends');
|
|
115
|
+
if (step !== null) {
|
|
114
116
|
event.preventDefault();
|
|
115
|
-
setFocusIndex(
|
|
116
|
-
return;
|
|
117
|
-
}
|
|
118
|
-
if (isKey(event, 'ArrowUp') || isKey(event, 'PageUp')) {
|
|
119
|
-
event.preventDefault();
|
|
120
|
-
setFocusIndex(idx === null ? list.length - 1 : Math.max(0, idx - 1));
|
|
121
|
-
return;
|
|
122
|
-
}
|
|
123
|
-
if (isKey(event, 'Home')) {
|
|
124
|
-
event.preventDefault();
|
|
125
|
-
setFocusIndex(0);
|
|
126
|
-
return;
|
|
127
|
-
}
|
|
128
|
-
if (isKey(event, 'End')) {
|
|
129
|
-
event.preventDefault();
|
|
130
|
-
setFocusIndex(list.length - 1);
|
|
117
|
+
setFocusIndex(step);
|
|
131
118
|
return;
|
|
132
119
|
}
|
|
133
120
|
if (idx === null)
|
|
@@ -267,7 +254,7 @@ export const NotificationHost = (props) => {
|
|
|
267
254
|
<OverlayScrollArea rootClass={styles.scrollArea} viewportClass={styles.stack} viewportRef={setScrollEl} hideHorizontal>
|
|
268
255
|
<For each={visible()}>
|
|
269
256
|
{(item, index) => (<div class={styles.enter} data-focused={focusIndex() === index() ? 'true' : 'false'}>
|
|
270
|
-
<NotificationItem item={item} controller={controller} shell={item.isolated ? null : shell}/>
|
|
257
|
+
<NotificationItem item={item} controller={controller} shell={item.isolated ? null : shell} corner={effectivePosition()}/>
|
|
271
258
|
</div>)}
|
|
272
259
|
</For>
|
|
273
260
|
</OverlayScrollArea>
|
|
@@ -3,7 +3,7 @@ import { Dynamic } from 'solid-js/web';
|
|
|
3
3
|
import { Show, For, createEffect, createMemo, createSignal, onCleanup, useContext, } from 'solid-js';
|
|
4
4
|
import { useRelativeNow } from './relativeTimeClock';
|
|
5
5
|
import { prefersReducedMotion } from '../a11y/prefersReducedMotion';
|
|
6
|
-
import {
|
|
6
|
+
import { cardRemindKey } from './toastFilterPolicy';
|
|
7
7
|
import { HoverTooltip } from '../overlay/HoverTooltip';
|
|
8
8
|
import { Button } from '../forms/Button';
|
|
9
9
|
import { Progress } from '../feedback/Progress';
|
|
@@ -14,6 +14,8 @@ import { relativeAgeLabel } from '../_internal/platform/intl/relativeAgeLabel';
|
|
|
14
14
|
import { isProgressRunning, } from './nativeEngine';
|
|
15
15
|
import { renderNotificationMarkdown } from './markdownRender';
|
|
16
16
|
import { NOTIFICATION_SEVERITY_LABELS } from './notificationSeverityLabels';
|
|
17
|
+
import { notificationEntryMark } from './notificationEntryList';
|
|
18
|
+
import { toastCornerEdge } from './toastCorner';
|
|
17
19
|
import { getGoogleSearchUrl, } from '../_internal/platform/vendorErrors';
|
|
18
20
|
import { DesktopContextMenuContext } from '../context/DesktopContextMenuContext';
|
|
19
21
|
import { placeMenuAtTrigger } from '../overlay/context-menu/desktopMenuPlacement';
|
|
@@ -53,6 +55,9 @@ const CUSTOM_ICONS = {
|
|
|
53
55
|
lock: VpLock,
|
|
54
56
|
};
|
|
55
57
|
export const NotificationItem = (props) => {
|
|
58
|
+
const controllerProp = createMemo(() => props.controller);
|
|
59
|
+
const itemProp = createMemo(() => props.item);
|
|
60
|
+
const shellProp = createMemo(() => props.shell);
|
|
56
61
|
const now = useRelativeNow();
|
|
57
62
|
const desktopMenu = useContext(DesktopContextMenuContext);
|
|
58
63
|
const [isExiting, setIsExiting] = createSignal(false);
|
|
@@ -61,32 +66,32 @@ export const NotificationItem = (props) => {
|
|
|
61
66
|
if (exitTimer !== undefined)
|
|
62
67
|
clearTimeout(exitTimer);
|
|
63
68
|
});
|
|
64
|
-
const closable = createMemo(() => !isProgressRunning(
|
|
69
|
+
const closable = createMemo(() => !isProgressRunning(itemProp()));
|
|
65
70
|
const close = () => {
|
|
66
71
|
if (isExiting())
|
|
67
72
|
return;
|
|
68
73
|
if (!closable() || prefersReducedMotion(document)) {
|
|
69
|
-
|
|
74
|
+
controllerProp().close(itemProp().id);
|
|
70
75
|
return;
|
|
71
76
|
}
|
|
72
77
|
setIsExiting(true);
|
|
73
78
|
if (exitTimer !== undefined)
|
|
74
79
|
clearTimeout(exitTimer);
|
|
75
|
-
exitTimer = setTimeout(() =>
|
|
80
|
+
exitTimer = setTimeout(() => controllerProp().close(itemProp().id), 180);
|
|
76
81
|
};
|
|
77
|
-
const setFocus = (focused) =>
|
|
78
|
-
const setHover = (hovered) =>
|
|
79
|
-
const toggleExpanded = () =>
|
|
82
|
+
const setFocus = (focused) => controllerProp().setFocus(itemProp().id, focused);
|
|
83
|
+
const setHover = (hovered) => controllerProp().setHover(itemProp().id, hovered);
|
|
84
|
+
const toggleExpanded = () => controllerProp().toggleExpanded(itemProp().id);
|
|
80
85
|
const severityIcon = createMemo(() => {
|
|
81
|
-
const customName =
|
|
86
|
+
const customName = itemProp().icon;
|
|
82
87
|
if (customName && CUSTOM_ICONS[customName])
|
|
83
88
|
return CUSTOM_ICONS[customName];
|
|
84
|
-
return SEVERITY_ICON[
|
|
89
|
+
return SEVERITY_ICON[itemProp().severity];
|
|
85
90
|
});
|
|
86
|
-
const relativeAgo = createMemo(() => formatRelativeAgo(
|
|
87
|
-
const exactTimestamp = createMemo(() => formatExactTimestamp(
|
|
88
|
-
const isSticky = createMemo(() =>
|
|
89
|
-
const duration = createMemo(() =>
|
|
91
|
+
const relativeAgo = createMemo(() => formatRelativeAgo(itemProp().createdAt, now()));
|
|
92
|
+
const exactTimestamp = createMemo(() => formatExactTimestamp(itemProp().createdAt));
|
|
93
|
+
const isSticky = createMemo(() => controllerProp().isSticky(itemProp()));
|
|
94
|
+
const duration = createMemo(() => controllerProp().duration(itemProp()));
|
|
90
95
|
const hasTimer = createMemo(() => {
|
|
91
96
|
if (isSticky())
|
|
92
97
|
return false;
|
|
@@ -100,11 +105,11 @@ export const NotificationItem = (props) => {
|
|
|
100
105
|
const focused = isFocused();
|
|
101
106
|
if (!hovered && !focused)
|
|
102
107
|
return;
|
|
103
|
-
const item =
|
|
108
|
+
const item = itemProp();
|
|
104
109
|
if (item === undefined)
|
|
105
110
|
return;
|
|
106
111
|
const { id } = item;
|
|
107
|
-
const controller =
|
|
112
|
+
const controller = controllerProp();
|
|
108
113
|
queueMicrotask(() => {
|
|
109
114
|
if (hovered)
|
|
110
115
|
controller.setHover(id, false);
|
|
@@ -115,7 +120,7 @@ export const NotificationItem = (props) => {
|
|
|
115
120
|
const [runCounter, setRunCounter] = createSignal(0);
|
|
116
121
|
const isPaused = createMemo(() => isHovered() ||
|
|
117
122
|
isFocused() ||
|
|
118
|
-
Boolean(
|
|
123
|
+
Boolean(itemProp().hovered || itemProp().focused));
|
|
119
124
|
let wasPaused = false;
|
|
120
125
|
createEffect(() => {
|
|
121
126
|
const paused = isPaused();
|
|
@@ -124,39 +129,39 @@ export const NotificationItem = (props) => {
|
|
|
124
129
|
}
|
|
125
130
|
wasPaused = paused;
|
|
126
131
|
});
|
|
127
|
-
let prevExpanded =
|
|
132
|
+
let prevExpanded = itemProp().expanded;
|
|
128
133
|
createEffect(() => {
|
|
129
|
-
const curExpanded =
|
|
134
|
+
const curExpanded = itemProp().expanded;
|
|
130
135
|
if (curExpanded !== prevExpanded) {
|
|
131
136
|
prevExpanded = curExpanded;
|
|
132
137
|
setRunCounter((c) => c + 1);
|
|
133
138
|
}
|
|
134
139
|
});
|
|
135
|
-
const fuseKey = createMemo(() => hasTimer() ? `${
|
|
136
|
-
const announcement = () =>
|
|
137
|
-
(
|
|
140
|
+
const fuseKey = createMemo(() => hasTimer() ? `${itemProp().id}-${duration()}-${runCounter()}` : null);
|
|
141
|
+
const announcement = () => itemProp().announce ??
|
|
142
|
+
(itemProp().severity === 'error' ? 'assertive' : 'polite');
|
|
138
143
|
createEffect(() => {
|
|
139
144
|
if (props.inCenter)
|
|
140
145
|
return;
|
|
141
|
-
const title =
|
|
142
|
-
const body =
|
|
146
|
+
const title = itemProp().title;
|
|
147
|
+
const body = itemProp().body;
|
|
143
148
|
const text = body ? `${title}: ${body}` : title;
|
|
144
149
|
if (announcement() === 'assertive') {
|
|
145
|
-
|
|
150
|
+
controllerProp().announcer.assertive(text);
|
|
146
151
|
}
|
|
147
152
|
else {
|
|
148
|
-
|
|
153
|
+
controllerProp().announcer.polite(text);
|
|
149
154
|
}
|
|
150
155
|
});
|
|
151
156
|
const bodyHtml = createMemo(() => {
|
|
152
|
-
const body =
|
|
157
|
+
const body = itemProp().body;
|
|
153
158
|
if (!body)
|
|
154
159
|
return '';
|
|
155
|
-
if (
|
|
156
|
-
return renderNotificationMarkdown(body,
|
|
160
|
+
if (itemProp().markdown)
|
|
161
|
+
return renderNotificationMarkdown(body, shellProp() !== null);
|
|
157
162
|
return escapeHtml(body).replace(/\n/g, '<br>');
|
|
158
163
|
});
|
|
159
|
-
const openLink = (url) =>
|
|
164
|
+
const openLink = (url) => controllerProp().openExternal(url);
|
|
160
165
|
const handleBodyClick = (event) => {
|
|
161
166
|
const target = event.target;
|
|
162
167
|
const link = target?.closest('a');
|
|
@@ -168,7 +173,7 @@ export const NotificationItem = (props) => {
|
|
|
168
173
|
openLink(href);
|
|
169
174
|
return;
|
|
170
175
|
}
|
|
171
|
-
const shell =
|
|
176
|
+
const shell = shellProp();
|
|
172
177
|
if (shell === null) {
|
|
173
178
|
event.preventDefault();
|
|
174
179
|
return;
|
|
@@ -176,16 +181,17 @@ export const NotificationItem = (props) => {
|
|
|
176
181
|
const interactive = target?.closest('a, button, [role="button"], input, select, textarea');
|
|
177
182
|
if (interactive)
|
|
178
183
|
return;
|
|
179
|
-
const route =
|
|
184
|
+
const route = itemProp().defaultRoute;
|
|
180
185
|
if (route)
|
|
181
186
|
shell.navigate(route);
|
|
182
187
|
};
|
|
183
188
|
const handleContextMenu = (event) => {
|
|
184
189
|
if (!desktopMenu)
|
|
185
190
|
return;
|
|
186
|
-
const
|
|
187
|
-
const
|
|
188
|
-
|
|
191
|
+
const card = itemProp();
|
|
192
|
+
const text = `${card.title}${card.body ? `\n${card.body}` : ''}`.trim();
|
|
193
|
+
const match = card.vendorError
|
|
194
|
+
? controllerProp().resolveVendorError(card.vendorError)
|
|
189
195
|
: null;
|
|
190
196
|
event.preventDefault();
|
|
191
197
|
event.stopPropagation();
|
|
@@ -223,7 +229,7 @@ export const NotificationItem = (props) => {
|
|
|
223
229
|
]);
|
|
224
230
|
};
|
|
225
231
|
const openGearMenu = (event) => {
|
|
226
|
-
const shell =
|
|
232
|
+
const shell = shellProp();
|
|
227
233
|
if (shell === null)
|
|
228
234
|
return;
|
|
229
235
|
if (!desktopMenu)
|
|
@@ -231,18 +237,16 @@ export const NotificationItem = (props) => {
|
|
|
231
237
|
event.preventDefault();
|
|
232
238
|
event.stopPropagation();
|
|
233
239
|
if (desktopMenu.state() &&
|
|
234
|
-
lastGearOpenedFor.get(desktopMenu) ===
|
|
240
|
+
lastGearOpenedFor.get(desktopMenu) === itemProp().id) {
|
|
235
241
|
desktopMenu.close();
|
|
236
242
|
lastGearOpenedFor.set(desktopMenu, null);
|
|
237
243
|
return;
|
|
238
244
|
}
|
|
239
|
-
lastGearOpenedFor.set(desktopMenu,
|
|
245
|
+
lastGearOpenedFor.set(desktopMenu, itemProp().id);
|
|
240
246
|
const gearTrigger = event.currentTarget;
|
|
241
|
-
const source =
|
|
242
|
-
const dontShowKey =
|
|
243
|
-
const remindKey =
|
|
244
|
-
props.item.remindKey ??
|
|
245
|
-
deriveImplicitRemindKey(source ?? 'general', props.item.title);
|
|
247
|
+
const source = itemProp().source;
|
|
248
|
+
const dontShowKey = itemProp().neverShowAgainKey;
|
|
249
|
+
const remindKey = cardRemindKey(itemProp());
|
|
246
250
|
const items = [];
|
|
247
251
|
if (dontShowKey) {
|
|
248
252
|
items.push({
|
|
@@ -293,7 +297,7 @@ export const NotificationItem = (props) => {
|
|
|
293
297
|
onSelect: () => shell.setSourceMuted(source, !muted),
|
|
294
298
|
});
|
|
295
299
|
}
|
|
296
|
-
const secondary =
|
|
300
|
+
const secondary = itemProp().secondaryActions;
|
|
297
301
|
if (secondary && secondary.length > 0) {
|
|
298
302
|
if (items.length > 0)
|
|
299
303
|
items.push({ type: 'separator' });
|
|
@@ -323,9 +327,9 @@ export const NotificationItem = (props) => {
|
|
|
323
327
|
close();
|
|
324
328
|
}
|
|
325
329
|
};
|
|
326
|
-
return (<div class={`${styles.item} card ${isExiting() ? styles.itemExiting : ''}`} id={props.inCenter ? undefined : `notification-card-${
|
|
327
|
-
severity: t(NOTIFICATION_SEVERITY_LABELS[
|
|
328
|
-
title:
|
|
330
|
+
return (<div class={`${styles.item} card ${isExiting() ? styles.itemExiting : ''}`} id={props.inCenter ? undefined : `notification-card-${itemProp().id}`} tabIndex={-1} data-severity={itemProp().severity} data-expanded={itemProp().expanded} data-edge={props.corner === undefined ? undefined : toastCornerEdge(props.corner)} data-has-actions={props.item.actions && props.item.actions.length > 0 ? 'true' : 'false'} data-has-timer={hasTimer() ? 'true' : 'false'} {...(props.inCenter ? notificationEntryMark : { 'aria-live': announcement() })} aria-atomic={props.inCenter ? undefined : 'true'} aria-label={t('{severity}: {title}', {
|
|
331
|
+
severity: t(NOTIFICATION_SEVERITY_LABELS[itemProp().severity]),
|
|
332
|
+
title: itemProp().title,
|
|
329
333
|
})} onMouseEnter={() => {
|
|
330
334
|
setIsHovered(true);
|
|
331
335
|
setHover(true);
|
|
@@ -340,17 +344,17 @@ export const NotificationItem = (props) => {
|
|
|
340
344
|
setFocus(false);
|
|
341
345
|
}} onContextMenu={handleContextMenu}>
|
|
342
346
|
<div class={styles.mainRow}>
|
|
343
|
-
<span class={styles.icon} data-severity={
|
|
347
|
+
<span class={styles.icon} data-severity={itemProp().severity} aria-hidden="true">
|
|
344
348
|
<Dynamic component={severityIcon()} size={16}/>
|
|
345
349
|
</span>
|
|
346
350
|
<div class={`${styles.body} body`}>
|
|
347
351
|
<div class={styles.titleRow}>
|
|
348
|
-
<span class={`${styles.title} title`}>{
|
|
352
|
+
<span class={`${styles.title} title`}>{itemProp().title}</span>
|
|
349
353
|
<HoverTooltip content={exactTimestamp()} delayMs={400}>
|
|
350
354
|
<span class={styles.timestamp}>{relativeAgo()}</span>
|
|
351
355
|
</HoverTooltip>
|
|
352
356
|
</div>
|
|
353
|
-
<Show when={
|
|
357
|
+
<Show when={itemProp().body}>
|
|
354
358
|
<OverlayScrollArea rootClass={styles.subtitleCollapse} viewportClass={styles.subtitleViewport} hideHorizontal>
|
|
355
359
|
<div class={styles.subtitle} tabIndex={-1} onClick={handleBodyClick} onKeyDown={(e) => {
|
|
356
360
|
if (isKey(e, 'Enter'))
|
|
@@ -360,12 +364,12 @@ export const NotificationItem = (props) => {
|
|
|
360
364
|
</Show>
|
|
361
365
|
</div>
|
|
362
366
|
<Panel.Toolbar class={styles.toolbar}>
|
|
363
|
-
<Show when={
|
|
364
|
-
<Button variant="ghost" size="sm" iconOnly aria-label={
|
|
367
|
+
<Show when={itemProp().body}>
|
|
368
|
+
<Button variant="ghost" size="sm" iconOnly aria-label={itemProp().expanded ? t('Collapse') : t('Expand')} title={itemProp().expanded ? t('Collapse') : t('Expand')} onClick={toggleExpanded}>
|
|
365
369
|
<VpChevronDown class={`${iconScale.iconMd} ${styles.chevron}`}/>
|
|
366
370
|
</Button>
|
|
367
371
|
</Show>
|
|
368
|
-
<Show when={
|
|
372
|
+
<Show when={shellProp() !== null}>
|
|
369
373
|
<Button variant="ghost" size="sm" iconOnly aria-label={t('More actions')} title={t('More actions')} onMouseDown={(event) => event.stopPropagation()} onClick={openGearMenu}>
|
|
370
374
|
<VpGear class={iconScale.iconMd}/>
|
|
371
375
|
</Button>
|
|
@@ -396,7 +400,7 @@ export const NotificationItem = (props) => {
|
|
|
396
400
|
<div class={styles.detailsRow}>
|
|
397
401
|
<Show when={props.item.actions && props.item.actions.length > 0}>
|
|
398
402
|
<div class={styles.actions}>
|
|
399
|
-
<For each={
|
|
403
|
+
<For each={itemProp().actions}>
|
|
400
404
|
{(action) => (<Button variant={action.primary ? 'primary' : 'secondary'} size="sm" class={`${action.primary ? 'primary ' : ''}btn`} onClick={() => void runAction(action)}>
|
|
401
405
|
{action.label}
|
|
402
406
|
</Button>)}
|
|
@@ -408,7 +412,7 @@ export const NotificationItem = (props) => {
|
|
|
408
412
|
props.item.source !== 'general' &&
|
|
409
413
|
props.item.source !== 'undefined'}>
|
|
410
414
|
<span class={styles.source}>
|
|
411
|
-
{t('Source: {source}', { source: String(
|
|
415
|
+
{t('Source: {source}', { source: String(itemProp().source) })}
|
|
412
416
|
</span>
|
|
413
417
|
</Show>
|
|
414
418
|
</div>
|
|
@@ -417,11 +421,11 @@ export const NotificationItem = (props) => {
|
|
|
417
421
|
|
|
418
422
|
<Show when={props.item.progress && !props.item.progress.done}>
|
|
419
423
|
<div class={styles.progressRow}>
|
|
420
|
-
<Show when={typeof
|
|
421
|
-
<Progress value={
|
|
424
|
+
<Show when={typeof itemProp().progress?.value === 'number'} fallback={<Progress indeterminate size="2xs" class={styles.progress} ariaLabel={t('Progress')}/>}>
|
|
425
|
+
<Progress value={itemProp().progress?.value ?? 0} max={1} size="2xs" class={styles.progress} ariaLabel={t('Progress')}/>
|
|
422
426
|
</Show>
|
|
423
|
-
<Show when={
|
|
424
|
-
<Button iconOnly variant="ghost" size="sm" class={styles.progressCancel} title={t('Cancel')} aria-label={t('Cancel')} onClick={() =>
|
|
427
|
+
<Show when={itemProp().progress?.onCancel}>
|
|
428
|
+
<Button iconOnly variant="ghost" size="sm" class={styles.progressCancel} title={t('Cancel')} aria-label={t('Cancel')} onClick={() => itemProp().progress?.onCancel?.()}>
|
|
425
429
|
<VpTreeClose />
|
|
426
430
|
</Button>
|
|
427
431
|
</Show>
|