@dxos/plugin-status-bar 0.8.1-staging.391c573 → 0.8.1-staging.9eaf14f

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.
@@ -42,19 +42,12 @@ var import_react_ui_theme = require("@dxos/react-ui-theme");
42
42
  var import_react2 = __toESM(require("react"));
43
43
  var import_app_framework = require("@dxos/app-framework");
44
44
  var import_react_ui = require("@dxos/react-ui");
45
- var import_react3 = require("@phosphor-icons/react");
46
- var import_react4 = __toESM(require("react"));
47
- var import_app_framework2 = require("@dxos/app-framework");
48
- var import_types = require("@dxos/plugin-observability/types");
49
- var import_react_ui2 = require("@dxos/react-ui");
50
- var import_react_ui_form = require("@dxos/react-ui-form");
51
- var import_react_ui_theme2 = require("@dxos/react-ui-theme");
52
45
  var import_formatDistance = require("date-fns/formatDistance");
53
- var import_react5 = __toESM(require("react"));
46
+ var import_react3 = __toESM(require("react"));
54
47
  var import_react_client = require("@dxos/react-client");
55
- var import_react_ui3 = require("@dxos/react-ui");
56
- var import_react6 = __toESM(require("react"));
57
- var import_app_framework3 = require("@dxos/app-framework");
48
+ var import_react_ui2 = require("@dxos/react-ui");
49
+ var import_react4 = __toESM(require("react"));
50
+ var import_app_framework2 = require("@dxos/app-framework");
58
51
  var StatusBarText = /* @__PURE__ */ (0, import_react.forwardRef)(({ classNames, children }, forwardedRef) => /* @__PURE__ */ import_react.default.createElement("span", {
59
52
  className: (0, import_react_ui_theme.mx)(classNames),
60
53
  ref: forwardedRef
@@ -102,172 +95,66 @@ var meta = {
102
95
  description: "Display a bar with status and actions.",
103
96
  icon: "ph--info--regular"
104
97
  };
105
- var entry = (translation) => ({
106
- [STATUS_BAR_PLUGIN]: translation
107
- });
108
- var mkTranslation = (t) => (key) => t(key);
109
- var translations = {
110
- "en-US": entry({
111
- "plugin name": "Status Bar",
112
- "name label": "Name",
113
- "name placeholder": "Preferred name",
114
- "email input label": "Email",
115
- "email input placeholder": "hello@example.com",
116
- "feedback text area label": "Feedback",
117
- "feedback text area placeholder": "Please describe your issue or suggestion.",
118
- "send feedback label": "Send Feedback",
119
- "warning title": "WARNING",
120
- "technology preview message": "Composer is currently in beta.",
121
- "learn more label": "Learn more",
122
- "released message": "This version released {{released}}.",
123
- "see release label": "See release on GitHub",
124
- "powered by dxos message": "Powered by <dxos>DXOS</dxos>",
125
- "discord label": "Discord",
126
- "feedback label": "Feedback"
127
- })
128
- };
129
- var translations_default = [
130
- translations
131
- ];
132
- var initialValues = {
133
- name: "",
134
- email: "",
135
- message: ""
136
- };
137
- var FeedbackForm = ({ onClose }) => {
138
- const { t } = (0, import_react_ui2.useTranslation)(STATUS_BAR_PLUGIN);
139
- const translation = mkTranslation(t);
140
- const { dispatchPromise: dispatch } = (0, import_app_framework2.useIntentDispatcher)();
141
- const onSave = (0, import_react4.useCallback)((values) => {
142
- void dispatch((0, import_app_framework2.createIntent)(import_types.ObservabilityAction.CaptureUserFeedback, values));
143
- onClose();
144
- }, [
145
- dispatch,
146
- onClose
147
- ]);
148
- const { handleSave, canSave, getStatus, ...inputProps } = (0, import_react_ui_form.useForm)({
149
- initialValues,
150
- schema: import_types.UserFeedback,
151
- onSave
152
- });
153
- return /* @__PURE__ */ import_react4.default.createElement("div", {
154
- role: "form",
155
- className: "p-3 flex flex-col gap-2"
156
- }, /* @__PURE__ */ import_react4.default.createElement("div", {
157
- role: "none",
158
- className: "space-b-1"
159
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Root, {
160
- validationValence: getStatus("name").status
161
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Label, null, translation("name label")), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.TextInput, {
162
- classNames: "text-sm",
163
- placeholder: translation("name placeholder"),
164
- autoFocus: true,
165
- ...inputProps
166
- }), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.DescriptionAndValidation, null, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Validation, null, getStatus("name").error)))), /* @__PURE__ */ import_react4.default.createElement("div", {
167
- role: "none",
168
- className: "space-b-1"
169
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Root, {
170
- validationValence: getStatus("email").status
171
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Label, null, translation("email input label")), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.TextInput, {
172
- classNames: "text-sm",
173
- placeholder: translation("email input placeholder"),
174
- ...inputProps
175
- }), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.DescriptionAndValidation, null, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Validation, null, getStatus("email").error)))), /* @__PURE__ */ import_react4.default.createElement("div", {
176
- role: "none",
177
- className: "space-b-1"
178
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Root, {
179
- validationValence: getStatus("message").status
180
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Label, null, translation("feedback text area label")), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.TextArea, {
181
- classNames: "text-sm",
182
- rows: 5,
183
- cols: 30,
184
- placeholder: translation("feedback text area placeholder"),
185
- ...inputProps
186
- }), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.DescriptionAndValidation, null, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Input.Validation, null, getStatus("message").error)))), /* @__PURE__ */ import_react4.default.createElement("div", {
187
- role: "none",
188
- className: "space-b-2"
189
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Button, {
190
- type: "submit",
191
- variant: "primary",
192
- classNames: "is-full flex gap-2",
193
- disabled: !canSave,
194
- onClick: handleSave
195
- }, /* @__PURE__ */ import_react4.default.createElement("span", null, translation("send feedback label")), /* @__PURE__ */ import_react4.default.createElement("div", {
196
- className: "grow"
197
- }), /* @__PURE__ */ import_react4.default.createElement(import_react3.PaperPlaneTilt, {
198
- className: (0, import_react_ui_theme2.getSize)(5)
199
- })), /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Popover.Close, {
200
- asChild: true
201
- }, /* @__PURE__ */ import_react4.default.createElement(import_react_ui2.Button, {
202
- classNames: "is-full flex gap-2"
203
- }, /* @__PURE__ */ import_react4.default.createElement("span", null, t("cancel label", {
204
- ns: "os"
205
- })), /* @__PURE__ */ import_react4.default.createElement("div", {
206
- className: "grow"
207
- }), /* @__PURE__ */ import_react4.default.createElement(import_react3.X, {
208
- className: (0, import_react_ui_theme2.getSize)(5)
209
- })))));
210
- };
211
98
  var repo = "https://github.com/dxos/dxos";
212
99
  var VERSION_REGEX = /([\d.]+)/;
213
100
  var VersionNumber = () => {
214
101
  const config = (0, import_react_client.useConfig)();
215
- const { t } = (0, import_react_ui3.useTranslation)(STATUS_BAR_PLUGIN);
102
+ const { t } = (0, import_react_ui2.useTranslation)(STATUS_BAR_PLUGIN);
216
103
  const { version, timestamp, commitHash } = config.values.runtime?.app?.build ?? {};
217
104
  const [_, v] = version?.match(VERSION_REGEX) ?? [];
218
105
  const isLabs = config.values.runtime?.app?.env?.DX_LABS;
219
106
  const releaseUrl = config.values.runtime?.app?.env?.DX_ENVIRONMENT === "production" ? `${repo}/releases/tag/v${version}` : `${repo}/commit/${commitHash}`;
220
107
  const previewUrl = "https://docs.dxos.org/composer#technology-preview";
221
- return /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Popover.Root, null, /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Popover.Trigger, {
108
+ return /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Popover.Root, null, /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Popover.Trigger, {
222
109
  asChild: true
223
- }, /* @__PURE__ */ import_react5.default.createElement(StatusBar.Button, {
110
+ }, /* @__PURE__ */ import_react3.default.createElement(StatusBar.Button, {
224
111
  classNames: "text-xs"
225
- }, isLabs ? version : v)), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Popover.Portal, null, /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Popover.Content, {
112
+ }, isLabs ? version : v)), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Popover.Portal, null, /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Popover.Content, {
226
113
  side: "top",
227
114
  role: "message",
228
115
  classNames: "z-[12] bg-warning-500 max-is-[min(calc(100vw-16px),40ch)]"
229
- }, /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Message.Root, {
116
+ }, /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Message.Root, {
230
117
  valence: "warning",
231
118
  className: "rounded-be-none p-5"
232
- }, /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Message.Title, null, /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Icon, {
119
+ }, /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Message.Title, null, /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Icon, {
233
120
  icon: "ph--warning--duotone",
234
121
  size: 6,
235
122
  classNames: "inline mie-2"
236
- }), /* @__PURE__ */ import_react5.default.createElement("span", null, t("warning title"))), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Message.Body, null, t("technology preview message"), /* @__PURE__ */ import_react5.default.createElement("br", null), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Link, {
123
+ }), /* @__PURE__ */ import_react3.default.createElement("span", null, t("warning title"))), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Message.Body, null, t("technology preview message"), /* @__PURE__ */ import_react3.default.createElement("br", null), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Link, {
237
124
  href: previewUrl,
238
125
  target: "_blank",
239
126
  rel: "noreferrer",
240
127
  variant: "neutral"
241
- }, t("learn more label"), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Icon, {
128
+ }, t("learn more label"), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Icon, {
242
129
  icon: "ph--arrow-square-out--bold",
243
130
  classNames: "inline mis-1"
244
- })))), /* @__PURE__ */ import_react5.default.createElement("div", {
131
+ })))), /* @__PURE__ */ import_react3.default.createElement("div", {
245
132
  role: "none",
246
133
  className: "plb-4 pli-5 space-b-2 text-baseText"
247
- }, timestamp && /* @__PURE__ */ import_react5.default.createElement("p", null, t("released message", {
134
+ }, timestamp && /* @__PURE__ */ import_react3.default.createElement("p", null, t("released message", {
248
135
  released: (0, import_formatDistance.formatDistance)(new Date(timestamp), /* @__PURE__ */ new Date(), {
249
136
  addSuffix: true
250
137
  })
251
- }), /* @__PURE__ */ import_react5.default.createElement("br", null), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Link, {
138
+ }), /* @__PURE__ */ import_react3.default.createElement("br", null), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Link, {
252
139
  href: releaseUrl,
253
140
  target: "_blank",
254
141
  rel: "noreferrer",
255
142
  variant: "neutral"
256
- }, t("see release label"), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Icon, {
143
+ }, t("see release label"), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Icon, {
257
144
  icon: "ph--arrow-square-out--bold",
258
145
  classNames: "inline mis-1"
259
- }))), /* @__PURE__ */ import_react5.default.createElement("p", null, /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Trans, {
146
+ }))), /* @__PURE__ */ import_react3.default.createElement("p", null, /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Trans, {
260
147
  t,
261
148
  i18nKey: "powered by dxos message",
262
149
  components: {
263
- dxos: /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Link, {
150
+ dxos: /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Link, {
264
151
  href: "https://dxos.org",
265
152
  target: "_blank",
266
153
  rel: "noreferrer",
267
154
  variant: "neutral"
268
155
  })
269
156
  }
270
- }))), /* @__PURE__ */ import_react5.default.createElement(import_react_ui3.Popover.Arrow, null))));
157
+ }))), /* @__PURE__ */ import_react3.default.createElement(import_react_ui2.Popover.Arrow, null))));
271
158
  };
272
159
  var StatusBarActions = () => {
273
160
  const { t } = (0, import_react_ui.useTranslation)(STATUS_BAR_PLUGIN);
@@ -275,31 +162,29 @@ var StatusBarActions = () => {
275
162
  return /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Popover.Root, {
276
163
  open,
277
164
  onOpenChange: setOpen
278
- }, /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Popover.Trigger, {
279
- asChild: true
280
165
  }, /* @__PURE__ */ import_react2.default.createElement(StatusBar.Button, {
281
- "data-joyride": "welcome/feedback"
166
+ asChild: true
167
+ }, /* @__PURE__ */ import_react2.default.createElement("a", {
168
+ href: "https://dxos.org/discord",
169
+ target: "_blank",
170
+ rel: "noopener noreferrer"
282
171
  }, /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Icon, {
283
- icon: "ph--paper-plane-tilt--regular",
172
+ icon: "ph--discord-logo--regular",
284
173
  size: 4
285
174
  }), /* @__PURE__ */ import_react2.default.createElement(StatusBar.Text, {
286
175
  classNames: "hidden sm:block"
287
- }, t("feedback label")))), /* @__PURE__ */ import_react2.default.createElement(StatusBar.Button, {
176
+ }, t("discord label")))), /* @__PURE__ */ import_react2.default.createElement(StatusBar.Button, {
288
177
  asChild: true
289
178
  }, /* @__PURE__ */ import_react2.default.createElement("a", {
290
- href: "https://dxos.org/discord",
179
+ href: "https://github.com/dxos/dxos",
291
180
  target: "_blank",
292
181
  rel: "noopener noreferrer"
293
182
  }, /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Icon, {
294
- icon: "ph--discord-logo--regular",
183
+ icon: "ph--github-logo--regular",
295
184
  size: 4
296
185
  }), /* @__PURE__ */ import_react2.default.createElement(StatusBar.Text, {
297
186
  classNames: "hidden sm:block"
298
- }, t("discord label")))), /* @__PURE__ */ import_react2.default.createElement(VersionNumber, null), /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Popover.Portal, null, /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Popover.Content, {
299
- classNames: "shadow-lg"
300
- }, /* @__PURE__ */ import_react2.default.createElement(FeedbackForm, {
301
- onClose: () => setOpen(false)
302
- }), /* @__PURE__ */ import_react2.default.createElement(import_react_ui.Popover.Arrow, null))));
187
+ }, t("github label")))), /* @__PURE__ */ import_react2.default.createElement(VersionNumber, null));
303
188
  };
304
189
  var StatusBarPanel = () => {
305
190
  return /* @__PURE__ */ import_react2.default.createElement(import_react2.default.Fragment, null, /* @__PURE__ */ import_react2.default.createElement(StatusBarActions, null), /* @__PURE__ */ import_react2.default.createElement("span", {
@@ -309,37 +194,57 @@ var StatusBarPanel = () => {
309
194
  role: "status"
310
195
  }));
311
196
  };
312
- var StatusBarPlugin = () => (0, import_app_framework3.definePlugin)(meta, [
313
- (0, import_app_framework3.defineModule)({
197
+ var entry = (translation) => ({
198
+ [STATUS_BAR_PLUGIN]: translation
199
+ });
200
+ var translations = {
201
+ "en-US": entry({
202
+ "plugin name": "Status Bar",
203
+ "warning title": "WARNING",
204
+ "technology preview message": "Composer is currently in beta.",
205
+ "learn more label": "Learn more",
206
+ "released message": "This version released {{released}}.",
207
+ "see release label": "See release on GitHub",
208
+ "powered by dxos message": "Powered by <dxos>DXOS</dxos>",
209
+ "discord label": "Discord",
210
+ "github label": "GitHub",
211
+ "feedback label": "Feedback"
212
+ })
213
+ };
214
+ var translations_default = [
215
+ translations
216
+ ];
217
+ var StatusBarPlugin = () => (0, import_app_framework2.definePlugin)(meta, [
218
+ (0, import_app_framework2.defineModule)({
314
219
  id: `${meta.id}/module/translations`,
315
- activatesOn: import_app_framework3.Events.SetupTranslations,
316
- activate: () => (0, import_app_framework3.contributes)(import_app_framework3.Capabilities.Translations, translations_default)
220
+ activatesOn: import_app_framework2.Events.SetupTranslations,
221
+ activate: () => (0, import_app_framework2.contributes)(import_app_framework2.Capabilities.Translations, translations_default)
317
222
  }),
318
- (0, import_app_framework3.defineModule)({
223
+ (0, import_app_framework2.defineModule)({
319
224
  id: `${meta.id}/module/react-surface`,
320
- activatesOn: import_app_framework3.Events.SetupReactSurface,
321
- activate: () => (0, import_app_framework3.contributes)(import_app_framework3.Capabilities.ReactSurface, [
322
- (0, import_app_framework3.createSurface)({
225
+ activatesOn: import_app_framework2.Events.SetupReactSurface,
226
+ activate: () => (0, import_app_framework2.contributes)(import_app_framework2.Capabilities.ReactSurface, [
227
+ (0, import_app_framework2.createSurface)({
323
228
  id: meta.id,
324
229
  role: "status-bar",
325
- component: () => /* @__PURE__ */ import_react6.default.createElement(StatusBarPanel, null)
230
+ component: () => /* @__PURE__ */ import_react4.default.createElement(StatusBarPanel, null)
326
231
  }),
327
- (0, import_app_framework3.createSurface)({
232
+ (0, import_app_framework2.createSurface)({
328
233
  id: meta.id,
329
234
  role: "status-bar--r0-footer",
330
- component: () => /* @__PURE__ */ import_react6.default.createElement(import_app_framework3.Surface, {
235
+ component: () => /* @__PURE__ */ import_react4.default.createElement(import_app_framework2.Surface, {
331
236
  role: "status"
332
237
  })
333
238
  }),
334
- (0, import_app_framework3.createSurface)({
239
+ (0, import_app_framework2.createSurface)({
335
240
  id: meta.id,
336
241
  role: "status-bar--r1-footer",
337
- component: () => /* @__PURE__ */ import_react6.default.createElement(StatusBarActions, null)
242
+ component: () => /* @__PURE__ */ import_react4.default.createElement(StatusBarActions, null)
338
243
  }),
339
- (0, import_app_framework3.createSurface)({
244
+ (0, import_app_framework2.createSurface)({
340
245
  id: `${STATUS_BAR_PLUGIN}/header-end`,
341
246
  role: "header-end",
342
- component: () => /* @__PURE__ */ import_react6.default.createElement(VersionNumber, null)
247
+ component: () => /* @__PURE__ */ import_react4.default.createElement(VersionNumber, null)
343
248
  })
344
249
  ])
345
250
  })
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/components/StatusBar.tsx", "../../../src/components/StatusBarPanel.tsx", "../../../src/components/FeedbackForm.tsx", "../../../src/meta.ts", "../../../src/translations.ts", "../../../src/components/VersionNumber.tsx", "../../../src/StatusBarPlugin.tsx"],
4
- "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { Slot } from '@radix-ui/react-slot';\nimport React, { type ComponentPropsWithRef, forwardRef, type PropsWithChildren, type ReactNode } from 'react';\n\nimport { type ThemedClassName } from '@dxos/react-ui';\nimport { mx } from '@dxos/react-ui-theme';\n\ntype StatusBarTextProps = ThemedClassName<{ children: ReactNode }>;\n\nconst StatusBarText = forwardRef<HTMLSpanElement, StatusBarTextProps>(({ classNames, children }, forwardedRef) => (\n <span className={mx(classNames)} ref={forwardedRef}>\n {children}\n </span>\n));\n\ntype StatusBarButtonProps = ThemedClassName<ComponentPropsWithRef<'button'> & { asChild?: boolean }>;\n\nconst StatusBarButton = forwardRef<HTMLButtonElement, StatusBarButtonProps>(\n ({ classNames, children, asChild, ...props }, forwardedRef) => {\n const classes = mx(\n 'flex items-center justify-center gap-2 p-1 px-2 rounded-sm',\n 'select-none cursor-pointer dx-focus-ring text-description text-xs',\n 'hover:bg-neutral-75 active:bg-neutral-150 dark:hover:bg-neutral-750 dark:active:bg-neutral-700',\n classNames,\n );\n\n return asChild ? (\n <Slot role='button' ref={forwardedRef} className={classes} {...props}>\n {children}\n </Slot>\n ) : (\n <button className={classes} ref={forwardedRef} {...props}>\n {children}\n </button>\n );\n },\n);\n\nexport default StatusBarButton;\n\ntype StatusBarItemProps = ThemedClassName<ComponentPropsWithRef<'div'>>;\n\nconst StatusBarItem = forwardRef<HTMLDivElement, StatusBarItemProps>(\n ({ classNames, children, ...props }, forwardedRef) => (\n <div\n role='menuitem'\n className={mx('flex items-center justify-center gap-2 p-1 px-2 rounded-sm select-none', classNames)}\n ref={forwardedRef}\n {...props}\n >\n {children}\n </div>\n ),\n);\n\ntype StartContentProps = ThemedClassName<PropsWithChildren<{}>>;\n\nconst StartContent = forwardRef<HTMLDivElement, StartContentProps>(({ classNames, children }, forwardedRef) => (\n <div role='none' className={mx('flex-grow flex items-center space-x-2', classNames)} ref={forwardedRef}>\n {children}\n </div>\n));\n\ntype EndContentProps = ThemedClassName<PropsWithChildren<{}>>;\n\nconst EndContent = forwardRef<HTMLDivElement, EndContentProps>(({ classNames, children }, forwardedRef) => (\n <div role='none' className={mx('flex-grow flex items-center justify-end', classNames)} ref={forwardedRef}>\n {children}\n </div>\n));\n\nexport const StatusBar = {\n Text: StatusBarText,\n Item: StatusBarItem,\n Button: StatusBarButton,\n StartContent,\n EndContent,\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useState } from 'react';\n\nimport { Surface } from '@dxos/app-framework';\nimport { Icon, Popover, useTranslation } from '@dxos/react-ui';\n\nimport { FeedbackForm } from './FeedbackForm';\nimport { StatusBar } from './StatusBar';\nimport { VersionNumber } from './VersionNumber';\nimport { STATUS_BAR_PLUGIN } from '../meta';\n\nexport const StatusBarActions = () => {\n const { t } = useTranslation(STATUS_BAR_PLUGIN);\n const [open, setOpen] = useState(false);\n return (\n <Popover.Root open={open} onOpenChange={setOpen}>\n <Popover.Trigger asChild>\n <StatusBar.Button data-joyride='welcome/feedback'>\n <Icon icon='ph--paper-plane-tilt--regular' size={4} />\n <StatusBar.Text classNames='hidden sm:block'>{t('feedback label')}</StatusBar.Text>\n </StatusBar.Button>\n </Popover.Trigger>\n {/* TODO(zan): Configure this label? */}\n <StatusBar.Button asChild>\n <a href='https://dxos.org/discord' target='_blank' rel='noopener noreferrer'>\n <Icon icon='ph--discord-logo--regular' size={4} />\n <StatusBar.Text classNames='hidden sm:block'>{t('discord label')}</StatusBar.Text>\n </a>\n </StatusBar.Button>\n <VersionNumber />\n <Popover.Portal>\n <Popover.Content classNames='shadow-lg'>\n <FeedbackForm onClose={() => setOpen(false)} />\n <Popover.Arrow />\n </Popover.Content>\n </Popover.Portal>\n </Popover.Root>\n );\n};\n\nexport const StatusBarPanel = () => {\n return (\n <>\n <StatusBarActions />\n <span role='separator' className='grow' />\n <Surface role='status' />\n </>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { PaperPlaneTilt, X } from '@phosphor-icons/react';\nimport React, { useCallback } from 'react';\n\nimport { createIntent, useIntentDispatcher } from '@dxos/app-framework';\nimport { ObservabilityAction, UserFeedback } from '@dxos/plugin-observability/types';\nimport { Button, Input, Popover, useTranslation } from '@dxos/react-ui';\nimport { useForm } from '@dxos/react-ui-form';\nimport { getSize } from '@dxos/react-ui-theme';\n\nimport { STATUS_BAR_PLUGIN } from '../meta';\nimport { mkTranslation } from '../translations';\n\nconst initialValues: UserFeedback = { name: '', email: '', message: '' };\n\nexport const FeedbackForm = ({ onClose }: { onClose: () => void }) => {\n const { t } = useTranslation(STATUS_BAR_PLUGIN);\n const translation = mkTranslation(t);\n const { dispatchPromise: dispatch } = useIntentDispatcher();\n\n const onSave = useCallback(\n (values: UserFeedback) => {\n void dispatch(createIntent(ObservabilityAction.CaptureUserFeedback, values));\n onClose();\n },\n [dispatch, onClose],\n );\n\n const { handleSave, canSave, getStatus, ...inputProps } = useForm<UserFeedback>({\n initialValues,\n schema: UserFeedback,\n onSave,\n });\n\n return (\n <div role='form' className='p-3 flex flex-col gap-2'>\n <div role='none' className='space-b-1'>\n <Input.Root validationValence={getStatus('name').status}>\n <Input.Label>{translation('name label')}</Input.Label>\n <Input.TextInput\n classNames={'text-sm'}\n placeholder={translation('name placeholder')}\n autoFocus\n {...inputProps}\n />\n <Input.DescriptionAndValidation>\n <Input.Validation>{getStatus('name').error}</Input.Validation>\n </Input.DescriptionAndValidation>\n </Input.Root>\n </div>\n\n <div role='none' className='space-b-1'>\n <Input.Root validationValence={getStatus('email').status}>\n <Input.Label>{translation('email input label')}</Input.Label>\n <Input.TextInput\n classNames={'text-sm'}\n placeholder={translation('email input placeholder')}\n {...inputProps}\n />\n <Input.DescriptionAndValidation>\n <Input.Validation>{getStatus('email').error}</Input.Validation>\n </Input.DescriptionAndValidation>\n </Input.Root>\n </div>\n\n <div role='none' className='space-b-1'>\n <Input.Root validationValence={getStatus('message').status}>\n <Input.Label>{translation('feedback text area label')}</Input.Label>\n <Input.TextArea\n classNames={'text-sm'}\n rows={5}\n cols={30}\n placeholder={translation('feedback text area placeholder')}\n {...inputProps}\n />\n <Input.DescriptionAndValidation>\n <Input.Validation>{getStatus('message').error}</Input.Validation>\n </Input.DescriptionAndValidation>\n </Input.Root>\n </div>\n\n <div role='none' className='space-b-2'>\n <Button\n type='submit'\n variant='primary'\n classNames='is-full flex gap-2'\n disabled={!canSave}\n onClick={handleSave}\n >\n <span>{translation('send feedback label')}</span>\n <div className='grow' />\n <PaperPlaneTilt className={getSize(5)} />\n </Button>\n <Popover.Close asChild>\n <Button classNames='is-full flex gap-2'>\n <span>{t('cancel label', { ns: 'os' })}</span>\n <div className='grow' />\n <X className={getSize(5)} />\n </Button>\n </Popover.Close>\n </div>\n </div>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { type PluginMeta } from '@dxos/app-framework';\n\nexport const STATUS_BAR_PLUGIN = 'dxos.org/plugin/status-bar';\n\nexport const meta = {\n id: STATUS_BAR_PLUGIN,\n name: 'Status Bar',\n description: 'Display a bar with status and actions.',\n icon: 'ph--info--regular',\n} satisfies PluginMeta;\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type useTranslation } from '@dxos/react-ui';\n\nimport { STATUS_BAR_PLUGIN } from './meta';\n\ntype StatusBarTranslationKeys =\n | 'plugin name'\n | 'email input label'\n | 'email input placeholder'\n | 'feedback text area label'\n | 'feedback text area placeholder'\n | 'send feedback label'\n | 'name label'\n | 'name placeholder'\n | 'warning title'\n | 'technology preview message'\n | 'learn more label'\n | 'released message'\n | 'see release label'\n | 'powered by dxos message'\n | 'discord label'\n | 'feedback label';\n\ntype RequiredTranslation = { [key in StatusBarTranslationKeys]: string };\ntype TranslationEntry = { [STATUS_BAR_PLUGIN]: RequiredTranslation };\ntype Language = string;\n\n// -- helpers.\nconst entry = (translation: RequiredTranslation): TranslationEntry => ({ [STATUS_BAR_PLUGIN]: translation });\nexport const mkTranslation = (t: ReturnType<typeof useTranslation>['t']) => (key: StatusBarTranslationKeys) => t(key);\n\nconst translations: Record<Language, TranslationEntry> = {\n 'en-US': entry({\n 'plugin name': 'Status Bar',\n 'name label': 'Name',\n 'name placeholder': 'Preferred name',\n 'email input label': 'Email',\n 'email input placeholder': 'hello@example.com',\n 'feedback text area label': 'Feedback',\n 'feedback text area placeholder': 'Please describe your issue or suggestion.',\n 'send feedback label': 'Send Feedback',\n 'warning title': 'WARNING',\n 'technology preview message': 'Composer is currently in beta.',\n 'learn more label': 'Learn more',\n 'released message': 'This version released {{released}}.',\n 'see release label': 'See release on GitHub',\n 'powered by dxos message': 'Powered by <dxos>DXOS</dxos>',\n 'discord label': 'Discord',\n 'feedback label': 'Feedback',\n }),\n};\n\nexport default [translations];\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { formatDistance } from 'date-fns/formatDistance';\nimport React from 'react';\n\nimport { useConfig } from '@dxos/react-client';\nimport { Link, Message, Popover, Trans, useTranslation, Icon } from '@dxos/react-ui';\n\nimport { StatusBar } from './StatusBar';\nimport { STATUS_BAR_PLUGIN } from '../meta';\n\nconst repo = 'https://github.com/dxos/dxos';\n\nconst VERSION_REGEX = /([\\d.]+)/;\n\nexport const VersionNumber = () => {\n const config = useConfig();\n const { t } = useTranslation(STATUS_BAR_PLUGIN);\n const { version, timestamp, commitHash } = config.values.runtime?.app?.build ?? {};\n const [_, v] = version?.match(VERSION_REGEX) ?? [];\n const isLabs = config.values.runtime?.app?.env?.DX_LABS;\n\n const releaseUrl =\n config.values.runtime?.app?.env?.DX_ENVIRONMENT === 'production'\n ? `${repo}/releases/tag/v${version}`\n : `${repo}/commit/${commitHash}`;\n\n const previewUrl = 'https://docs.dxos.org/composer#technology-preview';\n\n return (\n <Popover.Root>\n <Popover.Trigger asChild>\n <StatusBar.Button classNames='text-xs'>{isLabs ? version : v}</StatusBar.Button>\n </Popover.Trigger>\n <Popover.Portal>\n <Popover.Content\n side='top'\n role='message'\n classNames='z-[12] bg-warning-500 max-is-[min(calc(100vw-16px),40ch)]'\n >\n <Message.Root valence='warning' className='rounded-be-none p-5'>\n <Message.Title>\n <Icon icon='ph--warning--duotone' size={6} classNames='inline mie-2' />\n <span>{t('warning title')}</span>\n </Message.Title>\n <Message.Body>\n {t('technology preview message')}\n <br />\n <Link href={previewUrl} target='_blank' rel='noreferrer' variant='neutral'>\n {t('learn more label')}\n <Icon icon='ph--arrow-square-out--bold' classNames='inline mis-1' />\n </Link>\n </Message.Body>\n </Message.Root>\n <div role='none' className='plb-4 pli-5 space-b-2 text-baseText'>\n {timestamp && (\n <p>\n {t('released message', {\n released: formatDistance(new Date(timestamp), new Date(), { addSuffix: true }),\n })}\n <br />\n <Link href={releaseUrl} target='_blank' rel='noreferrer' variant='neutral'>\n {t('see release label')}\n <Icon icon='ph--arrow-square-out--bold' classNames='inline mis-1' />\n </Link>\n </p>\n )}\n <p>\n <Trans\n {...{\n t,\n i18nKey: 'powered by dxos message',\n components: {\n dxos: <Link href='https://dxos.org' target='_blank' rel='noreferrer' variant='neutral' />,\n },\n }}\n />\n </p>\n </div>\n <Popover.Arrow />\n </Popover.Content>\n </Popover.Portal>\n </Popover.Root>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React from 'react';\n\nimport {\n Capabilities,\n contributes,\n createSurface,\n defineModule,\n definePlugin,\n Events,\n Surface,\n} from '@dxos/app-framework';\n\nimport { StatusBarActions, StatusBarPanel } from './components';\nimport { VersionNumber } from './components/VersionNumber';\nimport { meta, STATUS_BAR_PLUGIN } from './meta';\nimport translations from './translations';\n\nexport const StatusBarPlugin = () =>\n definePlugin(meta, [\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.SetupReactSurface,\n activate: () =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: meta.id,\n role: 'status-bar',\n component: () => <StatusBarPanel />,\n }),\n createSurface({\n id: meta.id,\n role: 'status-bar--r0-footer',\n component: () => <Surface role='status' />,\n }),\n createSurface({\n id: meta.id,\n role: 'status-bar--r1-footer',\n component: () => <StatusBarActions />,\n }),\n createSurface({\n id: `${STATUS_BAR_PLUGIN}/header-end`,\n role: 'header-end',\n component: () => <VersionNumber />,\n }),\n ]),\n }),\n ]);\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,wBAAqB;AACrB,mBAAsG;AAGtG,4BAAmB;ACJnB,IAAAA,gBAAgC;AAEhC,2BAAwB;AACxB,sBAA8C;ACH9C,IAAAA,gBAAkC;AAClC,IAAAA,gBAAmC;AAEnC,IAAAC,wBAAkD;AAClD,mBAAkD;AAClD,IAAAC,mBAAuD;AACvD,2BAAwB;AACxB,IAAAC,yBAAwB;AGPxB,4BAA+B;AAC/B,IAAAH,gBAAkB;AAElB,0BAA0B;AAC1B,IAAAE,mBAAoE;ACJpE,IAAAF,gBAAkB;AAElB,IAAAC,wBAQO;ANFP,IAAMG,gBAAgBC,6CAAgD,CAAC,EAAEC,YAAYC,SAAQ,GAAIC,iBAC/F,6BAAAC,QAAA,cAACC,QAAAA;EAAKC,eAAWC,0BAAGN,UAAAA;EAAaO,KAAKL;GACnCD,QAAAA,CAAAA;AAML,IAAMO,kBAAkBT,6CACtB,CAAC,EAAEC,YAAYC,UAAUQ,SAAS,GAAGC,MAAAA,GAASR,iBAAAA;AAC5C,QAAMS,cAAUL,0BACd,8DACA,qEACA,kGACAN,UAAAA;AAGF,SAAOS,UACL,6BAAAN,QAAA,cAACS,wBAAAA;IAAKC,MAAK;IAASN,KAAKL;IAAcG,WAAWM;IAAU,GAAGD;KAC5DT,QAAAA,IAGH,6BAAAE,QAAA,cAACW,UAAAA;IAAOT,WAAWM;IAASJ,KAAKL;IAAe,GAAGQ;KAChDT,QAAAA;AAGP,CAAA;AAOF,IAAMc,gBAAgBhB,6CACpB,CAAC,EAAEC,YAAYC,UAAU,GAAGS,MAAAA,GAASR,iBACnC,6BAAAC,QAAA,cA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jCF,8BAAAA,QAAA,cAACmI,8BAAAA;IAAQzH,MAAK;;AAGpB;AK9BO,IAAM0H,kBAAkB,UAC7BC,oCAAahH,MAAM;MACjBiH,oCAAa;IACXhH,IAAI,GAAGD,KAAKC,EAAE;IACdiH,aAAaC,6BAAOC;IACpBC,UAAU,UAAMC,mCAAYC,mCAAaC,cAAc9G,oBAAAA;EACzD,CAAA;MACAuG,oCAAa;IACXhH,IAAI,GAAGD,KAAKC,EAAE;IACdiH,aAAaC,6BAAOM;IACpBJ,UAAU,UACRC,mCAAYC,mCAAaG,cAAc;UACrCC,qCAAc;QACZ1H,IAAID,KAAKC;QACTZ,MAAM;QACNuI,WAAW,MAAMjJ,8BAAAA,QAAA,cAACkI,gBAAAA,IAAAA;MACpB,CAAA;UACAc,qCAAc;QACZ1H,IAAID,KAAKC;QACTZ,MAAM;QACNuI,WAAW,MAAMjJ,8BAAAA,QAAA,cAACmI,sBAAAA,SAAAA;UAAQzH,MAAK;;MACjC,CAAA;UACAsI,qCAAc;QACZ1H,IAAID,KAAKC;QACTZ,MAAM;QACNuI,WAAW,MAAMjJ,8BAAAA,QAAA,cAAC2H,kBAAAA,IAAAA;MACpB,CAAA;UACAqB,qCAAc;QACZ1H,IAAI,GAAGF,iBAAAA;QACPV,MAAM;QACNuI,WAAW,MAAMjJ,8BAAAA,QAAA,cAACgF,eAAAA,IAAAA;MACpB,CAAA;KACD;EACL,CAAA;CACD;",
6
- "names": ["import_react", "import_app_framework", "import_react_ui", "import_react_ui_theme", "StatusBarText", "forwardRef", "classNames", "children", "forwardedRef", "React", "span", "className", "mx", "ref", "StatusBarButton", "asChild", "props", "classes", "Slot", "role", "button", "StatusBarItem", "div", "StartContent", "EndContent", "StatusBar", "Text", "Item", "Button", "STATUS_BAR_PLUGIN", "meta", "id", "name", "description", "icon", "entry", "translation", "mkTranslation", "t", "key", "translations", "initialValues", "email", "message", "FeedbackForm", "onClose", "useTranslation", "dispatchPromise", "dispatch", "useIntentDispatcher", "onSave", "useCallback", "values", "createIntent", "ObservabilityAction", "CaptureUserFeedback", "handleSave", "canSave", "getStatus", "inputProps", "useForm", "schema", "UserFeedback", "Input", "Root", "validationValence", "status", "Label", "TextInput", "placeholder", "autoFocus", "DescriptionAndValidation", "Validation", "error", "TextArea", "rows", "cols", "type", "variant", "disabled", "onClick", "PaperPlaneTilt", "getSize", "Popover", "Close", "ns", "X", "repo", "VERSION_REGEX", "VersionNumber", "config", "useConfig", "version", "timestamp", "commitHash", "runtime", "app", "build", "_", "v", "match", "isLabs", "env", "DX_LABS", "releaseUrl", "DX_ENVIRONMENT", "previewUrl", "Trigger", "Portal", "Content", "side", "Message", "valence", "Title", "Icon", "size", "Body", "br", "Link", "href", "target", "rel", "p", "released", "formatDistance", "Date", "addSuffix", "Trans", "i18nKey", "components", "dxos", "Arrow", "StatusBarActions", "open", "setOpen", "useState", "onOpenChange", "data-joyride", "a", "StatusBarPanel", "Surface", "StatusBarPlugin", "definePlugin", "defineModule", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "SetupReactSurface", "ReactSurface", "createSurface", "component"]
3
+ "sources": ["../../../src/components/StatusBar.tsx", "../../../src/components/StatusBarPanel.tsx", "../../../src/components/VersionNumber.tsx", "../../../src/meta.ts", "../../../src/StatusBarPlugin.tsx", "../../../src/translations.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport { Slot } from '@radix-ui/react-slot';\nimport React, { type ComponentPropsWithRef, forwardRef, type PropsWithChildren, type ReactNode } from 'react';\n\nimport { type ThemedClassName } from '@dxos/react-ui';\nimport { mx } from '@dxos/react-ui-theme';\n\ntype StatusBarTextProps = ThemedClassName<{ children: ReactNode }>;\n\nconst StatusBarText = forwardRef<HTMLSpanElement, StatusBarTextProps>(({ classNames, children }, forwardedRef) => (\n <span className={mx(classNames)} ref={forwardedRef}>\n {children}\n </span>\n));\n\ntype StatusBarButtonProps = ThemedClassName<ComponentPropsWithRef<'button'> & { asChild?: boolean }>;\n\nconst StatusBarButton = forwardRef<HTMLButtonElement, StatusBarButtonProps>(\n ({ classNames, children, asChild, ...props }, forwardedRef) => {\n const classes = mx(\n 'flex items-center justify-center gap-2 p-1 px-2 rounded-sm',\n 'select-none cursor-pointer dx-focus-ring text-description text-xs',\n 'hover:bg-neutral-75 active:bg-neutral-150 dark:hover:bg-neutral-750 dark:active:bg-neutral-700',\n classNames,\n );\n\n return asChild ? (\n <Slot role='button' ref={forwardedRef} className={classes} {...props}>\n {children}\n </Slot>\n ) : (\n <button className={classes} ref={forwardedRef} {...props}>\n {children}\n </button>\n );\n },\n);\n\nexport default StatusBarButton;\n\ntype StatusBarItemProps = ThemedClassName<ComponentPropsWithRef<'div'>>;\n\nconst StatusBarItem = forwardRef<HTMLDivElement, StatusBarItemProps>(\n ({ classNames, children, ...props }, forwardedRef) => (\n <div\n role='menuitem'\n className={mx('flex items-center justify-center gap-2 p-1 px-2 rounded-sm select-none', classNames)}\n ref={forwardedRef}\n {...props}\n >\n {children}\n </div>\n ),\n);\n\ntype StartContentProps = ThemedClassName<PropsWithChildren<{}>>;\n\nconst StartContent = forwardRef<HTMLDivElement, StartContentProps>(({ classNames, children }, forwardedRef) => (\n <div role='none' className={mx('flex-grow flex items-center space-x-2', classNames)} ref={forwardedRef}>\n {children}\n </div>\n));\n\ntype EndContentProps = ThemedClassName<PropsWithChildren<{}>>;\n\nconst EndContent = forwardRef<HTMLDivElement, EndContentProps>(({ classNames, children }, forwardedRef) => (\n <div role='none' className={mx('flex-grow flex items-center justify-end', classNames)} ref={forwardedRef}>\n {children}\n </div>\n));\n\nexport const StatusBar = {\n Text: StatusBarText,\n Item: StatusBarItem,\n Button: StatusBarButton,\n StartContent,\n EndContent,\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { useState } from 'react';\n\nimport { Surface } from '@dxos/app-framework';\nimport { Icon, Popover, useTranslation } from '@dxos/react-ui';\n\nimport { StatusBar } from './StatusBar';\nimport { VersionNumber } from './VersionNumber';\nimport { STATUS_BAR_PLUGIN } from '../meta';\n\nexport const StatusBarActions = () => {\n const { t } = useTranslation(STATUS_BAR_PLUGIN);\n const [open, setOpen] = useState(false);\n\n return (\n <Popover.Root open={open} onOpenChange={setOpen}>\n {/* TODO(zan): Configure this label? */}\n <StatusBar.Button asChild>\n <a href='https://dxos.org/discord' target='_blank' rel='noopener noreferrer'>\n <Icon icon='ph--discord-logo--regular' size={4} />\n <StatusBar.Text classNames='hidden sm:block'>{t('discord label')}</StatusBar.Text>\n </a>\n </StatusBar.Button>\n <StatusBar.Button asChild>\n <a href='https://github.com/dxos/dxos' target='_blank' rel='noopener noreferrer'>\n <Icon icon='ph--github-logo--regular' size={4} />\n <StatusBar.Text classNames='hidden sm:block'>{t('github label')}</StatusBar.Text>\n </a>\n </StatusBar.Button>\n <VersionNumber />\n </Popover.Root>\n );\n};\n\nexport const StatusBarPanel = () => {\n return (\n <>\n <StatusBarActions />\n <span role='separator' className='grow' />\n <Surface role='status' />\n </>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { formatDistance } from 'date-fns/formatDistance';\nimport React from 'react';\n\nimport { useConfig } from '@dxos/react-client';\nimport { Link, Message, Popover, Trans, useTranslation, Icon } from '@dxos/react-ui';\n\nimport { StatusBar } from './StatusBar';\nimport { STATUS_BAR_PLUGIN } from '../meta';\n\nconst repo = 'https://github.com/dxos/dxos';\n\nconst VERSION_REGEX = /([\\d.]+)/;\n\nexport const VersionNumber = () => {\n const config = useConfig();\n const { t } = useTranslation(STATUS_BAR_PLUGIN);\n const { version, timestamp, commitHash } = config.values.runtime?.app?.build ?? {};\n const [_, v] = version?.match(VERSION_REGEX) ?? [];\n const isLabs = config.values.runtime?.app?.env?.DX_LABS;\n\n const releaseUrl =\n config.values.runtime?.app?.env?.DX_ENVIRONMENT === 'production'\n ? `${repo}/releases/tag/v${version}`\n : `${repo}/commit/${commitHash}`;\n\n const previewUrl = 'https://docs.dxos.org/composer#technology-preview';\n\n return (\n <Popover.Root>\n <Popover.Trigger asChild>\n <StatusBar.Button classNames='text-xs'>{isLabs ? version : v}</StatusBar.Button>\n </Popover.Trigger>\n <Popover.Portal>\n <Popover.Content\n side='top'\n role='message'\n classNames='z-[12] bg-warning-500 max-is-[min(calc(100vw-16px),40ch)]'\n >\n <Message.Root valence='warning' className='rounded-be-none p-5'>\n <Message.Title>\n <Icon icon='ph--warning--duotone' size={6} classNames='inline mie-2' />\n <span>{t('warning title')}</span>\n </Message.Title>\n <Message.Body>\n {t('technology preview message')}\n <br />\n <Link href={previewUrl} target='_blank' rel='noreferrer' variant='neutral'>\n {t('learn more label')}\n <Icon icon='ph--arrow-square-out--bold' classNames='inline mis-1' />\n </Link>\n </Message.Body>\n </Message.Root>\n <div role='none' className='plb-4 pli-5 space-b-2 text-baseText'>\n {timestamp && (\n <p>\n {t('released message', {\n released: formatDistance(new Date(timestamp), new Date(), { addSuffix: true }),\n })}\n <br />\n <Link href={releaseUrl} target='_blank' rel='noreferrer' variant='neutral'>\n {t('see release label')}\n <Icon icon='ph--arrow-square-out--bold' classNames='inline mis-1' />\n </Link>\n </p>\n )}\n <p>\n <Trans\n {...{\n t,\n i18nKey: 'powered by dxos message',\n components: {\n dxos: <Link href='https://dxos.org' target='_blank' rel='noreferrer' variant='neutral' />,\n },\n }}\n />\n </p>\n </div>\n <Popover.Arrow />\n </Popover.Content>\n </Popover.Portal>\n </Popover.Root>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport { type PluginMeta } from '@dxos/app-framework';\n\nexport const STATUS_BAR_PLUGIN = 'dxos.org/plugin/status-bar';\n\nexport const meta: PluginMeta = {\n id: STATUS_BAR_PLUGIN,\n name: 'Status Bar',\n description: 'Display a bar with status and actions.',\n icon: 'ph--info--regular',\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React from 'react';\n\nimport {\n Capabilities,\n contributes,\n createSurface,\n defineModule,\n definePlugin,\n Events,\n Surface,\n} from '@dxos/app-framework';\n\nimport { StatusBarActions, StatusBarPanel } from './components';\nimport { VersionNumber } from './components/VersionNumber';\nimport { meta, STATUS_BAR_PLUGIN } from './meta';\nimport translations from './translations';\n\nexport const StatusBarPlugin = () =>\n definePlugin(meta, [\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/react-surface`,\n activatesOn: Events.SetupReactSurface,\n activate: () =>\n contributes(Capabilities.ReactSurface, [\n createSurface({\n id: meta.id,\n role: 'status-bar',\n component: () => <StatusBarPanel />,\n }),\n createSurface({\n id: meta.id,\n role: 'status-bar--r0-footer',\n component: () => <Surface role='status' />,\n }),\n createSurface({\n id: meta.id,\n role: 'status-bar--r1-footer',\n component: () => <StatusBarActions />,\n }),\n createSurface({\n id: `${STATUS_BAR_PLUGIN}/header-end`,\n role: 'header-end',\n component: () => <VersionNumber />,\n }),\n ]),\n }),\n ]);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type useTranslation } from '@dxos/react-ui';\n\nimport { STATUS_BAR_PLUGIN } from './meta';\n\n// TODO(wittjosiah): There's got to be a better way to do typesafe translations, this is too much boilerplate.\n\ntype StatusBarTranslationKeys =\n | 'plugin name'\n | 'warning title'\n | 'technology preview message'\n | 'learn more label'\n | 'released message'\n | 'see release label'\n | 'powered by dxos message'\n | 'discord label'\n | 'github label'\n | 'feedback label';\n\ntype RequiredTranslation = { [key in StatusBarTranslationKeys]: string };\ntype TranslationEntry = { [STATUS_BAR_PLUGIN]: RequiredTranslation };\ntype Language = string;\n\n// -- helpers.\nconst entry = (translation: RequiredTranslation): TranslationEntry => ({ [STATUS_BAR_PLUGIN]: translation });\nexport const mkTranslation = (t: ReturnType<typeof useTranslation>['t']) => (key: StatusBarTranslationKeys) => t(key);\n\nconst translations: Record<Language, TranslationEntry> = {\n 'en-US': entry({\n 'plugin name': 'Status Bar',\n 'warning title': 'WARNING',\n 'technology preview message': 'Composer is currently in beta.',\n 'learn more label': 'Learn more',\n 'released message': 'This version released {{released}}.',\n 'see release label': 'See release on GitHub',\n 'powered by dxos message': 'Powered by <dxos>DXOS</dxos>',\n 'discord label': 'Discord',\n 'github label': 'GitHub',\n 'feedback label': 'Feedback',\n }),\n};\n\nexport default [translations];\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,wBAAqB;AACrB,mBAAsG;AAGtG,4BAAmB;ACJnB,IAAAA,gBAAgC;AAEhC,2BAAwB;AACxB,sBAA8C;ACH9C,4BAA+B;AAC/B,IAAAA,gBAAkB;AAElB,0BAA0B;AAC1B,IAAAC,mBAAoE;AEJpE,IAAAD,gBAAkB;AAElB,IAAAE,wBAQO;AJFP,IAAMC,gBAAgBC,6CAAgD,CAAC,EAAEC,YAAYC,SAAQ,GAAIC,iBAC/F,6BAAAC,QAAA,cAACC,QAAAA;EAAKC,eAAWC,0BAAGN,UAAAA;EAAaO,KAAKL;GACnCD,QAAAA,CAAAA;AAML,IAAMO,kBAAkBT,6CACtB,CAAC,EAAEC,YAAYC,UAAUQ,SAAS,GAAGC,MAAAA,GAASR,iBAAAA;AAC5C,QAAMS,cAAUL,0BACd,8DACA,qEACA,kGACAN,UAAAA;AAGF,SAAOS,UACL,6BAAAN,QAAA,cAACS,wBAAAA;IAAKC,MAAK;IAASN,KAAKL;IAAcG,WAAWM;IAAU,GAAGD;KAC5DT,QAAAA,IAGH,6BAAAE,QAAA,cAACW,UAAAA;IAAOT,WAAWM;IAASJ,KAAKL;IAAe,GAAGQ;KAChDT,QAAAA;AAGP,CAAA;AAOF,IAAMc,gBAAgBhB,6CACpB,CAAC,EAAEC,YAAYC,UAAU,GAAGS,MAAAA,GAASR,iBACnC,6BAAAC,QAAA,cAACa,OAAAA;EACCH,MAAK;EACLR,eAAWC,0BAAG,0EAA0EN,UAAAA;EACxFO,KAAKL;EACJ,GAAGQ;GAEHT,QAAAA,CAAAA;AAOP,IAAMgB,eAAel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AW,MAAMrG,8BAAAA,QAAA,cAAC4B,eAAAA,IAAAA;MACpB,CAAA;KACD;EACL,CAAA;CACD;",
6
+ "names": ["import_react", "import_react_ui", "import_app_framework", "StatusBarText", "forwardRef", "classNames", "children", "forwardedRef", "React", "span", "className", "mx", "ref", "StatusBarButton", "asChild", "props", "classes", "Slot", "role", "button", "StatusBarItem", "div", "StartContent", "EndContent", "StatusBar", "Text", "Item", "Button", "STATUS_BAR_PLUGIN", "meta", "id", "name", "description", "icon", "repo", "VERSION_REGEX", "VersionNumber", "config", "useConfig", "t", "useTranslation", "version", "timestamp", "commitHash", "values", "runtime", "app", "build", "_", "v", "match", "isLabs", "env", "DX_LABS", "releaseUrl", "DX_ENVIRONMENT", "previewUrl", "Popover", "Root", "Trigger", "Portal", "Content", "side", "Message", "valence", "Title", "Icon", "size", "Body", "br", "Link", "href", "target", "rel", "variant", "p", "released", "formatDistance", "Date", "addSuffix", "Trans", "i18nKey", "components", "dxos", "Arrow", "StatusBarActions", "open", "setOpen", "useState", "onOpenChange", "a", "StatusBarPanel", "Surface", "entry", "translation", "translations", "StatusBarPlugin", "definePlugin", "defineModule", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "SetupReactSurface", "ReactSurface", "createSurface", "component"]
7
7
  }
@@ -1 +1 @@
1
- {"inputs":{"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx":{"bytes":7783,"imports":[{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-status-bar/src/meta.ts":{"bytes":1289,"imports":[],"format":"esm"},"packages/plugins/plugin-status-bar/src/translations.ts":{"bytes":4726,"imports":[{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/FeedbackForm.tsx":{"bytes":13476,"imports":[{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-observability/types","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-form","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"../meta"},{"path":"packages/plugins/plugin-status-bar/src/translations.ts","kind":"import-statement","original":"../translations"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx":{"bytes":11172,"imports":[{"path":"date-fns/formatDistance","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx","kind":"import-statement","original":"./StatusBar"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/StatusBarPanel.tsx":{"bytes":6757,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/components/FeedbackForm.tsx","kind":"import-statement","original":"./FeedbackForm"},{"path":"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx","kind":"import-statement","original":"./StatusBar"},{"path":"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx","kind":"import-statement","original":"./VersionNumber"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/index.ts":{"bytes":624,"imports":[{"path":"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx","kind":"import-statement","original":"./StatusBar"},{"path":"packages/plugins/plugin-status-bar/src/components/StatusBarPanel.tsx","kind":"import-statement","original":"./StatusBarPanel"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/StatusBarPlugin.tsx":{"bytes":6167,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx","kind":"import-statement","original":"./components/VersionNumber"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-status-bar/src/translations.ts","kind":"import-statement","original":"./translations"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/index.ts":{"bytes":699,"imports":[{"path":"packages/plugins/plugin-status-bar/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-status-bar/src/StatusBarPlugin.tsx","kind":"import-statement","original":"./StatusBarPlugin"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-status-bar/dist/lib/node/index.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":26553},"packages/plugins/plugin-status-bar/dist/lib/node/index.cjs":{"imports":[{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@phosphor-icons/react","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-observability/types","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"@dxos/react-ui-form","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"date-fns/formatDistance","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["STATUS_BAR_PLUGIN","StatusBar","StatusBarActions","StatusBarPanel","StatusBarPlugin","meta"],"entryPoint":"packages/plugins/plugin-status-bar/src/index.ts","inputs":{"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx":{"bytesInOutput":1948},"packages/plugins/plugin-status-bar/src/components/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-status-bar/src/components/StatusBarPanel.tsx":{"bytesInOutput":1972},"packages/plugins/plugin-status-bar/src/components/FeedbackForm.tsx":{"bytesInOutput":3972},"packages/plugins/plugin-status-bar/src/meta.ts":{"bytesInOutput":202},"packages/plugins/plugin-status-bar/src/translations.ts":{"bytesInOutput":947},"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx":{"bytesInOutput":3247},"packages/plugins/plugin-status-bar/src/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-status-bar/src/StatusBarPlugin.tsx":{"bytesInOutput":1317}},"bytes":14350}}}
1
+ {"inputs":{"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx":{"bytes":7783,"imports":[{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true}],"format":"esm"},"packages/plugins/plugin-status-bar/src/meta.ts":{"bytes":1277,"imports":[],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx":{"bytes":11172,"imports":[{"path":"date-fns/formatDistance","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx","kind":"import-statement","original":"./StatusBar"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/StatusBarPanel.tsx":{"bytes":5831,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx","kind":"import-statement","original":"./StatusBar"},{"path":"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx","kind":"import-statement","original":"./VersionNumber"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/components/index.ts":{"bytes":624,"imports":[{"path":"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx","kind":"import-statement","original":"./StatusBar"},{"path":"packages/plugins/plugin-status-bar/src/components/StatusBarPanel.tsx","kind":"import-statement","original":"./StatusBarPanel"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/translations.ts":{"bytes":3815,"imports":[{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/StatusBarPlugin.tsx":{"bytes":6167,"imports":[{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"packages/plugins/plugin-status-bar/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx","kind":"import-statement","original":"./components/VersionNumber"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-status-bar/src/translations.ts","kind":"import-statement","original":"./translations"}],"format":"esm"},"packages/plugins/plugin-status-bar/src/index.ts":{"bytes":699,"imports":[{"path":"packages/plugins/plugin-status-bar/src/components/index.ts","kind":"import-statement","original":"./components"},{"path":"packages/plugins/plugin-status-bar/src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"packages/plugins/plugin-status-bar/src/StatusBarPlugin.tsx","kind":"import-statement","original":"./StatusBarPlugin"}],"format":"esm"}},"outputs":{"packages/plugins/plugin-status-bar/dist/lib/node/index.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":18333},"packages/plugins/plugin-status-bar/dist/lib/node/index.cjs":{"imports":[{"path":"@radix-ui/react-slot","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-ui-theme","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"date-fns/formatDistance","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/react-client","kind":"import-statement","external":true},{"path":"@dxos/react-ui","kind":"import-statement","external":true},{"path":"react","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["STATUS_BAR_PLUGIN","StatusBar","StatusBarActions","StatusBarPanel","StatusBarPlugin","meta"],"entryPoint":"packages/plugins/plugin-status-bar/src/index.ts","inputs":{"packages/plugins/plugin-status-bar/src/components/StatusBar.tsx":{"bytesInOutput":1948},"packages/plugins/plugin-status-bar/src/components/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-status-bar/src/components/StatusBarPanel.tsx":{"bytesInOutput":1703},"packages/plugins/plugin-status-bar/src/components/VersionNumber.tsx":{"bytesInOutput":3210},"packages/plugins/plugin-status-bar/src/meta.ts":{"bytesInOutput":202},"packages/plugins/plugin-status-bar/src/index.ts":{"bytesInOutput":0},"packages/plugins/plugin-status-bar/src/StatusBarPlugin.tsx":{"bytesInOutput":1317},"packages/plugins/plugin-status-bar/src/translations.ts":{"bytesInOutput":608}},"bytes":9726}}}