@dxos/app-graph 0.6.14-main.2b6a0f3 → 0.6.14-main.f49f251
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/package.json +18 -21
- package/src/stories/Tree.tsx +7 -7
package/package.json
CHANGED
|
@@ -1,20 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/app-graph",
|
|
3
|
-
"version": "0.6.14-main.
|
|
3
|
+
"version": "0.6.14-main.f49f251",
|
|
4
4
|
"description": "Constructs knowledge graphs for the purpose of building applications on top of",
|
|
5
5
|
"homepage": "https://dxos.org",
|
|
6
6
|
"bugs": "https://github.com/dxos/dxos/issues",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"author": "DXOS.org",
|
|
9
|
-
"sideEffects":
|
|
9
|
+
"sideEffects": true,
|
|
10
10
|
"exports": {
|
|
11
11
|
".": {
|
|
12
|
+
"types": "./dist/types/src/index.d.ts",
|
|
12
13
|
"browser": "./dist/lib/browser/index.mjs",
|
|
13
|
-
"node":
|
|
14
|
-
"require": "./dist/lib/node/index.cjs",
|
|
15
|
-
"default": "./dist/lib/node-esm/index.mjs"
|
|
16
|
-
},
|
|
17
|
-
"types": "./dist/types/src/index.d.ts"
|
|
14
|
+
"node": "./dist/lib/node-esm/index.mjs"
|
|
18
15
|
}
|
|
19
16
|
},
|
|
20
17
|
"types": "dist/types/src/index.d.ts",
|
|
@@ -28,13 +25,13 @@
|
|
|
28
25
|
"dependencies": {
|
|
29
26
|
"@preact/signals-core": "^1.6.0",
|
|
30
27
|
"main-thread-scheduling": "^14.1.1",
|
|
31
|
-
"@dxos/async": "0.6.14-main.
|
|
32
|
-
"@dxos/debug": "0.6.14-main.
|
|
33
|
-
"@dxos/
|
|
34
|
-
"@dxos/echo-signals": "0.6.14-main.
|
|
35
|
-
"@dxos/
|
|
36
|
-
"@dxos/
|
|
37
|
-
"@dxos/
|
|
28
|
+
"@dxos/async": "0.6.14-main.f49f251",
|
|
29
|
+
"@dxos/debug": "0.6.14-main.f49f251",
|
|
30
|
+
"@dxos/echo-schema": "0.6.14-main.f49f251",
|
|
31
|
+
"@dxos/echo-signals": "0.6.14-main.f49f251",
|
|
32
|
+
"@dxos/invariant": "0.6.14-main.f49f251",
|
|
33
|
+
"@dxos/util": "0.6.14-main.f49f251",
|
|
34
|
+
"@dxos/log": "0.6.14-main.f49f251"
|
|
38
35
|
},
|
|
39
36
|
"devDependencies": {
|
|
40
37
|
"@phosphor-icons/react": "^2.1.5",
|
|
@@ -43,18 +40,18 @@
|
|
|
43
40
|
"react": "~18.2.0",
|
|
44
41
|
"react-dom": "~18.2.0",
|
|
45
42
|
"vite": "5.4.7",
|
|
46
|
-
"@dxos/random": "0.6.14-main.
|
|
47
|
-
"@dxos/react-ui": "0.6.14-main.
|
|
48
|
-
"@dxos/react-
|
|
49
|
-
"@dxos/react-
|
|
50
|
-
"@dxos/storybook-utils": "0.6.14-main.
|
|
43
|
+
"@dxos/random": "0.6.14-main.f49f251",
|
|
44
|
+
"@dxos/react-ui": "0.6.14-main.f49f251",
|
|
45
|
+
"@dxos/react-ui-theme": "0.6.14-main.f49f251",
|
|
46
|
+
"@dxos/react-client": "0.6.14-main.f49f251",
|
|
47
|
+
"@dxos/storybook-utils": "0.6.14-main.f49f251"
|
|
51
48
|
},
|
|
52
49
|
"peerDependencies": {
|
|
53
50
|
"@phosphor-icons/react": "^2.1.5",
|
|
54
51
|
"react": "~18.2.0",
|
|
55
52
|
"react-dom": "~18.2.0",
|
|
56
|
-
"@dxos/react-ui": "0.6.14-main.
|
|
57
|
-
"@dxos/react-ui
|
|
53
|
+
"@dxos/react-ui-theme": "0.6.14-main.f49f251",
|
|
54
|
+
"@dxos/react-ui": "0.6.14-main.f49f251"
|
|
58
55
|
},
|
|
59
56
|
"publishConfig": {
|
|
60
57
|
"access": "public"
|
package/src/stories/Tree.tsx
CHANGED
|
@@ -10,7 +10,7 @@ import { mx } from '@dxos/react-ui-theme';
|
|
|
10
10
|
|
|
11
11
|
export const Tree: FC<{ data?: object }> = ({ data }) => {
|
|
12
12
|
return (
|
|
13
|
-
<div className='flex overflow-auto ml-2 border-l-
|
|
13
|
+
<div className='flex overflow-auto ml-2 border-l-4 border-blue-500'>
|
|
14
14
|
<Node data={data} root />
|
|
15
15
|
</div>
|
|
16
16
|
);
|
|
@@ -23,18 +23,18 @@ export const Node: FC<{ data?: any; root?: boolean }> = ({ data, root }) => {
|
|
|
23
23
|
|
|
24
24
|
if (Array.isArray(data)) {
|
|
25
25
|
return (
|
|
26
|
-
<div className='flex flex-col space-y-
|
|
26
|
+
<div className='flex flex-col space-y-1'>
|
|
27
27
|
{data.map((value, index) => (
|
|
28
|
-
<KeyValue key={index} label={String(index)} data={value} className='
|
|
28
|
+
<KeyValue key={index} label={String(index)} data={value} className='' />
|
|
29
29
|
))}
|
|
30
30
|
</div>
|
|
31
31
|
);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
return (
|
|
35
|
-
<div className='flex flex-col space-y-
|
|
35
|
+
<div className='flex flex-col space-y-1'>
|
|
36
36
|
{Object.entries(data).map(([key, value]) => (
|
|
37
|
-
<KeyValue key={key} label={key} data={value} className='
|
|
37
|
+
<KeyValue key={key} label={key} data={value} className='' />
|
|
38
38
|
))}
|
|
39
39
|
</div>
|
|
40
40
|
);
|
|
@@ -49,7 +49,7 @@ export const KeyValue: FC<{ label: string; data?: any; className?: string }> = (
|
|
|
49
49
|
return (
|
|
50
50
|
<div className='flex'>
|
|
51
51
|
<Box
|
|
52
|
-
className={mx('border-blue-
|
|
52
|
+
className={mx('border-blue-500 text-sm select-none cursor-pointer min-w-[6rem]', className)}
|
|
53
53
|
onClick={() => setOpen((open) => !open)}
|
|
54
54
|
>
|
|
55
55
|
{label}
|
|
@@ -61,7 +61,7 @@ export const KeyValue: FC<{ label: string; data?: any; className?: string }> = (
|
|
|
61
61
|
|
|
62
62
|
const Scalar: FC<{ value: any }> = ({ value }) => {
|
|
63
63
|
return (
|
|
64
|
-
<Box className='
|
|
64
|
+
<Box className='border-green-500 text-sm font-thin'>
|
|
65
65
|
{(value === undefined && 'undefined') ||
|
|
66
66
|
(value === null && 'null') ||
|
|
67
67
|
(typeof value === 'string' && value) ||
|