@forgedevstack/bear 1.0.1 → 1.0.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/components/ActiveBar/ActiveBar.cjs +8 -0
- package/dist/components/ActiveBar/ActiveBar.d.ts +2 -0
- package/dist/components/ActiveBar/ActiveBar.js +90 -0
- package/dist/components/ActiveBar/ActiveBar.types.d.ts +16 -0
- package/dist/components/ActiveBar/index.d.ts +2 -0
- package/dist/components/Alert/Alert.cjs +1 -1
- package/dist/components/Alert/Alert.js +38 -38
- package/dist/components/AppBar/AppBar.cjs +1 -1
- package/dist/components/AppBar/AppBar.js +15 -15
- package/dist/components/Badge/Badge.cjs +1 -1
- package/dist/components/Badge/Badge.constants.cjs +1 -0
- package/dist/components/Badge/Badge.constants.d.ts +6 -0
- package/dist/components/Badge/Badge.constants.js +34 -0
- package/dist/components/Badge/Badge.js +27 -52
- package/dist/components/Box/Box.cjs +1 -0
- package/dist/components/Box/Box.d.ts +2 -0
- package/dist/components/Box/Box.js +64 -0
- package/dist/components/Box/Box.types.d.ts +24 -0
- package/dist/components/Box/Box.utils.cjs +1 -0
- package/dist/components/Box/Box.utils.d.ts +3 -0
- package/dist/components/Box/Box.utils.js +21 -0
- package/dist/components/Box/index.d.ts +2 -0
- package/dist/components/Button/Button.cjs +1 -57
- package/dist/components/Button/Button.constants.cjs +57 -0
- package/dist/components/Button/Button.constants.d.ts +3 -0
- package/dist/components/Button/Button.constants.js +77 -0
- package/dist/components/Button/Button.js +55 -119
- package/dist/components/Button/Button.types.d.ts +6 -1
- package/dist/components/ButtonGroup/ButtonGroup.cjs +1 -1
- package/dist/components/ButtonGroup/ButtonGroup.js +17 -17
- package/dist/components/Calendar/Calendar.cjs +1 -0
- package/dist/components/Calendar/Calendar.const.cjs +1 -0
- package/dist/components/Calendar/Calendar.const.d.ts +18 -0
- package/dist/components/Calendar/Calendar.const.js +27 -0
- package/dist/components/Calendar/Calendar.d.ts +3 -0
- package/dist/components/Calendar/Calendar.js +189 -0
- package/dist/components/Calendar/Calendar.types.d.ts +128 -0
- package/dist/components/Calendar/Calendar.utils.cjs +1 -0
- package/dist/components/Calendar/Calendar.utils.d.ts +41 -0
- package/dist/components/Calendar/Calendar.utils.js +33 -0
- package/dist/components/Calendar/index.d.ts +4 -0
- package/dist/components/Card/Card.cjs +1 -1
- package/dist/components/Card/Card.js +65 -65
- package/dist/components/Checkbox/Checkbox.cjs +1 -1
- package/dist/components/Checkbox/Checkbox.js +48 -48
- package/dist/components/CodeBlock/CodeBlock.cjs +2 -0
- package/dist/components/CodeBlock/CodeBlock.d.ts +2 -0
- package/dist/components/CodeBlock/CodeBlock.js +55 -0
- package/dist/components/CodeBlock/CodeBlock.types.d.ts +10 -0
- package/dist/components/CodeBlock/index.d.ts +2 -0
- package/dist/components/Columns/Columns.cjs +1 -0
- package/dist/components/Columns/Columns.d.ts +5 -0
- package/dist/components/Columns/Columns.js +54 -0
- package/dist/components/Columns/Columns.types.d.ts +17 -0
- package/dist/components/Columns/index.d.ts +2 -0
- package/dist/components/Container/Container.cjs +1 -1
- package/dist/components/Container/Container.js +15 -15
- package/dist/components/DatePicker/DatePicker.cjs +1 -1
- package/dist/components/DatePicker/DatePicker.js +77 -85
- package/dist/components/DatePicker/DatePicker.types.d.ts +9 -0
- package/dist/components/DatePicker/DatePicker.utils.cjs +1 -0
- package/dist/components/DatePicker/DatePicker.utils.d.ts +1 -0
- package/dist/components/DatePicker/DatePicker.utils.js +9 -0
- package/dist/components/DateTimePicker/DateTimePicker.cjs +1 -0
- package/dist/components/DateTimePicker/DateTimePicker.d.ts +3 -0
- package/dist/components/DateTimePicker/DateTimePicker.js +178 -0
- package/dist/components/DateTimePicker/DateTimePicker.types.d.ts +26 -0
- package/dist/components/DateTimePicker/DateTimePicker.utils.cjs +1 -0
- package/dist/components/DateTimePicker/DateTimePicker.utils.d.ts +2 -0
- package/dist/components/DateTimePicker/DateTimePicker.utils.js +16 -0
- package/dist/components/DateTimePicker/index.d.ts +2 -0
- package/dist/components/Divider/Divider.cjs +1 -1
- package/dist/components/Divider/Divider.js +29 -29
- package/dist/components/Dropdown/Dropdown.cjs +1 -1
- package/dist/components/Dropdown/Dropdown.js +70 -70
- package/dist/components/Editable/Editable.cjs +1 -0
- package/dist/components/Editable/Editable.d.ts +10 -0
- package/dist/components/Editable/Editable.js +194 -0
- package/dist/components/Editable/Editable.types.d.ts +39 -0
- package/dist/components/Editable/index.d.ts +2 -0
- package/dist/components/Em/Em.cjs +1 -0
- package/dist/components/Em/Em.d.ts +2 -0
- package/dist/components/Em/Em.js +24 -0
- package/dist/components/Em/Em.types.d.ts +5 -0
- package/dist/components/Em/index.d.ts +2 -0
- package/dist/components/Fab/Fab.cjs +1 -1
- package/dist/components/Fab/Fab.js +43 -43
- package/dist/components/FileUpload/FileUpload.cjs +1 -1
- package/dist/components/FileUpload/FileUpload.js +46 -49
- package/dist/components/FileUpload/FileUpload.utils.cjs +1 -0
- package/dist/components/FileUpload/FileUpload.utils.d.ts +1 -0
- package/dist/components/FileUpload/FileUpload.utils.js +9 -0
- package/dist/components/Flex/Flex.cjs +1 -1
- package/dist/components/Flex/Flex.js +58 -58
- package/dist/components/Grid/Grid.cjs +1 -1
- package/dist/components/Grid/Grid.js +60 -60
- package/dist/components/Highlight/Highlight.cjs +1 -0
- package/dist/components/Highlight/Highlight.d.ts +2 -0
- package/dist/components/Highlight/Highlight.js +28 -0
- package/dist/components/Highlight/Highlight.types.d.ts +6 -0
- package/dist/components/Highlight/index.d.ts +2 -0
- package/dist/components/HoverCard/HoverCard.cjs +6 -0
- package/dist/components/HoverCard/HoverCard.d.ts +2 -0
- package/dist/components/HoverCard/HoverCard.js +68 -0
- package/dist/components/HoverCard/HoverCard.types.d.ts +13 -0
- package/dist/components/HoverCard/HoverCard.utils.cjs +1 -0
- package/dist/components/HoverCard/HoverCard.utils.d.ts +2 -0
- package/dist/components/HoverCard/HoverCard.utils.js +23 -0
- package/dist/components/HoverCard/index.d.ts +2 -0
- package/dist/components/Icon/icons/status.js +1 -1
- package/dist/components/Icon/index.cjs +1 -1
- package/dist/components/Icon/index.d.ts +5 -0
- package/dist/components/Icon/index.js +28 -21
- package/dist/components/Link/Link.cjs +1 -1
- package/dist/components/Link/Link.js +47 -47
- package/dist/components/List/List.cjs +1 -1
- package/dist/components/List/List.js +117 -117
- package/dist/components/Mark/Mark.cjs +1 -0
- package/dist/components/Mark/Mark.d.ts +2 -0
- package/dist/components/Mark/Mark.js +26 -0
- package/dist/components/Mark/Mark.types.d.ts +5 -0
- package/dist/components/Mark/index.d.ts +2 -0
- package/dist/components/Menu/Menu.cjs +1 -1
- package/dist/components/Menu/Menu.js +58 -58
- package/dist/components/Paper/Paper.cjs +1 -1
- package/dist/components/Paper/Paper.js +36 -36
- package/dist/components/Radio/Radio.cjs +1 -1
- package/dist/components/Radio/Radio.js +79 -79
- package/dist/components/Rating/Rating.cjs +1 -1
- package/dist/components/Rating/Rating.js +37 -37
- package/dist/components/RichEditor/RichEditor.cjs +10 -0
- package/dist/components/RichEditor/RichEditor.d.ts +4 -0
- package/dist/components/RichEditor/RichEditor.icons.cjs +1 -0
- package/dist/components/RichEditor/RichEditor.icons.d.ts +16 -0
- package/dist/components/RichEditor/RichEditor.icons.js +62 -0
- package/dist/components/RichEditor/RichEditor.js +151 -0
- package/dist/components/RichEditor/RichEditor.types.d.ts +20 -0
- package/dist/components/RichEditor/RichEditor.utils.cjs +1 -0
- package/dist/components/RichEditor/RichEditor.utils.d.ts +3 -0
- package/dist/components/RichEditor/RichEditor.utils.js +22 -0
- package/dist/components/RichEditor/index.d.ts +2 -0
- package/dist/components/Sidebar/Sidebar.cjs +1 -0
- package/dist/components/Sidebar/Sidebar.d.ts +5 -0
- package/dist/components/Sidebar/Sidebar.js +158 -0
- package/dist/components/Sidebar/Sidebar.types.d.ts +40 -0
- package/dist/components/Sidebar/index.d.ts +2 -0
- package/dist/components/Slider/Slider.cjs +1 -1
- package/dist/components/Slider/Slider.js +8 -8
- package/dist/components/SpeedDial/SpeedDial.cjs +1 -1
- package/dist/components/SpeedDial/SpeedDial.js +40 -40
- package/dist/components/Spinner/Spinner.cjs +1 -1
- package/dist/components/Spinner/Spinner.js +24 -24
- package/dist/components/TimePicker/TimePicker.cjs +1 -1
- package/dist/components/TimePicker/TimePicker.constants.cjs +1 -0
- package/dist/components/TimePicker/TimePicker.constants.d.ts +5 -0
- package/dist/components/TimePicker/TimePicker.constants.js +16 -0
- package/dist/components/TimePicker/TimePicker.js +91 -70
- package/dist/components/TimePicker/TimePicker.types.d.ts +5 -2
- package/dist/components/TimePicker/TimePicker.utils.cjs +1 -0
- package/dist/components/TimePicker/TimePicker.utils.d.ts +1 -0
- package/dist/components/TimePicker/TimePicker.utils.js +7 -0
- package/dist/components/TransferList/TransferList.cjs +1 -1
- package/dist/components/TransferList/TransferList.js +74 -74
- package/dist/components/Typography/Typography.cjs +1 -1
- package/dist/components/Typography/Typography.js +52 -52
- package/dist/components/index.cjs +1 -1
- package/dist/components/index.d.ts +26 -0
- package/dist/components/index.js +119 -91
- package/dist/context/BearProvider.cjs +1 -1
- package/dist/context/BearProvider.d.ts +6 -1
- package/dist/context/BearProvider.js +42 -38
- package/dist/context/index.cjs +1 -1
- package/dist/context/index.d.ts +1 -1
- package/dist/context/index.js +6 -5
- package/dist/hooks/bearStyled.cjs +1 -0
- package/dist/hooks/bearStyled.d.ts +17 -0
- package/dist/hooks/bearStyled.js +17 -0
- package/dist/hooks/index.cjs +1 -1
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/index.js +14 -10
- package/dist/hooks/useBearStyles.cjs +1 -0
- package/dist/hooks/useBearStyles.d.ts +11 -0
- package/dist/hooks/useBearStyles.js +14 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +146 -113
- package/dist/styles.css +1 -1
- package/dist/types/bis.types.d.ts +9 -0
- package/dist/types/component.types.d.ts +3 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +2 -2
|
@@ -2,88 +2,88 @@ import { jsx as f } from "react/jsx-runtime";
|
|
|
2
2
|
import { forwardRef as u } from "react";
|
|
3
3
|
import { cn as w } from "../../utils/cn.js";
|
|
4
4
|
const v = {
|
|
5
|
-
none: "
|
|
6
|
-
1: "
|
|
7
|
-
2: "
|
|
8
|
-
3: "
|
|
9
|
-
4: "
|
|
10
|
-
5: "
|
|
11
|
-
6: "
|
|
12
|
-
7: "
|
|
13
|
-
8: "
|
|
14
|
-
9: "
|
|
15
|
-
10: "
|
|
16
|
-
11: "
|
|
17
|
-
12: "
|
|
5
|
+
none: "bear-grid-cols-none",
|
|
6
|
+
1: "bear-grid-cols-1",
|
|
7
|
+
2: "bear-grid-cols-2",
|
|
8
|
+
3: "bear-grid-cols-3",
|
|
9
|
+
4: "bear-grid-cols-4",
|
|
10
|
+
5: "bear-grid-cols-5",
|
|
11
|
+
6: "bear-grid-cols-6",
|
|
12
|
+
7: "bear-grid-cols-7",
|
|
13
|
+
8: "bear-grid-cols-8",
|
|
14
|
+
9: "bear-grid-cols-9",
|
|
15
|
+
10: "bear-grid-cols-10",
|
|
16
|
+
11: "bear-grid-cols-11",
|
|
17
|
+
12: "bear-grid-cols-12"
|
|
18
18
|
}, C = {
|
|
19
|
-
0: "
|
|
20
|
-
1: "
|
|
21
|
-
2: "
|
|
22
|
-
3: "
|
|
23
|
-
4: "
|
|
24
|
-
5: "
|
|
25
|
-
6: "
|
|
26
|
-
8: "
|
|
27
|
-
10: "
|
|
28
|
-
12: "
|
|
29
|
-
16: "
|
|
19
|
+
0: "bear-gap-0",
|
|
20
|
+
1: "bear-gap-1",
|
|
21
|
+
2: "bear-gap-2",
|
|
22
|
+
3: "bear-gap-3",
|
|
23
|
+
4: "bear-gap-4",
|
|
24
|
+
5: "bear-gap-5",
|
|
25
|
+
6: "bear-gap-6",
|
|
26
|
+
8: "bear-gap-8",
|
|
27
|
+
10: "bear-gap-10",
|
|
28
|
+
12: "bear-gap-12",
|
|
29
|
+
16: "bear-gap-16"
|
|
30
30
|
}, y = {
|
|
31
|
-
row: "
|
|
32
|
-
column: "
|
|
33
|
-
dense: "
|
|
34
|
-
"row-dense": "
|
|
35
|
-
"column-dense": "
|
|
36
|
-
},
|
|
37
|
-
if (
|
|
38
|
-
return typeof
|
|
31
|
+
row: "bear-grid-flow-row",
|
|
32
|
+
column: "bear-grid-flow-col",
|
|
33
|
+
dense: "bear-grid-flow-dense",
|
|
34
|
+
"row-dense": "bear-grid-flow-row-dense",
|
|
35
|
+
"column-dense": "bear-grid-flow-col-dense"
|
|
36
|
+
}, a = (r) => {
|
|
37
|
+
if (r !== void 0)
|
|
38
|
+
return typeof r == "object" ? r.base : r;
|
|
39
39
|
}, G = u(
|
|
40
40
|
({
|
|
41
|
-
cols:
|
|
42
|
-
gap:
|
|
43
|
-
rowGap:
|
|
44
|
-
colGap:
|
|
45
|
-
flow:
|
|
46
|
-
className:
|
|
47
|
-
children:
|
|
48
|
-
testId:
|
|
49
|
-
...
|
|
50
|
-
},
|
|
51
|
-
const l = r
|
|
41
|
+
cols: r = 1,
|
|
42
|
+
gap: d = 0,
|
|
43
|
+
rowGap: b,
|
|
44
|
+
colGap: g,
|
|
45
|
+
flow: o,
|
|
46
|
+
className: c,
|
|
47
|
+
children: i,
|
|
48
|
+
testId: n,
|
|
49
|
+
...e
|
|
50
|
+
}, s) => {
|
|
51
|
+
const l = a(r), t = a(d), p = a(b), m = a(g);
|
|
52
52
|
return /* @__PURE__ */ f(
|
|
53
53
|
"div",
|
|
54
54
|
{
|
|
55
|
-
ref:
|
|
55
|
+
ref: s,
|
|
56
56
|
className: w(
|
|
57
|
-
"
|
|
57
|
+
"bear-grid",
|
|
58
58
|
l !== void 0 && v[l],
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
59
|
+
t !== void 0 && C[t],
|
|
60
|
+
p !== void 0 && `bear-gap-y-${p}`,
|
|
61
|
+
m !== void 0 && `bear-gap-x-${m}`,
|
|
62
|
+
o && y[o],
|
|
63
|
+
c
|
|
64
64
|
),
|
|
65
|
-
"data-testid":
|
|
66
|
-
...
|
|
67
|
-
children:
|
|
65
|
+
"data-testid": n,
|
|
66
|
+
...e,
|
|
67
|
+
children: i
|
|
68
68
|
}
|
|
69
69
|
);
|
|
70
70
|
}
|
|
71
71
|
);
|
|
72
72
|
G.displayName = "Grid";
|
|
73
73
|
const V = u(
|
|
74
|
-
({ colSpan:
|
|
75
|
-
const
|
|
74
|
+
({ colSpan: r, rowSpan: d, colStart: b, colEnd: g, className: o, children: c, ...i }, n) => {
|
|
75
|
+
const e = a(r), s = a(d), l = e === "full" ? "bear-col-span-full" : e ? `bear-col-span-${e}` : "";
|
|
76
76
|
return /* @__PURE__ */ f(
|
|
77
77
|
"div",
|
|
78
78
|
{
|
|
79
|
-
ref:
|
|
79
|
+
ref: n,
|
|
80
80
|
className: w(
|
|
81
81
|
l,
|
|
82
|
-
|
|
83
|
-
|
|
82
|
+
s && `bear-row-span-${s}`,
|
|
83
|
+
o
|
|
84
84
|
),
|
|
85
|
-
...
|
|
86
|
-
children:
|
|
85
|
+
...i,
|
|
86
|
+
children: c
|
|
87
87
|
}
|
|
88
88
|
);
|
|
89
89
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),t=require("react"),b={yellow:"bg-yellow-200 dark:bg-yellow-500/30",pink:"bg-pink-200 dark:bg-pink-500/30",blue:"bg-blue-200 dark:bg-blue-500/30",green:"bg-green-200 dark:bg-green-500/30",purple:"bg-purple-200 dark:bg-purple-500/30",orange:"bg-orange-200 dark:bg-orange-500/30"},e=t.forwardRef(({children:r,color:g="yellow",animated:l=!1,className:a="",...i},n)=>o.jsx("span",{ref:n,className:`bear-highlight px-1 rounded ${b[g]} ${l?"animate-pulse":""} ${a}`.trim(),...i,children:r}));e.displayName="Highlight";exports.Highlight=e;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsx as b } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as p } from "react";
|
|
3
|
+
const n = {
|
|
4
|
+
yellow: "bg-yellow-200 dark:bg-yellow-500/30",
|
|
5
|
+
pink: "bg-pink-200 dark:bg-pink-500/30",
|
|
6
|
+
blue: "bg-blue-200 dark:bg-blue-500/30",
|
|
7
|
+
green: "bg-green-200 dark:bg-green-500/30",
|
|
8
|
+
purple: "bg-purple-200 dark:bg-purple-500/30",
|
|
9
|
+
orange: "bg-orange-200 dark:bg-orange-500/30"
|
|
10
|
+
}, i = p(({
|
|
11
|
+
children: e,
|
|
12
|
+
color: r = "yellow",
|
|
13
|
+
animated: g = !1,
|
|
14
|
+
className: l = "",
|
|
15
|
+
...a
|
|
16
|
+
}, o) => /* @__PURE__ */ b(
|
|
17
|
+
"span",
|
|
18
|
+
{
|
|
19
|
+
ref: o,
|
|
20
|
+
className: `bear-highlight px-1 rounded ${n[r]} ${g ? "animate-pulse" : ""} ${l}`.trim(),
|
|
21
|
+
...a,
|
|
22
|
+
children: e
|
|
23
|
+
}
|
|
24
|
+
));
|
|
25
|
+
i.displayName = "Highlight";
|
|
26
|
+
export {
|
|
27
|
+
i as Highlight
|
|
28
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),t=require("react"),u=require("./HoverCard.utils.cjs"),c=t.forwardRef(({children:l,cardContent:d,side:o="bottom",align:b="center",openDelay:m=200,closeDelay:v=300,arrow:f=!0,className:g="",...p},y)=>{const[h,a]=t.useState(!1),e=t.useRef(),r=t.useRef(),n=()=>{r.current&&clearTimeout(r.current),e.current=setTimeout(()=>{a(!0)},m)},i=()=>{e.current&&clearTimeout(e.current),r.current=setTimeout(()=>{a(!1)},v)};return t.useEffect(()=>()=>{e.current&&clearTimeout(e.current),r.current&&clearTimeout(r.current)},[]),s.jsxs("div",{ref:y,className:`bear-hover-card relative inline-block ${g}`.trim(),onMouseEnter:n,onMouseLeave:i,...p,children:[l,s.jsx("div",{className:`
|
|
2
|
+
absolute z-50 w-72
|
|
3
|
+
${u.getSideClasses(o,b)}
|
|
4
|
+
transition-all duration-200
|
|
5
|
+
${h?"opacity-100 visible scale-100":"opacity-0 invisible scale-95 pointer-events-none"}
|
|
6
|
+
`,onMouseEnter:n,onMouseLeave:i,children:s.jsxs("div",{className:"bg-white dark:bg-gray-800 rounded-lg shadow-xl border border-gray-200 dark:border-gray-700 p-4",children:[f&&s.jsx("div",{className:`absolute w-3 h-3 bg-white dark:bg-gray-800 border-gray-200 dark:border-gray-700 ${u.getArrowClasses(o)}`,style:{borderWidth:o==="top"||o==="left"?"0 1px 1px 0":"1px 0 0 1px"}}),d]})})]})});c.displayName="HoverCard";exports.HoverCard=c;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { jsxs as n, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as y, useState as x, useRef as c, useEffect as T } from "react";
|
|
3
|
+
import { getArrowClasses as w, getSideClasses as M } from "./HoverCard.utils.js";
|
|
4
|
+
const k = y(({
|
|
5
|
+
children: u,
|
|
6
|
+
cardContent: l,
|
|
7
|
+
side: t = "bottom",
|
|
8
|
+
align: d = "center",
|
|
9
|
+
openDelay: m = 200,
|
|
10
|
+
closeDelay: b = 300,
|
|
11
|
+
arrow: f = !0,
|
|
12
|
+
className: p = "",
|
|
13
|
+
...v
|
|
14
|
+
}, g) => {
|
|
15
|
+
const [h, o] = x(!1), e = c(), r = c(), a = () => {
|
|
16
|
+
r.current && clearTimeout(r.current), e.current = setTimeout(() => {
|
|
17
|
+
o(!0);
|
|
18
|
+
}, m);
|
|
19
|
+
}, s = () => {
|
|
20
|
+
e.current && clearTimeout(e.current), r.current = setTimeout(() => {
|
|
21
|
+
o(!1);
|
|
22
|
+
}, b);
|
|
23
|
+
};
|
|
24
|
+
return T(() => () => {
|
|
25
|
+
e.current && clearTimeout(e.current), r.current && clearTimeout(r.current);
|
|
26
|
+
}, []), /* @__PURE__ */ n(
|
|
27
|
+
"div",
|
|
28
|
+
{
|
|
29
|
+
ref: g,
|
|
30
|
+
className: `bear-hover-card relative inline-block ${p}`.trim(),
|
|
31
|
+
onMouseEnter: a,
|
|
32
|
+
onMouseLeave: s,
|
|
33
|
+
...v,
|
|
34
|
+
children: [
|
|
35
|
+
u,
|
|
36
|
+
/* @__PURE__ */ i(
|
|
37
|
+
"div",
|
|
38
|
+
{
|
|
39
|
+
className: `
|
|
40
|
+
absolute z-50 w-72
|
|
41
|
+
${M(t, d)}
|
|
42
|
+
transition-all duration-200
|
|
43
|
+
${h ? "opacity-100 visible scale-100" : "opacity-0 invisible scale-95 pointer-events-none"}
|
|
44
|
+
`,
|
|
45
|
+
onMouseEnter: a,
|
|
46
|
+
onMouseLeave: s,
|
|
47
|
+
children: /* @__PURE__ */ n("div", { className: "bg-white dark:bg-gray-800 rounded-lg shadow-xl border border-gray-200 dark:border-gray-700 p-4", children: [
|
|
48
|
+
f && /* @__PURE__ */ i(
|
|
49
|
+
"div",
|
|
50
|
+
{
|
|
51
|
+
className: `absolute w-3 h-3 bg-white dark:bg-gray-800 border-gray-200 dark:border-gray-700 ${w(t)}`,
|
|
52
|
+
style: {
|
|
53
|
+
borderWidth: t === "top" || t === "left" ? "0 1px 1px 0" : "1px 0 0 1px"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
),
|
|
57
|
+
l
|
|
58
|
+
] })
|
|
59
|
+
}
|
|
60
|
+
)
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
);
|
|
64
|
+
});
|
|
65
|
+
k.displayName = "HoverCard";
|
|
66
|
+
export {
|
|
67
|
+
k as HoverCard
|
|
68
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
2
|
+
export interface HoverCardProps extends Omit<HTMLAttributes<HTMLDivElement>, 'content'> {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
cardContent: ReactNode;
|
|
5
|
+
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
6
|
+
align?: 'start' | 'center' | 'end';
|
|
7
|
+
openDelay?: number;
|
|
8
|
+
closeDelay?: number;
|
|
9
|
+
arrow?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export interface HoverCardContentProps extends HTMLAttributes<HTMLDivElement> {
|
|
12
|
+
children?: ReactNode;
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=(t,e)=>{const r={top:"bottom-full mb-2",bottom:"top-full mt-2",left:"right-full mr-2",right:"left-full ml-2"},s={top:{start:"left-0",center:"left-1/2 -translate-x-1/2",end:"right-0"},bottom:{start:"left-0",center:"left-1/2 -translate-x-1/2",end:"right-0"},left:{start:"top-0",center:"top-1/2 -translate-y-1/2",end:"bottom-0"},right:{start:"top-0",center:"top-1/2 -translate-y-1/2",end:"bottom-0"}};return`${r[t]} ${s[t][e]}`},l=t=>({top:"bottom-0 left-1/2 -translate-x-1/2 translate-y-1/2 rotate-45",bottom:"top-0 left-1/2 -translate-x-1/2 -translate-y-1/2 rotate-45",left:"right-0 top-1/2 translate-x-1/2 -translate-y-1/2 rotate-45",right:"left-0 top-1/2 -translate-x-1/2 -translate-y-1/2 rotate-45"})[t];exports.getArrowClasses=l;exports.getSideClasses=a;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
const l = (t, e) => {
|
|
2
|
+
const r = {
|
|
3
|
+
top: "bottom-full mb-2",
|
|
4
|
+
bottom: "top-full mt-2",
|
|
5
|
+
left: "right-full mr-2",
|
|
6
|
+
right: "left-full ml-2"
|
|
7
|
+
}, a = {
|
|
8
|
+
top: { start: "left-0", center: "left-1/2 -translate-x-1/2", end: "right-0" },
|
|
9
|
+
bottom: { start: "left-0", center: "left-1/2 -translate-x-1/2", end: "right-0" },
|
|
10
|
+
left: { start: "top-0", center: "top-1/2 -translate-y-1/2", end: "bottom-0" },
|
|
11
|
+
right: { start: "top-0", center: "top-1/2 -translate-y-1/2", end: "bottom-0" }
|
|
12
|
+
};
|
|
13
|
+
return `${r[t]} ${a[t][e]}`;
|
|
14
|
+
}, s = (t) => ({
|
|
15
|
+
top: "bottom-0 left-1/2 -translate-x-1/2 translate-y-1/2 rotate-45",
|
|
16
|
+
bottom: "top-0 left-1/2 -translate-x-1/2 -translate-y-1/2 rotate-45",
|
|
17
|
+
left: "right-0 top-1/2 translate-x-1/2 -translate-y-1/2 rotate-45",
|
|
18
|
+
right: "left-0 top-1/2 -translate-x-1/2 -translate-y-1/2 rotate-45"
|
|
19
|
+
})[t];
|
|
20
|
+
export {
|
|
21
|
+
s as getArrowClasses,
|
|
22
|
+
l as getSideClasses
|
|
23
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { jsx as c, jsxs as e } from "react/jsx-runtime";
|
|
2
2
|
import { Icon as l } from "../Icon.js";
|
|
3
3
|
const h = (n) => /* @__PURE__ */ c(l, { ...n, children: /* @__PURE__ */ c("polyline", { points: "20 6 9 17 4 12" }) }), o = (n) => /* @__PURE__ */ e(l, { ...n, children: [
|
|
4
4
|
/* @__PURE__ */ c("path", { d: "M22 11.08V12a10 10 0 1 1-5.93-9.14" }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("react/jsx-runtime");const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("react/jsx-runtime");const n=require("./icons/action.cjs"),o=require("./icons/navigation.cjs"),t=require("./icons/content.cjs"),r=require("./icons/communication.cjs"),c=require("./icons/status.cjs"),i=require("./icons/media.cjs"),s=require("./icons/editor.cjs"),e=require("./icons/misc.cjs"),I=c.CheckIcon,h=o.CloseIcon,C=n.EditIcon,v=o.ChevronDownIcon,u=o.ChevronRightIcon,a=o.ChevronLeftIcon,g=o.ChevronsLeftIcon,d=o.ChevronsRightIcon,q=e.XIcon,f={...n,...o,...t,...r,...c,...i,...s,...e,Action:n,Navigation:o,Content:t,Communication:r,Status:c,Media:i,Editor:s,Misc:e};exports.BearIcons=f;exports.CheckIcon=I;exports.ChevronDownIcon=v;exports.ChevronLeftIcon=a;exports.ChevronRightIcon=u;exports.ChevronsLeftIcon=g;exports.ChevronsRightIcon=d;exports.CloseIcon=h;exports.EditIcon=C;exports.XIcon=q;
|
|
@@ -16,10 +16,15 @@ import * as EditorIcons from './icons/editor';
|
|
|
16
16
|
import * as MiscIcons from './icons/misc';
|
|
17
17
|
export declare const CheckIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
18
18
|
export declare const CloseIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
19
|
+
export declare const EditIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
19
20
|
export declare const ChevronDownIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
20
21
|
export declare const ChevronRightIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
21
22
|
export declare const ChevronLeftIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
22
23
|
export declare const ChevronUpIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
24
|
+
export declare const ChevronsUpIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
25
|
+
export declare const ChevronsDownIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
26
|
+
export declare const ChevronsLeftIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
27
|
+
export declare const ChevronsRightIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
23
28
|
export declare const MenuIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
24
29
|
export declare const SearchIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
25
30
|
export declare const SettingsIcon: import('react').FunctionComponent<Omit<import('./Icon.types').IconProps, "children">>;
|
|
@@ -1,38 +1,45 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import * as o from "./icons/action.js";
|
|
3
|
+
import { EditIcon as m } from "./icons/action.js";
|
|
3
4
|
import * as n from "./icons/navigation.js";
|
|
4
|
-
import { ChevronDownIcon as
|
|
5
|
+
import { CloseIcon as a, ChevronDownIcon as I, ChevronRightIcon as h, ChevronLeftIcon as C, ChevronsLeftIcon as f, ChevronsRightIcon as v } from "./icons/navigation.js";
|
|
5
6
|
import * as t from "./icons/content.js";
|
|
6
|
-
import * as
|
|
7
|
-
import * as
|
|
8
|
-
import { CheckIcon as
|
|
9
|
-
import * as
|
|
10
|
-
import * as
|
|
11
|
-
import * as
|
|
12
|
-
import { XIcon as
|
|
13
|
-
const
|
|
7
|
+
import * as c from "./icons/communication.js";
|
|
8
|
+
import * as r from "./icons/status.js";
|
|
9
|
+
import { CheckIcon as p } from "./icons/status.js";
|
|
10
|
+
import * as s from "./icons/media.js";
|
|
11
|
+
import * as i from "./icons/editor.js";
|
|
12
|
+
import * as e from "./icons/misc.js";
|
|
13
|
+
import { XIcon as $ } from "./icons/misc.js";
|
|
14
|
+
const E = p, k = a, l = m, w = I, D = h, X = C, M = f, x = v, A = $, B = {
|
|
14
15
|
// Flat access to common icons (shortcuts)
|
|
15
16
|
...o,
|
|
16
17
|
...n,
|
|
17
18
|
...t,
|
|
19
|
+
...c,
|
|
18
20
|
...r,
|
|
19
|
-
...
|
|
21
|
+
...s,
|
|
20
22
|
...i,
|
|
21
|
-
...
|
|
22
|
-
...a,
|
|
23
|
+
...e,
|
|
23
24
|
// Category-based access
|
|
24
25
|
Action: o,
|
|
25
26
|
Navigation: n,
|
|
26
27
|
Content: t,
|
|
27
|
-
Communication:
|
|
28
|
-
Status:
|
|
29
|
-
Media:
|
|
30
|
-
Editor:
|
|
31
|
-
Misc:
|
|
28
|
+
Communication: c,
|
|
29
|
+
Status: r,
|
|
30
|
+
Media: s,
|
|
31
|
+
Editor: i,
|
|
32
|
+
Misc: e
|
|
32
33
|
};
|
|
33
34
|
export {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
35
|
+
B as BearIcons,
|
|
36
|
+
E as CheckIcon,
|
|
37
|
+
w as ChevronDownIcon,
|
|
38
|
+
X as ChevronLeftIcon,
|
|
39
|
+
D as ChevronRightIcon,
|
|
40
|
+
M as ChevronsLeftIcon,
|
|
41
|
+
x as ChevronsRightIcon,
|
|
42
|
+
k as CloseIcon,
|
|
43
|
+
l as EditIcon,
|
|
44
|
+
A as XIcon
|
|
38
45
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),y=require("react"),v=require("../../utils/cn.cjs"),f={primary:"bear-text-pink-500 hover:bear-text-pink-600",secondary:"bear-text-gray-600 hover:bear-text-gray-700",success:"bear-text-green-500 hover:bear-text-green-600",danger:"bear-text-red-500 hover:bear-text-red-600",warning:"bear-text-amber-500 hover:bear-text-amber-600",info:"bear-text-blue-500 hover:bear-text-blue-600",ghost:"bear-text-gray-500 hover:bear-text-gray-600",outline:"bear-text-gray-700 hover:bear-text-gray-800",error:"bear-text-red-500 hover:bear-text-red-600",inherit:"bear-text-inherit"},p={none:"bear-no-underline",hover:"bear-no-underline hover:bear-underline",always:"bear-underline"},k=()=>e.jsxs("svg",{width:12,height:12,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,className:"bear-inline-block bear-ml-1",children:[e.jsx("path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"}),e.jsx("polyline",{points:"15 3 21 3 21 9"}),e.jsx("line",{x1:"10",y1:"14",x2:"21",y2:"3"})]}),o=y.forwardRef(({variant:i="primary",underline:s="hover",color:r,external:t=!1,showExternalIcon:b=!0,children:x,className:l,style:c,testId:u,target:a,rel:n,...d},h)=>{const g=t?{target:a||"_blank",rel:n||"noopener noreferrer"}:{target:a,rel:n};return e.jsxs("a",{ref:h,className:v.cn("bear-cursor-pointer bear-transition-colors bear-duration-200","focus:bear-outline-none focus:bear-ring-2 focus:bear-ring-pink-500 focus:bear-ring-offset-2 bear-rounded",!r&&f[i],p[s],l),style:{...c,...r&&{color:r}},"data-testid":u,...g,...d,children:[x,t&&b&&e.jsx(k,{})]})});o.displayName="Link";exports.Link=o;
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { cn as
|
|
4
|
-
const
|
|
5
|
-
primary: "
|
|
6
|
-
secondary: "
|
|
7
|
-
success: "
|
|
8
|
-
danger: "
|
|
9
|
-
warning: "
|
|
10
|
-
info: "
|
|
11
|
-
ghost: "
|
|
12
|
-
outline: "
|
|
13
|
-
error: "
|
|
14
|
-
inherit: "
|
|
15
|
-
},
|
|
16
|
-
none: "
|
|
17
|
-
hover: "
|
|
18
|
-
always: "
|
|
19
|
-
},
|
|
1
|
+
import { jsxs as o, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as p } from "react";
|
|
3
|
+
import { cn as f } from "../../utils/cn.js";
|
|
4
|
+
const v = {
|
|
5
|
+
primary: "bear-text-pink-500 hover:bear-text-pink-600",
|
|
6
|
+
secondary: "bear-text-gray-600 hover:bear-text-gray-700",
|
|
7
|
+
success: "bear-text-green-500 hover:bear-text-green-600",
|
|
8
|
+
danger: "bear-text-red-500 hover:bear-text-red-600",
|
|
9
|
+
warning: "bear-text-amber-500 hover:bear-text-amber-600",
|
|
10
|
+
info: "bear-text-blue-500 hover:bear-text-blue-600",
|
|
11
|
+
ghost: "bear-text-gray-500 hover:bear-text-gray-600",
|
|
12
|
+
outline: "bear-text-gray-700 hover:bear-text-gray-800",
|
|
13
|
+
error: "bear-text-red-500 hover:bear-text-red-600",
|
|
14
|
+
inherit: "bear-text-inherit"
|
|
15
|
+
}, y = {
|
|
16
|
+
none: "bear-no-underline",
|
|
17
|
+
hover: "bear-no-underline hover:bear-underline",
|
|
18
|
+
always: "bear-underline"
|
|
19
|
+
}, m = () => /* @__PURE__ */ o(
|
|
20
20
|
"svg",
|
|
21
21
|
{
|
|
22
22
|
width: 12,
|
|
@@ -25,52 +25,52 @@ const f = {
|
|
|
25
25
|
fill: "none",
|
|
26
26
|
stroke: "currentColor",
|
|
27
27
|
strokeWidth: 2,
|
|
28
|
-
className: "
|
|
28
|
+
className: "bear-inline-block bear-ml-1",
|
|
29
29
|
children: [
|
|
30
30
|
/* @__PURE__ */ e("path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6" }),
|
|
31
31
|
/* @__PURE__ */ e("polyline", { points: "15 3 21 3 21 9" }),
|
|
32
32
|
/* @__PURE__ */ e("line", { x1: "10", y1: "14", x2: "21", y2: "3" })
|
|
33
33
|
]
|
|
34
34
|
}
|
|
35
|
-
), k =
|
|
35
|
+
), k = p(({
|
|
36
36
|
variant: i = "primary",
|
|
37
37
|
underline: b = "hover",
|
|
38
38
|
color: r,
|
|
39
39
|
external: t = !1,
|
|
40
40
|
showExternalIcon: s = !0,
|
|
41
|
-
children:
|
|
42
|
-
className:
|
|
43
|
-
style:
|
|
44
|
-
testId:
|
|
45
|
-
target:
|
|
46
|
-
rel:
|
|
47
|
-
...
|
|
48
|
-
},
|
|
49
|
-
const
|
|
50
|
-
target:
|
|
51
|
-
rel:
|
|
52
|
-
} : { target:
|
|
53
|
-
return /* @__PURE__ */
|
|
41
|
+
children: l,
|
|
42
|
+
className: x,
|
|
43
|
+
style: h,
|
|
44
|
+
testId: d,
|
|
45
|
+
target: a,
|
|
46
|
+
rel: n,
|
|
47
|
+
...c
|
|
48
|
+
}, u) => {
|
|
49
|
+
const g = t ? {
|
|
50
|
+
target: a || "_blank",
|
|
51
|
+
rel: n || "noopener noreferrer"
|
|
52
|
+
} : { target: a, rel: n };
|
|
53
|
+
return /* @__PURE__ */ o(
|
|
54
54
|
"a",
|
|
55
55
|
{
|
|
56
|
-
ref:
|
|
57
|
-
className:
|
|
58
|
-
"
|
|
59
|
-
"focus:
|
|
60
|
-
!r &&
|
|
61
|
-
|
|
62
|
-
|
|
56
|
+
ref: u,
|
|
57
|
+
className: f(
|
|
58
|
+
"bear-cursor-pointer bear-transition-colors bear-duration-200",
|
|
59
|
+
"focus:bear-outline-none focus:bear-ring-2 focus:bear-ring-pink-500 focus:bear-ring-offset-2 bear-rounded",
|
|
60
|
+
!r && v[i],
|
|
61
|
+
y[b],
|
|
62
|
+
x
|
|
63
63
|
),
|
|
64
64
|
style: {
|
|
65
|
-
...
|
|
65
|
+
...h,
|
|
66
66
|
...r && { color: r }
|
|
67
67
|
},
|
|
68
|
-
"data-testid":
|
|
69
|
-
...
|
|
70
|
-
...
|
|
68
|
+
"data-testid": d,
|
|
69
|
+
...g,
|
|
70
|
+
...c,
|
|
71
71
|
children: [
|
|
72
|
-
|
|
73
|
-
t && s && /* @__PURE__ */ e(
|
|
72
|
+
l,
|
|
73
|
+
t && s && /* @__PURE__ */ e(m, {})
|
|
74
74
|
]
|
|
75
75
|
}
|
|
76
76
|
);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),c=require("react"),i=require("../../utils/cn.cjs"),u=c.createContext({}),w=()=>c.useContext(u),v=c.forwardRef(({variant:r="default",size:e="md",hoverable:b=!1,dense:a=!1,disablePadding:n=!1,className:t,children:x,testId:l,...y},o)=>{const g={xs:"bear-text-xs",sm:"bear-text-sm",md:"bear-text-base",lg:"bear-text-lg",xl:"bear-text-xl"},m={default:"",bordered:"bear-border bear-border-gray-200 dark:bear-border-gray-700 bear-rounded-lg",divided:"[&>li:not(:last-child)]:bear-border-b [&>li:not(:last-child)]:bear-border-gray-200 dark:[&>li:not(:last-child)]:bear-border-gray-700"};return s.jsx(u.Provider,{value:{dense:a,hoverable:b},children:s.jsx("ul",{ref:o,role:"list",className:i.cn("bear-list-none bear-m-0",!n&&"bear-py-2",g[e],m[r],t),"data-testid":l,...y,children:x})})});v.displayName="List";const h=c.forwardRef(({primary:r,secondary:e,leading:b,trailing:a,selected:n=!1,disabled:t=!1,clickable:x=!1,divider:l=!1,dense:y,onClick:o,className:g,children:m,testId:j,...k},L)=>{const{dense:N,hoverable:I}=w(),p=y??N,d=x||!!o;return s.jsxs("li",{ref:L,role:d?"button":"listitem",tabIndex:d&&!t?0:void 0,"aria-selected":n,"aria-disabled":t,onClick:t?void 0:o,onKeyDown:f=>{!t&&(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),o==null||o())},className:i.cn("bear-flex bear-items-center bear-gap-3",p?"bear-py-1 bear-px-3":"bear-py-2 bear-px-4",d&&!t&&"bear-cursor-pointer",(I||d)&&!t&&"hover:bear-bg-gray-100 dark:hover:bear-bg-gray-800",n&&"bear-bg-primary-50 dark:bear-bg-primary-900/20",t&&"bear-opacity-50 bear-cursor-not-allowed",l&&"bear-border-b bear-border-gray-200 dark:bear-border-gray-700",g),"data-testid":j,...k,children:[b&&s.jsx("div",{className:"bear-flex-shrink-0 bear-text-gray-500 dark:bear-text-gray-400",children:b}),r||e?s.jsxs("div",{className:"bear-flex-1 bear-min-w-0",children:[r&&s.jsx("div",{className:"bear-text-gray-900 dark:bear-text-gray-100 bear-truncate",children:r}),e&&s.jsx("div",{className:i.cn("bear-text-gray-500 dark:bear-text-gray-400 bear-truncate",p?"bear-text-xs":"bear-text-sm"),children:e})]}):s.jsx("div",{className:"bear-flex-1 bear-min-w-0",children:m}),a&&s.jsx("div",{className:"bear-flex-shrink-0 bear-text-gray-500 dark:bear-text-gray-400",children:a})]})});h.displayName="ListItem";const D=({sticky:r=!1,inset:e=!1,className:b,children:a,testId:n,...t})=>s.jsx("li",{role:"presentation",className:i.cn("bear-py-2 bear-px-4 bear-text-xs bear-font-semibold bear-uppercase bear-tracking-wider","bear-text-gray-500 dark:bear-text-gray-400","bear-bg-gray-50 dark:bear-bg-gray-800/50",r&&"bear-sticky bear-top-0 bear-z-10",e&&"bear-pl-12",b),"data-testid":n,...t,children:a}),R=({primary:r,secondary:e,inset:b=!1,dense:a=!1,className:n,...t})=>s.jsxs("div",{className:i.cn("bear-flex-1 bear-min-w-0",b&&"bear-pl-9",n),...t,children:[r&&s.jsx("div",{className:"bear-text-gray-900 dark:bear-text-gray-100",children:r}),e&&s.jsx("div",{className:i.cn("bear-text-gray-500 dark:bear-text-gray-400",a?"bear-text-xs":"bear-text-sm"),children:e})]}),S=({align:r="center",className:e,children:b,...a})=>s.jsx("div",{className:i.cn("bear-flex-shrink-0 bear-min-w-[36px]","bear-text-gray-500 dark:bear-text-gray-400",r==="top"&&"bear-self-start bear-mt-1",e),...a,children:b}),q=({selected:r=!1,disabled:e=!1,dense:b=!1,onClick:a,className:n,children:t,...x})=>s.jsx("div",{role:"button",tabIndex:e?-1:0,"aria-selected":r,"aria-disabled":e,onClick:e?void 0:a,onKeyDown:l=>{!e&&(l.key==="Enter"||l.key===" ")&&(l.preventDefault(),a==null||a())},className:i.cn("bear-flex bear-items-center bear-gap-3 bear-w-full bear-text-left",b?"bear-py-1 bear-px-3":"bear-py-2 bear-px-4","bear-cursor-pointer bear-transition-colors","hover:bear-bg-gray-100 dark:hover:bear-bg-gray-800",r&&"bear-bg-primary-50 dark:bear-bg-primary-900/20",e&&"bear-opacity-50 bear-cursor-not-allowed bear-pointer-events-none",n),...x,children:t});exports.List=v;exports.ListItem=h;exports.ListItemButton=q;exports.ListItemIcon=S;exports.ListItemText=R;exports.ListSubheader=D;
|