@dxos/plugin-registry 0.8.4-main.ae835ea → 0.8.4-main.bc674ce
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/app-graph-builder-P3ZGGFAR.mjs +166 -0
- package/dist/lib/browser/app-graph-builder-P3ZGGFAR.mjs.map +7 -0
- package/dist/lib/browser/{chunk-XPEFEID2.mjs → chunk-VOAOTNGS.mjs} +1 -1
- package/dist/lib/browser/chunk-VOAOTNGS.mjs.map +7 -0
- package/dist/lib/browser/cli/index.mjs +223 -0
- package/dist/lib/browser/cli/index.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +22 -29
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/operation-resolver-P5PKLPRT.mjs +24 -0
- package/dist/lib/browser/operation-resolver-P5PKLPRT.mjs.map +7 -0
- package/dist/lib/browser/react-surface-IIM6T7IA.mjs +337 -0
- package/dist/lib/browser/react-surface-IIM6T7IA.mjs.map +7 -0
- package/dist/lib/node-esm/app-graph-builder-56JXLOGZ.mjs +167 -0
- package/dist/lib/node-esm/app-graph-builder-56JXLOGZ.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-SALMIZ2W.mjs +21 -0
- package/dist/lib/node-esm/chunk-SALMIZ2W.mjs.map +7 -0
- package/dist/lib/node-esm/cli/index.mjs +224 -0
- package/dist/lib/node-esm/cli/index.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +63 -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/operation-resolver-3ZB5W3T3.mjs +25 -0
- package/dist/lib/node-esm/operation-resolver-3ZB5W3T3.mjs.map +7 -0
- package/dist/lib/node-esm/react-surface-F67P7RC3.mjs +338 -0
- package/dist/lib/node-esm/react-surface-F67P7RC3.mjs.map +7 -0
- package/dist/types/src/RegistryPlugin.d.ts +2 -1
- package/dist/types/src/RegistryPlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts +6 -0
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts +3 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +3 -3
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/operation-resolver/index.d.ts +3 -0
- package/dist/types/src/capabilities/operation-resolver/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts +5 -0
- package/dist/types/src/capabilities/operation-resolver/operation-resolver.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts +3 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts +5 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts.map +1 -0
- package/dist/types/src/cli/commands/disable.d.ts +11 -0
- package/dist/types/src/cli/commands/disable.d.ts.map +1 -0
- package/dist/types/src/cli/commands/enable.d.ts +11 -0
- package/dist/types/src/cli/commands/enable.d.ts.map +1 -0
- package/dist/types/src/cli/commands/index.d.ts +3 -0
- package/dist/types/src/cli/commands/index.d.ts.map +1 -0
- package/dist/types/src/cli/commands/list.d.ts +7 -0
- package/dist/types/src/cli/commands/list.d.ts.map +1 -0
- package/dist/types/src/cli/commands/util.d.ts +11 -0
- package/dist/types/src/cli/commands/util.d.ts.map +1 -0
- package/dist/types/src/cli/index.d.ts +3 -0
- package/dist/types/src/cli/index.d.ts.map +1 -0
- package/dist/types/src/cli/plugin.d.ts +3 -0
- package/dist/types/src/cli/plugin.d.ts.map +1 -0
- package/dist/types/src/cli/storage.d.ts +18 -0
- package/dist/types/src/cli/storage.d.ts.map +1 -0
- package/dist/types/src/components/PluginDetail.d.ts +3 -3
- package/dist/types/src/components/PluginDetail.d.ts.map +1 -1
- package/dist/types/src/components/PluginDetail.stories.d.ts +1 -1
- package/dist/types/src/components/PluginDetail.stories.d.ts.map +1 -1
- package/dist/types/src/components/PluginItem.d.ts +2 -2
- package/dist/types/src/components/PluginItem.d.ts.map +1 -1
- package/dist/types/src/components/PluginList.d.ts +1 -1
- package/dist/types/src/components/PluginList.d.ts.map +1 -1
- package/dist/types/src/components/PluginList.stories.d.ts.map +1 -1
- package/dist/types/src/components/RegistryContainer.d.ts +4 -3
- package/dist/types/src/components/RegistryContainer.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +2 -2
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +47 -31
- package/src/RegistryPlugin.tsx +9 -24
- package/src/capabilities/app-graph-builder/app-graph-builder.ts +136 -0
- package/src/capabilities/app-graph-builder/index.ts +7 -0
- package/src/capabilities/index.ts +3 -5
- package/src/capabilities/operation-resolver/index.ts +7 -0
- package/src/capabilities/operation-resolver/operation-resolver.ts +23 -0
- package/src/capabilities/react-surface/index.ts +7 -0
- package/src/capabilities/react-surface/react-surface.tsx +99 -0
- package/src/cli/commands/disable.ts +47 -0
- package/src/cli/commands/enable.ts +44 -0
- package/src/cli/commands/index.ts +14 -0
- package/src/cli/commands/list.ts +41 -0
- package/src/cli/commands/util.ts +24 -0
- package/src/cli/index.ts +6 -0
- package/src/cli/plugin.ts +16 -0
- package/src/cli/storage.ts +57 -0
- package/src/components/PluginDetail.stories.tsx +14 -16
- package/src/components/PluginDetail.tsx +8 -11
- package/src/components/PluginItem.tsx +5 -5
- package/src/components/PluginList.stories.tsx +14 -17
- package/src/components/PluginList.tsx +2 -2
- package/src/components/RegistryContainer.tsx +43 -44
- package/src/meta.ts +2 -2
- package/dist/lib/browser/app-graph-builder-AOIN4N2Q.mjs +0 -162
- package/dist/lib/browser/app-graph-builder-AOIN4N2Q.mjs.map +0 -7
- package/dist/lib/browser/chunk-XPEFEID2.mjs.map +0 -7
- package/dist/lib/browser/intent-resolver-LKNUYBTN.mjs +0 -23
- package/dist/lib/browser/intent-resolver-LKNUYBTN.mjs.map +0 -7
- package/dist/lib/browser/react-surface-KP3NX4UD.mjs +0 -357
- package/dist/lib/browser/react-surface-KP3NX4UD.mjs.map +0 -7
- package/dist/types/src/capabilities/app-graph-builder.d.ts +0 -4
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +0 -1
- package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
- package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-surface.d.ts +0 -4
- package/dist/types/src/capabilities/react-surface.d.ts.map +0 -1
- package/src/capabilities/app-graph-builder.ts +0 -156
- package/src/capabilities/intent-resolver.ts +0 -27
- package/src/capabilities/react-surface.tsx +0 -85
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import React, { useCallback, useMemo } from 'react';
|
|
6
|
-
|
|
7
|
-
import { Capabilities, Plugin, contributes, createSurface, usePluginManager } from '@dxos/app-framework';
|
|
8
|
-
|
|
9
|
-
import { PluginDetail, RegistryContainer } from '../components';
|
|
10
|
-
import { REGISTRY_KEY, meta } from '../meta';
|
|
11
|
-
|
|
12
|
-
export default () =>
|
|
13
|
-
contributes(Capabilities.ReactSurface, [
|
|
14
|
-
createSurface({
|
|
15
|
-
id: `${meta.id}/all`,
|
|
16
|
-
role: 'article',
|
|
17
|
-
filter: (data): data is any => data.subject === `${REGISTRY_KEY}+all`,
|
|
18
|
-
component: () => {
|
|
19
|
-
const manager = usePluginManager();
|
|
20
|
-
const filtered = useMemo(() => manager.plugins.filter(({ meta }) => !manager.core.includes(meta.id)), []);
|
|
21
|
-
|
|
22
|
-
return <RegistryContainer id={`${REGISTRY_KEY}+all`} plugins={filtered} />;
|
|
23
|
-
},
|
|
24
|
-
}),
|
|
25
|
-
createSurface({
|
|
26
|
-
id: `${meta.id}/installed`,
|
|
27
|
-
role: 'article',
|
|
28
|
-
filter: (data): data is any => data.subject === `${REGISTRY_KEY}+installed`,
|
|
29
|
-
component: () => {
|
|
30
|
-
const manager = usePluginManager();
|
|
31
|
-
const filtered = useMemo(
|
|
32
|
-
() =>
|
|
33
|
-
manager.plugins
|
|
34
|
-
.filter(({ meta }) => !manager.core.includes(meta.id))
|
|
35
|
-
.filter(({ meta }) => manager.enabled.includes(meta.id)),
|
|
36
|
-
[],
|
|
37
|
-
);
|
|
38
|
-
|
|
39
|
-
return <RegistryContainer id={`${REGISTRY_KEY}+installed`} plugins={filtered} />;
|
|
40
|
-
},
|
|
41
|
-
}),
|
|
42
|
-
createSurface({
|
|
43
|
-
id: `${meta.id}/recommended`,
|
|
44
|
-
role: 'article',
|
|
45
|
-
filter: (data): data is any => data.subject === `${REGISTRY_KEY}+recommended`,
|
|
46
|
-
component: () => {
|
|
47
|
-
const manager = usePluginManager();
|
|
48
|
-
const filtered = useMemo(
|
|
49
|
-
() =>
|
|
50
|
-
manager.plugins
|
|
51
|
-
.filter(({ meta }) => !manager.core.includes(meta.id))
|
|
52
|
-
.filter(({ meta }) => !meta.tags?.includes('labs')),
|
|
53
|
-
[],
|
|
54
|
-
);
|
|
55
|
-
|
|
56
|
-
return <RegistryContainer id={`${REGISTRY_KEY}+recommended`} plugins={filtered} />;
|
|
57
|
-
},
|
|
58
|
-
}),
|
|
59
|
-
createSurface({
|
|
60
|
-
id: `${meta.id}/labs`,
|
|
61
|
-
role: 'article',
|
|
62
|
-
filter: (data): data is any => data.subject === `${REGISTRY_KEY}+labs`,
|
|
63
|
-
component: () => {
|
|
64
|
-
const manager = usePluginManager();
|
|
65
|
-
const filtered = useMemo(() => manager.plugins.filter(({ meta }) => meta.tags?.includes('labs')), []);
|
|
66
|
-
|
|
67
|
-
return <RegistryContainer id={`${REGISTRY_KEY}+labs`} plugins={filtered} />;
|
|
68
|
-
},
|
|
69
|
-
}),
|
|
70
|
-
createSurface({
|
|
71
|
-
id: `${meta.id}/plugin-details`,
|
|
72
|
-
role: 'article',
|
|
73
|
-
filter: (data): data is { subject: Plugin } => data.subject instanceof Plugin,
|
|
74
|
-
component: ({ data: { subject } }) => {
|
|
75
|
-
const manager = usePluginManager();
|
|
76
|
-
const enabled = manager.enabled.includes(subject.meta.id);
|
|
77
|
-
const handleEnable = useCallback(
|
|
78
|
-
() => (enabled ? manager.disable(subject.meta.id) : manager.enable(subject.meta.id)),
|
|
79
|
-
[manager, subject.meta.id, enabled],
|
|
80
|
-
);
|
|
81
|
-
|
|
82
|
-
return <PluginDetail plugin={subject} enabled={enabled} onEnable={handleEnable} />;
|
|
83
|
-
},
|
|
84
|
-
}),
|
|
85
|
-
]);
|