@dxos/plugin-deck 0.8.4-main.422d1c7879 → 0.8.4-main.4668b7de9b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +102 -5
- package/PLUGIN.mdl +541 -0
- package/README.md +1 -1
- package/dist/lib/neutral/DeckLayout-YABVXRDU.mjs +291 -0
- package/dist/lib/neutral/DeckLayout-YABVXRDU.mjs.map +7 -0
- package/dist/lib/neutral/DeckPlugin.mjs +87 -0
- package/dist/lib/neutral/DeckPlugin.mjs.map +7 -0
- package/dist/lib/neutral/DeckPlugin.node.mjs +18 -0
- package/dist/lib/neutral/DeckPlugin.node.mjs.map +7 -0
- package/dist/lib/neutral/DeckPlugin.workerd.mjs +16 -0
- package/dist/lib/neutral/DeckPlugin.workerd.mjs.map +7 -0
- package/dist/lib/neutral/DeckSettings-W5I57OXM.mjs +27 -0
- package/dist/lib/neutral/DeckSettings-W5I57OXM.mjs.map +7 -0
- package/dist/lib/{browser/add-toast-EUN62IUE.mjs → neutral/add-toast-TNB6DXWU.mjs} +5 -5
- package/dist/lib/{browser/add-toast-EUN62IUE.mjs.map → neutral/add-toast-TNB6DXWU.mjs.map} +2 -2
- package/dist/lib/{browser/adjust-XWB6ZZ6U.mjs → neutral/adjust-HNU5CCRO.mjs} +15 -17
- package/dist/lib/neutral/adjust-HNU5CCRO.mjs.map +7 -0
- package/dist/lib/neutral/app-graph-builder-HMLT627T.mjs +129 -0
- package/dist/lib/neutral/app-graph-builder-HMLT627T.mjs.map +7 -0
- package/dist/lib/neutral/capabilities/index.mjs +25 -0
- package/dist/lib/neutral/capabilities/index.mjs.map +7 -0
- package/dist/lib/neutral/check-app-scheme-A7FZVNZO.mjs +10 -0
- package/dist/lib/neutral/chunk-BS4EOYMK.mjs +282 -0
- package/dist/lib/neutral/chunk-BS4EOYMK.mjs.map +7 -0
- package/dist/lib/neutral/chunk-GBIGQKYW.mjs +112 -0
- package/dist/lib/neutral/chunk-GBIGQKYW.mjs.map +7 -0
- package/dist/lib/{browser/chunk-KUTDCWZF.mjs → neutral/chunk-GLB73Q6U.mjs} +2 -10
- package/dist/lib/{browser/chunk-KUTDCWZF.mjs.map → neutral/chunk-GLB73Q6U.mjs.map} +2 -2
- package/dist/lib/neutral/chunk-OQGC7JYT.mjs +8 -0
- package/dist/lib/neutral/chunk-OQGC7JYT.mjs.map +7 -0
- package/dist/lib/neutral/chunk-PYEY5SEC.mjs +37 -0
- package/dist/lib/neutral/chunk-PYEY5SEC.mjs.map +7 -0
- package/dist/lib/neutral/chunk-Q534NBCS.mjs +1305 -0
- package/dist/lib/neutral/chunk-Q534NBCS.mjs.map +7 -0
- package/dist/lib/neutral/chunk-VHETZ22W.mjs +101 -0
- package/dist/lib/neutral/chunk-VHETZ22W.mjs.map +7 -0
- package/dist/lib/{browser/chunk-DF2VZ6W3.mjs → neutral/chunk-ZYYOSX5I.mjs} +1 -1
- package/dist/lib/{browser/chunk-DF2VZ6W3.mjs.map → neutral/chunk-ZYYOSX5I.mjs.map} +2 -2
- package/dist/lib/{browser/close-JXK73YIM.mjs → neutral/close-ASKR22A6.mjs} +12 -12
- package/dist/lib/{browser/close-JXK73YIM.mjs.map → neutral/close-ASKR22A6.mjs.map} +2 -2
- package/dist/lib/neutral/components/index.mjs +126 -0
- package/dist/lib/neutral/components/index.mjs.map +7 -0
- package/dist/lib/neutral/containers/index.mjs +32 -0
- package/dist/lib/neutral/containers/index.mjs.map +7 -0
- package/dist/lib/neutral/hooks/index.mjs +159 -0
- package/dist/lib/neutral/hooks/index.mjs.map +7 -0
- package/dist/lib/{node-esm/types → neutral}/index.mjs +13 -8
- package/dist/lib/neutral/meta.json +1 -0
- package/dist/lib/neutral/meta.mjs +8 -0
- package/dist/lib/neutral/notification-tracker-BYKXOXDE.mjs +128 -0
- package/dist/lib/neutral/notification-tracker-BYKXOXDE.mjs.map +7 -0
- package/dist/lib/{browser/open-K2JOEW2E.mjs → neutral/open-IFIEYVHG.mjs} +34 -25
- package/dist/lib/neutral/open-IFIEYVHG.mjs.map +7 -0
- package/dist/lib/neutral/operation-handler-266CVMTW.mjs +13 -0
- package/dist/lib/neutral/operation-handler-266CVMTW.mjs.map +7 -0
- package/dist/lib/neutral/operations/index.mjs +8 -0
- package/dist/lib/neutral/operations/index.mjs.map +7 -0
- package/dist/lib/neutral/plugin.mjs +16 -0
- package/dist/lib/neutral/plugin.mjs.map +7 -0
- package/dist/lib/neutral/react-root-HH5DEUOG.mjs +44 -0
- package/dist/lib/neutral/react-root-HH5DEUOG.mjs.map +7 -0
- package/dist/lib/neutral/react-surface-3UVVCK3O.mjs +34 -0
- package/dist/lib/neutral/react-surface-3UVVCK3O.mjs.map +7 -0
- package/dist/lib/{browser/revert-workspace-BNIR5U64.mjs → neutral/revert-workspace-B2QLT2C4.mjs} +5 -5
- package/dist/lib/{browser/revert-workspace-BNIR5U64.mjs.map → neutral/revert-workspace-B2QLT2C4.mjs.map} +2 -2
- package/dist/lib/{browser/scroll-into-view-4GSKC3GA.mjs → neutral/scroll-into-view-B52C3PJO.mjs} +5 -5
- package/dist/lib/{browser/scroll-into-view-4GSKC3GA.mjs.map → neutral/scroll-into-view-B52C3PJO.mjs.map} +2 -2
- package/dist/lib/{browser/set-XCG6NIAO.mjs → neutral/set-PA35ONXO.mjs} +11 -11
- package/dist/lib/{browser/set-XCG6NIAO.mjs.map → neutral/set-PA35ONXO.mjs.map} +2 -2
- package/dist/lib/{browser/set-layout-mode-BEVNGOY2.mjs → neutral/set-layout-mode-RPCCPQRB.mjs} +10 -15
- package/dist/lib/neutral/set-layout-mode-RPCCPQRB.mjs.map +7 -0
- package/dist/lib/neutral/settings-EGNYUM4T.mjs +33 -0
- package/dist/lib/neutral/settings-EGNYUM4T.mjs.map +7 -0
- package/dist/lib/neutral/state-IIDXMQUO.mjs +86 -0
- package/dist/lib/neutral/state-IIDXMQUO.mjs.map +7 -0
- package/dist/lib/{browser/switch-workspace-ICJJWNFT.mjs → neutral/switch-workspace-LZF4KZXH.mjs} +9 -17
- package/dist/lib/neutral/switch-workspace-LZF4KZXH.mjs.map +7 -0
- package/dist/lib/neutral/translations.mjs +59 -0
- package/dist/lib/neutral/translations.mjs.map +7 -0
- package/dist/lib/{browser → neutral}/types/index.mjs +7 -5
- package/dist/lib/neutral/types/index.mjs.map +7 -0
- package/dist/lib/{browser/update-companion-VPCBH3YT.mjs → neutral/update-companion-YUCZZVGY.mjs} +7 -7
- package/dist/lib/neutral/update-companion-YUCZZVGY.mjs.map +7 -0
- package/dist/lib/{browser/update-complementary-74DEQY6T.mjs → neutral/update-complementary-7FZNB55J.mjs} +6 -6
- package/dist/lib/neutral/update-complementary-7FZNB55J.mjs.map +7 -0
- package/dist/lib/{browser/update-dialog-6TDUYI5R.mjs → neutral/update-dialog-FNQTSSAP.mjs} +5 -5
- package/dist/lib/{browser/update-dialog-6TDUYI5R.mjs.map → neutral/update-dialog-FNQTSSAP.mjs.map} +2 -2
- package/dist/lib/neutral/update-plank-size-3YW4NXEY.mjs +26 -0
- package/dist/lib/neutral/update-plank-size-3YW4NXEY.mjs.map +7 -0
- package/dist/lib/{browser/update-popover-W7E2Z5T6.mjs → neutral/update-popover-G2VUD7E6.mjs} +5 -5
- package/dist/lib/{browser/update-popover-W7E2Z5T6.mjs.map → neutral/update-popover-G2VUD7E6.mjs.map} +2 -2
- package/dist/lib/{browser/update-sidebar-H3A6ZFRU.mjs → neutral/update-sidebar-KRHPUHUB.mjs} +6 -6
- package/dist/lib/{browser/update-sidebar-H3A6ZFRU.mjs.map → neutral/update-sidebar-KRHPUHUB.mjs.map} +2 -2
- package/dist/lib/neutral/url-handler-4SW6BFAC.mjs +229 -0
- package/dist/lib/neutral/url-handler-4SW6BFAC.mjs.map +7 -0
- package/dist/types/src/DeckPlugin.d.ts +1 -0
- package/dist/types/src/DeckPlugin.d.ts.map +1 -1
- package/dist/types/src/DeckPlugin.node.d.ts +4 -0
- package/dist/types/src/DeckPlugin.node.d.ts.map +1 -0
- package/dist/types/src/DeckPlugin.test.d.ts +2 -0
- package/dist/types/src/DeckPlugin.test.d.ts.map +1 -0
- package/dist/types/src/DeckPlugin.workerd.d.ts +4 -0
- package/dist/types/src/DeckPlugin.workerd.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
- package/dist/types/src/capabilities/check-app-scheme.d.ts +1 -1
- package/dist/types/src/capabilities/check-app-scheme.d.ts.map +1 -1
- package/dist/types/src/capabilities/index.d.ts +30 -29
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/notification-tracker.d.ts +13 -0
- package/dist/types/src/capabilities/notification-tracker.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-handler.d.ts +1 -1
- package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-root.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
- package/dist/types/src/capabilities/settings.d.ts.map +1 -1
- package/dist/types/src/capabilities/state.d.ts +28 -28
- package/dist/types/src/capabilities/state.d.ts.map +1 -1
- package/dist/types/src/capabilities/tools.d.ts.map +1 -1
- package/dist/types/src/capabilities/url-handler.d.ts +1 -1
- package/dist/types/src/capabilities/url-handler.d.ts.map +1 -1
- package/dist/types/src/components/DeckSettings/DeckSettings.d.ts.map +1 -1
- package/dist/types/src/components/DeckSettings/DeckSettings.stories.d.ts +44 -52
- package/dist/types/src/components/DeckSettings/DeckSettings.stories.d.ts.map +1 -1
- package/dist/types/src/components/Matrix/Matrix.d.ts +2 -2
- package/dist/types/src/components/Matrix/Matrix.d.ts.map +1 -1
- package/dist/types/src/components/Matrix/Matrix.stories.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/Banner.d.ts +1 -1
- package/dist/types/src/containers/Deck/Banner.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/Deck.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/Deck.stories.d.ts +44 -52
- package/dist/types/src/containers/Deck/Deck.stories.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/DeckContent.d.ts +4 -4
- package/dist/types/src/containers/Deck/DeckContent.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/DeckRoot.d.ts +5 -8
- package/dist/types/src/containers/Deck/DeckRoot.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/DeckViewport.d.ts +4 -7
- package/dist/types/src/containers/Deck/DeckViewport.d.ts.map +1 -1
- package/dist/types/src/containers/Deck/StatusBar.d.ts.map +1 -1
- package/dist/types/src/containers/DeckLayout/DeckLayout.d.ts.map +1 -1
- package/dist/types/src/containers/DeckLayout/DeckLayout.stories.d.ts +44 -52
- package/dist/types/src/containers/DeckLayout/DeckLayout.stories.d.ts.map +1 -1
- package/dist/types/src/containers/DeckLayout/Popover.d.ts.map +1 -1
- package/dist/types/src/containers/DeckLayout/Toast.d.ts +1 -1
- package/dist/types/src/containers/DeckLayout/Toast.d.ts.map +1 -1
- package/dist/types/src/containers/DeckLayout/index.d.ts.map +1 -1
- package/dist/types/src/containers/Plank/Plank.d.ts +1 -1
- package/dist/types/src/containers/Plank/Plank.d.ts.map +1 -1
- package/dist/types/src/containers/Plank/Plank.stories.d.ts +44 -52
- package/dist/types/src/containers/Plank/Plank.stories.d.ts.map +1 -1
- package/dist/types/src/containers/Plank/PlankComponent.d.ts.map +1 -1
- package/dist/types/src/containers/Plank/PlankContent.d.ts +1 -1
- package/dist/types/src/containers/Plank/PlankError.d.ts +1 -1
- package/dist/types/src/containers/Plank/PlankError.d.ts.map +1 -1
- package/dist/types/src/containers/Plank/PlankRoot.d.ts +1 -1
- package/dist/types/src/containers/Plank/PlankRoot.d.ts.map +1 -1
- package/dist/types/src/containers/Sidebar/ComplementarySidebar.d.ts.map +1 -1
- package/dist/types/src/containers/Sidebar/Sidebar.d.ts.map +1 -1
- package/dist/types/src/containers/Sidebar/SidebarButton.d.ts +1 -1
- package/dist/types/src/containers/Sidebar/SidebarButton.d.ts.map +1 -1
- package/dist/types/src/hooks/index.d.ts +0 -1
- package/dist/types/src/hooks/index.d.ts.map +1 -1
- package/dist/types/src/hooks/useBreakpoints.d.ts +1 -1
- package/dist/types/src/hooks/useCompanions.d.ts.map +1 -1
- package/dist/types/src/hooks/useDeckCompanions.d.ts +1 -1
- package/dist/types/src/hooks/useDeckCompanions.d.ts.map +1 -1
- package/dist/types/src/hooks/useMainSize.d.ts.map +1 -1
- package/dist/types/src/hooks/useNodeActionExpander.d.ts.map +1 -1
- package/dist/types/src/hooks/useSelectedCompanion.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +1 -3
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/layout.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +1 -1
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/operations/add-toast.d.ts +1 -1
- package/dist/types/src/operations/add-toast.d.ts.map +1 -1
- package/dist/types/src/operations/adjust.d.ts +3 -3
- package/dist/types/src/operations/adjust.d.ts.map +1 -1
- package/dist/types/src/operations/close.d.ts +1 -1
- package/dist/types/src/operations/close.d.ts.map +1 -1
- package/dist/types/src/operations/helpers.d.ts.map +1 -1
- package/dist/types/src/operations/index.d.ts +1 -2
- package/dist/types/src/operations/index.d.ts.map +1 -1
- package/dist/types/src/operations/open.d.ts +1 -1
- package/dist/types/src/operations/open.d.ts.map +1 -1
- package/dist/types/src/operations/revert-workspace.d.ts +1 -1
- package/dist/types/src/operations/revert-workspace.d.ts.map +1 -1
- package/dist/types/src/operations/scroll-into-view.d.ts +1 -1
- package/dist/types/src/operations/scroll-into-view.d.ts.map +1 -1
- package/dist/types/src/operations/set-layout-mode.d.ts +1 -1
- package/dist/types/src/operations/set-layout-mode.d.ts.map +1 -1
- package/dist/types/src/operations/set.d.ts +1 -1
- package/dist/types/src/operations/set.d.ts.map +1 -1
- package/dist/types/src/operations/switch-workspace.d.ts +1 -1
- package/dist/types/src/operations/switch-workspace.d.ts.map +1 -1
- package/dist/types/src/operations/update-companion.d.ts +1 -1
- package/dist/types/src/operations/update-companion.d.ts.map +1 -1
- package/dist/types/src/operations/update-complementary.d.ts +1 -1
- package/dist/types/src/operations/update-complementary.d.ts.map +1 -1
- package/dist/types/src/operations/update-dialog.d.ts +1 -1
- package/dist/types/src/operations/update-dialog.d.ts.map +1 -1
- package/dist/types/src/operations/update-plank-size.d.ts +3 -3
- package/dist/types/src/operations/update-plank-size.d.ts.map +1 -1
- package/dist/types/src/operations/update-popover.d.ts +1 -1
- package/dist/types/src/operations/update-popover.d.ts.map +1 -1
- package/dist/types/src/operations/update-sidebar.d.ts +1 -1
- package/dist/types/src/operations/update-sidebar.d.ts.map +1 -1
- package/dist/types/src/plugin.d.ts +4 -0
- package/dist/types/src/plugin.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +44 -53
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/DeckCapabilities.d.ts +188 -0
- package/dist/types/src/types/DeckCapabilities.d.ts.map +1 -0
- package/dist/types/src/types/DeckEvents.d.ts +5 -0
- package/dist/types/src/types/DeckEvents.d.ts.map +1 -0
- package/dist/types/src/types/DeckOperation.d.ts +15 -0
- package/dist/types/src/types/DeckOperation.d.ts.map +1 -0
- package/dist/types/src/types/Settings.d.ts +4 -5
- package/dist/types/src/types/Settings.d.ts.map +1 -1
- package/dist/types/src/types/index.d.ts +3 -2
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/src/types/schema.d.ts +6 -7
- package/dist/types/src/types/schema.d.ts.map +1 -1
- package/dist/types/src/util/layoutAppliesTopbar.d.ts.map +1 -1
- package/dist/types/src/util/plank-url-params.d.ts.map +1 -1
- package/dist/types/src/util/sanitize-persisted-state.d.ts.map +1 -1
- package/dist/types/src/util/set-active.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +105 -69
- package/src/DeckPlugin.node.ts +17 -0
- package/src/DeckPlugin.test.ts +27 -0
- package/src/DeckPlugin.ts +16 -4
- package/src/DeckPlugin.workerd.ts +16 -0
- package/src/capabilities/app-graph-builder.ts +4 -4
- package/src/capabilities/index.ts +2 -1
- package/src/capabilities/notification-tracker.ts +132 -0
- package/src/capabilities/operation-handler.ts +1 -1
- package/src/capabilities/react-root.tsx +20 -15
- package/src/capabilities/react-surface.tsx +2 -2
- package/src/capabilities/settings.ts +1 -2
- package/src/capabilities/tools.ts +1 -1
- package/src/capabilities/url-handler.ts +73 -2
- package/src/components/DeckSettings/DeckSettings.stories.tsx +2 -2
- package/src/components/DeckSettings/DeckSettings.tsx +8 -47
- package/src/components/Matrix/Matrix.stories.tsx +2 -2
- package/src/components/Matrix/Matrix.tsx +1 -1
- package/src/containers/Deck/Banner.tsx +2 -2
- package/src/containers/Deck/Deck.stories.tsx +1 -1
- package/src/containers/Deck/DeckContent.tsx +2 -5
- package/src/containers/Deck/DeckViewport.tsx +7 -13
- package/src/containers/DeckLayout/ActiveNode.tsx +1 -1
- package/src/containers/DeckLayout/DeckLayout.stories.tsx +8 -10
- package/src/containers/DeckLayout/Fallback.tsx +2 -2
- package/src/containers/DeckLayout/Popover.tsx +31 -26
- package/src/containers/DeckLayout/Toast.tsx +19 -29
- package/src/containers/Plank/Plank.stories.tsx +3 -3
- package/src/containers/Plank/PlankComponent.tsx +3 -2
- package/src/containers/Plank/PlankContent.tsx +1 -1
- package/src/containers/Plank/PlankError.tsx +6 -3
- package/src/containers/Plank/PlankHeading.tsx +5 -5
- package/src/containers/Plank/PlankLoading.tsx +1 -1
- package/src/containers/Plank/PlankRoot.tsx +1 -1
- package/src/containers/Sidebar/ComplementarySidebar.tsx +20 -39
- package/src/containers/Sidebar/Sidebar.tsx +5 -10
- package/src/containers/Sidebar/SidebarButton.tsx +7 -1
- package/src/hooks/index.ts +0 -1
- package/src/hooks/useDeckCompanions.ts +1 -1
- package/src/index.ts +1 -3
- package/src/meta.ts +24 -6
- package/src/operations/add-toast.ts +1 -1
- package/src/operations/adjust.ts +4 -5
- package/src/operations/close.ts +2 -2
- package/src/operations/index.ts +1 -4
- package/src/operations/open.ts +29 -13
- package/src/operations/revert-workspace.ts +1 -1
- package/src/operations/scroll-into-view.ts +1 -1
- package/src/operations/set-layout-mode.ts +1 -1
- package/src/operations/set.ts +2 -2
- package/src/operations/switch-workspace.ts +8 -2
- package/src/operations/update-companion.ts +1 -1
- package/src/operations/update-complementary.ts +1 -1
- package/src/operations/update-dialog.ts +1 -1
- package/src/operations/update-plank-size.ts +3 -4
- package/src/operations/update-popover.ts +1 -1
- package/src/operations/update-sidebar.ts +1 -1
- package/src/plugin.ts +11 -0
- package/src/translations.ts +4 -12
- package/src/types/DeckCapabilities.ts +34 -0
- package/src/types/DeckEvents.ts +21 -0
- package/src/{operations/definitions.ts → types/DeckOperation.ts} +13 -6
- package/src/types/Settings.ts +25 -6
- package/src/types/index.ts +4 -2
- package/src/types/schema.ts +0 -2
- package/src/vite-env.d.ts +5 -0
- package/dist/lib/browser/adjust-XWB6ZZ6U.mjs.map +0 -7
- package/dist/lib/browser/chunk-5LM6A3EC.mjs +0 -208
- package/dist/lib/browser/chunk-5LM6A3EC.mjs.map +0 -7
- package/dist/lib/browser/chunk-BRZAVPMC.mjs +0 -48
- package/dist/lib/browser/chunk-BRZAVPMC.mjs.map +0 -7
- package/dist/lib/browser/chunk-FRVCL5NO.mjs +0 -72
- package/dist/lib/browser/chunk-FRVCL5NO.mjs.map +0 -7
- package/dist/lib/browser/index.mjs +0 -201
- package/dist/lib/browser/index.mjs.map +0 -7
- package/dist/lib/browser/meta.json +0 -1
- package/dist/lib/browser/open-K2JOEW2E.mjs.map +0 -7
- package/dist/lib/browser/operations/index.mjs +0 -13
- package/dist/lib/browser/operations/index.mjs.map +0 -7
- package/dist/lib/browser/set-layout-mode-BEVNGOY2.mjs.map +0 -7
- package/dist/lib/browser/show-undo-5RQNREEB.mjs +0 -59
- package/dist/lib/browser/show-undo-5RQNREEB.mjs.map +0 -7
- package/dist/lib/browser/switch-workspace-ICJJWNFT.mjs.map +0 -7
- package/dist/lib/browser/update-companion-VPCBH3YT.mjs.map +0 -7
- package/dist/lib/browser/update-complementary-74DEQY6T.mjs.map +0 -7
- package/dist/lib/browser/update-plank-size-5VHZOTHE.mjs +0 -28
- package/dist/lib/browser/update-plank-size-5VHZOTHE.mjs.map +0 -7
- package/dist/lib/node-esm/add-toast-AZM7NFNM.mjs +0 -25
- package/dist/lib/node-esm/add-toast-AZM7NFNM.mjs.map +0 -7
- package/dist/lib/node-esm/adjust-ICALXQ6F.mjs +0 -96
- package/dist/lib/node-esm/adjust-ICALXQ6F.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-A63Q53TW.mjs +0 -73
- package/dist/lib/node-esm/chunk-A63Q53TW.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-B7WZXRW4.mjs +0 -209
- package/dist/lib/node-esm/chunk-B7WZXRW4.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs +0 -11
- package/dist/lib/node-esm/chunk-IRWCUYJY.mjs +0 -71
- package/dist/lib/node-esm/chunk-IRWCUYJY.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-MB4SDDVY.mjs +0 -50
- package/dist/lib/node-esm/chunk-MB4SDDVY.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-MLVJ2ODW.mjs +0 -32
- package/dist/lib/node-esm/chunk-MLVJ2ODW.mjs.map +0 -7
- package/dist/lib/node-esm/close-GC5V3GD5.mjs +0 -45
- package/dist/lib/node-esm/close-GC5V3GD5.mjs.map +0 -7
- package/dist/lib/node-esm/index.mjs +0 -202
- package/dist/lib/node-esm/index.mjs.map +0 -7
- package/dist/lib/node-esm/meta.json +0 -1
- package/dist/lib/node-esm/open-XXEHIR6G.mjs +0 -151
- package/dist/lib/node-esm/open-XXEHIR6G.mjs.map +0 -7
- package/dist/lib/node-esm/operations/index.mjs +0 -14
- package/dist/lib/node-esm/operations/index.mjs.map +0 -7
- package/dist/lib/node-esm/revert-workspace-WCXAL5C6.mjs +0 -22
- package/dist/lib/node-esm/revert-workspace-WCXAL5C6.mjs.map +0 -7
- package/dist/lib/node-esm/scroll-into-view-2ZNU44ZO.mjs +0 -22
- package/dist/lib/node-esm/scroll-into-view-2ZNU44ZO.mjs.map +0 -7
- package/dist/lib/node-esm/set-5MO2JCUQ.mjs +0 -38
- package/dist/lib/node-esm/set-5MO2JCUQ.mjs.map +0 -7
- package/dist/lib/node-esm/set-layout-mode-3RK4HIG7.mjs +0 -91
- package/dist/lib/node-esm/set-layout-mode-3RK4HIG7.mjs.map +0 -7
- package/dist/lib/node-esm/show-undo-WV7SAYGJ.mjs +0 -60
- package/dist/lib/node-esm/show-undo-WV7SAYGJ.mjs.map +0 -7
- package/dist/lib/node-esm/switch-workspace-VNM75H66.mjs +0 -69
- package/dist/lib/node-esm/switch-workspace-VNM75H66.mjs.map +0 -7
- package/dist/lib/node-esm/update-companion-SIB3GWH7.mjs +0 -33
- package/dist/lib/node-esm/update-companion-SIB3GWH7.mjs.map +0 -7
- package/dist/lib/node-esm/update-complementary-CZTIVIXU.mjs +0 -29
- package/dist/lib/node-esm/update-complementary-CZTIVIXU.mjs.map +0 -7
- package/dist/lib/node-esm/update-dialog-HEDV5XBB.mjs +0 -30
- package/dist/lib/node-esm/update-dialog-HEDV5XBB.mjs.map +0 -7
- package/dist/lib/node-esm/update-plank-size-JJLU7VE3.mjs +0 -29
- package/dist/lib/node-esm/update-plank-size-JJLU7VE3.mjs.map +0 -7
- package/dist/lib/node-esm/update-popover-HI5TU2VT.mjs +0 -34
- package/dist/lib/node-esm/update-popover-HI5TU2VT.mjs.map +0 -7
- package/dist/lib/node-esm/update-sidebar-QB5BA655.mjs +0 -26
- package/dist/lib/node-esm/update-sidebar-QB5BA655.mjs.map +0 -7
- package/dist/types/src/hooks/useHoistStatusbar.d.ts +0 -3
- package/dist/types/src/hooks/useHoistStatusbar.d.ts.map +0 -1
- package/dist/types/src/operations/definitions.d.ts +0 -15
- package/dist/types/src/operations/definitions.d.ts.map +0 -1
- package/dist/types/src/operations/show-undo.d.ts +0 -5
- package/dist/types/src/operations/show-undo.d.ts.map +0 -1
- package/dist/types/src/types/capabilities.d.ts +0 -191
- package/dist/types/src/types/capabilities.d.ts.map +0 -1
- package/dist/types/src/types/events.d.ts +0 -7
- package/dist/types/src/types/events.d.ts.map +0 -1
- package/src/hooks/useHoistStatusbar.ts +0 -24
- package/src/operations/show-undo.ts +0 -47
- package/src/types/capabilities.ts +0 -35
- package/src/types/events.ts +0 -21
- /package/dist/lib/{browser/chunk-J5LGTIGS.mjs.map → neutral/check-app-scheme-A7FZVNZO.mjs.map} +0 -0
- /package/dist/lib/{browser → neutral}/chunk-J5LGTIGS.mjs +0 -0
- /package/dist/lib/{browser/types/index.mjs.map → neutral/chunk-J5LGTIGS.mjs.map} +0 -0
- /package/dist/lib/{node-esm/types → neutral}/index.mjs.map +0 -0
- /package/dist/lib/{node-esm/chunk-HSLMI22Q.mjs.map → neutral/meta.mjs.map} +0 -0
|
@@ -20,8 +20,8 @@ import { Organization } from '@dxos/types';
|
|
|
20
20
|
|
|
21
21
|
import { DeckSettings, DeckState } from '#capabilities';
|
|
22
22
|
import { meta as pluginMeta } from '#meta';
|
|
23
|
+
import { translations } from '#translations';
|
|
23
24
|
|
|
24
|
-
import { translations } from '../../translations';
|
|
25
25
|
import { Plank } from './Plank';
|
|
26
26
|
|
|
27
27
|
const TestPlugin = Plugin.define(pluginMeta).pipe(
|
|
@@ -42,7 +42,7 @@ random.seed(101);
|
|
|
42
42
|
const storySurfaceExtension = Capability.contributes(
|
|
43
43
|
Capabilities.ReactSurface,
|
|
44
44
|
Surface.create({
|
|
45
|
-
id: '
|
|
45
|
+
id: 'storyArticle',
|
|
46
46
|
role: 'article',
|
|
47
47
|
component: ({ data }) => {
|
|
48
48
|
const subject = (data as any)?.subject;
|
|
@@ -71,7 +71,7 @@ const DefaultStory = () => {
|
|
|
71
71
|
return (
|
|
72
72
|
<Main.Root>
|
|
73
73
|
<Main.Content bounce handlesFocus classNames='grid' style={{ '--main-spacing': '0' } as any}>
|
|
74
|
-
<div
|
|
74
|
+
<div className='relative overflow-hidden bg-deck-surface'>
|
|
75
75
|
<StackContext.Provider value={{ orientation: 'horizontal', size: 'contain', rail: true }}>
|
|
76
76
|
<Plank.Root graph={graph} part='solo' layoutMode='solo'>
|
|
77
77
|
<Plank.Content solo companion={false} encapsulate={false}>
|
|
@@ -9,10 +9,11 @@ import { Surface } from '@dxos/app-framework/ui';
|
|
|
9
9
|
import { AppSurface } from '@dxos/app-toolkit/ui';
|
|
10
10
|
import { debounce } from '@dxos/async';
|
|
11
11
|
import { type Node } from '@dxos/plugin-graph';
|
|
12
|
+
import { mainIntrinsicSize } from '@dxos/react-ui';
|
|
12
13
|
import { getLinkedVariant } from '@dxos/react-ui-attention';
|
|
13
14
|
import { useAttentionAttributes } from '@dxos/react-ui-attention';
|
|
14
15
|
import { StackItem, type StackItemSize, railGridHorizontal } from '@dxos/react-ui-stack';
|
|
15
|
-
import {
|
|
16
|
+
import { mx } from '@dxos/ui-theme';
|
|
16
17
|
|
|
17
18
|
import { useMainSize } from '#hooks';
|
|
18
19
|
import { PLANK_COMPANION_TYPE } from '#types';
|
|
@@ -145,7 +146,7 @@ export const PlankComponent = memo(
|
|
|
145
146
|
const Root = part.startsWith('solo') ? 'article' : StackItem.Root;
|
|
146
147
|
const fullscreen = layoutMode === 'solo--fullscreen';
|
|
147
148
|
const classNames = [
|
|
148
|
-
'dx-attention-surface relative dx-focus-ring-inset-over-all dx-density-
|
|
149
|
+
'dx-attention-surface relative dx-focus-ring-inset-over-all dx-density-lg',
|
|
149
150
|
isSolo && 'absolute inset-0',
|
|
150
151
|
isSolo && mainIntrinsicSize,
|
|
151
152
|
railGridHorizontal,
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
import React, { type PropsWithChildren } from 'react';
|
|
6
6
|
|
|
7
|
+
import { composable, composableProps, mainIntrinsicSize } from '@dxos/react-ui';
|
|
7
8
|
import { railGridHorizontal } from '@dxos/react-ui-stack';
|
|
8
|
-
import { composable, composableProps, mainIntrinsicSize } from '@dxos/ui-theme';
|
|
9
9
|
|
|
10
10
|
import { useMainSize } from '#hooks';
|
|
11
11
|
|
|
@@ -64,15 +64,18 @@ export const PlankErrorFallback = ({ error }: ErrorFallbackProps) => {
|
|
|
64
64
|
return <ErrorFallback title='Plank Error' error={error} />;
|
|
65
65
|
} else {
|
|
66
66
|
const errorString = error?.toString() ?? '';
|
|
67
|
+
|
|
67
68
|
return (
|
|
68
69
|
<div
|
|
69
70
|
role='alert'
|
|
70
71
|
data-testid='plank-content-error'
|
|
71
72
|
className='dx-attention-surface overflow-y-auto p-8 grid place-items-center'
|
|
72
73
|
>
|
|
73
|
-
<
|
|
74
|
-
{
|
|
75
|
-
|
|
74
|
+
<div className='flex flex-col items-center gap-2'>
|
|
75
|
+
<p className={mx(descriptionMessage, 'break-all rounded-md p-4')}>
|
|
76
|
+
{error ? errorString : t('error-fallback.message')}
|
|
77
|
+
</p>
|
|
78
|
+
</div>
|
|
76
79
|
</div>
|
|
77
80
|
);
|
|
78
81
|
}
|
|
@@ -15,7 +15,7 @@ import { hoverableControls, hoverableFocusedWithinControls, iconSize } from '@dx
|
|
|
15
15
|
|
|
16
16
|
import { useBreakpoints } from '#hooks';
|
|
17
17
|
import { meta } from '#meta';
|
|
18
|
-
import { DeckOperation } from '#
|
|
18
|
+
import { DeckOperation } from '#types';
|
|
19
19
|
import { type LayoutMode, PLANK_COMPANION_TYPE, type ResolvedPart } from '#types';
|
|
20
20
|
|
|
21
21
|
import { PlankCompanionControls, PlankControls } from './PlankControls';
|
|
@@ -61,7 +61,7 @@ export const PlankHeading = memo(
|
|
|
61
61
|
const { graph, onAdjust, onUpdateCompanion } = usePlankContext('PlankHeading');
|
|
62
62
|
const runAction = useActionRunner();
|
|
63
63
|
const breakpoint = useBreakpoints();
|
|
64
|
-
const icon = node?.properties?.icon ?? 'ph--
|
|
64
|
+
const icon = node?.properties?.icon ?? 'ph--circle-dashed--regular';
|
|
65
65
|
const label = pending
|
|
66
66
|
? t('pending.heading')
|
|
67
67
|
: toLocalizedString(node?.properties?.label ?? ['plank-heading-fallback.label', { ns: meta.id }], t);
|
|
@@ -143,7 +143,7 @@ export const PlankHeading = memo(
|
|
|
143
143
|
data-plank-heading
|
|
144
144
|
style={iconSize(5)}
|
|
145
145
|
classNames={[
|
|
146
|
-
'py-1 items-stretch gap-1 sticky left-12 dx-app-drag min-w-0 dx-contain-layout dx-density-
|
|
146
|
+
'py-1 items-stretch gap-1 sticky left-12 dx-app-drag min-w-0 dx-contain-layout dx-density-lg',
|
|
147
147
|
part === 'solo'
|
|
148
148
|
? 'ps-[calc(env(safe-area-inset-left)+.25rem)] pe-[calc(env(safe-area-inset-right)+.25rem)]'
|
|
149
149
|
: 'px-1',
|
|
@@ -161,7 +161,7 @@ export const PlankHeading = memo(
|
|
|
161
161
|
>
|
|
162
162
|
{companions && isCompanionNode ? (
|
|
163
163
|
/* TODO(thure): IMPORTANT: This is a tablist; it should be implemented as such. */
|
|
164
|
-
<div data-tauri-drag-region
|
|
164
|
+
<div data-tauri-drag-region className='flex-1 min-w-0 overflow-x-auto scrollbar-none flex gap-1'>
|
|
165
165
|
{companions.map(({ id, properties: { icon, label } }) => (
|
|
166
166
|
<IconButton
|
|
167
167
|
key={id}
|
|
@@ -211,7 +211,7 @@ export const PlankHeading = memo(
|
|
|
211
211
|
</>
|
|
212
212
|
)}
|
|
213
213
|
{debug && (
|
|
214
|
-
<div
|
|
214
|
+
<div className='flex items-center text-sm text-info-text'>
|
|
215
215
|
{layoutMode}:{part}:{companioned}
|
|
216
216
|
</div>
|
|
217
217
|
)}
|
|
@@ -6,5 +6,5 @@ import React from 'react';
|
|
|
6
6
|
|
|
7
7
|
// TODO(burdon): Show skeleton: https://github.com/dxos/dxos/issues/8259
|
|
8
8
|
export const PlankLoading = () => {
|
|
9
|
-
return <div
|
|
9
|
+
return <div className='grid place-items-center dx-attention-surface' />;
|
|
10
10
|
};
|
|
@@ -7,7 +7,7 @@ import React, { PropsWithChildren } from 'react';
|
|
|
7
7
|
|
|
8
8
|
import { type Graph } from '@dxos/plugin-graph';
|
|
9
9
|
|
|
10
|
-
import { type DeckOperation } from '#
|
|
10
|
+
import { type DeckOperation } from '#types';
|
|
11
11
|
import { type LayoutMode, type PlankSizing, type ResolvedPart, type Settings } from '#types';
|
|
12
12
|
|
|
13
13
|
const PLANK_NAME = 'Plank';
|
|
@@ -11,7 +11,7 @@ import { getLinkedVariant } from '@dxos/react-ui-attention';
|
|
|
11
11
|
import { Tabs } from '@dxos/react-ui-tabs';
|
|
12
12
|
import { iconSize, mx } from '@dxos/ui-theme';
|
|
13
13
|
|
|
14
|
-
import { type DeckCompanion, useBreakpoints, useDeckCompanions, useDeckState
|
|
14
|
+
import { type DeckCompanion, useBreakpoints, useDeckCompanions, useDeckState } from '#hooks';
|
|
15
15
|
import { meta } from '#meta';
|
|
16
16
|
import { getMode } from '#types';
|
|
17
17
|
|
|
@@ -32,7 +32,6 @@ export const ComplementarySidebar = ({ current }: ComplementarySidebarProps) =>
|
|
|
32
32
|
const layoutMode = getMode(deck);
|
|
33
33
|
const breakpoint = useBreakpoints();
|
|
34
34
|
const topbar = layoutAppliesTopbar(breakpoint, layoutMode);
|
|
35
|
-
const hoistStatusbar = useHoistStatusbar(breakpoint, layoutMode);
|
|
36
35
|
|
|
37
36
|
const companions = useDeckCompanions();
|
|
38
37
|
const activeCompanion = companions.find((companion) => getLinkedVariant(companion.id) === current);
|
|
@@ -78,28 +77,24 @@ export const ComplementarySidebar = ({ current }: ComplementarySidebarProps) =>
|
|
|
78
77
|
return (
|
|
79
78
|
<Main.ComplementarySidebar
|
|
80
79
|
label={label}
|
|
81
|
-
classNames={[
|
|
82
|
-
topbar && 'top-[calc(env(safe-area-inset-top)+var(--dx-rail-size))]',
|
|
83
|
-
hoistStatusbar && 'bottom-(--dx-statusbar-size)',
|
|
84
|
-
]}
|
|
80
|
+
classNames={[topbar && 'top-[calc(env(safe-area-inset-top)+var(--dx-rail-size))]']}
|
|
85
81
|
>
|
|
86
82
|
{/* R0 Tabs */}
|
|
87
|
-
<Tabs.Root orientation='vertical' value={internalValue}
|
|
83
|
+
<Tabs.Root classNames='contents' orientation='vertical' value={internalValue}>
|
|
88
84
|
<div
|
|
89
85
|
data-tauri-drag-region
|
|
90
|
-
role='none'
|
|
91
86
|
style={iconSize(5)}
|
|
92
87
|
className={mx(
|
|
93
|
-
'absolute z-
|
|
88
|
+
'absolute z-1 inset-y-0 end-0 w-(--dx-r0-size)!',
|
|
94
89
|
'py-[env(safe-area-inset-top)] pb-[env(safe-area-inset-bottom)] border-s border-subdued-separator',
|
|
95
|
-
'grid grid-cols-1 grid-rows-[1fr_min-content] bg-
|
|
90
|
+
'grid grid-cols-1 grid-rows-[1fr_min-content] bg-r0-surface dx-contain-layout dx-app-drag',
|
|
96
91
|
)}
|
|
97
92
|
>
|
|
98
|
-
|
|
99
|
-
<Tabs.Tablist classNames='grid grid-cols-1 auto-rows-(--dx-rail-action) overflow-y-auto'>
|
|
93
|
+
<Tabs.Tablist classNames='grid grid-cols-1 auto-rows-(--dx-rail-action) overflow-y-auto scrollbar-none gap-1 p-1'>
|
|
100
94
|
{companions.map((companion) => (
|
|
101
95
|
<Tabs.Tab key={getLinkedVariant(companion.id)} value={getLinkedVariant(companion.id)} asChild>
|
|
102
96
|
<IconButton
|
|
97
|
+
classNames='w-(--dx-rail-action) h-(--dx-rail-action) min-h-0 px-0'
|
|
103
98
|
label={toLocalizedString(companion.properties.label, t)}
|
|
104
99
|
icon={companion.properties.icon}
|
|
105
100
|
iconOnly
|
|
@@ -118,16 +113,13 @@ export const ComplementarySidebar = ({ current }: ComplementarySidebarProps) =>
|
|
|
118
113
|
</Tabs.Tab>
|
|
119
114
|
))}
|
|
120
115
|
</Tabs.Tablist>
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
</div>
|
|
129
|
-
)}
|
|
130
|
-
<div role='none' className='hidden lg:grid grid-cols-1 auto-rows-(--dx-rail-action) p-1'>
|
|
116
|
+
<div
|
|
117
|
+
className='grid grid-cols-1 auto-rows-(--dx-rail-item) py-0.5 gap-0.5 overflow-y-auto scrollbar-none'
|
|
118
|
+
style={iconSize(4)}
|
|
119
|
+
>
|
|
120
|
+
<Surface.Surface role='status-indicator' />
|
|
121
|
+
</div>
|
|
122
|
+
<div className='hidden lg:grid grid-cols-1 auto-rows-(--dx-rail-action) p-1'>
|
|
131
123
|
<ToggleComplementarySidebarButton />
|
|
132
124
|
</div>
|
|
133
125
|
</div>
|
|
@@ -140,16 +132,11 @@ export const ComplementarySidebar = ({ current }: ComplementarySidebarProps) =>
|
|
|
140
132
|
value={getLinkedVariant(companion.id)}
|
|
141
133
|
classNames={[
|
|
142
134
|
'absolute data-[state="inactive"]:-z-[1] overflow-hidden',
|
|
143
|
-
'inset-y-0 start-0 w-
|
|
135
|
+
'inset-y-0 start-0 w-full lg:w-(--dx-r1-size)',
|
|
144
136
|
]}
|
|
145
137
|
{...(state.complementarySidebarState !== 'expanded' && { inert: true })}
|
|
146
138
|
>
|
|
147
|
-
<ComplementarySidebarPanel
|
|
148
|
-
companion={companion}
|
|
149
|
-
activeId={activeId}
|
|
150
|
-
data={data}
|
|
151
|
-
hoistStatusbar={hoistStatusbar}
|
|
152
|
-
/>
|
|
139
|
+
<ComplementarySidebarPanel companion={companion} activeId={activeId} data={data} />
|
|
153
140
|
</Tabs.Panel>
|
|
154
141
|
))}
|
|
155
142
|
</Tabs.Root>
|
|
@@ -164,10 +151,9 @@ type ComplementarySidebarPanelProps = {
|
|
|
164
151
|
id: string;
|
|
165
152
|
subject: any;
|
|
166
153
|
};
|
|
167
|
-
hoistStatusbar: boolean;
|
|
168
154
|
};
|
|
169
155
|
|
|
170
|
-
const ComplementarySidebarPanel = ({ companion, activeId, data
|
|
156
|
+
const ComplementarySidebarPanel = ({ companion, activeId, data }: ComplementarySidebarPanelProps) => {
|
|
171
157
|
const { t } = useTranslation(meta.id);
|
|
172
158
|
|
|
173
159
|
if (getLinkedVariant(companion.id) !== activeId && !data) {
|
|
@@ -177,14 +163,14 @@ const ComplementarySidebarPanel = ({ companion, activeId, data, hoistStatusbar }
|
|
|
177
163
|
return (
|
|
178
164
|
<Panel.Root>
|
|
179
165
|
<Panel.Toolbar asChild size='lg'>
|
|
180
|
-
<Toolbar.Root classNames='bg-
|
|
166
|
+
<Toolbar.Root style={iconSize(5)} classNames='bg-header-surface'>
|
|
181
167
|
<IconButton
|
|
168
|
+
classNames='w-(--dx-rail-action) h-(--dx-rail-action) min-h-0 px-0'
|
|
182
169
|
label={toLocalizedString(companion.properties.label, t)}
|
|
183
170
|
icon={companion.properties.icon}
|
|
184
171
|
iconOnly
|
|
185
172
|
tooltipSide='left'
|
|
186
173
|
data-value={getLinkedVariant(companion.id)}
|
|
187
|
-
classNames='h-10 w-10'
|
|
188
174
|
variant='default'
|
|
189
175
|
/>
|
|
190
176
|
<div role='none' className='px-1'>
|
|
@@ -192,7 +178,7 @@ const ComplementarySidebarPanel = ({ companion, activeId, data, hoistStatusbar }
|
|
|
192
178
|
</div>
|
|
193
179
|
</Toolbar.Root>
|
|
194
180
|
</Panel.Toolbar>
|
|
195
|
-
<Panel.Content classNames='bg-
|
|
181
|
+
<Panel.Content classNames='bg-r1-surface'>
|
|
196
182
|
<Surface.Surface
|
|
197
183
|
role={`deck-companion--${getLinkedVariant(companion.id)}`}
|
|
198
184
|
data={data}
|
|
@@ -200,11 +186,6 @@ const ComplementarySidebarPanel = ({ companion, activeId, data, hoistStatusbar }
|
|
|
200
186
|
placeholder={<PlankLoading />}
|
|
201
187
|
/>
|
|
202
188
|
</Panel.Content>
|
|
203
|
-
{!hoistStatusbar && (
|
|
204
|
-
<Panel.Statusbar size='sm'>
|
|
205
|
-
<Surface.Surface role='status-bar--r1-footer' limit={1} />
|
|
206
|
-
</Panel.Statusbar>
|
|
207
|
-
)}
|
|
208
189
|
</Panel.Root>
|
|
209
190
|
);
|
|
210
191
|
};
|
|
@@ -8,7 +8,7 @@ import { Surface } from '@dxos/app-framework/ui';
|
|
|
8
8
|
import { AppSurface } from '@dxos/app-toolkit/ui';
|
|
9
9
|
import { type Label, Main } from '@dxos/react-ui';
|
|
10
10
|
|
|
11
|
-
import { useBreakpoints, useDeckState
|
|
11
|
+
import { useBreakpoints, useDeckState } from '#hooks';
|
|
12
12
|
import { meta } from '#meta';
|
|
13
13
|
import { getMode } from '#types';
|
|
14
14
|
|
|
@@ -22,21 +22,16 @@ export const Sidebar = () => {
|
|
|
22
22
|
const breakpoint = useBreakpoints();
|
|
23
23
|
const layoutMode = getMode(deck);
|
|
24
24
|
const topbar = layoutAppliesTopbar(breakpoint, layoutMode);
|
|
25
|
-
const hoistStatusbar = useHoistStatusbar(breakpoint, layoutMode);
|
|
26
25
|
|
|
27
|
-
const navigationData = useMemo<AppSurface.NavigationData<{ topbar: boolean
|
|
28
|
-
() => ({ popoverAnchorId, topbar,
|
|
29
|
-
[popoverAnchorId, topbar,
|
|
26
|
+
const navigationData = useMemo<AppSurface.NavigationData<{ topbar: boolean }>>(
|
|
27
|
+
() => ({ popoverAnchorId, topbar, current }),
|
|
28
|
+
[popoverAnchorId, topbar, current],
|
|
30
29
|
);
|
|
31
30
|
|
|
32
31
|
return (
|
|
33
32
|
<Main.NavigationSidebar
|
|
34
33
|
label={label}
|
|
35
|
-
classNames={[
|
|
36
|
-
'grid',
|
|
37
|
-
topbar && 'top-[calc(env(safe-area-inset-top)+var(--dx-rail-size))]',
|
|
38
|
-
hoistStatusbar && 'bottom-(--dx-statusbar-size)',
|
|
39
|
-
]}
|
|
34
|
+
classNames={['grid', topbar && 'top-[calc(env(safe-area-inset-top)+var(--dx-rail-size))]']}
|
|
40
35
|
>
|
|
41
36
|
<Surface.Surface type={AppSurface.Navigation} data={navigationData} limit={1} />
|
|
42
37
|
</Main.NavigationSidebar>
|
|
@@ -80,13 +80,19 @@ export const ToggleComplementarySidebarButton = ({
|
|
|
80
80
|
}
|
|
81
81
|
}, [state, updateState, current, companions, invokePromise]);
|
|
82
82
|
|
|
83
|
+
const label = t(
|
|
84
|
+
state.complementarySidebarState === 'expanded'
|
|
85
|
+
? 'close-complementary-sidebar.label'
|
|
86
|
+
: 'open-complementary-sidebar.label',
|
|
87
|
+
);
|
|
88
|
+
|
|
83
89
|
return (
|
|
84
90
|
<IconButton
|
|
85
91
|
variant='ghost'
|
|
86
92
|
classNames={['[&>svg]:-scale-x-100', classNames]}
|
|
87
93
|
icon='ph--sidebar-simple--regular'
|
|
88
94
|
iconOnly
|
|
89
|
-
label={
|
|
95
|
+
label={label}
|
|
90
96
|
tooltipSide={inR0 ? 'left' : undefined}
|
|
91
97
|
onClick={handleClick}
|
|
92
98
|
/>
|
package/src/hooks/index.ts
CHANGED
|
@@ -6,7 +6,6 @@ export * from './useBreakpoints';
|
|
|
6
6
|
export * from './useCompanions';
|
|
7
7
|
export * from './useDeckCompanions';
|
|
8
8
|
export * from './useDeckState';
|
|
9
|
-
export * from './useHoistStatusbar';
|
|
10
9
|
export * from './useMainSize';
|
|
11
10
|
export * from './useNodeActionExpander';
|
|
12
11
|
export * from './useSelectedCompanion';
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import { useAppGraph } from '@dxos/app-toolkit/ui';
|
|
6
6
|
import { Node, type Node as NodeType } from '@dxos/plugin-graph';
|
|
7
7
|
import { useConnections } from '@dxos/plugin-graph';
|
|
8
|
-
import { type Label } from '@dxos/ui-types';
|
|
8
|
+
import { type Label } from '@dxos/ui-types/translations';
|
|
9
9
|
import { type Position, byPosition } from '@dxos/util';
|
|
10
10
|
|
|
11
11
|
import { DECK_COMPANION_TYPE } from '#types';
|
package/src/index.ts
CHANGED
package/src/meta.ts
CHANGED
|
@@ -2,15 +2,33 @@
|
|
|
2
2
|
// Copyright 2023 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import {
|
|
5
|
+
import { Plugin } from '@dxos/app-framework';
|
|
6
|
+
import { DXN } from '@dxos/keys';
|
|
6
7
|
import { trim } from '@dxos/util';
|
|
7
8
|
|
|
8
|
-
export const meta
|
|
9
|
-
|
|
9
|
+
export const meta = Plugin.makeMeta({
|
|
10
|
+
key: DXN.make('org.dxos.plugin.deck'),
|
|
10
11
|
name: 'Layout',
|
|
12
|
+
author: 'DXOS',
|
|
13
|
+
spec: 'PLUGIN.mdl',
|
|
11
14
|
description: trim`
|
|
12
|
-
|
|
13
|
-
|
|
15
|
+
The Deck plugin is the core layout engine for DXOS Composer. It manages the multi-plank
|
|
16
|
+
workspace (the "deck"), sidebar panels, dialogs, popovers, and toast notifications, giving
|
|
17
|
+
users a flexible, persistent workspace they can arrange to match their workflow.
|
|
18
|
+
|
|
19
|
+
In multi mode, subjects are opened as resizable "planks" arranged side by side. Users can
|
|
20
|
+
navigate with stack semantics — opening from a pivot truncates planks to the right and
|
|
21
|
+
appends the new one — or switch to solo or fullscreen mode for focused, distraction-free
|
|
22
|
+
viewing.
|
|
23
|
+
|
|
24
|
+
Layout state (active planks, sidebar visibility, plank sizes, companion pane) is persisted
|
|
25
|
+
across sessions via KVS/localStorage. URL routing is handled by the plugin so that any
|
|
26
|
+
workspace configuration can be bookmarked or shared as a deep link.
|
|
27
|
+
|
|
28
|
+
All layout changes are expressed through typed LayoutOperations (Open, Close, SetLayoutMode,
|
|
29
|
+
UpdateSidebar, UpdateDialog, UpdatePopover, etc.) that any plugin in the system can dispatch,
|
|
30
|
+
keeping the layout logic centralised and easy to extend.
|
|
14
31
|
`,
|
|
15
32
|
icon: 'ph--layout--regular',
|
|
16
|
-
|
|
33
|
+
tags: ['system'],
|
|
34
|
+
});
|
|
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
|
|
|
6
6
|
|
|
7
7
|
import { Capabilities } from '@dxos/app-framework';
|
|
8
8
|
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
-
import { Operation } from '@dxos/
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
10
|
|
|
11
11
|
import { DeckCapabilities } from '../types';
|
|
12
12
|
|
package/src/operations/adjust.ts
CHANGED
|
@@ -8,18 +8,17 @@ import * as Option from 'effect/Option';
|
|
|
8
8
|
|
|
9
9
|
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
10
10
|
import { AppCapabilities, LayoutOperation } from '@dxos/app-toolkit';
|
|
11
|
-
import { Operation } from '@dxos/
|
|
12
|
-
import { AttentionCapabilities } from '@dxos/plugin-attention
|
|
11
|
+
import { Operation } from '@dxos/compute';
|
|
12
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention';
|
|
13
13
|
import { Graph } from '@dxos/plugin-graph';
|
|
14
14
|
import { byPosition } from '@dxos/util';
|
|
15
15
|
|
|
16
16
|
import { incrementPlank } from '../layout';
|
|
17
|
-
import { DeckCapabilities, PLANK_COMPANION_TYPE } from '../types';
|
|
17
|
+
import { DeckCapabilities, DeckOperation, PLANK_COMPANION_TYPE } from '../types';
|
|
18
18
|
import { computeActiveUpdates } from '../util';
|
|
19
|
-
import { Adjust } from './definitions';
|
|
20
19
|
import { updateActiveDeck } from './helpers';
|
|
21
20
|
|
|
22
|
-
const handler: Operation.WithHandler<typeof Adjust> = Adjust.pipe(
|
|
21
|
+
const handler: Operation.WithHandler<typeof DeckOperation.Adjust> = DeckOperation.Adjust.pipe(
|
|
23
22
|
Operation.withHandler(
|
|
24
23
|
Effect.fnUntraced(function* (input) {
|
|
25
24
|
const _state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
package/src/operations/close.ts
CHANGED
|
@@ -6,8 +6,8 @@ import * as Effect from 'effect/Effect';
|
|
|
6
6
|
|
|
7
7
|
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
8
8
|
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
-
import { Operation } from '@dxos/
|
|
10
|
-
import { AttentionCapabilities } from '@dxos/plugin-attention
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention';
|
|
11
11
|
|
|
12
12
|
import { closeEntry } from '../layout';
|
|
13
13
|
import { DeckCapabilities } from '../types';
|
package/src/operations/index.ts
CHANGED
|
@@ -2,9 +2,7 @@
|
|
|
2
2
|
// Copyright 2025 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import { OperationHandlerSet } from '@dxos/
|
|
6
|
-
|
|
7
|
-
export * as DeckOperation from './definitions';
|
|
5
|
+
import { OperationHandlerSet } from '@dxos/compute';
|
|
8
6
|
|
|
9
7
|
export const DeckOperationHandlerSet = OperationHandlerSet.lazy(
|
|
10
8
|
() => import('./add-toast'),
|
|
@@ -15,7 +13,6 @@ export const DeckOperationHandlerSet = OperationHandlerSet.lazy(
|
|
|
15
13
|
() => import('./scroll-into-view'),
|
|
16
14
|
() => import('./set'),
|
|
17
15
|
() => import('./set-layout-mode'),
|
|
18
|
-
() => import('./show-undo'),
|
|
19
16
|
() => import('./switch-workspace'),
|
|
20
17
|
() => import('./update-companion'),
|
|
21
18
|
() => import('./update-complementary'),
|
package/src/operations/open.ts
CHANGED
|
@@ -13,13 +13,14 @@ import {
|
|
|
13
13
|
expandPath,
|
|
14
14
|
validateNavigationTarget,
|
|
15
15
|
} from '@dxos/app-toolkit';
|
|
16
|
+
import { Operation } from '@dxos/compute';
|
|
16
17
|
import { Context } from '@dxos/context';
|
|
17
|
-
import { Obj } from '@dxos/echo';
|
|
18
|
-
import {
|
|
19
|
-
import { AttentionCapabilities } from '@dxos/plugin-attention
|
|
20
|
-
import { ClientCapabilities } from '@dxos/plugin-client
|
|
18
|
+
import { Database, EID, Obj } from '@dxos/echo';
|
|
19
|
+
import { log } from '@dxos/log';
|
|
20
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention';
|
|
21
|
+
import { ClientCapabilities } from '@dxos/plugin-client';
|
|
21
22
|
import { Graph } from '@dxos/plugin-graph';
|
|
22
|
-
import { ObservabilityOperation } from '@dxos/plugin-observability
|
|
23
|
+
import { ObservabilityOperation } from '@dxos/plugin-observability';
|
|
23
24
|
|
|
24
25
|
import { openSubjectsOnActiveDeck } from '../layout';
|
|
25
26
|
import { DeckCapabilities } from '../types';
|
|
@@ -29,18 +30,33 @@ import { updateActiveDeck } from './helpers';
|
|
|
29
30
|
const handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperation.Open.pipe(
|
|
30
31
|
Operation.withHandler(
|
|
31
32
|
Effect.fnUntraced(function* (input) {
|
|
33
|
+
log('LayoutOperation.Open handler start');
|
|
32
34
|
const { graph } = yield* Capability.get(AppCapabilities.AppGraph);
|
|
33
35
|
const attention = yield* Capability.get(AttentionCapabilities.Attention);
|
|
34
36
|
|
|
35
37
|
// Validate navigation targets, redirecting to 404 if not found.
|
|
36
38
|
const capabilities = yield* Capability.Service;
|
|
37
39
|
const pathResolvers = capabilities.getAll(AppCapabilities.NavigationPathResolver);
|
|
38
|
-
const
|
|
39
|
-
Effect.map((client) =>
|
|
40
|
-
createEdgeExistenceChecker((spaceId, body) => client.edge.http.execQuery(new Context(), spaceId, body)),
|
|
41
|
-
),
|
|
40
|
+
const client = yield* Capability.get(ClientCapabilities.Client).pipe(
|
|
42
41
|
Effect.catchAll(() => Effect.succeed(undefined)),
|
|
43
42
|
);
|
|
43
|
+
// Existence checkers for the resolved EID: local (loadOption) first, then remote (edge).
|
|
44
|
+
const checkLocalExistence = client
|
|
45
|
+
? (id: EID.EID) => {
|
|
46
|
+
const spaceId = EID.getSpaceId(id);
|
|
47
|
+
const space = spaceId ? client.spaces.get(spaceId) : undefined;
|
|
48
|
+
if (!space) {
|
|
49
|
+
return Effect.succeed(false);
|
|
50
|
+
}
|
|
51
|
+
return Database.loadOption(space.db.makeRef(id)).pipe(
|
|
52
|
+
Effect.map(Option.isSome),
|
|
53
|
+
Effect.catchAll(() => Effect.succeed(false)),
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
: undefined;
|
|
57
|
+
const checkRemoteExistence = client
|
|
58
|
+
? createEdgeExistenceChecker((spaceId, body) => client.edge.http.execQuery(new Context(), spaceId, body))
|
|
59
|
+
: undefined;
|
|
44
60
|
|
|
45
61
|
// Immediate: skip 404 / resolver checks but still expand the path (same as validate’s first step).
|
|
46
62
|
if (input.navigation === 'immediate') {
|
|
@@ -53,7 +69,7 @@ const handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperat
|
|
|
53
69
|
input.subject.map((subjectId) =>
|
|
54
70
|
input.navigation === 'immediate'
|
|
55
71
|
? Effect.succeed(subjectId)
|
|
56
|
-
: validateNavigationTarget({ graph, subjectId, pathResolvers, checkRemoteExistence }),
|
|
72
|
+
: validateNavigationTarget({ graph, subjectId, pathResolvers, checkLocalExistence, checkRemoteExistence }),
|
|
57
73
|
),
|
|
58
74
|
);
|
|
59
75
|
input = { ...input, subject: validatedSubjects };
|
|
@@ -74,7 +90,7 @@ const handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperat
|
|
|
74
90
|
const deck = yield* DeckCapabilities.getDeck();
|
|
75
91
|
const active = !deck.solo && deck.initialized ? deck.active : [];
|
|
76
92
|
if (active.length > 0 && input.subject.length > 0) {
|
|
77
|
-
const
|
|
93
|
+
const resolveDXN = (qualifiedPath: string) =>
|
|
78
94
|
Effect.reduce(pathResolvers, Option.none<string>(), (acc, resolver) =>
|
|
79
95
|
Option.isSome(acc)
|
|
80
96
|
? Effect.succeed(acc)
|
|
@@ -88,7 +104,7 @@ const handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperat
|
|
|
88
104
|
const deckDxnMap = new Map<string, string>();
|
|
89
105
|
yield* Effect.all(
|
|
90
106
|
active.map((deckId) =>
|
|
91
|
-
|
|
107
|
+
resolveDXN(deckId).pipe(
|
|
92
108
|
Effect.map((opt) => {
|
|
93
109
|
if (Option.isSome(opt)) {
|
|
94
110
|
deckDxnMap.set(opt.value, deckId);
|
|
@@ -103,7 +119,7 @@ const handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperat
|
|
|
103
119
|
if (deckDxnMap.size > 0) {
|
|
104
120
|
const remapped = yield* Effect.all(
|
|
105
121
|
input.subject.map((subjectId) =>
|
|
106
|
-
|
|
122
|
+
resolveDXN(subjectId).pipe(
|
|
107
123
|
Effect.map((opt) => {
|
|
108
124
|
if (Option.isSome(opt)) {
|
|
109
125
|
const existing = deckDxnMap.get(opt.value);
|
|
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
|
|
|
6
6
|
|
|
7
7
|
import { Capabilities } from '@dxos/app-framework';
|
|
8
8
|
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
-
import { Operation } from '@dxos/
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
10
|
|
|
11
11
|
import { DeckCapabilities } from '../types';
|
|
12
12
|
|
|
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
|
|
|
6
6
|
|
|
7
7
|
import { Capabilities } from '@dxos/app-framework';
|
|
8
8
|
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
-
import { Operation } from '@dxos/
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
10
|
|
|
11
11
|
import { DeckCapabilities } from '../types';
|
|
12
12
|
|
|
@@ -6,8 +6,8 @@ import * as Effect from 'effect/Effect';
|
|
|
6
6
|
|
|
7
7
|
import { Capabilities } from '@dxos/app-framework';
|
|
8
8
|
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
9
10
|
import { log } from '@dxos/log';
|
|
10
|
-
import { Operation } from '@dxos/operation';
|
|
11
11
|
import { isNonNullable } from '@dxos/util';
|
|
12
12
|
|
|
13
13
|
import { DeckCapabilities, type DeckState, type LayoutMode, getMode, isLayoutMode } from '../types';
|
package/src/operations/set.ts
CHANGED
|
@@ -6,8 +6,8 @@ import * as Effect from 'effect/Effect';
|
|
|
6
6
|
|
|
7
7
|
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
8
8
|
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
-
import { Operation } from '@dxos/
|
|
10
|
-
import { AttentionCapabilities } from '@dxos/plugin-attention
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention';
|
|
11
11
|
|
|
12
12
|
import { DeckCapabilities } from '../types';
|
|
13
13
|
import { computeActiveUpdates } from '../util';
|