@dxos/react-ui 0.8.3-staging.0fa589b → 0.8.4-main.84f28bd
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/{chunk-WXW6KSRL.mjs → chunk-T6YPS45E.mjs} +68 -68
- package/dist/lib/browser/chunk-T6YPS45E.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +2 -2
- package/dist/lib/browser/index.mjs.map +1 -1
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/testing/index.mjs +4 -4
- package/dist/lib/browser/testing/index.mjs.map +2 -2
- package/dist/lib/node-esm/{chunk-EQ7EG74H.mjs → chunk-TYVQJ4KW.mjs} +68 -68
- package/dist/lib/node-esm/chunk-TYVQJ4KW.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +2 -2
- package/dist/lib/node-esm/index.mjs.map +1 -1
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/testing/index.mjs +4 -4
- package/dist/lib/node-esm/testing/index.mjs.map +2 -2
- package/dist/types/src/components/Buttons/Button.d.ts.map +1 -1
- package/dist/types/src/components/Buttons/Button.stories.d.ts +1 -1
- package/dist/types/src/components/Buttons/Button.stories.d.ts.map +1 -1
- package/dist/types/src/components/Clipboard/CopyButton.d.ts +4 -5
- package/dist/types/src/components/Clipboard/CopyButton.d.ts.map +1 -1
- package/dist/types/src/components/Clipboard/index.d.ts +2 -3
- package/dist/types/src/components/Clipboard/index.d.ts.map +1 -1
- package/dist/types/src/components/Input/Input.stories.d.ts +1 -1
- package/dist/types/src/components/Input/Input.stories.d.ts.map +1 -1
- package/dist/types/src/components/Popover/Popover.d.ts +1 -1
- package/dist/types/src/components/Popover/Popover.d.ts.map +1 -1
- package/dist/types/src/components/Select/Select.stories.d.ts +1 -1
- package/dist/types/src/components/Select/Select.stories.d.ts.map +1 -1
- package/dist/types/src/components/ThemeProvider/ThemeProvider.d.ts +1 -1
- package/dist/types/src/components/ThemeProvider/ThemeProvider.d.ts.map +1 -1
- package/dist/types/src/components/ThemeProvider/TranslationsProvider.d.ts.map +1 -1
- package/dist/types/src/components/ThemeProvider/index.d.ts +1 -1
- package/dist/types/src/components/ThemeProvider/index.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +1 -1
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/playground/Custom.stories.d.ts +1 -1
- package/dist/types/src/playground/Custom.stories.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +13 -13
- package/src/components/Buttons/Button.stories.tsx +1 -1
- package/src/components/Buttons/Button.tsx +1 -0
- package/src/components/Buttons/IconButton.tsx +1 -1
- package/src/components/Clipboard/CopyButton.tsx +10 -12
- package/src/components/Input/Input.stories.tsx +1 -1
- package/src/components/Popover/Popover.tsx +1 -1
- package/src/components/Select/Select.stories.tsx +1 -1
- package/src/components/ThemeProvider/ThemeProvider.tsx +1 -2
- package/src/components/ThemeProvider/TranslationsProvider.tsx +1 -1
- package/src/components/ThemeProvider/index.ts +3 -1
- package/src/index.ts +1 -1
- package/src/playground/Custom.stories.tsx +1 -1
- package/src/testing/decorators/withSurfaceVariantsLayout.tsx +1 -1
- package/README.yml +0 -1
- package/dist/lib/browser/chunk-WXW6KSRL.mjs.map +0 -7
- package/dist/lib/node/chunk-3E3QKWX4.cjs +0 -4363
- package/dist/lib/node/chunk-3E3QKWX4.cjs.map +0 -7
- package/dist/lib/node/index.cjs +0 -175
- package/dist/lib/node/index.cjs.map +0 -7
- package/dist/lib/node/meta.json +0 -1
- package/dist/lib/node/testing/index.cjs +0 -114
- package/dist/lib/node/testing/index.cjs.map +0 -7
- package/dist/lib/node-esm/chunk-EQ7EG74H.mjs.map +0 -7
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
//
|
|
1
|
+
// src/hooks/useDensityContext.ts
|
|
2
2
|
import { useContext as useContext6 } from "react";
|
|
3
3
|
|
|
4
|
-
//
|
|
4
|
+
// src/components/AnchoredOverflow/AnchoredOverflow.tsx
|
|
5
5
|
import { useSignals as _useSignals2 } from "@preact-signals/safe-react/tracking";
|
|
6
6
|
import { Primitive } from "@radix-ui/react-primitive";
|
|
7
7
|
import { Slot } from "@radix-ui/react-slot";
|
|
8
8
|
import React2, { forwardRef } from "react";
|
|
9
9
|
|
|
10
|
-
//
|
|
10
|
+
// src/hooks/useElevationContext.ts
|
|
11
11
|
import { useContext } from "react";
|
|
12
12
|
var useElevationContext = (propsElevation) => {
|
|
13
13
|
const { elevation } = useContext(ElevationContext);
|
|
14
14
|
return propsElevation ?? elevation;
|
|
15
15
|
};
|
|
16
16
|
|
|
17
|
-
//
|
|
17
|
+
// src/hooks/useThemeContext.ts
|
|
18
18
|
import { useContext as useContext2 } from "react";
|
|
19
19
|
import { raise } from "@dxos/debug";
|
|
20
20
|
var useThemeContext = () => useContext2(ThemeContext) ?? raise(new Error("Missing ThemeContext"));
|
|
21
21
|
|
|
22
|
-
//
|
|
22
|
+
// src/hooks/useIconHref.ts
|
|
23
23
|
var ICONS_URL = "/icons.svg";
|
|
24
24
|
var useIconHref = (icon) => {
|
|
25
25
|
const { noCache } = useThemeContext();
|
|
@@ -27,7 +27,7 @@ var useIconHref = (icon) => {
|
|
|
27
27
|
return icon ? `${url}#${icon}` : void 0;
|
|
28
28
|
};
|
|
29
29
|
|
|
30
|
-
//
|
|
30
|
+
// src/hooks/useSafeArea.ts
|
|
31
31
|
import { useCallback, useState } from "react";
|
|
32
32
|
import { useResize } from "@dxos/react-hooks";
|
|
33
33
|
var initialSafeArea = {
|
|
@@ -50,10 +50,10 @@ var useSafeArea = () => {
|
|
|
50
50
|
return padding;
|
|
51
51
|
};
|
|
52
52
|
|
|
53
|
-
//
|
|
53
|
+
// src/hooks/useTranslationsContext.ts
|
|
54
54
|
import { useContext as useContext4 } from "react";
|
|
55
55
|
|
|
56
|
-
//
|
|
56
|
+
// src/components/ThemeProvider/TranslationsProvider.tsx
|
|
57
57
|
import { useSignals as _useSignals } from "@preact-signals/safe-react/tracking";
|
|
58
58
|
import { enUS as dtLocaleEnUs } from "date-fns/locale";
|
|
59
59
|
import i18Next from "i18next";
|
|
@@ -123,10 +123,10 @@ var TranslationsProvider = ({ fallback, resourceExtensions, children, appNs, dtL
|
|
|
123
123
|
}
|
|
124
124
|
};
|
|
125
125
|
|
|
126
|
-
//
|
|
126
|
+
// src/hooks/useTranslationsContext.ts
|
|
127
127
|
var useTranslationsContext = () => useContext4(TranslationsContext);
|
|
128
128
|
|
|
129
|
-
//
|
|
129
|
+
// src/hooks/useVisualViewport.ts
|
|
130
130
|
import { useCallback as useCallback2, useState as useState3 } from "react";
|
|
131
131
|
import { useResize as useResize2 } from "@dxos/react-hooks";
|
|
132
132
|
var useVisualViewport = (deps) => {
|
|
@@ -145,7 +145,7 @@ var useVisualViewport = (deps) => {
|
|
|
145
145
|
};
|
|
146
146
|
};
|
|
147
147
|
|
|
148
|
-
//
|
|
148
|
+
// src/components/AnchoredOverflow/AnchoredOverflow.tsx
|
|
149
149
|
var AnchoredOverflowRoot = /* @__PURE__ */ forwardRef(({ asChild, classNames, children, ...props }, forwardedRef) => {
|
|
150
150
|
var _effect = _useSignals2();
|
|
151
151
|
try {
|
|
@@ -181,7 +181,7 @@ var AnchoredOverflow = {
|
|
|
181
181
|
Anchor: AnchoredOverflowAnchor
|
|
182
182
|
};
|
|
183
183
|
|
|
184
|
-
//
|
|
184
|
+
// src/components/Avatars/Avatar.tsx
|
|
185
185
|
import { useSignals as _useSignals3 } from "@preact-signals/safe-react/tracking";
|
|
186
186
|
import "@dxos/lit-ui/dx-avatar.pcss";
|
|
187
187
|
import { createContext as createContext2 } from "@radix-ui/react-context";
|
|
@@ -266,14 +266,14 @@ var Avatar = {
|
|
|
266
266
|
Description: AvatarDescription
|
|
267
267
|
};
|
|
268
268
|
|
|
269
|
-
//
|
|
269
|
+
// src/components/Breadcrumb/Breadcrumb.tsx
|
|
270
270
|
import { useSignals as _useSignals5 } from "@preact-signals/safe-react/tracking";
|
|
271
271
|
import { Dot } from "@phosphor-icons/react";
|
|
272
272
|
import { Primitive as Primitive4 } from "@radix-ui/react-primitive";
|
|
273
273
|
import { Slot as Slot4 } from "@radix-ui/react-slot";
|
|
274
274
|
import React5, { forwardRef as forwardRef4 } from "react";
|
|
275
275
|
|
|
276
|
-
//
|
|
276
|
+
// src/components/Link/Link.tsx
|
|
277
277
|
import { useSignals as _useSignals4 } from "@preact-signals/safe-react/tracking";
|
|
278
278
|
import { Primitive as Primitive3 } from "@radix-ui/react-primitive";
|
|
279
279
|
import { Slot as Slot3 } from "@radix-ui/react-slot";
|
|
@@ -295,7 +295,7 @@ var Link = /* @__PURE__ */ forwardRef3(({ asChild, variant, classNames, ...props
|
|
|
295
295
|
}
|
|
296
296
|
});
|
|
297
297
|
|
|
298
|
-
//
|
|
298
|
+
// src/components/Breadcrumb/Breadcrumb.tsx
|
|
299
299
|
var BreadcrumbRoot = /* @__PURE__ */ forwardRef4(({ asChild, classNames, ...props }, forwardedRef) => {
|
|
300
300
|
var _effect = _useSignals5();
|
|
301
301
|
try {
|
|
@@ -393,7 +393,7 @@ var Breadcrumb = {
|
|
|
393
393
|
Separator: BreadcrumbSeparator
|
|
394
394
|
};
|
|
395
395
|
|
|
396
|
-
//
|
|
396
|
+
// src/components/Buttons/Button.tsx
|
|
397
397
|
import { useSignals as _useSignals6 } from "@preact-signals/safe-react/tracking";
|
|
398
398
|
import { createContext as createContext3 } from "@radix-ui/react-context";
|
|
399
399
|
import { Primitive as Primitive5 } from "@radix-ui/react-primitive";
|
|
@@ -456,11 +456,11 @@ var ButtonGroup = /* @__PURE__ */ forwardRef5(({ children, elevation: propsEleva
|
|
|
456
456
|
});
|
|
457
457
|
ButtonGroup.displayName = BUTTON_GROUP_NAME;
|
|
458
458
|
|
|
459
|
-
//
|
|
459
|
+
// src/components/Buttons/IconButton.tsx
|
|
460
460
|
import { useSignals as _useSignals9 } from "@preact-signals/safe-react/tracking";
|
|
461
461
|
import React9, { forwardRef as forwardRef8 } from "react";
|
|
462
462
|
|
|
463
|
-
//
|
|
463
|
+
// src/components/Icon/Icon.tsx
|
|
464
464
|
import { useSignals as _useSignals7 } from "@preact-signals/safe-react/tracking";
|
|
465
465
|
import React7, { forwardRef as forwardRef6, memo as memo2 } from "react";
|
|
466
466
|
var Icon = /* @__PURE__ */ memo2(/* @__PURE__ */ forwardRef6(({ icon, classNames, size, ...props }, forwardedRef) => {
|
|
@@ -482,7 +482,7 @@ var Icon = /* @__PURE__ */ memo2(/* @__PURE__ */ forwardRef6(({ icon, classNames
|
|
|
482
482
|
}
|
|
483
483
|
}));
|
|
484
484
|
|
|
485
|
-
//
|
|
485
|
+
// src/components/Tooltip/Tooltip.tsx
|
|
486
486
|
import { useSignals as _useSignals8 } from "@preact-signals/safe-react/tracking";
|
|
487
487
|
import { composeEventHandlers } from "@radix-ui/primitive";
|
|
488
488
|
import { useComposedRefs } from "@radix-ui/react-compose-refs";
|
|
@@ -1105,7 +1105,7 @@ var Tooltip = {
|
|
|
1105
1105
|
Trigger: TooltipTrigger
|
|
1106
1106
|
};
|
|
1107
1107
|
|
|
1108
|
-
//
|
|
1108
|
+
// src/components/Buttons/IconButton.tsx
|
|
1109
1109
|
var IconOnlyButton = /* @__PURE__ */ forwardRef8(({ noTooltip, tooltipPortal = true, tooltipSide, ...props }, forwardedRef) => {
|
|
1110
1110
|
var _effect = _useSignals9();
|
|
1111
1111
|
try {
|
|
@@ -1133,7 +1133,9 @@ var LabelledIconButton = /* @__PURE__ */ forwardRef8(({ icon, size, iconOnly, la
|
|
|
1133
1133
|
const { tx } = useThemeContext();
|
|
1134
1134
|
return /* @__PURE__ */ React9.createElement(Button, {
|
|
1135
1135
|
...props,
|
|
1136
|
-
classNames: tx("iconButton.root", "iconButton", {
|
|
1136
|
+
classNames: tx("iconButton.root", "iconButton", {
|
|
1137
|
+
iconOnly
|
|
1138
|
+
}, classNames),
|
|
1137
1139
|
ref: forwardedRef
|
|
1138
1140
|
}, /* @__PURE__ */ React9.createElement(Icon, {
|
|
1139
1141
|
icon,
|
|
@@ -1164,7 +1166,7 @@ var IconButton = /* @__PURE__ */ forwardRef8((props, forwardedRef) => {
|
|
|
1164
1166
|
}
|
|
1165
1167
|
});
|
|
1166
1168
|
|
|
1167
|
-
//
|
|
1169
|
+
// src/components/Buttons/Toggle.tsx
|
|
1168
1170
|
import { useSignals as _useSignals10 } from "@preact-signals/safe-react/tracking";
|
|
1169
1171
|
import { Toggle as TogglePrimitive } from "@radix-ui/react-toggle";
|
|
1170
1172
|
import React10, { forwardRef as forwardRef9 } from "react";
|
|
@@ -1185,7 +1187,7 @@ var Toggle = /* @__PURE__ */ forwardRef9(({ defaultPressed, pressed, onPressedCh
|
|
|
1185
1187
|
}
|
|
1186
1188
|
});
|
|
1187
1189
|
|
|
1188
|
-
//
|
|
1190
|
+
// src/components/Buttons/ToggleGroup.tsx
|
|
1189
1191
|
import { useSignals as _useSignals11 } from "@preact-signals/safe-react/tracking";
|
|
1190
1192
|
import { ToggleGroup as ToggleGroupPrimitive, ToggleGroupItem as ToggleGroupItemPrimitive } from "@radix-ui/react-toggle-group";
|
|
1191
1193
|
import React11, { forwardRef as forwardRef10 } from "react";
|
|
@@ -1223,7 +1225,7 @@ var ToggleGroupItem = /* @__PURE__ */ forwardRef10(({ variant, elevation, densit
|
|
|
1223
1225
|
}
|
|
1224
1226
|
});
|
|
1225
1227
|
|
|
1226
|
-
//
|
|
1228
|
+
// src/components/Clipboard/ClipboardProvider.tsx
|
|
1227
1229
|
import { useSignals as _useSignals12 } from "@preact-signals/safe-react/tracking";
|
|
1228
1230
|
import React12, { createContext as createContext4, useCallback as useCallback4, useContext as useContext5, useState as useState5 } from "react";
|
|
1229
1231
|
var ClipboardContext = /* @__PURE__ */ createContext4({
|
|
@@ -1251,22 +1253,22 @@ var ClipboardProvider = ({ children }) => {
|
|
|
1251
1253
|
}
|
|
1252
1254
|
};
|
|
1253
1255
|
|
|
1254
|
-
//
|
|
1256
|
+
// src/components/Clipboard/CopyButton.tsx
|
|
1255
1257
|
import { useSignals as _useSignals16 } from "@preact-signals/safe-react/tracking";
|
|
1256
1258
|
import React16 from "react";
|
|
1257
1259
|
import { mx as mx2 } from "@dxos/react-ui-theme";
|
|
1258
1260
|
|
|
1259
|
-
//
|
|
1261
|
+
// src/components/ThemeProvider/ThemeProvider.tsx
|
|
1260
1262
|
import { useSignals as _useSignals15 } from "@preact-signals/safe-react/tracking";
|
|
1261
1263
|
import { createKeyborg } from "keyborg";
|
|
1262
1264
|
import React15, { createContext as createContext7, useEffect as useEffect3, useMemo as useMemo2 } from "react";
|
|
1263
1265
|
|
|
1264
|
-
//
|
|
1266
|
+
// src/util/hasIosKeyboard.ts
|
|
1265
1267
|
var hasIosKeyboard = () => {
|
|
1266
1268
|
return !!navigator.userAgent.match(/iP(ad|od|hone).+Safari/);
|
|
1267
1269
|
};
|
|
1268
1270
|
|
|
1269
|
-
//
|
|
1271
|
+
// src/components/DensityProvider/DensityProvider.tsx
|
|
1270
1272
|
import { useSignals as _useSignals13 } from "@preact-signals/safe-react/tracking";
|
|
1271
1273
|
import React13, { createContext as createContext5 } from "react";
|
|
1272
1274
|
var DensityContext = /* @__PURE__ */ createContext5({
|
|
@@ -1285,7 +1287,7 @@ var DensityProvider = ({ density, children }) => {
|
|
|
1285
1287
|
}
|
|
1286
1288
|
};
|
|
1287
1289
|
|
|
1288
|
-
//
|
|
1290
|
+
// src/components/ElevationProvider/ElevationProvider.tsx
|
|
1289
1291
|
import { useSignals as _useSignals14 } from "@preact-signals/safe-react/tracking";
|
|
1290
1292
|
import React14, { createContext as createContext6 } from "react";
|
|
1291
1293
|
var ElevationContext = /* @__PURE__ */ createContext6({
|
|
@@ -1304,7 +1306,7 @@ var ElevationProvider = ({ elevation, children }) => {
|
|
|
1304
1306
|
}
|
|
1305
1307
|
};
|
|
1306
1308
|
|
|
1307
|
-
//
|
|
1309
|
+
// src/components/ThemeProvider/ThemeProvider.tsx
|
|
1308
1310
|
var ThemeContext = /* @__PURE__ */ createContext7(void 0);
|
|
1309
1311
|
var ThemeProvider = ({ children, fallback = null, resourceExtensions, appNs, tx = (_path, defaultClassName, _styleProps, ..._options) => defaultClassName, themeMode = "dark", rootDensity = "fine", ...rest }) => {
|
|
1310
1312
|
var _effect = _useSignals15();
|
|
@@ -1352,9 +1354,9 @@ var handleInputModalityChange = (isUsingKeyboard) => {
|
|
|
1352
1354
|
}
|
|
1353
1355
|
};
|
|
1354
1356
|
|
|
1355
|
-
//
|
|
1357
|
+
// src/components/Clipboard/CopyButton.tsx
|
|
1356
1358
|
var inactiveLabelStyles = "invisible bs-px -mbe-px overflow-hidden";
|
|
1357
|
-
var CopyButton = ({
|
|
1359
|
+
var CopyButton = ({ classNames, value, size = 5, ...props }) => {
|
|
1358
1360
|
var _effect = _useSignals16();
|
|
1359
1361
|
try {
|
|
1360
1362
|
const { t } = useTranslation("os");
|
|
@@ -1375,8 +1377,7 @@ var CopyButton = ({ value, classNames, iconProps, ...props }) => {
|
|
|
1375
1377
|
className: "pli-1"
|
|
1376
1378
|
}, t("copy label")), /* @__PURE__ */ React16.createElement(Icon, {
|
|
1377
1379
|
icon: "ph--copy--regular",
|
|
1378
|
-
size
|
|
1379
|
-
...iconProps
|
|
1380
|
+
size
|
|
1380
1381
|
})), /* @__PURE__ */ React16.createElement("div", {
|
|
1381
1382
|
role: "none",
|
|
1382
1383
|
className: mx2("flex gap-1 items-center", !isCopied && inactiveLabelStyles)
|
|
@@ -1384,14 +1385,13 @@ var CopyButton = ({ value, classNames, iconProps, ...props }) => {
|
|
|
1384
1385
|
className: "pli-1"
|
|
1385
1386
|
}, t("copy success label")), /* @__PURE__ */ React16.createElement(Icon, {
|
|
1386
1387
|
icon: "ph--check--regular",
|
|
1387
|
-
size
|
|
1388
|
-
...iconProps
|
|
1388
|
+
size
|
|
1389
1389
|
})));
|
|
1390
1390
|
} finally {
|
|
1391
1391
|
_effect.f();
|
|
1392
1392
|
}
|
|
1393
1393
|
};
|
|
1394
|
-
var CopyButtonIconOnly = ({ __scopeTooltip, value, classNames,
|
|
1394
|
+
var CopyButtonIconOnly = ({ __scopeTooltip, value, classNames, size, variant, ...props }) => {
|
|
1395
1395
|
var _effect = _useSignals16();
|
|
1396
1396
|
try {
|
|
1397
1397
|
const { t } = useTranslation("os");
|
|
@@ -1403,7 +1403,7 @@ var CopyButtonIconOnly = ({ __scopeTooltip, value, classNames, iconProps, varian
|
|
|
1403
1403
|
iconOnly: true,
|
|
1404
1404
|
label,
|
|
1405
1405
|
icon: "ph--copy--regular",
|
|
1406
|
-
size
|
|
1406
|
+
size,
|
|
1407
1407
|
variant,
|
|
1408
1408
|
classNames: [
|
|
1409
1409
|
"inline-flex flex-col justify-center",
|
|
@@ -1417,14 +1417,14 @@ var CopyButtonIconOnly = ({ __scopeTooltip, value, classNames, iconProps, varian
|
|
|
1417
1417
|
}
|
|
1418
1418
|
};
|
|
1419
1419
|
|
|
1420
|
-
//
|
|
1420
|
+
// src/components/Clipboard/index.ts
|
|
1421
1421
|
var Clipboard = {
|
|
1422
1422
|
Button: CopyButton,
|
|
1423
1423
|
IconButton: CopyButtonIconOnly,
|
|
1424
1424
|
Provider: ClipboardProvider
|
|
1425
1425
|
};
|
|
1426
1426
|
|
|
1427
|
-
//
|
|
1427
|
+
// src/components/Dialogs/Dialog.tsx
|
|
1428
1428
|
import { useSignals as _useSignals17 } from "@preact-signals/safe-react/tracking";
|
|
1429
1429
|
import { createContext as createContext8 } from "@radix-ui/react-context";
|
|
1430
1430
|
import { Root as DialogRootPrimitive, DialogTrigger as DialogTriggerPrimitive, DialogPortal as DialogPortalPrimitive, DialogOverlay as DialogOverlayPrimitive, DialogTitle as DialogTitlePrimitive, DialogDescription as DialogDescriptionPrimitive, DialogClose as DialogClosePrimitive, DialogContent as DialogContentPrimitive } from "@radix-ui/react-dialog";
|
|
@@ -1523,7 +1523,7 @@ var Dialog = {
|
|
|
1523
1523
|
Close: DialogClose
|
|
1524
1524
|
};
|
|
1525
1525
|
|
|
1526
|
-
//
|
|
1526
|
+
// src/components/Dialogs/AlertDialog.tsx
|
|
1527
1527
|
import { useSignals as _useSignals18 } from "@preact-signals/safe-react/tracking";
|
|
1528
1528
|
import { Root as AlertDialogRootPrimitive, AlertDialogTrigger as AlertDialogTriggerPrimitive, AlertDialogPortal as AlertDialogPortalPrimitive, AlertDialogOverlay as AlertDialogOverlayPrimitive, AlertDialogTitle as AlertDialogTitlePrimitive, AlertDialogDescription as AlertDialogDescriptionPrimitive, AlertDialogAction as AlertDialogActionPrimitive, AlertDialogCancel as AlertDialogCancelPrimitive, AlertDialogContent as AlertDialogContentPrimitive } from "@radix-ui/react-alert-dialog";
|
|
1529
1529
|
import { createContext as createContext9 } from "@radix-ui/react-context";
|
|
@@ -1623,7 +1623,7 @@ var AlertDialog = {
|
|
|
1623
1623
|
Action: AlertDialogAction
|
|
1624
1624
|
};
|
|
1625
1625
|
|
|
1626
|
-
//
|
|
1626
|
+
// src/components/Input/Input.tsx
|
|
1627
1627
|
import { useSignals as _useSignals19 } from "@preact-signals/safe-react/tracking";
|
|
1628
1628
|
import { Root as CheckboxPrimitive } from "@radix-ui/react-checkbox";
|
|
1629
1629
|
import { useControllableState as useControllableState2 } from "@radix-ui/react-use-controllable-state";
|
|
@@ -1858,14 +1858,14 @@ var Input = {
|
|
|
1858
1858
|
DescriptionAndValidation
|
|
1859
1859
|
};
|
|
1860
1860
|
|
|
1861
|
-
//
|
|
1861
|
+
// src/components/Lists/List.tsx
|
|
1862
1862
|
import { useSignals as _useSignals21 } from "@preact-signals/safe-react/tracking";
|
|
1863
1863
|
import { CaretDown, CaretRight } from "@phosphor-icons/react";
|
|
1864
1864
|
import { Slot as Slot6 } from "@radix-ui/react-slot";
|
|
1865
1865
|
import React21, { forwardRef as forwardRef14 } from "react";
|
|
1866
1866
|
import { List as ListPrimitive, ListItemHeading as ListPrimitiveItemHeading, ListItemOpenTrigger as ListPrimitiveItemOpenTrigger, ListItemCollapsibleContent, ListItem as ListPrimitiveItem, LIST_NAME, LIST_ITEM_NAME, useListContext, useListItemContext } from "@dxos/react-list";
|
|
1867
1867
|
|
|
1868
|
-
//
|
|
1868
|
+
// src/components/Lists/ListDropIndicator.tsx
|
|
1869
1869
|
import { useSignals as _useSignals20 } from "@preact-signals/safe-react/tracking";
|
|
1870
1870
|
import React20 from "react";
|
|
1871
1871
|
var edgeToOrientationMap = {
|
|
@@ -1909,7 +1909,7 @@ var ListDropIndicator = ({ edge, gap = 0, lineInset = 0, terminalInset = lineIns
|
|
|
1909
1909
|
}
|
|
1910
1910
|
};
|
|
1911
1911
|
|
|
1912
|
-
//
|
|
1912
|
+
// src/components/Lists/List.tsx
|
|
1913
1913
|
var List = /* @__PURE__ */ forwardRef14(({ classNames, children, ...props }, forwardedRef) => {
|
|
1914
1914
|
var _effect = _useSignals21();
|
|
1915
1915
|
try {
|
|
@@ -2026,11 +2026,11 @@ var ListItem = {
|
|
|
2026
2026
|
DropIndicator: ListDropIndicator
|
|
2027
2027
|
};
|
|
2028
2028
|
|
|
2029
|
-
//
|
|
2029
|
+
// src/components/Lists/Tree.tsx
|
|
2030
2030
|
import { useSignals as _useSignals23 } from "@preact-signals/safe-react/tracking";
|
|
2031
2031
|
import React23, { forwardRef as forwardRef15 } from "react";
|
|
2032
2032
|
|
|
2033
|
-
//
|
|
2033
|
+
// src/components/Lists/TreeDropIndicator.tsx
|
|
2034
2034
|
import { useSignals as _useSignals22 } from "@preact-signals/safe-react/tracking";
|
|
2035
2035
|
import React22 from "react";
|
|
2036
2036
|
var edgeToOrientationMap2 = {
|
|
@@ -2081,7 +2081,7 @@ var TreeDropIndicator = ({ instruction, gap = 0 }) => {
|
|
|
2081
2081
|
}
|
|
2082
2082
|
};
|
|
2083
2083
|
|
|
2084
|
-
//
|
|
2084
|
+
// src/components/Lists/Tree.tsx
|
|
2085
2085
|
var TreeRoot = /* @__PURE__ */ forwardRef15((props, forwardedRef) => {
|
|
2086
2086
|
var _effect = _useSignals23();
|
|
2087
2087
|
try {
|
|
@@ -2135,7 +2135,7 @@ var TreeItem = {
|
|
|
2135
2135
|
DropIndicator: TreeDropIndicator
|
|
2136
2136
|
};
|
|
2137
2137
|
|
|
2138
|
-
//
|
|
2138
|
+
// src/components/Lists/Treegrid.tsx
|
|
2139
2139
|
import { useSignals as _useSignals24 } from "@preact-signals/safe-react/tracking";
|
|
2140
2140
|
import { useArrowNavigationGroup, useFocusableGroup } from "@fluentui/react-tabster";
|
|
2141
2141
|
import { createContextScope as createContextScope2 } from "@radix-ui/react-context";
|
|
@@ -2248,7 +2248,7 @@ var Treegrid = {
|
|
|
2248
2248
|
useTreegridRowContext
|
|
2249
2249
|
};
|
|
2250
2250
|
|
|
2251
|
-
//
|
|
2251
|
+
// src/components/Main/Main.tsx
|
|
2252
2252
|
import { useSignals as _useSignals25 } from "@preact-signals/safe-react/tracking";
|
|
2253
2253
|
import { createContext as createContext10 } from "@radix-ui/react-context";
|
|
2254
2254
|
import { Root as DialogRoot2, DialogContent as DialogContent2, DialogTitle as DialogTitle2 } from "@radix-ui/react-dialog";
|
|
@@ -2259,7 +2259,7 @@ import React25, { forwardRef as forwardRef17, useCallback as useCallback7, useEf
|
|
|
2259
2259
|
import { log } from "@dxos/log";
|
|
2260
2260
|
import { useMediaQuery, useForwardedRef } from "@dxos/react-hooks";
|
|
2261
2261
|
|
|
2262
|
-
//
|
|
2262
|
+
// src/components/Main/useSwipeToDismiss.ts
|
|
2263
2263
|
import { useCallback as useCallback6, useEffect as useEffect4, useState as useState6 } from "react";
|
|
2264
2264
|
var useSwipeToDismiss = (ref, {
|
|
2265
2265
|
onDismiss,
|
|
@@ -2350,8 +2350,8 @@ var useSwipeToDismiss = (ref, {
|
|
|
2350
2350
|
]);
|
|
2351
2351
|
};
|
|
2352
2352
|
|
|
2353
|
-
//
|
|
2354
|
-
var __dxlog_file = "/
|
|
2353
|
+
// src/components/Main/Main.tsx
|
|
2354
|
+
var __dxlog_file = "/__w/dxos/dxos/packages/ui/react-ui/src/components/Main/Main.tsx";
|
|
2355
2355
|
var MAIN_ROOT_NAME = "MainRoot";
|
|
2356
2356
|
var NAVIGATION_SIDEBAR_NAME = "NavigationSidebar";
|
|
2357
2357
|
var COMPLEMENTARY_SIDEBAR_NAME = "ComplementarySidebar";
|
|
@@ -2630,14 +2630,14 @@ var Main = {
|
|
|
2630
2630
|
ComplementarySidebar: MainComplementarySidebar
|
|
2631
2631
|
};
|
|
2632
2632
|
|
|
2633
|
-
//
|
|
2633
|
+
// src/components/Menus/ContextMenu.tsx
|
|
2634
2634
|
import { useSignals as _useSignals26 } from "@preact-signals/safe-react/tracking";
|
|
2635
2635
|
import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
|
|
2636
2636
|
import { Primitive as Primitive9 } from "@radix-ui/react-primitive";
|
|
2637
2637
|
import { Slot as Slot9 } from "@radix-ui/react-slot";
|
|
2638
2638
|
import React26, { forwardRef as forwardRef18 } from "react";
|
|
2639
2639
|
|
|
2640
|
-
//
|
|
2640
|
+
// src/hooks/useSafeCollisionPadding.ts
|
|
2641
2641
|
import { useMemo as useMemo3 } from "react";
|
|
2642
2642
|
var propIsNumber = (prop) => Number.isFinite(prop);
|
|
2643
2643
|
var propsIsRecord = (prop) => !!(prop && typeof prop === "object");
|
|
@@ -2657,7 +2657,7 @@ var useSafeCollisionPadding = (collisionPadding) => {
|
|
|
2657
2657
|
]);
|
|
2658
2658
|
};
|
|
2659
2659
|
|
|
2660
|
-
//
|
|
2660
|
+
// src/components/Menus/ContextMenu.tsx
|
|
2661
2661
|
var ContextMenuRoot = ContextMenuPrimitive.ContextMenu;
|
|
2662
2662
|
var ContextMenuTrigger = ContextMenuPrimitive.Trigger;
|
|
2663
2663
|
var ContextMenuPortal = ContextMenuPrimitive.Portal;
|
|
@@ -2775,7 +2775,7 @@ var ContextMenu2 = {
|
|
|
2775
2775
|
GroupLabel: ContextMenuGroupLabel
|
|
2776
2776
|
};
|
|
2777
2777
|
|
|
2778
|
-
//
|
|
2778
|
+
// src/components/Menus/DropdownMenu.tsx
|
|
2779
2779
|
import { useSignals as _useSignals27 } from "@preact-signals/safe-react/tracking";
|
|
2780
2780
|
import { composeEventHandlers as composeEventHandlers2 } from "@radix-ui/primitive";
|
|
2781
2781
|
import { composeRefs } from "@radix-ui/react-compose-refs";
|
|
@@ -3224,7 +3224,7 @@ var DropdownMenu = {
|
|
|
3224
3224
|
};
|
|
3225
3225
|
var useDropdownMenuMenuScope = useMenuScope;
|
|
3226
3226
|
|
|
3227
|
-
//
|
|
3227
|
+
// src/components/Message/Message.tsx
|
|
3228
3228
|
import { useSignals as _useSignals28 } from "@preact-signals/safe-react/tracking";
|
|
3229
3229
|
import { createContext as createContext11 } from "@radix-ui/react-context";
|
|
3230
3230
|
import { Primitive as Primitive11 } from "@radix-ui/react-primitive";
|
|
@@ -3317,7 +3317,7 @@ var Message = {
|
|
|
3317
3317
|
};
|
|
3318
3318
|
var Callout = Message;
|
|
3319
3319
|
|
|
3320
|
-
//
|
|
3320
|
+
// src/components/Popover/Popover.tsx
|
|
3321
3321
|
import { useSignals as _useSignals29 } from "@preact-signals/safe-react/tracking";
|
|
3322
3322
|
import { composeEventHandlers as composeEventHandlers3 } from "@radix-ui/primitive";
|
|
3323
3323
|
import { useComposedRefs as useComposedRefs2 } from "@radix-ui/react-compose-refs";
|
|
@@ -3697,7 +3697,7 @@ var Popover = {
|
|
|
3697
3697
|
Viewport: PopoverViewport
|
|
3698
3698
|
};
|
|
3699
3699
|
|
|
3700
|
-
//
|
|
3700
|
+
// src/components/Status/Status.tsx
|
|
3701
3701
|
import { useSignals as _useSignals30 } from "@preact-signals/safe-react/tracking";
|
|
3702
3702
|
import React30, { forwardRef as forwardRef22 } from "react";
|
|
3703
3703
|
var Status = /* @__PURE__ */ forwardRef22(({ classNames, children, progress = 0, indeterminate, variant, ...props }, forwardedRef) => {
|
|
@@ -3729,7 +3729,7 @@ var Status = /* @__PURE__ */ forwardRef22(({ classNames, children, progress = 0,
|
|
|
3729
3729
|
}
|
|
3730
3730
|
});
|
|
3731
3731
|
|
|
3732
|
-
//
|
|
3732
|
+
// src/components/ScrollArea/ScrollArea.tsx
|
|
3733
3733
|
import { useSignals as _useSignals31 } from "@preact-signals/safe-react/tracking";
|
|
3734
3734
|
import { Root as ScrollAreaPrimitiveRoot, Viewport as ScrollAreaPrimitiveViewport, Scrollbar as ScrollAreaPrimitiveScrollbar, Thumb as ScrollAreaPrimitiveThumb, Corner as ScrollAreaPrimitiveCorner } from "@radix-ui/react-scroll-area";
|
|
3735
3735
|
import React31, { forwardRef as forwardRef23 } from "react";
|
|
@@ -3807,7 +3807,7 @@ var ScrollArea = {
|
|
|
3807
3807
|
Corner: ScrollAreaCorner
|
|
3808
3808
|
};
|
|
3809
3809
|
|
|
3810
|
-
//
|
|
3810
|
+
// src/components/Select/Select.tsx
|
|
3811
3811
|
import { useSignals as _useSignals32 } from "@preact-signals/safe-react/tracking";
|
|
3812
3812
|
import { CaretDown as CaretDown2, CaretUp } from "@phosphor-icons/react";
|
|
3813
3813
|
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
@@ -3993,7 +3993,7 @@ var Select = {
|
|
|
3993
3993
|
Arrow: SelectArrow
|
|
3994
3994
|
};
|
|
3995
3995
|
|
|
3996
|
-
//
|
|
3996
|
+
// src/components/Separator/Separator.tsx
|
|
3997
3997
|
import { useSignals as _useSignals33 } from "@preact-signals/safe-react/tracking";
|
|
3998
3998
|
import { Separator as SeparatorPrimitive } from "@radix-ui/react-separator";
|
|
3999
3999
|
import React33, { forwardRef as forwardRef25 } from "react";
|
|
@@ -4015,7 +4015,7 @@ var Separator4 = /* @__PURE__ */ forwardRef25(({ classNames, orientation = "hori
|
|
|
4015
4015
|
}
|
|
4016
4016
|
});
|
|
4017
4017
|
|
|
4018
|
-
//
|
|
4018
|
+
// src/components/Tag/Tag.tsx
|
|
4019
4019
|
import { useSignals as _useSignals34 } from "@preact-signals/safe-react/tracking";
|
|
4020
4020
|
import { Primitive as Primitive13 } from "@radix-ui/react-primitive";
|
|
4021
4021
|
import { Slot as Slot13 } from "@radix-ui/react-slot";
|
|
@@ -4038,7 +4038,7 @@ var Tag = /* @__PURE__ */ forwardRef26(({ asChild, palette = "neutral", classNam
|
|
|
4038
4038
|
}
|
|
4039
4039
|
});
|
|
4040
4040
|
|
|
4041
|
-
//
|
|
4041
|
+
// src/components/Toast/Toast.tsx
|
|
4042
4042
|
import { useSignals as _useSignals35 } from "@preact-signals/safe-react/tracking";
|
|
4043
4043
|
import { Primitive as Primitive14 } from "@radix-ui/react-primitive";
|
|
4044
4044
|
import { Slot as Slot14 } from "@radix-ui/react-slot";
|
|
@@ -4142,7 +4142,7 @@ var Toast = {
|
|
|
4142
4142
|
Close: ToastClose
|
|
4143
4143
|
};
|
|
4144
4144
|
|
|
4145
|
-
//
|
|
4145
|
+
// src/components/Toolbar/Toolbar.tsx
|
|
4146
4146
|
import { useSignals as _useSignals36 } from "@preact-signals/safe-react/tracking";
|
|
4147
4147
|
import * as ToolbarPrimitive from "@radix-ui/react-toolbar";
|
|
4148
4148
|
import React36, { forwardRef as forwardRef28 } from "react";
|
|
@@ -4295,7 +4295,7 @@ var Toolbar = {
|
|
|
4295
4295
|
Separator: ToolbarSeparator
|
|
4296
4296
|
};
|
|
4297
4297
|
|
|
4298
|
-
//
|
|
4298
|
+
// src/hooks/useDensityContext.ts
|
|
4299
4299
|
var useDensityContext = (propsDensity) => {
|
|
4300
4300
|
const { density } = useContext6(DensityContext);
|
|
4301
4301
|
return propsDensity ?? density;
|
|
@@ -4373,4 +4373,4 @@ export {
|
|
|
4373
4373
|
Toast,
|
|
4374
4374
|
Toolbar
|
|
4375
4375
|
};
|
|
4376
|
-
//# sourceMappingURL=chunk-
|
|
4376
|
+
//# sourceMappingURL=chunk-T6YPS45E.mjs.map
|