@driveflux/beam 3.0.16 → 3.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/accordion/Accordion.js +87 -17
- package/dist/accordion/Accordion.stories.js +1 -1
- package/dist/alert/Alert.d.ts +1 -1
- package/dist/alert/Alert.d.ts.map +1 -1
- package/dist/alert/Alert.js +94 -21
- package/dist/alert/Alert.js.map +1 -1
- package/dist/alert/Alert.stories.js +3 -3
- package/dist/animations/LoadingAnimation.js +1 -1
- package/dist/badge/Badge.js +19 -10
- package/dist/badge/Badge.stories.js +1 -1
- package/dist/base-styles.css +1 -1
- package/dist/box/Box.js +75 -11
- package/dist/box/Box.stories.js +1 -1
- package/dist/breadcrumbs/Breadcrumbs.d.ts +1 -1
- package/dist/breadcrumbs/Breadcrumbs.d.ts.map +1 -1
- package/dist/breadcrumbs/Breadcrumbs.js +94 -31
- package/dist/breadcrumbs/Breadcrumbs.js.map +1 -1
- package/dist/breadcrumbs/Breadcrumbs.stories.js +3 -3
- package/dist/button/Button.js +75 -11
- package/dist/button/Button.stories.js +1 -1
- package/dist/button/TextButton.js +75 -11
- package/dist/card/Card.js +105 -26
- package/dist/card/Card.stories.js +1 -1
- package/dist/carousel/Carousel.js +53 -26
- package/dist/carousel/Carousel.stories.js +1 -1
- package/dist/carousel/CarouselButton.js +75 -11
- package/dist/center/Center.js +75 -11
- package/dist/center/Center.stories.js +1 -1
- package/dist/checkbox/Checkbox.js +77 -13
- package/dist/checkbox/Checkbox.stories.js +1 -1
- package/dist/chip/Chip.js +75 -11
- package/dist/chip/Chip.stories.js +1 -1
- package/dist/circular-progress/CircularProgress.js +23 -14
- package/dist/circular-progress/CircularProgress.stories.js +4 -4
- package/dist/command/command.d.ts +1 -1
- package/dist/command/command.d.ts.map +1 -1
- package/dist/command/command.js +110 -31
- package/dist/command/command.js.map +1 -1
- package/dist/datepicker/DatePicker.d.ts.map +1 -1
- package/dist/datepicker/DatePicker.js +25 -16
- package/dist/datepicker/DatePicker.js.map +1 -1
- package/dist/datepicker/DatePicker.stories.js +12 -13
- package/dist/datepicker/DatePicker.stories.js.map +1 -1
- package/dist/datepicker/DatePickerDrawer.js +4 -4
- package/dist/datepicker/DatePickerPopover.js +7 -7
- package/dist/datepicker/utils.js +2 -2
- package/dist/dialog/index.js +97 -24
- package/dist/dialog/index.js.map +1 -1
- package/dist/divider/Divider.js +75 -11
- package/dist/divider/Divider.stories.js +1 -1
- package/dist/drawer/index.js +99 -26
- package/dist/dropdown/Dropdown.js +119 -34
- package/dist/dropdown/Dropdown.stories.js +3 -3
- package/dist/dropdown/Dropdown.stories.js.map +1 -1
- package/dist/field-wrapper/FieldWrapper.js +75 -11
- package/dist/field-wrapper/FieldWrapper.stories.js +5 -5
- package/dist/flex/Flex.js +75 -11
- package/dist/flex/Flex.stories.js +1 -1
- package/dist/grid/Grid.js +75 -11
- package/dist/grid/Grid.stories.js +1 -1
- package/dist/hooks/use-breakpoint-value.js +2 -2
- package/dist/hooks/use-media-query.js +4 -4
- package/dist/hstack/HStack.js +75 -11
- package/dist/hstack/HStack.stories.js +1 -1
- package/dist/icons/FluxLogo.js +22 -13
- package/dist/icons/FluxLogoTable.js +19 -10
- package/dist/icons/Icon.js +19 -10
- package/dist/icons/Icon.stories.js +1 -1
- package/dist/icons/Icon24Hours.js +19 -10
- package/dist/icons/IconAcceleration.js +19 -10
- package/dist/icons/IconAccount.js +19 -10
- package/dist/icons/IconApplicant.js +19 -10
- package/dist/icons/IconArrow.js +20 -11
- package/dist/icons/IconArrowBack.js +19 -10
- package/dist/icons/IconArrowForward.js +19 -10
- package/dist/icons/IconArrowTopLeft.js +19 -10
- package/dist/icons/IconBluesharkProductGuide.js +22 -13
- package/dist/icons/IconBolt.js +19 -10
- package/dist/icons/IconBriefcase.js +19 -10
- package/dist/icons/IconBulb.js +19 -10
- package/dist/icons/IconCalendar.js +19 -10
- package/dist/icons/IconCalendarArrowBack.js +19 -10
- package/dist/icons/IconCalendarArrowForward.js +19 -10
- package/dist/icons/IconCalendarDoubleArrowBack.js +19 -10
- package/dist/icons/IconCalendarDoubleArrowForward.js +19 -10
- package/dist/icons/IconCancel.js +19 -10
- package/dist/icons/IconCancelMark.js +19 -10
- package/dist/icons/IconCarSUV.js +19 -10
- package/dist/icons/IconCarSedan.js +23 -14
- package/dist/icons/IconChain.js +19 -10
- package/dist/icons/IconCheckmark.js +19 -10
- package/dist/icons/IconChevronRight.js +19 -10
- package/dist/icons/IconCircle.js +19 -10
- package/dist/icons/IconCircleCheckmark.js +19 -10
- package/dist/icons/IconCircleError.js +19 -10
- package/dist/icons/IconCircleExclamation.js +19 -10
- package/dist/icons/IconCircleMark.js +19 -10
- package/dist/icons/IconCircleOutline.js +19 -10
- package/dist/icons/IconClock.js +19 -10
- package/dist/icons/IconClose.js +19 -10
- package/dist/icons/IconCollapseAll.js +19 -10
- package/dist/icons/IconConcierge.js +19 -10
- package/dist/icons/IconConciergeService.js +19 -10
- package/dist/icons/IconCreditCard.js +19 -10
- package/dist/icons/IconDash.js +19 -10
- package/dist/icons/IconDeliver.js +19 -10
- package/dist/icons/IconDelivery.js +21 -12
- package/dist/icons/IconDetails.js +19 -10
- package/dist/icons/IconDot.js +19 -10
- package/dist/icons/IconDownload.js +19 -10
- package/dist/icons/IconEVCharging.js +19 -10
- package/dist/icons/IconElectricCarFuel.js +19 -10
- package/dist/icons/IconEllipsis.js +19 -10
- package/dist/icons/IconEnvelope.js +19 -10
- package/dist/icons/IconExpandAll.js +19 -10
- package/dist/icons/IconEye.js +22 -13
- package/dist/icons/IconFacebook.js +19 -10
- package/dist/icons/IconFilter.js +19 -10
- package/dist/icons/IconFlagMalaysia.js +19 -10
- package/dist/icons/IconGiveKey.js +19 -10
- package/dist/icons/IconGlobe.js +19 -10
- package/dist/icons/IconGoogle.js +22 -13
- package/dist/icons/IconHome.js +21 -12
- package/dist/icons/IconHostAdvertise.js +19 -10
- package/dist/icons/IconHostCar.js +19 -10
- package/dist/icons/IconHostCash.js +19 -10
- package/dist/icons/IconHostHandle.js +19 -10
- package/dist/icons/IconHostLocation.js +19 -10
- package/dist/icons/IconHostPayment.js +19 -10
- package/dist/icons/IconHostService.js +19 -10
- package/dist/icons/IconHotDeals.js +19 -10
- package/dist/icons/IconInfo.js +19 -10
- package/dist/icons/IconInstagram.js +19 -10
- package/dist/icons/IconInsurance.js +19 -10
- package/dist/icons/IconInternet.js +19 -10
- package/dist/icons/IconInventory.js +21 -12
- package/dist/icons/IconLaurel.js +19 -10
- package/dist/icons/IconLinkedIn.js +19 -10
- package/dist/icons/IconLoading.js +19 -10
- package/dist/icons/IconLocation.js +19 -10
- package/dist/icons/IconLock.js +19 -10
- package/dist/icons/IconLogistics.js +19 -10
- package/dist/icons/IconMail.js +25 -16
- package/dist/icons/IconMember.js +21 -12
- package/dist/icons/IconMobilePen.js +19 -10
- package/dist/icons/IconMotorcycleMoped.js +21 -12
- package/dist/icons/IconNoCost.js +21 -12
- package/dist/icons/IconPDF.js +19 -10
- package/dist/icons/IconPencil.js +19 -10
- package/dist/icons/IconPhone.js +19 -10
- package/dist/icons/IconPlus.js +19 -10
- package/dist/icons/IconPricing.js +19 -10
- package/dist/icons/IconProtected.js +20 -11
- package/dist/icons/IconPsychology.js +19 -10
- package/dist/icons/IconQuestionTooltip.js +75 -11
- package/dist/icons/IconQuote.js +19 -10
- package/dist/icons/IconRate.js +20 -11
- package/dist/icons/IconRegister.js +19 -10
- package/dist/icons/IconReport.js +21 -12
- package/dist/icons/IconReturn.js +19 -10
- package/dist/icons/IconSearch.js +19 -10
- package/dist/icons/IconSecure.js +20 -11
- package/dist/icons/IconSecurity.js +19 -10
- package/dist/icons/IconSedanOutline.js +19 -10
- package/dist/icons/IconSelectArrow.js +20 -11
- package/dist/icons/IconSort.js +19 -10
- package/dist/icons/IconSortListed.js +19 -10
- package/dist/icons/IconSortPriceAscending.js +19 -10
- package/dist/icons/IconSortPriceDescending.js +19 -10
- package/dist/icons/IconSortYear.js +19 -10
- package/dist/icons/IconSpan.js +20 -11
- package/dist/icons/IconSpeaker.js +19 -10
- package/dist/icons/IconSpecialCar.js +20 -11
- package/dist/icons/IconStar.js +19 -10
- package/dist/icons/IconStockPhoto.js +19 -10
- package/dist/icons/IconSubscription.js +19 -10
- package/dist/icons/IconSubscriptions.js +19 -10
- package/dist/icons/IconSwap.js +19 -10
- package/dist/icons/IconTax.js +19 -10
- package/dist/icons/IconThinArrow.js +20 -11
- package/dist/icons/IconThumbsdown.js +19 -10
- package/dist/icons/IconThumbsup.js +19 -10
- package/dist/icons/IconTool.js +20 -11
- package/dist/icons/IconTooltip.js +75 -11
- package/dist/icons/IconTrash.js +19 -10
- package/dist/icons/IconTriangleExclamation.js +19 -10
- package/dist/icons/IconTyersBrakes.js +19 -10
- package/dist/icons/IconTyre.js +19 -10
- package/dist/icons/IconVacancy.js +19 -10
- package/dist/icons/IconVolunteer.js +19 -10
- package/dist/icons/IconWhatsapp.js +19 -10
- package/dist/icons/IconXPlatform.js +19 -10
- package/dist/icons/IconZeroEffort.js +21 -12
- package/dist/icons/Logo.js +19 -10
- package/dist/input/Input.js +17 -8
- package/dist/input-mask/InputMask.js +19 -10
- package/dist/input-mask/mask-trackers.js +1 -1
- package/dist/input-select/InputSelect.js +74 -41
- package/dist/input-select/InputSelect.stories.js +1 -1
- package/dist/popover/popover.d.ts +1 -1
- package/dist/popover/popover.js +76 -12
- package/dist/progress/Progress.js +75 -11
- package/dist/radio/Radio.js +75 -11
- package/dist/scroll-area/scroll-area.js +81 -14
- package/dist/search-input-select/SearchInputSelect.js +72 -39
- package/dist/select/Select.js +73 -34
- package/dist/skeleton/Skeleton.js +19 -10
- package/dist/skeleton/Skeleton.stories.js +1 -1
- package/dist/slider/Slider.js +75 -11
- package/dist/slider/Slider.stories.js +1 -1
- package/dist/stack/Stack.js +75 -11
- package/dist/stack/Stack.stories.js +1 -1
- package/dist/styles.css +1 -7
- package/dist/table/Table.d.ts +1 -1
- package/dist/table/Table.d.ts.map +1 -1
- package/dist/table/Table.js +118 -33
- package/dist/table/Table.js.map +1 -1
- package/dist/table/Table.stories.js +1 -1
- package/dist/tabs/Tabs.js +89 -19
- package/dist/tabs/Tabs.stories.js +1 -1
- package/dist/text/Text.js +75 -11
- package/dist/text/Text.stories.js +1 -1
- package/dist/toast/Toast.stories.js +4 -4
- package/dist/toast/ToastBox.js +4 -4
- package/dist/toast/sonner.js +3 -3
- package/dist/toggle/Toggle.js +78 -14
- package/dist/toggle/Toggle.stories.js +1 -1
- package/dist/tooltip/Tooltip.js +32 -14
- package/dist/tooltip/Tooltip.stories.js +2 -2
- package/dist/vstack/VStack.js +75 -11
- package/dist/vstack/VStack.stories.js +1 -1
- package/package.json +29 -29
package/dist/table/Table.js
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
function _array_like_to_array(arr, len) {
|
|
2
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
3
|
+
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
4
|
+
return arr2;
|
|
5
|
+
}
|
|
6
|
+
function _array_with_holes(arr) {
|
|
7
|
+
if (Array.isArray(arr)) return arr;
|
|
8
|
+
}
|
|
1
9
|
function _define_property(obj, key, value) {
|
|
2
10
|
if (key in obj) {
|
|
3
11
|
Object.defineProperty(obj, key, {
|
|
@@ -11,6 +19,36 @@ function _define_property(obj, key, value) {
|
|
|
11
19
|
}
|
|
12
20
|
return obj;
|
|
13
21
|
}
|
|
22
|
+
function _iterable_to_array(iter) {
|
|
23
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
24
|
+
}
|
|
25
|
+
function _iterable_to_array_limit(arr, i) {
|
|
26
|
+
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
27
|
+
if (_i == null) return;
|
|
28
|
+
var _arr = [];
|
|
29
|
+
var _n = true;
|
|
30
|
+
var _d = false;
|
|
31
|
+
var _s, _e;
|
|
32
|
+
try {
|
|
33
|
+
for(_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true){
|
|
34
|
+
_arr.push(_s.value);
|
|
35
|
+
if (i && _arr.length === i) break;
|
|
36
|
+
}
|
|
37
|
+
} catch (err) {
|
|
38
|
+
_d = true;
|
|
39
|
+
_e = err;
|
|
40
|
+
} finally{
|
|
41
|
+
try {
|
|
42
|
+
if (!_n && _i["return"] != null) _i["return"]();
|
|
43
|
+
} finally{
|
|
44
|
+
if (_d) throw _e;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
return _arr;
|
|
48
|
+
}
|
|
49
|
+
function _non_iterable_rest() {
|
|
50
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
51
|
+
}
|
|
14
52
|
function _object_spread(target) {
|
|
15
53
|
for(var i = 1; i < arguments.length; i++){
|
|
16
54
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
@@ -28,12 +66,22 @@ function _object_spread(target) {
|
|
|
28
66
|
}
|
|
29
67
|
function _object_without_properties(source, excluded) {
|
|
30
68
|
if (source == null) return {};
|
|
31
|
-
var target =
|
|
32
|
-
|
|
69
|
+
var target = {}, sourceKeys, key, i;
|
|
70
|
+
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
71
|
+
sourceKeys = Reflect.ownKeys(Object(source));
|
|
72
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
73
|
+
key = sourceKeys[i];
|
|
74
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
75
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
76
|
+
target[key] = source[key];
|
|
77
|
+
}
|
|
78
|
+
return target;
|
|
79
|
+
}
|
|
80
|
+
target = _object_without_properties_loose(source, excluded);
|
|
33
81
|
if (Object.getOwnPropertySymbols) {
|
|
34
|
-
|
|
35
|
-
for(i = 0; i <
|
|
36
|
-
key =
|
|
82
|
+
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
83
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
84
|
+
key = sourceKeys[i];
|
|
37
85
|
if (excluded.indexOf(key) >= 0) continue;
|
|
38
86
|
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
39
87
|
target[key] = source[key];
|
|
@@ -43,23 +91,39 @@ function _object_without_properties(source, excluded) {
|
|
|
43
91
|
}
|
|
44
92
|
function _object_without_properties_loose(source, excluded) {
|
|
45
93
|
if (source == null) return {};
|
|
46
|
-
var target = {};
|
|
47
|
-
var sourceKeys = Object.keys(source);
|
|
48
|
-
var key, i;
|
|
94
|
+
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
49
95
|
for(i = 0; i < sourceKeys.length; i++){
|
|
50
96
|
key = sourceKeys[i];
|
|
51
97
|
if (excluded.indexOf(key) >= 0) continue;
|
|
98
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
52
99
|
target[key] = source[key];
|
|
53
100
|
}
|
|
54
101
|
return target;
|
|
55
102
|
}
|
|
103
|
+
function _sliced_to_array(arr, i) {
|
|
104
|
+
return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
|
|
105
|
+
}
|
|
106
|
+
function _to_array(arr) {
|
|
107
|
+
return _array_with_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_rest();
|
|
108
|
+
}
|
|
109
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
110
|
+
if (!o) return;
|
|
111
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
112
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
113
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
114
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
115
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
116
|
+
}
|
|
56
117
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
57
118
|
import * as React from 'react';
|
|
58
119
|
import { cn } from '../utils';
|
|
59
|
-
var Table = /*#__PURE__*/ React.forwardRef(function(
|
|
60
|
-
var
|
|
120
|
+
var Table = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
121
|
+
var _ref = [
|
|
122
|
+
_0,
|
|
123
|
+
_1
|
|
124
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
61
125
|
"className"
|
|
62
|
-
]);
|
|
126
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
63
127
|
return /*#__PURE__*/ _jsx("div", {
|
|
64
128
|
className: "relative w-full overflow-auto",
|
|
65
129
|
children: /*#__PURE__*/ _jsx("table", _object_spread({
|
|
@@ -69,74 +133,95 @@ var Table = /*#__PURE__*/ React.forwardRef(function(_param, ref) {
|
|
|
69
133
|
});
|
|
70
134
|
});
|
|
71
135
|
Table.displayName = 'Table';
|
|
72
|
-
var TableHeader = /*#__PURE__*/ React.forwardRef(function(
|
|
73
|
-
var
|
|
136
|
+
var TableHeader = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
137
|
+
var _ref = [
|
|
138
|
+
_0,
|
|
139
|
+
_1
|
|
140
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
74
141
|
"className"
|
|
75
|
-
]);
|
|
142
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
76
143
|
return /*#__PURE__*/ _jsx("thead", _object_spread({
|
|
77
144
|
ref: ref,
|
|
78
145
|
className: cn('[&_tr]:border-b', className)
|
|
79
146
|
}, props));
|
|
80
147
|
});
|
|
81
148
|
TableHeader.displayName = 'TableHeader';
|
|
82
|
-
var TableBody = /*#__PURE__*/ React.forwardRef(function(
|
|
83
|
-
var
|
|
149
|
+
var TableBody = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
150
|
+
var _ref = [
|
|
151
|
+
_0,
|
|
152
|
+
_1
|
|
153
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
84
154
|
"className"
|
|
85
|
-
]);
|
|
155
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
86
156
|
return /*#__PURE__*/ _jsx("tbody", _object_spread({
|
|
87
157
|
ref: ref,
|
|
88
158
|
className: cn('[&_tr:last-child]:border-0', className)
|
|
89
159
|
}, props));
|
|
90
160
|
});
|
|
91
161
|
TableBody.displayName = 'TableBody';
|
|
92
|
-
var TableFooter = /*#__PURE__*/ React.forwardRef(function(
|
|
93
|
-
var
|
|
162
|
+
var TableFooter = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
163
|
+
var _ref = [
|
|
164
|
+
_0,
|
|
165
|
+
_1
|
|
166
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
94
167
|
"className"
|
|
95
|
-
]);
|
|
168
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
96
169
|
return /*#__PURE__*/ _jsx("tfoot", _object_spread({
|
|
97
170
|
ref: ref,
|
|
98
171
|
className: cn('border-t bg-zinc-100/50 font-medium last:[&>tr]:border-b-0 dark:bg-zinc-800/50', className)
|
|
99
172
|
}, props));
|
|
100
173
|
});
|
|
101
174
|
TableFooter.displayName = 'TableFooter';
|
|
102
|
-
var TableRow = /*#__PURE__*/ React.forwardRef(function(
|
|
103
|
-
var
|
|
175
|
+
var TableRow = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
176
|
+
var _ref = [
|
|
177
|
+
_0,
|
|
178
|
+
_1
|
|
179
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
104
180
|
"className"
|
|
105
|
-
]);
|
|
181
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
106
182
|
return /*#__PURE__*/ _jsx("tr", _object_spread({
|
|
107
183
|
ref: ref,
|
|
108
184
|
className: cn('h-10 border-b transition-colors hover:bg-zinc-100/50 data-[state=selected]:bg-zinc-100 dark:hover:bg-zinc-800/50 dark:data-[state=selected]:bg-zinc-800', className)
|
|
109
185
|
}, props));
|
|
110
186
|
});
|
|
111
187
|
TableRow.displayName = 'TableRow';
|
|
112
|
-
var TableHead = /*#__PURE__*/ React.forwardRef(function(
|
|
113
|
-
var
|
|
188
|
+
var TableHead = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
189
|
+
var _ref = [
|
|
190
|
+
_0,
|
|
191
|
+
_1
|
|
192
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
114
193
|
"className"
|
|
115
|
-
]);
|
|
194
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
116
195
|
return /*#__PURE__*/ _jsx("th", _object_spread({
|
|
117
196
|
ref: ref,
|
|
118
197
|
className: cn('px-3 text-left align-middle font-bold text-black [&:has([role=checkbox])]:pr-0 dark:text-zinc-400', className)
|
|
119
198
|
}, props));
|
|
120
199
|
});
|
|
121
200
|
TableHead.displayName = 'TableHead';
|
|
122
|
-
var TableCell = /*#__PURE__*/ React.forwardRef(function(
|
|
123
|
-
var
|
|
201
|
+
var TableCell = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
202
|
+
var _ref = [
|
|
203
|
+
_0,
|
|
204
|
+
_1
|
|
205
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
124
206
|
"className"
|
|
125
|
-
]);
|
|
207
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
126
208
|
return /*#__PURE__*/ _jsx("td", _object_spread({
|
|
127
209
|
ref: ref,
|
|
128
210
|
className: cn('px-3 align-middle [&:has([role=checkbox])]:pr-0', className)
|
|
129
211
|
}, props));
|
|
130
212
|
});
|
|
131
213
|
TableCell.displayName = 'TableCell';
|
|
132
|
-
var TableCaption = /*#__PURE__*/ React.forwardRef(function(
|
|
133
|
-
var
|
|
214
|
+
var TableCaption = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
215
|
+
var _ref = [
|
|
216
|
+
_0,
|
|
217
|
+
_1
|
|
218
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
134
219
|
"className"
|
|
135
|
-
]);
|
|
220
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
136
221
|
return /*#__PURE__*/ _jsx("caption", _object_spread({
|
|
137
222
|
ref: ref,
|
|
138
223
|
className: cn('mt-4 text-sm text-zinc-500 dark:text-zinc-400', className)
|
|
139
224
|
}, props));
|
|
140
225
|
});
|
|
141
226
|
TableCaption.displayName = 'TableCaption';
|
|
142
|
-
export { Table,
|
|
227
|
+
export { Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, };
|
package/dist/table/Table.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Table.js","sourceRoot":"","sources":["../../src/table/Table.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,EAAE,EAAE,MAAM,UAAU,CAAA;AAE7B,MAAM,KAAK,GAAG,KAAK,CAAC,UAAU,CAG5B,CAAC,EAAE,SAAS,EAAE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like_to_array(arr, len) {
|
|
3
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
4
|
+
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
5
|
+
return arr2;
|
|
6
|
+
}
|
|
7
|
+
function _array_with_holes(arr) {
|
|
8
|
+
if (Array.isArray(arr)) return arr;
|
|
9
|
+
}
|
|
2
10
|
function _define_property(obj, key, value) {
|
|
3
11
|
if (key in obj) {
|
|
4
12
|
Object.defineProperty(obj, key, {
|
|
@@ -12,6 +20,36 @@ function _define_property(obj, key, value) {
|
|
|
12
20
|
}
|
|
13
21
|
return obj;
|
|
14
22
|
}
|
|
23
|
+
function _iterable_to_array(iter) {
|
|
24
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
25
|
+
}
|
|
26
|
+
function _iterable_to_array_limit(arr, i) {
|
|
27
|
+
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
28
|
+
if (_i == null) return;
|
|
29
|
+
var _arr = [];
|
|
30
|
+
var _n = true;
|
|
31
|
+
var _d = false;
|
|
32
|
+
var _s, _e;
|
|
33
|
+
try {
|
|
34
|
+
for(_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true){
|
|
35
|
+
_arr.push(_s.value);
|
|
36
|
+
if (i && _arr.length === i) break;
|
|
37
|
+
}
|
|
38
|
+
} catch (err) {
|
|
39
|
+
_d = true;
|
|
40
|
+
_e = err;
|
|
41
|
+
} finally{
|
|
42
|
+
try {
|
|
43
|
+
if (!_n && _i["return"] != null) _i["return"]();
|
|
44
|
+
} finally{
|
|
45
|
+
if (_d) throw _e;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
return _arr;
|
|
49
|
+
}
|
|
50
|
+
function _non_iterable_rest() {
|
|
51
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
52
|
+
}
|
|
15
53
|
function _object_spread(target) {
|
|
16
54
|
for(var i = 1; i < arguments.length; i++){
|
|
17
55
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
@@ -53,12 +91,22 @@ function _object_spread_props(target, source) {
|
|
|
53
91
|
}
|
|
54
92
|
function _object_without_properties(source, excluded) {
|
|
55
93
|
if (source == null) return {};
|
|
56
|
-
var target =
|
|
57
|
-
|
|
94
|
+
var target = {}, sourceKeys, key, i;
|
|
95
|
+
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
96
|
+
sourceKeys = Reflect.ownKeys(Object(source));
|
|
97
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
98
|
+
key = sourceKeys[i];
|
|
99
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
100
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
101
|
+
target[key] = source[key];
|
|
102
|
+
}
|
|
103
|
+
return target;
|
|
104
|
+
}
|
|
105
|
+
target = _object_without_properties_loose(source, excluded);
|
|
58
106
|
if (Object.getOwnPropertySymbols) {
|
|
59
|
-
|
|
60
|
-
for(i = 0; i <
|
|
61
|
-
key =
|
|
107
|
+
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
108
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
109
|
+
key = sourceKeys[i];
|
|
62
110
|
if (excluded.indexOf(key) >= 0) continue;
|
|
63
111
|
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
64
112
|
target[key] = source[key];
|
|
@@ -68,23 +116,36 @@ function _object_without_properties(source, excluded) {
|
|
|
68
116
|
}
|
|
69
117
|
function _object_without_properties_loose(source, excluded) {
|
|
70
118
|
if (source == null) return {};
|
|
71
|
-
var target = {};
|
|
72
|
-
var sourceKeys = Object.keys(source);
|
|
73
|
-
var key, i;
|
|
119
|
+
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
74
120
|
for(i = 0; i < sourceKeys.length; i++){
|
|
75
121
|
key = sourceKeys[i];
|
|
76
122
|
if (excluded.indexOf(key) >= 0) continue;
|
|
123
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
77
124
|
target[key] = source[key];
|
|
78
125
|
}
|
|
79
126
|
return target;
|
|
80
127
|
}
|
|
128
|
+
function _sliced_to_array(arr, i) {
|
|
129
|
+
return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
|
|
130
|
+
}
|
|
131
|
+
function _to_array(arr) {
|
|
132
|
+
return _array_with_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_rest();
|
|
133
|
+
}
|
|
134
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
135
|
+
if (!o) return;
|
|
136
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
137
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
138
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
139
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
140
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
141
|
+
}
|
|
81
142
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
82
143
|
import * as TabsPrimitive from '@radix-ui/react-tabs';
|
|
83
144
|
import * as React from 'react';
|
|
84
145
|
import HStack from '../hstack/HStack';
|
|
85
146
|
import { cn } from '../utils';
|
|
86
|
-
var Tabs = function(
|
|
87
|
-
var defaultValue =
|
|
147
|
+
var Tabs = function Tabs(_0) {
|
|
148
|
+
var defaultValue = _0.defaultValue, props = _object_without_properties(_0, [
|
|
88
149
|
"defaultValue"
|
|
89
150
|
]);
|
|
90
151
|
var _React_Children_toArray_find_props_children_, _React_Children_toArray_find_props_children, _React_Children_toArray_find_props, _React_Children_toArray_find;
|
|
@@ -97,10 +158,13 @@ var Tabs = function(_param) {
|
|
|
97
158
|
defaultValue: defaultValue || firstTabValue
|
|
98
159
|
}, props));
|
|
99
160
|
};
|
|
100
|
-
var TabsList = /*#__PURE__*/ React.forwardRef(function(
|
|
101
|
-
var
|
|
161
|
+
var TabsList = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
162
|
+
var _ref = [
|
|
163
|
+
_0,
|
|
164
|
+
_1
|
|
165
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
102
166
|
"className"
|
|
103
|
-
]);
|
|
167
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
104
168
|
return /*#__PURE__*/ _jsx(TabsPrimitive.List, _object_spread({
|
|
105
169
|
ref: ref,
|
|
106
170
|
className: cn('inline-flex items-center w-full text-black text-[12px] border-b border-b-primary1', className)
|
|
@@ -108,11 +172,14 @@ var TabsList = /*#__PURE__*/ React.forwardRef(function(_param, ref) {
|
|
|
108
172
|
});
|
|
109
173
|
TabsList.displayName = TabsPrimitive.List.displayName;
|
|
110
174
|
// name of tab list
|
|
111
|
-
var Tab = /*#__PURE__*/ React.forwardRef(function(
|
|
112
|
-
var
|
|
175
|
+
var Tab = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
176
|
+
var _ref = [
|
|
177
|
+
_0,
|
|
178
|
+
_1
|
|
179
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, icon = _ref2.icon, props = _object_without_properties(_ref2, [
|
|
113
180
|
"className",
|
|
114
181
|
"icon"
|
|
115
|
-
]);
|
|
182
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
116
183
|
return /*#__PURE__*/ _jsx(TabsPrimitive.Trigger, _object_spread_props(_object_spread({
|
|
117
184
|
ref: ref,
|
|
118
185
|
className: cn('inline-flex items-center uppercase tracking-wider h-[32px] px-[16px] font-normal whitespace-nowrap', 'border-b border-primary2 -mb-px', 'data-[state=active]:font-bold data-[state=active]:border-b-2 data-[state=active]:border-b-[#50c8e8]', className)
|
|
@@ -128,10 +195,13 @@ var Tab = /*#__PURE__*/ React.forwardRef(function(_param, ref) {
|
|
|
128
195
|
});
|
|
129
196
|
Tab.displayName = TabsPrimitive.Trigger.displayName;
|
|
130
197
|
// the content for each tab
|
|
131
|
-
var TabsContent = /*#__PURE__*/ React.forwardRef(function(
|
|
132
|
-
var
|
|
198
|
+
var TabsContent = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
199
|
+
var _ref = [
|
|
200
|
+
_0,
|
|
201
|
+
_1
|
|
202
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), className = _ref2.className, props = _object_without_properties(_ref2, [
|
|
133
203
|
"className"
|
|
134
|
-
]);
|
|
204
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
135
205
|
return /*#__PURE__*/ _jsx(TabsPrimitive.Content, _object_spread({
|
|
136
206
|
ref: ref,
|
|
137
207
|
className: cn('mt-2 ring-offset-white focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-zinc-950 focus-visible:ring-offset-2 dark:ring-offset-zinc-950 dark:focus-visible:ring-zinc-300', className)
|
package/dist/text/Text.js
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
function _array_like_to_array(arr, len) {
|
|
2
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
3
|
+
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
4
|
+
return arr2;
|
|
5
|
+
}
|
|
6
|
+
function _array_with_holes(arr) {
|
|
7
|
+
if (Array.isArray(arr)) return arr;
|
|
8
|
+
}
|
|
1
9
|
function _define_property(obj, key, value) {
|
|
2
10
|
if (key in obj) {
|
|
3
11
|
Object.defineProperty(obj, key, {
|
|
@@ -11,6 +19,36 @@ function _define_property(obj, key, value) {
|
|
|
11
19
|
}
|
|
12
20
|
return obj;
|
|
13
21
|
}
|
|
22
|
+
function _iterable_to_array(iter) {
|
|
23
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
24
|
+
}
|
|
25
|
+
function _iterable_to_array_limit(arr, i) {
|
|
26
|
+
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
27
|
+
if (_i == null) return;
|
|
28
|
+
var _arr = [];
|
|
29
|
+
var _n = true;
|
|
30
|
+
var _d = false;
|
|
31
|
+
var _s, _e;
|
|
32
|
+
try {
|
|
33
|
+
for(_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true){
|
|
34
|
+
_arr.push(_s.value);
|
|
35
|
+
if (i && _arr.length === i) break;
|
|
36
|
+
}
|
|
37
|
+
} catch (err) {
|
|
38
|
+
_d = true;
|
|
39
|
+
_e = err;
|
|
40
|
+
} finally{
|
|
41
|
+
try {
|
|
42
|
+
if (!_n && _i["return"] != null) _i["return"]();
|
|
43
|
+
} finally{
|
|
44
|
+
if (_d) throw _e;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
return _arr;
|
|
48
|
+
}
|
|
49
|
+
function _non_iterable_rest() {
|
|
50
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
51
|
+
}
|
|
14
52
|
function _object_spread(target) {
|
|
15
53
|
for(var i = 1; i < arguments.length; i++){
|
|
16
54
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
@@ -52,12 +90,22 @@ function _object_spread_props(target, source) {
|
|
|
52
90
|
}
|
|
53
91
|
function _object_without_properties(source, excluded) {
|
|
54
92
|
if (source == null) return {};
|
|
55
|
-
var target =
|
|
56
|
-
|
|
93
|
+
var target = {}, sourceKeys, key, i;
|
|
94
|
+
if (typeof Reflect !== "undefined" && Reflect.ownKeys) {
|
|
95
|
+
sourceKeys = Reflect.ownKeys(Object(source));
|
|
96
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
97
|
+
key = sourceKeys[i];
|
|
98
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
99
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
100
|
+
target[key] = source[key];
|
|
101
|
+
}
|
|
102
|
+
return target;
|
|
103
|
+
}
|
|
104
|
+
target = _object_without_properties_loose(source, excluded);
|
|
57
105
|
if (Object.getOwnPropertySymbols) {
|
|
58
|
-
|
|
59
|
-
for(i = 0; i <
|
|
60
|
-
key =
|
|
106
|
+
sourceKeys = Object.getOwnPropertySymbols(source);
|
|
107
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
108
|
+
key = sourceKeys[i];
|
|
61
109
|
if (excluded.indexOf(key) >= 0) continue;
|
|
62
110
|
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
63
111
|
target[key] = source[key];
|
|
@@ -67,24 +115,40 @@ function _object_without_properties(source, excluded) {
|
|
|
67
115
|
}
|
|
68
116
|
function _object_without_properties_loose(source, excluded) {
|
|
69
117
|
if (source == null) return {};
|
|
70
|
-
var target = {};
|
|
71
|
-
var sourceKeys = Object.keys(source);
|
|
72
|
-
var key, i;
|
|
118
|
+
var target = {}, sourceKeys = Object.getOwnPropertyNames(source), key, i;
|
|
73
119
|
for(i = 0; i < sourceKeys.length; i++){
|
|
74
120
|
key = sourceKeys[i];
|
|
75
121
|
if (excluded.indexOf(key) >= 0) continue;
|
|
122
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
76
123
|
target[key] = source[key];
|
|
77
124
|
}
|
|
78
125
|
return target;
|
|
79
126
|
}
|
|
127
|
+
function _sliced_to_array(arr, i) {
|
|
128
|
+
return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
|
|
129
|
+
}
|
|
130
|
+
function _to_array(arr) {
|
|
131
|
+
return _array_with_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_rest();
|
|
132
|
+
}
|
|
133
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
134
|
+
if (!o) return;
|
|
135
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
136
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
137
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
138
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
139
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
140
|
+
}
|
|
80
141
|
import * as React from 'react';
|
|
81
142
|
import { cn } from '../utils.js';
|
|
82
|
-
var Text = /*#__PURE__*/ React.forwardRef(function(
|
|
83
|
-
var
|
|
143
|
+
var Text = /*#__PURE__*/ React.forwardRef(function(_0, _1) {
|
|
144
|
+
var _ref = [
|
|
145
|
+
_0,
|
|
146
|
+
_1
|
|
147
|
+
], _ref1 = _to_array(_ref), _ref2 = _ref1[0], _rest = _ref1.slice(1), _ref_as = _ref2.as, as = _ref_as === void 0 ? 'p' : _ref_as, className = _ref2.className, children = _ref2.children, props = _object_without_properties(_ref2, [
|
|
84
148
|
"as",
|
|
85
149
|
"className",
|
|
86
150
|
"children"
|
|
87
|
-
]);
|
|
151
|
+
]), _rest1 = _sliced_to_array(_rest, 1), ref = _rest1[0];
|
|
88
152
|
return /*#__PURE__*/ React.createElement(as, _object_spread_props(_object_spread({}, props), {
|
|
89
153
|
className: cn('text-base leading-[19.6px]', as === 'h3' && 'text-xl tracking-wide', as === 'h2' && 'text-2xl tracking-wider', className),
|
|
90
154
|
ref: ref
|
|
@@ -8,7 +8,7 @@ var meta = {
|
|
|
8
8
|
};
|
|
9
9
|
export default meta;
|
|
10
10
|
export var FirstStory = {
|
|
11
|
-
render: function() {
|
|
11
|
+
render: function render() {
|
|
12
12
|
return /*#__PURE__*/ _jsx(Outer, {
|
|
13
13
|
children: /*#__PURE__*/ _jsxs(VStack, {
|
|
14
14
|
children: [
|
|
@@ -54,9 +54,9 @@ export var FirstStory = {
|
|
|
54
54
|
});
|
|
55
55
|
}
|
|
56
56
|
};
|
|
57
|
-
var ToastButton = function(param) {
|
|
57
|
+
var ToastButton = function ToastButton(param) {
|
|
58
58
|
var title = param.title, description = param.description, status = param.status, buttonColor = param.buttonColor, _param_isClosable = param.isClosable, isClosable = _param_isClosable === void 0 ? true : _param_isClosable;
|
|
59
|
-
var showToast = function() {
|
|
59
|
+
var showToast = function showToast() {
|
|
60
60
|
toast({
|
|
61
61
|
title: title,
|
|
62
62
|
description: description,
|
|
@@ -71,7 +71,7 @@ var ToastButton = function(param) {
|
|
|
71
71
|
children: title
|
|
72
72
|
});
|
|
73
73
|
};
|
|
74
|
-
var Outer = function(param) {
|
|
74
|
+
var Outer = function Outer(param) {
|
|
75
75
|
var children = param.children;
|
|
76
76
|
return /*#__PURE__*/ _jsxs(Box, {
|
|
77
77
|
children: [
|
package/dist/toast/ToastBox.js
CHANGED
|
@@ -8,7 +8,7 @@ import IconClose from '../icons/IconClose';
|
|
|
8
8
|
import IconInfo from '../icons/IconInfo';
|
|
9
9
|
import IconTriangleExclamation from '../icons/IconTriangleExclamation';
|
|
10
10
|
import Text from '../text/Text';
|
|
11
|
-
var ToastBox = function(options) {
|
|
11
|
+
var ToastBox = function ToastBox(options) {
|
|
12
12
|
var title = options === null || options === void 0 ? void 0 : options.title;
|
|
13
13
|
var description = options === null || options === void 0 ? void 0 : options.description;
|
|
14
14
|
var isNumbered = options === null || options === void 0 ? void 0 : options.isNumbered;
|
|
@@ -40,7 +40,7 @@ var ToastBox = function(options) {
|
|
|
40
40
|
}),
|
|
41
41
|
(options === null || options === void 0 ? void 0 : options.isClosable) && /*#__PURE__*/ _jsx(Box, {
|
|
42
42
|
as: "button",
|
|
43
|
-
onClick: function() {
|
|
43
|
+
onClick: function onClick() {
|
|
44
44
|
toast.dismiss(options.id);
|
|
45
45
|
},
|
|
46
46
|
children: /*#__PURE__*/ _jsx(IconClose, {
|
|
@@ -50,7 +50,7 @@ var ToastBox = function(options) {
|
|
|
50
50
|
]
|
|
51
51
|
});
|
|
52
52
|
};
|
|
53
|
-
var splitText = function(text, isNumbered) {
|
|
53
|
+
var splitText = function splitText(text, isNumbered) {
|
|
54
54
|
var listItems = text.split('\n').map(function(line) {
|
|
55
55
|
return /*#__PURE__*/ _jsx("li", {
|
|
56
56
|
children: line
|
|
@@ -65,7 +65,7 @@ var splitText = function(text, isNumbered) {
|
|
|
65
65
|
children: listItems
|
|
66
66
|
});
|
|
67
67
|
};
|
|
68
|
-
var getStyles = function(status) {
|
|
68
|
+
var getStyles = function getStyles(status) {
|
|
69
69
|
var defaultStyles = {
|
|
70
70
|
icon: /*#__PURE__*/ _jsx(IconInfo, {
|
|
71
71
|
size: '24px'
|
package/dist/toast/sonner.js
CHANGED
|
@@ -49,8 +49,8 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
49
49
|
import { useTheme } from 'next-themes';
|
|
50
50
|
import { Toaster as Sonner, toast as sonnerToast } from 'sonner';
|
|
51
51
|
import ToastBox from './ToastBox';
|
|
52
|
-
var Toaster = function(
|
|
53
|
-
var props = _extends({},
|
|
52
|
+
var Toaster = function Toaster(_0) {
|
|
53
|
+
var ref = _object_destructuring_empty(_0), props = _extends({}, _0);
|
|
54
54
|
var _useTheme = useTheme(), _useTheme_theme = _useTheme.theme, theme = _useTheme_theme === void 0 ? 'system' : _useTheme_theme;
|
|
55
55
|
return /*#__PURE__*/ _jsx(Sonner, _object_spread({
|
|
56
56
|
theme: theme,
|
|
@@ -58,7 +58,7 @@ var Toaster = function(_param) {
|
|
|
58
58
|
position: "bottom-center"
|
|
59
59
|
}, props));
|
|
60
60
|
};
|
|
61
|
-
var toast = function(param) {
|
|
61
|
+
var toast = function toast(param) {
|
|
62
62
|
var title = param.title, description = param.description, status = param.status, _param_isClosable = param.isClosable, isClosable = _param_isClosable === void 0 ? true : _param_isClosable, isNumbered = param.isNumbered;
|
|
63
63
|
sonnerToast.custom(function(toastId) {
|
|
64
64
|
return /*#__PURE__*/ _jsx(ToastBox, {
|