@northslopetech/altitude-ui 3.1.0 → 3.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +14 -11
- package/dist/index.d.ts +14 -11
- package/dist/index.js +252 -223
- package/dist/index.mjs +328 -300
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -255,6 +255,7 @@ __export(index_exports, {
|
|
|
255
255
|
SidebarMenuButton: () => SidebarMenuButton,
|
|
256
256
|
SidebarMenuItem: () => SidebarMenuItem,
|
|
257
257
|
SidebarProvider: () => SidebarProvider,
|
|
258
|
+
SidebarSeparator: () => SidebarSeparator,
|
|
258
259
|
Slider: () => Slider,
|
|
259
260
|
StarIcon: () => StarIcon,
|
|
260
261
|
StatementIcon: () => StatementIcon,
|
|
@@ -329,8 +330,8 @@ __export(index_exports, {
|
|
|
329
330
|
module.exports = __toCommonJS(index_exports);
|
|
330
331
|
|
|
331
332
|
// src/components/ui/alert.tsx
|
|
332
|
-
var
|
|
333
|
-
var
|
|
333
|
+
var React2 = __toESM(require("react"));
|
|
334
|
+
var import_class_variance_authority3 = require("class-variance-authority");
|
|
334
335
|
|
|
335
336
|
// src/lib/utils.ts
|
|
336
337
|
var import_clsx = require("clsx");
|
|
@@ -400,124 +401,6 @@ function cn(...inputs) {
|
|
|
400
401
|
return twMerge((0, import_clsx.clsx)(inputs));
|
|
401
402
|
}
|
|
402
403
|
|
|
403
|
-
// src/components/ui/alert.tsx
|
|
404
|
-
var import_jsx_runtime = require("react/jsx-runtime");
|
|
405
|
-
var alertVariants = (0, import_class_variance_authority2.cva)(
|
|
406
|
-
"relative flex flex-wrap w-full items-center data-[multiline]:items-start gap-4 rounded-md border px-4 py-3 [&>[data-slot=alert-body]>svg]:size-4 [&>[data-slot=alert-body]>svg]:shrink-0",
|
|
407
|
-
{
|
|
408
|
-
variants: {
|
|
409
|
-
variant: {
|
|
410
|
-
default: "surface-default border-default [&>[data-slot=alert-body]>svg]:text-default",
|
|
411
|
-
info: "surface-info border-info [&>[data-slot=alert-body]>svg]:text-info",
|
|
412
|
-
success: "surface-success border-success [&>[data-slot=alert-body]>svg]:text-success",
|
|
413
|
-
warning: "surface-warning border-warning [&>[data-slot=alert-body]>svg]:text-warning",
|
|
414
|
-
error: "surface-error border-error [&>[data-slot=alert-body]>svg]:text-error"
|
|
415
|
-
}
|
|
416
|
-
},
|
|
417
|
-
defaultVariants: {
|
|
418
|
-
variant: "default"
|
|
419
|
-
}
|
|
420
|
-
}
|
|
421
|
-
);
|
|
422
|
-
function Alert({ className, variant, ref, ...props }) {
|
|
423
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
424
|
-
"div",
|
|
425
|
-
{
|
|
426
|
-
ref,
|
|
427
|
-
"data-slot": "alert",
|
|
428
|
-
role: variant === "warning" || variant === "error" ? "alert" : "status",
|
|
429
|
-
className: cn(alertVariants({ variant }), className),
|
|
430
|
-
...props
|
|
431
|
-
}
|
|
432
|
-
);
|
|
433
|
-
}
|
|
434
|
-
function AlertBody({ className, ref, ...props }) {
|
|
435
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
436
|
-
"div",
|
|
437
|
-
{
|
|
438
|
-
ref,
|
|
439
|
-
"data-slot": "alert-body",
|
|
440
|
-
className: cn(
|
|
441
|
-
"grid flex-1 min-w-0 grid-cols-[auto_1fr] gap-x-3 gap-y-0.5 items-start [&>svg]:col-start-1 [&>svg]:row-start-1 [&>svg]:mt-0.5",
|
|
442
|
-
className
|
|
443
|
-
),
|
|
444
|
-
...props
|
|
445
|
-
}
|
|
446
|
-
);
|
|
447
|
-
}
|
|
448
|
-
function AlertTitle({ className, ref, ...props }) {
|
|
449
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
450
|
-
"p",
|
|
451
|
-
{
|
|
452
|
-
ref,
|
|
453
|
-
"data-slot": "alert-title",
|
|
454
|
-
className: cn(
|
|
455
|
-
"col-start-2 row-start-1 type-body-sm-medium text-default",
|
|
456
|
-
className
|
|
457
|
-
),
|
|
458
|
-
...props
|
|
459
|
-
}
|
|
460
|
-
);
|
|
461
|
-
}
|
|
462
|
-
function AlertDescription({
|
|
463
|
-
className,
|
|
464
|
-
ref: externalRef,
|
|
465
|
-
...props
|
|
466
|
-
}) {
|
|
467
|
-
const localRef = React.useRef(null);
|
|
468
|
-
React.useLayoutEffect(() => {
|
|
469
|
-
const el = localRef.current;
|
|
470
|
-
if (!el) return;
|
|
471
|
-
const alert = el.closest("[data-slot=alert]");
|
|
472
|
-
if (!alert) return;
|
|
473
|
-
const update = () => {
|
|
474
|
-
const lineHeight = parseFloat(getComputedStyle(el).lineHeight);
|
|
475
|
-
alert.toggleAttribute(
|
|
476
|
-
"data-multiline",
|
|
477
|
-
el.clientHeight > lineHeight * 1.5
|
|
478
|
-
);
|
|
479
|
-
};
|
|
480
|
-
update();
|
|
481
|
-
const resizeObserver = new ResizeObserver(update);
|
|
482
|
-
resizeObserver.observe(el);
|
|
483
|
-
return () => {
|
|
484
|
-
resizeObserver.disconnect();
|
|
485
|
-
alert.removeAttribute("data-multiline");
|
|
486
|
-
};
|
|
487
|
-
}, []);
|
|
488
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
489
|
-
"p",
|
|
490
|
-
{
|
|
491
|
-
ref: (node) => {
|
|
492
|
-
localRef.current = node;
|
|
493
|
-
if (typeof externalRef === "function") externalRef(node);
|
|
494
|
-
else if (externalRef)
|
|
495
|
-
externalRef.current = node;
|
|
496
|
-
},
|
|
497
|
-
"data-slot": "alert-description",
|
|
498
|
-
className: cn(
|
|
499
|
-
"col-start-2 type-body-sm-regular text-secondary",
|
|
500
|
-
className
|
|
501
|
-
),
|
|
502
|
-
...props
|
|
503
|
-
}
|
|
504
|
-
);
|
|
505
|
-
}
|
|
506
|
-
function AlertActions({ className, ref, ...props }) {
|
|
507
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
508
|
-
"div",
|
|
509
|
-
{
|
|
510
|
-
ref,
|
|
511
|
-
"data-slot": "alert-actions",
|
|
512
|
-
className: cn("shrink-0 flex items-center gap-2", className),
|
|
513
|
-
...props
|
|
514
|
-
}
|
|
515
|
-
);
|
|
516
|
-
}
|
|
517
|
-
|
|
518
|
-
// src/components/ui/accordion.tsx
|
|
519
|
-
var import_accordion = require("@base-ui/react/accordion");
|
|
520
|
-
|
|
521
404
|
// src/components/ui/icons.tsx
|
|
522
405
|
var import_Lock = require("@phosphor-icons/react/Lock");
|
|
523
406
|
var import_Check = require("@phosphor-icons/react/Check");
|
|
@@ -578,7 +461,7 @@ var import_SquaresFour = require("@phosphor-icons/react/SquaresFour");
|
|
|
578
461
|
var import_MagnifyingGlassPlus = require("@phosphor-icons/react/MagnifyingGlassPlus");
|
|
579
462
|
var import_MagnifyingGlassMinus = require("@phosphor-icons/react/MagnifyingGlassMinus");
|
|
580
463
|
var import_SidebarSimple = require("@phosphor-icons/react/SidebarSimple");
|
|
581
|
-
var
|
|
464
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
582
465
|
function createIcon(PhosphorIcon) {
|
|
583
466
|
function Wrapped({
|
|
584
467
|
className,
|
|
@@ -587,7 +470,7 @@ function createIcon(PhosphorIcon) {
|
|
|
587
470
|
ref,
|
|
588
471
|
...props
|
|
589
472
|
}) {
|
|
590
|
-
return /* @__PURE__ */ (0,
|
|
473
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
591
474
|
PhosphorIcon,
|
|
592
475
|
{
|
|
593
476
|
ref,
|
|
@@ -661,81 +544,12 @@ var PanelIcon = createIcon(import_SidebarSimple.SidebarSimpleIcon);
|
|
|
661
544
|
var ZoomInIcon = createIcon(import_MagnifyingGlassPlus.MagnifyingGlassPlusIcon);
|
|
662
545
|
var ZoomOutIcon = createIcon(import_MagnifyingGlassMinus.MagnifyingGlassMinusIcon);
|
|
663
546
|
|
|
664
|
-
// src/components/ui/accordion.tsx
|
|
665
|
-
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
666
|
-
function Accordion({ className, ref, ...props }) {
|
|
667
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
668
|
-
import_accordion.Accordion.Root,
|
|
669
|
-
{
|
|
670
|
-
ref,
|
|
671
|
-
"data-slot": "accordion",
|
|
672
|
-
className: cn("flex w-full flex-col", className),
|
|
673
|
-
...props
|
|
674
|
-
}
|
|
675
|
-
);
|
|
676
|
-
}
|
|
677
|
-
function AccordionItem({ className, ref, ...props }) {
|
|
678
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
679
|
-
import_accordion.Accordion.Item,
|
|
680
|
-
{
|
|
681
|
-
ref,
|
|
682
|
-
"data-slot": "accordion-item",
|
|
683
|
-
className: cn("border-b border-muted", className),
|
|
684
|
-
...props
|
|
685
|
-
}
|
|
686
|
-
);
|
|
687
|
-
}
|
|
688
|
-
function AccordionTrigger({
|
|
689
|
-
className,
|
|
690
|
-
children,
|
|
691
|
-
ref,
|
|
692
|
-
...props
|
|
693
|
-
}) {
|
|
694
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_accordion.Accordion.Header, { className: "flex", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
|
|
695
|
-
import_accordion.Accordion.Trigger,
|
|
696
|
-
{
|
|
697
|
-
ref,
|
|
698
|
-
"data-slot": "accordion-trigger",
|
|
699
|
-
className: cn(
|
|
700
|
-
"group/accordion-trigger flex flex-1 items-center justify-between py-4 type-body-sm-medium text-default outline-none focus-visible:rounded-sm focus-visible:ring-2 focus-visible:ring-focus-default data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
701
|
-
className
|
|
702
|
-
),
|
|
703
|
-
...props,
|
|
704
|
-
children: [
|
|
705
|
-
children,
|
|
706
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CaretDownIcon, { className: "shrink-0 text-secondary group-data-[panel-open]/accordion-trigger:hidden" }),
|
|
707
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CaretUpIcon, { className: "hidden shrink-0 text-secondary group-data-[panel-open]/accordion-trigger:block" })
|
|
708
|
-
]
|
|
709
|
-
}
|
|
710
|
-
) });
|
|
711
|
-
}
|
|
712
|
-
function AccordionContent({
|
|
713
|
-
className,
|
|
714
|
-
children,
|
|
715
|
-
ref,
|
|
716
|
-
...props
|
|
717
|
-
}) {
|
|
718
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
719
|
-
import_accordion.Accordion.Panel,
|
|
720
|
-
{
|
|
721
|
-
ref,
|
|
722
|
-
"data-slot": "accordion-content",
|
|
723
|
-
className: cn(
|
|
724
|
-
"h-(--accordion-panel-height) overflow-hidden transition-[height] duration-200 ease-out data-[ending-style]:h-0 data-[starting-style]:h-0",
|
|
725
|
-
className
|
|
726
|
-
),
|
|
727
|
-
...props,
|
|
728
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "pb-4 type-body-sm-regular text-default", children })
|
|
729
|
-
}
|
|
730
|
-
);
|
|
731
|
-
}
|
|
732
|
-
|
|
733
547
|
// src/components/ui/button.tsx
|
|
734
|
-
var
|
|
548
|
+
var React = __toESM(require("react"));
|
|
735
549
|
var import_button = require("@base-ui/react/button");
|
|
736
|
-
var
|
|
737
|
-
var
|
|
738
|
-
var buttonVariants = (0,
|
|
550
|
+
var import_class_variance_authority2 = require("class-variance-authority");
|
|
551
|
+
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
552
|
+
var buttonVariants = (0, import_class_variance_authority2.cva)(
|
|
739
553
|
[
|
|
740
554
|
// Base layout
|
|
741
555
|
"inline-flex items-center justify-center gap-2 whitespace-nowrap",
|
|
@@ -781,7 +595,7 @@ var buttonVariants = (0, import_class_variance_authority3.cva)(
|
|
|
781
595
|
],
|
|
782
596
|
"destructive-subtle": [
|
|
783
597
|
// Base
|
|
784
|
-
"interactive-
|
|
598
|
+
"interactive-destructive-subtle interactive-destructive-subtle-fg shadow-xs",
|
|
785
599
|
"border border-default",
|
|
786
600
|
// Hover & active
|
|
787
601
|
"hover:interactive-hover",
|
|
@@ -845,7 +659,7 @@ var buttonVariants = (0, import_class_variance_authority3.cva)(
|
|
|
845
659
|
}
|
|
846
660
|
}
|
|
847
661
|
);
|
|
848
|
-
var hasTextChildren = (children) =>
|
|
662
|
+
var hasTextChildren = (children) => React.Children.toArray(children).some(
|
|
849
663
|
(child) => typeof child === "string" && child.trim().length > 0
|
|
850
664
|
);
|
|
851
665
|
function Button({
|
|
@@ -859,7 +673,7 @@ function Button({
|
|
|
859
673
|
}) {
|
|
860
674
|
const isIconOnly = !hasTextChildren(children);
|
|
861
675
|
const iconOnlyClasses = isIconOnly ? "aspect-square px-0 py-0" : void 0;
|
|
862
|
-
return /* @__PURE__ */ (0,
|
|
676
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
863
677
|
import_button.Button,
|
|
864
678
|
{
|
|
865
679
|
"data-slot": "button",
|
|
@@ -876,6 +690,206 @@ function Button({
|
|
|
876
690
|
);
|
|
877
691
|
}
|
|
878
692
|
|
|
693
|
+
// src/components/ui/alert.tsx
|
|
694
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
695
|
+
var alertVariants = (0, import_class_variance_authority3.cva)(
|
|
696
|
+
"relative flex flex-wrap w-full items-center data-[multiline]:items-start gap-4 rounded-md px-4 py-3 [&>[data-slot=alert-body]>svg]:size-4 [&>[data-slot=alert-body]>svg]:shrink-0",
|
|
697
|
+
{
|
|
698
|
+
variants: {
|
|
699
|
+
variant: {
|
|
700
|
+
default: "surface-secondary [&>[data-slot=alert-body]>svg]:text-default",
|
|
701
|
+
info: "surface-info border-info [&>[data-slot=alert-body]>svg]:text-info",
|
|
702
|
+
success: "surface-success border-success [&>[data-slot=alert-body]>svg]:text-success",
|
|
703
|
+
warning: "surface-warning border-warning [&>[data-slot=alert-body]>svg]:text-warning",
|
|
704
|
+
error: "surface-error border-error [&>[data-slot=alert-body]>svg]:text-error"
|
|
705
|
+
}
|
|
706
|
+
},
|
|
707
|
+
defaultVariants: {
|
|
708
|
+
variant: "default"
|
|
709
|
+
}
|
|
710
|
+
}
|
|
711
|
+
);
|
|
712
|
+
function Alert({ className, variant, onDismiss, ref, ...props }) {
|
|
713
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
|
|
714
|
+
"div",
|
|
715
|
+
{
|
|
716
|
+
ref,
|
|
717
|
+
"data-slot": "alert",
|
|
718
|
+
role: variant === "warning" || variant === "error" ? "alert" : "status",
|
|
719
|
+
className: cn(alertVariants({ variant }), className),
|
|
720
|
+
...props,
|
|
721
|
+
children: [
|
|
722
|
+
props.children,
|
|
723
|
+
onDismiss && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
724
|
+
Button,
|
|
725
|
+
{
|
|
726
|
+
type: "button",
|
|
727
|
+
variant: "ghost",
|
|
728
|
+
size: "mini",
|
|
729
|
+
"aria-label": "Dismiss",
|
|
730
|
+
onClick: onDismiss,
|
|
731
|
+
className: "shrink-0 self-start",
|
|
732
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(CloseIcon, { size: 16 })
|
|
733
|
+
}
|
|
734
|
+
)
|
|
735
|
+
]
|
|
736
|
+
}
|
|
737
|
+
);
|
|
738
|
+
}
|
|
739
|
+
function AlertBody({ className, ref, ...props }) {
|
|
740
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
741
|
+
"div",
|
|
742
|
+
{
|
|
743
|
+
ref,
|
|
744
|
+
"data-slot": "alert-body",
|
|
745
|
+
className: cn(
|
|
746
|
+
"grid flex-1 min-w-0 grid-cols-1 gap-y-0.5 items-start [&:has(>svg)]:grid-cols-[auto_1fr] [&:has(>svg)]:gap-x-3 [&>svg]:col-start-1 [&>svg]:row-start-1 [&>svg]:mt-0.5",
|
|
747
|
+
className
|
|
748
|
+
),
|
|
749
|
+
...props
|
|
750
|
+
}
|
|
751
|
+
);
|
|
752
|
+
}
|
|
753
|
+
function AlertTitle({ className, ref, ...props }) {
|
|
754
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
755
|
+
"p",
|
|
756
|
+
{
|
|
757
|
+
ref,
|
|
758
|
+
"data-slot": "alert-title",
|
|
759
|
+
className: cn(
|
|
760
|
+
"row-start-1 type-body-sm-medium text-default [div:has(>svg)>&]:col-start-2",
|
|
761
|
+
className
|
|
762
|
+
),
|
|
763
|
+
...props
|
|
764
|
+
}
|
|
765
|
+
);
|
|
766
|
+
}
|
|
767
|
+
function AlertDescription({
|
|
768
|
+
className,
|
|
769
|
+
ref: externalRef,
|
|
770
|
+
...props
|
|
771
|
+
}) {
|
|
772
|
+
const localRef = React2.useRef(null);
|
|
773
|
+
React2.useLayoutEffect(() => {
|
|
774
|
+
const el = localRef.current;
|
|
775
|
+
if (!el) return;
|
|
776
|
+
const alert = el.closest("[data-slot=alert]");
|
|
777
|
+
if (!alert) return;
|
|
778
|
+
const update = () => {
|
|
779
|
+
const lineHeight = parseFloat(getComputedStyle(el).lineHeight);
|
|
780
|
+
alert.toggleAttribute(
|
|
781
|
+
"data-multiline",
|
|
782
|
+
el.clientHeight > lineHeight * 1.5
|
|
783
|
+
);
|
|
784
|
+
};
|
|
785
|
+
update();
|
|
786
|
+
const resizeObserver = new ResizeObserver(update);
|
|
787
|
+
resizeObserver.observe(el);
|
|
788
|
+
return () => {
|
|
789
|
+
resizeObserver.disconnect();
|
|
790
|
+
alert.removeAttribute("data-multiline");
|
|
791
|
+
};
|
|
792
|
+
}, []);
|
|
793
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
794
|
+
"p",
|
|
795
|
+
{
|
|
796
|
+
ref: (node) => {
|
|
797
|
+
localRef.current = node;
|
|
798
|
+
if (typeof externalRef === "function") externalRef(node);
|
|
799
|
+
else if (externalRef)
|
|
800
|
+
externalRef.current = node;
|
|
801
|
+
},
|
|
802
|
+
"data-slot": "alert-description",
|
|
803
|
+
className: cn(
|
|
804
|
+
"type-body-sm-regular text-secondary [div:has(>svg)>&]:col-start-2",
|
|
805
|
+
className
|
|
806
|
+
),
|
|
807
|
+
...props
|
|
808
|
+
}
|
|
809
|
+
);
|
|
810
|
+
}
|
|
811
|
+
function AlertActions({ className, ref, ...props }) {
|
|
812
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
813
|
+
"div",
|
|
814
|
+
{
|
|
815
|
+
ref,
|
|
816
|
+
"data-slot": "alert-actions",
|
|
817
|
+
className: cn("shrink-0 flex items-center gap-2", className),
|
|
818
|
+
...props
|
|
819
|
+
}
|
|
820
|
+
);
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
// src/components/ui/accordion.tsx
|
|
824
|
+
var import_accordion = require("@base-ui/react/accordion");
|
|
825
|
+
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
826
|
+
function Accordion({ className, ref, ...props }) {
|
|
827
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
828
|
+
import_accordion.Accordion.Root,
|
|
829
|
+
{
|
|
830
|
+
ref,
|
|
831
|
+
"data-slot": "accordion",
|
|
832
|
+
className: cn("flex w-full flex-col", className),
|
|
833
|
+
...props
|
|
834
|
+
}
|
|
835
|
+
);
|
|
836
|
+
}
|
|
837
|
+
function AccordionItem({ className, ref, ...props }) {
|
|
838
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
839
|
+
import_accordion.Accordion.Item,
|
|
840
|
+
{
|
|
841
|
+
ref,
|
|
842
|
+
"data-slot": "accordion-item",
|
|
843
|
+
className: cn("border-b border-muted", className),
|
|
844
|
+
...props
|
|
845
|
+
}
|
|
846
|
+
);
|
|
847
|
+
}
|
|
848
|
+
function AccordionTrigger({
|
|
849
|
+
className,
|
|
850
|
+
children,
|
|
851
|
+
ref,
|
|
852
|
+
...props
|
|
853
|
+
}) {
|
|
854
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_accordion.Accordion.Header, { className: "flex", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
855
|
+
import_accordion.Accordion.Trigger,
|
|
856
|
+
{
|
|
857
|
+
ref,
|
|
858
|
+
"data-slot": "accordion-trigger",
|
|
859
|
+
className: cn(
|
|
860
|
+
"group/accordion-trigger flex flex-1 items-center justify-between py-4 type-body-sm-medium text-default outline-none focus-visible:rounded-sm focus-visible:ring-2 focus-visible:ring-focus-default data-[disabled]:pointer-events-none data-[disabled]:opacity-50",
|
|
861
|
+
className
|
|
862
|
+
),
|
|
863
|
+
...props,
|
|
864
|
+
children: [
|
|
865
|
+
children,
|
|
866
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(CaretDownIcon, { className: "shrink-0 text-secondary group-data-[panel-open]/accordion-trigger:hidden" }),
|
|
867
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(CaretUpIcon, { className: "hidden shrink-0 text-secondary group-data-[panel-open]/accordion-trigger:block" })
|
|
868
|
+
]
|
|
869
|
+
}
|
|
870
|
+
) });
|
|
871
|
+
}
|
|
872
|
+
function AccordionContent({
|
|
873
|
+
className,
|
|
874
|
+
children,
|
|
875
|
+
ref,
|
|
876
|
+
...props
|
|
877
|
+
}) {
|
|
878
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
879
|
+
import_accordion.Accordion.Panel,
|
|
880
|
+
{
|
|
881
|
+
ref,
|
|
882
|
+
"data-slot": "accordion-content",
|
|
883
|
+
className: cn(
|
|
884
|
+
"h-(--accordion-panel-height) overflow-hidden transition-[height] duration-200 ease-out data-[ending-style]:h-0 data-[starting-style]:h-0",
|
|
885
|
+
className
|
|
886
|
+
),
|
|
887
|
+
...props,
|
|
888
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { className: "pb-4 type-body-sm-regular text-default", children })
|
|
889
|
+
}
|
|
890
|
+
);
|
|
891
|
+
}
|
|
892
|
+
|
|
879
893
|
// src/components/ui/button-group.tsx
|
|
880
894
|
var React3 = __toESM(require("react"));
|
|
881
895
|
var import_merge_props = require("@base-ui/react/merge-props");
|
|
@@ -2712,14 +2726,13 @@ var TYPE_ICON_COLOR = {
|
|
|
2712
2726
|
warning: "text-warning"
|
|
2713
2727
|
};
|
|
2714
2728
|
var TYPE_SURFACE = {
|
|
2715
|
-
default: "surface-default border-default",
|
|
2716
|
-
success: "surface-success
|
|
2717
|
-
error: "surface-error
|
|
2718
|
-
info: "surface-info
|
|
2719
|
-
warning: "surface-warning
|
|
2729
|
+
default: "surface-default border border-default",
|
|
2730
|
+
success: "surface-success",
|
|
2731
|
+
error: "surface-error",
|
|
2732
|
+
info: "surface-info",
|
|
2733
|
+
warning: "surface-warning"
|
|
2720
2734
|
};
|
|
2721
2735
|
var VIEWPORT_POSITION = {
|
|
2722
|
-
"top-left": "top-4 left-4 sm:top-8 sm:left-8",
|
|
2723
2736
|
"top-center": "top-4 left-1/2 -translate-x-1/2 sm:top-8",
|
|
2724
2737
|
"top-right": "top-4 right-4 sm:top-8 sm:right-8",
|
|
2725
2738
|
"bottom-left": "bottom-4 left-4 sm:bottom-8 sm:left-8",
|
|
@@ -2751,7 +2764,7 @@ function ToastList({ side }) {
|
|
|
2751
2764
|
side === "top" ? "top-0 origin-top" : "bottom-0 origin-bottom",
|
|
2752
2765
|
// Surface — variant-tinted to match the Alert component (default = neutral)
|
|
2753
2766
|
TYPE_SURFACE[type],
|
|
2754
|
-
"rounded-lg
|
|
2767
|
+
"rounded-lg bg-clip-padding shadow-lg select-none",
|
|
2755
2768
|
// Collapsed transform: peek + shrink each toast behind the front one
|
|
2756
2769
|
"[transform:translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)+(var(--y-dir)*((var(--toast-index)*var(--peek))+(var(--shrink)*var(--height))))))_scale(var(--scale))]",
|
|
2757
2770
|
// Expanded (hover/focus) transform: fan out by real heights + gap
|
|
@@ -2776,7 +2789,8 @@ function ToastList({ side }) {
|
|
|
2776
2789
|
{
|
|
2777
2790
|
"data-slot": "toast-content",
|
|
2778
2791
|
className: cn(
|
|
2779
|
-
"flex h-full
|
|
2792
|
+
"flex h-full gap-3 px-4 py-3 overflow-hidden",
|
|
2793
|
+
item.description ? "items-start" : "items-center",
|
|
2780
2794
|
"transition-opacity duration-[250ms] ease-[cubic-bezier(0.22,1,0.36,1)]",
|
|
2781
2795
|
"data-behind:opacity-0 data-expanded:opacity-100"
|
|
2782
2796
|
),
|
|
@@ -2792,10 +2806,10 @@ function ToastList({ side }) {
|
|
|
2792
2806
|
import_toast.Toast.Title,
|
|
2793
2807
|
{
|
|
2794
2808
|
"data-slot": "toast-title",
|
|
2795
|
-
className: "type-body-sm-medium text-default"
|
|
2809
|
+
className: item.description ? "type-body-sm-medium text-default" : "type-label-sm-medium text-default"
|
|
2796
2810
|
}
|
|
2797
2811
|
),
|
|
2798
|
-
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
2812
|
+
item.description && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
2799
2813
|
import_toast.Toast.Description,
|
|
2800
2814
|
{
|
|
2801
2815
|
"data-slot": "toast-description",
|
|
@@ -2807,12 +2821,8 @@ function ToastList({ side }) {
|
|
|
2807
2821
|
import_toast.Toast.Action,
|
|
2808
2822
|
{
|
|
2809
2823
|
"data-slot": "toast-action",
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
"type-label-xs-medium text-default surface-default",
|
|
2813
|
-
"transition-colors hover:surface-secondary",
|
|
2814
|
-
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-focus-default"
|
|
2815
|
-
)
|
|
2824
|
+
render: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Button, { variant: "default", size: "mini" }),
|
|
2825
|
+
...item.actionProps
|
|
2816
2826
|
}
|
|
2817
2827
|
) : null,
|
|
2818
2828
|
/* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
|
|
@@ -2855,7 +2865,7 @@ function Toaster({
|
|
|
2855
2865
|
{
|
|
2856
2866
|
"data-slot": "toaster",
|
|
2857
2867
|
className: cn(
|
|
2858
|
-
"fixed z-50 mx-auto flex w-[calc(100vw-2rem)] sm:w-[
|
|
2868
|
+
"fixed z-50 mx-auto flex w-[calc(100vw-2rem)] sm:w-[400px]",
|
|
2859
2869
|
VIEWPORT_POSITION[position],
|
|
2860
2870
|
className
|
|
2861
2871
|
),
|
|
@@ -3112,7 +3122,7 @@ function Sidebar({
|
|
|
3112
3122
|
"div",
|
|
3113
3123
|
{
|
|
3114
3124
|
className: cn(
|
|
3115
|
-
"fixed inset-y-0 z-10 h-svh w-[var(--sidebar-width)] transition-[left,right,width] duration-200 ease-linear flex left-0",
|
|
3125
|
+
"fixed inset-y-0 z-10 h-svh w-[var(--sidebar-width)] transition-[left,right,width] duration-200 ease-linear flex left-0 border-r border-[var(--color-sidebar-border)]",
|
|
3116
3126
|
"group-data-[collapsible=icon]:w-[var(--sidebar-width-icon)]"
|
|
3117
3127
|
),
|
|
3118
3128
|
children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
@@ -3267,6 +3277,24 @@ function SidebarMenuButton({
|
|
|
3267
3277
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)(TooltipContent, { side: "right", align: "center", ...tooltipProps })
|
|
3268
3278
|
] }) });
|
|
3269
3279
|
}
|
|
3280
|
+
function SidebarSeparator({
|
|
3281
|
+
className,
|
|
3282
|
+
ref,
|
|
3283
|
+
...props
|
|
3284
|
+
}) {
|
|
3285
|
+
return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
|
|
3286
|
+
"div",
|
|
3287
|
+
{
|
|
3288
|
+
ref,
|
|
3289
|
+
"data-sidebar": "separator",
|
|
3290
|
+
className: cn(
|
|
3291
|
+
"border-t border-[var(--color-sidebar-border)] w-full",
|
|
3292
|
+
className
|
|
3293
|
+
),
|
|
3294
|
+
...props
|
|
3295
|
+
}
|
|
3296
|
+
);
|
|
3297
|
+
}
|
|
3270
3298
|
|
|
3271
3299
|
// src/components/ui/calendar.tsx
|
|
3272
3300
|
var React9 = __toESM(require("react"));
|
|
@@ -4577,13 +4605,13 @@ var tagVariants = (0, import_class_variance_authority18.cva)(
|
|
|
4577
4605
|
{
|
|
4578
4606
|
variants: {
|
|
4579
4607
|
color: {
|
|
4580
|
-
violet: "bg-violet-
|
|
4581
|
-
cyan: "bg-cyan-
|
|
4582
|
-
indigo: "bg-indigo-100 text-
|
|
4583
|
-
orange: "bg-orange-
|
|
4584
|
-
pink: "bg-pink-
|
|
4585
|
-
verdant: "bg-verdant-
|
|
4586
|
-
stone: "bg-stone-200 text-
|
|
4608
|
+
violet: "bg-violet-200 text-black",
|
|
4609
|
+
cyan: "bg-cyan-200 text-black",
|
|
4610
|
+
indigo: "bg-indigo-100 text-black",
|
|
4611
|
+
orange: "bg-orange-200 text-black",
|
|
4612
|
+
pink: "bg-pink-200 text-black",
|
|
4613
|
+
verdant: "bg-verdant-200 text-black",
|
|
4614
|
+
stone: "bg-stone-200 text-black"
|
|
4587
4615
|
}
|
|
4588
4616
|
},
|
|
4589
4617
|
defaultVariants: {
|
|
@@ -6593,6 +6621,7 @@ function DataTableViewOptions({
|
|
|
6593
6621
|
SidebarMenuButton,
|
|
6594
6622
|
SidebarMenuItem,
|
|
6595
6623
|
SidebarProvider,
|
|
6624
|
+
SidebarSeparator,
|
|
6596
6625
|
Slider,
|
|
6597
6626
|
StarIcon,
|
|
6598
6627
|
StatementIcon,
|