@dxos/plugin-help 0.8.2-staging.7ac8446 → 0.8.3-main.672df60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/browser/{app-graph-builder-K5UJXROL.mjs → app-graph-builder-2TXP7S56.mjs} +12 -11
- package/dist/lib/browser/app-graph-builder-2TXP7S56.mjs.map +7 -0
- package/dist/lib/browser/{chunk-EMRPD2QX.mjs → chunk-ACLT6V7I.mjs} +2 -2
- package/dist/lib/browser/{chunk-EMRPD2QX.mjs.map → chunk-ACLT6V7I.mjs.map} +1 -1
- package/dist/lib/browser/{chunk-AIK64B2S.mjs → chunk-BZUIJQPN.mjs} +6 -6
- package/dist/lib/browser/chunk-BZUIJQPN.mjs.map +7 -0
- package/dist/lib/browser/chunk-JNDWLTUJ.mjs +408 -0
- package/dist/lib/browser/chunk-JNDWLTUJ.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +8 -8
- package/dist/lib/browser/index.mjs.map +3 -3
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/{react-root-L377AIYI.mjs → react-root-PRXEQ5QF.mjs} +4 -4
- package/dist/lib/browser/{react-surface-IKAPWUA2.mjs → react-surface-IDR3XY36.mjs} +3 -3
- package/dist/lib/browser/{state-K6TSL77G.mjs → state-UOKD6P5V.mjs} +2 -2
- package/dist/lib/browser/types.mjs +1 -1
- package/dist/types/src/HelpPlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder.d.ts +2 -179
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
- package/dist/types/src/capabilities/index.d.ts +2 -178
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-root.d.ts.map +1 -1
- package/dist/types/src/capabilities/state.d.ts +1 -1
- package/dist/types/src/components/Shortcuts/Key.d.ts.map +1 -1
- package/dist/types/src/components/Shortcuts/ShortcutsHints.d.ts.map +1 -1
- package/dist/types/src/components/WelcomeTour/WelcomeTour.d.ts.map +1 -1
- package/dist/types/src/types.d.ts +7 -7
- package/dist/types/src/types.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +26 -20
- package/src/HelpPlugin.tsx +1 -1
- package/src/capabilities/app-graph-builder.ts +59 -49
- package/src/components/Shortcuts/ShortcutsDialog.tsx +1 -1
- package/src/components/Shortcuts/ShortcutsList.tsx +1 -1
- package/src/components/Tooltip/Tooltip.tsx +2 -2
- package/src/types.ts +6 -6
- package/dist/lib/browser/app-graph-builder-K5UJXROL.mjs.map +0 -7
- package/dist/lib/browser/chunk-AIK64B2S.mjs.map +0 -7
- package/dist/lib/browser/chunk-J6SNIC5D.mjs +0 -361
- package/dist/lib/browser/chunk-J6SNIC5D.mjs.map +0 -7
- /package/dist/lib/browser/{react-root-L377AIYI.mjs.map → react-root-PRXEQ5QF.mjs.map} +0 -0
- /package/dist/lib/browser/{react-surface-IKAPWUA2.mjs.map → react-surface-IDR3XY36.mjs.map} +0 -0
- /package/dist/lib/browser/{state-K6TSL77G.mjs.map → state-UOKD6P5V.mjs.map} +0 -0
|
@@ -1,361 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
HelpContext
|
|
3
|
-
} from "./chunk-AIK64B2S.mjs";
|
|
4
|
-
import {
|
|
5
|
-
HELP_PLUGIN
|
|
6
|
-
} from "./chunk-4KTRSNO5.mjs";
|
|
7
|
-
|
|
8
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/Key.tsx
|
|
9
|
-
import React from "react";
|
|
10
|
-
import { keySymbols } from "@dxos/keyboard";
|
|
11
|
-
|
|
12
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/styles.ts
|
|
13
|
-
import { mx } from "@dxos/react-ui-theme";
|
|
14
|
-
var shortcutKey = mx("inline-flex min-is-[24px] bs-[24px] pli-0.5 justify-center items-center text-xs", "rounded bg-neutral-100 dark:bg-neutral-900");
|
|
15
|
-
|
|
16
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/Key.tsx
|
|
17
|
-
var Key = ({ binding }) => {
|
|
18
|
-
return /* @__PURE__ */ React.createElement("span", {
|
|
19
|
-
role: "term",
|
|
20
|
-
className: "inline-flex gap-1",
|
|
21
|
-
"aria-label": binding,
|
|
22
|
-
id: binding
|
|
23
|
-
}, keySymbols(binding).map((c, i) => /* @__PURE__ */ React.createElement("span", {
|
|
24
|
-
key: i,
|
|
25
|
-
className: shortcutKey
|
|
26
|
-
}, c)));
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/ShortcutsList.tsx
|
|
30
|
-
import React2, { Fragment } from "react";
|
|
31
|
-
import { Keyboard } from "@dxos/keyboard";
|
|
32
|
-
import { toLocalizedString, useTranslation } from "@dxos/react-ui";
|
|
33
|
-
import { mx as mx2 } from "@dxos/react-ui-theme";
|
|
34
|
-
var ShortcutsList = () => {
|
|
35
|
-
const { t } = useTranslation(HELP_PLUGIN);
|
|
36
|
-
const bindings = Keyboard.singleton.getBindings();
|
|
37
|
-
bindings.sort((a, b) => {
|
|
38
|
-
return toLocalizedString(a.data, t)?.toLowerCase().localeCompare(toLocalizedString(b.data, t)?.toLowerCase());
|
|
39
|
-
});
|
|
40
|
-
return /* @__PURE__ */ React2.createElement("dl", {
|
|
41
|
-
className: mx2("is-fit grid grid-cols-[min-content_minmax(12rem,1fr)] gap-2 mlb-4 text-subdued")
|
|
42
|
-
}, bindings.map((binding, i) => /* @__PURE__ */ React2.createElement(Fragment, {
|
|
43
|
-
key: i
|
|
44
|
-
}, /* @__PURE__ */ React2.createElement(Key, {
|
|
45
|
-
binding: binding.shortcut
|
|
46
|
-
}), /* @__PURE__ */ React2.createElement("span", {
|
|
47
|
-
role: "definition",
|
|
48
|
-
className: "mis-4",
|
|
49
|
-
"aria-labelledby": binding.shortcut
|
|
50
|
-
}, toLocalizedString(binding.data, t)))));
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/ShortcutsDialog.tsx
|
|
54
|
-
import React3 from "react";
|
|
55
|
-
import { Button, Dialog, Icon, useTranslation as useTranslation2 } from "@dxos/react-ui";
|
|
56
|
-
var SHORTCUTS_DIALOG = `${HELP_PLUGIN}/ShortcutsDialog`;
|
|
57
|
-
var ShortcutsDialogContent = () => {
|
|
58
|
-
const { t } = useTranslation2(HELP_PLUGIN);
|
|
59
|
-
return /* @__PURE__ */ React3.createElement(Dialog.Content, {
|
|
60
|
-
classNames: "p-0 bs-content max-bs-full md:max-is-[25rem] overflow-hidden"
|
|
61
|
-
}, /* @__PURE__ */ React3.createElement("div", {
|
|
62
|
-
role: "none",
|
|
63
|
-
className: "flex justify-between mbe-1 pbs-3 pis-2 pie-3 @md:pbs-4 @md:pis-4 @md:pie-5"
|
|
64
|
-
}, /* @__PURE__ */ React3.createElement(Dialog.Title, null, t("shortcuts dialog title")), /* @__PURE__ */ React3.createElement(Dialog.Close, {
|
|
65
|
-
asChild: true
|
|
66
|
-
}, /* @__PURE__ */ React3.createElement(Button, {
|
|
67
|
-
density: "fine",
|
|
68
|
-
variant: "ghost",
|
|
69
|
-
autoFocus: true
|
|
70
|
-
}, /* @__PURE__ */ React3.createElement(Icon, {
|
|
71
|
-
icon: "ph--x--regular",
|
|
72
|
-
size: 3
|
|
73
|
-
})))), /* @__PURE__ */ React3.createElement("div", {
|
|
74
|
-
className: "flex items-center justify-center"
|
|
75
|
-
}, /* @__PURE__ */ React3.createElement(ShortcutsList, null)));
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/ShortcutsHints.tsx
|
|
79
|
-
import React4 from "react";
|
|
80
|
-
import { Keyboard as Keyboard2 } from "@dxos/keyboard";
|
|
81
|
-
import { Button as Button2, Icon as Icon2, toLocalizedString as toLocalizedString2, useTranslation as useTranslation3 } from "@dxos/react-ui";
|
|
82
|
-
var Shortcut = ({ binding }) => {
|
|
83
|
-
const { t } = useTranslation3("os");
|
|
84
|
-
return /* @__PURE__ */ React4.createElement("div", {
|
|
85
|
-
role: "none",
|
|
86
|
-
className: "flex items-center gap-2 whitespace-nowrap"
|
|
87
|
-
}, /* @__PURE__ */ React4.createElement(Key, {
|
|
88
|
-
binding: binding.shortcut
|
|
89
|
-
}), /* @__PURE__ */ React4.createElement("span", {
|
|
90
|
-
className: "text-sm"
|
|
91
|
-
}, toLocalizedString2(binding.data, t)));
|
|
92
|
-
};
|
|
93
|
-
var ShortcutsHints = ({ onClose }) => {
|
|
94
|
-
const defaults = [
|
|
95
|
-
"meta+k",
|
|
96
|
-
"meta+/",
|
|
97
|
-
"meta+,"
|
|
98
|
-
];
|
|
99
|
-
const bindings = Keyboard2.singleton.getBindings();
|
|
100
|
-
const hints = bindings.filter((binding) => defaults.includes(binding.shortcut));
|
|
101
|
-
return /* @__PURE__ */ React4.createElement("div", {
|
|
102
|
-
role: "none",
|
|
103
|
-
className: "flex overflow-hidden px-2 gap-4"
|
|
104
|
-
}, hints.map((binding) => /* @__PURE__ */ React4.createElement(Shortcut, {
|
|
105
|
-
key: binding.shortcut,
|
|
106
|
-
binding
|
|
107
|
-
})), onClose && /* @__PURE__ */ React4.createElement(Button2, {
|
|
108
|
-
variant: "ghost",
|
|
109
|
-
classNames: "p-0 cursor-pointer",
|
|
110
|
-
onClick: onClose
|
|
111
|
-
}, /* @__PURE__ */ React4.createElement(Icon2, {
|
|
112
|
-
icon: "ph--x--regular",
|
|
113
|
-
size: 4
|
|
114
|
-
})));
|
|
115
|
-
};
|
|
116
|
-
|
|
117
|
-
// packages/plugins/plugin-help/src/components/Shortcuts/ShortcutsSection.tsx
|
|
118
|
-
import React5 from "react";
|
|
119
|
-
import { descriptionText } from "@dxos/react-ui-theme";
|
|
120
|
-
var ShortcutsSection = () => {
|
|
121
|
-
return /* @__PURE__ */ React5.createElement("section", {
|
|
122
|
-
className: descriptionText
|
|
123
|
-
}, /* @__PURE__ */ React5.createElement(ShortcutsList, null));
|
|
124
|
-
};
|
|
125
|
-
|
|
126
|
-
// packages/plugins/plugin-help/src/components/Tooltip/Tooltip.tsx
|
|
127
|
-
import { useArrowNavigationGroup, useFocusableGroup } from "@fluentui/react-tabster";
|
|
128
|
-
import { CaretLeft, CaretRight, Circle, X } from "@phosphor-icons/react";
|
|
129
|
-
import React6, { forwardRef } from "react";
|
|
130
|
-
import { Button as Button3 } from "@dxos/react-ui";
|
|
131
|
-
import { getSize, mx as mx3 } from "@dxos/react-ui-theme";
|
|
132
|
-
var floaterProps = {
|
|
133
|
-
styles: {
|
|
134
|
-
// Arrow color is set by joyride.
|
|
135
|
-
arrow: {
|
|
136
|
-
length: 8,
|
|
137
|
-
spread: 16
|
|
138
|
-
},
|
|
139
|
-
floater: {
|
|
140
|
-
// TODO(burdon): Get tokens from theme.
|
|
141
|
-
filter: "drop-shadow(0 0 0.75rem rgba(0, 0, 0, 0.2))"
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
|
-
};
|
|
145
|
-
var Tooltip = /* @__PURE__ */ forwardRef(({ step: { title, content }, index, size, isLastStep, backProps, closeProps, primaryProps }, forwardedRef) => {
|
|
146
|
-
const arrowNavigationAttrs = useArrowNavigationGroup({
|
|
147
|
-
axis: "horizontal"
|
|
148
|
-
});
|
|
149
|
-
const focusableGroupAttrs = useFocusableGroup({
|
|
150
|
-
tabBehavior: "limited-trap-focus"
|
|
151
|
-
});
|
|
152
|
-
return /* @__PURE__ */ React6.createElement("div", {
|
|
153
|
-
className: "flex flex-col is-[15rem] min-bs-[10rem] overflow-hidden rounded-md shadow-xl bg-accentSurface text-inverse",
|
|
154
|
-
role: "tooltip",
|
|
155
|
-
"data-testid": "helpPlugin.tooltip",
|
|
156
|
-
"data-step": index + 1,
|
|
157
|
-
...focusableGroupAttrs,
|
|
158
|
-
ref: forwardedRef
|
|
159
|
-
}, /* @__PURE__ */ React6.createElement("div", {
|
|
160
|
-
className: "flex p-2"
|
|
161
|
-
}, /* @__PURE__ */ React6.createElement("h2", {
|
|
162
|
-
className: "grow pli-2 plb-1 text-lg font-medium text-inverse"
|
|
163
|
-
}, title), /* @__PURE__ */ React6.createElement(Button3, {
|
|
164
|
-
density: "fine",
|
|
165
|
-
variant: "primary",
|
|
166
|
-
onClick: closeProps.onClick,
|
|
167
|
-
title: closeProps["aria-label"],
|
|
168
|
-
"data-testid": "helpPlugin.tooltip.close"
|
|
169
|
-
}, /* @__PURE__ */ React6.createElement(X, {
|
|
170
|
-
weight: "bold",
|
|
171
|
-
className: getSize(4)
|
|
172
|
-
}))), /* @__PURE__ */ React6.createElement("div", {
|
|
173
|
-
className: "flex grow pli-4 mlb-2"
|
|
174
|
-
}, content), /* @__PURE__ */ React6.createElement("div", {
|
|
175
|
-
className: "flex p-2 items-center justify-between",
|
|
176
|
-
...arrowNavigationAttrs
|
|
177
|
-
}, /* @__PURE__ */ React6.createElement(Button3, {
|
|
178
|
-
variant: "primary",
|
|
179
|
-
onClick: backProps.onClick,
|
|
180
|
-
title: backProps["aria-label"],
|
|
181
|
-
classNames: [
|
|
182
|
-
!(index > 0 && backProps) && "invisible"
|
|
183
|
-
],
|
|
184
|
-
"data-testid": "helpPlugin.tooltip.back"
|
|
185
|
-
}, /* @__PURE__ */ React6.createElement(CaretLeft, {
|
|
186
|
-
className: getSize(5)
|
|
187
|
-
})), /* @__PURE__ */ React6.createElement("div", {
|
|
188
|
-
className: "flex grow gap-2 justify-center"
|
|
189
|
-
}, /* @__PURE__ */ React6.createElement("div", {
|
|
190
|
-
className: "flex"
|
|
191
|
-
}, Array.from({
|
|
192
|
-
length: size
|
|
193
|
-
}).map((_, i) => /* @__PURE__ */ React6.createElement(Circle, {
|
|
194
|
-
key: i,
|
|
195
|
-
weight: index === i ? "fill" : "regular",
|
|
196
|
-
className: mx3(getSize(2), "mli-1 cursor-pointer")
|
|
197
|
-
})))), isLastStep ? /* @__PURE__ */ React6.createElement(Button3, {
|
|
198
|
-
variant: "primary",
|
|
199
|
-
onClick: closeProps.onClick,
|
|
200
|
-
title: closeProps["aria-label"],
|
|
201
|
-
autoFocus: true,
|
|
202
|
-
"data-testid": "helpPlugin.tooltip.finish"
|
|
203
|
-
}, "Done") : /* @__PURE__ */ React6.createElement(Button3, {
|
|
204
|
-
variant: "primary",
|
|
205
|
-
onClick: primaryProps.onClick,
|
|
206
|
-
title: primaryProps["aria-label"],
|
|
207
|
-
autoFocus: true,
|
|
208
|
-
"data-testid": "helpPlugin.tooltip.next"
|
|
209
|
-
}, /* @__PURE__ */ React6.createElement(CaretRight, {
|
|
210
|
-
className: getSize(6)
|
|
211
|
-
}))));
|
|
212
|
-
});
|
|
213
|
-
|
|
214
|
-
// packages/plugins/plugin-help/src/components/WelcomeTour/WelcomeTour.tsx
|
|
215
|
-
import React7, { useState, useEffect } from "react";
|
|
216
|
-
import Joyride, { ACTIONS, EVENTS } from "react-joyride";
|
|
217
|
-
import { usePluginManager, useLayout } from "@dxos/app-framework";
|
|
218
|
-
var addStepClass = (target) => {
|
|
219
|
-
const element = typeof target === "string" ? document.querySelector(target) : target;
|
|
220
|
-
if (element) {
|
|
221
|
-
element.classList.add("joyride-target");
|
|
222
|
-
}
|
|
223
|
-
};
|
|
224
|
-
var removeTargetClass = (target) => {
|
|
225
|
-
const element = typeof target === "string" ? document.querySelector(target) : target;
|
|
226
|
-
if (element) {
|
|
227
|
-
element.classList.remove("joyride-target");
|
|
228
|
-
}
|
|
229
|
-
};
|
|
230
|
-
var getTarget = (step) => {
|
|
231
|
-
return typeof step.target === "string" ? document.querySelector(step.target) : step.target;
|
|
232
|
-
};
|
|
233
|
-
var waitForTarget = async (step) => {
|
|
234
|
-
if (typeof step.target === "string") {
|
|
235
|
-
const target = step.target;
|
|
236
|
-
const element = document.querySelector(target);
|
|
237
|
-
if (element) {
|
|
238
|
-
return;
|
|
239
|
-
}
|
|
240
|
-
await new Promise((resolve) => {
|
|
241
|
-
const observer = new MutationObserver((mutations) => {
|
|
242
|
-
mutations.forEach((mutation) => {
|
|
243
|
-
if (mutation.addedNodes.length > 0) {
|
|
244
|
-
const element2 = document.querySelector(target);
|
|
245
|
-
if (element2) {
|
|
246
|
-
observer.disconnect();
|
|
247
|
-
resolve();
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
});
|
|
251
|
-
});
|
|
252
|
-
observer.observe(document.body, {
|
|
253
|
-
childList: true,
|
|
254
|
-
subtree: true
|
|
255
|
-
});
|
|
256
|
-
});
|
|
257
|
-
}
|
|
258
|
-
};
|
|
259
|
-
var WelcomeTour = ({ steps: initialSteps, running: runningProp, onRunningChanged }) => {
|
|
260
|
-
const manager = usePluginManager();
|
|
261
|
-
const layout = useLayout();
|
|
262
|
-
const [running, setRunning] = useState(!!runningProp && !!getTarget(initialSteps[0]));
|
|
263
|
-
const [stepIndex, _setStepIndex] = useState(0);
|
|
264
|
-
const [steps, setSteps] = useState(initialSteps);
|
|
265
|
-
const paused = layout.dialogOpen;
|
|
266
|
-
const setStepIndex = (index) => {
|
|
267
|
-
if (runningProp) {
|
|
268
|
-
const step = steps[index];
|
|
269
|
-
step?.before?.(manager.context);
|
|
270
|
-
}
|
|
271
|
-
_setStepIndex(index);
|
|
272
|
-
};
|
|
273
|
-
const setRunningChanged = (state) => {
|
|
274
|
-
if (typeof runningProp !== "undefined") {
|
|
275
|
-
onRunningChanged?.(state);
|
|
276
|
-
} else {
|
|
277
|
-
if (state) {
|
|
278
|
-
setStepIndex(0);
|
|
279
|
-
setRunning(true);
|
|
280
|
-
} else {
|
|
281
|
-
setRunning(false);
|
|
282
|
-
}
|
|
283
|
-
}
|
|
284
|
-
};
|
|
285
|
-
useEffect(() => {
|
|
286
|
-
const timeout = setTimeout(async () => {
|
|
287
|
-
if (runningProp) {
|
|
288
|
-
await waitForTarget(steps[stepIndex]);
|
|
289
|
-
setStepIndex(0);
|
|
290
|
-
setRunning(true);
|
|
291
|
-
} else if (typeof runningProp !== "undefined") {
|
|
292
|
-
setRunning(false);
|
|
293
|
-
}
|
|
294
|
-
});
|
|
295
|
-
return () => clearTimeout(timeout);
|
|
296
|
-
}, [
|
|
297
|
-
runningProp
|
|
298
|
-
]);
|
|
299
|
-
const callback = async (options) => {
|
|
300
|
-
const { type, action, index, size } = options;
|
|
301
|
-
switch (type) {
|
|
302
|
-
case EVENTS.STEP_BEFORE:
|
|
303
|
-
addStepClass(options.step.target);
|
|
304
|
-
break;
|
|
305
|
-
case EVENTS.TOUR_END:
|
|
306
|
-
break;
|
|
307
|
-
case EVENTS.STEP_AFTER:
|
|
308
|
-
removeTargetClass(options.step.target);
|
|
309
|
-
switch (action) {
|
|
310
|
-
case ACTIONS.NEXT:
|
|
311
|
-
if (index < size - 1) {
|
|
312
|
-
setStepIndex(index + 1);
|
|
313
|
-
}
|
|
314
|
-
break;
|
|
315
|
-
case ACTIONS.PREV:
|
|
316
|
-
if (index > 0) {
|
|
317
|
-
setStepIndex(index - 1);
|
|
318
|
-
}
|
|
319
|
-
break;
|
|
320
|
-
case ACTIONS.CLOSE:
|
|
321
|
-
setRunningChanged(false);
|
|
322
|
-
setStepIndex(0);
|
|
323
|
-
break;
|
|
324
|
-
}
|
|
325
|
-
break;
|
|
326
|
-
}
|
|
327
|
-
};
|
|
328
|
-
return /* @__PURE__ */ React7.createElement(HelpContext.Provider, {
|
|
329
|
-
value: {
|
|
330
|
-
running: running && !paused,
|
|
331
|
-
steps,
|
|
332
|
-
setSteps,
|
|
333
|
-
setIndex: setStepIndex,
|
|
334
|
-
start: () => setRunningChanged(true),
|
|
335
|
-
stop: () => setRunningChanged(false)
|
|
336
|
-
}
|
|
337
|
-
}, /* @__PURE__ */ React7.createElement("style", null, `.joyride-target {
|
|
338
|
-
--controls-opacity: 1;
|
|
339
|
-
}`), /* @__PURE__ */ React7.createElement(Joyride, {
|
|
340
|
-
continuous: true,
|
|
341
|
-
steps,
|
|
342
|
-
stepIndex,
|
|
343
|
-
run: running && !paused,
|
|
344
|
-
callback,
|
|
345
|
-
floaterProps,
|
|
346
|
-
tooltipComponent: Tooltip
|
|
347
|
-
}));
|
|
348
|
-
};
|
|
349
|
-
|
|
350
|
-
export {
|
|
351
|
-
Key,
|
|
352
|
-
ShortcutsList,
|
|
353
|
-
SHORTCUTS_DIALOG,
|
|
354
|
-
ShortcutsDialogContent,
|
|
355
|
-
ShortcutsHints,
|
|
356
|
-
ShortcutsSection,
|
|
357
|
-
floaterProps,
|
|
358
|
-
Tooltip,
|
|
359
|
-
WelcomeTour
|
|
360
|
-
};
|
|
361
|
-
//# sourceMappingURL=chunk-J6SNIC5D.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../src/components/Shortcuts/Key.tsx", "../../../src/components/Shortcuts/styles.ts", "../../../src/components/Shortcuts/ShortcutsList.tsx", "../../../src/components/Shortcuts/ShortcutsDialog.tsx", "../../../src/components/Shortcuts/ShortcutsHints.tsx", "../../../src/components/Shortcuts/ShortcutsSection.tsx", "../../../src/components/Tooltip/Tooltip.tsx", "../../../src/components/WelcomeTour/WelcomeTour.tsx"],
|
|
4
|
-
"sourcesContent": ["//\n// Copyright 2024 DXOS.org\n//\n\nimport React from 'react';\n\nimport { keySymbols } from '@dxos/keyboard';\n\nimport { shortcutKey } from './styles';\n\nexport const Key = ({ binding }: { binding: string }) => {\n return (\n <span role='term' className='inline-flex gap-1' aria-label={binding} id={binding}>\n {keySymbols(binding).map((c, i) => (\n <span key={i} className={shortcutKey}>\n {c}\n </span>\n ))}\n </span>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { mx } from '@dxos/react-ui-theme';\n\nexport const shortcutKey = mx(\n 'inline-flex min-is-[24px] bs-[24px] pli-0.5 justify-center items-center text-xs',\n 'rounded bg-neutral-100 dark:bg-neutral-900',\n);\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React, { Fragment } from 'react';\n\nimport { Keyboard } from '@dxos/keyboard';\nimport { toLocalizedString, useTranslation } from '@dxos/react-ui';\nimport { mx } from '@dxos/react-ui-theme';\n\nimport { Key } from './Key';\nimport { HELP_PLUGIN } from '../../meta';\n\nexport const ShortcutsList = () => {\n const { t } = useTranslation(HELP_PLUGIN);\n const bindings = Keyboard.singleton.getBindings();\n\n // TODO(burdon): Get shortcuts from TextEditor.\n bindings.sort((a, b) => {\n return toLocalizedString(a.data, t)?.toLowerCase().localeCompare(toLocalizedString(b.data, t)?.toLowerCase());\n });\n\n return (\n <dl className={mx('is-fit grid grid-cols-[min-content_minmax(12rem,1fr)] gap-2 mlb-4 text-subdued')}>\n {bindings.map((binding, i) => (\n <Fragment key={i}>\n <Key binding={binding.shortcut} />\n <span role='definition' className='mis-4' aria-labelledby={binding.shortcut}>\n {toLocalizedString(binding.data, t)}\n </span>\n </Fragment>\n ))}\n </dl>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { Button, Dialog, Icon, useTranslation } from '@dxos/react-ui';\n\nimport { ShortcutsList } from './ShortcutsList';\nimport { HELP_PLUGIN } from '../../meta';\n\nexport const SHORTCUTS_DIALOG = `${HELP_PLUGIN}/ShortcutsDialog`;\n\nexport const ShortcutsDialogContent = () => {\n const { t } = useTranslation(HELP_PLUGIN);\n\n return (\n <Dialog.Content classNames='p-0 bs-content max-bs-full md:max-is-[25rem] overflow-hidden'>\n <div role='none' className='flex justify-between mbe-1 pbs-3 pis-2 pie-3 @md:pbs-4 @md:pis-4 @md:pie-5'>\n <Dialog.Title>{t('shortcuts dialog title')}</Dialog.Title>\n\n <Dialog.Close asChild>\n <Button density='fine' variant='ghost' autoFocus>\n <Icon icon='ph--x--regular' size={3} />\n </Button>\n </Dialog.Close>\n </div>\n\n <div className='flex items-center justify-center'>\n <ShortcutsList />\n </div>\n </Dialog.Content>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React from 'react';\n\nimport { type KeyBinding, Keyboard } from '@dxos/keyboard';\nimport { Button, Icon, toLocalizedString, useTranslation } from '@dxos/react-ui';\n\nimport { Key } from './Key';\n\nconst Shortcut = ({ binding }: { binding: KeyBinding }) => {\n const { t } = useTranslation('os');\n return (\n <div role='none' className='flex items-center gap-2 whitespace-nowrap'>\n <Key binding={binding.shortcut} />\n <span className='text-sm'>{toLocalizedString(binding.data, t)}</span>\n </div>\n );\n};\n\nexport const ShortcutsHints = ({ onClose }: { onClose?: () => void }) => {\n // TODO(burdon): Display by context/weight/cycle.\n const defaults = ['meta+k', 'meta+/', 'meta+,'];\n const bindings = Keyboard.singleton.getBindings();\n const hints = bindings.filter((binding) => defaults.includes(binding.shortcut));\n\n return (\n <div role='none' className='flex overflow-hidden px-2 gap-4'>\n {hints.map((binding) => (\n <Shortcut key={binding.shortcut} binding={binding} />\n ))}\n {onClose && (\n <Button variant='ghost' classNames='p-0 cursor-pointer' onClick={onClose}>\n <Icon icon='ph--x--regular' size={4} />\n </Button>\n )}\n </div>\n );\n};\n", "//\n// Copyright 2024 DXOS.org\n//\n\nimport React from 'react';\n\nimport { descriptionText } from '@dxos/react-ui-theme';\n\nimport { ShortcutsList } from './ShortcutsList';\n\nexport const ShortcutsSection = () => {\n return (\n <section className={descriptionText}>\n <ShortcutsList />\n </section>\n );\n};\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { useArrowNavigationGroup, useFocusableGroup } from '@fluentui/react-tabster';\nimport { CaretLeft, CaretRight, Circle, X } from '@phosphor-icons/react';\nimport React, { forwardRef } from 'react';\n// TODO(thure): This needed to be imported in the package.json specifically to pacify TS2742. See if this is resolved with typescript@5.5.x.\n// eslint-disable-next-line unused-imports/no-unused-imports\nimport _floater from 'react-floater';\nimport { type TooltipRenderProps, type Props } from 'react-joyride';\n// TODO(thure): This needed to be imported in the package.json specifically to pacify TS2742. See if this is resolved with typescript@5.5.x.\n// eslint-disable-next-line unused-imports/no-unused-imports\nimport _typefest from 'type-fest';\n\nimport { Button } from '@dxos/react-ui';\nimport { getSize, mx } from '@dxos/react-ui-theme';\n\n// https://docs.react-joyride.com/styling\n// https://github.com/gilbarbara/react-floater\nexport const floaterProps: Props['floaterProps'] = {\n styles: {\n // Arrow color is set by joyride.\n arrow: {\n length: 8,\n spread: 16,\n },\n floater: {\n // TODO(burdon): Get tokens from theme.\n filter: 'drop-shadow(0 0 0.75rem rgba(0, 0, 0, 0.2))',\n },\n },\n};\n\n// TODO(burdon): Add info link to docs.\nexport const Tooltip = forwardRef<HTMLDivElement, TooltipRenderProps>(\n ({ step: { title, content }, index, size, isLastStep, backProps, closeProps, primaryProps }, forwardedRef) => {\n const arrowNavigationAttrs = useArrowNavigationGroup({ axis: 'horizontal' });\n const focusableGroupAttrs = useFocusableGroup({ tabBehavior: 'limited-trap-focus' });\n\n return (\n <div\n className='flex flex-col is-[15rem] min-bs-[10rem] overflow-hidden rounded-md shadow-xl bg-accentSurface text-inverse'\n role='tooltip'\n data-testid='helpPlugin.tooltip'\n data-step={index + 1}\n {...focusableGroupAttrs}\n ref={forwardedRef}\n >\n <div className='flex p-2'>\n <h2 className='grow pli-2 plb-1 text-lg font-medium text-inverse'>{title}</h2>\n <Button\n density='fine'\n variant='primary'\n onClick={closeProps.onClick}\n title={closeProps['aria-label']}\n data-testid='helpPlugin.tooltip.close'\n >\n <X weight='bold' className={getSize(4)} />\n </Button>\n </div>\n <div className='flex grow pli-4 mlb-2'>{content}</div>\n <div className='flex p-2 items-center justify-between' {...arrowNavigationAttrs}>\n {\n <Button\n variant='primary'\n onClick={backProps.onClick}\n title={backProps['aria-label']}\n classNames={[!(index > 0 && backProps) && 'invisible']}\n data-testid='helpPlugin.tooltip.back'\n >\n <CaretLeft className={getSize(5)} />\n </Button>\n }\n <div className='flex grow gap-2 justify-center'>\n <div className='flex'>\n {Array.from({ length: size }).map((_, i) => (\n <Circle\n key={i}\n weight={index === i ? 'fill' : 'regular'}\n className={mx(getSize(2), 'mli-1 cursor-pointer')}\n />\n ))}\n </div>\n </div>\n {isLastStep ? (\n <Button\n variant='primary'\n onClick={closeProps.onClick}\n title={closeProps['aria-label']}\n autoFocus\n data-testid='helpPlugin.tooltip.finish'\n >\n Done\n </Button>\n ) : (\n <Button\n variant='primary'\n onClick={primaryProps.onClick}\n title={primaryProps['aria-label']}\n autoFocus\n data-testid='helpPlugin.tooltip.next'\n >\n <CaretRight className={getSize(6)} />\n </Button>\n )}\n </div>\n </div>\n );\n },\n);\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport React, { useState, useEffect } from 'react';\nimport Joyride, { ACTIONS, EVENTS } from 'react-joyride';\n\nimport { usePluginManager, useLayout } from '@dxos/app-framework';\n\nimport { type Step, HelpContext } from '../../types';\nimport { floaterProps, Tooltip } from '../Tooltip';\n\nconst addStepClass = (target: string | HTMLElement) => {\n const element = typeof target === 'string' ? document.querySelector(target) : target;\n if (element) {\n element.classList.add('joyride-target');\n }\n};\n\nconst removeTargetClass = (target: string | HTMLElement) => {\n const element = typeof target === 'string' ? document.querySelector(target) : target;\n if (element) {\n element.classList.remove('joyride-target');\n }\n};\n\nconst getTarget = (step: Step) => {\n return typeof step.target === 'string' ? document.querySelector(step.target) : step.target;\n};\n\n/**\n * Wait for the target element to be in the document.\n */\nconst waitForTarget = async (step: Step) => {\n if (typeof step.target === 'string') {\n const target = step.target;\n const element = document.querySelector(target);\n if (element) {\n return;\n }\n\n await new Promise<void>((resolve) => {\n const observer = new MutationObserver((mutations) => {\n mutations.forEach((mutation) => {\n if (mutation.addedNodes.length > 0) {\n const element = document.querySelector(target);\n if (element) {\n observer.disconnect();\n resolve();\n }\n }\n });\n });\n\n observer.observe(document.body, { childList: true, subtree: true });\n });\n }\n};\n\nexport type WelcomeTourProps = {\n steps: Step[];\n running?: boolean;\n onRunningChanged?: (state: boolean) => any;\n};\n\nexport const WelcomeTour = ({ steps: initialSteps, running: runningProp, onRunningChanged }: WelcomeTourProps) => {\n const manager = usePluginManager();\n const layout = useLayout();\n const [running, setRunning] = useState(!!runningProp && !!getTarget(initialSteps[0]));\n const [stepIndex, _setStepIndex] = useState(0);\n const [steps, setSteps] = useState(initialSteps);\n\n const paused = layout.dialogOpen;\n\n const setStepIndex = (index: number) => {\n if (runningProp) {\n const step = steps[index];\n step?.before?.(manager.context);\n }\n _setStepIndex(index);\n };\n\n const setRunningChanged = (state: boolean) => {\n if (typeof runningProp !== 'undefined') {\n onRunningChanged?.(state);\n } else {\n if (state) {\n setStepIndex(0);\n setRunning(true);\n } else {\n setRunning(false);\n }\n }\n };\n\n useEffect(() => {\n const timeout = setTimeout(async () => {\n if (runningProp) {\n // This handles the case when the target is not yet in the document.\n // If the target is not in the document, when the joyride is turned on, it will not show the tooltip.\n await waitForTarget(steps[stepIndex]);\n setStepIndex(0);\n setRunning(true);\n } else if (typeof runningProp !== 'undefined') {\n setRunning(false);\n }\n });\n\n return () => clearTimeout(timeout);\n }, [runningProp]);\n\n // https://docs.react-joyride.com/callback\n const callback: Joyride['callback'] = async (options) => {\n const { type, action, index, size } = options;\n switch (type) {\n case EVENTS.STEP_BEFORE:\n addStepClass(options.step.target);\n break;\n case EVENTS.TOUR_END:\n break;\n case EVENTS.STEP_AFTER:\n removeTargetClass(options.step.target);\n switch (action) {\n case ACTIONS.NEXT:\n if (index < size - 1) {\n setStepIndex(index + 1);\n }\n break;\n case ACTIONS.PREV:\n if (index > 0) {\n setStepIndex(index - 1);\n }\n break;\n case ACTIONS.CLOSE:\n setRunningChanged(false);\n setStepIndex(0);\n break;\n }\n break;\n }\n };\n\n return (\n <HelpContext.Provider\n value={{\n running: running && !paused,\n steps,\n setSteps,\n setIndex: setStepIndex,\n start: () => setRunningChanged(true),\n stop: () => setRunningChanged(false),\n }}\n >\n <style>\n {`.joyride-target {\n --controls-opacity: 1;\n }`}\n </style>\n <Joyride\n continuous={true}\n steps={steps}\n stepIndex={stepIndex}\n run={running && !paused}\n callback={callback}\n floaterProps={floaterProps}\n tooltipComponent={Tooltip}\n />\n </HelpContext.Provider>\n );\n};\n"],
|
|
5
|
-
"mappings": ";;;;;;;;AAIA,OAAOA,WAAW;AAElB,SAASC,kBAAkB;;;ACF3B,SAASC,UAAU;AAEZ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ACA;UACF,KAAKkB,QAAQE;AACX,gBAAIpB,QAAQ,GAAG;AACbD,2BAAaC,QAAQ,CAAA;YACvB;AACA;UACF,KAAKkB,QAAQG;AACXlB,8BAAkB,KAAA;AAClBJ,yBAAa,CAAA;AACb;QACJ;AACA;IACJ;EACF;AAEA,SACE,gBAAAuB,OAAA,cAACC,YAAYC,UAAQ;IACnBC,OAAO;MACLxC,SAASA,WAAW,CAACY;MACrBd;MACAa;MACA8B,UAAU3B;MACV4B,OAAO,MAAMxB,kBAAkB,IAAA;MAC/ByB,MAAM,MAAMzB,kBAAkB,KAAA;IAChC;KAEA,gBAAAmB,OAAA,cAACO,SAAAA,MACE;;UAEC,GAEJ,gBAAAP,OAAA,cAACQ,SAAAA;IACCC,YAAY;IACZhD;IACAW;IACAsC,KAAK/C,WAAW,CAACY;IACjBY;IACAwB;IACAC,kBAAkBC;;AAI1B;",
|
|
6
|
-
"names": ["React", "keySymbols", "mx", "shortcutKey", "mx", "Key", "binding", "span", "role", "className", "aria-label", "id", "keySymbols", "map", "c", "i", "key", "shortcutKey", "React", "Fragment", "Keyboard", "toLocalizedString", "useTranslation", "mx", "ShortcutsList", "t", "useTranslation", "HELP_PLUGIN", "bindings", "Keyboard", "singleton", "getBindings", "sort", "a", "b", "toLocalizedString", "data", "toLowerCase", "localeCompare", "React", "dl", "className", "mx", "map", "binding", "i", "Fragment", "key", "Key", "shortcut", "span", "role", "aria-labelledby", "React", "Button", "Dialog", "Icon", "useTranslation", "SHORTCUTS_DIALOG", "HELP_PLUGIN", "ShortcutsDialogContent", "t", "useTranslation", "React", "Dialog", "Content", "classNames", "div", "role", "className", "Title", "Close", "asChild", "Button", "density", "variant", "autoFocus", "Icon", "icon", "size", "ShortcutsList", "React", "Keyboard", "Button", "Icon", "toLocalizedString", "useTranslation", "Shortcut", "binding", "t", "useTranslation", "React", "div", "role", "className", "Key", "shortcut", "span", "toLocalizedString", "data", "ShortcutsHints", "onClose", "defaults", "bindings", "Keyboard", "singleton", "getBindings", "hints", "filter", "includes", "map", "key", "Button", "variant", "classNames", "onClick", "Icon", "icon", "size", "React", "descriptionText", "ShortcutsSection", "React", "section", "className", "descriptionText", "ShortcutsList", "useArrowNavigationGroup", "useFocusableGroup", "CaretLeft", "CaretRight", "Circle", "X", "React", "forwardRef", "Button", "getSize", "mx", "floaterProps", "styles", "arrow", "length", "spread", "floater", "filter", "Tooltip", "forwardRef", "step", "title", "content", "index", "size", "isLastStep", "backProps", "closeProps", "primaryProps", "forwardedRef", "arrowNavigationAttrs", "useArrowNavigationGroup", "axis", "focusableGroupAttrs", "useFocusableGroup", "tabBehavior", "React", "div", "className", "role", "data-testid", "data-step", "ref", "h2", "Button", "density", "variant", "onClick", "X", "weight", "getSize", "classNames", "CaretLeft", "Array", "from", "map", "_", "i", "Circle", "key", "mx", "autoFocus", "CaretRight", "React", "useState", "useEffect", "Joyride", "ACTIONS", "EVENTS", "usePluginManager", "useLayout", "addStepClass", "target", "element", "document", "querySelector", "classList", "add", "removeTargetClass", "remove", "getTarget", "step", "waitForTarget", "Promise", "resolve", "observer", "MutationObserver", "mutations", "forEach", "mutation", "addedNodes", "length", "disconnect", "observe", "body", "childList", "subtree", "WelcomeTour", "steps", "initialSteps", "running", "runningProp", "onRunningChanged", "manager", "usePluginManager", "layout", "useLayout", "setRunning", "useState", "stepIndex", "_setStepIndex", "setSteps", "paused", "dialogOpen", "setStepIndex", "index", "before", "context", "setRunningChanged", "state", "useEffect", "timeout", "setTimeout", "clearTimeout", "callback", "options", "type", "action", "size", "EVENTS", "STEP_BEFORE", "TOUR_END", "STEP_AFTER", "ACTIONS", "NEXT", "PREV", "CLOSE", "React", "HelpContext", "Provider", "value", "setIndex", "start", "stop", "style", "Joyride", "continuous", "run", "floaterProps", "tooltipComponent", "Tooltip"]
|
|
7
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|