@dxos/plugin-registry 0.8.4-main.fffef41 → 0.8.4-staging.60fe92afc8
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 +102 -5
- package/dist/lib/neutral/RegistryPlugin.mjs +27 -0
- package/dist/lib/neutral/RegistryPlugin.mjs.map +7 -0
- package/dist/lib/neutral/RegistryPlugin.node.mjs +153 -0
- package/dist/lib/neutral/RegistryPlugin.node.mjs.map +7 -0
- package/dist/lib/neutral/RegistryPlugin.workerd.mjs +10 -0
- package/dist/lib/neutral/RegistryPlugin.workerd.mjs.map +7 -0
- package/dist/lib/neutral/chunk-GRQI6MLI.mjs +36 -0
- package/dist/lib/neutral/chunk-GRQI6MLI.mjs.map +7 -0
- package/dist/lib/neutral/chunk-XK2JMH3H.mjs +33 -0
- package/dist/lib/neutral/chunk-XK2JMH3H.mjs.map +7 -0
- package/dist/lib/neutral/index.mjs +25 -0
- package/dist/lib/neutral/index.mjs.map +7 -0
- package/dist/lib/neutral/meta.json +1 -0
- package/dist/lib/neutral/open-plugin-registry-II735N76.mjs +15 -0
- package/dist/lib/neutral/open-plugin-registry-II735N76.mjs.map +7 -0
- package/dist/lib/neutral/plugin.mjs +18 -0
- package/dist/lib/neutral/plugin.mjs.map +7 -0
- package/dist/lib/neutral/translations.mjs +72 -0
- package/dist/lib/neutral/translations.mjs.map +7 -0
- package/dist/types/src/RegistryPlugin.d.ts +3 -1
- package/dist/types/src/RegistryPlugin.d.ts.map +1 -1
- package/dist/types/src/RegistryPlugin.node.d.ts +4 -0
- package/dist/types/src/RegistryPlugin.node.d.ts.map +1 -0
- package/dist/types/src/RegistryPlugin.test.d.ts +2 -0
- package/dist/types/src/RegistryPlugin.test.d.ts.map +1 -0
- package/dist/types/src/RegistryPlugin.workerd.d.ts +4 -0
- package/dist/types/src/RegistryPlugin.workerd.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder.d.ts +4 -2
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
- package/dist/types/src/capabilities/dev-plugin-loader.d.ts +11 -0
- package/dist/types/src/capabilities/dev-plugin-loader.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +15 -3
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/operation-handler.d.ts +6 -0
- package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface.d.ts +3 -2
- package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
- package/dist/types/src/capabilities/settings.d.ts +14 -0
- package/dist/types/src/capabilities/settings.d.ts.map +1 -0
- package/dist/types/src/categories.d.ts +18 -0
- package/dist/types/src/categories.d.ts.map +1 -0
- package/dist/types/src/commands/disable.d.ts +11 -0
- package/dist/types/src/commands/disable.d.ts.map +1 -0
- package/dist/types/src/commands/enable.d.ts +11 -0
- package/dist/types/src/commands/enable.d.ts.map +1 -0
- package/dist/types/src/commands/index.d.ts +3 -0
- package/dist/types/src/commands/index.d.ts.map +1 -0
- package/dist/types/src/commands/list.d.ts +7 -0
- package/dist/types/src/commands/list.d.ts.map +1 -0
- package/dist/types/src/commands/util.d.ts +11 -0
- package/dist/types/src/commands/util.d.ts.map +1 -0
- package/dist/types/src/components/DisableDependentsAlert/DisableDependentsAlert.d.ts +24 -0
- package/dist/types/src/components/DisableDependentsAlert/DisableDependentsAlert.d.ts.map +1 -0
- package/dist/types/src/components/DisableDependentsAlert/index.d.ts +2 -0
- package/dist/types/src/components/DisableDependentsAlert/index.d.ts.map +1 -0
- package/dist/types/src/components/PluginDetail/PluginDetail.d.ts +82 -0
- package/dist/types/src/components/PluginDetail/PluginDetail.d.ts.map +1 -0
- package/dist/types/src/components/PluginDetail/PluginDetail.stories.d.ts +79 -0
- package/dist/types/src/components/PluginDetail/PluginDetail.stories.d.ts.map +1 -0
- package/dist/types/src/components/PluginDetail/index.d.ts +2 -0
- package/dist/types/src/components/PluginDetail/index.d.ts.map +1 -0
- package/dist/types/src/components/PluginFailureBadge/PluginFailureBadge.d.ts +20 -0
- package/dist/types/src/components/PluginFailureBadge/PluginFailureBadge.d.ts.map +1 -0
- package/dist/types/src/components/PluginFailureBadge/index.d.ts +2 -0
- package/dist/types/src/components/PluginFailureBadge/index.d.ts.map +1 -0
- package/dist/types/src/components/PluginList/PluginItem.d.ts +40 -0
- package/dist/types/src/components/PluginList/PluginItem.d.ts.map +1 -0
- package/dist/types/src/components/PluginList/PluginList.d.ts +23 -0
- package/dist/types/src/components/PluginList/PluginList.d.ts.map +1 -0
- package/dist/types/src/components/PluginList/PluginList.stories.d.ts +78 -0
- package/dist/types/src/components/PluginList/PluginList.stories.d.ts.map +1 -0
- package/dist/types/src/components/PluginList/index.d.ts +2 -0
- package/dist/types/src/components/PluginList/index.d.ts.map +1 -0
- package/dist/types/src/components/RegistrySettings/RegistrySettings.d.ts +18 -0
- package/dist/types/src/components/RegistrySettings/RegistrySettings.d.ts.map +1 -0
- package/dist/types/src/components/RegistrySettings/index.d.ts +2 -0
- package/dist/types/src/components/RegistrySettings/index.d.ts.map +1 -0
- package/dist/types/src/components/index.d.ts +3 -1
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/containers/BaseRegistryArticle/BaseRegistryArticle.d.ts +20 -0
- package/dist/types/src/containers/BaseRegistryArticle/BaseRegistryArticle.d.ts.map +1 -0
- package/dist/types/src/containers/BaseRegistryArticle/index.d.ts +2 -0
- package/dist/types/src/containers/BaseRegistryArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/LoadPluginDialog/LoadPluginDialog.d.ts +5 -0
- package/dist/types/src/containers/LoadPluginDialog/LoadPluginDialog.d.ts.map +1 -0
- package/dist/types/src/containers/LoadPluginDialog/index.d.ts +2 -0
- package/dist/types/src/containers/LoadPluginDialog/index.d.ts.map +1 -0
- package/dist/types/src/containers/PluginArticle/PluginArticle.d.ts +7 -0
- package/dist/types/src/containers/PluginArticle/PluginArticle.d.ts.map +1 -0
- package/dist/types/src/containers/PluginArticle/index.d.ts +2 -0
- package/dist/types/src/containers/PluginArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/PublicRegistryArticle/PublicRegistryArticle.d.ts +8 -0
- package/dist/types/src/containers/PublicRegistryArticle/PublicRegistryArticle.d.ts.map +1 -0
- package/dist/types/src/containers/PublicRegistryArticle/index.d.ts +2 -0
- package/dist/types/src/containers/PublicRegistryArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/RegistryArticle/RegistryArticle.d.ts +14 -0
- package/dist/types/src/containers/RegistryArticle/RegistryArticle.d.ts.map +1 -0
- package/dist/types/src/containers/RegistryArticle/index.d.ts +2 -0
- package/dist/types/src/containers/RegistryArticle/index.d.ts.map +1 -0
- package/dist/types/src/containers/RegistrySettingsContainer/RegistrySettingsContainer.d.ts +13 -0
- package/dist/types/src/containers/RegistrySettingsContainer/RegistrySettingsContainer.d.ts.map +1 -0
- package/dist/types/src/containers/RegistrySettingsContainer/index.d.ts +2 -0
- package/dist/types/src/containers/RegistrySettingsContainer/index.d.ts.map +1 -0
- package/dist/types/src/containers/index.d.ts +8 -0
- package/dist/types/src/containers/index.d.ts.map +1 -0
- package/dist/types/src/hooks/index.d.ts +9 -0
- package/dist/types/src/hooks/index.d.ts.map +1 -0
- package/dist/types/src/hooks/useAutoTags.d.ts +20 -0
- package/dist/types/src/hooks/useAutoTags.d.ts.map +1 -0
- package/dist/types/src/hooks/useCatalogEntry.d.ts +11 -0
- package/dist/types/src/hooks/useCatalogEntry.d.ts.map +1 -0
- package/dist/types/src/hooks/useDisableConfirmation.d.ts +19 -0
- package/dist/types/src/hooks/useDisableConfirmation.d.ts.map +1 -0
- package/dist/types/src/hooks/useInstalledVersionTag.d.ts +18 -0
- package/dist/types/src/hooks/useInstalledVersionTag.d.ts.map +1 -0
- package/dist/types/src/hooks/usePluginActions.d.ts +36 -0
- package/dist/types/src/hooks/usePluginActions.d.ts.map +1 -0
- package/dist/types/src/hooks/useRegistryPlugins.d.ts +15 -0
- package/dist/types/src/hooks/useRegistryPlugins.d.ts.map +1 -0
- package/dist/types/src/hooks/useUpdateAvailable.d.ts +18 -0
- package/dist/types/src/hooks/useUpdateAvailable.d.ts.map +1 -0
- package/dist/types/src/hooks/useVersionPicker.d.ts +21 -0
- package/dist/types/src/hooks/useVersionPicker.d.ts.map +1 -0
- package/dist/types/src/index.d.ts +1 -1
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +21 -3
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/operations/index.d.ts +3 -0
- package/dist/types/src/operations/index.d.ts.map +1 -0
- package/dist/types/src/operations/open-plugin-registry.d.ts +5 -0
- package/dist/types/src/operations/open-plugin-registry.d.ts.map +1 -0
- package/dist/types/src/plugin.d.ts +4 -0
- package/dist/types/src/plugin.d.ts.map +1 -0
- package/dist/types/src/storage.d.ts +18 -0
- package/dist/types/src/storage.d.ts.map +1 -0
- package/dist/types/src/translations.d.ts +59 -16
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types.d.ts +30 -1
- package/dist/types/src/types.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +76 -35
- package/src/RegistryPlugin.node.ts +19 -0
- package/src/RegistryPlugin.test.ts +24 -0
- package/src/RegistryPlugin.tsx +19 -25
- package/src/RegistryPlugin.workerd.ts +11 -0
- package/src/capabilities/app-graph-builder.ts +199 -136
- package/src/capabilities/dev-plugin-loader.ts +39 -0
- package/src/capabilities/index.ts +10 -4
- package/src/capabilities/operation-handler.ts +16 -0
- package/src/capabilities/react-surface.tsx +115 -75
- package/src/capabilities/settings.ts +34 -0
- package/src/categories.ts +44 -0
- package/src/commands/disable.ts +47 -0
- package/src/commands/enable.ts +44 -0
- package/src/commands/index.ts +14 -0
- package/src/commands/list.ts +41 -0
- package/src/commands/util.ts +24 -0
- package/src/components/DisableDependentsAlert/DisableDependentsAlert.tsx +69 -0
- package/src/components/DisableDependentsAlert/index.ts +5 -0
- package/src/components/{PluginDetail.stories.tsx → PluginDetail/PluginDetail.stories.tsx} +14 -11
- package/src/components/PluginDetail/PluginDetail.tsx +345 -0
- package/src/components/PluginDetail/index.ts +5 -0
- package/src/components/PluginFailureBadge/PluginFailureBadge.tsx +68 -0
- package/src/components/PluginFailureBadge/index.ts +5 -0
- package/src/components/PluginList/PluginItem.tsx +223 -0
- package/src/components/PluginList/PluginList.stories.tsx +90 -0
- package/src/components/PluginList/PluginList.tsx +52 -0
- package/src/components/PluginList/index.ts +5 -0
- package/src/components/RegistrySettings/RegistrySettings.tsx +120 -0
- package/src/components/RegistrySettings/index.ts +5 -0
- package/src/components/index.ts +3 -1
- package/src/containers/BaseRegistryArticle/BaseRegistryArticle.tsx +178 -0
- package/src/containers/BaseRegistryArticle/index.ts +5 -0
- package/src/containers/LoadPluginDialog/LoadPluginDialog.tsx +88 -0
- package/src/containers/LoadPluginDialog/index.ts +5 -0
- package/src/containers/PluginArticle/PluginArticle.tsx +117 -0
- package/src/containers/PluginArticle/index.ts +5 -0
- package/src/containers/PublicRegistryArticle/PublicRegistryArticle.tsx +193 -0
- package/src/containers/PublicRegistryArticle/index.ts +5 -0
- package/src/containers/RegistryArticle/RegistryArticle.tsx +53 -0
- package/src/containers/RegistryArticle/index.ts +5 -0
- package/src/containers/RegistrySettingsContainer/RegistrySettingsContainer.tsx +59 -0
- package/src/containers/RegistrySettingsContainer/index.ts +5 -0
- package/src/containers/index.ts +12 -0
- package/src/hooks/index.ts +12 -0
- package/src/hooks/useAutoTags.ts +52 -0
- package/src/hooks/useCatalogEntry.ts +25 -0
- package/src/hooks/useDisableConfirmation.ts +58 -0
- package/src/hooks/useInstalledVersionTag.ts +41 -0
- package/src/hooks/usePluginActions.ts +177 -0
- package/src/hooks/useRegistryPlugins.ts +29 -0
- package/src/hooks/useUpdateAvailable.ts +31 -0
- package/src/hooks/useVersionPicker.ts +112 -0
- package/src/index.ts +1 -1
- package/src/meta.ts +34 -8
- package/src/operations/index.ts +7 -0
- package/src/operations/open-plugin-registry.ts +21 -0
- package/src/plugin.ts +11 -0
- package/src/storage.ts +50 -0
- package/src/translations.ts +64 -15
- package/src/types.ts +33 -1
- package/dist/lib/browser/app-graph-builder-6CNBP3A4.mjs +0 -162
- package/dist/lib/browser/app-graph-builder-6CNBP3A4.mjs.map +0 -7
- package/dist/lib/browser/chunk-XPEFEID2.mjs +0 -19
- package/dist/lib/browser/chunk-XPEFEID2.mjs.map +0 -7
- package/dist/lib/browser/index.mjs +0 -69
- package/dist/lib/browser/index.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/meta.json +0 -1
- package/dist/lib/browser/react-surface-IGCXOVE2.mjs +0 -359
- package/dist/lib/browser/react-surface-IGCXOVE2.mjs.map +0 -7
- 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/components/PluginDetail.d.ts +0 -9
- package/dist/types/src/components/PluginDetail.d.ts.map +0 -1
- package/dist/types/src/components/PluginDetail.stories.d.ts +0 -32
- package/dist/types/src/components/PluginDetail.stories.d.ts.map +0 -1
- package/dist/types/src/components/PluginItem.d.ts +0 -13
- package/dist/types/src/components/PluginItem.d.ts.map +0 -1
- package/dist/types/src/components/PluginList.d.ts +0 -8
- package/dist/types/src/components/PluginList.d.ts.map +0 -1
- package/dist/types/src/components/PluginList.stories.d.ts +0 -34
- package/dist/types/src/components/PluginList.stories.d.ts.map +0 -1
- package/dist/types/src/components/RegistryContainer.d.ts +0 -7
- package/dist/types/src/components/RegistryContainer.d.ts.map +0 -1
- package/src/capabilities/intent-resolver.ts +0 -27
- package/src/components/PluginDetail.tsx +0 -82
- package/src/components/PluginItem.tsx +0 -120
- package/src/components/PluginList.stories.tsx +0 -80
- package/src/components/PluginList.tsx +0 -24
- package/src/components/RegistryContainer.tsx +0 -76
package/LICENSE
CHANGED
|
@@ -1,8 +1,105 @@
|
|
|
1
|
-
|
|
2
|
-
Copyright (c) 2022 DXOS
|
|
1
|
+
# Functional Source License, Version 1.1, ALv2 Future License
|
|
3
2
|
|
|
4
|
-
|
|
3
|
+
## Abbreviation
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
FSL-1.1-Apache-2.0
|
|
7
6
|
|
|
8
|
-
|
|
7
|
+
## Notice
|
|
8
|
+
|
|
9
|
+
Copyright 2026 DXOS
|
|
10
|
+
|
|
11
|
+
## Terms and Conditions
|
|
12
|
+
|
|
13
|
+
### Licensor ("We")
|
|
14
|
+
|
|
15
|
+
The party offering the Software under these Terms and Conditions.
|
|
16
|
+
|
|
17
|
+
### The Software
|
|
18
|
+
|
|
19
|
+
The "Software" is each version of the software that we make available under
|
|
20
|
+
these Terms and Conditions, as indicated by our inclusion of these Terms and
|
|
21
|
+
Conditions with the Software.
|
|
22
|
+
|
|
23
|
+
### License Grant
|
|
24
|
+
|
|
25
|
+
Subject to your compliance with this License Grant and the Patents,
|
|
26
|
+
Redistribution and Trademark clauses below, we hereby grant you the right to
|
|
27
|
+
use, copy, modify, create derivative works, publicly perform, publicly display
|
|
28
|
+
and redistribute the Software for any Permitted Purpose identified below.
|
|
29
|
+
|
|
30
|
+
### Permitted Purpose
|
|
31
|
+
|
|
32
|
+
A Permitted Purpose is any purpose other than a Competing Use. A Competing Use
|
|
33
|
+
means making the Software available to others in a commercial product or
|
|
34
|
+
service that:
|
|
35
|
+
|
|
36
|
+
1. substitutes for the Software;
|
|
37
|
+
|
|
38
|
+
2. substitutes for any other product or service we offer using the Software
|
|
39
|
+
that exists as of the date we make the Software available; or
|
|
40
|
+
|
|
41
|
+
3. offers the same or substantially similar functionality as the Software.
|
|
42
|
+
|
|
43
|
+
Permitted Purposes specifically include using the Software:
|
|
44
|
+
|
|
45
|
+
1. for your internal use and access;
|
|
46
|
+
|
|
47
|
+
2. for non-commercial education;
|
|
48
|
+
|
|
49
|
+
3. for non-commercial research; and
|
|
50
|
+
|
|
51
|
+
4. in connection with professional services that you provide to a licensee
|
|
52
|
+
using the Software in accordance with these Terms and Conditions.
|
|
53
|
+
|
|
54
|
+
### Patents
|
|
55
|
+
|
|
56
|
+
To the extent your use for a Permitted Purpose would necessarily infringe our
|
|
57
|
+
patents, the license grant above includes a license under our patents. If you
|
|
58
|
+
make a claim against any party that the Software infringes or contributes to
|
|
59
|
+
the infringement of any patent, then your patent license to the Software ends
|
|
60
|
+
immediately.
|
|
61
|
+
|
|
62
|
+
### Redistribution
|
|
63
|
+
|
|
64
|
+
The Terms and Conditions apply to all copies, modifications and derivatives of
|
|
65
|
+
the Software.
|
|
66
|
+
|
|
67
|
+
If you redistribute any copies, modifications or derivatives of the Software,
|
|
68
|
+
you must include a copy of or a link to these Terms and Conditions and not
|
|
69
|
+
remove any copyright notices provided in or with the Software.
|
|
70
|
+
|
|
71
|
+
### Disclaimer
|
|
72
|
+
|
|
73
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND, EXPRESS OR
|
|
74
|
+
IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR
|
|
75
|
+
PURPOSE, MERCHANTABILITY, TITLE OR NON-INFRINGEMENT.
|
|
76
|
+
|
|
77
|
+
IN NO EVENT WILL WE HAVE ANY LIABILITY TO YOU ARISING OUT OF OR RELATED TO THE
|
|
78
|
+
SOFTWARE, INCLUDING INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES,
|
|
79
|
+
EVEN IF WE HAVE BEEN INFORMED OF THEIR POSSIBILITY IN ADVANCE.
|
|
80
|
+
|
|
81
|
+
### Trademarks
|
|
82
|
+
|
|
83
|
+
Except for displaying the License Details and identifying us as the origin of
|
|
84
|
+
the Software, you have no right under these Terms and Conditions to use our
|
|
85
|
+
trademarks, trade names, service marks or product names.
|
|
86
|
+
|
|
87
|
+
## Grant of Future License
|
|
88
|
+
|
|
89
|
+
We hereby irrevocably grant you an additional license to use the Software under
|
|
90
|
+
the Apache License, Version 2.0 that is effective on the second anniversary of
|
|
91
|
+
the date we make the Software available. On or after that date, you may use the
|
|
92
|
+
Software under the Apache License, Version 2.0, in which case the following
|
|
93
|
+
will apply:
|
|
94
|
+
|
|
95
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
96
|
+
this file except in compliance with the License.
|
|
97
|
+
|
|
98
|
+
You may obtain a copy of the License at
|
|
99
|
+
|
|
100
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
101
|
+
|
|
102
|
+
Unless required by applicable law or agreed to in writing, software distributed
|
|
103
|
+
under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
|
|
104
|
+
CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
|
105
|
+
specific language governing permissions and limitations under the License.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
// src/RegistryPlugin.tsx
|
|
2
|
+
import { ActivationEvents, Plugin } from "@dxos/app-framework";
|
|
3
|
+
import { AppPlugin } from "@dxos/app-toolkit";
|
|
4
|
+
import { AppGraphBuilder, DevPluginLoader, OperationHandler, ReactSurface, RegistrySettings } from "#capabilities";
|
|
5
|
+
import { meta } from "#meta";
|
|
6
|
+
import { translations } from "#translations";
|
|
7
|
+
var RegistryPlugin = Plugin.define(meta).pipe(AppPlugin.addAppGraphModule({
|
|
8
|
+
activate: AppGraphBuilder
|
|
9
|
+
}), AppPlugin.addOperationHandlerModule({
|
|
10
|
+
activate: OperationHandler
|
|
11
|
+
}), AppPlugin.addSettingsModule({
|
|
12
|
+
activate: RegistrySettings
|
|
13
|
+
}), AppPlugin.addSurfaceModule({
|
|
14
|
+
activate: ReactSurface
|
|
15
|
+
}), AppPlugin.addTranslationsModule({
|
|
16
|
+
translations
|
|
17
|
+
}), Plugin.addModule({
|
|
18
|
+
id: "dev-plugin-loader",
|
|
19
|
+
activatesOn: ActivationEvents.Startup,
|
|
20
|
+
activate: DevPluginLoader
|
|
21
|
+
}), Plugin.make);
|
|
22
|
+
var RegistryPlugin_default = RegistryPlugin;
|
|
23
|
+
export {
|
|
24
|
+
RegistryPlugin,
|
|
25
|
+
RegistryPlugin_default as default
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=RegistryPlugin.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/RegistryPlugin.tsx"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { ActivationEvents, Plugin } from '@dxos/app-framework';\nimport { AppPlugin } from '@dxos/app-toolkit';\n\nimport { AppGraphBuilder, DevPluginLoader, OperationHandler, ReactSurface, RegistrySettings } from '#capabilities';\nimport { meta } from '#meta';\nimport { translations } from '#translations';\n\nexport const RegistryPlugin = Plugin.define(meta).pipe(\n AppPlugin.addAppGraphModule({ activate: AppGraphBuilder }),\n AppPlugin.addOperationHandlerModule({ activate: OperationHandler }),\n AppPlugin.addSettingsModule({ activate: RegistrySettings }),\n AppPlugin.addSurfaceModule({ activate: ReactSurface }),\n AppPlugin.addTranslationsModule({ translations }),\n Plugin.addModule({\n id: 'dev-plugin-loader',\n activatesOn: ActivationEvents.Startup,\n activate: DevPluginLoader,\n }),\n Plugin.make,\n);\n\nexport default RegistryPlugin;\n"],
|
|
5
|
+
"mappings": ";AAIA,SAASA,kBAAkBC,cAAc;AACzC,SAASC,iBAAiB;AAE1B,SAASC,iBAAiBC,iBAAiBC,kBAAkBC,cAAcC,wBAAwB;AACnG,SAASC,YAAY;AACrB,SAASC,oBAAoB;AAEtB,IAAMC,iBAAiBT,OAAOU,OAAOH,IAAAA,EAAMI,KAChDV,UAAUW,kBAAkB;EAAEC,UAAUX;AAAgB,CAAA,GACxDD,UAAUa,0BAA0B;EAAED,UAAUT;AAAiB,CAAA,GACjEH,UAAUc,kBAAkB;EAAEF,UAAUP;AAAiB,CAAA,GACzDL,UAAUe,iBAAiB;EAAEH,UAAUR;AAAa,CAAA,GACpDJ,UAAUgB,sBAAsB;EAAET;AAAa,CAAA,GAC/CR,OAAOkB,UAAU;EACfC,IAAI;EACJC,aAAarB,iBAAiBsB;EAC9BR,UAAUV;AACZ,CAAA,GACAH,OAAOsB,IAAI;AAGb,IAAA,yBAAeb;",
|
|
6
|
+
"names": ["ActivationEvents", "Plugin", "AppPlugin", "AppGraphBuilder", "DevPluginLoader", "OperationHandler", "ReactSurface", "RegistrySettings", "meta", "translations", "RegistryPlugin", "define", "pipe", "addAppGraphModule", "activate", "addOperationHandlerModule", "addSettingsModule", "addSurfaceModule", "addTranslationsModule", "addModule", "id", "activatesOn", "Startup", "make"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import {
|
|
2
|
+
saveEnabledPlugins
|
|
3
|
+
} from "./chunk-XK2JMH3H.mjs";
|
|
4
|
+
|
|
5
|
+
// src/RegistryPlugin.node.ts
|
|
6
|
+
import { Plugin as Plugin4 } from "@dxos/app-framework";
|
|
7
|
+
import { AppPlugin } from "@dxos/app-toolkit";
|
|
8
|
+
import { meta } from "#meta";
|
|
9
|
+
|
|
10
|
+
// src/commands/index.ts
|
|
11
|
+
import * as Command4 from "@effect/cli/Command";
|
|
12
|
+
|
|
13
|
+
// src/commands/disable.ts
|
|
14
|
+
import * as Args from "@effect/cli/Args";
|
|
15
|
+
import * as Command from "@effect/cli/Command";
|
|
16
|
+
import * as Console from "effect/Console";
|
|
17
|
+
import * as Effect from "effect/Effect";
|
|
18
|
+
import { Plugin } from "@dxos/app-framework";
|
|
19
|
+
import { CommandConfig } from "@dxos/cli-util";
|
|
20
|
+
import { invariant } from "@dxos/invariant";
|
|
21
|
+
var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-registry/src/commands/disable.ts";
|
|
22
|
+
var handler = Effect.fn(function* ({ id }) {
|
|
23
|
+
const { json, profile } = yield* CommandConfig;
|
|
24
|
+
const manager = yield* Plugin.Service;
|
|
25
|
+
const plugins = manager.getPlugins();
|
|
26
|
+
const plugin2 = plugins.find((p) => p.meta.id === id);
|
|
27
|
+
invariant(plugin2, `Plugin not found: ${id}`, { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 17, S: this, A: ["plugin", "`Plugin not found: ${id}`"] });
|
|
28
|
+
const core = manager.getCore();
|
|
29
|
+
invariant(!core.includes(id), `Cannot disable core plugin: ${id}`, { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 19, S: this, A: ["!core.includes(id)", "`Cannot disable core plugin: ${id}`"] });
|
|
30
|
+
const disabled = yield* manager.disable(id);
|
|
31
|
+
invariant(disabled, `Failed to disable plugin: ${id}`, { "~LogMeta": "~LogMeta", F: __dxlog_file, L: 21, S: this, A: ["disabled", "`Failed to disable plugin: ${id}`"] });
|
|
32
|
+
const enabledPlugins = manager.getEnabled();
|
|
33
|
+
yield* saveEnabledPlugins({
|
|
34
|
+
profile,
|
|
35
|
+
enabled: [
|
|
36
|
+
...enabledPlugins
|
|
37
|
+
]
|
|
38
|
+
});
|
|
39
|
+
if (json) {
|
|
40
|
+
yield* Console.log(JSON.stringify({
|
|
41
|
+
id,
|
|
42
|
+
enabled: false
|
|
43
|
+
}, null, 2));
|
|
44
|
+
} else {
|
|
45
|
+
yield* Console.log(`Plugin "${plugin2.meta.name ?? id}" disabled.`);
|
|
46
|
+
}
|
|
47
|
+
});
|
|
48
|
+
var disable = Command.make("disable", {
|
|
49
|
+
id: Args.text({
|
|
50
|
+
name: "id"
|
|
51
|
+
}).pipe(Args.withDescription("The ID of the plugin to disable."))
|
|
52
|
+
}, handler).pipe(Command.withDescription("Disable a plugin."));
|
|
53
|
+
|
|
54
|
+
// src/commands/enable.ts
|
|
55
|
+
import * as Args2 from "@effect/cli/Args";
|
|
56
|
+
import * as Command2 from "@effect/cli/Command";
|
|
57
|
+
import * as Console2 from "effect/Console";
|
|
58
|
+
import * as Effect2 from "effect/Effect";
|
|
59
|
+
import { Plugin as Plugin2 } from "@dxos/app-framework";
|
|
60
|
+
import { CommandConfig as CommandConfig2 } from "@dxos/cli-util";
|
|
61
|
+
import { invariant as invariant2 } from "@dxos/invariant";
|
|
62
|
+
var __dxlog_file2 = "/__w/dxos/dxos/packages/plugins/plugin-registry/src/commands/enable.ts";
|
|
63
|
+
var handler2 = Effect2.fn(function* ({ id }) {
|
|
64
|
+
const { json, profile } = yield* CommandConfig2;
|
|
65
|
+
const manager = yield* Plugin2.Service;
|
|
66
|
+
const plugins = manager.getPlugins();
|
|
67
|
+
const plugin2 = plugins.find((p) => p.meta.id === id);
|
|
68
|
+
invariant2(plugin2, `Plugin not found: ${id}`, { "~LogMeta": "~LogMeta", F: __dxlog_file2, L: 17, S: this, A: ["plugin", "`Plugin not found: ${id}`"] });
|
|
69
|
+
const enabled = yield* manager.enable(id);
|
|
70
|
+
invariant2(enabled, `Failed to enable plugin: ${id}`, { "~LogMeta": "~LogMeta", F: __dxlog_file2, L: 19, S: this, A: ["enabled", "`Failed to enable plugin: ${id}`"] });
|
|
71
|
+
const enabledPlugins = manager.getEnabled();
|
|
72
|
+
yield* saveEnabledPlugins({
|
|
73
|
+
profile,
|
|
74
|
+
enabled: [
|
|
75
|
+
...enabledPlugins
|
|
76
|
+
]
|
|
77
|
+
});
|
|
78
|
+
if (json) {
|
|
79
|
+
yield* Console2.log(JSON.stringify({
|
|
80
|
+
id,
|
|
81
|
+
enabled: true
|
|
82
|
+
}, null, 2));
|
|
83
|
+
} else {
|
|
84
|
+
yield* Console2.log(`Plugin "${plugin2.meta.name ?? id}" enabled.`);
|
|
85
|
+
}
|
|
86
|
+
});
|
|
87
|
+
var enable = Command2.make("enable", {
|
|
88
|
+
id: Args2.text({
|
|
89
|
+
name: "id"
|
|
90
|
+
}).pipe(Args2.withDescription("The ID of the plugin to enable."))
|
|
91
|
+
}, handler2).pipe(Command2.withDescription("Enable a plugin."));
|
|
92
|
+
|
|
93
|
+
// src/commands/list.ts
|
|
94
|
+
import * as Command3 from "@effect/cli/Command";
|
|
95
|
+
import * as Console3 from "effect/Console";
|
|
96
|
+
import * as Effect3 from "effect/Effect";
|
|
97
|
+
import { Plugin as Plugin3 } from "@dxos/app-framework";
|
|
98
|
+
import { CommandConfig as CommandConfig3, printList } from "@dxos/cli-util";
|
|
99
|
+
|
|
100
|
+
// src/commands/util.ts
|
|
101
|
+
import { FormBuilder } from "@dxos/cli-util";
|
|
102
|
+
var printPlugin = (plugin2) => {
|
|
103
|
+
const status = plugin2.core ? "core" : plugin2.enabled ? "enabled" : "disabled";
|
|
104
|
+
return FormBuilder.make({
|
|
105
|
+
title: plugin2.name
|
|
106
|
+
}).pipe(FormBuilder.set("id", plugin2.id), FormBuilder.set("status", status), FormBuilder.build);
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
// src/commands/list.ts
|
|
110
|
+
var handler3 = Effect3.fn(function* () {
|
|
111
|
+
const { json } = yield* CommandConfig3;
|
|
112
|
+
const manager = yield* Plugin3.Service;
|
|
113
|
+
const plugins = manager.getPlugins();
|
|
114
|
+
const enabled = manager.getEnabled();
|
|
115
|
+
const core = manager.getCore();
|
|
116
|
+
const formattedPlugins = plugins.map((plugin2) => {
|
|
117
|
+
const isEnabled = enabled.includes(plugin2.meta.id);
|
|
118
|
+
const isCore = core.includes(plugin2.meta.id);
|
|
119
|
+
return {
|
|
120
|
+
id: plugin2.meta.id,
|
|
121
|
+
name: plugin2.meta.name ?? plugin2.meta.id,
|
|
122
|
+
enabled: isEnabled,
|
|
123
|
+
core: isCore
|
|
124
|
+
};
|
|
125
|
+
});
|
|
126
|
+
if (json) {
|
|
127
|
+
yield* Console3.log(JSON.stringify(formattedPlugins, null, 2));
|
|
128
|
+
} else {
|
|
129
|
+
const formatted = formattedPlugins.map(printPlugin);
|
|
130
|
+
yield* Console3.log(printList(formatted));
|
|
131
|
+
}
|
|
132
|
+
});
|
|
133
|
+
var list = Command3.make("list", {}, handler3).pipe(Command3.withDescription("List all available plugins."));
|
|
134
|
+
|
|
135
|
+
// src/commands/index.ts
|
|
136
|
+
var plugin = Command4.make("plugin").pipe(Command4.withDescription("Manage plugins."), Command4.withSubcommands([
|
|
137
|
+
enable,
|
|
138
|
+
disable,
|
|
139
|
+
list
|
|
140
|
+
]));
|
|
141
|
+
|
|
142
|
+
// src/RegistryPlugin.node.ts
|
|
143
|
+
var RegistryPlugin = Plugin4.define(meta).pipe(AppPlugin.addCommandModule({
|
|
144
|
+
commands: [
|
|
145
|
+
plugin
|
|
146
|
+
]
|
|
147
|
+
}), Plugin4.make);
|
|
148
|
+
var RegistryPlugin_node_default = RegistryPlugin;
|
|
149
|
+
export {
|
|
150
|
+
RegistryPlugin,
|
|
151
|
+
RegistryPlugin_node_default as default
|
|
152
|
+
};
|
|
153
|
+
//# sourceMappingURL=RegistryPlugin.node.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/RegistryPlugin.node.ts", "../../../src/commands/index.ts", "../../../src/commands/disable.ts", "../../../src/commands/enable.ts", "../../../src/commands/list.ts", "../../../src/commands/util.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Plugin } from '@dxos/app-framework';\nimport { AppPlugin } from '@dxos/app-toolkit';\n\nimport { meta } from '#meta';\n\nimport { plugin } from './commands';\n\nexport const RegistryPlugin = Plugin.define(meta).pipe(\n AppPlugin.addCommandModule({\n commands: [plugin],\n }),\n Plugin.make,\n);\n\nexport default RegistryPlugin;\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Command from '@effect/cli/Command';\n\nimport { disable } from './disable';\nimport { enable } from './enable';\nimport { list } from './list';\n\nexport const plugin: Command.Command<any, any, any, any> = Command.make('plugin').pipe(\n Command.withDescription('Manage plugins.'),\n Command.withSubcommands([enable, disable, list]),\n);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Args from '@effect/cli/Args';\nimport * as Command from '@effect/cli/Command';\nimport * as Console from 'effect/Console';\nimport * as Effect from 'effect/Effect';\n\nimport { Plugin } from '@dxos/app-framework';\nimport { CommandConfig } from '@dxos/cli-util';\nimport { invariant } from '@dxos/invariant';\n\nimport { saveEnabledPlugins } from '../storage';\n\nexport const handler = Effect.fn(function* ({ id }: { id: string }) {\n const { json, profile } = yield* CommandConfig;\n const manager = yield* Plugin.Service;\n\n const plugins = manager.getPlugins();\n const plugin = plugins.find((p: Plugin.Plugin) => p.meta.id === id);\n invariant(plugin, `Plugin not found: ${id}`);\n\n const core = manager.getCore();\n invariant(!core.includes(id), `Cannot disable core plugin: ${id}`);\n\n const disabled = yield* manager.disable(id);\n invariant(disabled, `Failed to disable plugin: ${id}`);\n\n // Save enabled plugins to storage\n const enabledPlugins = manager.getEnabled();\n yield* saveEnabledPlugins({ profile, enabled: [...enabledPlugins] });\n\n if (json) {\n yield* Console.log(JSON.stringify({ id, enabled: false }, null, 2));\n } else {\n yield* Console.log(`Plugin \"${plugin.meta.name ?? id}\" disabled.`);\n }\n});\n\nexport const disable = Command.make(\n 'disable',\n {\n id: Args.text({ name: 'id' }).pipe(Args.withDescription('The ID of the plugin to disable.')),\n },\n handler,\n).pipe(Command.withDescription('Disable a plugin.'));\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Args from '@effect/cli/Args';\nimport * as Command from '@effect/cli/Command';\nimport * as Console from 'effect/Console';\nimport * as Effect from 'effect/Effect';\n\nimport { Plugin } from '@dxos/app-framework';\nimport { CommandConfig } from '@dxos/cli-util';\nimport { invariant } from '@dxos/invariant';\n\nimport { saveEnabledPlugins } from '../storage';\n\nexport const handler = Effect.fn(function* ({ id }: { id: string }) {\n const { json, profile } = yield* CommandConfig;\n const manager = yield* Plugin.Service;\n\n const plugins = manager.getPlugins();\n const plugin = plugins.find((p: Plugin.Plugin) => p.meta.id === id);\n invariant(plugin, `Plugin not found: ${id}`);\n\n const enabled = yield* manager.enable(id);\n invariant(enabled, `Failed to enable plugin: ${id}`);\n\n // Save enabled plugins to storage\n const enabledPlugins = manager.getEnabled();\n yield* saveEnabledPlugins({ profile, enabled: [...enabledPlugins] });\n\n if (json) {\n yield* Console.log(JSON.stringify({ id, enabled: true }, null, 2));\n } else {\n yield* Console.log(`Plugin \"${plugin.meta.name ?? id}\" enabled.`);\n }\n});\n\nexport const enable = Command.make(\n 'enable',\n {\n id: Args.text({ name: 'id' }).pipe(Args.withDescription('The ID of the plugin to enable.')),\n },\n handler,\n).pipe(Command.withDescription('Enable a plugin.'));\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Command from '@effect/cli/Command';\nimport * as Console from 'effect/Console';\nimport * as Effect from 'effect/Effect';\n\nimport { Plugin } from '@dxos/app-framework';\nimport { CommandConfig, printList } from '@dxos/cli-util';\n\nimport { type FormattedPlugin, printPlugin } from './util';\n\nexport const handler = Effect.fn(function* () {\n const { json } = yield* CommandConfig;\n const manager = yield* Plugin.Service;\n\n const plugins = manager.getPlugins();\n const enabled = manager.getEnabled();\n const core = manager.getCore();\n\n const formattedPlugins: FormattedPlugin[] = plugins.map((plugin: Plugin.Plugin) => {\n const isEnabled = enabled.includes(plugin.meta.id);\n const isCore = core.includes(plugin.meta.id);\n return {\n id: plugin.meta.id,\n name: plugin.meta.name ?? plugin.meta.id,\n enabled: isEnabled,\n core: isCore,\n };\n });\n\n if (json) {\n yield* Console.log(JSON.stringify(formattedPlugins, null, 2));\n } else {\n const formatted = formattedPlugins.map(printPlugin);\n yield* Console.log(printList(formatted));\n }\n});\n\nexport const list = Command.make('list', {}, handler).pipe(Command.withDescription('List all available plugins.'));\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { FormBuilder } from '@dxos/cli-util';\n\nexport type FormattedPlugin = {\n id: string;\n name: string;\n enabled: boolean;\n core: boolean;\n};\n\n/**\n * Pretty prints a plugin with ANSI colors.\n */\nexport const printPlugin = (plugin: FormattedPlugin) => {\n const status = plugin.core ? 'core' : plugin.enabled ? 'enabled' : 'disabled';\n return FormBuilder.make({ title: plugin.name }).pipe(\n FormBuilder.set('id', plugin.id),\n FormBuilder.set('status', status),\n FormBuilder.build,\n );\n};\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
|
+
"names": ["Plugin", "AppPlugin", "meta", "Command", "Args", "Command", "Console", "Effect", "Plugin", "CommandConfig", "invariant", "handler", "manager", "Plugin", "plugins", "getPlugins", "plugin", "find", "p", "invariant", "core", "getCore", "includes", "disabled", "enabledPlugins", "profile", "enabled", "json", "id", "Console", "name", "Args", "withDescription", "pipe", "Args", "Command", "Console", "Effect", "Plugin", "CommandConfig", "invariant", "__dxlog_file", "handler", "manager", "Plugin", "plugins", "getPlugins", "plugin", "find", "p", "invariant", "enabled", "enable", "id", "enabledPlugins", "profile", "json", "Console", "name", "Args", "withDescription", "pipe", "Command", "Console", "Effect", "Plugin", "CommandConfig", "printList", "FormBuilder", "printPlugin", "plugin", "status", "core", "enabled", "make", "title", "name", "pipe", "set", "id", "build", "handler", "fn", "json", "CommandConfig", "manager", "Plugin", "Service", "plugins", "getPlugins", "enabled", "getEnabled", "core", "getCore", "formattedPlugins", "map", "plugin", "isEnabled", "includes", "meta", "id", "isCore", "name", "log", "JSON", "stringify", "formatted", "printPlugin", "printList", "list", "make", "pipe", "withDescription", "plugin", "make", "pipe", "withDescription", "withSubcommands", "enable", "disable", "list", "RegistryPlugin", "Plugin", "define", "meta", "pipe", "AppPlugin", "addCommandModule", "commands", "plugin", "make"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/RegistryPlugin.workerd.ts
|
|
2
|
+
import { Plugin } from "@dxos/app-framework";
|
|
3
|
+
import { meta } from "#meta";
|
|
4
|
+
var RegistryPlugin = Plugin.define(meta).pipe(Plugin.make);
|
|
5
|
+
var RegistryPlugin_workerd_default = RegistryPlugin;
|
|
6
|
+
export {
|
|
7
|
+
RegistryPlugin,
|
|
8
|
+
RegistryPlugin_workerd_default as default
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=RegistryPlugin.workerd.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/RegistryPlugin.workerd.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { Plugin } from '@dxos/app-framework';\n\nimport { meta } from '#meta';\n\nexport const RegistryPlugin = Plugin.define(meta).pipe(Plugin.make);\n\nexport default RegistryPlugin;\n"],
|
|
5
|
+
"mappings": ";AAIA,SAASA,cAAc;AAEvB,SAASC,YAAY;AAEd,IAAMC,iBAAiBF,OAAOG,OAAOF,IAAAA,EAAMG,KAAKJ,OAAOK,IAAI;AAElE,IAAA,iCAAeH;",
|
|
6
|
+
"names": ["Plugin", "meta", "RegistryPlugin", "define", "pipe", "make"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// src/meta.ts
|
|
2
|
+
import { Plugin } from "@dxos/app-framework";
|
|
3
|
+
import { pinnedWorkspaceId } from "@dxos/app-toolkit";
|
|
4
|
+
import { DXN } from "@dxos/keys";
|
|
5
|
+
import { trim } from "@dxos/util";
|
|
6
|
+
var REGISTRY_ID = pinnedWorkspaceId("dxos:plugin-registry");
|
|
7
|
+
var REGISTRY_KEY = "plugin-registry";
|
|
8
|
+
var CATEGORY_SEPARATOR = ">";
|
|
9
|
+
var registryCategoryId = (category) => `${REGISTRY_KEY}${CATEGORY_SEPARATOR}${category}`;
|
|
10
|
+
var getPluginPath = (pluginId) => `root/${REGISTRY_ID}/${pluginId}`;
|
|
11
|
+
var getPluginSpecPath = (pluginId) => `${getPluginPath(pluginId)}/spec`;
|
|
12
|
+
var meta = Plugin.makeMeta({
|
|
13
|
+
key: DXN.make("org.dxos.plugin.registry"),
|
|
14
|
+
name: "Plugins",
|
|
15
|
+
author: "DXOS",
|
|
16
|
+
description: trim`
|
|
17
|
+
Plugin management system for discovering, installing, and configuring workspace extensions.
|
|
18
|
+
Browse available plugins and customize your workspace capabilities.
|
|
19
|
+
`,
|
|
20
|
+
icon: "ph--squares-four--regular",
|
|
21
|
+
tags: [
|
|
22
|
+
"system"
|
|
23
|
+
]
|
|
24
|
+
});
|
|
25
|
+
var DISABLE_DEPENDENTS_DIALOG = DXN.make(`${meta.id}.disableDependentsDialog`);
|
|
26
|
+
|
|
27
|
+
export {
|
|
28
|
+
REGISTRY_ID,
|
|
29
|
+
REGISTRY_KEY,
|
|
30
|
+
registryCategoryId,
|
|
31
|
+
getPluginPath,
|
|
32
|
+
getPluginSpecPath,
|
|
33
|
+
meta,
|
|
34
|
+
DISABLE_DEPENDENTS_DIALOG
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=chunk-GRQI6MLI.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 { Plugin } from '@dxos/app-framework';\nimport { pinnedWorkspaceId } from '@dxos/app-toolkit';\nimport { DXN } from '@dxos/keys';\nimport { trim } from '@dxos/util';\n\nexport const REGISTRY_ID = pinnedWorkspaceId('dxos:plugin-registry');\nexport const REGISTRY_KEY = 'plugin-registry';\n\n// TODO(wittjosiah): Should this be a special separator or use the standard path separator?\nconst CATEGORY_SEPARATOR = '>';\n\n/** Build a registry category node ID. */\nexport const registryCategoryId = (category: string): string => `${REGISTRY_KEY}${CATEGORY_SEPARATOR}${category}`;\n\n/** Qualified graph path to a specific plugin node. */\nexport const getPluginPath = (pluginId: string): string => `root/${REGISTRY_ID}/${pluginId}`;\n\n/**\n * Qualified graph path to the bundled MDL spec child node for a plugin.\n *\n * The child is contributed by whichever plugin can render MDL (today:\n * `plugin-code`). plugin-registry only knows the path convention so it can:\n * - dispatch `LayoutOperation.Open` to open the spec viewer, and\n * - probe the app graph for the child's existence to gate the \"View\n * specification\" button. If no plugin contributes a renderer for the\n * child, the node is absent and the button stays hidden.\n */\nexport const getPluginSpecPath = (pluginId: string): string => `${getPluginPath(pluginId)}/spec`;\n\nexport const meta = Plugin.makeMeta({\n key: DXN.make('org.dxos.plugin.registry'),\n name: 'Plugins',\n author: 'DXOS',\n description: trim`\n Plugin management system for discovering, installing, and configuring workspace extensions.\n Browse available plugins and customize your workspace capabilities.\n `,\n icon: 'ph--squares-four--regular',\n tags: ['system'],\n});\n\n/** Cascade-disable confirmation dialog surface id. */\nexport const DISABLE_DEPENDENTS_DIALOG = DXN.make(`${meta.id}.disableDependentsDialog`);\n"],
|
|
5
|
+
"mappings": ";AAIA,SAASA,cAAc;AACvB,SAASC,yBAAyB;AAClC,SAASC,WAAW;AACpB,SAASC,YAAY;AAEd,IAAMC,cAAcH,kBAAkB,sBAAA;AACtC,IAAMI,eAAe;AAG5B,IAAMC,qBAAqB;AAGpB,IAAMC,qBAAqB,CAACC,aAA6B,GAAGH,YAAAA,GAAeC,kBAAAA,GAAqBE,QAAAA;AAGhG,IAAMC,gBAAgB,CAACC,aAA6B,QAAQN,WAAAA,IAAeM,QAAAA;AAY3E,IAAMC,oBAAoB,CAACD,aAA6B,GAAGD,cAAcC,QAAAA,CAAAA;AAEzE,IAAME,OAAOZ,OAAOa,SAAS;EAClCC,KAAKZ,IAAIa,KAAK,0BAAA;EACdC,MAAM;EACNC,QAAQ;EACRC,aAAaf;;;;EAIbgB,MAAM;EACNC,MAAM;IAAC;;AACT,CAAA;AAGO,IAAMC,4BAA4BnB,IAAIa,KAAK,GAAGH,KAAKU,EAAE,0BAA0B;",
|
|
6
|
+
"names": ["Plugin", "pinnedWorkspaceId", "DXN", "trim", "REGISTRY_ID", "REGISTRY_KEY", "CATEGORY_SEPARATOR", "registryCategoryId", "category", "getPluginPath", "pluginId", "getPluginSpecPath", "meta", "makeMeta", "key", "make", "name", "author", "description", "icon", "tags", "DISABLE_DEPENDENTS_DIALOG", "id"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
// src/storage.ts
|
|
2
|
+
import * as FileSystem from "@effect/platform/FileSystem";
|
|
3
|
+
import * as Path from "@effect/platform/Path";
|
|
4
|
+
import * as Effect from "effect/Effect";
|
|
5
|
+
import * as Schema from "effect/Schema";
|
|
6
|
+
import * as Yaml from "yaml";
|
|
7
|
+
import { DX_CONFIG } from "@dxos/client-protocol";
|
|
8
|
+
var PluginsSchema = Schema.Array(Schema.String);
|
|
9
|
+
var getPluginsConfigPath = (profile) => `${DX_CONFIG}/plugins/${profile}.yml`;
|
|
10
|
+
var loadEnabledPlugins = Effect.fn(function* ({ profile }) {
|
|
11
|
+
const fs = yield* FileSystem.FileSystem;
|
|
12
|
+
const pluginsPath = getPluginsConfigPath(profile);
|
|
13
|
+
const content = yield* fs.readFileString(pluginsPath).pipe(Effect.catchTag("SystemError", () => Effect.succeed("[]")));
|
|
14
|
+
const raw = Yaml.parse(content);
|
|
15
|
+
const parsed = yield* Schema.decodeUnknown(PluginsSchema)(raw ?? []).pipe(Effect.catchAll(() => Effect.succeed([])));
|
|
16
|
+
return parsed;
|
|
17
|
+
});
|
|
18
|
+
var saveEnabledPlugins = Effect.fn(function* ({ profile, enabled }) {
|
|
19
|
+
const fs = yield* FileSystem.FileSystem;
|
|
20
|
+
const path = yield* Path.Path;
|
|
21
|
+
const pluginsPath = getPluginsConfigPath(profile);
|
|
22
|
+
yield* fs.makeDirectory(path.dirname(pluginsPath), {
|
|
23
|
+
recursive: true
|
|
24
|
+
});
|
|
25
|
+
const encoded = Yaml.stringify(enabled);
|
|
26
|
+
yield* fs.writeFileString(pluginsPath, encoded);
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
export {
|
|
30
|
+
loadEnabledPlugins,
|
|
31
|
+
saveEnabledPlugins
|
|
32
|
+
};
|
|
33
|
+
//# sourceMappingURL=chunk-XK2JMH3H.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/storage.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as FileSystem from '@effect/platform/FileSystem';\nimport * as Path from '@effect/platform/Path';\nimport * as Effect from 'effect/Effect';\nimport * as Schema from 'effect/Schema';\nimport * as Yaml from 'yaml';\n\nimport { DX_CONFIG } from '@dxos/client-protocol';\n\n// TODO(wittjosiah): Factor out to app-framework?\n\nconst PluginsSchema = Schema.Array(Schema.String);\n\n/** CLI-only: path to plugins/<profile>.yml (sibling to profile/). */\nconst getPluginsConfigPath = (profile: string) => `${DX_CONFIG}/plugins/${profile}.yml`;\n\n/**\n * Load enabled plugins from plugins/<profile>.yml (sibling to profile/).\n * Returns the list of enabled plugin IDs, or an empty array if the file doesn't exist.\n */\nexport const loadEnabledPlugins = Effect.fn(function* ({ profile }: { profile: string }) {\n const fs = yield* FileSystem.FileSystem;\n const pluginsPath = getPluginsConfigPath(profile);\n\n const content = yield* fs\n .readFileString(pluginsPath)\n .pipe(Effect.catchTag('SystemError', () => Effect.succeed('[]')));\n\n const raw = Yaml.parse(content);\n const parsed = yield* Schema.decodeUnknown(PluginsSchema)(raw ?? []).pipe(\n Effect.catchAll(() => Effect.succeed([] as string[])),\n );\n\n return parsed;\n});\n\n/**\n * Save enabled plugins to plugins/<profile>.yml.\n */\nexport const saveEnabledPlugins = Effect.fn(function* ({ profile, enabled }: { profile: string; enabled: string[] }) {\n const fs = yield* FileSystem.FileSystem;\n const path = yield* Path.Path;\n const pluginsPath = getPluginsConfigPath(profile);\n yield* fs.makeDirectory(path.dirname(pluginsPath), { recursive: true });\n const encoded = Yaml.stringify(enabled);\n yield* fs.writeFileString(pluginsPath, encoded);\n});\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,gBAAgB;AAC5B,YAAYC,UAAU;AACtB,YAAYC,YAAY;AACxB,YAAYC,YAAY;AACxB,YAAYC,UAAU;AAEtB,SAASC,iBAAiB;AAI1B,IAAMC,gBAAuBC,aAAaC,aAAM;AAGhD,IAAMC,uBAAuB,CAACC,YAAoB,GAAGL,SAAAA,YAAqBK,OAAAA;AAMnE,IAAMC,qBAA4BC,UAAG,WAAW,EAAEF,QAAO,GAAuB;AACrF,QAAMG,KAAK,OAAkBb;AAC7B,QAAMc,cAAcL,qBAAqBC,OAAAA;AAEzC,QAAMK,UAAU,OAAOF,GACpBG,eAAeF,WAAAA,EACfG,KAAYC,gBAAS,eAAe,MAAaC,eAAQ,IAAA,CAAA,CAAA;AAE5D,QAAMC,MAAWC,WAAMN,OAAAA;AACvB,QAAMO,SAAS,OAAcC,qBAAcjB,aAAAA,EAAec,OAAO,CAAA,CAAE,EAAEH,KAC5DO,gBAAS,MAAaL,eAAQ,CAAA,CAAE,CAAA,CAAA;AAGzC,SAAOG;AACT,CAAA;AAKO,IAAMG,qBAA4Bb,UAAG,WAAW,EAAEF,SAASgB,QAAO,GAA0C;AACjH,QAAMb,KAAK,OAAkBb;AAC7B,QAAM2B,OAAO,OAAY1B;AACzB,QAAMa,cAAcL,qBAAqBC,OAAAA;AACzC,SAAOG,GAAGe,cAAcD,KAAKE,QAAQf,WAAAA,GAAc;IAAEgB,WAAW;EAAK,CAAA;AACrE,QAAMC,UAAeC,eAAUN,OAAAA;AAC/B,SAAOb,GAAGoB,gBAAgBnB,aAAaiB,OAAAA;AACzC,CAAA;",
|
|
6
|
+
"names": ["FileSystem", "Path", "Effect", "Schema", "Yaml", "DX_CONFIG", "PluginsSchema", "Array", "String", "getPluginsConfigPath", "profile", "loadEnabledPlugins", "fn", "fs", "pluginsPath", "content", "readFileString", "pipe", "catchTag", "succeed", "raw", "parse", "parsed", "decodeUnknown", "catchAll", "saveEnabledPlugins", "enabled", "path", "makeDirectory", "dirname", "recursive", "encoded", "stringify", "writeFileString"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import {
|
|
2
|
+
loadEnabledPlugins,
|
|
3
|
+
saveEnabledPlugins
|
|
4
|
+
} from "./chunk-XK2JMH3H.mjs";
|
|
5
|
+
import {
|
|
6
|
+
DISABLE_DEPENDENTS_DIALOG,
|
|
7
|
+
REGISTRY_ID,
|
|
8
|
+
REGISTRY_KEY,
|
|
9
|
+
getPluginPath,
|
|
10
|
+
getPluginSpecPath,
|
|
11
|
+
meta,
|
|
12
|
+
registryCategoryId
|
|
13
|
+
} from "./chunk-GRQI6MLI.mjs";
|
|
14
|
+
export {
|
|
15
|
+
DISABLE_DEPENDENTS_DIALOG,
|
|
16
|
+
REGISTRY_ID,
|
|
17
|
+
REGISTRY_KEY,
|
|
18
|
+
getPluginPath,
|
|
19
|
+
getPluginSpecPath,
|
|
20
|
+
loadEnabledPlugins,
|
|
21
|
+
meta,
|
|
22
|
+
registryCategoryId,
|
|
23
|
+
saveEnabledPlugins
|
|
24
|
+
};
|
|
25
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"inputs":{"src/meta.ts":{"bytes":5956,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/keys","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"src/storage.ts":{"bytes":6158,"imports":[{"path":"@effect/platform/FileSystem","kind":"import-statement","external":true},{"path":"@effect/platform/Path","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"effect/Schema","kind":"import-statement","external":true},{"path":"yaml","kind":"import-statement","external":true},{"path":"@dxos/client-protocol","kind":"import-statement","external":true}],"format":"esm"},"src/index.ts":{"bytes":451,"imports":[{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/storage.ts","kind":"import-statement","original":"./storage"}],"format":"esm"},"src/RegistryPlugin.tsx":{"bytes":3557,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"#capabilities","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true},{"path":"#translations","kind":"import-statement","external":true}],"format":"esm"},"src/commands/disable.ts":{"bytes":6258,"imports":[{"path":"@effect/cli/Args","kind":"import-statement","external":true},{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"effect/Console","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"src/storage.ts","kind":"import-statement","original":"../storage"}],"format":"esm"},"src/commands/enable.ts":{"bytes":5683,"imports":[{"path":"@effect/cli/Args","kind":"import-statement","external":true},{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"effect/Console","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"src/storage.ts","kind":"import-statement","original":"../storage"}],"format":"esm"},"src/commands/util.ts":{"bytes":1905,"imports":[{"path":"@dxos/cli-util","kind":"import-statement","external":true}],"format":"esm"},"src/commands/list.ts":{"bytes":4871,"imports":[{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"effect/Console","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true},{"path":"src/commands/util.ts","kind":"import-statement","original":"./util"}],"format":"esm"},"src/commands/index.ts":{"bytes":1502,"imports":[{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"src/commands/disable.ts","kind":"import-statement","original":"./disable"},{"path":"src/commands/enable.ts","kind":"import-statement","original":"./enable"},{"path":"src/commands/list.ts","kind":"import-statement","original":"./list"}],"format":"esm"},"src/RegistryPlugin.node.ts":{"bytes":1582,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true},{"path":"src/commands/index.ts","kind":"import-statement","original":"./commands"}],"format":"esm"},"src/RegistryPlugin.workerd.ts":{"bytes":1004,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true}],"format":"esm"},"src/operations/open-plugin-registry.ts":{"bytes":2203,"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/compute","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true}],"format":"esm"},"src/operations/index.ts":{"bytes":876,"imports":[{"path":"@dxos/compute","kind":"import-statement","external":true},{"path":"src/operations/open-plugin-registry.ts","kind":"dynamic-import","original":"./open-plugin-registry"}],"format":"esm"},"src/plugin.ts":{"bytes":1089,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/operations/index.ts","kind":"import-statement","original":"./operations"},{"path":"#plugin","kind":"dynamic-import","external":true}],"format":"esm"},"src/translations.ts":{"bytes":10347,"imports":[{"path":"#meta","kind":"import-statement","external":true}],"format":"esm"}},"outputs":{"dist/lib/neutral/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":93},"dist/lib/neutral/index.mjs":{"imports":[{"path":"dist/lib/neutral/chunk-XK2JMH3H.mjs","kind":"import-statement"},{"path":"dist/lib/neutral/chunk-GRQI6MLI.mjs","kind":"import-statement"}],"exports":["DISABLE_DEPENDENTS_DIALOG","REGISTRY_ID","REGISTRY_KEY","getPluginPath","getPluginSpecPath","loadEnabledPlugins","meta","registryCategoryId","saveEnabledPlugins"],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":0}},"bytes":468},"dist/lib/neutral/RegistryPlugin.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1903},"dist/lib/neutral/RegistryPlugin.mjs":{"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"#capabilities","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true},{"path":"#translations","kind":"import-statement","external":true}],"exports":["RegistryPlugin","default"],"entryPoint":"src/RegistryPlugin.tsx","inputs":{"src/RegistryPlugin.tsx":{"bytesInOutput":834}},"bytes":970},"dist/lib/neutral/RegistryPlugin.node.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":10592},"dist/lib/neutral/RegistryPlugin.node.mjs":{"imports":[{"path":"dist/lib/neutral/chunk-XK2JMH3H.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true},{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"@effect/cli/Args","kind":"import-statement","external":true},{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"effect/Console","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@effect/cli/Args","kind":"import-statement","external":true},{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"effect/Console","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true},{"path":"@dxos/invariant","kind":"import-statement","external":true},{"path":"@effect/cli/Command","kind":"import-statement","external":true},{"path":"effect/Console","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true},{"path":"@dxos/cli-util","kind":"import-statement","external":true}],"exports":["RegistryPlugin","default"],"entryPoint":"src/RegistryPlugin.node.ts","inputs":{"src/RegistryPlugin.node.ts":{"bytesInOutput":308},"src/commands/index.ts":{"bytesInOutput":196},"src/commands/disable.ts":{"bytesInOutput":1786},"src/commands/enable.ts":{"bytesInOutput":1605},"src/commands/list.ts":{"bytesInOutput":1133},"src/commands/util.ts":{"bytesInOutput":317}},"bytes":5770},"dist/lib/neutral/chunk-XK2JMH3H.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3160},"dist/lib/neutral/chunk-XK2JMH3H.mjs":{"imports":[{"path":"@effect/platform/FileSystem","kind":"import-statement","external":true},{"path":"@effect/platform/Path","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"effect/Schema","kind":"import-statement","external":true},{"path":"yaml","kind":"import-statement","external":true},{"path":"@dxos/client-protocol","kind":"import-statement","external":true}],"exports":["loadEnabledPlugins","saveEnabledPlugins"],"inputs":{"src/storage.ts":{"bytesInOutput":1230}},"bytes":1348},"dist/lib/neutral/RegistryPlugin.workerd.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":531},"dist/lib/neutral/RegistryPlugin.workerd.mjs":{"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true}],"exports":["RegistryPlugin","default"],"entryPoint":"src/RegistryPlugin.workerd.ts","inputs":{"src/RegistryPlugin.workerd.ts":{"bytesInOutput":189}},"bytes":348},"dist/lib/neutral/plugin.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":891},"dist/lib/neutral/plugin.mjs":{"imports":[{"path":"dist/lib/neutral/chunk-GRQI6MLI.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/compute","kind":"import-statement","external":true},{"path":"dist/lib/neutral/open-plugin-registry-II735N76.mjs","kind":"dynamic-import"},{"path":"#plugin","kind":"dynamic-import","external":true}],"exports":["RegistryOperationHandlerSet","RegistryPlugin"],"entryPoint":"src/plugin.ts","inputs":{"src/plugin.ts":{"bytesInOutput":111},"src/operations/index.ts":{"bytesInOutput":166}},"bytes":484},"dist/lib/neutral/chunk-GRQI6MLI.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2849},"dist/lib/neutral/chunk-GRQI6MLI.mjs":{"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/keys","kind":"import-statement","external":true},{"path":"@dxos/util","kind":"import-statement","external":true}],"exports":["DISABLE_DEPENDENTS_DIALOG","REGISTRY_ID","REGISTRY_KEY","getPluginPath","getPluginSpecPath","meta","registryCategoryId"],"inputs":{"src/meta.ts":{"bytesInOutput":984}},"bytes":1183},"dist/lib/neutral/translations.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4669},"dist/lib/neutral/translations.mjs":{"imports":[{"path":"#meta","kind":"import-statement","external":true}],"exports":["translations"],"entryPoint":"src/translations.ts","inputs":{"src/translations.ts":{"bytesInOutput":3448}},"bytes":3540},"dist/lib/neutral/open-plugin-registry-II735N76.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":1224},"dist/lib/neutral/open-plugin-registry-II735N76.mjs":{"imports":[{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"@dxos/app-toolkit","kind":"import-statement","external":true},{"path":"@dxos/compute","kind":"import-statement","external":true},{"path":"#meta","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/operations/open-plugin-registry.ts","inputs":{"src/operations/open-plugin-registry.ts":{"bytesInOutput":474}},"bytes":629}}}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// src/operations/open-plugin-registry.ts
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
import { LayoutOperation, SettingsOperation, getSpacePath } from "@dxos/app-toolkit";
|
|
4
|
+
import { Operation } from "@dxos/compute";
|
|
5
|
+
import { REGISTRY_ID } from "#meta";
|
|
6
|
+
var handler = SettingsOperation.OpenPluginRegistry.pipe(Operation.withHandler(Effect.fnUntraced(function* () {
|
|
7
|
+
yield* Operation.invoke(LayoutOperation.SwitchWorkspace, {
|
|
8
|
+
subject: getSpacePath(REGISTRY_ID)
|
|
9
|
+
});
|
|
10
|
+
})));
|
|
11
|
+
var open_plugin_registry_default = handler;
|
|
12
|
+
export {
|
|
13
|
+
open_plugin_registry_default as default
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=open-plugin-registry-II735N76.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/operations/open-plugin-registry.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as Effect from 'effect/Effect';\n\nimport { LayoutOperation, SettingsOperation, getSpacePath } from '@dxos/app-toolkit';\nimport { Operation } from '@dxos/compute';\n\nimport { REGISTRY_ID } from '#meta';\n\nconst handler: Operation.WithHandler<typeof SettingsOperation.OpenPluginRegistry> =\n SettingsOperation.OpenPluginRegistry.pipe(\n Operation.withHandler(\n Effect.fnUntraced(function* () {\n yield* Operation.invoke(LayoutOperation.SwitchWorkspace, { subject: getSpacePath(REGISTRY_ID) });\n }),\n ),\n );\n\nexport default handler;\n"],
|
|
5
|
+
"mappings": ";AAIA,YAAYA,YAAY;AAExB,SAASC,iBAAiBC,mBAAmBC,oBAAoB;AACjE,SAASC,iBAAiB;AAE1B,SAASC,mBAAmB;AAE5B,IAAMC,UACJJ,kBAAkBK,mBAAmBC,KACnCJ,UAAUK,YACDC,kBAAW,aAAA;AAChB,SAAON,UAAUO,OAAOV,gBAAgBW,iBAAiB;IAAEC,SAASV,aAAaE,WAAAA;EAAa,CAAA;AAChG,CAAA,CAAA,CAAA;AAIN,IAAA,+BAAeC;",
|
|
6
|
+
"names": ["Effect", "LayoutOperation", "SettingsOperation", "getSpacePath", "Operation", "REGISTRY_ID", "handler", "OpenPluginRegistry", "pipe", "withHandler", "fnUntraced", "invoke", "SwitchWorkspace", "subject"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import {
|
|
2
|
+
meta
|
|
3
|
+
} from "./chunk-GRQI6MLI.mjs";
|
|
4
|
+
|
|
5
|
+
// src/plugin.ts
|
|
6
|
+
import { Plugin } from "@dxos/app-framework";
|
|
7
|
+
|
|
8
|
+
// src/operations/index.ts
|
|
9
|
+
import { OperationHandlerSet } from "@dxos/compute";
|
|
10
|
+
var RegistryOperationHandlerSet = OperationHandlerSet.lazy(() => import("./open-plugin-registry-II735N76.mjs"));
|
|
11
|
+
|
|
12
|
+
// src/plugin.ts
|
|
13
|
+
var RegistryPlugin = Plugin.lazy(meta, () => import("#plugin"));
|
|
14
|
+
export {
|
|
15
|
+
RegistryOperationHandlerSet,
|
|
16
|
+
RegistryPlugin
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=plugin.mjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/plugin.ts", "../../../src/operations/index.ts"],
|
|
4
|
+
"sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Plugin } from '@dxos/app-framework';\n\nimport { meta } from './meta';\n\nexport const RegistryPlugin = Plugin.lazy(meta, () => import('#plugin'));\n\nexport { RegistryOperationHandlerSet } from './operations';\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { OperationHandlerSet } from '@dxos/compute';\n\nexport const RegistryOperationHandlerSet = OperationHandlerSet.lazy(() => import('./open-plugin-registry'));\n"],
|
|
5
|
+
"mappings": ";;;;;AAIA,SAASA,cAAc;;;ACAvB,SAASC,2BAA2B;AAE7B,IAAMC,8BAA8BD,oBAAoBE,KAAK,MAAM,OAAO,qCAAA,CAAA;;;ADE1E,IAAMC,iBAAiBC,OAAOC,KAAKC,MAAM,MAAM,OAAO,SAAA,CAAA;",
|
|
6
|
+
"names": ["Plugin", "OperationHandlerSet", "RegistryOperationHandlerSet", "lazy", "RegistryPlugin", "Plugin", "lazy", "meta"]
|
|
7
|
+
}
|