@jars-labs/jars-components 1.0.80 → 1.1.0
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/{index-Di2CTm6m.js → index-Dpa5RAiC.js} +182 -120
- package/dist/index-Dpa5RAiC.js.map +1 -0
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.js +2 -2
- package/dist/{lottie-CAeceDXT.js → lottie-DfsERZoD.js} +2 -2
- package/dist/{lottie-CAeceDXT.js.map → lottie-DfsERZoD.js.map} +1 -1
- package/dist/types/Avatar/Avatar.d.ts +2 -2
- package/dist/types/Avatar/Avatar.d.ts.map +1 -1
- package/dist/types/DateInput/DateInput.d.ts.map +1 -1
- package/dist/types/Icons/AvatarPlaceholder.d.ts.map +1 -1
- package/dist/types/Icons/Icon.d.ts.map +1 -1
- package/dist/types/Icons/IconTypes.d.ts +8 -8
- package/dist/types/Icons/IconTypes.d.ts.map +1 -1
- package/dist/types/Input/Input.d.ts.map +1 -1
- package/dist/types/Input/inputWrapperSlotProps.d.ts +12 -0
- package/dist/types/Input/inputWrapperSlotProps.d.ts.map +1 -0
- package/dist/types/NavBar/NavBar.d.ts.map +1 -1
- package/dist/types/Pill/Pill.d.ts +29 -0
- package/dist/types/Pill/Pill.d.ts.map +1 -0
- package/dist/types/Select/Select.d.ts.map +1 -1
- package/dist/types/Textarea/Textarea.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +3 -3
- package/dist/index-Di2CTm6m.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
2
|
-
import { Accordion as Accordion$1, AccordionItem as AccordionItem$1, AccordionControl as AccordionControl$1, AccordionPanel as AccordionPanel$1, ActionIcon as ActionIcon$1, Group, Combobox, useCombobox, Flex, TextInput, Loader as Loader$1, Checkbox as Checkbox$1, Menu as Menu$1, Divider, Modal as Modal$1, Tooltip as Tooltip$1, Box, Tabs as Tabs$1, Pagination as Pagination$1, Radio, SegmentedControl as SegmentedControl$1, Select as Select$1, Stepper as Stepper$1, StepperStep, Progress, Table as Table$1, Textarea as Textarea$1 } from '@mantine/core';
|
|
2
|
+
import { Accordion as Accordion$1, AccordionItem as AccordionItem$1, AccordionControl as AccordionControl$1, AccordionPanel as AccordionPanel$1, ActionIcon as ActionIcon$1, Group, Combobox, useCombobox, Flex, TextInput, Loader as Loader$1, Avatar as Avatar$1, Checkbox as Checkbox$1, Menu as Menu$1, Divider, Modal as Modal$1, Tooltip as Tooltip$1, Box, Tabs as Tabs$1, Pagination as Pagination$1, Radio, SegmentedControl as SegmentedControl$1, Select as Select$1, Stepper as Stepper$1, StepperStep, Progress, Table as Table$1, Textarea as Textarea$1 } from '@mantine/core';
|
|
3
3
|
import React, { useRef, useState, useEffect, forwardRef, useMemo, useLayoutEffect } from 'react';
|
|
4
4
|
import { DateInput as DateInput$1 } from '@mantine/dates';
|
|
5
5
|
import { ToastContainer as ToastContainer$1 } from 'react-toastify';
|
|
@@ -59,14 +59,14 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
59
59
|
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
60
60
|
};
|
|
61
61
|
|
|
62
|
-
var styles$
|
|
62
|
+
var styles$r = {"accordion":"Accordion-module_accordion__Nl0Vb","item":"Accordion-module_item__85Qrt","item-neutral":"Accordion-module_item-neutral__c06SU","item-white":"Accordion-module_item-white__l-DtA","chevron":"Accordion-module_chevron__kqKKx","bottom-right":"Accordion-module_bottom-right__2C-t6","control":"Accordion-module_control__92uvC","content":"Accordion-module_content__LkKAo","label":"Accordion-module_label__VkyEF"};
|
|
63
63
|
|
|
64
64
|
var serverSideRenderSVG = function (_a, children) {
|
|
65
65
|
var width = _a.width, height = _a.height, viewBox = _a.viewBox, fill = _a.fill, rotate = _a.rotate;
|
|
66
66
|
return (jsx("svg", { width: width, height: height, viewBox: viewBox, fill: fill, preserveAspectRatio: "xMidYMid meet", xmlns: "http://www.w3.org/2000/svg", transform: "rotate(".concat(rotate, ")"), children: children }));
|
|
67
67
|
};
|
|
68
68
|
var Icon = function (_a) {
|
|
69
|
-
var _b = _a.width, width = _b === undefined ? '32px' : _b, _c = _a.height, height = _c === undefined ? '32px' : _c, viewBox = _a.viewBox, _d = _a.fill, fill = _d === undefined ? 'none' : _d, _e = _a.stroke, stroke = _e === undefined ? 'currentColor' : _e, _f = _a.rotate, rotate = _f === undefined ? 0 : _f, _g = _a.style, style = _g === undefined ? {} : _g, children = _a.children;
|
|
69
|
+
var _b = _a.width, width = _b === undefined ? '32px' : _b, _c = _a.height, height = _c === undefined ? '32px' : _c, viewBox = _a.viewBox, _d = _a.fill, fill = _d === undefined ? 'none' : _d, _e = _a.stroke, stroke = _e === undefined ? 'currentColor' : _e, _f = _a.rotate, rotate = _f === undefined ? 0 : _f, _g = _a.style, style = _g === undefined ? {} : _g, children = _a.children, rest = __rest(_a, ["width", "height", "viewBox", "fill", "stroke", "rotate", "style", "children"]);
|
|
70
70
|
if (typeof window === 'undefined') {
|
|
71
71
|
serverSideRenderSVG({
|
|
72
72
|
width: width,
|
|
@@ -108,7 +108,7 @@ var Icon = function (_a) {
|
|
|
108
108
|
};
|
|
109
109
|
centerSvgInViewBox();
|
|
110
110
|
}, [viewBox]);
|
|
111
|
-
return (jsx("svg", { ref: svgRef, width: width, height: height, viewBox: viewBox, fill: fill, stroke: stroke, preserveAspectRatio: "xMidYMid meet", style: __assign(__assign({}, style), { transform: "rotate(".concat(rotate, "deg)"), transformOrigin: 'center' }), children: jsx("g", { transform: transform || undefined, children: children }) }));
|
|
111
|
+
return (jsx("svg", __assign({ ref: svgRef, width: width, height: height, viewBox: viewBox, fill: fill, stroke: stroke, preserveAspectRatio: "xMidYMid meet", style: __assign(__assign({}, style), { transform: "rotate(".concat(rotate, "deg)"), transformOrigin: 'center' }) }, rest, { children: jsx("g", { transform: transform || undefined, children: children }) })));
|
|
112
112
|
};
|
|
113
113
|
Icon.displayName = 'Icon';
|
|
114
114
|
|
|
@@ -131,30 +131,30 @@ var Accordion = function (_a) {
|
|
|
131
131
|
return child;
|
|
132
132
|
});
|
|
133
133
|
return (jsx(Accordion$1, { variant: "unstyled", chevron: jsx(Chevron, { rotate: 270, width: "24px", height: "24px" }), chevronSize: 24, classNames: {
|
|
134
|
-
root: styles$
|
|
135
|
-
chevron: "".concat(styles$
|
|
134
|
+
root: styles$r.accordion,
|
|
135
|
+
chevron: "".concat(styles$r.chevron, " ").concat(styles$r[customChevronPosition]),
|
|
136
136
|
}, multiple: true, children: childrenWithColor }));
|
|
137
137
|
};
|
|
138
138
|
Accordion.displayName = 'Accordion';
|
|
139
139
|
var AccordionItem = function (_a) {
|
|
140
140
|
var children = _a.children, value = _a.value, _b = _a.bgColor, bgColor = _b === undefined ? 'neutral' : _b, props = __rest(_a, ["children", "value", "bgColor"]);
|
|
141
141
|
return (jsx(AccordionItem$1, __assign({ classNames: {
|
|
142
|
-
item: "".concat(styles$
|
|
142
|
+
item: "".concat(styles$r.item, " ").concat(bgColor === 'white' ? styles$r['item-white'] : styles$r['item-neutral']),
|
|
143
143
|
}, value: value }, props, { children: children })));
|
|
144
144
|
};
|
|
145
145
|
AccordionItem.displayName = 'AccordionItem';
|
|
146
146
|
var AccordionControl = function (_a) {
|
|
147
147
|
var children = _a.children;
|
|
148
|
-
return (jsx(AccordionControl$1, { classNames: { label: styles$
|
|
148
|
+
return (jsx(AccordionControl$1, { classNames: { label: styles$r.label, control: styles$r.control }, children: children }));
|
|
149
149
|
};
|
|
150
150
|
AccordionControl.displayName = 'AccordionControl';
|
|
151
151
|
var AccordionPanel = function (_a) {
|
|
152
152
|
var children = _a.children;
|
|
153
|
-
return (jsx(AccordionPanel$1, { classNames: { content: styles$
|
|
153
|
+
return (jsx(AccordionPanel$1, { classNames: { content: styles$r.content }, children: children }));
|
|
154
154
|
};
|
|
155
155
|
AccordionPanel.displayName = 'AccordionPanel';
|
|
156
156
|
|
|
157
|
-
var styles$
|
|
157
|
+
var styles$q = {"root":"ActionIcon-module_root__orJKP"};
|
|
158
158
|
|
|
159
159
|
/**
|
|
160
160
|
* ActionIcon component to display an icon with a clickable action.
|
|
@@ -173,7 +173,7 @@ var styles$o = {"root":"ActionIcon-module_root__orJKP"};
|
|
|
173
173
|
var ActionIcon = forwardRef(function (_a, ref) {
|
|
174
174
|
var onClick = _a.onClick, _b = _a.radius, radius = _b === undefined ? 'xl' : _b, _c = _a.color, color = _c === undefined ? 'var(--color-neutral-200)' : _c, _d = _a.variant, variant = _d === undefined ? 'filled' : _d, _e = _a.size, size = _e === undefined ? 'md' : _e, _f = _a.disabled, disabled = _f === undefined ? false : _f, children = _a.children, rest = __rest(_a, ["onClick", "radius", "color", "variant", "size", "disabled", "children"]);
|
|
175
175
|
return (jsx(ActionIcon$1, __assign({ onClick: onClick && onClick, radius: radius, variant: variant, size: size, disabled: disabled, classNames: {
|
|
176
|
-
root: styles$
|
|
176
|
+
root: styles$q.root,
|
|
177
177
|
}, color: color, ref: ref }, rest, { children: jsx(Group, { children: children }) })));
|
|
178
178
|
});
|
|
179
179
|
ActionIcon.displayName = 'ActionIcon';
|
|
@@ -183,7 +183,7 @@ var Animation = function (_a) {
|
|
|
183
183
|
var refVector = useRef(null);
|
|
184
184
|
var _b = useState(null), lottie = _b[0], setLottie = _b[1];
|
|
185
185
|
useEffect(function () {
|
|
186
|
-
import('./lottie-
|
|
186
|
+
import('./lottie-DfsERZoD.js').then(function (n) { return n.l; }).then(function (Lottie) { return setLottie(Lottie.default); });
|
|
187
187
|
}, []);
|
|
188
188
|
useEffect(function () {
|
|
189
189
|
if (lottie && refVector.current) {
|
|
@@ -201,7 +201,7 @@ var Animation = function (_a) {
|
|
|
201
201
|
};
|
|
202
202
|
Animation.displayName = 'Animation';
|
|
203
203
|
|
|
204
|
-
var styles$
|
|
204
|
+
var styles$p = {"dropdown":"Dropdown-module_dropdown__Pf3Aj","option":"Dropdown-module_option__5-7L7"};
|
|
205
205
|
|
|
206
206
|
/**
|
|
207
207
|
*
|
|
@@ -241,7 +241,7 @@ var Dropdown = function (_a) {
|
|
|
241
241
|
store.selectOption(index);
|
|
242
242
|
onOptionSubmit === null || onOptionSubmit === undefined ? undefined : onOptionSubmit(option);
|
|
243
243
|
closeOnSelect && store.closeDropdown();
|
|
244
|
-
}, className: styles$
|
|
244
|
+
}, className: styles$p.option, children: option }, index));
|
|
245
245
|
}
|
|
246
246
|
return option;
|
|
247
247
|
});
|
|
@@ -249,7 +249,7 @@ var Dropdown = function (_a) {
|
|
|
249
249
|
return (jsxs(Combobox, __assign({ store: store, onOptionSubmit: function (value) {
|
|
250
250
|
onOptionSubmit === null || onOptionSubmit === undefined ? undefined : onOptionSubmit(value);
|
|
251
251
|
closeOnSelect && store.closeDropdown();
|
|
252
|
-
} }, rest, { children: [jsx(Combobox.Target, { children: jsx(Flex, { w: "100%", children: typeof children === 'function' ? children(store) : children }) }), jsxs(Combobox.Dropdown, { classNames: { dropdown: styles$
|
|
252
|
+
} }, rest, { children: [jsx(Combobox.Target, { children: jsx(Flex, { w: "100%", children: typeof children === 'function' ? children(store) : children }) }), jsxs(Combobox.Dropdown, { classNames: { dropdown: styles$p.dropdown }, children: [jsx(Combobox.Options, { mah: maxHeight, style: { overflow: maxHeight ? 'auto' : 'unset' }, children: renderOptions(options, onOptionSubmit) }), footer && (jsx(Combobox.Footer, { children: typeof footer === 'function' ? footer(store) : footer }))] })] })));
|
|
253
253
|
};
|
|
254
254
|
Dropdown.displayName = 'Dropdown';
|
|
255
255
|
Dropdown.Option = Combobox.Option;
|
|
@@ -358,7 +358,11 @@ function requireClassnames () {
|
|
|
358
358
|
var classnamesExports = requireClassnames();
|
|
359
359
|
var classNames = /*@__PURE__*/getDefaultExportFromCjs(classnamesExports);
|
|
360
360
|
|
|
361
|
-
var styles$
|
|
361
|
+
var styles$o = {"container":"Input-module_container__zzWGm","input":"Input-module_input__aRXjR","inputError":"Input-module_inputError__s3cRz","inputLeftIcon":"Input-module_inputLeftIcon__gObSe","inputRightIcon":"Input-module_inputRightIcon__hWB1a","label":"Input-module_label__HtZ2L","labelFocused":"Input-module_labelFocused__3-p5R","labelError":"Input-module_labelError__MA8Ti","labelDisabled":"Input-module_labelDisabled__lhjNw","description":"Input-module_description__Q1Rbw","error":"Input-module_error__yiAgw","errorVisible":"Input-module_errorVisible__IS7J2","errorHidden":"Input-module_errorHidden__8-hAw","errorText":"Input-module_errorText__wKZ67","leftSection":"Input-module_leftSection__YyGeo","rightSection":"Input-module_rightSection__zMH-z"};
|
|
362
|
+
|
|
363
|
+
var inputWrapperSlotElement = { component: 'div' };
|
|
364
|
+
var inputDescriptionProps = __assign({ className: styles$o.description }, inputWrapperSlotElement);
|
|
365
|
+
var inputErrorProps = __assign({ className: styles$o.error }, inputWrapperSlotElement);
|
|
362
366
|
|
|
363
367
|
var Info = function (_a) {
|
|
364
368
|
var width = _a.width, height = _a.height, viewBox = _a.viewBox, _b = _a.stroke, stroke = _b === undefined ? 'currentColor' : _b, _c = _a.strokeWidth, strokeWidth = _c === undefined ? 1.5 : _c;
|
|
@@ -366,7 +370,7 @@ var Info = function (_a) {
|
|
|
366
370
|
};
|
|
367
371
|
Info.displayName = 'Info';
|
|
368
372
|
|
|
369
|
-
var styles$
|
|
373
|
+
var styles$n = {"text":"Text-module_text__3xRq3","h1":"Text-module_h1__RkLfx","h2":"Text-module_h2__fAm7L","h3":"Text-module_h3__o11c2","h4":"Text-module_h4__RIwZg","m":"Text-module_m__nlfmp","s":"Text-module_s__t9q3d","xs":"Text-module_xs__ZU2jV","xxs":"Text-module_xxs__hmZHQ","bold":"Text-module_bold__N75tZ","medium":"Text-module_medium__Q8kf4","regular":"Text-module_regular__-EdPk"};
|
|
370
374
|
|
|
371
375
|
var elementType = {
|
|
372
376
|
h1: 'h1',
|
|
@@ -377,7 +381,7 @@ var elementType = {
|
|
|
377
381
|
var Text = React.forwardRef(function (props, ref) {
|
|
378
382
|
var as = props.as, children = props.children, className = props.className, color = props.color, style = props.style, variant = props.variant, weight = props.weight, rest = __rest(props, ["as", "children", "className", "color", "style", "variant", "weight"]);
|
|
379
383
|
var combinedStyle = __assign(__assign({}, style), { color: color });
|
|
380
|
-
var combinedClassName = classNames(className, styles$
|
|
384
|
+
var combinedClassName = classNames(className, styles$n['text'], styles$n[variant || ''], styles$n[weight || '']);
|
|
381
385
|
return React.createElement(as || elementType[variant] || 'p', __assign({ ref: ref, className: combinedClassName, style: combinedStyle }, rest), children);
|
|
382
386
|
});
|
|
383
387
|
Text.displayName = 'Text';
|
|
@@ -447,19 +451,19 @@ var Input = function (_a) {
|
|
|
447
451
|
var showLabel = !hideLabel && (isFocused || value.trim());
|
|
448
452
|
var placeHolderValue = placeholder && isFocused ? placeholder : (label !== null && label !== undefined ? label : placeholder);
|
|
449
453
|
var ErrorSection = useMemo(function () {
|
|
450
|
-
return holdSpace && (jsxs(Flex, { className: classNames(styles$
|
|
454
|
+
return holdSpace && (jsxs(Flex, { className: classNames(styles$o.error, error ? styles$o.errorVisible : styles$o.errorHidden), gap: 4, ml: 0, style: { alignItems: 'flex-start' }, children: [jsx(Flex, { style: { flexShrink: 0 }, children: jsx(Info, { width: "18px", height: "18px", viewBox: "0 0 24 24", stroke: "var(--color-red-300)" }) }), jsx(Text, { variant: "xs", className: classNames(styles$o.errorText), as: "span", children: capitalizeFirstSentenceLetter(error) })] }));
|
|
451
455
|
}, [error]);
|
|
452
|
-
return (jsxs("div", { className: styles$
|
|
453
|
-
_b[styles$
|
|
454
|
-
_b[styles$
|
|
455
|
-
_b[styles$
|
|
456
|
+
return (jsxs("div", { className: styles$o.container, children: [showLabel && (jsx("label", { className: classNames(styles$o.label, (_b = {},
|
|
457
|
+
_b[styles$o.labelError] = error && !isFocused,
|
|
458
|
+
_b[styles$o.labelFocused] = isFocused || isHovered,
|
|
459
|
+
_b[styles$o.labelDisabled] = disabled,
|
|
456
460
|
_b)), children: label })), jsx("div", { onMouseEnter: function () { return setIsHovered(true); }, onMouseLeave: function () { return setIsHovered(false); }, onFocus: function () { return setIsFocused(true); }, onBlur: function () { return setIsFocused(false); }, children: jsx(TextInput, __assign({ classNames: {
|
|
457
|
-
input: classNames(styles$
|
|
458
|
-
_c[styles$
|
|
459
|
-
_c[styles$
|
|
460
|
-
_c[styles$
|
|
461
|
+
input: classNames(styles$o.input, (_c = {},
|
|
462
|
+
_c[styles$o.inputLeftIcon] = leftSection,
|
|
463
|
+
_c[styles$o.inputRightIcon] = rightSection,
|
|
464
|
+
_c[styles$o.inputError] = error,
|
|
461
465
|
_c)),
|
|
462
|
-
}, placeholder: placeHolderValue, name: name, error: ErrorSection, description: !error && jsx(Text, { variant: "xs", children: description }), descriptionProps:
|
|
466
|
+
}, placeholder: placeHolderValue, name: name, error: ErrorSection, description: !error && jsx(Text, { variant: "xs", children: description }), descriptionProps: inputDescriptionProps, errorProps: inputErrorProps, inputWrapperOrder: ['label', 'input', 'description', 'error'], value: value, onChange: onChange, leftSection: leftSection, rightSection: rightSection, leftSectionProps: { className: styles$o.leftSection }, rightSectionProps: { className: styles$o.rightSection }, type: type, disabled: disabled }, rest)) })] }));
|
|
463
467
|
};
|
|
464
468
|
Input.displayName = 'Input';
|
|
465
469
|
|
|
@@ -544,12 +548,40 @@ var Autocomplete = function (_a) {
|
|
|
544
548
|
};
|
|
545
549
|
Autocomplete.displayName = 'Autocomplete';
|
|
546
550
|
|
|
551
|
+
var styles$m = {"avatar":"Avatar-module_avatar__QJpdG","placeholder":"Avatar-module_placeholder__9AtPN"};
|
|
552
|
+
|
|
547
553
|
var AvatarPlaceholder = function (_a) {
|
|
548
|
-
var width = _a.width, height = _a.height,
|
|
549
|
-
return (jsxs(Icon, { width: width, height: height, viewBox: viewBox, rotate: rotate,
|
|
554
|
+
var width = _a.width, height = _a.height, _b = _a.viewBox, viewBox = _b === undefined ? '0 0 24 24' : _b, rotate = _a.rotate, rest = __rest(_a, ["width", "height", "viewBox", "rotate"]);
|
|
555
|
+
return (jsxs(Icon, __assign({ stroke: "none", width: width, height: height, viewBox: viewBox, rotate: rotate }, rest, { children: [jsx("ellipse", { cx: "11.755", cy: "5.818", fill: "var(--color-tertiary-200)", rx: "5.878", ry: "5.818" }), jsx("path", { fill: "var(--color-primary-300)", d: "M24 24H12 0c0-6.56 5.373-11.879 12-11.879s12 5.319 12 11.88z" })] })));
|
|
550
556
|
};
|
|
551
557
|
AvatarPlaceholder.displayName = 'AvatarPlaceholder';
|
|
552
558
|
|
|
559
|
+
var sizeMapping = {
|
|
560
|
+
small: '32px',
|
|
561
|
+
medium: '48px',
|
|
562
|
+
large: '112px',
|
|
563
|
+
extraLarge: '150px',
|
|
564
|
+
};
|
|
565
|
+
var placeholderSizeMapping = {
|
|
566
|
+
small: '14px',
|
|
567
|
+
medium: '22px',
|
|
568
|
+
large: '46px',
|
|
569
|
+
extraLarge: '60px',
|
|
570
|
+
};
|
|
571
|
+
var Avatar = function (_a) {
|
|
572
|
+
var src = _a.src, alt = _a.alt, _b = _a.size, size = _b === undefined ? 'medium' : _b, testId = _a.testId, rest = __rest(_a, ["src", "alt", "size", "testId"]);
|
|
573
|
+
return (jsx(Avatar$1, __assign({ src: src, alt: alt, "data-testid": testId, radius: "xl", variant: "outline", styles: {
|
|
574
|
+
root: {
|
|
575
|
+
minWidth: sizeMapping[size],
|
|
576
|
+
minHeight: sizeMapping[size],
|
|
577
|
+
},
|
|
578
|
+
}, classNames: {
|
|
579
|
+
root: styles$m.avatar,
|
|
580
|
+
placeholder: styles$m.placeholder,
|
|
581
|
+
} }, rest, { children: jsx(AvatarPlaceholder, { role: "img", "aria-label": alt, "data-testid": testId ? "".concat(testId, "-placeholder") : undefined, width: placeholderSizeMapping[size], height: placeholderSizeMapping[size] }) })));
|
|
582
|
+
};
|
|
583
|
+
Avatar.displayName = 'Avatar';
|
|
584
|
+
|
|
553
585
|
var badgeVariantMap = {
|
|
554
586
|
notes: {
|
|
555
587
|
backgroundColor: 'var(--color-neutral-100)',
|
|
@@ -616,19 +648,19 @@ var Badge = forwardRef(function (_a, ref) {
|
|
|
616
648
|
});
|
|
617
649
|
Badge.displayName = 'Badge';
|
|
618
650
|
|
|
619
|
-
var styles$
|
|
651
|
+
var styles$l = {"button":"Button-module_button__7BLGt","label":"Button-module_label__447Ll","button-flex":"Button-module_button-flex__bzVRB","button--filled":"Button-module_button--filled__BKGu2","label-color--filled":"Button-module_label-color--filled__wJHlw","label-color--filled--disabled":"Button-module_label-color--filled--disabled__BbMbV","button--outlined":"Button-module_button--outlined__QZysw","label-color--outlined":"Button-module_label-color--outlined__seGi5","label-color--outlined--disabled":"Button-module_label-color--outlined--disabled__qXPjI","button--underlined":"Button-module_button--underlined__BsY5s","label-color--underlined":"Button-module_label-color--underlined__ymMfq","label-color--underlined--disabled":"Button-module_label-color--underlined--disabled__TBDd8","button--underlined-neutral":"Button-module_button--underlined-neutral__30A91","label-color--underlined-neutral":"Button-module_label-color--underlined-neutral__1xWMY","label-color--underlined-neutral--disabled":"Button-module_label-color--underlined-neutral--disabled__RQKW7","button--delete":"Button-module_button--delete__Xqpbl","label-color--delete":"Button-module_label-color--delete__iPB3X","label-color--delete--disabled":"Button-module_label-color--delete--disabled__lJkM6","button--small":"Button-module_button--small__3npYU","button--medium":"Button-module_button--medium__WRSIQ","button--large":"Button-module_button--large__bGVS1"};
|
|
620
652
|
|
|
621
653
|
var Button = forwardRef(function (_a, ref) {
|
|
622
654
|
var _b;
|
|
623
655
|
var _c = _a.variant, variant = _c === undefined ? 'filled' : _c, submit = _a.submit, _d = _a.size, size = _d === undefined ? 'medium' : _d, fullWidth = _a.fullWidth, backgroundColor = _a.backgroundColor, label = _a.label, icon = _a.icon, children = _a.children, props = __rest(_a, ["variant", "submit", "size", "fullWidth", "backgroundColor", "label", "icon", "children"]);
|
|
624
|
-
var mode = styles$
|
|
625
|
-
return (jsx("button", __assign({ ref: ref, type: submit ? 'submit' : 'button', style: __assign(__assign({}, props.style), { backgroundColor: backgroundColor, width: fullWidth ? '100%' : 'auto' }) }, props, { className: [styles$
|
|
626
|
-
_b[styles$
|
|
656
|
+
var mode = styles$l["button--".concat(variant)];
|
|
657
|
+
return (jsx("button", __assign({ ref: ref, type: submit ? 'submit' : 'button', style: __assign(__assign({}, props.style), { backgroundColor: backgroundColor, width: fullWidth ? '100%' : 'auto' }) }, props, { className: [styles$l.button, styles$l["button--".concat(size)], mode].join(' '), children: jsxs("div", { className: styles$l['button-flex'], children: [!!icon && icon, label ? (jsx(Text, { className: classNames(styles$l.label, styles$l["label-color--".concat(variant)], (_b = {},
|
|
658
|
+
_b[styles$l["label-color--".concat(variant, "--disabled")]] = props.disabled,
|
|
627
659
|
_b)), children: label })) : (children)] }) })));
|
|
628
660
|
});
|
|
629
661
|
Button.displayName = 'Button';
|
|
630
662
|
|
|
631
|
-
var styles$
|
|
663
|
+
var styles$k = {"card":"Card-module_card__-PlHa","footerDivider":"Card-module_footerDivider__nt5J7","mdShadow":"Card-module_mdShadow__yft6m","lgShadow":"Card-module_lgShadow__WzWj7","variantDefault":"Card-module_variantDefault__AIy3D","variantPlain":"Card-module_variantPlain__MOaH5","variantNeutral":"Card-module_variantNeutral__OAsYA","variantSuccess":"Card-module_variantSuccess__GWiOd","variantWarning":"Card-module_variantWarning__jappm","variantNotice":"Card-module_variantNotice__C7UUh","variantInfo":"Card-module_variantInfo__B26E9","variantPrimary":"Card-module_variantPrimary__9E-0B","variantCaution":"Card-module_variantCaution__-p-t8","paddingMd":"Card-module_paddingMd__i1uBq","paddingXs":"Card-module_paddingXs__9BSaQ","paddingCustom":"Card-module_paddingCustom__km95M","appearanceFilled":"Card-module_appearanceFilled__r6-rn","appearanceOutline":"Card-module_appearanceOutline__tseCa","borderWidthDefault":"Card-module_borderWidthDefault__QblrJ","borderWidthMd":"Card-module_borderWidthMd__lCL3w"};
|
|
632
664
|
|
|
633
665
|
var capitalize = function (value) {
|
|
634
666
|
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
@@ -636,15 +668,15 @@ var capitalize = function (value) {
|
|
|
636
668
|
var Card = function (_a) {
|
|
637
669
|
var _b;
|
|
638
670
|
var header = _a.header, children = _a.children, footer = _a.footer, style = _a.style, _c = _a.shadow, shadow = _c === undefined ? 'md' : _c, _d = _a.variant, variant = _d === undefined ? 'default' : _d, _e = _a.appearance, appearance = _e === undefined ? 'filled' : _e, _f = _a.padding, padding = _f === undefined ? 'md' : _f, _g = _a.borderWidth, borderWidth = _g === undefined ? 'default' : _g;
|
|
639
|
-
var cardClassName = classNames(styles$
|
|
640
|
-
_b[styles$
|
|
641
|
-
_b[styles$
|
|
642
|
-
_b), styles$
|
|
643
|
-
return (jsxs("div", { className: cardClassName, style: style, children: [header, children, footer && jsx("div", { className: styles$
|
|
671
|
+
var cardClassName = classNames(styles$k.card, (_b = {},
|
|
672
|
+
_b[styles$k.mdShadow] = shadow === 'md',
|
|
673
|
+
_b[styles$k.lgShadow] = shadow === 'lg',
|
|
674
|
+
_b), styles$k["variant".concat(capitalize(variant))], styles$k["appearance".concat(capitalize(appearance))], styles$k["padding".concat(capitalize(padding))], styles$k["borderWidth".concat(capitalize(borderWidth))]);
|
|
675
|
+
return (jsxs("div", { className: cardClassName, style: style, children: [header, children, footer && jsx("div", { className: styles$k.footerDivider }), footer] }));
|
|
644
676
|
};
|
|
645
677
|
Card.displayName = 'Card';
|
|
646
678
|
|
|
647
|
-
var styles$
|
|
679
|
+
var styles$j = {"cardStatus":"CardStatus-module_cardStatus__5T4aF","cardStatus--leftIcon":"CardStatus-module_cardStatus--leftIcon__ULp9A"};
|
|
648
680
|
|
|
649
681
|
var cardStatusVariantMap = {
|
|
650
682
|
notes: {
|
|
@@ -681,11 +713,11 @@ var CardStatus = function (_a) {
|
|
|
681
713
|
? (_b = cardStatusVariantMap[variant]) === null || _b === undefined ? undefined : _b.backgroundColor
|
|
682
714
|
: undefined;
|
|
683
715
|
var sizeStyles = sizeMap[size || 'small'];
|
|
684
|
-
return (jsxs("div", { className: "".concat(styles$
|
|
716
|
+
return (jsxs("div", { className: "".concat(styles$j.cardStatus, " ").concat(leftIcon ? styles$j['cardStatus--leftIcon'] : ''), style: backgroundColor ? { backgroundColor: backgroundColor } : undefined, children: [leftIcon && icon, jsx(Text, { variant: sizeStyles.textVariant, color: 'var(--color-neutral-600)', children: label }), !leftIcon && icon] }));
|
|
685
717
|
};
|
|
686
718
|
CardStatus.displayName = 'CardStatus';
|
|
687
719
|
|
|
688
|
-
var styles$
|
|
720
|
+
var styles$i = {"inner":"Checkbox-module_inner__R7olC","input":"Checkbox-module_input__XnCmS","label":"Checkbox-module_label__l8z5T","label-disabled":"Checkbox-module_label-disabled__fXIgW","icon-disabled":"Checkbox-module_icon-disabled__Nw0dG"};
|
|
689
721
|
|
|
690
722
|
/**
|
|
691
723
|
* Checkbox component for selecting multiple options from a set.
|
|
@@ -703,20 +735,20 @@ var Checkbox = function (_a) {
|
|
|
703
735
|
var _b, _c;
|
|
704
736
|
var _d = _a.checked, checked = _d === undefined ? false : _d, _e = _a.disabled, disabled = _e === undefined ? false : _e, label = _a.label, onChange = _a.onChange, id = _a.id, rest = __rest(_a, ["checked", "disabled", "label", "onChange", "id"]);
|
|
705
737
|
return (jsx(Checkbox$1, __assign({ checked: checked, label: label, disabled: disabled, onChange: onChange, id: id, color: "var(--color-primary-300)", classNames: {
|
|
706
|
-
labelWrapper: styles$
|
|
707
|
-
label: classNames(styles$
|
|
708
|
-
_b[styles$
|
|
738
|
+
labelWrapper: styles$i.labelWrapper,
|
|
739
|
+
label: classNames(styles$i.label, (_b = {},
|
|
740
|
+
_b[styles$i['label-disabled']] = disabled,
|
|
709
741
|
_b)),
|
|
710
|
-
input: styles$
|
|
711
|
-
inner: styles$
|
|
742
|
+
input: styles$i.input,
|
|
743
|
+
inner: styles$i.inner,
|
|
712
744
|
icon: classNames((_c = {},
|
|
713
|
-
_c[styles$
|
|
745
|
+
_c[styles$i['icon-disabled']] = disabled,
|
|
714
746
|
_c)),
|
|
715
747
|
} }, rest)));
|
|
716
748
|
};
|
|
717
749
|
Checkbox.displayName = 'Checkbox';
|
|
718
750
|
|
|
719
|
-
var styles$
|
|
751
|
+
var styles$h = {"chip-wrapper":"Chip-module_chip-wrapper__XcAWQ","chip-wrapper-text":"Chip-module_chip-wrapper-text__MGQ2X","chip-wrapper-menu-text":"Chip-module_chip-wrapper-menu-text__6-ZGF","chip-number":"Chip-module_chip-number__Y2-Tg","chip-number-wide":"Chip-module_chip-number-wide__qIVlX","chip-menu-dropdown":"Chip-module_chip-menu-dropdown__36ced","chip-menu-item":"Chip-module_chip-menu-item__-u2K-","chip-wrapper-filter":"Chip-module_chip-wrapper-filter__0GhdM"};
|
|
720
752
|
|
|
721
753
|
var ChevronCollapse = function (_a) {
|
|
722
754
|
var _b = _a.width, width = _b === undefined ? '32px' : _b, _c = _a.height, height = _c === undefined ? '32px' : _c, _d = _a.viewBox, viewBox = _d === undefined ? '0 0 32 32' : _d, _e = _a.stroke, stroke = _e === undefined ? 'currentColor' : _e, _f = _a.fill, fill = _f === undefined ? 'none' : _f;
|
|
@@ -740,10 +772,10 @@ var Chip = function (_a) {
|
|
|
740
772
|
return null;
|
|
741
773
|
// Just one filter
|
|
742
774
|
if (itemGroup.length === 1) {
|
|
743
|
-
return (jsxs(Flex, { className: styles$
|
|
775
|
+
return (jsxs(Flex, { className: styles$h['chip-wrapper'], children: [jsx(Text, { variant: "xs", weight: "regular", className: styles$h['chip-wrapper-text'], children: itemGroup[0] }), jsx(ActionIcon, { variant: "light", size: "xs", onClick: function () { return handleDelete(itemGroup[0]); }, children: jsx(Close, { width: "18px", height: "18px" }) })] }));
|
|
744
776
|
}
|
|
745
777
|
// More than one filter
|
|
746
|
-
return (jsxs(Menu$1, { opened: opened, onChange: setOpened, withinPortal: true, position: "bottom-start", closeOnItemClick: false, children: [jsx(Menu$1.Target, { children: jsxs(Flex, { className: styles$
|
|
778
|
+
return (jsxs(Menu$1, { opened: opened, onChange: setOpened, withinPortal: true, position: "bottom-start", closeOnItemClick: false, children: [jsx(Menu$1.Target, { children: jsxs(Flex, { className: styles$h['chip-wrapper'], children: [jsxs(Flex, { className: styles$h['chip-wrapper-menu-text'], children: [jsx(Text, { variant: "xs", weight: "regular", children: item }), jsx(Flex, { className: "".concat(styles$h['chip-number'], " ").concat(itemGroup.length > 9 ? styles$h['chip-number-wide'] : ''), children: jsx(Text, { variant: "xxs", weight: "bold", color: "var(--color-white)", style: { lineHeight: 1 }, children: itemGroup.length }) })] }), jsx(ActionIcon, { variant: "light", size: "xs", onClick: function () { return setOpened(function (o) { return !o; }); }, children: jsx(ChevronCollapse, { width: "24px", height: "24px" }) })] }) }), jsx(Menu$1.Dropdown, { className: styles$h['chip-menu-dropdown'], children: itemGroup.map(function (f) { return (jsx(Menu$1.Item, { className: styles$h['chip-menu-item'], children: jsx(Checkbox, { label: jsxs(Flex, { className: styles$h['chip-wrapper-filter'], children: [jsx(Text, { variant: "xs", weight: "regular", children: f }), jsxs(Text, { variant: "xs", weight: "regular", children: ["(", f.length, ")"] })] }), checked: itemGroup.includes(f), onChange: function () { return handleDelete(f); } }) }, f)); }) })] }));
|
|
747
779
|
};
|
|
748
780
|
Chip.displayName = 'Chip';
|
|
749
781
|
|
|
@@ -834,10 +866,10 @@ var DateInput = function (_a) {
|
|
|
834
866
|
var showLabel = !hideLabel && (isFocused || value);
|
|
835
867
|
var placeHolderValue = placeholder && isFocused ? placeholder : (label !== null && label !== undefined ? label : placeholder);
|
|
836
868
|
var ErrorSection = useMemo(function () {
|
|
837
|
-
return holdSpace && (jsxs(Flex, { className: styles$
|
|
869
|
+
return holdSpace && (jsxs(Flex, { className: styles$o.error, gap: 4, ml: 16, style: {
|
|
838
870
|
visibility: error ? 'visible' : 'hidden',
|
|
839
871
|
alignItems: 'flex-start',
|
|
840
|
-
}, children: [jsx(Flex, { style: { flexShrink: 0 }, children: jsx(Info, { width: "18px", height: "18px", viewBox: "0 0 24 24", stroke: "var(--color-red-300)" }) }), jsx(Text, { variant: "xs", className: classNames(styles$
|
|
872
|
+
}, children: [jsx(Flex, { style: { flexShrink: 0 }, children: jsx(Info, { width: "18px", height: "18px", viewBox: "0 0 24 24", stroke: "var(--color-red-300)" }) }), jsx(Text, { variant: "xs", className: classNames(styles$o.errorText), children: capitalizeFirstSentenceLetter(error || '') })] }));
|
|
841
873
|
}, [error, holdSpace]);
|
|
842
874
|
var handleBlur = function (e) {
|
|
843
875
|
setIsFocused(false);
|
|
@@ -845,36 +877,36 @@ var DateInput = function (_a) {
|
|
|
845
877
|
onBlur(e);
|
|
846
878
|
}
|
|
847
879
|
};
|
|
848
|
-
return (jsxs("div", { className: styles$
|
|
849
|
-
_b[styles$
|
|
850
|
-
_b[styles$
|
|
851
|
-
_b[styles$
|
|
880
|
+
return (jsxs("div", { className: styles$o.container, children: [showLabel && (jsx("label", { className: classNames(styles$o.label, (_b = {},
|
|
881
|
+
_b[styles$o.labelError] = error && !isFocused,
|
|
882
|
+
_b[styles$o.labelFocused] = isFocused || isHovered,
|
|
883
|
+
_b[styles$o.labelDisabled] = disabled,
|
|
852
884
|
_b)), children: label })), jsx("div", { onMouseEnter: function () { return setIsHovered(true); }, onMouseLeave: function () { return setIsHovered(false); }, onFocus: function () { return setIsFocused(true); }, onBlur: function () { return setIsFocused(false); }, children: jsx(DateInput$1, __assign({ name: name, classNames: {
|
|
853
|
-
input: classNames(styles$
|
|
854
|
-
_c[styles$
|
|
855
|
-
_c[styles$
|
|
885
|
+
input: classNames(styles$o.input, (_c = {},
|
|
886
|
+
_c[styles$o.inputError] = error,
|
|
887
|
+
_c[styles$o.inputRightIcon] = true,
|
|
856
888
|
_c)),
|
|
857
|
-
}, valueFormat: "MM/DD/YYYY", dateParser: dateParser, rightSection: jsx(Calendar, { stroke: "var(--color-neutral-600)", width: "18px", height: "18px", viewBox: "0 0 24 24" }), rightSectionProps: { className: styles$
|
|
889
|
+
}, valueFormat: "MM/DD/YYYY", dateParser: dateParser, rightSection: jsx(Calendar, { stroke: "var(--color-neutral-600)", width: "18px", height: "18px", viewBox: "0 0 24 24" }), rightSectionProps: { className: styles$o.rightSection }, placeholder: placeHolderValue, value: value, onChange: onChange, onBlur: handleBlur, error: ErrorSection, errorProps: inputErrorProps, inputWrapperOrder: ['label', 'input', 'error'], disabled: disabled }, rest)) })] }));
|
|
858
890
|
};
|
|
859
891
|
DateInput.displayName = 'DateInput';
|
|
860
892
|
|
|
861
|
-
var styles$
|
|
893
|
+
var styles$g = {"code-input":"EnterCodeInput-module_code-input__bCj-T","code-input--2":"EnterCodeInput-module_code-input--2__yoYWJ","code-input--3":"EnterCodeInput-module_code-input--3__0xXFa","code-input--4":"EnterCodeInput-module_code-input--4__stWlP","code-input-error":"EnterCodeInput-module_code-input-error__l8yKQ"};
|
|
862
894
|
|
|
863
895
|
var EnterCodeInput = React.forwardRef(function (props, ref) {
|
|
864
896
|
var className = [
|
|
865
|
-
styles$
|
|
866
|
-
styles$
|
|
897
|
+
styles$g['code-input'],
|
|
898
|
+
styles$g["code-input--".concat(props.inline)],
|
|
867
899
|
].join(' ');
|
|
868
900
|
if (props.error) {
|
|
869
|
-
className = [className, styles$
|
|
901
|
+
className = [className, styles$g['code-input-error']].join(' ');
|
|
870
902
|
}
|
|
871
903
|
return (jsx("input", __assign({}, (typeof props.field === 'object' ? props.field : {}), props, { ref: ref, name: props.name, autoFocus: true, className: className, type: props.type, maxLength: 6, placeholder: props.placeholder, onChange: props.onChange, onBlur: props.onBlur, onKeyUp: props.onKeyUp, value: props.value })));
|
|
872
904
|
});
|
|
873
905
|
EnterCodeInput.displayName = 'EnterCodeInput';
|
|
874
906
|
|
|
875
|
-
var styles$
|
|
907
|
+
var styles$f = {"container":"FileInput-module_container__PUDhK","dropzone":"FileInput-module_dropzone__y5BNo","dragging":"FileInput-module_dragging__DoJPz","disabled":"FileInput-module_disabled__2Vlih","input":"FileInput-module_input__xiCkj","icon":"FileInput-module_icon__lXNr-","content":"FileInput-module_content__V9dYE","label":"FileInput-module_label__3DYWx","helper":"FileInput-module_helper__vVlYi","fileFormatText":"FileInput-module_fileFormatText__3E24H","fileList":"FileInput-module_fileList__xwhfk"};
|
|
876
908
|
|
|
877
|
-
var styles$
|
|
909
|
+
var styles$e = {"fileItem":"FileUpload-module_fileItem__TQAj3","fileInfo":"FileUpload-module_fileInfo__0Rsbg","successIcon":"FileUpload-module_successIcon__P4ekl","errorIcon":"FileUpload-module_errorIcon__3IUcP","fileName":"FileUpload-module_fileName__iE6N7","fileSize":"FileUpload-module_fileSize__BuAI5","fileMessage":"FileUpload-module_fileMessage__ymYSV","progressBar":"FileUpload-module_progressBar__MYqP0","progress":"FileUpload-module_progress__eXpUX"};
|
|
878
910
|
|
|
879
911
|
var Clock = function (_a) {
|
|
880
912
|
var _b = _a.width, width = _b === undefined ? '32px' : _b, _c = _a.height, height = _c === undefined ? '32px' : _c, _d = _a.viewBox, viewBox = _d === undefined ? '0 0 32 32' : _d, _e = _a.stroke, stroke = _e === undefined ? 'currentColor' : _e;
|
|
@@ -930,25 +962,25 @@ var getMessage = function (status, message, progress) {
|
|
|
930
962
|
if (status === 'failed') {
|
|
931
963
|
if (message === null || message === undefined ? undefined : message.includes('-')) {
|
|
932
964
|
var _a = message.split('-'), errorReason = _a[0], errorMessage = _a[1];
|
|
933
|
-
return (jsxs(Text, { className: styles$
|
|
965
|
+
return (jsxs(Text, { className: styles$e.fileMessage, color: "var(--color-red-400)", children: [jsx("strong", { children: errorReason }), " - ", errorMessage] }));
|
|
934
966
|
}
|
|
935
|
-
return (jsx(Text, { className: styles$
|
|
967
|
+
return (jsx(Text, { className: styles$e.fileMessage, color: "var(--color-red-400)", children: message }));
|
|
936
968
|
}
|
|
937
969
|
if (status === 'duplicate') {
|
|
938
970
|
if (message === null || message === undefined ? undefined : message.includes('-')) {
|
|
939
971
|
var _b = message.split('-'), errorReason = _b[0], errorMessage = _b[1];
|
|
940
|
-
return (jsxs(Text, { className: styles$
|
|
972
|
+
return (jsxs(Text, { className: styles$e.fileMessage, color: "var(--color-orange-400)", children: [jsx("strong", { children: errorReason }), " - ", errorMessage] }));
|
|
941
973
|
}
|
|
942
|
-
return (jsx(Text, { className: styles$
|
|
974
|
+
return (jsx(Text, { className: styles$e.fileMessage, color: "var(--color-orange-400)", children: message }));
|
|
943
975
|
}
|
|
944
976
|
if (status === 'uploading') {
|
|
945
|
-
return (jsxs(Flex, { align: "center", gap: 24, children: [jsx(Flex, { className: styles$
|
|
977
|
+
return (jsxs(Flex, { align: "center", gap: 24, children: [jsx(Flex, { className: styles$e.progressBar, children: jsx(Flex, { className: styles$e.progress, w: "".concat(progress, "%") }) }), jsxs(Text, { color: "var(--color-neutral-500)", variant: "m", style: { margin: 0 }, children: [progress, "%"] })] }));
|
|
946
978
|
}
|
|
947
979
|
if (status === 'previously-uploaded') {
|
|
948
|
-
return (jsx(Text, { className: styles$
|
|
980
|
+
return (jsx(Text, { className: styles$e.fileMessage, color: "var(--color-green-400)", children: message }));
|
|
949
981
|
}
|
|
950
982
|
if (status === 'uploaded') {
|
|
951
|
-
return (jsx(Text, { className: styles$
|
|
983
|
+
return (jsx(Text, { className: styles$e.fileMessage, color: "var(--color-green-400)", children: message }));
|
|
952
984
|
}
|
|
953
985
|
return null;
|
|
954
986
|
};
|
|
@@ -964,7 +996,7 @@ var parseFileSize = function (size) {
|
|
|
964
996
|
|
|
965
997
|
var FileUpload = function (_a) {
|
|
966
998
|
var id = _a.id, name = _a.name, size = _a.size, status = _a.status, message = _a.message, progress = _a.progress, removeFile = _a.removeFile;
|
|
967
|
-
return (jsxs(Fragment, { children: [jsx(Divider, { color: "var(--color-neutral-300)" }), jsxs("div", { className: styles$
|
|
999
|
+
return (jsxs(Fragment, { children: [jsx(Divider, { color: "var(--color-neutral-300)" }), jsxs("div", { className: styles$e.fileItem, children: [jsxs("div", { className: styles$e.fileInfo, children: [getIcon$1(status), jsxs(Flex, { direction: "column", w: "100%", children: [jsx(Text, { className: styles$e.fileName, children: name }), jsx(Text, { className: styles$e.fileSize, color: "var(--color-neutral-500)", children: parseFileSize(size) }), getMessage(status, message, progress)] })] }), removeFile && (jsx(ActionIcon, { variant: "light", size: 'md', onClick: function () { return removeFile(id); }, "aria-label": "Remove ".concat(name), children: jsx(Close, {}) }))] }, "".concat(name, "-").concat(id))] }));
|
|
968
1000
|
};
|
|
969
1001
|
FileUpload.displayName = 'FileUpload';
|
|
970
1002
|
|
|
@@ -1022,34 +1054,34 @@ var FileInput = function (_a) {
|
|
|
1022
1054
|
.join(', ')
|
|
1023
1055
|
.slice('.'.length)
|
|
1024
1056
|
.toUpperCase(), ". Max file size: ").concat(maxSize, "MB");
|
|
1025
|
-
return (jsxs(Fragment, { children: [jsx("div", { className: styles$
|
|
1026
|
-
_b[styles$
|
|
1027
|
-
_b[styles$
|
|
1028
|
-
_b)), onDragOver: handleDragOver, onDragLeave: handleDragLeave, onDrop: handleDrop, children: [jsx("input", { type: "file", accept: acceptedFormats.join(','), onChange: handleFileInput, className: styles$
|
|
1057
|
+
return (jsxs(Fragment, { children: [jsx("div", { className: styles$f.container, children: jsxs("div", { className: classNames(styles$f.dropzone, (_b = {},
|
|
1058
|
+
_b[styles$f.dragging] = isDragging,
|
|
1059
|
+
_b[styles$f.disabled] = disabled,
|
|
1060
|
+
_b)), onDragOver: handleDragOver, onDragLeave: handleDragLeave, onDrop: handleDrop, children: [jsx("input", { type: "file", accept: acceptedFormats.join(','), onChange: handleFileInput, className: styles$f.input, "aria-label": label, disabled: disabled, multiple: true }), jsx("div", { className: styles$f.icon, children: jsx(Upload, { stroke: color, width: "2.6rem", height: "2.6rem", viewBox: "0 0 40 40" }) }), jsxs("div", { className: styles$f.content, children: [jsxs(Flex, { gap: 4, children: [jsx(Text, { variant: "m", weight: "medium", color: color, children: "Drag or" }), jsxs(Text, { variant: "m", weight: "medium", color: color, style: { textDecoration: 'underline' }, children: ["click to upload ", label] })] }), jsx(Text, { className: styles$f.fileFormatText, color: color, children: fileFormatText })] })] }) }), files.some(function (f) { return f.status === 'failed'; }) ? (jsx(Text, { variant: "xs", className: styles$f.helper, children: errorMessage })) : (jsx(Text, { variant: "xs", className: styles$f.helper, children: helperText })), files.length > 0 && (jsx(Flex, { className: styles$f.fileList, children: files.map(function (_a, index) {
|
|
1029
1061
|
var file = _a.file, rest = __rest(_a, ["file"]);
|
|
1030
1062
|
return (jsx(FileUpload, __assign({ file: file, removeFile: removeFile }, rest), "".concat(file.name, "-").concat(index)));
|
|
1031
1063
|
}) }))] }));
|
|
1032
1064
|
};
|
|
1033
1065
|
FileInput.displayName = 'FileInput';
|
|
1034
1066
|
|
|
1035
|
-
var styles$
|
|
1067
|
+
var styles$d = {"flex":"IncrementNumber-module_flex__Zo8-v","increment-button":"IncrementNumber-module_increment-button__qpw2X"};
|
|
1036
1068
|
|
|
1037
1069
|
var IncrementNumber = function (props) {
|
|
1038
1070
|
var formatter = new Intl.NumberFormat('en-US', {
|
|
1039
1071
|
style: 'currency',
|
|
1040
1072
|
currency: 'USD',
|
|
1041
1073
|
});
|
|
1042
|
-
return (jsxs("div", { className: styles$
|
|
1074
|
+
return (jsxs("div", { className: styles$d['flex'], children: [props.disableDecrease ? (jsx("div", { style: { width: 24 } })) : (jsx("button", { className: styles$d['increment-button'], onClick: function () { return props.handleDecrease(props.value); }, children: jsx("img", { src: props.minusIconPath, width: 24, height: 24, alt: "-", style: {
|
|
1043
1075
|
maxWidth: '100%',
|
|
1044
1076
|
height: 'auto',
|
|
1045
|
-
} }) })), jsx(Text, { variant: "m", weight: "regular", style: { minWidth: 120 }, children: formatter.format(props.value) }), props.disableIncrease ? (jsx("div", { style: { width: 24 } })) : (jsx("button", { className: styles$
|
|
1077
|
+
} }) })), jsx(Text, { variant: "m", weight: "regular", style: { minWidth: 120 }, children: formatter.format(props.value) }), props.disableIncrease ? (jsx("div", { style: { width: 24 } })) : (jsx("button", { className: styles$d['increment-button'], onClick: function () { return props.handleIncrease(props.value); }, children: jsx("img", { src: props.plusIconPath, width: 24, height: 24, alt: "+", style: {
|
|
1046
1078
|
maxWidth: '100%',
|
|
1047
1079
|
height: 'auto',
|
|
1048
1080
|
} }) }))] }));
|
|
1049
1081
|
};
|
|
1050
1082
|
IncrementNumber.displayName = 'IncrementNumber';
|
|
1051
1083
|
|
|
1052
|
-
var styles$
|
|
1084
|
+
var styles$c = {"link":"Link-module_link__8oxip","s":"Link-module_s__YsU8H","m":"Link-module_m__8-UFj","bold":"Link-module_bold__H3baG","medium":"Link-module_medium__nuncU","regular":"Link-module_regular__4VBH2","disabledUnderlined":"Link-module_disabledUnderlined__rLghi"};
|
|
1053
1085
|
|
|
1054
1086
|
/**
|
|
1055
1087
|
*
|
|
@@ -1079,15 +1111,15 @@ var styles$b = {"link":"Link-module_link__8oxip","s":"Link-module_s__YsU8H","m":
|
|
|
1079
1111
|
var Link = function (_a) {
|
|
1080
1112
|
var children = _a.children, variant = _a.variant, weight = _a.weight, href = _a.href, target = _a.target, _b = _a.disabledUnderlined, disabledUnderlined = _b === undefined ? false : _b, rel = _a.rel, rest = __rest(_a, ["children", "variant", "weight", "href", "target", "disabledUnderlined", "rel"]);
|
|
1081
1113
|
return (jsx("a", __assign({}, rest, { href: href || '#', target: target, rel: rel, className: [
|
|
1082
|
-
styles$
|
|
1083
|
-
styles$
|
|
1084
|
-
styles$
|
|
1085
|
-
disabledUnderlined ? styles$
|
|
1114
|
+
styles$c['link'],
|
|
1115
|
+
styles$c[variant || ''],
|
|
1116
|
+
styles$c[weight || ''],
|
|
1117
|
+
disabledUnderlined ? styles$c['disabledUnderlined'] : '',
|
|
1086
1118
|
].join(' '), children: children })));
|
|
1087
1119
|
};
|
|
1088
1120
|
Link.displayName = 'Link';
|
|
1089
1121
|
|
|
1090
|
-
var styles$
|
|
1122
|
+
var styles$b = {"modal":"Modal-module_modal__gMPgi","body":"Modal-module_body__OhLb0","header":"Modal-module_header__5sBzU"};
|
|
1091
1123
|
|
|
1092
1124
|
var Modal = function (_a) {
|
|
1093
1125
|
var isOpen = _a.isOpen, onClose = _a.onClose, noLabel = _a.noLabel, yesLabel = _a.yesLabel, invertColors = _a.invertColors, underButton = _a.underButton, no = _a.no, yes = _a.yes, _b = _a.size, size = _b === undefined ? 'sm' : _b, _c = _a.padding, padding = _c === undefined ? 'sm' : _c, _d = _a.customRadius, customRadius = _d === undefined ? 16 : _d, children = _a.children, _e = _a.disabled, disabled = _e === undefined ? false : _e;
|
|
@@ -1112,9 +1144,9 @@ var Modal = function (_a) {
|
|
|
1112
1144
|
title: 'Close modal',
|
|
1113
1145
|
icon: jsx(Close, { fill: "var(--color-neutral-200)" }),
|
|
1114
1146
|
}, classNames: {
|
|
1115
|
-
content: styles$
|
|
1116
|
-
body: styles$
|
|
1117
|
-
header: styles$
|
|
1147
|
+
content: styles$b.modal,
|
|
1148
|
+
body: styles$b.body,
|
|
1149
|
+
header: styles$b.header,
|
|
1118
1150
|
}, styles: {
|
|
1119
1151
|
body: {
|
|
1120
1152
|
padding: paddingMap[padding],
|
|
@@ -1140,7 +1172,7 @@ var Warning = function (_a) {
|
|
|
1140
1172
|
};
|
|
1141
1173
|
Warning.displayName = 'Warning';
|
|
1142
1174
|
|
|
1143
|
-
var styles$
|
|
1175
|
+
var styles$a = {"message":"Message-module_message__HyLo0","general":"Message-module_general__jNnP2","alert":"Message-module_alert__3mQLB","negative":"Message-module_negative__H-tsT","positive":"Message-module_positive__CU0EL","center":"Message-module_center__Y4KjG","top":"Message-module_top__J-o9d","bottom":"Message-module_bottom__2p2bW"};
|
|
1144
1176
|
|
|
1145
1177
|
/**
|
|
1146
1178
|
* Message component for displaying feedback to the user.
|
|
@@ -1170,18 +1202,18 @@ var getIcon = function (status) {
|
|
|
1170
1202
|
};
|
|
1171
1203
|
var Message = function (_a) {
|
|
1172
1204
|
var content = _a.content, _b = _a.variant, variant = _b === undefined ? 'form' : _b, _c = _a.status, status = _c === undefined ? 'general' : _c, _d = _a.iconAlignment, iconAlignment = _d === undefined ? 'center' : _d;
|
|
1173
|
-
return (jsxs(Flex, { className: classNames(styles$
|
|
1205
|
+
return (jsxs(Flex, { className: classNames(styles$a.message, styles$a[status], styles$a[variant]), children: [jsx(Flex, { className: styles$a[iconAlignment], children: getIcon(status) }), typeof content === 'string' ? (jsx(Text, { variant: "xs", children: content })) : (content)] }));
|
|
1174
1206
|
};
|
|
1175
1207
|
Message.displayName = 'Message';
|
|
1176
1208
|
|
|
1177
1209
|
var multiselectStyles = {"input":"Multiselect-module_input__lwmrJ","inputFocused":"Multiselect-module_inputFocused__rm-OP","disabled":"Multiselect-module_disabled__DyqLt","pill":"Multiselect-module_pill__NwXcT","pillText":"Multiselect-module_pillText__6hobG"};
|
|
1178
1210
|
|
|
1179
|
-
var styles$
|
|
1211
|
+
var styles$9 = {"tooltip":"Tooltip-module_tooltip__Q1YfF"};
|
|
1180
1212
|
|
|
1181
1213
|
var Tooltip = function (_a) {
|
|
1182
1214
|
var children = _a.children, props = __rest(_a, ["children"]);
|
|
1183
1215
|
return (jsx(Tooltip$1, __assign({}, props, { classNames: {
|
|
1184
|
-
tooltip: styles$
|
|
1216
|
+
tooltip: styles$9.tooltip,
|
|
1185
1217
|
}, offset: 4, children: children })));
|
|
1186
1218
|
};
|
|
1187
1219
|
Tooltip.displayName = 'Tooltip';
|
|
@@ -1338,17 +1370,17 @@ var MultiselectInternal = function (_a) {
|
|
|
1338
1370
|
}, onClick: function (e) { return e.stopPropagation(); } }))] }));
|
|
1339
1371
|
};
|
|
1340
1372
|
PillAndSearchSection.displayName = 'PillAndSearchSection';
|
|
1341
|
-
var ErrorSection = (jsxs(Flex, { className: styles$
|
|
1342
|
-
var DescriptionSection = (jsx(Flex, { className: styles$
|
|
1373
|
+
var ErrorSection = (jsxs(Flex, { className: styles$o.error, gap: 4, ml: 16, mt: 8, style: { visibility: error ? 'visible' : 'hidden' }, children: [jsx(Info, { width: "18px", height: "18px", viewBox: "0 0 24 24", stroke: "var(--color-red-300)" }), jsx(Text, { variant: "xs", className: classNames(styles$o.errorText), children: error })] }));
|
|
1374
|
+
var DescriptionSection = (jsx(Flex, { className: styles$o.description, gap: 4, ml: 16, mt: 8, style: { visibility: description ? 'visible' : 'hidden' }, children: jsx(Text, { variant: "xs", children: description }) }));
|
|
1343
1375
|
var dropdownFooter = function (store) { return (jsxs(Flex, { justify: "flex-end", py: 8, gap: 8, children: [jsx(Button, { variant: "outlined", label: "Clear", size: "small", onClick: handleClear }), jsx(Button, { variant: "filled", label: "Apply", size: "small", onClick: function () { return handleApply(store.closeDropdown); } })] })); };
|
|
1344
1376
|
return (jsx(Dropdown, { options: dropdownOptions, maxHeight: 300, footer: dropdownFooter, children: function (store) {
|
|
1345
1377
|
var _a, _b;
|
|
1346
1378
|
var floatLabel = store.dropdownOpened || hasSelectedOptions;
|
|
1347
|
-
return (jsxs("div", { className: styles$
|
|
1348
|
-
_a[styles$
|
|
1349
|
-
_a[styles$
|
|
1350
|
-
_a)), children: label })), jsxs(Box, { className: classNames(styles$
|
|
1351
|
-
_b[styles$
|
|
1379
|
+
return (jsxs("div", { className: styles$o.container, children: [floatLabel && (jsx("label", { className: classNames(styles$o.label, (_a = {},
|
|
1380
|
+
_a[styles$o.labelError] = error && !isFocused,
|
|
1381
|
+
_a[styles$o.labelFocused] = isFocused || isHovered,
|
|
1382
|
+
_a)), children: label })), jsxs(Box, { className: classNames(styles$o.input, multiselectStyles.input, (_b = {},
|
|
1383
|
+
_b[styles$o.inputError] = error && !isFocused,
|
|
1352
1384
|
_b[multiselectStyles.inputFocused] = isFocused || store.dropdownOpened,
|
|
1353
1385
|
_b[multiselectStyles.disabled] = disabled,
|
|
1354
1386
|
_b)), onMouseEnter: function () { return setIsHovered(true); }, onMouseLeave: function () { return setIsHovered(false); }, onClick: function () { return store.toggleDropdown(); }, onFocus: function () { return setIsFocused(true); }, onBlur: handleBlur, tabIndex: 0, children: [jsx(PillAndSearchSection, { store: store, maxPills: maxPills }), jsx(Chevron, { rotate: store.dropdownOpened ? 90 : 270 })] }), error ? ErrorSection : DescriptionSection] }));
|
|
@@ -1378,6 +1410,9 @@ var NavBar = function (_a) {
|
|
|
1378
1410
|
}
|
|
1379
1411
|
}, [expandedIdx, links]);
|
|
1380
1412
|
var isSubitemActive = function (item) { var _a; return (_a = item.subitems) === null || _a === undefined ? undefined : _a.some(function (sub) { return currentPath === null || currentPath === undefined ? undefined : currentPath.startsWith(sub.href); }); };
|
|
1413
|
+
var isItemActive = function (item) {
|
|
1414
|
+
return !!item.href && (currentPath === null || currentPath === undefined ? undefined : currentPath.startsWith(item.href));
|
|
1415
|
+
};
|
|
1381
1416
|
var handleNavigation = function (e, href) {
|
|
1382
1417
|
if (!href)
|
|
1383
1418
|
return;
|
|
@@ -1404,7 +1439,10 @@ var NavBar = function (_a) {
|
|
|
1404
1439
|
: ''), "data-text": item.title, children: item.title })) : (jsx("a", { onClick: function (e) {
|
|
1405
1440
|
setExpandedIdx(null);
|
|
1406
1441
|
handleNavigation(e, item.href);
|
|
1407
|
-
}, className: navBarStyles.menuItemText
|
|
1442
|
+
}, className: navBarStyles.menuItemText +
|
|
1443
|
+
(isItemActive(item)
|
|
1444
|
+
? ' ' + navBarStyles['menuItemText--bold']
|
|
1445
|
+
: ''), href: (_b = item.href) !== null && _b !== undefined ? _b : '', "data-text": item.title, children: item.title })), expandedIdx === idx && hasSubitems && (jsx(Flex, { className: navBarStyles.subnav, direction: "column", ref: dropdownRef, children: (_c = item === null || item === undefined ? undefined : item.subitems) === null || _c === undefined ? undefined : _c.map(function (sub) { return (jsx("a", { href: sub.href, onClick: function (e) {
|
|
1408
1446
|
setExpandedIdx(null);
|
|
1409
1447
|
handleNavigation(e, sub.href);
|
|
1410
1448
|
}, className: navBarStyles.subnavItem +
|
|
@@ -1415,15 +1453,15 @@ var NavBar = function (_a) {
|
|
|
1415
1453
|
};
|
|
1416
1454
|
NavBar.displayName = 'NavBar';
|
|
1417
1455
|
|
|
1418
|
-
var styles$
|
|
1456
|
+
var styles$8 = {"navbarSideContainer":"NavBarSide-module_navbarSideContainer__P8vLp","tabsRoot":"NavBarSide-module_tabsRoot__AAHNn","tabsList":"NavBarSide-module_tabsList__q9npG","tab":"NavBarSide-module_tab__i8yDE","tabsPanel":"NavBarSide-module_tabsPanel__-JWPo"};
|
|
1419
1457
|
|
|
1420
1458
|
var NavBarSide = function (_a) {
|
|
1421
1459
|
var tabs = _a.tabs, onChange = _a.onChange, value = _a.value;
|
|
1422
|
-
return (jsx("div", { className: styles$
|
|
1423
|
-
list: styles$
|
|
1424
|
-
tab: styles$
|
|
1425
|
-
panel: styles$
|
|
1426
|
-
root: styles$
|
|
1460
|
+
return (jsx("div", { className: styles$8.navbarSideContainer, children: jsxs(Tabs$1, { value: value, onChange: onChange, orientation: "vertical", keepMounted: false, classNames: {
|
|
1461
|
+
list: styles$8.tabsList,
|
|
1462
|
+
tab: styles$8.tab,
|
|
1463
|
+
panel: styles$8.tabsPanel,
|
|
1464
|
+
root: styles$8.tabsRoot,
|
|
1427
1465
|
}, children: [jsx(Tabs$1.List, { children: tabs.map(function (tab) { return (jsx(Tabs$1.Tab, { value: tab.value, "data-active": undefined, children: tab.label }, tab.value)); }) }), tabs.map(function (tab) { return (jsx(Tabs$1.Panel, { value: tab.value, children: tab.content }, tab.value)); })] }) }));
|
|
1428
1466
|
};
|
|
1429
1467
|
NavBarSide.displayName = 'NavBarSide';
|
|
@@ -1486,6 +1524,30 @@ var PasswordInput = function (_a) {
|
|
|
1486
1524
|
};
|
|
1487
1525
|
PasswordInput.displayName = 'PasswordInput';
|
|
1488
1526
|
|
|
1527
|
+
var styles$7 = {"pill":"Pill-module_pill__LeCgu","badge":"Pill-module_badge__DN2xw","secondary":"Pill-module_secondary__gu5Nq","text":"Pill-module_text__kUgzL","secondarySelected":"Pill-module_secondarySelected__-f9tB","primary":"Pill-module_primary__ZlP8y","primarySelected":"Pill-module_primarySelected__JC8JY","disabled":"Pill-module_disabled__1KocP"};
|
|
1528
|
+
|
|
1529
|
+
/**
|
|
1530
|
+
* Pill component is used to display a pill with a label and an optional icon
|
|
1531
|
+
* @param label - The label of the pill
|
|
1532
|
+
* @param rightIcon - The icon to display on the right side of the pill
|
|
1533
|
+
* @param leftIcon - The icon to display on the left side of the pill
|
|
1534
|
+
* @param isSelected - Whether the pill is selected
|
|
1535
|
+
* @param onClick - The function to call when the pill is clicked
|
|
1536
|
+
* @param disabled - Whether the pill is disabled
|
|
1537
|
+
* @param className - The class name to apply to the pill
|
|
1538
|
+
* @param dataFsElement - The data-fs-element to apply to the pill
|
|
1539
|
+
* @param variant - The variant of the pill
|
|
1540
|
+
* @returns The Pill component
|
|
1541
|
+
*/
|
|
1542
|
+
var Pill = function (_a) {
|
|
1543
|
+
var label = _a.label, rightIcon = _a.rightIcon, leftIcon = _a.leftIcon, _b = _a.isSelected, isSelected = _b === undefined ? false : _b, onClick = _a.onClick, _c = _a.disabled, disabled = _c === undefined ? false : _c, _d = _a.className, className = _d === undefined ? '' : _d, dataFsElement = _a.dataFsElement, _e = _a.variant, variant = _e === undefined ? 'secondary' : _e;
|
|
1544
|
+
var variantClass = isSelected
|
|
1545
|
+
? styles$7["".concat(variant, "Selected")]
|
|
1546
|
+
: styles$7[variant];
|
|
1547
|
+
return (jsxs("div", __assign({ className: classNames(styles$7.pill, variantClass, disabled && styles$7.disabled, className), onClick: disabled ? undefined : onClick }, (dataFsElement ? { 'data-fs-element': dataFsElement } : {}), { children: [leftIcon, jsx(Text, { variant: "xs", weight: "medium", className: "\n ".concat(styles$7.text, "\n ").concat(isSelected ? styles$7.selectedText : '', "\n ").concat(disabled ? styles$7.disabledText : '', "\n "), children: label }), rightIcon] })));
|
|
1548
|
+
};
|
|
1549
|
+
Pill.displayName = 'Pill';
|
|
1550
|
+
|
|
1489
1551
|
var styles$6 = {"radio":"RadioButton-module_radio__0A47m","label":"RadioButton-module_label__4gTzQ","disabled-label":"RadioButton-module_disabled-label__Nk0NW"};
|
|
1490
1552
|
|
|
1491
1553
|
/**
|
|
@@ -1585,7 +1647,7 @@ var Select = function (_a) {
|
|
|
1585
1647
|
label: styles$4['default-label'],
|
|
1586
1648
|
dropdown: styles$4.dropdown,
|
|
1587
1649
|
option: styles$4.option,
|
|
1588
|
-
}, data: data, placeholder: placeHolderValue, value: value, name: name || '', onChange: onChange, comboboxProps: { zIndex: 1000 }, error: ErrorSection, onFocus: function () { return setIsFocused(true); }, onBlur: handleBlur, inputWrapperOrder: ['label', 'input', 'description', 'error'], description: !error && description && jsx(Text, { variant: "xs", children: description }), descriptionProps: { className: styles$4.description }, errorProps: { className: styles$4.error }, rightSection: jsx(Chevron, { rotate: isOpen ? 90 : 270 }), rightSectionPointerEvents: "none", rightSectionProps: {
|
|
1650
|
+
}, data: data, placeholder: placeHolderValue, value: value, name: name || '', onChange: onChange, comboboxProps: { zIndex: 1000 }, error: ErrorSection, onFocus: function () { return setIsFocused(true); }, onBlur: handleBlur, inputWrapperOrder: ['label', 'input', 'description', 'error'], description: !error && description && jsx(Text, { variant: "xs", children: description }), descriptionProps: __assign({ className: styles$4.description }, inputWrapperSlotElement), errorProps: __assign({ className: styles$4.error }, inputWrapperSlotElement), rightSection: jsx(Chevron, { rotate: isOpen ? 90 : 270 }), rightSectionPointerEvents: "none", rightSectionProps: {
|
|
1589
1651
|
className: styles$4.chevron,
|
|
1590
1652
|
}, withCheckIcon: false, onDropdownOpen: function () { return setIsOpen(true); }, onDropdownClose: function () { return setIsOpen(false); }, disabled: disabled, searchable: searchable, allowDeselect: false, autoComplete: "new-password", renderOption: renderOption }) })] }));
|
|
1591
1653
|
};
|
|
@@ -1795,16 +1857,16 @@ var Textarea = function (_a) {
|
|
|
1795
1857
|
var _j = useState(false), isHovered = _j[0], setIsHovered = _j[1];
|
|
1796
1858
|
var showLabel = !hideLabel && (isFocused || value.trim());
|
|
1797
1859
|
var ErrorSection = useMemo(function () {
|
|
1798
|
-
return holdSpace && (jsxs(Flex, { className: styles$
|
|
1860
|
+
return holdSpace && (jsxs(Flex, { className: styles$o.error, gap: 4, ml: 0, style: { visibility: error ? 'visible' : 'hidden' }, children: [jsx(Info, { width: "18px", height: "18px", viewBox: "0 0 24 24", stroke: "var(--color-red-300)" }), jsx(Text, { variant: "xs", className: classNames(styles$o.errorText), as: "span", children: capitalizeFirstSentenceLetter(error) })] }));
|
|
1799
1861
|
}, [error]);
|
|
1800
|
-
return (jsxs("div", { className: styles$
|
|
1801
|
-
_b[styles$
|
|
1802
|
-
_b[styles$
|
|
1862
|
+
return (jsxs("div", { className: styles$o.container, children: [showLabel && (jsx("label", { className: classNames(styles$o.label, (_b = {},
|
|
1863
|
+
_b[styles$o.labelError] = error && !isFocused,
|
|
1864
|
+
_b[styles$o.labelFocused] = isFocused || isHovered,
|
|
1803
1865
|
_b)), children: label })), jsx("div", { onMouseEnter: function () { return setIsHovered(true); }, onMouseLeave: function () { return setIsHovered(false); }, onFocus: function () { return setIsFocused(true); }, onBlur: function () { return setIsFocused(false); }, children: jsx(Textarea$1, __assign({ classNames: {
|
|
1804
|
-
input: classNames(styles$
|
|
1805
|
-
_c[styles$
|
|
1866
|
+
input: classNames(styles$o.input, (_c = {},
|
|
1867
|
+
_c[styles$o.inputError] = error,
|
|
1806
1868
|
_c)),
|
|
1807
|
-
}, placeholder: placeholder !== null && placeholder !== undefined ? placeholder : label, name: name, error: ErrorSection, description: !error && jsx(Text, { variant: "xs", children: description }), descriptionProps:
|
|
1869
|
+
}, placeholder: placeholder !== null && placeholder !== undefined ? placeholder : label, name: name, error: ErrorSection, description: !error && jsx(Text, { variant: "xs", children: description }), descriptionProps: inputDescriptionProps, errorProps: inputErrorProps, inputWrapperOrder: ['label', 'input', 'description', 'error'], value: value, onChange: onChange, autosize: rest.h ? false : rest.autosize, minRows: 2 }, rest, { styles: {
|
|
1808
1870
|
input: {
|
|
1809
1871
|
height: typeof rest.h === 'string' || typeof rest.h === 'number'
|
|
1810
1872
|
? rest.h
|
|
@@ -2050,5 +2112,5 @@ var World = function (_a) {
|
|
|
2050
2112
|
};
|
|
2051
2113
|
World.displayName = 'World';
|
|
2052
2114
|
|
|
2053
|
-
export {
|
|
2054
|
-
//# sourceMappingURL=index-
|
|
2115
|
+
export { Attachment as $, Accordion as A, Badge as B, Card as C, DateInput as D, EnterCodeInput as E, FileInput as F, Stepper as G, Tabs as H, IncrementNumber as I, Text as J, Textarea as K, Link as L, Message as M, NavBar as N, ToastContainer as O, Pagination as P, Tooltip as Q, RadioButton as R, SegmentedControl as S, Table as T, AIGenerate as U, AIPrompt as V, AIRedo as W, AISearch as X, Alert as Y, Archive as Z, Arrow as _, AccordionItem as a, AvatarPlaceholder as a0, Bell as a1, Calendar as a2, Camera as a3, Cat as a4, Chat as a5, Check as a6, Chevron as a7, ChevronCollapse as a8, Clock as a9, Plaid as aA, Plus as aB, Refresh as aC, Remove as aD, Search as aE, Shield as aF, StepIndicator as aG, ThreeDots as aH, ThumbsDown as aI, Tick as aJ, Umbrello as aK, Upload as aL, Visa as aM, Warning as aN, World as aO, capitalizeFirstSentenceLetter as aP, Close as aa, Cloud as ab, CloudUpload as ac, CreditCard as ad, Delete as ae, Document as af, Dog as ag, EyeHide as ah, EyeShow as ai, Fingerprint as aj, Google as ak, Grid as al, Hamburger as am, HappyFace as an, House as ao, HouseTime as ap, Identification as aq, Info as ar, Location as as, Mail as at, Menu as au, MenuTouched as av, Notification as aw, Open as ax, Pets as ay, Phone as az, AccordionControl as b, AccordionPanel as c, ActionIcon as d, Animation as e, Autocomplete as f, getDefaultExportFromCjs as g, Avatar as h, badgeVariantMap as i, Button as j, cardStatusVariantMap as k, CardStatus as l, Checkbox as m, Chip as n, Dropdown as o, FileUpload as p, Input as q, LinkModal as r, Loader as s, Modal as t, Multiselect as u, NavBarSide as v, PasswordInput as w, Pill as x, Select as y, StatusBadge as z };
|
|
2116
|
+
//# sourceMappingURL=index-Dpa5RAiC.js.map
|