@dxos/plugin-testing 0.8.4-main.6fa680abb7 → 0.8.4-main.7996785055
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-M6ZVP2PQ.mjs +22 -0
- package/dist/lib/browser/add-toast-M6ZVP2PQ.mjs.map +7 -0
- package/dist/lib/browser/{chunk-NWOKPVNQ.mjs → chunk-F2MMDTKN.mjs} +1 -1
- package/dist/lib/browser/chunk-F2MMDTKN.mjs.map +7 -0
- package/dist/lib/browser/chunk-M4TYMLOE.mjs +21 -0
- package/dist/lib/browser/chunk-M4TYMLOE.mjs.map +7 -0
- package/dist/lib/browser/close-M6YHTWUZ.mjs +10 -0
- package/dist/lib/browser/close-M6YHTWUZ.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +47 -17
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/open-ND4QPYWD.mjs +10 -0
- package/dist/lib/browser/open-ND4QPYWD.mjs.map +7 -0
- package/dist/lib/browser/operation-handler-DUWMXELV.mjs +16 -0
- package/dist/lib/browser/operation-handler-DUWMXELV.mjs.map +7 -0
- package/dist/lib/browser/scroll-into-view-UAINWR6E.mjs +10 -0
- package/dist/lib/browser/scroll-into-view-UAINWR6E.mjs.map +7 -0
- package/dist/lib/browser/set-layout-mode-E6SJ6ATN.mjs +10 -0
- package/dist/lib/browser/set-layout-mode-E6SJ6ATN.mjs.map +7 -0
- package/dist/lib/browser/{state-TCYYH5JN.mjs → state-MRRN7LZE.mjs} +3 -2
- package/dist/lib/browser/state-MRRN7LZE.mjs.map +7 -0
- package/dist/lib/browser/switch-workspace-RPYF6M6L.mjs +19 -0
- package/dist/lib/browser/switch-workspace-RPYF6M6L.mjs.map +7 -0
- package/dist/lib/browser/update-complementary-HNS4FIWF.mjs +25 -0
- package/dist/lib/browser/update-complementary-HNS4FIWF.mjs.map +7 -0
- package/dist/lib/browser/update-dialog-W7QOCQ2N.mjs +27 -0
- package/dist/lib/browser/update-dialog-W7QOCQ2N.mjs.map +7 -0
- package/dist/lib/browser/update-popover-UELZDJW6.mjs +45 -0
- package/dist/lib/browser/update-popover-UELZDJW6.mjs.map +7 -0
- package/dist/lib/browser/update-sidebar-RJZTREDE.mjs +25 -0
- package/dist/lib/browser/update-sidebar-RJZTREDE.mjs.map +7 -0
- package/dist/lib/node-esm/add-toast-VMEADC7Y.mjs +23 -0
- package/dist/lib/node-esm/add-toast-VMEADC7Y.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-NWN7D2LS.mjs → chunk-VDX7GMAD.mjs} +1 -1
- package/dist/lib/node-esm/chunk-VDX7GMAD.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-ZLM7QUEK.mjs +22 -0
- package/dist/lib/node-esm/chunk-ZLM7QUEK.mjs.map +7 -0
- package/dist/lib/node-esm/close-B54TW3OK.mjs +12 -0
- package/dist/lib/node-esm/close-B54TW3OK.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +47 -17
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/open-OLJQ7VR3.mjs +12 -0
- package/dist/lib/node-esm/open-OLJQ7VR3.mjs.map +7 -0
- package/dist/lib/node-esm/operation-handler-TCIEZXBS.mjs +18 -0
- package/dist/lib/node-esm/operation-handler-TCIEZXBS.mjs.map +7 -0
- package/dist/lib/node-esm/scroll-into-view-C3XK4YMK.mjs +12 -0
- package/dist/lib/node-esm/scroll-into-view-C3XK4YMK.mjs.map +7 -0
- package/dist/lib/node-esm/set-layout-mode-AEQI6AVR.mjs +12 -0
- package/dist/lib/node-esm/set-layout-mode-AEQI6AVR.mjs.map +7 -0
- package/dist/lib/node-esm/{state-ZJEK6SP7.mjs → state-PVDE6Q6G.mjs} +3 -2
- package/dist/lib/node-esm/state-PVDE6Q6G.mjs.map +7 -0
- package/dist/lib/node-esm/switch-workspace-ZDUCWF6E.mjs +20 -0
- package/dist/lib/node-esm/switch-workspace-ZDUCWF6E.mjs.map +7 -0
- package/dist/lib/node-esm/update-complementary-LAPUAZ5I.mjs +26 -0
- package/dist/lib/node-esm/update-complementary-LAPUAZ5I.mjs.map +7 -0
- package/dist/lib/node-esm/update-dialog-5M7FL4XG.mjs +28 -0
- package/dist/lib/node-esm/update-dialog-5M7FL4XG.mjs.map +7 -0
- package/dist/lib/node-esm/update-popover-2TDGFHL3.mjs +46 -0
- package/dist/lib/node-esm/update-popover-2TDGFHL3.mjs.map +7 -0
- package/dist/lib/node-esm/update-sidebar-CU6TUDK5.mjs +26 -0
- package/dist/lib/node-esm/update-sidebar-CU6TUDK5.mjs.map +7 -0
- package/dist/types/src/capabilities/index.d.ts +1 -1
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/operation-handler/index.d.ts +4 -0
- package/dist/types/src/capabilities/operation-handler/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-handler/operation-handler.d.ts +6 -0
- package/dist/types/src/capabilities/operation-handler/operation-handler.d.ts.map +1 -0
- package/dist/types/src/capabilities/state/state.d.ts.map +1 -1
- package/dist/types/src/components/Layout/Layout.d.ts.map +1 -1
- package/dist/types/src/core.d.ts +1 -7
- package/dist/types/src/core.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/close.d.ts +5 -0
- package/dist/types/src/operations/close.d.ts.map +1 -0
- package/dist/types/src/operations/index.d.ts +3 -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/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 +5 -0
- package/dist/types/src/operations/set-layout-mode.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-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-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/operations/update-state.d.ts +5 -0
- package/dist/types/src/operations/update-state.d.ts.map +1 -0
- package/dist/types/src/types/capabilities.d.ts +2 -0
- package/dist/types/src/types/capabilities.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +16 -17
- package/src/StorybookPlugin.ts +3 -3
- package/src/capabilities/index.ts +1 -1
- package/src/capabilities/operation-handler/index.ts +11 -0
- package/src/capabilities/operation-handler/operation-handler.ts +16 -0
- package/src/capabilities/state/state.tsx +1 -0
- package/src/components/Layout/Layout.tsx +124 -70
- package/src/core.ts +0 -5
- package/src/operations/add-toast.ts +22 -0
- package/src/operations/close.ts +14 -0
- package/src/operations/index.ts +18 -0
- package/src/operations/open.ts +14 -0
- package/src/operations/scroll-into-view.ts +14 -0
- package/src/operations/set-layout-mode.ts +14 -0
- package/src/operations/switch-workspace.ts +20 -0
- package/src/operations/update-complementary.ts +27 -0
- package/src/operations/update-dialog.ts +27 -0
- package/src/operations/update-popover.ts +37 -0
- package/src/operations/update-sidebar.ts +26 -0
- package/src/operations/update-state.ts +17 -0
- package/src/types/capabilities.ts +3 -0
- package/dist/lib/browser/chunk-NWOKPVNQ.mjs.map +0 -7
- package/dist/lib/browser/operation-resolver-SR4GZ7Q5.mjs +0 -112
- package/dist/lib/browser/operation-resolver-SR4GZ7Q5.mjs.map +0 -7
- package/dist/lib/browser/state-TCYYH5JN.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-NWN7D2LS.mjs.map +0 -7
- package/dist/lib/node-esm/operation-resolver-A6XLCTWX.mjs +0 -113
- package/dist/lib/node-esm/operation-resolver-A6XLCTWX.mjs.map +0 -7
- package/dist/lib/node-esm/state-ZJEK6SP7.mjs.map +0 -7
- package/dist/types/src/capabilities/operation-resolver/index.d.ts +0 -3
- package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +0 -1
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +0 -5
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +0 -1
- package/src/capabilities/operation-resolver/index.ts +0 -7
- package/src/capabilities/operation-resolver/operation-resolver.ts +0 -99
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import {
|
|
2
|
+
updateState
|
|
3
|
+
} from "./chunk-M4TYMLOE.mjs";
|
|
4
|
+
import "./chunk-F2MMDTKN.mjs";
|
|
5
|
+
|
|
6
|
+
// src/operations/add-toast.ts
|
|
7
|
+
import * as Effect from "effect/Effect";
|
|
8
|
+
import { LayoutOperation } from "@dxos/app-toolkit";
|
|
9
|
+
import { Operation } from "@dxos/operation";
|
|
10
|
+
var handler = LayoutOperation.AddToast.pipe(Operation.withHandler(Effect.fnUntraced(function* (input) {
|
|
11
|
+
yield* updateState((state) => ({
|
|
12
|
+
toasts: [
|
|
13
|
+
...state.toasts,
|
|
14
|
+
input
|
|
15
|
+
]
|
|
16
|
+
}));
|
|
17
|
+
})));
|
|
18
|
+
var add_toast_default = handler;
|
|
19
|
+
export {
|
|
20
|
+
add_toast_default as default
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=add-toast-M6ZVP2PQ.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/add-toast.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/operation';\n\nimport { updateState } from './update-state';\n\nconst handler: Operation.WithHandler<typeof LayoutOperation.AddToast> = LayoutOperation.AddToast.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* (input) {\n yield* updateState((state) => ({\n toasts: [...state.toasts, input as LayoutOperation.Toast],\n }));\n }),\n ),\n);\n\nexport default handler;\n"],
|
|
5
|
+
"mappings": ";;;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAI1B,IAAMC,UAAkEC,gBAAgBC,SAASC,KAC/FC,UAAUC,YACDC,kBAAW,WAAWC,OAAK;AAChC,SAAOC,YAAY,CAACC,WAAW;IAC7BC,QAAQ;SAAID,MAAMC;MAAQH;;EAC5B,EAAA;AACF,CAAA,CAAA,CAAA;AAIJ,IAAA,oBAAeP;",
|
|
6
|
+
"names": ["Effect", "LayoutOperation", "Operation", "handler", "LayoutOperation", "AddToast", "pipe", "Operation", "withHandler", "fnUntraced", "input", "updateState", "state", "toasts"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/meta.ts", "../../../src/types/capabilities.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { trim } from '@dxos/util';\n\nexport const meta: Plugin.Meta = {\n id: 'org.dxos.plugin.storybook-layout',\n name: 'Storybook',\n description: trim`\n Development layout optimized for Storybook component testing and documentation.\n Provides specialized views for component development and design system exploration.\n `,\n source: 'https://github.com/dxos/dxos/tree/main/packages/plugins/plugin-testing',\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { type Atom } from '@effect-atom/atom-react';\n\nimport { Capability } from '@dxos/app-framework';\nimport { type LayoutOperation } from '@dxos/app-toolkit';\nimport { type Label } from '@dxos/react-ui';\n\nimport { meta } from '../meta';\n\nexport type LayoutStateProps = {\n sidebarState?: 'expanded' | 'collapsed' | 'closed';\n complementarySidebarState?: 'expanded' | 'collapsed' | 'closed';\n\n dialogOpen: boolean;\n dialogType?: 'default' | 'alert';\n dialogBlockAlign?: 'start' | 'center' | 'end';\n dialogOverlayClasses?: string;\n dialogOverlayStyle?: Record<string, any>;\n /** Data to be passed to the dialog Surface. */\n dialogContent?: any;\n\n popoverOpen?: boolean;\n popoverSide?: 'top' | 'right' | 'bottom' | 'left';\n popoverVariant?: 'virtual' | 'react';\n popoverAnchor?: HTMLButtonElement;\n popoverAnchorId?: string;\n popoverKind?: 'base' | 'card';\n popoverTitle?: Label;\n popoverContent?: any;\n\n toasts: LayoutOperation.Toast[];\n\n workspace: string;\n};\n\nexport const LayoutState = Capability.make<Atom.Writable<LayoutStateProps>>(`${meta.id}.state`);\n"],
|
|
5
|
+
"mappings": ";AAKA,SAASA,YAAY;AAEd,IAAMC,OAAoB;EAC/BC,IAAI;EACJC,MAAM;EACNC,aAAaC;;;;EAIbC,QAAQ;AACV;;;ACTA,SAASC,kBAAkB;AAgCpB,IAAMC,cAAcC,WAAWC,KAAsC,GAAGC,KAAKC,EAAE,QAAQ;",
|
|
6
|
+
"names": ["trim", "meta", "id", "name", "description", "trim", "source", "Capability", "LayoutState", "Capability", "make", "meta", "id"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import {
|
|
2
|
+
LayoutState
|
|
3
|
+
} from "./chunk-F2MMDTKN.mjs";
|
|
4
|
+
|
|
5
|
+
// src/operations/update-state.ts
|
|
6
|
+
import * as Effect from "effect/Effect";
|
|
7
|
+
import { Capabilities, Capability } from "@dxos/app-framework";
|
|
8
|
+
var updateState = (fn) => Effect.gen(function* () {
|
|
9
|
+
const registry = yield* Capability.get(Capabilities.AtomRegistry);
|
|
10
|
+
const stateAtom = yield* Capability.get(LayoutState);
|
|
11
|
+
const current = registry.get(stateAtom);
|
|
12
|
+
registry.set(stateAtom, {
|
|
13
|
+
...current,
|
|
14
|
+
...fn(current)
|
|
15
|
+
});
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
export {
|
|
19
|
+
updateState
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=chunk-M4TYMLOE.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/update-state.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Capabilities, Capability } from '@dxos/app-framework';\n\nimport { LayoutState, type LayoutStateProps } from '../types';\n\nexport const updateState = (fn: (state: LayoutStateProps) => Partial<LayoutStateProps>) =>\n Effect.gen(function* () {\n const registry = yield* Capability.get(Capabilities.AtomRegistry);\n const stateAtom = yield* Capability.get(LayoutState);\n const current = registry.get(stateAtom);\n registry.set(stateAtom, { ...current, ...fn(current) });\n });\n"],
|
|
5
|
+
"mappings": ";;;;;AAIA,YAAYA,YAAY;AAExB,SAASC,cAAcC,kBAAkB;AAIlC,IAAMC,cAAc,CAACC,OACnBC,WAAI,aAAA;AACT,QAAMC,WAAW,OAAOC,WAAWC,IAAIC,aAAaC,YAAY;AAChE,QAAMC,YAAY,OAAOJ,WAAWC,IAAII,WAAAA;AACxC,QAAMC,UAAUP,SAASE,IAAIG,SAAAA;AAC7BL,WAASQ,IAAIH,WAAW;IAAE,GAAGE;IAAS,GAAGT,GAAGS,OAAAA;EAAS,CAAA;AACvD,CAAA;",
|
|
6
|
+
"names": ["Effect", "Capabilities", "Capability", "updateState", "fn", "gen", "registry", "Capability", "get", "Capabilities", "AtomRegistry", "stateAtom", "LayoutState", "current", "set"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/operations/close.ts
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
import { LayoutOperation } from "@dxos/app-toolkit";
|
|
4
|
+
import { Operation } from "@dxos/operation";
|
|
5
|
+
var handler = LayoutOperation.Close.pipe(Operation.withHandler(() => Effect.void));
|
|
6
|
+
var close_default = handler;
|
|
7
|
+
export {
|
|
8
|
+
close_default as default
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=close-M6YHTWUZ.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/close.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/operation';\n\nconst handler: Operation.WithHandler<typeof LayoutOperation.Close> = LayoutOperation.Close.pipe(\n Operation.withHandler(() => Effect.void),\n);\n\nexport default handler;\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,YAAY;AAExB,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAE1B,IAAMC,UAA+DC,gBAAgBC,MAAMC,KACzFC,UAAUC,YAAY,MAAaC,WAAI,CAAA;AAGzC,IAAA,gBAAeN;",
|
|
6
|
+
"names": ["Effect", "LayoutOperation", "Operation", "handler", "LayoutOperation", "Close", "pipe", "Operation", "withHandler", "void"]
|
|
7
|
+
}
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
LayoutState,
|
|
3
3
|
meta
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-F2MMDTKN.mjs";
|
|
5
5
|
|
|
6
6
|
// src/core.ts
|
|
7
7
|
import { OperationPlugin, RuntimePlugin } from "@dxos/app-framework";
|
|
8
8
|
import { AttentionPlugin } from "@dxos/plugin-attention";
|
|
9
|
-
import { ClientPlugin } from "@dxos/plugin-client";
|
|
10
9
|
import { GraphPlugin } from "@dxos/plugin-graph";
|
|
11
10
|
import { SettingsPlugin } from "@dxos/plugin-settings";
|
|
12
11
|
import { ThemePlugin } from "@dxos/plugin-theme";
|
|
@@ -27,23 +26,49 @@ import * as Effect from "effect/Effect";
|
|
|
27
26
|
import { ActivationEvents, Capabilities, Capability as Capability3, Plugin } from "@dxos/app-framework";
|
|
28
27
|
import { AppActivationEvents, AppPlugin } from "@dxos/app-toolkit";
|
|
29
28
|
|
|
30
|
-
// src/capabilities/operation-
|
|
29
|
+
// src/capabilities/operation-handler/index.ts
|
|
31
30
|
import { Capability } from "@dxos/app-framework";
|
|
32
|
-
var
|
|
31
|
+
var OperationHandler = Capability.lazy("OperationHandler", () => import("./operation-handler-DUWMXELV.mjs"));
|
|
33
32
|
|
|
34
33
|
// src/capabilities/state/index.ts
|
|
35
34
|
import { Capability as Capability2 } from "@dxos/app-framework";
|
|
36
|
-
var State = Capability2.lazy("State", () => import("./state-
|
|
35
|
+
var State = Capability2.lazy("State", () => import("./state-MRRN7LZE.mjs"));
|
|
37
36
|
|
|
38
37
|
// src/components/Layout/Layout.tsx
|
|
39
38
|
import { RegistryContext, useAtomValue } from "@effect-atom/atom-react";
|
|
40
39
|
import React, { useCallback, useContext, useEffect, useRef, useState } from "react";
|
|
41
40
|
import { Surface, useCapability } from "@dxos/app-framework/ui";
|
|
42
|
-
import { AlertDialog, Dialog, Main, Popover, toLocalizedString, useTranslation } from "@dxos/react-ui";
|
|
41
|
+
import { AlertDialog, Button, Dialog, Icon, Main, Popover, Toast, toLocalizedString, useTranslation } from "@dxos/react-ui";
|
|
43
42
|
import { Card } from "@dxos/react-ui";
|
|
44
43
|
import { Mosaic } from "@dxos/react-ui-mosaic";
|
|
45
44
|
import { descriptionMessage, mx } from "@dxos/ui-theme";
|
|
46
45
|
var debounce_delay = 100;
|
|
46
|
+
var StoryToast = ({ toast, onDismiss }) => {
|
|
47
|
+
const { t } = useTranslation(meta.id);
|
|
48
|
+
return /* @__PURE__ */ React.createElement(Toast.Root, {
|
|
49
|
+
"data-testid": toast.id,
|
|
50
|
+
defaultOpen: true,
|
|
51
|
+
duration: toast.duration,
|
|
52
|
+
onOpenChange: (open) => {
|
|
53
|
+
if (!open) {
|
|
54
|
+
onDismiss(toast.id);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}, /* @__PURE__ */ React.createElement(Toast.Body, null, /* @__PURE__ */ React.createElement(Toast.Title, {
|
|
58
|
+
classNames: "items-center"
|
|
59
|
+
}, toast.icon && /* @__PURE__ */ React.createElement(Icon, {
|
|
60
|
+
icon: toast.icon,
|
|
61
|
+
classNames: "inline mr-1"
|
|
62
|
+
}), toast.title && /* @__PURE__ */ React.createElement("span", null, toLocalizedString(toast.title, t))), toast.description && /* @__PURE__ */ React.createElement(Toast.Description, null, toLocalizedString(toast.description, t))), /* @__PURE__ */ React.createElement(Toast.Actions, null, toast.onAction && toast.actionAlt && toast.actionLabel && /* @__PURE__ */ React.createElement(Toast.Action, {
|
|
63
|
+
altText: toLocalizedString(toast.actionAlt, t),
|
|
64
|
+
asChild: true
|
|
65
|
+
}, /* @__PURE__ */ React.createElement(Button, {
|
|
66
|
+
variant: "primary",
|
|
67
|
+
onClick: () => toast.onAction?.()
|
|
68
|
+
}, toLocalizedString(toast.actionLabel, t))), toast.closeLabel && /* @__PURE__ */ React.createElement(Toast.Close, {
|
|
69
|
+
asChild: true
|
|
70
|
+
}, /* @__PURE__ */ React.createElement(Button, null, toLocalizedString(toast.closeLabel, t)))));
|
|
71
|
+
};
|
|
47
72
|
var Layout = ({ children }) => {
|
|
48
73
|
const { t } = useTranslation(meta.id);
|
|
49
74
|
const trigger = useRef(null);
|
|
@@ -102,9 +127,17 @@ var Layout = ({ children }) => {
|
|
|
102
127
|
}, [
|
|
103
128
|
handleClose
|
|
104
129
|
]);
|
|
130
|
+
const handleDismissToast = useCallback((id) => {
|
|
131
|
+
updateState({
|
|
132
|
+
toasts: layout.toasts.filter((toast) => toast.id !== id)
|
|
133
|
+
});
|
|
134
|
+
}, [
|
|
135
|
+
updateState,
|
|
136
|
+
layout.toasts
|
|
137
|
+
]);
|
|
105
138
|
const DialogRoot = layout.dialogType === "alert" ? AlertDialog.Root : Dialog.Root;
|
|
106
139
|
const DialogOverlay = layout.dialogType === "alert" ? AlertDialog.Overlay : Dialog.Overlay;
|
|
107
|
-
return /* @__PURE__ */ React.createElement("div", {
|
|
140
|
+
return /* @__PURE__ */ React.createElement(Toast.Provider, null, /* @__PURE__ */ React.createElement("div", {
|
|
108
141
|
role: "none",
|
|
109
142
|
className: "fixed inset-0 flex overflow-hidden"
|
|
110
143
|
}, /* @__PURE__ */ React.createElement(Mosaic.Root, null, /* @__PURE__ */ React.createElement(Popover.Root, {
|
|
@@ -158,7 +191,11 @@ var Layout = ({ children }) => {
|
|
|
158
191
|
role: "popover",
|
|
159
192
|
data: layout.popoverContent,
|
|
160
193
|
limit: 1
|
|
161
|
-
})), /* @__PURE__ */ React.createElement(Popover.Arrow, null))))))
|
|
194
|
+
})), /* @__PURE__ */ React.createElement(Popover.Arrow, null))))), layout.toasts.map((toast) => /* @__PURE__ */ React.createElement(StoryToast, {
|
|
195
|
+
key: toast.id,
|
|
196
|
+
toast,
|
|
197
|
+
onDismiss: handleDismissToast
|
|
198
|
+
})), /* @__PURE__ */ React.createElement(Toast.Viewport, null)));
|
|
162
199
|
};
|
|
163
200
|
var ErrorFallback = ({ error }) => {
|
|
164
201
|
const { t } = useTranslation(meta.id);
|
|
@@ -173,8 +210,8 @@ var ErrorFallback = ({ error }) => {
|
|
|
173
210
|
};
|
|
174
211
|
|
|
175
212
|
// src/StorybookPlugin.ts
|
|
176
|
-
var StorybookPlugin = Plugin.define(meta).pipe(AppPlugin.
|
|
177
|
-
activate:
|
|
213
|
+
var StorybookPlugin = Plugin.define(meta).pipe(AppPlugin.addOperationHandlerModule({
|
|
214
|
+
activate: OperationHandler
|
|
178
215
|
}), AppPlugin.addReactContextModule({
|
|
179
216
|
activate: () => Effect.succeed(Capability3.contributes(Capabilities.ReactContext, {
|
|
180
217
|
id: "storybook-layout",
|
|
@@ -191,14 +228,7 @@ var StorybookPlugin = Plugin.define(meta).pipe(AppPlugin.addOperationResolverMod
|
|
|
191
228
|
})
|
|
192
229
|
})), Plugin.make);
|
|
193
230
|
export {
|
|
194
|
-
AttentionPlugin,
|
|
195
|
-
ClientPlugin,
|
|
196
|
-
GraphPlugin,
|
|
197
|
-
OperationPlugin,
|
|
198
|
-
RuntimePlugin,
|
|
199
|
-
SettingsPlugin,
|
|
200
231
|
StorybookPlugin,
|
|
201
|
-
ThemePlugin,
|
|
202
232
|
corePlugins,
|
|
203
233
|
meta
|
|
204
234
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../../../src/core.ts", "../../../src/StorybookPlugin.ts", "../../../src/capabilities/operation-
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { OperationPlugin, type Plugin, RuntimePlugin } from '@dxos/app-framework';\nimport { AttentionPlugin } from '@dxos/plugin-attention';\nimport { ClientPlugin } from '@dxos/plugin-client';\nimport { GraphPlugin } from '@dxos/plugin-graph';\nimport { SettingsPlugin } from '@dxos/plugin-settings';\nimport { ThemePlugin } from '@dxos/plugin-theme';\nimport { defaultTx } from '@dxos/ui-theme';\n\n// TODO(burdon): Remove this.\n// Re-export common framework plugins.\nexport { AttentionPlugin, ClientPlugin, GraphPlugin, OperationPlugin, RuntimePlugin, SettingsPlugin, ThemePlugin };\n\n/**\n * Core plugins for testing/storybook environments.\n * NOTE: Does not include SpacePlugin to avoid circular dependencies.\n * Import SpacePlugin directly in your stories if needed.\n */\nexport const corePlugins = (): Plugin.Plugin[] => [\n AttentionPlugin(),\n GraphPlugin(),\n OperationPlugin(),\n RuntimePlugin(),\n SettingsPlugin(),\n ThemePlugin({ tx: defaultTx }),\n];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { ActivationEvents, Capabilities, Capability, Plugin } from '@dxos/app-framework';\nimport { AppActivationEvents, AppPlugin } from '@dxos/app-toolkit';\n\nimport { OperationResolver, State } from './capabilities';\nimport { Layout } from './components';\nimport { meta } from './meta';\nimport { type LayoutStateProps } from './types';\n\nexport type StorybookPluginOptions = {\n initialState?: Partial<LayoutStateProps>;\n};\n\nexport const StorybookPlugin = Plugin.define<StorybookPluginOptions>(meta).pipe(\n AppPlugin.addOperationResolverModule({\n activate: OperationResolver,\n }),\n AppPlugin.addReactContextModule({\n activate: () =>\n Effect.succeed(\n Capability.contributes(Capabilities.ReactContext, {\n id: 'storybook-layout',\n context: Layout,\n }),\n ),\n }),\n Plugin.addModule(({ initialState }) => ({\n id: Capability.getModuleTag(State),\n activatesOn: ActivationEvents.Startup,\n activatesAfter: [AppActivationEvents.LayoutReady],\n activate: () => State({ initialState }),\n })),\n Plugin.make,\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\n\nexport const OperationResolver = Capability.lazy('OperationResolver', () => import('./operation-resolver'));\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\n\nexport const State = Capability.lazy('State', () => import('./state'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { RegistryContext, useAtomValue } from '@effect-atom/atom-react';\nimport React, { type PropsWithChildren, useCallback, useContext, useEffect, useRef, useState } from 'react';\n\nimport { Surface, useCapability } from '@dxos/app-framework/ui';\nimport {\n AlertDialog,\n Dialog,\n Main,\n Popover,\n type PopoverContentInteractOutsideEvent,\n toLocalizedString,\n useTranslation,\n} from '@dxos/react-ui';\nimport { Card } from '@dxos/react-ui';\nimport { Mosaic } from '@dxos/react-ui-mosaic';\nimport { descriptionMessage, mx } from '@dxos/ui-theme';\n\nimport { meta } from '../../meta';\nimport { LayoutState, type LayoutStateProps } from '../../types';\n\nconst debounce_delay = 100;\n\n// TODO(wittjosiah): Support dialogs, tooltips, maybe toast.\nexport const Layout = ({ children }: PropsWithChildren<{}>) => {\n const { t } = useTranslation(meta.id);\n const trigger = useRef<HTMLButtonElement | null>(null);\n const registry = useContext(RegistryContext);\n const stateAtom = useCapability(LayoutState);\n const layout = useAtomValue(stateAtom);\n const [iter, setIter] = useState(0);\n const [open, setOpen] = useState(false);\n const debounceRef = useRef<NodeJS.Timeout | null>(null);\n\n const updateState = useCallback(\n (updates: Partial<LayoutStateProps>) => {\n const current = registry.get(stateAtom);\n registry.set(stateAtom, { ...current, ...updates });\n },\n [registry, stateAtom],\n );\n\n useEffect(() => {\n setOpen(false);\n if (debounceRef.current) {\n clearTimeout(debounceRef.current);\n debounceRef.current = null;\n }\n trigger.current = layout.popoverAnchor ?? null;\n setIter((iter) => iter + 1);\n if (layout.popoverOpen) {\n debounceRef.current = setTimeout(() => setOpen(true), debounce_delay);\n }\n }, [layout.popoverAnchor, layout.popoverContent, layout.popoverOpen]);\n\n const handleClose = useCallback(() => {\n setOpen(false);\n updateState({\n popoverOpen: false,\n popoverAnchor: undefined,\n popoverAnchorId: undefined,\n popoverSide: undefined,\n });\n }, [updateState]);\n\n const handleInteractOutside = useCallback(\n (event: KeyboardEvent | PopoverContentInteractOutsideEvent) => {\n if (\n // TODO(thure): CodeMirror should not focus itself when it updates.\n event.type === 'dismissableLayer.focusOutside' &&\n (event.currentTarget as HTMLElement | undefined)?.classList.contains('cm-content')\n ) {\n event.preventDefault();\n } else {\n handleClose();\n }\n },\n [handleClose],\n );\n\n const DialogRoot = layout.dialogType === 'alert' ? AlertDialog.Root : Dialog.Root;\n const DialogOverlay = layout.dialogType === 'alert' ? AlertDialog.Overlay : Dialog.Overlay;\n\n return (\n <div role='none' className='fixed inset-0 flex overflow-hidden'>\n <Mosaic.Root>\n <Popover.Root open={open}>\n <Main.Root\n navigationSidebarState={layout.sidebarState}\n complementarySidebarState={layout.complementarySidebarState}\n onNavigationSidebarStateChange={(next) => updateState({ sidebarState: next })}\n onComplementarySidebarStateChange={(next) => updateState({ complementarySidebarState: next })}\n >\n {children}\n </Main.Root>\n\n <DialogRoot\n modal={layout.dialogBlockAlign !== 'end'}\n open={layout.dialogOpen}\n onOpenChange={(nextOpen) => updateState({ dialogOpen: nextOpen })}\n >\n {layout.dialogBlockAlign === 'end' ? (\n <Surface.Surface\n role='dialog'\n data={layout.dialogContent}\n limit={1}\n fallback={ErrorFallback}\n placeholder={<div />}\n />\n ) : (\n <DialogOverlay\n blockAlign={layout.dialogBlockAlign}\n classNames={layout.dialogOverlayClasses}\n style={layout.dialogOverlayStyle}\n >\n <Surface.Surface role='dialog' data={layout.dialogContent} limit={1} fallback={ErrorFallback} />\n </DialogOverlay>\n )}\n </DialogRoot>\n\n <Popover.VirtualTrigger key={iter} virtualRef={trigger} />\n <Popover.Portal>\n <Popover.Content\n side={layout.popoverSide}\n onInteractOutside={handleInteractOutside}\n onEscapeKeyDown={handleInteractOutside}\n sticky='always'\n hideWhenDetached\n >\n <Popover.Viewport>\n {layout.popoverKind === 'card' && (\n <Card.Root>\n <Card.Toolbar>\n {/* TODO(wittjosiah): Cleaner way to handle no drag handle in toolbar? */}\n <span />\n {layout.popoverTitle ? (\n <Card.Title>{toLocalizedString(layout.popoverTitle, t)}</Card.Title>\n ) : (\n <span />\n )}\n <Card.CloseIconButton onClick={handleClose} />\n </Card.Toolbar>\n <Surface.Surface role='card--content' data={layout.popoverContent} limit={1} />\n </Card.Root>\n )}\n {layout.popoverKind === 'base' && (\n <Surface.Surface role='popover' data={layout.popoverContent} limit={1} />\n )}\n </Popover.Viewport>\n <Popover.Arrow />\n </Popover.Content>\n </Popover.Portal>\n </Popover.Root>\n </Mosaic.Root>\n </div>\n );\n};\n\nexport const ErrorFallback = ({ error }: { error?: Error }) => {\n const { t } = useTranslation(meta.id);\n const errorString = error?.toString() ?? '';\n return (\n <div\n role='alert'\n data-testid='error-boundary-fallback'\n className={mx('overflow-auto p-8 dx-attention-surface grid place-items-center')}\n >\n <p className={mx(descriptionMessage, 'break-words rounded-md p-8', errorString.length < 256 && 'text-lg')}>\n {error ? errorString : t('error fallback message')}\n </p>\n </div>\n );\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;AAIA,SAASA,iBAA8BC,qBAAqB;AAC5D,SAASC,uBAAuB;AAChC,SAASC,
|
|
6
|
-
"names": ["OperationPlugin", "RuntimePlugin", "AttentionPlugin", "
|
|
3
|
+
"sources": ["../../../src/core.ts", "../../../src/StorybookPlugin.ts", "../../../src/capabilities/operation-handler/index.ts", "../../../src/capabilities/state/index.ts", "../../../src/components/Layout/Layout.tsx"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { OperationPlugin, type Plugin, RuntimePlugin } from '@dxos/app-framework';\nimport { AttentionPlugin } from '@dxos/plugin-attention';\nimport { GraphPlugin } from '@dxos/plugin-graph';\nimport { SettingsPlugin } from '@dxos/plugin-settings';\nimport { ThemePlugin } from '@dxos/plugin-theme';\nimport { defaultTx } from '@dxos/ui-theme';\n\n/**\n * Core plugins for testing/storybook environments.\n * NOTE: Does not include SpacePlugin to avoid circular dependencies.\n * Import SpacePlugin directly in your stories if needed.\n */\nexport const corePlugins = (): Plugin.Plugin[] => [\n AttentionPlugin(),\n GraphPlugin(),\n OperationPlugin(),\n RuntimePlugin(),\n SettingsPlugin(),\n ThemePlugin({ tx: defaultTx }),\n];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { ActivationEvents, Capabilities, Capability, Plugin } from '@dxos/app-framework';\nimport { AppActivationEvents, AppPlugin } from '@dxos/app-toolkit';\n\nimport { OperationHandler, State } from './capabilities';\nimport { Layout } from './components';\nimport { meta } from './meta';\nimport { type LayoutStateProps } from './types';\n\nexport type StorybookPluginOptions = {\n initialState?: Partial<LayoutStateProps>;\n};\n\nexport const StorybookPlugin = Plugin.define<StorybookPluginOptions>(meta).pipe(\n AppPlugin.addOperationHandlerModule({\n activate: OperationHandler,\n }),\n AppPlugin.addReactContextModule({\n activate: () =>\n Effect.succeed(\n Capability.contributes(Capabilities.ReactContext, {\n id: 'storybook-layout',\n context: Layout,\n }),\n ),\n }),\n Plugin.addModule(({ initialState }) => ({\n id: Capability.getModuleTag(State),\n activatesOn: ActivationEvents.Startup,\n activatesAfter: [AppActivationEvents.LayoutReady],\n activate: () => State({ initialState }),\n })),\n Plugin.make,\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\nimport { OperationHandlerSet } from '@dxos/operation';\n\nexport const OperationHandler = Capability.lazy<OperationHandlerSet.OperationHandlerSet>(\n 'OperationHandler',\n () => import('./operation-handler'),\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { Capability } from '@dxos/app-framework';\n\nexport const State = Capability.lazy('State', () => import('./state'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { RegistryContext, useAtomValue } from '@effect-atom/atom-react';\nimport React, { type PropsWithChildren, useCallback, useContext, useEffect, useRef, useState } from 'react';\n\nimport { Surface, useCapability } from '@dxos/app-framework/ui';\nimport { type LayoutOperation } from '@dxos/app-toolkit';\nimport {\n AlertDialog,\n Button,\n Dialog,\n Icon,\n Main,\n Popover,\n type PopoverContentInteractOutsideEvent,\n Toast,\n toLocalizedString,\n useTranslation,\n} from '@dxos/react-ui';\nimport { Card } from '@dxos/react-ui';\nimport { Mosaic } from '@dxos/react-ui-mosaic';\nimport { descriptionMessage, mx } from '@dxos/ui-theme';\n\nimport { meta } from '../../meta';\nimport { LayoutState, type LayoutStateProps } from '../../types';\n\nconst debounce_delay = 100;\n\nconst StoryToast = ({ toast, onDismiss }: { toast: LayoutOperation.Toast; onDismiss: (id: string) => void }) => {\n const { t } = useTranslation(meta.id);\n return (\n <Toast.Root\n data-testid={toast.id}\n defaultOpen\n duration={toast.duration}\n onOpenChange={(open) => {\n if (!open) {\n onDismiss(toast.id);\n }\n }}\n >\n <Toast.Body>\n <Toast.Title classNames='items-center'>\n {toast.icon && <Icon icon={toast.icon} classNames='inline mr-1' />}\n {toast.title && <span>{toLocalizedString(toast.title, t)}</span>}\n </Toast.Title>\n {toast.description && <Toast.Description>{toLocalizedString(toast.description, t)}</Toast.Description>}\n </Toast.Body>\n <Toast.Actions>\n {toast.onAction && toast.actionAlt && toast.actionLabel && (\n <Toast.Action altText={toLocalizedString(toast.actionAlt, t)} asChild>\n <Button variant='primary' onClick={() => toast.onAction?.()}>\n {toLocalizedString(toast.actionLabel, t)}\n </Button>\n </Toast.Action>\n )}\n {toast.closeLabel && (\n <Toast.Close asChild>\n <Button>{toLocalizedString(toast.closeLabel, t)}</Button>\n </Toast.Close>\n )}\n </Toast.Actions>\n </Toast.Root>\n );\n};\n\nexport const Layout = ({ children }: PropsWithChildren<{}>) => {\n const { t } = useTranslation(meta.id);\n const trigger = useRef<HTMLButtonElement | null>(null);\n const registry = useContext(RegistryContext);\n const stateAtom = useCapability(LayoutState);\n const layout = useAtomValue(stateAtom);\n const [iter, setIter] = useState(0);\n const [open, setOpen] = useState(false);\n const debounceRef = useRef<NodeJS.Timeout | null>(null);\n\n const updateState = useCallback(\n (updates: Partial<LayoutStateProps>) => {\n const current = registry.get(stateAtom);\n registry.set(stateAtom, { ...current, ...updates });\n },\n [registry, stateAtom],\n );\n\n useEffect(() => {\n setOpen(false);\n if (debounceRef.current) {\n clearTimeout(debounceRef.current);\n debounceRef.current = null;\n }\n trigger.current = layout.popoverAnchor ?? null;\n setIter((iter) => iter + 1);\n if (layout.popoverOpen) {\n debounceRef.current = setTimeout(() => setOpen(true), debounce_delay);\n }\n }, [layout.popoverAnchor, layout.popoverContent, layout.popoverOpen]);\n\n const handleClose = useCallback(() => {\n setOpen(false);\n updateState({\n popoverOpen: false,\n popoverAnchor: undefined,\n popoverAnchorId: undefined,\n popoverSide: undefined,\n });\n }, [updateState]);\n\n const handleInteractOutside = useCallback(\n (event: KeyboardEvent | PopoverContentInteractOutsideEvent) => {\n if (\n // TODO(thure): CodeMirror should not focus itself when it updates.\n event.type === 'dismissableLayer.focusOutside' &&\n (event.currentTarget as HTMLElement | undefined)?.classList.contains('cm-content')\n ) {\n event.preventDefault();\n } else {\n handleClose();\n }\n },\n [handleClose],\n );\n\n const handleDismissToast = useCallback(\n (id: string) => {\n updateState({ toasts: layout.toasts.filter((toast) => toast.id !== id) });\n },\n [updateState, layout.toasts],\n );\n\n const DialogRoot = layout.dialogType === 'alert' ? AlertDialog.Root : Dialog.Root;\n const DialogOverlay = layout.dialogType === 'alert' ? AlertDialog.Overlay : Dialog.Overlay;\n\n return (\n <Toast.Provider>\n <div role='none' className='fixed inset-0 flex overflow-hidden'>\n <Mosaic.Root>\n <Popover.Root open={open}>\n <Main.Root\n navigationSidebarState={layout.sidebarState}\n complementarySidebarState={layout.complementarySidebarState}\n onNavigationSidebarStateChange={(next) => updateState({ sidebarState: next })}\n onComplementarySidebarStateChange={(next) => updateState({ complementarySidebarState: next })}\n >\n {children}\n </Main.Root>\n\n <DialogRoot\n modal={layout.dialogBlockAlign !== 'end'}\n open={layout.dialogOpen}\n onOpenChange={(nextOpen) => updateState({ dialogOpen: nextOpen })}\n >\n {layout.dialogBlockAlign === 'end' ? (\n <Surface.Surface\n role='dialog'\n data={layout.dialogContent}\n limit={1}\n fallback={ErrorFallback}\n placeholder={<div />}\n />\n ) : (\n <DialogOverlay\n blockAlign={layout.dialogBlockAlign}\n classNames={layout.dialogOverlayClasses}\n style={layout.dialogOverlayStyle}\n >\n <Surface.Surface role='dialog' data={layout.dialogContent} limit={1} fallback={ErrorFallback} />\n </DialogOverlay>\n )}\n </DialogRoot>\n\n <Popover.VirtualTrigger key={iter} virtualRef={trigger} />\n <Popover.Portal>\n <Popover.Content\n side={layout.popoverSide}\n onInteractOutside={handleInteractOutside}\n onEscapeKeyDown={handleInteractOutside}\n sticky='always'\n hideWhenDetached\n >\n <Popover.Viewport>\n {layout.popoverKind === 'card' && (\n <Card.Root>\n <Card.Toolbar>\n {/* TODO(wittjosiah): Cleaner way to handle no drag handle in toolbar? */}\n <span />\n {layout.popoverTitle ? (\n <Card.Title>{toLocalizedString(layout.popoverTitle, t)}</Card.Title>\n ) : (\n <span />\n )}\n <Card.CloseIconButton onClick={handleClose} />\n </Card.Toolbar>\n <Surface.Surface role='card--content' data={layout.popoverContent} limit={1} />\n </Card.Root>\n )}\n {layout.popoverKind === 'base' && (\n <Surface.Surface role='popover' data={layout.popoverContent} limit={1} />\n )}\n </Popover.Viewport>\n <Popover.Arrow />\n </Popover.Content>\n </Popover.Portal>\n </Popover.Root>\n </Mosaic.Root>\n {layout.toasts.map((toast) => (\n <StoryToast key={toast.id} toast={toast} onDismiss={handleDismissToast} />\n ))}\n <Toast.Viewport />\n </div>\n </Toast.Provider>\n );\n};\n\nexport const ErrorFallback = ({ error }: { error?: Error }) => {\n const { t } = useTranslation(meta.id);\n const errorString = error?.toString() ?? '';\n return (\n <div\n role='alert'\n data-testid='error-boundary-fallback'\n className={mx('overflow-auto p-8 dx-attention-surface grid place-items-center')}\n >\n <p className={mx(descriptionMessage, 'break-words rounded-md p-8', errorString.length < 256 && 'text-lg')}>\n {error ? errorString : t('error fallback message')}\n </p>\n </div>\n );\n};\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
|
+
"names": ["OperationPlugin", "RuntimePlugin", "AttentionPlugin", "GraphPlugin", "SettingsPlugin", "ThemePlugin", "defaultTx", "corePlugins", "AttentionPlugin", "GraphPlugin", "OperationPlugin", "RuntimePlugin", "SettingsPlugin", "ThemePlugin", "tx", "defaultTx", "Effect", "ActivationEvents", "Capabilities", "Capability", "Plugin", "AppActivationEvents", "AppPlugin", "Capability", "OperationHandler", "Capability", "lazy", "Capability", "State", "Capability", "lazy", "RegistryContext", "useAtomValue", "React", "useCallback", "useContext", "useEffect", "useRef", "useState", "Surface", "useCapability", "AlertDialog", "Button", "Dialog", "Icon", "Main", "Popover", "Toast", "toLocalizedString", "useTranslation", "Card", "Mosaic", "descriptionMessage", "mx", "debounce_delay", "StoryToast", "toast", "onDismiss", "t", "useTranslation", "meta", "id", "Toast", "Root", "data-testid", "defaultOpen", "duration", "onOpenChange", "open", "Body", "Title", "classNames", "icon", "Icon", "title", "span", "toLocalizedString", "description", "Description", "Actions", "onAction", "actionAlt", "actionLabel", "Action", "altText", "asChild", "Button", "variant", "onClick", "closeLabel", "Close", "Layout", "children", "trigger", "useRef", "registry", "useContext", "RegistryContext", "stateAtom", "useCapability", "LayoutState", "layout", "useAtomValue", "iter", "setIter", "useState", "setOpen", "debounceRef", "updateState", "useCallback", "updates", "current", "get", "set", "useEffect", "clearTimeout", "popoverAnchor", "popoverOpen", "setTimeout", "popoverContent", "handleClose", "undefined", "popoverAnchorId", "popoverSide", "handleInteractOutside", "event", "type", "currentTarget", "classList", "contains", "preventDefault", "handleDismissToast", "toasts", "filter", "DialogRoot", "dialogType", "AlertDialog", "Dialog", "DialogOverlay", "Overlay", "Provider", "div", "role", "className", "Mosaic", "Popover", "Main", "navigationSidebarState", "sidebarState", "complementarySidebarState", "onNavigationSidebarStateChange", "next", "onComplementarySidebarStateChange", "modal", "dialogBlockAlign", "dialogOpen", "nextOpen", "Surface", "data", "dialogContent", "limit", "fallback", "ErrorFallback", "placeholder", "blockAlign", "dialogOverlayClasses", "style", "dialogOverlayStyle", "VirtualTrigger", "key", "virtualRef", "Portal", "Content", "side", "onInteractOutside", "onEscapeKeyDown", "sticky", "hideWhenDetached", "Viewport", "popoverKind", "Card", "Toolbar", "popoverTitle", "CloseIconButton", "Arrow", "map", "error", "errorString", "toString", "mx", "p", "descriptionMessage", "length", "StorybookPlugin", "Plugin", "define", "meta", "pipe", "AppPlugin", "addOperationHandlerModule", "activate", "OperationHandler", "addReactContextModule", "succeed", "Capability", "contributes", "Capabilities", "ReactContext", "id", "context", "Layout", "addModule", "initialState", "getModuleTag", "State", "activatesOn", "ActivationEvents", "Startup", "activatesAfter", "AppActivationEvents", "LayoutReady", "make"]
|
|
7
7
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"inputs":{"src/core.ts":{"bytes":3429,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/meta.ts":{"bytes":1661,"imports":[{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"src/types/capabilities.ts":{"bytes":2133,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/types/index.ts":{"bytes":476,"imports":[{"path":"src/types/capabilities.ts","kind":"import-statement","original":"./capabilities"}],"format":"esm"},"src/capabilities/operation-resolver/operation-resolver.ts":{"bytes":13577,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/capabilities/operation-resolver/index.ts":{"bytes":963,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/operation-resolver/operation-resolver.ts","kind":"dynamic-import","original":"./operation-resolver"}],"format":"esm"},"src/capabilities/state/state.tsx":{"bytes":4774,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/capabilities/state/index.ts":{"bytes":837,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/state/state.tsx","kind":"dynamic-import","original":"./state"}],"format":"esm"},"src/capabilities/index.ts":{"bytes":578,"imports":[{"path":"src/capabilities/operation-resolver/index.ts","kind":"import-statement","original":"./operation-resolver"},{"path":"src/capabilities/state/index.ts","kind":"import-statement","original":"./state"}],"format":"esm"},"src/components/Layout/Layout.tsx":{"bytes":21250,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework/ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../../meta"},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/components/Layout/index.ts":{"bytes":474,"imports":[{"path":"src/components/Layout/Layout.tsx","kind":"import-statement","original":"./Layout"}],"format":"esm"},"src/components/index.ts":{"bytes":467,"imports":[{"path":"src/components/Layout/index.ts","kind":"import-statement","original":"./Layout"}],"format":"esm"},"src/StorybookPlugin.ts":{"bytes":4319,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"src/index.ts":{"bytes":637,"imports":[{"path":"src/core.ts","kind":"import-statement","original":"./core"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/StorybookPlugin.ts","kind":"import-statement","original":"./StorybookPlugin"}],"format":"esm"}},"outputs":{"dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":16087},"dist/lib/browser/index.mjs":{"imports":[{"path":"dist/lib/browser/chunk-NWOKPVNQ.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-client","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/operation-resolver-SR4GZ7Q5.mjs","kind":"dynamic-import"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/state-TCYYH5JN.mjs","kind":"dynamic-import"},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework/ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"exports":["AttentionPlugin","ClientPlugin","GraphPlugin","OperationPlugin","RuntimePlugin","SettingsPlugin","StorybookPlugin","ThemePlugin","corePlugins","meta"],"entryPoint":"src/index.ts","inputs":{"src/core.ts":{"bytesInOutput":546},"src/index.ts":{"bytesInOutput":0},"src/StorybookPlugin.ts":{"bytesInOutput":762},"src/capabilities/operation-resolver/index.ts":{"bytesInOutput":163},"src/capabilities/index.ts":{"bytesInOutput":0},"src/capabilities/state/index.ts":{"bytesInOutput":142},"src/components/Layout/Layout.tsx":{"bytesInOutput":5528},"src/components/Layout/index.ts":{"bytesInOutput":0},"src/components/index.ts":{"bytesInOutput":0}},"bytes":7602},"dist/lib/browser/operation-resolver-SR4GZ7Q5.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":6707},"dist/lib/browser/operation-resolver-SR4GZ7Q5.mjs":{"imports":[{"path":"dist/lib/browser/chunk-NWOKPVNQ.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/operation-resolver/operation-resolver.ts","inputs":{"src/capabilities/operation-resolver/operation-resolver.ts":{"bytesInOutput":3417}},"bytes":3642},"dist/lib/browser/state-TCYYH5JN.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2536},"dist/lib/browser/state-TCYYH5JN.mjs":{"imports":[{"path":"dist/lib/browser/chunk-NWOKPVNQ.mjs","kind":"import-statement"},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/state/state.tsx","inputs":{"src/capabilities/state/state.tsx":{"bytesInOutput":1058}},"bytes":1232},"dist/lib/browser/chunk-NWOKPVNQ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2020},"dist/lib/browser/chunk-NWOKPVNQ.mjs":{"imports":[{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["LayoutState","meta"],"inputs":{"src/meta.ts":{"bytesInOutput":395},"src/types/capabilities.ts":{"bytesInOutput":105},"src/types/index.ts":{"bytesInOutput":0}},"bytes":624}}}
|
|
1
|
+
{"inputs":{"src/core.ts":{"bytes":2660,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"format":"esm"},"src/meta.ts":{"bytes":1661,"imports":[{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"src/types/capabilities.ts":{"bytes":2261,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/types/index.ts":{"bytes":476,"imports":[{"path":"src/types/capabilities.ts","kind":"import-statement","original":"./capabilities"}],"format":"esm"},"src/operations/update-state.ts":{"bytes":2266,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"src/operations/add-toast.ts":{"bytes":2156,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/update-state.ts","kind":"import-statement","original":"./update-state"}],"format":"esm"},"src/operations/close.ts":{"bytes":1412,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"format":"esm"},"src/operations/open.ts":{"bytes":1402,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"format":"esm"},"src/operations/scroll-into-view.ts":{"bytes":1480,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"format":"esm"},"src/operations/set-layout-mode.ts":{"bytes":1474,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"format":"esm"},"src/operations/switch-workspace.ts":{"bytes":2035,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/update-state.ts","kind":"import-statement","original":"./update-state"}],"format":"esm"},"src/operations/update-complementary.ts":{"bytes":2748,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/update-state.ts","kind":"import-statement","original":"./update-state"}],"format":"esm"},"src/operations/update-dialog.ts":{"bytes":3378,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/update-state.ts","kind":"import-statement","original":"./update-state"}],"format":"esm"},"src/operations/update-popover.ts":{"bytes":4904,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/update-state.ts","kind":"import-statement","original":"./update-state"}],"format":"esm"},"src/operations/update-sidebar.ts":{"bytes":2549,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/update-state.ts","kind":"import-statement","original":"./update-state"}],"format":"esm"},"src/operations/index.ts":{"bytes":1914,"imports":[{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"src/operations/add-toast.ts","kind":"dynamic-import","original":"./add-toast"},{"path":"src/operations/close.ts","kind":"dynamic-import","original":"./close"},{"path":"src/operations/open.ts","kind":"dynamic-import","original":"./open"},{"path":"src/operations/scroll-into-view.ts","kind":"dynamic-import","original":"./scroll-into-view"},{"path":"src/operations/set-layout-mode.ts","kind":"dynamic-import","original":"./set-layout-mode"},{"path":"src/operations/switch-workspace.ts","kind":"dynamic-import","original":"./switch-workspace"},{"path":"src/operations/update-complementary.ts","kind":"dynamic-import","original":"./update-complementary"},{"path":"src/operations/update-dialog.ts","kind":"dynamic-import","original":"./update-dialog"},{"path":"src/operations/update-popover.ts","kind":"dynamic-import","original":"./update-popover"},{"path":"src/operations/update-sidebar.ts","kind":"dynamic-import","original":"./update-sidebar"}],"format":"esm"},"src/capabilities/operation-handler/operation-handler.ts":{"bytes":1813,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/operations/index.ts","kind":"import-statement","original":"../../operations"}],"format":"esm"},"src/capabilities/operation-handler/index.ts":{"bytes":1095,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/operation-handler/operation-handler.ts","kind":"dynamic-import","original":"./operation-handler"}],"format":"esm"},"src/capabilities/state/state.tsx":{"bytes":4850,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/capabilities/state/index.ts":{"bytes":837,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/state/state.tsx","kind":"dynamic-import","original":"./state"}],"format":"esm"},"src/capabilities/index.ts":{"bytes":577,"imports":[{"path":"src/capabilities/operation-handler/index.ts","kind":"import-statement","original":"./operation-handler"},{"path":"src/capabilities/state/index.ts","kind":"import-statement","original":"./state"}],"format":"esm"},"src/components/Layout/Layout.tsx":{"bytes":27830,"imports":[{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework/ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../../meta"},{"path":"src/types/index.ts","kind":"import-statement","original":"../../types"}],"format":"esm"},"src/components/Layout/index.ts":{"bytes":474,"imports":[{"path":"src/components/Layout/Layout.tsx","kind":"import-statement","original":"./Layout"}],"format":"esm"},"src/components/index.ts":{"bytes":467,"imports":[{"path":"src/components/Layout/index.ts","kind":"import-statement","original":"./Layout"}],"format":"esm"},"src/StorybookPlugin.ts":{"bytes":4308,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"src/index.ts":{"bytes":637,"imports":[{"path":"src/core.ts","kind":"import-statement","original":"./core"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/StorybookPlugin.ts","kind":"import-statement","original":"./StorybookPlugin"}],"format":"esm"}},"outputs":{"dist/lib/browser/update-dialog-W7QOCQ2N.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1776},"dist/lib/browser/update-dialog-W7QOCQ2N.mjs":{"imports":[{"path":"dist/lib/browser/chunk-M4TYMLOE.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/update-dialog.ts","inputs":{"src/operations/update-dialog.ts":{"bytesInOutput":681}},"bytes":901},"dist/lib/browser/update-popover-UELZDJW6.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2541},"dist/lib/browser/update-popover-UELZDJW6.mjs":{"imports":[{"path":"dist/lib/browser/chunk-M4TYMLOE.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/update-popover.ts","inputs":{"src/operations/update-popover.ts":{"bytesInOutput":1073}},"bytes":1296},"dist/lib/browser/update-sidebar-RJZTREDE.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1343},"dist/lib/browser/update-sidebar-RJZTREDE.mjs":{"imports":[{"path":"dist/lib/browser/chunk-M4TYMLOE.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/update-sidebar.ts","inputs":{"src/operations/update-sidebar.ts":{"bytesInOutput":496}},"bytes":719},"dist/lib/browser/operation-handler-DUWMXELV.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1880},"dist/lib/browser/operation-handler-DUWMXELV.mjs":{"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true},{"path":"dist/lib/browser/add-toast-M6ZVP2PQ.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/close-M6YHTWUZ.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/open-ND4QPYWD.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/scroll-into-view-UAINWR6E.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/set-layout-mode-E6SJ6ATN.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/switch-workspace-RPYF6M6L.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/update-complementary-HNS4FIWF.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/update-dialog-W7QOCQ2N.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/update-popover-UELZDJW6.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/update-sidebar-RJZTREDE.mjs","kind":"dynamic-import"}],"exports":["default"],"entryPoint":"src/capabilities/operation-handler/operation-handler.ts","inputs":{"src/capabilities/operation-handler/operation-handler.ts":{"bytesInOutput":289},"src/operations/index.ts":{"bytesInOutput":570}},"bytes":1113},"dist/lib/browser/state-MRRN7LZE.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2577},"dist/lib/browser/state-MRRN7LZE.mjs":{"imports":[{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/state/state.tsx","inputs":{"src/capabilities/state/state.tsx":{"bytesInOutput":1072}},"bytes":1246},"dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":19531},"dist/lib/browser/index.mjs":{"imports":[{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-attention","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/plugin-theme","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/operation-handler-DUWMXELV.mjs","kind":"dynamic-import"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/state-MRRN7LZE.mjs","kind":"dynamic-import"},{"path":"@effect-atom/atom-react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework/ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/ui-theme","kind":"import-statement","external":true}],"exports":["StorybookPlugin","corePlugins","meta"],"entryPoint":"src/index.ts","inputs":{"src/core.ts":{"bytesInOutput":494},"src/index.ts":{"bytesInOutput":0},"src/StorybookPlugin.ts":{"bytesInOutput":760},"src/capabilities/operation-handler/index.ts":{"bytesInOutput":160},"src/capabilities/index.ts":{"bytesInOutput":0},"src/capabilities/state/index.ts":{"bytesInOutput":142},"src/components/Layout/Layout.tsx":{"bytesInOutput":7402},"src/components/Layout/index.ts":{"bytesInOutput":0},"src/components/index.ts":{"bytesInOutput":0}},"bytes":9299},"dist/lib/browser/add-toast-M6ZVP2PQ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1116},"dist/lib/browser/add-toast-M6ZVP2PQ.mjs":{"imports":[{"path":"dist/lib/browser/chunk-M4TYMLOE.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/add-toast.ts","inputs":{"src/operations/add-toast.ts":{"bytesInOutput":379}},"bytes":587},"dist/lib/browser/close-M6YHTWUZ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":750},"dist/lib/browser/close-M6YHTWUZ.mjs":{"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/close.ts","inputs":{"src/operations/close.ts":{"bytesInOutput":252}},"bytes":362},"dist/lib/browser/open-ND4QPYWD.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":745},"dist/lib/browser/open-ND4QPYWD.mjs":{"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/open.ts","inputs":{"src/operations/open.ts":{"bytesInOutput":250}},"bytes":357},"dist/lib/browser/scroll-into-view-UAINWR6E.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":788},"dist/lib/browser/scroll-into-view-UAINWR6E.mjs":{"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/scroll-into-view.ts","inputs":{"src/operations/scroll-into-view.ts":{"bytesInOutput":272}},"bytes":415},"dist/lib/browser/set-layout-mode-E6SJ6ATN.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":784},"dist/lib/browser/set-layout-mode-E6SJ6ATN.mjs":{"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/set-layout-mode.ts","inputs":{"src/operations/set-layout-mode.ts":{"bytesInOutput":270}},"bytes":410},"dist/lib/browser/switch-workspace-RPYF6M6L.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1072},"dist/lib/browser/switch-workspace-RPYF6M6L.mjs":{"imports":[{"path":"dist/lib/browser/chunk-M4TYMLOE.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/switch-workspace.ts","inputs":{"src/operations/switch-workspace.ts":{"bytesInOutput":362}},"bytes":591},"dist/lib/browser/update-complementary-HNS4FIWF.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1451},"dist/lib/browser/update-complementary-HNS4FIWF.mjs":{"imports":[{"path":"dist/lib/browser/chunk-M4TYMLOE.mjs","kind":"import-statement"},{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/operation","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/update-complementary.ts","inputs":{"src/operations/update-complementary.ts":{"bytesInOutput":547}},"bytes":788},"dist/lib/browser/chunk-M4TYMLOE.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1182},"dist/lib/browser/chunk-M4TYMLOE.mjs":{"imports":[{"path":"dist/lib/browser/chunk-F2MMDTKN.mjs","kind":"import-statement"},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["updateState"],"inputs":{"src/operations/update-state.ts":{"bytesInOutput":398}},"bytes":558},"dist/lib/browser/chunk-F2MMDTKN.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2117},"dist/lib/browser/chunk-F2MMDTKN.mjs":{"imports":[{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["LayoutState","meta"],"inputs":{"src/meta.ts":{"bytesInOutput":395},"src/types/capabilities.ts":{"bytesInOutput":105},"src/types/index.ts":{"bytesInOutput":0}},"bytes":624}}}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/operations/open.ts
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
import { LayoutOperation } from "@dxos/app-toolkit";
|
|
4
|
+
import { Operation } from "@dxos/operation";
|
|
5
|
+
var handler = LayoutOperation.Open.pipe(Operation.withHandler(() => Effect.void));
|
|
6
|
+
var open_default = handler;
|
|
7
|
+
export {
|
|
8
|
+
open_default as default
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=open-ND4QPYWD.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/open.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/operation';\n\nconst handler: Operation.WithHandler<typeof LayoutOperation.Open> = LayoutOperation.Open.pipe(\n Operation.withHandler(() => Effect.void),\n);\n\nexport default handler;\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,YAAY;AAExB,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAE1B,IAAMC,UAA8DC,gBAAgBC,KAAKC,KACvFC,UAAUC,YAAY,MAAaC,WAAI,CAAA;AAGzC,IAAA,eAAeN;",
|
|
6
|
+
"names": ["Effect", "LayoutOperation", "Operation", "handler", "LayoutOperation", "Open", "pipe", "Operation", "withHandler", "void"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// src/capabilities/operation-handler/operation-handler.ts
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
import { Capabilities, Capability } from "@dxos/app-framework";
|
|
4
|
+
|
|
5
|
+
// src/operations/index.ts
|
|
6
|
+
import { OperationHandlerSet } from "@dxos/operation";
|
|
7
|
+
var TestingOperationHandlerSet = OperationHandlerSet.lazy(() => import("./add-toast-M6ZVP2PQ.mjs"), () => import("./close-M6YHTWUZ.mjs"), () => import("./open-ND4QPYWD.mjs"), () => import("./scroll-into-view-UAINWR6E.mjs"), () => import("./set-layout-mode-E6SJ6ATN.mjs"), () => import("./switch-workspace-RPYF6M6L.mjs"), () => import("./update-complementary-HNS4FIWF.mjs"), () => import("./update-dialog-W7QOCQ2N.mjs"), () => import("./update-popover-UELZDJW6.mjs"), () => import("./update-sidebar-RJZTREDE.mjs"));
|
|
8
|
+
|
|
9
|
+
// src/capabilities/operation-handler/operation-handler.ts
|
|
10
|
+
var operation_handler_default = Capability.makeModule(Effect.fnUntraced(function* () {
|
|
11
|
+
return Capability.contributes(Capabilities.OperationHandler, TestingOperationHandlerSet);
|
|
12
|
+
}));
|
|
13
|
+
export {
|
|
14
|
+
operation_handler_default as default
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=operation-handler-DUWMXELV.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/capabilities/operation-handler/operation-handler.ts", "../../../src/operations/index.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { Capabilities, Capability } from '@dxos/app-framework';\nimport type { OperationHandlerSet } from '@dxos/operation';\n\nimport { TestingOperationHandlerSet } from '../../operations';\n\nexport default Capability.makeModule<OperationHandlerSet.OperationHandlerSet>(\n Effect.fnUntraced(function* () {\n return Capability.contributes(Capabilities.OperationHandler, TestingOperationHandlerSet);\n }),\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { OperationHandlerSet } from '@dxos/operation';\n\nexport const TestingOperationHandlerSet = OperationHandlerSet.lazy(\n () => import('./add-toast'),\n () => import('./close'),\n () => import('./open'),\n () => import('./scroll-into-view'),\n () => import('./set-layout-mode'),\n () => import('./switch-workspace'),\n () => import('./update-complementary'),\n () => import('./update-dialog'),\n () => import('./update-popover'),\n () => import('./update-sidebar'),\n);\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,YAAY;AAExB,SAASC,cAAcC,kBAAkB;;;ACFzC,SAASC,2BAA2B;AAE7B,IAAMC,6BAA6BC,oBAAoBC,KAC5D,MAAM,OAAO,0BAAA,GACb,MAAM,OAAO,sBAAA,GACb,MAAM,OAAO,qBAAA,GACb,MAAM,OAAO,iCAAA,GACb,MAAM,OAAO,gCAAA,GACb,MAAM,OAAO,iCAAA,GACb,MAAM,OAAO,qCAAA,GACb,MAAM,OAAO,8BAAA,GACb,MAAM,OAAO,+BAAA,GACb,MAAM,OAAO,+BAAA,CAAA;;;ADLf,IAAA,4BAAeC,WAAWC,WACjBC,kBAAW,aAAA;AAChB,SAAOF,WAAWG,YAAYC,aAAaC,kBAAkBC,0BAAAA;AAC/D,CAAA,CAAA;",
|
|
6
|
+
"names": ["Effect", "Capabilities", "Capability", "OperationHandlerSet", "TestingOperationHandlerSet", "OperationHandlerSet", "lazy", "Capability", "makeModule", "fnUntraced", "contributes", "Capabilities", "OperationHandler", "TestingOperationHandlerSet"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/operations/scroll-into-view.ts
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
import { LayoutOperation } from "@dxos/app-toolkit";
|
|
4
|
+
import { Operation } from "@dxos/operation";
|
|
5
|
+
var handler = LayoutOperation.ScrollIntoView.pipe(Operation.withHandler(() => Effect.void));
|
|
6
|
+
var scroll_into_view_default = handler;
|
|
7
|
+
export {
|
|
8
|
+
scroll_into_view_default as default
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=scroll-into-view-UAINWR6E.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/scroll-into-view.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/operation';\n\nconst handler: Operation.WithHandler<typeof LayoutOperation.ScrollIntoView> = LayoutOperation.ScrollIntoView.pipe(\n Operation.withHandler(() => Effect.void),\n);\n\nexport default handler;\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,YAAY;AAExB,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAE1B,IAAMC,UAAwEC,gBAAgBC,eAAeC,KAC3GC,UAAUC,YAAY,MAAaC,WAAI,CAAA;AAGzC,IAAA,2BAAeN;",
|
|
6
|
+
"names": ["Effect", "LayoutOperation", "Operation", "handler", "LayoutOperation", "ScrollIntoView", "pipe", "Operation", "withHandler", "void"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/operations/set-layout-mode.ts
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
import { LayoutOperation } from "@dxos/app-toolkit";
|
|
4
|
+
import { Operation } from "@dxos/operation";
|
|
5
|
+
var handler = LayoutOperation.SetLayoutMode.pipe(Operation.withHandler(() => Effect.void));
|
|
6
|
+
var set_layout_mode_default = handler;
|
|
7
|
+
export {
|
|
8
|
+
set_layout_mode_default as default
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=set-layout-mode-E6SJ6ATN.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/set-layout-mode.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/operation';\n\nconst handler: Operation.WithHandler<typeof LayoutOperation.SetLayoutMode> = LayoutOperation.SetLayoutMode.pipe(\n Operation.withHandler(() => Effect.void),\n);\n\nexport default handler;\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,YAAY;AAExB,SAASC,uBAAuB;AAChC,SAASC,iBAAiB;AAE1B,IAAMC,UAAuEC,gBAAgBC,cAAcC,KACzGC,UAAUC,YAAY,MAAaC,WAAI,CAAA;AAGzC,IAAA,0BAAeN;",
|
|
6
|
+
"names": ["Effect", "LayoutOperation", "Operation", "handler", "LayoutOperation", "SetLayoutMode", "pipe", "Operation", "withHandler", "void"]
|
|
7
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
LayoutState
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-F2MMDTKN.mjs";
|
|
4
4
|
|
|
5
5
|
// src/capabilities/state/state.tsx
|
|
6
6
|
import { Atom } from "@effect-atom/atom-react";
|
|
@@ -11,6 +11,7 @@ var defaultState = {
|
|
|
11
11
|
sidebarState: "closed",
|
|
12
12
|
complementarySidebarState: "closed",
|
|
13
13
|
dialogOpen: false,
|
|
14
|
+
toasts: [],
|
|
14
15
|
workspace: "default"
|
|
15
16
|
};
|
|
16
17
|
var state_default = Capability.makeModule(Effect.fnUntraced(function* (props) {
|
|
@@ -40,4 +41,4 @@ var state_default = Capability.makeModule(Effect.fnUntraced(function* (props) {
|
|
|
40
41
|
export {
|
|
41
42
|
state_default as default
|
|
42
43
|
};
|
|
43
|
-
//# sourceMappingURL=state-
|
|
44
|
+
//# sourceMappingURL=state-MRRN7LZE.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/capabilities/state/state.tsx"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Atom } from '@effect-atom/atom-react';\nimport * as Effect from 'effect/Effect';\n\nimport { Capability } from '@dxos/app-framework';\nimport { AppCapabilities } from '@dxos/app-toolkit';\n\nimport { LayoutState, type LayoutStateProps } from '../../types';\n\nconst defaultState: LayoutStateProps = {\n sidebarState: 'closed',\n complementarySidebarState: 'closed',\n dialogOpen: false,\n toasts: [],\n workspace: 'default',\n};\n\nexport default Capability.makeModule(\n Effect.fnUntraced(function* (props?: { initialState?: Partial<LayoutStateProps> }) {\n const { initialState } = props ?? {};\n const stateAtom = Atom.make<LayoutStateProps>({ ...defaultState, ...initialState });\n\n const layoutAtom = Atom.make((get): AppCapabilities.Layout => {\n const state = get(stateAtom);\n return {\n mode: 'storybook',\n dialogOpen: state.dialogOpen,\n sidebarOpen: state.sidebarState === 'expanded',\n complementarySidebarOpen: state.complementarySidebarState === 'expanded',\n workspace: state.workspace,\n active: [],\n inactive: [],\n scrollIntoView: undefined,\n };\n });\n\n return [Capability.contributes(LayoutState, stateAtom), Capability.contributes(AppCapabilities.Layout, layoutAtom)];\n }),\n);\n"],
|
|
5
|
+
"mappings": ";;;;;AAIA,SAASA,YAAY;AACrB,YAAYC,YAAY;AAExB,SAASC,kBAAkB;AAC3B,SAASC,uBAAuB;AAIhC,IAAMC,eAAiC;EACrCC,cAAc;EACdC,2BAA2B;EAC3BC,YAAY;EACZC,QAAQ,CAAA;EACRC,WAAW;AACb;AAEA,IAAA,gBAAeC,WAAWC,WACjBC,kBAAW,WAAWC,OAAoD;AAC/E,QAAM,EAAEC,aAAY,IAAKD,SAAS,CAAC;AACnC,QAAME,YAAYC,KAAKC,KAAuB;IAAE,GAAGb;IAAc,GAAGU;EAAa,CAAA;AAEjF,QAAMI,aAAaF,KAAKC,KAAK,CAACE,QAAAA;AAC5B,UAAMC,QAAQD,IAAIJ,SAAAA;AAClB,WAAO;MACLM,MAAM;MACNd,YAAYa,MAAMb;MAClBe,aAAaF,MAAMf,iBAAiB;MACpCkB,0BAA0BH,MAAMd,8BAA8B;MAC9DG,WAAWW,MAAMX;MACjBe,QAAQ,CAAA;MACRC,UAAU,CAAA;MACVC,gBAAgBC;IAClB;EACF,CAAA;AAEA,SAAO;IAACjB,WAAWkB,YAAYC,aAAad,SAAAA;IAAYL,WAAWkB,YAAYE,gBAAgBC,QAAQb,UAAAA;;AACzG,CAAA,CAAA;",
|
|
6
|
+
"names": ["Atom", "Effect", "Capability", "AppCapabilities", "defaultState", "sidebarState", "complementarySidebarState", "dialogOpen", "toasts", "workspace", "Capability", "makeModule", "fnUntraced", "props", "initialState", "stateAtom", "Atom", "make", "layoutAtom", "get", "state", "mode", "sidebarOpen", "complementarySidebarOpen", "active", "inactive", "scrollIntoView", "undefined", "contributes", "LayoutState", "AppCapabilities", "Layout"]
|
|
7
|
+
}
|