@dxos/plugin-stack 0.6.12 → 0.6.13-main.09887cd
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/{StackMain-XRQRNZ4I.mjs → StackMain-JA6SVPH5.mjs} +10 -8
- package/dist/lib/browser/StackMain-JA6SVPH5.mjs.map +7 -0
- package/dist/lib/browser/{chunk-R5KXWF2W.mjs → chunk-BA6WV7BZ.mjs} +9 -3
- package/dist/lib/browser/{chunk-R5KXWF2W.mjs.map → chunk-BA6WV7BZ.mjs.map} +3 -3
- package/dist/lib/browser/{chunk-AYDYMPJK.mjs → chunk-ONAKM24Z.mjs} +3 -6
- package/dist/lib/browser/chunk-ONAKM24Z.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +8 -6
- package/dist/lib/browser/index.mjs.map +3 -3
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/meta.mjs +1 -1
- package/dist/lib/browser/types/index.mjs +1 -1
- package/dist/lib/node/{StackMain-XJGYFDDN.cjs → StackMain-P2QHA4YD.cjs} +23 -21
- package/dist/lib/node/StackMain-P2QHA4YD.cjs.map +7 -0
- package/dist/lib/node/{chunk-EMD6A66G.cjs → chunk-ACPGRTG3.cjs} +12 -6
- package/dist/lib/node/{chunk-EMD6A66G.cjs.map → chunk-ACPGRTG3.cjs.map} +3 -3
- package/dist/lib/node/{chunk-I42JKRXR.cjs → chunk-O5SQVKNW.cjs} +5 -18
- package/dist/lib/node/chunk-O5SQVKNW.cjs.map +7 -0
- package/dist/lib/node/index.cjs +51 -49
- package/dist/lib/node/index.cjs.map +3 -3
- package/dist/lib/node/meta.cjs +4 -4
- package/dist/lib/node/meta.cjs.map +1 -1
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/types/index.cjs +3 -3
- package/dist/lib/node/types/index.cjs.map +1 -1
- package/dist/lib/node-esm/StackMain-5W53IZEG.mjs +279 -0
- package/dist/lib/node-esm/StackMain-5W53IZEG.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-DIM4KTS3.mjs +29 -0
- package/dist/lib/node-esm/chunk-DIM4KTS3.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-J57BXQJY.mjs +18 -0
- package/dist/lib/node-esm/chunk-J57BXQJY.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +288 -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/meta.mjs +12 -0
- package/dist/lib/node-esm/meta.mjs.map +7 -0
- package/dist/lib/node-esm/types/index.mjs +10 -0
- package/dist/lib/node-esm/types/index.mjs.map +7 -0
- package/dist/types/src/StackPlugin.d.ts.map +1 -1
- package/dist/types/src/components/StackMain.d.ts +2 -1
- package/dist/types/src/components/StackMain.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +2 -1
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +1 -4
- package/dist/types/src/meta.d.ts.map +1 -1
- package/package.json +33 -29
- package/src/StackPlugin.tsx +16 -7
- package/src/components/StackMain.tsx +48 -44
- package/src/{meta.tsx → meta.ts} +3 -5
- package/src/types/stack.ts +2 -2
- package/dist/lib/browser/StackMain-XRQRNZ4I.mjs.map +0 -7
- package/dist/lib/browser/chunk-AYDYMPJK.mjs.map +0 -7
- package/dist/lib/node/StackMain-XJGYFDDN.cjs.map +0 -7
- package/dist/lib/node/chunk-I42JKRXR.cjs.map +0 -7
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SECTION_IDENTIFIER,
|
|
3
3
|
STACK_PLUGIN
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-ONAKM24Z.mjs";
|
|
5
5
|
import {
|
|
6
6
|
StackViewType
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-BA6WV7BZ.mjs";
|
|
8
8
|
|
|
9
9
|
// packages/plugins/plugin-stack/src/components/StackMain.tsx
|
|
10
10
|
import { Plus } from "@phosphor-icons/react";
|
|
@@ -15,7 +15,8 @@ import { useGraph } from "@dxos/plugin-graph";
|
|
|
15
15
|
import { SpaceAction } from "@dxos/plugin-space";
|
|
16
16
|
import { fullyQualifiedId } from "@dxos/react-client/echo";
|
|
17
17
|
import { Button, toLocalizedString as toLocalizedString2, useTranslation as useTranslation2 } from "@dxos/react-ui";
|
|
18
|
-
import {
|
|
18
|
+
import { AttentionProvider } from "@dxos/react-ui-attention";
|
|
19
|
+
import { Mosaic, Path } from "@dxos/react-ui-mosaic";
|
|
19
20
|
import { Stack } from "@dxos/react-ui-stack";
|
|
20
21
|
import { nonNullable } from "@dxos/util";
|
|
21
22
|
|
|
@@ -107,7 +108,7 @@ var SectionContent = ({ data }) => {
|
|
|
107
108
|
placeholder: /* @__PURE__ */ React2.createElement(React2.Fragment, null)
|
|
108
109
|
});
|
|
109
110
|
};
|
|
110
|
-
var StackMain = ({ collection, separation }) => {
|
|
111
|
+
var StackMain = ({ id, collection, separation }) => {
|
|
111
112
|
const dispatch = useIntentDispatcher2();
|
|
112
113
|
const { graph } = useGraph();
|
|
113
114
|
const { t } = useTranslation2(STACK_PLUGIN);
|
|
@@ -127,7 +128,6 @@ var StackMain = ({ collection, separation }) => {
|
|
|
127
128
|
collection,
|
|
128
129
|
stack
|
|
129
130
|
]);
|
|
130
|
-
const id = `stack-${collection.id}`;
|
|
131
131
|
const items = collection.objects.filter(nonNullable).map((object) => {
|
|
132
132
|
const metadata = metadataPlugin?.provides.metadata.resolver(getType(object)?.objectId ?? "never");
|
|
133
133
|
const view = {
|
|
@@ -230,7 +230,9 @@ var StackMain = ({ collection, separation }) => {
|
|
|
230
230
|
[id2]: collapsed
|
|
231
231
|
}));
|
|
232
232
|
};
|
|
233
|
-
return /* @__PURE__ */ React2.createElement(
|
|
233
|
+
return /* @__PURE__ */ React2.createElement(AttentionProvider, {
|
|
234
|
+
id
|
|
235
|
+
}, /* @__PURE__ */ React2.createElement(Mosaic.Root, null, /* @__PURE__ */ React2.createElement(Mosaic.DragOverlay, null), /* @__PURE__ */ React2.createElement(Stack, {
|
|
234
236
|
id,
|
|
235
237
|
"data-testid": "main.stack",
|
|
236
238
|
SectionContent,
|
|
@@ -267,10 +269,10 @@ var StackMain = ({ collection, separation }) => {
|
|
|
267
269
|
})
|
|
268
270
|
}, /* @__PURE__ */ React2.createElement(Plus, null), /* @__PURE__ */ React2.createElement("span", {
|
|
269
271
|
className: "sr-only"
|
|
270
|
-
}, t("add section label")))));
|
|
272
|
+
}, t("add section label"))))));
|
|
271
273
|
};
|
|
272
274
|
var StackMain_default = StackMain;
|
|
273
275
|
export {
|
|
274
276
|
StackMain_default as default
|
|
275
277
|
};
|
|
276
|
-
//# sourceMappingURL=StackMain-
|
|
278
|
+
//# sourceMappingURL=StackMain-JA6SVPH5.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/StackMain.tsx", "../../../src/components/AddSection.tsx"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Plus } from '@phosphor-icons/react';\nimport React, { useEffect, useMemo, useState } from 'react';\n\nimport {\n LayoutAction,\n NavigationAction,\n parseMetadataResolverPlugin,\n Surface,\n useIntentDispatcher,\n useResolvePlugin,\n} from '@dxos/app-framework';\nimport { create, getType, isReactiveObject } from '@dxos/echo-schema';\nimport { useGraph } from '@dxos/plugin-graph';\nimport { SpaceAction } from '@dxos/plugin-space';\nimport { type CollectionType } from '@dxos/plugin-space/types';\nimport { fullyQualifiedId } from '@dxos/react-client/echo';\nimport { Button, toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { AttentionProvider } from '@dxos/react-ui-attention';\nimport { type MosaicDataItem, type MosaicDropEvent, type MosaicMoveEvent, Mosaic, Path } from '@dxos/react-ui-mosaic';\nimport {\n type AddSectionPosition,\n type CollapsedSections,\n Stack,\n type StackProps,\n type StackSectionItem,\n} from '@dxos/react-ui-stack';\nimport { nonNullable } from '@dxos/util';\n\nimport { AddSection } from './AddSection';\nimport { SECTION_IDENTIFIER, STACK_PLUGIN } from '../meta';\nimport { StackViewType } from '../types';\n\nconst SectionContent: StackProps['SectionContent'] = ({ data }) => {\n // TODO(wittjosiah): Better section placeholder.\n return <Surface role='section' data={{ object: data }} limit={1} placeholder={<></>} />;\n};\n\ntype StackMainProps = {\n id: string;\n collection: CollectionType;\n separation?: boolean;\n};\n\nconst StackMain = ({ id, collection, separation }: StackMainProps) => {\n const dispatch = useIntentDispatcher();\n const { graph } = useGraph();\n const { t } = useTranslation(STACK_PLUGIN);\n const metadataPlugin = useResolvePlugin(parseMetadataResolverPlugin);\n const defaultStack = useMemo(() => create(StackViewType, { sections: {} }), [collection]);\n const stack = (collection.views[StackViewType.typename] as StackViewType) ?? defaultStack;\n const [collapsedSections, setCollapsedSections] = useState<CollapsedSections>({});\n\n useEffect(() => {\n if (!collection.views[StackViewType.typename]) {\n collection.views[StackViewType.typename] = stack;\n }\n }, [collection, stack]);\n\n const items =\n collection.objects\n // TODO(wittjosiah): Should the database handle this differently?\n // TODO(wittjosiah): Render placeholders for missing objects so they can be removed from the stack?\n .filter(nonNullable)\n .map((object) => {\n const metadata = metadataPlugin?.provides.metadata.resolver(\n getType(object)?.objectId ?? 'never',\n ) as StackSectionItem['metadata'];\n const view = {\n ...stack.sections[object.id],\n collapsed: collapsedSections[fullyQualifiedId(object)],\n title:\n (object as any)?.title ?? toLocalizedString(graph.findNode(fullyQualifiedId(object))?.properties.label, t),\n } as StackSectionItem['view'];\n return { id: fullyQualifiedId(object), object, metadata, view };\n }) ?? [];\n\n const handleOver = ({ active, over }: MosaicMoveEvent<number>) => {\n // TODO(thure): Eventually Stack should handle foreign draggables.\n if (active.type !== SECTION_IDENTIFIER) {\n return 'reject';\n }\n if (Path.parent(active.path) === Path.parent(over.path)) {\n return 'rearrange';\n }\n\n const parseData = metadataPlugin?.provides.metadata.resolver(active.type)?.parse;\n const data = parseData ? parseData(active.item, 'object') : active.item;\n\n // TODO(wittjosiah): Prevent dropping items which don't have a section renderer?\n // Perhaps stack plugin should just provide a fallback section renderer.\n if (!isReactiveObject(data)) {\n return 'reject';\n }\n\n const exists = items.findIndex(({ id }) => id === active.item.id) >= 0;\n if (!exists) {\n return 'transfer';\n } else {\n return 'reject';\n }\n };\n\n const handleDrop = ({ operation, active, over }: MosaicDropEvent<number>) => {\n if (\n (active.path === Path.create(id, active.item.id) || active.path === id) &&\n (operation !== 'copy' || over.path === Path.create(id, over.item.id) || over.path === id)\n ) {\n collection.objects.splice(active.position!, 1);\n delete stack.sections[active.item.id];\n }\n\n const parseData = metadataPlugin?.provides.metadata.resolver(active.type)?.parse;\n const object = parseData?.(active.item, 'object');\n if (object && over.path === Path.create(id, over.item.id)) {\n collection.objects.splice(over.position!, 0, object);\n } else if (object && over.path === id) {\n collection.objects.push(object);\n }\n\n if (!stack.sections[object.id]) {\n stack.sections[object.id] = {};\n }\n };\n\n const handleDelete = async (path: string) => {\n const index = collection.objects\n .filter(nonNullable)\n .findIndex((section) => fullyQualifiedId(section) === Path.last(path));\n if (index >= 0) {\n await dispatch({\n action: SpaceAction.REMOVE_OBJECT,\n data: { object: collection.objects[index], collection },\n });\n\n // TODO(wittjosiah): The section should also be removed, but needs to be restored if the action is undone.\n // delete stack.sections[Path.last(path)];\n }\n };\n\n // TODO(wittjosiah): Factor out.\n\n const handleNavigate = async (object: MosaicDataItem) => {\n const toId = fullyQualifiedId(object);\n await dispatch([\n {\n action: NavigationAction.OPEN,\n data: { activeParts: { main: [toId] } },\n },\n {\n action: LayoutAction.SCROLL_INTO_VIEW,\n data: { id: toId },\n },\n ]);\n };\n\n const handleAddSection = (path: string, position: AddSectionPosition) => {\n void dispatch?.({\n action: LayoutAction.SET_LAYOUT,\n data: {\n element: 'dialog',\n component: `${STACK_PLUGIN}/AddSectionDialog`,\n subject: { path, position, collection },\n },\n });\n };\n\n const handleCollapseSection = (id: string, collapsed: boolean) => {\n setCollapsedSections((prev) => ({ ...prev, [id]: collapsed }));\n };\n\n return (\n <AttentionProvider id={id}>\n <Mosaic.Root>\n <Mosaic.DragOverlay />\n <Stack\n id={id}\n data-testid='main.stack'\n SectionContent={SectionContent}\n type={SECTION_IDENTIFIER}\n items={items}\n separation={separation}\n emptyComponent={<span data-testid='stack.empty'></span>}\n onDrop={handleDrop}\n onOver={handleOver}\n onDeleteSection={handleDelete}\n onNavigateToSection={handleNavigate}\n onAddSection={handleAddSection}\n onCollapseSection={handleCollapseSection}\n />\n\n {items.length === 0 ? (\n <AddSection collection={collection} />\n ) : (\n <div role='none' className='flex mlb-2 pli-2 justify-center'>\n <Button\n data-testid='stack.createSection'\n classNames='gap-2'\n onClick={() =>\n dispatch?.({\n action: LayoutAction.SET_LAYOUT,\n data: {\n element: 'dialog',\n component: 'dxos.org/plugin/stack/AddSectionDialog',\n subject: { position: 'afterAll', collection },\n },\n })\n }\n >\n <Plus />\n <span className='sr-only'>{t('add section label')}</span>\n </Button>\n </div>\n )}\n </Mosaic.Root>\n </AttentionProvider>\n );\n};\n\nexport default StackMain;\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { useArrowNavigationGroup } from '@fluentui/react-tabster';\nimport { type IconProps } from '@phosphor-icons/react';\nimport React, { type FC, type KeyboardEvent, type MouseEvent, useCallback } from 'react';\n\nimport { usePlugin, useIntentDispatcher } from '@dxos/app-framework';\nimport { type CollectionType } from '@dxos/plugin-space/types';\nimport { toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { getSize, mx } from '@dxos/react-ui-theme';\n\nimport { STACK_PLUGIN } from '../meta';\nimport { StackViewType, type StackSectionCreator, type StackPluginProvides } from '../types';\n\nconst CreatorTile = ({\n Icon,\n label,\n testId,\n handleAdd,\n}: {\n Icon: FC<IconProps>;\n testId: string;\n label: string;\n handleAdd: () => void;\n}) => {\n const onClick = useCallback((_: MouseEvent<HTMLDivElement>) => handleAdd(), [handleAdd]);\n const onKeyDown = useCallback(\n (event: KeyboardEvent<HTMLDivElement>) => {\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n handleAdd();\n }\n },\n [handleAdd],\n );\n\n return (\n <div\n role='button'\n aria-label={label}\n tabIndex={0}\n className={mx(\n 'flex items-center w-[10rem] h-16 overflow-hidden',\n 'border rounded-md border-separator shadow-sm hover:bg-hoverSurface cursor-pointer',\n )}\n onClick={onClick}\n onKeyDown={onKeyDown}\n data-testid={testId}\n >\n <div className='flex h-full w-12 items-center justify-center bg-scrim shrink-0 border-r border-separator'>\n <Icon weight='thin' className={getSize(6)} />\n </div>\n <div className='overflow-hidden items-center p-2 px-3'>\n <span className='capitalize'>{label}</span>\n </div>\n </div>\n );\n};\n\nexport const AddSection = ({ collection }: { collection: CollectionType }) => {\n const domAttributes = useArrowNavigationGroup({ axis: 'grid' });\n const dispatch = useIntentDispatcher();\n const { t } = useTranslation(STACK_PLUGIN);\n\n const stackPlugin = usePlugin<StackPluginProvides>(STACK_PLUGIN);\n const stackCreators = stackPlugin?.provides?.stack.creators ?? [];\n\n const handleAdd = useCallback(\n async (creator: StackSectionCreator) => {\n const { data: section } = (await dispatch(creator.intent)) ?? {};\n collection.objects = [section];\n const stack = collection.views[StackViewType.typename];\n if (stack) {\n stack.sections[section.id] = {};\n }\n },\n [collection, dispatch],\n );\n\n if (stackCreators.length === 0) {\n return null;\n }\n\n return (\n <div {...domAttributes} role='none' className='flex flex-wrap items-center p-8 gap-4'>\n {stackCreators.map((creator) => {\n const { id, type, icon, testId } = creator;\n return (\n <CreatorTile\n key={id}\n label={toLocalizedString(type, t)}\n testId={testId}\n Icon={icon}\n handleAdd={() => handleAdd(creator)}\n />\n );\n })}\n </div>\n );\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;AAIA,SAASA,YAAY;AACrB,OAAOC,UAASC,WAAWC,SAASC,gBAAgB;AAEpD,SACEC,cACAC,kBACAC,6BACAC,SACAC,uBAAAA,sBACAC,wBACK;AACP,SAAS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R,OAAA,cAAC2G,OAAAA;IAAIzG,MAAK;IAAO0G,WAAU;KACzB,gBAAA5G,OAAA,cAAC6G,QAAAA;IACCb,eAAY;IACZc,YAAW;IACXC,SAAS,MACPrG,WAAW;MACT+D,QAAQS,aAAaG;MACrBtF,MAAM;QACJuF,SAAS;QACTC,WAAW;QACXC,SAAS;UAAErB,UAAU;UAAY3D;QAAW;MAC9C;IACF,CAAA;KAGF,gBAAAR,OAAA,cAACgH,MAAAA,IAAAA,GACD,gBAAAhH,OAAA,cAACkG,QAAAA;IAAKU,WAAU;KAAW9F,EAAE,mBAAA,CAAA,CAAA,CAAA,CAAA,CAAA;AAO3C;AAEA,IAAA,oBAAeR;",
|
|
6
|
+
"names": ["Plus", "React", "useEffect", "useMemo", "useState", "LayoutAction", "NavigationAction", "parseMetadataResolverPlugin", "Surface", "useIntentDispatcher", "useResolvePlugin", "create", "getType", "isReactiveObject", "useGraph", "SpaceAction", "fullyQualifiedId", "Button", "toLocalizedString", "useTranslation", "AttentionProvider", "Mosaic", "Path", "Stack", "nonNullable", "useArrowNavigationGroup", "React", "useCallback", "usePlugin", "useIntentDispatcher", "toLocalizedString", "useTranslation", "getSize", "mx", "CreatorTile", "Icon", "label", "testId", "handleAdd", "onClick", "useCallback", "_", "onKeyDown", "event", "key", "preventDefault", "div", "role", "aria-label", "tabIndex", "className", "mx", "data-testid", "weight", "getSize", "span", "AddSection", "collection", "domAttributes", "useArrowNavigationGroup", "axis", "dispatch", "useIntentDispatcher", "t", "useTranslation", "STACK_PLUGIN", "stackPlugin", "usePlugin", "stackCreators", "provides", "stack", "creators", "creator", "data", "section", "intent", "objects", "views", "StackViewType", "typename", "sections", "id", "length", "map", "type", "icon", "toLocalizedString", "SectionContent", "data", "React", "Surface", "role", "object", "limit", "placeholder", "StackMain", "id", "collection", "separation", "dispatch", "useIntentDispatcher", "graph", "useGraph", "t", "useTranslation", "STACK_PLUGIN", "metadataPlugin", "useResolvePlugin", "parseMetadataResolverPlugin", "defaultStack", "useMemo", "create", "StackViewType", "sections", "stack", "views", "typename", "collapsedSections", "setCollapsedSections", "useState", "useEffect", "items", "objects", "filter", "nonNullable", "map", "metadata", "provides", "resolver", "getType", "objectId", "view", "collapsed", "fullyQualifiedId", "title", "toLocalizedString", "findNode", "properties", "label", "handleOver", "active", "over", "type", "SECTION_IDENTIFIER", "Path", "parent", "path", "parseData", "parse", "item", "isReactiveObject", "exists", "findIndex", "handleDrop", "operation", "splice", "position", "push", "handleDelete", "index", "section", "last", "action", "SpaceAction", "REMOVE_OBJECT", "handleNavigate", "toId", "NavigationAction", "OPEN", "activeParts", "main", "LayoutAction", "SCROLL_INTO_VIEW", "handleAddSection", "SET_LAYOUT", "element", "component", "subject", "handleCollapseSection", "prev", "AttentionProvider", "Mosaic", "Root", "DragOverlay", "Stack", "data-testid", "emptyComponent", "span", "onDrop", "onOver", "onDeleteSection", "onNavigateToSection", "onAddSection", "onCollapseSection", "length", "AddSection", "div", "className", "Button", "classNames", "onClick", "Plus"]
|
|
7
|
+
}
|
|
@@ -4,13 +4,19 @@ var SectionSchema = S.Struct({
|
|
|
4
4
|
height: S.optional(S.Number),
|
|
5
5
|
// Space for data that isn't stack-specific but is specific to this view instance.
|
|
6
6
|
// e.g. cover/fill for an image
|
|
7
|
-
custom: S.optional(S.Record(
|
|
7
|
+
custom: S.optional(S.Record({
|
|
8
|
+
key: S.String,
|
|
9
|
+
value: S.Any
|
|
10
|
+
}))
|
|
8
11
|
});
|
|
9
12
|
var StackViewType = class extends TypedObject({
|
|
10
13
|
typename: "dxos.org/type/StackView",
|
|
11
14
|
version: "0.1.0"
|
|
12
15
|
})({
|
|
13
|
-
sections: S.mutable(S.Record(
|
|
16
|
+
sections: S.mutable(S.Record({
|
|
17
|
+
key: S.String,
|
|
18
|
+
value: SectionSchema
|
|
19
|
+
}))
|
|
14
20
|
}) {
|
|
15
21
|
};
|
|
16
22
|
|
|
@@ -18,4 +24,4 @@ export {
|
|
|
18
24
|
SectionSchema,
|
|
19
25
|
StackViewType
|
|
20
26
|
};
|
|
21
|
-
//# sourceMappingURL=chunk-
|
|
27
|
+
//# sourceMappingURL=chunk-BA6WV7BZ.mjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/types/stack.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { S, TypedObject } from '@dxos/echo-schema';\n\n// All section metadata needs to be optional/have defaults.\n// Any objects added to the collection will start with the section defaults.\n// If an object is removed from the collection without removing the section metadata this is fine.\n// Stack component should cleanup the superfluous data on future edits.\n\nexport const SectionSchema = S.Struct({\n height: S.optional(S.Number),\n // Space for data that isn't stack-specific but is specific to this view instance.\n // e.g. cover/fill for an image\n custom: S.optional(S.Record(S.String, S.Any)),\n});\n\nexport class StackViewType extends TypedObject({ typename: 'dxos.org/type/StackView', version: '0.1.0' })({\n sections: S.mutable(S.Record(S.String, SectionSchema)),\n}) {}\n"],
|
|
5
|
-
"mappings": ";AAIA,SAASA,GAAGC,mBAAmB;AAOxB,IAAMC,gBAAgBC,EAAEC,OAAO;EACpCC,QAAQF,EAAEG,SAASH,EAAEI,MAAM;;;EAG3BC,QAAQL,EAAEG,SAASH,EAAEM,
|
|
6
|
-
"names": ["S", "TypedObject", "SectionSchema", "S", "Struct", "height", "optional", "Number", "custom", "Record", "String", "Any", "StackViewType", "TypedObject", "typename", "version", "sections", "mutable"]
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { S, TypedObject } from '@dxos/echo-schema';\n\n// All section metadata needs to be optional/have defaults.\n// Any objects added to the collection will start with the section defaults.\n// If an object is removed from the collection without removing the section metadata this is fine.\n// Stack component should cleanup the superfluous data on future edits.\n\nexport const SectionSchema = S.Struct({\n height: S.optional(S.Number),\n // Space for data that isn't stack-specific but is specific to this view instance.\n // e.g. cover/fill for an image\n custom: S.optional(S.Record({ key: S.String, value: S.Any })),\n});\n\nexport class StackViewType extends TypedObject({ typename: 'dxos.org/type/StackView', version: '0.1.0' })({\n sections: S.mutable(S.Record({ key: S.String, value: SectionSchema })),\n}) {}\n"],
|
|
5
|
+
"mappings": ";AAIA,SAASA,GAAGC,mBAAmB;AAOxB,IAAMC,gBAAgBC,EAAEC,OAAO;EACpCC,QAAQF,EAAEG,SAASH,EAAEI,MAAM;;;EAG3BC,QAAQL,EAAEG,SAASH,EAAEM,OAAO;IAAEC,KAAKP,EAAEQ;IAAQC,OAAOT,EAAEU;EAAI,CAAA,CAAA;AAC5D,CAAA;AAEO,IAAMC,gBAAN,cAA4BC,YAAY;EAAEC,UAAU;EAA2BC,SAAS;AAAQ,CAAA,EAAG;EACxGC,UAAUf,EAAEgB,QAAQhB,EAAEM,OAAO;IAAEC,KAAKP,EAAEQ;IAAQC,OAAOV;EAAc,CAAA,CAAA;AACrE,CAAA,EAAA;AAAI;",
|
|
6
|
+
"names": ["S", "TypedObject", "SectionSchema", "S", "Struct", "height", "optional", "Number", "custom", "Record", "key", "String", "value", "Any", "StackViewType", "TypedObject", "typename", "version", "sections", "mutable"]
|
|
7
7
|
}
|
|
@@ -1,14 +1,11 @@
|
|
|
1
|
-
// packages/plugins/plugin-stack/src/meta.
|
|
2
|
-
import { StackSimple } from "@phosphor-icons/react";
|
|
3
|
-
import React from "react";
|
|
1
|
+
// packages/plugins/plugin-stack/src/meta.ts
|
|
4
2
|
var STACK_PLUGIN = "dxos.org/plugin/stack";
|
|
5
3
|
var SECTION_IDENTIFIER = "dxos.org/type/StackSection";
|
|
6
4
|
var meta_default = {
|
|
7
5
|
id: STACK_PLUGIN,
|
|
8
6
|
// TODO(wittjosiah): Prevents "stacks" language from being exposed to users in settings panel.
|
|
9
7
|
name: "Collections",
|
|
10
|
-
|
|
11
|
-
iconSymbol: "ph--stack-simple--regular"
|
|
8
|
+
icon: "ph--stack-simple--regular"
|
|
12
9
|
};
|
|
13
10
|
|
|
14
11
|
export {
|
|
@@ -16,4 +13,4 @@ export {
|
|
|
16
13
|
SECTION_IDENTIFIER,
|
|
17
14
|
meta_default
|
|
18
15
|
};
|
|
19
|
-
//# sourceMappingURL=chunk-
|
|
16
|
+
//# sourceMappingURL=chunk-ONAKM24Z.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/meta.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { type PluginMeta } from '@dxos/app-framework';\n\nexport const STACK_PLUGIN = 'dxos.org/plugin/stack';\nexport const SECTION_IDENTIFIER = 'dxos.org/type/StackSection';\n\nexport default {\n id: STACK_PLUGIN,\n // TODO(wittjosiah): Prevents \"stacks\" language from being exposed to users in settings panel.\n name: 'Collections',\n icon: 'ph--stack-simple--regular',\n} satisfies PluginMeta;\n"],
|
|
5
|
+
"mappings": ";AAMO,IAAMA,eAAe;AACrB,IAAMC,qBAAqB;AAElC,IAAA,eAAe;EACbC,IAAIF;;EAEJG,MAAM;EACNC,MAAM;AACR;",
|
|
6
|
+
"names": ["STACK_PLUGIN", "SECTION_IDENTIFIER", "id", "name", "icon"]
|
|
7
|
+
}
|
|
@@ -2,18 +2,18 @@ import {
|
|
|
2
2
|
SECTION_IDENTIFIER,
|
|
3
3
|
STACK_PLUGIN,
|
|
4
4
|
meta_default
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-ONAKM24Z.mjs";
|
|
6
6
|
import {
|
|
7
7
|
SectionSchema,
|
|
8
8
|
StackViewType
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-BA6WV7BZ.mjs";
|
|
10
10
|
|
|
11
11
|
// packages/plugins/plugin-stack/src/StackPlugin.tsx
|
|
12
|
-
import { StackSimple } from "@phosphor-icons/react";
|
|
13
12
|
import React4 from "react";
|
|
14
13
|
import { create as create2 } from "@dxos/echo-schema";
|
|
15
14
|
import { LocalStorageStore } from "@dxos/local-storage";
|
|
16
15
|
import { CollectionType } from "@dxos/plugin-space/types";
|
|
16
|
+
import { fullyQualifiedId } from "@dxos/react-client/echo";
|
|
17
17
|
import { Main } from "@dxos/react-ui";
|
|
18
18
|
import { baseSurface, topbarBlockPaddingStart, bottombarBlockPaddingEnd } from "@dxos/react-ui-theme";
|
|
19
19
|
|
|
@@ -146,7 +146,7 @@ var AddSectionDialog = ({ path, position, collection }) => {
|
|
|
146
146
|
};
|
|
147
147
|
|
|
148
148
|
// packages/plugins/plugin-stack/src/components/index.ts
|
|
149
|
-
var StackMain = React3.lazy(() => import("./StackMain-
|
|
149
|
+
var StackMain = React3.lazy(() => import("./StackMain-JA6SVPH5.mjs"));
|
|
150
150
|
|
|
151
151
|
// packages/plugins/plugin-stack/src/translations.ts
|
|
152
152
|
import { translations as stackTranslations } from "@dxos/react-ui-stack";
|
|
@@ -204,8 +204,7 @@ var StackPlugin = () => {
|
|
|
204
204
|
ns: STACK_PLUGIN
|
|
205
205
|
}
|
|
206
206
|
],
|
|
207
|
-
icon:
|
|
208
|
-
iconSymbol: "ph--stack-simple--regular"
|
|
207
|
+
icon: "ph--stack-simple--regular"
|
|
209
208
|
},
|
|
210
209
|
[SECTION_IDENTIFIER]: {
|
|
211
210
|
parse: (section, type) => {
|
|
@@ -238,6 +237,7 @@ var StackPlugin = () => {
|
|
|
238
237
|
return dataHasAddSectionDialogProps(data) ? /* @__PURE__ */ React4.createElement(AddSectionDialog, data.subject) : null;
|
|
239
238
|
}
|
|
240
239
|
const primary = data.active ?? data.object;
|
|
240
|
+
const id = typeof data.id === "string" ? data.id : void 0;
|
|
241
241
|
switch (role) {
|
|
242
242
|
case "main":
|
|
243
243
|
return primary instanceof CollectionType ? /* @__PURE__ */ React4.createElement(Main.Content, {
|
|
@@ -248,6 +248,7 @@ var StackPlugin = () => {
|
|
|
248
248
|
bottombarBlockPaddingEnd
|
|
249
249
|
]
|
|
250
250
|
}, /* @__PURE__ */ React4.createElement(StackMain, {
|
|
251
|
+
id: id ?? fullyQualifiedId(primary),
|
|
251
252
|
collection: primary,
|
|
252
253
|
separation: settings.values.separation
|
|
253
254
|
})) : null;
|
|
@@ -256,6 +257,7 @@ var StackPlugin = () => {
|
|
|
256
257
|
role: "none",
|
|
257
258
|
className: "row-span-2 overflow-auto"
|
|
258
259
|
}, /* @__PURE__ */ React4.createElement(StackMain, {
|
|
260
|
+
id: id ?? fullyQualifiedId(primary),
|
|
259
261
|
collection: primary,
|
|
260
262
|
separation: settings.values.separation
|
|
261
263
|
})) : null;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/StackPlugin.tsx", "../../../src/components/index.ts", "../../../src/components/StackSettings.tsx", "../../../src/components/AddSectionDialog.tsx", "../../../src/translations.ts", "../../../src/index.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { StackSimple, type IconProps } from '@phosphor-icons/react';\nimport React from 'react';\n\nimport { type Plugin, type PluginDefinition } from '@dxos/app-framework';\nimport { create } from '@dxos/echo-schema';\nimport { type EchoReactiveObject } from '@dxos/echo-schema';\nimport { LocalStorageStore } from '@dxos/local-storage';\nimport { CollectionType } from '@dxos/plugin-space/types';\nimport { Main } from '@dxos/react-ui';\nimport { baseSurface, topbarBlockPaddingStart, bottombarBlockPaddingEnd } from '@dxos/react-ui-theme';\n\nimport { StackMain, StackSettings, AddSectionDialog, dataHasAddSectionDialogProps } from './components';\nimport meta, { SECTION_IDENTIFIER, STACK_PLUGIN } from './meta';\nimport translations from './translations';\nimport { StackViewType } from './types';\nimport { type StackPluginProvides, type StackProvides, type StackState, type StackSettingsProps } from './types';\n\nexport const StackPlugin = (): PluginDefinition<StackPluginProvides> => {\n const settings = new LocalStorageStore<StackSettingsProps>(STACK_PLUGIN, { separation: true });\n const stackState = create<StackState>({ creators: [] });\n\n return {\n meta,\n ready: async (plugins) => {\n settings.prop({ key: 'separation', type: LocalStorageStore.bool() });\n\n for (const plugin of plugins) {\n if (plugin.meta.id === STACK_PLUGIN) {\n continue;\n }\n\n if (Array.isArray((plugin as Plugin<StackProvides>).provides?.stack?.creators)) {\n stackState.creators.push(...((plugin as Plugin<StackProvides>).provides.stack.creators ?? []));\n }\n }\n },\n provides: {\n settings: settings.values,\n metadata: {\n records: {\n [StackViewType.typename]: {\n placeholder: ['stack title placeholder', { ns: STACK_PLUGIN }],\n icon: (props: IconProps) => <StackSimple {...props} />,\n iconSymbol: 'ph--stack-simple--regular',\n },\n [SECTION_IDENTIFIER]: {\n parse: (section: { object: EchoReactiveObject<any> }, type: string) => {\n switch (type) {\n case 'node':\n // TODO(wittjosiah): Remove cast.\n return { id: section.object.id, label: section.object.title, data: section.object };\n case 'object':\n return section.object;\n case 'view-object':\n return section;\n }\n },\n },\n },\n },\n translations,\n echo: {\n schema: [StackViewType],\n },\n surface: {\n component: ({ data, role }) => {\n switch (data.component) {\n case `${STACK_PLUGIN}/AddSectionDialog`:\n return dataHasAddSectionDialogProps(data) ? <AddSectionDialog {...data.subject} /> : null;\n }\n\n const primary = data.active ?? data.object;\n switch (role) {\n case 'main':\n return primary instanceof CollectionType ? (\n <Main.Content bounce classNames={[baseSurface, topbarBlockPaddingStart, bottombarBlockPaddingEnd]}>\n <StackMain collection={primary} separation={settings.values.separation} />\n </Main.Content>\n ) : null;\n case 'article':\n return primary instanceof CollectionType ? (\n <div role='none' className='row-span-2 overflow-auto'>\n <StackMain collection={primary} separation={settings.values.separation} />\n </div>\n ) : null;\n case 'settings': {\n return data.plugin === meta.id ? <StackSettings settings={settings.values} /> : null;\n }\n default:\n return null;\n }\n },\n },\n stack: stackState,\n },\n };\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\n// Lazily load components for content surfaces.\nexport const StackMain = React.lazy(() => import('./StackMain'));\n\nexport * from './StackSettings';\nexport * from './AddSectionDialog';\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { SettingsValue } from '@dxos/plugin-settings';\nimport { Input, useTranslation } from '@dxos/react-ui';\n\nimport { STACK_PLUGIN } from '../meta';\nimport { type StackSettingsProps } from '../types';\n\nexport const StackSettings = ({ settings }: { settings: StackSettingsProps }) => {\n const { t } = useTranslation(STACK_PLUGIN);\n\n return (\n <>\n <SettingsValue label={t('settings separation label')}>\n <Input.Switch checked={settings.separation} onCheckedChange={(checked) => (settings.separation = !!checked)} />\n </SettingsValue>\n </>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { FilePlus } from '@phosphor-icons/react';\nimport React, { useCallback, useRef, useState } from 'react';\n\nimport { usePlugin, useIntent, LayoutAction, useResolvePlugin, parseFileManagerPlugin } from '@dxos/app-framework';\nimport { type EchoReactiveObject, create } from '@dxos/echo-schema';\nimport { FileType } from '@dxos/plugin-ipfs/types';\nimport { type CollectionType } from '@dxos/plugin-space/types';\nimport { getSpace } from '@dxos/react-client/echo';\nimport { Dialog, toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { Path } from '@dxos/react-ui-mosaic';\nimport { SearchList } from '@dxos/react-ui-searchlist';\nimport { type AddSectionPosition } from '@dxos/react-ui-stack';\nimport { getSize, mx } from '@dxos/react-ui-theme';\nimport { nonNullable } from '@dxos/util';\n\nimport { STACK_PLUGIN } from '../meta';\nimport { StackViewType, type StackPluginProvides } from '../types';\n\ntype AddSectionDialogProps = { path?: string; position: AddSectionPosition; collection: CollectionType };\n\nexport const dataHasAddSectionDialogProps = (data: any): data is { subject: AddSectionDialogProps } => {\n return (\n 'subject' in data &&\n typeof data.subject === 'object' &&\n !!data.subject &&\n 'position' in data.subject &&\n typeof data.subject.position === 'string' &&\n 'collection' in data.subject\n );\n};\n\nexport const AddSectionDialog = ({ path, position, collection }: AddSectionDialogProps) => {\n const { t } = useTranslation(STACK_PLUGIN);\n const stackPlugin = usePlugin<StackPluginProvides>(STACK_PLUGIN);\n const fileManagerPlugin = useResolvePlugin(parseFileManagerPlugin);\n const fileRef = useRef<HTMLInputElement | null>(null);\n const { dispatch } = useIntent();\n const space = getSpace(collection);\n const [pending, setPending] = useState<boolean>(false);\n const [uploadError, setUploadError] = useState<Error | undefined>();\n\n const handleAdd = useCallback(\n (sectionObject: EchoReactiveObject<any>) => {\n const index =\n position === 'beforeAll'\n ? 0\n : position === 'afterAll'\n ? collection.objects.length\n : collection.objects.filter(nonNullable).findIndex((section) => section.id === Path.last(path!));\n\n collection.objects.splice(index + (position === 'after' ? 1 : 0), 0, sectionObject);\n const stack = collection.views[StackViewType.typename];\n if (stack) {\n stack.sections[sectionObject.id] = {};\n }\n setPending(false);\n void dispatch?.({ action: LayoutAction.SET_LAYOUT, data: { element: 'dialog', state: false } });\n },\n [collection, path, position, dispatch],\n );\n\n const handleFileUpload =\n fileManagerPlugin?.provides.file.upload && space\n ? async (file: File) => {\n const filename = file.name.split('.')[0];\n try {\n const info = await fileManagerPlugin.provides.file.upload?.(file, space);\n if (info) {\n const obj = create(FileType, { type: file.type, name: filename, filename, cid: info.cid });\n handleAdd(obj);\n }\n } catch (err: any) {\n setUploadError(err);\n }\n }\n : undefined;\n\n return (\n <Dialog.Content>\n <Dialog.Title>{t(`add section ${position} dialog title`)}</Dialog.Title>\n <SearchList.Root label={t('add section input placeholder')}>\n <SearchList.Input placeholder={t('add section input placeholder')} classNames='pli-3' disabled={pending} />\n <SearchList.Content classNames='min-bs-24 bs-fit max-bs-64 overflow-auto' {...(pending && { inert: 'true' })}>\n {stackPlugin?.provides?.stack.creators?.map(({ id, icon: Icon, label: propsLabel, testId, intent }) => {\n const label = toLocalizedString(propsLabel, t);\n return (\n <SearchList.Item\n value={label}\n key={id}\n onSelect={async () => {\n setPending(true);\n const { data: nextSection } = (await dispatch({ ...intent, data: { space } })) ?? {};\n handleAdd(nextSection);\n }}\n classNames='flex items-center gap-2 pli-2'\n data-testid={testId}\n >\n {Icon && <Icon className={mx(getSize(4), 'shrink-0')} />}\n <span className='grow truncate'>{label}</span>\n </SearchList.Item>\n );\n })}\n {handleFileUpload && (\n <SearchList.Item\n value={t('upload file label')}\n classNames='flex items-center gap-2 pli-2'\n onSelect={() => fileRef.current?.click()}\n >\n <FilePlus />\n <span className='grow truncate'>{t('upload file label')}</span>\n </SearchList.Item>\n )}\n {uploadError && <div className='text-error-500'>{uploadError.message}</div>}\n </SearchList.Content>\n </SearchList.Root>\n {handleFileUpload && (\n <input\n type='file'\n className='sr-only'\n ref={fileRef}\n onChange={({ target: { files } }) => files && handleFileUpload(files[0])}\n />\n )}\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { translations as stackTranslations } from '@dxos/react-ui-stack';\n\nimport { STACK_PLUGIN } from './meta';\n\nexport default [\n {\n 'en-US': {\n [STACK_PLUGIN]: {\n 'plugin name': 'Stacks',\n 'settings separation label': 'Separate sections',\n 'add section beforeAll dialog title': 'Add a section to the start',\n 'add section afterAll dialog title': 'Add a section to the end',\n 'add section before dialog title': 'Add a section',\n 'add section after dialog title': 'Add a section',\n 'add section input placeholder': 'Find the type of section to add',\n 'upload file label': 'Add file',\n 'add section label': 'Add section',\n },\n },\n },\n ...stackTranslations,\n];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { StackPlugin } from './StackPlugin';\n\nexport default StackPlugin;\n\nexport * from './types';\n\nexport * from './StackPlugin';\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;AAIA,
|
|
6
|
-
"names": ["
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type Plugin, type PluginDefinition } from '@dxos/app-framework';\nimport { create, type EchoReactiveObject } from '@dxos/echo-schema';\nimport { LocalStorageStore } from '@dxos/local-storage';\nimport { CollectionType } from '@dxos/plugin-space/types';\nimport { fullyQualifiedId } from '@dxos/react-client/echo';\nimport { Main } from '@dxos/react-ui';\nimport { baseSurface, topbarBlockPaddingStart, bottombarBlockPaddingEnd } from '@dxos/react-ui-theme';\n\nimport { StackMain, StackSettings, AddSectionDialog, dataHasAddSectionDialogProps } from './components';\nimport meta, { SECTION_IDENTIFIER, STACK_PLUGIN } from './meta';\nimport translations from './translations';\nimport { StackViewType } from './types';\nimport { type StackPluginProvides, type StackProvides, type StackState, type StackSettingsProps } from './types';\n\nexport const StackPlugin = (): PluginDefinition<StackPluginProvides> => {\n const settings = new LocalStorageStore<StackSettingsProps>(STACK_PLUGIN, { separation: true });\n const stackState = create<StackState>({ creators: [] });\n\n return {\n meta,\n ready: async (plugins) => {\n settings.prop({ key: 'separation', type: LocalStorageStore.bool() });\n\n for (const plugin of plugins) {\n if (plugin.meta.id === STACK_PLUGIN) {\n continue;\n }\n\n if (Array.isArray((plugin as Plugin<StackProvides>).provides?.stack?.creators)) {\n stackState.creators.push(...((plugin as Plugin<StackProvides>).provides.stack.creators ?? []));\n }\n }\n },\n provides: {\n settings: settings.values,\n metadata: {\n records: {\n [StackViewType.typename]: {\n placeholder: ['stack title placeholder', { ns: STACK_PLUGIN }],\n icon: 'ph--stack-simple--regular',\n },\n [SECTION_IDENTIFIER]: {\n parse: (section: { object: EchoReactiveObject<any> }, type: string) => {\n switch (type) {\n case 'node':\n // TODO(wittjosiah): Remove cast.\n return { id: section.object.id, label: section.object.title, data: section.object };\n case 'object':\n return section.object;\n case 'view-object':\n return section;\n }\n },\n },\n },\n },\n translations,\n echo: {\n schema: [StackViewType],\n },\n surface: {\n component: ({ data, role }) => {\n switch (data.component) {\n case `${STACK_PLUGIN}/AddSectionDialog`:\n return dataHasAddSectionDialogProps(data) ? <AddSectionDialog {...data.subject} /> : null;\n }\n\n const primary = data.active ?? data.object;\n // This allows the id to be overridden by the surface for situations where the id of the collection\n // is not the same as the id of what is being represented (e.g. a space with a root collection).\n const id = typeof data.id === 'string' ? data.id : undefined;\n switch (role) {\n case 'main':\n return primary instanceof CollectionType ? (\n <Main.Content bounce classNames={[baseSurface, topbarBlockPaddingStart, bottombarBlockPaddingEnd]}>\n <StackMain\n id={id ?? fullyQualifiedId(primary)}\n collection={primary}\n separation={settings.values.separation}\n />\n </Main.Content>\n ) : null;\n case 'article':\n return primary instanceof CollectionType ? (\n <div role='none' className='row-span-2 overflow-auto'>\n <StackMain\n id={id ?? fullyQualifiedId(primary)}\n collection={primary}\n separation={settings.values.separation}\n />\n </div>\n ) : null;\n case 'settings': {\n return data.plugin === meta.id ? <StackSettings settings={settings.values} /> : null;\n }\n default:\n return null;\n }\n },\n },\n stack: stackState,\n },\n };\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\n// Lazily load components for content surfaces.\nexport const StackMain = React.lazy(() => import('./StackMain'));\n\nexport * from './StackSettings';\nexport * from './AddSectionDialog';\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { SettingsValue } from '@dxos/plugin-settings';\nimport { Input, useTranslation } from '@dxos/react-ui';\n\nimport { STACK_PLUGIN } from '../meta';\nimport { type StackSettingsProps } from '../types';\n\nexport const StackSettings = ({ settings }: { settings: StackSettingsProps }) => {\n const { t } = useTranslation(STACK_PLUGIN);\n\n return (\n <>\n <SettingsValue label={t('settings separation label')}>\n <Input.Switch checked={settings.separation} onCheckedChange={(checked) => (settings.separation = !!checked)} />\n </SettingsValue>\n </>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { FilePlus } from '@phosphor-icons/react';\nimport React, { useCallback, useRef, useState } from 'react';\n\nimport { usePlugin, useIntent, LayoutAction, useResolvePlugin, parseFileManagerPlugin } from '@dxos/app-framework';\nimport { type EchoReactiveObject, create } from '@dxos/echo-schema';\nimport { FileType } from '@dxos/plugin-ipfs/types';\nimport { type CollectionType } from '@dxos/plugin-space/types';\nimport { getSpace } from '@dxos/react-client/echo';\nimport { Dialog, toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { Path } from '@dxos/react-ui-mosaic';\nimport { SearchList } from '@dxos/react-ui-searchlist';\nimport { type AddSectionPosition } from '@dxos/react-ui-stack';\nimport { getSize, mx } from '@dxos/react-ui-theme';\nimport { nonNullable } from '@dxos/util';\n\nimport { STACK_PLUGIN } from '../meta';\nimport { StackViewType, type StackPluginProvides } from '../types';\n\ntype AddSectionDialogProps = { path?: string; position: AddSectionPosition; collection: CollectionType };\n\nexport const dataHasAddSectionDialogProps = (data: any): data is { subject: AddSectionDialogProps } => {\n return (\n 'subject' in data &&\n typeof data.subject === 'object' &&\n !!data.subject &&\n 'position' in data.subject &&\n typeof data.subject.position === 'string' &&\n 'collection' in data.subject\n );\n};\n\nexport const AddSectionDialog = ({ path, position, collection }: AddSectionDialogProps) => {\n const { t } = useTranslation(STACK_PLUGIN);\n const stackPlugin = usePlugin<StackPluginProvides>(STACK_PLUGIN);\n const fileManagerPlugin = useResolvePlugin(parseFileManagerPlugin);\n const fileRef = useRef<HTMLInputElement | null>(null);\n const { dispatch } = useIntent();\n const space = getSpace(collection);\n const [pending, setPending] = useState<boolean>(false);\n const [uploadError, setUploadError] = useState<Error | undefined>();\n\n const handleAdd = useCallback(\n (sectionObject: EchoReactiveObject<any>) => {\n const index =\n position === 'beforeAll'\n ? 0\n : position === 'afterAll'\n ? collection.objects.length\n : collection.objects.filter(nonNullable).findIndex((section) => section.id === Path.last(path!));\n\n collection.objects.splice(index + (position === 'after' ? 1 : 0), 0, sectionObject);\n const stack = collection.views[StackViewType.typename];\n if (stack) {\n stack.sections[sectionObject.id] = {};\n }\n setPending(false);\n void dispatch?.({ action: LayoutAction.SET_LAYOUT, data: { element: 'dialog', state: false } });\n },\n [collection, path, position, dispatch],\n );\n\n const handleFileUpload =\n fileManagerPlugin?.provides.file.upload && space\n ? async (file: File) => {\n const filename = file.name.split('.')[0];\n try {\n const info = await fileManagerPlugin.provides.file.upload?.(file, space);\n if (info) {\n const obj = create(FileType, { type: file.type, name: filename, filename, cid: info.cid });\n handleAdd(obj);\n }\n } catch (err: any) {\n setUploadError(err);\n }\n }\n : undefined;\n\n return (\n <Dialog.Content>\n <Dialog.Title>{t(`add section ${position} dialog title`)}</Dialog.Title>\n <SearchList.Root label={t('add section input placeholder')}>\n <SearchList.Input placeholder={t('add section input placeholder')} classNames='pli-3' disabled={pending} />\n <SearchList.Content classNames='min-bs-24 bs-fit max-bs-64 overflow-auto' {...(pending && { inert: 'true' })}>\n {stackPlugin?.provides?.stack.creators?.map(({ id, icon: Icon, label: propsLabel, testId, intent }) => {\n const label = toLocalizedString(propsLabel, t);\n return (\n <SearchList.Item\n value={label}\n key={id}\n onSelect={async () => {\n setPending(true);\n const { data: nextSection } = (await dispatch({ ...intent, data: { space } })) ?? {};\n handleAdd(nextSection);\n }}\n classNames='flex items-center gap-2 pli-2'\n data-testid={testId}\n >\n {Icon && <Icon className={mx(getSize(4), 'shrink-0')} />}\n <span className='grow truncate'>{label}</span>\n </SearchList.Item>\n );\n })}\n {handleFileUpload && (\n <SearchList.Item\n value={t('upload file label')}\n classNames='flex items-center gap-2 pli-2'\n onSelect={() => fileRef.current?.click()}\n >\n <FilePlus />\n <span className='grow truncate'>{t('upload file label')}</span>\n </SearchList.Item>\n )}\n {uploadError && <div className='text-error-500'>{uploadError.message}</div>}\n </SearchList.Content>\n </SearchList.Root>\n {handleFileUpload && (\n <input\n type='file'\n className='sr-only'\n ref={fileRef}\n onChange={({ target: { files } }) => files && handleFileUpload(files[0])}\n />\n )}\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { translations as stackTranslations } from '@dxos/react-ui-stack';\n\nimport { STACK_PLUGIN } from './meta';\n\nexport default [\n {\n 'en-US': {\n [STACK_PLUGIN]: {\n 'plugin name': 'Stacks',\n 'settings separation label': 'Separate sections',\n 'add section beforeAll dialog title': 'Add a section to the start',\n 'add section afterAll dialog title': 'Add a section to the end',\n 'add section before dialog title': 'Add a section',\n 'add section after dialog title': 'Add a section',\n 'add section input placeholder': 'Find the type of section to add',\n 'upload file label': 'Add file',\n 'add section label': 'Add section',\n },\n },\n },\n ...stackTranslations,\n];\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { StackPlugin } from './StackPlugin';\n\nexport default StackPlugin;\n\nexport * from './types';\n\nexport * from './StackPlugin';\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;AAIA,OAAOA,YAAW;AAGlB,SAASC,UAAAA,eAAuC;AAChD,SAASC,yBAAyB;AAClC,SAASC,sBAAsB;AAC/B,SAASC,wBAAwB;AACjC,SAASC,YAAY;AACrB,SAASC,aAAaC,yBAAyBC,gCAAgC;;;ACR/E,OAAOC,YAAW;;;ACAlB,OAAOC,WAAW;AAElB,SAASC,qBAAqB;AAC9B,SAASC,OAAOC,sBAAsB;AAK/B,IAAMC,gBAAgB,CAAC,EAAEC,SAAQ,MAAoC;AAC1E,QAAM,EAAEC,EAAC,IAAKC,eAAeC,YAAAA;AAE7B,SACE,sBAAA,cAAA,MAAA,UAAA,MACE,sBAAA,cAACC,eAAAA;IAAcC,OAAOJ,EAAE,2BAAA;KACtB,sBAAA,cAACK,MAAMC,QAAM;IAACC,SAASR,SAASS;IAAYC,iBAAiB,CAACF,YAAaR,SAASS,aAAa,CAAC,CAACD;;AAI3G;;;AClBA,SAASG,gBAAgB;AACzB,OAAOC,UAASC,aAAaC,QAAQC,gBAAgB;AAErD,SAASC,WAAWC,WAAWC,cAAcC,kBAAkBC,8BAA8B;AAC7F,SAAkCC,cAAc;AAChD,SAASC,gBAAgB;AAEzB,SAASC,gBAAgB;AACzB,SAASC,QAAQC,mBAAmBC,kBAAAA,uBAAsB;AAC1D,SAASC,YAAY;AACrB,SAASC,kBAAkB;AAE3B,SAASC,SAASC,UAAU;AAC5B,SAASC,mBAAmB;AAOrB,IAAMC,+BAA+B,CAACC,SAAAA;AAC3C,SACE,aAAaA,QACb,OAAOA,KAAKC,YAAY,YACxB,CAAC,CAACD,KAAKC,WACP,cAAcD,KAAKC,WACnB,OAAOD,KAAKC,QAAQC,aAAa,YACjC,gBAAgBF,KAAKC;AAEzB;AAEO,IAAME,mBAAmB,CAAC,EAAEC,MAAMF,UAAUG,WAAU,MAAyB;A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AK;gBAAOoB,WAAU;iBACzB,gBAAAlB,OAAA,cAACc,WAAAA;gBACC1C,IAAIA,MAAM2C,iBAAiBZ,OAAAA;gBAC3Ba,YAAYb;gBACZ3C,YAAYH,SAASqB,OAAOlB;oBAG9B;YACN,KAAK,YAAY;AACf,qBAAOgC,KAAKrB,WAAWP,aAAKQ,KAAK,gBAAA4B,OAAA,cAACmB,eAAAA;gBAAc9D,UAAUA,SAASqB;mBAAa;YAClF;YACA;AACE,qBAAO;UACX;QACF;MACF;MACAF,OAAOf;IACT;EACF;AACF;;;AKvGA,IAAA,cAAe2D;",
|
|
6
|
+
"names": ["React", "create", "LocalStorageStore", "CollectionType", "fullyQualifiedId", "Main", "baseSurface", "topbarBlockPaddingStart", "bottombarBlockPaddingEnd", "React", "React", "SettingsValue", "Input", "useTranslation", "StackSettings", "settings", "t", "useTranslation", "STACK_PLUGIN", "SettingsValue", "label", "Input", "Switch", "checked", "separation", "onCheckedChange", "FilePlus", "React", "useCallback", "useRef", "useState", "usePlugin", "useIntent", "LayoutAction", "useResolvePlugin", "parseFileManagerPlugin", "create", "FileType", "getSpace", "Dialog", "toLocalizedString", "useTranslation", "Path", "SearchList", "getSize", "mx", "nonNullable", "dataHasAddSectionDialogProps", "data", "subject", "position", "AddSectionDialog", "path", "collection", "t", "useTranslation", "STACK_PLUGIN", "stackPlugin", "usePlugin", "fileManagerPlugin", "useResolvePlugin", "parseFileManagerPlugin", "fileRef", "useRef", "dispatch", "useIntent", "space", "getSpace", "pending", "setPending", "useState", "uploadError", "setUploadError", "handleAdd", "useCallback", "sectionObject", "index", "objects", "length", "filter", "nonNullable", "findIndex", "section", "id", "Path", "last", "splice", "stack", "views", "StackViewType", "typename", "sections", "action", "LayoutAction", "SET_LAYOUT", "element", "state", "handleFileUpload", "provides", "file", "upload", "filename", "name", "split", "info", "obj", "create", "FileType", "type", "cid", "err", "undefined", "React", "Dialog", "Content", "Title", "SearchList", "Root", "label", "Input", "placeholder", "classNames", "disabled", "inert", "creators", "map", "icon", "Icon", "propsLabel", "testId", "intent", "toLocalizedString", "Item", "value", "key", "onSelect", "nextSection", "data-testid", "className", "mx", "getSize", "span", "current", "click", "FilePlus", "div", "message", "input", "ref", "onChange", "target", "files", "StackMain", "React", "lazy", "translations", "stackTranslations", "STACK_PLUGIN", "stackTranslations", "StackPlugin", "settings", "LocalStorageStore", "STACK_PLUGIN", "separation", "stackState", "create", "creators", "meta", "ready", "plugins", "prop", "key", "type", "bool", "plugin", "id", "Array", "isArray", "provides", "stack", "push", "values", "metadata", "records", "StackViewType", "typename", "placeholder", "ns", "icon", "SECTION_IDENTIFIER", "parse", "section", "object", "label", "title", "data", "translations", "echo", "schema", "surface", "component", "role", "dataHasAddSectionDialogProps", "React", "AddSectionDialog", "subject", "primary", "active", "undefined", "CollectionType", "Main", "Content", "bounce", "classNames", "baseSurface", "topbarBlockPaddingStart", "bottombarBlockPaddingEnd", "StackMain", "fullyQualifiedId", "collection", "div", "className", "StackSettings", "StackPlugin"]
|
|
7
7
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"inputs":{"packages/plugins/plugin-stack/src/meta.tsx":{"bytes":2015,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-stack/src/components/StackSettings.tsx":{"bytes":2578,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.tsx","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-stack/src/types/stack.ts":{"bytes":3077,"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-stack/src/types/types.ts":{"bytes":2031,"imports":[],"format":"esm"},"packages/plugins/plugin-stack/src/types/index.ts":{"bytes":581,"imports":[{"path":"packages/plugins/plugin-stack/src/types/stack.ts","kind":"import-statement","original":"./stack"},{"path":"packages/plugins/plugin-stack/src/types/types.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/AddSectionDialog.tsx":{"bytes":18438,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-ipfs/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","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/react-ui-searchlist","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.tsx","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/AddSection.tsx":{"bytes":10461,"imports":[{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.tsx","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/StackMain.tsx":{"bytes":26459,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","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/react-ui-stack","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/components/AddSection.tsx","kind":"import-statement","original":"./AddSection"},{"path":"packages/plugins/plugin-stack/src/meta.tsx","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/index.ts":{"bytes":1140,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/components/StackSettings.tsx","kind":"import-statement","original":"./StackSettings"},{"path":"packages/plugins/plugin-stack/src/components/AddSectionDialog.tsx","kind":"import-statement","original":"./AddSectionDialog"},{"path":"packages/plugins/plugin-stack/src/components/StackMain.tsx","kind":"dynamic-import","original":"./StackMain"}],"format":"esm"},"packages/plugins/plugin-stack/src/translations.ts":{"bytes":2731,"imports":[{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.tsx","kind":"import-statement","original":"./meta"}],"format":"esm"},"packages/plugins/plugin-stack/src/StackPlugin.tsx":{"bytes":14740,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/local-storage","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-stack/src/meta.tsx","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-stack/src/translations.ts","kind":"import-statement","original":"./translations"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-stack/src/index.ts":{"bytes":854,"imports":[{"path":"packages/plugins/plugin-stack/src/StackPlugin.tsx","kind":"import-statement","original":"./StackPlugin"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"./types"},{"path":"packages/plugins/plugin-stack/src/StackPlugin.tsx","kind":"import-statement","original":"./StackPlugin"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-stack/dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":19831},"packages/plugins/plugin-stack/dist/lib/browser/index.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-AYDYMPJK.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-R5KXWF2W.mjs","kind":"import-statement"},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/local-storage","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-ipfs/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","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/react-ui-searchlist","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/dist/lib/browser/StackMain-XRQRNZ4I.mjs","kind":"dynamic-import"},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true}],"exports":["SectionSchema","StackPlugin","StackViewType","default"],"entryPoint":"packages/plugins/plugin-stack/src/index.ts","inputs":{"packages/plugins/plugin-stack/src/StackPlugin.tsx":{"bytesInOutput":3688},"packages/plugins/plugin-stack/src/components/index.ts":{"bytesInOutput":99},"packages/plugins/plugin-stack/src/components/StackSettings.tsx":{"bytesInOutput":554},"packages/plugins/plugin-stack/src/components/AddSectionDialog.tsx":{"bytesInOutput":4643},"packages/plugins/plugin-stack/src/translations.ts":{"bytesInOutput":710},"packages/plugins/plugin-stack/src/index.ts":{"bytesInOutput":31}},"bytes":10474},"packages/plugins/plugin-stack/dist/lib/browser/meta.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/plugins/plugin-stack/dist/lib/browser/meta.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-AYDYMPJK.mjs","kind":"import-statement"}],"exports":["SECTION_IDENTIFIER","STACK_PLUGIN","default"],"entryPoint":"packages/plugins/plugin-stack/src/meta.tsx","inputs":{},"bytes":203},"packages/plugins/plugin-stack/dist/lib/browser/types/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/plugins/plugin-stack/dist/lib/browser/types/index.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-R5KXWF2W.mjs","kind":"import-statement"}],"exports":["SectionSchema","StackViewType"],"entryPoint":"packages/plugins/plugin-stack/src/types/index.ts","inputs":{},"bytes":154},"packages/plugins/plugin-stack/dist/lib/browser/StackMain-XRQRNZ4I.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":19143},"packages/plugins/plugin-stack/dist/lib/browser/StackMain-XRQRNZ4I.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-AYDYMPJK.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-R5KXWF2W.mjs","kind":"import-statement"},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","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/react-ui-stack","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-stack/src/components/StackMain.tsx","inputs":{"packages/plugins/plugin-stack/src/components/StackMain.tsx":{"bytesInOutput":6206},"packages/plugins/plugin-stack/src/components/AddSection.tsx":{"bytesInOutput":2546}},"bytes":9166},"packages/plugins/plugin-stack/dist/lib/browser/chunk-AYDYMPJK.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":962},"packages/plugins/plugin-stack/dist/lib/browser/chunk-AYDYMPJK.mjs":{"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true}],"exports":["SECTION_IDENTIFIER","STACK_PLUGIN","meta_default"],"inputs":{"packages/plugins/plugin-stack/src/meta.tsx":{"bytesInOutput":470}},"bytes":626},"packages/plugins/plugin-stack/dist/lib/browser/chunk-R5KXWF2W.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1475},"packages/plugins/plugin-stack/dist/lib/browser/chunk-R5KXWF2W.mjs":{"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"exports":["SectionSchema","StackViewType"],"inputs":{"packages/plugins/plugin-stack/src/types/stack.ts":{"bytesInOutput":463},"packages/plugins/plugin-stack/src/types/index.ts":{"bytesInOutput":0}},"bytes":605}}}
|
|
1
|
+
{"inputs":{"packages/plugins/plugin-stack/src/meta.ts":{"bytes":1525,"imports":[],"format":"esm"},"packages/plugins/plugin-stack/src/components/StackSettings.tsx":{"bytes":2578,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-stack/src/types/stack.ts":{"bytes":3281,"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-stack/src/types/types.ts":{"bytes":2031,"imports":[],"format":"esm"},"packages/plugins/plugin-stack/src/types/index.ts":{"bytes":581,"imports":[{"path":"packages/plugins/plugin-stack/src/types/stack.ts","kind":"import-statement","original":"./stack"},{"path":"packages/plugins/plugin-stack/src/types/types.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/AddSectionDialog.tsx":{"bytes":18438,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-ipfs/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","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/react-ui-searchlist","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/AddSection.tsx":{"bytes":10461,"imports":[{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/StackMain.tsx":{"bytes":27132,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-attention","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/components/AddSection.tsx","kind":"import-statement","original":"./AddSection"},{"path":"packages/plugins/plugin-stack/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"../types"}],"format":"esm"},"packages/plugins/plugin-stack/src/components/index.ts":{"bytes":1140,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/components/StackSettings.tsx","kind":"import-statement","original":"./StackSettings"},{"path":"packages/plugins/plugin-stack/src/components/AddSectionDialog.tsx","kind":"import-statement","original":"./AddSectionDialog"},{"path":"packages/plugins/plugin-stack/src/components/StackMain.tsx","kind":"dynamic-import","original":"./StackMain"}],"format":"esm"},"packages/plugins/plugin-stack/src/translations.ts":{"bytes":2731,"imports":[{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"packages/plugins/plugin-stack/src/StackPlugin.tsx":{"bytes":15800,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/local-storage","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-stack/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-stack/src/translations.ts","kind":"import-statement","original":"./translations"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"./types"}],"format":"esm"},"packages/plugins/plugin-stack/src/index.ts":{"bytes":854,"imports":[{"path":"packages/plugins/plugin-stack/src/StackPlugin.tsx","kind":"import-statement","original":"./StackPlugin"},{"path":"packages/plugins/plugin-stack/src/types/index.ts","kind":"import-statement","original":"./types"},{"path":"packages/plugins/plugin-stack/src/StackPlugin.tsx","kind":"import-statement","original":"./StackPlugin"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-stack/dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":20309},"packages/plugins/plugin-stack/dist/lib/browser/index.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-ONAKM24Z.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-BA6WV7BZ.mjs","kind":"import-statement"},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/local-storage","kind":"import-statement","external":true},{"path":"@dxos/plugin-space/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/plugin-settings","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-ipfs/types","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","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/react-ui-searchlist","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-stack/dist/lib/browser/StackMain-JA6SVPH5.mjs","kind":"dynamic-import"},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true}],"exports":["SectionSchema","StackPlugin","StackViewType","default"],"entryPoint":"packages/plugins/plugin-stack/src/index.ts","inputs":{"packages/plugins/plugin-stack/src/StackPlugin.tsx":{"bytesInOutput":3777},"packages/plugins/plugin-stack/src/components/index.ts":{"bytesInOutput":99},"packages/plugins/plugin-stack/src/components/StackSettings.tsx":{"bytesInOutput":554},"packages/plugins/plugin-stack/src/components/AddSectionDialog.tsx":{"bytesInOutput":4643},"packages/plugins/plugin-stack/src/translations.ts":{"bytesInOutput":710},"packages/plugins/plugin-stack/src/index.ts":{"bytesInOutput":31}},"bytes":10563},"packages/plugins/plugin-stack/dist/lib/browser/meta.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/plugins/plugin-stack/dist/lib/browser/meta.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-ONAKM24Z.mjs","kind":"import-statement"}],"exports":["SECTION_IDENTIFIER","STACK_PLUGIN","default"],"entryPoint":"packages/plugins/plugin-stack/src/meta.ts","inputs":{},"bytes":203},"packages/plugins/plugin-stack/dist/lib/browser/types/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"packages/plugins/plugin-stack/dist/lib/browser/types/index.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-BA6WV7BZ.mjs","kind":"import-statement"}],"exports":["SectionSchema","StackViewType"],"entryPoint":"packages/plugins/plugin-stack/src/types/index.ts","inputs":{},"bytes":154},"packages/plugins/plugin-stack/dist/lib/browser/StackMain-JA6SVPH5.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":19553},"packages/plugins/plugin-stack/dist/lib/browser/StackMain-JA6SVPH5.mjs":{"imports":[{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-ONAKM24Z.mjs","kind":"import-statement"},{"path":"packages/plugins/plugin-stack/dist/lib/browser/chunk-BA6WV7BZ.mjs","kind":"import-statement"},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/echo-schema","kind":"import-statement","external":true},{"path":"@dxos/plugin-graph","kind":"import-statement","external":true},{"path":"@dxos/plugin-space","kind":"import-statement","external":true},{"path":"@dxos/react-client/echo","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-attention","kind":"import-statement","external":true},{"path":"@dxos/react-ui-mosaic","kind":"import-statement","external":true},{"path":"@dxos/react-ui-stack","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true},{"path":"@fluentui/react-tabster","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"packages/plugins/plugin-stack/src/components/StackMain.tsx","inputs":{"packages/plugins/plugin-stack/src/components/StackMain.tsx":{"bytesInOutput":6372},"packages/plugins/plugin-stack/src/components/AddSection.tsx":{"bytesInOutput":2546}},"bytes":9332},"packages/plugins/plugin-stack/dist/lib/browser/chunk-ONAKM24Z.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":710},"packages/plugins/plugin-stack/dist/lib/browser/chunk-ONAKM24Z.mjs":{"imports":[],"exports":["SECTION_IDENTIFIER","STACK_PLUGIN","meta_default"],"inputs":{"packages/plugins/plugin-stack/src/meta.ts":{"bytesInOutput":299}},"bytes":454},"packages/plugins/plugin-stack/dist/lib/browser/chunk-BA6WV7BZ.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1567},"packages/plugins/plugin-stack/dist/lib/browser/chunk-BA6WV7BZ.mjs":{"imports":[{"path":"@dxos/echo-schema","kind":"import-statement","external":true}],"exports":["SectionSchema","StackViewType"],"inputs":{"packages/plugins/plugin-stack/src/types/stack.ts":{"bytesInOutput":515},"packages/plugins/plugin-stack/src/types/index.ts":{"bytesInOutput":0}},"bytes":657}}}
|