@yusr_systems/ui 6.0.13 → 6.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +11 -2
- package/dist/yusr-ui.js +707 -639
- package/package.json +2 -2
package/dist/yusr-ui.js
CHANGED
|
@@ -1261,22 +1261,90 @@ function Yt({ title: e }) {
|
|
|
1261
1261
|
}
|
|
1262
1262
|
//#endregion
|
|
1263
1263
|
//#region src/components/custom/fields/fieldsSection.tsx
|
|
1264
|
-
|
|
1264
|
+
var Xt = {
|
|
1265
|
+
1: "grid-cols-1",
|
|
1266
|
+
2: "grid-cols-2",
|
|
1267
|
+
3: "grid-cols-3",
|
|
1268
|
+
4: "grid-cols-4",
|
|
1269
|
+
5: "grid-cols-5",
|
|
1270
|
+
6: "grid-cols-6",
|
|
1271
|
+
7: "grid-cols-7",
|
|
1272
|
+
8: "grid-cols-8",
|
|
1273
|
+
9: "grid-cols-9",
|
|
1274
|
+
10: "grid-cols-10"
|
|
1275
|
+
}, Zt = {
|
|
1276
|
+
sm: {
|
|
1277
|
+
1: "sm:grid-cols-1",
|
|
1278
|
+
2: "sm:grid-cols-2",
|
|
1279
|
+
3: "sm:grid-cols-3",
|
|
1280
|
+
4: "sm:grid-cols-4",
|
|
1281
|
+
5: "sm:grid-cols-5",
|
|
1282
|
+
6: "sm:grid-cols-6",
|
|
1283
|
+
7: "sm:grid-cols-7",
|
|
1284
|
+
8: "sm:grid-cols-8",
|
|
1285
|
+
9: "sm:grid-cols-9",
|
|
1286
|
+
10: "sm:grid-cols-10"
|
|
1287
|
+
},
|
|
1288
|
+
md: {
|
|
1289
|
+
1: "md:grid-cols-1",
|
|
1290
|
+
2: "md:grid-cols-2",
|
|
1291
|
+
3: "md:grid-cols-3",
|
|
1292
|
+
4: "md:grid-cols-4",
|
|
1293
|
+
5: "md:grid-cols-5",
|
|
1294
|
+
6: "md:grid-cols-6",
|
|
1295
|
+
7: "md:grid-cols-7",
|
|
1296
|
+
8: "md:grid-cols-8",
|
|
1297
|
+
9: "md:grid-cols-9",
|
|
1298
|
+
10: "md:grid-cols-10"
|
|
1299
|
+
},
|
|
1300
|
+
lg: {
|
|
1301
|
+
1: "lg:grid-cols-1",
|
|
1302
|
+
2: "lg:grid-cols-2",
|
|
1303
|
+
3: "lg:grid-cols-3",
|
|
1304
|
+
4: "lg:grid-cols-4",
|
|
1305
|
+
5: "lg:grid-cols-5",
|
|
1306
|
+
6: "lg:grid-cols-6",
|
|
1307
|
+
7: "lg:grid-cols-7",
|
|
1308
|
+
8: "lg:grid-cols-8",
|
|
1309
|
+
9: "lg:grid-cols-9",
|
|
1310
|
+
10: "lg:grid-cols-10"
|
|
1311
|
+
},
|
|
1312
|
+
xl: {
|
|
1313
|
+
1: "xl:grid-cols-1",
|
|
1314
|
+
2: "xl:grid-cols-2",
|
|
1315
|
+
3: "xl:grid-cols-3",
|
|
1316
|
+
4: "xl:grid-cols-4",
|
|
1317
|
+
5: "xl:grid-cols-5",
|
|
1318
|
+
6: "xl:grid-cols-6",
|
|
1319
|
+
7: "xl:grid-cols-7",
|
|
1320
|
+
8: "xl:grid-cols-8",
|
|
1321
|
+
9: "xl:grid-cols-9",
|
|
1322
|
+
10: "xl:grid-cols-10"
|
|
1323
|
+
}
|
|
1324
|
+
};
|
|
1325
|
+
function Qt(e) {
|
|
1326
|
+
return !e || typeof e == "number" ? "" : P(e.base && Xt[e.base], e.sm && Zt.sm[e.sm], e.md && Zt.md[e.md], e.lg && Zt.lg[e.lg], e.xl && Zt.xl[e.xl]);
|
|
1327
|
+
}
|
|
1328
|
+
function $t(e) {
|
|
1329
|
+
if (typeof e == "number") return { gridTemplateColumns: `repeat(${e}, minmax(0, 1fr))` };
|
|
1330
|
+
}
|
|
1331
|
+
function en({ title: e, children: t, columns: n = {
|
|
1332
|
+
base: 1,
|
|
1333
|
+
md: 2,
|
|
1334
|
+
lg: 3
|
|
1335
|
+
}, className: r, gridClassName: i }) {
|
|
1265
1336
|
return /* @__PURE__ */ o("div", {
|
|
1266
1337
|
className: P("space-y-3", r),
|
|
1267
1338
|
children: [e && /* @__PURE__ */ a(Yt, { title: e }), /* @__PURE__ */ a("div", {
|
|
1268
|
-
className: P("grid gap-4",
|
|
1269
|
-
|
|
1270
|
-
"grid-cols-2": n === 2,
|
|
1271
|
-
"grid-cols-3": n === 3
|
|
1272
|
-
}),
|
|
1339
|
+
className: P("grid gap-4", typeof n != "number" && Qt(n), i),
|
|
1340
|
+
style: $t(n),
|
|
1273
1341
|
children: t
|
|
1274
1342
|
})]
|
|
1275
1343
|
});
|
|
1276
1344
|
}
|
|
1277
1345
|
//#endregion
|
|
1278
1346
|
//#region src/components/custom/fields/inputField.tsx
|
|
1279
|
-
function
|
|
1347
|
+
function tn({ label: e, error: t, isInvalid: n, required: r, ...i }) {
|
|
1280
1348
|
return /* @__PURE__ */ a(R, {
|
|
1281
1349
|
label: e,
|
|
1282
1350
|
error: t,
|
|
@@ -1290,7 +1358,7 @@ function Zt({ label: e, error: t, isInvalid: n, required: r, ...i }) {
|
|
|
1290
1358
|
}
|
|
1291
1359
|
//#endregion
|
|
1292
1360
|
//#region src/components/custom/inputs/numberInput.tsx
|
|
1293
|
-
function
|
|
1361
|
+
function nn({ onChange: e, min: t, max: n, isInvalid: r, className: i, ...o }) {
|
|
1294
1362
|
return /* @__PURE__ */ a(z, {
|
|
1295
1363
|
...o,
|
|
1296
1364
|
type: "number",
|
|
@@ -1310,13 +1378,13 @@ function Qt({ onChange: e, min: t, max: n, isInvalid: r, className: i, ...o }) {
|
|
|
1310
1378
|
}
|
|
1311
1379
|
//#endregion
|
|
1312
1380
|
//#region src/components/custom/fields/numberField.tsx
|
|
1313
|
-
function
|
|
1381
|
+
function rn({ label: e, error: t, isInvalid: n, required: r, ...i }) {
|
|
1314
1382
|
return /* @__PURE__ */ a(R, {
|
|
1315
1383
|
label: e,
|
|
1316
1384
|
error: t,
|
|
1317
1385
|
isInvalid: n,
|
|
1318
1386
|
required: r,
|
|
1319
|
-
children: /* @__PURE__ */ a(
|
|
1387
|
+
children: /* @__PURE__ */ a(nn, {
|
|
1320
1388
|
...i,
|
|
1321
1389
|
isInvalid: n
|
|
1322
1390
|
})
|
|
@@ -1324,11 +1392,11 @@ function $t({ label: e, error: t, isInvalid: n, required: r, ...i }) {
|
|
|
1324
1392
|
}
|
|
1325
1393
|
//#endregion
|
|
1326
1394
|
//#region src/components/custom/fields/passwordField.tsx
|
|
1327
|
-
function
|
|
1395
|
+
function an(e) {
|
|
1328
1396
|
let [t, n] = x(!1);
|
|
1329
1397
|
return /* @__PURE__ */ o("div", {
|
|
1330
1398
|
className: "relative",
|
|
1331
|
-
children: [/* @__PURE__ */ a(
|
|
1399
|
+
children: [/* @__PURE__ */ a(tn, {
|
|
1332
1400
|
...e,
|
|
1333
1401
|
type: t ? "text" : "password",
|
|
1334
1402
|
className: "pl-10"
|
|
@@ -1342,8 +1410,8 @@ function en(e) {
|
|
|
1342
1410
|
}
|
|
1343
1411
|
//#endregion
|
|
1344
1412
|
//#region src/components/custom/fields/phoneField.tsx
|
|
1345
|
-
function
|
|
1346
|
-
return /* @__PURE__ */ a(
|
|
1413
|
+
function on(e) {
|
|
1414
|
+
return /* @__PURE__ */ a(tn, {
|
|
1347
1415
|
...e,
|
|
1348
1416
|
type: "tel",
|
|
1349
1417
|
dir: "ltr",
|
|
@@ -1353,26 +1421,26 @@ function tn(e) {
|
|
|
1353
1421
|
}
|
|
1354
1422
|
//#endregion
|
|
1355
1423
|
//#region src/components/pure/select.tsx
|
|
1356
|
-
function
|
|
1424
|
+
function sn({ ...e }) {
|
|
1357
1425
|
return /* @__PURE__ */ a(T.Root, {
|
|
1358
1426
|
"data-slot": "select",
|
|
1359
1427
|
...e
|
|
1360
1428
|
});
|
|
1361
1429
|
}
|
|
1362
|
-
function
|
|
1430
|
+
function cn({ className: e, ...t }) {
|
|
1363
1431
|
return /* @__PURE__ */ a(T.Group, {
|
|
1364
1432
|
"data-slot": "select-group",
|
|
1365
1433
|
className: P("scroll-my-1 p-1", e),
|
|
1366
1434
|
...t
|
|
1367
1435
|
});
|
|
1368
1436
|
}
|
|
1369
|
-
function
|
|
1437
|
+
function ln({ ...e }) {
|
|
1370
1438
|
return /* @__PURE__ */ a(T.Value, {
|
|
1371
1439
|
"data-slot": "select-value",
|
|
1372
1440
|
...e
|
|
1373
1441
|
});
|
|
1374
1442
|
}
|
|
1375
|
-
function
|
|
1443
|
+
function un({ className: e, size: t = "default", children: n, ...r }) {
|
|
1376
1444
|
return /* @__PURE__ */ o(T.Trigger, {
|
|
1377
1445
|
"data-slot": "select-trigger",
|
|
1378
1446
|
"data-size": t,
|
|
@@ -1384,7 +1452,7 @@ function on({ className: e, size: t = "default", children: n, ...r }) {
|
|
|
1384
1452
|
})]
|
|
1385
1453
|
});
|
|
1386
1454
|
}
|
|
1387
|
-
function
|
|
1455
|
+
function dn({ className: e, children: t, position: n = "item-aligned", align: r = "center", ...i }) {
|
|
1388
1456
|
return /* @__PURE__ */ a(T.Portal, { children: /* @__PURE__ */ o(T.Content, {
|
|
1389
1457
|
"data-slot": "select-content",
|
|
1390
1458
|
"data-align-trigger": n === "item-aligned",
|
|
@@ -1393,24 +1461,24 @@ function sn({ className: e, children: t, position: n = "item-aligned", align: r
|
|
|
1393
1461
|
align: r,
|
|
1394
1462
|
...i,
|
|
1395
1463
|
children: [
|
|
1396
|
-
/* @__PURE__ */ a(
|
|
1464
|
+
/* @__PURE__ */ a(hn, {}),
|
|
1397
1465
|
/* @__PURE__ */ a(T.Viewport, {
|
|
1398
1466
|
"data-position": n,
|
|
1399
1467
|
className: P("data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)", n === "popper" && ""),
|
|
1400
1468
|
children: t
|
|
1401
1469
|
}),
|
|
1402
|
-
/* @__PURE__ */ a(
|
|
1470
|
+
/* @__PURE__ */ a(gn, {})
|
|
1403
1471
|
]
|
|
1404
1472
|
}) });
|
|
1405
1473
|
}
|
|
1406
|
-
function
|
|
1474
|
+
function fn({ className: e, ...t }) {
|
|
1407
1475
|
return /* @__PURE__ */ a(T.Label, {
|
|
1408
1476
|
"data-slot": "select-label",
|
|
1409
1477
|
className: P("text-muted-foreground px-1.5 py-1 text-xs", e),
|
|
1410
1478
|
...t
|
|
1411
1479
|
});
|
|
1412
1480
|
}
|
|
1413
|
-
function
|
|
1481
|
+
function pn({ className: e, children: t, ...n }) {
|
|
1414
1482
|
return /* @__PURE__ */ o(T.Item, {
|
|
1415
1483
|
"data-slot": "select-item",
|
|
1416
1484
|
className: P("focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground gap-1.5 rounded-md py-1 pe-8 ps-1.5 text-sm [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2 relative flex w-full cursor-default items-center outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0", e),
|
|
@@ -1421,14 +1489,14 @@ function ln({ className: e, children: t, ...n }) {
|
|
|
1421
1489
|
}), /* @__PURE__ */ a(T.ItemText, { children: t })]
|
|
1422
1490
|
});
|
|
1423
1491
|
}
|
|
1424
|
-
function
|
|
1492
|
+
function mn({ className: e, ...t }) {
|
|
1425
1493
|
return /* @__PURE__ */ a(T.Separator, {
|
|
1426
1494
|
"data-slot": "select-separator",
|
|
1427
1495
|
className: P("bg-border -mx-1 my-1 h-px pointer-events-none", e),
|
|
1428
1496
|
...t
|
|
1429
1497
|
});
|
|
1430
1498
|
}
|
|
1431
|
-
function
|
|
1499
|
+
function hn({ className: e, ...t }) {
|
|
1432
1500
|
return /* @__PURE__ */ a(T.ScrollUpButton, {
|
|
1433
1501
|
"data-slot": "select-scroll-up-button",
|
|
1434
1502
|
className: P("bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-4", e),
|
|
@@ -1436,7 +1504,7 @@ function dn({ className: e, ...t }) {
|
|
|
1436
1504
|
children: /* @__PURE__ */ a(m, {})
|
|
1437
1505
|
});
|
|
1438
1506
|
}
|
|
1439
|
-
function
|
|
1507
|
+
function gn({ className: e, ...t }) {
|
|
1440
1508
|
return /* @__PURE__ */ a(T.ScrollDownButton, {
|
|
1441
1509
|
"data-slot": "select-scroll-down-button",
|
|
1442
1510
|
className: P("bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-4", e),
|
|
@@ -1446,16 +1514,16 @@ function fn({ className: e, ...t }) {
|
|
|
1446
1514
|
}
|
|
1447
1515
|
//#endregion
|
|
1448
1516
|
//#region src/components/custom/inputs/selectInput.tsx
|
|
1449
|
-
function
|
|
1450
|
-
return /* @__PURE__ */ o(
|
|
1517
|
+
function _n({ value: e, onValueChange: t, options: n, placeholder: r, isInvalid: i, disabled: s }) {
|
|
1518
|
+
return /* @__PURE__ */ o(sn, {
|
|
1451
1519
|
value: e,
|
|
1452
1520
|
onValueChange: t,
|
|
1453
1521
|
dir: "rtl",
|
|
1454
1522
|
disabled: s,
|
|
1455
|
-
children: [/* @__PURE__ */ a(
|
|
1523
|
+
children: [/* @__PURE__ */ a(un, {
|
|
1456
1524
|
className: P("w-full", i && "border-red-600 ring-red-600 text-red-900"),
|
|
1457
|
-
children: /* @__PURE__ */ a(
|
|
1458
|
-
}), /* @__PURE__ */ a(
|
|
1525
|
+
children: /* @__PURE__ */ a(ln, { placeholder: r })
|
|
1526
|
+
}), /* @__PURE__ */ a(dn, { children: n.map((e) => /* @__PURE__ */ a(pn, {
|
|
1459
1527
|
value: e.value,
|
|
1460
1528
|
children: e.label
|
|
1461
1529
|
}, e.value)) })]
|
|
@@ -1463,13 +1531,13 @@ function pn({ value: e, onValueChange: t, options: n, placeholder: r, isInvalid:
|
|
|
1463
1531
|
}
|
|
1464
1532
|
//#endregion
|
|
1465
1533
|
//#region src/components/custom/fields/selectField.tsx
|
|
1466
|
-
function
|
|
1534
|
+
function vn({ label: e, error: t, required: n, isInvalid: r, ...i }) {
|
|
1467
1535
|
return /* @__PURE__ */ a(R, {
|
|
1468
1536
|
label: e,
|
|
1469
1537
|
error: t,
|
|
1470
1538
|
isInvalid: r,
|
|
1471
1539
|
required: n,
|
|
1472
|
-
children: /* @__PURE__ */ a(
|
|
1540
|
+
children: /* @__PURE__ */ a(_n, {
|
|
1473
1541
|
...i,
|
|
1474
1542
|
isInvalid: r
|
|
1475
1543
|
})
|
|
@@ -1477,7 +1545,7 @@ function mn({ label: e, error: t, required: n, isInvalid: r, ...i }) {
|
|
|
1477
1545
|
}
|
|
1478
1546
|
//#endregion
|
|
1479
1547
|
//#region src/components/pure/card.tsx
|
|
1480
|
-
function
|
|
1548
|
+
function yn({ className: e, size: t = "default", ...n }) {
|
|
1481
1549
|
return /* @__PURE__ */ a("div", {
|
|
1482
1550
|
"data-slot": "card",
|
|
1483
1551
|
"data-size": t,
|
|
@@ -1485,42 +1553,42 @@ function hn({ className: e, size: t = "default", ...n }) {
|
|
|
1485
1553
|
...n
|
|
1486
1554
|
});
|
|
1487
1555
|
}
|
|
1488
|
-
function
|
|
1556
|
+
function bn({ className: e, ...t }) {
|
|
1489
1557
|
return /* @__PURE__ */ a("div", {
|
|
1490
1558
|
"data-slot": "card-header",
|
|
1491
1559
|
className: P("gap-1 rounded-t-xl px-4 group-data-[size=sm]/card:px-3 [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3 group/card-header @container/card-header grid auto-rows-min items-start has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto]", e),
|
|
1492
1560
|
...t
|
|
1493
1561
|
});
|
|
1494
1562
|
}
|
|
1495
|
-
function
|
|
1563
|
+
function xn({ className: e, ...t }) {
|
|
1496
1564
|
return /* @__PURE__ */ a("div", {
|
|
1497
1565
|
"data-slot": "card-title",
|
|
1498
1566
|
className: P("text-base leading-snug font-medium group-data-[size=sm]/card:text-sm", e),
|
|
1499
1567
|
...t
|
|
1500
1568
|
});
|
|
1501
1569
|
}
|
|
1502
|
-
function
|
|
1570
|
+
function Sn({ className: e, ...t }) {
|
|
1503
1571
|
return /* @__PURE__ */ a("div", {
|
|
1504
1572
|
"data-slot": "card-description",
|
|
1505
1573
|
className: P("text-muted-foreground text-sm", e),
|
|
1506
1574
|
...t
|
|
1507
1575
|
});
|
|
1508
1576
|
}
|
|
1509
|
-
function
|
|
1577
|
+
function Cn({ className: e, ...t }) {
|
|
1510
1578
|
return /* @__PURE__ */ a("div", {
|
|
1511
1579
|
"data-slot": "card-action",
|
|
1512
1580
|
className: P("col-start-2 row-span-2 row-start-1 self-start justify-self-end", e),
|
|
1513
1581
|
...t
|
|
1514
1582
|
});
|
|
1515
1583
|
}
|
|
1516
|
-
function
|
|
1584
|
+
function wn({ className: e, ...t }) {
|
|
1517
1585
|
return /* @__PURE__ */ a("div", {
|
|
1518
1586
|
"data-slot": "card-content",
|
|
1519
1587
|
className: P("px-4 group-data-[size=sm]/card:px-3", e),
|
|
1520
1588
|
...t
|
|
1521
1589
|
});
|
|
1522
1590
|
}
|
|
1523
|
-
function
|
|
1591
|
+
function Tn({ className: e, ...t }) {
|
|
1524
1592
|
return /* @__PURE__ */ a("div", {
|
|
1525
1593
|
"data-slot": "card-footer",
|
|
1526
1594
|
className: P("bg-muted/50 rounded-b-xl border-t p-4 group-data-[size=sm]/card:p-3 flex items-center", e),
|
|
@@ -1529,13 +1597,13 @@ function xn({ className: e, ...t }) {
|
|
|
1529
1597
|
}
|
|
1530
1598
|
//#endregion
|
|
1531
1599
|
//#region src/components/pure/carousel.tsx
|
|
1532
|
-
var
|
|
1533
|
-
function
|
|
1534
|
-
let e = y.useContext(
|
|
1600
|
+
var En = y.createContext(null);
|
|
1601
|
+
function Dn() {
|
|
1602
|
+
let e = y.useContext(En);
|
|
1535
1603
|
if (!e) throw Error("useCarousel must be used within a <Carousel />");
|
|
1536
1604
|
return e;
|
|
1537
1605
|
}
|
|
1538
|
-
function
|
|
1606
|
+
function On({ orientation: e = "horizontal", opts: t, setApi: n, plugins: r, className: i, children: o, ...s }) {
|
|
1539
1607
|
let [c, l] = He({
|
|
1540
1608
|
...t,
|
|
1541
1609
|
axis: e === "horizontal" ? "x" : "y"
|
|
@@ -1554,7 +1622,7 @@ function wn({ orientation: e = "horizontal", opts: t, setApi: n, plugins: r, cla
|
|
|
1554
1622
|
if (l) return m(l), l.on("reInit", m), l.on("select", m), () => {
|
|
1555
1623
|
l?.off("select", m);
|
|
1556
1624
|
};
|
|
1557
|
-
}, [l, m]), /* @__PURE__ */ a(
|
|
1625
|
+
}, [l, m]), /* @__PURE__ */ a(En.Provider, {
|
|
1558
1626
|
value: {
|
|
1559
1627
|
carouselRef: c,
|
|
1560
1628
|
api: l,
|
|
@@ -1576,8 +1644,8 @@ function wn({ orientation: e = "horizontal", opts: t, setApi: n, plugins: r, cla
|
|
|
1576
1644
|
})
|
|
1577
1645
|
});
|
|
1578
1646
|
}
|
|
1579
|
-
function
|
|
1580
|
-
let { carouselRef: n, orientation: r } =
|
|
1647
|
+
function kn({ className: e, ...t }) {
|
|
1648
|
+
let { carouselRef: n, orientation: r } = Dn();
|
|
1581
1649
|
return /* @__PURE__ */ a("div", {
|
|
1582
1650
|
ref: n,
|
|
1583
1651
|
className: "overflow-hidden",
|
|
@@ -1588,8 +1656,8 @@ function Tn({ className: e, ...t }) {
|
|
|
1588
1656
|
})
|
|
1589
1657
|
});
|
|
1590
1658
|
}
|
|
1591
|
-
function
|
|
1592
|
-
let { orientation: n } =
|
|
1659
|
+
function An({ className: e, ...t }) {
|
|
1660
|
+
let { orientation: n } = Dn();
|
|
1593
1661
|
return /* @__PURE__ */ a("div", {
|
|
1594
1662
|
role: "group",
|
|
1595
1663
|
"aria-roledescription": "slide",
|
|
@@ -1598,8 +1666,8 @@ function En({ className: e, ...t }) {
|
|
|
1598
1666
|
...t
|
|
1599
1667
|
});
|
|
1600
1668
|
}
|
|
1601
|
-
function
|
|
1602
|
-
let { orientation: i, scrollPrev: s, canScrollPrev: c } =
|
|
1669
|
+
function jn({ className: e, variant: t = "outline", size: n = "icon-sm", ...r }) {
|
|
1670
|
+
let { orientation: i, scrollPrev: s, canScrollPrev: c } = Dn();
|
|
1603
1671
|
return /* @__PURE__ */ o(F, {
|
|
1604
1672
|
"data-slot": "carousel-previous",
|
|
1605
1673
|
variant: t,
|
|
@@ -1614,8 +1682,8 @@ function Dn({ className: e, variant: t = "outline", size: n = "icon-sm", ...r })
|
|
|
1614
1682
|
})]
|
|
1615
1683
|
});
|
|
1616
1684
|
}
|
|
1617
|
-
function
|
|
1618
|
-
let { orientation: i, scrollNext: s, canScrollNext: c } =
|
|
1685
|
+
function Mn({ className: e, variant: t = "outline", size: n = "icon-sm", ...r }) {
|
|
1686
|
+
let { orientation: i, scrollNext: s, canScrollNext: c } = Dn();
|
|
1619
1687
|
return /* @__PURE__ */ o(F, {
|
|
1620
1688
|
"data-slot": "carousel-next",
|
|
1621
1689
|
variant: t,
|
|
@@ -1632,14 +1700,14 @@ function On({ className: e, variant: t = "outline", size: n = "icon-sm", ...r })
|
|
|
1632
1700
|
}
|
|
1633
1701
|
//#endregion
|
|
1634
1702
|
//#region src/components/custom/fields/storageFilesField.tsx
|
|
1635
|
-
function
|
|
1703
|
+
function Nn(e) {
|
|
1636
1704
|
return e?.contentType === "application/pdf" || e?.extension?.toLowerCase() === ".pdf";
|
|
1637
1705
|
}
|
|
1638
|
-
function
|
|
1706
|
+
function Pn({ label: e, file: t, onFileChange: n, onRemove: r, onDownload: s, getFileSrc: c, showPreview: l, fileInputRef: u, error: d, isInvalid: f, dir: p = "rtl" }) {
|
|
1639
1707
|
let m = Me(() => Array.isArray(t) ? t : t ? [t] : [], [t]), h = Me(() => m.filter((e) => l(e)), [m, l]), g = b((e) => {
|
|
1640
1708
|
n(e), e.target && (e.target.value = "");
|
|
1641
1709
|
}, [n]), v = b((e) => {
|
|
1642
|
-
let t =
|
|
1710
|
+
let t = Nn(e), n = c(e);
|
|
1643
1711
|
return t ? /* @__PURE__ */ o("div", {
|
|
1644
1712
|
className: "flex flex-col items-center justify-center w-full h-full bg-muted/30",
|
|
1645
1713
|
children: [/* @__PURE__ */ a(te, { className: "h-12 w-12 text-red-500 mb-2" }), /* @__PURE__ */ a("span", {
|
|
@@ -1662,22 +1730,22 @@ function An({ label: e, file: t, onFileChange: n, onRemove: r, onDownload: s, ge
|
|
|
1662
1730
|
}),
|
|
1663
1731
|
h.length > 0 ? /* @__PURE__ */ o("div", {
|
|
1664
1732
|
className: "space-y-2 max-w-100 mt-3",
|
|
1665
|
-
children: [/* @__PURE__ */ o(
|
|
1733
|
+
children: [/* @__PURE__ */ o(On, {
|
|
1666
1734
|
opts: {
|
|
1667
1735
|
direction: p,
|
|
1668
1736
|
align: "start",
|
|
1669
1737
|
dragFree: !0
|
|
1670
1738
|
},
|
|
1671
1739
|
className: "w-full relative group",
|
|
1672
|
-
children: [/* @__PURE__ */ a(
|
|
1740
|
+
children: [/* @__PURE__ */ a(kn, { children: h.map((e, t) => {
|
|
1673
1741
|
let n = e.url || (e.base64File ? e.base64File.substring(0, 40) : `fallback-key-${t}`), i = m.indexOf(e);
|
|
1674
|
-
return /* @__PURE__ */ a(
|
|
1742
|
+
return /* @__PURE__ */ a(An, {
|
|
1675
1743
|
className: "basis-full",
|
|
1676
1744
|
children: /* @__PURE__ */ a("div", {
|
|
1677
1745
|
className: "p-1",
|
|
1678
|
-
children: /* @__PURE__ */ a(
|
|
1746
|
+
children: /* @__PURE__ */ a(yn, {
|
|
1679
1747
|
className: "relative group overflow-hidden border-2 aspect-video flex items-center justify-center bg-background shadow-sm",
|
|
1680
|
-
children: /* @__PURE__ */ o(
|
|
1748
|
+
children: /* @__PURE__ */ o(wn, {
|
|
1681
1749
|
className: "p-0 w-full h-full flex items-center justify-center",
|
|
1682
1750
|
children: [/* @__PURE__ */ o(I, { children: [/* @__PURE__ */ a(ft, {
|
|
1683
1751
|
asChild: !0,
|
|
@@ -1729,7 +1797,7 @@ function An({ label: e, file: t, onFileChange: n, onRemove: r, onDownload: s, ge
|
|
|
1729
1797
|
})
|
|
1730
1798
|
})
|
|
1731
1799
|
}, n);
|
|
1732
|
-
}) }), h.length > 1 && /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ a(
|
|
1800
|
+
}) }), h.length > 1 && /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ a(jn, { className: "absolute right-2 top-1/2 -translate-y-1/2 h-8 w-8 rounded-full z-40 bg-background/80 hover:bg-background" }), /* @__PURE__ */ a(Mn, { className: "absolute left-2 top-1/2 -translate-y-1/2 h-8 w-8 rounded-full z-40 bg-background/80 hover:bg-background" })] })]
|
|
1733
1801
|
}), /* @__PURE__ */ o(F, {
|
|
1734
1802
|
type: "button",
|
|
1735
1803
|
variant: "outline",
|
|
@@ -1770,7 +1838,7 @@ function An({ label: e, file: t, onFileChange: n, onRemove: r, onDownload: s, ge
|
|
|
1770
1838
|
}
|
|
1771
1839
|
//#endregion
|
|
1772
1840
|
//#region src/components/pure/textarea.tsx
|
|
1773
|
-
function
|
|
1841
|
+
function Fn({ className: e, ...t }) {
|
|
1774
1842
|
return /* @__PURE__ */ a("textarea", {
|
|
1775
1843
|
"data-slot": "textarea",
|
|
1776
1844
|
className: P("border-input dark:bg-input/30 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 disabled:bg-input/50 dark:disabled:bg-input/80 rounded-lg border bg-transparent px-2.5 py-2 text-base transition-colors focus-visible:ring-3 aria-invalid:ring-3 md:text-sm placeholder:text-muted-foreground flex field-sizing-content min-h-16 w-full outline-none disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
@@ -1779,21 +1847,21 @@ function jn({ className: e, ...t }) {
|
|
|
1779
1847
|
}
|
|
1780
1848
|
//#endregion
|
|
1781
1849
|
//#region src/components/custom/inputs/textAreaInput.tsx
|
|
1782
|
-
function
|
|
1783
|
-
return /* @__PURE__ */ a(
|
|
1850
|
+
function In({ isInvalid: e, className: t, ...n }) {
|
|
1851
|
+
return /* @__PURE__ */ a(Fn, {
|
|
1784
1852
|
...n,
|
|
1785
1853
|
className: P(t, e && "border-red-600 focus-visible:ring-red-600")
|
|
1786
1854
|
});
|
|
1787
1855
|
}
|
|
1788
1856
|
//#endregion
|
|
1789
1857
|
//#region src/components/custom/fields/textAreaField.tsx
|
|
1790
|
-
function
|
|
1858
|
+
function Ln({ label: e, error: t, isInvalid: n, required: r, ...i }) {
|
|
1791
1859
|
return /* @__PURE__ */ a(R, {
|
|
1792
1860
|
label: e,
|
|
1793
1861
|
error: t,
|
|
1794
1862
|
isInvalid: n,
|
|
1795
1863
|
required: r,
|
|
1796
|
-
children: /* @__PURE__ */ a(
|
|
1864
|
+
children: /* @__PURE__ */ a(In, {
|
|
1797
1865
|
...i,
|
|
1798
1866
|
isInvalid: n
|
|
1799
1867
|
})
|
|
@@ -1801,15 +1869,15 @@ function Nn({ label: e, error: t, isInvalid: n, required: r, ...i }) {
|
|
|
1801
1869
|
}
|
|
1802
1870
|
//#endregion
|
|
1803
1871
|
//#region src/components/custom/fields/textField.tsx
|
|
1804
|
-
function
|
|
1805
|
-
return /* @__PURE__ */ a(
|
|
1872
|
+
function Rn(e) {
|
|
1873
|
+
return /* @__PURE__ */ a(tn, {
|
|
1806
1874
|
...e,
|
|
1807
1875
|
type: "text"
|
|
1808
1876
|
});
|
|
1809
1877
|
}
|
|
1810
1878
|
//#endregion
|
|
1811
1879
|
//#region src/components/custom/images/lightbox.tsx
|
|
1812
|
-
function
|
|
1880
|
+
function zn({ srcLight: e, srcDark: t, alt: n, onClose: r }) {
|
|
1813
1881
|
return je(() => {
|
|
1814
1882
|
let e = (e) => e.key === "Escape" && r();
|
|
1815
1883
|
return window.addEventListener("keydown", e), document.body.style.overflow = "hidden", () => {
|
|
@@ -1840,7 +1908,7 @@ function Fn({ srcLight: e, srcDark: t, alt: n, onClose: r }) {
|
|
|
1840
1908
|
}
|
|
1841
1909
|
//#endregion
|
|
1842
1910
|
//#region src/components/custom/images/zoomableImage.tsx
|
|
1843
|
-
function
|
|
1911
|
+
function Bn({ srcLight: e, srcDark: t, alt: n, className: r, wrapperClassName: i, onOpen: s }) {
|
|
1844
1912
|
return /* @__PURE__ */ o("div", {
|
|
1845
1913
|
className: `group/zoom relative cursor-zoom-in overflow-hidden ${i ?? ""}`,
|
|
1846
1914
|
onClick: () => s(e, t, n),
|
|
@@ -1868,7 +1936,7 @@ function In({ srcLight: e, srcDark: t, alt: n, className: r, wrapperClassName: i
|
|
|
1868
1936
|
}
|
|
1869
1937
|
//#endregion
|
|
1870
1938
|
//#region src/components/custom/inputs/searchInput.tsx
|
|
1871
|
-
function
|
|
1939
|
+
function Vn({ columnsNames: e, onSearch: t }) {
|
|
1872
1940
|
let [n, r] = x(""), [i, s] = x(e[0]?.value || ""), c = Ue((e, n) => {
|
|
1873
1941
|
e.trim() ? t({
|
|
1874
1942
|
value: e,
|
|
@@ -1879,16 +1947,16 @@ function Ln({ columnsNames: e, onSearch: t }) {
|
|
|
1879
1947
|
className: "p-3 rounded-t-xl border-x border-t flex flex-col sm:flex-row gap-4",
|
|
1880
1948
|
children: /* @__PURE__ */ o("div", {
|
|
1881
1949
|
className: "relative w-full flex gap-2",
|
|
1882
|
-
children: [e.length > 1 && /* @__PURE__ */ o(
|
|
1950
|
+
children: [e.length > 1 && /* @__PURE__ */ o(sn, {
|
|
1883
1951
|
dir: "rtl",
|
|
1884
1952
|
value: i,
|
|
1885
1953
|
onValueChange: (e) => {
|
|
1886
1954
|
s(e), n.trim() && c(n, e);
|
|
1887
1955
|
},
|
|
1888
|
-
children: [/* @__PURE__ */ a(
|
|
1956
|
+
children: [/* @__PURE__ */ a(un, {
|
|
1889
1957
|
className: "bg-secondary border-none",
|
|
1890
|
-
children: /* @__PURE__ */ a(
|
|
1891
|
-
}), /* @__PURE__ */ a(
|
|
1958
|
+
children: /* @__PURE__ */ a(ln, { placeholder: "اختر العمود" })
|
|
1959
|
+
}), /* @__PURE__ */ a(dn, { children: e.map((e) => /* @__PURE__ */ a(pn, {
|
|
1892
1960
|
value: e.value,
|
|
1893
1961
|
children: e.label
|
|
1894
1962
|
}, e.value)) })]
|
|
@@ -1909,7 +1977,7 @@ function Ln({ columnsNames: e, onSearch: t }) {
|
|
|
1909
1977
|
}
|
|
1910
1978
|
//#endregion
|
|
1911
1979
|
//#region src/components/pure/table.tsx
|
|
1912
|
-
function
|
|
1980
|
+
function Hn({ className: e, ...t }) {
|
|
1913
1981
|
return /* @__PURE__ */ a("div", {
|
|
1914
1982
|
"data-slot": "table-container",
|
|
1915
1983
|
className: "relative w-full overflow-x-auto",
|
|
@@ -1920,49 +1988,49 @@ function Rn({ className: e, ...t }) {
|
|
|
1920
1988
|
})
|
|
1921
1989
|
});
|
|
1922
1990
|
}
|
|
1923
|
-
function
|
|
1991
|
+
function Un({ className: e, ...t }) {
|
|
1924
1992
|
return /* @__PURE__ */ a("thead", {
|
|
1925
1993
|
"data-slot": "table-header",
|
|
1926
1994
|
className: P("[&_tr]:border-b", e),
|
|
1927
1995
|
...t
|
|
1928
1996
|
});
|
|
1929
1997
|
}
|
|
1930
|
-
function
|
|
1998
|
+
function Wn({ className: e, ...t }) {
|
|
1931
1999
|
return /* @__PURE__ */ a("tbody", {
|
|
1932
2000
|
"data-slot": "table-body",
|
|
1933
2001
|
className: P("[&_tr:last-child]:border-0", e),
|
|
1934
2002
|
...t
|
|
1935
2003
|
});
|
|
1936
2004
|
}
|
|
1937
|
-
function
|
|
2005
|
+
function Gn({ className: e, ...t }) {
|
|
1938
2006
|
return /* @__PURE__ */ a("tfoot", {
|
|
1939
2007
|
"data-slot": "table-footer",
|
|
1940
2008
|
className: P("bg-muted/50 border-t font-medium [&>tr]:last:border-b-0", e),
|
|
1941
2009
|
...t
|
|
1942
2010
|
});
|
|
1943
2011
|
}
|
|
1944
|
-
function
|
|
2012
|
+
function Kn({ className: e, ...t }) {
|
|
1945
2013
|
return /* @__PURE__ */ a("tr", {
|
|
1946
2014
|
"data-slot": "table-row",
|
|
1947
2015
|
className: P("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors", e),
|
|
1948
2016
|
...t
|
|
1949
2017
|
});
|
|
1950
2018
|
}
|
|
1951
|
-
function
|
|
2019
|
+
function qn({ className: e, ...t }) {
|
|
1952
2020
|
return /* @__PURE__ */ a("th", {
|
|
1953
2021
|
"data-slot": "table-head",
|
|
1954
2022
|
className: P("text-foreground h-10 px-2 text-start align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pe-0", e),
|
|
1955
2023
|
...t
|
|
1956
2024
|
});
|
|
1957
2025
|
}
|
|
1958
|
-
function
|
|
2026
|
+
function Jn({ className: e, ...t }) {
|
|
1959
2027
|
return /* @__PURE__ */ a("td", {
|
|
1960
2028
|
"data-slot": "table-cell",
|
|
1961
2029
|
className: P("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pe-0", e),
|
|
1962
2030
|
...t
|
|
1963
2031
|
});
|
|
1964
2032
|
}
|
|
1965
|
-
function
|
|
2033
|
+
function Yn({ className: e, ...t }) {
|
|
1966
2034
|
return /* @__PURE__ */ a("caption", {
|
|
1967
2035
|
"data-slot": "table-caption",
|
|
1968
2036
|
className: P("text-muted-foreground mt-4 text-sm", e),
|
|
@@ -1971,53 +2039,53 @@ function Gn({ className: e, ...t }) {
|
|
|
1971
2039
|
}
|
|
1972
2040
|
//#endregion
|
|
1973
2041
|
//#region src/components/custom/status/empty.tsx
|
|
1974
|
-
function
|
|
2042
|
+
function Xn({ className: e, ...t }) {
|
|
1975
2043
|
return /* @__PURE__ */ a("div", {
|
|
1976
2044
|
"data-slot": "empty",
|
|
1977
2045
|
className: P("gap-4 rounded-xl border-dashed p-6 flex w-full min-w-0 flex-1 flex-col items-center justify-center text-center text-balance", e),
|
|
1978
2046
|
...t
|
|
1979
2047
|
});
|
|
1980
2048
|
}
|
|
1981
|
-
function
|
|
2049
|
+
function Zn({ className: e, ...t }) {
|
|
1982
2050
|
return /* @__PURE__ */ a("div", {
|
|
1983
2051
|
"data-slot": "empty-header",
|
|
1984
2052
|
className: P("gap-2 flex max-w-sm flex-col items-center", e),
|
|
1985
2053
|
...t
|
|
1986
2054
|
});
|
|
1987
2055
|
}
|
|
1988
|
-
var
|
|
2056
|
+
var Qn = S("mb-2 flex shrink-0 items-center justify-center [&_svg]:pointer-events-none [&_svg]:shrink-0", {
|
|
1989
2057
|
variants: { variant: {
|
|
1990
2058
|
default: "bg-transparent",
|
|
1991
2059
|
icon: "bg-muted text-foreground flex size-8 shrink-0 items-center justify-center rounded-lg [&_svg:not([class*='size-'])]:size-4"
|
|
1992
2060
|
} },
|
|
1993
2061
|
defaultVariants: { variant: "default" }
|
|
1994
2062
|
});
|
|
1995
|
-
function
|
|
2063
|
+
function $n({ className: e, variant: t = "default", ...n }) {
|
|
1996
2064
|
return /* @__PURE__ */ a("div", {
|
|
1997
2065
|
"data-slot": "empty-icon",
|
|
1998
2066
|
"data-variant": t,
|
|
1999
|
-
className: P(
|
|
2067
|
+
className: P(Qn({
|
|
2000
2068
|
variant: t,
|
|
2001
2069
|
className: e
|
|
2002
2070
|
})),
|
|
2003
2071
|
...n
|
|
2004
2072
|
});
|
|
2005
2073
|
}
|
|
2006
|
-
function
|
|
2074
|
+
function er({ className: e, ...t }) {
|
|
2007
2075
|
return /* @__PURE__ */ a("div", {
|
|
2008
2076
|
"data-slot": "empty-title",
|
|
2009
2077
|
className: P("text-sm font-medium tracking-tight", e),
|
|
2010
2078
|
...t
|
|
2011
2079
|
});
|
|
2012
2080
|
}
|
|
2013
|
-
function
|
|
2081
|
+
function tr({ className: e, ...t }) {
|
|
2014
2082
|
return /* @__PURE__ */ a("div", {
|
|
2015
2083
|
"data-slot": "empty-description",
|
|
2016
2084
|
className: P("text-sm/relaxed text-muted-foreground [&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4", e),
|
|
2017
2085
|
...t
|
|
2018
2086
|
});
|
|
2019
2087
|
}
|
|
2020
|
-
function
|
|
2088
|
+
function nr({ className: e, ...t }) {
|
|
2021
2089
|
return /* @__PURE__ */ a("div", {
|
|
2022
2090
|
"data-slot": "empty-content",
|
|
2023
2091
|
className: P("gap-2.5 text-sm flex w-full max-w-sm min-w-0 flex-col items-center text-balance", e),
|
|
@@ -2026,91 +2094,91 @@ function Qn({ className: e, ...t }) {
|
|
|
2026
2094
|
}
|
|
2027
2095
|
//#endregion
|
|
2028
2096
|
//#region src/components/custom/table/crudEmptyTablePreview.tsx
|
|
2029
|
-
function
|
|
2030
|
-
return a(e === "loading" ?
|
|
2097
|
+
function rr({ mode: e }) {
|
|
2098
|
+
return a(e === "loading" ? ir : e === "error" ? or : ar, {});
|
|
2031
2099
|
}
|
|
2032
|
-
function
|
|
2033
|
-
return /* @__PURE__ */ o(
|
|
2034
|
-
/* @__PURE__ */ a(
|
|
2100
|
+
function ir() {
|
|
2101
|
+
return /* @__PURE__ */ o(Xn, { children: [/* @__PURE__ */ o(Zn, { children: [
|
|
2102
|
+
/* @__PURE__ */ a($n, {
|
|
2035
2103
|
variant: "icon",
|
|
2036
2104
|
children: /* @__PURE__ */ a(xe, {})
|
|
2037
2105
|
}),
|
|
2038
|
-
/* @__PURE__ */ a(
|
|
2039
|
-
/* @__PURE__ */ a(
|
|
2040
|
-
] }), /* @__PURE__ */ a(
|
|
2106
|
+
/* @__PURE__ */ a(er, { children: "الرجاء الانتظار" }),
|
|
2107
|
+
/* @__PURE__ */ a(tr, { children: "يتم تحميل البيانات المطلوبة" })
|
|
2108
|
+
] }), /* @__PURE__ */ a(nr, { children: /* @__PURE__ */ a(ae, { className: "animate-spin duration-700" }) })] });
|
|
2041
2109
|
}
|
|
2042
|
-
function
|
|
2043
|
-
return /* @__PURE__ */ a(
|
|
2044
|
-
/* @__PURE__ */ a(
|
|
2110
|
+
function ar() {
|
|
2111
|
+
return /* @__PURE__ */ a(Xn, { children: /* @__PURE__ */ o(Zn, { children: [
|
|
2112
|
+
/* @__PURE__ */ a($n, {
|
|
2045
2113
|
variant: "icon",
|
|
2046
2114
|
children: /* @__PURE__ */ a(xe, {})
|
|
2047
2115
|
}),
|
|
2048
|
-
/* @__PURE__ */ a(
|
|
2049
|
-
/* @__PURE__ */ a(
|
|
2116
|
+
/* @__PURE__ */ a(er, { children: "لا توجد بيانات لعرضها" }),
|
|
2117
|
+
/* @__PURE__ */ a(tr, { children: "هذا الجدول فارغ ولا يحتوي على بيانات للعرض" })
|
|
2050
2118
|
] }) });
|
|
2051
2119
|
}
|
|
2052
|
-
function
|
|
2053
|
-
return /* @__PURE__ */ o(
|
|
2054
|
-
/* @__PURE__ */ a(
|
|
2120
|
+
function or() {
|
|
2121
|
+
return /* @__PURE__ */ o(Xn, { children: [/* @__PURE__ */ o(Zn, { children: [
|
|
2122
|
+
/* @__PURE__ */ a($n, {
|
|
2055
2123
|
variant: "icon",
|
|
2056
2124
|
children: /* @__PURE__ */ a(xe, {})
|
|
2057
2125
|
}),
|
|
2058
|
-
/* @__PURE__ */ a(
|
|
2059
|
-
/* @__PURE__ */ a(
|
|
2060
|
-
] }), /* @__PURE__ */ a(
|
|
2126
|
+
/* @__PURE__ */ a(er, { children: "حدث خطأ ما" }),
|
|
2127
|
+
/* @__PURE__ */ a(tr, { children: "حدث خطأ اثناء جلب البيانات الرجاء التحقق من اتصالك الانترنت او اتصل بخدمة العملاء لدينا في حال تكراره" })
|
|
2128
|
+
] }), /* @__PURE__ */ a(nr, { children: /* @__PURE__ */ a(ge, {}) })] });
|
|
2061
2129
|
}
|
|
2062
2130
|
//#endregion
|
|
2063
2131
|
//#region src/components/custom/table/crudTable.tsx
|
|
2064
|
-
function
|
|
2065
|
-
return e.isLoading ? /* @__PURE__ */ a(
|
|
2132
|
+
function sr({ state: e, children: t }) {
|
|
2133
|
+
return e.isLoading ? /* @__PURE__ */ a(rr, { mode: "loading" }) : e.entities?.count == 0 ? /* @__PURE__ */ a(rr, { mode: "empty" }) : e.entities == null ? /* @__PURE__ */ a(rr, { mode: "loading" }) : /* @__PURE__ */ a(Hn, { children: t });
|
|
2066
2134
|
}
|
|
2067
2135
|
//#endregion
|
|
2068
2136
|
//#region src/components/pure/context-menu.tsx
|
|
2069
|
-
function
|
|
2137
|
+
function cr({ ...e }) {
|
|
2070
2138
|
return /* @__PURE__ */ a(E.Root, {
|
|
2071
2139
|
"data-slot": "context-menu",
|
|
2072
2140
|
...e
|
|
2073
2141
|
});
|
|
2074
2142
|
}
|
|
2075
|
-
function
|
|
2143
|
+
function lr({ className: e, ...t }) {
|
|
2076
2144
|
return /* @__PURE__ */ a(E.Trigger, {
|
|
2077
2145
|
"data-slot": "context-menu-trigger",
|
|
2078
2146
|
className: P("select-none", e),
|
|
2079
2147
|
...t
|
|
2080
2148
|
});
|
|
2081
2149
|
}
|
|
2082
|
-
function
|
|
2150
|
+
function ur({ ...e }) {
|
|
2083
2151
|
return /* @__PURE__ */ a(E.Group, {
|
|
2084
2152
|
"data-slot": "context-menu-group",
|
|
2085
2153
|
...e
|
|
2086
2154
|
});
|
|
2087
2155
|
}
|
|
2088
|
-
function
|
|
2156
|
+
function dr({ ...e }) {
|
|
2089
2157
|
return /* @__PURE__ */ a(E.Portal, {
|
|
2090
2158
|
"data-slot": "context-menu-portal",
|
|
2091
2159
|
...e
|
|
2092
2160
|
});
|
|
2093
2161
|
}
|
|
2094
|
-
function
|
|
2162
|
+
function fr({ ...e }) {
|
|
2095
2163
|
return /* @__PURE__ */ a(E.Sub, {
|
|
2096
2164
|
"data-slot": "context-menu-sub",
|
|
2097
2165
|
...e
|
|
2098
2166
|
});
|
|
2099
2167
|
}
|
|
2100
|
-
function
|
|
2168
|
+
function pr({ ...e }) {
|
|
2101
2169
|
return /* @__PURE__ */ a(E.RadioGroup, {
|
|
2102
2170
|
"data-slot": "context-menu-radio-group",
|
|
2103
2171
|
...e
|
|
2104
2172
|
});
|
|
2105
2173
|
}
|
|
2106
|
-
function
|
|
2174
|
+
function mr({ className: e, ...t }) {
|
|
2107
2175
|
return /* @__PURE__ */ a(E.Portal, { children: /* @__PURE__ */ a(E.Content, {
|
|
2108
2176
|
"data-slot": "context-menu-content",
|
|
2109
2177
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 bg-popover text-popover-foreground min-w-36 rounded-lg p-1 shadow-md ring-1 duration-100 z-50 max-h-(--radix-context-menu-content-available-height) origin-(--radix-context-menu-content-transform-origin) overflow-x-hidden overflow-y-auto", e),
|
|
2110
2178
|
...t
|
|
2111
2179
|
}) });
|
|
2112
2180
|
}
|
|
2113
|
-
function
|
|
2181
|
+
function hr({ className: e, inset: t, variant: n = "default", ...r }) {
|
|
2114
2182
|
return /* @__PURE__ */ a(E.Item, {
|
|
2115
2183
|
"data-slot": "context-menu-item",
|
|
2116
2184
|
"data-inset": t,
|
|
@@ -2119,7 +2187,7 @@ function dr({ className: e, inset: t, variant: n = "default", ...r }) {
|
|
|
2119
2187
|
...r
|
|
2120
2188
|
});
|
|
2121
2189
|
}
|
|
2122
|
-
function
|
|
2190
|
+
function gr({ className: e, inset: t, children: n, ...r }) {
|
|
2123
2191
|
return /* @__PURE__ */ o(E.SubTrigger, {
|
|
2124
2192
|
"data-slot": "context-menu-sub-trigger",
|
|
2125
2193
|
"data-inset": t,
|
|
@@ -2128,14 +2196,14 @@ function fr({ className: e, inset: t, children: n, ...r }) {
|
|
|
2128
2196
|
children: [n, /* @__PURE__ */ a(p, { className: "rtl:rotate-180 ms-auto" })]
|
|
2129
2197
|
});
|
|
2130
2198
|
}
|
|
2131
|
-
function
|
|
2199
|
+
function _r({ className: e, ...t }) {
|
|
2132
2200
|
return /* @__PURE__ */ a(E.SubContent, {
|
|
2133
2201
|
"data-slot": "context-menu-sub-content",
|
|
2134
2202
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 bg-popover text-popover-foreground min-w-32 rounded-lg border p-1 shadow-lg duration-100 z-50 origin-(--radix-context-menu-content-transform-origin) overflow-hidden", e),
|
|
2135
2203
|
...t
|
|
2136
2204
|
});
|
|
2137
2205
|
}
|
|
2138
|
-
function
|
|
2206
|
+
function vr({ className: e, children: t, checked: n, inset: r, ...i }) {
|
|
2139
2207
|
return /* @__PURE__ */ o(E.CheckboxItem, {
|
|
2140
2208
|
"data-slot": "context-menu-checkbox-item",
|
|
2141
2209
|
"data-inset": r,
|
|
@@ -2148,7 +2216,7 @@ function mr({ className: e, children: t, checked: n, inset: r, ...i }) {
|
|
|
2148
2216
|
}), t]
|
|
2149
2217
|
});
|
|
2150
2218
|
}
|
|
2151
|
-
function
|
|
2219
|
+
function yr({ className: e, children: t, inset: n, ...r }) {
|
|
2152
2220
|
return /* @__PURE__ */ o(E.RadioItem, {
|
|
2153
2221
|
"data-slot": "context-menu-radio-item",
|
|
2154
2222
|
"data-inset": n,
|
|
@@ -2160,7 +2228,7 @@ function hr({ className: e, children: t, inset: n, ...r }) {
|
|
|
2160
2228
|
}), t]
|
|
2161
2229
|
});
|
|
2162
2230
|
}
|
|
2163
|
-
function
|
|
2231
|
+
function br({ className: e, inset: t, ...n }) {
|
|
2164
2232
|
return /* @__PURE__ */ a(E.Label, {
|
|
2165
2233
|
"data-slot": "context-menu-label",
|
|
2166
2234
|
"data-inset": t,
|
|
@@ -2168,14 +2236,14 @@ function gr({ className: e, inset: t, ...n }) {
|
|
|
2168
2236
|
...n
|
|
2169
2237
|
});
|
|
2170
2238
|
}
|
|
2171
|
-
function
|
|
2239
|
+
function xr({ className: e, ...t }) {
|
|
2172
2240
|
return /* @__PURE__ */ a(E.Separator, {
|
|
2173
2241
|
"data-slot": "context-menu-separator",
|
|
2174
2242
|
className: P("bg-border -mx-1 my-1 h-px", e),
|
|
2175
2243
|
...t
|
|
2176
2244
|
});
|
|
2177
2245
|
}
|
|
2178
|
-
function
|
|
2246
|
+
function Sr({ className: e, ...t }) {
|
|
2179
2247
|
return /* @__PURE__ */ a("span", {
|
|
2180
2248
|
"data-slot": "context-menu-shortcut",
|
|
2181
2249
|
className: P("text-muted-foreground group-focus/context-menu-item:text-accent-foreground ms-auto text-xs tracking-widest", e),
|
|
@@ -2184,14 +2252,14 @@ function vr({ className: e, ...t }) {
|
|
|
2184
2252
|
}
|
|
2185
2253
|
//#endregion
|
|
2186
2254
|
//#region src/components/custom/table/crudTableBodyRow.tsx
|
|
2187
|
-
function
|
|
2188
|
-
return /* @__PURE__ */ a(i, { children: /* @__PURE__ */ o(
|
|
2255
|
+
function Cr({ tableRows: e, dropdownMenu: t, contextMenuContent: n }) {
|
|
2256
|
+
return /* @__PURE__ */ a(i, { children: /* @__PURE__ */ o(cr, {
|
|
2189
2257
|
dir: "rtl",
|
|
2190
|
-
children: [/* @__PURE__ */ a(
|
|
2258
|
+
children: [/* @__PURE__ */ a(lr, {
|
|
2191
2259
|
asChild: !0,
|
|
2192
|
-
children: /* @__PURE__ */ o(
|
|
2260
|
+
children: /* @__PURE__ */ o(Kn, {
|
|
2193
2261
|
className: "hover:bg-secondary/50 transition-colors",
|
|
2194
|
-
children: [/* @__PURE__ */ a(
|
|
2262
|
+
children: [/* @__PURE__ */ a(Jn, { children: t }), e.map((e, t) => /* @__PURE__ */ a(Jn, { children: /* @__PURE__ */ a("span", {
|
|
2195
2263
|
className: e.rowStyles,
|
|
2196
2264
|
children: e.rowName
|
|
2197
2265
|
}) }, t))]
|
|
@@ -2201,18 +2269,18 @@ function yr({ tableRows: e, dropdownMenu: t, contextMenuContent: n }) {
|
|
|
2201
2269
|
}
|
|
2202
2270
|
//#endregion
|
|
2203
2271
|
//#region src/components/custom/table/crudTableCard.tsx
|
|
2204
|
-
function
|
|
2272
|
+
function wr({ cards: e }) {
|
|
2205
2273
|
return /* @__PURE__ */ a("div", {
|
|
2206
2274
|
className: "mb-5 grid grid-cols-1 sm:grid-cols-2 gap-5",
|
|
2207
|
-
children: e.map((e, t) => /* @__PURE__ */ o(
|
|
2275
|
+
children: e.map((e, t) => /* @__PURE__ */ o(yn, {
|
|
2208
2276
|
className: "shadow-sm",
|
|
2209
|
-
children: [/* @__PURE__ */ o(
|
|
2277
|
+
children: [/* @__PURE__ */ o(bn, {
|
|
2210
2278
|
className: "flex flex-row items-center justify-between space-y-0 pb-2",
|
|
2211
|
-
children: [/* @__PURE__ */ a(
|
|
2279
|
+
children: [/* @__PURE__ */ a(xn, {
|
|
2212
2280
|
className: "text-sm font-medium text-muted-foreground",
|
|
2213
2281
|
children: e.title
|
|
2214
2282
|
}), e.icon]
|
|
2215
|
-
}), /* @__PURE__ */ a(
|
|
2283
|
+
}), /* @__PURE__ */ a(wn, { children: /* @__PURE__ */ a("div", {
|
|
2216
2284
|
className: "text-2xl font-bold",
|
|
2217
2285
|
children: e.data
|
|
2218
2286
|
}) })]
|
|
@@ -2221,7 +2289,7 @@ function br({ cards: e }) {
|
|
|
2221
2289
|
}
|
|
2222
2290
|
//#endregion
|
|
2223
2291
|
//#region src/components/custom/table/crudTableHeader.tsx
|
|
2224
|
-
function
|
|
2292
|
+
function Tr({ title: e, buttonTitle: t, createComp: n, isButtonVisible: r = !0 }) {
|
|
2225
2293
|
let [s, c] = x(!1), l = De.isValidElement(n) ? De.cloneElement(n, { onSuccess: (e) => {
|
|
2226
2294
|
c(!1), n.props.onSuccess?.(e);
|
|
2227
2295
|
} }) : n;
|
|
@@ -2240,10 +2308,10 @@ function xr({ title: e, buttonTitle: t, createComp: n, isButtonVisible: r = !0 }
|
|
|
2240
2308
|
}
|
|
2241
2309
|
//#endregion
|
|
2242
2310
|
//#region src/components/custom/table/crudTableHeaderRows.tsx
|
|
2243
|
-
function
|
|
2244
|
-
return /* @__PURE__ */ a(
|
|
2311
|
+
function Er({ tableHeadRows: e }) {
|
|
2312
|
+
return /* @__PURE__ */ a(Un, {
|
|
2245
2313
|
className: "bg-muted",
|
|
2246
|
-
children: /* @__PURE__ */ a(
|
|
2314
|
+
children: /* @__PURE__ */ a(Kn, { children: e.map((e, t) => /* @__PURE__ */ a(qn, {
|
|
2247
2315
|
className: e.rowStyles,
|
|
2248
2316
|
children: e.rowName
|
|
2249
2317
|
}, t)) })
|
|
@@ -2251,7 +2319,7 @@ function Sr({ tableHeadRows: e }) {
|
|
|
2251
2319
|
}
|
|
2252
2320
|
//#endregion
|
|
2253
2321
|
//#region src/components/pure/pagination.tsx
|
|
2254
|
-
function
|
|
2322
|
+
function Dr({ className: e, ...t }) {
|
|
2255
2323
|
return /* @__PURE__ */ a("nav", {
|
|
2256
2324
|
role: "navigation",
|
|
2257
2325
|
"aria-label": "pagination",
|
|
@@ -2260,20 +2328,20 @@ function Cr({ className: e, ...t }) {
|
|
|
2260
2328
|
...t
|
|
2261
2329
|
});
|
|
2262
2330
|
}
|
|
2263
|
-
function
|
|
2331
|
+
function Or({ className: e, ...t }) {
|
|
2264
2332
|
return /* @__PURE__ */ a("ul", {
|
|
2265
2333
|
"data-slot": "pagination-content",
|
|
2266
2334
|
className: P("gap-0.5 flex items-center", e),
|
|
2267
2335
|
...t
|
|
2268
2336
|
});
|
|
2269
2337
|
}
|
|
2270
|
-
function
|
|
2338
|
+
function kr({ ...e }) {
|
|
2271
2339
|
return /* @__PURE__ */ a("li", {
|
|
2272
2340
|
"data-slot": "pagination-item",
|
|
2273
2341
|
...e
|
|
2274
2342
|
});
|
|
2275
2343
|
}
|
|
2276
|
-
function
|
|
2344
|
+
function Ar({ className: e, isActive: t, size: n = "icon", ...r }) {
|
|
2277
2345
|
return /* @__PURE__ */ a(F, {
|
|
2278
2346
|
asChild: !0,
|
|
2279
2347
|
variant: t ? "outline" : "ghost",
|
|
@@ -2287,8 +2355,8 @@ function Er({ className: e, isActive: t, size: n = "icon", ...r }) {
|
|
|
2287
2355
|
})
|
|
2288
2356
|
});
|
|
2289
2357
|
}
|
|
2290
|
-
function
|
|
2291
|
-
return /* @__PURE__ */ o(
|
|
2358
|
+
function jr({ className: e, text: t = "Previous", ...n }) {
|
|
2359
|
+
return /* @__PURE__ */ o(Ar, {
|
|
2292
2360
|
"aria-label": "Go to previous page",
|
|
2293
2361
|
size: "default",
|
|
2294
2362
|
className: P("ps-1.5!", e),
|
|
@@ -2302,8 +2370,8 @@ function Dr({ className: e, text: t = "Previous", ...n }) {
|
|
|
2302
2370
|
})]
|
|
2303
2371
|
});
|
|
2304
2372
|
}
|
|
2305
|
-
function
|
|
2306
|
-
return /* @__PURE__ */ o(
|
|
2373
|
+
function Mr({ className: e, text: t = "Next", ...n }) {
|
|
2374
|
+
return /* @__PURE__ */ o(Ar, {
|
|
2307
2375
|
"aria-label": "Go to next page",
|
|
2308
2376
|
size: "default",
|
|
2309
2377
|
className: P("pe-1.5!", e),
|
|
@@ -2317,7 +2385,7 @@ function Or({ className: e, text: t = "Next", ...n }) {
|
|
|
2317
2385
|
})]
|
|
2318
2386
|
});
|
|
2319
2387
|
}
|
|
2320
|
-
function
|
|
2388
|
+
function Nr({ className: e, ...t }) {
|
|
2321
2389
|
return /* @__PURE__ */ o("span", {
|
|
2322
2390
|
"aria-hidden": !0,
|
|
2323
2391
|
"data-slot": "pagination-ellipsis",
|
|
@@ -2331,25 +2399,25 @@ function kr({ className: e, ...t }) {
|
|
|
2331
2399
|
}
|
|
2332
2400
|
//#endregion
|
|
2333
2401
|
//#region src/components/pure/dropdown-menu.tsx
|
|
2334
|
-
function
|
|
2402
|
+
function Pr({ ...e }) {
|
|
2335
2403
|
return /* @__PURE__ */ a(D.Root, {
|
|
2336
2404
|
"data-slot": "dropdown-menu",
|
|
2337
2405
|
...e
|
|
2338
2406
|
});
|
|
2339
2407
|
}
|
|
2340
|
-
function
|
|
2408
|
+
function Fr({ ...e }) {
|
|
2341
2409
|
return /* @__PURE__ */ a(D.Portal, {
|
|
2342
2410
|
"data-slot": "dropdown-menu-portal",
|
|
2343
2411
|
...e
|
|
2344
2412
|
});
|
|
2345
2413
|
}
|
|
2346
|
-
function
|
|
2414
|
+
function Ir({ ...e }) {
|
|
2347
2415
|
return /* @__PURE__ */ a(D.Trigger, {
|
|
2348
2416
|
"data-slot": "dropdown-menu-trigger",
|
|
2349
2417
|
...e
|
|
2350
2418
|
});
|
|
2351
2419
|
}
|
|
2352
|
-
function
|
|
2420
|
+
function Lr({ className: e, align: t = "start", sideOffset: n = 4, ...r }) {
|
|
2353
2421
|
return /* @__PURE__ */ a(D.Portal, { children: /* @__PURE__ */ a(D.Content, {
|
|
2354
2422
|
"data-slot": "dropdown-menu-content",
|
|
2355
2423
|
sideOffset: n,
|
|
@@ -2358,7 +2426,7 @@ function Nr({ className: e, align: t = "start", sideOffset: n = 4, ...r }) {
|
|
|
2358
2426
|
...r
|
|
2359
2427
|
}) });
|
|
2360
2428
|
}
|
|
2361
|
-
function
|
|
2429
|
+
function Rr({ ...e }) {
|
|
2362
2430
|
return /* @__PURE__ */ a(D.Group, {
|
|
2363
2431
|
"data-slot": "dropdown-menu-group",
|
|
2364
2432
|
...e
|
|
@@ -2373,7 +2441,7 @@ function B({ className: e, inset: t, variant: n = "default", ...r }) {
|
|
|
2373
2441
|
...r
|
|
2374
2442
|
});
|
|
2375
2443
|
}
|
|
2376
|
-
function
|
|
2444
|
+
function zr({ className: e, children: t, checked: n, inset: r, ...i }) {
|
|
2377
2445
|
return /* @__PURE__ */ o(D.CheckboxItem, {
|
|
2378
2446
|
"data-slot": "dropdown-menu-checkbox-item",
|
|
2379
2447
|
"data-inset": r,
|
|
@@ -2387,13 +2455,13 @@ function Fr({ className: e, children: t, checked: n, inset: r, ...i }) {
|
|
|
2387
2455
|
}), t]
|
|
2388
2456
|
});
|
|
2389
2457
|
}
|
|
2390
|
-
function
|
|
2458
|
+
function Br({ ...e }) {
|
|
2391
2459
|
return /* @__PURE__ */ a(D.RadioGroup, {
|
|
2392
2460
|
"data-slot": "dropdown-menu-radio-group",
|
|
2393
2461
|
...e
|
|
2394
2462
|
});
|
|
2395
2463
|
}
|
|
2396
|
-
function
|
|
2464
|
+
function Vr({ className: e, children: t, inset: n, ...r }) {
|
|
2397
2465
|
return /* @__PURE__ */ o(D.RadioItem, {
|
|
2398
2466
|
"data-slot": "dropdown-menu-radio-item",
|
|
2399
2467
|
"data-inset": n,
|
|
@@ -2406,7 +2474,7 @@ function Lr({ className: e, children: t, inset: n, ...r }) {
|
|
|
2406
2474
|
}), t]
|
|
2407
2475
|
});
|
|
2408
2476
|
}
|
|
2409
|
-
function
|
|
2477
|
+
function Hr({ className: e, inset: t, ...n }) {
|
|
2410
2478
|
return /* @__PURE__ */ a(D.Label, {
|
|
2411
2479
|
"data-slot": "dropdown-menu-label",
|
|
2412
2480
|
"data-inset": t,
|
|
@@ -2414,27 +2482,27 @@ function Rr({ className: e, inset: t, ...n }) {
|
|
|
2414
2482
|
...n
|
|
2415
2483
|
});
|
|
2416
2484
|
}
|
|
2417
|
-
function
|
|
2485
|
+
function Ur({ className: e, ...t }) {
|
|
2418
2486
|
return /* @__PURE__ */ a(D.Separator, {
|
|
2419
2487
|
"data-slot": "dropdown-menu-separator",
|
|
2420
2488
|
className: P("bg-border -mx-1 my-1 h-px", e),
|
|
2421
2489
|
...t
|
|
2422
2490
|
});
|
|
2423
2491
|
}
|
|
2424
|
-
function
|
|
2492
|
+
function Wr({ className: e, ...t }) {
|
|
2425
2493
|
return /* @__PURE__ */ a("span", {
|
|
2426
2494
|
"data-slot": "dropdown-menu-shortcut",
|
|
2427
2495
|
className: P("text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground ms-auto text-xs tracking-widest", e),
|
|
2428
2496
|
...t
|
|
2429
2497
|
});
|
|
2430
2498
|
}
|
|
2431
|
-
function
|
|
2499
|
+
function Gr({ ...e }) {
|
|
2432
2500
|
return /* @__PURE__ */ a(D.Sub, {
|
|
2433
2501
|
"data-slot": "dropdown-menu-sub",
|
|
2434
2502
|
...e
|
|
2435
2503
|
});
|
|
2436
2504
|
}
|
|
2437
|
-
function
|
|
2505
|
+
function Kr({ className: e, inset: t, children: n, ...r }) {
|
|
2438
2506
|
return /* @__PURE__ */ o(D.SubTrigger, {
|
|
2439
2507
|
"data-slot": "dropdown-menu-sub-trigger",
|
|
2440
2508
|
"data-inset": t,
|
|
@@ -2443,7 +2511,7 @@ function Hr({ className: e, inset: t, children: n, ...r }) {
|
|
|
2443
2511
|
children: [n, /* @__PURE__ */ a(p, { className: "rtl:rotate-180 ms-auto" })]
|
|
2444
2512
|
});
|
|
2445
2513
|
}
|
|
2446
|
-
function
|
|
2514
|
+
function qr({ className: e, ...t }) {
|
|
2447
2515
|
return /* @__PURE__ */ a(D.SubContent, {
|
|
2448
2516
|
"data-slot": "dropdown-menu-sub-content",
|
|
2449
2517
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/10 bg-popover text-popover-foreground min-w-[96px] rounded-md p-1 shadow-lg ring-1 duration-100 z-50 origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden", e),
|
|
@@ -2452,51 +2520,51 @@ function Ur({ className: e, ...t }) {
|
|
|
2452
2520
|
}
|
|
2453
2521
|
//#endregion
|
|
2454
2522
|
//#region src/hooks/use-mobile.ts
|
|
2455
|
-
var
|
|
2456
|
-
function
|
|
2523
|
+
var Jr = 768;
|
|
2524
|
+
function Yr() {
|
|
2457
2525
|
let [e, t] = y.useState(void 0);
|
|
2458
2526
|
return y.useEffect(() => {
|
|
2459
|
-
let e = window.matchMedia(`(max-width: ${
|
|
2460
|
-
t(window.innerWidth <
|
|
2527
|
+
let e = window.matchMedia(`(max-width: ${Jr - 1}px)`), n = () => {
|
|
2528
|
+
t(window.innerWidth < Jr);
|
|
2461
2529
|
};
|
|
2462
|
-
return e.addEventListener("change", n), t(window.innerWidth <
|
|
2530
|
+
return e.addEventListener("change", n), t(window.innerWidth < Jr), () => e.removeEventListener("change", n);
|
|
2463
2531
|
}, []), !!e;
|
|
2464
2532
|
}
|
|
2465
2533
|
//#endregion
|
|
2466
2534
|
//#region src/components/pure/sheet.tsx
|
|
2467
|
-
function
|
|
2535
|
+
function Xr({ ...e }) {
|
|
2468
2536
|
return /* @__PURE__ */ a(w.Root, {
|
|
2469
2537
|
"data-slot": "sheet",
|
|
2470
2538
|
...e
|
|
2471
2539
|
});
|
|
2472
2540
|
}
|
|
2473
|
-
function
|
|
2541
|
+
function Zr({ ...e }) {
|
|
2474
2542
|
return /* @__PURE__ */ a(w.Trigger, {
|
|
2475
2543
|
"data-slot": "sheet-trigger",
|
|
2476
2544
|
...e
|
|
2477
2545
|
});
|
|
2478
2546
|
}
|
|
2479
|
-
function
|
|
2547
|
+
function Qr({ ...e }) {
|
|
2480
2548
|
return /* @__PURE__ */ a(w.Close, {
|
|
2481
2549
|
"data-slot": "sheet-close",
|
|
2482
2550
|
...e
|
|
2483
2551
|
});
|
|
2484
2552
|
}
|
|
2485
|
-
function
|
|
2553
|
+
function $r({ ...e }) {
|
|
2486
2554
|
return /* @__PURE__ */ a(w.Portal, {
|
|
2487
2555
|
"data-slot": "sheet-portal",
|
|
2488
2556
|
...e
|
|
2489
2557
|
});
|
|
2490
2558
|
}
|
|
2491
|
-
function
|
|
2559
|
+
function ei({ className: e, ...t }) {
|
|
2492
2560
|
return /* @__PURE__ */ a(w.Overlay, {
|
|
2493
2561
|
"data-slot": "sheet-overlay",
|
|
2494
2562
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/10 duration-100 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50", e),
|
|
2495
2563
|
...t
|
|
2496
2564
|
});
|
|
2497
2565
|
}
|
|
2498
|
-
function
|
|
2499
|
-
return /* @__PURE__ */ o(
|
|
2566
|
+
function ti({ className: e, children: t, side: n = "right", showCloseButton: r = !0, ...i }) {
|
|
2567
|
+
return /* @__PURE__ */ o($r, { children: [/* @__PURE__ */ a(ei, {}), /* @__PURE__ */ o(w.Content, {
|
|
2500
2568
|
"data-slot": "sheet-content",
|
|
2501
2569
|
"data-side": n,
|
|
2502
2570
|
className: P("bg-background data-open:animate-in data-closed:animate-out data-[side=right]:data-closed:slide-out-to-right-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=top]:data-closed:slide-out-to-top-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:fade-out-0 data-open:fade-in-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=bottom]:data-open:slide-in-from-bottom-10 fixed z-50 flex flex-col gap-4 bg-clip-padding text-sm shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-e data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-s data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm", e),
|
|
@@ -2516,28 +2584,28 @@ function Zr({ className: e, children: t, side: n = "right", showCloseButton: r =
|
|
|
2516
2584
|
})]
|
|
2517
2585
|
})] });
|
|
2518
2586
|
}
|
|
2519
|
-
function
|
|
2587
|
+
function ni({ className: e, ...t }) {
|
|
2520
2588
|
return /* @__PURE__ */ a("div", {
|
|
2521
2589
|
"data-slot": "sheet-header",
|
|
2522
2590
|
className: P("gap-0.5 p-4 flex flex-col", e),
|
|
2523
2591
|
...t
|
|
2524
2592
|
});
|
|
2525
2593
|
}
|
|
2526
|
-
function
|
|
2594
|
+
function ri({ className: e, ...t }) {
|
|
2527
2595
|
return /* @__PURE__ */ a("div", {
|
|
2528
2596
|
"data-slot": "sheet-footer",
|
|
2529
2597
|
className: P("gap-2 p-4 mt-auto flex flex-col", e),
|
|
2530
2598
|
...t
|
|
2531
2599
|
});
|
|
2532
2600
|
}
|
|
2533
|
-
function
|
|
2601
|
+
function ii({ className: e, ...t }) {
|
|
2534
2602
|
return /* @__PURE__ */ a(w.Title, {
|
|
2535
2603
|
"data-slot": "sheet-title",
|
|
2536
2604
|
className: P("text-foreground text-base font-medium", e),
|
|
2537
2605
|
...t
|
|
2538
2606
|
});
|
|
2539
2607
|
}
|
|
2540
|
-
function
|
|
2608
|
+
function ai({ className: e, ...t }) {
|
|
2541
2609
|
return /* @__PURE__ */ a(w.Description, {
|
|
2542
2610
|
"data-slot": "sheet-description",
|
|
2543
2611
|
className: P("text-muted-foreground text-sm", e),
|
|
@@ -2555,26 +2623,26 @@ function V({ className: e, ...t }) {
|
|
|
2555
2623
|
}
|
|
2556
2624
|
//#endregion
|
|
2557
2625
|
//#region src/components/pure/tooltip.tsx
|
|
2558
|
-
function
|
|
2626
|
+
function oi({ delayDuration: e = 0, ...t }) {
|
|
2559
2627
|
return /* @__PURE__ */ a(O.Provider, {
|
|
2560
2628
|
"data-slot": "tooltip-provider",
|
|
2561
2629
|
delayDuration: e,
|
|
2562
2630
|
...t
|
|
2563
2631
|
});
|
|
2564
2632
|
}
|
|
2565
|
-
function
|
|
2633
|
+
function si({ ...e }) {
|
|
2566
2634
|
return /* @__PURE__ */ a(O.Root, {
|
|
2567
2635
|
"data-slot": "tooltip",
|
|
2568
2636
|
...e
|
|
2569
2637
|
});
|
|
2570
2638
|
}
|
|
2571
|
-
function
|
|
2639
|
+
function ci({ ...e }) {
|
|
2572
2640
|
return /* @__PURE__ */ a(O.Trigger, {
|
|
2573
2641
|
"data-slot": "tooltip-trigger",
|
|
2574
2642
|
...e
|
|
2575
2643
|
});
|
|
2576
2644
|
}
|
|
2577
|
-
function
|
|
2645
|
+
function li({ className: e, sideOffset: t = 0, children: n, ...r }) {
|
|
2578
2646
|
return /* @__PURE__ */ a(O.Portal, { children: /* @__PURE__ */ o(O.Content, {
|
|
2579
2647
|
"data-slot": "tooltip-content",
|
|
2580
2648
|
sideOffset: t,
|
|
@@ -2585,16 +2653,16 @@ function ai({ className: e, sideOffset: t = 0, children: n, ...r }) {
|
|
|
2585
2653
|
}
|
|
2586
2654
|
//#endregion
|
|
2587
2655
|
//#region src/components/pure/sidebar.tsx
|
|
2588
|
-
var
|
|
2589
|
-
function
|
|
2590
|
-
let e = y.useContext(
|
|
2656
|
+
var ui = "sidebar_state", di = 3600 * 24 * 7, fi = "16rem", pi = "18rem", mi = "3rem", hi = "b", gi = y.createContext(null);
|
|
2657
|
+
function _i() {
|
|
2658
|
+
let e = y.useContext(gi);
|
|
2591
2659
|
if (!e) throw Error("useSidebar must be used within a SidebarProvider.");
|
|
2592
2660
|
return e;
|
|
2593
2661
|
}
|
|
2594
|
-
function
|
|
2595
|
-
let c =
|
|
2662
|
+
function vi({ defaultOpen: e = !0, open: t, onOpenChange: n, className: r, style: i, children: o, ...s }) {
|
|
2663
|
+
let c = Yr(), [l, u] = y.useState(!1), [d, f] = y.useState(e), p = t ?? d, m = y.useCallback((e) => {
|
|
2596
2664
|
let t = typeof e == "function" ? e(p) : e;
|
|
2597
|
-
n ? n(t) : f(t), document.cookie = `${
|
|
2665
|
+
n ? n(t) : f(t), document.cookie = `${ui}=${t}; path=/; max-age=${di}`;
|
|
2598
2666
|
}, [n, p]), h = y.useCallback(() => c ? u((e) => !e) : m((e) => !e), [
|
|
2599
2667
|
c,
|
|
2600
2668
|
m,
|
|
@@ -2602,7 +2670,7 @@ function mi({ defaultOpen: e = !0, open: t, onOpenChange: n, className: r, style
|
|
|
2602
2670
|
]);
|
|
2603
2671
|
y.useEffect(() => {
|
|
2604
2672
|
let e = (e) => {
|
|
2605
|
-
e.key ===
|
|
2673
|
+
e.key === hi && (e.metaKey || e.ctrlKey) && (e.preventDefault(), h());
|
|
2606
2674
|
};
|
|
2607
2675
|
return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
|
|
2608
2676
|
}, [h]);
|
|
@@ -2623,13 +2691,13 @@ function mi({ defaultOpen: e = !0, open: t, onOpenChange: n, className: r, style
|
|
|
2623
2691
|
u,
|
|
2624
2692
|
h
|
|
2625
2693
|
]);
|
|
2626
|
-
return /* @__PURE__ */ a(
|
|
2694
|
+
return /* @__PURE__ */ a(gi.Provider, {
|
|
2627
2695
|
value: _,
|
|
2628
2696
|
children: /* @__PURE__ */ a("div", {
|
|
2629
2697
|
"data-slot": "sidebar-wrapper",
|
|
2630
2698
|
style: {
|
|
2631
|
-
"--sidebar-width":
|
|
2632
|
-
"--sidebar-width-icon":
|
|
2699
|
+
"--sidebar-width": fi,
|
|
2700
|
+
"--sidebar-width-icon": mi,
|
|
2633
2701
|
...i
|
|
2634
2702
|
},
|
|
2635
2703
|
className: P("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full", r),
|
|
@@ -2638,28 +2706,28 @@ function mi({ defaultOpen: e = !0, open: t, onOpenChange: n, className: r, style
|
|
|
2638
2706
|
})
|
|
2639
2707
|
});
|
|
2640
2708
|
}
|
|
2641
|
-
function
|
|
2642
|
-
let { isMobile: l, state: u, openMobile: d, setOpenMobile: f } =
|
|
2709
|
+
function yi({ side: e = "left", variant: t = "sidebar", collapsible: n = "offcanvas", className: r, children: i, dir: s, ...c }) {
|
|
2710
|
+
let { isMobile: l, state: u, openMobile: d, setOpenMobile: f } = _i();
|
|
2643
2711
|
return n === "none" ? /* @__PURE__ */ a("div", {
|
|
2644
2712
|
"data-slot": "sidebar",
|
|
2645
2713
|
className: P("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col", r),
|
|
2646
2714
|
...c,
|
|
2647
2715
|
children: i
|
|
2648
|
-
}) : l ? /* @__PURE__ */ a(
|
|
2716
|
+
}) : l ? /* @__PURE__ */ a(Xr, {
|
|
2649
2717
|
open: d,
|
|
2650
2718
|
onOpenChange: f,
|
|
2651
2719
|
...c,
|
|
2652
|
-
children: /* @__PURE__ */ o(
|
|
2720
|
+
children: /* @__PURE__ */ o(ti, {
|
|
2653
2721
|
dir: s,
|
|
2654
2722
|
"data-sidebar": "sidebar",
|
|
2655
2723
|
"data-slot": "sidebar",
|
|
2656
2724
|
"data-mobile": "true",
|
|
2657
2725
|
className: "bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",
|
|
2658
|
-
style: { "--sidebar-width":
|
|
2726
|
+
style: { "--sidebar-width": pi },
|
|
2659
2727
|
side: e,
|
|
2660
|
-
children: [/* @__PURE__ */ o(
|
|
2728
|
+
children: [/* @__PURE__ */ o(ni, {
|
|
2661
2729
|
className: "sr-only",
|
|
2662
|
-
children: [/* @__PURE__ */ a(
|
|
2730
|
+
children: [/* @__PURE__ */ a(ii, { children: "Sidebar" }), /* @__PURE__ */ a(ai, { children: "Displays the mobile sidebar." })]
|
|
2663
2731
|
}), /* @__PURE__ */ a("div", {
|
|
2664
2732
|
className: "flex h-full w-full flex-col",
|
|
2665
2733
|
children: i
|
|
@@ -2689,8 +2757,8 @@ function hi({ side: e = "left", variant: t = "sidebar", collapsible: n = "offcan
|
|
|
2689
2757
|
})]
|
|
2690
2758
|
});
|
|
2691
2759
|
}
|
|
2692
|
-
function
|
|
2693
|
-
let { toggleSidebar: r } =
|
|
2760
|
+
function bi({ className: e, onClick: t, ...n }) {
|
|
2761
|
+
let { toggleSidebar: r } = _i();
|
|
2694
2762
|
return /* @__PURE__ */ o(F, {
|
|
2695
2763
|
"data-sidebar": "trigger",
|
|
2696
2764
|
"data-slot": "sidebar-trigger",
|
|
@@ -2707,8 +2775,8 @@ function gi({ className: e, onClick: t, ...n }) {
|
|
|
2707
2775
|
})]
|
|
2708
2776
|
});
|
|
2709
2777
|
}
|
|
2710
|
-
function
|
|
2711
|
-
let { toggleSidebar: n } =
|
|
2778
|
+
function xi({ className: e, ...t }) {
|
|
2779
|
+
let { toggleSidebar: n } = _i();
|
|
2712
2780
|
return /* @__PURE__ */ a("button", {
|
|
2713
2781
|
"data-sidebar": "rail",
|
|
2714
2782
|
"data-slot": "sidebar-rail",
|
|
@@ -2720,14 +2788,14 @@ function _i({ className: e, ...t }) {
|
|
|
2720
2788
|
...t
|
|
2721
2789
|
});
|
|
2722
2790
|
}
|
|
2723
|
-
function
|
|
2791
|
+
function Si({ className: e, ...t }) {
|
|
2724
2792
|
return /* @__PURE__ */ a("main", {
|
|
2725
2793
|
"data-slot": "sidebar-inset",
|
|
2726
2794
|
className: P("bg-background md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ms-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ms-2 relative flex w-full flex-1 flex-col", e),
|
|
2727
2795
|
...t
|
|
2728
2796
|
});
|
|
2729
2797
|
}
|
|
2730
|
-
function
|
|
2798
|
+
function Ci({ className: e, ...t }) {
|
|
2731
2799
|
return /* @__PURE__ */ a(z, {
|
|
2732
2800
|
"data-slot": "sidebar-input",
|
|
2733
2801
|
"data-sidebar": "input",
|
|
@@ -2735,7 +2803,7 @@ function yi({ className: e, ...t }) {
|
|
|
2735
2803
|
...t
|
|
2736
2804
|
});
|
|
2737
2805
|
}
|
|
2738
|
-
function
|
|
2806
|
+
function wi({ className: e, ...t }) {
|
|
2739
2807
|
return /* @__PURE__ */ a("div", {
|
|
2740
2808
|
"data-slot": "sidebar-header",
|
|
2741
2809
|
"data-sidebar": "header",
|
|
@@ -2743,7 +2811,7 @@ function bi({ className: e, ...t }) {
|
|
|
2743
2811
|
...t
|
|
2744
2812
|
});
|
|
2745
2813
|
}
|
|
2746
|
-
function
|
|
2814
|
+
function Ti({ className: e, ...t }) {
|
|
2747
2815
|
return /* @__PURE__ */ a("div", {
|
|
2748
2816
|
"data-slot": "sidebar-footer",
|
|
2749
2817
|
"data-sidebar": "footer",
|
|
@@ -2751,7 +2819,7 @@ function xi({ className: e, ...t }) {
|
|
|
2751
2819
|
...t
|
|
2752
2820
|
});
|
|
2753
2821
|
}
|
|
2754
|
-
function
|
|
2822
|
+
function Ei({ className: e, ...t }) {
|
|
2755
2823
|
return /* @__PURE__ */ a(L, {
|
|
2756
2824
|
"data-slot": "sidebar-separator",
|
|
2757
2825
|
"data-sidebar": "separator",
|
|
@@ -2759,7 +2827,7 @@ function Si({ className: e, ...t }) {
|
|
|
2759
2827
|
...t
|
|
2760
2828
|
});
|
|
2761
2829
|
}
|
|
2762
|
-
function
|
|
2830
|
+
function Di({ className: e, ...t }) {
|
|
2763
2831
|
return /* @__PURE__ */ a("div", {
|
|
2764
2832
|
"data-slot": "sidebar-content",
|
|
2765
2833
|
"data-sidebar": "content",
|
|
@@ -2767,7 +2835,7 @@ function Ci({ className: e, ...t }) {
|
|
|
2767
2835
|
...t
|
|
2768
2836
|
});
|
|
2769
2837
|
}
|
|
2770
|
-
function
|
|
2838
|
+
function Oi({ className: e, ...t }) {
|
|
2771
2839
|
return /* @__PURE__ */ a("div", {
|
|
2772
2840
|
"data-slot": "sidebar-group",
|
|
2773
2841
|
"data-sidebar": "group",
|
|
@@ -2775,7 +2843,7 @@ function wi({ className: e, ...t }) {
|
|
|
2775
2843
|
...t
|
|
2776
2844
|
});
|
|
2777
2845
|
}
|
|
2778
|
-
function
|
|
2846
|
+
function ki({ className: e, asChild: t = !1, ...n }) {
|
|
2779
2847
|
return /* @__PURE__ */ a(t ? C : "div", {
|
|
2780
2848
|
"data-slot": "sidebar-group-label",
|
|
2781
2849
|
"data-sidebar": "group-label",
|
|
@@ -2783,7 +2851,7 @@ function Ti({ className: e, asChild: t = !1, ...n }) {
|
|
|
2783
2851
|
...n
|
|
2784
2852
|
});
|
|
2785
2853
|
}
|
|
2786
|
-
function
|
|
2854
|
+
function Ai({ className: e, asChild: t = !1, ...n }) {
|
|
2787
2855
|
return /* @__PURE__ */ a(t ? C : "button", {
|
|
2788
2856
|
"data-slot": "sidebar-group-action",
|
|
2789
2857
|
"data-sidebar": "group-action",
|
|
@@ -2791,7 +2859,7 @@ function Ei({ className: e, asChild: t = !1, ...n }) {
|
|
|
2791
2859
|
...n
|
|
2792
2860
|
});
|
|
2793
2861
|
}
|
|
2794
|
-
function
|
|
2862
|
+
function ji({ className: e, ...t }) {
|
|
2795
2863
|
return /* @__PURE__ */ a("div", {
|
|
2796
2864
|
"data-slot": "sidebar-group-content",
|
|
2797
2865
|
"data-sidebar": "group-content",
|
|
@@ -2815,7 +2883,7 @@ function U({ className: e, ...t }) {
|
|
|
2815
2883
|
...t
|
|
2816
2884
|
});
|
|
2817
2885
|
}
|
|
2818
|
-
var
|
|
2886
|
+
var Mi = S("ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground gap-2 rounded-md p-2 text-start text-sm transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pe-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! focus-visible:ring-2 data-active:font-medium peer/menu-button flex w-full items-center overflow-hidden outline-hidden group/menu-button disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&_svg]:size-6 [&_svg]:shrink-0", {
|
|
2819
2887
|
variants: {
|
|
2820
2888
|
variant: {
|
|
2821
2889
|
default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
|
|
@@ -2833,28 +2901,28 @@ var Oi = S("ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-
|
|
|
2833
2901
|
}
|
|
2834
2902
|
});
|
|
2835
2903
|
function W({ asChild: e = !1, isActive: t = !1, variant: n = "default", size: r = "default", tooltip: i, className: s, ...c }) {
|
|
2836
|
-
let l = e ? C : "button", { isMobile: u, state: d } =
|
|
2904
|
+
let l = e ? C : "button", { isMobile: u, state: d } = _i(), f = /* @__PURE__ */ a(l, {
|
|
2837
2905
|
"data-slot": "sidebar-menu-button",
|
|
2838
2906
|
"data-sidebar": "menu-button",
|
|
2839
2907
|
"data-size": r,
|
|
2840
2908
|
"data-active": t,
|
|
2841
|
-
className: P(
|
|
2909
|
+
className: P(Mi({
|
|
2842
2910
|
variant: n,
|
|
2843
2911
|
size: r
|
|
2844
2912
|
}), s),
|
|
2845
2913
|
...c
|
|
2846
2914
|
});
|
|
2847
|
-
return i ? (typeof i == "string" && (i = { children: i }), /* @__PURE__ */ o(
|
|
2915
|
+
return i ? (typeof i == "string" && (i = { children: i }), /* @__PURE__ */ o(si, { children: [/* @__PURE__ */ a(ci, {
|
|
2848
2916
|
asChild: !0,
|
|
2849
2917
|
children: f
|
|
2850
|
-
}), /* @__PURE__ */ a(
|
|
2918
|
+
}), /* @__PURE__ */ a(li, {
|
|
2851
2919
|
side: "right",
|
|
2852
2920
|
align: "center",
|
|
2853
2921
|
hidden: d !== "collapsed" || u,
|
|
2854
2922
|
...i
|
|
2855
2923
|
})] })) : f;
|
|
2856
2924
|
}
|
|
2857
|
-
function
|
|
2925
|
+
function Ni({ className: e, asChild: t = !1, showOnHover: n = !1, ...r }) {
|
|
2858
2926
|
return /* @__PURE__ */ a(t ? C : "button", {
|
|
2859
2927
|
"data-slot": "sidebar-menu-action",
|
|
2860
2928
|
"data-sidebar": "menu-action",
|
|
@@ -2862,7 +2930,7 @@ function ki({ className: e, asChild: t = !1, showOnHover: n = !1, ...r }) {
|
|
|
2862
2930
|
...r
|
|
2863
2931
|
});
|
|
2864
2932
|
}
|
|
2865
|
-
function
|
|
2933
|
+
function Pi({ className: e, ...t }) {
|
|
2866
2934
|
return /* @__PURE__ */ a("div", {
|
|
2867
2935
|
"data-slot": "sidebar-menu-badge",
|
|
2868
2936
|
"data-sidebar": "menu-badge",
|
|
@@ -2870,7 +2938,7 @@ function Ai({ className: e, ...t }) {
|
|
|
2870
2938
|
...t
|
|
2871
2939
|
});
|
|
2872
2940
|
}
|
|
2873
|
-
function
|
|
2941
|
+
function Fi({ className: e, showIcon: t = !1, ...n }) {
|
|
2874
2942
|
let [r] = y.useState(() => `${Math.floor(Math.random() * 40) + 50}%`);
|
|
2875
2943
|
return /* @__PURE__ */ o("div", {
|
|
2876
2944
|
"data-slot": "sidebar-menu-skeleton",
|
|
@@ -2887,7 +2955,7 @@ function ji({ className: e, showIcon: t = !1, ...n }) {
|
|
|
2887
2955
|
})]
|
|
2888
2956
|
});
|
|
2889
2957
|
}
|
|
2890
|
-
function
|
|
2958
|
+
function Ii({ className: e, ...t }) {
|
|
2891
2959
|
return /* @__PURE__ */ a("ul", {
|
|
2892
2960
|
"data-slot": "sidebar-menu-sub",
|
|
2893
2961
|
"data-sidebar": "menu-sub",
|
|
@@ -2895,7 +2963,7 @@ function Mi({ className: e, ...t }) {
|
|
|
2895
2963
|
...t
|
|
2896
2964
|
});
|
|
2897
2965
|
}
|
|
2898
|
-
function
|
|
2966
|
+
function Li({ className: e, ...t }) {
|
|
2899
2967
|
return /* @__PURE__ */ a("li", {
|
|
2900
2968
|
"data-slot": "sidebar-menu-sub-item",
|
|
2901
2969
|
"data-sidebar": "menu-sub-item",
|
|
@@ -2903,7 +2971,7 @@ function Ni({ className: e, ...t }) {
|
|
|
2903
2971
|
...t
|
|
2904
2972
|
});
|
|
2905
2973
|
}
|
|
2906
|
-
function
|
|
2974
|
+
function Ri({ asChild: e = !1, size: t = "md", isActive: n = !1, className: r, ...i }) {
|
|
2907
2975
|
return /* @__PURE__ */ a(e ? C : "a", {
|
|
2908
2976
|
"data-slot": "sidebar-menu-sub-button",
|
|
2909
2977
|
"data-sidebar": "menu-sub-button",
|
|
@@ -2915,7 +2983,7 @@ function Pi({ asChild: e = !1, size: t = "md", isActive: n = !1, className: r, .
|
|
|
2915
2983
|
}
|
|
2916
2984
|
//#endregion
|
|
2917
2985
|
//#region src/components/custom/table/crudTablePagination.tsx
|
|
2918
|
-
function
|
|
2986
|
+
function zi({ pageSize: e, totalNumber: t, currentPage: n, onPageChanged: r }) {
|
|
2919
2987
|
let i = Math.ceil(t / e);
|
|
2920
2988
|
return /* @__PURE__ */ o("div", {
|
|
2921
2989
|
className: "p-4 border-t bg-muted flex items-center justify-between text-sm text-muted-foreground",
|
|
@@ -2931,25 +2999,25 @@ function Fi({ pageSize: e, totalNumber: t, currentPage: n, onPageChanged: r }) {
|
|
|
2931
2999
|
t,
|
|
2932
3000
|
" "
|
|
2933
3001
|
]
|
|
2934
|
-
}), /* @__PURE__ */ a(
|
|
3002
|
+
}), /* @__PURE__ */ a(Dr, {
|
|
2935
3003
|
dir: "rtl",
|
|
2936
3004
|
className: "justify-end w-auto mx-0",
|
|
2937
|
-
children: /* @__PURE__ */ o(
|
|
2938
|
-
/* @__PURE__ */ a(
|
|
3005
|
+
children: /* @__PURE__ */ o(Or, { children: [
|
|
3006
|
+
/* @__PURE__ */ a(kr, { children: /* @__PURE__ */ a(jr, {
|
|
2939
3007
|
onClick: () => {
|
|
2940
3008
|
n > 1 && r?.(n - 1);
|
|
2941
3009
|
},
|
|
2942
3010
|
text: "السابق"
|
|
2943
3011
|
}) }),
|
|
2944
|
-
/* @__PURE__ */ o(
|
|
3012
|
+
/* @__PURE__ */ o(Pr, {
|
|
2945
3013
|
dir: "rtl",
|
|
2946
|
-
children: [/* @__PURE__ */ a(
|
|
3014
|
+
children: [/* @__PURE__ */ a(Ir, {
|
|
2947
3015
|
asChild: !0,
|
|
2948
3016
|
children: /* @__PURE__ */ a(W, {
|
|
2949
3017
|
className: "w-full h-5 justify-start gap-2 text-base",
|
|
2950
3018
|
children: /* @__PURE__ */ a("span", { children: n })
|
|
2951
3019
|
})
|
|
2952
|
-
}), /* @__PURE__ */ a(
|
|
3020
|
+
}), /* @__PURE__ */ a(Lr, {
|
|
2953
3021
|
align: "end",
|
|
2954
3022
|
children: Array.from({ length: Math.ceil(t / e) }, (e, t) => /* @__PURE__ */ a(B, {
|
|
2955
3023
|
onClick: () => r?.(t + 1),
|
|
@@ -2957,7 +3025,7 @@ function Fi({ pageSize: e, totalNumber: t, currentPage: n, onPageChanged: r }) {
|
|
|
2957
3025
|
}, t + 1))
|
|
2958
3026
|
})]
|
|
2959
3027
|
}),
|
|
2960
|
-
/* @__PURE__ */ a(
|
|
3028
|
+
/* @__PURE__ */ a(kr, { children: /* @__PURE__ */ a(Mr, {
|
|
2961
3029
|
onClick: () => {
|
|
2962
3030
|
n < i && r?.(n + 1);
|
|
2963
3031
|
},
|
|
@@ -2969,21 +3037,21 @@ function Fi({ pageSize: e, totalNumber: t, currentPage: n, onPageChanged: r }) {
|
|
|
2969
3037
|
}
|
|
2970
3038
|
//#endregion
|
|
2971
3039
|
//#region src/components/custom/table/crudTableRowActionsMenu.tsx
|
|
2972
|
-
function
|
|
2973
|
-
return /* @__PURE__ */ o(i, { children: [n === "dropdown" && /* @__PURE__ */ o(
|
|
3040
|
+
function Bi({ onEditClicked: e, onDeleteClicked: t, type: n, permissions: r }) {
|
|
3041
|
+
return /* @__PURE__ */ o(i, { children: [n === "dropdown" && /* @__PURE__ */ o(Pr, {
|
|
2974
3042
|
dir: "rtl",
|
|
2975
|
-
children: [/* @__PURE__ */ a(
|
|
3043
|
+
children: [/* @__PURE__ */ a(Ir, {
|
|
2976
3044
|
asChild: !0,
|
|
2977
3045
|
children: /* @__PURE__ */ a(F, {
|
|
2978
3046
|
variant: "ghost",
|
|
2979
3047
|
className: "h-8 w-8 p-0",
|
|
2980
3048
|
children: /* @__PURE__ */ a(le, { className: "h-4 w-4" })
|
|
2981
3049
|
})
|
|
2982
|
-
}), /* @__PURE__ */ o(
|
|
3050
|
+
}), /* @__PURE__ */ o(Lr, {
|
|
2983
3051
|
align: "start",
|
|
2984
3052
|
children: [
|
|
2985
|
-
/* @__PURE__ */ a(
|
|
2986
|
-
/* @__PURE__ */ a(
|
|
3053
|
+
/* @__PURE__ */ a(Hr, { children: "الإجراءات" }),
|
|
3054
|
+
/* @__PURE__ */ a(Ur, {}),
|
|
2987
3055
|
r.updatePermission && /* @__PURE__ */ a(B, {
|
|
2988
3056
|
onSelect: e,
|
|
2989
3057
|
children: "تعديل"
|
|
@@ -2995,14 +3063,14 @@ function Ii({ onEditClicked: e, onDeleteClicked: t, type: n, permissions: r }) {
|
|
|
2995
3063
|
})
|
|
2996
3064
|
]
|
|
2997
3065
|
})]
|
|
2998
|
-
}), n === "context" && /* @__PURE__ */ a(
|
|
2999
|
-
/* @__PURE__ */ a(
|
|
3000
|
-
/* @__PURE__ */ a(
|
|
3001
|
-
r.updatePermission && /* @__PURE__ */ a(
|
|
3066
|
+
}), n === "context" && /* @__PURE__ */ a(mr, { children: /* @__PURE__ */ o(ur, { children: [
|
|
3067
|
+
/* @__PURE__ */ a(br, { children: "الإجراءات" }),
|
|
3068
|
+
/* @__PURE__ */ a(xr, {}),
|
|
3069
|
+
r.updatePermission && /* @__PURE__ */ a(hr, {
|
|
3002
3070
|
onSelect: e,
|
|
3003
3071
|
children: "تعديل"
|
|
3004
3072
|
}),
|
|
3005
|
-
r.deletePermission && /* @__PURE__ */ a(
|
|
3073
|
+
r.deletePermission && /* @__PURE__ */ a(hr, {
|
|
3006
3074
|
className: "text-destructive",
|
|
3007
3075
|
onSelect: t,
|
|
3008
3076
|
children: "حذف"
|
|
@@ -3011,38 +3079,38 @@ function Ii({ onEditClicked: e, onDeleteClicked: t, type: n, permissions: r }) {
|
|
|
3011
3079
|
}
|
|
3012
3080
|
//#endregion
|
|
3013
3081
|
//#region src/components/custom/pages/crudPage.tsx
|
|
3014
|
-
function
|
|
3082
|
+
function Vi({ permissions: e, useSlice: t, entityName: n, title: r, addNewItemTitle: i, cards: s, columnsToFilter: c, actions: l, service: u, entityState: d, tableHeadRows: f, tableRowMapper: p, ChangeDialog: m, children: h }) {
|
|
3015
3083
|
let g = We(), { selectedRow: _, isChangeDialogOpen: v, isDeleteDialogOpen: ee } = t();
|
|
3016
3084
|
return je(() => {
|
|
3017
3085
|
g(l.filter(void 0));
|
|
3018
3086
|
}, [g, l.filter]), /* @__PURE__ */ o("div", {
|
|
3019
3087
|
className: "px-5 py-3",
|
|
3020
3088
|
children: [
|
|
3021
|
-
/* @__PURE__ */ a(
|
|
3089
|
+
/* @__PURE__ */ a(Tr, {
|
|
3022
3090
|
title: r,
|
|
3023
3091
|
buttonTitle: i,
|
|
3024
3092
|
isButtonVisible: e.addPermission,
|
|
3025
3093
|
createComp: m
|
|
3026
3094
|
}),
|
|
3027
|
-
/* @__PURE__ */ a(
|
|
3028
|
-
/* @__PURE__ */ a(
|
|
3095
|
+
/* @__PURE__ */ a(wr, { cards: s }),
|
|
3096
|
+
/* @__PURE__ */ a(Vn, {
|
|
3029
3097
|
columnsNames: c,
|
|
3030
3098
|
onSearch: (e) => g(l.filter(e))
|
|
3031
3099
|
}),
|
|
3032
3100
|
/* @__PURE__ */ o("div", {
|
|
3033
3101
|
className: "rounded-b-xl border shadow-sm overflow-hidden",
|
|
3034
3102
|
children: [
|
|
3035
|
-
/* @__PURE__ */ o(
|
|
3103
|
+
/* @__PURE__ */ o(sr, {
|
|
3036
3104
|
state: d,
|
|
3037
|
-
children: [/* @__PURE__ */ a(
|
|
3105
|
+
children: [/* @__PURE__ */ a(Er, { tableHeadRows: f }), /* @__PURE__ */ a(Wn, { children: d.entities?.data?.map((t, n) => /* @__PURE__ */ a(Cr, {
|
|
3038
3106
|
tableRows: p(t),
|
|
3039
|
-
dropdownMenu: /* @__PURE__ */ a(
|
|
3107
|
+
dropdownMenu: /* @__PURE__ */ a(Bi, {
|
|
3040
3108
|
permissions: e,
|
|
3041
3109
|
type: "dropdown",
|
|
3042
3110
|
onEditClicked: () => g(l.openChangeDialog(t)),
|
|
3043
3111
|
onDeleteClicked: () => g(l.openDeleteDialog(t))
|
|
3044
3112
|
}),
|
|
3045
|
-
contextMenuContent: /* @__PURE__ */ a(
|
|
3113
|
+
contextMenuContent: /* @__PURE__ */ a(Bi, {
|
|
3046
3114
|
permissions: e,
|
|
3047
3115
|
type: "context",
|
|
3048
3116
|
onEditClicked: () => g(l.openChangeDialog(t)),
|
|
@@ -3050,7 +3118,7 @@ function Li({ permissions: e, useSlice: t, entityName: n, title: r, addNewItemTi
|
|
|
3050
3118
|
})
|
|
3051
3119
|
}, n)) })]
|
|
3052
3120
|
}),
|
|
3053
|
-
/* @__PURE__ */ a(
|
|
3121
|
+
/* @__PURE__ */ a(zi, {
|
|
3054
3122
|
pageSize: d.rowsPerPage,
|
|
3055
3123
|
totalNumber: d.entities?.count ?? 0,
|
|
3056
3124
|
currentPage: d.currentPage || 1,
|
|
@@ -3085,75 +3153,75 @@ function Li({ permissions: e, useSlice: t, entityName: n, title: r, addNewItemTi
|
|
|
3085
3153
|
}
|
|
3086
3154
|
//#endregion
|
|
3087
3155
|
//#region src/components/pure/alert-dialog.tsx
|
|
3088
|
-
function
|
|
3156
|
+
function Hi({ ...e }) {
|
|
3089
3157
|
return /* @__PURE__ */ a(k.Root, {
|
|
3090
3158
|
"data-slot": "alert-dialog",
|
|
3091
3159
|
...e
|
|
3092
3160
|
});
|
|
3093
3161
|
}
|
|
3094
|
-
function
|
|
3162
|
+
function Ui({ ...e }) {
|
|
3095
3163
|
return /* @__PURE__ */ a(k.Trigger, {
|
|
3096
3164
|
"data-slot": "alert-dialog-trigger",
|
|
3097
3165
|
...e
|
|
3098
3166
|
});
|
|
3099
3167
|
}
|
|
3100
|
-
function
|
|
3168
|
+
function Wi({ ...e }) {
|
|
3101
3169
|
return /* @__PURE__ */ a(k.Portal, {
|
|
3102
3170
|
"data-slot": "alert-dialog-portal",
|
|
3103
3171
|
...e
|
|
3104
3172
|
});
|
|
3105
3173
|
}
|
|
3106
|
-
function
|
|
3174
|
+
function Gi({ className: e, ...t }) {
|
|
3107
3175
|
return /* @__PURE__ */ a(k.Overlay, {
|
|
3108
3176
|
"data-slot": "alert-dialog-overlay",
|
|
3109
3177
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50", e),
|
|
3110
3178
|
...t
|
|
3111
3179
|
});
|
|
3112
3180
|
}
|
|
3113
|
-
function
|
|
3114
|
-
return /* @__PURE__ */ o(
|
|
3181
|
+
function Ki({ className: e, size: t = "default", ...n }) {
|
|
3182
|
+
return /* @__PURE__ */ o(Wi, { children: [/* @__PURE__ */ a(Gi, {}), /* @__PURE__ */ a(k.Content, {
|
|
3115
3183
|
"data-slot": "alert-dialog-content",
|
|
3116
3184
|
"data-size": t,
|
|
3117
3185
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 bg-background ring-foreground/10 gap-4 rounded-xl p-4 ring-1 duration-100 data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm group/alert-dialog-content fixed top-1/2 start-1/2 z-50 grid w-full -translate-x-1/2 rtl:translate-x-1/2 -translate-y-1/2 outline-none", e),
|
|
3118
3186
|
...n
|
|
3119
3187
|
})] });
|
|
3120
3188
|
}
|
|
3121
|
-
function
|
|
3189
|
+
function qi({ className: e, ...t }) {
|
|
3122
3190
|
return /* @__PURE__ */ a("div", {
|
|
3123
3191
|
"data-slot": "alert-dialog-header",
|
|
3124
3192
|
className: P("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-start sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", e),
|
|
3125
3193
|
...t
|
|
3126
3194
|
});
|
|
3127
3195
|
}
|
|
3128
|
-
function
|
|
3196
|
+
function Ji({ className: e, ...t }) {
|
|
3129
3197
|
return /* @__PURE__ */ a("div", {
|
|
3130
3198
|
"data-slot": "alert-dialog-footer",
|
|
3131
3199
|
className: P("bg-muted/50 -mx-4 -mb-4 rounded-b-xl border-t p-4 flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", e),
|
|
3132
3200
|
...t
|
|
3133
3201
|
});
|
|
3134
3202
|
}
|
|
3135
|
-
function
|
|
3203
|
+
function Yi({ className: e, ...t }) {
|
|
3136
3204
|
return /* @__PURE__ */ a("div", {
|
|
3137
3205
|
"data-slot": "alert-dialog-media",
|
|
3138
3206
|
className: P("bg-muted mb-2 inline-flex size-10 items-center justify-center rounded-md sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6", e),
|
|
3139
3207
|
...t
|
|
3140
3208
|
});
|
|
3141
3209
|
}
|
|
3142
|
-
function
|
|
3210
|
+
function Xi({ className: e, ...t }) {
|
|
3143
3211
|
return /* @__PURE__ */ a(k.Title, {
|
|
3144
3212
|
"data-slot": "alert-dialog-title",
|
|
3145
3213
|
className: P("text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", e),
|
|
3146
3214
|
...t
|
|
3147
3215
|
});
|
|
3148
3216
|
}
|
|
3149
|
-
function
|
|
3217
|
+
function Zi({ className: e, ...t }) {
|
|
3150
3218
|
return /* @__PURE__ */ a(k.Description, {
|
|
3151
3219
|
"data-slot": "alert-dialog-description",
|
|
3152
3220
|
className: P("text-muted-foreground *:[a]:hover:text-foreground text-sm text-balance md:text-pretty *:[a]:underline *:[a]:underline-offset-3", e),
|
|
3153
3221
|
...t
|
|
3154
3222
|
});
|
|
3155
3223
|
}
|
|
3156
|
-
function
|
|
3224
|
+
function Qi({ className: e, variant: t = "default", size: n = "default", ...r }) {
|
|
3157
3225
|
return /* @__PURE__ */ a(F, {
|
|
3158
3226
|
variant: t,
|
|
3159
3227
|
size: n,
|
|
@@ -3165,7 +3233,7 @@ function Ji({ className: e, variant: t = "default", size: n = "default", ...r })
|
|
|
3165
3233
|
})
|
|
3166
3234
|
});
|
|
3167
3235
|
}
|
|
3168
|
-
function
|
|
3236
|
+
function $i({ className: e, variant: t = "outline", size: n = "default", ...r }) {
|
|
3169
3237
|
return /* @__PURE__ */ a(F, {
|
|
3170
3238
|
variant: t,
|
|
3171
3239
|
size: n,
|
|
@@ -3179,36 +3247,36 @@ function Yi({ className: e, variant: t = "outline", size: n = "default", ...r })
|
|
|
3179
3247
|
}
|
|
3180
3248
|
//#endregion
|
|
3181
3249
|
//#region src/components/pure/alert.tsx
|
|
3182
|
-
var
|
|
3250
|
+
var ea = S("group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-start text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pe-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4", {
|
|
3183
3251
|
variants: { variant: {
|
|
3184
3252
|
default: "bg-card text-card-foreground",
|
|
3185
3253
|
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
|
|
3186
3254
|
} },
|
|
3187
3255
|
defaultVariants: { variant: "default" }
|
|
3188
3256
|
});
|
|
3189
|
-
function
|
|
3257
|
+
function ta({ className: e, variant: t, ...n }) {
|
|
3190
3258
|
return /* @__PURE__ */ a("div", {
|
|
3191
3259
|
"data-slot": "alert",
|
|
3192
3260
|
role: "alert",
|
|
3193
|
-
className: P(
|
|
3261
|
+
className: P(ea({ variant: t }), e),
|
|
3194
3262
|
...n
|
|
3195
3263
|
});
|
|
3196
3264
|
}
|
|
3197
|
-
function
|
|
3265
|
+
function na({ className: e, ...t }) {
|
|
3198
3266
|
return /* @__PURE__ */ a("div", {
|
|
3199
3267
|
"data-slot": "alert-title",
|
|
3200
3268
|
className: P("font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground", e),
|
|
3201
3269
|
...t
|
|
3202
3270
|
});
|
|
3203
3271
|
}
|
|
3204
|
-
function
|
|
3272
|
+
function ra({ className: e, ...t }) {
|
|
3205
3273
|
return /* @__PURE__ */ a("div", {
|
|
3206
3274
|
"data-slot": "alert-description",
|
|
3207
3275
|
className: P("text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4", e),
|
|
3208
3276
|
...t
|
|
3209
3277
|
});
|
|
3210
3278
|
}
|
|
3211
|
-
function
|
|
3279
|
+
function ia({ className: e, ...t }) {
|
|
3212
3280
|
return /* @__PURE__ */ a("div", {
|
|
3213
3281
|
"data-slot": "alert-action",
|
|
3214
3282
|
className: P("absolute top-2 end-2", e),
|
|
@@ -3217,7 +3285,7 @@ function ea({ className: e, ...t }) {
|
|
|
3217
3285
|
}
|
|
3218
3286
|
//#endregion
|
|
3219
3287
|
//#region src/components/pure/avatar.tsx
|
|
3220
|
-
function
|
|
3288
|
+
function aa({ className: e, size: t = "default", ...n }) {
|
|
3221
3289
|
return /* @__PURE__ */ a(Ge.Root, {
|
|
3222
3290
|
"data-slot": "avatar",
|
|
3223
3291
|
"data-size": t,
|
|
@@ -3225,35 +3293,35 @@ function ta({ className: e, size: t = "default", ...n }) {
|
|
|
3225
3293
|
...n
|
|
3226
3294
|
});
|
|
3227
3295
|
}
|
|
3228
|
-
function
|
|
3296
|
+
function oa({ className: e, ...t }) {
|
|
3229
3297
|
return console.log(t), /* @__PURE__ */ a(Ge.Image, {
|
|
3230
3298
|
"data-slot": "avatar-image",
|
|
3231
3299
|
className: P("rounded-full aspect-square size-full object-cover", e),
|
|
3232
3300
|
...t
|
|
3233
3301
|
});
|
|
3234
3302
|
}
|
|
3235
|
-
function
|
|
3303
|
+
function sa({ className: e, ...t }) {
|
|
3236
3304
|
return /* @__PURE__ */ a(Ge.Fallback, {
|
|
3237
3305
|
"data-slot": "avatar-fallback",
|
|
3238
3306
|
className: P("bg-muted text-muted-foreground rounded-full flex size-full items-center justify-center text-sm group-data-[size=sm]/avatar:text-xs", e),
|
|
3239
3307
|
...t
|
|
3240
3308
|
});
|
|
3241
3309
|
}
|
|
3242
|
-
function
|
|
3310
|
+
function ca({ className: e, ...t }) {
|
|
3243
3311
|
return /* @__PURE__ */ a("span", {
|
|
3244
3312
|
"data-slot": "avatar-badge",
|
|
3245
3313
|
className: P("bg-primary text-primary-foreground ring-background absolute end-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-blend-color ring-2 select-none", "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden", "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2", "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2", e),
|
|
3246
3314
|
...t
|
|
3247
3315
|
});
|
|
3248
3316
|
}
|
|
3249
|
-
function
|
|
3317
|
+
function la({ className: e, ...t }) {
|
|
3250
3318
|
return /* @__PURE__ */ a("div", {
|
|
3251
3319
|
"data-slot": "avatar-group",
|
|
3252
3320
|
className: P("*:data-[slot=avatar]:ring-background group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2", e),
|
|
3253
3321
|
...t
|
|
3254
3322
|
});
|
|
3255
3323
|
}
|
|
3256
|
-
function
|
|
3324
|
+
function ua({ className: e, ...t }) {
|
|
3257
3325
|
return /* @__PURE__ */ a("div", {
|
|
3258
3326
|
"data-slot": "avatar-group-count",
|
|
3259
3327
|
className: P("bg-muted text-muted-foreground size-8 rounded-full text-sm group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3 ring-background relative flex shrink-0 items-center justify-center ring-2", e),
|
|
@@ -3262,7 +3330,7 @@ function oa({ className: e, ...t }) {
|
|
|
3262
3330
|
}
|
|
3263
3331
|
//#endregion
|
|
3264
3332
|
//#region src/components/pure/badge.tsx
|
|
3265
|
-
var
|
|
3333
|
+
var da = S("h-5 gap-1 rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium transition-all has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 [&>svg]:size-3! inline-flex items-center justify-center w-fit whitespace-nowrap shrink-0 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive overflow-hidden group/badge", {
|
|
3266
3334
|
variants: { variant: {
|
|
3267
3335
|
default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
|
|
3268
3336
|
secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
|
|
@@ -3273,17 +3341,17 @@ var sa = S("h-5 gap-1 rounded-4xl border border-transparent px-2 py-0.5 text-xs
|
|
|
3273
3341
|
} },
|
|
3274
3342
|
defaultVariants: { variant: "default" }
|
|
3275
3343
|
});
|
|
3276
|
-
function
|
|
3344
|
+
function fa({ className: e, variant: t = "default", asChild: n = !1, ...r }) {
|
|
3277
3345
|
return /* @__PURE__ */ a(n ? C : "span", {
|
|
3278
3346
|
"data-slot": "badge",
|
|
3279
3347
|
"data-variant": t,
|
|
3280
|
-
className: P(
|
|
3348
|
+
className: P(da({ variant: t }), e),
|
|
3281
3349
|
...r
|
|
3282
3350
|
});
|
|
3283
3351
|
}
|
|
3284
3352
|
//#endregion
|
|
3285
3353
|
//#region src/components/pure/breadcrumb.tsx
|
|
3286
|
-
function
|
|
3354
|
+
function pa({ className: e, ...t }) {
|
|
3287
3355
|
return /* @__PURE__ */ a("nav", {
|
|
3288
3356
|
"aria-label": "breadcrumb",
|
|
3289
3357
|
"data-slot": "breadcrumb",
|
|
@@ -3291,28 +3359,28 @@ function la({ className: e, ...t }) {
|
|
|
3291
3359
|
...t
|
|
3292
3360
|
});
|
|
3293
3361
|
}
|
|
3294
|
-
function
|
|
3362
|
+
function ma({ className: e, ...t }) {
|
|
3295
3363
|
return /* @__PURE__ */ a("ol", {
|
|
3296
3364
|
"data-slot": "breadcrumb-list",
|
|
3297
3365
|
className: P("text-muted-foreground gap-1.5 text-sm flex flex-wrap items-center wrap-break-word", e),
|
|
3298
3366
|
...t
|
|
3299
3367
|
});
|
|
3300
3368
|
}
|
|
3301
|
-
function
|
|
3369
|
+
function ha({ className: e, ...t }) {
|
|
3302
3370
|
return /* @__PURE__ */ a("li", {
|
|
3303
3371
|
"data-slot": "breadcrumb-item",
|
|
3304
3372
|
className: P("gap-1 inline-flex items-center", e),
|
|
3305
3373
|
...t
|
|
3306
3374
|
});
|
|
3307
3375
|
}
|
|
3308
|
-
function
|
|
3376
|
+
function ga({ asChild: e, className: t, ...n }) {
|
|
3309
3377
|
return /* @__PURE__ */ a(e ? C : "a", {
|
|
3310
3378
|
"data-slot": "breadcrumb-link",
|
|
3311
3379
|
className: P("hover:text-foreground transition-colors", t),
|
|
3312
3380
|
...n
|
|
3313
3381
|
});
|
|
3314
3382
|
}
|
|
3315
|
-
function
|
|
3383
|
+
function _a({ className: e, ...t }) {
|
|
3316
3384
|
return /* @__PURE__ */ a("span", {
|
|
3317
3385
|
"data-slot": "breadcrumb-page",
|
|
3318
3386
|
role: "link",
|
|
@@ -3322,7 +3390,7 @@ function pa({ className: e, ...t }) {
|
|
|
3322
3390
|
...t
|
|
3323
3391
|
});
|
|
3324
3392
|
}
|
|
3325
|
-
function
|
|
3393
|
+
function va({ children: e, className: t, ...n }) {
|
|
3326
3394
|
return /* @__PURE__ */ a("li", {
|
|
3327
3395
|
"data-slot": "breadcrumb-separator",
|
|
3328
3396
|
role: "presentation",
|
|
@@ -3332,7 +3400,7 @@ function ma({ children: e, className: t, ...n }) {
|
|
|
3332
3400
|
children: e ?? /* @__PURE__ */ a(p, { className: "rtl:rotate-180" })
|
|
3333
3401
|
});
|
|
3334
3402
|
}
|
|
3335
|
-
function
|
|
3403
|
+
function ya({ className: e, ...t }) {
|
|
3336
3404
|
return /* @__PURE__ */ o("span", {
|
|
3337
3405
|
"data-slot": "breadcrumb-ellipsis",
|
|
3338
3406
|
role: "presentation",
|
|
@@ -3347,34 +3415,34 @@ function ha({ className: e, ...t }) {
|
|
|
3347
3415
|
}
|
|
3348
3416
|
//#endregion
|
|
3349
3417
|
//#region src/components/pure/chart.tsx
|
|
3350
|
-
var
|
|
3418
|
+
var ba = {
|
|
3351
3419
|
light: "",
|
|
3352
3420
|
dark: ".dark"
|
|
3353
|
-
},
|
|
3354
|
-
function
|
|
3355
|
-
let e = y.useContext(
|
|
3421
|
+
}, xa = y.createContext(null);
|
|
3422
|
+
function Sa() {
|
|
3423
|
+
let e = y.useContext(xa);
|
|
3356
3424
|
if (!e) throw Error("useChart must be used within a <ChartContainer />");
|
|
3357
3425
|
return e;
|
|
3358
3426
|
}
|
|
3359
|
-
function
|
|
3427
|
+
function Ca({ id: e, className: t, children: n, config: r, ...i }) {
|
|
3360
3428
|
let s = y.useId(), c = `chart-${e || s.replace(/:/g, "")}`;
|
|
3361
|
-
return /* @__PURE__ */ a(
|
|
3429
|
+
return /* @__PURE__ */ a(xa.Provider, {
|
|
3362
3430
|
value: { config: r },
|
|
3363
3431
|
children: /* @__PURE__ */ o("div", {
|
|
3364
3432
|
"data-slot": "chart",
|
|
3365
3433
|
"data-chart": c,
|
|
3366
3434
|
className: P("[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border[&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border[&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border flex aspect-video justify-center text-xs [&_.recharts-dot[stroke='#fff']]:stroke-transparent[&_.recharts-layer]:outline-hidden [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden", t),
|
|
3367
3435
|
...i,
|
|
3368
|
-
children: [/* @__PURE__ */ a(
|
|
3436
|
+
children: [/* @__PURE__ */ a(wa, {
|
|
3369
3437
|
id: c,
|
|
3370
3438
|
config: r
|
|
3371
3439
|
}), /* @__PURE__ */ a(Ke.ResponsiveContainer, { children: n })]
|
|
3372
3440
|
})
|
|
3373
3441
|
});
|
|
3374
3442
|
}
|
|
3375
|
-
var
|
|
3443
|
+
var wa = ({ id: e, config: t }) => {
|
|
3376
3444
|
let n = Object.entries(t).filter(([, e]) => e.theme || e.color);
|
|
3377
|
-
return n.length ? /* @__PURE__ */ a("style", { dangerouslySetInnerHTML: { __html: Object.entries(
|
|
3445
|
+
return n.length ? /* @__PURE__ */ a("style", { dangerouslySetInnerHTML: { __html: Object.entries(ba).map(([t, r]) => `
|
|
3378
3446
|
${r} [data-chart=${e}] {
|
|
3379
3447
|
${n.map(([e, n]) => {
|
|
3380
3448
|
let r = n.theme?.[t] || n.color;
|
|
@@ -3382,11 +3450,11 @@ ${n.map(([e, n]) => {
|
|
|
3382
3450
|
}).join("\n")}
|
|
3383
3451
|
}
|
|
3384
3452
|
`).join("\n") } }) : null;
|
|
3385
|
-
},
|
|
3386
|
-
function
|
|
3387
|
-
let { config: g } =
|
|
3453
|
+
}, Ta = Ke.Tooltip;
|
|
3454
|
+
function Ea({ active: e, payload: t, className: n, indicator: r = "dot", hideLabel: s = !1, hideIndicator: c = !1, label: l, labelFormatter: u, labelClassName: d, formatter: f, color: p, nameKey: m, labelKey: h }) {
|
|
3455
|
+
let { config: g } = Sa(), _ = y.useMemo(() => {
|
|
3388
3456
|
if (s || !t?.length) return null;
|
|
3389
|
-
let [e] = t, n =
|
|
3457
|
+
let [e] = t, n = ka(g, e, `${h || e?.dataKey || e?.name || "value"}`), r = !h && typeof l == "string" ? g[l]?.label || l : n?.label;
|
|
3390
3458
|
return u ? /* @__PURE__ */ a("div", {
|
|
3391
3459
|
className: P("font-medium", d),
|
|
3392
3460
|
children: u(r, t)
|
|
@@ -3410,7 +3478,7 @@ function Sa({ active: e, payload: t, className: n, indicator: r = "dot", hideLab
|
|
|
3410
3478
|
children: [v ? null : _, /* @__PURE__ */ a("div", {
|
|
3411
3479
|
className: "grid gap-1.5",
|
|
3412
3480
|
children: t.filter((e) => e.type !== "none").map((e, t) => {
|
|
3413
|
-
let n =
|
|
3481
|
+
let n = ka(g, e, `${m || e.name || e.dataKey || "value"}`), s = p || e.payload.fill || e.color;
|
|
3414
3482
|
return /* @__PURE__ */ a("div", {
|
|
3415
3483
|
className: P("[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5", r === "dot" && "items-center"),
|
|
3416
3484
|
children: f && e?.value !== void 0 && e.name ? f(e.value, e.name, e, t, e.payload) : /* @__PURE__ */ o(i, { children: [n?.icon ? /* @__PURE__ */ a(n.icon, {}) : !c && /* @__PURE__ */ a("div", {
|
|
@@ -3442,13 +3510,13 @@ function Sa({ active: e, payload: t, className: n, indicator: r = "dot", hideLab
|
|
|
3442
3510
|
})]
|
|
3443
3511
|
});
|
|
3444
3512
|
}
|
|
3445
|
-
var
|
|
3446
|
-
function
|
|
3447
|
-
let { config: s } =
|
|
3513
|
+
var Da = Ke.Legend;
|
|
3514
|
+
function Oa({ className: e, hideIcon: t = !1, payload: n, verticalAlign: r = "bottom", nameKey: i }) {
|
|
3515
|
+
let { config: s } = Sa();
|
|
3448
3516
|
return n?.length ? /* @__PURE__ */ a("div", {
|
|
3449
3517
|
className: P("flex items-center justify-center gap-4", r === "top" ? "pb-3" : "pt-3", e),
|
|
3450
3518
|
children: n.filter((e) => e.type !== "none").map((e) => {
|
|
3451
|
-
let n =
|
|
3519
|
+
let n = ka(s, e, `${i || e.dataKey || "value"}`);
|
|
3452
3520
|
return /* @__PURE__ */ o("div", {
|
|
3453
3521
|
className: P("[&>svg]:text-muted-foreground flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3"),
|
|
3454
3522
|
children: [n?.icon && !t ? /* @__PURE__ */ a(n.icon, {}) : /* @__PURE__ */ a("div", {
|
|
@@ -3459,14 +3527,14 @@ function wa({ className: e, hideIcon: t = !1, payload: n, verticalAlign: r = "bo
|
|
|
3459
3527
|
})
|
|
3460
3528
|
}) : null;
|
|
3461
3529
|
}
|
|
3462
|
-
function
|
|
3530
|
+
function ka(e, t, n) {
|
|
3463
3531
|
if (typeof t != "object" || !t) return;
|
|
3464
3532
|
let r = "payload" in t && typeof t.payload == "object" && t.payload !== null ? t.payload : void 0, i = n;
|
|
3465
3533
|
return n in t && typeof t[n] == "string" ? i = t[n] : r && n in r && typeof r[n] == "string" && (i = r[n]), i in e ? e[i] : e[n];
|
|
3466
3534
|
}
|
|
3467
3535
|
//#endregion
|
|
3468
3536
|
//#region src/components/pure/checkbox.tsx
|
|
3469
|
-
function
|
|
3537
|
+
function Aa({ className: e, ...t }) {
|
|
3470
3538
|
return /* @__PURE__ */ a(qe.Root, {
|
|
3471
3539
|
"data-slot": "checkbox",
|
|
3472
3540
|
className: P("border-input dark:bg-input/30 data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary data-checked:border-primary aria-invalid:aria-checked:border-primary aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 flex size-4 items-center justify-center rounded-[4px] border transition-colors group-has-disabled/field:opacity-50 focus-visible:ring-3 aria-invalid:ring-3 peer relative shrink-0 outline-none after:absolute after:-inset-x-3 after:-inset-y-2 disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
@@ -3480,7 +3548,7 @@ function Ea({ className: e, ...t }) {
|
|
|
3480
3548
|
}
|
|
3481
3549
|
//#endregion
|
|
3482
3550
|
//#region src/components/pure/input-group.tsx
|
|
3483
|
-
function
|
|
3551
|
+
function ja({ className: e, ...t }) {
|
|
3484
3552
|
return /* @__PURE__ */ a("div", {
|
|
3485
3553
|
"data-slot": "input-group",
|
|
3486
3554
|
role: "group",
|
|
@@ -3488,7 +3556,7 @@ function Da({ className: e, ...t }) {
|
|
|
3488
3556
|
...t
|
|
3489
3557
|
});
|
|
3490
3558
|
}
|
|
3491
|
-
var
|
|
3559
|
+
var Ma = S("text-muted-foreground h-auto gap-2 py-1.5 text-sm font-medium group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4 flex cursor-text items-center justify-center select-none", {
|
|
3492
3560
|
variants: { align: {
|
|
3493
3561
|
"inline-start": "ps-2 has-[>button]:ms-[-0.3rem] has-[>kbd]:ms-[-0.15rem] order-first",
|
|
3494
3562
|
"inline-end": "pe-2 has-[>button]:me-[-0.3rem] has-[>kbd]:me-[-0.15rem] order-last",
|
|
@@ -3497,19 +3565,19 @@ var Oa = S("text-muted-foreground h-auto gap-2 py-1.5 text-sm font-medium group-
|
|
|
3497
3565
|
} },
|
|
3498
3566
|
defaultVariants: { align: "inline-start" }
|
|
3499
3567
|
});
|
|
3500
|
-
function
|
|
3568
|
+
function Na({ className: e, align: t = "inline-start", ...n }) {
|
|
3501
3569
|
return /* @__PURE__ */ a("div", {
|
|
3502
3570
|
role: "group",
|
|
3503
3571
|
"data-slot": "input-group-addon",
|
|
3504
3572
|
"data-align": t,
|
|
3505
|
-
className: P(
|
|
3573
|
+
className: P(Ma({ align: t }), e),
|
|
3506
3574
|
onClick: (e) => {
|
|
3507
3575
|
e.target.closest("button") || e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
3508
3576
|
},
|
|
3509
3577
|
...n
|
|
3510
3578
|
});
|
|
3511
3579
|
}
|
|
3512
|
-
var
|
|
3580
|
+
var Pa = S("gap-2 text-sm shadow-none flex items-center", {
|
|
3513
3581
|
variants: { size: {
|
|
3514
3582
|
xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
3515
3583
|
sm: "",
|
|
@@ -3518,30 +3586,30 @@ var Aa = S("gap-2 text-sm shadow-none flex items-center", {
|
|
|
3518
3586
|
} },
|
|
3519
3587
|
defaultVariants: { size: "xs" }
|
|
3520
3588
|
});
|
|
3521
|
-
function
|
|
3589
|
+
function Fa({ className: e, type: t = "button", variant: n = "ghost", size: r = "xs", ...i }) {
|
|
3522
3590
|
return /* @__PURE__ */ a(F, {
|
|
3523
3591
|
type: t,
|
|
3524
3592
|
"data-size": r,
|
|
3525
3593
|
variant: n,
|
|
3526
|
-
className: P(
|
|
3594
|
+
className: P(Pa({ size: r }), e),
|
|
3527
3595
|
...i
|
|
3528
3596
|
});
|
|
3529
3597
|
}
|
|
3530
|
-
function
|
|
3598
|
+
function Ia({ className: e, ...t }) {
|
|
3531
3599
|
return /* @__PURE__ */ a("span", {
|
|
3532
3600
|
className: P("text-muted-foreground gap-2 text-sm [&_svg:not([class*='size-'])]:size-4 flex items-center [&_svg]:pointer-events-none", e),
|
|
3533
3601
|
...t
|
|
3534
3602
|
});
|
|
3535
3603
|
}
|
|
3536
|
-
function
|
|
3604
|
+
function La({ className: e, ...t }) {
|
|
3537
3605
|
return /* @__PURE__ */ a(z, {
|
|
3538
3606
|
"data-slot": "input-group-control",
|
|
3539
3607
|
className: P("rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent flex-1", e),
|
|
3540
3608
|
...t
|
|
3541
3609
|
});
|
|
3542
3610
|
}
|
|
3543
|
-
function
|
|
3544
|
-
return /* @__PURE__ */ a(
|
|
3611
|
+
function Ra({ className: e, ...t }) {
|
|
3612
|
+
return /* @__PURE__ */ a(Fn, {
|
|
3545
3613
|
"data-slot": "input-group-control",
|
|
3546
3614
|
className: P("rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent flex-1 resize-none", e),
|
|
3547
3615
|
...t
|
|
@@ -3549,14 +3617,14 @@ function Pa({ className: e, ...t }) {
|
|
|
3549
3617
|
}
|
|
3550
3618
|
//#endregion
|
|
3551
3619
|
//#region src/components/pure/combobox.tsx
|
|
3552
|
-
var
|
|
3553
|
-
function
|
|
3620
|
+
var za = A.Root;
|
|
3621
|
+
function Ba({ ...e }) {
|
|
3554
3622
|
return /* @__PURE__ */ a(A.Value, {
|
|
3555
3623
|
"data-slot": "combobox-value",
|
|
3556
3624
|
...e
|
|
3557
3625
|
});
|
|
3558
3626
|
}
|
|
3559
|
-
function
|
|
3627
|
+
function Va({ className: e, children: t, ...n }) {
|
|
3560
3628
|
return /* @__PURE__ */ o(A.Trigger, {
|
|
3561
3629
|
"data-slot": "combobox-trigger",
|
|
3562
3630
|
className: P("[&_svg:not([class*='size-'])]:size-4", e),
|
|
@@ -3564,10 +3632,10 @@ function La({ className: e, children: t, ...n }) {
|
|
|
3564
3632
|
children: [t, /* @__PURE__ */ a(l, { className: "text-muted-foreground size-4 pointer-events-none" })]
|
|
3565
3633
|
});
|
|
3566
3634
|
}
|
|
3567
|
-
function
|
|
3635
|
+
function Ha({ className: e, ...t }) {
|
|
3568
3636
|
return /* @__PURE__ */ a(A.Clear, {
|
|
3569
3637
|
"data-slot": "combobox-clear",
|
|
3570
|
-
render: /* @__PURE__ */ a(
|
|
3638
|
+
render: /* @__PURE__ */ a(Fa, {
|
|
3571
3639
|
variant: "ghost",
|
|
3572
3640
|
size: "icon-xs"
|
|
3573
3641
|
}),
|
|
@@ -3576,31 +3644,31 @@ function Ra({ className: e, ...t }) {
|
|
|
3576
3644
|
children: /* @__PURE__ */ a(Te, { className: "pointer-events-none" })
|
|
3577
3645
|
});
|
|
3578
3646
|
}
|
|
3579
|
-
function
|
|
3580
|
-
return /* @__PURE__ */ o(
|
|
3647
|
+
function Ua({ className: e, children: t, disabled: n = !1, showTrigger: r = !0, showClear: i = !1, ...s }) {
|
|
3648
|
+
return /* @__PURE__ */ o(ja, {
|
|
3581
3649
|
className: P("w-auto", e),
|
|
3582
3650
|
children: [
|
|
3583
3651
|
/* @__PURE__ */ a(A.Input, {
|
|
3584
|
-
render: /* @__PURE__ */ a(
|
|
3652
|
+
render: /* @__PURE__ */ a(La, { disabled: n }),
|
|
3585
3653
|
...s
|
|
3586
3654
|
}),
|
|
3587
|
-
/* @__PURE__ */ o(
|
|
3655
|
+
/* @__PURE__ */ o(Na, {
|
|
3588
3656
|
align: "inline-end",
|
|
3589
|
-
children: [r && /* @__PURE__ */ a(
|
|
3657
|
+
children: [r && /* @__PURE__ */ a(Fa, {
|
|
3590
3658
|
size: "icon-xs",
|
|
3591
3659
|
variant: "ghost",
|
|
3592
3660
|
asChild: !0,
|
|
3593
3661
|
"data-slot": "input-group-button",
|
|
3594
3662
|
className: "group-has-data-[slot=combobox-clear]/input-group:hidden data-pressed:bg-transparent",
|
|
3595
3663
|
disabled: n,
|
|
3596
|
-
children: /* @__PURE__ */ a(
|
|
3597
|
-
}), i && /* @__PURE__ */ a(
|
|
3664
|
+
children: /* @__PURE__ */ a(Va, {})
|
|
3665
|
+
}), i && /* @__PURE__ */ a(Ha, { disabled: n })]
|
|
3598
3666
|
}),
|
|
3599
3667
|
t
|
|
3600
3668
|
]
|
|
3601
3669
|
});
|
|
3602
3670
|
}
|
|
3603
|
-
function
|
|
3671
|
+
function Wa({ className: e, side: t = "bottom", sideOffset: n = 6, align: r = "start", alignOffset: i = 0, anchor: o, ...s }) {
|
|
3604
3672
|
return /* @__PURE__ */ a(A.Portal, { children: /* @__PURE__ */ a(A.Positioner, {
|
|
3605
3673
|
side: t,
|
|
3606
3674
|
sideOffset: n,
|
|
@@ -3616,14 +3684,14 @@ function Ba({ className: e, side: t = "bottom", sideOffset: n = 6, align: r = "s
|
|
|
3616
3684
|
})
|
|
3617
3685
|
}) });
|
|
3618
3686
|
}
|
|
3619
|
-
function
|
|
3687
|
+
function Ga({ className: e, ...t }) {
|
|
3620
3688
|
return /* @__PURE__ */ a(A.List, {
|
|
3621
3689
|
"data-slot": "combobox-list",
|
|
3622
3690
|
className: P("no-scrollbar max-h-[min(calc(--spacing(72)---spacing(9)),calc(var(--available-height)---spacing(9)))] scroll-py-1 p-1 data-empty:p-0 overflow-y-auto overscroll-contain", e),
|
|
3623
3691
|
...t
|
|
3624
3692
|
});
|
|
3625
3693
|
}
|
|
3626
|
-
function
|
|
3694
|
+
function Ka({ className: e, children: t, ...n }) {
|
|
3627
3695
|
return /* @__PURE__ */ o(A.Item, {
|
|
3628
3696
|
"data-slot": "combobox-item",
|
|
3629
3697
|
className: P("data-highlighted:bg-accent data-highlighted:text-accent-foreground not-data-[variant=destructive]:data-highlighted:**:text-accent-foreground gap-2 rounded-md py-1 pe-8 ps-1.5 text-sm [&_svg:not([class*='size-'])]:size-4 relative flex w-full cursor-default items-center outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0", e),
|
|
@@ -3634,48 +3702,48 @@ function Ha({ className: e, children: t, ...n }) {
|
|
|
3634
3702
|
})]
|
|
3635
3703
|
});
|
|
3636
3704
|
}
|
|
3637
|
-
function
|
|
3705
|
+
function qa({ className: e, ...t }) {
|
|
3638
3706
|
return /* @__PURE__ */ a(A.Group, {
|
|
3639
3707
|
"data-slot": "combobox-group",
|
|
3640
3708
|
className: P(e),
|
|
3641
3709
|
...t
|
|
3642
3710
|
});
|
|
3643
3711
|
}
|
|
3644
|
-
function
|
|
3712
|
+
function Ja({ className: e, ...t }) {
|
|
3645
3713
|
return /* @__PURE__ */ a(A.GroupLabel, {
|
|
3646
3714
|
"data-slot": "combobox-label",
|
|
3647
3715
|
className: P("text-muted-foreground px-2 py-1.5 text-xs", e),
|
|
3648
3716
|
...t
|
|
3649
3717
|
});
|
|
3650
3718
|
}
|
|
3651
|
-
function
|
|
3719
|
+
function Ya({ ...e }) {
|
|
3652
3720
|
return /* @__PURE__ */ a(A.Collection, {
|
|
3653
3721
|
"data-slot": "combobox-collection",
|
|
3654
3722
|
...e
|
|
3655
3723
|
});
|
|
3656
3724
|
}
|
|
3657
|
-
function
|
|
3725
|
+
function Xa({ className: e, ...t }) {
|
|
3658
3726
|
return /* @__PURE__ */ a(A.Empty, {
|
|
3659
3727
|
"data-slot": "combobox-empty",
|
|
3660
3728
|
className: P("text-muted-foreground hidden w-full justify-center py-2 text-center text-sm group-data-empty/combobox-content:flex", e),
|
|
3661
3729
|
...t
|
|
3662
3730
|
});
|
|
3663
3731
|
}
|
|
3664
|
-
function
|
|
3732
|
+
function Za({ className: e, ...t }) {
|
|
3665
3733
|
return /* @__PURE__ */ a(A.Separator, {
|
|
3666
3734
|
"data-slot": "combobox-separator",
|
|
3667
3735
|
className: P("bg-border -mx-1 my-1 h-px", e),
|
|
3668
3736
|
...t
|
|
3669
3737
|
});
|
|
3670
3738
|
}
|
|
3671
|
-
function
|
|
3739
|
+
function Qa({ className: e, ...t }) {
|
|
3672
3740
|
return /* @__PURE__ */ a(A.Chips, {
|
|
3673
3741
|
"data-slot": "combobox-chips",
|
|
3674
3742
|
className: P("dark:bg-input/30 border-input focus-within:border-ring focus-within:ring-ring/50 has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40 has-aria-invalid:border-destructive dark:has-aria-invalid:border-destructive/50 flex min-h-8 flex-wrap items-center gap-1 rounded-lg border bg-transparent bg-clip-padding px-2.5 py-1 text-sm transition-colors focus-within:ring-3 has-aria-invalid:ring-3 has-data-[slot=combobox-chip]:px-1", e),
|
|
3675
3743
|
...t
|
|
3676
3744
|
});
|
|
3677
3745
|
}
|
|
3678
|
-
function
|
|
3746
|
+
function $a({ className: e, children: t, showRemove: n = !0, ...r }) {
|
|
3679
3747
|
return /* @__PURE__ */ o(A.Chip, {
|
|
3680
3748
|
"data-slot": "combobox-chip",
|
|
3681
3749
|
className: P("bg-muted text-foreground flex h-[calc(--spacing(5.25))] w-fit items-center justify-center gap-1 rounded-sm px-1.5 text-xs font-medium whitespace-nowrap has-data-[slot=combobox-chip-remove]:pe-0 has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-disabled:opacity-50", e),
|
|
@@ -3691,26 +3759,26 @@ function Ya({ className: e, children: t, showRemove: n = !0, ...r }) {
|
|
|
3691
3759
|
})]
|
|
3692
3760
|
});
|
|
3693
3761
|
}
|
|
3694
|
-
function
|
|
3762
|
+
function eo({ className: e, ...t }) {
|
|
3695
3763
|
return /* @__PURE__ */ a(A.Input, {
|
|
3696
3764
|
"data-slot": "combobox-chip-input",
|
|
3697
3765
|
className: P("min-w-16 flex-1 outline-none", e),
|
|
3698
3766
|
...t
|
|
3699
3767
|
});
|
|
3700
3768
|
}
|
|
3701
|
-
function
|
|
3769
|
+
function to() {
|
|
3702
3770
|
return y.useRef(null);
|
|
3703
3771
|
}
|
|
3704
3772
|
//#endregion
|
|
3705
3773
|
//#region src/components/pure/command.tsx
|
|
3706
|
-
function
|
|
3774
|
+
function no({ className: e, ...t }) {
|
|
3707
3775
|
return /* @__PURE__ */ a(j, {
|
|
3708
3776
|
"data-slot": "command",
|
|
3709
3777
|
className: P("bg-popover text-popover-foreground rounded-xl! p-1 flex size-full flex-col overflow-hidden", e),
|
|
3710
3778
|
...t
|
|
3711
3779
|
});
|
|
3712
3780
|
}
|
|
3713
|
-
function
|
|
3781
|
+
function ro({ title: e = "Command Palette", description: t = "Search for a command to run...", children: n, className: r, showCloseButton: i = !1, ...s }) {
|
|
3714
3782
|
return /* @__PURE__ */ o(I, {
|
|
3715
3783
|
...s,
|
|
3716
3784
|
children: [/* @__PURE__ */ o(_t, {
|
|
@@ -3723,49 +3791,49 @@ function $a({ title: e = "Command Palette", description: t = "Search for a comma
|
|
|
3723
3791
|
})]
|
|
3724
3792
|
});
|
|
3725
3793
|
}
|
|
3726
|
-
function
|
|
3794
|
+
function io({ className: e, ...t }) {
|
|
3727
3795
|
return /* @__PURE__ */ a("div", {
|
|
3728
3796
|
"data-slot": "command-input-wrapper",
|
|
3729
3797
|
className: "p-1 pb-0",
|
|
3730
|
-
children: /* @__PURE__ */ o(
|
|
3798
|
+
children: /* @__PURE__ */ o(ja, {
|
|
3731
3799
|
className: "bg-input/30 border-input/30 h-8! rounded-lg! shadow-none! *:data-[slot=input-group-addon]:ps-2!",
|
|
3732
3800
|
children: [/* @__PURE__ */ a(j.Input, {
|
|
3733
3801
|
"data-slot": "command-input",
|
|
3734
3802
|
className: P("w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
3735
3803
|
...t
|
|
3736
|
-
}), /* @__PURE__ */ a(
|
|
3804
|
+
}), /* @__PURE__ */ a(Na, { children: /* @__PURE__ */ a(ve, { className: "size-4 shrink-0 opacity-50" }) })]
|
|
3737
3805
|
})
|
|
3738
3806
|
});
|
|
3739
3807
|
}
|
|
3740
|
-
function
|
|
3808
|
+
function ao({ className: e, ...t }) {
|
|
3741
3809
|
return /* @__PURE__ */ a(j.List, {
|
|
3742
3810
|
"data-slot": "command-list",
|
|
3743
3811
|
className: P("no-scrollbar max-h-72 scroll-py-1 outline-none overflow-x-hidden overflow-y-auto", e),
|
|
3744
3812
|
...t
|
|
3745
3813
|
});
|
|
3746
3814
|
}
|
|
3747
|
-
function
|
|
3815
|
+
function oo({ className: e, ...t }) {
|
|
3748
3816
|
return /* @__PURE__ */ a(j.Empty, {
|
|
3749
3817
|
"data-slot": "command-empty",
|
|
3750
3818
|
className: P("py-6 text-center text-sm", e),
|
|
3751
3819
|
...t
|
|
3752
3820
|
});
|
|
3753
3821
|
}
|
|
3754
|
-
function
|
|
3822
|
+
function so({ className: e, ...t }) {
|
|
3755
3823
|
return /* @__PURE__ */ a(j.Group, {
|
|
3756
3824
|
"data-slot": "command-group",
|
|
3757
3825
|
className: P("text-foreground **:[[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium", e),
|
|
3758
3826
|
...t
|
|
3759
3827
|
});
|
|
3760
3828
|
}
|
|
3761
|
-
function
|
|
3829
|
+
function co({ className: e, ...t }) {
|
|
3762
3830
|
return /* @__PURE__ */ a(j.Separator, {
|
|
3763
3831
|
"data-slot": "command-separator",
|
|
3764
3832
|
className: P("bg-border -mx-1 h-px", e),
|
|
3765
3833
|
...t
|
|
3766
3834
|
});
|
|
3767
3835
|
}
|
|
3768
|
-
function
|
|
3836
|
+
function lo({ className: e, children: t, ...n }) {
|
|
3769
3837
|
return /* @__PURE__ */ o(j.Item, {
|
|
3770
3838
|
"data-slot": "command-item",
|
|
3771
3839
|
className: P("data-selected:bg-muted data-selected:text-foreground data-selected:*:[svg]:text-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none in-data-[slot=dialog-content]:rounded-lg! [&_svg:not([class*='size-'])]:size-4 group/command-item data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0", e),
|
|
@@ -3773,7 +3841,7 @@ function ao({ className: e, children: t, ...n }) {
|
|
|
3773
3841
|
children: [t, /* @__PURE__ */ a(c, { className: "ms-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" })]
|
|
3774
3842
|
});
|
|
3775
3843
|
}
|
|
3776
|
-
function
|
|
3844
|
+
function uo({ className: e, ...t }) {
|
|
3777
3845
|
return /* @__PURE__ */ a("span", {
|
|
3778
3846
|
"data-slot": "command-shortcut",
|
|
3779
3847
|
className: P("text-muted-foreground group-data-selected/command-item:text-foreground ms-auto text-xs tracking-widest", e),
|
|
@@ -3782,50 +3850,50 @@ function oo({ className: e, ...t }) {
|
|
|
3782
3850
|
}
|
|
3783
3851
|
//#endregion
|
|
3784
3852
|
//#region src/components/pure/direction.tsx
|
|
3785
|
-
function
|
|
3853
|
+
function fo({ dir: e, direction: t, children: n }) {
|
|
3786
3854
|
return /* @__PURE__ */ a(Je.DirectionProvider, {
|
|
3787
3855
|
dir: t ?? e,
|
|
3788
3856
|
children: n
|
|
3789
3857
|
});
|
|
3790
3858
|
}
|
|
3791
|
-
var
|
|
3859
|
+
var po = Je.useDirection;
|
|
3792
3860
|
//#endregion
|
|
3793
3861
|
//#region src/components/pure/drawer.tsx
|
|
3794
|
-
function
|
|
3862
|
+
function mo({ ...e }) {
|
|
3795
3863
|
return /* @__PURE__ */ a(M.Root, {
|
|
3796
3864
|
"data-slot": "drawer",
|
|
3797
3865
|
...e
|
|
3798
3866
|
});
|
|
3799
3867
|
}
|
|
3800
|
-
function
|
|
3868
|
+
function ho({ ...e }) {
|
|
3801
3869
|
return /* @__PURE__ */ a(M.Trigger, {
|
|
3802
3870
|
"data-slot": "drawer-trigger",
|
|
3803
3871
|
...e
|
|
3804
3872
|
});
|
|
3805
3873
|
}
|
|
3806
|
-
function
|
|
3874
|
+
function go({ ...e }) {
|
|
3807
3875
|
return /* @__PURE__ */ a(M.Portal, {
|
|
3808
3876
|
"data-slot": "drawer-portal",
|
|
3809
3877
|
...e
|
|
3810
3878
|
});
|
|
3811
3879
|
}
|
|
3812
|
-
function
|
|
3880
|
+
function _o({ ...e }) {
|
|
3813
3881
|
return /* @__PURE__ */ a(M.Close, {
|
|
3814
3882
|
"data-slot": "drawer-close",
|
|
3815
3883
|
...e
|
|
3816
3884
|
});
|
|
3817
3885
|
}
|
|
3818
|
-
function
|
|
3886
|
+
function vo({ className: e, ...t }) {
|
|
3819
3887
|
return /* @__PURE__ */ a(M.Overlay, {
|
|
3820
3888
|
"data-slot": "drawer-overlay",
|
|
3821
3889
|
className: P("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/10 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50", e),
|
|
3822
3890
|
...t
|
|
3823
3891
|
});
|
|
3824
3892
|
}
|
|
3825
|
-
function
|
|
3826
|
-
return /* @__PURE__ */ o(
|
|
3893
|
+
function yo({ className: e, children: t, ...n }) {
|
|
3894
|
+
return /* @__PURE__ */ o(go, {
|
|
3827
3895
|
"data-slot": "drawer-portal",
|
|
3828
|
-
children: [/* @__PURE__ */ a(
|
|
3896
|
+
children: [/* @__PURE__ */ a(vo, {}), /* @__PURE__ */ o(M.Content, {
|
|
3829
3897
|
"data-slot": "drawer-content",
|
|
3830
3898
|
className: P("bg-background flex h-auto flex-col text-sm data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=bottom]:rounded-t-xl data-[vaul-drawer-direction=bottom]:border-t data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:start-0 data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:rounded-e-xl data-[vaul-drawer-direction=left]:border-e data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:end-0 data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:rounded-s-xl data-[vaul-drawer-direction=right]:border-s data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=top]:rounded-b-xl data-[vaul-drawer-direction=top]:border-b data-[vaul-drawer-direction=left]:sm:max-w-sm data-[vaul-drawer-direction=right]:sm:max-w-sm group/drawer-content fixed z-50", e),
|
|
3831
3899
|
...n,
|
|
@@ -3833,28 +3901,28 @@ function ho({ className: e, children: t, ...n }) {
|
|
|
3833
3901
|
})]
|
|
3834
3902
|
});
|
|
3835
3903
|
}
|
|
3836
|
-
function
|
|
3904
|
+
function bo({ className: e, ...t }) {
|
|
3837
3905
|
return /* @__PURE__ */ a("div", {
|
|
3838
3906
|
"data-slot": "drawer-header",
|
|
3839
3907
|
className: P("gap-0.5 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:gap-0.5 md:text-start flex flex-col", e),
|
|
3840
3908
|
...t
|
|
3841
3909
|
});
|
|
3842
3910
|
}
|
|
3843
|
-
function
|
|
3911
|
+
function xo({ className: e, ...t }) {
|
|
3844
3912
|
return /* @__PURE__ */ a("div", {
|
|
3845
3913
|
"data-slot": "drawer-footer",
|
|
3846
3914
|
className: P("gap-2 p-4 mt-auto flex flex-col", e),
|
|
3847
3915
|
...t
|
|
3848
3916
|
});
|
|
3849
3917
|
}
|
|
3850
|
-
function
|
|
3918
|
+
function So({ className: e, ...t }) {
|
|
3851
3919
|
return /* @__PURE__ */ a(M.Title, {
|
|
3852
3920
|
"data-slot": "drawer-title",
|
|
3853
3921
|
className: P("text-foreground text-base font-medium", e),
|
|
3854
3922
|
...t
|
|
3855
3923
|
});
|
|
3856
3924
|
}
|
|
3857
|
-
function
|
|
3925
|
+
function Co({ className: e, ...t }) {
|
|
3858
3926
|
return /* @__PURE__ */ a(M.Description, {
|
|
3859
3927
|
"data-slot": "drawer-description",
|
|
3860
3928
|
className: P("text-muted-foreground text-sm", e),
|
|
@@ -3863,14 +3931,14 @@ function yo({ className: e, ...t }) {
|
|
|
3863
3931
|
}
|
|
3864
3932
|
//#endregion
|
|
3865
3933
|
//#region src/components/pure/field.tsx
|
|
3866
|
-
function
|
|
3934
|
+
function wo({ className: e, ...t }) {
|
|
3867
3935
|
return /* @__PURE__ */ a("fieldset", {
|
|
3868
3936
|
"data-slot": "field-set",
|
|
3869
3937
|
className: P("gap-4 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3 flex flex-col", e),
|
|
3870
3938
|
...t
|
|
3871
3939
|
});
|
|
3872
3940
|
}
|
|
3873
|
-
function
|
|
3941
|
+
function To({ className: e, variant: t = "legend", ...n }) {
|
|
3874
3942
|
return /* @__PURE__ */ a("legend", {
|
|
3875
3943
|
"data-slot": "field-legend",
|
|
3876
3944
|
"data-variant": t,
|
|
@@ -3878,14 +3946,14 @@ function xo({ className: e, variant: t = "legend", ...n }) {
|
|
|
3878
3946
|
...n
|
|
3879
3947
|
});
|
|
3880
3948
|
}
|
|
3881
|
-
function
|
|
3949
|
+
function Eo({ className: e, ...t }) {
|
|
3882
3950
|
return /* @__PURE__ */ a("div", {
|
|
3883
3951
|
"data-slot": "field-group",
|
|
3884
3952
|
className: P("gap-5 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4 group/field-group @container/field-group flex w-full flex-col", e),
|
|
3885
3953
|
...t
|
|
3886
3954
|
});
|
|
3887
3955
|
}
|
|
3888
|
-
var
|
|
3956
|
+
var Do = S("data-[invalid=true]:text-destructive gap-2 group/field flex w-full", {
|
|
3889
3957
|
variants: { orientation: {
|
|
3890
3958
|
vertical: "flex-col *:w-full [&>.sr-only]:w-auto",
|
|
3891
3959
|
horizontal: "flex-row items-center *:data-[slot=field-label]:flex-auto has-[>[data-slot=field-content]]:items-start has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",
|
|
@@ -3893,44 +3961,44 @@ var Co = S("data-[invalid=true]:text-destructive gap-2 group/field flex w-full",
|
|
|
3893
3961
|
} },
|
|
3894
3962
|
defaultVariants: { orientation: "vertical" }
|
|
3895
3963
|
});
|
|
3896
|
-
function
|
|
3964
|
+
function Oo({ className: e, orientation: t = "vertical", ...n }) {
|
|
3897
3965
|
return /* @__PURE__ */ a("div", {
|
|
3898
3966
|
role: "group",
|
|
3899
3967
|
"data-slot": "field",
|
|
3900
3968
|
"data-orientation": t,
|
|
3901
|
-
className: P(
|
|
3969
|
+
className: P(Do({ orientation: t }), e),
|
|
3902
3970
|
...n
|
|
3903
3971
|
});
|
|
3904
3972
|
}
|
|
3905
|
-
function
|
|
3973
|
+
function ko({ className: e, ...t }) {
|
|
3906
3974
|
return /* @__PURE__ */ a("div", {
|
|
3907
3975
|
"data-slot": "field-content",
|
|
3908
3976
|
className: P("gap-0.5 group/field-content flex flex-1 flex-col leading-snug", e),
|
|
3909
3977
|
...t
|
|
3910
3978
|
});
|
|
3911
3979
|
}
|
|
3912
|
-
function
|
|
3980
|
+
function Ao({ className: e, ...t }) {
|
|
3913
3981
|
return /* @__PURE__ */ a(Wt, {
|
|
3914
3982
|
"data-slot": "field-label",
|
|
3915
3983
|
className: P("has-data-checked:bg-primary/5 has-data-checked:border-primary/30 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10 gap-2 group-data-[disabled=true]/field:opacity-50 has-[>[data-slot=field]]:rounded-lg has-[>[data-slot=field]]:border *:data-[slot=field]:p-2.5 group/field-label peer/field-label flex w-fit leading-snug", "has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col", e),
|
|
3916
3984
|
...t
|
|
3917
3985
|
});
|
|
3918
3986
|
}
|
|
3919
|
-
function
|
|
3987
|
+
function jo({ className: e, ...t }) {
|
|
3920
3988
|
return /* @__PURE__ */ a("div", {
|
|
3921
3989
|
"data-slot": "field-label",
|
|
3922
3990
|
className: P("gap-2 text-sm font-medium group-data-[disabled=true]/field:opacity-50 flex w-fit items-center leading-snug", e),
|
|
3923
3991
|
...t
|
|
3924
3992
|
});
|
|
3925
3993
|
}
|
|
3926
|
-
function
|
|
3994
|
+
function Mo({ className: e, ...t }) {
|
|
3927
3995
|
return /* @__PURE__ */ a("p", {
|
|
3928
3996
|
"data-slot": "field-description",
|
|
3929
3997
|
className: P("text-muted-foreground text-start text-sm [[data-variant=legend]+&]:-mt-1.5 leading-normal font-normal group-has-data-horizontal/field:text-balance", "last:mt-0 nth-last-2:-mt-1", "[&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4", e),
|
|
3930
3998
|
...t
|
|
3931
3999
|
});
|
|
3932
4000
|
}
|
|
3933
|
-
function
|
|
4001
|
+
function No({ children: e, className: t, ...n }) {
|
|
3934
4002
|
return /* @__PURE__ */ o("div", {
|
|
3935
4003
|
"data-slot": "field-separator",
|
|
3936
4004
|
"data-content": !!e,
|
|
@@ -3943,7 +4011,7 @@ function ko({ children: e, className: t, ...n }) {
|
|
|
3943
4011
|
})]
|
|
3944
4012
|
});
|
|
3945
4013
|
}
|
|
3946
|
-
function
|
|
4014
|
+
function Po({ className: e, children: t, errors: n, ...r }) {
|
|
3947
4015
|
let i = Me(() => {
|
|
3948
4016
|
if (t) return t;
|
|
3949
4017
|
if (!n?.length) return null;
|
|
@@ -3963,7 +4031,7 @@ function Ao({ className: e, children: t, errors: n, ...r }) {
|
|
|
3963
4031
|
}
|
|
3964
4032
|
//#endregion
|
|
3965
4033
|
//#region src/components/pure/scroll-area.tsx
|
|
3966
|
-
function
|
|
4034
|
+
function Fo({ className: e, children: t, ...n }) {
|
|
3967
4035
|
return /* @__PURE__ */ o(Ye.Root, {
|
|
3968
4036
|
"data-slot": "scroll-area",
|
|
3969
4037
|
className: P("relative", e),
|
|
@@ -3974,12 +4042,12 @@ function jo({ className: e, children: t, ...n }) {
|
|
|
3974
4042
|
className: "focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",
|
|
3975
4043
|
children: t
|
|
3976
4044
|
}),
|
|
3977
|
-
/* @__PURE__ */ a(
|
|
4045
|
+
/* @__PURE__ */ a(Io, {}),
|
|
3978
4046
|
/* @__PURE__ */ a(Ye.Corner, {})
|
|
3979
4047
|
]
|
|
3980
4048
|
});
|
|
3981
4049
|
}
|
|
3982
|
-
function
|
|
4050
|
+
function Io({ className: e, orientation: t = "vertical", ...n }) {
|
|
3983
4051
|
return /* @__PURE__ */ a(Ye.ScrollAreaScrollbar, {
|
|
3984
4052
|
"data-slot": "scroll-area-scrollbar",
|
|
3985
4053
|
"data-orientation": t,
|
|
@@ -3994,7 +4062,7 @@ function Mo({ className: e, orientation: t = "vertical", ...n }) {
|
|
|
3994
4062
|
}
|
|
3995
4063
|
//#endregion
|
|
3996
4064
|
//#region src/components/pure/sonner.tsx
|
|
3997
|
-
var
|
|
4065
|
+
var Lo = ({ ...e }) => {
|
|
3998
4066
|
let { theme: t = "system" } = Xe();
|
|
3999
4067
|
return /* @__PURE__ */ a(Ze, {
|
|
4000
4068
|
theme: t,
|
|
@@ -4018,7 +4086,7 @@ var No = ({ ...e }) => {
|
|
|
4018
4086
|
};
|
|
4019
4087
|
//#endregion
|
|
4020
4088
|
//#region src/components/pure/switch.tsx
|
|
4021
|
-
function
|
|
4089
|
+
function Ro({ className: e, size: t = "default", ...n }) {
|
|
4022
4090
|
return /* @__PURE__ */ a(Qe.Root, {
|
|
4023
4091
|
"data-slot": "switch",
|
|
4024
4092
|
"data-size": t,
|
|
@@ -4032,7 +4100,7 @@ function Po({ className: e, size: t = "default", ...n }) {
|
|
|
4032
4100
|
}
|
|
4033
4101
|
//#endregion
|
|
4034
4102
|
//#region src/components/pure/tabs.tsx
|
|
4035
|
-
function
|
|
4103
|
+
function zo({ className: e, orientation: t = "horizontal", ...n }) {
|
|
4036
4104
|
return /* @__PURE__ */ a($e.Root, {
|
|
4037
4105
|
"data-slot": "tabs",
|
|
4038
4106
|
"data-orientation": t,
|
|
@@ -4040,29 +4108,29 @@ function Fo({ className: e, orientation: t = "horizontal", ...n }) {
|
|
|
4040
4108
|
...n
|
|
4041
4109
|
});
|
|
4042
4110
|
}
|
|
4043
|
-
var
|
|
4111
|
+
var Bo = S("rounded-lg p-[3px] group-data-horizontal/tabs:h-8 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col", {
|
|
4044
4112
|
variants: { variant: {
|
|
4045
4113
|
default: "bg-muted",
|
|
4046
4114
|
line: "gap-1 bg-transparent"
|
|
4047
4115
|
} },
|
|
4048
4116
|
defaultVariants: { variant: "default" }
|
|
4049
4117
|
});
|
|
4050
|
-
function
|
|
4118
|
+
function Vo({ className: e, variant: t = "default", ...n }) {
|
|
4051
4119
|
return /* @__PURE__ */ a($e.List, {
|
|
4052
4120
|
"data-slot": "tabs-list",
|
|
4053
4121
|
"data-variant": t,
|
|
4054
|
-
className: P(
|
|
4122
|
+
className: P(Bo({ variant: t }), e),
|
|
4055
4123
|
...n
|
|
4056
4124
|
});
|
|
4057
4125
|
}
|
|
4058
|
-
function
|
|
4126
|
+
function Ho({ className: e, ...t }) {
|
|
4059
4127
|
return /* @__PURE__ */ a($e.Trigger, {
|
|
4060
4128
|
"data-slot": "tabs-trigger",
|
|
4061
4129
|
className: P("gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg:not([class*='size-'])]:size-4 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground/60 hover:text-foreground dark:text-muted-foreground dark:hover:text-foreground relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center whitespace-nowrap transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0", "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent", "data-active:bg-background dark:data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 data-active:text-foreground", "after:bg-foreground after:absolute after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-end-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100", e),
|
|
4062
4130
|
...t
|
|
4063
4131
|
});
|
|
4064
4132
|
}
|
|
4065
|
-
function
|
|
4133
|
+
function Uo({ className: e, ...t }) {
|
|
4066
4134
|
return /* @__PURE__ */ a($e.Content, {
|
|
4067
4135
|
"data-slot": "tabs-content",
|
|
4068
4136
|
className: P("text-sm flex-1 outline-none", e),
|
|
@@ -4071,7 +4139,7 @@ function zo({ className: e, ...t }) {
|
|
|
4071
4139
|
}
|
|
4072
4140
|
//#endregion
|
|
4073
4141
|
//#region src/components/pure/toggle.tsx
|
|
4074
|
-
var
|
|
4142
|
+
var Wo = S("hover:text-foreground aria-pressed:bg-muted focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive data-[state=on]:bg-muted gap-1 rounded-lg text-sm font-medium transition-all [&_svg:not([class*='size-'])]:size-4 group/toggle hover:bg-muted inline-flex items-center justify-center whitespace-nowrap outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0", {
|
|
4075
4143
|
variants: {
|
|
4076
4144
|
variant: {
|
|
4077
4145
|
default: "bg-transparent",
|
|
@@ -4088,10 +4156,10 @@ var Bo = S("hover:text-foreground aria-pressed:bg-muted focus-visible:border-rin
|
|
|
4088
4156
|
size: "default"
|
|
4089
4157
|
}
|
|
4090
4158
|
});
|
|
4091
|
-
function
|
|
4159
|
+
function Go({ className: e, variant: t = "default", size: n = "default", ...r }) {
|
|
4092
4160
|
return /* @__PURE__ */ a(tt.Root, {
|
|
4093
4161
|
"data-slot": "toggle",
|
|
4094
|
-
className: P(
|
|
4162
|
+
className: P(Wo({
|
|
4095
4163
|
variant: t,
|
|
4096
4164
|
size: n,
|
|
4097
4165
|
className: e
|
|
@@ -4101,13 +4169,13 @@ function Vo({ className: e, variant: t = "default", size: n = "default", ...r })
|
|
|
4101
4169
|
}
|
|
4102
4170
|
//#endregion
|
|
4103
4171
|
//#region src/components/pure/toggle-group.tsx
|
|
4104
|
-
var
|
|
4172
|
+
var Ko = y.createContext({
|
|
4105
4173
|
size: "default",
|
|
4106
4174
|
variant: "default",
|
|
4107
4175
|
spacing: 0,
|
|
4108
4176
|
orientation: "horizontal"
|
|
4109
4177
|
});
|
|
4110
|
-
function
|
|
4178
|
+
function qo({ className: e, variant: t, size: n, spacing: r = 0, orientation: i = "horizontal", children: o, ...s }) {
|
|
4111
4179
|
return /* @__PURE__ */ a(et.Root, {
|
|
4112
4180
|
"data-slot": "toggle-group",
|
|
4113
4181
|
"data-variant": t,
|
|
@@ -4117,7 +4185,7 @@ function Uo({ className: e, variant: t, size: n, spacing: r = 0, orientation: i
|
|
|
4117
4185
|
style: { "--gap": r },
|
|
4118
4186
|
className: P("rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] data-vertical:flex-col data-vertical:items-stretch", e),
|
|
4119
4187
|
...s,
|
|
4120
|
-
children: /* @__PURE__ */ a(
|
|
4188
|
+
children: /* @__PURE__ */ a(Ko.Provider, {
|
|
4121
4189
|
value: {
|
|
4122
4190
|
variant: t,
|
|
4123
4191
|
size: n,
|
|
@@ -4128,14 +4196,14 @@ function Uo({ className: e, variant: t, size: n, spacing: r = 0, orientation: i
|
|
|
4128
4196
|
})
|
|
4129
4197
|
});
|
|
4130
4198
|
}
|
|
4131
|
-
function
|
|
4132
|
-
let o = y.useContext(
|
|
4199
|
+
function Jo({ className: e, children: t, variant: n = "default", size: r = "default", ...i }) {
|
|
4200
|
+
let o = y.useContext(Ko);
|
|
4133
4201
|
return /* @__PURE__ */ a(et.Item, {
|
|
4134
4202
|
"data-slot": "toggle-group-item",
|
|
4135
4203
|
"data-variant": o.variant || n,
|
|
4136
4204
|
"data-size": o.size || r,
|
|
4137
4205
|
"data-spacing": o.spacing,
|
|
4138
|
-
className: P("group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-s-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-e-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg shrink-0 focus:z-10 focus-visible:z-10 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-s-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-s group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t",
|
|
4206
|
+
className: P("group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-s-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-e-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg shrink-0 focus:z-10 focus-visible:z-10 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-s-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-s group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t", Wo({
|
|
4139
4207
|
variant: o.variant || n,
|
|
4140
4208
|
size: o.size || r
|
|
4141
4209
|
}), e),
|
|
@@ -4145,7 +4213,7 @@ function Wo({ className: e, children: t, variant: n = "default", size: r = "defa
|
|
|
4145
4213
|
}
|
|
4146
4214
|
//#endregion
|
|
4147
4215
|
//#region src/components/custom/permissions/permissionCard.tsx
|
|
4148
|
-
var
|
|
4216
|
+
var Yo = (e, t, n = ".") => {
|
|
4149
4217
|
let r = e.reduce((e, t) => {
|
|
4150
4218
|
let [r, i] = t.split(n);
|
|
4151
4219
|
return e[r] || (e[r] = {
|
|
@@ -4158,11 +4226,11 @@ var Go = (e, t, n = ".") => {
|
|
|
4158
4226
|
...r[e]
|
|
4159
4227
|
}));
|
|
4160
4228
|
};
|
|
4161
|
-
function
|
|
4229
|
+
function Xo({ resourceId: e, label: t, masterPermission: n, actions: r, selectedPermissions: i, onToggle: s, isMasterRequired: c = !1 }) {
|
|
4162
4230
|
let l = c ? !0 : n ? i.includes(n) : !1, u = (e, t, n, r = ".") => e.includes(n) ? e.filter((e) => !e.startsWith(`${t}${r}`)) : [...e, n], d = (e, t) => e.includes(t) ? e.filter((e) => e !== t) : [...e, t];
|
|
4163
|
-
return /* @__PURE__ */ o(
|
|
4231
|
+
return /* @__PURE__ */ o(yn, {
|
|
4164
4232
|
className: "shadow-none border-2",
|
|
4165
|
-
children: [/* @__PURE__ */ o(
|
|
4233
|
+
children: [/* @__PURE__ */ o(bn, {
|
|
4166
4234
|
className: "flex flex-row items-center justify-between border-b py-3 px-4",
|
|
4167
4235
|
children: [/* @__PURE__ */ o("div", {
|
|
4168
4236
|
className: "flex items-center gap-2",
|
|
@@ -4170,11 +4238,11 @@ function Ko({ resourceId: e, label: t, masterPermission: n, actions: r, selected
|
|
|
4170
4238
|
className: "font-bold text-sm",
|
|
4171
4239
|
children: t
|
|
4172
4240
|
})]
|
|
4173
|
-
}), n && !c && /* @__PURE__ */ a(
|
|
4241
|
+
}), n && !c && /* @__PURE__ */ a(Aa, {
|
|
4174
4242
|
checked: l,
|
|
4175
4243
|
onCheckedChange: () => s(u(i, e, n))
|
|
4176
4244
|
})]
|
|
4177
|
-
}), /* @__PURE__ */ a(
|
|
4245
|
+
}), /* @__PURE__ */ a(wn, {
|
|
4178
4246
|
className: "p-2 space-y-1",
|
|
4179
4247
|
children: r.map((e) => /* @__PURE__ */ o("div", {
|
|
4180
4248
|
className: `flex items-center justify-between p-2 rounded-sm transition-opacity ${l ? "hover:bg-muted" : "opacity-40 select-none"}`,
|
|
@@ -4184,7 +4252,7 @@ function Ko({ resourceId: e, label: t, masterPermission: n, actions: r, selected
|
|
|
4184
4252
|
className: "text-xs cursor-pointer",
|
|
4185
4253
|
children: e.label
|
|
4186
4254
|
})]
|
|
4187
|
-
}), /* @__PURE__ */ a(
|
|
4255
|
+
}), /* @__PURE__ */ a(Aa, {
|
|
4188
4256
|
disabled: !l,
|
|
4189
4257
|
checked: i.includes(e.id),
|
|
4190
4258
|
onCheckedChange: () => s(d(i, e.id))
|
|
@@ -4195,18 +4263,18 @@ function Ko({ resourceId: e, label: t, masterPermission: n, actions: r, selected
|
|
|
4195
4263
|
}
|
|
4196
4264
|
//#endregion
|
|
4197
4265
|
//#region src/components/custom/permissions/permissionSkeleton.tsx
|
|
4198
|
-
var
|
|
4266
|
+
var Zo = () => /* @__PURE__ */ a("div", {
|
|
4199
4267
|
className: "grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",
|
|
4200
4268
|
children: [
|
|
4201
4269
|
1,
|
|
4202
4270
|
2,
|
|
4203
4271
|
3
|
|
4204
|
-
].map((e) => /* @__PURE__ */ o(
|
|
4272
|
+
].map((e) => /* @__PURE__ */ o(yn, {
|
|
4205
4273
|
className: "shadow-none border-2",
|
|
4206
|
-
children: [/* @__PURE__ */ o(
|
|
4274
|
+
children: [/* @__PURE__ */ o(bn, {
|
|
4207
4275
|
className: "flex flex-row items-center justify-between border-b p-4",
|
|
4208
4276
|
children: [/* @__PURE__ */ a(V, { className: "h-4 w-25" }), /* @__PURE__ */ a(V, { className: "h-5 w-5 rounded-md" })]
|
|
4209
|
-
}), /* @__PURE__ */ o(
|
|
4277
|
+
}), /* @__PURE__ */ o(wn, {
|
|
4210
4278
|
className: "p-4 space-y-3",
|
|
4211
4279
|
children: [/* @__PURE__ */ a(V, { className: "h-4 w-full" }), /* @__PURE__ */ a(V, { className: "h-4 w-full" })]
|
|
4212
4280
|
})]
|
|
@@ -4214,7 +4282,7 @@ var qo = () => /* @__PURE__ */ a("div", {
|
|
|
4214
4282
|
});
|
|
4215
4283
|
//#endregion
|
|
4216
4284
|
//#region src/components/custom/select/searchableSelect.tsx
|
|
4217
|
-
function
|
|
4285
|
+
function Qo({ items: e, itemLabelKey: t, itemValueKey: n, value: r, onValueChange: i, disabled: c, errorInputClass: l, placeholder: u = "اختر...", columnsNames: d, onSearch: f }) {
|
|
4218
4286
|
let [p, m] = y.useState(!1), g = e.find((e) => String(e[n]) === r), _ = g ? String(g[t]) : u;
|
|
4219
4287
|
return /* @__PURE__ */ o(It, {
|
|
4220
4288
|
open: p,
|
|
@@ -4237,19 +4305,19 @@ function Jo({ items: e, itemLabelKey: t, itemValueKey: n, value: r, onValueChang
|
|
|
4237
4305
|
className: "w-[--radix-popover-trigger-width] p-0",
|
|
4238
4306
|
align: "start",
|
|
4239
4307
|
dir: "rtl",
|
|
4240
|
-
children: [/* @__PURE__ */ a(
|
|
4308
|
+
children: [/* @__PURE__ */ a(Vn, {
|
|
4241
4309
|
columnsNames: d,
|
|
4242
4310
|
onSearch: f
|
|
4243
|
-
}), /* @__PURE__ */ a(
|
|
4311
|
+
}), /* @__PURE__ */ a(no, {
|
|
4244
4312
|
shouldFilter: !1,
|
|
4245
|
-
children: /* @__PURE__ */ a(
|
|
4313
|
+
children: /* @__PURE__ */ a(ao, {
|
|
4246
4314
|
className: "max-h-50 overflow-y-auto overflow-x-hidden",
|
|
4247
|
-
children: e.length === 0 ? /* @__PURE__ */ a(
|
|
4315
|
+
children: e.length === 0 ? /* @__PURE__ */ a(oo, {
|
|
4248
4316
|
className: "py-6 text-center text-sm text-muted-foreground",
|
|
4249
4317
|
children: "لا توجد بيانات"
|
|
4250
|
-
}) : /* @__PURE__ */ a(
|
|
4318
|
+
}) : /* @__PURE__ */ a(so, { children: e.map((e) => {
|
|
4251
4319
|
let c = String(e[n]), l = String(e[t]);
|
|
4252
|
-
return /* @__PURE__ */ o(
|
|
4320
|
+
return /* @__PURE__ */ o(lo, {
|
|
4253
4321
|
value: c,
|
|
4254
4322
|
onSelect: () => {
|
|
4255
4323
|
i(c), m(!1);
|
|
@@ -4265,16 +4333,16 @@ function Jo({ items: e, itemLabelKey: t, itemValueKey: n, value: r, onValueChang
|
|
|
4265
4333
|
}
|
|
4266
4334
|
//#endregion
|
|
4267
4335
|
//#region src/components/custom/sideBar/sideBarCompanyData.tsx
|
|
4268
|
-
function
|
|
4336
|
+
function $o({ company: e }) {
|
|
4269
4337
|
return /* @__PURE__ */ a(H, { children: /* @__PURE__ */ a(U, { children: /* @__PURE__ */ o(W, {
|
|
4270
4338
|
size: "lg",
|
|
4271
4339
|
className: "data-[state=open]:bg-sidebar-accent data-[state=open]:text-sidebar-accent-foreground",
|
|
4272
|
-
children: [/* @__PURE__ */ o(
|
|
4340
|
+
children: [/* @__PURE__ */ o(aa, {
|
|
4273
4341
|
className: "h-8 w-8 rounded-lg grayscale",
|
|
4274
|
-
children: [/* @__PURE__ */ a(
|
|
4342
|
+
children: [/* @__PURE__ */ a(oa, {
|
|
4275
4343
|
src: e.logo,
|
|
4276
4344
|
alt: e.name
|
|
4277
|
-
}), /* @__PURE__ */ a(
|
|
4345
|
+
}), /* @__PURE__ */ a(sa, {
|
|
4278
4346
|
className: "rounded-lg",
|
|
4279
4347
|
children: "YSR"
|
|
4280
4348
|
})]
|
|
@@ -4289,8 +4357,8 @@ function Yo({ company: e }) {
|
|
|
4289
4357
|
}
|
|
4290
4358
|
//#endregion
|
|
4291
4359
|
//#region src/components/custom/sideBar/sidebarLogo.tsx
|
|
4292
|
-
function
|
|
4293
|
-
let { state: n } =
|
|
4360
|
+
function es({ logos: e, alt: t = "Logo" }) {
|
|
4361
|
+
let { state: n } = _i(), r = n === "collapsed";
|
|
4294
4362
|
return /* @__PURE__ */ o("div", {
|
|
4295
4363
|
className: `
|
|
4296
4364
|
animate-fadeSlide transition-all duration-300 pb-3
|
|
@@ -4309,19 +4377,19 @@ function Xo({ logos: e, alt: t = "Logo" }) {
|
|
|
4309
4377
|
}
|
|
4310
4378
|
//#endregion
|
|
4311
4379
|
//#region src/components/pure/collapsible.tsx
|
|
4312
|
-
function
|
|
4380
|
+
function ts({ ...e }) {
|
|
4313
4381
|
return /* @__PURE__ */ a(nt.Root, {
|
|
4314
4382
|
"data-slot": "collapsible",
|
|
4315
4383
|
...e
|
|
4316
4384
|
});
|
|
4317
4385
|
}
|
|
4318
|
-
function
|
|
4386
|
+
function ns({ ...e }) {
|
|
4319
4387
|
return /* @__PURE__ */ a(nt.CollapsibleTrigger, {
|
|
4320
4388
|
"data-slot": "collapsible-trigger",
|
|
4321
4389
|
...e
|
|
4322
4390
|
});
|
|
4323
4391
|
}
|
|
4324
|
-
function
|
|
4392
|
+
function rs({ ...e }) {
|
|
4325
4393
|
return /* @__PURE__ */ a(nt.CollapsibleContent, {
|
|
4326
4394
|
"data-slot": "collapsible-content",
|
|
4327
4395
|
...e
|
|
@@ -4329,18 +4397,18 @@ function $o({ ...e }) {
|
|
|
4329
4397
|
}
|
|
4330
4398
|
//#endregion
|
|
4331
4399
|
//#region src/components/custom/sideBar/sideBarMainMenu.tsx
|
|
4332
|
-
function
|
|
4333
|
-
return /* @__PURE__ */ a(
|
|
4400
|
+
function is({ items: t }) {
|
|
4401
|
+
return /* @__PURE__ */ a(Oi, {
|
|
4334
4402
|
className: "mt-5",
|
|
4335
|
-
children: /* @__PURE__ */ a(
|
|
4403
|
+
children: /* @__PURE__ */ a(ji, { children: /* @__PURE__ */ a(H, { children: t.map((t) => {
|
|
4336
4404
|
if (!t.hasAuth) return null;
|
|
4337
4405
|
if (t.subItems && t.subItems.length > 0) {
|
|
4338
4406
|
let n = t.subItems.filter((e) => e.hasAuth);
|
|
4339
|
-
return n.length === 0 ? null : /* @__PURE__ */ o(Oe, { children: [/* @__PURE__ */ a(
|
|
4407
|
+
return n.length === 0 ? null : /* @__PURE__ */ o(Oe, { children: [/* @__PURE__ */ a(ts, {
|
|
4340
4408
|
asChild: !0,
|
|
4341
4409
|
defaultOpen: !1,
|
|
4342
4410
|
className: "group/collapsible",
|
|
4343
|
-
children: /* @__PURE__ */ o(U, { children: [/* @__PURE__ */ a(
|
|
4411
|
+
children: /* @__PURE__ */ o(U, { children: [/* @__PURE__ */ a(ns, {
|
|
4344
4412
|
asChild: !0,
|
|
4345
4413
|
children: /* @__PURE__ */ o(W, {
|
|
4346
4414
|
tooltip: t.title,
|
|
@@ -4356,7 +4424,7 @@ function es({ items: t }) {
|
|
|
4356
4424
|
})]
|
|
4357
4425
|
}), /* @__PURE__ */ a(u, { className: "mr-auto transition-transform duration-200 group-data-[state=open]/collapsible:-rotate-90" })]
|
|
4358
4426
|
})
|
|
4359
|
-
}), /* @__PURE__ */ a(
|
|
4427
|
+
}), /* @__PURE__ */ a(rs, { children: /* @__PURE__ */ a(Ii, { children: n.map((t) => /* @__PURE__ */ o(Oe, { children: [/* @__PURE__ */ a(Li, { children: /* @__PURE__ */ a(Ri, {
|
|
4360
4428
|
asChild: !0,
|
|
4361
4429
|
children: /* @__PURE__ */ a(e, {
|
|
4362
4430
|
to: t.url,
|
|
@@ -4394,11 +4462,11 @@ function es({ items: t }) {
|
|
|
4394
4462
|
}
|
|
4395
4463
|
//#endregion
|
|
4396
4464
|
//#region src/components/custom/theme/themeProvider.tsx
|
|
4397
|
-
var
|
|
4465
|
+
var as = ke({
|
|
4398
4466
|
theme: "system",
|
|
4399
4467
|
setTheme: () => null
|
|
4400
4468
|
});
|
|
4401
|
-
function
|
|
4469
|
+
function os({ children: e, defaultTheme: t = "system", storageKey: n = "yusr-theme", ...r }) {
|
|
4402
4470
|
let [i, o] = x(t), [s, c] = x(!1);
|
|
4403
4471
|
je(() => {
|
|
4404
4472
|
c(!0);
|
|
@@ -4420,24 +4488,24 @@ function ns({ children: e, defaultTheme: t = "system", storageKey: n = "yusr-the
|
|
|
4420
4488
|
localStorage.setItem(n, e), o(e);
|
|
4421
4489
|
}
|
|
4422
4490
|
};
|
|
4423
|
-
return /* @__PURE__ */ a(
|
|
4491
|
+
return /* @__PURE__ */ a(as.Provider, {
|
|
4424
4492
|
...r,
|
|
4425
4493
|
value: l,
|
|
4426
4494
|
children: e
|
|
4427
4495
|
});
|
|
4428
4496
|
}
|
|
4429
|
-
var
|
|
4430
|
-
let e = Ae(
|
|
4497
|
+
var ss = () => {
|
|
4498
|
+
let e = Ae(as);
|
|
4431
4499
|
if (e === void 0) throw Error("useTheme must be used within a ThemeProvider");
|
|
4432
4500
|
return e;
|
|
4433
4501
|
};
|
|
4434
4502
|
//#endregion
|
|
4435
4503
|
//#region src/components/custom/theme/themeToggle.tsx
|
|
4436
|
-
function
|
|
4437
|
-
let { setTheme: t } =
|
|
4438
|
-
return /* @__PURE__ */ o(
|
|
4504
|
+
function cs({ variant: e = "icon" }) {
|
|
4505
|
+
let { setTheme: t } = ss();
|
|
4506
|
+
return /* @__PURE__ */ o(Pr, {
|
|
4439
4507
|
dir: "rtl",
|
|
4440
|
-
children: [/* @__PURE__ */ a(
|
|
4508
|
+
children: [/* @__PURE__ */ a(Ir, {
|
|
4441
4509
|
asChild: !0,
|
|
4442
4510
|
children: e === "sidebar" ? /* @__PURE__ */ o(W, {
|
|
4443
4511
|
className: "w-full justify-start gap-3 px-3",
|
|
@@ -4461,7 +4529,7 @@ function is({ variant: e = "icon" }) {
|
|
|
4461
4529
|
})
|
|
4462
4530
|
]
|
|
4463
4531
|
})
|
|
4464
|
-
}), /* @__PURE__ */ o(
|
|
4532
|
+
}), /* @__PURE__ */ o(Lr, {
|
|
4465
4533
|
align: "end",
|
|
4466
4534
|
children: [
|
|
4467
4535
|
/* @__PURE__ */ a(B, {
|
|
@@ -4482,10 +4550,10 @@ function is({ variant: e = "icon" }) {
|
|
|
4482
4550
|
}
|
|
4483
4551
|
//#endregion
|
|
4484
4552
|
//#region src/components/custom/sideBar/sideBarSecondaryMenu.tsx
|
|
4485
|
-
function
|
|
4486
|
-
return /* @__PURE__ */ a(
|
|
4553
|
+
function ls({ items: e, onLogout: t, LinkComponent: n = "a", ...r }) {
|
|
4554
|
+
return /* @__PURE__ */ a(Oi, {
|
|
4487
4555
|
...r,
|
|
4488
|
-
children: /* @__PURE__ */ a(
|
|
4556
|
+
children: /* @__PURE__ */ a(ji, { children: /* @__PURE__ */ o(H, { children: [
|
|
4489
4557
|
e.map((e) => /* @__PURE__ */ a(U, { children: /* @__PURE__ */ a(W, {
|
|
4490
4558
|
asChild: !0,
|
|
4491
4559
|
children: /* @__PURE__ */ o(n, {
|
|
@@ -4500,7 +4568,7 @@ function as({ items: e, onLogout: t, LinkComponent: n = "a", ...r }) {
|
|
|
4500
4568
|
})]
|
|
4501
4569
|
})
|
|
4502
4570
|
}) }, e.title)),
|
|
4503
|
-
/* @__PURE__ */ a(U, { children: /* @__PURE__ */ a(
|
|
4571
|
+
/* @__PURE__ */ a(U, { children: /* @__PURE__ */ a(cs, { variant: "sidebar" }) }),
|
|
4504
4572
|
/* @__PURE__ */ a(U, { children: /* @__PURE__ */ a(W, {
|
|
4505
4573
|
asChild: !0,
|
|
4506
4574
|
onClick: t,
|
|
@@ -4520,16 +4588,16 @@ function as({ items: e, onLogout: t, LinkComponent: n = "a", ...r }) {
|
|
|
4520
4588
|
}
|
|
4521
4589
|
//#endregion
|
|
4522
4590
|
//#region src/components/custom/sideBar/sideBarUserData.tsx
|
|
4523
|
-
function
|
|
4591
|
+
function us({ user: e }) {
|
|
4524
4592
|
return /* @__PURE__ */ a(H, { children: /* @__PURE__ */ a(U, { children: /* @__PURE__ */ o(W, {
|
|
4525
4593
|
size: "lg",
|
|
4526
4594
|
className: "data-[state=open]:bg-sidebar-accent data-[state=open]:text-sidebar-accent-foreground",
|
|
4527
|
-
children: [/* @__PURE__ */ o(
|
|
4595
|
+
children: [/* @__PURE__ */ o(aa, {
|
|
4528
4596
|
className: "h-8 w-8 rounded-lg grayscale",
|
|
4529
|
-
children: [/* @__PURE__ */ a(
|
|
4597
|
+
children: [/* @__PURE__ */ a(oa, {
|
|
4530
4598
|
src: "/avatars/shadcn.jpg",
|
|
4531
4599
|
alt: e?.username
|
|
4532
|
-
}), /* @__PURE__ */ a(
|
|
4600
|
+
}), /* @__PURE__ */ a(sa, {
|
|
4533
4601
|
className: "rounded-lg",
|
|
4534
4602
|
children: "YSR"
|
|
4535
4603
|
})]
|
|
@@ -4544,25 +4612,25 @@ function os({ user: e }) {
|
|
|
4544
4612
|
}
|
|
4545
4613
|
//#endregion
|
|
4546
4614
|
//#region src/hooks/useSidebarContext.tsx
|
|
4547
|
-
var
|
|
4548
|
-
let e = Ae(
|
|
4615
|
+
var ds = ke(null), fs = () => {
|
|
4616
|
+
let e = Ae(ds);
|
|
4549
4617
|
if (!e) throw Error("useSidebarContext must be used within a SidebarProvider");
|
|
4550
4618
|
return e;
|
|
4551
4619
|
};
|
|
4552
4620
|
//#endregion
|
|
4553
4621
|
//#region src/components/custom/sideBar/yusrSideBarMainMenu.tsx
|
|
4554
|
-
function
|
|
4555
|
-
return /* @__PURE__ */ a(
|
|
4622
|
+
function ps({ items: e, LinkComponent: t = "a" }) {
|
|
4623
|
+
return /* @__PURE__ */ a(Oi, {
|
|
4556
4624
|
className: "mt-5",
|
|
4557
|
-
children: /* @__PURE__ */ a(
|
|
4625
|
+
children: /* @__PURE__ */ a(ji, { children: /* @__PURE__ */ a(H, { children: e.map((e) => {
|
|
4558
4626
|
if (!e.hasAuth) return null;
|
|
4559
4627
|
if (e.subItems && e.subItems.length > 0) {
|
|
4560
4628
|
let n = e.subItems.filter((e) => e.hasAuth);
|
|
4561
|
-
return n.length === 0 ? null : /* @__PURE__ */ a(
|
|
4629
|
+
return n.length === 0 ? null : /* @__PURE__ */ a(ts, {
|
|
4562
4630
|
asChild: !0,
|
|
4563
4631
|
defaultOpen: !1,
|
|
4564
4632
|
className: "group/collapsible",
|
|
4565
|
-
children: /* @__PURE__ */ o(U, { children: [/* @__PURE__ */ a(
|
|
4633
|
+
children: /* @__PURE__ */ o(U, { children: [/* @__PURE__ */ a(ns, {
|
|
4566
4634
|
asChild: !0,
|
|
4567
4635
|
children: /* @__PURE__ */ o(W, {
|
|
4568
4636
|
tooltip: e.title,
|
|
@@ -4578,7 +4646,7 @@ function ls({ items: e, LinkComponent: t = "a" }) {
|
|
|
4578
4646
|
})]
|
|
4579
4647
|
}), /* @__PURE__ */ a(f, { className: "ml-auto transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90" })]
|
|
4580
4648
|
})
|
|
4581
|
-
}), /* @__PURE__ */ a(
|
|
4649
|
+
}), /* @__PURE__ */ a(rs, { children: /* @__PURE__ */ a(Ii, { children: n.map((e) => /* @__PURE__ */ a(Li, { children: /* @__PURE__ */ a(Ri, {
|
|
4582
4650
|
asChild: !0,
|
|
4583
4651
|
children: /* @__PURE__ */ a(t, {
|
|
4584
4652
|
href: e.url,
|
|
@@ -4607,11 +4675,11 @@ function ls({ items: e, LinkComponent: t = "a" }) {
|
|
|
4607
4675
|
}
|
|
4608
4676
|
//#endregion
|
|
4609
4677
|
//#region src/components/custom/sideBar/yusrSideBar.tsx
|
|
4610
|
-
function
|
|
4678
|
+
function ms({ LinkComponent: e = "a", logos: t, displayCompany: n = {
|
|
4611
4679
|
name: "Yusr UI",
|
|
4612
4680
|
logo: "/yusr-logo.png"
|
|
4613
4681
|
}, navMain: r, navSecondary: i, children: o, ...s }) {
|
|
4614
|
-
return /* @__PURE__ */ a(
|
|
4682
|
+
return /* @__PURE__ */ a(ds.Provider, {
|
|
4615
4683
|
value: {
|
|
4616
4684
|
LinkComponent: e,
|
|
4617
4685
|
logos: t,
|
|
@@ -4619,7 +4687,7 @@ function us({ LinkComponent: e = "a", logos: t, displayCompany: n = {
|
|
|
4619
4687
|
navMain: r,
|
|
4620
4688
|
navSecondary: i
|
|
4621
4689
|
},
|
|
4622
|
-
children: /* @__PURE__ */ a(
|
|
4690
|
+
children: /* @__PURE__ */ a(vi, { children: /* @__PURE__ */ a(yi, {
|
|
4623
4691
|
collapsible: "icon",
|
|
4624
4692
|
side: "right",
|
|
4625
4693
|
...s,
|
|
@@ -4627,9 +4695,9 @@ function us({ LinkComponent: e = "a", logos: t, displayCompany: n = {
|
|
|
4627
4695
|
}) })
|
|
4628
4696
|
});
|
|
4629
4697
|
}
|
|
4630
|
-
|
|
4631
|
-
let { displayCompany: e, logos: t } =
|
|
4632
|
-
return /* @__PURE__ */ a(
|
|
4698
|
+
ms.Header = function() {
|
|
4699
|
+
let { displayCompany: e, logos: t } = fs();
|
|
4700
|
+
return /* @__PURE__ */ a(wi, { children: /* @__PURE__ */ a(H, { children: /* @__PURE__ */ o(U, { children: [/* @__PURE__ */ a(es, { logos: {
|
|
4633
4701
|
full: {
|
|
4634
4702
|
light: t.logoFullLight,
|
|
4635
4703
|
dark: t.logoFullDark
|
|
@@ -4638,24 +4706,24 @@ us.Header = function() {
|
|
|
4638
4706
|
light: t.logoOnlyLight,
|
|
4639
4707
|
dark: t.logoOnlyDark
|
|
4640
4708
|
}
|
|
4641
|
-
} }), e && /* @__PURE__ */ a(
|
|
4642
|
-
},
|
|
4643
|
-
let { navMain: t, navSecondary: n, LinkComponent: r } =
|
|
4644
|
-
return !t || !n ? /* @__PURE__ */ a(
|
|
4709
|
+
} }), e && /* @__PURE__ */ a($o, { company: e })] }) }) });
|
|
4710
|
+
}, ms.Content = function({ LogoutHandler: e }) {
|
|
4711
|
+
let { navMain: t, navSecondary: n, LinkComponent: r } = fs();
|
|
4712
|
+
return !t || !n ? /* @__PURE__ */ a(Di, {}) : /* @__PURE__ */ o(Di, { children: [/* @__PURE__ */ a(ps, {
|
|
4645
4713
|
items: t,
|
|
4646
4714
|
LinkComponent: r
|
|
4647
|
-
}), e !== void 0 && /* @__PURE__ */ a(
|
|
4715
|
+
}), e !== void 0 && /* @__PURE__ */ a(ls, {
|
|
4648
4716
|
items: n,
|
|
4649
4717
|
className: "pt-10 mt-auto text-center",
|
|
4650
4718
|
onLogout: e,
|
|
4651
4719
|
LinkComponent: r
|
|
4652
4720
|
})] });
|
|
4653
|
-
},
|
|
4654
|
-
return /* @__PURE__ */ a(
|
|
4721
|
+
}, ms.Footer = function({ loggedInUser: e = void 0 }) {
|
|
4722
|
+
return /* @__PURE__ */ a(Ti, { children: /* @__PURE__ */ a(us, { user: e }) });
|
|
4655
4723
|
};
|
|
4656
4724
|
//#endregion
|
|
4657
4725
|
//#region src/components/custom/status/loading.tsx
|
|
4658
|
-
function
|
|
4726
|
+
function hs({ entityName: e }) {
|
|
4659
4727
|
return /* @__PURE__ */ o("div", {
|
|
4660
4728
|
className: "sm:max-w-xl flex flex-col items-center justify-center py-20",
|
|
4661
4729
|
children: [/* @__PURE__ */ a(re, { className: "h-10 w-10 animate-spin text-primary" }), /* @__PURE__ */ o("p", {
|
|
@@ -4670,7 +4738,7 @@ function ds({ entityName: e }) {
|
|
|
4670
4738
|
}
|
|
4671
4739
|
//#endregion
|
|
4672
4740
|
//#region src/hooks/useDialog.ts
|
|
4673
|
-
function
|
|
4741
|
+
function gs() {
|
|
4674
4742
|
let [e, t] = x(null), [n, r] = x(!1), [i, a] = x(!1);
|
|
4675
4743
|
return {
|
|
4676
4744
|
selectedRow: e,
|
|
@@ -4688,7 +4756,7 @@ function fs() {
|
|
|
4688
4756
|
}
|
|
4689
4757
|
//#endregion
|
|
4690
4758
|
//#region src/hooks/useDynamicList.ts
|
|
4691
|
-
function
|
|
4759
|
+
function _s(e, t, n) {
|
|
4692
4760
|
return {
|
|
4693
4761
|
addRow: b((r) => {
|
|
4694
4762
|
t((t) => ({
|
|
@@ -4736,7 +4804,7 @@ function ps(e, t, n) {
|
|
|
4736
4804
|
}
|
|
4737
4805
|
//#endregion
|
|
4738
4806
|
//#region src/hooks/useFormValidation.ts
|
|
4739
|
-
function
|
|
4807
|
+
function vs(e, t) {
|
|
4740
4808
|
let [n, r] = x({}), i = (e) => n[e], a = (e) => !!n[e];
|
|
4741
4809
|
return {
|
|
4742
4810
|
errors: n,
|
|
@@ -4766,10 +4834,10 @@ function ms(e, t) {
|
|
|
4766
4834
|
}
|
|
4767
4835
|
//#endregion
|
|
4768
4836
|
//#region src/hooks/useEntityForm.ts
|
|
4769
|
-
function
|
|
4837
|
+
function ys(e, t) {
|
|
4770
4838
|
let [n, r] = x({ ...e }), [i, a] = x(e);
|
|
4771
4839
|
e !== i && (r({ ...e }), a(e));
|
|
4772
|
-
let o =
|
|
4840
|
+
let o = vs(n, t);
|
|
4773
4841
|
return {
|
|
4774
4842
|
formData: n,
|
|
4775
4843
|
handleChange: b((e) => {
|
|
@@ -4788,7 +4856,7 @@ function hs(e, t) {
|
|
|
4788
4856
|
}
|
|
4789
4857
|
//#endregion
|
|
4790
4858
|
//#region src/hooks/useLightBox.ts
|
|
4791
|
-
function
|
|
4859
|
+
function bs() {
|
|
4792
4860
|
let [e, t] = x(null);
|
|
4793
4861
|
return {
|
|
4794
4862
|
lightbox: e,
|
|
@@ -4804,7 +4872,7 @@ function gs() {
|
|
|
4804
4872
|
}
|
|
4805
4873
|
//#endregion
|
|
4806
4874
|
//#region src/hooks/useStorageFile.ts
|
|
4807
|
-
function
|
|
4875
|
+
function xs(e, t) {
|
|
4808
4876
|
let n = Ne(null), r = async (r) => {
|
|
4809
4877
|
let i = Array.from(r.target.files || []);
|
|
4810
4878
|
if (i.length === 0) return;
|
|
@@ -4890,7 +4958,7 @@ function _s(e, t) {
|
|
|
4890
4958
|
}
|
|
4891
4959
|
//#endregion
|
|
4892
4960
|
//#region src/state/authListener.ts
|
|
4893
|
-
var
|
|
4961
|
+
var Ss = (e, t) => {
|
|
4894
4962
|
window.addEventListener("storage", (n) => {
|
|
4895
4963
|
n.key === rt.AuthCheckStorageItemName && e(t.syncFromStorage());
|
|
4896
4964
|
}), window.addEventListener(rt.UnauthorizedEventName, () => {
|
|
@@ -4899,7 +4967,7 @@ var vs = (e, t) => {
|
|
|
4899
4967
|
};
|
|
4900
4968
|
//#endregion
|
|
4901
4969
|
//#region src/state/generics/genericDialogSlice.ts
|
|
4902
|
-
function
|
|
4970
|
+
function Cs(e) {
|
|
4903
4971
|
return ot({
|
|
4904
4972
|
name: e,
|
|
4905
4973
|
initialState: {
|
|
@@ -4925,7 +4993,7 @@ function ys(e) {
|
|
|
4925
4993
|
}
|
|
4926
4994
|
//#endregion
|
|
4927
4995
|
//#region ../../node_modules/immer/dist/immer.mjs
|
|
4928
|
-
var
|
|
4996
|
+
var ws = Symbol.for("immer-nothing"), Ts = Symbol.for("immer-draftable"), G = Symbol.for("immer-state"), Es = process.env.NODE_ENV === "production" ? [] : [
|
|
4929
4997
|
function(e) {
|
|
4930
4998
|
return `The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`;
|
|
4931
4999
|
},
|
|
@@ -4955,63 +5023,63 @@ var bs = Symbol.for("immer-nothing"), xs = Symbol.for("immer-draftable"), G = Sy
|
|
|
4955
5023
|
];
|
|
4956
5024
|
function K(e, ...t) {
|
|
4957
5025
|
if (process.env.NODE_ENV !== "production") {
|
|
4958
|
-
let n =
|
|
5026
|
+
let n = Es[e], r = Z(n) ? n.apply(null, t) : n;
|
|
4959
5027
|
throw Error(`[Immer] ${r}`);
|
|
4960
5028
|
}
|
|
4961
5029
|
throw Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`);
|
|
4962
5030
|
}
|
|
4963
|
-
var q = Object, J = q.getPrototypeOf,
|
|
5031
|
+
var q = Object, J = q.getPrototypeOf, Ds = "constructor", Os = "prototype", ks = "configurable", As = "enumerable", js = "writable", Ms = "value", Y = (e) => !!e && !!e[G];
|
|
4964
5032
|
function X(e) {
|
|
4965
|
-
return e ?
|
|
5033
|
+
return e ? Fs(e) || Hs(e) || !!e[Ts] || !!e[Ds]?.[Ts] || Us(e) || Ws(e) : !1;
|
|
4966
5034
|
}
|
|
4967
|
-
var
|
|
4968
|
-
function
|
|
4969
|
-
if (!e || !
|
|
5035
|
+
var Ns = q[Os][Ds].toString(), Ps = /* @__PURE__ */ new WeakMap();
|
|
5036
|
+
function Fs(e) {
|
|
5037
|
+
if (!e || !Gs(e)) return !1;
|
|
4970
5038
|
let t = J(e);
|
|
4971
|
-
if (t === null || t === q[
|
|
4972
|
-
let n = q.hasOwnProperty.call(t,
|
|
5039
|
+
if (t === null || t === q[Os]) return !0;
|
|
5040
|
+
let n = q.hasOwnProperty.call(t, Ds) && t[Ds];
|
|
4973
5041
|
if (n === Object) return !0;
|
|
4974
5042
|
if (!Z(n)) return !1;
|
|
4975
|
-
let r =
|
|
4976
|
-
return r === void 0 && (r = Function.toString.call(n),
|
|
5043
|
+
let r = Ps.get(n);
|
|
5044
|
+
return r === void 0 && (r = Function.toString.call(n), Ps.set(n, r)), r === Ns;
|
|
4977
5045
|
}
|
|
4978
|
-
function
|
|
4979
|
-
|
|
5046
|
+
function Is(e, t, n = !0) {
|
|
5047
|
+
Ls(e) === 0 ? (n ? Reflect.ownKeys(e) : q.keys(e)).forEach((n) => {
|
|
4980
5048
|
t(n, e[n], e);
|
|
4981
5049
|
}) : e.forEach((n, r) => t(r, n, e));
|
|
4982
5050
|
}
|
|
4983
|
-
function
|
|
5051
|
+
function Ls(e) {
|
|
4984
5052
|
let t = e[G];
|
|
4985
|
-
return t ? t.type_ :
|
|
5053
|
+
return t ? t.type_ : Hs(e) ? 1 : Us(e) ? 2 : Ws(e) ? 3 : 0;
|
|
4986
5054
|
}
|
|
4987
|
-
var
|
|
5055
|
+
var Rs = (e, t, n = Ls(e)) => n === 2 ? e.has(t) : q[Os].hasOwnProperty.call(e, t), zs = (e, t, n = Ls(e)) => n === 2 ? e.get(t) : e[t], Bs = (e, t, n, r = Ls(e)) => {
|
|
4988
5056
|
r === 2 ? e.set(t, n) : r === 3 ? e.add(n) : e[t] = n;
|
|
4989
5057
|
};
|
|
4990
|
-
function
|
|
5058
|
+
function Vs(e, t) {
|
|
4991
5059
|
return e === t ? e !== 0 || 1 / e == 1 / t : e !== e && t !== t;
|
|
4992
5060
|
}
|
|
4993
|
-
var
|
|
4994
|
-
function
|
|
5061
|
+
var Hs = Array.isArray, Us = (e) => e instanceof Map, Ws = (e) => e instanceof Set, Gs = (e) => typeof e == "object", Z = (e) => typeof e == "function", Ks = (e) => typeof e == "boolean";
|
|
5062
|
+
function qs(e) {
|
|
4995
5063
|
let t = +e;
|
|
4996
5064
|
return Number.isInteger(t) && String(t) === e;
|
|
4997
5065
|
}
|
|
4998
|
-
var Q = (e) => e.copy_ || e.base_,
|
|
4999
|
-
function
|
|
5000
|
-
if (
|
|
5001
|
-
if (
|
|
5002
|
-
if (
|
|
5003
|
-
let n =
|
|
5066
|
+
var Q = (e) => e.copy_ || e.base_, Js = (e) => e.modified_ ? e.copy_ : e.base_;
|
|
5067
|
+
function Ys(e, t) {
|
|
5068
|
+
if (Us(e)) return new Map(e);
|
|
5069
|
+
if (Ws(e)) return new Set(e);
|
|
5070
|
+
if (Hs(e)) return Array[Os].slice.call(e);
|
|
5071
|
+
let n = Fs(e);
|
|
5004
5072
|
if (t === !0 || t === "class_only" && !n) {
|
|
5005
5073
|
let t = q.getOwnPropertyDescriptors(e);
|
|
5006
5074
|
delete t[G];
|
|
5007
5075
|
let n = Reflect.ownKeys(t);
|
|
5008
5076
|
for (let r = 0; r < n.length; r++) {
|
|
5009
5077
|
let i = n[r], a = t[i];
|
|
5010
|
-
a[
|
|
5011
|
-
[
|
|
5012
|
-
[
|
|
5013
|
-
[
|
|
5014
|
-
[
|
|
5078
|
+
a[js] === !1 && (a[js] = !0, a[ks] = !0), (a.get || a.set) && (t[i] = {
|
|
5079
|
+
[ks]: !0,
|
|
5080
|
+
[js]: !0,
|
|
5081
|
+
[As]: a[As],
|
|
5082
|
+
[Ms]: e[i]
|
|
5015
5083
|
});
|
|
5016
5084
|
}
|
|
5017
5085
|
return q.create(J(e), t);
|
|
@@ -5022,29 +5090,29 @@ function Gs(e, t) {
|
|
|
5022
5090
|
return q.assign(r, e);
|
|
5023
5091
|
}
|
|
5024
5092
|
}
|
|
5025
|
-
function
|
|
5026
|
-
return
|
|
5027
|
-
set:
|
|
5028
|
-
add:
|
|
5029
|
-
clear:
|
|
5030
|
-
delete:
|
|
5031
|
-
}), q.freeze(e), t &&
|
|
5032
|
-
|
|
5093
|
+
function Xs(e, t = !1) {
|
|
5094
|
+
return $s(e) || Y(e) || !X(e) ? e : (Ls(e) > 1 && q.defineProperties(e, {
|
|
5095
|
+
set: Qs,
|
|
5096
|
+
add: Qs,
|
|
5097
|
+
clear: Qs,
|
|
5098
|
+
delete: Qs
|
|
5099
|
+
}), q.freeze(e), t && Is(e, (e, t) => {
|
|
5100
|
+
Xs(t, !0);
|
|
5033
5101
|
}, !1), e);
|
|
5034
5102
|
}
|
|
5035
|
-
function
|
|
5103
|
+
function Zs() {
|
|
5036
5104
|
K(2);
|
|
5037
5105
|
}
|
|
5038
|
-
var
|
|
5039
|
-
function
|
|
5040
|
-
return e === null || !
|
|
5106
|
+
var Qs = { [Ms]: Zs };
|
|
5107
|
+
function $s(e) {
|
|
5108
|
+
return e === null || !Gs(e) ? !0 : q.isFrozen(e);
|
|
5041
5109
|
}
|
|
5042
|
-
var
|
|
5110
|
+
var ec = "MapSet", tc = "Patches", nc = "ArrayMethods", rc = {};
|
|
5043
5111
|
function $(e) {
|
|
5044
|
-
let t =
|
|
5112
|
+
let t = rc[e];
|
|
5045
5113
|
return t || K(0, e), t;
|
|
5046
5114
|
}
|
|
5047
|
-
var
|
|
5115
|
+
var ic = (e) => !!rc[e], ac, oc = () => ac, sc = (e, t) => ({
|
|
5048
5116
|
drafts_: [],
|
|
5049
5117
|
parent_: e,
|
|
5050
5118
|
immer_: t,
|
|
@@ -5052,114 +5120,114 @@ var ec = (e) => !!$s[e], tc, nc = () => tc, rc = (e, t) => ({
|
|
|
5052
5120
|
unfinalizedDrafts_: 0,
|
|
5053
5121
|
handledSet_: /* @__PURE__ */ new Set(),
|
|
5054
5122
|
processedForPatches_: /* @__PURE__ */ new Set(),
|
|
5055
|
-
mapSetPlugin_: ec
|
|
5056
|
-
arrayMethodsPlugin_:
|
|
5123
|
+
mapSetPlugin_: ic(ec) ? $(ec) : void 0,
|
|
5124
|
+
arrayMethodsPlugin_: ic(nc) ? $(nc) : void 0
|
|
5057
5125
|
});
|
|
5058
|
-
function
|
|
5059
|
-
t && (e.patchPlugin_ = $(
|
|
5126
|
+
function cc(e, t) {
|
|
5127
|
+
t && (e.patchPlugin_ = $(tc), e.patches_ = [], e.inversePatches_ = [], e.patchListener_ = t);
|
|
5060
5128
|
}
|
|
5061
|
-
function
|
|
5062
|
-
|
|
5129
|
+
function lc(e) {
|
|
5130
|
+
uc(e), e.drafts_.forEach(fc), e.drafts_ = null;
|
|
5063
5131
|
}
|
|
5064
|
-
function
|
|
5065
|
-
e ===
|
|
5132
|
+
function uc(e) {
|
|
5133
|
+
e === ac && (ac = e.parent_);
|
|
5066
5134
|
}
|
|
5067
|
-
var
|
|
5068
|
-
function
|
|
5135
|
+
var dc = (e) => ac = sc(ac, e);
|
|
5136
|
+
function fc(e) {
|
|
5069
5137
|
let t = e[G];
|
|
5070
5138
|
t.type_ === 0 || t.type_ === 1 ? t.revoke_() : t.revoked_ = !0;
|
|
5071
5139
|
}
|
|
5072
|
-
function
|
|
5140
|
+
function pc(e, t) {
|
|
5073
5141
|
t.unfinalizedDrafts_ = t.drafts_.length;
|
|
5074
5142
|
let n = t.drafts_[0];
|
|
5075
5143
|
if (e !== void 0 && e !== n) {
|
|
5076
|
-
n[G].modified_ && (
|
|
5144
|
+
n[G].modified_ && (lc(t), K(4)), X(e) && (e = mc(t, e));
|
|
5077
5145
|
let { patchPlugin_: r } = t;
|
|
5078
5146
|
r && r.generateReplacementPatches_(n[G].base_, e, t);
|
|
5079
|
-
} else e =
|
|
5080
|
-
return
|
|
5147
|
+
} else e = mc(t, n);
|
|
5148
|
+
return hc(t, e, !0), lc(t), t.patches_ && t.patchListener_(t.patches_, t.inversePatches_), e === ws ? void 0 : e;
|
|
5081
5149
|
}
|
|
5082
|
-
function
|
|
5083
|
-
if (
|
|
5150
|
+
function mc(e, t) {
|
|
5151
|
+
if ($s(t)) return t;
|
|
5084
5152
|
let n = t[G];
|
|
5085
|
-
if (!n) return
|
|
5086
|
-
if (!
|
|
5153
|
+
if (!n) return Cc(t, e.handledSet_, e);
|
|
5154
|
+
if (!_c(n, e)) return t;
|
|
5087
5155
|
if (!n.modified_) return n.base_;
|
|
5088
5156
|
if (!n.finalized_) {
|
|
5089
5157
|
let { callbacks_: t } = n;
|
|
5090
5158
|
if (t) for (; t.length > 0;) t.pop()(e);
|
|
5091
|
-
|
|
5159
|
+
xc(n, e);
|
|
5092
5160
|
}
|
|
5093
5161
|
return n.copy_;
|
|
5094
5162
|
}
|
|
5095
|
-
function
|
|
5096
|
-
!e.parent_ && e.immer_.autoFreeze_ && e.canAutoFreeze_ &&
|
|
5163
|
+
function hc(e, t, n = !1) {
|
|
5164
|
+
!e.parent_ && e.immer_.autoFreeze_ && e.canAutoFreeze_ && Xs(t, n);
|
|
5097
5165
|
}
|
|
5098
|
-
function
|
|
5166
|
+
function gc(e) {
|
|
5099
5167
|
e.finalized_ = !0, e.scope_.unfinalizedDrafts_--;
|
|
5100
5168
|
}
|
|
5101
|
-
var
|
|
5102
|
-
function
|
|
5169
|
+
var _c = (e, t) => e.scope_ === t, vc = [];
|
|
5170
|
+
function yc(e, t, n, r) {
|
|
5103
5171
|
let i = Q(e), a = e.type_;
|
|
5104
|
-
if (r !== void 0 &&
|
|
5105
|
-
|
|
5172
|
+
if (r !== void 0 && zs(i, r, a) === t) {
|
|
5173
|
+
Bs(i, r, n, a);
|
|
5106
5174
|
return;
|
|
5107
5175
|
}
|
|
5108
5176
|
if (!e.draftLocations_) {
|
|
5109
5177
|
let t = e.draftLocations_ = /* @__PURE__ */ new Map();
|
|
5110
|
-
|
|
5178
|
+
Is(i, (e, n) => {
|
|
5111
5179
|
if (Y(n)) {
|
|
5112
5180
|
let r = t.get(n) || [];
|
|
5113
5181
|
r.push(e), t.set(n, r);
|
|
5114
5182
|
}
|
|
5115
5183
|
});
|
|
5116
5184
|
}
|
|
5117
|
-
let o = e.draftLocations_.get(t) ??
|
|
5118
|
-
for (let e of o)
|
|
5185
|
+
let o = e.draftLocations_.get(t) ?? vc;
|
|
5186
|
+
for (let e of o) Bs(i, e, n, a);
|
|
5119
5187
|
}
|
|
5120
|
-
function
|
|
5188
|
+
function bc(e, t, n) {
|
|
5121
5189
|
e.callbacks_.push(function(r) {
|
|
5122
5190
|
let i = t;
|
|
5123
|
-
if (!i || !
|
|
5191
|
+
if (!i || !_c(i, r)) return;
|
|
5124
5192
|
r.mapSetPlugin_?.fixSetContents(i);
|
|
5125
|
-
let a =
|
|
5126
|
-
|
|
5193
|
+
let a = Js(i);
|
|
5194
|
+
yc(e, i.draft_ ?? i, a, n), xc(i, r);
|
|
5127
5195
|
});
|
|
5128
5196
|
}
|
|
5129
|
-
function
|
|
5197
|
+
function xc(e, t) {
|
|
5130
5198
|
if (e.modified_ && !e.finalized_ && (e.type_ === 3 || e.type_ === 1 && e.allIndicesReassigned_ || (e.assigned_?.size ?? 0) > 0)) {
|
|
5131
5199
|
let { patchPlugin_: n } = t;
|
|
5132
5200
|
if (n) {
|
|
5133
5201
|
let r = n.getPath(e);
|
|
5134
5202
|
r && n.generatePatches_(e, r, t);
|
|
5135
5203
|
}
|
|
5136
|
-
|
|
5204
|
+
gc(e);
|
|
5137
5205
|
}
|
|
5138
5206
|
}
|
|
5139
|
-
function
|
|
5207
|
+
function Sc(e, t, n) {
|
|
5140
5208
|
let { scope_: r } = e;
|
|
5141
5209
|
if (Y(n)) {
|
|
5142
5210
|
let i = n[G];
|
|
5143
|
-
|
|
5144
|
-
|
|
5211
|
+
_c(i, r) && i.callbacks_.push(function() {
|
|
5212
|
+
jc(e), yc(e, n, Js(i), t);
|
|
5145
5213
|
});
|
|
5146
5214
|
} else X(n) && e.callbacks_.push(function() {
|
|
5147
5215
|
let i = Q(e);
|
|
5148
|
-
e.type_ === 3 ? i.has(n) &&
|
|
5216
|
+
e.type_ === 3 ? i.has(n) && Cc(n, r.handledSet_, r) : zs(i, t, e.type_) === n && r.drafts_.length > 1 && (e.assigned_.get(t) ?? !1) === !0 && e.copy_ && Cc(zs(e.copy_, t, e.type_), r.handledSet_, r);
|
|
5149
5217
|
});
|
|
5150
5218
|
}
|
|
5151
|
-
function
|
|
5152
|
-
return !n.immer_.autoFreeze_ && n.unfinalizedDrafts_ < 1 || Y(e) || t.has(e) || !X(e) ||
|
|
5219
|
+
function Cc(e, t, n) {
|
|
5220
|
+
return !n.immer_.autoFreeze_ && n.unfinalizedDrafts_ < 1 || Y(e) || t.has(e) || !X(e) || $s(e) ? e : (t.add(e), Is(e, (r, i) => {
|
|
5153
5221
|
if (Y(i)) {
|
|
5154
5222
|
let t = i[G];
|
|
5155
|
-
|
|
5156
|
-
} else X(i) &&
|
|
5223
|
+
_c(t, n) && (Bs(e, r, Js(t), e.type_), gc(t));
|
|
5224
|
+
} else X(i) && Cc(i, t, n);
|
|
5157
5225
|
}), e);
|
|
5158
5226
|
}
|
|
5159
|
-
function
|
|
5160
|
-
let n =
|
|
5227
|
+
function wc(e, t) {
|
|
5228
|
+
let n = Hs(e), r = {
|
|
5161
5229
|
type_: n ? 1 : 0,
|
|
5162
|
-
scope_: t ? t.scope_ :
|
|
5230
|
+
scope_: t ? t.scope_ : oc(),
|
|
5163
5231
|
modified_: !1,
|
|
5164
5232
|
finalized_: !1,
|
|
5165
5233
|
assigned_: void 0,
|
|
@@ -5170,23 +5238,23 @@ function bc(e, t) {
|
|
|
5170
5238
|
revoke_: null,
|
|
5171
5239
|
isManual_: !1,
|
|
5172
5240
|
callbacks_: void 0
|
|
5173
|
-
}, i = r, a =
|
|
5174
|
-
n && (i = [r], a =
|
|
5241
|
+
}, i = r, a = Tc;
|
|
5242
|
+
n && (i = [r], a = Ec);
|
|
5175
5243
|
let { revoke: o, proxy: s } = Proxy.revocable(i, a);
|
|
5176
5244
|
return r.draft_ = s, r.revoke_ = o, [s, r];
|
|
5177
5245
|
}
|
|
5178
|
-
var
|
|
5246
|
+
var Tc = {
|
|
5179
5247
|
get(e, t) {
|
|
5180
5248
|
if (t === G) return e;
|
|
5181
5249
|
let n = e.scope_.arrayMethodsPlugin_, r = e.type_ === 1 && typeof t == "string";
|
|
5182
5250
|
if (r && n?.isArrayOperationMethod(t)) return n.createMethodInterceptor(e, t);
|
|
5183
5251
|
let i = Q(e);
|
|
5184
|
-
if (!
|
|
5252
|
+
if (!Rs(i, t, e.type_)) return Oc(e, i, t);
|
|
5185
5253
|
let a = i[t];
|
|
5186
|
-
if (e.finalized_ || !X(a) || r && e.operationMethod && n?.isMutatingArrayMethod(e.operationMethod) &&
|
|
5187
|
-
if (a ===
|
|
5188
|
-
|
|
5189
|
-
let n = e.type_ === 1 ? +t : t, r =
|
|
5254
|
+
if (e.finalized_ || !X(a) || r && e.operationMethod && n?.isMutatingArrayMethod(e.operationMethod) && qs(t)) return a;
|
|
5255
|
+
if (a === Dc(e.base_, t)) {
|
|
5256
|
+
jc(e);
|
|
5257
|
+
let n = e.type_ === 1 ? +t : t, r = Nc(e.scope_, a, e, n);
|
|
5190
5258
|
return e.copy_[n] = r;
|
|
5191
5259
|
}
|
|
5192
5260
|
return a;
|
|
@@ -5198,26 +5266,26 @@ var xc = {
|
|
|
5198
5266
|
return Reflect.ownKeys(Q(e));
|
|
5199
5267
|
},
|
|
5200
5268
|
set(e, t, n) {
|
|
5201
|
-
let r =
|
|
5269
|
+
let r = kc(Q(e), t);
|
|
5202
5270
|
if (r?.set) return r.set.call(e.draft_, n), !0;
|
|
5203
5271
|
if (!e.modified_) {
|
|
5204
|
-
let r =
|
|
5272
|
+
let r = Dc(Q(e), t), i = r?.[G];
|
|
5205
5273
|
if (i && i.base_ === n) return e.copy_[t] = n, e.assigned_.set(t, !1), !0;
|
|
5206
|
-
if (
|
|
5207
|
-
|
|
5274
|
+
if (Vs(n, r) && (n !== void 0 || Rs(e.base_, t, e.type_))) return !0;
|
|
5275
|
+
jc(e), Ac(e);
|
|
5208
5276
|
}
|
|
5209
|
-
return e.copy_[t] === n && (n !== void 0 || t in e.copy_) || Number.isNaN(n) && Number.isNaN(e.copy_[t]) ? !0 : (e.copy_[t] = n, e.assigned_.set(t, !0),
|
|
5277
|
+
return e.copy_[t] === n && (n !== void 0 || t in e.copy_) || Number.isNaN(n) && Number.isNaN(e.copy_[t]) ? !0 : (e.copy_[t] = n, e.assigned_.set(t, !0), Sc(e, t, n), !0);
|
|
5210
5278
|
},
|
|
5211
5279
|
deleteProperty(e, t) {
|
|
5212
|
-
return
|
|
5280
|
+
return jc(e), Dc(e.base_, t) !== void 0 || t in e.base_ ? (e.assigned_.set(t, !1), Ac(e)) : e.assigned_.delete(t), e.copy_ && delete e.copy_[t], !0;
|
|
5213
5281
|
},
|
|
5214
5282
|
getOwnPropertyDescriptor(e, t) {
|
|
5215
5283
|
let n = Q(e), r = Reflect.getOwnPropertyDescriptor(n, t);
|
|
5216
5284
|
return r && {
|
|
5217
|
-
[
|
|
5218
|
-
[
|
|
5219
|
-
[
|
|
5220
|
-
[
|
|
5285
|
+
[js]: !0,
|
|
5286
|
+
[ks]: e.type_ !== 1 || t !== "length",
|
|
5287
|
+
[As]: r[As],
|
|
5288
|
+
[Ms]: n[t]
|
|
5221
5289
|
};
|
|
5222
5290
|
},
|
|
5223
5291
|
defineProperty() {
|
|
@@ -5229,28 +5297,28 @@ var xc = {
|
|
|
5229
5297
|
setPrototypeOf() {
|
|
5230
5298
|
K(12);
|
|
5231
5299
|
}
|
|
5232
|
-
},
|
|
5233
|
-
for (let e in
|
|
5234
|
-
let t =
|
|
5235
|
-
|
|
5300
|
+
}, Ec = {};
|
|
5301
|
+
for (let e in Tc) {
|
|
5302
|
+
let t = Tc[e];
|
|
5303
|
+
Ec[e] = function() {
|
|
5236
5304
|
let e = arguments;
|
|
5237
5305
|
return e[0] = e[0][0], t.apply(this, e);
|
|
5238
5306
|
};
|
|
5239
5307
|
}
|
|
5240
|
-
|
|
5241
|
-
return process.env.NODE_ENV !== "production" && isNaN(parseInt(t)) && K(13),
|
|
5242
|
-
},
|
|
5243
|
-
return process.env.NODE_ENV !== "production" && t !== "length" && isNaN(parseInt(t)) && K(14),
|
|
5308
|
+
Ec.deleteProperty = function(e, t) {
|
|
5309
|
+
return process.env.NODE_ENV !== "production" && isNaN(parseInt(t)) && K(13), Ec.set.call(this, e, t, void 0);
|
|
5310
|
+
}, Ec.set = function(e, t, n) {
|
|
5311
|
+
return process.env.NODE_ENV !== "production" && t !== "length" && isNaN(parseInt(t)) && K(14), Tc.set.call(this, e[0], t, n, e[0]);
|
|
5244
5312
|
};
|
|
5245
|
-
function
|
|
5313
|
+
function Dc(e, t) {
|
|
5246
5314
|
let n = e[G];
|
|
5247
5315
|
return (n ? Q(n) : e)[t];
|
|
5248
5316
|
}
|
|
5249
|
-
function
|
|
5250
|
-
let r =
|
|
5251
|
-
return r ?
|
|
5317
|
+
function Oc(e, t, n) {
|
|
5318
|
+
let r = kc(t, n);
|
|
5319
|
+
return r ? Ms in r ? r[Ms] : r.get?.call(e.draft_) : void 0;
|
|
5252
5320
|
}
|
|
5253
|
-
function
|
|
5321
|
+
function kc(e, t) {
|
|
5254
5322
|
if (!(t in e)) return;
|
|
5255
5323
|
let n = J(e);
|
|
5256
5324
|
for (; n;) {
|
|
@@ -5259,13 +5327,13 @@ function Tc(e, t) {
|
|
|
5259
5327
|
n = J(n);
|
|
5260
5328
|
}
|
|
5261
5329
|
}
|
|
5262
|
-
function
|
|
5263
|
-
e.modified_ || (e.modified_ = !0, e.parent_ &&
|
|
5330
|
+
function Ac(e) {
|
|
5331
|
+
e.modified_ || (e.modified_ = !0, e.parent_ && Ac(e.parent_));
|
|
5264
5332
|
}
|
|
5265
|
-
function
|
|
5266
|
-
e.copy_ ||= (e.assigned_ = /* @__PURE__ */ new Map(),
|
|
5333
|
+
function jc(e) {
|
|
5334
|
+
e.copy_ ||= (e.assigned_ = /* @__PURE__ */ new Map(), Ys(e.base_, e.scope_.immer_.useStrictShallowCopy_));
|
|
5267
5335
|
}
|
|
5268
|
-
var
|
|
5336
|
+
var Mc = class {
|
|
5269
5337
|
constructor(e) {
|
|
5270
5338
|
this.autoFreeze_ = !0, this.useStrictShallowCopy_ = !1, this.useStrictIteration_ = !1, this.produce = (e, t, n) => {
|
|
5271
5339
|
if (Z(e) && !Z(t)) {
|
|
@@ -5279,17 +5347,17 @@ var Oc = class {
|
|
|
5279
5347
|
Z(t) || K(6), n !== void 0 && !Z(n) && K(7);
|
|
5280
5348
|
let r;
|
|
5281
5349
|
if (X(e)) {
|
|
5282
|
-
let i =
|
|
5350
|
+
let i = dc(this), a = Nc(i, e, void 0), o = !0;
|
|
5283
5351
|
try {
|
|
5284
5352
|
r = t(a), o = !1;
|
|
5285
5353
|
} finally {
|
|
5286
|
-
o ?
|
|
5354
|
+
o ? lc(i) : uc(i);
|
|
5287
5355
|
}
|
|
5288
|
-
return
|
|
5289
|
-
} else if (!e || !
|
|
5290
|
-
if (r = t(e), r === void 0 && (r = e), r ===
|
|
5356
|
+
return cc(i, n), pc(r, i);
|
|
5357
|
+
} else if (!e || !Gs(e)) {
|
|
5358
|
+
if (r = t(e), r === void 0 && (r = e), r === ws && (r = void 0), this.autoFreeze_ && Xs(r, !0), n) {
|
|
5291
5359
|
let t = [], i = [];
|
|
5292
|
-
$(
|
|
5360
|
+
$(tc).generateReplacementPatches_(e, r, {
|
|
5293
5361
|
patches_: t,
|
|
5294
5362
|
inversePatches_: i
|
|
5295
5363
|
}), n(t, i);
|
|
@@ -5306,18 +5374,18 @@ var Oc = class {
|
|
|
5306
5374
|
n,
|
|
5307
5375
|
r
|
|
5308
5376
|
];
|
|
5309
|
-
},
|
|
5377
|
+
}, Ks(e?.autoFreeze) && this.setAutoFreeze(e.autoFreeze), Ks(e?.useStrictShallowCopy) && this.setUseStrictShallowCopy(e.useStrictShallowCopy), Ks(e?.useStrictIteration) && this.setUseStrictIteration(e.useStrictIteration);
|
|
5310
5378
|
}
|
|
5311
5379
|
createDraft(e) {
|
|
5312
|
-
X(e) || K(8), Y(e) && (e =
|
|
5313
|
-
let t =
|
|
5314
|
-
return n[G].isManual_ = !0,
|
|
5380
|
+
X(e) || K(8), Y(e) && (e = Pc(e));
|
|
5381
|
+
let t = dc(this), n = Nc(t, e, void 0);
|
|
5382
|
+
return n[G].isManual_ = !0, uc(t), n;
|
|
5315
5383
|
}
|
|
5316
5384
|
finishDraft(e, t) {
|
|
5317
5385
|
let n = e && e[G];
|
|
5318
5386
|
(!n || !n.isManual_) && K(9);
|
|
5319
5387
|
let { scope_: r } = n;
|
|
5320
|
-
return
|
|
5388
|
+
return cc(r, t), pc(void 0, r);
|
|
5321
5389
|
}
|
|
5322
5390
|
setAutoFreeze(e) {
|
|
5323
5391
|
this.autoFreeze_ = e;
|
|
@@ -5341,37 +5409,37 @@ var Oc = class {
|
|
|
5341
5409
|
}
|
|
5342
5410
|
}
|
|
5343
5411
|
n > -1 && (t = t.slice(n + 1));
|
|
5344
|
-
let r = $(
|
|
5412
|
+
let r = $(tc).applyPatches_;
|
|
5345
5413
|
return Y(e) ? r(e, t) : this.produce(e, (e) => r(e, t));
|
|
5346
5414
|
}
|
|
5347
5415
|
};
|
|
5348
|
-
function
|
|
5349
|
-
let [i, a] =
|
|
5350
|
-
return (n?.scope_ ??
|
|
5416
|
+
function Nc(e, t, n, r) {
|
|
5417
|
+
let [i, a] = Us(t) ? $(ec).proxyMap_(t, n) : Ws(t) ? $(ec).proxySet_(t, n) : wc(t, n);
|
|
5418
|
+
return (n?.scope_ ?? oc()).drafts_.push(i), a.callbacks_ = n?.callbacks_ ?? [], a.key_ = r, n && r !== void 0 ? bc(n, a, r) : a.callbacks_.push(function(e) {
|
|
5351
5419
|
e.mapSetPlugin_?.fixSetContents(a);
|
|
5352
5420
|
let { patchPlugin_: t } = e;
|
|
5353
5421
|
a.modified_ && t && t.generatePatches_(a, [], e);
|
|
5354
5422
|
}), i;
|
|
5355
5423
|
}
|
|
5356
|
-
function
|
|
5357
|
-
return Y(e) || K(10, e),
|
|
5424
|
+
function Pc(e) {
|
|
5425
|
+
return Y(e) || K(10, e), Fc(e);
|
|
5358
5426
|
}
|
|
5359
|
-
function
|
|
5360
|
-
if (!X(e) ||
|
|
5427
|
+
function Fc(e) {
|
|
5428
|
+
if (!X(e) || $s(e)) return e;
|
|
5361
5429
|
let t = e[G], n, r = !0;
|
|
5362
5430
|
if (t) {
|
|
5363
5431
|
if (!t.modified_) return t.base_;
|
|
5364
|
-
t.finalized_ = !0, n =
|
|
5365
|
-
} else n =
|
|
5366
|
-
return
|
|
5367
|
-
|
|
5432
|
+
t.finalized_ = !0, n = Ys(e, t.scope_.immer_.useStrictShallowCopy_), r = t.scope_.immer_.shouldUseStrictIteration();
|
|
5433
|
+
} else n = Ys(e, !0);
|
|
5434
|
+
return Is(n, (e, t) => {
|
|
5435
|
+
Bs(n, e, Fc(t));
|
|
5368
5436
|
}, r), t && (t.finalized_ = !1), n;
|
|
5369
5437
|
}
|
|
5370
|
-
new
|
|
5371
|
-
var
|
|
5438
|
+
new Mc().produce;
|
|
5439
|
+
var Ic = (e) => e;
|
|
5372
5440
|
//#endregion
|
|
5373
5441
|
//#region src/state/generics/genericEntitySlice.ts
|
|
5374
|
-
function
|
|
5442
|
+
function Lc(e, t, n, r) {
|
|
5375
5443
|
let i = {
|
|
5376
5444
|
entities: {
|
|
5377
5445
|
data: [],
|
|
@@ -5399,7 +5467,7 @@ function Nc(e, t, n, r) {
|
|
|
5399
5467
|
if (r) --e.entities.count, e.entities.data = e.entities.data?.filter((e) => e.id !== r);
|
|
5400
5468
|
else if (n) {
|
|
5401
5469
|
let t = e.entities.data?.findIndex((e) => e.id === n.id);
|
|
5402
|
-
t !== void 0 && t !== -1 ? e.entities.data && (e.entities.data[t] =
|
|
5470
|
+
t !== void 0 && t !== -1 ? e.entities.data && (e.entities.data[t] = Ic(n)) : (e.entities.count += 1, e.entities.data = [Ic(n), ...e.entities.data ?? []]);
|
|
5403
5471
|
}
|
|
5404
5472
|
},
|
|
5405
5473
|
...r || {}
|
|
@@ -5423,4 +5491,4 @@ function Nc(e, t, n, r) {
|
|
|
5423
5491
|
};
|
|
5424
5492
|
}
|
|
5425
5493
|
//#endregion
|
|
5426
|
-
export {
|
|
5494
|
+
export { ta as Alert, ia as AlertAction, ra as AlertDescription, Hi as AlertDialog, Qi as AlertDialogAction, $i as AlertDialogCancel, Ki as AlertDialogContent, Zi as AlertDialogDescription, Ji as AlertDialogFooter, qi as AlertDialogHeader, Yi as AlertDialogMedia, Gi as AlertDialogOverlay, Wi as AlertDialogPortal, Xi as AlertDialogTitle, Ui as AlertDialogTrigger, na as AlertTitle, aa as Avatar, ca as AvatarBadge, sa as AvatarFallback, la as AvatarGroup, ua as AvatarGroupCount, oa as AvatarImage, fa as Badge, Kt as BaseInput, pa as Breadcrumb, ya as BreadcrumbEllipsis, ha as BreadcrumbItem, ga as BreadcrumbLink, ma as BreadcrumbList, _a as BreadcrumbPage, va as BreadcrumbSeparator, F as Button, Pt as Calendar, Ft as CalendarDayButton, yn as Card, Cn as CardAction, wn as CardContent, Sn as CardDescription, Tn as CardFooter, bn as CardHeader, xn as CardTitle, On as Carousel, kn as CarouselContent, An as CarouselItem, Mn as CarouselNext, jn as CarouselPrevious, xt as ChangeDialog, Ca as ChartContainer, Da as ChartLegend, Oa as ChartLegendContent, wa as ChartStyle, Ta as ChartTooltip, Ea as ChartTooltipContent, Aa as Checkbox, za as Combobox, $a as ComboboxChip, Qa as ComboboxChips, eo as ComboboxChipsInput, Ya as ComboboxCollection, Wa as ComboboxContent, Xa as ComboboxEmpty, qa as ComboboxGroup, Ua as ComboboxInput, Ka as ComboboxItem, Ja as ComboboxLabel, Ga as ComboboxList, Za as ComboboxSeparator, Va as ComboboxTrigger, Ba as ComboboxValue, no as Command, ro as CommandDialog, oo as CommandEmpty, so as CommandGroup, io as CommandInput, lo as CommandItem, ao as CommandList, co as CommandSeparator, uo as CommandShortcut, cr as ContextMenu, vr as ContextMenuCheckboxItem, mr as ContextMenuContent, ur as ContextMenuGroup, hr as ContextMenuItem, br as ContextMenuLabel, dr as ContextMenuPortal, pr as ContextMenuRadioGroup, yr as ContextMenuRadioItem, xr as ContextMenuSeparator, Sr as ContextMenuShortcut, fr as ContextMenuSub, _r as ContextMenuSubContent, gr as ContextMenuSubTrigger, lr as ContextMenuTrigger, rr as CrudEmptyTablePreview, Vi as CrudPage, sr as CrudTable, Cr as CrudTableBodyRow, wr as CrudTableCard, Tr as CrudTableHeader, Er as CrudTableHeaderRows, zi as CrudTablePagination, Bi as CrudTableRowActionsMenu, Gt as DateField, Ut as DateInput, Jt as DateTimeField, qt as DateTimeInput, St as DeleteDialog, I as Dialog, mt as DialogClose, gt as DialogContent, bt as DialogDescription, vt as DialogFooter, _t as DialogHeader, ht as DialogOverlay, pt as DialogPortal, yt as DialogTitle, ft as DialogTrigger, fo as DirectionProvider, mo as Drawer, _o as DrawerClose, yo as DrawerContent, Co as DrawerDescription, xo as DrawerFooter, bo as DrawerHeader, vo as DrawerOverlay, go as DrawerPortal, So as DrawerTitle, ho as DrawerTrigger, Pr as DropdownMenu, zr as DropdownMenuCheckboxItem, Lr as DropdownMenuContent, Rr as DropdownMenuGroup, B as DropdownMenuItem, Hr as DropdownMenuLabel, Fr as DropdownMenuPortal, Br as DropdownMenuRadioGroup, Vr as DropdownMenuRadioItem, Ur as DropdownMenuSeparator, Wr as DropdownMenuShortcut, Gr as DropdownMenuSub, qr as DropdownMenuSubContent, Kr as DropdownMenuSubTrigger, Ir as DropdownMenuTrigger, dt as DynamicListContainer, Xn as Empty, nr as EmptyContent, tr as EmptyDescription, Zn as EmptyHeader, $n as EmptyMedia, er as EmptyTitle, Oo as Field, ko as FieldContent, Mo as FieldDescription, Po as FieldError, Eo as FieldGroup, Ao as FieldLabel, To as FieldLegend, No as FieldSeparator, wo as FieldSet, jo as FieldTitle, en as FieldsSection, R as FormField, z as Input, tn as InputField, ja as InputGroup, Na as InputGroupAddon, Fa as InputGroupButton, La as InputGroupInput, Ia as InputGroupText, Ra as InputGroupTextarea, Wt as Label, zn as Lightbox, hs as Loading, rn as NumberField, nn as NumberInput, Dr as Pagination, Or as PaginationContent, Nr as PaginationEllipsis, kr as PaginationItem, Ar as PaginationLink, Mr as PaginationNext, jr as PaginationPrevious, an as PasswordField, Xo as PermissionCard, Zo as PermissionSkeleton, on as PhoneField, It as Popover, zt as PopoverAnchor, Rt as PopoverContent, Ht as PopoverDescription, Bt as PopoverHeader, Vt as PopoverTitle, Lt as PopoverTrigger, st as ProtectedRoute, ut as SaveButton, Fo as ScrollArea, Io as ScrollBar, Vn as SearchInput, Qo as SearchableSelect, sn as Select, dn as SelectContent, vn as SelectField, cn as SelectGroup, _n as SelectInput, pn as SelectItem, fn as SelectLabel, gn as SelectScrollDownButton, hn as SelectScrollUpButton, mn as SelectSeparator, un as SelectTrigger, ln as SelectValue, L as Separator, Xr as Sheet, Qr as SheetClose, ti as SheetContent, ai as SheetDescription, ri as SheetFooter, ni as SheetHeader, ii as SheetTitle, Zr as SheetTrigger, $o as SideBarCompanyData, is as SideBarMainMenu, ls as SideBarSecondaryMenu, us as SideBarUserData, yi as Sidebar, Di as SidebarContent, ds as SidebarContext, Ti as SidebarFooter, Oi as SidebarGroup, Ai as SidebarGroupAction, ji as SidebarGroupContent, ki as SidebarGroupLabel, wi as SidebarHeader, Ci as SidebarInput, Si as SidebarInset, es as SidebarLogo, H as SidebarMenu, Ni as SidebarMenuAction, Pi as SidebarMenuBadge, W as SidebarMenuButton, U as SidebarMenuItem, Fi as SidebarMenuSkeleton, Ii as SidebarMenuSub, Ri as SidebarMenuSubButton, Li as SidebarMenuSubItem, vi as SidebarProvider, xi as SidebarRail, Ei as SidebarSeparator, bi as SidebarTrigger, V as Skeleton, Pn as StorageFileField, Ro as Switch, Hn as Table, Wn as TableBody, Yn as TableCaption, Jn as TableCell, Gn as TableFooter, qn as TableHead, Un as TableHeader, Kn as TableRow, zo as Tabs, Uo as TabsContent, Vo as TabsList, Ho as TabsTrigger, Ln as TextAreaField, In as TextAreaInput, Rn as TextField, Fn as Textarea, os as ThemeProvider, cs as ThemeToggle, Yt as TitleSeparator, Lo as Toaster, Go as Toggle, qo as ToggleGroup, Jo as ToggleGroupItem, si as Tooltip, li as TooltipContent, oi as TooltipProvider, ci as TooltipTrigger, ct as YusrBusBackground, ms as YusrSideBar, ps as YusrSideBarMainMenu, Bn as ZoomableImage, da as badgeVariants, lt as buttonVariants, Yo as categorizePermissions, P as cn, Cs as createGenericDialogSlice, Lc as createGenericEntitySlice, Nn as isPDF, Ss as setupAuthListeners, Bo as tabsListVariants, Wo as toggleVariants, Dn as useCarousel, to as useComboboxAnchor, gs as useDialog, po as useDirection, _s as useDynamicList, ys as useEntityForm, vs as useFormValidation, Yr as useIsMobile, bs as useLightBox, _i as useSidebar, fs as useSidebarContext, xs as useStorageFile, ss as useTheme };
|