@forgedevstack/bear 1.0.7 → 1.0.9
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/ActivityItem/ActivityItem.cjs +1 -1
- package/dist/components/ActivityItem/ActivityItem.js +1 -0
- package/dist/components/Alert/Alert.cjs +1 -1
- package/dist/components/Alert/Alert.const.cjs +1 -1
- package/dist/components/Alert/Alert.const.d.ts +4 -0
- package/dist/components/Alert/Alert.const.js +10 -15
- package/dist/components/Alert/Alert.js +43 -38
- package/dist/components/AppBar/AppBar.cjs +1 -1
- package/dist/components/AppBar/AppBar.js +19 -14
- package/dist/components/BackTop/BackTop.cjs +1 -0
- package/dist/components/BackTop/BackTop.const.cjs +1 -0
- package/dist/components/BackTop/BackTop.const.d.ts +34 -0
- package/dist/components/BackTop/BackTop.const.js +29 -0
- package/dist/components/BackTop/BackTop.d.ts +21 -0
- package/dist/components/BackTop/BackTop.js +87 -0
- package/dist/components/BackTop/BackTop.types.d.ts +28 -0
- package/dist/components/BackTop/index.d.ts +3 -0
- package/dist/components/Badge/Badge.cjs +1 -1
- package/dist/components/Badge/Badge.constants.d.ts +4 -4
- package/dist/components/Badge/Badge.js +15 -14
- package/dist/components/Badge/Badge.types.d.ts +3 -3
- package/dist/components/BearLogo/EmberLogo.cjs +1 -1
- package/dist/components/BearLogo/EmberLogo.js +3 -2
- package/dist/components/BottomNavigation/BottomNavigation.cjs +1 -1
- package/dist/components/BottomNavigation/BottomNavigation.js +3 -2
- package/dist/components/BottomSheet/BottomSheet.cjs +1 -1
- package/dist/components/BottomSheet/BottomSheet.js +39 -38
- package/dist/components/Button/Button.cjs +1 -1
- package/dist/components/Button/Button.constants.cjs +38 -48
- package/dist/components/Button/Button.constants.d.ts +22 -3
- package/dist/components/Button/Button.constants.js +51 -50
- package/dist/components/Button/Button.d.ts +14 -7
- package/dist/components/Button/Button.js +123 -45
- package/dist/components/Button/Button.types.d.ts +22 -4
- package/dist/components/Calendar/Calendar.cjs +1 -1
- package/dist/components/Calendar/Calendar.js +3 -2
- package/dist/components/Card/Card.const.d.ts +2 -2
- package/dist/components/Card/Card.types.d.ts +2 -2
- package/dist/components/Carousel/Carousel.cjs +1 -1
- package/dist/components/Carousel/Carousel.const.cjs +1 -0
- package/dist/components/Carousel/Carousel.const.d.ts +12 -0
- package/dist/components/Carousel/Carousel.const.js +9 -0
- package/dist/components/Carousel/Carousel.d.ts +14 -3
- package/dist/components/Carousel/Carousel.js +222 -75
- package/dist/components/Carousel/Carousel.types.d.ts +32 -2
- package/dist/components/Carousel/index.d.ts +1 -1
- package/dist/components/Chat/Chat.cjs +1 -0
- package/dist/components/Chat/Chat.const.cjs +1 -0
- package/dist/components/Chat/Chat.const.d.ts +26 -0
- package/dist/components/Chat/Chat.const.js +29 -0
- package/dist/components/Chat/Chat.d.ts +21 -0
- package/dist/components/Chat/Chat.js +179 -0
- package/dist/components/Chat/Chat.types.d.ts +55 -0
- package/dist/components/Chat/index.d.ts +2 -0
- package/dist/components/Chip/Chip.cjs +1 -1
- package/dist/components/Chip/Chip.js +3 -2
- package/dist/components/CodeEditor/CodeEditor.cjs +5 -0
- package/dist/components/CodeEditor/CodeEditor.const.cjs +1 -0
- package/dist/components/CodeEditor/CodeEditor.const.d.ts +21 -0
- package/dist/components/CodeEditor/CodeEditor.const.js +119 -0
- package/dist/components/CodeEditor/CodeEditor.d.ts +22 -0
- package/dist/components/CodeEditor/CodeEditor.js +250 -0
- package/dist/components/CodeEditor/CodeEditor.types.d.ts +80 -0
- package/dist/components/CodeEditor/CodeEditor.utils.cjs +1 -0
- package/dist/components/CodeEditor/CodeEditor.utils.d.ts +6 -0
- package/dist/components/CodeEditor/CodeEditor.utils.js +75 -0
- package/dist/components/CodeEditor/index.d.ts +2 -0
- package/dist/components/Columns/Columns.cjs +1 -1
- package/dist/components/Columns/Columns.js +9 -8
- package/dist/components/Confetti/Confetti.cjs +1 -0
- package/dist/components/Confetti/Confetti.const.cjs +1 -0
- package/dist/components/Confetti/Confetti.const.d.ts +16 -0
- package/dist/components/Confetti/Confetti.const.js +36 -0
- package/dist/components/Confetti/Confetti.d.ts +23 -0
- package/dist/components/Confetti/Confetti.js +94 -0
- package/dist/components/Confetti/Confetti.types.d.ts +50 -0
- package/dist/components/Confetti/index.d.ts +4 -0
- package/dist/components/Confetti/useConfetti.cjs +1 -0
- package/dist/components/Confetti/useConfetti.d.ts +13 -0
- package/dist/components/Confetti/useConfetti.js +12 -0
- package/dist/components/CountdownTimer/CountdownTimer.cjs +1 -0
- package/dist/components/CountdownTimer/CountdownTimer.const.cjs +1 -0
- package/dist/components/CountdownTimer/CountdownTimer.const.d.ts +27 -0
- package/dist/components/CountdownTimer/CountdownTimer.const.js +35 -0
- package/dist/components/CountdownTimer/CountdownTimer.d.ts +7 -0
- package/dist/components/CountdownTimer/CountdownTimer.js +115 -0
- package/dist/components/CountdownTimer/CountdownTimer.types.d.ts +56 -0
- package/dist/components/CountdownTimer/index.d.ts +2 -0
- package/dist/components/Cropper/Cropper.cjs +1 -0
- package/dist/components/Cropper/Cropper.const.cjs +1 -0
- package/dist/components/Cropper/Cropper.const.d.ts +31 -0
- package/dist/components/Cropper/Cropper.const.js +33 -0
- package/dist/components/Cropper/Cropper.d.ts +21 -0
- package/dist/components/Cropper/Cropper.js +362 -0
- package/dist/components/Cropper/Cropper.types.d.ts +72 -0
- package/dist/components/Cropper/index.d.ts +2 -0
- package/dist/components/DataTable/DataTable.cjs +1 -1
- package/dist/components/DataTable/DataTable.js +5 -4
- package/dist/components/DatePicker/DatePicker.cjs +1 -1
- package/dist/components/DatePicker/DatePicker.js +3 -2
- package/dist/components/DiffViewer/DiffViewer.cjs +1 -0
- package/dist/components/DiffViewer/DiffViewer.const.cjs +1 -0
- package/dist/components/DiffViewer/DiffViewer.const.d.ts +18 -0
- package/dist/components/DiffViewer/DiffViewer.const.js +21 -0
- package/dist/components/DiffViewer/DiffViewer.d.ts +18 -0
- package/dist/components/DiffViewer/DiffViewer.js +127 -0
- package/dist/components/DiffViewer/DiffViewer.types.d.ts +40 -0
- package/dist/components/DiffViewer/DiffViewer.utils.cjs +3 -0
- package/dist/components/DiffViewer/DiffViewer.utils.d.ts +9 -0
- package/dist/components/DiffViewer/DiffViewer.utils.js +39 -0
- package/dist/components/DiffViewer/index.d.ts +2 -0
- package/dist/components/Divider/Divider.cjs +1 -1
- package/dist/components/Divider/Divider.js +15 -14
- package/dist/components/Dock/Dock.cjs +1 -0
- package/dist/components/Dock/Dock.const.cjs +1 -0
- package/dist/components/Dock/Dock.const.d.ts +25 -0
- package/dist/components/Dock/Dock.const.js +22 -0
- package/dist/components/Dock/Dock.d.ts +7 -0
- package/dist/components/Dock/Dock.js +144 -0
- package/dist/components/Dock/Dock.types.d.ts +42 -0
- package/dist/components/Dock/index.d.ts +2 -0
- package/dist/components/Drawer/Drawer.cjs +1 -1
- package/dist/components/Drawer/Drawer.js +35 -35
- package/dist/components/EmptyState/EmptyState.cjs +1 -1
- package/dist/components/EmptyState/EmptyState.js +7 -6
- package/dist/components/FloatingChat/FloatingChat.cjs +1 -0
- package/dist/components/FloatingChat/FloatingChat.const.cjs +1 -0
- package/dist/components/FloatingChat/FloatingChat.const.d.ts +12 -0
- package/dist/components/FloatingChat/FloatingChat.const.js +15 -0
- package/dist/components/FloatingChat/FloatingChat.d.ts +19 -0
- package/dist/components/FloatingChat/FloatingChat.js +144 -0
- package/dist/components/FloatingChat/FloatingChat.types.d.ts +44 -0
- package/dist/components/FloatingChat/index.d.ts +2 -0
- package/dist/components/GradientText/GradientText.cjs +1 -0
- package/dist/components/GradientText/GradientText.const.cjs +1 -0
- package/dist/components/GradientText/GradientText.const.d.ts +15 -0
- package/dist/components/GradientText/GradientText.const.js +36 -0
- package/dist/components/GradientText/GradientText.d.ts +7 -0
- package/dist/components/GradientText/GradientText.js +52 -0
- package/dist/components/GradientText/GradientText.types.d.ts +27 -0
- package/dist/components/GradientText/index.d.ts +2 -0
- package/dist/components/Highlight/Highlight.cjs +1 -1
- package/dist/components/Highlight/Highlight.const.cjs +1 -0
- package/dist/components/Highlight/Highlight.const.d.ts +8 -0
- package/dist/components/Highlight/Highlight.const.js +15 -0
- package/dist/components/Highlight/Highlight.d.ts +4 -0
- package/dist/components/Highlight/Highlight.js +32 -24
- package/dist/components/Highlight/Highlight.types.d.ts +9 -1
- package/dist/components/Highlight/index.d.ts +1 -1
- package/dist/components/Icon/Icon.cjs +1 -1
- package/dist/components/Icon/Icon.js +17 -16
- package/dist/components/Icon/index.cjs +1 -1
- package/dist/components/Icon/index.js +12 -11
- package/dist/components/JsonViewer/JsonViewer.cjs +1 -0
- package/dist/components/JsonViewer/JsonViewer.const.cjs +1 -0
- package/dist/components/JsonViewer/JsonViewer.const.d.ts +4 -0
- package/dist/components/JsonViewer/JsonViewer.const.js +24 -0
- package/dist/components/JsonViewer/JsonViewer.d.ts +17 -0
- package/dist/components/JsonViewer/JsonViewer.js +195 -0
- package/dist/components/JsonViewer/JsonViewer.types.d.ts +54 -0
- package/dist/components/JsonViewer/index.d.ts +2 -0
- package/dist/components/Kanban/Kanban.cjs +1 -1
- package/dist/components/Kanban/Kanban.js +18 -17
- package/dist/components/Kbd/Kbd.cjs +1 -1
- package/dist/components/Kbd/Kbd.js +17 -16
- package/dist/components/Map/Map.cjs +1 -0
- package/dist/components/Map/Map.const.cjs +1 -0
- package/dist/components/Map/Map.const.d.ts +20 -0
- package/dist/components/Map/Map.const.js +26 -0
- package/dist/components/Map/Map.d.ts +20 -0
- package/dist/components/Map/Map.js +259 -0
- package/dist/components/Map/Map.types.d.ts +81 -0
- package/dist/components/Map/index.d.ts +2 -0
- package/dist/components/Marquee/Marquee.cjs +1 -0
- package/dist/components/Marquee/Marquee.const.cjs +1 -0
- package/dist/components/Marquee/Marquee.const.d.ts +11 -0
- package/dist/components/Marquee/Marquee.const.js +12 -0
- package/dist/components/Marquee/Marquee.d.ts +7 -0
- package/dist/components/Marquee/Marquee.js +106 -0
- package/dist/components/Marquee/Marquee.types.d.ts +32 -0
- package/dist/components/Marquee/index.d.ts +2 -0
- package/dist/components/Masonry/Masonry.cjs +1 -0
- package/dist/components/Masonry/Masonry.const.cjs +1 -0
- package/dist/components/Masonry/Masonry.const.d.ts +9 -0
- package/dist/components/Masonry/Masonry.const.js +9 -0
- package/dist/components/Masonry/Masonry.d.ts +7 -0
- package/dist/components/Masonry/Masonry.js +51 -0
- package/dist/components/Masonry/Masonry.types.d.ts +21 -0
- package/dist/components/Masonry/index.d.ts +2 -0
- package/dist/components/NavigableSelect/NavigableSelect.cjs +1 -0
- package/dist/components/NavigableSelect/NavigableSelect.const.cjs +1 -0
- package/dist/components/NavigableSelect/NavigableSelect.const.d.ts +23 -0
- package/dist/components/NavigableSelect/NavigableSelect.const.js +33 -0
- package/dist/components/NavigableSelect/NavigableSelect.d.ts +7 -0
- package/dist/components/NavigableSelect/NavigableSelect.js +361 -0
- package/dist/components/NavigableSelect/NavigableSelect.types.d.ts +56 -0
- package/dist/components/NavigableSelect/index.d.ts +2 -0
- package/dist/components/Progress/Progress.cjs +1 -1
- package/dist/components/Progress/Progress.js +3 -2
- package/dist/components/QRCode/QRCode.cjs +1 -0
- package/dist/components/QRCode/QRCode.const.cjs +1 -0
- package/dist/components/QRCode/QRCode.const.d.ts +21 -0
- package/dist/components/QRCode/QRCode.const.js +11 -0
- package/dist/components/QRCode/QRCode.d.ts +29 -0
- package/dist/components/QRCode/QRCode.js +68 -0
- package/dist/components/QRCode/QRCode.types.d.ts +32 -0
- package/dist/components/QRCode/QRCode.utils.cjs +1 -0
- package/dist/components/QRCode/QRCode.utils.d.ts +12 -0
- package/dist/components/QRCode/QRCode.utils.js +74 -0
- package/dist/components/QRCode/index.d.ts +3 -0
- package/dist/components/RichEditor/components/ToolbarButton/ToolbarButton.cjs +1 -1
- package/dist/components/RichEditor/components/ToolbarButton/ToolbarButton.js +3 -2
- package/dist/components/ScrollArea/ScrollArea.cjs +1 -1
- package/dist/components/ScrollArea/ScrollArea.js +3 -2
- package/dist/components/Sidebar/Sidebar.cjs +1 -1
- package/dist/components/Sidebar/Sidebar.js +13 -12
- package/dist/components/Spinner/Spinner.cjs +1 -1
- package/dist/components/Spinner/Spinner.js +3 -2
- package/dist/components/Spinner/Spinner.types.d.ts +2 -2
- package/dist/components/Spotlight/Spotlight.cjs +1 -0
- package/dist/components/Spotlight/Spotlight.const.cjs +1 -0
- package/dist/components/Spotlight/Spotlight.const.d.ts +18 -0
- package/dist/components/Spotlight/Spotlight.const.js +9 -0
- package/dist/components/Spotlight/Spotlight.d.ts +7 -0
- package/dist/components/Spotlight/Spotlight.js +220 -0
- package/dist/components/Spotlight/Spotlight.types.d.ts +51 -0
- package/dist/components/Spotlight/index.d.ts +2 -0
- package/dist/components/StatCard/StatCard.cjs +1 -1
- package/dist/components/StatCard/StatCard.js +9 -8
- package/dist/components/Statistic/Statistic.cjs +1 -1
- package/dist/components/Statistic/Statistic.js +7 -6
- package/dist/components/Switch/Switch.cjs +1 -1
- package/dist/components/Switch/Switch.js +11 -10
- package/dist/components/Terminal/Terminal.cjs +1 -0
- package/dist/components/Terminal/Terminal.const.cjs +1 -0
- package/dist/components/Terminal/Terminal.const.d.ts +32 -0
- package/dist/components/Terminal/Terminal.const.js +42 -0
- package/dist/components/Terminal/Terminal.d.ts +27 -0
- package/dist/components/Terminal/Terminal.js +155 -0
- package/dist/components/Terminal/Terminal.types.d.ts +49 -0
- package/dist/components/Terminal/index.d.ts +2 -0
- package/dist/components/TimePicker/components/TimePickerColumnsDropdown/TimePickerColumnsDropdown.cjs +1 -1
- package/dist/components/TimePicker/components/TimePickerColumnsDropdown/TimePickerColumnsDropdown.js +16 -15
- package/dist/components/TimePicker/helpers/ClockFaceSvg.cjs +1 -1
- package/dist/components/TimePicker/helpers/ClockFaceSvg.js +13 -12
- package/dist/components/Tour/Tour.cjs +1 -0
- package/dist/components/Tour/Tour.const.cjs +1 -0
- package/dist/components/Tour/Tour.const.d.ts +25 -0
- package/dist/components/Tour/Tour.const.js +38 -0
- package/dist/components/Tour/Tour.d.ts +17 -0
- package/dist/components/Tour/Tour.js +179 -0
- package/dist/components/Tour/Tour.types.d.ts +80 -0
- package/dist/components/Tour/index.d.ts +4 -0
- package/dist/components/Tour/useTour.cjs +1 -0
- package/dist/components/Tour/useTour.d.ts +14 -0
- package/dist/components/Tour/useTour.js +27 -0
- package/dist/components/Transition/Transition.cjs +1 -0
- package/dist/components/Transition/Transition.const.cjs +1 -0
- package/dist/components/Transition/Transition.const.d.ts +15 -0
- package/dist/components/Transition/Transition.const.js +73 -0
- package/dist/components/Transition/Transition.d.ts +37 -0
- package/dist/components/Transition/Transition.js +107 -0
- package/dist/components/Transition/Transition.types.d.ts +69 -0
- package/dist/components/Transition/index.d.ts +2 -0
- package/dist/components/Typewriter/Typewriter.cjs +1 -0
- package/dist/components/Typewriter/Typewriter.const.cjs +1 -0
- package/dist/components/Typewriter/Typewriter.const.d.ts +22 -0
- package/dist/components/Typewriter/Typewriter.const.js +11 -0
- package/dist/components/Typewriter/Typewriter.d.ts +7 -0
- package/dist/components/Typewriter/Typewriter.js +88 -0
- package/dist/components/Typewriter/Typewriter.types.d.ts +32 -0
- package/dist/components/Typewriter/index.d.ts +2 -0
- package/dist/components/Typography/Typography.cjs +1 -1
- package/dist/components/Typography/Typography.d.ts +5 -1
- package/dist/components/Typography/Typography.js +93 -57
- package/dist/components/Typography/Typography.types.d.ts +29 -2
- package/dist/components/Watermark/Watermark.cjs +1 -0
- package/dist/components/Watermark/Watermark.const.cjs +1 -0
- package/dist/components/Watermark/Watermark.const.d.ts +30 -0
- package/dist/components/Watermark/Watermark.const.js +18 -0
- package/dist/components/Watermark/Watermark.d.ts +7 -0
- package/dist/components/Watermark/Watermark.js +96 -0
- package/dist/components/Watermark/Watermark.types.d.ts +35 -0
- package/dist/components/Watermark/index.d.ts +2 -0
- package/dist/components/index.cjs +1 -1
- package/dist/components/index.d.ts +46 -2
- package/dist/components/index.js +288 -237
- package/dist/context/BearProvider.cjs +1 -1
- package/dist/context/BearProvider.d.ts +110 -5
- package/dist/context/BearProvider.js +198 -53
- package/dist/context/defaultTheme.cjs +1 -1
- package/dist/context/defaultTheme.js +11 -11
- package/dist/hooks/index.cjs +1 -1
- package/dist/hooks/index.d.ts +18 -0
- package/dist/hooks/index.js +61 -39
- package/dist/hooks/useAnimate.cjs +1 -0
- package/dist/hooks/useAnimate.d.ts +61 -0
- package/dist/hooks/useAnimate.js +125 -0
- package/dist/hooks/useBearComponent/index.d.ts +2 -0
- package/dist/hooks/useBearComponent/useBearComponent.cjs +1 -0
- package/dist/hooks/useBearComponent/useBearComponent.d.ts +71 -0
- package/dist/hooks/useBearComponent/useBearComponent.js +54 -0
- package/dist/hooks/useBearComponent/useBearComponent.types.d.ts +40 -0
- package/dist/hooks/useIdle/index.d.ts +2 -0
- package/dist/hooks/useIdle/useIdle.cjs +1 -0
- package/dist/hooks/useIdle/useIdle.d.ts +22 -0
- package/dist/hooks/useIdle/useIdle.js +66 -0
- package/dist/hooks/useIdle/useIdle.types.d.ts +29 -0
- package/dist/hooks/useLongPress/index.d.ts +2 -0
- package/dist/hooks/useLongPress/useLongPress.cjs +1 -0
- package/dist/hooks/useLongPress/useLongPress.d.ts +17 -0
- package/dist/hooks/useLongPress/useLongPress.js +44 -0
- package/dist/hooks/useLongPress/useLongPress.types.d.ts +26 -0
- package/dist/hooks/useOnline/index.d.ts +2 -0
- package/dist/hooks/useOnline/useOnline.cjs +1 -0
- package/dist/hooks/useOnline/useOnline.d.ts +16 -0
- package/dist/hooks/useOnline/useOnline.js +25 -0
- package/dist/hooks/useOnline/useOnline.types.d.ts +15 -0
- package/dist/hooks/usePageVisibility/index.d.ts +2 -0
- package/dist/hooks/usePageVisibility/usePageVisibility.cjs +1 -0
- package/dist/hooks/usePageVisibility/usePageVisibility.d.ts +19 -0
- package/dist/hooks/usePageVisibility/usePageVisibility.js +26 -0
- package/dist/hooks/usePageVisibility/usePageVisibility.types.d.ts +15 -0
- package/dist/hooks/useResponsive.cjs +1 -0
- package/dist/hooks/useResponsive.d.ts +35 -0
- package/dist/hooks/useResponsive.js +74 -0
- package/dist/hooks/useSpotlight/index.d.ts +2 -0
- package/dist/hooks/useSpotlight/useSpotlight.cjs +1 -0
- package/dist/hooks/useSpotlight/useSpotlight.d.ts +24 -0
- package/dist/hooks/useSpotlight/useSpotlight.js +49 -0
- package/dist/hooks/useSpotlight/useSpotlight.types.d.ts +23 -0
- package/dist/hooks/useWebSocket/index.d.ts +2 -0
- package/dist/hooks/useWebSocket/useWebSocket.cjs +1 -0
- package/dist/hooks/useWebSocket/useWebSocket.d.ts +22 -0
- package/dist/hooks/useWebSocket/useWebSocket.js +75 -0
- package/dist/hooks/useWebSocket/useWebSocket.types.d.ts +44 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +363 -288
- package/dist/styles.css +1 -1
- package/dist/types/component.types.d.ts +125 -42
- package/dist/types/theme.types.d.ts +82 -0
- package/dist/utils/createSlots.cjs +1 -0
- package/dist/utils/createSlots.d.ts +70 -0
- package/dist/utils/createSlots.js +65 -0
- package/dist/utils/index.cjs +1 -1
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/index.js +4 -2
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),d=require("../../utils/cn.cjs")
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),d=require("../../utils/cn.cjs");require("react");const m=({icon:s,iconBg:r="rgba(16, 185, 129, 0.2)",title:a,description:i,user:t,time:l,onClick:c,className:n,...x})=>e.jsxs("div",{className:d.cn("flex items-start gap-4 p-4 hover:bg-slate-700/30 dark:hover:bg-slate-700/30 rounded-xl transition-colors cursor-pointer",n),onClick:c,...x,children:[e.jsx("div",{className:"flex items-center justify-center w-10 h-10 rounded-xl flex-shrink-0",style:{background:r},children:s}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-gray-900 dark:text-white font-medium truncate",children:a}),e.jsx("p",{className:"text-gray-500 dark:text-slate-400 text-sm truncate",children:i})]}),e.jsxs("div",{className:"text-right flex-shrink-0",children:[e.jsx("p",{className:"text-gray-500 dark:text-slate-400 text-sm",children:l}),t&&e.jsx("p",{className:"text-gray-400 dark:text-slate-500 text-xs",children:t})]})]});exports.ActivityItem=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),m=require("react"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),m=require("react"),x=require("../../utils/cn.cjs"),r=require("./Alert.const.cjs"),w={success:e.jsxs("svg",{width:20,height:20,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,"aria-hidden":"true",children:[e.jsx("path",{d:"M22 11.08V12a10 10 0 1 1-5.93-9.14"}),e.jsx("polyline",{points:"22 4 12 14.01 9 11.01"})]}),info:e.jsxs("svg",{width:20,height:20,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,"aria-hidden":"true",children:[e.jsx("circle",{cx:"12",cy:"12",r:"10"}),e.jsx("line",{x1:"12",y1:"16",x2:"12",y2:"12"}),e.jsx("line",{x1:"12",y1:"8",x2:"12.01",y2:"8"})]}),warning:e.jsxs("svg",{width:20,height:20,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,"aria-hidden":"true",children:[e.jsx("path",{d:"M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"}),e.jsx("line",{x1:"12",y1:"9",x2:"12",y2:"13"}),e.jsx("line",{x1:"12",y1:"17",x2:"12.01",y2:"17"})]}),error:e.jsxs("svg",{width:20,height:20,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,"aria-hidden":"true",children:[e.jsx("circle",{cx:"12",cy:"12",r:"10"}),e.jsx("line",{x1:"15",y1:"9",x2:"9",y2:"15"}),e.jsx("line",{x1:"9",y1:"9",x2:"15",y2:"15"})]})},k=()=>e.jsxs("svg",{width:18,height:18,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,"aria-hidden":"true",children:[e.jsx("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.jsx("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]}),C=h=>{const{severity:t=r.ALERT_DEFAULTS.SEVERITY,variant:a=r.ALERT_DEFAULTS.VARIANT,title:l,icon:n=r.ALERT_DEFAULTS.SHOW_ICON,action:c,closable:u=r.ALERT_DEFAULTS.CLOSABLE,onClose:i,children:d,className:v,testId:g,id:j,...f}=h,[y,A]=m.useState(!0);if(!y)return null;const o=a==="filled",s={success:{bg:"var(--bear-success-50)",border:"var(--bear-success-500)",text:"var(--bear-success-800)",icon:"var(--bear-success-600)"},info:{bg:"var(--bear-info-50)",border:"var(--bear-info-500)",text:"var(--bear-info-800)",icon:"var(--bear-info-600)"},warning:{bg:"var(--bear-warning-50)",border:"var(--bear-warning-500)",text:"var(--bear-warning-800)",icon:"var(--bear-warning-600)"},error:{bg:"var(--bear-danger-50)",border:"var(--bear-danger-500)",text:"var(--bear-danger-800)",icon:"var(--bear-danger-600)"}}[t],_=()=>{A(!1),i==null||i()},b=()=>n===!1?null:n!==!0?n:w[t];return e.jsxs("div",{id:j,role:"alert","aria-live":"polite",className:x.cn("Bear-Alert","bear-flex bear-items-start bear-gap-3 bear-p-4 bear-rounded-lg",r.ALERT_VARIANT_CLASSES[a](t),v),style:{backgroundColor:o?void 0:s.bg,borderColor:a==="outlined"?s.border:void 0,color:o?void 0:s.text},"data-testid":g,...f,children:[b()&&e.jsx("span",{className:"Bear-Alert__icon bear-flex-shrink-0 bear-mt-0.5",style:{color:o?"currentColor":s.icon},children:b()}),e.jsxs("div",{className:"Bear-Alert__content bear-flex-1 bear-min-w-0",children:[l&&e.jsx("div",{className:"Bear-Alert__title bear-font-semibold bear-mb-1",children:l}),d&&e.jsx("div",{className:"Bear-Alert__message bear-text-sm",children:d})]}),c&&e.jsx("div",{className:"Bear-Alert__action bear-flex-shrink-0",children:c}),u&&e.jsx("button",{type:"button",onClick:_,className:x.cn("Bear-Alert__close","bear-flex-shrink-0 bear-p-1 bear-rounded hover:bear-bg-black/10 bear-transition-colors","bear-bg-transparent bear-border-none bear-cursor-pointer"),"aria-label":"Close alert",children:e.jsx(k,{})})]})};exports.Alert=C;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../utils/cn.cjs")
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../utils/cn.cjs");require("react");const a={filled:e=>r.cn("bear-text-white bear-alert-filled",e==="success"&&"bear-alert-filled-success",e==="info"&&"bear-alert-filled-info",e==="warning"&&"bear-alert-filled-warning",e==="error"&&"bear-alert-filled-error"),outlined:()=>"bear-bg-transparent bear-border",standard:()=>""},l={SEVERITY:"info",VARIANT:"standard",SHOW_ICON:!0,CLOSABLE:!1};exports.ALERT_DEFAULTS=l;exports.ALERT_VARIANT_CLASSES=a;
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { AlertSeverity, AlertVariant } from './Alert.types';
|
|
2
|
+
/**
|
|
3
|
+
* Alert severity colors using CSS variables for theme support
|
|
4
|
+
* These map to the theme's success, info, warning, and danger color scales
|
|
5
|
+
*/
|
|
2
6
|
export declare const ALERT_SEVERITY_COLORS: Record<AlertSeverity, {
|
|
3
7
|
bg: string;
|
|
4
8
|
border: string;
|
|
@@ -1,27 +1,22 @@
|
|
|
1
1
|
import { cn as e } from "../../utils/cn.js";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
info: { bg: "rgba(59, 130, 246, 0.1)", border: "#3b82f6", text: "#1e40af", icon: "#3b82f6" },
|
|
5
|
-
warning: { bg: "rgba(245, 158, 11, 0.1)", border: "#f59e0b", text: "#92400e", icon: "#f59e0b" },
|
|
6
|
-
error: { bg: "rgba(239, 68, 68, 0.1)", border: "#ef4444", text: "#991b1b", icon: "#ef4444" }
|
|
7
|
-
}, n = {
|
|
2
|
+
import "react";
|
|
3
|
+
const t = {
|
|
8
4
|
filled: (r) => e(
|
|
9
|
-
"bear-text-white",
|
|
10
|
-
r === "success" && "bear-
|
|
11
|
-
r === "info" && "bear-
|
|
12
|
-
r === "warning" && "bear-
|
|
13
|
-
r === "error" && "bear-
|
|
5
|
+
"bear-text-white bear-alert-filled",
|
|
6
|
+
r === "success" && "bear-alert-filled-success",
|
|
7
|
+
r === "info" && "bear-alert-filled-info",
|
|
8
|
+
r === "warning" && "bear-alert-filled-warning",
|
|
9
|
+
r === "error" && "bear-alert-filled-error"
|
|
14
10
|
),
|
|
15
11
|
outlined: () => "bear-bg-transparent bear-border",
|
|
16
12
|
standard: () => ""
|
|
17
|
-
},
|
|
13
|
+
}, n = {
|
|
18
14
|
SEVERITY: "info",
|
|
19
15
|
VARIANT: "standard",
|
|
20
16
|
SHOW_ICON: !0,
|
|
21
17
|
CLOSABLE: !1
|
|
22
18
|
};
|
|
23
19
|
export {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
n as ALERT_VARIANT_CLASSES
|
|
20
|
+
n as ALERT_DEFAULTS,
|
|
21
|
+
t as ALERT_VARIANT_CLASSES
|
|
27
22
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as r, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { useState as k } from "react";
|
|
3
|
-
import { cn as
|
|
4
|
-
import { ALERT_DEFAULTS as
|
|
5
|
-
const
|
|
3
|
+
import { cn as v } from "../../utils/cn.js";
|
|
4
|
+
import { ALERT_DEFAULTS as t, ALERT_VARIANT_CLASSES as C } from "./Alert.const.js";
|
|
5
|
+
const _ = {
|
|
6
6
|
success: /* @__PURE__ */ r("svg", { width: 20, height: 20, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, "aria-hidden": "true", children: [
|
|
7
7
|
/* @__PURE__ */ e("path", { d: "M22 11.08V12a10 10 0 1 1-5.93-9.14" }),
|
|
8
8
|
/* @__PURE__ */ e("polyline", { points: "22 4 12 14.01 9 11.01" })
|
|
@@ -22,73 +22,78 @@ const w = {
|
|
|
22
22
|
/* @__PURE__ */ e("line", { x1: "15", y1: "9", x2: "9", y2: "15" }),
|
|
23
23
|
/* @__PURE__ */ e("line", { x1: "9", y1: "9", x2: "15", y2: "15" })
|
|
24
24
|
] })
|
|
25
|
-
},
|
|
25
|
+
}, B = () => /* @__PURE__ */ r("svg", { width: 18, height: 18, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, "aria-hidden": "true", children: [
|
|
26
26
|
/* @__PURE__ */ e("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
|
|
27
27
|
/* @__PURE__ */ e("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
|
|
28
|
-
] }),
|
|
28
|
+
] }), W = (x) => {
|
|
29
29
|
const {
|
|
30
|
-
severity:
|
|
31
|
-
variant:
|
|
30
|
+
severity: o = t.SEVERITY,
|
|
31
|
+
variant: i = t.VARIANT,
|
|
32
32
|
title: c,
|
|
33
|
-
icon: n =
|
|
33
|
+
icon: n = t.SHOW_ICON,
|
|
34
34
|
action: d,
|
|
35
|
-
closable:
|
|
36
|
-
onClose:
|
|
37
|
-
children:
|
|
38
|
-
className:
|
|
39
|
-
testId:
|
|
40
|
-
id:
|
|
41
|
-
...
|
|
42
|
-
} =
|
|
43
|
-
if (!
|
|
44
|
-
const
|
|
45
|
-
|
|
46
|
-
|
|
35
|
+
closable: u = t.CLOSABLE,
|
|
36
|
+
onClose: l,
|
|
37
|
+
children: b,
|
|
38
|
+
className: g,
|
|
39
|
+
testId: f,
|
|
40
|
+
id: m,
|
|
41
|
+
...y
|
|
42
|
+
} = x, [p, w] = k(!0);
|
|
43
|
+
if (!p) return null;
|
|
44
|
+
const s = i === "filled", a = {
|
|
45
|
+
success: { bg: "var(--bear-success-50)", border: "var(--bear-success-500)", text: "var(--bear-success-800)", icon: "var(--bear-success-600)" },
|
|
46
|
+
info: { bg: "var(--bear-info-50)", border: "var(--bear-info-500)", text: "var(--bear-info-800)", icon: "var(--bear-info-600)" },
|
|
47
|
+
warning: { bg: "var(--bear-warning-50)", border: "var(--bear-warning-500)", text: "var(--bear-warning-800)", icon: "var(--bear-warning-600)" },
|
|
48
|
+
error: { bg: "var(--bear-danger-50)", border: "var(--bear-danger-500)", text: "var(--bear-danger-800)", icon: "var(--bear-danger-600)" }
|
|
49
|
+
}[o], A = () => {
|
|
50
|
+
w(!1), l == null || l();
|
|
51
|
+
}, h = () => n === !1 ? null : n !== !0 ? n : _[o];
|
|
47
52
|
return /* @__PURE__ */ r(
|
|
48
53
|
"div",
|
|
49
54
|
{
|
|
50
|
-
id:
|
|
55
|
+
id: m,
|
|
51
56
|
role: "alert",
|
|
52
57
|
"aria-live": "polite",
|
|
53
|
-
className:
|
|
58
|
+
className: v(
|
|
54
59
|
"Bear-Alert",
|
|
55
60
|
"bear-flex bear-items-start bear-gap-3 bear-p-4 bear-rounded-lg",
|
|
56
|
-
|
|
57
|
-
|
|
61
|
+
C[i](o),
|
|
62
|
+
g
|
|
58
63
|
),
|
|
59
64
|
style: {
|
|
60
|
-
backgroundColor: s ? void 0 :
|
|
61
|
-
borderColor:
|
|
62
|
-
color: s ? void 0 :
|
|
65
|
+
backgroundColor: s ? void 0 : a.bg,
|
|
66
|
+
borderColor: i === "outlined" ? a.border : void 0,
|
|
67
|
+
color: s ? void 0 : a.text
|
|
63
68
|
},
|
|
64
|
-
"data-testid":
|
|
65
|
-
...
|
|
69
|
+
"data-testid": f,
|
|
70
|
+
...y,
|
|
66
71
|
children: [
|
|
67
|
-
|
|
72
|
+
h() && /* @__PURE__ */ e(
|
|
68
73
|
"span",
|
|
69
74
|
{
|
|
70
75
|
className: "Bear-Alert__icon bear-flex-shrink-0 bear-mt-0.5",
|
|
71
|
-
style: { color: s ? "currentColor" :
|
|
72
|
-
children:
|
|
76
|
+
style: { color: s ? "currentColor" : a.icon },
|
|
77
|
+
children: h()
|
|
73
78
|
}
|
|
74
79
|
),
|
|
75
80
|
/* @__PURE__ */ r("div", { className: "Bear-Alert__content bear-flex-1 bear-min-w-0", children: [
|
|
76
81
|
c && /* @__PURE__ */ e("div", { className: "Bear-Alert__title bear-font-semibold bear-mb-1", children: c }),
|
|
77
|
-
|
|
82
|
+
b && /* @__PURE__ */ e("div", { className: "Bear-Alert__message bear-text-sm", children: b })
|
|
78
83
|
] }),
|
|
79
84
|
d && /* @__PURE__ */ e("div", { className: "Bear-Alert__action bear-flex-shrink-0", children: d }),
|
|
80
|
-
|
|
85
|
+
u && /* @__PURE__ */ e(
|
|
81
86
|
"button",
|
|
82
87
|
{
|
|
83
88
|
type: "button",
|
|
84
|
-
onClick:
|
|
85
|
-
className:
|
|
89
|
+
onClick: A,
|
|
90
|
+
className: v(
|
|
86
91
|
"Bear-Alert__close",
|
|
87
92
|
"bear-flex-shrink-0 bear-p-1 bear-rounded hover:bear-bg-black/10 bear-transition-colors",
|
|
88
93
|
"bear-bg-transparent bear-border-none bear-cursor-pointer"
|
|
89
94
|
),
|
|
90
95
|
"aria-label": "Close alert",
|
|
91
|
-
children: /* @__PURE__ */ e(
|
|
96
|
+
children: /* @__PURE__ */ e(B, {})
|
|
92
97
|
}
|
|
93
98
|
)
|
|
94
99
|
]
|
|
@@ -96,5 +101,5 @@ const w = {
|
|
|
96
101
|
);
|
|
97
102
|
};
|
|
98
103
|
export {
|
|
99
|
-
|
|
104
|
+
W as Alert
|
|
100
105
|
};
|
|
@@ -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"),m=require("../../utils/cn.cjs");require("react");const u=({children:a,position:t="sticky",variant:b="default",color:r="primary",className:s,leftContent:i,rightContent:l,centerContent:c,elevation:n=!0})=>{const d={fixed:"bear-fixed bear-top-0 bear-left-0 bear-right-0 bear-z-50",sticky:"bear-sticky bear-top-0 bear-z-50",static:"bear-static",relative:"bear-relative"},o={default:"",transparent:"bear-bg-transparent",blur:"bear-backdrop-blur-md"},p={default:"bear-bg-white bear-text-gray-900 dark:bear-bg-zinc-900 dark:bear-text-white",primary:"bear-bg-pink-600 bear-text-white",dark:"bear-bg-gray-900 bear-text-white dark:bear-bg-black"},x=n?"bear-shadow-md bear-border-b bear-border-gray-200/10":"";return e.jsx("header",{className:m.cn("Bear-AppBar","bear-w-full bear-h-16 bear-px-4 bear-flex bear-items-center",d[t],o[b],p[r],x,s),style:{backgroundColor:r==="primary"?"var(--bear-primary-600)":void 0},children:a??e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"bear-flex bear-items-center bear-gap-4",children:i}),e.jsx("div",{className:"bear-flex-1 bear-flex bear-items-center bear-justify-center",children:c}),e.jsx("div",{className:"bear-flex bear-items-center bear-gap-4",children:l})]})})};exports.AppBar=u;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { jsx as e, jsxs as
|
|
1
|
+
import { jsx as e, jsxs as f, Fragment as x } from "react/jsx-runtime";
|
|
2
2
|
import { cn as g } from "../../utils/cn.js";
|
|
3
|
+
import "react";
|
|
3
4
|
const u = ({
|
|
4
5
|
children: a,
|
|
5
6
|
position: t = "sticky",
|
|
6
|
-
variant:
|
|
7
|
-
color:
|
|
7
|
+
variant: b = "default",
|
|
8
|
+
color: r = "primary",
|
|
8
9
|
className: s,
|
|
9
10
|
leftContent: i,
|
|
10
11
|
rightContent: l,
|
|
@@ -17,26 +18,30 @@ const u = ({
|
|
|
17
18
|
static: "bear-static",
|
|
18
19
|
relative: "bear-relative"
|
|
19
20
|
}, o = {
|
|
20
|
-
default: "bear-bg-white bear-text-gray-900 dark:bear-bg-zinc-900 dark:bear-text-white",
|
|
21
|
-
transparent: "bear-bg-transparent",
|
|
22
|
-
blur: "bear-bg-white/80 dark:bear-bg-zinc-900/80 bear-backdrop-blur-md"
|
|
23
|
-
}, f = {
|
|
24
21
|
default: "",
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
}, p =
|
|
22
|
+
transparent: "bear-bg-transparent",
|
|
23
|
+
blur: "bear-backdrop-blur-md"
|
|
24
|
+
}, p = {
|
|
25
|
+
default: "bear-bg-white bear-text-gray-900 dark:bear-bg-zinc-900 dark:bear-text-white",
|
|
26
|
+
primary: "bear-bg-pink-600 bear-text-white",
|
|
27
|
+
dark: "bear-bg-gray-900 bear-text-white dark:bear-bg-black"
|
|
28
|
+
}, m = n ? "bear-shadow-md bear-border-b bear-border-gray-200/10" : "";
|
|
28
29
|
return /* @__PURE__ */ e(
|
|
29
30
|
"header",
|
|
30
31
|
{
|
|
31
32
|
className: g(
|
|
33
|
+
"Bear-AppBar",
|
|
32
34
|
"bear-w-full bear-h-16 bear-px-4 bear-flex bear-items-center",
|
|
33
35
|
d[t],
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
36
|
+
o[b],
|
|
37
|
+
p[r],
|
|
38
|
+
m,
|
|
37
39
|
s
|
|
38
40
|
),
|
|
39
|
-
|
|
41
|
+
style: {
|
|
42
|
+
backgroundColor: r === "primary" ? "var(--bear-primary-600)" : void 0
|
|
43
|
+
},
|
|
44
|
+
children: a ?? /* @__PURE__ */ f(x, { children: [
|
|
40
45
|
/* @__PURE__ */ e("div", { className: "bear-flex bear-items-center bear-gap-4", children: i }),
|
|
41
46
|
/* @__PURE__ */ e("div", { className: "bear-flex-1 bear-flex bear-items-center bear-justify-center", children: c }),
|
|
42
47
|
/* @__PURE__ */ e("div", { className: "bear-flex bear-items-center bear-gap-4", children: l })
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),s=require("react"),v=require("../../utils/cn.cjs"),y=require("../Button/Button.cjs"),o=require("./BackTop.const.cjs"),I=({bottom:l=o.BACKTOP_DEFAULTS.BOTTOM,right:a=o.BACKTOP_DEFAULTS.RIGHT,visibleAt:b=o.BACKTOP_DEFAULTS.VISIBLE_AT,duration:c=o.BACKTOP_DEFAULTS.DURATION,target:i,children:p,size:u=o.BACKTOP_DEFAULTS.SIZE,variant:h=o.BACKTOP_DEFAULTS.VARIANT,animated:A=o.BACKTOP_DEFAULTS.ANIMATED,className:S,testId:w,onClick:r,...B})=>{const[f,E]=s.useState(!1),t=o.BACKTOP_SIZES[u],n=s.useCallback(()=>i?i():typeof window<"u"?window:null,[i]);s.useEffect(()=>{const e=n();if(!e)return;const T=()=>{const g=e===window?window.scrollY||document.documentElement.scrollTop:e.scrollTop;E(g>=b)};return e.addEventListener("scroll",T,{passive:!0}),T(),()=>{e.removeEventListener("scroll",T)}},[n,b]);const m=s.useCallback(()=>{const e=n();e&&(r==null||r(),e===window?window.scrollTo({top:0,behavior:c>0?"smooth":"auto"}):e.scrollTo({top:0,behavior:c>0?"smooth":"auto"}))},[n,c,r]),L=d.jsx("svg",{width:t.iconSize,height:t.iconSize,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2.5,strokeLinecap:"round",strokeLinejoin:"round",children:d.jsx("path",{d:"M18 15l-6-6-6 6"})}),O=u==="sm"?"sm":u==="lg"?"lg":"md";return d.jsx(y.Button,{variant:h,size:O,className:v.cn("Bear-BackTop","!bear-rounded-full !bear-p-0","!bear-fixed !bear-shadow-lg",A&&"bear-transition-all bear-duration-300 bear-ease-out",f?"bear-opacity-100 bear-translate-y-0 bear-scale-100":"bear-opacity-0 bear-translate-y-5 bear-scale-75 bear-pointer-events-none",S),style:{bottom:typeof l=="number"?`${l}px`:l,right:typeof a=="number"?`${a}px`:a,width:t.width,height:t.height,minWidth:t.width,zIndex:9999},onClick:m,"aria-label":"Scroll to top","data-testid":w,...B,children:p||L})};exports.BackTop=I;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i={BOTTOM:40,RIGHT:40,VISIBLE_AT:400,DURATION:300,SIZE:"md",VARIANT:"primary",ANIMATED:!0},t={sm:{width:36,height:36,iconSize:16},md:{width:44,height:44,iconSize:20},lg:{width:52,height:52,iconSize:24}};exports.BACKTOP_DEFAULTS=i;exports.BACKTOP_SIZES=t;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* BackTop component defaults
|
|
3
|
+
* Uses Bear Button for consistent styling
|
|
4
|
+
*/
|
|
5
|
+
export declare const BACKTOP_DEFAULTS: {
|
|
6
|
+
readonly BOTTOM: 40;
|
|
7
|
+
readonly RIGHT: 40;
|
|
8
|
+
readonly VISIBLE_AT: 400;
|
|
9
|
+
readonly DURATION: 300;
|
|
10
|
+
readonly SIZE: "md";
|
|
11
|
+
readonly VARIANT: "primary";
|
|
12
|
+
readonly ANIMATED: true;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* BackTop size configurations
|
|
16
|
+
* Controls the button dimensions and icon size
|
|
17
|
+
*/
|
|
18
|
+
export declare const BACKTOP_SIZES: {
|
|
19
|
+
readonly sm: {
|
|
20
|
+
readonly width: 36;
|
|
21
|
+
readonly height: 36;
|
|
22
|
+
readonly iconSize: 16;
|
|
23
|
+
};
|
|
24
|
+
readonly md: {
|
|
25
|
+
readonly width: 44;
|
|
26
|
+
readonly height: 44;
|
|
27
|
+
readonly iconSize: 20;
|
|
28
|
+
};
|
|
29
|
+
readonly lg: {
|
|
30
|
+
readonly width: 52;
|
|
31
|
+
readonly height: 52;
|
|
32
|
+
readonly iconSize: 24;
|
|
33
|
+
};
|
|
34
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
const i = {
|
|
2
|
+
BOTTOM: 40,
|
|
3
|
+
RIGHT: 40,
|
|
4
|
+
VISIBLE_AT: 400,
|
|
5
|
+
DURATION: 300,
|
|
6
|
+
SIZE: "md",
|
|
7
|
+
VARIANT: "primary",
|
|
8
|
+
ANIMATED: !0
|
|
9
|
+
}, t = {
|
|
10
|
+
sm: {
|
|
11
|
+
width: 36,
|
|
12
|
+
height: 36,
|
|
13
|
+
iconSize: 16
|
|
14
|
+
},
|
|
15
|
+
md: {
|
|
16
|
+
width: 44,
|
|
17
|
+
height: 44,
|
|
18
|
+
iconSize: 20
|
|
19
|
+
},
|
|
20
|
+
lg: {
|
|
21
|
+
width: 52,
|
|
22
|
+
height: 52,
|
|
23
|
+
iconSize: 24
|
|
24
|
+
}
|
|
25
|
+
};
|
|
26
|
+
export {
|
|
27
|
+
i as BACKTOP_DEFAULTS,
|
|
28
|
+
t as BACKTOP_SIZES
|
|
29
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
import { BackTopProps } from './BackTop.types';
|
|
3
|
+
/**
|
|
4
|
+
* BackTop - Scroll to top button
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```tsx
|
|
8
|
+
* // Basic usage
|
|
9
|
+
* <BackTop />
|
|
10
|
+
*
|
|
11
|
+
* // Custom position and threshold
|
|
12
|
+
* <BackTop bottom={60} right={20} visibleAt={200} />
|
|
13
|
+
*
|
|
14
|
+
* // Custom content
|
|
15
|
+
* <BackTop>
|
|
16
|
+
* <span>↑ Top</span>
|
|
17
|
+
* </BackTop>
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export declare const BackTop: FC<BackTopProps>;
|
|
21
|
+
export default BackTop;
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { jsx as p } from "react/jsx-runtime";
|
|
2
|
+
import { useState as y, useCallback as b, useEffect as A } from "react";
|
|
3
|
+
import { cn as x } from "../../utils/cn.js";
|
|
4
|
+
import { Button as L } from "../Button/Button.js";
|
|
5
|
+
import { BACKTOP_DEFAULTS as o, BACKTOP_SIZES as z } from "./BackTop.const.js";
|
|
6
|
+
const V = ({
|
|
7
|
+
bottom: s = o.BOTTOM,
|
|
8
|
+
right: l = o.RIGHT,
|
|
9
|
+
visibleAt: u = o.VISIBLE_AT,
|
|
10
|
+
duration: a = o.DURATION,
|
|
11
|
+
target: i,
|
|
12
|
+
children: m,
|
|
13
|
+
size: c = o.SIZE,
|
|
14
|
+
variant: T = o.VARIANT,
|
|
15
|
+
animated: f = o.ANIMATED,
|
|
16
|
+
className: h,
|
|
17
|
+
testId: w,
|
|
18
|
+
onClick: r,
|
|
19
|
+
...S
|
|
20
|
+
}) => {
|
|
21
|
+
const [I, g] = y(!1), t = z[c], n = b(() => i ? i() : typeof window < "u" ? window : null, [i]);
|
|
22
|
+
A(() => {
|
|
23
|
+
const e = n();
|
|
24
|
+
if (!e) return;
|
|
25
|
+
const d = () => {
|
|
26
|
+
const E = e === window ? window.scrollY || document.documentElement.scrollTop : e.scrollTop;
|
|
27
|
+
g(E >= u);
|
|
28
|
+
};
|
|
29
|
+
return e.addEventListener("scroll", d, { passive: !0 }), d(), () => {
|
|
30
|
+
e.removeEventListener("scroll", d);
|
|
31
|
+
};
|
|
32
|
+
}, [n, u]);
|
|
33
|
+
const v = b(() => {
|
|
34
|
+
const e = n();
|
|
35
|
+
e && (r == null || r(), e === window ? window.scrollTo({
|
|
36
|
+
top: 0,
|
|
37
|
+
behavior: a > 0 ? "smooth" : "auto"
|
|
38
|
+
}) : e.scrollTo({
|
|
39
|
+
top: 0,
|
|
40
|
+
behavior: a > 0 ? "smooth" : "auto"
|
|
41
|
+
}));
|
|
42
|
+
}, [n, a, r]), B = /* @__PURE__ */ p(
|
|
43
|
+
"svg",
|
|
44
|
+
{
|
|
45
|
+
width: t.iconSize,
|
|
46
|
+
height: t.iconSize,
|
|
47
|
+
viewBox: "0 0 24 24",
|
|
48
|
+
fill: "none",
|
|
49
|
+
stroke: "currentColor",
|
|
50
|
+
strokeWidth: 2.5,
|
|
51
|
+
strokeLinecap: "round",
|
|
52
|
+
strokeLinejoin: "round",
|
|
53
|
+
children: /* @__PURE__ */ p("path", { d: "M18 15l-6-6-6 6" })
|
|
54
|
+
}
|
|
55
|
+
);
|
|
56
|
+
return /* @__PURE__ */ p(
|
|
57
|
+
L,
|
|
58
|
+
{
|
|
59
|
+
variant: T,
|
|
60
|
+
size: c === "sm" ? "sm" : c === "lg" ? "lg" : "md",
|
|
61
|
+
className: x(
|
|
62
|
+
"Bear-BackTop",
|
|
63
|
+
"!bear-rounded-full !bear-p-0",
|
|
64
|
+
"!bear-fixed !bear-shadow-lg",
|
|
65
|
+
f && "bear-transition-all bear-duration-300 bear-ease-out",
|
|
66
|
+
I ? "bear-opacity-100 bear-translate-y-0 bear-scale-100" : "bear-opacity-0 bear-translate-y-5 bear-scale-75 bear-pointer-events-none",
|
|
67
|
+
h
|
|
68
|
+
),
|
|
69
|
+
style: {
|
|
70
|
+
bottom: typeof s == "number" ? `${s}px` : s,
|
|
71
|
+
right: typeof l == "number" ? `${l}px` : l,
|
|
72
|
+
width: t.width,
|
|
73
|
+
height: t.height,
|
|
74
|
+
minWidth: t.width,
|
|
75
|
+
zIndex: 9999
|
|
76
|
+
},
|
|
77
|
+
onClick: v,
|
|
78
|
+
"aria-label": "Scroll to top",
|
|
79
|
+
"data-testid": w,
|
|
80
|
+
...S,
|
|
81
|
+
children: m || B
|
|
82
|
+
}
|
|
83
|
+
);
|
|
84
|
+
};
|
|
85
|
+
export {
|
|
86
|
+
V as BackTop
|
|
87
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { ReactNode, HTMLAttributes } from 'react';
|
|
2
|
+
import { BearVariant, BearSize } from '../../types';
|
|
3
|
+
export interface BackTopProps extends Omit<HTMLAttributes<HTMLButtonElement>, 'children'> {
|
|
4
|
+
/** Distance from bottom of viewport */
|
|
5
|
+
bottom?: number | string;
|
|
6
|
+
/** Distance from right of viewport */
|
|
7
|
+
right?: number | string;
|
|
8
|
+
/** Show threshold - scroll distance before button appears */
|
|
9
|
+
visibleAt?: number;
|
|
10
|
+
/** Scroll duration in ms */
|
|
11
|
+
duration?: number;
|
|
12
|
+
/** Target element to scroll (defaults to window) */
|
|
13
|
+
target?: () => HTMLElement | null;
|
|
14
|
+
/** Custom icon or content */
|
|
15
|
+
children?: ReactNode;
|
|
16
|
+
/** Button size - uses Bear Button sizes */
|
|
17
|
+
size?: Extract<BearSize, 'sm' | 'md' | 'lg'>;
|
|
18
|
+
/** Button variant - uses Bear Button variants */
|
|
19
|
+
variant?: BearVariant;
|
|
20
|
+
/** Show/hide animation */
|
|
21
|
+
animated?: boolean;
|
|
22
|
+
/** Custom class name */
|
|
23
|
+
className?: string;
|
|
24
|
+
/** Test ID */
|
|
25
|
+
testId?: string;
|
|
26
|
+
/** Callback when clicked */
|
|
27
|
+
onClick?: () => void;
|
|
28
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),r=require("../../utils/cn.cjs")
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react/jsx-runtime"),r=require("../../utils/cn.cjs");require("react");const e=require("./Badge.constants.cjs"),u=({variant:s="neutral",size:n="sm",pill:t=!1,dot:d=!1,className:l,children:o,testId:i,...c})=>a.jsxs("span",{className:r.cn("Bear-Badge","bear-inline-flex bear-items-center bear-gap-1.5 bear-font-medium",e.sizeClasses[n],e.variantClasses[s],t?"Bear-Badge--pill bear-rounded-full":"bear-rounded-md",l),"data-testid":i,...c,children:[d&&a.jsx("span",{className:r.cn("Bear-Badge__dot",e.BADGE_DOT_SIZE_CLASSES,"bear-rounded-full",e.dotVariantColors[s])}),a.jsx("span",{className:"Bear-Badge__content",children:o})]});exports.Badge=u;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { BearSize, BearVariant } from '../../types';
|
|
2
2
|
/** Dot size utility classes (bear-w-1.5 bear-h-1.5). */
|
|
3
3
|
export declare const BADGE_DOT_SIZE_CLASSES = "bear-w-1.5 bear-h-1.5";
|
|
4
|
-
export declare const sizeClasses: Record<Exclude<
|
|
5
|
-
export declare const variantClasses: Record<
|
|
6
|
-
export declare const dotVariantColors: Record<
|
|
4
|
+
export declare const sizeClasses: Record<Exclude<BearSize, 'xl'>, string>;
|
|
5
|
+
export declare const variantClasses: Record<BearVariant | 'neutral', string>;
|
|
6
|
+
export declare const dotVariantColors: Record<BearVariant | 'neutral', string>;
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { jsxs as i, jsx as a } from "react/jsx-runtime";
|
|
2
2
|
import { cn as r } from "../../utils/cn.js";
|
|
3
|
-
import
|
|
4
|
-
|
|
3
|
+
import "react";
|
|
4
|
+
import { dotVariantColors as p, BADGE_DOT_SIZE_CLASSES as B, variantClasses as f, sizeClasses as c } from "./Badge.constants.js";
|
|
5
|
+
const x = ({
|
|
5
6
|
variant: e = "neutral",
|
|
6
7
|
size: s = "sm",
|
|
7
|
-
pill:
|
|
8
|
-
dot:
|
|
9
|
-
className:
|
|
10
|
-
children:
|
|
8
|
+
pill: t = !1,
|
|
9
|
+
dot: d = !1,
|
|
10
|
+
className: l,
|
|
11
|
+
children: n,
|
|
11
12
|
testId: o,
|
|
12
13
|
...m
|
|
13
14
|
}) => /* @__PURE__ */ i(
|
|
@@ -17,28 +18,28 @@ const g = ({
|
|
|
17
18
|
"Bear-Badge",
|
|
18
19
|
"bear-inline-flex bear-items-center bear-gap-1.5 bear-font-medium",
|
|
19
20
|
c[s],
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
f[e],
|
|
22
|
+
t ? "Bear-Badge--pill bear-rounded-full" : "bear-rounded-md",
|
|
23
|
+
l
|
|
23
24
|
),
|
|
24
25
|
"data-testid": o,
|
|
25
26
|
...m,
|
|
26
27
|
children: [
|
|
27
|
-
|
|
28
|
+
d && /* @__PURE__ */ a(
|
|
28
29
|
"span",
|
|
29
30
|
{
|
|
30
31
|
className: r(
|
|
31
32
|
"Bear-Badge__dot",
|
|
32
|
-
|
|
33
|
+
B,
|
|
33
34
|
"bear-rounded-full",
|
|
34
|
-
|
|
35
|
+
p[e]
|
|
35
36
|
)
|
|
36
37
|
}
|
|
37
38
|
),
|
|
38
|
-
/* @__PURE__ */ a("span", { className: "Bear-Badge__content", children:
|
|
39
|
+
/* @__PURE__ */ a("span", { className: "Bear-Badge__content", children: n })
|
|
39
40
|
]
|
|
40
41
|
}
|
|
41
42
|
);
|
|
42
43
|
export {
|
|
43
|
-
|
|
44
|
+
x as Badge
|
|
44
45
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { HTMLAttributes } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { BearSize, BearVariant } from '../../types';
|
|
3
3
|
export interface BadgeProps extends HTMLAttributes<HTMLSpanElement> {
|
|
4
4
|
/** Badge variant */
|
|
5
|
-
variant?:
|
|
5
|
+
variant?: BearVariant | 'neutral';
|
|
6
6
|
/** Badge size */
|
|
7
|
-
size?: Exclude<
|
|
7
|
+
size?: Exclude<BearSize, 'xl'>;
|
|
8
8
|
/** Whether badge is pill shaped */
|
|
9
9
|
pill?: boolean;
|
|
10
10
|
/** Whether badge has a dot indicator */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("../../utils/cn.cjs")
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("../../utils/cn.cjs");require("react");const t=({size:r=48,className:o,animated:s=!1})=>e.jsxs("svg",{width:r,height:r,viewBox:"0 0 100 100",fill:"none",className:l.cn("bear-logo",s&&"bear-animate-bear-glow",o),children:[e.jsxs("defs",{children:[e.jsxs("linearGradient",{id:"emberFlameGrad",x1:"50%",y1:"100%",x2:"50%",y2:"0%",children:[e.jsx("stop",{offset:"0%",stopColor:"#ea580c"}),e.jsx("stop",{offset:"30%",stopColor:"#f97316"}),e.jsx("stop",{offset:"60%",stopColor:"#fb923c"}),e.jsx("stop",{offset:"100%",stopColor:"#fed7aa"})]}),e.jsxs("linearGradient",{id:"emberCoreGrad",x1:"50%",y1:"100%",x2:"50%",y2:"0%",children:[e.jsx("stop",{offset:"0%",stopColor:"#f97316"}),e.jsx("stop",{offset:"50%",stopColor:"#fbbf24"}),e.jsx("stop",{offset:"100%",stopColor:"#fef3c7"})]}),e.jsxs("filter",{id:"emberGlow",x:"-50%",y:"-50%",width:"200%",height:"200%",children:[e.jsx("feGaussianBlur",{stdDeviation:"3",result:"coloredBlur"}),e.jsxs("feMerge",{children:[e.jsx("feMergeNode",{in:"coloredBlur"}),e.jsx("feMergeNode",{in:"SourceGraphic"})]})]})]}),e.jsx("circle",{cx:"50",cy:"50",r:"45",fill:"#1a1a2e",stroke:"url(#emberFlameGrad)",strokeWidth:"2"}),e.jsx("path",{d:`M50 15
|
|
2
2
|
C35 30 25 45 25 60
|
|
3
3
|
C25 75 35 85 50 85
|
|
4
4
|
C65 85 75 75 75 60
|