@dxos/react-ui-mosaic 0.3.3-main.3ce60d4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +8 -0
- package/README.md +45 -0
- package/dist/lib/browser/index.mjs +596 -0
- package/dist/lib/browser/index.mjs.map +7 -0
- package/dist/lib/browser/meta.json +1 -0
- package/dist/types/src/index.d.ts +2 -0
- package/dist/types/src/index.d.ts.map +1 -0
- package/dist/types/src/mosaic/Container.d.ts +65 -0
- package/dist/types/src/mosaic/Container.d.ts.map +1 -0
- package/dist/types/src/mosaic/Debug.d.ts +9 -0
- package/dist/types/src/mosaic/Debug.d.ts.map +1 -0
- package/dist/types/src/mosaic/DefaultComponent.d.ts +4 -0
- package/dist/types/src/mosaic/DefaultComponent.d.ts.map +1 -0
- package/dist/types/src/mosaic/DragOverlay.d.ts +11 -0
- package/dist/types/src/mosaic/DragOverlay.d.ts.map +1 -0
- package/dist/types/src/mosaic/Mosaic.d.ts +32 -0
- package/dist/types/src/mosaic/Mosaic.d.ts.map +1 -0
- package/dist/types/src/mosaic/Root.d.ts +24 -0
- package/dist/types/src/mosaic/Root.d.ts.map +1 -0
- package/dist/types/src/mosaic/SortableContext.d.ts +14 -0
- package/dist/types/src/mosaic/SortableContext.d.ts.map +1 -0
- package/dist/types/src/mosaic/Tile.d.ts +41 -0
- package/dist/types/src/mosaic/Tile.d.ts.map +1 -0
- package/dist/types/src/mosaic/hooks/index.d.ts +5 -0
- package/dist/types/src/mosaic/hooks/index.d.ts.map +1 -0
- package/dist/types/src/mosaic/hooks/useContainer.d.ts +4 -0
- package/dist/types/src/mosaic/hooks/useContainer.d.ts.map +1 -0
- package/dist/types/src/mosaic/hooks/useItemsWithPreview.d.ts +10 -0
- package/dist/types/src/mosaic/hooks/useItemsWithPreview.d.ts.map +1 -0
- package/dist/types/src/mosaic/hooks/useMosaic.d.ts +2 -0
- package/dist/types/src/mosaic/hooks/useMosaic.d.ts.map +1 -0
- package/dist/types/src/mosaic/hooks/useSortedItems.d.ts +6 -0
- package/dist/types/src/mosaic/hooks/useSortedItems.d.ts.map +1 -0
- package/dist/types/src/mosaic/index.d.ts +5 -0
- package/dist/types/src/mosaic/index.d.ts.map +1 -0
- package/dist/types/src/mosaic/types.d.ts +9 -0
- package/dist/types/src/mosaic/types.d.ts.map +1 -0
- package/dist/types/src/mosaic/util/data.d.ts +3 -0
- package/dist/types/src/mosaic/util/data.d.ts.map +1 -0
- package/dist/types/src/mosaic/util/index.d.ts +4 -0
- package/dist/types/src/mosaic/util/index.d.ts.map +1 -0
- package/dist/types/src/mosaic/util/path.d.ts +14 -0
- package/dist/types/src/mosaic/util/path.d.ts.map +1 -0
- package/dist/types/src/mosaic/util/path.test.d.ts +2 -0
- package/dist/types/src/mosaic/util/path.test.d.ts.map +1 -0
- package/dist/types/src/mosaic/util/styles.d.ts +3 -0
- package/dist/types/src/mosaic/util/styles.d.ts.map +1 -0
- package/dist/types/src/testing/Cards.d.ts +10 -0
- package/dist/types/src/testing/Cards.d.ts.map +1 -0
- package/dist/types/src/testing/decorators.d.ts +4 -0
- package/dist/types/src/testing/decorators.d.ts.map +1 -0
- package/dist/types/src/testing/generator.d.ts +43 -0
- package/dist/types/src/testing/generator.d.ts.map +1 -0
- package/dist/types/src/testing/index.d.ts +5 -0
- package/dist/types/src/testing/index.d.ts.map +1 -0
- package/dist/types/src/testing/next-fractional-index.d.ts +5 -0
- package/dist/types/src/testing/next-fractional-index.d.ts.map +1 -0
- package/dist/types/src/views/Demo/Demo.stories.d.ts +13 -0
- package/dist/types/src/views/Demo/Demo.stories.d.ts.map +1 -0
- package/dist/types/src/views/Demo/Echo.stories.d.ts +12 -0
- package/dist/types/src/views/Demo/Echo.stories.d.ts.map +1 -0
- package/dist/types/src/views/Grid/Grid.d.ts +30 -0
- package/dist/types/src/views/Grid/Grid.d.ts.map +1 -0
- package/dist/types/src/views/Grid/Grid.stories.d.ts +13 -0
- package/dist/types/src/views/Grid/Grid.stories.d.ts.map +1 -0
- package/dist/types/src/views/Grid/index.d.ts +3 -0
- package/dist/types/src/views/Grid/index.d.ts.map +1 -0
- package/dist/types/src/views/Grid/layout.d.ts +27 -0
- package/dist/types/src/views/Grid/layout.d.ts.map +1 -0
- package/dist/types/src/views/Grid/testing.d.ts +10 -0
- package/dist/types/src/views/Grid/testing.d.ts.map +1 -0
- package/dist/types/src/views/Kanban/Echo.stories.d.ts +18 -0
- package/dist/types/src/views/Kanban/Echo.stories.d.ts.map +1 -0
- package/dist/types/src/views/Kanban/Kanban.d.ts +11 -0
- package/dist/types/src/views/Kanban/Kanban.d.ts.map +1 -0
- package/dist/types/src/views/Kanban/Kanban.stories.d.ts +28 -0
- package/dist/types/src/views/Kanban/Kanban.stories.d.ts.map +1 -0
- package/dist/types/src/views/Kanban/index.d.ts +2 -0
- package/dist/types/src/views/Kanban/index.d.ts.map +1 -0
- package/dist/types/src/views/Kanban/testing.d.ts +20 -0
- package/dist/types/src/views/Kanban/testing.d.ts.map +1 -0
- package/dist/types/src/views/Stack/Columns.stories.d.ts +34 -0
- package/dist/types/src/views/Stack/Columns.stories.d.ts.map +1 -0
- package/dist/types/src/views/Stack/Stack.d.ts +9 -0
- package/dist/types/src/views/Stack/Stack.d.ts.map +1 -0
- package/dist/types/src/views/Stack/Stack.stories.d.ts +39 -0
- package/dist/types/src/views/Stack/Stack.stories.d.ts.map +1 -0
- package/dist/types/src/views/Stack/index.d.ts +2 -0
- package/dist/types/src/views/Stack/index.d.ts.map +1 -0
- package/dist/types/src/views/Stack/testing.d.ts +9 -0
- package/dist/types/src/views/Stack/testing.d.ts.map +1 -0
- package/dist/types/src/views/Tree/Graph.stories.d.ts +21 -0
- package/dist/types/src/views/Tree/Graph.stories.d.ts.map +1 -0
- package/dist/types/src/views/Tree/Tree.d.ts +13 -0
- package/dist/types/src/views/Tree/Tree.d.ts.map +1 -0
- package/dist/types/src/views/Tree/Tree.stories.d.ts +41 -0
- package/dist/types/src/views/Tree/Tree.stories.d.ts.map +1 -0
- package/dist/types/src/views/Tree/index.d.ts +2 -0
- package/dist/types/src/views/Tree/index.d.ts.map +1 -0
- package/dist/types/src/views/Tree/testing.d.ts +15 -0
- package/dist/types/src/views/Tree/testing.d.ts.map +1 -0
- package/dist/types/src/views/index.d.ts +5 -0
- package/dist/types/src/views/index.d.ts.map +1 -0
- package/package.json +67 -0
- package/src/index.ts +5 -0
- package/src/mosaic/Container.tsx +137 -0
- package/src/mosaic/Debug.tsx +24 -0
- package/src/mosaic/DefaultComponent.tsx +26 -0
- package/src/mosaic/DragOverlay.tsx +136 -0
- package/src/mosaic/Mosaic.ts +84 -0
- package/src/mosaic/Root.tsx +255 -0
- package/src/mosaic/SortableContext.tsx +60 -0
- package/src/mosaic/Tile.tsx +189 -0
- package/src/mosaic/hooks/index.ts +8 -0
- package/src/mosaic/hooks/useContainer.ts +16 -0
- package/src/mosaic/hooks/useItemsWithPreview.ts +64 -0
- package/src/mosaic/hooks/useMosaic.ts +11 -0
- package/src/mosaic/hooks/useSortedItems.ts +14 -0
- package/src/mosaic/index.ts +9 -0
- package/src/mosaic/types.ts +13 -0
- package/src/mosaic/util/data.ts +19 -0
- package/src/mosaic/util/index.ts +7 -0
- package/src/mosaic/util/path.test.ts +26 -0
- package/src/mosaic/util/path.ts +21 -0
- package/src/mosaic/util/styles.ts +10 -0
- package/src/testing/Cards.tsx +88 -0
- package/src/testing/decorators.tsx +20 -0
- package/src/testing/generator.ts +135 -0
- package/src/testing/index.ts +9 -0
- package/src/testing/next-fractional-index.ts +36 -0
- package/src/views/Demo/Demo.stories.tsx +79 -0
- package/src/views/Demo/Echo.stories.tsx +74 -0
- package/src/views/Grid/Grid.stories.tsx +48 -0
- package/src/views/Grid/Grid.tsx +248 -0
- package/src/views/Grid/index.ts +7 -0
- package/src/views/Grid/layout.ts +42 -0
- package/src/views/Grid/testing.tsx +91 -0
- package/src/views/Kanban/Echo.stories.tsx +67 -0
- package/src/views/Kanban/Kanban.stories.tsx +48 -0
- package/src/views/Kanban/Kanban.tsx +139 -0
- package/src/views/Kanban/index.ts +5 -0
- package/src/views/Kanban/testing.tsx +231 -0
- package/src/views/Stack/Columns.stories.tsx +61 -0
- package/src/views/Stack/Stack.stories.tsx +62 -0
- package/src/views/Stack/Stack.tsx +58 -0
- package/src/views/Stack/index.ts +5 -0
- package/src/views/Stack/testing.tsx +77 -0
- package/src/views/Tree/Graph.stories.tsx +36 -0
- package/src/views/Tree/Tree.stories.tsx +92 -0
- package/src/views/Tree/Tree.tsx +128 -0
- package/src/views/Tree/index.ts +5 -0
- package/src/views/Tree/testing.tsx +156 -0
- package/src/views/index.ts +8 -0
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type MosaicTileComponent } from '../mosaic';
|
|
2
|
+
export type SimpleCardProps = {
|
|
3
|
+
id: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
body?: string;
|
|
6
|
+
image?: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const SimpleCard: MosaicTileComponent<SimpleCardProps>;
|
|
9
|
+
export declare const ComplexCard: MosaicTileComponent<SimpleCardProps>;
|
|
10
|
+
//# sourceMappingURL=Cards.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Cards.d.ts","sourceRoot":"","sources":["../../../../src/testing/Cards.tsx"],"names":[],"mappings":"AASA,OAAO,EAAU,KAAK,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAK7D,MAAM,MAAM,eAAe,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAE5F,eAAO,MAAM,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAgC3D,CAAC;AAIF,eAAO,MAAM,WAAW,EAAE,mBAAmB,CAAC,eAAe,CAiC5D,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"decorators.d.ts","sourceRoot":"","sources":["../../../../src/testing/decorators.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAMtD,eAAO,MAAM,mBAAmB,eAAgB,MAAM,KAAG,kBAAkB,aAAa,CAQvF,CAAC"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { Schema as SchemaType } from '@dxos/client/echo';
|
|
2
|
+
import { type TypedObject } from '@dxos/echo-schema';
|
|
3
|
+
export declare const range: <T>(fn: (i: number) => T | undefined, length: number) => T[];
|
|
4
|
+
export type TestItem = {
|
|
5
|
+
id: string;
|
|
6
|
+
type: string;
|
|
7
|
+
} & Record<string, any>;
|
|
8
|
+
type ObjectDataGenerator = {
|
|
9
|
+
createSchema?: () => SchemaType;
|
|
10
|
+
createData: () => any;
|
|
11
|
+
};
|
|
12
|
+
type ObjectFactory<T extends TypedObject> = {
|
|
13
|
+
schema?: SchemaType;
|
|
14
|
+
createObject: () => T;
|
|
15
|
+
};
|
|
16
|
+
type ObjectFactoryMap = {
|
|
17
|
+
[type: string]: ObjectFactory<any>;
|
|
18
|
+
};
|
|
19
|
+
export declare const Status: string[];
|
|
20
|
+
export declare const Priority: number[];
|
|
21
|
+
export declare const defaultGenerators: {
|
|
22
|
+
[type: string]: ObjectDataGenerator;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* Typed object generator.
|
|
26
|
+
*/
|
|
27
|
+
export declare class TestObjectGenerator {
|
|
28
|
+
readonly factories: ObjectFactoryMap;
|
|
29
|
+
constructor({ types, factories }?: {
|
|
30
|
+
types?: string[];
|
|
31
|
+
factories?: ObjectFactoryMap;
|
|
32
|
+
});
|
|
33
|
+
get schema(): SchemaType[];
|
|
34
|
+
createObject({ types }?: {
|
|
35
|
+
types?: string[];
|
|
36
|
+
}): any;
|
|
37
|
+
createObjects({ types, length }: {
|
|
38
|
+
types?: string[];
|
|
39
|
+
length: number;
|
|
40
|
+
}): any[];
|
|
41
|
+
}
|
|
42
|
+
export {};
|
|
43
|
+
//# sourceMappingURL=generator.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["../../../../src/testing/generator.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,EAAW,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAG9D,eAAO,MAAM,KAAK,cAAe,MAAM,4BAA4B,MAAM,QAG9C,CAAC;AAG5B,MAAM,MAAM,QAAQ,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;AAE1E,KAAK,mBAAmB,GAAG;IACzB,YAAY,CAAC,EAAE,MAAM,UAAU,CAAC;IAChC,UAAU,EAAE,MAAM,GAAG,CAAC;CACvB,CAAC;AAEF,KAAK,aAAa,CAAC,CAAC,SAAS,WAAW,IAAI;IAC1C,MAAM,CAAC,EAAE,UAAU,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC,CAAC;CACvB,CAAC;AAEF,KAAK,gBAAgB,GAAG;IAAE,CAAC,IAAI,EAAE,MAAM,GAAG,aAAa,CAAC,GAAG,CAAC,CAAA;CAAE,CAAC;AAW/D,eAAO,MAAM,MAAM,UAAgC,CAAC;AACpD,eAAO,MAAM,QAAQ,UAAkB,CAAC;AAExC,eAAO,MAAM,iBAAiB,EAAE;IAAE,CAAC,IAAI,EAAE,MAAM,GAAG,mBAAmB,CAAA;CA6CpE,CAAC;AAEF;;GAEG;AACH,qBAAa,mBAAmB;IAC9B,SAAgB,SAAS,EAAE,gBAAgB,CAAC;gBAEhC,EAAE,KAAK,EAAE,SAAS,EAAE,GAAE;QAAE,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;QAAC,SAAS,CAAC,EAAE,gBAAgB,CAAA;KAAO;IASzF,IAAI,MAAM,IAAI,UAAU,EAAE,CAEzB;IAED,YAAY,CAAC,EAAE,KAAK,EAAE,GAAE;QAAE,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;KAAO;IAMjD,aAAa,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,EAAE;QAAE,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE;CAGtE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/testing/index.ts"],"names":[],"mappings":"AAIA,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,yBAAyB,CAAC;AAExC,cAAc,SAAS,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type UniqueIdentifier } from '@dnd-kit/core';
|
|
2
|
+
import { type Node } from '@braneframe/plugin-graph';
|
|
3
|
+
export declare const nextRearrangeIndex: (nodes: Node[], activeId: UniqueIdentifier, overId?: UniqueIdentifier) => string | null;
|
|
4
|
+
export declare const nextCopyIndex: (nodes: Node[], overId?: UniqueIdentifier) => string;
|
|
5
|
+
//# sourceMappingURL=next-fractional-index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-fractional-index.d.ts","sourceRoot":"","sources":["../../../../src/testing/next-fractional-index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAGtD,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,0BAA0B,CAAC;AAErD,eAAO,MAAM,kBAAkB,UAAW,IAAI,EAAE,YAAY,gBAAgB,WAAW,gBAAgB,kBAYtG,CAAC;AAEF,eAAO,MAAM,aAAa,UAAW,IAAI,EAAE,WAAW,gBAAgB,WAYrE,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import '@dxosTheme';
|
|
2
|
+
declare const _default: {
|
|
3
|
+
title: string;
|
|
4
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
5
|
+
parameters: {
|
|
6
|
+
layout: string;
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
export default _default;
|
|
10
|
+
export declare const Default: () => JSX.Element;
|
|
11
|
+
export declare const Tree: () => JSX.Element;
|
|
12
|
+
export declare const Kanban: () => JSX.Element;
|
|
13
|
+
//# sourceMappingURL=Demo.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Demo.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Demo/Demo.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;;;;;;;;AAcpB,wBAME;AAKF,eAAO,MAAM,OAAO,mBAenB,CAAC;AAEF,eAAO,MAAM,IAAI,mBAehB,CAAC;AAEF,eAAO,MAAM,MAAM,mBAelB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type PublicKey } from '@dxos/react-client';
|
|
3
|
+
declare const _default: {
|
|
4
|
+
title: string;
|
|
5
|
+
render: React.FC<{
|
|
6
|
+
spaceKey: PublicKey;
|
|
7
|
+
}>;
|
|
8
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
9
|
+
};
|
|
10
|
+
export default _default;
|
|
11
|
+
export declare const ECHO: {};
|
|
12
|
+
//# sourceMappingURL=Echo.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Echo.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Demo/Echo.stories.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAEvC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;;;;;;;;AAmCpD,wBA2BE;AAIF,eAAO,MAAM,IAAI,IAAK,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import '@dxosTheme';
|
|
2
|
+
import { type Dimension, type Position, type Size } from './layout';
|
|
3
|
+
import { type MosaicContainerProps, type MosaicDataItem } from '../../mosaic';
|
|
4
|
+
type ControlledSelection = {
|
|
5
|
+
selected?: string;
|
|
6
|
+
onSelect?: (id: string) => void;
|
|
7
|
+
};
|
|
8
|
+
type GridOptions = {
|
|
9
|
+
size: Size;
|
|
10
|
+
cellBounds: Dimension;
|
|
11
|
+
spacing?: number;
|
|
12
|
+
};
|
|
13
|
+
export type GridLayout = {
|
|
14
|
+
[id: string]: Position;
|
|
15
|
+
};
|
|
16
|
+
export type GridProps<TData extends MosaicDataItem = MosaicDataItem> = MosaicContainerProps<TData, Position> & ControlledSelection & {
|
|
17
|
+
items?: TData[];
|
|
18
|
+
layout?: GridLayout;
|
|
19
|
+
options?: Partial<GridOptions>;
|
|
20
|
+
margin?: boolean;
|
|
21
|
+
square?: boolean;
|
|
22
|
+
debug?: boolean;
|
|
23
|
+
onCreate?: (position: Position) => void;
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* Grid content.
|
|
27
|
+
*/
|
|
28
|
+
export declare const Grid: ({ id, items, layout, options: opts, margin, square, debug, selected: controlledSelected, Component, className, onDrop, onSelect, onCreate, }: GridProps) => JSX.Element;
|
|
29
|
+
export {};
|
|
30
|
+
//# sourceMappingURL=Grid.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Grid.d.ts","sourceRoot":"","sources":["../../../../../src/views/Grid/Grid.tsx"],"names":[],"mappings":"AAIA,OAAO,YAAY,CAAC;AAWpB,OAAO,EAML,KAAK,SAAS,EACd,KAAK,QAAQ,EACb,KAAK,IAAI,EACV,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,KAAK,oBAAoB,EAAE,KAAK,cAAc,EAA2B,MAAM,cAAc,CAAC;AAOvG,KAAK,mBAAmB,GAAG;IACzB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;CACjC,CAAC;AAMF,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,IAAI,CAAC;IACX,UAAU,EAAE,SAAS,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAYF,MAAM,MAAM,UAAU,GAAG;IAAE,CAAC,EAAE,EAAE,MAAM,GAAG,QAAQ,CAAA;CAAE,CAAC;AAEpD,MAAM,MAAM,SAAS,CAAC,KAAK,SAAS,cAAc,GAAG,cAAc,IAAI,oBAAoB,CAAC,KAAK,EAAE,QAAQ,CAAC,GAC1G,mBAAmB,GAAG;IACpB,KAAK,CAAC,EAAE,KAAK,EAAE,CAAC;IAChB,MAAM,CAAC,EAAE,UAAU,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;IAC/B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,CAAC,QAAQ,EAAE,QAAQ,KAAK,IAAI,CAAC;CACzC,CAAC;AAEJ;;GAEG;AAEH,eAAO,MAAM,IAAI,iJAcd,SAAS,gBAkHX,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import '@dxosTheme';
|
|
3
|
+
declare const _default: {
|
|
4
|
+
component: ({ id, items, layout, options: opts, margin, square, debug, selected: controlledSelected, Component, className, onDrop, onSelect, onCreate, }: import("./Grid").GridProps<import("../../mosaic").MosaicDataItem>) => JSX.Element;
|
|
5
|
+
render: () => JSX.Element;
|
|
6
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default _default;
|
|
12
|
+
export declare const Default: {};
|
|
13
|
+
//# sourceMappingURL=Grid.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Grid.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Grid/Grid.stories.tsx"],"names":[],"mappings":";AAIA,OAAO,YAAY,CAAC;;;;;;;;;AA2BpB,wBAcE;AAEF,eAAO,MAAM,OAAO,IAAK,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/views/Grid/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC;AAEzB,cAAc,QAAQ,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export type Size = {
|
|
2
|
+
x: number;
|
|
3
|
+
y: number;
|
|
4
|
+
};
|
|
5
|
+
export type Position = {
|
|
6
|
+
x: number;
|
|
7
|
+
y: number;
|
|
8
|
+
};
|
|
9
|
+
export type Dimension = {
|
|
10
|
+
width: number;
|
|
11
|
+
height: number;
|
|
12
|
+
};
|
|
13
|
+
export type Bounds = {
|
|
14
|
+
left: number;
|
|
15
|
+
top: number;
|
|
16
|
+
width: number;
|
|
17
|
+
height: number;
|
|
18
|
+
};
|
|
19
|
+
export declare const createMatrix: <TValue>(size: Size, value: (position: Position) => TValue) => TValue[][];
|
|
20
|
+
export declare const getDimension: ({ width, height }: Dimension, spacing?: number) => Dimension;
|
|
21
|
+
export declare const getBounds: ({ x, y }: Position, { width, height }: Dimension, spacing?: number) => Bounds;
|
|
22
|
+
export declare const getPanelBounds: ({ x, y }: Position, { width, height }: Dimension, spacing?: number) => Dimension;
|
|
23
|
+
export declare const calculateCellWidth: (defaultWidth: number, screenWidth: number, options?: {
|
|
24
|
+
min: number;
|
|
25
|
+
max: number;
|
|
26
|
+
}) => number;
|
|
27
|
+
//# sourceMappingURL=layout.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../../../../src/views/Grid/layout.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,IAAI,GAAG;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAC5C,MAAM,MAAM,QAAQ,GAAG;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAChD,MAAM,MAAM,SAAS,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAC1D,MAAM,MAAM,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAElF,eAAO,MAAM,YAAY,iBAAkB,IAAI,oBAAoB,QAAQ,0BAO1E,CAAC;AAEF,eAAO,MAAM,YAAY,sBAAuB,SAAS,uBAAgB,SAGvE,CAAC;AAEH,eAAO,MAAM,SAAS,aAAc,QAAQ,qBAAqB,SAAS,uBAAgB,MAKxF,CAAC;AAEH,eAAO,MAAM,cAAc,aAAc,QAAQ,qBAAqB,SAAS,uBAAgB,SAG7F,CAAC;AAEH,eAAO,MAAM,kBAAkB,iBACf,MAAM,eACP,MAAM,YACV;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,WAGtC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type GridLayout, type GridProps } from './Grid';
|
|
2
|
+
import { type MosaicDataItem } from '../../mosaic';
|
|
3
|
+
export type DemoGridProps = GridProps & {
|
|
4
|
+
initialItems?: MosaicDataItem[];
|
|
5
|
+
initialLayout?: GridLayout;
|
|
6
|
+
types?: string[];
|
|
7
|
+
debug?: boolean;
|
|
8
|
+
};
|
|
9
|
+
export declare const DemoGrid: ({ id, options, Component, initialItems, initialLayout, types, debug, className, }: DemoGridProps) => JSX.Element;
|
|
10
|
+
//# sourceMappingURL=testing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"testing.d.ts","sourceRoot":"","sources":["../../../../../src/views/Grid/testing.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAQ,KAAK,UAAU,EAAE,KAAK,SAAS,EAAE,MAAM,QAAQ,CAAC;AAE/D,OAAO,EAAE,KAAK,cAAc,EAAwB,MAAM,cAAc,CAAC;AAGzE,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG;IACtC,YAAY,CAAC,EAAE,cAAc,EAAE,CAAC;IAChC,aAAa,CAAC,EAAE,UAAU,CAAC;IAC3B,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,QAAQ,sFASlB,aAAa,gBA8Df,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type PublicKey } from '@dxos/react-client';
|
|
3
|
+
declare const _default: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: ({ id, columns, Component: TileComponent, debug, onDrop, }: import("./Kanban").KanbanProps<import("../../mosaic").MosaicDataItem>) => JSX.Element;
|
|
6
|
+
render: ({ basePath, spaceKey, debug, }: {
|
|
7
|
+
basePath: string;
|
|
8
|
+
spaceKey: PublicKey;
|
|
9
|
+
debug: boolean;
|
|
10
|
+
}) => JSX.Element;
|
|
11
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
12
|
+
parameters: {
|
|
13
|
+
layout: string;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
export default _default;
|
|
17
|
+
export declare const ECHO: {};
|
|
18
|
+
//# sourceMappingURL=Echo.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Echo.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Kanban/Echo.stories.tsx"],"names":[],"mappings":";AAMA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;;;;;kBAoBtC,MAAM;kBACN,SAAS;eACZ,OAAO;;;;;;;AAXlB,wBA+CE;AAEF,eAAO,MAAM,IAAI,IAAK,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type MosaicContainerProps, type MosaicDataItem } from '../../mosaic';
|
|
2
|
+
export type KanbanColumn<TData extends MosaicDataItem = MosaicDataItem> = MosaicDataItem & {
|
|
3
|
+
title: string;
|
|
4
|
+
items: TData[];
|
|
5
|
+
};
|
|
6
|
+
export type KanbanProps<TData extends MosaicDataItem = MosaicDataItem> = MosaicContainerProps<TData, number> & {
|
|
7
|
+
columns: KanbanColumn<TData>[];
|
|
8
|
+
debug?: boolean;
|
|
9
|
+
};
|
|
10
|
+
export declare const Kanban: ({ id, columns, Component: TileComponent, debug, onDrop, }: KanbanProps) => JSX.Element;
|
|
11
|
+
//# sourceMappingURL=Kanban.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Kanban.d.ts","sourceRoot":"","sources":["../../../../../src/views/Kanban/Kanban.tsx"],"names":[],"mappings":"AASA,OAAO,EAEL,KAAK,oBAAoB,EACzB,KAAK,cAAc,EAKpB,MAAM,cAAc,CAAC;AAKtB,MAAM,MAAM,YAAY,CAAC,KAAK,SAAS,cAAc,GAAG,cAAc,IAAI,cAAc,GAAG;IACzF,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,KAAK,EAAE,CAAC;CAChB,CAAC;AAEF,MAAM,MAAM,WAAW,CAAC,KAAK,SAAS,cAAc,GAAG,cAAc,IAAI,oBAAoB,CAAC,KAAK,EAAE,MAAM,CAAC,GAAG;IAC7G,OAAO,EAAE,YAAY,CAAC,KAAK,CAAC,EAAE,CAAC;IAC/B,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,MAAM,8DAMhB,WAAW,gBAqCb,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import '@dxosTheme';
|
|
3
|
+
import { type DemoKanbanProps } from './testing';
|
|
4
|
+
declare const _default: {
|
|
5
|
+
component: ({ id, columns, Component: TileComponent, debug, onDrop, }: import("./Kanban").KanbanProps<import("../../mosaic").MosaicDataItem>) => JSX.Element;
|
|
6
|
+
render: (args: DemoKanbanProps) => JSX.Element;
|
|
7
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
8
|
+
parameters: {
|
|
9
|
+
layout: string;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export default _default;
|
|
13
|
+
export declare const Default: {
|
|
14
|
+
args: {
|
|
15
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
16
|
+
count: number;
|
|
17
|
+
debug: boolean;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
export declare const Complex: {
|
|
21
|
+
args: {
|
|
22
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
23
|
+
types: string[];
|
|
24
|
+
count: number;
|
|
25
|
+
debug: boolean;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=Kanban.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Kanban.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Kanban/Kanban.stories.tsx"],"names":[],"mappings":";AAIA,OAAO,YAAY,CAAC;AAMpB,OAAO,EAAc,KAAK,eAAe,EAAE,MAAM,WAAW,CAAC;;;mBAQ5C,eAAe;;;;;;AAFhC,wBAcE;AAEF,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC;AAEF,eAAO,MAAM,OAAO;;;;;;;CAOnB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/views/Kanban/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type PublicKey } from '@dxos/react-client';
|
|
3
|
+
import { type KanbanProps } from './Kanban';
|
|
4
|
+
import { TestObjectGenerator } from '../../testing';
|
|
5
|
+
export type DemoKanbanProps = Omit<KanbanProps, 'columns'> & {
|
|
6
|
+
types?: string[];
|
|
7
|
+
count?: number;
|
|
8
|
+
debug?: boolean;
|
|
9
|
+
};
|
|
10
|
+
export declare const DemoKanban: FC<DemoKanbanProps>;
|
|
11
|
+
export declare const columnValues: {
|
|
12
|
+
[property: string]: any[];
|
|
13
|
+
};
|
|
14
|
+
export declare const EchoKanban: ({ id, spaceKey, generator, debug, }: {
|
|
15
|
+
id: string;
|
|
16
|
+
spaceKey: PublicKey;
|
|
17
|
+
generator: TestObjectGenerator;
|
|
18
|
+
debug?: boolean | undefined;
|
|
19
|
+
}) => JSX.Element;
|
|
20
|
+
//# sourceMappingURL=testing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"testing.d.ts","sourceRoot":"","sources":["../../../../../src/views/Kanban/testing.tsx"],"names":[],"mappings":"AAKA,OAAc,EAAE,KAAK,EAAE,EAAoB,MAAM,OAAO,CAAC;AAGzD,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAKpD,OAAO,EAA6B,KAAK,WAAW,EAAE,MAAM,UAAU,CAAC;AAEvE,OAAO,EAAE,mBAAmB,EAA+C,MAAM,eAAe,CAAC;AAWjG,MAAM,MAAM,eAAe,GAAG,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,GAAG;IAC3D,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,EAAE,CAAC,eAAe,CA6C1C,CAAC;AAGF,eAAO,MAAM,YAAY,EAAE;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,GAAG,EAAE,CAAA;CAGrD,CAAC;AAEF,eAAO,MAAM,UAAU;QAMjB,MAAM;cACA,SAAS;eACR,mBAAmB;;iBA+G/B,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import '@dxosTheme';
|
|
3
|
+
import { type DemoStackProps } from './testing';
|
|
4
|
+
declare const _default: {
|
|
5
|
+
title: string;
|
|
6
|
+
component: ({ id, Component, onOver, onDrop, items, direction, debug, }: import("./Stack").StackProps<import("../../mosaic").MosaicDataItem>) => JSX.Element;
|
|
7
|
+
render: (args: DemoStackProps) => JSX.Element;
|
|
8
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
9
|
+
parameters: {
|
|
10
|
+
layout: string;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export default _default;
|
|
14
|
+
export declare const Adopt: {
|
|
15
|
+
args: {
|
|
16
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
17
|
+
debug: boolean;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
export declare const Copy: {
|
|
21
|
+
args: {
|
|
22
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
23
|
+
debug: boolean;
|
|
24
|
+
operation: string;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
export declare const Reject: {
|
|
28
|
+
args: {
|
|
29
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
30
|
+
debug: boolean;
|
|
31
|
+
operation: string;
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=Columns.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Columns.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Stack/Columns.stories.tsx"],"names":[],"mappings":";AAIA,OAAO,YAAY,CAAC;AAMpB,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,WAAW,CAAC;;;;mBAS1C,cAAc;;;;;;AAH/B,wBAoBE;AAEF,eAAO,MAAM,KAAK;;;;;CAKjB,CAAC;AAGF,eAAO,MAAM,IAAI;;;;;;CAMhB,CAAC;AAEF,eAAO,MAAM,MAAM;;;;;;CAMlB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type MosaicContainerProps, type MosaicDataItem } from '../../mosaic';
|
|
2
|
+
export type Direction = 'horizontal' | 'vertical';
|
|
3
|
+
export type StackProps<TData extends MosaicDataItem = MosaicDataItem> = MosaicContainerProps<TData, number> & {
|
|
4
|
+
items?: TData[];
|
|
5
|
+
direction?: Direction;
|
|
6
|
+
debug?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export declare const Stack: ({ id, Component, onOver, onDrop, items, direction, debug, }: StackProps) => JSX.Element;
|
|
9
|
+
//# sourceMappingURL=Stack.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Stack.d.ts","sourceRoot":"","sources":["../../../../../src/views/Stack/Stack.tsx"],"names":[],"mappings":"AAQA,OAAO,EAAU,KAAK,oBAAoB,EAAE,KAAK,cAAc,EAAuB,MAAM,cAAc,CAAC;AAE3G,MAAM,MAAM,SAAS,GAAG,YAAY,GAAG,UAAU,CAAC;AAElD,MAAM,MAAM,UAAU,CAAC,KAAK,SAAS,cAAc,GAAG,cAAc,IAAI,oBAAoB,CAAC,KAAK,EAAE,MAAM,CAAC,GAAG;IAC5G,KAAK,CAAC,EAAE,KAAK,EAAE,CAAC;IAChB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAGF,eAAO,MAAM,KAAK,gEAQf,UAAU,gBA8BZ,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import '@dxosTheme';
|
|
3
|
+
import { type StackProps } from './Stack';
|
|
4
|
+
declare const _default: {
|
|
5
|
+
component: ({ id, Component, onOver, onDrop, items, direction, debug, }: StackProps<import("../../mosaic").MosaicDataItem>) => JSX.Element;
|
|
6
|
+
render: (args: StackProps & {
|
|
7
|
+
types: string[];
|
|
8
|
+
count: number;
|
|
9
|
+
}) => JSX.Element;
|
|
10
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
11
|
+
parameters: {
|
|
12
|
+
layout: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export default _default;
|
|
16
|
+
export declare const Default: {
|
|
17
|
+
args: {
|
|
18
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
19
|
+
count: number;
|
|
20
|
+
debug: boolean;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export declare const Horizontal: {
|
|
24
|
+
args: {
|
|
25
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
26
|
+
direction: string;
|
|
27
|
+
count: number;
|
|
28
|
+
debug: boolean;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
export declare const Complex: {
|
|
32
|
+
args: {
|
|
33
|
+
Component: import("../../mosaic").MosaicTileComponent<import("../../testing").SimpleCardProps>;
|
|
34
|
+
types: string[];
|
|
35
|
+
count: number;
|
|
36
|
+
debug: boolean;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
//# sourceMappingURL=Stack.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Stack.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Stack/Stack.stories.tsx"],"names":[],"mappings":";AAIA,OAAO,YAAY,CAAC;AAKpB,OAAO,EAAS,KAAK,UAAU,EAAE,MAAM,SAAS,CAAC;;;mBAUvC,UAAU,GAAG;QACjB,KAAK,EAAE,MAAM,EAAE,CAAC;QAChB,KAAK,EAAE,MAAM,CAAC;KACf;;;;;;AANL,wBAmBE;AAEF,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC;AAEF,eAAO,MAAM,UAAU;;;;;;;CAOtB,CAAC;AAEF,eAAO,MAAM,OAAO;;;;;;;CAOnB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/views/Stack/index.ts"],"names":[],"mappings":"AAIA,cAAc,SAAS,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type StackProps } from './Stack';
|
|
2
|
+
import { type MosaicOperation } from '../../mosaic';
|
|
3
|
+
export type DemoStackProps = StackProps & {
|
|
4
|
+
types?: string[];
|
|
5
|
+
count?: number;
|
|
6
|
+
operation?: MosaicOperation;
|
|
7
|
+
};
|
|
8
|
+
export declare const DemoStack: ({ id, Component, types, count, direction, operation, debug, }: DemoStackProps) => JSX.Element;
|
|
9
|
+
//# sourceMappingURL=testing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"testing.d.ts","sourceRoot":"","sources":["../../../../../src/views/Stack/testing.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAS,KAAK,UAAU,EAAE,MAAM,SAAS,CAAC;AACjD,OAAO,EAIL,KAAK,eAAe,EAErB,MAAM,cAAc,CAAC;AAGtB,MAAM,MAAM,cAAc,GAAG,UAAU,GAAG;IACxC,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,eAAe,CAAC;CAC7B,CAAC;AAEF,eAAO,MAAM,SAAS,kEAQnB,cAAc,gBA8ChB,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import '@dxosTheme';
|
|
3
|
+
declare const _default: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: ({ id, Component, onOver, onDrop, items, debug, compare }: import("./Tree").TreeProps<import("./Tree").TreeData>) => JSX.Element;
|
|
6
|
+
render: ({ id, debug }: {
|
|
7
|
+
id: string;
|
|
8
|
+
debug: boolean;
|
|
9
|
+
}) => JSX.Element;
|
|
10
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
11
|
+
parameters: {
|
|
12
|
+
layout: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export default _default;
|
|
16
|
+
export declare const Graph: {
|
|
17
|
+
args: {
|
|
18
|
+
debug: boolean;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=Graph.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Graph.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Tree/Graph.stories.tsx"],"names":[],"mappings":";AAIA,OAAO,YAAY,CAAC;;;;;YAeqB,MAAM;eAAS,OAAO;;;;;;;AAH/D,wBAeE;AAEF,eAAO,MAAM,KAAK;;;;CAEjB,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type MosaicContainerProps, type MosaicDataItem, type MosaicCompareDataItem } from '../../mosaic';
|
|
2
|
+
export type TreeProps<TData extends MosaicDataItem = TreeData> = MosaicContainerProps<TData, number> & {
|
|
3
|
+
items?: TData[];
|
|
4
|
+
debug?: boolean;
|
|
5
|
+
compare?: MosaicCompareDataItem;
|
|
6
|
+
};
|
|
7
|
+
export type TreeData = {
|
|
8
|
+
id: string;
|
|
9
|
+
label?: string;
|
|
10
|
+
children: TreeData[];
|
|
11
|
+
};
|
|
12
|
+
export declare const Tree: ({ id, Component, onOver, onDrop, items, debug, compare }: TreeProps) => JSX.Element;
|
|
13
|
+
//# sourceMappingURL=Tree.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tree.d.ts","sourceRoot":"","sources":["../../../../../src/views/Tree/Tree.tsx"],"names":[],"mappings":"AASA,OAAO,EACL,KAAK,oBAAoB,EAEzB,KAAK,cAAc,EAMnB,KAAK,qBAAqB,EAC3B,MAAM,cAAc,CAAC;AAOtB,MAAM,MAAM,SAAS,CAAC,KAAK,SAAS,cAAc,GAAG,QAAQ,IAAI,oBAAoB,CAAC,KAAK,EAAE,MAAM,CAAC,GAAG;IACrG,KAAK,CAAC,EAAE,KAAK,EAAE,CAAC;IAChB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,qBAAqB,CAAC;CACjC,CAAC;AAEF,MAAM,MAAM,QAAQ,GAAG;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,QAAQ,EAAE,CAAC;CACtB,CAAC;AAGF,eAAO,MAAM,IAAI,6DAA8E,SAAS,gBAevG,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import '@dxosTheme';
|
|
3
|
+
import { type DemoTreeProps } from './testing';
|
|
4
|
+
declare const _default: {
|
|
5
|
+
component: ({ id, Component, onOver, onDrop, items, debug, compare }: import("./Tree").TreeProps<import("./Tree").TreeData>) => JSX.Element;
|
|
6
|
+
render: (args: DemoTreeProps) => JSX.Element;
|
|
7
|
+
decorators: import("@storybook/csf").DecoratorFunction<import("@storybook/react/dist/types-0a347bb9").R>[];
|
|
8
|
+
parameters: {
|
|
9
|
+
layout: string;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export default _default;
|
|
13
|
+
export declare const Default: {
|
|
14
|
+
args: {
|
|
15
|
+
initialItems: {
|
|
16
|
+
id: string;
|
|
17
|
+
label: string;
|
|
18
|
+
children: {
|
|
19
|
+
id: any;
|
|
20
|
+
label: any;
|
|
21
|
+
children: never[];
|
|
22
|
+
}[];
|
|
23
|
+
}[];
|
|
24
|
+
debug: boolean;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
export declare const Deep: {
|
|
28
|
+
args: {
|
|
29
|
+
initialItems: {
|
|
30
|
+
id: string;
|
|
31
|
+
children: {
|
|
32
|
+
id: string;
|
|
33
|
+
children: {
|
|
34
|
+
id: string;
|
|
35
|
+
children: never[];
|
|
36
|
+
}[];
|
|
37
|
+
}[];
|
|
38
|
+
}[];
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
//# sourceMappingURL=Tree.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tree.stories.d.ts","sourceRoot":"","sources":["../../../../../src/views/Tree/Tree.stories.tsx"],"names":[],"mappings":";AAIA,OAAO,YAAY,CAAC;AAMpB,OAAO,EAAY,KAAK,aAAa,EAAE,MAAM,WAAW,CAAC;;;mBA6DxC,aAAa;;;;;;AAF9B,wBAcE;AAEF,eAAO,MAAM,OAAO;;;;;;;;;;;;;CAEnB,CAAC;AAEF,eAAO,MAAM,IAAI;;;;;;;;;;;;;CAEhB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/views/Tree/index.ts"],"names":[],"mappings":"AAIA,cAAc,QAAQ,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type Graph } from '@braneframe/plugin-graph';
|
|
2
|
+
import { type TreeData, type TreeProps } from './Tree';
|
|
3
|
+
export type DemoTreeProps = TreeProps & {
|
|
4
|
+
initialItems?: TreeData[];
|
|
5
|
+
types?: string[];
|
|
6
|
+
debug?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export declare const DemoTree: ({ id, initialItems, types, debug }: DemoTreeProps) => JSX.Element;
|
|
9
|
+
export declare const createGraph: () => Graph;
|
|
10
|
+
export declare const GraphTree: ({ id, graph, debug }: {
|
|
11
|
+
id: string;
|
|
12
|
+
graph?: Graph | undefined;
|
|
13
|
+
debug: boolean;
|
|
14
|
+
}) => JSX.Element;
|
|
15
|
+
//# sourceMappingURL=testing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"testing.d.ts","sourceRoot":"","sources":["../../../../../src/views/Tree/testing.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,KAAK,KAAK,EAA2B,MAAM,0BAA0B,CAAC;AAI/E,OAAO,EAAQ,KAAK,QAAQ,EAAE,KAAK,SAAS,EAAE,MAAM,QAAQ,CAAC;AAM7D,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG;IACtC,YAAY,CAAC,EAAE,QAAQ,EAAE,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,QAAQ,uCAAiD,aAAa,gBA0DlF,CAAC;AAEF,eAAO,MAAM,WAAW,aAqBvB,CAAC;AAcF,eAAO,MAAM,SAAS;QAAgD,MAAM;;WAAwB,OAAO;iBAqC1G,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/views/index.ts"],"names":[],"mappings":"AAIA,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC"}
|