@dxos/app-framework 0.8.1-staging.5be625a → 0.8.1-staging.97aedb1
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-OD3G2J2U.mjs → app-graph-builder-576BHZC7.mjs} +3 -3
- package/dist/lib/browser/{chunk-CESGLKOM.mjs → chunk-6AVTZPMT.mjs} +63 -44
- package/dist/lib/browser/chunk-6AVTZPMT.mjs.map +7 -0
- package/dist/lib/browser/{chunk-KP6FVIAA.mjs → chunk-PPIBZ5N4.mjs} +50 -7
- package/dist/lib/browser/chunk-PPIBZ5N4.mjs.map +7 -0
- package/dist/lib/browser/{chunk-CB3W6T5E.mjs → chunk-SFPT4Z2C.mjs} +1 -1
- package/dist/lib/browser/{chunk-CB3W6T5E.mjs.map → chunk-SFPT4Z2C.mjs.map} +2 -2
- package/dist/lib/browser/index.mjs +6 -6
- package/dist/lib/browser/{intent-dispatcher-RTXTATZJ.mjs → intent-dispatcher-3Q67MHZZ.mjs} +2 -2
- package/dist/lib/browser/{intent-resolver-ZL6WBF2L.mjs → intent-resolver-O763LCLG.mjs} +3 -3
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/{store-JIKLP4JL.mjs → store-URSN7DZI.mjs} +2 -2
- package/dist/lib/browser/testing/index.mjs +2 -2
- package/dist/lib/browser/worker.mjs +1 -1
- package/dist/lib/node/{app-graph-builder-S3ER53EH.cjs → app-graph-builder-JZCSKYPY.cjs} +28 -28
- package/dist/lib/node/{chunk-SCHC4AZQ.cjs → chunk-JUSEAFDU.cjs} +4 -4
- package/dist/lib/node/{chunk-SCHC4AZQ.cjs.map → chunk-JUSEAFDU.cjs.map} +2 -2
- package/dist/lib/node/{chunk-KRK7EH6Z.cjs → chunk-YIFTVCOR.cjs} +189 -170
- package/dist/lib/node/chunk-YIFTVCOR.cjs.map +7 -0
- package/dist/lib/node/{chunk-4YBMWZR3.cjs → chunk-YNTKVTVX.cjs} +66 -23
- package/dist/lib/node/{chunk-4YBMWZR3.cjs.map → chunk-YNTKVTVX.cjs.map} +3 -3
- package/dist/lib/node/index.cjs +78 -78
- package/dist/lib/node/{intent-dispatcher-TBTSYYGJ.cjs → intent-dispatcher-H334XLFD.cjs} +8 -8
- package/dist/lib/node/{intent-dispatcher-TBTSYYGJ.cjs.map → intent-dispatcher-H334XLFD.cjs.map} +2 -2
- package/dist/lib/node/{intent-resolver-IYW254AY.cjs → intent-resolver-3F4POWAM.cjs} +12 -12
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/{store-KGQB37IW.cjs → store-OFDHTDCB.cjs} +7 -7
- package/dist/lib/node/testing/index.cjs +8 -8
- package/dist/lib/node/worker.cjs +37 -37
- package/dist/lib/node/worker.cjs.map +1 -1
- package/dist/lib/node-esm/{app-graph-builder-UP3LWWYO.mjs → app-graph-builder-VYKLSMSZ.mjs} +3 -3
- package/dist/lib/node-esm/{chunk-RQWO2T4E.mjs → chunk-AHKIPS2L.mjs} +63 -44
- package/dist/lib/node-esm/chunk-AHKIPS2L.mjs.map +7 -0
- package/dist/lib/node-esm/{chunk-BSYAFUZ7.mjs → chunk-PHOUQACM.mjs} +1 -1
- package/dist/lib/node-esm/{chunk-BSYAFUZ7.mjs.map → chunk-PHOUQACM.mjs.map} +2 -2
- package/dist/lib/node-esm/{chunk-MZCAK52M.mjs → chunk-R6A7Z4LU.mjs} +50 -7
- package/dist/lib/node-esm/chunk-R6A7Z4LU.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +6 -6
- package/dist/lib/node-esm/{intent-dispatcher-7UNJKY3C.mjs → intent-dispatcher-YDE2ONZA.mjs} +2 -2
- package/dist/lib/node-esm/{intent-resolver-6MHZSVCT.mjs → intent-resolver-LAGJ7LXM.mjs} +3 -3
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/{store-YSFTF2GM.mjs → store-EYSUVNCS.mjs} +2 -2
- package/dist/lib/node-esm/testing/index.mjs +2 -2
- package/dist/lib/node-esm/worker.mjs +1 -1
- package/dist/types/src/App.d.ts +4 -2
- package/dist/types/src/App.d.ts.map +1 -1
- package/dist/types/src/common/layout.d.ts +1 -0
- package/dist/types/src/common/layout.d.ts.map +1 -1
- package/dist/types/src/core/capabilities.d.ts +5 -3
- package/dist/types/src/core/capabilities.d.ts.map +1 -1
- package/dist/types/src/playground/playground.stories.d.ts.map +1 -1
- package/dist/types/src/plugin-intent/actions.d.ts +14 -0
- package/dist/types/src/plugin-intent/actions.d.ts.map +1 -1
- package/dist/types/src/plugin-intent/intent-dispatcher.d.ts +1 -1
- package/dist/types/src/plugin-intent/intent-dispatcher.d.ts.map +1 -1
- package/dist/types/src/plugin-settings/actions.d.ts.map +1 -1
- package/package.json +20 -19
- package/src/App.tsx +65 -8
- package/src/common/layout.ts +1 -0
- package/src/core/capabilities.test.ts +3 -2
- package/src/core/capabilities.ts +11 -3
- package/src/core/manager.ts +2 -2
- package/src/playground/playground.stories.tsx +5 -1
- package/src/plugin-intent/actions.ts +11 -0
- package/src/plugin-intent/intent-dispatcher.ts +18 -5
- package/src/plugin-settings/actions.ts +2 -0
- package/src/testing/withPluginManager.stories.tsx +2 -2
- package/dist/lib/browser/chunk-CESGLKOM.mjs.map +0 -7
- package/dist/lib/browser/chunk-KP6FVIAA.mjs.map +0 -7
- package/dist/lib/node/chunk-KRK7EH6Z.cjs.map +0 -7
- package/dist/lib/node-esm/chunk-MZCAK52M.mjs.map +0 -7
- package/dist/lib/node-esm/chunk-RQWO2T4E.mjs.map +0 -7
- /package/dist/lib/browser/{app-graph-builder-OD3G2J2U.mjs.map → app-graph-builder-576BHZC7.mjs.map} +0 -0
- /package/dist/lib/browser/{intent-dispatcher-RTXTATZJ.mjs.map → intent-dispatcher-3Q67MHZZ.mjs.map} +0 -0
- /package/dist/lib/browser/{intent-resolver-ZL6WBF2L.mjs.map → intent-resolver-O763LCLG.mjs.map} +0 -0
- /package/dist/lib/browser/{store-JIKLP4JL.mjs.map → store-URSN7DZI.mjs.map} +0 -0
- /package/dist/lib/node/{app-graph-builder-S3ER53EH.cjs.map → app-graph-builder-JZCSKYPY.cjs.map} +0 -0
- /package/dist/lib/node/{intent-resolver-IYW254AY.cjs.map → intent-resolver-3F4POWAM.cjs.map} +0 -0
- /package/dist/lib/node/{store-KGQB37IW.cjs.map → store-OFDHTDCB.cjs.map} +0 -0
- /package/dist/lib/node-esm/{app-graph-builder-UP3LWWYO.mjs.map → app-graph-builder-VYKLSMSZ.mjs.map} +0 -0
- /package/dist/lib/node-esm/{intent-dispatcher-7UNJKY3C.mjs.map → intent-dispatcher-YDE2ONZA.mjs.map} +0 -0
- /package/dist/lib/node-esm/{intent-resolver-6MHZSVCT.mjs.map → intent-resolver-LAGJ7LXM.mjs.map} +0 -0
- /package/dist/lib/node-esm/{store-YSFTF2GM.mjs.map → store-EYSUVNCS.mjs.map} +0 -0
|
@@ -16,31 +16,31 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
16
16
|
return to;
|
|
17
17
|
};
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var
|
|
20
|
-
__export(
|
|
19
|
+
var app_graph_builder_JZCSKYPY_exports = {};
|
|
20
|
+
__export(app_graph_builder_JZCSKYPY_exports, {
|
|
21
21
|
default: () => app_graph_builder_default
|
|
22
22
|
});
|
|
23
|
-
module.exports = __toCommonJS(
|
|
24
|
-
var
|
|
25
|
-
var
|
|
23
|
+
module.exports = __toCommonJS(app_graph_builder_JZCSKYPY_exports);
|
|
24
|
+
var import_chunk_JUSEAFDU = require("./chunk-JUSEAFDU.cjs");
|
|
25
|
+
var import_chunk_YIFTVCOR = require("./chunk-YIFTVCOR.cjs");
|
|
26
26
|
var import_app_graph = require("@dxos/app-graph");
|
|
27
27
|
var import_util = require("@dxos/util");
|
|
28
|
-
var app_graph_builder_default = (context) => (0,
|
|
28
|
+
var app_graph_builder_default = (context) => (0, import_chunk_YIFTVCOR.contributes)(import_chunk_YIFTVCOR.Capabilities.AppGraphBuilder, [
|
|
29
29
|
(0, import_app_graph.createExtension)({
|
|
30
|
-
id: `${
|
|
30
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_PLUGIN}/action`,
|
|
31
31
|
filter: (node) => node.id === "root",
|
|
32
32
|
actions: () => [
|
|
33
33
|
{
|
|
34
|
-
id:
|
|
34
|
+
id: import_chunk_JUSEAFDU.SETTINGS_PLUGIN,
|
|
35
35
|
data: async () => {
|
|
36
|
-
const { dispatchPromise: dispatch } = context.requestCapability(
|
|
37
|
-
await dispatch((0,
|
|
36
|
+
const { dispatchPromise: dispatch } = context.requestCapability(import_chunk_YIFTVCOR.Capabilities.IntentDispatcher);
|
|
37
|
+
await dispatch((0, import_chunk_YIFTVCOR.createIntent)(import_chunk_JUSEAFDU.SettingsAction.Open));
|
|
38
38
|
},
|
|
39
39
|
properties: {
|
|
40
40
|
label: [
|
|
41
41
|
"open settings label",
|
|
42
42
|
{
|
|
43
|
-
ns:
|
|
43
|
+
ns: import_chunk_JUSEAFDU.SETTINGS_PLUGIN
|
|
44
44
|
}
|
|
45
45
|
],
|
|
46
46
|
icon: "ph--gear--regular",
|
|
@@ -53,17 +53,17 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
53
53
|
]
|
|
54
54
|
}),
|
|
55
55
|
(0, import_app_graph.createExtension)({
|
|
56
|
-
id: `${
|
|
56
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_PLUGIN}/core`,
|
|
57
57
|
filter: (node) => node.id === "root",
|
|
58
58
|
connector: () => [
|
|
59
59
|
{
|
|
60
|
-
id:
|
|
61
|
-
type:
|
|
60
|
+
id: import_chunk_JUSEAFDU.SETTINGS_ID,
|
|
61
|
+
type: import_chunk_JUSEAFDU.SETTINGS_PLUGIN,
|
|
62
62
|
properties: {
|
|
63
63
|
label: [
|
|
64
64
|
"app settings label",
|
|
65
65
|
{
|
|
66
|
-
ns:
|
|
66
|
+
ns: import_chunk_JUSEAFDU.SETTINGS_PLUGIN
|
|
67
67
|
}
|
|
68
68
|
],
|
|
69
69
|
icon: "ph--gear--regular",
|
|
@@ -75,11 +75,11 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
75
75
|
]
|
|
76
76
|
}),
|
|
77
77
|
(0, import_app_graph.createExtension)({
|
|
78
|
-
id: `${
|
|
79
|
-
filter: (node) => node.id ===
|
|
78
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_PLUGIN}/core-plugins`,
|
|
79
|
+
filter: (node) => node.id === import_chunk_JUSEAFDU.SETTINGS_ID,
|
|
80
80
|
connector: () => {
|
|
81
|
-
const manager = context.requestCapability(
|
|
82
|
-
const [settingsStore] = context.requestCapabilities(
|
|
81
|
+
const manager = context.requestCapability(import_chunk_YIFTVCOR.Capabilities.PluginManager);
|
|
82
|
+
const [settingsStore] = context.requestCapabilities(import_chunk_YIFTVCOR.Capabilities.SettingsStore);
|
|
83
83
|
return [
|
|
84
84
|
...manager.plugins.filter((plugin) => manager.core.includes(plugin.meta.id)).map((plugin) => {
|
|
85
85
|
const settings = settingsStore?.getStore(plugin.meta.id);
|
|
@@ -91,7 +91,7 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
91
91
|
settings
|
|
92
92
|
];
|
|
93
93
|
}).filter(import_util.isNonNullable).map(([meta, settings]) => ({
|
|
94
|
-
id: `${
|
|
94
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_KEY}:${meta.id.replaceAll("/", ":")}`,
|
|
95
95
|
type: "category",
|
|
96
96
|
data: settings,
|
|
97
97
|
properties: {
|
|
@@ -100,13 +100,13 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
100
100
|
}
|
|
101
101
|
})),
|
|
102
102
|
{
|
|
103
|
-
id: `${
|
|
103
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_KEY}:custom-plugins`,
|
|
104
104
|
type: "collection",
|
|
105
105
|
properties: {
|
|
106
106
|
label: [
|
|
107
107
|
"custom plugins label",
|
|
108
108
|
{
|
|
109
|
-
ns:
|
|
109
|
+
ns: import_chunk_JUSEAFDU.SETTINGS_PLUGIN
|
|
110
110
|
}
|
|
111
111
|
],
|
|
112
112
|
icon: "ph--squares-four--regular",
|
|
@@ -117,11 +117,11 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
117
117
|
}
|
|
118
118
|
}),
|
|
119
119
|
(0, import_app_graph.createExtension)({
|
|
120
|
-
id: `${
|
|
121
|
-
filter: (node) => node.id === `${
|
|
120
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_PLUGIN}/custom-plugins`,
|
|
121
|
+
filter: (node) => node.id === `${import_chunk_JUSEAFDU.SETTINGS_KEY}:custom-plugins`,
|
|
122
122
|
connector: () => {
|
|
123
|
-
const manager = context.requestCapability(
|
|
124
|
-
const [settingsStore] = context.requestCapabilities(
|
|
123
|
+
const manager = context.requestCapability(import_chunk_YIFTVCOR.Capabilities.PluginManager);
|
|
124
|
+
const [settingsStore] = context.requestCapabilities(import_chunk_YIFTVCOR.Capabilities.SettingsStore);
|
|
125
125
|
return manager.plugins.filter((plugin) => !manager.core.includes(plugin.meta.id)).map((plugin) => {
|
|
126
126
|
const settings = settingsStore?.getStore(plugin.meta.id);
|
|
127
127
|
if (!settings) {
|
|
@@ -132,7 +132,7 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
132
132
|
settings
|
|
133
133
|
];
|
|
134
134
|
}).filter(import_util.isNonNullable).map(([meta, settings]) => ({
|
|
135
|
-
id: `${
|
|
135
|
+
id: `${import_chunk_JUSEAFDU.SETTINGS_KEY}:${meta.id.replaceAll("/", ":")}`,
|
|
136
136
|
type: "category",
|
|
137
137
|
data: settings,
|
|
138
138
|
properties: {
|
|
@@ -143,4 +143,4 @@ var app_graph_builder_default = (context) => (0, import_chunk_KRK7EH6Z.contribut
|
|
|
143
143
|
}
|
|
144
144
|
})
|
|
145
145
|
]);
|
|
146
|
-
//# sourceMappingURL=app-graph-builder-
|
|
146
|
+
//# sourceMappingURL=app-graph-builder-JZCSKYPY.cjs.map
|
|
@@ -16,15 +16,15 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
16
16
|
return to;
|
|
17
17
|
};
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var
|
|
20
|
-
__export(
|
|
19
|
+
var chunk_JUSEAFDU_exports = {};
|
|
20
|
+
__export(chunk_JUSEAFDU_exports, {
|
|
21
21
|
SETTINGS_ACTION: () => SETTINGS_ACTION,
|
|
22
22
|
SETTINGS_ID: () => SETTINGS_ID,
|
|
23
23
|
SETTINGS_KEY: () => SETTINGS_KEY,
|
|
24
24
|
SETTINGS_PLUGIN: () => SETTINGS_PLUGIN,
|
|
25
25
|
SettingsAction: () => SettingsAction
|
|
26
26
|
});
|
|
27
|
-
module.exports = __toCommonJS(
|
|
27
|
+
module.exports = __toCommonJS(chunk_JUSEAFDU_exports);
|
|
28
28
|
var import_effect = require("effect");
|
|
29
29
|
var SETTINGS_PLUGIN = "dxos.org/plugin/settings";
|
|
30
30
|
var SETTINGS_ACTION = `${SETTINGS_PLUGIN}/action`;
|
|
@@ -55,4 +55,4 @@ var SettingsAction;
|
|
|
55
55
|
SETTINGS_PLUGIN,
|
|
56
56
|
SettingsAction
|
|
57
57
|
});
|
|
58
|
-
//# sourceMappingURL=chunk-
|
|
58
|
+
//# sourceMappingURL=chunk-JUSEAFDU.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/plugin-settings/actions.ts"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Schema as S } from 'effect';\n\nexport const SETTINGS_PLUGIN = 'dxos.org/plugin/settings';\nexport const SETTINGS_ACTION = `${SETTINGS_PLUGIN}/action`;\nexport const SETTINGS_ID = '!dxos:settings';\nexport const SETTINGS_KEY = 'settings';\n\nexport namespace SettingsAction {\n export class Open extends S.TaggedClass<Open>()(`${SETTINGS_ACTION}/open`, {\n input: S.Struct({\n plugin: S.optional(S.String),\n }),\n output: S.Void,\n }) {}\n\n export class OpenPluginRegistry extends S.TaggedClass<OpenPluginRegistry>()(\n `${SETTINGS_ACTION}/open-plugin-registry`,\n {\n input: S.Void,\n output: S.Void,\n },\n ) {}\n}\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,oBAA4B;AAErB,IAAMA,kBAAkB;AACxB,IAAMC,kBAAkB,GAAGD,eAAAA;
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Schema as S } from 'effect';\n\nexport const SETTINGS_PLUGIN = 'dxos.org/plugin/settings';\nexport const SETTINGS_ACTION = `${SETTINGS_PLUGIN}/action`;\n// TODO(wittjosiah): This is a hack to prevent the previous deck from being set for pinned items.\n// Ideally this should be worked into the data model in a generic way.\nexport const SETTINGS_ID = '!dxos:settings';\nexport const SETTINGS_KEY = 'settings';\n\nexport namespace SettingsAction {\n export class Open extends S.TaggedClass<Open>()(`${SETTINGS_ACTION}/open`, {\n input: S.Struct({\n plugin: S.optional(S.String),\n }),\n output: S.Void,\n }) {}\n\n export class OpenPluginRegistry extends S.TaggedClass<OpenPluginRegistry>()(\n `${SETTINGS_ACTION}/open-plugin-registry`,\n {\n input: S.Void,\n output: S.Void,\n },\n ) {}\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,oBAA4B;AAErB,IAAMA,kBAAkB;AACxB,IAAMC,kBAAkB,GAAGD,eAAAA;AAG3B,IAAME,cAAc;AACpB,IAAMC,eAAe;;UAEXC,iBAAAA;EACR,MAAMC,aAAaC,cAAAA,OAAEC,YAAW,EAAS,GAAGN,eAAAA,SAAwB;IACzEO,OAAOF,cAAAA,OAAEG,OAAO;MACdC,QAAQJ,cAAAA,OAAEK,SAASL,cAAAA,OAAEM,MAAM;IAC7B,CAAA;IACAC,QAAQP,cAAAA,OAAEQ;EACZ,CAAA,EAAA;EAAI;kBALST,OAAAA;EAON,MAAMU,2BAA2BT,cAAAA,OAAEC,YAAW,EACnD,GAAGN,eAAAA,yBACH;IACEO,OAAOF,cAAAA,OAAEQ;IACTD,QAAQP,cAAAA,OAAEQ;EACZ,CAAA,EAAA;EACC;kBANUC,qBAAAA;AAOf,GAfiBX,mBAAAA,iBAAAA,CAAAA,EAAAA;",
|
|
6
6
|
"names": ["SETTINGS_PLUGIN", "SETTINGS_ACTION", "SETTINGS_ID", "SETTINGS_KEY", "SettingsAction", "Open", "S", "TaggedClass", "input", "Struct", "plugin", "optional", "String", "output", "Void", "OpenPluginRegistry"]
|
|
7
7
|
}
|