@brightlocal/ui-components 0.1.1 → 0.1.3
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/accordion.cjs +1 -1
- package/dist/accordion.d.ts +74 -4
- package/dist/accordion.d.ts.map +1 -1
- package/dist/accordion.js +100 -105
- package/dist/alert-dialog.cjs +1 -1
- package/dist/alert-dialog.d.ts +30 -10
- package/dist/alert-dialog.d.ts.map +1 -1
- package/dist/alert-dialog.js +129 -132
- package/dist/alert.d.ts +22 -1
- package/dist/alert.d.ts.map +1 -1
- package/dist/aspect-ratio.cjs +1 -1
- package/dist/aspect-ratio.d.ts +11 -1
- package/dist/aspect-ratio.d.ts.map +1 -1
- package/dist/aspect-ratio.js +16 -20
- package/dist/avatar.cjs +1 -1
- package/dist/avatar.d.ts +43 -3
- package/dist/avatar.d.ts.map +1 -1
- package/dist/avatar.js +18 -16
- package/dist/badge.cjs +1 -1
- package/dist/badge.d.ts +24 -9
- package/dist/badge.d.ts.map +1 -1
- package/dist/badge.js +34 -32
- package/dist/blocks/data-table.cjs +1 -1
- package/dist/blocks/data-table.d.ts.map +1 -1
- package/dist/blocks/data-table.js +209 -202
- package/dist/blocks/sidebar.cjs +1 -1
- package/dist/blocks/sidebar.d.ts +1 -1
- package/dist/blocks/sidebar.d.ts.map +1 -1
- package/dist/blocks/sidebar.js +154 -154
- package/dist/breadcrumb.cjs +1 -1
- package/dist/breadcrumb.d.ts +63 -8
- package/dist/breadcrumb.d.ts.map +1 -1
- package/dist/breadcrumb.js +97 -93
- package/dist/button.cjs +1 -1
- package/dist/button.d.ts +17 -45
- package/dist/button.d.ts.map +1 -1
- package/dist/button.js +49 -50
- package/dist/calendar.cjs +1 -1
- package/dist/calendar.d.ts +12 -0
- package/dist/calendar.d.ts.map +1 -1
- package/dist/calendar.js +10 -8
- package/dist/card.cjs +1 -1
- package/dist/card.d.ts +58 -18
- package/dist/card.d.ts.map +1 -1
- package/dist/card.js +60 -51
- package/dist/carousel.cjs +1 -1
- package/dist/carousel.d.ts +99 -9
- package/dist/carousel.d.ts.map +1 -1
- package/dist/carousel.js +142 -128
- package/dist/centred-layout.cjs +1 -1
- package/dist/centred-layout.d.ts +18 -2
- package/dist/centred-layout.d.ts.map +1 -1
- package/dist/centred-layout.js +46 -33
- package/dist/chart.cjs +4 -4
- package/dist/chart.d.ts +70 -7
- package/dist/chart.d.ts.map +1 -1
- package/dist/chart.js +71 -66
- package/dist/checkbox.cjs +1 -1
- package/dist/checkbox.d.ts +9 -5
- package/dist/checkbox.d.ts.map +1 -1
- package/dist/checkbox.js +61 -82
- package/dist/collapsible.cjs +1 -1
- package/dist/collapsible.d.ts +65 -8
- package/dist/collapsible.d.ts.map +1 -1
- package/dist/collapsible.js +41 -55
- package/dist/combobox.cjs +1 -1
- package/dist/combobox.d.ts +29 -11
- package/dist/combobox.d.ts.map +1 -1
- package/dist/combobox.js +193 -159
- package/dist/command.cjs +1 -1
- package/dist/command.d.ts +115 -9
- package/dist/command.d.ts.map +1 -1
- package/dist/command.js +176 -152
- package/dist/context-menu.cjs +1 -1
- package/dist/context-menu.d.ts +188 -20
- package/dist/context-menu.d.ts.map +1 -1
- package/dist/context-menu.js +119 -121
- package/dist/date-picker.cjs +1 -1
- package/dist/date-picker.d.ts +75 -9
- package/dist/date-picker.d.ts.map +1 -1
- package/dist/date-picker.js +220 -81
- package/dist/description.cjs +1 -0
- package/dist/description.d.ts +37 -0
- package/dist/description.d.ts.map +1 -0
- package/dist/description.js +25 -0
- package/dist/dialog.cjs +1 -1
- package/dist/dialog.d.ts +73 -9
- package/dist/dialog.d.ts.map +1 -1
- package/dist/dialog.js +103 -112
- package/dist/drawer.cjs +1 -1
- package/dist/drawer.d.ts +92 -0
- package/dist/drawer.d.ts.map +1 -1
- package/dist/drawer.js +67 -52
- package/dist/dropdown-menu.cjs +1 -1
- package/dist/dropdown-menu.d.ts +95 -11
- package/dist/dropdown-menu.d.ts.map +1 -1
- package/dist/dropdown-menu.js +146 -106
- package/dist/field.cjs +1 -1
- package/dist/field.d.ts +23 -6
- package/dist/field.d.ts.map +1 -1
- package/dist/field.js +54 -53
- package/dist/global-layout.cjs +1 -1
- package/dist/global-layout.d.ts +27 -17
- package/dist/global-layout.d.ts.map +1 -1
- package/dist/global-layout.js +86 -79
- package/dist/hover-card.cjs +1 -1
- package/dist/hover-card.d.ts +36 -6
- package/dist/hover-card.d.ts.map +1 -1
- package/dist/hover-card.js +44 -42
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +383 -387
- package/dist/input-group.cjs +1 -1
- package/dist/input-group.d.ts +21 -2
- package/dist/input-group.d.ts.map +1 -1
- package/dist/input-group.js +51 -41
- package/dist/input-password.cjs +1 -1
- package/dist/input-password.d.ts.map +1 -1
- package/dist/input-password.js +24 -25
- package/dist/input.cjs +1 -1
- package/dist/input.d.ts +38 -24
- package/dist/input.d.ts.map +1 -1
- package/dist/input.js +68 -136
- package/dist/label.cjs +1 -1
- package/dist/label.d.ts +20 -1
- package/dist/label.d.ts.map +1 -1
- package/dist/label.js +31 -18
- package/dist/logo.cjs +1 -1
- package/dist/logo.d.ts +3 -0
- package/dist/logo.d.ts.map +1 -1
- package/dist/logo.js +12 -10
- package/dist/menubar.cjs +1 -1
- package/dist/menubar.d.ts +40 -6
- package/dist/menubar.d.ts.map +1 -1
- package/dist/menubar.js +97 -76
- package/dist/popover.cjs +1 -1
- package/dist/popover.d.ts +59 -4
- package/dist/popover.d.ts.map +1 -1
- package/dist/popover.js +42 -34
- package/dist/progress.cjs +1 -1
- package/dist/progress.d.ts +9 -2
- package/dist/progress.d.ts.map +1 -1
- package/dist/progress.js +71 -59
- package/dist/radio-group.d.ts +40 -0
- package/dist/radio-group.d.ts.map +1 -1
- package/dist/rating.d.ts +4 -0
- package/dist/rating.d.ts.map +1 -1
- package/dist/resizable.cjs +1 -1
- package/dist/resizable.d.ts +65 -4
- package/dist/resizable.d.ts.map +1 -1
- package/dist/resizable.js +53 -36
- package/dist/scroll-area.cjs +1 -1
- package/dist/scroll-area.d.ts +46 -5
- package/dist/scroll-area.d.ts.map +1 -1
- package/dist/scroll-area.js +42 -38
- package/dist/select.cjs +1 -1
- package/dist/select.d.ts +30 -0
- package/dist/select.d.ts.map +1 -1
- package/dist/select.js +64 -54
- package/dist/separator.cjs +1 -1
- package/dist/separator.d.ts +49 -2
- package/dist/separator.d.ts.map +1 -1
- package/dist/separator.js +48 -36
- package/dist/sheet.cjs +1 -1
- package/dist/sheet.d.ts +80 -9
- package/dist/sheet.d.ts.map +1 -1
- package/dist/sheet.js +117 -113
- package/dist/skeleton.cjs +1 -1
- package/dist/skeleton.d.ts +24 -2
- package/dist/skeleton.d.ts.map +1 -1
- package/dist/skeleton.js +15 -9
- package/dist/slider.cjs +1 -1
- package/dist/slider.d.ts +18 -4
- package/dist/slider.d.ts.map +1 -1
- package/dist/slider.js +72 -66
- package/dist/sonner.cjs +1 -1
- package/dist/sonner.d.ts +4 -2
- package/dist/sonner.d.ts.map +1 -1
- package/dist/sonner.js +29 -28
- package/dist/split-layout.d.ts +4 -1
- package/dist/split-layout.d.ts.map +1 -1
- package/dist/table.cjs +1 -1
- package/dist/table.js +1 -1
- package/dist/toggle-group.cjs +1 -1
- package/dist/toggle-group.d.ts +3 -1
- package/dist/toggle-group.d.ts.map +1 -1
- package/dist/toggle-group.js +38 -36
- package/package.json +8 -2
- package/src/blocks/data-table.tsx +42 -32
- package/src/blocks/sidebar.tsx +4 -12
- package/src/components/accordion.tsx +163 -77
- package/src/components/alert-dialog.tsx +156 -111
- package/src/components/alert.tsx +26 -13
- package/src/components/aspect-ratio.tsx +25 -16
- package/src/components/avatar.tsx +56 -8
- package/src/components/badge.tsx +65 -42
- package/src/components/breadcrumb.tsx +158 -82
- package/src/components/button.tsx +41 -62
- package/src/components/calendar.tsx +16 -2
- package/src/components/card.tsx +92 -40
- package/src/components/carousel.tsx +240 -115
- package/src/components/centred-layout.tsx +67 -35
- package/src/components/chart.tsx +118 -47
- package/src/components/checkbox.tsx +42 -78
- package/src/components/collapsible.tsx +95 -26
- package/src/components/combobox.tsx +242 -144
- package/src/components/command.tsx +295 -121
- package/src/components/context-menu.tsx +278 -81
- package/src/components/date-picker.tsx +281 -30
- package/src/components/description.tsx +60 -0
- package/src/components/dialog.tsx +162 -86
- package/src/components/drawer.tsx +76 -2
- package/src/components/dropdown-menu.tsx +143 -37
- package/src/components/field.tsx +36 -11
- package/src/components/global-layout.tsx +116 -77
- package/src/components/hover-card.tsx +54 -14
- package/src/components/input-group.tsx +56 -18
- package/src/components/input-password.tsx +3 -4
- package/src/components/input.tsx +93 -186
- package/src/components/label.tsx +56 -15
- package/src/components/logo.tsx +3 -0
- package/src/components/menubar.tsx +58 -4
- package/src/components/popover.tsx +103 -20
- package/src/components/progress.tsx +82 -60
- package/src/components/radio-group.tsx +40 -0
- package/src/components/rating.tsx +4 -1
- package/src/components/resizable.tsx +119 -31
- package/src/components/scroll-area.tsx +123 -56
- package/src/components/select.tsx +21 -1
- package/src/components/separator.tsx +97 -20
- package/src/components/sheet.tsx +180 -79
- package/src/components/skeleton.tsx +40 -10
- package/src/components/slider.tsx +83 -57
- package/src/components/sonner.tsx +10 -7
- package/src/components/split-layout.tsx +4 -1
- package/src/components/table.tsx +1 -1
- package/src/components/toggle-group.tsx +4 -0
- package/src/index.ts +1 -1
- package/dist/input-base.cjs +0 -1
- package/dist/input-base.d.ts +0 -28
- package/dist/input-base.d.ts.map +0 -1
- package/dist/input-base.js +0 -56
- package/src/components/input-base.tsx +0 -86
package/dist/progress.js
CHANGED
|
@@ -1,64 +1,76 @@
|
|
|
1
|
-
import { jsx as r, jsxs as
|
|
2
|
-
import * as
|
|
3
|
-
import * as
|
|
4
|
-
import { motion as
|
|
5
|
-
import { cn as
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
"
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
{
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
1
|
+
import { jsx as r, jsxs as u } from "react/jsx-runtime";
|
|
2
|
+
import * as o from "react";
|
|
3
|
+
import * as i from "@radix-ui/react-progress";
|
|
4
|
+
import { motion as h } from "framer-motion";
|
|
5
|
+
import { cn as b } from "@brightlocal/ui-components/lib/utils";
|
|
6
|
+
const v = o.forwardRef(
|
|
7
|
+
({
|
|
8
|
+
className: l,
|
|
9
|
+
value: n,
|
|
10
|
+
dataHook: d,
|
|
11
|
+
trackingEl: m,
|
|
12
|
+
trackingLabel: f,
|
|
13
|
+
ariaLabel: p = "Progress",
|
|
14
|
+
label: a,
|
|
15
|
+
...c
|
|
16
|
+
}, g) => {
|
|
17
|
+
const s = o.useId(), e = !!a, t = /* @__PURE__ */ r(
|
|
18
|
+
i.Root,
|
|
19
|
+
{
|
|
20
|
+
ref: g,
|
|
21
|
+
"aria-label": e ? void 0 : p,
|
|
22
|
+
"aria-labelledby": e ? s : void 0,
|
|
23
|
+
className: b(
|
|
24
|
+
"relative h-2 w-full overflow-hidden rounded-full",
|
|
25
|
+
"bg-primary/20",
|
|
26
|
+
l
|
|
27
|
+
),
|
|
28
|
+
"data-hook": d,
|
|
29
|
+
"data-slot": "progress",
|
|
30
|
+
"data-tracking-el": m,
|
|
31
|
+
"data-tracking-label": f,
|
|
32
|
+
...c,
|
|
33
|
+
children: /* @__PURE__ */ r(i.Indicator, { asChild: !0, children: /* @__PURE__ */ r(
|
|
34
|
+
h.div,
|
|
35
|
+
{
|
|
36
|
+
animate: {
|
|
37
|
+
transform: `translateX(-${100 - (n || 0)}%)`
|
|
38
|
+
},
|
|
39
|
+
className: "h-full w-full flex-1 bg-green-400",
|
|
40
|
+
"data-slot": "progress-indicator",
|
|
41
|
+
initial: !1,
|
|
42
|
+
transition: {
|
|
43
|
+
type: "spring",
|
|
44
|
+
stiffness: 80,
|
|
45
|
+
damping: 20,
|
|
46
|
+
mass: 1
|
|
47
|
+
}
|
|
45
48
|
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
/* @__PURE__ */ r(
|
|
52
|
-
"span",
|
|
49
|
+
) })
|
|
50
|
+
}
|
|
51
|
+
);
|
|
52
|
+
return a ? /* @__PURE__ */ u(
|
|
53
|
+
"div",
|
|
53
54
|
{
|
|
54
|
-
className: "
|
|
55
|
-
|
|
56
|
-
children:
|
|
55
|
+
className: "flex w-full items-center gap-2",
|
|
56
|
+
"data-slot": "progress-wrapper",
|
|
57
|
+
children: [
|
|
58
|
+
/* @__PURE__ */ r(
|
|
59
|
+
"span",
|
|
60
|
+
{
|
|
61
|
+
className: "text-foreground text-sm leading-normal font-medium",
|
|
62
|
+
"data-slot": "progress-label",
|
|
63
|
+
id: s,
|
|
64
|
+
children: a
|
|
65
|
+
}
|
|
66
|
+
),
|
|
67
|
+
t
|
|
68
|
+
]
|
|
57
69
|
}
|
|
58
|
-
)
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
70
|
+
) : t;
|
|
71
|
+
}
|
|
72
|
+
);
|
|
73
|
+
v.displayName = "Progress";
|
|
62
74
|
export {
|
|
63
|
-
|
|
75
|
+
v as Progress
|
|
64
76
|
};
|
package/dist/radio-group.d.ts
CHANGED
|
@@ -7,23 +7,63 @@ declare const radioGroupVariants: (props?: ({
|
|
|
7
7
|
declare const radioGroupItemVariants: (props?: ({
|
|
8
8
|
variant?: "default" | "box" | "boxIconVertical" | "boxIconHorizontal" | null | undefined;
|
|
9
9
|
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
10
|
+
/**
|
|
11
|
+
* Visual style variants for the radio group component.
|
|
12
|
+
*/
|
|
10
13
|
declare enum RadioGroupVariant {
|
|
14
|
+
/** Standard radio group with minimal styling */
|
|
11
15
|
DEFAULT = "default",
|
|
16
|
+
/** Radio items wrapped in styled card containers */
|
|
12
17
|
BOX = "box",
|
|
18
|
+
/** Radio items with icons displayed vertically above the label */
|
|
13
19
|
BOX_ICON_VERTICAL = "boxIconVertical",
|
|
20
|
+
/** Radio items with icons displayed horizontally to the left */
|
|
14
21
|
BOX_ICON_HORIZONTAL = "boxIconHorizontal"
|
|
15
22
|
}
|
|
23
|
+
/**
|
|
24
|
+
* Props for the RadioGroup component.
|
|
25
|
+
*/
|
|
16
26
|
interface RadioGroupProps extends React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>, VariantProps<typeof radioGroupVariants> {
|
|
27
|
+
/**
|
|
28
|
+
* Data hook for automated testing (required)
|
|
29
|
+
*/
|
|
17
30
|
dataHook: string;
|
|
31
|
+
/**
|
|
32
|
+
* Tracking element identifier for analytics
|
|
33
|
+
*/
|
|
18
34
|
trackingEl?: string;
|
|
35
|
+
/**
|
|
36
|
+
* Tracking label for analytics context
|
|
37
|
+
*/
|
|
19
38
|
trackingLabel?: string;
|
|
20
39
|
}
|
|
40
|
+
/**
|
|
41
|
+
* Props for the RadioGroupItem component.
|
|
42
|
+
*/
|
|
21
43
|
interface RadioGroupItemProps extends React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>, VariantProps<typeof radioGroupItemVariants> {
|
|
44
|
+
/**
|
|
45
|
+
* Label text displayed next to the radio button
|
|
46
|
+
*/
|
|
22
47
|
label?: React.ReactNode;
|
|
48
|
+
/**
|
|
49
|
+
* Description text displayed below the label
|
|
50
|
+
*/
|
|
23
51
|
description?: React.ReactNode;
|
|
52
|
+
/**
|
|
53
|
+
* Icon displayed for box icon variants
|
|
54
|
+
*/
|
|
24
55
|
icon?: React.ReactNode;
|
|
56
|
+
/**
|
|
57
|
+
* Data hook for automated testing (required)
|
|
58
|
+
*/
|
|
25
59
|
dataHook: string;
|
|
60
|
+
/**
|
|
61
|
+
* Tracking element identifier for analytics
|
|
62
|
+
*/
|
|
26
63
|
trackingEl?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Tracking label for analytics context
|
|
66
|
+
*/
|
|
27
67
|
trackingLabel?: string;
|
|
28
68
|
}
|
|
29
69
|
declare const RadioGroup: React.ForwardRefExoticComponent<RadioGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"radio-group.d.ts","sourceRoot":"","sources":["../../src/components/radio-group.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAEnE,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAOlE,QAAA,MAAM,kBAAkB;;8EAYtB,CAAC;AAEH,QAAA,MAAM,sBAAsB;;8EAiC3B,CAAC;AA6DF,aAAK,iBAAiB;IACpB,OAAO,YAAY;IACnB,GAAG,QAAQ;IACX,iBAAiB,oBAAoB;IACrC,mBAAmB,sBAAsB;CAC1C;AAMD,UAAU,eACR,SACE,KAAK,CAAC,wBAAwB,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,EAC/D,YAAY,CAAC,OAAO,kBAAkB,CAAC;IACzC,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,UAAU,mBACR,SACE,KAAK,CAAC,wBAAwB,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,EAC/D,YAAY,CAAC,OAAO,sBAAsB,CAAC;IAC7C,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAUD,QAAA,MAAM,UAAU,wFAgCf,CAAC;AAKF,QAAA,MAAM,cAAc,+FA6EnB,CAAC;AAKF,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,iBAAiB,EAAE,CAAC;AACzD,YAAY,EAAE,eAAe,EAAE,mBAAmB,EAAE,CAAC"}
|
|
1
|
+
{"version":3,"file":"radio-group.d.ts","sourceRoot":"","sources":["../../src/components/radio-group.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAEnE,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAOlE,QAAA,MAAM,kBAAkB;;8EAYtB,CAAC;AAEH,QAAA,MAAM,sBAAsB;;8EAiC3B,CAAC;AA6DF;;GAEG;AACH,aAAK,iBAAiB;IACpB,gDAAgD;IAChD,OAAO,YAAY;IACnB,oDAAoD;IACpD,GAAG,QAAQ;IACX,kEAAkE;IAClE,iBAAiB,oBAAoB;IACrC,gEAAgE;IAChE,mBAAmB,sBAAsB;CAC1C;AAMD;;GAEG;AACH,UAAU,eACR,SACE,KAAK,CAAC,wBAAwB,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,EAC/D,YAAY,CAAC,OAAO,kBAAkB,CAAC;IACzC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;GAEG;AACH,UAAU,mBACR,SACE,KAAK,CAAC,wBAAwB,CAAC,OAAO,mBAAmB,CAAC,IAAI,CAAC,EAC/D,YAAY,CAAC,OAAO,sBAAsB,CAAC;IAC7C;;OAEG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB;;OAEG;IACH,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC9B;;OAEG;IACH,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAUD,QAAA,MAAM,UAAU,wFAgCf,CAAC;AAKF,QAAA,MAAM,cAAc,+FA6EnB,CAAC;AAKF,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,iBAAiB,EAAE,CAAC;AACzD,YAAY,EAAE,eAAe,EAAE,mBAAmB,EAAE,CAAC"}
|
package/dist/rating.d.ts
CHANGED
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Rating component displays a star-based rating indicator.
|
|
4
|
+
* Supports full and half-star values for precise rating display.
|
|
5
|
+
*/
|
|
2
6
|
export interface RatingProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
3
7
|
/**
|
|
4
8
|
* The rating value (0-5, supports 0.5 increments)
|
package/dist/rating.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rating.d.ts","sourceRoot":"","sources":["../../src/components/rating.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"rating.d.ts","sourceRoot":"","sources":["../../src/components/rating.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B;;;GAGG;AACH,MAAM,WAAW,WAAY,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IACvE;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,QAAA,MAAM,MAAM,oFAyDX,CAAC;AAIF,OAAO,EAAE,MAAM,EAAE,CAAC"}
|
package/dist/resizable.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),b=require("react"),g=require("lucide-react"),v=require("react-resizable-panels"),s=require("@brightlocal/ui-components/lib/utils");function c(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const r=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(t,a,r.get?r:{enumerable:!0,get:()=>e[a]})}}return t.default=e,Object.freeze(t)}const d=c(b),o=c(v),u=d.forwardRef(({className:e,dataHook:t,trackingEl:a,trackingLabel:r,...l},n)=>i.jsx(o.PanelGroup,{ref:n,className:s.cn("flex h-full w-full data-[panel-group-direction=vertical]:flex-col",e),"data-hook":t,"data-slot":"resizable-panel-group","data-tracking-el":a,"data-tracking-label":r,...l}));u.displayName="ResizablePanelGroup";const f=d.forwardRef(({dataHook:e,trackingEl:t,trackingLabel:a,...r},l)=>i.jsx(o.Panel,{ref:l,"data-hook":e,"data-slot":"resizable-panel","data-tracking-el":t,"data-tracking-label":a,...r}));f.displayName="ResizablePanel";function p({withHandle:e,className:t,dataHook:a,trackingEl:r,trackingLabel:l,...n}){return i.jsx(o.PanelResizeHandle,{className:s.cn("bg-border focus-visible:ring-ring relative flex w-px items-center justify-center after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-1 focus-visible:ring-offset-1 focus-visible:outline-none data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:translate-x-0 data-[panel-group-direction=vertical]:after:-translate-y-1/2 [&[data-panel-group-direction=vertical]>div]:rotate-90",t),"data-hook":a,"data-slot":"resizable-handle","data-tracking-el":r,"data-tracking-label":l,...n,children:e&&i.jsx("div",{className:"border-border bg-border z-10 flex h-4 w-3 items-center justify-center rounded-xs border",children:i.jsx(g.GripVertical,{className:"h-2.5 w-2.5"})})})}p.displayName="ResizableHandle";exports.ResizableHandle=p;exports.ResizablePanel=f;exports.ResizablePanelGroup=u;
|
package/dist/resizable.d.ts
CHANGED
|
@@ -1,14 +1,75 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import * as ResizablePrimitive from "react-resizable-panels";
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
/**
|
|
4
|
+
* Props for the ResizablePanelGroup component.
|
|
5
|
+
*/
|
|
6
|
+
interface ResizablePanelGroupProps extends React.ComponentProps<typeof ResizablePrimitive.PanelGroup> {
|
|
7
|
+
/**
|
|
8
|
+
* Data hook for automated testing
|
|
9
|
+
*/
|
|
10
|
+
dataHook?: string;
|
|
11
|
+
/**
|
|
12
|
+
* Tracking element identifier for analytics
|
|
13
|
+
*/
|
|
14
|
+
trackingEl?: string;
|
|
15
|
+
/**
|
|
16
|
+
* Tracking label for analytics context
|
|
17
|
+
*/
|
|
18
|
+
trackingLabel?: string;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Container for resizable panels. Manages layout direction and panel sizing.
|
|
22
|
+
*/
|
|
23
|
+
declare const ResizablePanelGroup: React.ForwardRefExoticComponent<Omit<ResizablePanelGroupProps, "ref"> & React.RefAttributes<ResizablePrimitive.ImperativePanelGroupHandle>>;
|
|
24
|
+
/**
|
|
25
|
+
* Props for the ResizablePanel component.
|
|
26
|
+
*/
|
|
27
|
+
interface ResizablePanelProps extends React.ComponentProps<typeof ResizablePrimitive.Panel> {
|
|
28
|
+
/**
|
|
29
|
+
* Data hook for automated testing
|
|
30
|
+
*/
|
|
31
|
+
dataHook?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Tracking element identifier for analytics
|
|
34
|
+
*/
|
|
35
|
+
trackingEl?: string;
|
|
36
|
+
/**
|
|
37
|
+
* Tracking label for analytics context
|
|
38
|
+
*/
|
|
39
|
+
trackingLabel?: string;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Individual resizable panel within a panel group.
|
|
43
|
+
*/
|
|
44
|
+
declare const ResizablePanel: React.ForwardRefExoticComponent<Omit<ResizablePanelProps, "ref"> & React.RefAttributes<ResizablePrimitive.ImperativePanelHandle>>;
|
|
45
|
+
/**
|
|
46
|
+
* Props for the ResizableHandle component.
|
|
47
|
+
*/
|
|
5
48
|
interface ResizableHandleProps extends React.ComponentProps<typeof ResizablePrimitive.PanelResizeHandle> {
|
|
49
|
+
/**
|
|
50
|
+
* Show a visible drag handle indicator
|
|
51
|
+
*/
|
|
6
52
|
withHandle?: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* Data hook for automated testing
|
|
55
|
+
*/
|
|
7
56
|
dataHook?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Tracking element identifier for analytics
|
|
59
|
+
*/
|
|
8
60
|
trackingEl?: string;
|
|
61
|
+
/**
|
|
62
|
+
* Tracking label for analytics context
|
|
63
|
+
*/
|
|
9
64
|
trackingLabel?: string;
|
|
10
65
|
}
|
|
11
|
-
|
|
66
|
+
/**
|
|
67
|
+
* Draggable handle between resizable panels.
|
|
68
|
+
*/
|
|
69
|
+
declare function ResizableHandle({ withHandle, className, dataHook, trackingEl, trackingLabel, ...props }: ResizableHandleProps): import("react/jsx-runtime").JSX.Element;
|
|
70
|
+
declare namespace ResizableHandle {
|
|
71
|
+
var displayName: string;
|
|
72
|
+
}
|
|
12
73
|
export { ResizablePanelGroup, ResizablePanel, ResizableHandle };
|
|
13
|
-
export type { ResizableHandleProps };
|
|
74
|
+
export type { ResizablePanelGroupProps, ResizablePanelProps, ResizableHandleProps, };
|
|
14
75
|
//# sourceMappingURL=resizable.d.ts.map
|
package/dist/resizable.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resizable.d.ts","sourceRoot":"","sources":["../../src/components/resizable.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,KAAK,kBAAkB,MAAM,wBAAwB,CAAC;AAI7D,
|
|
1
|
+
{"version":3,"file":"resizable.d.ts","sourceRoot":"","sources":["../../src/components/resizable.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,KAAK,kBAAkB,MAAM,wBAAwB,CAAC;AAI7D;;GAEG;AACH,UAAU,wBAAyB,SAAQ,KAAK,CAAC,cAAc,CAC7D,OAAO,kBAAkB,CAAC,UAAU,CACrC;IACC;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;GAEG;AACH,QAAA,MAAM,mBAAmB,6IAgBvB,CAAC;AAIH;;GAEG;AACH,UAAU,mBAAoB,SAAQ,KAAK,CAAC,cAAc,CACxD,OAAO,kBAAkB,CAAC,KAAK,CAChC;IACC;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;GAEG;AACH,QAAA,MAAM,cAAc,mIAYlB,CAAC;AAIH;;GAEG;AACH,UAAU,oBAAqB,SAAQ,KAAK,CAAC,cAAc,CACzD,OAAO,kBAAkB,CAAC,iBAAiB,CAC5C;IACC;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;GAEG;AACH,iBAAS,eAAe,CAAC,EACvB,UAAU,EACV,SAAS,EACT,QAAQ,EACR,UAAU,EACV,aAAa,EACb,GAAG,KAAK,EACT,EAAE,oBAAoB,2CAoBtB;kBA3BQ,eAAe;;;AA+BxB,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,eAAe,EAAE,CAAC;AAEhE,YAAY,EACV,wBAAwB,EACxB,mBAAmB,EACnB,oBAAoB,GACrB,CAAC"}
|
package/dist/resizable.js
CHANGED
|
@@ -1,46 +1,63 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import * as d from "react";
|
|
2
3
|
import { GripVertical as c } from "lucide-react";
|
|
3
|
-
import * as
|
|
4
|
-
import { cn as
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
...r
|
|
8
|
-
}) => /* @__PURE__ */ a(
|
|
9
|
-
t.PanelGroup,
|
|
4
|
+
import * as n from "react-resizable-panels";
|
|
5
|
+
import { cn as s } from "@brightlocal/ui-components/lib/utils";
|
|
6
|
+
const f = d.forwardRef(({ className: a, dataHook: e, trackingEl: r, trackingLabel: t, ...l }, o) => /* @__PURE__ */ i(
|
|
7
|
+
n.PanelGroup,
|
|
10
8
|
{
|
|
11
|
-
|
|
9
|
+
ref: o,
|
|
10
|
+
className: s(
|
|
12
11
|
"flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
|
|
13
|
-
|
|
12
|
+
a
|
|
14
13
|
),
|
|
14
|
+
"data-hook": e,
|
|
15
15
|
"data-slot": "resizable-panel-group",
|
|
16
|
-
|
|
16
|
+
"data-tracking-el": r,
|
|
17
|
+
"data-tracking-label": t,
|
|
18
|
+
...l
|
|
17
19
|
}
|
|
18
|
-
)
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
className: r,
|
|
23
|
-
dataHook: i,
|
|
24
|
-
trackingEl: o,
|
|
25
|
-
trackingLabel: n,
|
|
26
|
-
...s
|
|
27
|
-
}) => /* @__PURE__ */ a(
|
|
28
|
-
t.PanelResizeHandle,
|
|
20
|
+
));
|
|
21
|
+
f.displayName = "ResizablePanelGroup";
|
|
22
|
+
const p = d.forwardRef(({ dataHook: a, trackingEl: e, trackingLabel: r, ...t }, l) => /* @__PURE__ */ i(
|
|
23
|
+
n.Panel,
|
|
29
24
|
{
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
"data-
|
|
35
|
-
|
|
36
|
-
"data-tracking-el": o,
|
|
37
|
-
"data-tracking-label": n,
|
|
38
|
-
...s,
|
|
39
|
-
children: e && /* @__PURE__ */ a("div", { className: "border-border bg-border z-10 flex h-4 w-3 items-center justify-center rounded-xs border", children: /* @__PURE__ */ a(c, { className: "h-2.5 w-2.5" }) })
|
|
25
|
+
ref: l,
|
|
26
|
+
"data-hook": a,
|
|
27
|
+
"data-slot": "resizable-panel",
|
|
28
|
+
"data-tracking-el": e,
|
|
29
|
+
"data-tracking-label": r,
|
|
30
|
+
...t
|
|
40
31
|
}
|
|
41
|
-
);
|
|
32
|
+
));
|
|
33
|
+
p.displayName = "ResizablePanel";
|
|
34
|
+
function u({
|
|
35
|
+
withHandle: a,
|
|
36
|
+
className: e,
|
|
37
|
+
dataHook: r,
|
|
38
|
+
trackingEl: t,
|
|
39
|
+
trackingLabel: l,
|
|
40
|
+
...o
|
|
41
|
+
}) {
|
|
42
|
+
return /* @__PURE__ */ i(
|
|
43
|
+
n.PanelResizeHandle,
|
|
44
|
+
{
|
|
45
|
+
className: s(
|
|
46
|
+
"bg-border focus-visible:ring-ring relative flex w-px items-center justify-center after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-1 focus-visible:ring-offset-1 focus-visible:outline-none data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:translate-x-0 data-[panel-group-direction=vertical]:after:-translate-y-1/2 [&[data-panel-group-direction=vertical]>div]:rotate-90",
|
|
47
|
+
e
|
|
48
|
+
),
|
|
49
|
+
"data-hook": r,
|
|
50
|
+
"data-slot": "resizable-handle",
|
|
51
|
+
"data-tracking-el": t,
|
|
52
|
+
"data-tracking-label": l,
|
|
53
|
+
...o,
|
|
54
|
+
children: a && /* @__PURE__ */ i("div", { className: "border-border bg-border z-10 flex h-4 w-3 items-center justify-center rounded-xs border", children: /* @__PURE__ */ i(c, { className: "h-2.5 w-2.5" }) })
|
|
55
|
+
}
|
|
56
|
+
);
|
|
57
|
+
}
|
|
58
|
+
u.displayName = "ResizableHandle";
|
|
42
59
|
export {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
60
|
+
u as ResizableHandle,
|
|
61
|
+
p as ResizablePanel,
|
|
62
|
+
f as ResizablePanelGroup
|
|
46
63
|
};
|
package/dist/scroll-area.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),m=require("react"),p=require("@radix-ui/react-scroll-area"),d=require("@brightlocal/ui-components/lib/utils");function u(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const l=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(r,a,l.get?l:{enumerable:!0,get:()=>e[a]})}}return r.default=e,Object.freeze(r)}const b=u(m),o=u(p),f=b.forwardRef(({className:e,children:r,dataHook:a,trackingEl:l,trackingLabel:c,...s},n)=>t.jsxs(o.Root,{ref:n,className:d.cn("relative",e),"data-hook":a,"data-slot":"scroll-area","data-tracking-el":l,"data-tracking-label":c,...s,children:[t.jsx(o.Viewport,{className:"focus-visible:shadow-default size-full rounded-[inherit] p-1 transition-[color,box-shadow] outline-none","data-slot":"scroll-area-viewport",tabIndex:0,children:r}),t.jsx(i,{}),t.jsx(o.Corner,{})]}));f.displayName="ScrollArea";const i=b.forwardRef(({className:e,orientation:r="vertical",dataHook:a,trackingEl:l,trackingLabel:c,...s},n)=>t.jsx(o.ScrollAreaScrollbar,{ref:n,className:d.cn("flex touch-none p-px transition-colors select-none",r==="vertical"&&"h-full w-2.5 border-l border-l-transparent",r==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent",e),"data-hook":a,"data-slot":"scroll-area-scrollbar","data-tracking-el":l,"data-tracking-label":c,orientation:r,...s,children:t.jsx(o.ScrollAreaThumb,{className:"bg-border relative flex-1 rounded-full","data-slot":"scroll-area-thumb"})}));i.displayName="ScrollBar";exports.ScrollArea=f;exports.ScrollBar=i;
|
package/dist/scroll-area.d.ts
CHANGED
|
@@ -1,12 +1,53 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
|
|
3
|
-
|
|
3
|
+
/**
|
|
4
|
+
* Props for the ScrollArea component.
|
|
5
|
+
*/
|
|
6
|
+
interface ScrollAreaProps extends React.ComponentProps<typeof ScrollAreaPrimitive.Root> {
|
|
7
|
+
/**
|
|
8
|
+
* Data hook for automated testing (required)
|
|
9
|
+
*/
|
|
4
10
|
dataHook: string;
|
|
11
|
+
/**
|
|
12
|
+
* Tracking element identifier for analytics
|
|
13
|
+
*/
|
|
5
14
|
trackingEl?: string;
|
|
15
|
+
/**
|
|
16
|
+
* Tracking label for analytics context
|
|
17
|
+
*/
|
|
6
18
|
trackingLabel?: string;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* ScrollArea provides a styled scrollable viewport with custom scrollbars.
|
|
22
|
+
* Built on Radix UI ScrollArea primitive.
|
|
23
|
+
*/
|
|
24
|
+
declare const ScrollArea: React.ForwardRefExoticComponent<Omit<ScrollAreaProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
25
|
+
/**
|
|
26
|
+
* Props for the ScrollBar component.
|
|
27
|
+
*/
|
|
28
|
+
interface ScrollBarProps extends React.ComponentProps<typeof ScrollAreaPrimitive.ScrollAreaScrollbar> {
|
|
29
|
+
/**
|
|
30
|
+
* Data hook for automated testing
|
|
31
|
+
*/
|
|
32
|
+
dataHook?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Tracking element identifier for analytics
|
|
35
|
+
*/
|
|
36
|
+
trackingEl?: string;
|
|
37
|
+
/**
|
|
38
|
+
* Tracking label for analytics context
|
|
39
|
+
*/
|
|
40
|
+
trackingLabel?: string;
|
|
41
|
+
/**
|
|
42
|
+
* The orientation of the scrollbar
|
|
43
|
+
* @default "vertical"
|
|
44
|
+
*/
|
|
45
|
+
orientation?: "vertical" | "horizontal";
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* ScrollBar provides a styled scrollbar for ScrollArea.
|
|
49
|
+
*/
|
|
50
|
+
declare const ScrollBar: React.ForwardRefExoticComponent<Omit<ScrollBarProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
51
|
export { ScrollArea, ScrollBar };
|
|
11
|
-
export type { ScrollAreaProps };
|
|
52
|
+
export type { ScrollAreaProps, ScrollBarProps };
|
|
12
53
|
//# sourceMappingURL=scroll-area.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scroll-area.d.ts","sourceRoot":"","sources":["../../src/components/scroll-area.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAGnE,
|
|
1
|
+
{"version":3,"file":"scroll-area.d.ts","sourceRoot":"","sources":["../../src/components/scroll-area.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,mBAAmB,MAAM,6BAA6B,CAAC;AAGnE;;GAEG;AACH,UAAU,eAAgB,SAAQ,KAAK,CAAC,cAAc,CACpD,OAAO,mBAAmB,CAAC,IAAI,CAChC;IACC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;;GAGG;AACH,QAAA,MAAM,UAAU,qGA8Bf,CAAC;AAIF;;GAEG;AACH,UAAU,cAAe,SAAQ,KAAK,CAAC,cAAc,CACnD,OAAO,mBAAmB,CAAC,mBAAmB,CAC/C;IACC;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,WAAW,CAAC,EAAE,UAAU,GAAG,YAAY,CAAC;CACzC;AAED;;GAEG;AACH,QAAA,MAAM,SAAS,oGAwCd,CAAC;AAIF,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC;AAEjC,YAAY,EAAE,eAAe,EAAE,cAAc,EAAE,CAAC"}
|
package/dist/scroll-area.js
CHANGED
|
@@ -1,26 +1,21 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import * as
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
children: r,
|
|
7
|
-
|
|
8
|
-
trackingEl: s,
|
|
9
|
-
trackingLabel: c,
|
|
10
|
-
...n
|
|
11
|
-
}) {
|
|
12
|
-
return /* @__PURE__ */ i(
|
|
13
|
-
a.Root,
|
|
1
|
+
import { jsxs as f, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import * as i from "react";
|
|
3
|
+
import * as l from "@radix-ui/react-scroll-area";
|
|
4
|
+
import { cn as n } from "@brightlocal/ui-components/lib/utils";
|
|
5
|
+
const b = i.forwardRef(
|
|
6
|
+
({ className: o, children: r, dataHook: e, trackingEl: t, trackingLabel: s, ...c }, d) => /* @__PURE__ */ f(
|
|
7
|
+
l.Root,
|
|
14
8
|
{
|
|
15
|
-
|
|
9
|
+
ref: d,
|
|
10
|
+
className: n("relative", o),
|
|
16
11
|
"data-hook": e,
|
|
17
12
|
"data-slot": "scroll-area",
|
|
18
|
-
"data-tracking-el":
|
|
19
|
-
"data-tracking-label":
|
|
20
|
-
...
|
|
13
|
+
"data-tracking-el": t,
|
|
14
|
+
"data-tracking-label": s,
|
|
15
|
+
...c,
|
|
21
16
|
children: [
|
|
22
|
-
/* @__PURE__ */
|
|
23
|
-
|
|
17
|
+
/* @__PURE__ */ a(
|
|
18
|
+
l.Viewport,
|
|
24
19
|
{
|
|
25
20
|
className: "focus-visible:shadow-default size-full rounded-[inherit] p-1 transition-[color,box-shadow] outline-none",
|
|
26
21
|
"data-slot": "scroll-area-viewport",
|
|
@@ -28,40 +23,49 @@ function f({
|
|
|
28
23
|
children: r
|
|
29
24
|
}
|
|
30
25
|
),
|
|
31
|
-
/* @__PURE__ */
|
|
32
|
-
/* @__PURE__ */ l
|
|
26
|
+
/* @__PURE__ */ a(m, {}),
|
|
27
|
+
/* @__PURE__ */ a(l.Corner, {})
|
|
33
28
|
]
|
|
34
29
|
}
|
|
35
|
-
)
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
30
|
+
)
|
|
31
|
+
);
|
|
32
|
+
b.displayName = "ScrollArea";
|
|
33
|
+
const m = i.forwardRef(
|
|
34
|
+
({
|
|
35
|
+
className: o,
|
|
36
|
+
orientation: r = "vertical",
|
|
37
|
+
dataHook: e,
|
|
38
|
+
trackingEl: t,
|
|
39
|
+
trackingLabel: s,
|
|
40
|
+
...c
|
|
41
|
+
}, d) => /* @__PURE__ */ a(
|
|
42
|
+
l.ScrollAreaScrollbar,
|
|
44
43
|
{
|
|
45
|
-
|
|
44
|
+
ref: d,
|
|
45
|
+
className: n(
|
|
46
46
|
"flex touch-none p-px transition-colors select-none",
|
|
47
47
|
r === "vertical" && "h-full w-2.5 border-l border-l-transparent",
|
|
48
48
|
r === "horizontal" && "h-2.5 flex-col border-t border-t-transparent",
|
|
49
49
|
o
|
|
50
50
|
),
|
|
51
|
+
"data-hook": e,
|
|
51
52
|
"data-slot": "scroll-area-scrollbar",
|
|
53
|
+
"data-tracking-el": t,
|
|
54
|
+
"data-tracking-label": s,
|
|
52
55
|
orientation: r,
|
|
53
|
-
...
|
|
54
|
-
children: /* @__PURE__ */
|
|
55
|
-
|
|
56
|
+
...c,
|
|
57
|
+
children: /* @__PURE__ */ a(
|
|
58
|
+
l.ScrollAreaThumb,
|
|
56
59
|
{
|
|
57
60
|
className: "bg-border relative flex-1 rounded-full",
|
|
58
61
|
"data-slot": "scroll-area-thumb"
|
|
59
62
|
}
|
|
60
63
|
)
|
|
61
64
|
}
|
|
62
|
-
)
|
|
63
|
-
|
|
65
|
+
)
|
|
66
|
+
);
|
|
67
|
+
m.displayName = "ScrollBar";
|
|
64
68
|
export {
|
|
65
|
-
|
|
66
|
-
|
|
69
|
+
b as ScrollArea,
|
|
70
|
+
m as ScrollBar
|
|
67
71
|
};
|