@gnome-ui/react-native 1.5.0 → 1.6.0
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/README.md +441 -3
- package/dist/components/AvatarGroup/AvatarGroup.d.ts +47 -0
- package/dist/components/AvatarGroup/index.d.ts +2 -0
- package/dist/components/AvatarRotator/AvatarRotator.d.ts +65 -0
- package/dist/components/AvatarRotator/index.d.ts +2 -0
- package/dist/components/Box/Box.d.ts +87 -0
- package/dist/components/Box/index.d.ts +2 -0
- package/dist/components/Clamp/Clamp.d.ts +61 -0
- package/dist/components/Clamp/index.d.ts +2 -0
- package/dist/components/CoachMark/CoachMark.d.ts +92 -0
- package/dist/components/CoachMark/CoachMarkTour.d.ts +54 -0
- package/dist/components/CoachMark/coachMarkUtils.d.ts +42 -0
- package/dist/components/CoachMark/index.d.ts +5 -0
- package/dist/components/InlineViewSwitcher/InlineViewSwitcher.d.ts +93 -0
- package/dist/components/InlineViewSwitcher/InlineViewSwitcherItem.d.ts +25 -0
- package/dist/components/InlineViewSwitcher/index.d.ts +4 -0
- package/dist/components/InlineViewSwitcher/variants.d.ts +30 -0
- package/dist/components/PreferencesGroup/PreferencesGroup.d.ts +52 -0
- package/dist/components/PreferencesGroup/index.d.ts +2 -0
- package/dist/components/StatusPage/StatusPage.d.ts +79 -0
- package/dist/components/StatusPage/index.d.ts +2 -0
- package/dist/components/ToggleGroup/ToggleGroup.d.ts +70 -0
- package/dist/components/ToggleGroup/ToggleGroupItem.d.ts +49 -0
- package/dist/components/ToggleGroup/index.d.ts +4 -0
- package/dist/components/WrapBox/WrapBox.d.ts +67 -0
- package/dist/components/WrapBox/index.d.ts +2 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +10 -0
- package/dist/index.js +1487 -393
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Children as e, Fragment as t, cloneElement as n, createContext as r, forwardRef as i, isValidElement as a, useCallback as o, useContext as s, useEffect as c, useImperativeHandle as l, useMemo as u, useRef as d, useState as f } from "react";
|
|
2
2
|
import { AccessibilityInfo as p, Animated as m, BackHandler as h, Dimensions as g, Easing as _, I18nManager as v, Image as y, Linking as b, Modal as x, PanResponder as S, Platform as C, Pressable as w, ScrollView as T, StyleSheet as E, Text as D, TextInput as O, View as k, useColorScheme as A } from "react-native";
|
|
3
3
|
import { Fragment as j, jsx as M, jsxs as N } from "react/jsx-runtime";
|
|
4
|
-
import { ApplicationXExecutable as P, AudioXGeneric as F, Check as I, Close as L, Connecting as R, Document as z, Downloading as
|
|
5
|
-
import { Circle as
|
|
4
|
+
import { ApplicationXExecutable as P, AudioXGeneric as F, Check as I, Close as L, Connecting as R, Document as z, Downloading as B, Folder as V, FontXGeneric as H, ImageXGeneric as ee, PackageXGeneric as te, PanDown as ne, PanEnd as re, Recording as U, Syncing as W, TextXGeneric as ie, VideoXGeneric as ae, XOfficeDocument as oe, XOfficePresentation as se, XOfficeSpreadsheet as ce } from "@gnome-ui/icons";
|
|
5
|
+
import { Circle as le, G as ue, Path as de, Svg as fe, SvgXml as pe } from "react-native-svg";
|
|
6
6
|
//#region src/theme/tokens.generated.ts
|
|
7
|
-
var
|
|
7
|
+
var me = {
|
|
8
8
|
accentBgColor: "#3584e4",
|
|
9
9
|
accentColor: "#3584e4",
|
|
10
10
|
accentFgColor: "#fff",
|
|
@@ -145,7 +145,7 @@ var ve = {
|
|
|
145
145
|
yellow3: "#f6d32d",
|
|
146
146
|
yellow4: "#f5c211",
|
|
147
147
|
yellow5: "#e5a50a"
|
|
148
|
-
},
|
|
148
|
+
}, he = {
|
|
149
149
|
accentBgColor: "#3584e4",
|
|
150
150
|
accentColor: "#62a0ea",
|
|
151
151
|
accentFgColor: "#fff",
|
|
@@ -286,7 +286,7 @@ var ve = {
|
|
|
286
286
|
yellow3: "#f6d32d",
|
|
287
287
|
yellow4: "#f5c211",
|
|
288
288
|
yellow5: "#e5a50a"
|
|
289
|
-
},
|
|
289
|
+
}, ge = {
|
|
290
290
|
accentBgColor: "#1a5fb4",
|
|
291
291
|
accentColor: "#1a5fb4",
|
|
292
292
|
accentFgColor: "#fff",
|
|
@@ -427,7 +427,7 @@ var ve = {
|
|
|
427
427
|
yellow3: "#f6d32d",
|
|
428
428
|
yellow4: "#f5c211",
|
|
429
429
|
yellow5: "#e5a50a"
|
|
430
|
-
},
|
|
430
|
+
}, _e = {
|
|
431
431
|
accentBgColor: "#62a0ea",
|
|
432
432
|
accentColor: "#99c1f1",
|
|
433
433
|
accentFgColor: "#fff",
|
|
@@ -568,7 +568,7 @@ var ve = {
|
|
|
568
568
|
yellow3: "#f6d32d",
|
|
569
569
|
yellow4: "#f5c211",
|
|
570
570
|
yellow5: "#e5a50a"
|
|
571
|
-
},
|
|
571
|
+
}, ve = {
|
|
572
572
|
"--gnome-accent-bg-color": "#3584e4",
|
|
573
573
|
"--gnome-accent-color": "#3584e4",
|
|
574
574
|
"--gnome-accent-fg-color": "#fff",
|
|
@@ -709,7 +709,7 @@ var ve = {
|
|
|
709
709
|
"--gnome-yellow-3": "#f6d32d",
|
|
710
710
|
"--gnome-yellow-4": "#f5c211",
|
|
711
711
|
"--gnome-yellow-5": "#e5a50a"
|
|
712
|
-
},
|
|
712
|
+
}, ye = {
|
|
713
713
|
"--gnome-accent-bg-color": "#3584e4",
|
|
714
714
|
"--gnome-accent-color": "#62a0ea",
|
|
715
715
|
"--gnome-accent-fg-color": "#fff",
|
|
@@ -850,7 +850,7 @@ var ve = {
|
|
|
850
850
|
"--gnome-yellow-3": "#f6d32d",
|
|
851
851
|
"--gnome-yellow-4": "#f5c211",
|
|
852
852
|
"--gnome-yellow-5": "#e5a50a"
|
|
853
|
-
},
|
|
853
|
+
}, be = {
|
|
854
854
|
"--gnome-accent-bg-color": "#1a5fb4",
|
|
855
855
|
"--gnome-accent-color": "#1a5fb4",
|
|
856
856
|
"--gnome-accent-fg-color": "#fff",
|
|
@@ -991,7 +991,7 @@ var ve = {
|
|
|
991
991
|
"--gnome-yellow-3": "#f6d32d",
|
|
992
992
|
"--gnome-yellow-4": "#f5c211",
|
|
993
993
|
"--gnome-yellow-5": "#e5a50a"
|
|
994
|
-
},
|
|
994
|
+
}, xe = {
|
|
995
995
|
"--gnome-accent-bg-color": "#62a0ea",
|
|
996
996
|
"--gnome-accent-color": "#99c1f1",
|
|
997
997
|
"--gnome-accent-fg-color": "#fff",
|
|
@@ -1132,7 +1132,7 @@ var ve = {
|
|
|
1132
1132
|
"--gnome-yellow-3": "#f6d32d",
|
|
1133
1133
|
"--gnome-yellow-4": "#f5c211",
|
|
1134
1134
|
"--gnome-yellow-5": "#e5a50a"
|
|
1135
|
-
},
|
|
1135
|
+
}, G = r({
|
|
1136
1136
|
locale: void 0,
|
|
1137
1137
|
dir: "ltr",
|
|
1138
1138
|
numberFormat: void 0,
|
|
@@ -1142,16 +1142,16 @@ var ve = {
|
|
|
1142
1142
|
contrast: "system",
|
|
1143
1143
|
resolvedContrast: "normal",
|
|
1144
1144
|
accentColor: "blue",
|
|
1145
|
-
theme:
|
|
1145
|
+
theme: me
|
|
1146
1146
|
});
|
|
1147
|
-
function
|
|
1148
|
-
return s(
|
|
1147
|
+
function Se() {
|
|
1148
|
+
return s(G).locale;
|
|
1149
1149
|
}
|
|
1150
|
-
function
|
|
1151
|
-
return s(
|
|
1150
|
+
function Ce() {
|
|
1151
|
+
return s(G).dir;
|
|
1152
1152
|
}
|
|
1153
|
-
function
|
|
1154
|
-
let { locale: t, numberFormat: n } = s(
|
|
1153
|
+
function we(e) {
|
|
1154
|
+
let { locale: t, numberFormat: n } = s(G);
|
|
1155
1155
|
return u(() => new Intl.NumberFormat(t, {
|
|
1156
1156
|
...n,
|
|
1157
1157
|
...e
|
|
@@ -1161,8 +1161,8 @@ function Oe(e) {
|
|
|
1161
1161
|
e
|
|
1162
1162
|
]);
|
|
1163
1163
|
}
|
|
1164
|
-
function
|
|
1165
|
-
let { locale: t, dateTimeFormat: n } = s(
|
|
1164
|
+
function Te(e) {
|
|
1165
|
+
let { locale: t, dateTimeFormat: n } = s(G);
|
|
1166
1166
|
return u(() => new Intl.DateTimeFormat(t, {
|
|
1167
1167
|
...n,
|
|
1168
1168
|
...e
|
|
@@ -1172,32 +1172,32 @@ function ke(e) {
|
|
|
1172
1172
|
e
|
|
1173
1173
|
]);
|
|
1174
1174
|
}
|
|
1175
|
-
function
|
|
1176
|
-
return s(
|
|
1175
|
+
function Ee() {
|
|
1176
|
+
return s(G).colorScheme;
|
|
1177
1177
|
}
|
|
1178
|
-
function
|
|
1179
|
-
return s(
|
|
1178
|
+
function K() {
|
|
1179
|
+
return s(G).resolvedColorScheme;
|
|
1180
1180
|
}
|
|
1181
|
-
function
|
|
1182
|
-
return s(
|
|
1181
|
+
function De() {
|
|
1182
|
+
return s(G).contrast;
|
|
1183
1183
|
}
|
|
1184
|
-
function
|
|
1185
|
-
return s(
|
|
1184
|
+
function Oe() {
|
|
1185
|
+
return s(G).resolvedContrast;
|
|
1186
1186
|
}
|
|
1187
|
-
function
|
|
1188
|
-
return s(
|
|
1187
|
+
function ke() {
|
|
1188
|
+
return s(G).accentColor;
|
|
1189
1189
|
}
|
|
1190
|
-
function
|
|
1191
|
-
return s(
|
|
1190
|
+
function q() {
|
|
1191
|
+
return s(G).theme;
|
|
1192
1192
|
}
|
|
1193
1193
|
//#endregion
|
|
1194
1194
|
//#region src/theme/resolveTheme.ts
|
|
1195
|
-
function
|
|
1196
|
-
return t === "more" ? e === "dark" ?
|
|
1195
|
+
function Ae({ colorScheme: e, contrast: t = "normal" }) {
|
|
1196
|
+
return t === "more" ? e === "dark" ? _e : ge : e === "dark" ? he : me;
|
|
1197
1197
|
}
|
|
1198
1198
|
//#endregion
|
|
1199
1199
|
//#region src/GnomeProvider/resolveContext.ts
|
|
1200
|
-
var
|
|
1200
|
+
var je = new Set([
|
|
1201
1201
|
"blue",
|
|
1202
1202
|
"green",
|
|
1203
1203
|
"yellow",
|
|
@@ -1206,15 +1206,15 @@ var Pe = new Set([
|
|
|
1206
1206
|
"purple",
|
|
1207
1207
|
"brown"
|
|
1208
1208
|
]);
|
|
1209
|
-
function
|
|
1209
|
+
function Me(e, t) {
|
|
1210
1210
|
return e === "system" ? t === "dark" ? "dark" : "light" : e;
|
|
1211
1211
|
}
|
|
1212
|
-
function
|
|
1212
|
+
function Ne(e, t) {
|
|
1213
1213
|
return e === "system" ? t ? "more" : "normal" : e;
|
|
1214
1214
|
}
|
|
1215
|
-
function
|
|
1215
|
+
function Pe(e, t, n, r) {
|
|
1216
1216
|
if (t === "blue") return e;
|
|
1217
|
-
let i =
|
|
1217
|
+
let i = je.has(t), a = i ? e[`${t}${n === "dark" ? 2 : 3}`] : t, o = i ? e[`${t}3`] : t;
|
|
1218
1218
|
return {
|
|
1219
1219
|
...e,
|
|
1220
1220
|
accentColor: a,
|
|
@@ -1224,7 +1224,7 @@ function Le(e, t, n, r) {
|
|
|
1224
1224
|
}
|
|
1225
1225
|
//#endregion
|
|
1226
1226
|
//#region src/GnomeProvider/GnomeProvider.tsx
|
|
1227
|
-
function
|
|
1227
|
+
function Fe() {
|
|
1228
1228
|
let [e, t] = f(!1);
|
|
1229
1229
|
return c(() => {
|
|
1230
1230
|
let e = C.OS === "android" ? p.isHighTextContrastEnabled : C.OS === "ios" ? p.isDarkerSystemColorsEnabled : void 0;
|
|
@@ -1240,7 +1240,7 @@ function Re() {
|
|
|
1240
1240
|
};
|
|
1241
1241
|
}, []), e;
|
|
1242
1242
|
}
|
|
1243
|
-
function
|
|
1243
|
+
function J() {
|
|
1244
1244
|
let [e, t] = f(!1);
|
|
1245
1245
|
return c(() => {
|
|
1246
1246
|
let e = !0;
|
|
@@ -1254,8 +1254,8 @@ function G() {
|
|
|
1254
1254
|
};
|
|
1255
1255
|
}, []), e;
|
|
1256
1256
|
}
|
|
1257
|
-
var
|
|
1258
|
-
let c = A(), l =
|
|
1257
|
+
var Ie = ({ locale: e, dir: t, numberFormat: n, dateTimeFormat: r, colorScheme: i = "system", contrast: a = "system", accentColor: o = "blue", children: s }) => {
|
|
1258
|
+
let c = A(), l = Fe(), d = Me(i, c), f = Ne(a, l), p = t ?? (v.isRTL ? "rtl" : "ltr"), m = u(() => ({
|
|
1259
1259
|
locale: e,
|
|
1260
1260
|
dir: p,
|
|
1261
1261
|
numberFormat: n,
|
|
@@ -1265,7 +1265,7 @@ var ze = ({ locale: e, dir: t, numberFormat: n, dateTimeFormat: r, colorScheme:
|
|
|
1265
1265
|
contrast: a,
|
|
1266
1266
|
resolvedContrast: f,
|
|
1267
1267
|
accentColor: o,
|
|
1268
|
-
theme:
|
|
1268
|
+
theme: Pe(Ae({
|
|
1269
1269
|
colorScheme: d,
|
|
1270
1270
|
contrast: f
|
|
1271
1271
|
}), o, d, f)
|
|
@@ -1280,11 +1280,11 @@ var ze = ({ locale: e, dir: t, numberFormat: n, dateTimeFormat: r, colorScheme:
|
|
|
1280
1280
|
f,
|
|
1281
1281
|
o
|
|
1282
1282
|
]);
|
|
1283
|
-
return /* @__PURE__ */ M(
|
|
1283
|
+
return /* @__PURE__ */ M(G.Provider, {
|
|
1284
1284
|
value: m,
|
|
1285
1285
|
children: s
|
|
1286
1286
|
});
|
|
1287
|
-
},
|
|
1287
|
+
}, Le = new Set([
|
|
1288
1288
|
"large-title",
|
|
1289
1289
|
"title-1",
|
|
1290
1290
|
"title-2",
|
|
@@ -1292,7 +1292,7 @@ var ze = ({ locale: e, dir: t, numberFormat: n, dateTimeFormat: r, colorScheme:
|
|
|
1292
1292
|
"title-4",
|
|
1293
1293
|
"heading"
|
|
1294
1294
|
]);
|
|
1295
|
-
function
|
|
1295
|
+
function Re(e, t) {
|
|
1296
1296
|
let n = (e) => String(e);
|
|
1297
1297
|
switch (t) {
|
|
1298
1298
|
case "large-title": return {
|
|
@@ -1361,7 +1361,7 @@ function Ve(e, t) {
|
|
|
1361
1361
|
};
|
|
1362
1362
|
}
|
|
1363
1363
|
}
|
|
1364
|
-
function
|
|
1364
|
+
function ze(e, t) {
|
|
1365
1365
|
switch (t) {
|
|
1366
1366
|
case "dim": return {
|
|
1367
1367
|
color: e.windowFgColor,
|
|
@@ -1375,22 +1375,22 @@ function He(e, t) {
|
|
|
1375
1375
|
default: return { color: e.windowFgColor };
|
|
1376
1376
|
}
|
|
1377
1377
|
}
|
|
1378
|
-
var
|
|
1379
|
-
let s =
|
|
1378
|
+
var Y = i(function({ variant: e = "body", color: t = "default", style: n, children: r, accessibilityRole: i, ...a }, o) {
|
|
1379
|
+
let s = q();
|
|
1380
1380
|
return /* @__PURE__ */ M(D, {
|
|
1381
1381
|
ref: o,
|
|
1382
|
-
accessibilityRole: i ?? (
|
|
1382
|
+
accessibilityRole: i ?? (Le.has(e) ? "header" : void 0),
|
|
1383
1383
|
style: [
|
|
1384
1384
|
{ fontFamily: s.fontFamily },
|
|
1385
|
-
|
|
1386
|
-
|
|
1385
|
+
Re(s, e),
|
|
1386
|
+
ze(s, t),
|
|
1387
1387
|
n
|
|
1388
1388
|
],
|
|
1389
1389
|
...a,
|
|
1390
1390
|
children: r
|
|
1391
1391
|
});
|
|
1392
|
-
}),
|
|
1393
|
-
let u =
|
|
1392
|
+
}), Be = i(function({ title: e, subtitle: t, leading: n, trailing: r, interactive: i = !1, variant: a = "default", style: o, disabled: s, ...c }, l) {
|
|
1393
|
+
let u = q(), d = a === "property", f = {
|
|
1394
1394
|
flexDirection: "row",
|
|
1395
1395
|
alignItems: "center",
|
|
1396
1396
|
gap: u.space2,
|
|
@@ -1408,13 +1408,13 @@ var K = i(function({ variant: e = "body", color: t = "default", style: n, childr
|
|
|
1408
1408
|
flex: 1,
|
|
1409
1409
|
gap: 2
|
|
1410
1410
|
},
|
|
1411
|
-
children: [/* @__PURE__ */ M(
|
|
1411
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
1412
1412
|
variant: d ? "caption" : "body",
|
|
1413
1413
|
color: d ? "dim" : "default",
|
|
1414
1414
|
numberOfLines: 1,
|
|
1415
1415
|
ellipsizeMode: "tail",
|
|
1416
1416
|
children: e
|
|
1417
|
-
}), t && /* @__PURE__ */ M(
|
|
1417
|
+
}), t && /* @__PURE__ */ M(Y, {
|
|
1418
1418
|
variant: d ? "body" : "caption",
|
|
1419
1419
|
color: d ? "default" : "dim",
|
|
1420
1420
|
numberOfLines: 1,
|
|
@@ -1456,12 +1456,12 @@ var K = i(function({ variant: e = "body", color: t = "default", style: n, childr
|
|
|
1456
1456
|
...c,
|
|
1457
1457
|
children: p
|
|
1458
1458
|
});
|
|
1459
|
-
}),
|
|
1459
|
+
}), Ve = {
|
|
1460
1460
|
sm: 12,
|
|
1461
1461
|
md: 16,
|
|
1462
1462
|
lg: 20
|
|
1463
1463
|
};
|
|
1464
|
-
function
|
|
1464
|
+
function He(e, t) {
|
|
1465
1465
|
switch (t) {
|
|
1466
1466
|
case "blue": return e.blue3;
|
|
1467
1467
|
case "green": return e.green4;
|
|
@@ -1473,7 +1473,7 @@ function Ge(e, t) {
|
|
|
1473
1473
|
default: return e.windowFgColor;
|
|
1474
1474
|
}
|
|
1475
1475
|
}
|
|
1476
|
-
function
|
|
1476
|
+
function Ue(e) {
|
|
1477
1477
|
return e ? {
|
|
1478
1478
|
accessible: !0,
|
|
1479
1479
|
accessibilityLabel: e,
|
|
@@ -1485,27 +1485,27 @@ function Ke(e) {
|
|
|
1485
1485
|
}
|
|
1486
1486
|
//#endregion
|
|
1487
1487
|
//#region src/components/Icon/Icon.tsx
|
|
1488
|
-
function
|
|
1488
|
+
function We(e) {
|
|
1489
1489
|
return "paths" in e && Array.isArray(e.paths) ? !0 : typeof e.svg == "string" && !("path" in e);
|
|
1490
1490
|
}
|
|
1491
|
-
function
|
|
1491
|
+
function Ge(e) {
|
|
1492
1492
|
return e === "nonzero" || e === "evenodd" ? e : void 0;
|
|
1493
1493
|
}
|
|
1494
|
-
var
|
|
1495
|
-
let s =
|
|
1494
|
+
var X = ({ icon: e, size: t = "md", width: n, height: r, label: i, color: a, style: o }) => {
|
|
1495
|
+
let s = q(), c = Ve[t], l = He(s, a), u = We(e) ? e.viewBox : e.viewBox ?? "0 0 24 24", d = We(e) ? e.svg : void 0, f = We(e) ? e.svg ? void 0 : e.paths?.map((e, t) => /* @__PURE__ */ M(de, {
|
|
1496
1496
|
d: e.d,
|
|
1497
|
-
fillRule:
|
|
1498
|
-
clipRule:
|
|
1497
|
+
fillRule: Ge(e.fillRule),
|
|
1498
|
+
clipRule: Ge(e.clipRule),
|
|
1499
1499
|
transform: e.transform
|
|
1500
|
-
}, t)) : [/* @__PURE__ */ M(
|
|
1501
|
-
return d ? /* @__PURE__ */ M(
|
|
1500
|
+
}, t)) : [/* @__PURE__ */ M(de, { d: e.path }, 0)], p = Ue(i);
|
|
1501
|
+
return d ? /* @__PURE__ */ M(pe, {
|
|
1502
1502
|
xml: `<svg viewBox="${u}">${d}</svg>`,
|
|
1503
1503
|
width: n ?? c,
|
|
1504
1504
|
height: r ?? c,
|
|
1505
1505
|
fill: l,
|
|
1506
1506
|
style: o,
|
|
1507
1507
|
...p
|
|
1508
|
-
}) : /* @__PURE__ */ M(
|
|
1508
|
+
}) : /* @__PURE__ */ M(fe, {
|
|
1509
1509
|
viewBox: u,
|
|
1510
1510
|
width: n ?? c,
|
|
1511
1511
|
height: r ?? c,
|
|
@@ -1514,8 +1514,8 @@ var q = ({ icon: e, size: t = "md", width: n, height: r, label: i, color: a, sty
|
|
|
1514
1514
|
...p,
|
|
1515
1515
|
children: f
|
|
1516
1516
|
});
|
|
1517
|
-
},
|
|
1518
|
-
function
|
|
1517
|
+
}, Ke = m.createAnimatedComponent(ue), qe = m.createAnimatedComponent(de), Je = m.createAnimatedComponent(le);
|
|
1518
|
+
function Ye(e) {
|
|
1519
1519
|
let t = d(new m.Value(0)).current;
|
|
1520
1520
|
return c(() => {
|
|
1521
1521
|
let n = m.loop(m.timing(t, {
|
|
@@ -1527,7 +1527,7 @@ function Qe(e) {
|
|
|
1527
1527
|
return n.start(), () => n.stop();
|
|
1528
1528
|
}, [t, e]), t;
|
|
1529
1529
|
}
|
|
1530
|
-
function
|
|
1530
|
+
function Xe(e, t) {
|
|
1531
1531
|
let n = d(new m.Value(0)).current;
|
|
1532
1532
|
return c(() => {
|
|
1533
1533
|
let r = m.sequence([m.delay(t), m.loop(m.timing(n, {
|
|
@@ -1543,17 +1543,17 @@ function $e(e, t) {
|
|
|
1543
1543
|
t
|
|
1544
1544
|
]), n;
|
|
1545
1545
|
}
|
|
1546
|
-
var
|
|
1547
|
-
transform:
|
|
1546
|
+
var Ze = ({ fill: e }) => /* @__PURE__ */ M(Ke, {
|
|
1547
|
+
transform: Ye(1500).interpolate({
|
|
1548
1548
|
inputRange: [0, 1],
|
|
1549
1549
|
outputRange: ["rotate(0, 8, 8)", "rotate(360, 8, 8)"]
|
|
1550
1550
|
}),
|
|
1551
|
-
children: /* @__PURE__ */ M(
|
|
1551
|
+
children: /* @__PURE__ */ M(de, {
|
|
1552
1552
|
fill: e,
|
|
1553
1553
|
fillRule: "evenodd",
|
|
1554
1554
|
d: "M8 2a6 6 0 0 0-6 6h2a4 4 0 0 1 4-4 4 4 0 0 1 4 4 4 4 0 0 1-4 4v-2L5 13l3 3v-2a6 6 0 0 0 6-6 6 6 0 0 0-6-6z"
|
|
1555
1555
|
})
|
|
1556
|
-
}),
|
|
1556
|
+
}), Qe = ({ fill: e }) => {
|
|
1557
1557
|
let t = d(new m.Value(1)).current;
|
|
1558
1558
|
return c(() => {
|
|
1559
1559
|
let e = _.inOut(_.ease), n = m.loop(m.sequence([m.timing(t, {
|
|
@@ -1568,13 +1568,13 @@ var et = ({ fill: e }) => /* @__PURE__ */ M(Ye, {
|
|
|
1568
1568
|
useNativeDriver: !1
|
|
1569
1569
|
})]));
|
|
1570
1570
|
return n.start(), () => n.stop();
|
|
1571
|
-
}, [t]), /* @__PURE__ */ M(
|
|
1571
|
+
}, [t]), /* @__PURE__ */ M(qe, {
|
|
1572
1572
|
fill: e,
|
|
1573
1573
|
opacity: t,
|
|
1574
1574
|
d: "m 15 8 c 0 3.867188 -3.132812 7 -7 7 s -7 -3.132812 -7 -7 s 3.132812 -7 7 -7 s 7 3.132812 7 7 z m 0 0"
|
|
1575
1575
|
});
|
|
1576
|
-
},
|
|
1577
|
-
let t =
|
|
1576
|
+
}, $e = ({ fill: e }) => {
|
|
1577
|
+
let t = Ye(1400), n = [
|
|
1578
1578
|
0,
|
|
1579
1579
|
.2,
|
|
1580
1580
|
.5,
|
|
@@ -1602,30 +1602,30 @@ var et = ({ fill: e }) => /* @__PURE__ */ M(Ye, {
|
|
|
1602
1602
|
1
|
|
1603
1603
|
]
|
|
1604
1604
|
});
|
|
1605
|
-
return /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M(
|
|
1605
|
+
return /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M(de, {
|
|
1606
1606
|
fill: e,
|
|
1607
1607
|
d: "M2 13h12v2H2z"
|
|
1608
|
-
}), /* @__PURE__ */ M(
|
|
1608
|
+
}), /* @__PURE__ */ M(Ke, {
|
|
1609
1609
|
transform: r,
|
|
1610
1610
|
opacity: i,
|
|
1611
|
-
children: /* @__PURE__ */ M(
|
|
1611
|
+
children: /* @__PURE__ */ M(de, {
|
|
1612
1612
|
fill: e,
|
|
1613
1613
|
fillRule: "evenodd",
|
|
1614
1614
|
d: "m2.5 5 5.5 6 5.5-6z"
|
|
1615
1615
|
})
|
|
1616
1616
|
})] });
|
|
1617
1617
|
};
|
|
1618
|
-
function
|
|
1618
|
+
function et(e, t, n) {
|
|
1619
1619
|
return `translate(${e}, ${t}) scale(${n}) translate(${-e}, ${-t})`;
|
|
1620
1620
|
}
|
|
1621
|
-
var
|
|
1622
|
-
let i =
|
|
1621
|
+
var tt = ({ cx: e, cy: t, fill: n, delay: r }) => {
|
|
1622
|
+
let i = Xe(1200, r), a = [
|
|
1623
1623
|
0,
|
|
1624
1624
|
.2,
|
|
1625
1625
|
.4,
|
|
1626
1626
|
1
|
|
1627
1627
|
];
|
|
1628
|
-
return /* @__PURE__ */ M(
|
|
1628
|
+
return /* @__PURE__ */ M(Je, {
|
|
1629
1629
|
cx: e,
|
|
1630
1630
|
cy: t,
|
|
1631
1631
|
r: 2,
|
|
@@ -1642,44 +1642,44 @@ var rt = ({ cx: e, cy: t, fill: n, delay: r }) => {
|
|
|
1642
1642
|
transform: i.interpolate({
|
|
1643
1643
|
inputRange: a,
|
|
1644
1644
|
outputRange: [
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1645
|
+
et(e, t, 1),
|
|
1646
|
+
et(e, t, .7),
|
|
1647
|
+
et(e, t, 1),
|
|
1648
|
+
et(e, t, 1)
|
|
1649
1649
|
]
|
|
1650
1650
|
})
|
|
1651
1651
|
});
|
|
1652
|
-
},
|
|
1653
|
-
[
|
|
1654
|
-
[
|
|
1655
|
-
[
|
|
1652
|
+
}, nt = new Map([
|
|
1653
|
+
[W, Ze],
|
|
1654
|
+
[U, Qe],
|
|
1655
|
+
[B, $e],
|
|
1656
1656
|
[R, ({ fill: e }) => /* @__PURE__ */ N(j, { children: [
|
|
1657
|
-
/* @__PURE__ */ M(
|
|
1657
|
+
/* @__PURE__ */ M(de, {
|
|
1658
1658
|
fill: e,
|
|
1659
1659
|
d: "m 8 1.992188 c -2.617188 0 -5.238281 0.933593 -7.195312 2.808593 l -0.496094 0.480469 c -0.3984378 0.378906 -0.410156 1.011719 -0.03125 1.410156 c 0.003906 0.007813 0.011718 0.011719 0.019531 0.015625 c 0.480469 -1.011719 1.503906 -1.707031 2.703125 -1.707031 h 0.9375 c 2.480469 -1.292969 5.644531 -1.292969 8.125 0 h 0.9375 c 1.199219 0 2.222656 0.695312 2.707031 1.707031 c 0.003907 -0.007812 0.011719 -0.011719 0.015625 -0.015625 c 0.378906 -0.398437 0.367188 -1.03125 -0.03125 -1.410156 l -0.496094 -0.480469 c -1.957031 -1.875 -4.578124 -2.808593 -7.195312 -2.808593 z m -1.730469 9.007812 c -0.441406 0.765625 -0.339843 1.757812 0.316407 2.414062 c 0.78125 0.78125 2.046874 0.78125 2.828124 0 c 0.65625 -0.65625 0.757813 -1.648437 0.316407 -2.414062 z m 0 0"
|
|
1660
1660
|
}),
|
|
1661
|
-
/* @__PURE__ */ M(
|
|
1661
|
+
/* @__PURE__ */ M(tt, {
|
|
1662
1662
|
cx: 3,
|
|
1663
1663
|
cy: 8,
|
|
1664
1664
|
fill: e,
|
|
1665
1665
|
delay: 0
|
|
1666
1666
|
}),
|
|
1667
|
-
/* @__PURE__ */ M(
|
|
1667
|
+
/* @__PURE__ */ M(tt, {
|
|
1668
1668
|
cx: 8,
|
|
1669
1669
|
cy: 8,
|
|
1670
1670
|
fill: e,
|
|
1671
1671
|
delay: 150
|
|
1672
1672
|
}),
|
|
1673
|
-
/* @__PURE__ */ M(
|
|
1673
|
+
/* @__PURE__ */ M(tt, {
|
|
1674
1674
|
cx: 13,
|
|
1675
1675
|
cy: 8,
|
|
1676
1676
|
fill: e,
|
|
1677
1677
|
delay: 300
|
|
1678
1678
|
})
|
|
1679
1679
|
] })]
|
|
1680
|
-
]),
|
|
1681
|
-
let s =
|
|
1682
|
-
if (!l) return /* @__PURE__ */ M(
|
|
1680
|
+
]), rt = ({ icon: e, playing: t = !0, size: n = "md", width: r, height: i, label: a, color: o }) => {
|
|
1681
|
+
let s = q(), c = J(), l = t && !c ? nt.get(e) : void 0;
|
|
1682
|
+
if (!l) return /* @__PURE__ */ M(X, {
|
|
1683
1683
|
icon: e,
|
|
1684
1684
|
size: n,
|
|
1685
1685
|
width: r,
|
|
@@ -1687,15 +1687,15 @@ var rt = ({ cx: e, cy: t, fill: n, delay: r }) => {
|
|
|
1687
1687
|
label: a,
|
|
1688
1688
|
color: o
|
|
1689
1689
|
});
|
|
1690
|
-
let u =
|
|
1691
|
-
return /* @__PURE__ */ M(
|
|
1690
|
+
let u = Ve[n], d = He(s, o), f = Ue(a);
|
|
1691
|
+
return /* @__PURE__ */ M(fe, {
|
|
1692
1692
|
viewBox: e.viewBox,
|
|
1693
1693
|
width: r ?? u,
|
|
1694
1694
|
height: i ?? u,
|
|
1695
1695
|
...f,
|
|
1696
1696
|
children: /* @__PURE__ */ M(l, { fill: d })
|
|
1697
1697
|
});
|
|
1698
|
-
},
|
|
1698
|
+
}, it = [
|
|
1699
1699
|
"blue",
|
|
1700
1700
|
"green",
|
|
1701
1701
|
"yellow",
|
|
@@ -1705,27 +1705,27 @@ var rt = ({ cx: e, cy: t, fill: n, delay: r }) => {
|
|
|
1705
1705
|
"brown",
|
|
1706
1706
|
"teal",
|
|
1707
1707
|
"slate"
|
|
1708
|
-
],
|
|
1708
|
+
], at = {
|
|
1709
1709
|
sm: 24,
|
|
1710
1710
|
md: 32,
|
|
1711
1711
|
lg: 48,
|
|
1712
1712
|
xl: 64
|
|
1713
|
-
},
|
|
1713
|
+
}, ot = {
|
|
1714
1714
|
sm: .5,
|
|
1715
1715
|
md: .6,
|
|
1716
1716
|
lg: 1,
|
|
1717
1717
|
xl: 1.4
|
|
1718
1718
|
};
|
|
1719
|
-
function
|
|
1719
|
+
function st(e) {
|
|
1720
1720
|
let t = 0;
|
|
1721
1721
|
for (let n = 0; n < e.length; n++) t = t * 31 + e.charCodeAt(n) >>> 0;
|
|
1722
|
-
return
|
|
1722
|
+
return it[t % it.length];
|
|
1723
1723
|
}
|
|
1724
|
-
function
|
|
1724
|
+
function ct(e) {
|
|
1725
1725
|
let t = e.trim().split(/\s+/).filter(Boolean);
|
|
1726
1726
|
return t.length === 0 ? "" : t.length === 1 ? t[0].charAt(0).toUpperCase() : t[0].charAt(0).toUpperCase() + t[t.length - 1].charAt(0).toUpperCase();
|
|
1727
1727
|
}
|
|
1728
|
-
function
|
|
1728
|
+
function lt(e, t) {
|
|
1729
1729
|
switch (t) {
|
|
1730
1730
|
case "blue": return {
|
|
1731
1731
|
backgroundColor: e.blue3,
|
|
@@ -1765,8 +1765,8 @@ function dt(e, t) {
|
|
|
1765
1765
|
};
|
|
1766
1766
|
}
|
|
1767
1767
|
}
|
|
1768
|
-
var
|
|
1769
|
-
let o =
|
|
1768
|
+
var ut = ({ name: e = "", src: t, alt: n, size: r = "md", color: i, style: a }) => {
|
|
1769
|
+
let o = q(), s = K(), c = i ?? (e ? st(e) : "blue"), l = ct(e), u = at[r], { backgroundColor: d, initialsColor: f } = lt(o, c), p = s === "dark" ? "rgba(255, 255, 255, 0.08)" : "rgba(0, 0, 0, 0.08)";
|
|
1770
1770
|
return /* @__PURE__ */ M(k, {
|
|
1771
1771
|
accessible: !0,
|
|
1772
1772
|
role: "img",
|
|
@@ -1798,17 +1798,164 @@ var ft = ({ name: e = "", src: t, alt: n, size: r = "md", color: i, style: a })
|
|
|
1798
1798
|
style: {
|
|
1799
1799
|
fontFamily: o.fontFamily,
|
|
1800
1800
|
fontWeight: String(o.fontWeightSemibold),
|
|
1801
|
-
fontSize: o.fontSizeBody *
|
|
1802
|
-
lineHeight: o.fontSizeBody *
|
|
1801
|
+
fontSize: o.fontSizeBody * ot[r],
|
|
1802
|
+
lineHeight: o.fontSizeBody * ot[r],
|
|
1803
1803
|
color: f
|
|
1804
1804
|
},
|
|
1805
1805
|
children: l
|
|
1806
1806
|
})
|
|
1807
1807
|
});
|
|
1808
|
+
}, dt = {
|
|
1809
|
+
sm: 6,
|
|
1810
|
+
md: 8,
|
|
1811
|
+
lg: 12,
|
|
1812
|
+
xl: 16
|
|
1813
|
+
}, ft = {
|
|
1814
|
+
sm: 24,
|
|
1815
|
+
md: 32,
|
|
1816
|
+
lg: 48,
|
|
1817
|
+
xl: 64
|
|
1818
|
+
}, pt = {
|
|
1819
|
+
sm: 8,
|
|
1820
|
+
md: 9.6,
|
|
1821
|
+
lg: 14,
|
|
1822
|
+
xl: 17.6
|
|
1823
|
+
}, mt = ({ avatars: e, max: t = 5, size: n = "md", accessibilityLabel: r, style: i, testID: a }) => {
|
|
1824
|
+
let o = q(), s = e.length > t ? e.slice(0, t) : e, c = e.length > t ? e.length - t : 0, l = e.map((e) => e.name).filter(Boolean).join(", "), u = r ?? (l ? c > 0 ? `${l} and ${c} more` : l : "Avatar group"), d = dt[n];
|
|
1825
|
+
return /* @__PURE__ */ N(k, {
|
|
1826
|
+
testID: a,
|
|
1827
|
+
accessible: !0,
|
|
1828
|
+
role: "group",
|
|
1829
|
+
accessibilityLabel: u,
|
|
1830
|
+
style: [{
|
|
1831
|
+
flexDirection: "row",
|
|
1832
|
+
alignItems: "center"
|
|
1833
|
+
}, i],
|
|
1834
|
+
children: [s.map((e, t) => /* @__PURE__ */ M(ut, {
|
|
1835
|
+
name: e.name,
|
|
1836
|
+
src: e.src,
|
|
1837
|
+
alt: e.alt ?? e.name,
|
|
1838
|
+
color: e.color,
|
|
1839
|
+
size: n,
|
|
1840
|
+
style: {
|
|
1841
|
+
marginStart: t === 0 ? 0 : -d,
|
|
1842
|
+
borderWidth: 2,
|
|
1843
|
+
borderColor: o.windowBgColor
|
|
1844
|
+
}
|
|
1845
|
+
}, `${e.name ?? ""}-${e.src ?? ""}-${t}`)), c > 0 && /* @__PURE__ */ M(k, {
|
|
1846
|
+
accessible: !0,
|
|
1847
|
+
accessibilityLabel: `+${c} more`,
|
|
1848
|
+
style: {
|
|
1849
|
+
width: ft[n],
|
|
1850
|
+
height: ft[n],
|
|
1851
|
+
marginStart: -d,
|
|
1852
|
+
borderRadius: o.radiusPill,
|
|
1853
|
+
borderWidth: 2,
|
|
1854
|
+
borderColor: o.windowBgColor,
|
|
1855
|
+
backgroundColor: o.dark2,
|
|
1856
|
+
alignItems: "center",
|
|
1857
|
+
justifyContent: "center"
|
|
1858
|
+
},
|
|
1859
|
+
children: /* @__PURE__ */ M(D, {
|
|
1860
|
+
accessibilityElementsHidden: !0,
|
|
1861
|
+
importantForAccessibility: "no",
|
|
1862
|
+
style: {
|
|
1863
|
+
fontFamily: o.fontFamily,
|
|
1864
|
+
fontWeight: String(o.fontWeightSemibold),
|
|
1865
|
+
fontSize: pt[n],
|
|
1866
|
+
color: "#fff"
|
|
1867
|
+
},
|
|
1868
|
+
children: `+${c}`
|
|
1869
|
+
})
|
|
1870
|
+
})]
|
|
1871
|
+
});
|
|
1872
|
+
};
|
|
1873
|
+
//#endregion
|
|
1874
|
+
//#region src/components/AvatarRotator/AvatarRotator.tsx
|
|
1875
|
+
function ht(e, t) {
|
|
1876
|
+
return t <= 0 ? 0 : (e % t + t) % t;
|
|
1877
|
+
}
|
|
1878
|
+
var gt = {
|
|
1879
|
+
sm: 24,
|
|
1880
|
+
md: 32,
|
|
1881
|
+
lg: 48,
|
|
1882
|
+
xl: 64
|
|
1883
|
+
}, _t = ({ active: e, duration: t, reducedMotion: n, children: r }) => {
|
|
1884
|
+
let i = d(new m.Value(+!!e)).current;
|
|
1885
|
+
return c(() => {
|
|
1886
|
+
if (n) {
|
|
1887
|
+
i.setValue(+!!e);
|
|
1888
|
+
return;
|
|
1889
|
+
}
|
|
1890
|
+
m.timing(i, {
|
|
1891
|
+
toValue: +!!e,
|
|
1892
|
+
duration: t,
|
|
1893
|
+
useNativeDriver: !0
|
|
1894
|
+
}).start();
|
|
1895
|
+
}, [
|
|
1896
|
+
e,
|
|
1897
|
+
t,
|
|
1898
|
+
n,
|
|
1899
|
+
i
|
|
1900
|
+
]), /* @__PURE__ */ M(m.View, {
|
|
1901
|
+
accessibilityElementsHidden: !0,
|
|
1902
|
+
importantForAccessibility: "no",
|
|
1903
|
+
style: [E.absoluteFill, { opacity: i }],
|
|
1904
|
+
children: r
|
|
1905
|
+
});
|
|
1906
|
+
}, vt = ({ name: e = "", avatars: t = [], alt: n, size: r = "md", color: i, interval: a = 3e3, transitionDuration: o = 240, pauseOnPress: s = !0, activeIndex: l, defaultActiveIndex: u = 0, onIndexChange: d, style: p, testID: m }) => {
|
|
1907
|
+
let h = J(), g = t.map((e) => e.trim()).filter(Boolean), _ = l !== void 0, [v, y] = f(u), [b, x] = f(!1), S = ht(_ ? l : v, g.length);
|
|
1908
|
+
if (c(() => {
|
|
1909
|
+
if (g.length <= 1 || a <= 0 || b || h) return;
|
|
1910
|
+
let e = setInterval(() => {
|
|
1911
|
+
let e = ht(S + 1, g.length);
|
|
1912
|
+
_ || y(e), d?.(e);
|
|
1913
|
+
}, a);
|
|
1914
|
+
return () => clearInterval(e);
|
|
1915
|
+
}, [
|
|
1916
|
+
S,
|
|
1917
|
+
a,
|
|
1918
|
+
_,
|
|
1919
|
+
b,
|
|
1920
|
+
d,
|
|
1921
|
+
h,
|
|
1922
|
+
g.length
|
|
1923
|
+
]), g.length === 0) return /* @__PURE__ */ M(ut, {
|
|
1924
|
+
name: e,
|
|
1925
|
+
alt: n,
|
|
1926
|
+
size: r,
|
|
1927
|
+
color: i,
|
|
1928
|
+
style: p
|
|
1929
|
+
});
|
|
1930
|
+
let C = n ?? (e || void 0) ?? "Avatar", T = gt[r];
|
|
1931
|
+
return /* @__PURE__ */ M(w, {
|
|
1932
|
+
testID: m,
|
|
1933
|
+
accessible: !0,
|
|
1934
|
+
role: "img",
|
|
1935
|
+
accessibilityLabel: C,
|
|
1936
|
+
onPressIn: () => s && x(!0),
|
|
1937
|
+
onPressOut: () => s && x(!1),
|
|
1938
|
+
style: [{
|
|
1939
|
+
width: T,
|
|
1940
|
+
height: T,
|
|
1941
|
+
borderRadius: T / 2,
|
|
1942
|
+
overflow: "hidden"
|
|
1943
|
+
}, p],
|
|
1944
|
+
children: g.map((t, n) => /* @__PURE__ */ M(_t, {
|
|
1945
|
+
active: n === S,
|
|
1946
|
+
duration: Math.max(0, o),
|
|
1947
|
+
reducedMotion: h,
|
|
1948
|
+
children: /* @__PURE__ */ M(ut, {
|
|
1949
|
+
name: e,
|
|
1950
|
+
src: t,
|
|
1951
|
+
size: r
|
|
1952
|
+
})
|
|
1953
|
+
}, `${t}-${n}`))
|
|
1954
|
+
});
|
|
1808
1955
|
};
|
|
1809
1956
|
//#endregion
|
|
1810
1957
|
//#region src/components/Badge/Badge.tsx
|
|
1811
|
-
function
|
|
1958
|
+
function yt(e, t, n) {
|
|
1812
1959
|
switch (n) {
|
|
1813
1960
|
case "accent": return {
|
|
1814
1961
|
backgroundColor: e.accentBgColor,
|
|
@@ -1832,8 +1979,8 @@ function pt(e, t, n) {
|
|
|
1832
1979
|
};
|
|
1833
1980
|
}
|
|
1834
1981
|
}
|
|
1835
|
-
var
|
|
1836
|
-
let a =
|
|
1982
|
+
var bt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i }) => {
|
|
1983
|
+
let a = q(), { backgroundColor: o, color: s } = yt(a, K(), e), c = /* @__PURE__ */ M(k, {
|
|
1837
1984
|
testID: "badge-ring",
|
|
1838
1985
|
style: [{
|
|
1839
1986
|
padding: 2,
|
|
@@ -1872,8 +2019,8 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
1872
2019
|
style: { alignSelf: "flex-start" },
|
|
1873
2020
|
children: [r, c]
|
|
1874
2021
|
}) : c;
|
|
1875
|
-
},
|
|
1876
|
-
let c =
|
|
2022
|
+
}, xt = ({ variant: e = "info", children: t, actionLabel: n, onAction: r, dismissible: i = !1, onDismiss: a, style: o, ...s }) => {
|
|
2023
|
+
let c = q(), l = {
|
|
1877
2024
|
info: {
|
|
1878
2025
|
bg: c.accentBgColor,
|
|
1879
2026
|
fg: c.accentFgColor
|
|
@@ -1906,7 +2053,7 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
1906
2053
|
backgroundColor: l.bg
|
|
1907
2054
|
}, o],
|
|
1908
2055
|
...s,
|
|
1909
|
-
children: [/* @__PURE__ */ M(
|
|
2056
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
1910
2057
|
variant: "body",
|
|
1911
2058
|
style: {
|
|
1912
2059
|
flex: 1,
|
|
@@ -1964,8 +2111,8 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
1964
2111
|
})]
|
|
1965
2112
|
})]
|
|
1966
2113
|
});
|
|
1967
|
-
},
|
|
1968
|
-
let s =
|
|
2114
|
+
}, St = m.createAnimatedComponent(w), Ct = 150, wt = ({ open: e, title: t, children: n, onClose: r, closeOnBackdrop: i = !0, style: a, testID: o }) => {
|
|
2115
|
+
let s = q(), l = J(), [p, _] = f(e), [v, y] = f(0), b = d(new m.Value(g.get("window").height)).current, C = d(new m.Value(0)).current, T = d(!1);
|
|
1969
2116
|
c(() => {
|
|
1970
2117
|
e && _(!0);
|
|
1971
2118
|
}, [e]), c(() => {
|
|
@@ -2022,7 +2169,7 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2022
2169
|
b.setValue(Math.max(0, t.dy));
|
|
2023
2170
|
},
|
|
2024
2171
|
onPanResponderRelease: (e, t) => {
|
|
2025
|
-
T.current = !1, Math.max(0, t.dy) >=
|
|
2172
|
+
T.current = !1, Math.max(0, t.dy) >= Ct ? r?.() : m.timing(b, {
|
|
2026
2173
|
toValue: 0,
|
|
2027
2174
|
duration: s.durationNormal,
|
|
2028
2175
|
useNativeDriver: !0
|
|
@@ -2039,7 +2186,7 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2039
2186
|
animationType: "none",
|
|
2040
2187
|
statusBarTranslucent: !0,
|
|
2041
2188
|
onRequestClose: r,
|
|
2042
|
-
children: /* @__PURE__ */ M(
|
|
2189
|
+
children: /* @__PURE__ */ M(St, {
|
|
2043
2190
|
testID: o,
|
|
2044
2191
|
onPress: i ? r : void 0,
|
|
2045
2192
|
accessible: !1,
|
|
@@ -2095,7 +2242,7 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2095
2242
|
opacity: .2
|
|
2096
2243
|
} })
|
|
2097
2244
|
}),
|
|
2098
|
-
t && /* @__PURE__ */ M(
|
|
2245
|
+
t && /* @__PURE__ */ M(Y, {
|
|
2099
2246
|
variant: "title-4",
|
|
2100
2247
|
style: {
|
|
2101
2248
|
paddingHorizontal: s.space4,
|
|
@@ -2110,7 +2257,7 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2110
2257
|
paddingHorizontal: s.space4,
|
|
2111
2258
|
paddingBottom: s.space4
|
|
2112
2259
|
},
|
|
2113
|
-
children: typeof n == "string" ? /* @__PURE__ */ M(
|
|
2260
|
+
children: typeof n == "string" ? /* @__PURE__ */ M(Y, {
|
|
2114
2261
|
variant: "body",
|
|
2115
2262
|
children: n
|
|
2116
2263
|
}) : n
|
|
@@ -2120,13 +2267,42 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2120
2267
|
})
|
|
2121
2268
|
})
|
|
2122
2269
|
}) : null;
|
|
2123
|
-
},
|
|
2270
|
+
}, Tt = {
|
|
2271
|
+
start: "flex-start",
|
|
2272
|
+
center: "center",
|
|
2273
|
+
end: "flex-end",
|
|
2274
|
+
stretch: "stretch",
|
|
2275
|
+
baseline: "baseline"
|
|
2276
|
+
}, Et = {
|
|
2277
|
+
start: "flex-start",
|
|
2278
|
+
center: "center",
|
|
2279
|
+
end: "flex-end",
|
|
2280
|
+
"space-between": "space-between",
|
|
2281
|
+
"space-around": "space-around",
|
|
2282
|
+
"space-evenly": "space-evenly"
|
|
2283
|
+
}, Dt = i(function({ orientation: e = "vertical", spacing: t = 6, align: n, justify: r = "start", padding: i, children: a, style: o, ...s }, c) {
|
|
2284
|
+
return /* @__PURE__ */ M(k, {
|
|
2285
|
+
ref: c,
|
|
2286
|
+
style: [
|
|
2287
|
+
{
|
|
2288
|
+
flexDirection: e === "horizontal" ? "row" : "column",
|
|
2289
|
+
gap: t,
|
|
2290
|
+
alignItems: Tt[n ?? (e === "horizontal" ? "center" : "stretch")],
|
|
2291
|
+
justifyContent: Et[r]
|
|
2292
|
+
},
|
|
2293
|
+
i !== void 0 && { padding: i },
|
|
2294
|
+
o
|
|
2295
|
+
],
|
|
2296
|
+
...s,
|
|
2297
|
+
children: a
|
|
2298
|
+
});
|
|
2299
|
+
}), Ot = i(function({ orientation: e = "horizontal", style: t, ...n }, r) {
|
|
2124
2300
|
return /* @__PURE__ */ M(k, {
|
|
2125
2301
|
ref: r,
|
|
2126
2302
|
accessible: !1,
|
|
2127
2303
|
style: [
|
|
2128
2304
|
{
|
|
2129
|
-
backgroundColor:
|
|
2305
|
+
backgroundColor: q().cardShadeColor,
|
|
2130
2306
|
flexShrink: 0
|
|
2131
2307
|
},
|
|
2132
2308
|
e === "vertical" ? {
|
|
@@ -2141,8 +2317,8 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2141
2317
|
],
|
|
2142
2318
|
...n
|
|
2143
2319
|
});
|
|
2144
|
-
}),
|
|
2145
|
-
let o =
|
|
2320
|
+
}), kt = i(function({ children: t, variant: n = "default", style: r, ...i }, a) {
|
|
2321
|
+
let o = q(), s = e.toArray(t).filter(Boolean);
|
|
2146
2322
|
return n === "separate" ? /* @__PURE__ */ M(k, {
|
|
2147
2323
|
ref: a,
|
|
2148
2324
|
accessible: !0,
|
|
@@ -2171,12 +2347,12 @@ var mt = ({ variant: e = "accent", dot: t = !1, children: n, anchor: r, style: i
|
|
|
2171
2347
|
overflow: "hidden"
|
|
2172
2348
|
}, r],
|
|
2173
2349
|
...i,
|
|
2174
|
-
children: s.map((e, t) => /* @__PURE__ */ N(k, { children: [t > 0 && /* @__PURE__ */ M(
|
|
2350
|
+
children: s.map((e, t) => /* @__PURE__ */ N(k, { children: [t > 0 && /* @__PURE__ */ M(Ot, { testID: "boxed-list-separator" }), e] }, t))
|
|
2175
2351
|
});
|
|
2176
2352
|
});
|
|
2177
2353
|
//#endregion
|
|
2178
2354
|
//#region src/components/Button/Button.tsx
|
|
2179
|
-
function
|
|
2355
|
+
function At(e, t) {
|
|
2180
2356
|
switch (t) {
|
|
2181
2357
|
case "sm": return {
|
|
2182
2358
|
minHeight: 28,
|
|
@@ -2201,14 +2377,14 @@ function xt(e, t) {
|
|
|
2201
2377
|
};
|
|
2202
2378
|
}
|
|
2203
2379
|
}
|
|
2204
|
-
function
|
|
2380
|
+
function jt(e) {
|
|
2205
2381
|
switch (e) {
|
|
2206
2382
|
case "sm": return 28;
|
|
2207
2383
|
case "lg": return 42;
|
|
2208
2384
|
default: return 34;
|
|
2209
2385
|
}
|
|
2210
2386
|
}
|
|
2211
|
-
function
|
|
2387
|
+
function Mt(e, t, n, r) {
|
|
2212
2388
|
if (r) return {
|
|
2213
2389
|
backgroundColor: n ? "rgba(0, 0, 0, 0.85)" : "rgba(0, 0, 0, 0.65)",
|
|
2214
2390
|
borderColor: "rgba(255, 255, 255, 0.12)",
|
|
@@ -2237,15 +2413,15 @@ function Ct(e, t, n, r) {
|
|
|
2237
2413
|
};
|
|
2238
2414
|
}
|
|
2239
2415
|
}
|
|
2240
|
-
var
|
|
2241
|
-
let f =
|
|
2416
|
+
var Nt = i(function({ variant: e = "default", size: t = "md", shape: n = "default", osd: r = !1, leadingIcon: i, trailingIcon: a, children: o, style: s, textStyle: c, disabled: l, ...u }, d) {
|
|
2417
|
+
let f = q(), p = Oe();
|
|
2242
2418
|
return /* @__PURE__ */ M(w, {
|
|
2243
2419
|
ref: d,
|
|
2244
2420
|
disabled: l,
|
|
2245
2421
|
accessibilityRole: "button",
|
|
2246
2422
|
accessibilityState: { disabled: !!l },
|
|
2247
2423
|
style: ({ pressed: i }) => {
|
|
2248
|
-
let { backgroundColor: a, borderColor: o } =
|
|
2424
|
+
let { backgroundColor: a, borderColor: o } = Mt(f, e, i, r), c = !r && (e === "suggested" || e === "destructive"), u = n === "circular" ? jt(t) : void 0, { minHeight: d, minWidth: m, paddingVertical: h, paddingHorizontal: g } = At(f, t);
|
|
2249
2425
|
return [{
|
|
2250
2426
|
flexDirection: "row",
|
|
2251
2427
|
alignItems: "center",
|
|
@@ -2266,7 +2442,7 @@ var wt = i(function({ variant: e = "default", size: t = "md", shape: n = "defaul
|
|
|
2266
2442
|
},
|
|
2267
2443
|
...u,
|
|
2268
2444
|
children: ({ pressed: n }) => {
|
|
2269
|
-
let { fontSize: s } =
|
|
2445
|
+
let { fontSize: s } = At(f, t), { color: l } = Mt(f, e, n, r);
|
|
2270
2446
|
return /* @__PURE__ */ N(j, { children: [
|
|
2271
2447
|
i,
|
|
2272
2448
|
typeof o == "string" ? /* @__PURE__ */ M(D, {
|
|
@@ -2285,7 +2461,7 @@ var wt = i(function({ variant: e = "default", size: t = "md", shape: n = "defaul
|
|
|
2285
2461
|
});
|
|
2286
2462
|
//#endregion
|
|
2287
2463
|
//#region src/components/Card/Card.tsx
|
|
2288
|
-
function
|
|
2464
|
+
function Pt(e, t) {
|
|
2289
2465
|
switch (t) {
|
|
2290
2466
|
case "none": return 0;
|
|
2291
2467
|
case "sm": return e.space2;
|
|
@@ -2293,14 +2469,14 @@ function Tt(e, t) {
|
|
|
2293
2469
|
default: return e.space4;
|
|
2294
2470
|
}
|
|
2295
2471
|
}
|
|
2296
|
-
var
|
|
2297
|
-
let s =
|
|
2472
|
+
var Ft = i(function({ interactive: e = !1, padding: t = "md", style: n, children: r, disabled: i, ...a }, o) {
|
|
2473
|
+
let s = q(), c = {
|
|
2298
2474
|
backgroundColor: s.cardBgColor,
|
|
2299
2475
|
borderWidth: 1,
|
|
2300
2476
|
borderColor: s.cardShadeColor,
|
|
2301
2477
|
borderRadius: s.radiusLg,
|
|
2302
2478
|
overflow: "hidden",
|
|
2303
|
-
padding:
|
|
2479
|
+
padding: Pt(s, t)
|
|
2304
2480
|
};
|
|
2305
2481
|
return e ? /* @__PURE__ */ M(w, {
|
|
2306
2482
|
ref: o,
|
|
@@ -2329,8 +2505,8 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2329
2505
|
...a,
|
|
2330
2506
|
children: r
|
|
2331
2507
|
});
|
|
2332
|
-
}),
|
|
2333
|
-
let s =
|
|
2508
|
+
}), It = 18, Lt = i(function({ value: e, indeterminate: t = !1, onValueChange: n, disabled: r, style: i, ...a }, o) {
|
|
2509
|
+
let s = q(), l = K(), u = Oe(), f = e || t, p = d(new m.Value(+!!f)).current, h = d(!0);
|
|
2334
2510
|
c(() => {
|
|
2335
2511
|
if (h.current) {
|
|
2336
2512
|
h.current = !1;
|
|
@@ -2369,8 +2545,8 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2369
2545
|
...a,
|
|
2370
2546
|
children: /* @__PURE__ */ M(m.View, {
|
|
2371
2547
|
style: {
|
|
2372
|
-
width:
|
|
2373
|
-
height:
|
|
2548
|
+
width: It,
|
|
2549
|
+
height: It,
|
|
2374
2550
|
alignItems: "center",
|
|
2375
2551
|
justifyContent: "center",
|
|
2376
2552
|
borderRadius: s.radiusSm,
|
|
@@ -2396,8 +2572,8 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2396
2572
|
})
|
|
2397
2573
|
})
|
|
2398
2574
|
});
|
|
2399
|
-
}),
|
|
2400
|
-
let l =
|
|
2575
|
+
}), Rt = ({ label: e, icon: t, onRemove: n, selectable: r = !1, selected: i = !1, onToggle: a, disabled: o = !1, style: s, testID: c }) => {
|
|
2576
|
+
let l = q(), u = r && !n, d = {
|
|
2401
2577
|
flexDirection: "row",
|
|
2402
2578
|
alignItems: "center",
|
|
2403
2579
|
gap: l.space1,
|
|
@@ -2414,12 +2590,12 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2414
2590
|
}, p = /* @__PURE__ */ N(j, { children: [
|
|
2415
2591
|
t && /* @__PURE__ */ M(k, {
|
|
2416
2592
|
style: { marginStart: -2 },
|
|
2417
|
-
children: /* @__PURE__ */ M(
|
|
2593
|
+
children: /* @__PURE__ */ M(X, {
|
|
2418
2594
|
icon: t,
|
|
2419
2595
|
size: "sm"
|
|
2420
2596
|
})
|
|
2421
2597
|
}),
|
|
2422
|
-
/* @__PURE__ */ M(
|
|
2598
|
+
/* @__PURE__ */ M(Y, {
|
|
2423
2599
|
variant: "caption",
|
|
2424
2600
|
style: f,
|
|
2425
2601
|
children: e
|
|
@@ -2434,7 +2610,7 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2434
2610
|
marginEnd: -4,
|
|
2435
2611
|
opacity: o ? l.opacityDisabled : 1
|
|
2436
2612
|
},
|
|
2437
|
-
children: /* @__PURE__ */ M(
|
|
2613
|
+
children: /* @__PURE__ */ M(X, {
|
|
2438
2614
|
icon: L,
|
|
2439
2615
|
size: "sm"
|
|
2440
2616
|
})
|
|
@@ -2468,8 +2644,380 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2468
2644
|
],
|
|
2469
2645
|
children: p
|
|
2470
2646
|
});
|
|
2471
|
-
},
|
|
2472
|
-
|
|
2647
|
+
}, zt = (e) => Math.min(Math.max(e, 0), 1), Bt = i(function({ maximumSize: e = 600, tighteningThreshold: t = 1, children: n, style: r, ...i }, a) {
|
|
2648
|
+
return /* @__PURE__ */ M(k, {
|
|
2649
|
+
ref: a,
|
|
2650
|
+
style: [{
|
|
2651
|
+
width: `${zt(t) * 100}%`,
|
|
2652
|
+
maxWidth: e,
|
|
2653
|
+
alignSelf: "center"
|
|
2654
|
+
}, r],
|
|
2655
|
+
...i,
|
|
2656
|
+
children: n
|
|
2657
|
+
});
|
|
2658
|
+
}), Vt = 12, Z = 12, Ht = 7, Ut = (e, t) => ({
|
|
2659
|
+
top: e.top - t,
|
|
2660
|
+
left: e.left - t,
|
|
2661
|
+
width: e.width + t * 2,
|
|
2662
|
+
height: e.height + t * 2
|
|
2663
|
+
}), Wt = (e, t, n, r) => {
|
|
2664
|
+
let i = e.left + e.width, a = e.top + e.height, o = e.left + e.width / 2, s = e.top + e.height / 2, c = [...new Set([
|
|
2665
|
+
r,
|
|
2666
|
+
{
|
|
2667
|
+
top: "bottom",
|
|
2668
|
+
bottom: "top",
|
|
2669
|
+
left: "right",
|
|
2670
|
+
right: "left"
|
|
2671
|
+
}[r],
|
|
2672
|
+
"bottom",
|
|
2673
|
+
"top",
|
|
2674
|
+
"right",
|
|
2675
|
+
"left"
|
|
2676
|
+
])], l = (n) => {
|
|
2677
|
+
switch (n) {
|
|
2678
|
+
case "bottom": return {
|
|
2679
|
+
top: a + Vt,
|
|
2680
|
+
left: o - t.width / 2
|
|
2681
|
+
};
|
|
2682
|
+
case "top": return {
|
|
2683
|
+
top: e.top - t.height - Vt,
|
|
2684
|
+
left: o - t.width / 2
|
|
2685
|
+
};
|
|
2686
|
+
case "left": return {
|
|
2687
|
+
top: s - t.height / 2,
|
|
2688
|
+
left: e.left - t.width - Vt
|
|
2689
|
+
};
|
|
2690
|
+
default: return {
|
|
2691
|
+
top: s - t.height / 2,
|
|
2692
|
+
left: i + Vt
|
|
2693
|
+
};
|
|
2694
|
+
}
|
|
2695
|
+
};
|
|
2696
|
+
for (let e of c) {
|
|
2697
|
+
let { top: r, left: i } = l(e), a = i >= Z && i + t.width <= n.width - Z, c = r >= Z && r + t.height <= n.height - Z;
|
|
2698
|
+
if (a && c) return {
|
|
2699
|
+
top: r,
|
|
2700
|
+
left: i,
|
|
2701
|
+
placement: e,
|
|
2702
|
+
arrowOffset: e === "top" || e === "bottom" ? o - i : s - r
|
|
2703
|
+
};
|
|
2704
|
+
}
|
|
2705
|
+
for (let e of c) {
|
|
2706
|
+
let { top: r, left: i } = l(e);
|
|
2707
|
+
if (e === "top" || e === "bottom") {
|
|
2708
|
+
if (!(r >= Z && r + t.height <= n.height - Z)) continue;
|
|
2709
|
+
let a = Math.max(Z, Math.min(i, n.width - t.width - Z)), s = o - a;
|
|
2710
|
+
return {
|
|
2711
|
+
top: r,
|
|
2712
|
+
left: a,
|
|
2713
|
+
placement: e,
|
|
2714
|
+
arrowOffset: Math.max(11, Math.min(s, t.width - Ht - 4))
|
|
2715
|
+
};
|
|
2716
|
+
}
|
|
2717
|
+
if (!(i >= Z && i + t.width <= n.width - Z)) continue;
|
|
2718
|
+
let a = Math.max(Z, Math.min(r, n.height - t.height - Z)), c = s - a;
|
|
2719
|
+
return {
|
|
2720
|
+
top: a,
|
|
2721
|
+
left: i,
|
|
2722
|
+
placement: e,
|
|
2723
|
+
arrowOffset: Math.max(11, Math.min(c, t.height - Ht - 4))
|
|
2724
|
+
};
|
|
2725
|
+
}
|
|
2726
|
+
let u = a + Vt, d = o - t.width / 2, f = Math.max(Z, Math.min(u, n.height - t.height - Z)), p = Math.max(Z, Math.min(d, n.width - t.width - Z)), m = o - p;
|
|
2727
|
+
return {
|
|
2728
|
+
top: f,
|
|
2729
|
+
left: p,
|
|
2730
|
+
placement: "bottom",
|
|
2731
|
+
arrowOffset: Math.max(11, Math.min(m, t.width - Ht - 4))
|
|
2732
|
+
};
|
|
2733
|
+
}, Gt = 7, Kt = "rgba(0, 0, 0, 0.55)", qt = ({ open: e, targetRef: t, title: n, description: r, placement: i = "bottom", spotlight: a = !0, spotlightPadding: o = 8, dismissOnBackdrop: s = !1, step: l, stepCount: u, primaryAction: p, secondaryAction: _, onDismiss: v, style: y, testID: b }) => {
|
|
2734
|
+
let S = q(), C = J(), [T, D] = f(null), [O, A] = f(null), [P, F] = f(null), I = d(new m.Value(0)).current;
|
|
2735
|
+
c(() => {
|
|
2736
|
+
if (!e) {
|
|
2737
|
+
D(null), A(null), F(null), I.setValue(0);
|
|
2738
|
+
return;
|
|
2739
|
+
}
|
|
2740
|
+
let n = setTimeout(() => {
|
|
2741
|
+
t.current?.measureInWindow((e, t, n, r) => {
|
|
2742
|
+
D({
|
|
2743
|
+
top: t,
|
|
2744
|
+
left: e,
|
|
2745
|
+
width: n,
|
|
2746
|
+
height: r
|
|
2747
|
+
});
|
|
2748
|
+
});
|
|
2749
|
+
}, 50);
|
|
2750
|
+
return () => clearTimeout(n);
|
|
2751
|
+
}, [
|
|
2752
|
+
e,
|
|
2753
|
+
t,
|
|
2754
|
+
I
|
|
2755
|
+
]), c(() => {
|
|
2756
|
+
if (!T || !O) return;
|
|
2757
|
+
let { width: e, height: t } = g.get("window");
|
|
2758
|
+
F(Wt(T, O, {
|
|
2759
|
+
width: e,
|
|
2760
|
+
height: t
|
|
2761
|
+
}, i));
|
|
2762
|
+
}, [
|
|
2763
|
+
T,
|
|
2764
|
+
O,
|
|
2765
|
+
i
|
|
2766
|
+
]), c(() => {
|
|
2767
|
+
if (P) {
|
|
2768
|
+
if (C) {
|
|
2769
|
+
I.setValue(1);
|
|
2770
|
+
return;
|
|
2771
|
+
}
|
|
2772
|
+
m.timing(I, {
|
|
2773
|
+
toValue: 1,
|
|
2774
|
+
duration: S.durationFast,
|
|
2775
|
+
useNativeDriver: !0
|
|
2776
|
+
}).start();
|
|
2777
|
+
}
|
|
2778
|
+
}, [
|
|
2779
|
+
P,
|
|
2780
|
+
C,
|
|
2781
|
+
I,
|
|
2782
|
+
S.durationFast
|
|
2783
|
+
]), c(() => {
|
|
2784
|
+
if (!e) return;
|
|
2785
|
+
let t = h.addEventListener("hardwareBackPress", () => (v?.(), !0));
|
|
2786
|
+
return () => t.remove();
|
|
2787
|
+
}, [e, v]);
|
|
2788
|
+
let L = (e) => {
|
|
2789
|
+
let { width: t, height: n } = e.nativeEvent.layout;
|
|
2790
|
+
A({
|
|
2791
|
+
width: t,
|
|
2792
|
+
height: n
|
|
2793
|
+
});
|
|
2794
|
+
};
|
|
2795
|
+
if (!e) return null;
|
|
2796
|
+
let R = T ? Ut(T, o) : null, { width: z } = g.get("window"), B = {
|
|
2797
|
+
position: "absolute",
|
|
2798
|
+
width: 0,
|
|
2799
|
+
height: 0,
|
|
2800
|
+
borderWidth: Gt,
|
|
2801
|
+
borderColor: "transparent"
|
|
2802
|
+
}, V = (() => {
|
|
2803
|
+
if (!P) return null;
|
|
2804
|
+
switch (P.placement) {
|
|
2805
|
+
case "top": return {
|
|
2806
|
+
...B,
|
|
2807
|
+
bottom: -14,
|
|
2808
|
+
left: P.arrowOffset - Gt,
|
|
2809
|
+
borderTopColor: S.cardBgColor
|
|
2810
|
+
};
|
|
2811
|
+
case "bottom": return {
|
|
2812
|
+
...B,
|
|
2813
|
+
top: -14,
|
|
2814
|
+
left: P.arrowOffset - Gt,
|
|
2815
|
+
borderBottomColor: S.cardBgColor
|
|
2816
|
+
};
|
|
2817
|
+
case "left": return {
|
|
2818
|
+
...B,
|
|
2819
|
+
right: -14,
|
|
2820
|
+
top: P.arrowOffset - Gt,
|
|
2821
|
+
borderLeftColor: S.cardBgColor
|
|
2822
|
+
};
|
|
2823
|
+
default: return {
|
|
2824
|
+
...B,
|
|
2825
|
+
left: -14,
|
|
2826
|
+
top: P.arrowOffset - Gt,
|
|
2827
|
+
borderRightColor: S.cardBgColor
|
|
2828
|
+
};
|
|
2829
|
+
}
|
|
2830
|
+
})();
|
|
2831
|
+
return /* @__PURE__ */ M(x, {
|
|
2832
|
+
visible: e,
|
|
2833
|
+
transparent: !0,
|
|
2834
|
+
animationType: "none",
|
|
2835
|
+
statusBarTranslucent: !0,
|
|
2836
|
+
onRequestClose: v,
|
|
2837
|
+
children: /* @__PURE__ */ N(m.View, {
|
|
2838
|
+
pointerEvents: "box-none",
|
|
2839
|
+
style: E.absoluteFill,
|
|
2840
|
+
children: [a && /* @__PURE__ */ M(w, {
|
|
2841
|
+
testID: b,
|
|
2842
|
+
onPress: s ? v : void 0,
|
|
2843
|
+
accessible: !1,
|
|
2844
|
+
style: E.absoluteFill,
|
|
2845
|
+
children: /* @__PURE__ */ M(m.View, {
|
|
2846
|
+
pointerEvents: "none",
|
|
2847
|
+
style: [E.absoluteFill, { opacity: I }],
|
|
2848
|
+
children: R && /* @__PURE__ */ N(j, { children: [
|
|
2849
|
+
/* @__PURE__ */ M(k, { style: {
|
|
2850
|
+
position: "absolute",
|
|
2851
|
+
top: 0,
|
|
2852
|
+
left: 0,
|
|
2853
|
+
right: 0,
|
|
2854
|
+
height: Math.max(0, R.top),
|
|
2855
|
+
backgroundColor: Kt
|
|
2856
|
+
} }),
|
|
2857
|
+
/* @__PURE__ */ M(k, { style: {
|
|
2858
|
+
position: "absolute",
|
|
2859
|
+
top: Math.max(0, R.top + R.height),
|
|
2860
|
+
left: 0,
|
|
2861
|
+
right: 0,
|
|
2862
|
+
bottom: 0,
|
|
2863
|
+
backgroundColor: Kt
|
|
2864
|
+
} }),
|
|
2865
|
+
/* @__PURE__ */ M(k, { style: {
|
|
2866
|
+
position: "absolute",
|
|
2867
|
+
top: Math.max(0, R.top),
|
|
2868
|
+
left: 0,
|
|
2869
|
+
width: Math.max(0, R.left),
|
|
2870
|
+
height: R.height,
|
|
2871
|
+
backgroundColor: Kt
|
|
2872
|
+
} }),
|
|
2873
|
+
/* @__PURE__ */ M(k, { style: {
|
|
2874
|
+
position: "absolute",
|
|
2875
|
+
top: Math.max(0, R.top),
|
|
2876
|
+
left: Math.max(0, R.left + R.width),
|
|
2877
|
+
right: 0,
|
|
2878
|
+
height: R.height,
|
|
2879
|
+
backgroundColor: Kt
|
|
2880
|
+
} }),
|
|
2881
|
+
/* @__PURE__ */ M(k, {
|
|
2882
|
+
pointerEvents: "none",
|
|
2883
|
+
style: {
|
|
2884
|
+
position: "absolute",
|
|
2885
|
+
top: R.top,
|
|
2886
|
+
left: R.left,
|
|
2887
|
+
width: R.width,
|
|
2888
|
+
height: R.height,
|
|
2889
|
+
borderRadius: S.radiusMd,
|
|
2890
|
+
borderWidth: 2,
|
|
2891
|
+
borderColor: S.accentColor
|
|
2892
|
+
}
|
|
2893
|
+
})
|
|
2894
|
+
] })
|
|
2895
|
+
})
|
|
2896
|
+
}), /* @__PURE__ */ N(m.View, {
|
|
2897
|
+
onLayout: L,
|
|
2898
|
+
accessible: !0,
|
|
2899
|
+
role: "dialog",
|
|
2900
|
+
accessibilityViewIsModal: !0,
|
|
2901
|
+
style: [
|
|
2902
|
+
{
|
|
2903
|
+
position: "absolute",
|
|
2904
|
+
maxWidth: Math.min(320, z - 24),
|
|
2905
|
+
padding: S.space3,
|
|
2906
|
+
backgroundColor: S.cardBgColor,
|
|
2907
|
+
borderRadius: S.radiusLg,
|
|
2908
|
+
shadowColor: "#000",
|
|
2909
|
+
shadowOffset: {
|
|
2910
|
+
width: 0,
|
|
2911
|
+
height: 4
|
|
2912
|
+
},
|
|
2913
|
+
shadowOpacity: .2,
|
|
2914
|
+
shadowRadius: 16,
|
|
2915
|
+
elevation: 8
|
|
2916
|
+
},
|
|
2917
|
+
P ? {
|
|
2918
|
+
top: P.top,
|
|
2919
|
+
left: P.left,
|
|
2920
|
+
opacity: I,
|
|
2921
|
+
transform: [{ scale: I.interpolate({
|
|
2922
|
+
inputRange: [0, 1],
|
|
2923
|
+
outputRange: [.96, 1]
|
|
2924
|
+
}) }]
|
|
2925
|
+
} : {
|
|
2926
|
+
top: -9999,
|
|
2927
|
+
left: -9999,
|
|
2928
|
+
opacity: 0
|
|
2929
|
+
},
|
|
2930
|
+
y
|
|
2931
|
+
],
|
|
2932
|
+
children: [
|
|
2933
|
+
V && /* @__PURE__ */ M(k, { style: V }),
|
|
2934
|
+
l !== void 0 && u !== void 0 && /* @__PURE__ */ M(Y, {
|
|
2935
|
+
variant: "caption",
|
|
2936
|
+
style: {
|
|
2937
|
+
marginBottom: S.space1,
|
|
2938
|
+
color: S.accentColor,
|
|
2939
|
+
fontWeight: String(S.fontWeightBold)
|
|
2940
|
+
},
|
|
2941
|
+
children: `${l} of ${u}`
|
|
2942
|
+
}),
|
|
2943
|
+
n && /* @__PURE__ */ M(Y, {
|
|
2944
|
+
variant: "title-4",
|
|
2945
|
+
style: {
|
|
2946
|
+
marginBottom: S.space1,
|
|
2947
|
+
fontWeight: String(S.fontWeightBold)
|
|
2948
|
+
},
|
|
2949
|
+
children: n
|
|
2950
|
+
}),
|
|
2951
|
+
r && /* @__PURE__ */ M(Y, {
|
|
2952
|
+
variant: "body",
|
|
2953
|
+
color: "dim",
|
|
2954
|
+
children: r
|
|
2955
|
+
}),
|
|
2956
|
+
(p || _) && /* @__PURE__ */ N(k, {
|
|
2957
|
+
style: {
|
|
2958
|
+
flexDirection: "row",
|
|
2959
|
+
justifyContent: "flex-end",
|
|
2960
|
+
gap: S.space2,
|
|
2961
|
+
marginTop: S.space3
|
|
2962
|
+
},
|
|
2963
|
+
children: [_ && /* @__PURE__ */ M(Nt, {
|
|
2964
|
+
variant: "flat",
|
|
2965
|
+
size: "sm",
|
|
2966
|
+
onPress: _.onPress,
|
|
2967
|
+
children: _.label
|
|
2968
|
+
}), p && /* @__PURE__ */ M(Nt, {
|
|
2969
|
+
variant: "suggested",
|
|
2970
|
+
size: "sm",
|
|
2971
|
+
onPress: p.onPress,
|
|
2972
|
+
children: p.label
|
|
2973
|
+
})]
|
|
2974
|
+
})
|
|
2975
|
+
]
|
|
2976
|
+
})]
|
|
2977
|
+
})
|
|
2978
|
+
});
|
|
2979
|
+
}, Jt = {
|
|
2980
|
+
next: "Next",
|
|
2981
|
+
back: "Back",
|
|
2982
|
+
skip: "Skip",
|
|
2983
|
+
finish: "Done"
|
|
2984
|
+
}, Yt = ({ steps: e, open: t, startIndex: n = 0, onFinish: r, onSkip: i, onStepChange: a, placement: o = "bottom", spotlight: s = !0, dismissOnBackdrop: l = !1, labels: u, testID: d }) => {
|
|
2985
|
+
let [p, m] = f(n);
|
|
2986
|
+
if (c(() => {
|
|
2987
|
+
t && m(n);
|
|
2988
|
+
}, [t, n]), !t || e.length === 0) return null;
|
|
2989
|
+
let h = Math.min(p, e.length - 1), g = e[h], _ = h === 0, v = h === e.length - 1, y = {
|
|
2990
|
+
...Jt,
|
|
2991
|
+
...u
|
|
2992
|
+
}, b = (e) => {
|
|
2993
|
+
m(e), a?.(e);
|
|
2994
|
+
}, x = {
|
|
2995
|
+
label: v ? y.finish : y.next,
|
|
2996
|
+
onPress: () => v ? r?.() : b(h + 1)
|
|
2997
|
+
}, S = _ ? {
|
|
2998
|
+
label: y.skip,
|
|
2999
|
+
onPress: () => i?.()
|
|
3000
|
+
} : {
|
|
3001
|
+
label: y.back,
|
|
3002
|
+
onPress: () => b(h - 1)
|
|
3003
|
+
};
|
|
3004
|
+
return /* @__PURE__ */ M(qt, {
|
|
3005
|
+
open: t,
|
|
3006
|
+
targetRef: g.targetRef,
|
|
3007
|
+
title: g.title,
|
|
3008
|
+
description: g.description,
|
|
3009
|
+
placement: g.placement ?? o,
|
|
3010
|
+
spotlight: s,
|
|
3011
|
+
dismissOnBackdrop: l,
|
|
3012
|
+
step: h + 1,
|
|
3013
|
+
stepCount: e.length,
|
|
3014
|
+
primaryAction: x,
|
|
3015
|
+
secondaryAction: S,
|
|
3016
|
+
onDismiss: () => i?.(),
|
|
3017
|
+
testID: d
|
|
3018
|
+
});
|
|
3019
|
+
}, Xt = m.createAnimatedComponent(w), Zt = ({ open: e, title: t, children: n, buttons: r = [], onClose: i, closeOnBackdrop: a = !0, role: o = "dialog", responses: s, onResponse: l, style: u, testID: f }) => {
|
|
3020
|
+
let p = q(), g = K(), v = J(), y = d(new m.Value(+!!v)).current, b = !!s, S = () => {
|
|
2473
3021
|
let e = s?.find((e) => e.variant !== "destructive" && !e.disabled);
|
|
2474
3022
|
e && l?.(e.id);
|
|
2475
3023
|
}, C = () => {
|
|
@@ -2528,7 +3076,7 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2528
3076
|
backgroundColor: r ? p.activeOverlay : "transparent",
|
|
2529
3077
|
opacity: t.disabled ? p.opacityDisabled : 1
|
|
2530
3078
|
}),
|
|
2531
|
-
children: /* @__PURE__ */ M(
|
|
3079
|
+
children: /* @__PURE__ */ M(Y, {
|
|
2532
3080
|
variant: "body",
|
|
2533
3081
|
style: {
|
|
2534
3082
|
textAlign: "center",
|
|
@@ -2555,7 +3103,7 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2555
3103
|
animationType: "none",
|
|
2556
3104
|
statusBarTranslucent: !0,
|
|
2557
3105
|
onRequestClose: C,
|
|
2558
|
-
children: /* @__PURE__ */ M(
|
|
3106
|
+
children: /* @__PURE__ */ M(Xt, {
|
|
2559
3107
|
testID: f,
|
|
2560
3108
|
onPress: T,
|
|
2561
3109
|
style: {
|
|
@@ -2597,7 +3145,7 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2597
3145
|
}) }]
|
|
2598
3146
|
}, u],
|
|
2599
3147
|
children: [
|
|
2600
|
-
t && /* @__PURE__ */ M(
|
|
3148
|
+
t && /* @__PURE__ */ M(Y, {
|
|
2601
3149
|
variant: "title-4",
|
|
2602
3150
|
style: {
|
|
2603
3151
|
padding: p.space4,
|
|
@@ -2612,7 +3160,7 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2612
3160
|
paddingVertical: p.space2,
|
|
2613
3161
|
paddingHorizontal: p.space4
|
|
2614
3162
|
},
|
|
2615
|
-
children: typeof n == "string" ? /* @__PURE__ */ M(
|
|
3163
|
+
children: typeof n == "string" ? /* @__PURE__ */ M(Y, {
|
|
2616
3164
|
variant: "body",
|
|
2617
3165
|
style: {
|
|
2618
3166
|
textAlign: "center",
|
|
@@ -2627,8 +3175,8 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2627
3175
|
})
|
|
2628
3176
|
})
|
|
2629
3177
|
});
|
|
2630
|
-
},
|
|
2631
|
-
let i =
|
|
3178
|
+
}, Qt = ({ children: e, accessibilityLabel: t, style: n, testID: r }) => {
|
|
3179
|
+
let i = q(), a = !!e;
|
|
2632
3180
|
return /* @__PURE__ */ N(k, {
|
|
2633
3181
|
testID: r,
|
|
2634
3182
|
accessible: !0,
|
|
@@ -2644,7 +3192,7 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2644
3192
|
flex: 1,
|
|
2645
3193
|
height: 1,
|
|
2646
3194
|
backgroundColor: i.cardShadeColor
|
|
2647
|
-
} }), a && /* @__PURE__ */ N(j, { children: [typeof e == "string" ? /* @__PURE__ */ M(
|
|
3195
|
+
} }), a && /* @__PURE__ */ N(j, { children: [typeof e == "string" ? /* @__PURE__ */ M(Y, {
|
|
2648
3196
|
variant: "caption",
|
|
2649
3197
|
color: "dim",
|
|
2650
3198
|
children: e
|
|
@@ -2654,8 +3202,8 @@ var Et = i(function({ interactive: e = !1, padding: t = "md", style: n, children
|
|
|
2654
3202
|
backgroundColor: i.cardShadeColor
|
|
2655
3203
|
} })] })]
|
|
2656
3204
|
});
|
|
2657
|
-
},
|
|
2658
|
-
function
|
|
3205
|
+
}, $t = 6, Q = 8, en = 5;
|
|
3206
|
+
function tn(e, t) {
|
|
2659
3207
|
if (e) {
|
|
2660
3208
|
if (typeof e == "function") {
|
|
2661
3209
|
e(t);
|
|
@@ -2664,27 +3212,27 @@ function Pt(e, t) {
|
|
|
2664
3212
|
e.current = t;
|
|
2665
3213
|
}
|
|
2666
3214
|
}
|
|
2667
|
-
function
|
|
3215
|
+
function nn(e, t, n) {
|
|
2668
3216
|
switch (n) {
|
|
2669
3217
|
case "top": return {
|
|
2670
|
-
top: e.y - t.height -
|
|
3218
|
+
top: e.y - t.height - $t,
|
|
2671
3219
|
left: e.x + e.width / 2 - t.width / 2
|
|
2672
3220
|
};
|
|
2673
3221
|
case "bottom": return {
|
|
2674
|
-
top: e.y + e.height +
|
|
3222
|
+
top: e.y + e.height + $t,
|
|
2675
3223
|
left: e.x + e.width / 2 - t.width / 2
|
|
2676
3224
|
};
|
|
2677
3225
|
case "left": return {
|
|
2678
3226
|
top: e.y + e.height / 2 - t.height / 2,
|
|
2679
|
-
left: e.x - t.width -
|
|
3227
|
+
left: e.x - t.width - $t
|
|
2680
3228
|
};
|
|
2681
3229
|
case "right": return {
|
|
2682
3230
|
top: e.y + e.height / 2 - t.height / 2,
|
|
2683
|
-
left: e.x + e.width +
|
|
3231
|
+
left: e.x + e.width + $t
|
|
2684
3232
|
};
|
|
2685
3233
|
}
|
|
2686
3234
|
}
|
|
2687
|
-
function
|
|
3235
|
+
function rn(e, t, n) {
|
|
2688
3236
|
let { width: r, height: i } = g.get("window"), a = [
|
|
2689
3237
|
n,
|
|
2690
3238
|
n === "top" ? "bottom" : n === "bottom" ? "top" : n === "left" ? "right" : "left",
|
|
@@ -2694,22 +3242,22 @@ function It(e, t, n) {
|
|
|
2694
3242
|
"right"
|
|
2695
3243
|
];
|
|
2696
3244
|
for (let n of a) {
|
|
2697
|
-
let { top: a, left: o } =
|
|
3245
|
+
let { top: a, left: o } = nn(e, t, n), s = o >= Q && o + t.width <= r - Q, c = a >= Q && a + t.height <= i - Q;
|
|
2698
3246
|
if (s && c) return {
|
|
2699
|
-
top: Math.max(
|
|
2700
|
-
left: Math.max(
|
|
3247
|
+
top: Math.max(Q, Math.min(a, i - t.height - Q)),
|
|
3248
|
+
left: Math.max(Q, Math.min(o, r - t.width - Q)),
|
|
2701
3249
|
placement: n
|
|
2702
3250
|
};
|
|
2703
3251
|
}
|
|
2704
|
-
let { top: o, left: s } =
|
|
3252
|
+
let { top: o, left: s } = nn(e, t, n);
|
|
2705
3253
|
return {
|
|
2706
|
-
top: Math.max(
|
|
2707
|
-
left: Math.max(
|
|
3254
|
+
top: Math.max(Q, Math.min(o, i - t.height - Q)),
|
|
3255
|
+
left: Math.max(Q, Math.min(s, r - t.width - Q)),
|
|
2708
3256
|
placement: n
|
|
2709
3257
|
};
|
|
2710
3258
|
}
|
|
2711
|
-
var
|
|
2712
|
-
let a =
|
|
3259
|
+
var an = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
3260
|
+
let a = q(), s = K(), l = J(), [u, p] = f(!1), [h, g] = f(null), [_, v] = f(null), [y, b] = f(null), S = d(null), C = d(null), w = d(new m.Value(0)).current, T = o(() => {
|
|
2713
3261
|
C.current &&= (clearTimeout(C.current), null);
|
|
2714
3262
|
}, []), D = o(() => {
|
|
2715
3263
|
T(), p(!0);
|
|
@@ -2736,7 +3284,7 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2736
3284
|
});
|
|
2737
3285
|
});
|
|
2738
3286
|
}, [u]), c(() => {
|
|
2739
|
-
!h || !_ || b(
|
|
3287
|
+
!h || !_ || b(rn(h, _, t));
|
|
2740
3288
|
}, [
|
|
2741
3289
|
h,
|
|
2742
3290
|
_,
|
|
@@ -2777,7 +3325,7 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2777
3325
|
position: "absolute",
|
|
2778
3326
|
width: 0,
|
|
2779
3327
|
height: 0,
|
|
2780
|
-
borderWidth:
|
|
3328
|
+
borderWidth: en,
|
|
2781
3329
|
borderColor: "transparent"
|
|
2782
3330
|
}, z = (() => {
|
|
2783
3331
|
switch (y?.placement) {
|
|
@@ -2811,10 +3359,10 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2811
3359
|
};
|
|
2812
3360
|
default: return null;
|
|
2813
3361
|
}
|
|
2814
|
-
})(),
|
|
3362
|
+
})(), B = i.props.ref;
|
|
2815
3363
|
return /* @__PURE__ */ N(j, { children: [n(i, {
|
|
2816
3364
|
ref: (e) => {
|
|
2817
|
-
S.current = e,
|
|
3365
|
+
S.current = e, tn(B, e);
|
|
2818
3366
|
},
|
|
2819
3367
|
delayLongPress: r,
|
|
2820
3368
|
accessibilityHint: i.props.accessibilityHint ?? e,
|
|
@@ -2870,7 +3418,7 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2870
3418
|
left: -9999,
|
|
2871
3419
|
opacity: 0
|
|
2872
3420
|
}],
|
|
2873
|
-
children: [/* @__PURE__ */ M(
|
|
3421
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
2874
3422
|
style: {
|
|
2875
3423
|
color: I,
|
|
2876
3424
|
fontSize: a.fontSizeCaption,
|
|
@@ -2883,12 +3431,12 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2883
3431
|
})
|
|
2884
3432
|
})
|
|
2885
3433
|
})] });
|
|
2886
|
-
},
|
|
3434
|
+
}, on = {
|
|
2887
3435
|
sm: "sm",
|
|
2888
3436
|
md: "md",
|
|
2889
3437
|
lg: "lg"
|
|
2890
|
-
},
|
|
2891
|
-
let u = /* @__PURE__ */ M(
|
|
3438
|
+
}, sn = i(function({ icon: e, label: t, variant: n = "default", size: r = "md", iconSize: i, tooltip: a, tooltipPlacement: o, tooltipDelay: s, ...c }, l) {
|
|
3439
|
+
let u = /* @__PURE__ */ M(Nt, {
|
|
2892
3440
|
ref: l,
|
|
2893
3441
|
accessibilityLabel: t,
|
|
2894
3442
|
shape: "circular",
|
|
@@ -2896,22 +3444,22 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2896
3444
|
variant: n === "osd" ? "flat" : n,
|
|
2897
3445
|
osd: n === "osd",
|
|
2898
3446
|
...c,
|
|
2899
|
-
children: /* @__PURE__ */ M(
|
|
3447
|
+
children: /* @__PURE__ */ M(X, {
|
|
2900
3448
|
icon: e,
|
|
2901
|
-
size: i ??
|
|
3449
|
+
size: i ?? on[r]
|
|
2902
3450
|
})
|
|
2903
3451
|
});
|
|
2904
|
-
return a ? /* @__PURE__ */ M(
|
|
3452
|
+
return a ? /* @__PURE__ */ M(an, {
|
|
2905
3453
|
label: a,
|
|
2906
3454
|
placement: o,
|
|
2907
3455
|
delay: s,
|
|
2908
3456
|
children: u
|
|
2909
3457
|
}) : u;
|
|
2910
|
-
}),
|
|
3458
|
+
}), cn = m.createAnimatedComponent(w), ln = r(0), un = {
|
|
2911
3459
|
classic: 420,
|
|
2912
3460
|
wide: 640
|
|
2913
|
-
},
|
|
2914
|
-
let v =
|
|
3461
|
+
}, dn = .85, fn = 240, pn = ({ open: e, side: t = "right", size: n = "classic", title: r, content: i, children: a, onClose: o, closeOnBackdrop: l = !0, rail: u, style: f, testID: p }) => {
|
|
3462
|
+
let v = q(), y = K(), b = J(), S = s(ln), C = i === void 0 ? a : i, T = un[n], E = S > 0 ? Math.max(fn, Math.round(T * dn ** S)) : T, D = g.get("window").width - v.space3 * 2, O = Math.min(E, D), A = d(new m.Value(+!!b)).current;
|
|
2915
3463
|
c(() => {
|
|
2916
3464
|
if (!e) return;
|
|
2917
3465
|
if (b) {
|
|
@@ -2958,7 +3506,7 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2958
3506
|
[t === "right" ? "borderRightWidth" : "borderLeftWidth"]: 1,
|
|
2959
3507
|
borderColor: v.cardShadeColor
|
|
2960
3508
|
},
|
|
2961
|
-
children: u.map((e) => /* @__PURE__ */ M(
|
|
3509
|
+
children: u.map((e) => /* @__PURE__ */ M(sn, {
|
|
2962
3510
|
icon: e.icon,
|
|
2963
3511
|
label: e.label,
|
|
2964
3512
|
tooltip: e.label,
|
|
@@ -2979,7 +3527,7 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
2979
3527
|
animationType: "none",
|
|
2980
3528
|
statusBarTranslucent: !0,
|
|
2981
3529
|
onRequestClose: o,
|
|
2982
|
-
children: /* @__PURE__ */ M(
|
|
3530
|
+
children: /* @__PURE__ */ M(cn, {
|
|
2983
3531
|
testID: p,
|
|
2984
3532
|
onPress: l ? o : void 0,
|
|
2985
3533
|
accessible: !1,
|
|
@@ -3028,20 +3576,20 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
3028
3576
|
padding: v.space4,
|
|
3029
3577
|
paddingBottom: v.space2
|
|
3030
3578
|
},
|
|
3031
|
-
children: [/* @__PURE__ */ M(
|
|
3579
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
3032
3580
|
variant: "title-4",
|
|
3033
3581
|
style: {
|
|
3034
3582
|
flex: 1,
|
|
3035
3583
|
fontWeight: String(v.fontWeightBold)
|
|
3036
3584
|
},
|
|
3037
3585
|
children: r
|
|
3038
|
-
}), o && /* @__PURE__ */ M(
|
|
3586
|
+
}), o && /* @__PURE__ */ M(Nt, {
|
|
3039
3587
|
variant: "flat",
|
|
3040
3588
|
shape: "circular",
|
|
3041
3589
|
size: "sm",
|
|
3042
3590
|
accessibilityLabel: "Close",
|
|
3043
3591
|
onPress: o,
|
|
3044
|
-
children: /* @__PURE__ */ M(
|
|
3592
|
+
children: /* @__PURE__ */ M(X, {
|
|
3045
3593
|
icon: L,
|
|
3046
3594
|
size: "sm"
|
|
3047
3595
|
})
|
|
@@ -3052,9 +3600,9 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
3052
3600
|
padding: v.space4,
|
|
3053
3601
|
paddingTop: r ? 0 : v.space4
|
|
3054
3602
|
},
|
|
3055
|
-
children: /* @__PURE__ */ M(
|
|
3603
|
+
children: /* @__PURE__ */ M(ln.Provider, {
|
|
3056
3604
|
value: S + 1,
|
|
3057
|
-
children: typeof C == "string" ? /* @__PURE__ */ M(
|
|
3605
|
+
children: typeof C == "string" ? /* @__PURE__ */ M(Y, {
|
|
3058
3606
|
variant: "body",
|
|
3059
3607
|
children: C
|
|
3060
3608
|
}) : C
|
|
@@ -3067,18 +3615,18 @@ var Lt = ({ label: e, placement: t = "top", delay: r = 500, children: i }) => {
|
|
|
3067
3615
|
})
|
|
3068
3616
|
})
|
|
3069
3617
|
});
|
|
3070
|
-
},
|
|
3071
|
-
function
|
|
3072
|
-
let { height: n } = g.get("window"), r = n - (e.y + e.height) < t && e.y > t, i = r ? e.y - t -
|
|
3618
|
+
}, mn = 4, hn = 8, gn = 280;
|
|
3619
|
+
function _n(e, t) {
|
|
3620
|
+
let { height: n } = g.get("window"), r = n - (e.y + e.height) < t && e.y > t, i = r ? e.y - t - mn : e.y + e.height + mn;
|
|
3073
3621
|
return {
|
|
3074
|
-
top: Math.max(
|
|
3622
|
+
top: Math.max(hn, Math.min(i, n - t - hn)),
|
|
3075
3623
|
left: e.x,
|
|
3076
3624
|
width: e.width,
|
|
3077
3625
|
flipUp: r
|
|
3078
3626
|
};
|
|
3079
3627
|
}
|
|
3080
|
-
var
|
|
3081
|
-
let l =
|
|
3628
|
+
var vn = ({ options: e, value: t, onChange: n, placeholder: r = "Select an option", accessibilityLabel: i, disabled: a, style: o, testID: s }) => {
|
|
3629
|
+
let l = q(), u = J(), [p, h] = f(!1), [g, _] = f(null), [v, y] = f(null), [b, S] = f(null), C = d(null), E = d(new m.Value(0)).current, D = e.find((e) => e.value === t), O = () => {
|
|
3082
3630
|
a || h(!0);
|
|
3083
3631
|
}, A = () => h(!1), j = (e) => {
|
|
3084
3632
|
e.disabled || (n?.(e.value), A());
|
|
@@ -3097,7 +3645,7 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3097
3645
|
});
|
|
3098
3646
|
});
|
|
3099
3647
|
}, [p]), c(() => {
|
|
3100
|
-
g === null || v === null || S(
|
|
3648
|
+
g === null || v === null || S(_n(g, v));
|
|
3101
3649
|
}, [g, v]), c(() => {
|
|
3102
3650
|
if (b) {
|
|
3103
3651
|
if (u) {
|
|
@@ -3143,7 +3691,7 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3143
3691
|
borderRadius: l.radiusMd,
|
|
3144
3692
|
opacity: a ? l.opacityDisabled : 1
|
|
3145
3693
|
}),
|
|
3146
|
-
children: [/* @__PURE__ */ M(
|
|
3694
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
3147
3695
|
numberOfLines: 1,
|
|
3148
3696
|
style: {
|
|
3149
3697
|
flex: 1,
|
|
@@ -3152,8 +3700,8 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3152
3700
|
opacity: D ? 1 : l.opacityDim
|
|
3153
3701
|
},
|
|
3154
3702
|
children: D?.label ?? r
|
|
3155
|
-
}), /* @__PURE__ */ M(
|
|
3156
|
-
icon:
|
|
3703
|
+
}), /* @__PURE__ */ M(X, {
|
|
3704
|
+
icon: ne,
|
|
3157
3705
|
size: "md",
|
|
3158
3706
|
color: "default",
|
|
3159
3707
|
style: { transform: [{ rotate: p ? "180deg" : "0deg" }] }
|
|
@@ -3170,13 +3718,13 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3170
3718
|
testID: s ? `${s}-backdrop` : void 0,
|
|
3171
3719
|
children: /* @__PURE__ */ M(m.View, {
|
|
3172
3720
|
onLayout: (e) => {
|
|
3173
|
-
y(Math.min(e.nativeEvent.layout.height,
|
|
3721
|
+
y(Math.min(e.nativeEvent.layout.height, gn));
|
|
3174
3722
|
},
|
|
3175
3723
|
role: "list",
|
|
3176
3724
|
accessible: !0,
|
|
3177
3725
|
style: [{
|
|
3178
3726
|
position: "absolute",
|
|
3179
|
-
maxHeight:
|
|
3727
|
+
maxHeight: gn,
|
|
3180
3728
|
backgroundColor: l.popoverBgColor,
|
|
3181
3729
|
borderWidth: 1,
|
|
3182
3730
|
borderColor: l.cardShadeColor,
|
|
@@ -3228,7 +3776,7 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3228
3776
|
flex: 1,
|
|
3229
3777
|
gap: 1
|
|
3230
3778
|
},
|
|
3231
|
-
children: [/* @__PURE__ */ M(
|
|
3779
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
3232
3780
|
numberOfLines: 1,
|
|
3233
3781
|
style: {
|
|
3234
3782
|
fontSize: l.fontSizeBody,
|
|
@@ -3236,7 +3784,7 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3236
3784
|
fontWeight: n ? String(l.fontWeightSemibold) : void 0
|
|
3237
3785
|
},
|
|
3238
3786
|
children: e.label
|
|
3239
|
-
}), e.description && /* @__PURE__ */ M(
|
|
3787
|
+
}), e.description && /* @__PURE__ */ M(Y, {
|
|
3240
3788
|
numberOfLines: 1,
|
|
3241
3789
|
style: {
|
|
3242
3790
|
fontSize: l.fontSizeCaption,
|
|
@@ -3245,7 +3793,7 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3245
3793
|
},
|
|
3246
3794
|
children: e.description
|
|
3247
3795
|
})]
|
|
3248
|
-
}), n && /* @__PURE__ */ M(
|
|
3796
|
+
}), n && /* @__PURE__ */ M(X, {
|
|
3249
3797
|
icon: I,
|
|
3250
3798
|
size: "md",
|
|
3251
3799
|
color: "blue"
|
|
@@ -3257,8 +3805,8 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3257
3805
|
})
|
|
3258
3806
|
})]
|
|
3259
3807
|
});
|
|
3260
|
-
},
|
|
3261
|
-
let l =
|
|
3808
|
+
}, yn = ({ label: e, children: t, expanded: n, defaultExpanded: r = !1, onExpandedChange: i, disabled: a = !1, style: o, testID: s }) => {
|
|
3809
|
+
let l = q(), u = J(), p = n !== void 0, [h, g] = f(r), v = p ? n : h, [y, b] = f(0), x = d(!1), S = d(new m.Value(0)).current, C = d(new m.Value(+!!r)).current, T = () => {
|
|
3262
3810
|
if (a) return;
|
|
3263
3811
|
let e = !v;
|
|
3264
3812
|
p || g(e), i?.(e);
|
|
@@ -3328,11 +3876,11 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3328
3876
|
opacity: .55,
|
|
3329
3877
|
transform: [{ rotate: O }]
|
|
3330
3878
|
},
|
|
3331
|
-
children: /* @__PURE__ */ M(
|
|
3332
|
-
icon:
|
|
3879
|
+
children: /* @__PURE__ */ M(X, {
|
|
3880
|
+
icon: re,
|
|
3333
3881
|
size: "md"
|
|
3334
3882
|
})
|
|
3335
|
-
}), typeof e == "string" ? /* @__PURE__ */ M(
|
|
3883
|
+
}), typeof e == "string" ? /* @__PURE__ */ M(Y, {
|
|
3336
3884
|
style: { color: l.windowFgColor },
|
|
3337
3885
|
children: e
|
|
3338
3886
|
}) : e]
|
|
@@ -3352,21 +3900,21 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3352
3900
|
})
|
|
3353
3901
|
})]
|
|
3354
3902
|
});
|
|
3355
|
-
},
|
|
3356
|
-
folder:
|
|
3357
|
-
image:
|
|
3903
|
+
}, bn = {
|
|
3904
|
+
folder: V,
|
|
3905
|
+
image: ee,
|
|
3358
3906
|
audio: F,
|
|
3359
|
-
video:
|
|
3360
|
-
text:
|
|
3907
|
+
video: ae,
|
|
3908
|
+
text: ie,
|
|
3361
3909
|
pdf: z,
|
|
3362
|
-
archive:
|
|
3363
|
-
document:
|
|
3364
|
-
spreadsheet:
|
|
3365
|
-
presentation:
|
|
3366
|
-
font:
|
|
3910
|
+
archive: te,
|
|
3911
|
+
document: oe,
|
|
3912
|
+
spreadsheet: ce,
|
|
3913
|
+
presentation: se,
|
|
3914
|
+
font: H,
|
|
3367
3915
|
executable: P,
|
|
3368
|
-
unknown:
|
|
3369
|
-
},
|
|
3916
|
+
unknown: ie
|
|
3917
|
+
}, xn = {
|
|
3370
3918
|
folder: "Folder",
|
|
3371
3919
|
image: "Image file",
|
|
3372
3920
|
audio: "Audio file",
|
|
@@ -3380,7 +3928,7 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3380
3928
|
font: "Font file",
|
|
3381
3929
|
executable: "Executable",
|
|
3382
3930
|
unknown: "File"
|
|
3383
|
-
},
|
|
3931
|
+
}, Sn = {
|
|
3384
3932
|
png: "image",
|
|
3385
3933
|
jpg: "image",
|
|
3386
3934
|
jpeg: "image",
|
|
@@ -3452,13 +4000,13 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3452
4000
|
h: "text",
|
|
3453
4001
|
java: "text",
|
|
3454
4002
|
sql: "text"
|
|
3455
|
-
},
|
|
4003
|
+
}, Cn = {
|
|
3456
4004
|
image: "image",
|
|
3457
4005
|
audio: "audio",
|
|
3458
4006
|
video: "video",
|
|
3459
4007
|
text: "text",
|
|
3460
4008
|
font: "font"
|
|
3461
|
-
},
|
|
4009
|
+
}, wn = {
|
|
3462
4010
|
pdf: "pdf",
|
|
3463
4011
|
zip: "archive",
|
|
3464
4012
|
gzip: "archive",
|
|
@@ -3478,31 +4026,31 @@ var Xt = ({ options: e, value: t, onChange: n, placeholder: r = "Select an optio
|
|
|
3478
4026
|
"x-sh": "executable",
|
|
3479
4027
|
"x-executable": "executable"
|
|
3480
4028
|
};
|
|
3481
|
-
function
|
|
4029
|
+
function Tn(e) {
|
|
3482
4030
|
let t = e.trim().toLowerCase();
|
|
3483
4031
|
if (t === "inode/directory") return "folder";
|
|
3484
4032
|
let [n, r] = t.split("/");
|
|
3485
|
-
return r &&
|
|
4033
|
+
return r && wn[r] ? wn[r] : Cn[n] ?? null;
|
|
3486
4034
|
}
|
|
3487
|
-
function
|
|
4035
|
+
function En(e) {
|
|
3488
4036
|
let t = e.trim().replace(/^\.+/, ""), n = t.lastIndexOf(".");
|
|
3489
|
-
return n <= 0 ? null :
|
|
4037
|
+
return n <= 0 ? null : Sn[t.slice(n + 1).toLowerCase()] ?? null;
|
|
3490
4038
|
}
|
|
3491
|
-
function
|
|
3492
|
-
return
|
|
4039
|
+
function Dn(e) {
|
|
4040
|
+
return bn[e];
|
|
3493
4041
|
}
|
|
3494
|
-
function
|
|
3495
|
-
return
|
|
4042
|
+
function On(e) {
|
|
4043
|
+
return xn[e];
|
|
3496
4044
|
}
|
|
3497
4045
|
//#endregion
|
|
3498
4046
|
//#region src/components/FileTypeIcon/FileTypeIcon.tsx
|
|
3499
|
-
var
|
|
3500
|
-
let c =
|
|
4047
|
+
var kn = ({ name: e, mimeType: t, isFolder: n = !1, thumbnail: r, label: i, size: a = "md", style: o, testID: s }) => {
|
|
4048
|
+
let c = q(), l = Ve[a], u = n ? "folder" : t && Tn(t) || e && En(e) || "unknown";
|
|
3501
4049
|
return /* @__PURE__ */ M(k, {
|
|
3502
4050
|
testID: s,
|
|
3503
4051
|
accessible: !0,
|
|
3504
4052
|
role: "img",
|
|
3505
|
-
accessibilityLabel: i ??
|
|
4053
|
+
accessibilityLabel: i ?? On(u),
|
|
3506
4054
|
style: [{
|
|
3507
4055
|
width: l,
|
|
3508
4056
|
height: l,
|
|
@@ -3518,13 +4066,13 @@ var cn = ({ name: e, mimeType: t, isFolder: n = !1, thumbnail: r, label: i, size
|
|
|
3518
4066
|
height: l,
|
|
3519
4067
|
borderRadius: c.radiusSm
|
|
3520
4068
|
}
|
|
3521
|
-
}) : /* @__PURE__ */ M(
|
|
3522
|
-
icon:
|
|
4069
|
+
}) : /* @__PURE__ */ M(X, {
|
|
4070
|
+
icon: Dn(u),
|
|
3523
4071
|
size: a
|
|
3524
4072
|
})
|
|
3525
4073
|
});
|
|
3526
|
-
},
|
|
3527
|
-
let s =
|
|
4074
|
+
}, An = i(function({ title: e, start: t, end: n, flat: r = !1, style: i, ...a }, o) {
|
|
4075
|
+
let s = q();
|
|
3528
4076
|
return /* @__PURE__ */ N(k, {
|
|
3529
4077
|
ref: o,
|
|
3530
4078
|
style: [{
|
|
@@ -3583,23 +4131,23 @@ var cn = ({ name: e, mimeType: t, isFolder: n = !1, thumbnail: r, label: i, size
|
|
|
3583
4131
|
});
|
|
3584
4132
|
//#endregion
|
|
3585
4133
|
//#region src/components/Highlight/Highlight.tsx
|
|
3586
|
-
function
|
|
4134
|
+
function jn(e) {
|
|
3587
4135
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
3588
4136
|
}
|
|
3589
|
-
var
|
|
3590
|
-
let i =
|
|
3591
|
-
if (o.length === 0) return /* @__PURE__ */ M(
|
|
4137
|
+
var Mn = ({ text: e, query: t, caseSensitive: n = !1, ...r }) => {
|
|
4138
|
+
let i = q(), a = Oe(), o = (Array.isArray(t) ? t : [t]).map((e) => e.trim()).filter(Boolean);
|
|
4139
|
+
if (o.length === 0) return /* @__PURE__ */ M(Y, {
|
|
3592
4140
|
...r,
|
|
3593
4141
|
children: e
|
|
3594
4142
|
});
|
|
3595
|
-
let s = RegExp(`(${o.map(
|
|
4143
|
+
let s = RegExp(`(${o.map(jn).join("|")})`, n ? "g" : "gi"), c = e.split(s), l = {
|
|
3596
4144
|
fontWeight: String(i.fontWeightSemibold),
|
|
3597
4145
|
...a === "more" ? {
|
|
3598
4146
|
backgroundColor: i.accentBgColor,
|
|
3599
4147
|
color: "#fff"
|
|
3600
4148
|
} : { backgroundColor: `${i.accentBgColor}4D` }
|
|
3601
4149
|
};
|
|
3602
|
-
return /* @__PURE__ */ M(
|
|
4150
|
+
return /* @__PURE__ */ M(Y, {
|
|
3603
4151
|
...r,
|
|
3604
4152
|
children: c.map((e, t) => t % 2 == 1 ? /* @__PURE__ */ M(D, {
|
|
3605
4153
|
style: l,
|
|
@@ -3608,11 +4156,369 @@ var dn = ({ text: e, query: t, caseSensitive: n = !1, ...r }) => {
|
|
|
3608
4156
|
});
|
|
3609
4157
|
};
|
|
3610
4158
|
//#endregion
|
|
4159
|
+
//#region src/components/InlineViewSwitcher/variants.ts
|
|
4160
|
+
function Nn(e, t, n) {
|
|
4161
|
+
let r = n ? "rgba(255, 255, 255, 0.12)" : e.light3, i = `${e.accentBgColor}${n ? "40" : "26"}`, a = `${e.accentBgColor}${n ? "80" : "66"}`;
|
|
4162
|
+
switch (t) {
|
|
4163
|
+
case "flat": return {
|
|
4164
|
+
container: {
|
|
4165
|
+
backgroundColor: "transparent",
|
|
4166
|
+
borderRadius: e.radiusMd,
|
|
4167
|
+
padding: 2,
|
|
4168
|
+
gap: 2
|
|
4169
|
+
},
|
|
4170
|
+
gap: 2,
|
|
4171
|
+
padding: 2,
|
|
4172
|
+
item: {
|
|
4173
|
+
borderRadius: e.radiusMd - 2,
|
|
4174
|
+
paddingHorizontal: e.space2
|
|
4175
|
+
},
|
|
4176
|
+
iconOnlyItem: {
|
|
4177
|
+
paddingHorizontal: 4,
|
|
4178
|
+
minWidth: 28
|
|
4179
|
+
},
|
|
4180
|
+
indicator: {
|
|
4181
|
+
backgroundColor: i,
|
|
4182
|
+
borderRadius: e.radiusMd - 2
|
|
4183
|
+
},
|
|
4184
|
+
indicatorInset: 2,
|
|
4185
|
+
activeTextColor: e.accentColor,
|
|
4186
|
+
idleTextColor: e.windowFgColor
|
|
4187
|
+
};
|
|
4188
|
+
case "round": return {
|
|
4189
|
+
container: {
|
|
4190
|
+
backgroundColor: e.cardBgColor,
|
|
4191
|
+
borderWidth: 1,
|
|
4192
|
+
borderColor: r,
|
|
4193
|
+
borderRadius: e.radiusPill,
|
|
4194
|
+
padding: 2,
|
|
4195
|
+
gap: 2
|
|
4196
|
+
},
|
|
4197
|
+
gap: 2,
|
|
4198
|
+
padding: 2,
|
|
4199
|
+
item: {
|
|
4200
|
+
borderRadius: e.radiusPill,
|
|
4201
|
+
paddingHorizontal: e.space2
|
|
4202
|
+
},
|
|
4203
|
+
iconOnlyItem: {
|
|
4204
|
+
paddingHorizontal: 4,
|
|
4205
|
+
minWidth: 28
|
|
4206
|
+
},
|
|
4207
|
+
indicator: {
|
|
4208
|
+
backgroundColor: e.accentBgColor,
|
|
4209
|
+
borderRadius: e.radiusPill
|
|
4210
|
+
},
|
|
4211
|
+
indicatorInset: 2,
|
|
4212
|
+
activeTextColor: e.accentFgColor,
|
|
4213
|
+
idleTextColor: e.windowFgColor
|
|
4214
|
+
};
|
|
4215
|
+
case "pill": return {
|
|
4216
|
+
container: {
|
|
4217
|
+
backgroundColor: e.hoverOverlay,
|
|
4218
|
+
borderRadius: e.radiusPill,
|
|
4219
|
+
padding: 3,
|
|
4220
|
+
gap: 2
|
|
4221
|
+
},
|
|
4222
|
+
gap: 2,
|
|
4223
|
+
padding: 3,
|
|
4224
|
+
item: {
|
|
4225
|
+
borderRadius: e.radiusPill,
|
|
4226
|
+
paddingVertical: 5,
|
|
4227
|
+
paddingHorizontal: e.space2
|
|
4228
|
+
},
|
|
4229
|
+
iconOnlyItem: {
|
|
4230
|
+
paddingHorizontal: 5,
|
|
4231
|
+
minWidth: 28
|
|
4232
|
+
},
|
|
4233
|
+
indicator: {
|
|
4234
|
+
backgroundColor: e.cardBgColor,
|
|
4235
|
+
borderRadius: e.radiusPill
|
|
4236
|
+
},
|
|
4237
|
+
indicatorInset: 3,
|
|
4238
|
+
activeTextColor: e.windowFgColor,
|
|
4239
|
+
idleTextColor: e.windowFgColor
|
|
4240
|
+
};
|
|
4241
|
+
default: return {
|
|
4242
|
+
container: {
|
|
4243
|
+
backgroundColor: e.cardBgColor,
|
|
4244
|
+
borderWidth: 1,
|
|
4245
|
+
borderColor: r,
|
|
4246
|
+
borderRadius: e.radiusMd,
|
|
4247
|
+
padding: 2,
|
|
4248
|
+
gap: 2
|
|
4249
|
+
},
|
|
4250
|
+
gap: 2,
|
|
4251
|
+
padding: 2,
|
|
4252
|
+
item: {
|
|
4253
|
+
borderRadius: e.radiusMd - 2,
|
|
4254
|
+
paddingHorizontal: e.space2
|
|
4255
|
+
},
|
|
4256
|
+
iconOnlyItem: {
|
|
4257
|
+
paddingHorizontal: 4,
|
|
4258
|
+
minWidth: 28
|
|
4259
|
+
},
|
|
4260
|
+
indicator: {
|
|
4261
|
+
backgroundColor: i,
|
|
4262
|
+
borderRadius: e.radiusMd - 2,
|
|
4263
|
+
borderWidth: 1,
|
|
4264
|
+
borderColor: a
|
|
4265
|
+
},
|
|
4266
|
+
indicatorInset: 2,
|
|
4267
|
+
activeTextColor: e.accentColor,
|
|
4268
|
+
idleTextColor: e.windowFgColor
|
|
4269
|
+
};
|
|
4270
|
+
}
|
|
4271
|
+
}
|
|
4272
|
+
function Pn(e, t, n) {
|
|
4273
|
+
return {
|
|
4274
|
+
fontFamily: e.fontFamily,
|
|
4275
|
+
fontSize: e.fontSizeBody,
|
|
4276
|
+
fontWeight: String(t ? e.fontWeightSemibold : e.fontWeightNormal),
|
|
4277
|
+
color: n
|
|
4278
|
+
};
|
|
4279
|
+
}
|
|
4280
|
+
//#endregion
|
|
4281
|
+
//#region src/components/InlineViewSwitcher/InlineViewSwitcher.tsx
|
|
4282
|
+
var Fn = r(null);
|
|
4283
|
+
function In() {
|
|
4284
|
+
let e = s(Fn);
|
|
4285
|
+
if (!e) throw Error("InlineViewSwitcherItem must be used inside InlineViewSwitcher");
|
|
4286
|
+
return e;
|
|
4287
|
+
}
|
|
4288
|
+
var Ln = 160, Rn = 30, zn = i(function({ value: t, onValueChange: n, variant: r = "default", overflow: i = "wrap", accessibilityLabel: s = "View switcher", children: l, style: p, ...h }, g) {
|
|
4289
|
+
let _ = q(), v = K() === "dark", y = J(), b = u(() => Nn(_, r, v), [
|
|
4290
|
+
_,
|
|
4291
|
+
r,
|
|
4292
|
+
v
|
|
4293
|
+
]), [x, S] = f({}), [C, E] = f(0), [O, A] = f(!1), [P, F] = f(!1), L = d(0), R = d(new m.Value(0)).current, z = d(new m.Value(0)).current, B = o((e, t) => {
|
|
4294
|
+
S((n) => {
|
|
4295
|
+
let r = n[e];
|
|
4296
|
+
return r && r.x === t.x && r.width === t.width ? n : {
|
|
4297
|
+
...n,
|
|
4298
|
+
[e]: t
|
|
4299
|
+
};
|
|
4300
|
+
});
|
|
4301
|
+
}, []), V = i === "compact" || i === "menu", H = u(() => e.toArray(l).filter(a).filter((e) => e.type.displayName === "InlineViewSwitcherItem").map((e) => e.props), [l]), ee = u(() => {
|
|
4302
|
+
let e = H.map((e) => x[e.name]?.width ?? 0);
|
|
4303
|
+
if (e.some((e) => e === 0)) return 0;
|
|
4304
|
+
let t = Math.max(H.length - 1, 0) * b.gap;
|
|
4305
|
+
return e.reduce((e, t) => e + t, 0) + t + 2 * b.padding;
|
|
4306
|
+
}, [
|
|
4307
|
+
H,
|
|
4308
|
+
x,
|
|
4309
|
+
b.gap,
|
|
4310
|
+
b.padding
|
|
4311
|
+
]);
|
|
4312
|
+
c(() => {
|
|
4313
|
+
if (!V || C === 0 || ee === 0) {
|
|
4314
|
+
V || A(!1);
|
|
4315
|
+
return;
|
|
4316
|
+
}
|
|
4317
|
+
A((e) => e ? L.current > C + Rn : ee > C ? (L.current = ee, !0) : !1);
|
|
4318
|
+
}, [
|
|
4319
|
+
V,
|
|
4320
|
+
C,
|
|
4321
|
+
ee
|
|
4322
|
+
]);
|
|
4323
|
+
let te = i === "compact" && O, re = i === "menu" && O, U = H.find((e) => e.name === t) ?? H[0], W = x[t];
|
|
4324
|
+
c(() => {
|
|
4325
|
+
if (re || !W) return;
|
|
4326
|
+
if (y) {
|
|
4327
|
+
R.setValue(W.x), z.setValue(W.width);
|
|
4328
|
+
return;
|
|
4329
|
+
}
|
|
4330
|
+
let e = m.parallel([m.timing(R, {
|
|
4331
|
+
toValue: W.x,
|
|
4332
|
+
duration: Ln,
|
|
4333
|
+
useNativeDriver: !1
|
|
4334
|
+
}), m.timing(z, {
|
|
4335
|
+
toValue: W.width,
|
|
4336
|
+
duration: Ln,
|
|
4337
|
+
useNativeDriver: !1
|
|
4338
|
+
})]);
|
|
4339
|
+
return e.start(), () => e.stop();
|
|
4340
|
+
}, [
|
|
4341
|
+
W,
|
|
4342
|
+
re,
|
|
4343
|
+
y,
|
|
4344
|
+
R,
|
|
4345
|
+
z
|
|
4346
|
+
]);
|
|
4347
|
+
let ie = u(() => ({
|
|
4348
|
+
value: t,
|
|
4349
|
+
onValueChange: n,
|
|
4350
|
+
compact: te,
|
|
4351
|
+
styles: b,
|
|
4352
|
+
onItemLayout: B
|
|
4353
|
+
}), [
|
|
4354
|
+
t,
|
|
4355
|
+
n,
|
|
4356
|
+
te,
|
|
4357
|
+
b,
|
|
4358
|
+
B
|
|
4359
|
+
]), ae = o((e) => {
|
|
4360
|
+
V && E(e.nativeEvent.layout.width);
|
|
4361
|
+
}, [V]), oe = u(() => i === "scroll" ? H.map((e) => x[e.name]?.x ?? 0).filter((e, t) => t === 0 || e > 0) : void 0, [
|
|
4362
|
+
i,
|
|
4363
|
+
H,
|
|
4364
|
+
x
|
|
4365
|
+
]), se = /* @__PURE__ */ M(k, {
|
|
4366
|
+
ref: g,
|
|
4367
|
+
accessibilityRole: re ? void 0 : "radiogroup",
|
|
4368
|
+
accessibilityLabel: s,
|
|
4369
|
+
onLayout: ae,
|
|
4370
|
+
style: [
|
|
4371
|
+
{
|
|
4372
|
+
flexDirection: "row",
|
|
4373
|
+
alignItems: "stretch"
|
|
4374
|
+
},
|
|
4375
|
+
b.container,
|
|
4376
|
+
V ? { width: "100%" } : { alignSelf: "flex-start" },
|
|
4377
|
+
p
|
|
4378
|
+
],
|
|
4379
|
+
...h,
|
|
4380
|
+
children: re ? /* @__PURE__ */ N(w, {
|
|
4381
|
+
accessibilityRole: "button",
|
|
4382
|
+
accessibilityLabel: `${s}: ${U?.label ?? U?.name}`,
|
|
4383
|
+
onPress: () => F(!0),
|
|
4384
|
+
style: [{
|
|
4385
|
+
flexDirection: "row",
|
|
4386
|
+
alignItems: "center",
|
|
4387
|
+
justifyContent: "center",
|
|
4388
|
+
gap: _.space1,
|
|
4389
|
+
minHeight: 28,
|
|
4390
|
+
paddingVertical: 4
|
|
4391
|
+
}, b.item],
|
|
4392
|
+
children: [
|
|
4393
|
+
U?.icon ? /* @__PURE__ */ M(X, {
|
|
4394
|
+
icon: U.icon,
|
|
4395
|
+
size: "md"
|
|
4396
|
+
}) : null,
|
|
4397
|
+
U?.label ? /* @__PURE__ */ M(D, {
|
|
4398
|
+
style: Pn(_, !0, b.idleTextColor),
|
|
4399
|
+
children: U.label
|
|
4400
|
+
}) : null,
|
|
4401
|
+
/* @__PURE__ */ M(X, {
|
|
4402
|
+
icon: ne,
|
|
4403
|
+
size: "sm"
|
|
4404
|
+
})
|
|
4405
|
+
]
|
|
4406
|
+
}) : /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M(m.View, {
|
|
4407
|
+
pointerEvents: "none",
|
|
4408
|
+
style: [{
|
|
4409
|
+
position: "absolute",
|
|
4410
|
+
left: 0,
|
|
4411
|
+
top: b.indicatorInset,
|
|
4412
|
+
bottom: b.indicatorInset,
|
|
4413
|
+
width: z,
|
|
4414
|
+
transform: [{ translateX: R }]
|
|
4415
|
+
}, b.indicator]
|
|
4416
|
+
}), l] })
|
|
4417
|
+
});
|
|
4418
|
+
return /* @__PURE__ */ N(Fn.Provider, {
|
|
4419
|
+
value: ie,
|
|
4420
|
+
children: [i === "scroll" ? /* @__PURE__ */ M(T, {
|
|
4421
|
+
horizontal: !0,
|
|
4422
|
+
showsHorizontalScrollIndicator: !1,
|
|
4423
|
+
snapToOffsets: oe,
|
|
4424
|
+
decelerationRate: "fast",
|
|
4425
|
+
contentContainerStyle: { flexGrow: 0 },
|
|
4426
|
+
style: { flexGrow: 0 },
|
|
4427
|
+
children: se
|
|
4428
|
+
}) : se, i === "menu" ? /* @__PURE__ */ M(wt, {
|
|
4429
|
+
open: P,
|
|
4430
|
+
title: s,
|
|
4431
|
+
onClose: () => F(!1),
|
|
4432
|
+
children: /* @__PURE__ */ M(k, {
|
|
4433
|
+
accessibilityRole: "radiogroup",
|
|
4434
|
+
accessibilityLabel: s,
|
|
4435
|
+
children: H.map((e) => {
|
|
4436
|
+
let r = e.name === t;
|
|
4437
|
+
return /* @__PURE__ */ N(w, {
|
|
4438
|
+
accessibilityRole: "radio",
|
|
4439
|
+
accessibilityState: { checked: r },
|
|
4440
|
+
accessibilityLabel: e.label ?? e.name,
|
|
4441
|
+
onPress: () => {
|
|
4442
|
+
n(e.name), F(!1);
|
|
4443
|
+
},
|
|
4444
|
+
style: ({ pressed: e }) => ({
|
|
4445
|
+
flexDirection: "row",
|
|
4446
|
+
alignItems: "center",
|
|
4447
|
+
gap: _.space2,
|
|
4448
|
+
paddingVertical: _.space2,
|
|
4449
|
+
paddingHorizontal: _.space3,
|
|
4450
|
+
borderRadius: _.radiusMd,
|
|
4451
|
+
backgroundColor: e ? _.activeOverlay : "transparent"
|
|
4452
|
+
}),
|
|
4453
|
+
children: [
|
|
4454
|
+
e.icon ? /* @__PURE__ */ M(X, {
|
|
4455
|
+
icon: e.icon,
|
|
4456
|
+
size: "md"
|
|
4457
|
+
}) : null,
|
|
4458
|
+
/* @__PURE__ */ M(D, {
|
|
4459
|
+
style: [Pn(_, r, r ? _.accentColor : _.windowFgColor), { flex: 1 }],
|
|
4460
|
+
children: e.label ?? e.name
|
|
4461
|
+
}),
|
|
4462
|
+
r ? /* @__PURE__ */ M(X, {
|
|
4463
|
+
icon: I,
|
|
4464
|
+
size: "md"
|
|
4465
|
+
}) : null
|
|
4466
|
+
]
|
|
4467
|
+
}, e.name);
|
|
4468
|
+
})
|
|
4469
|
+
})
|
|
4470
|
+
}) : null]
|
|
4471
|
+
});
|
|
4472
|
+
}), Bn = i(function({ name: e, label: t, icon: n, accessibilityLabel: r, disabled: i = !1, ...a }, s) {
|
|
4473
|
+
let c = q(), { value: l, onValueChange: u, compact: d, styles: f, onItemLayout: p } = In(), m = l === e, h = !!t && !(d && n), g = !!n && !h;
|
|
4474
|
+
return /* @__PURE__ */ N(w, {
|
|
4475
|
+
ref: s,
|
|
4476
|
+
disabled: i,
|
|
4477
|
+
onPress: () => u(e),
|
|
4478
|
+
onLayout: o((t) => {
|
|
4479
|
+
let { x: n, width: r } = t.nativeEvent.layout;
|
|
4480
|
+
p(e, {
|
|
4481
|
+
x: n,
|
|
4482
|
+
width: r
|
|
4483
|
+
});
|
|
4484
|
+
}, [e, p]),
|
|
4485
|
+
accessibilityRole: "radio",
|
|
4486
|
+
accessibilityState: {
|
|
4487
|
+
checked: m,
|
|
4488
|
+
disabled: i
|
|
4489
|
+
},
|
|
4490
|
+
accessibilityLabel: r ?? t,
|
|
4491
|
+
style: [
|
|
4492
|
+
{
|
|
4493
|
+
flexDirection: "row",
|
|
4494
|
+
alignItems: "center",
|
|
4495
|
+
justifyContent: "center",
|
|
4496
|
+
gap: c.space1,
|
|
4497
|
+
minHeight: 28,
|
|
4498
|
+
paddingVertical: 4,
|
|
4499
|
+
opacity: i ? c.opacityDisabled : 1
|
|
4500
|
+
},
|
|
4501
|
+
f.item,
|
|
4502
|
+
g ? f.iconOnlyItem : null
|
|
4503
|
+
],
|
|
4504
|
+
...a,
|
|
4505
|
+
children: [n ? /* @__PURE__ */ M(X, {
|
|
4506
|
+
icon: n,
|
|
4507
|
+
size: "md"
|
|
4508
|
+
}) : null, h ? /* @__PURE__ */ M(D, {
|
|
4509
|
+
numberOfLines: 1,
|
|
4510
|
+
style: Pn(c, m, m ? f.activeTextColor : f.idleTextColor),
|
|
4511
|
+
children: t
|
|
4512
|
+
}) : null]
|
|
4513
|
+
});
|
|
4514
|
+
});
|
|
4515
|
+
Bn.displayName = "InlineViewSwitcherItem";
|
|
4516
|
+
//#endregion
|
|
3611
4517
|
//#region src/components/LevelBar/LevelBar.tsx
|
|
3612
|
-
function
|
|
4518
|
+
function Vn(e, t, n, r, i, a) {
|
|
3613
4519
|
return t !== void 0 && e <= t ? n : r !== void 0 && e >= r ? i : a;
|
|
3614
4520
|
}
|
|
3615
|
-
function
|
|
4521
|
+
function Hn(e, t) {
|
|
3616
4522
|
switch (t) {
|
|
3617
4523
|
case "accent": return e.accentBgColor;
|
|
3618
4524
|
case "success": return e.successBgColor;
|
|
@@ -3620,8 +4526,8 @@ function pn(e, t) {
|
|
|
3620
4526
|
case "error": return e.errorBgColor;
|
|
3621
4527
|
}
|
|
3622
4528
|
}
|
|
3623
|
-
var
|
|
3624
|
-
let g =
|
|
4529
|
+
var Un = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning", high: a, highVariant: o = "error", variant: s = "accent", discrete: l = !1, numBlocks: u = 10, accessibilityLabel: f, style: p, testID: h }) => {
|
|
4530
|
+
let g = q(), v = K(), y = J(), b = n - t, x = Math.min(n, Math.max(t, e)), S = b > 0 ? (x - t) / b : 0, C = Vn(x, r, i, a, o, s), w = d(new m.Value(S)).current;
|
|
3625
4531
|
c(() => {
|
|
3626
4532
|
if (l) return;
|
|
3627
4533
|
let [e, t, n, r] = g.easingDefault;
|
|
@@ -3668,7 +4574,7 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3668
4574
|
height: "100%",
|
|
3669
4575
|
minWidth: 2,
|
|
3670
4576
|
borderRadius: 1,
|
|
3671
|
-
backgroundColor: (t + 1) / u <= S ?
|
|
4577
|
+
backgroundColor: (t + 1) / u <= S ? Hn(g, C) : T
|
|
3672
4578
|
}
|
|
3673
4579
|
}, t)) : /* @__PURE__ */ M(m.View, {
|
|
3674
4580
|
testID: h ? `${h}-fill` : void 0,
|
|
@@ -3676,14 +4582,14 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3676
4582
|
width: "100%",
|
|
3677
4583
|
height: "100%",
|
|
3678
4584
|
borderRadius: g.radiusPill,
|
|
3679
|
-
backgroundColor:
|
|
4585
|
+
backgroundColor: Hn(g, C),
|
|
3680
4586
|
transformOrigin: "left",
|
|
3681
4587
|
transform: [{ scaleX: w }]
|
|
3682
4588
|
}
|
|
3683
4589
|
})
|
|
3684
4590
|
});
|
|
3685
|
-
},
|
|
3686
|
-
let c =
|
|
4591
|
+
}, Wn = i(function({ href: e, external: t = !1, children: n, style: r, textStyle: i, onPress: a, ...o }, s) {
|
|
4592
|
+
let c = q();
|
|
3687
4593
|
return /* @__PURE__ */ M(w, {
|
|
3688
4594
|
ref: s,
|
|
3689
4595
|
accessibilityRole: "link",
|
|
@@ -3691,7 +4597,7 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3691
4597
|
onPress: a ?? (() => b.openURL(e)),
|
|
3692
4598
|
style: r,
|
|
3693
4599
|
...o,
|
|
3694
|
-
children: ({ pressed: e }) => /* @__PURE__ */ N(
|
|
4600
|
+
children: ({ pressed: e }) => /* @__PURE__ */ N(Y, {
|
|
3695
4601
|
style: [{
|
|
3696
4602
|
color: c.accentColor,
|
|
3697
4603
|
textDecorationLine: e ? "underline" : "none",
|
|
@@ -3705,8 +4611,8 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3705
4611
|
})]
|
|
3706
4612
|
})
|
|
3707
4613
|
});
|
|
3708
|
-
}),
|
|
3709
|
-
let a =
|
|
4614
|
+
}), Gn = m.createAnimatedComponent(w), Kn = ({ open: e, onDismiss: t, children: n, style: r, testID: i }) => {
|
|
4615
|
+
let a = q(), o = J(), [s, l] = f(e), u = d(new m.Value(+!!e)).current;
|
|
3710
4616
|
return c(() => {
|
|
3711
4617
|
e && l(!0);
|
|
3712
4618
|
}, [e]), c(() => {
|
|
@@ -3744,7 +4650,7 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3744
4650
|
transparent: !0,
|
|
3745
4651
|
animationType: "none",
|
|
3746
4652
|
statusBarTranslucent: !0,
|
|
3747
|
-
children: /* @__PURE__ */ M(
|
|
4653
|
+
children: /* @__PURE__ */ M(Gn, {
|
|
3748
4654
|
testID: i,
|
|
3749
4655
|
onPress: t,
|
|
3750
4656
|
accessible: !1,
|
|
@@ -3762,8 +4668,8 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3762
4668
|
})
|
|
3763
4669
|
})
|
|
3764
4670
|
}) : null;
|
|
3765
|
-
},
|
|
3766
|
-
let a =
|
|
4671
|
+
}, qn = ({ segments: e, onNavigate: n, style: r, ...i }) => {
|
|
4672
|
+
let a = q();
|
|
3767
4673
|
return /* @__PURE__ */ M(k, {
|
|
3768
4674
|
style: [{
|
|
3769
4675
|
flexDirection: "row",
|
|
@@ -3836,8 +4742,8 @@ var mn = ({ value: e, min: t = 0, max: n = 1, low: r, lowVariant: i = "warning",
|
|
|
3836
4742
|
})] }, r.path);
|
|
3837
4743
|
})
|
|
3838
4744
|
});
|
|
3839
|
-
},
|
|
3840
|
-
function
|
|
4745
|
+
}, Jn = 8, $ = 10, Yn = 6;
|
|
4746
|
+
function Xn(e, t) {
|
|
3841
4747
|
if (e) {
|
|
3842
4748
|
if (typeof e == "function") {
|
|
3843
4749
|
e(t);
|
|
@@ -3846,27 +4752,27 @@ function bn(e, t) {
|
|
|
3846
4752
|
e.current = t;
|
|
3847
4753
|
}
|
|
3848
4754
|
}
|
|
3849
|
-
function
|
|
4755
|
+
function Zn(e, t, n) {
|
|
3850
4756
|
switch (n) {
|
|
3851
4757
|
case "top": return {
|
|
3852
|
-
top: e.y - t.height -
|
|
4758
|
+
top: e.y - t.height - Jn,
|
|
3853
4759
|
left: e.x + e.width / 2 - t.width / 2
|
|
3854
4760
|
};
|
|
3855
4761
|
case "bottom": return {
|
|
3856
|
-
top: e.y + e.height +
|
|
4762
|
+
top: e.y + e.height + Jn,
|
|
3857
4763
|
left: e.x + e.width / 2 - t.width / 2
|
|
3858
4764
|
};
|
|
3859
4765
|
case "left": return {
|
|
3860
4766
|
top: e.y + e.height / 2 - t.height / 2,
|
|
3861
|
-
left: e.x - t.width -
|
|
4767
|
+
left: e.x - t.width - Jn
|
|
3862
4768
|
};
|
|
3863
4769
|
case "right": return {
|
|
3864
4770
|
top: e.y + e.height / 2 - t.height / 2,
|
|
3865
|
-
left: e.x + e.width +
|
|
4771
|
+
left: e.x + e.width + Jn
|
|
3866
4772
|
};
|
|
3867
4773
|
}
|
|
3868
4774
|
}
|
|
3869
|
-
function
|
|
4775
|
+
function Qn(e, t, n) {
|
|
3870
4776
|
let { width: r, height: i } = g.get("window"), a = [
|
|
3871
4777
|
n,
|
|
3872
4778
|
n === "top" ? "bottom" : n === "bottom" ? "top" : n === "left" ? "right" : "left",
|
|
@@ -3876,22 +4782,22 @@ function Sn(e, t, n) {
|
|
|
3876
4782
|
"right"
|
|
3877
4783
|
];
|
|
3878
4784
|
for (let n of a) {
|
|
3879
|
-
let { top: a, left: o } =
|
|
4785
|
+
let { top: a, left: o } = Zn(e, t, n), s = o >= $ && o + t.width <= r - $, c = a >= $ && a + t.height <= i - $;
|
|
3880
4786
|
if (s && c) return {
|
|
3881
|
-
top: Math.max(
|
|
3882
|
-
left: Math.max(
|
|
4787
|
+
top: Math.max($, Math.min(a, i - t.height - $)),
|
|
4788
|
+
left: Math.max($, Math.min(o, r - t.width - $)),
|
|
3883
4789
|
placement: n
|
|
3884
4790
|
};
|
|
3885
4791
|
}
|
|
3886
|
-
let { top: o, left: s } =
|
|
4792
|
+
let { top: o, left: s } = Zn(e, t, n);
|
|
3887
4793
|
return {
|
|
3888
|
-
top: Math.max(
|
|
3889
|
-
left: Math.max(
|
|
4794
|
+
top: Math.max($, Math.min(o, i - t.height - $)),
|
|
4795
|
+
left: Math.max($, Math.min(s, r - t.width - $)),
|
|
3890
4796
|
placement: n
|
|
3891
4797
|
};
|
|
3892
4798
|
}
|
|
3893
|
-
var
|
|
3894
|
-
let l =
|
|
4799
|
+
var $n = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panelStyle: a, children: s }) => {
|
|
4800
|
+
let l = q(), u = J(), p = r !== void 0, [g, _] = f(!1), v = p ? r : g, [y, b] = f(null), [S, C] = f(null), [T, E] = f(null), D = d(null), O = d(new m.Value(0)).current, A = o((e) => {
|
|
3895
4801
|
p || _(e), i?.(e);
|
|
3896
4802
|
}, [p, i]), P = o(() => A(!1), [A]), F = o(() => A(!v), [v, A]);
|
|
3897
4803
|
c(() => {
|
|
@@ -3908,7 +4814,7 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
3908
4814
|
});
|
|
3909
4815
|
});
|
|
3910
4816
|
}, [v]), c(() => {
|
|
3911
|
-
!y || !S || E(
|
|
4817
|
+
!y || !S || E(Qn(y, S, t));
|
|
3912
4818
|
}, [
|
|
3913
4819
|
y,
|
|
3914
4820
|
S,
|
|
@@ -3945,7 +4851,7 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
3945
4851
|
position: "absolute",
|
|
3946
4852
|
width: 0,
|
|
3947
4853
|
height: 0,
|
|
3948
|
-
borderWidth:
|
|
4854
|
+
borderWidth: Yn,
|
|
3949
4855
|
borderColor: "transparent"
|
|
3950
4856
|
}, R = (() => {
|
|
3951
4857
|
switch (T?.placement) {
|
|
@@ -3982,7 +4888,7 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
3982
4888
|
})(), z = s.props.ref;
|
|
3983
4889
|
return /* @__PURE__ */ N(j, { children: [n(s, {
|
|
3984
4890
|
ref: (e) => {
|
|
3985
|
-
D.current = e,
|
|
4891
|
+
D.current = e, Xn(z, e);
|
|
3986
4892
|
},
|
|
3987
4893
|
accessibilityState: {
|
|
3988
4894
|
expanded: v,
|
|
@@ -4040,8 +4946,41 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
4040
4946
|
})
|
|
4041
4947
|
})
|
|
4042
4948
|
})] });
|
|
4043
|
-
},
|
|
4044
|
-
let
|
|
4949
|
+
}, er = i(function({ title: e, description: t, headerSuffix: n, children: r, style: i, ...a }, o) {
|
|
4950
|
+
let s = q(), c = !!(e || t || n);
|
|
4951
|
+
return /* @__PURE__ */ N(k, {
|
|
4952
|
+
ref: o,
|
|
4953
|
+
style: [{ gap: s.space2 }, i],
|
|
4954
|
+
...a,
|
|
4955
|
+
children: [c ? /* @__PURE__ */ N(k, {
|
|
4956
|
+
style: {
|
|
4957
|
+
flexDirection: "row",
|
|
4958
|
+
alignItems: "baseline",
|
|
4959
|
+
gap: s.space2
|
|
4960
|
+
},
|
|
4961
|
+
children: [/* @__PURE__ */ N(k, {
|
|
4962
|
+
style: {
|
|
4963
|
+
flex: 1,
|
|
4964
|
+
gap: 2
|
|
4965
|
+
},
|
|
4966
|
+
children: [e ? /* @__PURE__ */ M(Y, {
|
|
4967
|
+
variant: "body",
|
|
4968
|
+
accessibilityRole: "header",
|
|
4969
|
+
style: { fontWeight: String(s.fontWeightSemibold) },
|
|
4970
|
+
children: e
|
|
4971
|
+
}) : null, t ? /* @__PURE__ */ M(Y, {
|
|
4972
|
+
variant: "caption",
|
|
4973
|
+
color: "dim",
|
|
4974
|
+
children: t
|
|
4975
|
+
}) : null]
|
|
4976
|
+
}), n ? /* @__PURE__ */ M(k, {
|
|
4977
|
+
style: { flexShrink: 0 },
|
|
4978
|
+
children: n
|
|
4979
|
+
}) : null]
|
|
4980
|
+
}) : null, /* @__PURE__ */ M(k, { children: r })]
|
|
4981
|
+
});
|
|
4982
|
+
}), tr = ({ value: e, variant: t = "accent", accessibilityLabel: n, style: r, onLayout: i, ...a }) => {
|
|
4983
|
+
let o = q(), s = K(), l = J(), u = e == null, p = u ? void 0 : Math.min(1, Math.max(0, e)), h = p === void 0 ? void 0 : p * 100, g = d(new m.Value(p ?? 0)).current, v = d(new m.Value(0)).current, [y, b] = f(0), x = (e) => {
|
|
4045
4984
|
b(e.nativeEvent.layout.width), i?.(e);
|
|
4046
4985
|
};
|
|
4047
4986
|
c(() => {
|
|
@@ -4123,8 +5062,8 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
4123
5062
|
backgroundColor: C[t]
|
|
4124
5063
|
}, w] })
|
|
4125
5064
|
});
|
|
4126
|
-
},
|
|
4127
|
-
let o =
|
|
5065
|
+
}, nr = 18, rr = 6, ir = i(function({ value: e, onSelect: t, disabled: n, style: r, ...i }, a) {
|
|
5066
|
+
let o = q(), s = K(), l = Oe(), u = d(new m.Value(+!!e)).current, f = d(!0);
|
|
4128
5067
|
c(() => {
|
|
4129
5068
|
if (f.current) {
|
|
4130
5069
|
f.current = !1;
|
|
@@ -4165,8 +5104,8 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
4165
5104
|
...i,
|
|
4166
5105
|
children: /* @__PURE__ */ M(m.View, {
|
|
4167
5106
|
style: {
|
|
4168
|
-
width:
|
|
4169
|
-
height:
|
|
5107
|
+
width: nr,
|
|
5108
|
+
height: nr,
|
|
4170
5109
|
alignItems: "center",
|
|
4171
5110
|
justifyContent: "center",
|
|
4172
5111
|
borderRadius: o.radiusPill,
|
|
@@ -4175,8 +5114,8 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
4175
5114
|
backgroundColor: g
|
|
4176
5115
|
},
|
|
4177
5116
|
children: /* @__PURE__ */ M(m.View, { style: {
|
|
4178
|
-
width:
|
|
4179
|
-
height:
|
|
5117
|
+
width: rr,
|
|
5118
|
+
height: rr,
|
|
4180
5119
|
borderRadius: o.radiusPill,
|
|
4181
5120
|
backgroundColor: "#fff",
|
|
4182
5121
|
opacity: u
|
|
@@ -4186,14 +5125,14 @@ var Cn = ({ content: e, placement: t = "bottom", open: r, onOpenChange: i, panel
|
|
|
4186
5125
|
});
|
|
4187
5126
|
//#endregion
|
|
4188
5127
|
//#region src/components/SearchBar/SearchBar.tsx
|
|
4189
|
-
function
|
|
5128
|
+
function ar(e, t) {
|
|
4190
5129
|
let n = e.match(/^rgba?\(([^,]+),([^,]+),([^,]+),?([^)]+)?\)$/);
|
|
4191
5130
|
if (!n) return e;
|
|
4192
5131
|
let [, r, i, a, o] = n, s = (o ? Number.parseFloat(o) : 1) * t;
|
|
4193
5132
|
return `rgba(${r.trim()}, ${i.trim()}, ${a.trim()}, ${s})`;
|
|
4194
5133
|
}
|
|
4195
|
-
var
|
|
4196
|
-
let g =
|
|
5134
|
+
var or = i(function({ open: e, onClose: t, onClear: n, children: r, value: i, placeholder: a = "Search…", editable: o = !0, inline: s = !1, closeLabel: u = "Cancel", style: f, inputStyle: p, ...m }, h) {
|
|
5135
|
+
let g = q(), _ = d(null);
|
|
4197
5136
|
if (l(h, () => _.current, []), c(() => {
|
|
4198
5137
|
if (!e) return;
|
|
4199
5138
|
let t = requestAnimationFrame(() => _.current?.focus());
|
|
@@ -4236,7 +5175,7 @@ var kn = i(function({ open: e, onClose: t, onClear: n, children: r, value: i, pl
|
|
|
4236
5175
|
editable: o,
|
|
4237
5176
|
value: i,
|
|
4238
5177
|
placeholder: a,
|
|
4239
|
-
placeholderTextColor:
|
|
5178
|
+
placeholderTextColor: ar(g.windowFgColor, g.opacityDim),
|
|
4240
5179
|
style: [{
|
|
4241
5180
|
flex: 1,
|
|
4242
5181
|
padding: 0,
|
|
@@ -4301,9 +5240,9 @@ var kn = i(function({ open: e, onClose: t, onClear: n, children: r, value: i, pl
|
|
|
4301
5240
|
children: r
|
|
4302
5241
|
})]
|
|
4303
5242
|
});
|
|
4304
|
-
}),
|
|
4305
|
-
function
|
|
4306
|
-
switch (t %
|
|
5243
|
+
}), sr = 8;
|
|
5244
|
+
function cr(e, t) {
|
|
5245
|
+
switch (t % sr) {
|
|
4307
5246
|
case 0: return e.blue3;
|
|
4308
5247
|
case 1: return e.green3;
|
|
4309
5248
|
case 2: return e.purple3;
|
|
@@ -4314,8 +5253,8 @@ function jn(e, t) {
|
|
|
4314
5253
|
default: return e.green5;
|
|
4315
5254
|
}
|
|
4316
5255
|
}
|
|
4317
|
-
var
|
|
4318
|
-
let i =
|
|
5256
|
+
var lr = ({ values: e, accessibilityLabel: t, style: n, testID: r }) => {
|
|
5257
|
+
let i = q(), a = K(), [o, s] = f(null), c = e.reduce((e, t) => e + t.value, 0) || 100, l = e.map((e) => `${e.label} ${e.value}%`).join(", "), u = a === "dark" ? i.dark2 : i.light3;
|
|
4319
5258
|
return /* @__PURE__ */ M(k, {
|
|
4320
5259
|
testID: r,
|
|
4321
5260
|
accessible: !0,
|
|
@@ -4332,7 +5271,7 @@ var Mn = ({ values: e, accessibilityLabel: t, style: n, testID: r }) => {
|
|
|
4332
5271
|
}, n],
|
|
4333
5272
|
children: e.map((e, t) => {
|
|
4334
5273
|
let n = `${e.value / c * 100}%`, r = e.value % 1 == 0 ? e.value : e.value.toFixed(1);
|
|
4335
|
-
return /* @__PURE__ */ M(
|
|
5274
|
+
return /* @__PURE__ */ M(an, {
|
|
4336
5275
|
label: `${e.label}: ${r}%`,
|
|
4337
5276
|
placement: "top",
|
|
4338
5277
|
delay: 200,
|
|
@@ -4343,7 +5282,7 @@ var Mn = ({ values: e, accessibilityLabel: t, style: n, testID: r }) => {
|
|
|
4343
5282
|
style: {
|
|
4344
5283
|
width: n,
|
|
4345
5284
|
height: "100%",
|
|
4346
|
-
backgroundColor: e.color ??
|
|
5285
|
+
backgroundColor: e.color ?? cr(i, t),
|
|
4347
5286
|
opacity: o !== null && o !== t ? .35 : 1
|
|
4348
5287
|
}
|
|
4349
5288
|
})
|
|
@@ -4353,30 +5292,30 @@ var Mn = ({ values: e, accessibilityLabel: t, style: n, testID: r }) => {
|
|
|
4353
5292
|
};
|
|
4354
5293
|
//#endregion
|
|
4355
5294
|
//#region src/components/Sidebar/filterUtils.ts
|
|
4356
|
-
function
|
|
5295
|
+
function ur(t, n) {
|
|
4357
5296
|
let r = 0;
|
|
4358
5297
|
return e.forEach(t, (e) => {
|
|
4359
5298
|
if (!a(e)) return;
|
|
4360
5299
|
let t = e.props;
|
|
4361
|
-
typeof t.label == "string" ? t.label.toLowerCase().includes(n.toLowerCase()) && r++ : t.children && (r +=
|
|
5300
|
+
typeof t.label == "string" ? t.label.toLowerCase().includes(n.toLowerCase()) && r++ : t.children && (r += ur(t.children, n));
|
|
4362
5301
|
}), r;
|
|
4363
5302
|
}
|
|
4364
|
-
function
|
|
5303
|
+
function dr(e, t) {
|
|
4365
5304
|
if (!t || !a(e)) return !0;
|
|
4366
5305
|
let n = e.props;
|
|
4367
|
-
return typeof n.label == "string" ? n.label.toLowerCase().includes(t.toLowerCase()) : n.children ?
|
|
5306
|
+
return typeof n.label == "string" ? n.label.toLowerCase().includes(t.toLowerCase()) : n.children ? ur(n.children, t) > 0 : !0;
|
|
4368
5307
|
}
|
|
4369
5308
|
//#endregion
|
|
4370
5309
|
//#region src/components/Sidebar/Sidebar.tsx
|
|
4371
|
-
var
|
|
4372
|
-
function
|
|
4373
|
-
return s(
|
|
5310
|
+
var fr = r(!1);
|
|
5311
|
+
function pr() {
|
|
5312
|
+
return s(fr);
|
|
4374
5313
|
}
|
|
4375
|
-
var
|
|
4376
|
-
let c =
|
|
4377
|
-
return /* @__PURE__ */ M(
|
|
5314
|
+
var mr = r(""), hr = i(function({ children: n, collapsed: r = !1, filter: i = "", style: a, ...o }, s) {
|
|
5315
|
+
let c = q(), l = i.length > 0, u = e.toArray(n).filter(Boolean).filter((e) => dr(e, i)), d = !l || u.length > 0;
|
|
5316
|
+
return /* @__PURE__ */ M(fr.Provider, {
|
|
4378
5317
|
value: r,
|
|
4379
|
-
children: /* @__PURE__ */ M(
|
|
5318
|
+
children: /* @__PURE__ */ M(mr.Provider, {
|
|
4380
5319
|
value: i,
|
|
4381
5320
|
children: /* @__PURE__ */ M(k, {
|
|
4382
5321
|
ref: s,
|
|
@@ -4390,7 +5329,7 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4390
5329
|
...o,
|
|
4391
5330
|
children: /* @__PURE__ */ M(T, {
|
|
4392
5331
|
contentContainerStyle: { padding: c.space1 },
|
|
4393
|
-
children: l && !d ? /* @__PURE__ */ M(
|
|
5332
|
+
children: l && !d ? /* @__PURE__ */ M(Y, {
|
|
4394
5333
|
variant: "caption",
|
|
4395
5334
|
color: "dim",
|
|
4396
5335
|
style: {
|
|
@@ -4398,7 +5337,7 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4398
5337
|
padding: c.space4
|
|
4399
5338
|
},
|
|
4400
5339
|
children: "No items match your search."
|
|
4401
|
-
}) : u.map((e, n) => /* @__PURE__ */ N(t, { children: [n > 0 && /* @__PURE__ */ M(
|
|
5340
|
+
}) : u.map((e, n) => /* @__PURE__ */ N(t, { children: [n > 0 && /* @__PURE__ */ M(Ot, {
|
|
4402
5341
|
testID: "sidebar-separator",
|
|
4403
5342
|
style: { marginVertical: c.space1 }
|
|
4404
5343
|
}), e] }, n))
|
|
@@ -4406,8 +5345,8 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4406
5345
|
})
|
|
4407
5346
|
})
|
|
4408
5347
|
});
|
|
4409
|
-
}),
|
|
4410
|
-
let l =
|
|
5348
|
+
}), gr = i(function({ label: e, icon: t, active: n = !1, suffix: r, disabled: i, style: a, ...o }, c) {
|
|
5349
|
+
let l = q(), u = pr(), d = s(mr);
|
|
4411
5350
|
return d.length > 0 && !e.toLowerCase().includes(d.toLowerCase()) ? null : /* @__PURE__ */ N(w, {
|
|
4412
5351
|
ref: c,
|
|
4413
5352
|
disabled: i,
|
|
@@ -4443,7 +5382,7 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4443
5382
|
},
|
|
4444
5383
|
children: t
|
|
4445
5384
|
}),
|
|
4446
|
-
!u && /* @__PURE__ */ M(
|
|
5385
|
+
!u && /* @__PURE__ */ M(Y, {
|
|
4447
5386
|
numberOfLines: 1,
|
|
4448
5387
|
ellipsizeMode: "tail",
|
|
4449
5388
|
style: {
|
|
@@ -4460,15 +5399,15 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4460
5399
|
})
|
|
4461
5400
|
]
|
|
4462
5401
|
});
|
|
4463
|
-
}),
|
|
4464
|
-
let p =
|
|
5402
|
+
}), _r = i(function({ title: e, icon: t, collapsible: n = !1, defaultOpen: r = !0, open: i, onOpenChange: a, children: o, style: c, ...u }, d) {
|
|
5403
|
+
let p = q(), [m, h] = f(r), g = i !== void 0, _ = g ? i : m, v = pr(), y = s(mr), b = (e) => {
|
|
4465
5404
|
g || h(e), a?.(e);
|
|
4466
5405
|
};
|
|
4467
5406
|
if (l(d, () => ({
|
|
4468
5407
|
expand: () => b(!0),
|
|
4469
5408
|
collapse: () => b(!1),
|
|
4470
5409
|
toggle: () => b(!_)
|
|
4471
|
-
})), !(y.length === 0 ||
|
|
5410
|
+
})), !(y.length === 0 || ur(o, y) > 0)) return null;
|
|
4472
5411
|
let x = v ? !0 : _, S = !v && !!(e || t), C = (e || t) && /* @__PURE__ */ N(k, {
|
|
4473
5412
|
style: {
|
|
4474
5413
|
flexDirection: "row",
|
|
@@ -4487,14 +5426,14 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4487
5426
|
},
|
|
4488
5427
|
children: t
|
|
4489
5428
|
}),
|
|
4490
|
-
e && /* @__PURE__ */ M(
|
|
5429
|
+
e && /* @__PURE__ */ M(Y, {
|
|
4491
5430
|
variant: "caption-heading",
|
|
4492
5431
|
color: "dim",
|
|
4493
5432
|
style: { flex: 1 },
|
|
4494
5433
|
numberOfLines: 1,
|
|
4495
5434
|
children: e
|
|
4496
5435
|
}),
|
|
4497
|
-
n && /* @__PURE__ */ M(
|
|
5436
|
+
n && /* @__PURE__ */ M(Y, {
|
|
4498
5437
|
variant: "caption",
|
|
4499
5438
|
color: "dim",
|
|
4500
5439
|
style: { flexShrink: 0 },
|
|
@@ -4521,8 +5460,8 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4521
5460
|
children: o
|
|
4522
5461
|
})]
|
|
4523
5462
|
});
|
|
4524
|
-
}),
|
|
4525
|
-
let l =
|
|
5463
|
+
}), vr = ({ variant: e = "rect", width: t = "100%", height: n = 16, size: r = 40, lines: i = 3, animated: a = !0, style: o, ...s }) => {
|
|
5464
|
+
let l = q(), u = J(), f = d(new m.Value(1)).current, p = a && !u;
|
|
4526
5465
|
if (c(() => {
|
|
4527
5466
|
if (!p) {
|
|
4528
5467
|
f.setValue(1);
|
|
@@ -4580,22 +5519,22 @@ var Ln = r(""), Rn = i(function({ children: n, collapsed: r = !1, filter: i = ""
|
|
|
4580
5519
|
],
|
|
4581
5520
|
...s
|
|
4582
5521
|
});
|
|
4583
|
-
},
|
|
4584
|
-
function
|
|
5522
|
+
}, yr = 6, br = 22, xr = 4;
|
|
5523
|
+
function Sr(e, t, n) {
|
|
4585
5524
|
return Math.min(n, Math.max(t, e));
|
|
4586
5525
|
}
|
|
4587
|
-
function
|
|
5526
|
+
function Cr(e, t, n, r) {
|
|
4588
5527
|
return parseFloat((Math.round((e - t) / n) * n + t).toFixed(r));
|
|
4589
5528
|
}
|
|
4590
|
-
function
|
|
5529
|
+
function wr(e) {
|
|
4591
5530
|
let t = e.toString(), n = t.indexOf(".");
|
|
4592
5531
|
return n === -1 ? 0 : t.length - n - 1;
|
|
4593
5532
|
}
|
|
4594
|
-
var
|
|
4595
|
-
let m =
|
|
5533
|
+
var Tr = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabled: a = !1, marks: s, accessibilityLabel: c, style: l, onLayout: d, ...p }) => {
|
|
5534
|
+
let m = q(), [h, g] = f(0), [_, v] = f({}), y = wr(i), b = Sr(e, n, r), x = (b - n) / (r - n) * 100, C = o((e) => {
|
|
4596
5535
|
g(e.nativeEvent.layout.width), d?.(e);
|
|
4597
5536
|
}, [d]), w = o((e) => {
|
|
4598
|
-
a || h <= 0 || t(
|
|
5537
|
+
a || h <= 0 || t(Sr(Cr(e / h * (r - n) + n, n, i, y), n, r));
|
|
4599
5538
|
}, [
|
|
4600
5539
|
a,
|
|
4601
5540
|
h,
|
|
@@ -4612,10 +5551,10 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4612
5551
|
}), [a, w]), E = o((o) => {
|
|
4613
5552
|
if (!a) switch (o.nativeEvent.actionName) {
|
|
4614
5553
|
case "increment":
|
|
4615
|
-
t(
|
|
5554
|
+
t(Sr(Cr(e + i, n, i, y), n, r));
|
|
4616
5555
|
break;
|
|
4617
5556
|
case "decrement":
|
|
4618
|
-
t(
|
|
5557
|
+
t(Sr(Cr(e - i, n, i, y), n, r));
|
|
4619
5558
|
break;
|
|
4620
5559
|
}
|
|
4621
5560
|
}, [
|
|
@@ -4626,7 +5565,7 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4626
5565
|
r,
|
|
4627
5566
|
y,
|
|
4628
5567
|
t
|
|
4629
|
-
]), O = s && s.length > 0, A = O && s.some((e) => e.label), j = x / 100 * h -
|
|
5568
|
+
]), O = s && s.length > 0, A = O && s.some((e) => e.label), j = x / 100 * h - br / 2;
|
|
4630
5569
|
return /* @__PURE__ */ N(k, {
|
|
4631
5570
|
style: [{
|
|
4632
5571
|
width: "100%",
|
|
@@ -4655,7 +5594,7 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4655
5594
|
onAccessibilityAction: E,
|
|
4656
5595
|
style: {
|
|
4657
5596
|
justifyContent: "center",
|
|
4658
|
-
height:
|
|
5597
|
+
height: br,
|
|
4659
5598
|
opacity: a ? m.opacityDisabled : 1
|
|
4660
5599
|
},
|
|
4661
5600
|
...T.panHandlers,
|
|
@@ -4664,7 +5603,7 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4664
5603
|
pointerEvents: "none",
|
|
4665
5604
|
style: {
|
|
4666
5605
|
width: "100%",
|
|
4667
|
-
height:
|
|
5606
|
+
height: yr,
|
|
4668
5607
|
borderRadius: m.radiusPill,
|
|
4669
5608
|
backgroundColor: m.cardShadeColor,
|
|
4670
5609
|
overflow: "hidden"
|
|
@@ -4681,8 +5620,8 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4681
5620
|
style: {
|
|
4682
5621
|
position: "absolute",
|
|
4683
5622
|
left: j,
|
|
4684
|
-
width:
|
|
4685
|
-
height:
|
|
5623
|
+
width: br,
|
|
5624
|
+
height: br,
|
|
4686
5625
|
borderRadius: m.radiusPill,
|
|
4687
5626
|
backgroundColor: m.accentBgColor,
|
|
4688
5627
|
borderWidth: 2,
|
|
@@ -4702,10 +5641,10 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4702
5641
|
importantForAccessibility: "no",
|
|
4703
5642
|
style: {
|
|
4704
5643
|
position: "absolute",
|
|
4705
|
-
left: (
|
|
4706
|
-
width:
|
|
4707
|
-
height:
|
|
4708
|
-
borderRadius:
|
|
5644
|
+
left: (Sr(e.value, n, r) - n) / (r - n) * 100 / 100 * h - xr / 2,
|
|
5645
|
+
width: xr,
|
|
5646
|
+
height: xr,
|
|
5647
|
+
borderRadius: xr / 2,
|
|
4709
5648
|
backgroundColor: m.windowBgColor
|
|
4710
5649
|
}
|
|
4711
5650
|
}, e.value))
|
|
@@ -4729,7 +5668,7 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4729
5668
|
},
|
|
4730
5669
|
style: {
|
|
4731
5670
|
position: "absolute",
|
|
4732
|
-
left: (
|
|
5671
|
+
left: (Sr(e.value, n, r) - n) / (r - n) * 100 / 100 * h - (_[e.value] ?? 0) / 2,
|
|
4733
5672
|
fontFamily: m.fontFamily,
|
|
4734
5673
|
fontSize: m.fontSizeCaption,
|
|
4735
5674
|
color: m.windowFgColor,
|
|
@@ -4739,21 +5678,21 @@ var qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, disabl
|
|
|
4739
5678
|
}, e.value))
|
|
4740
5679
|
})]
|
|
4741
5680
|
});
|
|
4742
|
-
},
|
|
4743
|
-
function
|
|
5681
|
+
}, Er = 36;
|
|
5682
|
+
function Dr(e) {
|
|
4744
5683
|
let t = e.toString(), n = t.indexOf(".");
|
|
4745
5684
|
return n === -1 ? 0 : t.length - n - 1;
|
|
4746
5685
|
}
|
|
4747
|
-
function
|
|
5686
|
+
function Or(e, t, n) {
|
|
4748
5687
|
return Math.min(n, Math.max(t, e));
|
|
4749
5688
|
}
|
|
4750
|
-
function
|
|
5689
|
+
function kr(e, t, n, r) {
|
|
4751
5690
|
let i = n - t + r;
|
|
4752
5691
|
return ((e - t) % i + i) % i + t;
|
|
4753
5692
|
}
|
|
4754
|
-
var
|
|
4755
|
-
let f =
|
|
4756
|
-
let a = s ?
|
|
5693
|
+
var Ar = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decimals: a, wrap: s = !1, format: c, disabled: l = !1, accessibilityLabel: u, style: d }) => {
|
|
5694
|
+
let f = q(), p = a ?? Dr(i), m = o((e) => {
|
|
5695
|
+
let a = s ? kr(e, n, r, i) : Or(e, n, r);
|
|
4757
5696
|
t(parseFloat(a.toFixed(p)));
|
|
4758
5697
|
}, [
|
|
4759
5698
|
t,
|
|
@@ -4814,8 +5753,8 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4814
5753
|
disabled: _,
|
|
4815
5754
|
onPress: () => m(e - i),
|
|
4816
5755
|
style: ({ pressed: e }) => ({
|
|
4817
|
-
width:
|
|
4818
|
-
height:
|
|
5756
|
+
width: Er,
|
|
5757
|
+
height: Er,
|
|
4819
5758
|
alignItems: "center",
|
|
4820
5759
|
justifyContent: "center",
|
|
4821
5760
|
borderRightWidth: 1,
|
|
@@ -4852,8 +5791,8 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4852
5791
|
disabled: v,
|
|
4853
5792
|
onPress: () => m(e + i),
|
|
4854
5793
|
style: ({ pressed: e }) => ({
|
|
4855
|
-
width:
|
|
4856
|
-
height:
|
|
5794
|
+
width: Er,
|
|
5795
|
+
height: Er,
|
|
4857
5796
|
alignItems: "center",
|
|
4858
5797
|
justifyContent: "center",
|
|
4859
5798
|
borderLeftWidth: 1,
|
|
@@ -4872,7 +5811,7 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4872
5811
|
})
|
|
4873
5812
|
]
|
|
4874
5813
|
});
|
|
4875
|
-
},
|
|
5814
|
+
}, jr = {
|
|
4876
5815
|
sm: {
|
|
4877
5816
|
dimension: 16,
|
|
4878
5817
|
borderWidth: 2
|
|
@@ -4885,8 +5824,8 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4885
5824
|
dimension: 36,
|
|
4886
5825
|
borderWidth: 3
|
|
4887
5826
|
}
|
|
4888
|
-
},
|
|
4889
|
-
let i =
|
|
5827
|
+
}, Mr = ({ size: e = "md", label: t = "Loading…", style: n, ...r }) => {
|
|
5828
|
+
let i = q(), a = K(), o = J(), s = d(new m.Value(0)).current;
|
|
4890
5829
|
c(() => {
|
|
4891
5830
|
s.setValue(0);
|
|
4892
5831
|
let e = m.loop(m.timing(s, {
|
|
@@ -4900,7 +5839,7 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4900
5839
|
let l = s.interpolate({
|
|
4901
5840
|
inputRange: [0, 1],
|
|
4902
5841
|
outputRange: ["0deg", "360deg"]
|
|
4903
|
-
}), { dimension: u, borderWidth: f } =
|
|
5842
|
+
}), { dimension: u, borderWidth: f } = jr[e], p = a === "dark" ? "rgba(255, 255, 255, 0.15)" : "rgba(0, 0, 0, 0.15)";
|
|
4904
5843
|
return /* @__PURE__ */ M(m.View, {
|
|
4905
5844
|
accessible: !0,
|
|
4906
5845
|
accessibilityRole: "progressbar",
|
|
@@ -4918,8 +5857,86 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4918
5857
|
}, n],
|
|
4919
5858
|
...r
|
|
4920
5859
|
});
|
|
4921
|
-
},
|
|
4922
|
-
|
|
5860
|
+
}, Nr = {
|
|
5861
|
+
start: "flex-start",
|
|
5862
|
+
center: "center",
|
|
5863
|
+
end: "flex-end",
|
|
5864
|
+
stretch: "stretch"
|
|
5865
|
+
}, Pr = {
|
|
5866
|
+
start: "flex-start",
|
|
5867
|
+
center: "center",
|
|
5868
|
+
end: "flex-end",
|
|
5869
|
+
"space-between": "space-between",
|
|
5870
|
+
"space-around": "space-around",
|
|
5871
|
+
"space-evenly": "space-evenly"
|
|
5872
|
+
}, Fr = i(function({ childSpacing: e = 6, lineSpacing: t, justify: n = "start", align: r = "center", wrapReverse: i = !1, children: a, style: o, ...s }, c) {
|
|
5873
|
+
return /* @__PURE__ */ M(k, {
|
|
5874
|
+
ref: c,
|
|
5875
|
+
style: [{
|
|
5876
|
+
flexDirection: "row",
|
|
5877
|
+
flexWrap: i ? "wrap-reverse" : "wrap",
|
|
5878
|
+
columnGap: e,
|
|
5879
|
+
rowGap: t ?? e,
|
|
5880
|
+
justifyContent: Pr[n],
|
|
5881
|
+
alignItems: Nr[r],
|
|
5882
|
+
alignContent: "stretch"
|
|
5883
|
+
}, o],
|
|
5884
|
+
...s,
|
|
5885
|
+
children: a
|
|
5886
|
+
});
|
|
5887
|
+
}), Ir = (e) => Math.round(36 * .5 * e), Lr = i(function({ icon: e, iconNode: t, title: n, description: r, children: i, compact: a = !1, style: o, ...s }, c) {
|
|
5888
|
+
let l = q(), u = K(), d = a ? 64 : 128, f = e ? /* @__PURE__ */ M(X, {
|
|
5889
|
+
icon: e,
|
|
5890
|
+
width: d,
|
|
5891
|
+
height: d
|
|
5892
|
+
}) : t, p = a ? l.fontSizeCaption : l.fontSizeBody;
|
|
5893
|
+
return /* @__PURE__ */ N(k, {
|
|
5894
|
+
ref: c,
|
|
5895
|
+
style: [{
|
|
5896
|
+
width: "100%",
|
|
5897
|
+
alignItems: "center",
|
|
5898
|
+
justifyContent: "center",
|
|
5899
|
+
paddingVertical: a ? l.space3 : l.space6,
|
|
5900
|
+
paddingHorizontal: a ? l.space3 : l.space4
|
|
5901
|
+
}, o],
|
|
5902
|
+
...s,
|
|
5903
|
+
children: [
|
|
5904
|
+
f ? /* @__PURE__ */ M(k, {
|
|
5905
|
+
accessibilityElementsHidden: !0,
|
|
5906
|
+
importantForAccessibility: "no",
|
|
5907
|
+
style: {
|
|
5908
|
+
alignItems: "center",
|
|
5909
|
+
justifyContent: "center",
|
|
5910
|
+
marginBottom: a ? l.space2 : l.space4,
|
|
5911
|
+
opacity: u === "dark" ? .45 : .55
|
|
5912
|
+
},
|
|
5913
|
+
children: f
|
|
5914
|
+
}) : null,
|
|
5915
|
+
/* @__PURE__ */ M(Y, {
|
|
5916
|
+
variant: a ? "title-4" : "title-1",
|
|
5917
|
+
style: { textAlign: "center" },
|
|
5918
|
+
children: n
|
|
5919
|
+
}),
|
|
5920
|
+
r ? /* @__PURE__ */ M(Y, {
|
|
5921
|
+
variant: a ? "caption" : "body",
|
|
5922
|
+
color: "dim",
|
|
5923
|
+
style: {
|
|
5924
|
+
textAlign: "center",
|
|
5925
|
+
maxWidth: Ir(p),
|
|
5926
|
+
marginTop: a ? l.space1 : l.space2
|
|
5927
|
+
},
|
|
5928
|
+
children: r
|
|
5929
|
+
}) : null,
|
|
5930
|
+
i ? /* @__PURE__ */ M(Fr, {
|
|
5931
|
+
justify: "center",
|
|
5932
|
+
childSpacing: a ? l.space1 : l.space2,
|
|
5933
|
+
style: { marginTop: a ? l.space2 : l.space4 },
|
|
5934
|
+
children: i
|
|
5935
|
+
}) : null
|
|
5936
|
+
]
|
|
5937
|
+
});
|
|
5938
|
+
}), Rr = 56, zr = 28, Br = 20, Vr = 3, Hr = 28, Ur = i(function({ value: e, onValueChange: t, disabled: n, style: r, ...i }, a) {
|
|
5939
|
+
let o = q(), s = K(), l = Oe(), u = d(new m.Value(+!!e)).current, f = d(!0);
|
|
4923
5940
|
c(() => {
|
|
4924
5941
|
if (f.current) {
|
|
4925
5942
|
f.current = !1;
|
|
@@ -4958,8 +5975,8 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4958
5975
|
...i,
|
|
4959
5976
|
children: /* @__PURE__ */ M(m.View, {
|
|
4960
5977
|
style: {
|
|
4961
|
-
width:
|
|
4962
|
-
height:
|
|
5978
|
+
width: Rr,
|
|
5979
|
+
height: zr,
|
|
4963
5980
|
borderRadius: o.radiusPill,
|
|
4964
5981
|
borderWidth: l === "more" ? 2 : 1,
|
|
4965
5982
|
borderColor: v,
|
|
@@ -4967,15 +5984,15 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4967
5984
|
},
|
|
4968
5985
|
children: /* @__PURE__ */ M(m.View, { style: [{
|
|
4969
5986
|
position: "absolute",
|
|
4970
|
-
top:
|
|
4971
|
-
left:
|
|
4972
|
-
width:
|
|
4973
|
-
height:
|
|
5987
|
+
top: Vr,
|
|
5988
|
+
left: Vr,
|
|
5989
|
+
width: Br,
|
|
5990
|
+
height: Br,
|
|
4974
5991
|
borderRadius: o.radiusPill,
|
|
4975
5992
|
backgroundColor: e ? "#fff" : h,
|
|
4976
5993
|
transform: [{ translateX: u.interpolate({
|
|
4977
5994
|
inputRange: [0, 1],
|
|
4978
|
-
outputRange: [0,
|
|
5995
|
+
outputRange: [0, Hr]
|
|
4979
5996
|
}) }]
|
|
4980
5997
|
}, l !== "more" && {
|
|
4981
5998
|
shadowColor: "#000",
|
|
@@ -4989,8 +6006,8 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
4989
6006
|
}] })
|
|
4990
6007
|
})
|
|
4991
6008
|
});
|
|
4992
|
-
}),
|
|
4993
|
-
let o =
|
|
6009
|
+
}), Wr = i(function({ children: e, inline: t = !1, accessibilityLabel: n = "Tabs", style: r, ...i }, a) {
|
|
6010
|
+
let o = q();
|
|
4994
6011
|
return /* @__PURE__ */ M(T, {
|
|
4995
6012
|
ref: a,
|
|
4996
6013
|
horizontal: !0,
|
|
@@ -5015,8 +6032,8 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
5015
6032
|
...i,
|
|
5016
6033
|
children: e
|
|
5017
6034
|
});
|
|
5018
|
-
}),
|
|
5019
|
-
let l =
|
|
6035
|
+
}), Gr = i(function({ label: e, icon: t, active: n = !1, onClose: r, closeLabel: i = "Close tab", count: a, disabled: o, ...s }, c) {
|
|
6036
|
+
let l = q();
|
|
5020
6037
|
return /* @__PURE__ */ N(w, {
|
|
5021
6038
|
ref: c,
|
|
5022
6039
|
disabled: o,
|
|
@@ -5115,7 +6132,7 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
5115
6132
|
})
|
|
5116
6133
|
]
|
|
5117
6134
|
});
|
|
5118
|
-
}),
|
|
6135
|
+
}), Kr = i(function({ active: e = !1, style: t, children: n, ...r }, i) {
|
|
5119
6136
|
return /* @__PURE__ */ M(k, {
|
|
5120
6137
|
ref: i,
|
|
5121
6138
|
style: [{ display: e ? "flex" : "none" }, t],
|
|
@@ -5125,21 +6142,21 @@ var Qn = ({ value: e, onChange: t, min: n = 0, max: r = 100, step: i = 1, decima
|
|
|
5125
6142
|
});
|
|
5126
6143
|
//#endregion
|
|
5127
6144
|
//#region src/components/TextField/TextField.tsx
|
|
5128
|
-
function
|
|
6145
|
+
function qr(e, t) {
|
|
5129
6146
|
let n = e.match(/^rgba?\(([^,]+),([^,]+),([^,]+),?([^)]+)?\)$/);
|
|
5130
6147
|
if (!n) return e;
|
|
5131
6148
|
let [, r, i, a, o] = n, s = (o ? Number.parseFloat(o) : 1) * t;
|
|
5132
6149
|
return `rgba(${r.trim()}, ${i.trim()}, ${a.trim()}, ${s})`;
|
|
5133
6150
|
}
|
|
5134
|
-
var
|
|
5135
|
-
let p =
|
|
6151
|
+
var Jr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i, editable: a = !0, onFocus: o, onBlur: s, accessibilityLabel: c, accessibilityHint: l, ...u }, d) {
|
|
6152
|
+
let p = q(), m = Oe(), [h, g] = f(!1), _ = !a, v = n ?? t, y = n ? p.errorColor : h ? p.accentColor : p.borderSubtle;
|
|
5136
6153
|
return /* @__PURE__ */ N(k, {
|
|
5137
6154
|
style: [{
|
|
5138
6155
|
gap: p.space1,
|
|
5139
6156
|
opacity: _ ? p.opacityDisabled : 1
|
|
5140
6157
|
}, r],
|
|
5141
6158
|
children: [
|
|
5142
|
-
e && /* @__PURE__ */ M(
|
|
6159
|
+
e && /* @__PURE__ */ M(Y, {
|
|
5143
6160
|
variant: "body",
|
|
5144
6161
|
style: { fontWeight: String(p.fontWeightSemibold) },
|
|
5145
6162
|
children: e
|
|
@@ -5149,7 +6166,7 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5149
6166
|
editable: a,
|
|
5150
6167
|
accessibilityLabel: c ?? e,
|
|
5151
6168
|
accessibilityHint: l ?? v,
|
|
5152
|
-
placeholderTextColor:
|
|
6169
|
+
placeholderTextColor: qr(p.windowFgColor, p.opacityDim),
|
|
5153
6170
|
onFocus: (e) => {
|
|
5154
6171
|
g(!0), o?.(e);
|
|
5155
6172
|
},
|
|
@@ -5171,7 +6188,7 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5171
6188
|
}, i],
|
|
5172
6189
|
...u
|
|
5173
6190
|
}),
|
|
5174
|
-
v && /* @__PURE__ */ M(
|
|
6191
|
+
v && /* @__PURE__ */ M(Y, {
|
|
5175
6192
|
variant: "caption",
|
|
5176
6193
|
style: {
|
|
5177
6194
|
color: n ? p.errorColor : p.windowFgColor,
|
|
@@ -5181,8 +6198,8 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5181
6198
|
})
|
|
5182
6199
|
]
|
|
5183
6200
|
});
|
|
5184
|
-
}),
|
|
5185
|
-
let u =
|
|
6201
|
+
}), Yr = m.createAnimatedComponent(w), Xr = ({ title: e, duration: t = 3e3, onDismiss: n, actionLabel: r, onAction: i, dismissible: a = !1, style: s, ...l }) => {
|
|
6202
|
+
let u = q(), f = K(), p = J(), h = d(null), g = d(t), v = d(0), y = d(new m.Value(+!!p)).current, b = o(() => {
|
|
5186
6203
|
h.current &&= (clearTimeout(h.current), null);
|
|
5187
6204
|
}, []), x = o((e) => {
|
|
5188
6205
|
e <= 0 || !n || (b(), v.current = Date.now(), h.current = setTimeout(() => n(), e));
|
|
@@ -5227,7 +6244,7 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5227
6244
|
shadowRadius: 8,
|
|
5228
6245
|
elevation: 4
|
|
5229
6246
|
};
|
|
5230
|
-
return /* @__PURE__ */ N(
|
|
6247
|
+
return /* @__PURE__ */ N(Yr, {
|
|
5231
6248
|
accessible: !0,
|
|
5232
6249
|
accessibilityRole: "alert",
|
|
5233
6250
|
accessibilityLiveRegion: "polite",
|
|
@@ -5261,7 +6278,7 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5261
6278
|
...E
|
|
5262
6279
|
}, s],
|
|
5263
6280
|
...l,
|
|
5264
|
-
children: [/* @__PURE__ */ M(
|
|
6281
|
+
children: [/* @__PURE__ */ M(Y, {
|
|
5265
6282
|
variant: "body",
|
|
5266
6283
|
style: {
|
|
5267
6284
|
flex: 1,
|
|
@@ -5313,8 +6330,8 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5313
6330
|
})
|
|
5314
6331
|
})] })]
|
|
5315
6332
|
});
|
|
5316
|
-
},
|
|
5317
|
-
let i =
|
|
6333
|
+
}, Zr = ({ position: e = "bottom", children: t, style: n, ...r }) => {
|
|
6334
|
+
let i = q();
|
|
5318
6335
|
return /* @__PURE__ */ M(k, {
|
|
5319
6336
|
pointerEvents: "box-none",
|
|
5320
6337
|
accessibilityLabel: "Notifications",
|
|
@@ -5333,8 +6350,85 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5333
6350
|
...r,
|
|
5334
6351
|
children: t
|
|
5335
6352
|
});
|
|
5336
|
-
},
|
|
5337
|
-
|
|
6353
|
+
}, Qr = r(null);
|
|
6354
|
+
function $r() {
|
|
6355
|
+
let e = s(Qr);
|
|
6356
|
+
if (!e) throw Error("ToggleGroupItem must be used inside ToggleGroup");
|
|
6357
|
+
return e;
|
|
6358
|
+
}
|
|
6359
|
+
var ei = i(function({ value: e, onValueChange: t, accessibilityLabel: n = "Options", children: r, style: i, ...a }, o) {
|
|
6360
|
+
let s = q(), c = K(), l = u(() => ({
|
|
6361
|
+
value: e,
|
|
6362
|
+
onValueChange: t
|
|
6363
|
+
}), [e, t]);
|
|
6364
|
+
return /* @__PURE__ */ M(Qr.Provider, {
|
|
6365
|
+
value: l,
|
|
6366
|
+
children: /* @__PURE__ */ M(k, {
|
|
6367
|
+
ref: o,
|
|
6368
|
+
accessibilityRole: "radiogroup",
|
|
6369
|
+
accessibilityLabel: n,
|
|
6370
|
+
style: [{
|
|
6371
|
+
alignSelf: "flex-start",
|
|
6372
|
+
flexDirection: "row",
|
|
6373
|
+
alignItems: "stretch",
|
|
6374
|
+
gap: 2,
|
|
6375
|
+
padding: 2,
|
|
6376
|
+
borderRadius: s.radiusMd,
|
|
6377
|
+
borderWidth: 1,
|
|
6378
|
+
borderColor: c === "dark" ? "rgba(255, 255, 255, 0.12)" : s.light3,
|
|
6379
|
+
backgroundColor: s.cardBgColor
|
|
6380
|
+
}, i],
|
|
6381
|
+
...a,
|
|
6382
|
+
children: r
|
|
6383
|
+
})
|
|
6384
|
+
});
|
|
6385
|
+
}), ti = i(function({ name: e, label: t, icon: n, accessibilityLabel: r, disabled: i = !1, ...a }, o) {
|
|
6386
|
+
let s = q(), c = K(), { value: l, onValueChange: u } = $r(), d = l === e, f = !!n && !t, p = c === "dark";
|
|
6387
|
+
return /* @__PURE__ */ N(w, {
|
|
6388
|
+
ref: o,
|
|
6389
|
+
disabled: i,
|
|
6390
|
+
onPress: () => u(e),
|
|
6391
|
+
accessibilityRole: "radio",
|
|
6392
|
+
accessibilityState: {
|
|
6393
|
+
checked: d,
|
|
6394
|
+
disabled: i
|
|
6395
|
+
},
|
|
6396
|
+
accessibilityLabel: r ?? t,
|
|
6397
|
+
style: ({ pressed: e }) => ({
|
|
6398
|
+
flexDirection: "row",
|
|
6399
|
+
alignItems: "center",
|
|
6400
|
+
justifyContent: "center",
|
|
6401
|
+
gap: s.space1,
|
|
6402
|
+
minHeight: 28,
|
|
6403
|
+
minWidth: f ? 28 : void 0,
|
|
6404
|
+
paddingVertical: 4,
|
|
6405
|
+
paddingHorizontal: f ? 4 : s.space2,
|
|
6406
|
+
borderRadius: s.radiusMd - 2,
|
|
6407
|
+
borderWidth: 1,
|
|
6408
|
+
borderColor: d ? `${s.accentBgColor}${p ? "80" : "66"}` : "transparent",
|
|
6409
|
+
backgroundColor: d ? `${s.accentBgColor}${p ? "40" : "26"}` : e && !i ? s.activeOverlay : "transparent",
|
|
6410
|
+
opacity: i ? s.opacityDisabled : 1
|
|
6411
|
+
}),
|
|
6412
|
+
...a,
|
|
6413
|
+
children: [n ? /* @__PURE__ */ M(k, {
|
|
6414
|
+
style: { flexShrink: 0 },
|
|
6415
|
+
children: /* @__PURE__ */ M(X, {
|
|
6416
|
+
icon: n,
|
|
6417
|
+
size: "md"
|
|
6418
|
+
})
|
|
6419
|
+
}) : null, t ? /* @__PURE__ */ M(D, {
|
|
6420
|
+
numberOfLines: 1,
|
|
6421
|
+
style: {
|
|
6422
|
+
fontFamily: s.fontFamily,
|
|
6423
|
+
fontSize: s.fontSizeBody,
|
|
6424
|
+
fontWeight: String(d ? s.fontWeightSemibold : s.fontWeightNormal),
|
|
6425
|
+
color: d ? s.accentColor : s.windowFgColor
|
|
6426
|
+
},
|
|
6427
|
+
children: t
|
|
6428
|
+
}) : null]
|
|
6429
|
+
});
|
|
6430
|
+
}), ni = i(function({ children: e, accessibilityLabel: t = "View switcher", style: n, ...r }, i) {
|
|
6431
|
+
let a = q(), o = K();
|
|
5338
6432
|
return /* @__PURE__ */ N(k, {
|
|
5339
6433
|
ref: i,
|
|
5340
6434
|
accessible: !0,
|
|
@@ -5360,8 +6454,8 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5360
6454
|
children: e
|
|
5361
6455
|
})]
|
|
5362
6456
|
});
|
|
5363
|
-
}),
|
|
5364
|
-
let o =
|
|
6457
|
+
}), ri = i(function({ label: e, icon: t, active: n = !1, disabled: r, ...i }, a) {
|
|
6458
|
+
let o = q();
|
|
5365
6459
|
return /* @__PURE__ */ N(w, {
|
|
5366
6460
|
ref: a,
|
|
5367
6461
|
disabled: r,
|
|
@@ -5398,6 +6492,6 @@ var dr = i(function({ label: e, helperText: t, error: n, style: r, inputStyle: i
|
|
|
5398
6492
|
});
|
|
5399
6493
|
});
|
|
5400
6494
|
//#endregion
|
|
5401
|
-
export {
|
|
6495
|
+
export { Be as ActionRow, rt as AnimatedIcon, ut as Avatar, mt as AvatarGroup, vt as AvatarRotator, bt as Badge, xt as Banner, wt as BottomSheet, Dt as Box, kt as BoxedList, Nt as Button, Ft as Card, Lt as Checkbox, Rt as Chip, Bt as Clamp, qt as CoachMark, Yt as CoachMarkTour, Zt as Dialog, Qt as Divider, pn as Drawer, vn as Dropdown, yn as Expander, kn as FileTypeIcon, G as GnomeContext, Ie as GnomeProvider, An as HeaderBar, Mn as Highlight, X as Icon, sn as IconButton, zn as InlineViewSwitcher, Bn as InlineViewSwitcherItem, Un as LevelBar, Wn as Link, je as NAMED_ACCENT_COLORS, Kn as Overlay, qn as PathBar, $n as Popover, er as PreferencesGroup, tr as ProgressBar, ir as RadioButton, or as SearchBar, lr as SegmentedBar, Ot as Separator, hr as Sidebar, fr as SidebarCollapsedContext, mr as SidebarFilterContext, gr as SidebarItem, _r as SidebarSection, vr as Skeleton, Tr as Slider, Ar as SpinButton, Mr as Spinner, Lr as StatusPage, Ur as Switch, Wr as TabBar, Gr as TabItem, Kr as TabPanel, Y as Text, Jr as TextField, Xr as Toast, Zr as Toaster, ei as ToggleGroup, ti as ToggleGroupItem, an as Tooltip, ni as ViewSwitcher, ri as ViewSwitcherItem, Fr as WrapBox, Pe as applyAccentColor, ye as darkRawTokens, he as darkTheme, xe as highContrastDarkRawTokens, _e as highContrastDarkTheme, be as highContrastRawTokens, ge as highContrastTheme, ve as lightRawTokens, me as lightTheme, Me as resolveColorScheme, Ne as resolveContrast, Ae as resolveGnomeTheme, ke as useAccentColor, Ee as useColorScheme, De as useContrast, Te as useDateTimeFormatter, Ce as useDir, q as useGnomeTheme, Se as useLocale, we as useNumberFormatter, J as useReducedMotion, K as useResolvedColorScheme, Oe as useResolvedContrast, pr as useSidebarCollapsed };
|
|
5402
6496
|
|
|
5403
6497
|
//# sourceMappingURL=index.js.map
|