@dxos/plugin-registry 0.8.4-main.f5c0578 → 0.8.4-main.fcc0d83b33

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.
Files changed (165) hide show
  1. package/dist/lib/browser/cli/index.mjs +179 -0
  2. package/dist/lib/browser/cli/index.mjs.map +7 -0
  3. package/dist/lib/browser/index.mjs +37 -63
  4. package/dist/lib/browser/index.mjs.map +4 -4
  5. package/dist/lib/browser/meta.json +1 -1
  6. package/dist/lib/browser/translations.mjs +35 -0
  7. package/dist/lib/browser/translations.mjs.map +7 -0
  8. package/dist/lib/node-esm/cli/index.mjs +181 -0
  9. package/dist/lib/node-esm/cli/index.mjs.map +7 -0
  10. package/dist/lib/node-esm/index.mjs +47 -0
  11. package/dist/lib/node-esm/index.mjs.map +7 -0
  12. package/dist/lib/node-esm/meta.json +1 -0
  13. package/dist/lib/node-esm/translations.mjs +37 -0
  14. package/dist/lib/node-esm/translations.mjs.map +7 -0
  15. package/dist/types/src/RegistryPlugin.d.ts +2 -1
  16. package/dist/types/src/RegistryPlugin.d.ts.map +1 -1
  17. package/dist/types/src/capabilities/app-graph-builder.d.ts +4 -2
  18. package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
  19. package/dist/types/src/capabilities/index.d.ts +6 -3
  20. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  21. package/dist/types/src/capabilities/operation-handler.d.ts +6 -0
  22. package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -0
  23. package/dist/types/src/capabilities/react-surface.d.ts +3 -2
  24. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  25. package/dist/types/src/capabilities/state.d.ts +7 -0
  26. package/dist/types/src/capabilities/state.d.ts.map +1 -0
  27. package/dist/types/src/cli/commands/disable.d.ts +11 -0
  28. package/dist/types/src/cli/commands/disable.d.ts.map +1 -0
  29. package/dist/types/src/cli/commands/enable.d.ts +11 -0
  30. package/dist/types/src/cli/commands/enable.d.ts.map +1 -0
  31. package/dist/types/src/cli/commands/index.d.ts +3 -0
  32. package/dist/types/src/cli/commands/index.d.ts.map +1 -0
  33. package/dist/types/src/cli/commands/list.d.ts +7 -0
  34. package/dist/types/src/cli/commands/list.d.ts.map +1 -0
  35. package/dist/types/src/cli/commands/util.d.ts +11 -0
  36. package/dist/types/src/cli/commands/util.d.ts.map +1 -0
  37. package/dist/types/src/cli/index.d.ts +3 -0
  38. package/dist/types/src/cli/index.d.ts.map +1 -0
  39. package/dist/types/src/cli/plugin.d.ts +3 -0
  40. package/dist/types/src/cli/plugin.d.ts.map +1 -0
  41. package/dist/types/src/cli/storage.d.ts +18 -0
  42. package/dist/types/src/cli/storage.d.ts.map +1 -0
  43. package/dist/types/src/components/PluginDetail/PluginDetail.d.ts +22 -0
  44. package/dist/types/src/components/PluginDetail/PluginDetail.d.ts.map +1 -0
  45. package/dist/types/src/components/PluginDetail/PluginDetail.stories.d.ts +42 -0
  46. package/dist/types/src/components/PluginDetail/PluginDetail.stories.d.ts.map +1 -0
  47. package/dist/types/src/components/PluginDetail/index.d.ts +2 -0
  48. package/dist/types/src/components/PluginDetail/index.d.ts.map +1 -0
  49. package/dist/types/src/components/PluginList/PluginItem.d.ts +26 -0
  50. package/dist/types/src/components/PluginList/PluginItem.d.ts.map +1 -0
  51. package/dist/types/src/components/PluginList/PluginList.d.ts +13 -0
  52. package/dist/types/src/components/PluginList/PluginList.d.ts.map +1 -0
  53. package/dist/types/src/components/PluginList/PluginList.stories.d.ts +41 -0
  54. package/dist/types/src/components/PluginList/PluginList.stories.d.ts.map +1 -0
  55. package/dist/types/src/components/PluginList/index.d.ts +2 -0
  56. package/dist/types/src/components/PluginList/index.d.ts.map +1 -0
  57. package/dist/types/src/components/index.d.ts +0 -1
  58. package/dist/types/src/components/index.d.ts.map +1 -1
  59. package/dist/types/src/containers/CommunityRegistry/CommunityRegistry.d.ts +8 -0
  60. package/dist/types/src/containers/CommunityRegistry/CommunityRegistry.d.ts.map +1 -0
  61. package/dist/types/src/containers/CommunityRegistry/index.d.ts +2 -0
  62. package/dist/types/src/containers/CommunityRegistry/index.d.ts.map +1 -0
  63. package/dist/types/src/containers/LoadPluginDialog/LoadPluginDialog.d.ts +4 -0
  64. package/dist/types/src/containers/LoadPluginDialog/LoadPluginDialog.d.ts.map +1 -0
  65. package/dist/types/src/containers/LoadPluginDialog/index.d.ts +2 -0
  66. package/dist/types/src/containers/LoadPluginDialog/index.d.ts.map +1 -0
  67. package/dist/types/src/containers/PluginArticle/PluginArticle.d.ts +7 -0
  68. package/dist/types/src/containers/PluginArticle/PluginArticle.d.ts.map +1 -0
  69. package/dist/types/src/containers/PluginArticle/index.d.ts +2 -0
  70. package/dist/types/src/containers/PluginArticle/index.d.ts.map +1 -0
  71. package/dist/types/src/containers/PluginRegistry/PluginRegistry.d.ts +14 -0
  72. package/dist/types/src/containers/PluginRegistry/PluginRegistry.d.ts.map +1 -0
  73. package/dist/types/src/containers/PluginRegistry/index.d.ts +2 -0
  74. package/dist/types/src/containers/PluginRegistry/index.d.ts.map +1 -0
  75. package/dist/types/src/containers/index.d.ts +7 -0
  76. package/dist/types/src/containers/index.d.ts.map +1 -0
  77. package/dist/types/src/hooks/index.d.ts +3 -0
  78. package/dist/types/src/hooks/index.d.ts.map +1 -0
  79. package/dist/types/src/hooks/use-auto-tags.d.ts +20 -0
  80. package/dist/types/src/hooks/use-auto-tags.d.ts.map +1 -0
  81. package/dist/types/src/hooks/use-community-plugins.d.ts +16 -0
  82. package/dist/types/src/hooks/use-community-plugins.d.ts.map +1 -0
  83. package/dist/types/src/meta.d.ts +7 -4
  84. package/dist/types/src/meta.d.ts.map +1 -1
  85. package/dist/types/src/operations/index.d.ts +3 -0
  86. package/dist/types/src/operations/index.d.ts.map +1 -0
  87. package/dist/types/src/operations/open-plugin-registry.d.ts +5 -0
  88. package/dist/types/src/operations/open-plugin-registry.d.ts.map +1 -0
  89. package/dist/types/src/translations.d.ts +22 -16
  90. package/dist/types/src/translations.d.ts.map +1 -1
  91. package/dist/types/src/types.d.ts +14 -1
  92. package/dist/types/src/types.d.ts.map +1 -1
  93. package/dist/types/tsconfig.tsbuildinfo +1 -1
  94. package/package.json +71 -37
  95. package/src/RegistryPlugin.tsx +17 -27
  96. package/src/capabilities/app-graph-builder.ts +173 -135
  97. package/src/capabilities/index.ts +9 -4
  98. package/src/capabilities/operation-handler.ts +16 -0
  99. package/src/capabilities/react-surface.tsx +108 -78
  100. package/src/capabilities/state.ts +40 -0
  101. package/src/cli/commands/disable.ts +47 -0
  102. package/src/cli/commands/enable.ts +44 -0
  103. package/src/cli/commands/index.ts +14 -0
  104. package/src/cli/commands/list.ts +41 -0
  105. package/src/cli/commands/util.ts +24 -0
  106. package/src/cli/index.ts +6 -0
  107. package/src/cli/plugin.ts +17 -0
  108. package/src/cli/storage.ts +50 -0
  109. package/src/components/PluginDetail/PluginDetail.stories.tsx +44 -0
  110. package/src/components/PluginDetail/PluginDetail.tsx +106 -0
  111. package/src/components/PluginDetail/index.ts +5 -0
  112. package/src/components/PluginList/PluginItem.tsx +187 -0
  113. package/src/components/PluginList/PluginList.stories.tsx +87 -0
  114. package/src/components/PluginList/PluginList.tsx +29 -0
  115. package/src/components/PluginList/index.ts +5 -0
  116. package/src/components/index.ts +0 -1
  117. package/src/containers/CommunityRegistry/CommunityRegistry.tsx +181 -0
  118. package/src/containers/CommunityRegistry/index.ts +5 -0
  119. package/src/containers/LoadPluginDialog/LoadPluginDialog.tsx +86 -0
  120. package/src/containers/LoadPluginDialog/index.ts +5 -0
  121. package/src/containers/PluginArticle/PluginArticle.tsx +73 -0
  122. package/src/containers/PluginArticle/index.ts +5 -0
  123. package/src/containers/PluginRegistry/PluginRegistry.tsx +98 -0
  124. package/src/containers/PluginRegistry/index.ts +5 -0
  125. package/src/containers/index.ts +11 -0
  126. package/src/hooks/index.ts +6 -0
  127. package/src/hooks/use-auto-tags.ts +52 -0
  128. package/src/hooks/use-community-plugins.ts +35 -0
  129. package/src/meta.ts +19 -9
  130. package/src/operations/index.ts +7 -0
  131. package/src/operations/open-plugin-registry.ts +21 -0
  132. package/src/translations.ts +22 -15
  133. package/src/types.ts +30 -1
  134. package/dist/lib/browser/app-graph-builder-6JQNRTEQ.mjs +0 -161
  135. package/dist/lib/browser/app-graph-builder-6JQNRTEQ.mjs.map +0 -7
  136. package/dist/lib/browser/chunk-AEBASNOI.mjs +0 -16
  137. package/dist/lib/browser/chunk-AEBASNOI.mjs.map +0 -7
  138. package/dist/lib/browser/intent-resolver-UGDFPMAG.mjs +0 -23
  139. package/dist/lib/browser/intent-resolver-UGDFPMAG.mjs.map +0 -7
  140. package/dist/lib/browser/react-surface-BQPO3F3E.mjs +0 -333
  141. package/dist/lib/browser/react-surface-BQPO3F3E.mjs.map +0 -7
  142. package/dist/types/src/capabilities/intent-resolver.d.ts +0 -4
  143. package/dist/types/src/capabilities/intent-resolver.d.ts.map +0 -1
  144. package/dist/types/src/components/Icon.stories.d.ts +0 -6
  145. package/dist/types/src/components/Icon.stories.d.ts.map +0 -1
  146. package/dist/types/src/components/PluginDetail.d.ts +0 -9
  147. package/dist/types/src/components/PluginDetail.d.ts.map +0 -1
  148. package/dist/types/src/components/PluginDetail.stories.d.ts +0 -8
  149. package/dist/types/src/components/PluginDetail.stories.d.ts.map +0 -1
  150. package/dist/types/src/components/PluginItem.d.ts +0 -13
  151. package/dist/types/src/components/PluginItem.d.ts.map +0 -1
  152. package/dist/types/src/components/PluginList.d.ts +0 -8
  153. package/dist/types/src/components/PluginList.d.ts.map +0 -1
  154. package/dist/types/src/components/PluginList.stories.d.ts +0 -11
  155. package/dist/types/src/components/PluginList.stories.d.ts.map +0 -1
  156. package/dist/types/src/components/RegistryContainer.d.ts +0 -7
  157. package/dist/types/src/components/RegistryContainer.d.ts.map +0 -1
  158. package/src/capabilities/intent-resolver.ts +0 -27
  159. package/src/components/Icon.stories.tsx +0 -108
  160. package/src/components/PluginDetail.stories.tsx +0 -46
  161. package/src/components/PluginDetail.tsx +0 -63
  162. package/src/components/PluginItem.tsx +0 -119
  163. package/src/components/PluginList.stories.tsx +0 -83
  164. package/src/components/PluginList.tsx +0 -26
  165. package/src/components/RegistryContainer.tsx +0 -84
@@ -1,333 +0,0 @@
1
- import {
2
- REGISTRY_KEY,
3
- REGISTRY_PLUGIN
4
- } from "./chunk-AEBASNOI.mjs";
5
-
6
- // src/capabilities/react-surface.tsx
7
- import React5, { useCallback as useCallback3, useMemo as useMemo2 } from "react";
8
- import { Capabilities as Capabilities2, Plugin, contributes, createSurface, usePluginManager as usePluginManager2 } from "@dxos/app-framework";
9
- import { StackItem as StackItem2 } from "@dxos/react-ui-stack";
10
-
11
- // src/components/PluginDetail.tsx
12
- import { useSignals as _useSignals } from "@preact-signals/safe-react/tracking";
13
- import React from "react";
14
- import { Icon, Input, Link, useTranslation } from "@dxos/react-ui";
15
- import { DeprecatedFormContainer } from "@dxos/react-ui-form";
16
- var PluginDetail = ({ plugin, enabled, onEnable }) => {
17
- var _effect = _useSignals();
18
- try {
19
- const { t } = useTranslation(REGISTRY_PLUGIN);
20
- const { id, name, description, homePage, source, screenshots } = plugin.meta;
21
- return /* @__PURE__ */ React.createElement(DeprecatedFormContainer, {
22
- classNames: "gap-6"
23
- }, /* @__PURE__ */ React.createElement("div", {
24
- role: "none",
25
- className: "flex justify-between items-center"
26
- }, /* @__PURE__ */ React.createElement("p", null, id), /* @__PURE__ */ React.createElement(Input.Root, null, /* @__PURE__ */ React.createElement(Input.Switch, {
27
- classNames: "self-center",
28
- checked: enabled,
29
- onClick: onEnable
30
- }))), screenshots && screenshots.length > 0 && /* @__PURE__ */ React.createElement("div", {
31
- role: "none"
32
- }, /* @__PURE__ */ React.createElement("h1", {
33
- className: "text-lg mb-2"
34
- }, "Preview"), /* @__PURE__ */ React.createElement("img", {
35
- src: screenshots[0],
36
- alt: name,
37
- className: "aspect-video object-fit"
38
- })), /* @__PURE__ */ React.createElement("div", {
39
- role: "none"
40
- }, /* @__PURE__ */ React.createElement("p", null, description)), /* @__PURE__ */ React.createElement("div", {
41
- role: "none"
42
- }, /* @__PURE__ */ React.createElement("h1", {
43
- className: "text-lg mb-2"
44
- }, "Resources"), /* @__PURE__ */ React.createElement("div", {
45
- className: "flex gap-2"
46
- }, homePage && /* @__PURE__ */ React.createElement(Link, {
47
- href: homePage,
48
- target: "_blank",
49
- rel: "noreferrer",
50
- classNames: "text-sm text-description"
51
- }, t("home page label"), /* @__PURE__ */ React.createElement(Icon, {
52
- icon: "ph--arrow-square-out--bold",
53
- size: 3,
54
- classNames: "inline-block leading-none mli-1"
55
- })), source && /* @__PURE__ */ React.createElement(Link, {
56
- href: source,
57
- target: "_blank",
58
- rel: "noreferrer",
59
- classNames: "text-sm text-description"
60
- }, t("source label"), /* @__PURE__ */ React.createElement(Icon, {
61
- icon: "ph--arrow-square-out--bold",
62
- size: 3,
63
- classNames: "inline-block leading-none mli-1"
64
- })))));
65
- } finally {
66
- _effect.f();
67
- }
68
- };
69
-
70
- // src/components/PluginList.tsx
71
- import { useSignals as _useSignals3 } from "@preact-signals/safe-react/tracking";
72
- import React3 from "react";
73
- import { List } from "@dxos/react-ui";
74
-
75
- // src/components/PluginItem.tsx
76
- import { useSignals as _useSignals2 } from "@preact-signals/safe-react/tracking";
77
- import React2, { useCallback } from "react";
78
- import { Icon as Icon2, IconButton, Input as Input2, Link as Link2, ListItem, Tag, useTranslation as useTranslation2 } from "@dxos/react-ui";
79
- import { descriptionText, mx } from "@dxos/react-ui-theme";
80
- var PluginItem = ({ plugin, enabled = [], onClick, onChange, hasSettings: _hasSettings, onSettings }) => {
81
- var _effect = _useSignals2();
82
- try {
83
- const { t } = useTranslation2(REGISTRY_PLUGIN);
84
- const { id, name, description, tags, icon = "ph--circle--regular" } = plugin.meta;
85
- const isEnabled = enabled.includes(id);
86
- const inputId = `${id}-input`;
87
- const labelId = `${id}-label`;
88
- const descriptionId = `${id}-description`;
89
- const handleClick = useCallback(() => onClick?.(id), [
90
- id,
91
- onClick
92
- ]);
93
- const handleChange = useCallback((event) => {
94
- event.stopPropagation();
95
- onChange?.(id, !isEnabled);
96
- }, [
97
- id,
98
- isEnabled,
99
- onChange
100
- ]);
101
- const hasSettings = _hasSettings?.(id) ?? false;
102
- const handleSettings = useCallback(() => onSettings?.(id), [
103
- id,
104
- onSettings
105
- ]);
106
- return /* @__PURE__ */ React2.createElement(ListItem.Root, {
107
- key: id,
108
- labelId,
109
- "data-testid": `pluginList.${id}`,
110
- "aria-describedby": descriptionId,
111
- // TODO(burdon): Use Rail vars.
112
- classNames: "is-full bs-full grid grid-cols-[48px_1fr_48px] grid-rows-[40px_1fr_32px] p-1 border border-separator rounded-md"
113
- }, /* @__PURE__ */ React2.createElement("div", {
114
- className: "flex flex-col grow justify-center items-center"
115
- }, /* @__PURE__ */ React2.createElement(Icon2, {
116
- icon,
117
- size: 6,
118
- onClick: handleClick,
119
- classNames: "text-subdued cursor-pointer"
120
- })), /* @__PURE__ */ React2.createElement("div", {
121
- className: "flex items-center overflow-hidden cursor-pointer",
122
- onClick: handleClick
123
- }, /* @__PURE__ */ React2.createElement("span", {
124
- className: "truncate"
125
- }, name ?? id)), /* @__PURE__ */ React2.createElement("div", {
126
- className: "flex justify-center items-center"
127
- }, /* @__PURE__ */ React2.createElement(Input2.Root, {
128
- id: inputId
129
- }, /* @__PURE__ */ React2.createElement(Input2.Switch, {
130
- classNames: "self-center",
131
- checked: isEnabled,
132
- onClick: handleChange
133
- }))), /* @__PURE__ */ React2.createElement("div", null), (description || tags) && /* @__PURE__ */ React2.createElement("div", {
134
- id: descriptionId,
135
- className: "col-span-2 flex flex-col w-full justify-between gap-2 pb-2"
136
- }, /* @__PURE__ */ React2.createElement("div", {
137
- className: "grow"
138
- }, /* @__PURE__ */ React2.createElement("p", {
139
- className: mx(descriptionText, "line-clamp-3 min-w-0 pie-2")
140
- }, description)), tags && tags.length > 0 && /* @__PURE__ */ React2.createElement("div", null, tags.map((tag) => /* @__PURE__ */ React2.createElement(Tag, {
141
- key: tag,
142
- palette: "indigo",
143
- classNames: "text-xs capitalize"
144
- }, tag)))), /* @__PURE__ */ React2.createElement("div", null), /* @__PURE__ */ React2.createElement("div", {
145
- className: "flex gap-2 items-center pie-1"
146
- }, /* @__PURE__ */ React2.createElement(Link2, {
147
- "aria-describedby": descriptionId,
148
- classNames: "text-sm text-description cursor-pointer",
149
- onClick: handleClick
150
- }, t("details label")), /* @__PURE__ */ React2.createElement("div", {
151
- className: "flex-1"
152
- })), /* @__PURE__ */ React2.createElement("div", {
153
- className: "flex justify-center items-center"
154
- }, hasSettings && /* @__PURE__ */ React2.createElement(IconButton, {
155
- "aria-describedby": descriptionId,
156
- classNames: "text-sm text-description cursor-pointer",
157
- icon: "ph--gear--regular",
158
- label: t("settings label"),
159
- iconOnly: true,
160
- size: 4,
161
- onClick: handleSettings
162
- })));
163
- } finally {
164
- _effect.f();
165
- }
166
- };
167
-
168
- // src/components/PluginList.tsx
169
- var PluginList = ({ plugins = [], ...props }) => {
170
- var _effect = _useSignals3();
171
- try {
172
- return /* @__PURE__ */ React3.createElement(List, {
173
- classNames: "grid grid-cols-[repeat(auto-fill,minmax(280px,1fr))] auto-rows-[12rem] gap-3 p-3"
174
- }, plugins.map((plugin) => /* @__PURE__ */ React3.createElement("div", {
175
- key: plugin.meta.id,
176
- className: "flex"
177
- }, /* @__PURE__ */ React3.createElement(PluginItem, {
178
- plugin,
179
- ...props
180
- }))));
181
- } finally {
182
- _effect.f();
183
- }
184
- };
185
-
186
- // src/components/RegistryContainer.tsx
187
- import { useSignals as _useSignals4 } from "@preact-signals/safe-react/tracking";
188
- import React4, { useCallback as useCallback2, useMemo } from "react";
189
- import { Capabilities, LayoutAction, SettingsAction, createIntent, useCapability, useIntentDispatcher, usePluginManager } from "@dxos/app-framework";
190
- import { ObservabilityAction } from "@dxos/plugin-observability/types";
191
- import { StackItem } from "@dxos/react-ui-stack";
192
- var sortByPluginMeta = ({ meta: { name: a = "" } }, { meta: { name: b = "" } }) => a.localeCompare(b);
193
- var RegistryContainer = ({ id, plugins: _plugins }) => {
194
- var _effect = _useSignals4();
195
- try {
196
- const manager = usePluginManager();
197
- const { dispatchPromise: dispatch } = useIntentDispatcher();
198
- const plugins = useMemo(() => _plugins.sort(sortByPluginMeta), [
199
- _plugins
200
- ]);
201
- const settingsStore = useCapability(Capabilities.SettingsStore);
202
- const handleChange = useCallback2(async (id2, enabled) => {
203
- if (enabled) {
204
- await manager.enable(id2);
205
- } else {
206
- await manager.disable(id2);
207
- }
208
- await dispatch(createIntent(ObservabilityAction.SendEvent, {
209
- name: "plugins.toggle",
210
- properties: {
211
- plugin: id2,
212
- enabled
213
- }
214
- }));
215
- }, [
216
- dispatch,
217
- manager
218
- ]);
219
- const handleClick = useCallback2((pluginId) => dispatch(createIntent(LayoutAction.Open, {
220
- part: "main",
221
- // TODO(wittjosiah): `/` currently is not supported in ids.
222
- subject: [
223
- pluginId.replaceAll("/", ":")
224
- ],
225
- options: {
226
- pivotId: id,
227
- positioning: "end"
228
- }
229
- })), [
230
- dispatch,
231
- id
232
- ]);
233
- const hasSettings = useCallback2((pluginId) => !!settingsStore.getStore(pluginId), [
234
- settingsStore
235
- ]);
236
- const handleSettings = useCallback2((pluginId) => dispatch(createIntent(SettingsAction.Open, {
237
- plugin: pluginId
238
- })), [
239
- dispatch
240
- ]);
241
- return /* @__PURE__ */ React4.createElement(StackItem.Content, {
242
- classNames: "min-bs-0 overflow-y-auto scrollbar-thin contain-layout"
243
- }, /* @__PURE__ */ React4.createElement(PluginList, {
244
- plugins,
245
- enabled: manager.enabled,
246
- onClick: handleClick,
247
- onChange: handleChange,
248
- hasSettings,
249
- onSettings: handleSettings
250
- }));
251
- } finally {
252
- _effect.f();
253
- }
254
- };
255
-
256
- // src/capabilities/react-surface.tsx
257
- var react_surface_default = () => contributes(Capabilities2.ReactSurface, [
258
- createSurface({
259
- id: `${REGISTRY_PLUGIN}/all`,
260
- role: "article",
261
- filter: (data) => data.subject === `${REGISTRY_KEY}+all`,
262
- component: () => {
263
- const manager = usePluginManager2();
264
- const filtered = useMemo2(() => manager.plugins.filter(({ meta }) => !manager.core.includes(meta.id)), []);
265
- return /* @__PURE__ */ React5.createElement(RegistryContainer, {
266
- id: `${REGISTRY_KEY}+all`,
267
- plugins: filtered
268
- });
269
- }
270
- }),
271
- createSurface({
272
- id: `${REGISTRY_PLUGIN}/installed`,
273
- role: "article",
274
- filter: (data) => data.subject === `${REGISTRY_KEY}+installed`,
275
- component: () => {
276
- const manager = usePluginManager2();
277
- const filtered = useMemo2(() => manager.plugins.filter(({ meta }) => !manager.core.includes(meta.id)).filter(({ meta }) => manager.enabled.includes(meta.id)), []);
278
- return /* @__PURE__ */ React5.createElement(RegistryContainer, {
279
- id: `${REGISTRY_KEY}+installed`,
280
- plugins: filtered
281
- });
282
- }
283
- }),
284
- createSurface({
285
- id: `${REGISTRY_PLUGIN}/recommended`,
286
- role: "article",
287
- filter: (data) => data.subject === `${REGISTRY_KEY}+recommended`,
288
- component: () => {
289
- const manager = usePluginManager2();
290
- const filtered = useMemo2(() => manager.plugins.filter(({ meta }) => !manager.core.includes(meta.id)).filter(({ meta }) => !meta.tags?.includes("labs")), []);
291
- return /* @__PURE__ */ React5.createElement(RegistryContainer, {
292
- id: `${REGISTRY_KEY}+recommended`,
293
- plugins: filtered
294
- });
295
- }
296
- }),
297
- createSurface({
298
- id: `${REGISTRY_PLUGIN}/labs`,
299
- role: "article",
300
- filter: (data) => data.subject === `${REGISTRY_KEY}+labs`,
301
- component: () => {
302
- const manager = usePluginManager2();
303
- const filtered = useMemo2(() => manager.plugins.filter(({ meta }) => meta.tags?.includes("labs")), []);
304
- return /* @__PURE__ */ React5.createElement(RegistryContainer, {
305
- id: `${REGISTRY_KEY}+labs`,
306
- plugins: filtered
307
- });
308
- }
309
- }),
310
- createSurface({
311
- id: `${REGISTRY_PLUGIN}/plugin-details`,
312
- role: "article",
313
- filter: (data) => data.subject instanceof Plugin,
314
- component: ({ data: { subject } }) => {
315
- const manager = usePluginManager2();
316
- const enabled = manager.enabled.includes(subject.meta.id);
317
- const handleEnable = useCallback3(() => enabled ? manager.disable(subject.meta.id) : manager.enable(subject.meta.id), [
318
- manager,
319
- subject.meta.id,
320
- enabled
321
- ]);
322
- return /* @__PURE__ */ React5.createElement(StackItem2.Content, null, /* @__PURE__ */ React5.createElement(PluginDetail, {
323
- plugin: subject,
324
- enabled,
325
- onEnable: handleEnable
326
- }));
327
- }
328
- })
329
- ]);
330
- export {
331
- react_surface_default as default
332
- };
333
- //# sourceMappingURL=react-surface-BQPO3F3E.mjs.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/capabilities/react-surface.tsx", "../../../src/components/PluginDetail.tsx", "../../../src/components/PluginList.tsx", "../../../src/components/PluginItem.tsx", "../../../src/components/RegistryContainer.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport React, { useCallback, useMemo } from 'react';\n\nimport { Capabilities, Plugin, contributes, createSurface, usePluginManager } from '@dxos/app-framework';\nimport { StackItem } from '@dxos/react-ui-stack';\n\nimport { PluginDetail, RegistryContainer } from '../components';\nimport { REGISTRY_KEY, REGISTRY_PLUGIN } from '../meta';\n\nexport default () =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: `${REGISTRY_PLUGIN}/all`,\n role: 'article',\n filter: (data): data is any => data.subject === `${REGISTRY_KEY}+all`,\n component: () => {\n const manager = usePluginManager();\n const filtered = useMemo(() => manager.plugins.filter(({ meta }) => !manager.core.includes(meta.id)), []);\n\n return <RegistryContainer id={`${REGISTRY_KEY}+all`} plugins={filtered} />;\n },\n }),\n createSurface({\n id: `${REGISTRY_PLUGIN}/installed`,\n role: 'article',\n filter: (data): data is any => data.subject === `${REGISTRY_KEY}+installed`,\n component: () => {\n const manager = usePluginManager();\n const filtered = useMemo(\n () =>\n manager.plugins\n .filter(({ meta }) => !manager.core.includes(meta.id))\n .filter(({ meta }) => manager.enabled.includes(meta.id)),\n [],\n );\n\n return <RegistryContainer id={`${REGISTRY_KEY}+installed`} plugins={filtered} />;\n },\n }),\n createSurface({\n id: `${REGISTRY_PLUGIN}/recommended`,\n role: 'article',\n filter: (data): data is any => data.subject === `${REGISTRY_KEY}+recommended`,\n component: () => {\n const manager = usePluginManager();\n const filtered = useMemo(\n () =>\n manager.plugins\n .filter(({ meta }) => !manager.core.includes(meta.id))\n .filter(({ meta }) => !meta.tags?.includes('labs')),\n [],\n );\n\n return <RegistryContainer id={`${REGISTRY_KEY}+recommended`} plugins={filtered} />;\n },\n }),\n createSurface({\n id: `${REGISTRY_PLUGIN}/labs`,\n role: 'article',\n filter: (data): data is any => data.subject === `${REGISTRY_KEY}+labs`,\n component: () => {\n const manager = usePluginManager();\n const filtered = useMemo(() => manager.plugins.filter(({ meta }) => meta.tags?.includes('labs')), []);\n\n return <RegistryContainer id={`${REGISTRY_KEY}+labs`} plugins={filtered} />;\n },\n }),\n createSurface({\n id: `${REGISTRY_PLUGIN}/plugin-details`,\n role: 'article',\n filter: (data): data is { subject: Plugin } => data.subject instanceof Plugin,\n component: ({ data: { subject } }) => {\n const manager = usePluginManager();\n const enabled = manager.enabled.includes(subject.meta.id);\n const handleEnable = useCallback(\n () => (enabled ? manager.disable(subject.meta.id) : manager.enable(subject.meta.id)),\n [manager, subject.meta.id, enabled],\n );\n\n return (\n <StackItem.Content>\n <PluginDetail plugin={subject} enabled={enabled} onEnable={handleEnable} />\n </StackItem.Content>\n );\n },\n }),\n ]);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { Icon, Input, Link, useTranslation } from '@dxos/react-ui';\nimport { DeprecatedFormContainer } from '@dxos/react-ui-form';\n\nimport { REGISTRY_PLUGIN } from '../meta';\n\nexport type PluginDetailProps = {\n plugin: Plugin;\n enabled?: boolean;\n onEnable?: () => void;\n};\n\nexport const PluginDetail = ({ plugin, enabled, onEnable }: PluginDetailProps) => {\n const { t } = useTranslation(REGISTRY_PLUGIN);\n const { id, name, description, homePage, source, screenshots } = plugin.meta;\n\n return (\n <DeprecatedFormContainer classNames='gap-6'>\n <div role='none' className='flex justify-between items-center'>\n <p>{id}</p>\n <Input.Root>\n <Input.Switch classNames='self-center' checked={enabled} onClick={onEnable} />\n </Input.Root>\n </div>\n\n {screenshots && screenshots.length > 0 && (\n <div role='none'>\n <h1 className='text-lg mb-2'>Preview</h1>\n <img src={screenshots[0]} alt={name} className='aspect-video object-fit' />\n </div>\n )}\n\n <div role='none'>\n <p>{description}</p>\n </div>\n\n <div role='none'>\n <h1 className='text-lg mb-2'>Resources</h1>\n <div className='flex gap-2'>\n {homePage && (\n <Link href={homePage} target='_blank' rel='noreferrer' classNames='text-sm text-description'>\n {t('home page label')}\n <Icon icon='ph--arrow-square-out--bold' size={3} classNames='inline-block leading-none mli-1' />\n </Link>\n )}\n\n {source && (\n <Link href={source} target='_blank' rel='noreferrer' classNames='text-sm text-description'>\n {t('source label')}\n <Icon icon='ph--arrow-square-out--bold' size={3} classNames='inline-block leading-none mli-1' />\n </Link>\n )}\n </div>\n </div>\n </DeprecatedFormContainer>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { List } from '@dxos/react-ui';\n\nimport { PluginItem, type PluginItemProps } from './PluginItem';\n\nexport type PluginListProps = Omit<PluginItemProps, 'plugin'> & {\n plugins?: readonly Plugin[];\n};\n\nexport const PluginList = ({ plugins = [], ...props }: PluginListProps) => {\n return (\n <List classNames='grid grid-cols-[repeat(auto-fill,minmax(280px,1fr))] auto-rows-[12rem] gap-3 p-3'>\n {plugins.map((plugin) => (\n <div key={plugin.meta.id} className='flex'>\n <PluginItem plugin={plugin} {...props} />\n </div>\n ))}\n </List>\n );\n};\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport React, { type MouseEvent, useCallback } from 'react';\n\nimport { type Plugin } from '@dxos/app-framework';\nimport { Icon, IconButton, Input, Link, ListItem, Tag, useTranslation } from '@dxos/react-ui';\nimport { descriptionText, mx } from '@dxos/react-ui-theme';\n\nimport { REGISTRY_PLUGIN } from '../meta';\n\nexport type PluginItemProps = {\n plugin: Plugin;\n installed?: readonly string[];\n enabled?: readonly string[];\n onClick?: (id: string) => void;\n onChange?: (id: string, enabled: boolean) => void;\n hasSettings?: (id: string) => boolean;\n onSettings?: (id: string) => void;\n};\n\nexport const PluginItem = ({\n plugin,\n enabled = [],\n onClick,\n onChange,\n hasSettings: _hasSettings,\n onSettings,\n}: PluginItemProps) => {\n const { t } = useTranslation(REGISTRY_PLUGIN);\n const { id, name, description, tags, icon = 'ph--circle--regular' } = plugin.meta;\n const isEnabled = enabled.includes(id);\n const inputId = `${id}-input`;\n const labelId = `${id}-label`;\n const descriptionId = `${id}-description`;\n const handleClick = useCallback(() => onClick?.(id), [id, onClick]);\n\n const handleChange = useCallback(\n (event: MouseEvent) => {\n event.stopPropagation();\n onChange?.(id, !isEnabled);\n },\n [id, isEnabled, onChange],\n );\n\n const hasSettings = _hasSettings?.(id) ?? false;\n const handleSettings = useCallback(() => onSettings?.(id), [id, onSettings]);\n\n return (\n <ListItem.Root\n key={id}\n labelId={labelId}\n data-testid={`pluginList.${id}`}\n aria-describedby={descriptionId}\n // TODO(burdon): Use Rail vars.\n classNames='is-full bs-full grid grid-cols-[48px_1fr_48px] grid-rows-[40px_1fr_32px] p-1 border border-separator rounded-md'\n >\n {/* Header. */}\n <div className='flex flex-col grow justify-center items-center'>\n <Icon icon={icon} size={6} onClick={handleClick} classNames='text-subdued cursor-pointer' />\n </div>\n <div className='flex items-center overflow-hidden cursor-pointer' onClick={handleClick}>\n <span className='truncate'>{name ?? id}</span>\n </div>\n <div className='flex justify-center items-center'>\n <Input.Root id={inputId}>\n <Input.Switch classNames='self-center' checked={isEnabled} onClick={handleChange} />\n </Input.Root>\n </div>\n\n {/* Body. */}\n <div />\n {(description || tags) && (\n <div id={descriptionId} className='col-span-2 flex flex-col w-full justify-between gap-2 pb-2'>\n <div className='grow'>\n <p className={mx(descriptionText, 'line-clamp-3 min-w-0 pie-2')}>{description}</p>\n </div>\n {tags && tags.length > 0 && (\n <div>\n {tags.map((tag) => (\n <Tag key={tag} palette={'indigo'} classNames='text-xs capitalize'>\n {tag}\n </Tag>\n ))}\n </div>\n )}\n </div>\n )}\n\n {/* Footer. */}\n <div />\n <div className='flex gap-2 items-center pie-1'>\n <Link\n aria-describedby={descriptionId}\n classNames='text-sm text-description cursor-pointer'\n onClick={handleClick}\n >\n {t('details label')}\n </Link>\n\n <div className='flex-1' />\n </div>\n <div className='flex justify-center items-center'>\n {hasSettings && (\n <IconButton\n aria-describedby={descriptionId}\n classNames='text-sm text-description cursor-pointer'\n icon='ph--gear--regular'\n label={t('settings label')}\n iconOnly\n size={4}\n onClick={handleSettings}\n />\n )}\n </div>\n </ListItem.Root>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React, { useCallback, useMemo } from 'react';\n\nimport {\n Capabilities,\n LayoutAction,\n type Plugin,\n SettingsAction,\n createIntent,\n useCapability,\n useIntentDispatcher,\n usePluginManager,\n} from '@dxos/app-framework';\nimport { ObservabilityAction } from '@dxos/plugin-observability/types';\nimport { StackItem } from '@dxos/react-ui-stack';\n\nimport { PluginList } from './PluginList';\n\nconst sortByPluginMeta = ({ meta: { name: a = '' } }: Plugin, { meta: { name: b = '' } }: Plugin) => a.localeCompare(b);\n\nexport const RegistryContainer = ({ id, plugins: _plugins }: { id: string; plugins: Plugin[] }) => {\n const manager = usePluginManager();\n const { dispatchPromise: dispatch } = useIntentDispatcher();\n const plugins = useMemo(() => _plugins.sort(sortByPluginMeta), [_plugins]);\n const settingsStore = useCapability(Capabilities.SettingsStore);\n\n // TODO(wittjosiah): Factor out to an intent?\n const handleChange = useCallback(\n async (id: string, enabled: boolean) => {\n if (enabled) {\n await manager.enable(id);\n } else {\n await manager.disable(id);\n }\n\n await dispatch(\n createIntent(ObservabilityAction.SendEvent, {\n name: 'plugins.toggle',\n properties: {\n plugin: id,\n enabled,\n },\n }),\n );\n },\n [dispatch, manager],\n );\n\n const handleClick = useCallback(\n (pluginId: string) =>\n dispatch(\n createIntent(LayoutAction.Open, {\n part: 'main',\n // TODO(wittjosiah): `/` currently is not supported in ids.\n subject: [pluginId.replaceAll('/', ':')],\n options: { pivotId: id, positioning: 'end' },\n }),\n ),\n [dispatch, id],\n );\n\n const hasSettings = useCallback((pluginId: string) => !!settingsStore.getStore(pluginId), [settingsStore]);\n\n const handleSettings = useCallback(\n (pluginId: string) => dispatch(createIntent(SettingsAction.Open, { plugin: pluginId })),\n [dispatch],\n );\n\n return (\n <StackItem.Content classNames='min-bs-0 overflow-y-auto scrollbar-thin contain-layout'>\n <PluginList\n plugins={plugins}\n enabled={manager.enabled}\n onClick={handleClick}\n onChange={handleChange}\n hasSettings={hasSettings}\n onSettings={handleSettings}\n />\n </StackItem.Content>\n );\n};\n"],
5
- "mappings": ";;;;;;AAIA,OAAOA,UAASC,eAAAA,cAAaC,WAAAA,gBAAe;AAE5C,SAASC,gBAAAA,eAAcC,QAAQC,aAAaC,eAAeC,oBAAAA,yBAAwB;AACnF,SAASC,aAAAA,kBAAiB;;;;ACH1B,OAAOC,WAAW;AAGlB,SAASC,MAAMC,OAAOC,MAAMC,sBAAsB;AAClD,SAASC,+BAA+B;AAUjC,IAAMC,eAAe,CAAC,EAAEC,QAAQC,SAASC,SAAQ,MAAqB;;;AAC3E,UAAM,EAAEC,EAAC,IAAKC,eAAeC,eAAAA;AAC7B,UAAM,EAAEC,IAAIC,MAAMC,aAAaC,UAAUC,QAAQC,YAAW,IAAKX,OAAOY;AAExE,WACE,sBAAA,cAACC,yBAAAA;MAAwBC,YAAW;OAClC,sBAAA,cAACC,OAAAA;MAAIC,MAAK;MAAOC,WAAU;OACzB,sBAAA,cAACC,KAAAA,MAAGZ,EAAAA,GACJ,sBAAA,cAACa,MAAMC,MAAI,MACT,sBAAA,cAACD,MAAME,QAAM;MAACP,YAAW;MAAcQ,SAASrB;MA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"names": ["React", "useCallback", "useMemo", "Capabilities", "Plugin", "contributes", "createSurface", "usePluginManager", "StackItem", "React", "Icon", "Input", "Link", "useTranslation", "DeprecatedFormContainer", "PluginDetail", "plugin", "enabled", "onEnable", "t", "useTranslation", "REGISTRY_PLUGIN", "id", "name", "description", "homePage", "source", "screenshots", "meta", "DeprecatedFormContainer", "classNames", "div", "role", "className", "p", "Input", "Root", "Switch", "checked", "onClick", "length", "h1", "img", "src", "alt", "Link", "href", "target", "rel", "Icon", "icon", "size", "React", "List", "React", "useCallback", "Icon", "IconButton", "Input", "Link", "ListItem", "Tag", "useTranslation", "descriptionText", "mx", "PluginItem", "plugin", "enabled", "onClick", "onChange", "hasSettings", "_hasSettings", "onSettings", "t", "useTranslation", "REGISTRY_PLUGIN", "id", "name", "description", "tags", "icon", "meta", "isEnabled", "includes", "inputId", "labelId", "descriptionId", "handleClick", "useCallback", "handleChange", "event", "stopPropagation", "handleSettings", "React", "ListItem", "Root", "key", "data-testid", "aria-describedby", "classNames", "div", "className", "Icon", "size", "span", "Input", "Switch", "checked", "p", "mx", "descriptionText", "length", "map", "tag", "Tag", "palette", "Link", "IconButton", "label", "iconOnly", "PluginList", "plugins", "props", "React", "List", "classNames", "map", "plugin", "div", "key", "meta", "id", "className", "PluginItem", "React", "useCallback", "useMemo", "Capabilities", "LayoutAction", "SettingsAction", "createIntent", "useCapability", "useIntentDispatcher", "usePluginManager", "ObservabilityAction", "StackItem", "sortByPluginMeta", "meta", "name", "a", "b", "localeCompare", "RegistryContainer", "id", "plugins", "_plugins", "manager", "usePluginManager", "dispatchPromise", "dispatch", "useIntentDispatcher", "useMemo", "sort", "settingsStore", "useCapability", "Capabilities", "SettingsStore", "handleChange", "useCallback", "enabled", "enable", "disable", "createIntent", "ObservabilityAction", "SendEvent", "properties", "plugin", "handleClick", "pluginId", "LayoutAction", "Open", "part", "subject", "replaceAll", "options", "pivotId", "positioning", "hasSettings", "getStore", "handleSettings", "SettingsAction", "React", "StackItem", "Content", "classNames", "PluginList", "onClick", "onChange", "onSettings", "contributes", "Capabilities", "ReactSurface", "createSurface", "id", "REGISTRY_PLUGIN", "role", "filter", "data", "subject", "REGISTRY_KEY", "component", "manager", "usePluginManager", "filtered", "useMemo", "plugins", "meta", "core", "includes", "React", "RegistryContainer", "enabled", "tags", "Plugin", "handleEnable", "useCallback", "disable", "enable", "StackItem", "Content", "PluginDetail", "plugin", "onEnable"]
7
- }
@@ -1,4 +0,0 @@
1
- import { Capabilities } from '@dxos/app-framework';
2
- declare const _default: () => import("@dxos/app-framework").Capability<Capabilities.IntentResolver>;
3
- export default _default;
4
- //# sourceMappingURL=intent-resolver.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"intent-resolver.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/intent-resolver.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,YAAY,EAMb,MAAM,qBAAqB,CAAC;;AAI7B,wBAWI"}
@@ -1,6 +0,0 @@
1
- import '@dxos-theme';
2
- import { type Meta } from '@storybook/react-vite';
3
- export declare const Default: {};
4
- declare const meta: Meta;
5
- export default meta;
6
- //# sourceMappingURL=Icon.stories.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Icon.stories.d.ts","sourceRoot":"","sources":["../../../../src/components/Icon.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAGrB,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,uBAAuB,CAAC;AA0FlD,eAAO,MAAM,OAAO,IAAK,CAAC;AAE1B,QAAA,MAAM,IAAI,EAAE,IAMX,CAAC;AAEF,eAAe,IAAI,CAAC"}
@@ -1,9 +0,0 @@
1
- import React from 'react';
2
- import { type Plugin } from '@dxos/app-framework';
3
- export type PluginDetailProps = {
4
- plugin: Plugin;
5
- enabled?: boolean;
6
- onEnable?: () => void;
7
- };
8
- export declare const PluginDetail: ({ plugin, enabled, onEnable }: PluginDetailProps) => React.JSX.Element;
9
- //# sourceMappingURL=PluginDetail.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PluginDetail.d.ts","sourceRoot":"","sources":["../../../../src/components/PluginDetail.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAMlD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;CACvB,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,+BAA+B,iBAAiB,sBA4C5E,CAAC"}
@@ -1,8 +0,0 @@
1
- import '@dxos-theme';
2
- import { type Meta, type StoryObj } from '@storybook/react-vite';
3
- import { type PluginDetailProps } from './PluginDetail';
4
- declare const meta: Meta<PluginDetailProps>;
5
- export default meta;
6
- type Story = StoryObj<PluginDetailProps>;
7
- export declare const Default: Story;
8
- //# sourceMappingURL=PluginDetail.stories.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PluginDetail.stories.d.ts","sourceRoot":"","sources":["../../../../src/components/PluginDetail.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,KAAK,IAAI,EAAE,KAAK,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAOjE,OAAO,EAAgB,KAAK,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAEtE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,iBAAiB,CAOjC,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,iBAAiB,CAAC,CAAC;AAEzC,eAAO,MAAM,OAAO,EAAE,KAiBrB,CAAC"}
@@ -1,13 +0,0 @@
1
- import React from 'react';
2
- import { type Plugin } from '@dxos/app-framework';
3
- export type PluginItemProps = {
4
- plugin: Plugin;
5
- installed?: readonly string[];
6
- enabled?: readonly string[];
7
- onClick?: (id: string) => void;
8
- onChange?: (id: string, enabled: boolean) => void;
9
- hasSettings?: (id: string) => boolean;
10
- onSettings?: (id: string) => void;
11
- };
12
- export declare const PluginItem: ({ plugin, enabled, onClick, onChange, hasSettings: _hasSettings, onSettings, }: PluginItemProps) => React.JSX.Element;
13
- //# sourceMappingURL=PluginItem.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PluginItem.d.ts","sourceRoot":"","sources":["../../../../src/components/PluginItem.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAuC,MAAM,OAAO,CAAC;AAE5D,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAMlD,MAAM,MAAM,eAAe,GAAG;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9B,OAAO,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC5B,OAAO,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,QAAQ,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IAClD,WAAW,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,CAAC;IACtC,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;CACnC,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,gFAOxB,eAAe,sBAyFjB,CAAC"}
@@ -1,8 +0,0 @@
1
- import React from 'react';
2
- import { type Plugin } from '@dxos/app-framework';
3
- import { type PluginItemProps } from './PluginItem';
4
- export type PluginListProps = Omit<PluginItemProps, 'plugin'> & {
5
- plugins?: readonly Plugin[];
6
- };
7
- export declare const PluginList: ({ plugins, ...props }: PluginListProps) => React.JSX.Element;
8
- //# sourceMappingURL=PluginList.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PluginList.d.ts","sourceRoot":"","sources":["../../../../src/components/PluginList.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAGlD,OAAO,EAAc,KAAK,eAAe,EAAE,MAAM,cAAc,CAAC;AAEhE,MAAM,MAAM,eAAe,GAAG,IAAI,CAAC,eAAe,EAAE,QAAQ,CAAC,GAAG;IAC9D,OAAO,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CAC7B,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,uBAA4B,eAAe,sBAUrE,CAAC"}
@@ -1,11 +0,0 @@
1
- import '@dxos-theme';
2
- import { type Meta } from '@storybook/react-vite';
3
- declare const meta: Meta;
4
- export default meta;
5
- export declare const Default: {};
6
- export declare const Column: {
7
- args: {
8
- classNames: string;
9
- };
10
- };
11
- //# sourceMappingURL=PluginList.stories.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"PluginList.stories.d.ts","sourceRoot":"","sources":["../../../../src/components/PluginList.stories.tsx"],"names":[],"mappings":"AAIA,OAAO,aAAa,CAAC;AAErB,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,uBAAuB,CAAC;AA0DlD,QAAA,MAAM,IAAI,EAAE,IAQX,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,OAAO,IAAK,CAAC;AAE1B,eAAO,MAAM,MAAM;;;;CAIlB,CAAC"}
@@ -1,7 +0,0 @@
1
- import React from 'react';
2
- import { type Plugin } from '@dxos/app-framework';
3
- export declare const RegistryContainer: ({ id, plugins: _plugins }: {
4
- id: string;
5
- plugins: Plugin[];
6
- }) => React.JSX.Element;
7
- //# sourceMappingURL=RegistryContainer.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RegistryContainer.d.ts","sourceRoot":"","sources":["../../../../src/components/RegistryContainer.tsx"],"names":[],"mappings":"AAIA,OAAO,KAA+B,MAAM,OAAO,CAAC;AAEpD,OAAO,EAGL,KAAK,MAAM,EAMZ,MAAM,qBAAqB,CAAC;AAQ7B,eAAO,MAAM,iBAAiB,GAAI,2BAA2B;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,EAAE,CAAA;CAAE,sBA4D7F,CAAC"}
@@ -1,27 +0,0 @@
1
- //
2
- // Copyright 2025 DXOS.org
3
- //
4
-
5
- import {
6
- Capabilities,
7
- LayoutAction,
8
- SettingsAction,
9
- contributes,
10
- createIntent,
11
- createResolver,
12
- } from '@dxos/app-framework';
13
-
14
- import { REGISTRY_ID } from '../meta';
15
-
16
- export default () =>
17
- contributes(
18
- Capabilities.IntentResolver,
19
- createResolver({
20
- intent: SettingsAction.OpenPluginRegistry,
21
- resolve: () => {
22
- return {
23
- intents: [createIntent(LayoutAction.SwitchWorkspace, { part: 'workspace', subject: REGISTRY_ID })],
24
- };
25
- },
26
- }),
27
- );
@@ -1,108 +0,0 @@
1
- //
2
- // Copyright 2023 DXOS.org
3
- //
4
-
5
- import '@dxos-theme';
6
-
7
- import { IconBase, type IconProps, type IconWeight } from '@phosphor-icons/react';
8
- import { type Meta } from '@storybook/react-vite';
9
- import React, { type ReactElement, type SVGProps, forwardRef } from 'react';
10
-
11
- import { Icon } from '@dxos/react-ui';
12
- import { getSize, mx } from '@dxos/react-ui-theme';
13
-
14
- /**
15
- * Serializable icon props.
16
- */
17
- type StoryIconProps = {
18
- name: string;
19
- weights: Record<string, SVGProps<SVGPathElement>[]>;
20
- };
21
-
22
- /**
23
- * Create icon from serializable data.
24
- * https://github.com/phosphor-icons/react#custom-icons
25
- * https://github.com/phosphor-icons/core/tree/main/assets
26
- */
27
- const createIcon = ({ name, weights }: StoryIconProps) => {
28
- const CustomIcon = forwardRef<SVGSVGElement, IconProps>((props, ref) => (
29
- <IconBase
30
- ref={ref}
31
- {...props}
32
- weights={
33
- new Map<IconWeight, ReactElement>(
34
- Object.entries(weights).map(
35
- ([key, paths]) =>
36
- [
37
- key,
38
- <>
39
- {paths.map((props, i) => (
40
- <path key={`${key}-${i}`} {...props} />
41
- ))}
42
- </>,
43
- ] as [IconWeight, ReactElement],
44
- ),
45
- )
46
- }
47
- />
48
- ));
49
- CustomIcon.displayName = name;
50
- return CustomIcon;
51
- };
52
-
53
- const DefaultStory = () => {
54
- const CustomIcon = createIcon({
55
- name: 'GithubLogo',
56
- weights: {
57
- // https://github.com/phosphor-icons/core/tree/main/assets
58
- // <path d="M119.83,56A52,52,0,0,0,76,32a51.92,51.92,0,0,0-3.49,44.7A49.28,49.28,0,0,0,64,104v8a48,48,0,0,0,48,48h48a48,48,0,0,0,48-48v-8a49.28,49.28,0,0,0-8.51-27.3A51.92,51.92,0,0,0,196,32a52,52,0,0,0-43.83,24Z" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
59
- // <path d="M104,232V192a32,32,0,0,1,32-32h0a32,32,0,0,1,32,32v40" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
60
- // <path d="M104,208H72a32,32,0,0,1-32-32A32,32,0,0,0,8,144" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="16"/>
61
- regular: [
62
- {
63
- d: 'M119.83,56A52,52,0,0,0,76,32a51.92,51.92,0,0,0-3.49,44.7A49.28,49.28,0,0,0,64,104v8a48,48,0,0,0,48,48h48a48,48,0,0,0,48-48v-8a49.28,49.28,0,0,0-8.51-27.3A51.92,51.92,0,0,0,196,32a52,52,0,0,0-43.83,24Z',
64
- fill: 'none',
65
- stroke: 'currentColor',
66
- strokeLinecap: 'round',
67
- strokeLinejoin: 'round',
68
- strokeWidth: '16',
69
- },
70
- {
71
- d: 'M104,232V192a32,32,0,0,1,32-32h0a32,32,0,0,1,32,32v40',
72
- fill: 'none',
73
- stroke: 'currentColor',
74
- strokeLinecap: 'round',
75
- strokeLinejoin: 'round',
76
- strokeWidth: '16',
77
- },
78
- {
79
- d: 'M104,208H72a32,32,0,0,1-32-32A32,32,0,0,0,8,144',
80
- fill: 'none',
81
- stroke: 'currentColor',
82
- strokeLinecap: 'round',
83
- strokeLinejoin: 'round',
84
- strokeWidth: '16',
85
- },
86
- ],
87
- },
88
- });
89
-
90
- return (
91
- <div className='flex gap-4 p-8 ring'>
92
- <CustomIcon weight={'regular'} className={mx(getSize(8))} />
93
- <Icon icon='ph--github-logo--regular' classNames={mx(getSize(8))} />
94
- </div>
95
- );
96
- };
97
-
98
- export const Default = {};
99
-
100
- const meta: Meta = {
101
- title: 'plugins/plugin-registry/Icon',
102
- render: DefaultStory,
103
- parameters: {
104
- layout: 'centered',
105
- },
106
- };
107
-
108
- export default meta;