@dxos/plugin-deck 0.8.4-main.f5c0578 → 0.8.4-main.fcc0d83b33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/browser/add-toast-JWJOQNVL.mjs +24 -0
- package/dist/lib/browser/add-toast-JWJOQNVL.mjs.map +7 -0
- package/dist/lib/browser/adjust-RG6LIQLX.mjs +95 -0
- package/dist/lib/browser/adjust-RG6LIQLX.mjs.map +7 -0
- package/dist/lib/browser/chunk-GLB73Q6U.mjs +22 -0
- package/dist/lib/browser/chunk-GLB73Q6U.mjs.map +7 -0
- package/dist/lib/browser/chunk-J5LGTIGS.mjs +10 -0
- package/dist/lib/browser/chunk-LSZ47AY3.mjs +48 -0
- package/dist/lib/browser/chunk-LSZ47AY3.mjs.map +7 -0
- package/dist/lib/browser/chunk-MARE7ZFK.mjs +215 -0
- package/dist/lib/browser/chunk-MARE7ZFK.mjs.map +7 -0
- package/dist/lib/browser/chunk-XM263CQU.mjs +72 -0
- package/dist/lib/browser/chunk-XM263CQU.mjs.map +7 -0
- package/dist/lib/browser/chunk-ZYYOSX5I.mjs +69 -0
- package/dist/lib/browser/chunk-ZYYOSX5I.mjs.map +7 -0
- package/dist/lib/browser/close-URA766JO.mjs +44 -0
- package/dist/lib/browser/close-URA766JO.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +111 -147
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/open-OPFOOHCQ.mjs +147 -0
- package/dist/lib/browser/open-OPFOOHCQ.mjs.map +7 -0
- package/dist/lib/browser/operations/index.mjs +13 -0
- package/dist/lib/browser/operations/index.mjs.map +7 -0
- package/dist/lib/browser/revert-workspace-KP2Y4QLG.mjs +21 -0
- package/dist/lib/browser/revert-workspace-KP2Y4QLG.mjs.map +7 -0
- package/dist/lib/browser/scroll-into-view-S5H2FGSQ.mjs +21 -0
- package/dist/lib/browser/scroll-into-view-S5H2FGSQ.mjs.map +7 -0
- package/dist/lib/browser/set-AEKFFSIX.mjs +37 -0
- package/dist/lib/browser/set-AEKFFSIX.mjs.map +7 -0
- package/dist/lib/browser/set-layout-mode-CWIGQDFZ.mjs +85 -0
- package/dist/lib/browser/set-layout-mode-CWIGQDFZ.mjs.map +7 -0
- package/dist/lib/browser/show-undo-XFVEDKYC.mjs +59 -0
- package/dist/lib/browser/show-undo-XFVEDKYC.mjs.map +7 -0
- package/dist/lib/browser/switch-workspace-DSAAXZSI.mjs +60 -0
- package/dist/lib/browser/switch-workspace-DSAAXZSI.mjs.map +7 -0
- package/dist/lib/browser/translations.mjs +57 -0
- package/dist/lib/browser/translations.mjs.map +7 -0
- package/dist/lib/browser/types/index.mjs +12 -12
- package/dist/lib/browser/update-companion-IDBBBHT3.mjs +32 -0
- package/dist/lib/browser/update-companion-IDBBBHT3.mjs.map +7 -0
- package/dist/lib/browser/update-complementary-55PNO5MD.mjs +28 -0
- package/dist/lib/browser/update-complementary-55PNO5MD.mjs.map +7 -0
- package/dist/lib/browser/update-dialog-VNARIANC.mjs +29 -0
- package/dist/lib/browser/update-dialog-VNARIANC.mjs.map +7 -0
- package/dist/lib/browser/update-plank-size-H63PRRXS.mjs +28 -0
- package/dist/lib/browser/update-plank-size-H63PRRXS.mjs.map +7 -0
- package/dist/lib/browser/update-popover-ODTPZ3JL.mjs +33 -0
- package/dist/lib/browser/update-popover-ODTPZ3JL.mjs.map +7 -0
- package/dist/lib/browser/update-sidebar-JDVQ36WK.mjs +25 -0
- package/dist/lib/browser/update-sidebar-JDVQ36WK.mjs.map +7 -0
- package/dist/lib/node-esm/add-toast-JUTN4GTI.mjs +25 -0
- package/dist/lib/node-esm/add-toast-JUTN4GTI.mjs.map +7 -0
- package/dist/lib/node-esm/adjust-P5QK33P4.mjs +96 -0
- package/dist/lib/node-esm/adjust-P5QK33P4.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-FO7YDJZ3.mjs +216 -0
- package/dist/lib/node-esm/chunk-FO7YDJZ3.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs +11 -0
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-KY7ZCANM.mjs +50 -0
- package/dist/lib/node-esm/chunk-KY7ZCANM.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-L7OVX7CV.mjs +73 -0
- package/dist/lib/node-esm/chunk-L7OVX7CV.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-SHSR2CYO.mjs +24 -0
- package/dist/lib/node-esm/chunk-SHSR2CYO.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-WGBUTT5K.mjs +71 -0
- package/dist/lib/node-esm/chunk-WGBUTT5K.mjs.map +7 -0
- package/dist/lib/node-esm/close-U5VC7ERP.mjs +45 -0
- package/dist/lib/node-esm/close-U5VC7ERP.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +139 -0
- package/dist/lib/node-esm/index.mjs.map +7 -0
- package/dist/lib/node-esm/meta.json +1 -0
- package/dist/lib/node-esm/open-4B3P5XGS.mjs +148 -0
- package/dist/lib/node-esm/open-4B3P5XGS.mjs.map +7 -0
- package/dist/lib/node-esm/operations/index.mjs +14 -0
- package/dist/lib/node-esm/operations/index.mjs.map +7 -0
- package/dist/lib/node-esm/revert-workspace-QD63M2U7.mjs +22 -0
- package/dist/lib/node-esm/revert-workspace-QD63M2U7.mjs.map +7 -0
- package/dist/lib/node-esm/scroll-into-view-G5M2EWK7.mjs +22 -0
- package/dist/lib/node-esm/scroll-into-view-G5M2EWK7.mjs.map +7 -0
- package/dist/lib/node-esm/set-ERJCXZBY.mjs +38 -0
- package/dist/lib/node-esm/set-ERJCXZBY.mjs.map +7 -0
- package/dist/lib/node-esm/set-layout-mode-BOZD7744.mjs +86 -0
- package/dist/lib/node-esm/set-layout-mode-BOZD7744.mjs.map +7 -0
- package/dist/lib/node-esm/show-undo-H5BRBYDC.mjs +60 -0
- package/dist/lib/node-esm/show-undo-H5BRBYDC.mjs.map +7 -0
- package/dist/lib/node-esm/switch-workspace-F54PXE5N.mjs +61 -0
- package/dist/lib/node-esm/switch-workspace-F54PXE5N.mjs.map +7 -0
- package/dist/lib/node-esm/translations.mjs +58 -0
- package/dist/lib/node-esm/translations.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +33 -0
- package/dist/lib/node-esm/types/index.mjs.map +7 -0
- package/dist/lib/node-esm/update-companion-47LMKL5R.mjs +33 -0
- package/dist/lib/node-esm/update-companion-47LMKL5R.mjs.map +7 -0
- package/dist/lib/node-esm/update-complementary-7VYYG7L2.mjs +29 -0
- package/dist/lib/node-esm/update-complementary-7VYYG7L2.mjs.map +7 -0
- package/dist/lib/node-esm/update-dialog-CABL7OWW.mjs +30 -0
- package/dist/lib/node-esm/update-dialog-CABL7OWW.mjs.map +7 -0
- package/dist/lib/node-esm/update-plank-size-WYTSMZF2.mjs +29 -0
- package/dist/lib/node-esm/update-plank-size-WYTSMZF2.mjs.map +7 -0
- package/dist/lib/node-esm/update-popover-YZDYGL7G.mjs +34 -0
- package/dist/lib/node-esm/update-popover-YZDYGL7G.mjs.map +7 -0
- package/dist/lib/node-esm/update-sidebar-HV736LUN.mjs +26 -0
- package/dist/lib/node-esm/update-sidebar-HV736LUN.mjs.map +7 -0
- package/dist/types/src/DeckPlugin.d.ts +2 -1
- package/dist/types/src/DeckPlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder.d.ts +4 -2
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
- package/dist/types/src/capabilities/check-app-scheme.d.ts +17 -2
- package/dist/types/src/capabilities/check-app-scheme.d.ts.map +1 -1
- package/dist/types/src/capabilities/index.d.ts +196 -12
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/operation-handler.d.ts +6 -0
- package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-root.d.ts +4 -2
- package/dist/types/src/capabilities/react-root.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-surface.d.ts +3 -2
- package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
- package/dist/types/src/capabilities/settings.d.ts +5 -2
- package/dist/types/src/capabilities/settings.d.ts.map +1 -1
- package/dist/types/src/capabilities/state.d.ts +136 -46
- package/dist/types/src/capabilities/state.d.ts.map +1 -1
- package/dist/types/src/capabilities/tools.d.ts +4 -3
- package/dist/types/src/capabilities/tools.d.ts.map +1 -1
- package/dist/types/src/capabilities/url-handler.d.ts +3 -2
- package/dist/types/src/capabilities/url-handler.d.ts.map +1 -1
- package/dist/types/src/components/DeckSettings/DeckSettings.d.ts +4 -4
- package/dist/types/src/components/DeckSettings/DeckSettings.d.ts.map +1 -1
- package/dist/types/src/components/DeckSettings/DeckSettings.stories.d.ts +61 -0
- package/dist/types/src/components/DeckSettings/DeckSettings.stories.d.ts.map +1 -0
- package/dist/types/src/components/DeckSettings/index.d.ts +1 -1
- package/dist/types/src/components/DeckSettings/index.d.ts.map +1 -1
- package/dist/types/src/components/Matrix/Matrix.d.ts +41 -0
- package/dist/types/src/components/Matrix/Matrix.d.ts.map +1 -0
- package/dist/types/src/components/Matrix/Matrix.stories.d.ts +17 -0
- package/dist/types/src/components/Matrix/Matrix.stories.d.ts.map +1 -0
- package/dist/types/src/components/Matrix/index.d.ts +3 -0
- package/dist/types/src/components/Matrix/index.d.ts.map +1 -0
- package/dist/types/src/components/index.d.ts +3 -2
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/{components/DeckLayout → containers/Deck}/Banner.d.ts +1 -1
- package/dist/types/src/containers/Deck/Banner.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/Deck.d.ts +25 -0
- package/dist/types/src/containers/Deck/Deck.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/Deck.stories.d.ts +61 -0
- package/dist/types/src/containers/Deck/Deck.stories.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/DeckContent.d.ts +7 -0
- package/dist/types/src/containers/Deck/DeckContent.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/DeckRoot.d.ts +39 -0
- package/dist/types/src/containers/Deck/DeckRoot.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/DeckViewport.d.ts +16 -0
- package/dist/types/src/containers/Deck/DeckViewport.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/StatusBar.d.ts.map +1 -0
- package/dist/types/src/containers/Deck/index.d.ts +2 -0
- package/dist/types/src/containers/Deck/index.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/ActiveNode.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/DeckLayout.d.ts +5 -0
- package/dist/types/src/containers/DeckLayout/DeckLayout.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/DeckLayout.stories.d.ts +63 -0
- package/dist/types/src/containers/DeckLayout/DeckLayout.stories.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/Dialog.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/Fallback.d.ts +2 -0
- package/dist/types/src/containers/DeckLayout/Fallback.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/Popover.d.ts +5 -0
- package/dist/types/src/containers/DeckLayout/Popover.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/Toast.d.ts +10 -0
- package/dist/types/src/containers/DeckLayout/Toast.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/constants.d.ts.map +1 -0
- package/dist/types/src/containers/DeckLayout/index.d.ts +4 -0
- package/dist/types/src/containers/DeckLayout/index.d.ts.map +1 -0
- package/dist/types/src/containers/Plank/Plank.d.ts +17 -0
- package/dist/types/src/containers/Plank/Plank.d.ts.map +1 -0
- package/dist/types/src/containers/Plank/Plank.stories.d.ts +61 -0
- package/dist/types/src/containers/Plank/Plank.stories.d.ts.map +1 -0
- package/dist/types/src/containers/Plank/PlankComponent.d.ts +17 -0
- package/dist/types/src/containers/Plank/PlankComponent.d.ts.map +1 -0
- package/dist/types/src/containers/Plank/PlankContent.d.ts +10 -0
- package/dist/types/src/containers/Plank/PlankContent.d.ts.map +1 -0
- package/dist/types/src/{components → containers}/Plank/PlankControls.d.ts +5 -6
- package/dist/types/src/containers/Plank/PlankControls.d.ts.map +1 -0
- package/dist/types/src/containers/Plank/PlankError.d.ts +15 -0
- package/dist/types/src/containers/Plank/PlankError.d.ts.map +1 -0
- package/dist/types/src/{components → containers}/Plank/PlankHeading.d.ts +5 -4
- package/dist/types/src/containers/Plank/PlankHeading.d.ts.map +1 -0
- package/dist/types/src/{components → containers}/Plank/PlankLoading.d.ts.map +1 -1
- package/dist/types/src/containers/Plank/PlankRoot.d.ts +37 -0
- package/dist/types/src/containers/Plank/PlankRoot.d.ts.map +1 -0
- package/dist/types/src/containers/Plank/index.d.ts +4 -0
- package/dist/types/src/containers/Plank/index.d.ts.map +1 -0
- package/dist/types/src/containers/Sidebar/ComplementarySidebar.d.ts.map +1 -0
- package/dist/types/src/containers/Sidebar/Sidebar.d.ts.map +1 -0
- package/dist/types/src/{components → containers}/Sidebar/SidebarButton.d.ts +1 -1
- package/dist/types/src/containers/Sidebar/SidebarButton.d.ts.map +1 -0
- package/dist/types/src/{components → containers}/Sidebar/index.d.ts.map +1 -1
- package/dist/types/src/containers/index.d.ts +6 -0
- package/dist/types/src/containers/index.d.ts.map +1 -0
- package/dist/types/src/hooks/index.d.ts +2 -0
- 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 +4 -4
- package/dist/types/src/hooks/useDeckCompanions.d.ts.map +1 -1
- package/dist/types/src/hooks/useDeckState.d.ts +17 -0
- package/dist/types/src/hooks/useDeckState.d.ts.map +1 -0
- package/dist/types/src/hooks/useHoistStatusbar.d.ts +1 -1
- package/dist/types/src/hooks/useHoistStatusbar.d.ts.map +1 -1
- package/dist/types/src/hooks/useMainSize.d.ts +2 -2
- package/dist/types/src/hooks/useMainSize.d.ts.map +1 -1
- package/dist/types/src/hooks/useNodeActionExpander.d.ts +1 -1
- package/dist/types/src/hooks/useNodeActionExpander.d.ts.map +1 -1
- package/dist/types/src/hooks/useSelectedCompanion.d.ts +13 -0
- package/dist/types/src/hooks/useSelectedCompanion.d.ts.map +1 -0
- package/dist/types/src/index.d.ts +1 -2
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/layout.d.ts +20 -9
- package/dist/types/src/layout.d.ts.map +1 -1
- package/dist/types/src/layout.test.d.ts +2 -0
- package/dist/types/src/layout.test.d.ts.map +1 -0
- package/dist/types/src/meta.d.ts +2 -3
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/operations/add-toast.d.ts +5 -0
- package/dist/types/src/operations/add-toast.d.ts.map +1 -0
- package/dist/types/src/operations/adjust.d.ts +5 -0
- package/dist/types/src/operations/adjust.d.ts.map +1 -0
- package/dist/types/src/operations/close.d.ts +5 -0
- package/dist/types/src/operations/close.d.ts.map +1 -0
- package/dist/types/src/operations/definitions.d.ts +15 -0
- package/dist/types/src/operations/definitions.d.ts.map +1 -0
- package/dist/types/src/operations/helpers.d.ts +3 -0
- package/dist/types/src/operations/helpers.d.ts.map +1 -0
- package/dist/types/src/operations/index.d.ts +4 -0
- package/dist/types/src/operations/index.d.ts.map +1 -0
- package/dist/types/src/operations/open.d.ts +5 -0
- package/dist/types/src/operations/open.d.ts.map +1 -0
- package/dist/types/src/operations/revert-workspace.d.ts +5 -0
- package/dist/types/src/operations/revert-workspace.d.ts.map +1 -0
- package/dist/types/src/operations/scroll-into-view.d.ts +5 -0
- package/dist/types/src/operations/scroll-into-view.d.ts.map +1 -0
- package/dist/types/src/operations/set-layout-mode.d.ts +9 -0
- package/dist/types/src/operations/set-layout-mode.d.ts.map +1 -0
- package/dist/types/src/operations/set.d.ts +5 -0
- package/dist/types/src/operations/set.d.ts.map +1 -0
- package/dist/types/src/operations/show-undo.d.ts +5 -0
- package/dist/types/src/operations/show-undo.d.ts.map +1 -0
- package/dist/types/src/operations/switch-workspace.d.ts +5 -0
- package/dist/types/src/operations/switch-workspace.d.ts.map +1 -0
- package/dist/types/src/operations/update-companion.d.ts +5 -0
- package/dist/types/src/operations/update-companion.d.ts.map +1 -0
- package/dist/types/src/operations/update-complementary.d.ts +5 -0
- package/dist/types/src/operations/update-complementary.d.ts.map +1 -0
- package/dist/types/src/operations/update-dialog.d.ts +5 -0
- package/dist/types/src/operations/update-dialog.d.ts.map +1 -0
- package/dist/types/src/operations/update-plank-size.d.ts +5 -0
- package/dist/types/src/operations/update-plank-size.d.ts.map +1 -0
- package/dist/types/src/operations/update-popover.d.ts +5 -0
- package/dist/types/src/operations/update-popover.d.ts.map +1 -0
- package/dist/types/src/operations/update-sidebar.d.ts +5 -0
- package/dist/types/src/operations/update-sidebar.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +42 -53
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types/Settings.d.ts +11 -0
- package/dist/types/src/types/Settings.d.ts.map +1 -0
- package/dist/types/src/{capabilities → types}/capabilities.d.ts +101 -94
- package/dist/types/src/types/capabilities.d.ts.map +1 -0
- package/dist/types/src/types/events.d.ts +7 -0
- package/dist/types/src/types/events.d.ts.map +1 -0
- package/dist/types/src/types/index.d.ts +3 -0
- package/dist/types/src/types/index.d.ts.map +1 -1
- package/dist/types/src/types/schema.d.ts +66 -64
- package/dist/types/src/types/schema.d.ts.map +1 -1
- package/dist/types/src/util/index.d.ts +2 -1
- package/dist/types/src/util/index.d.ts.map +1 -1
- package/dist/types/src/util/layoutAppliesTopbar.d.ts +1 -1
- package/dist/types/src/util/layoutAppliesTopbar.d.ts.map +1 -1
- package/dist/types/src/util/plank-url-params.d.ts +14 -0
- package/dist/types/src/util/plank-url-params.d.ts.map +1 -0
- package/dist/types/src/util/plank-url-params.test.d.ts +2 -0
- package/dist/types/src/util/plank-url-params.test.d.ts.map +1 -0
- package/dist/types/src/util/sanitize-persisted-state.d.ts +19 -0
- package/dist/types/src/util/sanitize-persisted-state.d.ts.map +1 -0
- package/dist/types/src/util/sanitize-persisted-state.test.d.ts +2 -0
- package/dist/types/src/util/sanitize-persisted-state.test.d.ts.map +1 -0
- package/dist/types/src/util/set-active.d.ts +19 -4
- package/dist/types/src/util/set-active.d.ts.map +1 -1
- package/dist/types/src/util/set-active.test.d.ts +2 -0
- package/dist/types/src/util/set-active.test.d.ts.map +1 -0
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +90 -56
- package/src/DeckPlugin.ts +44 -71
- package/src/capabilities/app-graph-builder.ts +112 -127
- package/src/capabilities/check-app-scheme.ts +123 -24
- package/src/capabilities/index.ts +13 -14
- package/src/capabilities/operation-handler.ts +16 -0
- package/src/capabilities/react-root.tsx +37 -29
- package/src/capabilities/react-surface.tsx +28 -22
- package/src/capabilities/settings.ts +30 -19
- package/src/capabilities/state.ts +74 -88
- package/src/capabilities/tools.ts +58 -51
- package/src/capabilities/url-handler.ts +221 -50
- package/src/components/DeckSettings/DeckSettings.stories.tsx +38 -0
- package/src/components/DeckSettings/DeckSettings.tsx +19 -73
- package/src/components/DeckSettings/index.ts +2 -2
- package/src/components/Matrix/Matrix.stories.tsx +220 -0
- package/src/components/Matrix/Matrix.tsx +205 -0
- package/src/components/Matrix/SPEC.md +219 -0
- package/src/components/Matrix/index.ts +6 -0
- package/src/components/index.ts +6 -3
- package/src/{components/DeckLayout → containers/Deck}/Banner.tsx +13 -11
- package/src/containers/Deck/Deck.stories.tsx +81 -0
- package/src/containers/Deck/Deck.tsx +21 -0
- package/src/containers/Deck/DeckContent.tsx +105 -0
- package/src/containers/Deck/DeckRoot.tsx +50 -0
- package/src/containers/Deck/DeckViewport.tsx +456 -0
- package/src/{components/DeckLayout → containers/Deck}/StatusBar.tsx +4 -4
- package/src/containers/Deck/index.ts +5 -0
- package/src/{components → containers}/DeckLayout/ActiveNode.tsx +8 -3
- package/src/containers/DeckLayout/DeckLayout.stories.tsx +397 -0
- package/src/containers/DeckLayout/DeckLayout.tsx +62 -0
- package/src/containers/DeckLayout/Dialog.tsx +52 -0
- package/src/containers/DeckLayout/Fallback.tsx +24 -0
- package/src/containers/DeckLayout/Popover.tsx +161 -0
- package/src/{components → containers}/DeckLayout/Toast.tsx +30 -5
- package/src/{components → containers}/DeckLayout/constants.ts +1 -0
- package/src/{components → containers}/DeckLayout/index.ts +3 -2
- package/src/containers/Plank/Plank.stories.tsx +108 -0
- package/src/containers/Plank/Plank.tsx +22 -0
- package/src/containers/Plank/PlankComponent.tsx +217 -0
- package/src/containers/Plank/PlankContent.tsx +45 -0
- package/src/{components → containers}/Plank/PlankControls.tsx +45 -38
- package/src/containers/Plank/PlankError.tsx +79 -0
- package/src/{components → containers}/Plank/PlankHeading.tsx +68 -64
- package/src/{components → containers}/Plank/PlankLoading.tsx +1 -1
- package/src/containers/Plank/PlankRoot.tsx +49 -0
- package/src/{components → containers}/Plank/index.ts +0 -2
- package/src/containers/Sidebar/ComplementarySidebar.tsx +210 -0
- package/src/containers/Sidebar/Sidebar.tsx +44 -0
- package/src/containers/Sidebar/SidebarButton.tsx +100 -0
- package/src/containers/index.ts +11 -0
- package/src/hooks/index.ts +2 -0
- package/src/hooks/useCompanions.ts +3 -3
- package/src/hooks/useDeckCompanions.ts +8 -10
- package/src/hooks/useDeckState.ts +73 -0
- package/src/hooks/useHoistStatusbar.ts +4 -5
- package/src/hooks/useMainSize.ts +2 -2
- package/src/hooks/useNodeActionExpander.ts +4 -4
- package/src/hooks/useSelectedCompanion.ts +32 -0
- package/src/index.ts +1 -2
- package/src/layout.test.ts +59 -0
- package/src/layout.ts +38 -40
- package/src/meta.ts +8 -5
- package/src/operations/add-toast.ts +24 -0
- package/src/operations/adjust.ts +83 -0
- package/src/operations/close.ts +35 -0
- package/src/operations/definitions.ts +49 -0
- package/src/operations/helpers.ts +22 -0
- package/src/operations/index.ts +26 -0
- package/src/operations/open.ts +184 -0
- package/src/operations/revert-workspace.ts +22 -0
- package/src/operations/scroll-into-view.ts +24 -0
- package/src/operations/set-layout-mode.ts +84 -0
- package/src/operations/set.ts +36 -0
- package/src/operations/show-undo.ts +47 -0
- package/src/operations/switch-workspace.ts +60 -0
- package/src/operations/update-companion.ts +35 -0
- package/src/operations/update-complementary.ts +33 -0
- package/src/operations/update-dialog.ts +34 -0
- package/src/operations/update-plank-size.ts +29 -0
- package/src/operations/update-popover.ts +36 -0
- package/src/operations/update-sidebar.ts +28 -0
- package/src/translations.ts +42 -52
- package/src/types/Settings.ts +42 -0
- package/src/types/capabilities.ts +35 -0
- package/src/types/events.ts +21 -0
- package/src/types/index.ts +3 -0
- package/src/types/schema.ts +51 -56
- package/src/util/index.ts +2 -1
- package/src/util/layoutAppliesTopbar.ts +2 -2
- package/src/util/plank-url-params.test.ts +85 -0
- package/src/util/plank-url-params.ts +36 -0
- package/src/util/sanitize-persisted-state.test.ts +79 -0
- package/src/util/sanitize-persisted-state.ts +52 -0
- package/src/util/set-active.test.ts +106 -0
- package/src/util/set-active.ts +50 -30
- package/src/vite-env.d.ts +5 -0
- package/dist/lib/browser/app-graph-builder-DVEKLXB4.mjs +0 -152
- package/dist/lib/browser/app-graph-builder-DVEKLXB4.mjs.map +0 -7
- package/dist/lib/browser/check-app-scheme-3BQJXWEY.mjs +0 -32
- package/dist/lib/browser/check-app-scheme-3BQJXWEY.mjs.map +0 -7
- package/dist/lib/browser/chunk-6MQIYIPY.mjs +0 -1494
- package/dist/lib/browser/chunk-6MQIYIPY.mjs.map +0 -7
- package/dist/lib/browser/chunk-CNTGBCMK.mjs +0 -145
- package/dist/lib/browser/chunk-CNTGBCMK.mjs.map +0 -7
- package/dist/lib/browser/chunk-F5BQOOEG.mjs +0 -160
- package/dist/lib/browser/chunk-F5BQOOEG.mjs.map +0 -7
- package/dist/lib/browser/chunk-M57WD3V6.mjs +0 -16
- package/dist/lib/browser/chunk-M57WD3V6.mjs.map +0 -7
- package/dist/lib/browser/chunk-MX7WRVX3.mjs +0 -127
- package/dist/lib/browser/chunk-MX7WRVX3.mjs.map +0 -7
- package/dist/lib/browser/chunk-NRCPV6AV.mjs +0 -129
- package/dist/lib/browser/chunk-NRCPV6AV.mjs.map +0 -7
- package/dist/lib/browser/chunk-Z5KITAZW.mjs +0 -13
- package/dist/lib/browser/chunk-Z5KITAZW.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-2SUIIV6N.mjs +0 -521
- package/dist/lib/browser/intent-resolver-2SUIIV6N.mjs.map +0 -7
- package/dist/lib/browser/react-root-GVZANZX7.mjs +0 -43
- package/dist/lib/browser/react-root-GVZANZX7.mjs.map +0 -7
- package/dist/lib/browser/react-surface-NXSSD2GW.mjs +0 -40
- package/dist/lib/browser/react-surface-NXSSD2GW.mjs.map +0 -7
- package/dist/lib/browser/settings-LUPQPZ27.mjs +0 -29
- package/dist/lib/browser/settings-LUPQPZ27.mjs.map +0 -7
- package/dist/lib/browser/state-CRXR7X63.mjs +0 -12
- package/dist/lib/browser/toolkit-OBKFXX23.mjs +0 -47
- package/dist/lib/browser/toolkit-OBKFXX23.mjs.map +0 -7
- package/dist/lib/browser/url-handler-LROZYQ26.mjs +0 -70
- package/dist/lib/browser/url-handler-LROZYQ26.mjs.map +0 -7
- package/dist/types/src/capabilities/capabilities.d.ts.map +0 -1
- package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
- package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/toolkit.d.ts +0 -5
- package/dist/types/src/capabilities/toolkit.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/ActiveNode.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/Banner.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/ContentEmpty.d.ts +0 -3
- package/dist/types/src/components/DeckLayout/ContentEmpty.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/DeckLayout.d.ts +0 -6
- package/dist/types/src/components/DeckLayout/DeckLayout.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/Dialog.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/Fallback.d.ts +0 -3
- package/dist/types/src/components/DeckLayout/Fallback.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/Popover.d.ts +0 -5
- package/dist/types/src/components/DeckLayout/Popover.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/StatusBar.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/Toast.d.ts +0 -5
- package/dist/types/src/components/DeckLayout/Toast.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/Topbar.d.ts +0 -3
- package/dist/types/src/components/DeckLayout/Topbar.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/constants.d.ts.map +0 -1
- package/dist/types/src/components/DeckLayout/index.d.ts +0 -4
- package/dist/types/src/components/DeckLayout/index.d.ts.map +0 -1
- package/dist/types/src/components/Plank/Plank.d.ts +0 -27
- package/dist/types/src/components/Plank/Plank.d.ts.map +0 -1
- package/dist/types/src/components/Plank/Plank.stories.d.ts +0 -8
- package/dist/types/src/components/Plank/Plank.stories.d.ts.map +0 -1
- package/dist/types/src/components/Plank/PlankControls.d.ts.map +0 -1
- package/dist/types/src/components/Plank/PlankError.d.ts +0 -13
- package/dist/types/src/components/Plank/PlankError.d.ts.map +0 -1
- package/dist/types/src/components/Plank/PlankHeading.d.ts.map +0 -1
- package/dist/types/src/components/Plank/index.d.ts +0 -6
- package/dist/types/src/components/Plank/index.d.ts.map +0 -1
- package/dist/types/src/components/Sidebar/ComplementarySidebar.d.ts.map +0 -1
- package/dist/types/src/components/Sidebar/Sidebar.d.ts.map +0 -1
- package/dist/types/src/components/Sidebar/SidebarButton.d.ts.map +0 -1
- package/dist/types/src/components/fragments.d.ts +0 -4
- package/dist/types/src/components/fragments.d.ts.map +0 -1
- package/dist/types/src/events.d.ts +0 -4
- package/dist/types/src/events.d.ts.map +0 -1
- package/dist/types/src/util/overscroll.d.ts +0 -47
- package/dist/types/src/util/overscroll.d.ts.map +0 -1
- package/src/capabilities/capabilities.ts +0 -14
- package/src/capabilities/intent-resolver.ts +0 -469
- package/src/capabilities/toolkit.ts +0 -55
- package/src/components/DeckLayout/ContentEmpty.tsx +0 -31
- package/src/components/DeckLayout/DeckLayout.tsx +0 -302
- package/src/components/DeckLayout/Dialog.tsx +0 -36
- package/src/components/DeckLayout/Fallback.tsx +0 -28
- package/src/components/DeckLayout/Popover.tsx +0 -104
- package/src/components/DeckLayout/Topbar.tsx +0 -11
- package/src/components/Plank/Plank.stories.tsx +0 -56
- package/src/components/Plank/Plank.tsx +0 -267
- package/src/components/Plank/PlankError.tsx +0 -49
- package/src/components/Sidebar/ComplementarySidebar.tsx +0 -194
- package/src/components/Sidebar/Sidebar.tsx +0 -42
- package/src/components/Sidebar/SidebarButton.tsx +0 -87
- package/src/components/fragments.ts +0 -14
- package/src/events.ts +0 -11
- package/src/util/overscroll.ts +0 -69
- /package/dist/lib/browser/{state-CRXR7X63.mjs.map → chunk-J5LGTIGS.mjs.map} +0 -0
- /package/dist/types/src/{components/DeckLayout → containers/Deck}/StatusBar.d.ts +0 -0
- /package/dist/types/src/{components → containers}/DeckLayout/ActiveNode.d.ts +0 -0
- /package/dist/types/src/{components → containers}/DeckLayout/Dialog.d.ts +0 -0
- /package/dist/types/src/{components → containers}/DeckLayout/constants.d.ts +0 -0
- /package/dist/types/src/{components → containers}/Plank/PlankLoading.d.ts +0 -0
- /package/dist/types/src/{components → containers}/Sidebar/ComplementarySidebar.d.ts +0 -0
- /package/dist/types/src/{components → containers}/Sidebar/Sidebar.d.ts +0 -0
- /package/dist/types/src/{components → containers}/Sidebar/index.d.ts +0 -0
- /package/src/{components → containers}/Sidebar/index.ts +0 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention/types';
|
|
11
|
+
|
|
12
|
+
import { closeEntry } from '../layout';
|
|
13
|
+
import { DeckCapabilities } from '../types';
|
|
14
|
+
import { computeActiveUpdates } from '../util';
|
|
15
|
+
import { updateActiveDeck } from './helpers';
|
|
16
|
+
|
|
17
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.Close> = LayoutOperation.Close.pipe(
|
|
18
|
+
Operation.withHandler(
|
|
19
|
+
Effect.fnUntraced(function* (input) {
|
|
20
|
+
const deck = yield* DeckCapabilities.getDeck();
|
|
21
|
+
const attention = yield* Capability.get(AttentionCapabilities.Attention);
|
|
22
|
+
|
|
23
|
+
const active = deck.solo ? [deck.solo] : deck.active;
|
|
24
|
+
const next = input.subject.reduce((acc, id) => closeEntry(acc, id), active);
|
|
25
|
+
const { deckUpdates, toAttend } = computeActiveUpdates({ next, deck, attention });
|
|
26
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => updateActiveDeck(state, deckUpdates));
|
|
27
|
+
|
|
28
|
+
if (toAttend) {
|
|
29
|
+
yield* Operation.schedule(LayoutOperation.ScrollIntoView, { subject: toAttend });
|
|
30
|
+
}
|
|
31
|
+
}),
|
|
32
|
+
),
|
|
33
|
+
);
|
|
34
|
+
|
|
35
|
+
export default handler;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Schema from 'effect/Schema';
|
|
6
|
+
|
|
7
|
+
import { Capability } from '@dxos/app-framework';
|
|
8
|
+
import { Operation } from '@dxos/compute';
|
|
9
|
+
|
|
10
|
+
import { meta } from '#meta';
|
|
11
|
+
|
|
12
|
+
const PartAdjustment = Schema.Union(
|
|
13
|
+
Schema.Literal('close').annotations({ description: 'Close the plank.' }),
|
|
14
|
+
Schema.Literal('companion').annotations({ description: 'Open the companion plank.' }),
|
|
15
|
+
Schema.Literal('solo').annotations({ description: 'Solo the plank.' }),
|
|
16
|
+
Schema.Literal('solo--fullscreen').annotations({ description: 'Fullscreen the plank.' }),
|
|
17
|
+
Schema.Literal('increment-start').annotations({ description: 'Move the plank towards the start of the deck.' }),
|
|
18
|
+
Schema.Literal('increment-end').annotations({ description: 'Move the plank towards the end of the deck.' }),
|
|
19
|
+
);
|
|
20
|
+
|
|
21
|
+
export type PartAdjustment = Schema.Schema.Type<typeof PartAdjustment>;
|
|
22
|
+
|
|
23
|
+
export const Adjust = Operation.make({
|
|
24
|
+
meta: {
|
|
25
|
+
key: `${meta.id}.operation.adjust`,
|
|
26
|
+
name: 'Adjust',
|
|
27
|
+
description: 'Adjust the layout of a plank.',
|
|
28
|
+
},
|
|
29
|
+
services: [Capability.Service],
|
|
30
|
+
input: Schema.Struct({
|
|
31
|
+
id: Schema.String.annotations({ description: 'The id of the plank to adjust.' }),
|
|
32
|
+
type: PartAdjustment.annotations({ description: 'The type of adjustment to make.' }),
|
|
33
|
+
}),
|
|
34
|
+
output: Schema.Void,
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
export const UpdatePlankSize = Operation.make({
|
|
38
|
+
meta: {
|
|
39
|
+
key: `${meta.id}.operation.update-plank-size`,
|
|
40
|
+
name: 'Update Plank Size',
|
|
41
|
+
description: 'Update the size of a plank.',
|
|
42
|
+
},
|
|
43
|
+
services: [Capability.Service],
|
|
44
|
+
input: Schema.Struct({
|
|
45
|
+
id: Schema.String.annotations({ description: 'The id of the plank to resize.' }),
|
|
46
|
+
size: Schema.Number.annotations({ description: 'The new size of the plank.' }),
|
|
47
|
+
}),
|
|
48
|
+
output: Schema.Void,
|
|
49
|
+
});
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import { invariant } from '@dxos/invariant';
|
|
6
|
+
|
|
7
|
+
import { type DeckState, type StoredDeckState } from '../types';
|
|
8
|
+
|
|
9
|
+
export const updateActiveDeck = (current: StoredDeckState, deckUpdates: Partial<DeckState>): StoredDeckState => {
|
|
10
|
+
const currentDeck = current.decks[current.activeDeck];
|
|
11
|
+
invariant(currentDeck, `Deck not found: ${current.activeDeck}`);
|
|
12
|
+
return {
|
|
13
|
+
...current,
|
|
14
|
+
decks: {
|
|
15
|
+
...current.decks,
|
|
16
|
+
[current.activeDeck]: {
|
|
17
|
+
...currentDeck,
|
|
18
|
+
...deckUpdates,
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import { OperationHandlerSet } from '@dxos/compute';
|
|
6
|
+
|
|
7
|
+
export * as DeckOperation from './definitions';
|
|
8
|
+
|
|
9
|
+
export const DeckOperationHandlerSet = OperationHandlerSet.lazy(
|
|
10
|
+
() => import('./add-toast'),
|
|
11
|
+
() => import('./adjust'),
|
|
12
|
+
() => import('./close'),
|
|
13
|
+
() => import('./open'),
|
|
14
|
+
() => import('./revert-workspace'),
|
|
15
|
+
() => import('./scroll-into-view'),
|
|
16
|
+
() => import('./set'),
|
|
17
|
+
() => import('./set-layout-mode'),
|
|
18
|
+
() => import('./show-undo'),
|
|
19
|
+
() => import('./switch-workspace'),
|
|
20
|
+
() => import('./update-companion'),
|
|
21
|
+
() => import('./update-complementary'),
|
|
22
|
+
() => import('./update-dialog'),
|
|
23
|
+
() => import('./update-plank-size'),
|
|
24
|
+
() => import('./update-popover'),
|
|
25
|
+
() => import('./update-sidebar'),
|
|
26
|
+
);
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
import * as Option from 'effect/Option';
|
|
7
|
+
|
|
8
|
+
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
9
|
+
import {
|
|
10
|
+
AppCapabilities,
|
|
11
|
+
LayoutOperation,
|
|
12
|
+
createEdgeExistenceChecker,
|
|
13
|
+
expandPath,
|
|
14
|
+
validateNavigationTarget,
|
|
15
|
+
} from '@dxos/app-toolkit';
|
|
16
|
+
import { Operation } from '@dxos/compute';
|
|
17
|
+
import { Context } from '@dxos/context';
|
|
18
|
+
import { Obj } from '@dxos/echo';
|
|
19
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention/types';
|
|
20
|
+
import { ClientCapabilities } from '@dxos/plugin-client/types';
|
|
21
|
+
import { Graph } from '@dxos/plugin-graph';
|
|
22
|
+
import { ObservabilityOperation } from '@dxos/plugin-observability/operations';
|
|
23
|
+
|
|
24
|
+
import { openSubjectsOnActiveDeck } from '../layout';
|
|
25
|
+
import { DeckCapabilities } from '../types';
|
|
26
|
+
import { computeActiveUpdates } from '../util';
|
|
27
|
+
import { updateActiveDeck } from './helpers';
|
|
28
|
+
|
|
29
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperation.Open.pipe(
|
|
30
|
+
Operation.withHandler(
|
|
31
|
+
Effect.fnUntraced(function* (input) {
|
|
32
|
+
const { graph } = yield* Capability.get(AppCapabilities.AppGraph);
|
|
33
|
+
const attention = yield* Capability.get(AttentionCapabilities.Attention);
|
|
34
|
+
|
|
35
|
+
// Validate navigation targets, redirecting to 404 if not found.
|
|
36
|
+
const capabilities = yield* Capability.Service;
|
|
37
|
+
const pathResolvers = capabilities.getAll(AppCapabilities.NavigationPathResolver);
|
|
38
|
+
const checkRemoteExistence = yield* Capability.get(ClientCapabilities.Client).pipe(
|
|
39
|
+
Effect.map((client) =>
|
|
40
|
+
createEdgeExistenceChecker((spaceId, body) => client.edge.http.execQuery(new Context(), spaceId, body)),
|
|
41
|
+
),
|
|
42
|
+
Effect.catchAll(() => Effect.succeed(undefined)),
|
|
43
|
+
);
|
|
44
|
+
|
|
45
|
+
// Immediate: skip 404 / resolver checks but still expand the path (same as validate’s first step).
|
|
46
|
+
if (input.navigation === 'immediate') {
|
|
47
|
+
for (const subjectId of input.subject) {
|
|
48
|
+
expandPath(graph, subjectId);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
const validatedSubjects = yield* Effect.all(
|
|
53
|
+
input.subject.map((subjectId) =>
|
|
54
|
+
input.navigation === 'immediate'
|
|
55
|
+
? Effect.succeed(subjectId)
|
|
56
|
+
: validateNavigationTarget({ graph, subjectId, pathResolvers, checkRemoteExistence }),
|
|
57
|
+
),
|
|
58
|
+
);
|
|
59
|
+
input = { ...input, subject: validatedSubjects };
|
|
60
|
+
|
|
61
|
+
{
|
|
62
|
+
const state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
|
63
|
+
if (input.workspace && state.activeDeck !== input.workspace) {
|
|
64
|
+
yield* Operation.invoke(LayoutOperation.SwitchWorkspace, { subject: input.workspace });
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
// Dedup subjects against the active deck using DXN identity.
|
|
69
|
+
// The same object can appear under different graph paths (e.g., via collections vs types).
|
|
70
|
+
// Resolve each subject's DXN and, if it matches an already-open deck item, remap the
|
|
71
|
+
// subject to the existing deck entry so that openEntry's exact-match check succeeds.
|
|
72
|
+
// Only needed in multi (deck) mode; solo mode replaces the single visible item anyway.
|
|
73
|
+
{
|
|
74
|
+
const deck = yield* DeckCapabilities.getDeck();
|
|
75
|
+
const active = !deck.solo && deck.initialized ? deck.active : [];
|
|
76
|
+
if (active.length > 0 && input.subject.length > 0) {
|
|
77
|
+
const resolveDxn = (qualifiedPath: string) =>
|
|
78
|
+
Effect.reduce(pathResolvers, Option.none<string>(), (acc, resolver) =>
|
|
79
|
+
Option.isSome(acc)
|
|
80
|
+
? Effect.succeed(acc)
|
|
81
|
+
: resolver(qualifiedPath).pipe(
|
|
82
|
+
Effect.map((opt) => Option.map(opt, (dxn) => dxn.toString())),
|
|
83
|
+
Effect.catchAll(() => Effect.succeed(Option.none<string>())),
|
|
84
|
+
),
|
|
85
|
+
);
|
|
86
|
+
|
|
87
|
+
// Build DXN → deck item ID map for active items.
|
|
88
|
+
const deckDxnMap = new Map<string, string>();
|
|
89
|
+
yield* Effect.all(
|
|
90
|
+
active.map((deckId) =>
|
|
91
|
+
resolveDxn(deckId).pipe(
|
|
92
|
+
Effect.map((opt) => {
|
|
93
|
+
if (Option.isSome(opt)) {
|
|
94
|
+
deckDxnMap.set(opt.value, deckId);
|
|
95
|
+
}
|
|
96
|
+
}),
|
|
97
|
+
),
|
|
98
|
+
),
|
|
99
|
+
{ concurrency: 'unbounded' },
|
|
100
|
+
);
|
|
101
|
+
|
|
102
|
+
// Remap subjects whose DXN matches an existing deck item.
|
|
103
|
+
if (deckDxnMap.size > 0) {
|
|
104
|
+
const remapped = yield* Effect.all(
|
|
105
|
+
input.subject.map((subjectId) =>
|
|
106
|
+
resolveDxn(subjectId).pipe(
|
|
107
|
+
Effect.map((opt) => {
|
|
108
|
+
if (Option.isSome(opt)) {
|
|
109
|
+
const existing = deckDxnMap.get(opt.value);
|
|
110
|
+
if (existing && existing !== subjectId) {
|
|
111
|
+
return existing;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
return subjectId;
|
|
115
|
+
}),
|
|
116
|
+
),
|
|
117
|
+
),
|
|
118
|
+
{ concurrency: 'unbounded' },
|
|
119
|
+
);
|
|
120
|
+
input = { ...input, subject: remapped };
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// Compute the next active deck state and apply it.
|
|
126
|
+
// In solo or uninitialized mode the subject list replaces the deck entirely.
|
|
127
|
+
// In multi (deck) mode, subjects are merged via openSubjectsOnActiveDeck which
|
|
128
|
+
// uses stack semantics (truncate after pivot, then push new entries).
|
|
129
|
+
let previouslyOpenIds: Set<string>;
|
|
130
|
+
{
|
|
131
|
+
const deck = yield* DeckCapabilities.getDeck();
|
|
132
|
+
previouslyOpenIds = new Set<string>(deck.solo ? [deck.solo] : deck.active);
|
|
133
|
+
const next =
|
|
134
|
+
deck.solo || !deck.initialized
|
|
135
|
+
? [...input.subject]
|
|
136
|
+
: openSubjectsOnActiveDeck(deck.active, input.subject, {
|
|
137
|
+
pivotId: input.pivotId,
|
|
138
|
+
key: input.key,
|
|
139
|
+
});
|
|
140
|
+
|
|
141
|
+
const { deckUpdates, toAttend: _toAttend } = computeActiveUpdates({ next, deck, attention });
|
|
142
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => updateActiveDeck(state, deckUpdates));
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
// Schedule side-effects for the newly opened items: scroll into view, expose in
|
|
146
|
+
// the navigation sidebar, and emit observability events.
|
|
147
|
+
// When nothing is newly opened (subject was already visible), the fallback
|
|
148
|
+
// `input.subject[0]` still triggers scroll and expose so the user is taken there.
|
|
149
|
+
{
|
|
150
|
+
const deck = yield* DeckCapabilities.getDeck();
|
|
151
|
+
const ids = deck.solo ? [deck.solo] : deck.active;
|
|
152
|
+
const newlyOpen = ids.filter((i: string) => !previouslyOpenIds.has(i));
|
|
153
|
+
|
|
154
|
+
if (input.scrollIntoView !== false && (newlyOpen[0] ?? input.subject[0])) {
|
|
155
|
+
yield* Operation.schedule(LayoutOperation.ScrollIntoView, {
|
|
156
|
+
subject: newlyOpen[0] ?? input.subject[0],
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
if (newlyOpen[0] ?? input.subject[0]) {
|
|
161
|
+
yield* Operation.schedule(LayoutOperation.Expose, { subject: newlyOpen[0] ?? input.subject[0] });
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
for (const subjectId of newlyOpen) {
|
|
165
|
+
const typename = Option.match(Graph.getNode(graph, subjectId), {
|
|
166
|
+
onNone: () => undefined,
|
|
167
|
+
onSome: (node) => {
|
|
168
|
+
const active = node.data;
|
|
169
|
+
return Obj.isObject(active) ? Obj.getTypename(active) : undefined;
|
|
170
|
+
},
|
|
171
|
+
});
|
|
172
|
+
yield* Operation.schedule(ObservabilityOperation.SendEvent, {
|
|
173
|
+
name: 'navigation.activate',
|
|
174
|
+
properties: { subjectId, typename },
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
return validatedSubjects;
|
|
180
|
+
}),
|
|
181
|
+
),
|
|
182
|
+
);
|
|
183
|
+
|
|
184
|
+
export default handler;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
|
|
11
|
+
import { DeckCapabilities } from '../types';
|
|
12
|
+
|
|
13
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.RevertWorkspace> = LayoutOperation.RevertWorkspace.pipe(
|
|
14
|
+
Operation.withHandler(
|
|
15
|
+
Effect.fnUntraced(function* () {
|
|
16
|
+
const state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
|
17
|
+
yield* Operation.invoke(LayoutOperation.SwitchWorkspace, { subject: state.previousDeck });
|
|
18
|
+
}),
|
|
19
|
+
),
|
|
20
|
+
);
|
|
21
|
+
|
|
22
|
+
export default handler;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
|
|
11
|
+
import { DeckCapabilities } from '../types';
|
|
12
|
+
|
|
13
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.ScrollIntoView> = LayoutOperation.ScrollIntoView.pipe(
|
|
14
|
+
Operation.withHandler(
|
|
15
|
+
Effect.fnUntraced(function* (input) {
|
|
16
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.EphemeralState, (state) => ({
|
|
17
|
+
...state,
|
|
18
|
+
scrollIntoView: input.subject,
|
|
19
|
+
}));
|
|
20
|
+
}),
|
|
21
|
+
),
|
|
22
|
+
);
|
|
23
|
+
|
|
24
|
+
export default handler;
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { log } from '@dxos/log';
|
|
11
|
+
import { isNonNullable } from '@dxos/util';
|
|
12
|
+
|
|
13
|
+
import { DeckCapabilities, type DeckState, type LayoutMode, getMode, isLayoutMode } from '../types';
|
|
14
|
+
import { updateActiveDeck } from './helpers';
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Transitions between layout modes (multi, solo, solo--fullscreen) or reverts to the previous mode.
|
|
18
|
+
* Computes which planks become active/inactive and persists the previous mode for revert support.
|
|
19
|
+
*/
|
|
20
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.SetLayoutMode> = LayoutOperation.SetLayoutMode.pipe(
|
|
21
|
+
Operation.withHandler(
|
|
22
|
+
Effect.fnUntraced(function* (input) {
|
|
23
|
+
if ('mode' in input && !isLayoutMode(input.mode)) {
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
const state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
|
28
|
+
const deck = yield* DeckCapabilities.getDeck();
|
|
29
|
+
|
|
30
|
+
const computeModeUpdate = (mode: LayoutMode, subject?: string): Partial<DeckState> => {
|
|
31
|
+
const current = deck.solo ? [deck.solo] : deck.active;
|
|
32
|
+
const next = (mode !== 'multi' ? [subject ?? deck.solo ?? deck.active[0]] : [...deck.active, deck.solo]).filter(
|
|
33
|
+
isNonNullable,
|
|
34
|
+
);
|
|
35
|
+
|
|
36
|
+
const removed = current.filter((id: string) => !next.includes(id));
|
|
37
|
+
const closed = Array.from(new Set([...deck.inactive.filter((id: string) => !next.includes(id)), ...removed]));
|
|
38
|
+
|
|
39
|
+
const soloUpdate =
|
|
40
|
+
mode !== 'multi' && next[0]
|
|
41
|
+
? { solo: next[0] }
|
|
42
|
+
: mode === 'multi' && deck.solo
|
|
43
|
+
? { solo: undefined, initialized: true }
|
|
44
|
+
: {};
|
|
45
|
+
|
|
46
|
+
const fullscreenUpdate = mode === 'solo--fullscreen' ? { fullscreen: !deck.fullscreen } : {};
|
|
47
|
+
|
|
48
|
+
return {
|
|
49
|
+
inactive: closed,
|
|
50
|
+
...soloUpdate,
|
|
51
|
+
...fullscreenUpdate,
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
if ('mode' in input) {
|
|
56
|
+
const currentMode = getMode(deck);
|
|
57
|
+
const subject = 'subject' in input ? input.subject : undefined;
|
|
58
|
+
const deckUpdates = computeModeUpdate(input.mode as LayoutMode, subject);
|
|
59
|
+
|
|
60
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => {
|
|
61
|
+
const newPreviousMode =
|
|
62
|
+
currentMode !== input.mode
|
|
63
|
+
? { ...state.previousMode, [state.activeDeck]: currentMode }
|
|
64
|
+
: state.previousMode;
|
|
65
|
+
return {
|
|
66
|
+
...updateActiveDeck(state, deckUpdates),
|
|
67
|
+
previousMode: newPreviousMode,
|
|
68
|
+
};
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
if (subject) {
|
|
72
|
+
yield* Operation.schedule(LayoutOperation.Expose, { subject });
|
|
73
|
+
}
|
|
74
|
+
} else if ('revert' in input) {
|
|
75
|
+
const deckUpdates = computeModeUpdate(state.previousMode[state.activeDeck]);
|
|
76
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => updateActiveDeck(state, deckUpdates));
|
|
77
|
+
} else {
|
|
78
|
+
log.warn('Invalid layout mode', input);
|
|
79
|
+
}
|
|
80
|
+
}),
|
|
81
|
+
),
|
|
82
|
+
);
|
|
83
|
+
|
|
84
|
+
export default handler;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { AttentionCapabilities } from '@dxos/plugin-attention/types';
|
|
11
|
+
|
|
12
|
+
import { DeckCapabilities } from '../types';
|
|
13
|
+
import { computeActiveUpdates } from '../util';
|
|
14
|
+
import { updateActiveDeck } from './helpers';
|
|
15
|
+
|
|
16
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.Set> = LayoutOperation.Set.pipe(
|
|
17
|
+
Operation.withHandler(
|
|
18
|
+
Effect.fnUntraced(function* (input) {
|
|
19
|
+
const deck = yield* DeckCapabilities.getDeck();
|
|
20
|
+
const attention = yield* Capability.get(AttentionCapabilities.Attention);
|
|
21
|
+
|
|
22
|
+
const { deckUpdates, toAttend } = computeActiveUpdates({
|
|
23
|
+
next: input.subject as string[],
|
|
24
|
+
deck,
|
|
25
|
+
attention,
|
|
26
|
+
});
|
|
27
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => updateActiveDeck(state, deckUpdates));
|
|
28
|
+
|
|
29
|
+
if (toAttend) {
|
|
30
|
+
yield* Operation.schedule(LayoutOperation.ScrollIntoView, { subject: toAttend });
|
|
31
|
+
}
|
|
32
|
+
}),
|
|
33
|
+
),
|
|
34
|
+
);
|
|
35
|
+
|
|
36
|
+
export default handler;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities, Capability, UndoOperation } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
|
|
11
|
+
import { meta } from '#meta';
|
|
12
|
+
|
|
13
|
+
import { DeckCapabilities } from '../types';
|
|
14
|
+
|
|
15
|
+
const handler: Operation.WithHandler<typeof UndoOperation.ShowUndo> = UndoOperation.ShowUndo.pipe(
|
|
16
|
+
Operation.withHandler(
|
|
17
|
+
Effect.fnUntraced(function* (input) {
|
|
18
|
+
const historyTracker = yield* Capability.get(Capabilities.HistoryTracker);
|
|
19
|
+
|
|
20
|
+
const newUndoId = `show-undo-${Date.now()}`;
|
|
21
|
+
// TODO(wittjosiah): Support undoing further back than the last action.
|
|
22
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.EphemeralState, (state) => {
|
|
23
|
+
const filteredToasts = state.currentUndoId
|
|
24
|
+
? state.toasts.filter((toast) => toast.id !== state.currentUndoId)
|
|
25
|
+
: state.toasts;
|
|
26
|
+
|
|
27
|
+
const toast: LayoutOperation.Toast = {
|
|
28
|
+
id: newUndoId,
|
|
29
|
+
title: input.message ?? ['undo-available.label', { ns: meta.id }],
|
|
30
|
+
duration: 10_000,
|
|
31
|
+
actionLabel: ['undo-action.label', { ns: meta.id }],
|
|
32
|
+
actionAlt: ['undo-action.alt', { ns: meta.id }],
|
|
33
|
+
closeLabel: ['undo-close.label', { ns: meta.id }],
|
|
34
|
+
onAction: () => historyTracker.undoPromise(),
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
return {
|
|
38
|
+
...state,
|
|
39
|
+
currentUndoId: newUndoId,
|
|
40
|
+
toasts: [...filteredToasts, toast],
|
|
41
|
+
};
|
|
42
|
+
});
|
|
43
|
+
}),
|
|
44
|
+
),
|
|
45
|
+
);
|
|
46
|
+
|
|
47
|
+
export default handler;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities, Capability } from '@dxos/app-framework';
|
|
8
|
+
import { AppCapabilities, isPinnedWorkspace, LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { invariant } from '@dxos/invariant';
|
|
11
|
+
import { Graph, Node } from '@dxos/plugin-graph';
|
|
12
|
+
|
|
13
|
+
import { DeckCapabilities, defaultDeck } from '../types';
|
|
14
|
+
|
|
15
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.SwitchWorkspace> = LayoutOperation.SwitchWorkspace.pipe(
|
|
16
|
+
Operation.withHandler(
|
|
17
|
+
Effect.fnUntraced(function* (input) {
|
|
18
|
+
const { graph } = yield* Capability.get(AppCapabilities.AppGraph);
|
|
19
|
+
|
|
20
|
+
{
|
|
21
|
+
const state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
|
22
|
+
// TODO(wittjosiah): This is a hack to prevent the previous deck from being set for pinned items.
|
|
23
|
+
// Ideally this should be worked into the data model in a generic way.
|
|
24
|
+
const shouldUpdatePrevious = !isPinnedWorkspace(state.activeDeck);
|
|
25
|
+
|
|
26
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => {
|
|
27
|
+
const newDecks = state.decks[input.subject]
|
|
28
|
+
? state.decks
|
|
29
|
+
: { ...state.decks, [input.subject]: { ...defaultDeck } };
|
|
30
|
+
return {
|
|
31
|
+
...state,
|
|
32
|
+
previousDeck: shouldUpdatePrevious ? state.activeDeck : state.previousDeck,
|
|
33
|
+
activeDeck: input.subject,
|
|
34
|
+
decks: newDecks,
|
|
35
|
+
};
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
{
|
|
40
|
+
const state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
|
41
|
+
const deck = state.decks[input.subject];
|
|
42
|
+
invariant(deck, `Deck not found: ${input.subject}`);
|
|
43
|
+
|
|
44
|
+
const first = deck.solo ? deck.solo : deck.active[0];
|
|
45
|
+
if (first) {
|
|
46
|
+
yield* Operation.schedule(LayoutOperation.ScrollIntoView, { subject: first });
|
|
47
|
+
} else {
|
|
48
|
+
const [item] = Graph.getConnections(graph, input.subject, 'child').filter(
|
|
49
|
+
(node) => !Node.isActionLike(node) && !node.properties.disposition,
|
|
50
|
+
);
|
|
51
|
+
if (item) {
|
|
52
|
+
yield* Operation.schedule(LayoutOperation.Open, { subject: [item.id] });
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}),
|
|
57
|
+
),
|
|
58
|
+
);
|
|
59
|
+
|
|
60
|
+
export default handler;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
import { getLinkedVariant } from '@dxos/react-ui-attention';
|
|
11
|
+
|
|
12
|
+
import { DeckCapabilities } from '../types';
|
|
13
|
+
import { updateActiveDeck } from './helpers';
|
|
14
|
+
|
|
15
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.UpdateCompanion> = LayoutOperation.UpdateCompanion.pipe(
|
|
16
|
+
Operation.withHandler(
|
|
17
|
+
Effect.fnUntraced(function* (input) {
|
|
18
|
+
if (input.subject === null) {
|
|
19
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) =>
|
|
20
|
+
updateActiveDeck(state, { companionOpen: false }),
|
|
21
|
+
);
|
|
22
|
+
} else {
|
|
23
|
+
const variant = getLinkedVariant(input.subject);
|
|
24
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) =>
|
|
25
|
+
updateActiveDeck(state, {
|
|
26
|
+
companionOpen: true,
|
|
27
|
+
companionVariant: variant,
|
|
28
|
+
}),
|
|
29
|
+
);
|
|
30
|
+
}
|
|
31
|
+
}),
|
|
32
|
+
),
|
|
33
|
+
);
|
|
34
|
+
|
|
35
|
+
export default handler;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Effect from 'effect/Effect';
|
|
6
|
+
|
|
7
|
+
import { Capabilities } from '@dxos/app-framework';
|
|
8
|
+
import { LayoutOperation } from '@dxos/app-toolkit';
|
|
9
|
+
import { Operation } from '@dxos/compute';
|
|
10
|
+
|
|
11
|
+
import { DeckCapabilities } from '../types';
|
|
12
|
+
|
|
13
|
+
const handler: Operation.WithHandler<typeof LayoutOperation.UpdateComplementary> =
|
|
14
|
+
LayoutOperation.UpdateComplementary.pipe(
|
|
15
|
+
Operation.withHandler(
|
|
16
|
+
Effect.fnUntraced(function* (input) {
|
|
17
|
+
const state = yield* Capabilities.getAtomValue(DeckCapabilities.State);
|
|
18
|
+
const panelChanged = state.complementarySidebarPanel !== input.subject;
|
|
19
|
+
const next = input.subject ? 'expanded' : (input.state ?? state.complementarySidebarState);
|
|
20
|
+
const stateChanged = next !== state.complementarySidebarState;
|
|
21
|
+
|
|
22
|
+
if (panelChanged || stateChanged) {
|
|
23
|
+
yield* Capabilities.updateAtomValue(DeckCapabilities.State, (state) => ({
|
|
24
|
+
...state,
|
|
25
|
+
complementarySidebarPanel: panelChanged ? input.subject : state.complementarySidebarPanel,
|
|
26
|
+
complementarySidebarState: stateChanged ? next : state.complementarySidebarState,
|
|
27
|
+
}));
|
|
28
|
+
}
|
|
29
|
+
}),
|
|
30
|
+
),
|
|
31
|
+
);
|
|
32
|
+
|
|
33
|
+
export default handler;
|