@forgedevstack/bear 1.2.0 → 1.2.2

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.
Files changed (268) hide show
  1. package/dist/components/AnimatedCounter/AnimatedCounter.cjs +1 -0
  2. package/dist/components/AnimatedCounter/AnimatedCounter.const.cjs +1 -0
  3. package/dist/components/AnimatedCounter/AnimatedCounter.const.d.ts +5 -0
  4. package/dist/components/AnimatedCounter/AnimatedCounter.const.js +7 -0
  5. package/dist/components/AnimatedCounter/AnimatedCounter.d.ts +3 -0
  6. package/dist/components/AnimatedCounter/AnimatedCounter.js +59 -0
  7. package/dist/components/AnimatedCounter/AnimatedCounter.types.d.ts +26 -0
  8. package/dist/components/AnimatedCounter/AnimatedCounter.utils.cjs +1 -0
  9. package/dist/components/AnimatedCounter/AnimatedCounter.utils.d.ts +6 -0
  10. package/dist/components/AnimatedCounter/AnimatedCounter.utils.js +13 -0
  11. package/dist/components/AnimatedCounter/index.d.ts +2 -0
  12. package/dist/components/Autocomplete/Autocomplete.cjs +1 -1
  13. package/dist/components/Autocomplete/Autocomplete.const.cjs +1 -0
  14. package/dist/components/Autocomplete/Autocomplete.const.d.ts +1 -0
  15. package/dist/components/Autocomplete/Autocomplete.const.js +4 -0
  16. package/dist/components/Autocomplete/Autocomplete.js +110 -72
  17. package/dist/components/BottomSheet/BottomSheet.cjs +1 -1
  18. package/dist/components/BottomSheet/BottomSheet.js +74 -53
  19. package/dist/components/BottomSheet/BottomSheet.types.d.ts +2 -0
  20. package/dist/components/Breadcrumbs/Breadcrumbs.cjs +1 -1
  21. package/dist/components/Breadcrumbs/Breadcrumbs.js +126 -46
  22. package/dist/components/Breadcrumbs/Breadcrumbs.types.d.ts +11 -4
  23. package/dist/components/Breadcrumbs/index.d.ts +1 -1
  24. package/dist/components/Cascader/Cascader.cjs +1 -1
  25. package/dist/components/Cascader/Cascader.const.cjs +1 -1
  26. package/dist/components/Cascader/Cascader.const.d.ts +1 -1
  27. package/dist/components/Cascader/Cascader.const.js +1 -1
  28. package/dist/components/Cascader/Cascader.js +109 -146
  29. package/dist/components/Cascader/components/CascaderPanel/CascaderPanel.cjs +1 -0
  30. package/dist/components/Cascader/components/CascaderPanel/CascaderPanel.d.ts +3 -0
  31. package/dist/components/Cascader/components/CascaderPanel/CascaderPanel.js +50 -0
  32. package/dist/components/Cascader/components/CascaderPanel/index.d.ts +1 -0
  33. package/dist/components/Chart/BarChart.cjs +1 -0
  34. package/dist/components/Chart/BarChart.d.ts +3 -0
  35. package/dist/components/Chart/BarChart.js +65 -0
  36. package/dist/components/Chart/Chart.cjs +1 -1
  37. package/dist/components/Chart/Chart.const.cjs +1 -1
  38. package/dist/components/Chart/Chart.const.d.ts +7 -0
  39. package/dist/components/Chart/Chart.const.js +12 -2
  40. package/dist/components/Chart/Chart.d.ts +1 -13
  41. package/dist/components/Chart/Chart.js +18 -204
  42. package/dist/components/Chart/Chart.types.d.ts +7 -1
  43. package/dist/components/Chart/LineChart.cjs +1 -0
  44. package/dist/components/Chart/LineChart.d.ts +3 -0
  45. package/dist/components/Chart/LineChart.js +73 -0
  46. package/dist/components/Chart/PieChart.cjs +1 -0
  47. package/dist/components/Chart/PieChart.d.ts +3 -0
  48. package/dist/components/Chart/PieChart.js +110 -0
  49. package/dist/components/Chart/index.d.ts +4 -1
  50. package/dist/components/ColorPicker/ColorPicker.cjs +1 -1
  51. package/dist/components/ColorPicker/ColorPicker.const.cjs +1 -1
  52. package/dist/components/ColorPicker/ColorPicker.const.d.ts +4 -2
  53. package/dist/components/ColorPicker/ColorPicker.const.js +8 -6
  54. package/dist/components/ColorPicker/ColorPicker.js +135 -73
  55. package/dist/components/ColorPicker/ColorPicker.utils.cjs +1 -0
  56. package/dist/components/ColorPicker/ColorPicker.utils.d.ts +17 -0
  57. package/dist/components/ColorPicker/ColorPicker.utils.js +43 -0
  58. package/dist/components/CountdownTimer/CountdownTimer.cjs +1 -1
  59. package/dist/components/CountdownTimer/CountdownTimer.const.cjs +1 -1
  60. package/dist/components/CountdownTimer/CountdownTimer.const.d.ts +2 -0
  61. package/dist/components/CountdownTimer/CountdownTimer.const.js +29 -17
  62. package/dist/components/CountdownTimer/CountdownTimer.js +91 -61
  63. package/dist/components/CountdownTimer/CountdownTimer.types.d.ts +11 -2
  64. package/dist/components/CreditInput/CreditInput.cjs +1 -1
  65. package/dist/components/CreditInput/CreditInput.js +80 -78
  66. package/dist/components/CurrencyInput/CurrencyInput.cjs +1 -0
  67. package/dist/components/CurrencyInput/CurrencyInput.const.cjs +1 -0
  68. package/dist/components/CurrencyInput/CurrencyInput.const.d.ts +4 -0
  69. package/dist/components/CurrencyInput/CurrencyInput.const.js +19 -0
  70. package/dist/components/CurrencyInput/CurrencyInput.d.ts +3 -0
  71. package/dist/components/CurrencyInput/CurrencyInput.js +60 -0
  72. package/dist/components/CurrencyInput/CurrencyInput.types.d.ts +22 -0
  73. package/dist/components/CurrencyInput/CurrencyInput.utils.cjs +1 -0
  74. package/dist/components/CurrencyInput/CurrencyInput.utils.d.ts +2 -0
  75. package/dist/components/CurrencyInput/CurrencyInput.utils.js +14 -0
  76. package/dist/components/CurrencyInput/index.d.ts +2 -0
  77. package/dist/components/DateRangePicker/DateRangePicker.cjs +1 -1
  78. package/dist/components/DateRangePicker/DateRangePicker.js +89 -84
  79. package/dist/components/DiffSquares/DiffSquares.cjs +1 -0
  80. package/dist/components/DiffSquares/DiffSquares.const.cjs +1 -0
  81. package/dist/components/DiffSquares/DiffSquares.const.d.ts +3 -0
  82. package/dist/components/DiffSquares/DiffSquares.const.js +6 -0
  83. package/dist/components/DiffSquares/DiffSquares.d.ts +3 -0
  84. package/dist/components/DiffSquares/DiffSquares.js +70 -0
  85. package/dist/components/DiffSquares/DiffSquares.types.d.ts +23 -0
  86. package/dist/components/DiffSquares/DiffSquares.utils.cjs +1 -0
  87. package/dist/components/DiffSquares/DiffSquares.utils.d.ts +3 -0
  88. package/dist/components/DiffSquares/DiffSquares.utils.js +12 -0
  89. package/dist/components/DiffSquares/index.d.ts +2 -0
  90. package/dist/components/DiffViewer/DiffViewer.cjs +1 -1
  91. package/dist/components/DiffViewer/DiffViewer.const.cjs +1 -1
  92. package/dist/components/DiffViewer/DiffViewer.const.d.ts +6 -0
  93. package/dist/components/DiffViewer/DiffViewer.const.js +17 -4
  94. package/dist/components/DiffViewer/DiffViewer.d.ts +0 -14
  95. package/dist/components/DiffViewer/DiffViewer.js +97 -105
  96. package/dist/components/DiffViewer/DiffViewer.types.d.ts +5 -0
  97. package/dist/components/DiffViewer/index.d.ts +1 -1
  98. package/dist/components/Drawer/Drawer.cjs +1 -1
  99. package/dist/components/Drawer/Drawer.js +41 -41
  100. package/dist/components/Dropdown/Dropdown.cjs +1 -1
  101. package/dist/components/Dropdown/Dropdown.const.cjs +1 -0
  102. package/dist/components/Dropdown/Dropdown.const.d.ts +7 -0
  103. package/dist/components/Dropdown/Dropdown.const.js +10 -0
  104. package/dist/components/Dropdown/Dropdown.d.ts +0 -1
  105. package/dist/components/Dropdown/Dropdown.js +102 -92
  106. package/dist/components/Dropdown/Dropdown.types.d.ts +2 -0
  107. package/dist/components/Gauge/Gauge.cjs +1 -1
  108. package/dist/components/Gauge/Gauge.js +61 -50
  109. package/dist/components/Gauge/Gauge.types.d.ts +2 -0
  110. package/dist/components/GlowCard/GlowCard.cjs +1 -0
  111. package/dist/components/GlowCard/GlowCard.const.cjs +1 -0
  112. package/dist/components/GlowCard/GlowCard.const.d.ts +11 -0
  113. package/dist/components/GlowCard/GlowCard.const.js +13 -0
  114. package/dist/components/GlowCard/GlowCard.d.ts +3 -0
  115. package/dist/components/GlowCard/GlowCard.js +185 -0
  116. package/dist/components/GlowCard/GlowCard.types.d.ts +21 -0
  117. package/dist/components/GlowCard/index.d.ts +2 -0
  118. package/dist/components/Heatmap/Heatmap.cjs +1 -0
  119. package/dist/components/Heatmap/Heatmap.const.cjs +1 -0
  120. package/dist/components/Heatmap/Heatmap.const.d.ts +8 -0
  121. package/dist/components/Heatmap/Heatmap.const.js +11 -0
  122. package/dist/components/Heatmap/Heatmap.d.ts +3 -0
  123. package/dist/components/Heatmap/Heatmap.js +103 -0
  124. package/dist/components/Heatmap/Heatmap.types.d.ts +34 -0
  125. package/dist/components/Heatmap/Heatmap.utils.cjs +1 -0
  126. package/dist/components/Heatmap/Heatmap.utils.d.ts +2 -0
  127. package/dist/components/Heatmap/Heatmap.utils.js +18 -0
  128. package/dist/components/Heatmap/index.d.ts +2 -0
  129. package/dist/components/HoverCard/HoverCard.cjs +6 -6
  130. package/dist/components/HoverCard/HoverCard.js +72 -54
  131. package/dist/components/Icon/icons/status.js +1 -1
  132. package/dist/components/ImageAnnotation/ImageAnnotation.cjs +1 -0
  133. package/dist/components/ImageAnnotation/ImageAnnotation.const.cjs +1 -0
  134. package/dist/components/ImageAnnotation/ImageAnnotation.const.d.ts +3 -0
  135. package/dist/components/ImageAnnotation/ImageAnnotation.const.js +6 -0
  136. package/dist/components/ImageAnnotation/ImageAnnotation.d.ts +3 -0
  137. package/dist/components/ImageAnnotation/ImageAnnotation.js +113 -0
  138. package/dist/components/ImageAnnotation/ImageAnnotation.types.d.ts +28 -0
  139. package/dist/components/ImageAnnotation/index.d.ts +2 -0
  140. package/dist/components/MediaPlayer/MediaPlayer.cjs +1 -0
  141. package/dist/components/MediaPlayer/MediaPlayer.const.cjs +1 -0
  142. package/dist/components/MediaPlayer/MediaPlayer.const.d.ts +36 -0
  143. package/dist/components/MediaPlayer/MediaPlayer.const.js +11 -0
  144. package/dist/components/MediaPlayer/MediaPlayer.d.ts +3 -0
  145. package/dist/components/MediaPlayer/MediaPlayer.js +279 -0
  146. package/dist/components/MediaPlayer/MediaPlayer.types.d.ts +69 -0
  147. package/dist/components/MediaPlayer/MediaPlayer.utils.cjs +1 -0
  148. package/dist/components/MediaPlayer/MediaPlayer.utils.d.ts +1 -0
  149. package/dist/components/MediaPlayer/MediaPlayer.utils.js +7 -0
  150. package/dist/components/MediaPlayer/index.d.ts +2 -0
  151. package/dist/components/MentionsInput/MentionsInput.cjs +1 -1
  152. package/dist/components/MentionsInput/MentionsInput.js +106 -83
  153. package/dist/components/Menu/Menu.cjs +1 -1
  154. package/dist/components/Menu/Menu.js +91 -80
  155. package/dist/components/Modal/Modal.cjs +1 -1
  156. package/dist/components/Modal/Modal.const.cjs +1 -1
  157. package/dist/components/Modal/Modal.const.d.ts +1 -1
  158. package/dist/components/Modal/Modal.const.js +1 -1
  159. package/dist/components/Modal/Modal.js +50 -44
  160. package/dist/components/Modal/Modal.types.d.ts +6 -0
  161. package/dist/components/MultiSelect/MultiSelect.cjs +1 -1
  162. package/dist/components/MultiSelect/MultiSelect.js +123 -78
  163. package/dist/components/NavigableSelect/NavigableSelect.cjs +1 -1
  164. package/dist/components/NavigableSelect/NavigableSelect.const.cjs +1 -1
  165. package/dist/components/NavigableSelect/NavigableSelect.const.d.ts +1 -1
  166. package/dist/components/NavigableSelect/NavigableSelect.const.js +1 -1
  167. package/dist/components/NavigableSelect/NavigableSelect.js +167 -143
  168. package/dist/components/NotificationCenter/NotificationCenter.cjs +1 -1
  169. package/dist/components/NotificationCenter/NotificationCenter.const.cjs +1 -1
  170. package/dist/components/NotificationCenter/NotificationCenter.const.d.ts +1 -1
  171. package/dist/components/NotificationCenter/NotificationCenter.const.js +1 -1
  172. package/dist/components/NotificationCenter/NotificationCenter.js +87 -81
  173. package/dist/components/OTPInput/OTPInput.cjs +1 -1
  174. package/dist/components/OTPInput/OTPInput.const.cjs +1 -0
  175. package/dist/components/OTPInput/OTPInput.const.d.ts +6 -0
  176. package/dist/components/OTPInput/OTPInput.const.js +14 -0
  177. package/dist/components/OTPInput/OTPInput.js +99 -65
  178. package/dist/components/OTPInput/OTPInput.types.d.ts +7 -0
  179. package/dist/components/PhoneInput/PhoneInput.cjs +1 -1
  180. package/dist/components/PhoneInput/PhoneInput.const.cjs +1 -1
  181. package/dist/components/PhoneInput/PhoneInput.const.d.ts +1 -1
  182. package/dist/components/PhoneInput/PhoneInput.const.js +1 -1
  183. package/dist/components/PhoneInput/PhoneInput.js +88 -83
  184. package/dist/components/Popconfirm/Popconfirm.cjs +1 -1
  185. package/dist/components/Popconfirm/Popconfirm.const.cjs +1 -1
  186. package/dist/components/Popconfirm/Popconfirm.const.d.ts +1 -3
  187. package/dist/components/Popconfirm/Popconfirm.const.js +12 -18
  188. package/dist/components/Popconfirm/Popconfirm.js +71 -51
  189. package/dist/components/Popover/Popover.cjs +1 -1
  190. package/dist/components/Popover/Popover.js +36 -31
  191. package/dist/components/Portal/Portal.cjs +1 -1
  192. package/dist/components/Portal/Portal.d.ts +0 -3
  193. package/dist/components/Portal/Portal.js +4 -10
  194. package/dist/components/Select/Select.cjs +1 -1
  195. package/dist/components/Select/Select.js +71 -51
  196. package/dist/components/Stepper/Stepper.cjs +1 -1
  197. package/dist/components/Stepper/Stepper.const.cjs +1 -1
  198. package/dist/components/Stepper/Stepper.const.d.ts +26 -4
  199. package/dist/components/Stepper/Stepper.const.js +39 -20
  200. package/dist/components/Stepper/Stepper.d.ts +3 -10
  201. package/dist/components/Stepper/Stepper.js +189 -130
  202. package/dist/components/Stepper/Stepper.types.d.ts +14 -0
  203. package/dist/components/Stepper/Stepper.utils.cjs +1 -0
  204. package/dist/components/Stepper/Stepper.utils.d.ts +12 -0
  205. package/dist/components/Stepper/Stepper.utils.js +19 -0
  206. package/dist/components/Stepper/components/StepperControls.cjs +1 -0
  207. package/dist/components/Stepper/components/StepperControls.d.ts +2 -0
  208. package/dist/components/Stepper/components/StepperControls.js +32 -0
  209. package/dist/components/Stepper/index.d.ts +2 -1
  210. package/dist/components/Tabs/TabList.cjs +1 -1
  211. package/dist/components/Tabs/TabList.js +72 -57
  212. package/dist/components/Tabs/Tabs.types.d.ts +4 -2
  213. package/dist/components/Tabs/index.d.ts +2 -2
  214. package/dist/components/TagCloud/TagCloud.cjs +1 -0
  215. package/dist/components/TagCloud/TagCloud.const.cjs +1 -0
  216. package/dist/components/TagCloud/TagCloud.const.d.ts +5 -0
  217. package/dist/components/TagCloud/TagCloud.const.js +8 -0
  218. package/dist/components/TagCloud/TagCloud.d.ts +3 -0
  219. package/dist/components/TagCloud/TagCloud.js +76 -0
  220. package/dist/components/TagCloud/TagCloud.types.d.ts +26 -0
  221. package/dist/components/TagCloud/index.d.ts +2 -0
  222. package/dist/components/TimePicker/components/TimePickerDialDropdown/TimePickerDialDropdown.cjs +1 -1
  223. package/dist/components/TimePicker/components/TimePickerDialDropdown/TimePickerDialDropdown.js +26 -26
  224. package/dist/components/TimePicker/helpers/ClockFaceSvg.cjs +1 -1
  225. package/dist/components/TimePicker/helpers/ClockFaceSvg.js +17 -17
  226. package/dist/components/TimelineChart/TimelineChart.cjs +1 -0
  227. package/dist/components/TimelineChart/TimelineChart.const.cjs +1 -0
  228. package/dist/components/TimelineChart/TimelineChart.const.d.ts +6 -0
  229. package/dist/components/TimelineChart/TimelineChart.const.js +9 -0
  230. package/dist/components/TimelineChart/TimelineChart.d.ts +3 -0
  231. package/dist/components/TimelineChart/TimelineChart.js +65 -0
  232. package/dist/components/TimelineChart/TimelineChart.types.d.ts +31 -0
  233. package/dist/components/TimelineChart/index.d.ts +2 -0
  234. package/dist/components/Toast/Toast.cjs +1 -1
  235. package/dist/components/Toast/Toast.js +86 -82
  236. package/dist/components/Toast/Toast.types.d.ts +2 -0
  237. package/dist/components/Tooltip/Tooltip.cjs +1 -1
  238. package/dist/components/Tooltip/Tooltip.js +52 -44
  239. package/dist/components/TreeSelect/TreeSelect.cjs +1 -1
  240. package/dist/components/TreeSelect/TreeSelect.const.cjs +1 -1
  241. package/dist/components/TreeSelect/TreeSelect.const.d.ts +1 -1
  242. package/dist/components/TreeSelect/TreeSelect.const.js +3 -3
  243. package/dist/components/TreeSelect/TreeSelect.js +120 -88
  244. package/dist/components/Watermark/Watermark.cjs +1 -1
  245. package/dist/components/Watermark/Watermark.const.cjs +1 -1
  246. package/dist/components/Watermark/Watermark.const.d.ts +6 -3
  247. package/dist/components/Watermark/Watermark.const.js +13 -11
  248. package/dist/components/Watermark/Watermark.js +87 -61
  249. package/dist/components/Watermark/Watermark.types.d.ts +2 -0
  250. package/dist/components/index.cjs +1 -1
  251. package/dist/components/index.d.ts +22 -4
  252. package/dist/components/index.js +319 -296
  253. package/dist/hooks/index.cjs +1 -1
  254. package/dist/hooks/index.d.ts +1 -1
  255. package/dist/hooks/index.js +55 -54
  256. package/dist/hooks/useClickOutside.cjs +1 -1
  257. package/dist/hooks/useClickOutside.d.ts +4 -11
  258. package/dist/hooks/useClickOutside.js +26 -7
  259. package/dist/index.cjs +1 -1
  260. package/dist/index.js +412 -388
  261. package/dist/styles/_effects.css +32 -0
  262. package/dist/styles.css +1 -1
  263. package/dist/utils/maxVisible.utils.cjs +1 -0
  264. package/dist/utils/maxVisible.utils.d.ts +12 -0
  265. package/dist/utils/maxVisible.utils.js +15 -0
  266. package/package.json +1 -1
  267. package/dist/components/HoverCard/HoverCard.utils.cjs +0 -1
  268. package/dist/components/HoverCard/HoverCard.utils.js +0 -23
@@ -1,86 +1,93 @@
1
- import { jsxs as I, jsx as o } from "react/jsx-runtime";
2
- import { useState as D, useRef as v, useCallback as c, useEffect as S, isValidElement as q, cloneElement as G } from "react";
3
- import { cn as h } from "../../utils/cn.js";
4
- import { useClickOutside as H } from "../../hooks/useClickOutside.js";
1
+ import { jsxs as j, jsx as o } from "react/jsx-runtime";
2
+ import { useState as m, useRef as E, useCallback as u, useEffect as I, useMemo as $, isValidElement as O, cloneElement as ee } from "react";
3
+ import { cn as C } from "../../utils/cn.js";
4
+ import { useClickOutsideMultiple as re } from "../../hooks/useClickOutside.js";
5
5
  import "../../context/BearProvider.js";
6
6
  import "../../hooks/useBearComponent/useBearComponent.js";
7
- const J = {
8
- xs: "bear-text-xs bear-py-1 bear-px-2",
9
- sm: "bear-text-sm bear-py-1.5 bear-px-3",
10
- md: "bear-text-sm bear-py-2 bear-px-3",
11
- lg: "bear-text-base bear-py-2.5 bear-px-4",
12
- xl: "bear-text-lg bear-py-3 bear-px-5"
13
- }, Q = {
14
- "bottom-start": "bear-top-full bear-left-0 bear-mt-1",
15
- "bottom-end": "bear-top-full bear-right-0 bear-mt-1",
16
- bottom: "bear-top-full bear-left-1/2 -bear-translate-x-1/2 bear-mt-1",
17
- "top-start": "bear-bottom-full bear-left-0 bear-mb-1",
18
- "top-end": "bear-bottom-full bear-right-0 bear-mb-1",
19
- top: "bear-bottom-full bear-left-1/2 -bear-translate-x-1/2 bear-mb-1",
20
- left: "bear-right-full bear-top-0 bear-mr-1",
21
- right: "bear-left-full bear-top-0 bear-ml-1"
22
- }, te = ({
23
- trigger: p,
24
- items: i,
25
- open: y,
26
- defaultOpen: A = !1,
27
- placement: L = "bottom-start",
28
- offset: X = 4,
29
- matchWidth: R = !1,
30
- minWidth: j = 150,
31
- maxHeight: W = 300,
32
- size: z = "md",
33
- closeOnSelect: g = !0,
34
- closeOnClickOutside: k = !0,
35
- disabled: w = !1,
7
+ import { Portal as te } from "../Portal/Portal.js";
8
+ import { SIZE_CLASSES as ae } from "./Dropdown.const.js";
9
+ const pe = ({
10
+ trigger: v,
11
+ items: d,
12
+ open: L,
13
+ defaultOpen: z = !1,
14
+ placement: i = "bottom-start",
15
+ offset: x = 4,
16
+ matchWidth: N = !1,
17
+ minWidth: h = 150,
18
+ maxHeight: A = 300,
19
+ size: U = "md",
20
+ closeOnSelect: D = !0,
21
+ closeOnClickOutside: g = !0,
22
+ disabled: M = !1,
36
23
  onOpenChange: f,
37
- className: F,
38
- testId: M,
39
- ..._
24
+ className: B,
25
+ testId: F,
26
+ ...K
40
27
  }) => {
41
- var C;
42
- const [B, K] = D(A), [n, s] = D(-1), E = v(null), P = v(null), N = v(null), x = y !== void 0, a = x ? y : B, u = c((e) => {
43
- x || K(e), f == null || f(e);
44
- }, [x, f]), T = c(() => {
45
- w || u(!a);
46
- }, [w, a, u]), l = c(() => {
47
- u(!1), s(-1);
48
- }, [u]), m = c((e) => {
49
- var t;
50
- e.disabled || e.divider || e.header || ((t = e.onClick) == null || t.call(e), g && !e.items && l());
51
- }, [g, l]), U = c(() => {
52
- a && k && l();
53
- }, [a, k, l]);
54
- H(E, U), S(() => {
28
+ const [T, V] = m(z), [b, c] = m(-1), [w, Z] = m({ top: 0, left: 0, minWidth: h }), R = E(null), W = E(null), P = E(null), y = L !== void 0, a = y ? L : T, p = u((e) => {
29
+ y || V(e), f == null || f(e);
30
+ }, [y, f]), _ = u(() => {
31
+ M || p(!a);
32
+ }, [M, a, p]), l = u(() => {
33
+ p(!1), c(-1);
34
+ }, [p]), k = u((e) => {
35
+ var r;
36
+ e.disabled || e.divider || e.header || ((r = e.onClick) == null || r.call(e), D && !e.items && l());
37
+ }, [D, l]), q = u(() => {
38
+ a && g && l();
39
+ }, [a, g, l]);
40
+ re([R, W], q, {
41
+ enabled: a && g
42
+ }), I(() => {
55
43
  if (!a) return;
56
- const e = i.filter((r) => !r.disabled && !r.divider && !r.header), t = (r) => {
57
- switch (r.key) {
44
+ const e = d.filter((t) => !t.disabled && !t.divider && !t.header), r = (t) => {
45
+ switch (t.key) {
58
46
  case "Escape":
59
- r.preventDefault(), l();
47
+ t.preventDefault(), l();
60
48
  break;
61
49
  case "ArrowDown":
62
- r.preventDefault(), s((d) => {
63
- const b = d + 1;
64
- return b >= e.length ? 0 : b;
50
+ t.preventDefault(), c((n) => {
51
+ const s = n + 1;
52
+ return s >= e.length ? 0 : s;
65
53
  });
66
54
  break;
67
55
  case "ArrowUp":
68
- r.preventDefault(), s((d) => {
69
- const b = d - 1;
70
- return b < 0 ? e.length - 1 : b;
56
+ t.preventDefault(), c((n) => {
57
+ const s = n - 1;
58
+ return s < 0 ? e.length - 1 : s;
71
59
  });
72
60
  break;
73
61
  case "Enter":
74
62
  case " ":
75
- r.preventDefault(), n >= 0 && n < e.length && m(e[n]);
63
+ t.preventDefault(), b >= 0 && b < e.length && k(e[b]);
76
64
  break;
77
65
  }
78
66
  };
79
- return document.addEventListener("keydown", t), () => document.removeEventListener("keydown", t);
80
- }, [a, i, n, l, m]), S(() => {
81
- a || s(-1);
67
+ return document.addEventListener("keydown", r), () => document.removeEventListener("keydown", r);
68
+ }, [a, d, b, l, k]), I(() => {
69
+ if (!a) return;
70
+ const e = () => {
71
+ var S;
72
+ const r = (S = P.current) == null ? void 0 : S.getBoundingClientRect();
73
+ if (!r) return;
74
+ const t = window.innerWidth, n = N ? r.width : h, Q = i.endsWith("end") ? r.right - n : i === "top" || i === "bottom" ? r.left + r.width / 2 - n / 2 : r.left, X = Math.min(Math.max(8, Q), Math.max(8, t - n - 8)), Y = i.startsWith("top") ? r.top - x : r.bottom + x;
75
+ Z({
76
+ top: Y,
77
+ left: X,
78
+ minWidth: n
79
+ });
80
+ };
81
+ return e(), window.addEventListener("resize", e), window.addEventListener("scroll", e, !0), () => {
82
+ window.removeEventListener("resize", e), window.removeEventListener("scroll", e, !0);
83
+ };
84
+ }, [a, N, h, i, x]), I(() => {
85
+ a || c(-1);
82
86
  }, [a]);
83
- const V = (e, t) => {
87
+ const G = $(
88
+ () => d.map((e, r) => ({ item: e, index: r })).filter(({ item: e }) => !e.disabled && !e.divider && !e.header),
89
+ [d]
90
+ ), H = (e, r) => {
84
91
  if (e.divider)
85
92
  return /* @__PURE__ */ o(
86
93
  "div",
@@ -101,20 +108,21 @@ const J = {
101
108
  },
102
109
  e.key
103
110
  );
104
- const r = i.slice(0, t).filter((b) => !b.disabled && !b.divider && !b.header).length, d = n === r;
105
- return /* @__PURE__ */ I(
111
+ const t = G.findIndex((s) => s.index === r), n = b === t;
112
+ return /* @__PURE__ */ j(
106
113
  "button",
107
114
  {
108
115
  type: "button",
109
116
  role: "menuitem",
110
117
  disabled: e.disabled,
111
- onClick: () => m(e),
112
- onMouseEnter: () => s(r),
113
- className: h(
118
+ onClick: () => k(e),
119
+ onMouseEnter: () => c(t),
120
+ className: C(
114
121
  "bear-w-full bear-flex bear-items-center bear-gap-2 bear-text-left bear-border-none bear-bg-transparent",
115
- J[z],
122
+ ae[U],
116
123
  "bear-transition-colors bear-cursor-pointer",
117
- d && !e.danger && "bear-bg-[var(--bear-bg-tertiary)]",
124
+ e.selected && !e.danger && "bear-bg-[var(--bear-bg-tertiary)] bear-text-[var(--bear-text-primary)]",
125
+ n && !e.danger && "bear-bg-[var(--bear-bg-tertiary)]",
118
126
  e.danger && "bear-text-red-600 dark:bear-text-red-400 hover:bear-bg-red-50 dark:hover:bear-bg-red-900/20",
119
127
  !e.danger && !e.disabled && "hover:bear-bg-[var(--bear-bg-tertiary)]",
120
128
  e.disabled && "bear-opacity-50 bear-cursor-not-allowed bear-pointer-events-none"
@@ -129,46 +137,48 @@ const J = {
129
137
  },
130
138
  e.key
131
139
  );
132
- }, Z = q(p) ? G(p, {
133
- onClick: T,
134
- ref: N,
140
+ }, J = O(v) ? ee(v, {
141
+ onClick: _,
142
+ ref: P,
135
143
  "aria-expanded": a,
136
144
  "aria-haspopup": !0
137
- }) : p;
138
- return /* @__PURE__ */ I(
145
+ }) : v;
146
+ return /* @__PURE__ */ j(
139
147
  "div",
140
148
  {
141
- ref: E,
142
- className: h("bear-relative bear-inline-block", F),
143
- "data-testid": M,
144
- ..._,
149
+ ref: R,
150
+ className: C("bear-relative bear-inline-block", B),
151
+ "data-testid": F,
152
+ ...K,
145
153
  children: [
146
- Z,
147
- a && /* @__PURE__ */ o(
154
+ J,
155
+ a && /* @__PURE__ */ o(te, { children: /* @__PURE__ */ o(
148
156
  "div",
149
157
  {
150
- ref: P,
158
+ ref: W,
151
159
  role: "menu",
152
- className: h(
153
- "bear-absolute bear-z-50",
160
+ className: C(
161
+ "bear-fixed",
154
162
  "bear-border bear-rounded-lg bear-shadow-lg",
155
163
  "bear-py-1 bear-overflow-y-auto",
156
- "bear-animate-in bear-fade-in-0 bear-zoom-in-95 bear-duration-100",
157
- Q[L]
164
+ "bear-duration-100"
158
165
  ),
159
166
  style: {
160
167
  backgroundColor: "var(--bear-bg-primary)",
161
168
  borderColor: "var(--bear-border-default)",
162
- minWidth: R ? (C = N.current) == null ? void 0 : C.offsetWidth : j,
163
- maxHeight: W
169
+ minWidth: w.minWidth,
170
+ maxHeight: A,
171
+ top: w.top,
172
+ left: w.left,
173
+ zIndex: 11e3
164
174
  },
165
- children: i.map((e, t) => V(e, t))
175
+ children: d.map((e, r) => H(e, r))
166
176
  }
167
- )
177
+ ) })
168
178
  ]
169
179
  }
170
180
  );
171
181
  };
172
182
  export {
173
- te as Dropdown
183
+ pe as Dropdown
174
184
  };
@@ -17,6 +17,8 @@ export interface DropdownItem {
17
17
  header?: boolean;
18
18
  /** Danger/destructive action */
19
19
  danger?: boolean;
20
+ /** Selected/active visual state */
21
+ selected?: boolean;
20
22
  /** Click handler */
21
23
  onClick?: () => void;
22
24
  /** Nested items for submenu */
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),h=require("react"),o=require("../../utils/cn.cjs"),C=({value:a,min:r=0,max:l=100,size:i=120,strokeWidth:t=10,color:y="#ec4899",trackColor:j,showLabel:g=!0,label:p,animated:k=!0,arcAngle:n=270,gradient:s,className:M,...N})=>{const f=h.useId(),{percentage:v,circumference:u,offset:b,startAngle:x}=h.useMemo(()=>{const m=Math.min(Math.max((a-r)/(l-r)*100,0),100),w=50-t/2,c=2*Math.PI*w*(n/360),D=c-m/100*c,q=90+(360-n)/2;return{percentage:m,circumference:c,offset:D,startAngle:q}},[a,r,l,n,t]),d=50-t/2;return e.jsxs("div",{className:o.cn("relative inline-flex items-center justify-center",M),style:{width:i,height:i},...N,children:[e.jsxs("svg",{viewBox:"0 0 100 100",className:"w-full h-full -rotate-90",children:[e.jsx("defs",{children:s&&e.jsxs("linearGradient",{id:f,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[e.jsx("stop",{offset:"0%",stopColor:s[0]}),e.jsx("stop",{offset:"100%",stopColor:s[1]})]})}),e.jsx("circle",{cx:"50",cy:"50",r:d,fill:"none",stroke:j||"currentColor",strokeWidth:t,strokeLinecap:"round",strokeDasharray:u,strokeDashoffset:0,className:o.cn("text-gray-200 dark:text-slate-700"),style:{transformOrigin:"center",transform:`rotate(${x}deg)`}}),e.jsx("circle",{cx:"50",cy:"50",r:d,fill:"none",stroke:s?`url(#${f})`:y,strokeWidth:t,strokeLinecap:"round",strokeDasharray:u,strokeDashoffset:b,className:o.cn(k&&"transition-all duration-1000 ease-out"),style:{transformOrigin:"center",transform:`rotate(${x}deg)`}})]}),g&&e.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:p||e.jsxs("span",{className:"text-2xl font-semibold text-gray-800 dark:text-white",children:[Math.round(v),"%"]})})]})};exports.Gauge=C;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),i=require("react"),g=require("../../utils/cn.cjs"),F=({value:x,min:a=0,max:d=100,size:h=120,strokeWidth:s=10,color:p="#ec4899",trackColor:v,showLabel:k=!0,label:b,animated:t=!0,fillDurationMs:D=900,arcAngle:f=270,gradient:n,className:M,...N})=>{const m=i.useId(),{percentage:O,circumference:r,offset:o,startAngle:y}=i.useMemo(()=>{const c=Math.min(Math.max((x-a)/(d-a)*100,0),100),w=50-s/2,u=2*Math.PI*w*(f/360),$=u-c/100*u,C=90+(360-f)/2;return{percentage:c,circumference:u,offset:$,startAngle:C}},[x,a,d,f,s]),[q,l]=i.useState(()=>t?r:o);i.useLayoutEffect(()=>{if(!t){l(o);return}l(r);const c=requestAnimationFrame(()=>l(o));return()=>cancelAnimationFrame(c)},[t,r,o]);const j=50-s/2;return e.jsxs("div",{className:g.cn("relative inline-flex items-center justify-center",M),style:{width:h,height:h},...N,children:[e.jsxs("svg",{viewBox:"0 0 100 100",className:"h-full w-full -rotate-90",children:[e.jsx("defs",{children:n&&e.jsxs("linearGradient",{id:m,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[e.jsx("stop",{offset:"0%",stopColor:n[0]}),e.jsx("stop",{offset:"100%",stopColor:n[1]})]})}),e.jsx("circle",{cx:"50",cy:"50",r:j,fill:"none",stroke:v||"currentColor",strokeWidth:s,strokeLinecap:"round",strokeDasharray:r,strokeDashoffset:0,className:g.cn("text-gray-200 dark:text-slate-700"),style:{transformOrigin:"center",transform:`rotate(${y}deg)`}}),e.jsx("circle",{cx:"50",cy:"50",r:j,fill:"none",stroke:n?`url(#${m})`:p,strokeWidth:s,strokeLinecap:"round",strokeDasharray:r,strokeDashoffset:q,style:{transformOrigin:"center",transform:`rotate(${y}deg)`,transitionProperty:t?"stroke-dashoffset":void 0,transitionDuration:t?`${D}ms`:void 0,transitionTimingFunction:t?"cubic-bezier(0.4, 0, 0.2, 1)":void 0}})]}),k&&e.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:b||e.jsxs("span",{className:"text-2xl font-semibold text-gray-800 dark:text-white",children:[Math.round(O),"%"]})})]})};exports.Gauge=F;
@@ -1,86 +1,97 @@
1
- import { jsxs as s, jsx as e } from "react/jsx-runtime";
2
- import { useId as $, useMemo as b } from "react";
3
- import { cn as c } from "../../utils/cn.js";
4
- const B = ({
5
- value: l,
6
- min: o = 0,
7
- max: i = 100,
8
- size: f = 120,
9
- strokeWidth: t = 10,
10
- color: p = "#ec4899",
11
- trackColor: y,
12
- showLabel: g = !0,
13
- label: k,
14
- animated: N = !0,
15
- arcAngle: n = 270,
16
- gradient: r,
17
- className: M,
1
+ import { jsxs as i, jsx as t } from "react/jsx-runtime";
2
+ import { useId as I, useMemo as L, useState as A, useLayoutEffect as G } from "react";
3
+ import { cn as g } from "../../utils/cn.js";
4
+ const E = ({
5
+ value: m,
6
+ min: a = 0,
7
+ max: d = 100,
8
+ size: h = 120,
9
+ strokeWidth: r = 10,
10
+ color: k = "#ec4899",
11
+ trackColor: v,
12
+ showLabel: D = !0,
13
+ label: M,
14
+ animated: e = !0,
15
+ fillDurationMs: N = 900,
16
+ arcAngle: f = 270,
17
+ gradient: o,
18
+ className: b,
18
19
  ...j
19
20
  }) => {
20
- const u = $(), { percentage: v, circumference: m, offset: w, startAngle: d } = b(() => {
21
- const h = Math.min(Math.max((l - o) / (i - o) * 100, 0), 100), D = 50 - t / 2, a = 2 * Math.PI * D * (n / 360), C = a - h / 100 * a, I = 90 + (360 - n) / 2;
21
+ const x = I(), { percentage: w, circumference: s, offset: n, startAngle: p } = L(() => {
22
+ const c = Math.min(Math.max((m - a) / (d - a) * 100, 0), 100), $ = 50 - r / 2, u = 2 * Math.PI * $ * (f / 360), C = u - c / 100 * u, F = 90 + (360 - f) / 2;
22
23
  return {
23
- percentage: h,
24
- circumference: a,
24
+ percentage: c,
25
+ circumference: u,
25
26
  offset: C,
26
- startAngle: I
27
+ startAngle: F
27
28
  };
28
- }, [l, o, i, n, t]), x = 50 - t / 2;
29
- return /* @__PURE__ */ s(
29
+ }, [m, a, d, f, r]), [O, l] = A(() => e ? s : n);
30
+ G(() => {
31
+ if (!e) {
32
+ l(n);
33
+ return;
34
+ }
35
+ l(s);
36
+ const c = requestAnimationFrame(() => l(n));
37
+ return () => cancelAnimationFrame(c);
38
+ }, [e, s, n]);
39
+ const y = 50 - r / 2;
40
+ return /* @__PURE__ */ i(
30
41
  "div",
31
42
  {
32
- className: c("relative inline-flex items-center justify-center", M),
33
- style: { width: f, height: f },
43
+ className: g("relative inline-flex items-center justify-center", b),
44
+ style: { width: h, height: h },
34
45
  ...j,
35
46
  children: [
36
- /* @__PURE__ */ s("svg", { viewBox: "0 0 100 100", className: "w-full h-full -rotate-90", children: [
37
- /* @__PURE__ */ e("defs", { children: r && /* @__PURE__ */ s("linearGradient", { id: u, x1: "0%", y1: "0%", x2: "100%", y2: "0%", children: [
38
- /* @__PURE__ */ e("stop", { offset: "0%", stopColor: r[0] }),
39
- /* @__PURE__ */ e("stop", { offset: "100%", stopColor: r[1] })
47
+ /* @__PURE__ */ i("svg", { viewBox: "0 0 100 100", className: "h-full w-full -rotate-90", children: [
48
+ /* @__PURE__ */ t("defs", { children: o && /* @__PURE__ */ i("linearGradient", { id: x, x1: "0%", y1: "0%", x2: "100%", y2: "0%", children: [
49
+ /* @__PURE__ */ t("stop", { offset: "0%", stopColor: o[0] }),
50
+ /* @__PURE__ */ t("stop", { offset: "100%", stopColor: o[1] })
40
51
  ] }) }),
41
- /* @__PURE__ */ e(
52
+ /* @__PURE__ */ t(
42
53
  "circle",
43
54
  {
44
55
  cx: "50",
45
56
  cy: "50",
46
- r: x,
57
+ r: y,
47
58
  fill: "none",
48
- stroke: y || "currentColor",
49
- strokeWidth: t,
59
+ stroke: v || "currentColor",
60
+ strokeWidth: r,
50
61
  strokeLinecap: "round",
51
- strokeDasharray: m,
62
+ strokeDasharray: s,
52
63
  strokeDashoffset: 0,
53
- className: c("text-gray-200 dark:text-slate-700"),
64
+ className: g("text-gray-200 dark:text-slate-700"),
54
65
  style: {
55
66
  transformOrigin: "center",
56
- transform: `rotate(${d}deg)`
67
+ transform: `rotate(${p}deg)`
57
68
  }
58
69
  }
59
70
  ),
60
- /* @__PURE__ */ e(
71
+ /* @__PURE__ */ t(
61
72
  "circle",
62
73
  {
63
74
  cx: "50",
64
75
  cy: "50",
65
- r: x,
76
+ r: y,
66
77
  fill: "none",
67
- stroke: r ? `url(#${u})` : p,
68
- strokeWidth: t,
78
+ stroke: o ? `url(#${x})` : k,
79
+ strokeWidth: r,
69
80
  strokeLinecap: "round",
70
- strokeDasharray: m,
71
- strokeDashoffset: w,
72
- className: c(
73
- N && "transition-all duration-1000 ease-out"
74
- ),
81
+ strokeDasharray: s,
82
+ strokeDashoffset: O,
75
83
  style: {
76
84
  transformOrigin: "center",
77
- transform: `rotate(${d}deg)`
85
+ transform: `rotate(${p}deg)`,
86
+ transitionProperty: e ? "stroke-dashoffset" : void 0,
87
+ transitionDuration: e ? `${N}ms` : void 0,
88
+ transitionTimingFunction: e ? "cubic-bezier(0.4, 0, 0.2, 1)" : void 0
78
89
  }
79
90
  }
80
91
  )
81
92
  ] }),
82
- g && /* @__PURE__ */ e("div", { className: "absolute inset-0 flex items-center justify-center", children: k || /* @__PURE__ */ s("span", { className: "text-2xl font-semibold text-gray-800 dark:text-white", children: [
83
- Math.round(v),
93
+ D && /* @__PURE__ */ t("div", { className: "absolute inset-0 flex items-center justify-center", children: M || /* @__PURE__ */ i("span", { className: "text-2xl font-semibold text-gray-800 dark:text-white", children: [
94
+ Math.round(w),
84
95
  "%"
85
96
  ] }) })
86
97
  ]
@@ -88,5 +99,5 @@ const B = ({
88
99
  );
89
100
  };
90
101
  export {
91
- B as Gauge
102
+ E as Gauge
92
103
  };
@@ -20,6 +20,8 @@ export interface GaugeProps extends HTMLAttributes<HTMLDivElement> {
20
20
  label?: ReactNode;
21
21
  /** Animate on render */
22
22
  animated?: boolean;
23
+ /** Fill transition duration in ms when animated */
24
+ fillDurationMs?: number;
23
25
  /** Arc angle (180 for half, 270 for 3/4, 360 for full) */
24
26
  arcAngle?: number;
25
27
  /** Gradient colors [start, end] */
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),d=require("react"),C=require("../../utils/cn.cjs"),n=require("./GlowCard.const.cjs"),w=({children:$,glowColor:a=n.DEFAULT_GLOW_COLOR,glowIntensity:i=n.DEFAULT_GLOW_INTENSITY,followMouse:p=!0,borderRadius:c=n.DEFAULT_BORDER_RADIUS,disabled:u=!1,effect:v=n.DEFAULT_EFFECT,borderWidth:r=n.DEFAULT_BORDER_WIDTH,testId:y,className:E,style:b,...O})=>{const l=d.useRef(null),[s,T]=d.useState({x:n.CENTER_POSITION,y:n.CENTER_POSITION}),[m,_]=d.useState(!1),h=d.useCallback(x=>{if(!p||u||!l.current)return;const o=l.current.getBoundingClientRect();T({x:(x.clientX-o.left)/o.width*100,y:(x.clientY-o.top)/o.height*100})},[p,u]),t=m&&!u,A=typeof c=="number"?`${c}px`:c,B=()=>{switch(v){case"border":return e.jsx("div",{className:"Bear-GlowCard__border absolute inset-0 pointer-events-none rounded-[inherit] transition-opacity duration-300",style:{opacity:t?1:0,background:`radial-gradient(circle at ${s.x}% ${s.y}%, ${a}${n.HEX_OPACITY_BORDER}, transparent ${i}%)`,mask:"linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0)",maskComposite:"exclude",WebkitMaskComposite:"xor",padding:r}});case"spotlight":return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"Bear-GlowCard__spot absolute inset-0 pointer-events-none transition-opacity duration-300",style:{opacity:t?.8:0,background:`radial-gradient(300px circle at ${s.x}% ${s.y}%, ${a}${n.HEX_OPACITY_AMBIENT}, transparent 60%)`}}),e.jsx("div",{className:"Bear-GlowCard__spot-border absolute inset-0 pointer-events-none rounded-[inherit] transition-opacity duration-300",style:{opacity:t?1:0,boxShadow:`inset 0 0 0 ${r}px ${a}${n.HEX_OPACITY_BORDER}`}})]});case"pulse":return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"Bear-GlowCard__pulse-inner absolute inset-0 pointer-events-none rounded-[inherit] transition-opacity duration-300",style:{opacity:t?1:0,background:`radial-gradient(ellipse at 50% 50%, ${a}${n.HEX_OPACITY_AMBIENT}, transparent 70%)`,animation:t?"bear-glow-pulse 2s ease-in-out infinite":"none"}}),e.jsx("div",{className:"Bear-GlowCard__pulse-outer absolute -inset-1 pointer-events-none rounded-[inherit]",style:{boxShadow:`0 0 ${i}px ${i/2}px ${a}${n.HEX_OPACITY_SHADOW}`,animation:t?"bear-glow-pulse 2s ease-in-out infinite":"none",opacity:t?1:0,transition:"opacity 0.3s"}}),e.jsx("div",{className:"Bear-GlowCard__pulse-ring absolute inset-0 pointer-events-none rounded-[inherit]",style:{boxShadow:`inset 0 0 0 ${r}px ${a}${n.HEX_OPACITY_BORDER}`,animation:t?"bear-glow-pulse 2s ease-in-out infinite 0.5s":"none",opacity:t?1:0,transition:"opacity 0.3s"}})]});case"wave":return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"Bear-GlowCard__wave absolute inset-0 pointer-events-none rounded-[inherit]",style:{opacity:t?1:0,transition:"opacity 0.3s",background:`linear-gradient(90deg, transparent 0%, ${a}${n.HEX_OPACITY_AMBIENT} 50%, transparent 100%)`,backgroundSize:"200% 100%",animation:t?"bear-glow-wave 2.5s ease-in-out infinite":"none"}}),e.jsx("div",{className:"Bear-GlowCard__wave-edge absolute inset-0 pointer-events-none rounded-[inherit]",style:{opacity:t?1:0,transition:"opacity 0.3s",boxShadow:`inset 0 ${r}px 0 ${a}${n.HEX_OPACITY_BORDER}, 0 0 ${i/2}px ${a}${n.HEX_OPACITY_SHADOW}`,animation:t?"bear-glow-wave-shadow 2.5s ease-in-out infinite":"none"}})]});default:return e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"Bear-GlowCard__ambient absolute inset-0 pointer-events-none transition-opacity duration-300",style:{opacity:t?.6:0,background:`radial-gradient(circle at ${s.x}% ${s.y}%, ${a}${n.HEX_OPACITY_AMBIENT}, transparent ${i}%)`}}),e.jsx("div",{className:"Bear-GlowCard__shadow absolute inset-0 pointer-events-none rounded-[inherit] transition-opacity duration-300",style:{opacity:t?.6:0,boxShadow:`inset 0 0 0 1px ${a}${n.HEX_OPACITY_BORDER_SHADOW}, 0 0 ${i}px ${a}${n.HEX_OPACITY_SHADOW}`}})]})}};return e.jsxs("div",{ref:l,className:C.cn("Bear-GlowCard relative overflow-hidden transition-shadow duration-300","bg-white dark:bg-zinc-900 border border-gray-200 dark:border-zinc-700",t&&"shadow-xl",E),style:{borderRadius:A,...b},onMouseMove:h,onMouseEnter:()=>_(!0),onMouseLeave:()=>_(!1),"data-testid":y,...O,children:[B(),e.jsx("div",{className:"Bear-GlowCard__content relative z-10",children:$})]})};exports.GlowCard=w;
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E="#ec4899",_=40,O=12,T="ambient",A=2,D=50,I="66",R="33",t="22",L="44";exports.CENTER_POSITION=D;exports.DEFAULT_BORDER_RADIUS=O;exports.DEFAULT_BORDER_WIDTH=A;exports.DEFAULT_EFFECT=T;exports.DEFAULT_GLOW_COLOR=E;exports.DEFAULT_GLOW_INTENSITY=_;exports.HEX_OPACITY_AMBIENT=R;exports.HEX_OPACITY_BORDER=I;exports.HEX_OPACITY_BORDER_SHADOW=L;exports.HEX_OPACITY_SHADOW=t;
@@ -0,0 +1,11 @@
1
+ export declare const DEFAULT_GLOW_COLOR = "#ec4899";
2
+ export declare const DEFAULT_GLOW_INTENSITY = 40;
3
+ export declare const DEFAULT_BORDER_RADIUS = 12;
4
+ export declare const DEFAULT_EFFECT: "ambient";
5
+ export declare const DEFAULT_BORDER_WIDTH = 2;
6
+ export declare const CENTER_POSITION = 50;
7
+ export declare const HEX_OPACITY_BORDER = "66";
8
+ export declare const HEX_OPACITY_AMBIENT = "33";
9
+ export declare const HEX_OPACITY_SHADOW = "22";
10
+ export declare const HEX_OPACITY_BORDER_SHADOW = "44";
11
+ export declare const PULSE_INTERVAL_MS = 2000;
@@ -0,0 +1,13 @@
1
+ const E = "#ec4899", _ = 40, O = 12, T = "ambient", A = 2, D = 50, t = "66", c = "33", n = "22", o = "44";
2
+ export {
3
+ D as CENTER_POSITION,
4
+ O as DEFAULT_BORDER_RADIUS,
5
+ A as DEFAULT_BORDER_WIDTH,
6
+ T as DEFAULT_EFFECT,
7
+ E as DEFAULT_GLOW_COLOR,
8
+ _ as DEFAULT_GLOW_INTENSITY,
9
+ c as HEX_OPACITY_AMBIENT,
10
+ t as HEX_OPACITY_BORDER,
11
+ o as HEX_OPACITY_BORDER_SHADOW,
12
+ n as HEX_OPACITY_SHADOW
13
+ };
@@ -0,0 +1,3 @@
1
+ import { FC } from 'react';
2
+ import { GlowCardProps } from './GlowCard.types';
3
+ export declare const GlowCard: FC<GlowCardProps>;