@giro-ds/react 11.0.0 → 11.2.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.cjs +283 -205
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +87 -32
- package/dist/index.esm.js +285 -208
- package/dist/index.esm.js.map +1 -1
- package/dist/styles.css +2 -2
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
2
2
|
import clsx from 'clsx';
|
|
3
|
-
import { Avatar as Avatar$1, Tooltip as Tooltip$1, Checkbox as Checkbox$1, Popover as Popover$1, Label, AlertDialog, RadioGroup, DropdownMenu, Dialog as Dialog$1, Select as Select$1, Toast as Toast$1, Switch as Switch$1 } from 'radix-ui';
|
|
3
|
+
import { Avatar as Avatar$1, Tooltip as Tooltip$1, Checkbox as Checkbox$1, Popover as Popover$1, Label, AlertDialog, RadioGroup, DropdownMenu, Dialog as Dialog$1, Select as Select$1, Toast as Toast$1, Switch as Switch$1, unstable_OneTimePasswordField } from 'radix-ui';
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import React__default, { useId, useMemo, createContext, useState, useContext, useRef, useCallback, useEffect, useLayoutEffect, createElement, forwardRef, memo, useReducer, isValidElement } from 'react';
|
|
6
|
-
import { SpinnerIos16Regular, ChevronUp16Regular, ChevronLeft16Regular, ChevronRight16Regular, ChevronDown16Regular, Dismiss24Regular, Emoji20Regular, ChevronDown20Regular, KeyboardShiftUppercase20Regular, KeyboardShift20Filled, KeyboardShift20Regular, Backspace20Regular, Info12Regular, Dismiss16Regular, Calendar16Regular, FilterRegular, Search16Regular, ChevronDownRegular, ChevronRight16Filled, Subtract16Regular, Add16Regular, SearchInfo20Regular, ArrowSortUp16Regular, ArrowSortDown16Regular, ArrowSort16Regular, Info20Filled, CheckmarkCircle20Filled, Warning20Filled, Dismiss16Filled } from '@fluentui/react-icons';
|
|
6
|
+
import { SpinnerIos16Regular, ChevronUp16Regular, ChevronLeft16Regular, ChevronRight16Regular, ChevronDown16Regular, Dismiss24Regular, Emoji20Regular, ChevronDown20Regular, KeyboardShiftUppercase20Regular, KeyboardShift20Filled, KeyboardShift20Regular, Backspace20Regular, Info12Regular, Dismiss16Regular, Calendar16Regular, DocumentAdd24Regular, Warning24Regular, Document24Regular, FilterRegular, Search16Regular, ChevronDownRegular, ChevronRight16Filled, Subtract16Regular, Add16Regular, SearchInfo20Regular, ArrowSortUp16Regular, ArrowSortDown16Regular, ArrowSort16Regular, Info20Filled, CheckmarkCircle20Filled, Warning20Filled, Dismiss16Filled } from '@fluentui/react-icons';
|
|
7
7
|
import { DayPicker } from 'react-day-picker';
|
|
8
8
|
import { format, addDays, addMonths, addWeeks, addYears, differenceInCalendarDays, differenceInCalendarMonths, eachMonthOfInterval, eachYearOfInterval, endOfISOWeek, endOfMonth, endOfWeek, endOfYear, getISOWeek, getMonth, getYear, getWeek, isAfter, isBefore, isDate, isSameDay, isSameMonth, isSameYear, max, min, setMonth, setYear, startOfDay, startOfISOWeek, startOfMonth, startOfWeek, startOfYear } from 'date-fns';
|
|
9
9
|
import { createPortal } from 'react-dom';
|
|
@@ -12,17 +12,17 @@ import { useReactTable, getSortedRowModel, getCoreRowModel, flexRender } from '@
|
|
|
12
12
|
export { createColumnHelper as createTableColumnHelper } from '@tanstack/react-table';
|
|
13
13
|
import Skeleton from 'react-loading-skeleton';
|
|
14
14
|
|
|
15
|
-
var styles$
|
|
15
|
+
var styles$v = {"AvatarRoot":"Avatar-module__AvatarRoot___7eNx7","AvatarRoot--sm":"Avatar-module__AvatarRoot--sm___LVHoe","AvatarRoot--lg":"Avatar-module__AvatarRoot--lg___QWux5","AvatarImage":"Avatar-module__AvatarImage___-H6iH","AvatarFallback":"Avatar-module__AvatarFallback___RDyNV"};
|
|
16
16
|
|
|
17
17
|
const Avatar = ({ icon, size = 'lg', src, className, initialLetters, ...rest }) => {
|
|
18
|
-
const AvatarClass = clsx(styles$
|
|
19
|
-
[styles$
|
|
20
|
-
[styles$
|
|
18
|
+
const AvatarClass = clsx(styles$v.AvatarRoot, {
|
|
19
|
+
[styles$v['AvatarRoot--lg']]: size === 'lg',
|
|
20
|
+
[styles$v['AvatarRoot--sm']]: size === 'sm',
|
|
21
21
|
}, className);
|
|
22
|
-
return (jsxs(Avatar$1.Root, { className: AvatarClass, ...rest, children: [src && (jsx(Avatar$1.Image, { className: styles$
|
|
22
|
+
return (jsxs(Avatar$1.Root, { className: AvatarClass, ...rest, children: [src && (jsx(Avatar$1.Image, { className: styles$v.AvatarImage, src: src, alt: "Avatar" })), jsx(Avatar$1.Fallback, { className: styles$v.AvatarFallback, children: icon || initialLetters })] }));
|
|
23
23
|
};
|
|
24
24
|
|
|
25
|
-
var styles$
|
|
25
|
+
var styles$u = {"badge__status":"Badge-module__badge__status___-u3xv","badge":"Badge-module__badge___ZbEBU","badgeContainer":"Badge-module__badgeContainer___Guw9Z","badge__empty":"Badge-module__badge__empty___u8ccy","badge__flex":"Badge-module__badge__flex___DSJHW","badge__status__empty":"Badge-module__badge__status__empty___h8L4e","badge__status__flex":"Badge-module__badge__status__flex___703Q6","badge__status__filterBadge":"Badge-module__badge__status__filterBadge___DhjGU"};
|
|
26
26
|
|
|
27
27
|
const getDisplayValue = (value) => {
|
|
28
28
|
if (value === null || value === undefined)
|
|
@@ -44,25 +44,25 @@ const Badge = ({ children, badgeValue = null, className, id, filterVariant = fal
|
|
|
44
44
|
const displayValue = getDisplayValue(badgeValue);
|
|
45
45
|
const isEmpty = displayValue === '';
|
|
46
46
|
if (children) {
|
|
47
|
-
return (jsxs("div", { className: styles$
|
|
48
|
-
[styles$
|
|
49
|
-
[styles$
|
|
47
|
+
return (jsxs("div", { className: styles$u.badgeContainer, ...rest, children: [jsx("div", { "data-testid": "badge-content", children: children }), jsx("div", { id: componentId, className: clsx(styles$u.badge, {
|
|
48
|
+
[styles$u['badge__empty']]: isEmpty,
|
|
49
|
+
[styles$u['badge__flex']]: displayValue.length >= 2,
|
|
50
50
|
}, className), "data-testid": "badge", children: !isEmpty && jsx("span", { "aria-hidden": !!ariaLabel, children: displayValue }) })] }));
|
|
51
51
|
}
|
|
52
|
-
return (jsx("div", { className: styles$
|
|
53
|
-
[styles$
|
|
54
|
-
[styles$
|
|
55
|
-
[styles$
|
|
52
|
+
return (jsx("div", { className: styles$u.badgeContainer, children: jsx("div", { className: clsx(styles$u['badge__status'], {
|
|
53
|
+
[styles$u['badge__status__empty']]: isEmpty,
|
|
54
|
+
[styles$u['badge__status__flex']]: displayValue.length >= 2,
|
|
55
|
+
[styles$u['badge__status__filterBadge']]: filterVariant,
|
|
56
56
|
}, className), "data-testid": "badge", children: !isEmpty && (jsx("span", { "aria-hidden": !!ariaLabel, children: displayValue })) }) }));
|
|
57
57
|
};
|
|
58
58
|
|
|
59
|
-
var styles$
|
|
59
|
+
var styles$t = {"tooltipContent":"Tooltip-module__tooltipContent___xycUg","triggerWrapper":"Tooltip-module__triggerWrapper___x83XR"};
|
|
60
60
|
|
|
61
61
|
const Tooltip = ({ children, text, side = 'bottom', align = 'start', maxWidth, sideOffset = 10, className, ...rest }) => {
|
|
62
|
-
return (jsx(Tooltip$1.Provider, { children: jsxs(Tooltip$1.Root, { children: [jsx(Tooltip$1.Trigger, { asChild: true, children: jsx("span", { className: styles$
|
|
62
|
+
return (jsx(Tooltip$1.Provider, { children: jsxs(Tooltip$1.Root, { children: [jsx(Tooltip$1.Trigger, { asChild: true, children: jsx("span", { className: styles$t.triggerWrapper, children: children }) }), jsx(Tooltip$1.Portal, { children: jsx(Tooltip$1.Content, { className: clsx(styles$t.tooltipContent, className), side: side, align: align, sideOffset: sideOffset, style: { maxWidth: maxWidth ? `${maxWidth}px` : 'auto' }, ...rest, children: text }) })] }) }));
|
|
63
63
|
};
|
|
64
64
|
|
|
65
|
-
var styles$
|
|
65
|
+
var styles$s = {"button":"Button-module__button___18Bed","button-lg":"Button-module__button-lg___-A8B9","button-sm":"Button-module__button-sm___L7aT7","button-filled":"Button-module__button-filled___IQx1z","button-outlined":"Button-module__button-outlined___hLkLN","button-text":"Button-module__button-text___8GFeA","buttonWithIcon":"Button-module__buttonWithIcon___8ehK1","buttonIconPosition-left":"Button-module__buttonIconPosition-left___uOY6b","buttonIconPosition-right":"Button-module__buttonIconPosition-right___eswRS","buttonIconPosition-both":"Button-module__buttonIconPosition-both___1Lith","buttonNoContent":"Button-module__buttonNoContent___Tc9jk","buttonIconOnly":"Button-module__buttonIconOnly___aifk4","buttonIconLeft":"Button-module__buttonIconLeft___RICR3","buttonIconRight":"Button-module__buttonIconRight___71lu2","buttonFullWidth":"Button-module__buttonFullWidth___tXuVE","disabled":"Button-module__disabled___UzdWL","buttonLoading":"Button-module__buttonLoading___RGdNw","buttonContentHidden":"Button-module__buttonContentHidden___CoCiN","buttonLoadingSpinner":"Button-module__buttonLoadingSpinner___oZxEU","spin":"Button-module__spin___kQKH9"};
|
|
66
66
|
|
|
67
67
|
const Button = React__default.forwardRef(({ as, children, variant = 'filled', iconPosition = 'left', href, to, external = false, target, rel, disabled = false, onClick, size = 'lg', scale = 1, className, type = 'button', id, icon, fullWidth = false, ariaLabel, iconOnly = false, loading = false, tooltipText, tooltipSide = 'top', tooltipAlign = 'center', ...rest }, ref) => {
|
|
68
68
|
const generatedId = useId();
|
|
@@ -91,14 +91,14 @@ const Button = React__default.forwardRef(({ as, children, variant = 'filled', ic
|
|
|
91
91
|
'Forneça um ícone via `icon={<MeuIcone />}`.');
|
|
92
92
|
}
|
|
93
93
|
const resolvedIcon = icon;
|
|
94
|
-
const buttonClasses = clsx(styles$
|
|
95
|
-
[styles$
|
|
96
|
-
[styles$
|
|
97
|
-
[styles$
|
|
98
|
-
[styles$
|
|
99
|
-
[styles$
|
|
100
|
-
[styles$
|
|
101
|
-
[styles$
|
|
94
|
+
const buttonClasses = clsx(styles$s.button, styles$s[`button-${variant}`], styles$s[`button-${size}`], {
|
|
95
|
+
[styles$s['disabled']]: disabled,
|
|
96
|
+
[styles$s['buttonLoading']]: loading,
|
|
97
|
+
[styles$s['buttonWithIcon']]: resolvedIcon && !iconOnly,
|
|
98
|
+
[styles$s[`buttonIconPosition-${iconPosition}`]]: resolvedIcon && !iconOnly,
|
|
99
|
+
[styles$s['buttonNoContent']]: resolvedIcon && !hasContent && !iconOnly,
|
|
100
|
+
[styles$s['buttonFullWidth']]: fullWidth,
|
|
101
|
+
[styles$s['buttonIconOnly']]: iconOnly,
|
|
102
102
|
}, className);
|
|
103
103
|
const getAriaLabel = () => {
|
|
104
104
|
if (ariaLabel)
|
|
@@ -124,12 +124,12 @@ const Button = React__default.forwardRef(({ as, children, variant = 'filled', ic
|
|
|
124
124
|
};
|
|
125
125
|
const renderContent = () => {
|
|
126
126
|
if (iconOnly && !loading) {
|
|
127
|
-
return (jsx("span", { className: styles$
|
|
127
|
+
return (jsx("span", { className: styles$s.buttonIconOnly, "aria-hidden": "true", children: resolvedIcon }));
|
|
128
128
|
}
|
|
129
129
|
if (loading) {
|
|
130
|
-
return (jsxs(Fragment, { children: [!iconOnly && (jsxs("span", { className: styles$
|
|
130
|
+
return (jsxs(Fragment, { children: [!iconOnly && (jsxs("span", { className: styles$s.buttonContentHidden, "aria-hidden": "true", children: [resolvedIcon && (iconPosition === 'left' || iconPosition === 'both') && (jsx("span", { className: styles$s.buttonIconLeft, children: resolvedIcon })), children, resolvedIcon && (iconPosition === 'right' || iconPosition === 'both') && (jsx("span", { className: styles$s.buttonIconRight, children: resolvedIcon }))] })), jsx("span", { className: styles$s.buttonLoadingSpinner, "aria-hidden": "true", children: jsx(SpinnerIos16Regular, { "aria-hidden": "true" }) })] }));
|
|
131
131
|
}
|
|
132
|
-
return (jsxs(Fragment, { children: [resolvedIcon && (iconPosition === 'left' || iconPosition === 'both') && (jsx("span", { className: styles$
|
|
132
|
+
return (jsxs(Fragment, { children: [resolvedIcon && (iconPosition === 'left' || iconPosition === 'both') && (jsx("span", { className: styles$s.buttonIconLeft, "aria-hidden": "true", children: resolvedIcon })), children, resolvedIcon && (iconPosition === 'right' || iconPosition === 'both') && (jsx("span", { className: styles$s.buttonIconRight, "aria-hidden": "true", children: resolvedIcon }))] }));
|
|
133
133
|
};
|
|
134
134
|
const { style: externalStyle, ...otherRest } = rest;
|
|
135
135
|
const baseProps = {
|
|
@@ -2439,7 +2439,7 @@ const ptBR = {
|
|
|
2439
2439
|
},
|
|
2440
2440
|
};
|
|
2441
2441
|
|
|
2442
|
-
var styles$
|
|
2442
|
+
var styles$r = {"root":"Calendar-module__root___vQEhz","day":"Calendar-module__day___dseUA","day_button":"Calendar-module__day_button___r3WNU","caption_label":"Calendar-module__caption_label___Dhkie","button_next":"Calendar-module__button_next___iRaNz","button_previous":"Calendar-module__button_previous___r7JBs","chevron":"Calendar-module__chevron___NPDg-","nav":"Calendar-module__nav___MT3Dm","dropdowns":"Calendar-module__dropdowns___xBVtv","dropdown":"Calendar-module__dropdown___D7OlW","dropdown_root":"Calendar-module__dropdown_root___v4DlK","month_caption":"Calendar-module__month_caption___P3Hlu","month":"Calendar-module__month___0RA-L","months":"Calendar-module__months___rmJdy","month_grid":"Calendar-module__month_grid___f6YkX","weekday":"Calendar-module__weekday___Spb2f","week_number":"Calendar-module__week_number___EXJD9","today":"Calendar-module__today___U36wP","outside":"Calendar-module__outside___UeJFZ","selected":"Calendar-module__selected___5Nryr","disabled":"Calendar-module__disabled___T3658","hidden":"Calendar-module__hidden___uL3uc","range_start":"Calendar-module__range_start___c1eNH","range_middle":"Calendar-module__range_middle___Uv4gt","range_end":"Calendar-module__range_end___4qDh5","focusable":"Calendar-module__focusable___V7w-Q","weeks_before_enter":"Calendar-module__weeks_before_enter___O1ytQ","slide_in_left":"Calendar-module__slide_in_left___hfrfr","weeks_before_exit":"Calendar-module__weeks_before_exit___v7nDr","slide_out_left":"Calendar-module__slide_out_left___kib4j","weeks_after_enter":"Calendar-module__weeks_after_enter___CEtsD","slide_in_right":"Calendar-module__slide_in_right___ldL0M","weeks_after_exit":"Calendar-module__weeks_after_exit___F8Edz","slide_out_right":"Calendar-module__slide_out_right___X2hxE","caption_after_enter":"Calendar-module__caption_after_enter___0ek1H","fade_in":"Calendar-module__fade_in___YyYoZ","caption_after_exit":"Calendar-module__caption_after_exit___RA1iK","fade_out":"Calendar-module__fade_out___lNcmB","caption_before_enter":"Calendar-module__caption_before_enter___j6sMK","caption_before_exit":"Calendar-module__caption_before_exit___rntl-","calendar_grid_wrapper":"Calendar-module__calendar_grid_wrapper___OX0TR","caption_grid_btn":"Calendar-module__caption_grid_btn___qD0-E","caption_year_chevron":"Calendar-module__caption_year_chevron___4ghQV","caption_grid_label":"Calendar-module__caption_grid_label___93Wx4","gridOverlay":"Calendar-module__gridOverlay___Za-y0","gridOverlayCaption":"Calendar-module__gridOverlayCaption___p4OUO","gridOverlayYearsNav":"Calendar-module__gridOverlayYearsNav___U6S-V","gridCells":"Calendar-module__gridCells___Y8DaG","gridCellsYears":"Calendar-module__gridCellsYears___jEV52","gridCell":"Calendar-module__gridCell___RV1co","gridCellActive":"Calendar-module__gridCellActive___UBi5y","gridNavBtn":"Calendar-module__gridNavBtn___Jligz","chevronNavBtnPrev":"Calendar-module__chevronNavBtnPrev___ifEps","chevronNavBtnNext":"Calendar-module__chevronNavBtnNext___qmghm","chevron_wrapper":"Calendar-module__chevron_wrapper___BfN9a"};
|
|
2443
2443
|
|
|
2444
2444
|
const FLUENT_CHEVRON_MAP = {
|
|
2445
2445
|
down: ChevronDown16Regular,
|
|
@@ -2449,7 +2449,7 @@ const FLUENT_CHEVRON_MAP = {
|
|
|
2449
2449
|
};
|
|
2450
2450
|
const CustomChevron = ({ orientation = "left", className, }) => {
|
|
2451
2451
|
const Icon = FLUENT_CHEVRON_MAP[orientation];
|
|
2452
|
-
return jsx("span", { className: styles$
|
|
2452
|
+
return jsx("span", { className: styles$r.chevron_wrapper, children: jsx(Icon, { className: className, "aria-hidden": true }) });
|
|
2453
2453
|
};
|
|
2454
2454
|
const GridCtx = createContext(null);
|
|
2455
2455
|
const GridMonthCaption = ({ calendarMonth, displayIndex: _displayIndex, ...divProps }) => {
|
|
@@ -2458,7 +2458,7 @@ const GridMonthCaption = ({ calendarMonth, displayIndex: _displayIndex, ...divPr
|
|
|
2458
2458
|
const date = calendarMonth.date;
|
|
2459
2459
|
const monthLabel = new Intl.DateTimeFormat(intlLocale, { month: "long" }).format(date);
|
|
2460
2460
|
const yearLabel = String(date.getFullYear());
|
|
2461
|
-
return (jsxs("div", { ...divProps, children: [jsx("span", { className: styles$
|
|
2461
|
+
return (jsxs("div", { ...divProps, children: [jsx("span", { className: styles$r.caption_grid_label, children: monthLabel }), jsxs("button", { type: "button", className: styles$r.caption_grid_btn, "aria-pressed": view === "years", onClick: onYearLabelClick, children: [yearLabel, view !== "days" ? (jsx("span", { className: styles$r.chevron_wrapper, children: jsx(ChevronUp16Regular, { className: styles$r.caption_year_chevron, "aria-hidden": true }) })) : (jsx("span", { className: styles$r.chevron_wrapper, children: jsx(ChevronDown16Regular, { className: styles$r.caption_year_chevron, "aria-hidden": true }) }))] })] }));
|
|
2462
2462
|
};
|
|
2463
2463
|
const YEARS_PER_PAGE = 20;
|
|
2464
2464
|
const Calendar = ({ selected, currentDate, defaultMonth, startMonth, endMonth, onDaySelect, onDateChange, onClear: _onClear, minDate, maxDate, disabled, format: _format, locale = "pt-br", autoFocus, className, style, scale = 1, id, "aria-label": ariaLabel, ...rest }) => {
|
|
@@ -2526,7 +2526,7 @@ const Calendar = ({ selected, currentDate, defaultMonth, startMonth, endMonth, o
|
|
|
2526
2526
|
onYearLabelClick: handleYearLabelClick,
|
|
2527
2527
|
};
|
|
2528
2528
|
const sharedDayPickerProps = {
|
|
2529
|
-
classNames: styles$
|
|
2529
|
+
classNames: styles$r,
|
|
2530
2530
|
animate,
|
|
2531
2531
|
mode: "single",
|
|
2532
2532
|
selected: resolvedSelected,
|
|
@@ -2539,10 +2539,10 @@ const Calendar = ({ selected, currentDate, defaultMonth, startMonth, endMonth, o
|
|
|
2539
2539
|
"aria-label": ariaLabel,
|
|
2540
2540
|
};
|
|
2541
2541
|
const containerStyle = { '--giro-scale': scale };
|
|
2542
|
-
return (jsx(GridCtx.Provider, { value: gridCtxValue, children: jsxs("div", { className: clsx(styles$
|
|
2542
|
+
return (jsx(GridCtx.Provider, { value: gridCtxValue, children: jsxs("div", { className: clsx(styles$r.calendar_grid_wrapper, className), style: { ...containerStyle, ...style }, children: [jsx(DayPicker, { id: id, ...sharedDayPickerProps, ...rest, captionLayout: "label", month: resolvedDisplayMonth, onMonthChange: handleMonthChange, components: { MonthCaption: GridMonthCaption, Chevron: CustomChevron } }), gridView !== "days" && (jsxs("div", { className: `${styles$r.gridOverlay}${gridView === "years" ? ` ${styles$r.gridOverlayYears}` : ""}`, role: "dialog", "aria-modal": "true", "aria-label": gridView === "months" ? "Selecione o mês" : "Selecione o ano", children: [gridView === "months" && (jsxs(Fragment, { children: [jsxs("div", { className: styles$r.gridOverlayCaption, children: [jsx("span", { className: styles$r.caption_grid_label, children: new Intl.DateTimeFormat(intlLocale, { month: "long" }).format(resolvedDisplayMonth) }), jsxs("button", { type: "button", className: styles$r.caption_grid_btn, onClick: () => setGridView("days"), "aria-label": "Fechar sele\u00E7\u00E3o de m\u00EAs", children: [displayedYear, jsx("span", { className: styles$r.chevron_wrapper, children: jsx(ChevronUp16Regular, { className: styles$r.caption_year_chevron, "aria-hidden": true }) })] })] }), jsx("div", { className: styles$r.gridCells, children: monthsGrid.map(({ index, label, disabled: monthDisabled }) => (jsx("button", { type: "button", disabled: monthDisabled, className: `${styles$r.gridCell}${displayedMonthIndex === index ? ` ${styles$r.gridCellActive}` : ""}`, onClick: () => handleGridMonthSelect(index), children: label }, index))) })] })), gridView === "years" && (jsxs(Fragment, { children: [jsxs("div", { className: styles$r.gridOverlayCaption, children: [jsx("span", { className: styles$r.caption_grid_label, children: new Intl.DateTimeFormat(intlLocale, { month: "long" }).format(resolvedDisplayMonth) }), jsxs("button", { type: "button", className: styles$r.caption_grid_btn, onClick: () => setGridView("days"), "aria-label": "Fechar sele\u00E7\u00E3o de ano", children: [displayedYear, jsx("span", { className: styles$r.chevron_wrapper, children: jsx(ChevronUp16Regular, { className: styles$r.caption_year_chevron, "aria-hidden": true }) })] }), jsxs("div", { className: styles$r.gridOverlayYearsNav, children: [jsx("button", { type: "button", className: styles$r.gridNavBtn, disabled: !canGoPrevYears, onClick: () => setYearPageStart((s) => s - YEARS_PER_PAGE), "aria-label": "Anos anteriores", children: jsx("span", { className: styles$r.chevron_wrapper, children: jsx(ChevronLeft16Regular, { className: styles$r.chevronNavBtnPrev, "aria-hidden": true }) }) }), jsx("button", { type: "button", className: styles$r.gridNavBtn, disabled: !canGoNextYears, onClick: () => setYearPageStart((s) => s + YEARS_PER_PAGE), "aria-label": "Pr\u00F3ximos anos", children: jsx("span", { className: styles$r.chevron_wrapper, children: jsx(ChevronRight16Regular, { className: styles$r.chevronNavBtnNext, "aria-hidden": true }) }) })] })] }), jsx("div", { className: `${styles$r.gridCells} ${styles$r.gridCellsYears}`, children: yearsInPage.map((year) => (jsx("button", { type: "button", className: `${styles$r.gridCell}${displayedYear === year ? ` ${styles$r.gridCellActive}` : ""}`, onClick: () => handleGridYearSelect(year), children: year }, year))) })] }))] }))] }) }));
|
|
2543
2543
|
};
|
|
2544
2544
|
|
|
2545
|
-
var styles$
|
|
2545
|
+
var styles$q = {"container":"Callout-module__container___dggFW","withTitle":"Callout-module__withTitle___e-HEg","brand":"Callout-module__brand___YHDPQ","success":"Callout-module__success___RPS0Q","alert":"Callout-module__alert___LVlJM","content":"Callout-module__content___g44Qz","icon":"Callout-module__icon___4CBkz","subcontent":"Callout-module__subcontent___5hz-f","title":"Callout-module__title___IPSdE","text":"Callout-module__text___0Ys48","dismiss":"Callout-module__dismiss___ZaycS"};
|
|
2546
2546
|
|
|
2547
2547
|
const Callout = ({ variant = 'neutral', title, text, icon, onDismiss, dismiss, backgroundColor, textColor, className, id, style, ...rest }) => {
|
|
2548
2548
|
if (process.env.NODE_ENV !== 'production' && (text === '' || (typeof text === 'string' && !text.trim()))) {
|
|
@@ -2552,19 +2552,19 @@ const Callout = ({ variant = 'neutral', title, text, icon, onDismiss, dismiss, b
|
|
|
2552
2552
|
const titleId = `callout-title-${id || generatedId}`;
|
|
2553
2553
|
const componentId = id || generatedId;
|
|
2554
2554
|
const isAlert = variant === 'alert';
|
|
2555
|
-
const containerClass = clsx(styles$
|
|
2555
|
+
const containerClass = clsx(styles$q.container, styles$q[variant], { [styles$q.withTitle]: title }, className);
|
|
2556
2556
|
const customStyle = {
|
|
2557
2557
|
...style,
|
|
2558
2558
|
...(backgroundColor && { '--callout-bg': `var(--${backgroundColor})` }),
|
|
2559
2559
|
...(textColor && { '--callout-text': `var(--${textColor})` }),
|
|
2560
2560
|
};
|
|
2561
|
-
return (jsx("div", { id: componentId, className: containerClass, role: isAlert ? 'alert' : 'status', "aria-live": isAlert ? 'assertive' : 'polite', "aria-labelledby": title ? titleId : undefined, style: customStyle, ...rest, children: jsxs("div", { className: styles$
|
|
2561
|
+
return (jsx("div", { id: componentId, className: containerClass, role: isAlert ? 'alert' : 'status', "aria-live": isAlert ? 'assertive' : 'polite', "aria-labelledby": title ? titleId : undefined, style: customStyle, ...rest, children: jsxs("div", { className: styles$q.content, children: [icon && jsx("span", { className: styles$q.icon, "aria-hidden": "true", children: icon }), jsxs("div", { className: styles$q.subcontent, children: [title && (jsx("span", { id: titleId, className: styles$q.title, children: title })), text && jsx("span", { className: styles$q.text, children: text })] }), dismiss && (jsx("button", { className: styles$q.dismiss, onClick: onDismiss, type: "button", "aria-label": "Fechar", children: jsx(Dismiss24Regular, { "aria-hidden": "true" }) }))] }) }));
|
|
2562
2562
|
};
|
|
2563
2563
|
|
|
2564
|
-
var styles$
|
|
2564
|
+
var styles$p = {"card":"Card-module__card___LzN-3","card--hoverable":"Card-module__card--hoverable___orpJZ"};
|
|
2565
2565
|
|
|
2566
2566
|
function Card({ children, className, hoverable }) {
|
|
2567
|
-
return (jsx("main", { className: clsx(styles$
|
|
2567
|
+
return (jsx("main", { className: clsx(styles$p['card'], hoverable && styles$p['card--hoverable'], className), children: children }));
|
|
2568
2568
|
}
|
|
2569
2569
|
|
|
2570
2570
|
const CheckSmall = ({ className = '', width = 12, height = 10, fill = 'white', ...restProps }) => {
|
|
@@ -2575,22 +2575,22 @@ const CheckHalf = ({ className = '', width = 16, height = 16, fill = 'white', ..
|
|
|
2575
2575
|
return (jsx("svg", { width: width, height: height, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className, "aria-hidden": "true", ...restProps, children: jsx("g", { id: "Icons/check_indeterminate_small", children: jsx("path", { id: "icon", d: "M3 9V7H13V9H3Z", fill: fill }) }) }));
|
|
2576
2576
|
};
|
|
2577
2577
|
|
|
2578
|
-
var styles$
|
|
2578
|
+
var styles$o = {"container":"Checkbox-module__container___pUY-s","root":"Checkbox-module__root___BS5dT","disabled":"Checkbox-module__disabled___WagIC","label":"Checkbox-module__label___JBaRm","indicator":"Checkbox-module__indicator___HXLHH","wrapperCheckbox":"Checkbox-module__wrapperCheckbox___m2qIW"};
|
|
2579
2579
|
|
|
2580
2580
|
const Checkbox = ({ id, label, onCheckedChange, checked, disabled, className, style, scale = 1, indeterminate = false, ...rest }) => {
|
|
2581
2581
|
const componentId = id || React.useId();
|
|
2582
|
-
return (jsxs("div", { className: clsx(styles$
|
|
2583
|
-
[styles$
|
|
2584
|
-
}), role: "presentation", tabIndex: disabled ? -1 : 0, children: jsx(Checkbox$1.Root, { className: styles$
|
|
2582
|
+
return (jsxs("div", { className: clsx(styles$o.container, className), style: { '--giro-scale': scale, ...style }, children: [jsx("div", { className: clsx(styles$o.wrapperCheckbox, {
|
|
2583
|
+
[styles$o.disabled]: disabled,
|
|
2584
|
+
}), role: "presentation", tabIndex: disabled ? -1 : 0, children: jsx(Checkbox$1.Root, { className: styles$o.root, checked: indeterminate ? 'indeterminate' : checked, id: componentId, onCheckedChange: onCheckedChange, disabled: disabled, "data-disabled": disabled, "data-indeterminate": indeterminate, "aria-checked": indeterminate ? 'mixed' : checked ? 'true' : 'false', ...rest, children: jsx(Checkbox$1.Indicator, { className: styles$o.indicator, children: indeterminate ? jsx(CheckHalf, {}) : jsx(CheckSmall, {}) }) }) }), jsx("label", { className: clsx(styles$o.label, { [styles$o.disabled]: disabled }), htmlFor: componentId, children: label })] }));
|
|
2585
2585
|
};
|
|
2586
2586
|
|
|
2587
|
-
var styles$
|
|
2587
|
+
var styles$n = {"chips":"Chips-module__chips___SOvBe","title":"Chips-module__title___ZhuQi","iconLeft":"Chips-module__iconLeft___tPhnw","iconRight":"Chips-module__iconRight___-HxL2","hasLeftIcon":"Chips-module__hasLeftIcon___D3quS","hasRightIcon":"Chips-module__hasRightIcon___ZMx2Y","brand":"Chips-module__brand___q1Gsm","success":"Chips-module__success___UhxQa","alert":"Chips-module__alert___nvPnr","disabled":"Chips-module__disabled___ElWLI"};
|
|
2588
2588
|
|
|
2589
2589
|
const Chips = ({ children, leftIcon, rightIcon, variant = 'neutral', disabled = false, backgroundColor, textColor, scale = 1, className, style, ...rest }) => {
|
|
2590
|
-
const chipsClass = clsx(styles$
|
|
2591
|
-
[styles$
|
|
2592
|
-
[styles$
|
|
2593
|
-
[styles$
|
|
2590
|
+
const chipsClass = clsx(styles$n.chips, styles$n[variant], {
|
|
2591
|
+
[styles$n.disabled]: disabled,
|
|
2592
|
+
[styles$n.hasLeftIcon]: leftIcon,
|
|
2593
|
+
[styles$n.hasRightIcon]: rightIcon,
|
|
2594
2594
|
}, className);
|
|
2595
2595
|
const colorStyle = {
|
|
2596
2596
|
'--giro-scale': scale,
|
|
@@ -2599,21 +2599,21 @@ const Chips = ({ children, leftIcon, rightIcon, variant = 'neutral', disabled =
|
|
|
2599
2599
|
...style,
|
|
2600
2600
|
};
|
|
2601
2601
|
const isInteractive = typeof rest.onClick === 'function';
|
|
2602
|
-
return (jsxs("div", { className: chipsClass, "aria-disabled": disabled, style: colorStyle, role: isInteractive ? 'button' : undefined, tabIndex: isInteractive ? (disabled ? -1 : 0) : undefined, ...rest, children: [leftIcon && (jsx("span", { className: styles$
|
|
2602
|
+
return (jsxs("div", { className: chipsClass, "aria-disabled": disabled, style: colorStyle, role: isInteractive ? 'button' : undefined, tabIndex: isInteractive ? (disabled ? -1 : 0) : undefined, ...rest, children: [leftIcon && (jsx("span", { className: styles$n.iconLeft, "aria-hidden": "true", children: leftIcon })), jsx("span", { className: styles$n.title, children: children }), rightIcon && (jsx("span", { className: styles$n.iconRight, children: rightIcon }))] }));
|
|
2603
2603
|
};
|
|
2604
2604
|
const MemoizedChips = React__default.memo(Chips);
|
|
2605
2605
|
MemoizedChips.displayName = 'Chips';
|
|
2606
2606
|
|
|
2607
|
-
var styles$
|
|
2607
|
+
var styles$m = {"container":"Container-module__container___exPuE"};
|
|
2608
2608
|
|
|
2609
2609
|
function Container({ children, className }) {
|
|
2610
|
-
return (jsx("main", { className: clsx(styles$
|
|
2610
|
+
return (jsx("main", { className: clsx(styles$m['container'], 'mx-auto', className), children: children }));
|
|
2611
2611
|
}
|
|
2612
2612
|
|
|
2613
|
-
var styles$
|
|
2613
|
+
var styles$l = {"Content":"Popover-module__Content___RIETg"};
|
|
2614
2614
|
|
|
2615
2615
|
const Popover = ({ trigger, content, side = "left", align = "start", sideOffset = 8, open, onOpenChange, asAnchor = false, onOpenAutoFocus, onCloseAutoFocus, showArrow = false, className, ...rest }) => {
|
|
2616
|
-
return (jsxs(Popover$1.Root, { open: open, onOpenChange: onOpenChange, ...rest, children: [asAnchor ? (jsx(Popover$1.Anchor, { asChild: true, children: trigger })) : (jsx(Popover$1.Trigger, { asChild: true, children: trigger })), jsx(Popover$1.Portal, { children: jsxs(Popover$1.Content, { className: clsx(styles$
|
|
2616
|
+
return (jsxs(Popover$1.Root, { open: open, onOpenChange: onOpenChange, ...rest, children: [asAnchor ? (jsx(Popover$1.Anchor, { asChild: true, children: trigger })) : (jsx(Popover$1.Trigger, { asChild: true, children: trigger })), jsx(Popover$1.Portal, { children: jsxs(Popover$1.Content, { className: clsx(styles$l.Content, className), sideOffset: sideOffset, side: side, align: align, onOpenAutoFocus: asAnchor ? (e) => e.preventDefault() : onOpenAutoFocus, onCloseAutoFocus: asAnchor ? (e) => e.preventDefault() : onCloseAutoFocus, onInteractOutside: asAnchor ? (e) => e.preventDefault() : undefined, children: [content, showArrow && jsx(Popover$1.Arrow, {})] }) })] }));
|
|
2617
2617
|
};
|
|
2618
2618
|
|
|
2619
2619
|
function useInputKeyboardValue(externalRef) {
|
|
@@ -2663,10 +2663,15 @@ const LAYOUT_DISPLAY = {
|
|
|
2663
2663
|
|
|
2664
2664
|
const EMOTICON_KEY = '{emoticon}';
|
|
2665
2665
|
const DOWN_KEYBOARD_KEY = '{downkeyboard}';
|
|
2666
|
+
const ENTER_KEY = '{enter}';
|
|
2666
2667
|
const removeKeyFromLayout = (layout, key) => Object.fromEntries(Object.entries(layout).map(([layoutName, rows]) => [
|
|
2667
2668
|
layoutName,
|
|
2668
2669
|
rows.map((row) => row.split(key).join(' ').replace(/\s+/g, ' ').trim()),
|
|
2669
2670
|
]));
|
|
2671
|
+
const replaceKeyWithBlank = (layout, key) => Object.fromEntries(Object.entries(layout).map(([layoutName, rows]) => [
|
|
2672
|
+
layoutName,
|
|
2673
|
+
rows.map((row) => row.split(key).join('{//}')),
|
|
2674
|
+
]));
|
|
2670
2675
|
const QWERTY_LOWERCASE = [
|
|
2671
2676
|
'1 2 3 4 5 6 7 8 9 0',
|
|
2672
2677
|
'q w e r t y u i o p',
|
|
@@ -2724,7 +2729,7 @@ const NATIVE_LAYOUTS = {
|
|
|
2724
2729
|
const NATIVE_LAYOUT_KEYS = new Set([
|
|
2725
2730
|
'default', 'numeric',
|
|
2726
2731
|
]);
|
|
2727
|
-
const getNativeLayout = (type, Emoji = true, showDownKeyboardButton = true, isFixed = false) => {
|
|
2732
|
+
const getNativeLayout = (type, Emoji = true, showDownKeyboardButton = true, isFixed = false, showEnterKey = true, showTypeSwitchKey = true) => {
|
|
2728
2733
|
const layout = NATIVE_LAYOUTS[type] ?? NATIVE_LAYOUTS.default ?? null;
|
|
2729
2734
|
if (!layout)
|
|
2730
2735
|
return null;
|
|
@@ -2735,6 +2740,13 @@ const getNativeLayout = (type, Emoji = true, showDownKeyboardButton = true, isFi
|
|
|
2735
2740
|
if (!showDownKeyboardButton) {
|
|
2736
2741
|
computedLayout = removeKeyFromLayout(computedLayout, DOWN_KEYBOARD_KEY);
|
|
2737
2742
|
}
|
|
2743
|
+
if (!showEnterKey) {
|
|
2744
|
+
computedLayout = removeKeyFromLayout(computedLayout, ENTER_KEY);
|
|
2745
|
+
}
|
|
2746
|
+
if (!showTypeSwitchKey) {
|
|
2747
|
+
computedLayout = removeKeyFromLayout(computedLayout, '{numbers}');
|
|
2748
|
+
computedLayout = replaceKeyWithBlank(computedLayout, '{abc}');
|
|
2749
|
+
}
|
|
2738
2750
|
if (isFixed) {
|
|
2739
2751
|
computedLayout = Object.fromEntries(Object.entries(computedLayout).map(([layoutName, rows]) => [
|
|
2740
2752
|
layoutName,
|
|
@@ -2760,7 +2772,7 @@ const SHIFT_TOGGLES = {
|
|
|
2760
2772
|
alt2: 'alt',
|
|
2761
2773
|
};
|
|
2762
2774
|
|
|
2763
|
-
var styles$
|
|
2775
|
+
var styles$k = {"container":"VirtualKeyboard-module__container___A-e0I","layout--numeric":"VirtualKeyboard-module__layout--numeric___zfd7G","mode--fixed":"VirtualKeyboard-module__mode--fixed___1eFY1","layout--default":"VirtualKeyboard-module__layout--default___qyY1b","textFieldContainer":"VirtualKeyboard-module__textFieldContainer___XxGen","keyboardWrapper":"VirtualKeyboard-module__keyboardWrapper___jryTf","keyboardNumpadActive":"VirtualKeyboard-module__keyboardNumpadActive___jPpJD","overlay":"VirtualKeyboard-module__overlay___a5y7i","overlayOpen":"VirtualKeyboard-module__overlayOpen___hREu-","textFieldWrapper":"VirtualKeyboard-module__textFieldWrapper___bmi-z","keyPreview":"VirtualKeyboard-module__keyPreview___oWaO1","accentMenu":"VirtualKeyboard-module__accentMenu___A6tTy","accentMenuRow":"VirtualKeyboard-module__accentMenuRow___3kbvT","accentOption":"VirtualKeyboard-module__accentOption___ao-Ta"};
|
|
2764
2776
|
|
|
2765
2777
|
const LONG_PRESS_DELAY_MS = 400;
|
|
2766
2778
|
const ACCENT_OPTIONS = {
|
|
@@ -2800,12 +2812,12 @@ const ACCENT_OPTIONS = {
|
|
|
2800
2812
|
* <VirtualKeyboard targetRef={inputRef} value={value} onChange={setValue} />
|
|
2801
2813
|
* ```
|
|
2802
2814
|
*/
|
|
2803
|
-
const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onChange, onKeyPress, maxLength, Emoji = false, className, id, textFieldPlaceholder = 'Digite aqui...', helperText, error, errorMessage, targetRef, }) => {
|
|
2815
|
+
const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onChange, onKeyPress, onTypeChange, maxLength, Emoji = false, className, id, textFieldPlaceholder = 'Digite aqui...', helperText, error, errorMessage, targetRef, textFieldScale = 1, showEnterKey = true, showTypeSwitchKey = true, }) => {
|
|
2804
2816
|
const [layoutName, setLayoutName] = useState('default');
|
|
2805
2817
|
const [capsLockOn, setCapsLockOn] = useState(false);
|
|
2806
2818
|
const [accentMenu, setAccentMenu] = useState(null);
|
|
2807
2819
|
const [accentMenuOffsetX, setAccentMenuOffsetX] = useState(0);
|
|
2808
|
-
const [activeLayout, setActiveLayout] = useState(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed'));
|
|
2820
|
+
const [activeLayout, setActiveLayout] = useState(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed', showEnterKey, showTypeSwitchKey));
|
|
2809
2821
|
const visualType = NATIVE_LAYOUT_KEYS.has(type) ? type : 'default';
|
|
2810
2822
|
const [isOpen, setIsOpen] = useState(variant !== 'native');
|
|
2811
2823
|
const hideTimeoutRef = useRef(null);
|
|
@@ -2844,6 +2856,9 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
2844
2856
|
useEffect(() => {
|
|
2845
2857
|
syncKeyboardInput(value);
|
|
2846
2858
|
}, [value, syncKeyboardInput]);
|
|
2859
|
+
useEffect(() => {
|
|
2860
|
+
onTypeChange?.(type);
|
|
2861
|
+
}, [type, onTypeChange]);
|
|
2847
2862
|
const scheduleHideIfBlurred = useCallback(() => {
|
|
2848
2863
|
if (variant !== 'native')
|
|
2849
2864
|
return;
|
|
@@ -2918,8 +2933,8 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
2918
2933
|
useEffect(() => {
|
|
2919
2934
|
setLayoutName('default');
|
|
2920
2935
|
setCapsLockOn(false);
|
|
2921
|
-
setActiveLayout(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed'));
|
|
2922
|
-
}, [type, Emoji, variant]);
|
|
2936
|
+
setActiveLayout(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed', showEnterKey, showTypeSwitchKey));
|
|
2937
|
+
}, [type, Emoji, variant, showEnterKey, showTypeSwitchKey]);
|
|
2923
2938
|
useEffect(() => {
|
|
2924
2939
|
if (!Emoji && layoutName === 'emoticon') {
|
|
2925
2940
|
setLayoutName(type === 'numeric' ? 'abc' : 'default');
|
|
@@ -3161,10 +3176,12 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3161
3176
|
}
|
|
3162
3177
|
if (button === '{numbers}') {
|
|
3163
3178
|
setLayoutName('numbers');
|
|
3179
|
+
onTypeChange?.('numeric');
|
|
3164
3180
|
return;
|
|
3165
3181
|
}
|
|
3166
3182
|
if (button === '{abc}') {
|
|
3167
3183
|
setLayoutName(baseLayout);
|
|
3184
|
+
onTypeChange?.('default');
|
|
3168
3185
|
return;
|
|
3169
3186
|
}
|
|
3170
3187
|
if (button === '{alt}' || button === '{altright}') {
|
|
@@ -3219,6 +3236,7 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3219
3236
|
layoutName,
|
|
3220
3237
|
capsLockOn,
|
|
3221
3238
|
onKeyPress,
|
|
3239
|
+
onTypeChange,
|
|
3222
3240
|
Emoji,
|
|
3223
3241
|
variant,
|
|
3224
3242
|
closeAccentMenu,
|
|
@@ -3269,7 +3287,7 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3269
3287
|
'{bksp}': (baseDisplay['{bksp}'] ?? '').replace(/\s*Apagar$/, ''),
|
|
3270
3288
|
};
|
|
3271
3289
|
}, [visualType, variant]);
|
|
3272
|
-
const keyboardEl = activeLayout ? (jsxs("div", { ref: keyboardWrapperRef, className: styles$
|
|
3290
|
+
const keyboardEl = activeLayout ? (jsxs("div", { ref: keyboardWrapperRef, className: clsx(styles$k.keyboardWrapper, ((type === 'numeric' && layoutName === 'default') || layoutName === 'numbers' || type === 'default') && styles$k.keyboardNumpadActive), onPointerDownCapture: handleLongPressStart, onPointerUpCapture: handleLongPressEnd, onPointerLeave: handleLongPressEnd, onPointerCancelCapture: handleLongPressEnd, children: [jsx(Keyboard, { keyboardRef: (instance) => {
|
|
3273
3291
|
keyboardInstanceRef.current = instance;
|
|
3274
3292
|
if (instance) {
|
|
3275
3293
|
instance.setInput(valueRef.current);
|
|
@@ -3288,17 +3306,17 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3288
3306
|
}
|
|
3289
3307
|
return createPortal(createElement(Icon), slot, `icon-${key}`);
|
|
3290
3308
|
});
|
|
3291
|
-
})(), keyPreview && typeof document !== 'undefined' && createPortal(jsx("div", { ref: keyPreviewRef, className: styles$
|
|
3309
|
+
})(), keyPreview && typeof document !== 'undefined' && createPortal(jsx("div", { ref: keyPreviewRef, className: styles$k.keyPreview, style: {
|
|
3292
3310
|
top: keyPreview.top,
|
|
3293
3311
|
left: keyPreview.left + keyPreviewOffsetX,
|
|
3294
3312
|
width: portalSizes.preview,
|
|
3295
3313
|
height: portalSizes.preview,
|
|
3296
3314
|
...(portalSizes.fontSize ? { fontSize: portalSizes.fontSize } : {}),
|
|
3297
3315
|
}, "aria-hidden": true, children: keyPreview.char }), document.body), accentMenu && (typeof document !== 'undefined' &&
|
|
3298
|
-
createPortal(jsx("div", { ref: accentMenuRef, className: styles$
|
|
3316
|
+
createPortal(jsx("div", { ref: accentMenuRef, className: styles$k.accentMenu, style: {
|
|
3299
3317
|
top: accentMenu.top,
|
|
3300
3318
|
left: accentMenu.left + accentMenuOffsetX,
|
|
3301
|
-
}, role: "listbox", "aria-label": `Opcoes de acento para ${accentMenu.sourceKey}`, children: Array.from({ length: Math.ceil(accentMenu.options.length / 5) }, (_, rowIndex) => accentMenu.options.slice(rowIndex * 5, rowIndex * 5 + 5)).map((rowOptions, rowIndex) => (jsx("div", { className: styles$
|
|
3319
|
+
}, role: "listbox", "aria-label": `Opcoes de acento para ${accentMenu.sourceKey}`, children: Array.from({ length: Math.ceil(accentMenu.options.length / 5) }, (_, rowIndex) => accentMenu.options.slice(rowIndex * 5, rowIndex * 5 + 5)).map((rowOptions, rowIndex) => (jsx("div", { className: styles$k.accentMenuRow, children: rowOptions.map((option) => (jsx("button", { type: "button", className: styles$k.accentOption, style: {
|
|
3302
3320
|
minWidth: portalSizes.option,
|
|
3303
3321
|
height: portalSizes.option,
|
|
3304
3322
|
...(portalSizes.fontSize ? { fontSize: portalSizes.fontSize } : {}),
|
|
@@ -3307,12 +3325,12 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3307
3325
|
event.stopPropagation();
|
|
3308
3326
|
}, onClick: () => handleAccentSelect(option), children: option }, `${accentMenu.sourceKey}-${option}`))) }, rowIndex))) }), document.body))] })) : null;
|
|
3309
3327
|
if (variant === 'native' && typeof document !== 'undefined') {
|
|
3310
|
-
return createPortal(jsx("div", { id: id, className: clsx(styles$
|
|
3328
|
+
return createPortal(jsx("div", { id: id, className: clsx(styles$k.overlay, { [styles$k.overlayOpen]: isOpen }, styles$k[`layout--${visualType}`], className), children: keyboardEl }), document.body);
|
|
3311
3329
|
}
|
|
3312
|
-
return (jsxs("div", { id: id, className: clsx(styles$
|
|
3330
|
+
return (jsxs("div", { id: id, className: clsx(styles$k.container, styles$k[`mode--${variant}`], styles$k[`layout--${visualType}`], className), children: [variant === 'fixed' && (jsx("div", { className: styles$k.textFieldContainer, children: jsx(TextField$1, { placeholder: textFieldPlaceholder, value: value, onChange: onChange, helperText: helperText, error: error, errorMessage: errorMessage, readOnly: true, disableAutoComplete: true, maxLength: maxLength, attachedToVirtualKeyboard: true, className: styles$k.textFieldWrapper, scale: textFieldScale }) })), keyboardEl] }));
|
|
3313
3331
|
};
|
|
3314
3332
|
|
|
3315
|
-
var styles$
|
|
3333
|
+
var styles$j = {"container":"TextField-module__container___WJHFR","inputWrapper":"TextField-module__inputWrapper___INjfd","inputContainer":"TextField-module__inputContainer___3EsFJ","icon":"TextField-module__icon___p1vwi","clearButton":"TextField-module__clearButton___kgOot","inputWithIcon":"TextField-module__inputWithIcon___shqkL","helperText":"TextField-module__helperText___d5QGC","error":"TextField-module__error___IGQzp","disabled":"TextField-module__disabled___roIKP","attachedToVirtualKeyboard":"TextField-module__attachedToVirtualKeyboard___fuO2O","errorWithMessage":"TextField-module__errorWithMessage___m-5AA","clearButtonIcon":"TextField-module__clearButtonIcon___Z2iyc"};
|
|
3316
3334
|
|
|
3317
3335
|
const validateInput = ({ value, maxLength, errorMessage, required }) => {
|
|
3318
3336
|
if (required && value.trim() === '') {
|
|
@@ -3324,14 +3342,14 @@ const validateInput = ({ value, maxLength, errorMessage, required }) => {
|
|
|
3324
3342
|
return '';
|
|
3325
3343
|
};
|
|
3326
3344
|
|
|
3327
|
-
var styles$
|
|
3345
|
+
var styles$i = {"labelContainer":"index-module__labelContainer___WGyDF","wrapperLabel":"index-module__wrapperLabel___XJzZO","requiredLabel":"index-module__requiredLabel___7oZkh","infoIcon":"index-module__infoIcon___lClx4","errorIcon":"index-module__errorIcon___yN-lq","disabledIcon":"index-module__disabledIcon___89Os7","errorLabel":"index-module__errorLabel___qa6h6","disabledLabel":"index-module__disabledLabel___U9vL8","disabledContainer":"index-module__disabledContainer___MtOvy"};
|
|
3328
3346
|
|
|
3329
3347
|
const LabelComponent = ({ children, htmlFor, required = false, tooltip = false, tooltipText, side = 'bottom', align = 'start', className, error = false, disabled = false, scale = 1, }) => {
|
|
3330
3348
|
const containerStyle = {
|
|
3331
3349
|
'--giro-scale': scale,
|
|
3332
3350
|
};
|
|
3333
|
-
const container = (jsxs("div", { className: clsx(styles$
|
|
3334
|
-
styles$
|
|
3351
|
+
const container = (jsxs("div", { className: clsx(styles$i.labelContainer, disabled && styles$i.disabledContainer), style: containerStyle, children: [jsxs(Label.Root, { className: clsx(styles$i.wrapperLabel, error && !disabled && styles$i.errorLabel, disabled && styles$i.disabledLabel, className), htmlFor: htmlFor, children: [children, required && jsx("span", { className: styles$i.requiredLabel, children: "*" })] }), tooltip && (jsx("span", { className: disabled ? styles$i.disabledIcon : error ?
|
|
3352
|
+
styles$i.errorIcon : styles$i.infoIcon, children: jsx(Info12Regular, {}) }))] }));
|
|
3335
3353
|
if (tooltip) {
|
|
3336
3354
|
return (jsx(Tooltip, { side: side, align: align, text: tooltipText || '', children: container }));
|
|
3337
3355
|
}
|
|
@@ -3399,19 +3417,19 @@ const TextField = forwardRef(({ className, style, value, label, placeholder, typ
|
|
|
3399
3417
|
? `${componentId}-helper`
|
|
3400
3418
|
: undefined;
|
|
3401
3419
|
const containerStyle = { '--giro-scale': scale };
|
|
3402
|
-
const containerClass = clsx(styles$
|
|
3403
|
-
[styles$
|
|
3404
|
-
[styles$
|
|
3405
|
-
[styles$
|
|
3406
|
-
[styles$
|
|
3420
|
+
const containerClass = clsx(styles$j.container, {
|
|
3421
|
+
[styles$j.attachedToVirtualKeyboard]: attachedToVirtualKeyboard,
|
|
3422
|
+
[styles$j.disabled]: disabled,
|
|
3423
|
+
[styles$j.error]: error,
|
|
3424
|
+
[styles$j.errorWithMessage]: !!errorMessage,
|
|
3407
3425
|
[className]: className,
|
|
3408
3426
|
});
|
|
3409
|
-
return (jsxs("div", { className: containerClass, style: { ...containerStyle, ...style }, children: [label && (jsx(LabelComponent, { scale: scale, htmlFor: componentId, required: required, tooltip: tooltip, tooltipText: tooltipText, side: tooltipSide, align: tooltipAlign, error: hasError, disabled: disabled, children: label })), jsxs("div", { className: styles$
|
|
3410
|
-
[styles$
|
|
3411
|
-
}) }), showCustomIcon && jsx("span", { className: styles$
|
|
3427
|
+
return (jsxs("div", { className: containerClass, style: { ...containerStyle, ...style }, children: [label && (jsx(LabelComponent, { scale: scale, htmlFor: componentId, required: required, tooltip: tooltip, tooltipText: tooltipText, side: tooltipSide, align: tooltipAlign, error: hasError, disabled: disabled, children: label })), jsxs("div", { className: styles$j.inputWrapper, children: [jsxs("div", { className: styles$j.inputContainer, children: [jsx("input", { ...rest, ref: setInputRefs, id: componentId, name: name, type: type, value: inputValue, placeholder: placeholder, onChange: handleChange, onFocus: handleFocus, onBlur: handleBlur, maxLength: maxLength, disabled: disabled, "aria-invalid": hasError, "aria-required": required, "aria-describedby": helperId, inputMode: (virtualKeyboard === 'default' || virtualKeyboard === 'numeric') ? 'none' : rest.inputMode, autoComplete: (disableAutoComplete || virtualKeyboard === 'default' || virtualKeyboard === 'numeric') ? 'off' : rest.autoComplete, className: clsx({
|
|
3428
|
+
[styles$j.inputWithIcon]: showCustomIcon || showClearIcon,
|
|
3429
|
+
}) }), showCustomIcon && jsx("span", { className: styles$j.icon, children: icon }), showClearIcon && (jsx("button", { type: "button", className: styles$j.clearButton, onMouseDown: (e) => {
|
|
3412
3430
|
e.preventDefault();
|
|
3413
3431
|
handleClear();
|
|
3414
|
-
}, "aria-label": "Limpar campo", tabIndex: -1, children: jsx("span", { className: styles$
|
|
3432
|
+
}, "aria-label": "Limpar campo", tabIndex: -1, children: jsx("span", { className: styles$j.clearButtonIcon, children: jsx(Dismiss16Regular, {}) }) }))] }), ((error && errorMessage) || inputError || helperText) && (jsx("span", { id: helperId, className: styles$j.helperText, "aria-live": hasError ? 'polite' : undefined, children: displayHelperText }))] }), (virtualKeyboard === 'default' || virtualKeyboard === 'numeric') && (jsx("div", { className: "virtualKeyboardWrapper", children: jsx(VirtualKeyboard, { variant: "native", type: virtualKeyboard, value: inputValue, maxLength: maxLength, targetRef: inputRef, onChange: (val) => {
|
|
3415
3433
|
if (!disabled && (!maxLength || val.length <= maxLength)) {
|
|
3416
3434
|
setInputValue(val);
|
|
3417
3435
|
onChange?.(val);
|
|
@@ -3421,7 +3439,7 @@ const TextField = forwardRef(({ className, style, value, label, placeholder, typ
|
|
|
3421
3439
|
TextField.displayName = 'TextField';
|
|
3422
3440
|
var TextField$1 = React__default.memo(TextField);
|
|
3423
3441
|
|
|
3424
|
-
var styles$
|
|
3442
|
+
var styles$h = {"datePicker":"DatePicker-module__datePicker___raJYg","textfieldContainer":"DatePicker-module__textfieldContainer___yy8pT","datePickerIcon":"DatePicker-module__datePickerIcon___XCZsn","datePickerIconDisabled":"DatePicker-module__datePickerIconDisabled___BB-Gx"};
|
|
3425
3443
|
|
|
3426
3444
|
function formatDate(date, locale = 'pt-br') {
|
|
3427
3445
|
if (!date || !(date instanceof Date)) {
|
|
@@ -3643,7 +3661,7 @@ const DatePicker = ({ locale = 'pt-br', calendarSide = 'bottom', calendarAlign =
|
|
|
3643
3661
|
}
|
|
3644
3662
|
}
|
|
3645
3663
|
};
|
|
3646
|
-
return (jsx("div", { ref: wrapperRef, className: clsx(styles$
|
|
3664
|
+
return (jsx("div", { ref: wrapperRef, className: clsx(styles$h.datePicker, className), style: { ...containerStyle, ...style }, ...rest, children: jsx(Popover, { open: showCalendar, onOpenChange: setShowCalendar, asAnchor: true, trigger: jsx(TextField$1, { className: styles$h.textfieldContainer, type: "tel", icon: jsx(Calendar16Regular, { onClick: !disabled ? handleIconClick : undefined, className: clsx(styles$h.datePickerIcon, disabled && styles$h.datePickerIconDisabled) }), onChange: (e) => {
|
|
3647
3665
|
handleTextFieldChange(String(e));
|
|
3648
3666
|
}, onKeyDown: handleKeyDown, onFocus: handleFocus, persistIcon: true, autoComplete: "off", value: displayValue, helperText: !externalError ? (helperText || undefined) : undefined, errorMessage: externalError ? combinedHelperText : undefined, error: hasValidationError ? true : undefined, maxLength: 10, required: required, label: label, disabled: disabled, scale: scale, id: fieldId, "data-testid": testId, placeholder: locale === 'en-us' ? 'MM/DD/YYYY' : 'DD/MM/YYYY', "aria-label": "Open calendar", "aria-expanded": showCalendar, "aria-controls": calendarId, "aria-invalid": hasValidationError, "aria-describedby": externalError ? undefined : (helperText ? `${fieldId}-help` : undefined) }), content: jsx(Calendar, { selected: currentSelectedDate, currentDate: currentDate, onDateChange: setCurrentDate, onDaySelect: handleDaySelect, locale: locale, format: locale === 'en-us' ? 'mm/dd/yyyy' : 'dd/mm/yyyy', minDate: minDate, maxDate: maxDate, scale: scale, id: calendarId, onClear: () => {
|
|
3649
3667
|
handleDateChange(null);
|
|
@@ -3652,11 +3670,11 @@ const DatePicker = ({ locale = 'pt-br', calendarSide = 'bottom', calendarAlign =
|
|
|
3652
3670
|
};
|
|
3653
3671
|
var DatePicker_default = React__default.memo(DatePicker);
|
|
3654
3672
|
|
|
3655
|
-
var styles$
|
|
3673
|
+
var styles$g = {"DialogOverlay":"Dialog-module__DialogOverlay___LEX2O","DialogContent":"Dialog-module__DialogContent___ziVXb","DialogTitle":"Dialog-module__DialogTitle___ay1tD","DialogDescription":"Dialog-module__DialogDescription___odslw","DivButtons":"Dialog-module__DivButtons___BiwX-"};
|
|
3656
3674
|
|
|
3657
|
-
const Dialog = ({ show = false, title, bodyContent, textPrimaryAction, textSecondaryAction, onPrimaryAction, onSecondaryAction, className, ...rest }) => (jsx(AlertDialog.Root, { open: show, ...rest, children: jsxs(AlertDialog.Portal, { children: [jsx(AlertDialog.Overlay, { className: styles$
|
|
3675
|
+
const Dialog = ({ show = false, title, bodyContent, textPrimaryAction, textSecondaryAction, onPrimaryAction, onSecondaryAction, className, ...rest }) => (jsx(AlertDialog.Root, { open: show, ...rest, children: jsxs(AlertDialog.Portal, { children: [jsx(AlertDialog.Overlay, { className: styles$g.DialogOverlay }), jsxs(AlertDialog.Content, { className: clsx(styles$g.DialogContent, className), children: [jsx(AlertDialog.Title, { className: styles$g.DialogTitle, children: title }), jsx(AlertDialog.Description, { className: styles$g.DialogDescription, children: bodyContent }), jsxs("div", { className: styles$g.DivButtons, children: [!!(textSecondaryAction && textSecondaryAction.trim()) && (jsx(AlertDialog.Cancel, { asChild: true, children: jsx(Button, { variant: "outlined", ...(onSecondaryAction && { onClick: onSecondaryAction }), children: textSecondaryAction }) })), jsx(AlertDialog.Action, { asChild: true, children: jsx(Button, { variant: "filled", ...(onPrimaryAction && { onClick: onPrimaryAction }), children: textPrimaryAction }) })] })] })] }) }));
|
|
3658
3676
|
|
|
3659
|
-
var styles$
|
|
3677
|
+
var styles$f = {"drawerShadow":"Drawer-module__drawerShadow___0Z6iL","drawerShadow--visible":"Drawer-module__drawerShadow--visible___FspoH","drawerSidebar":"Drawer-module__drawerSidebar___cdyyb","drawerSidebar--open":"Drawer-module__drawerSidebar--open___ee2-Y","drawerSidebar--disabled":"Drawer-module__drawerSidebar--disabled___MYrBI","drawerTitleClose":"Drawer-module__drawerTitleClose___QzqN-","drawerTitle":"Drawer-module__drawerTitle___naMX0","drawerChildren":"Drawer-module__drawerChildren___xGdg9","drawerHeaderContent":"Drawer-module__drawerHeaderContent___NLSwj"};
|
|
3660
3678
|
|
|
3661
3679
|
const Drawer = ({ children, headerContent, footer, customWidth = '400px', onClose, title = 'Título', isOpen = false, onOpen, className, id, disabled = false, onOverlayClick, closeOnOverlayClick = true, closeOnEscape = true, ...rest }) => {
|
|
3662
3680
|
const internalClose = useCallback(() => {
|
|
@@ -3705,15 +3723,185 @@ const Drawer = ({ children, headerContent, footer, customWidth = '400px', onClos
|
|
|
3705
3723
|
event.stopPropagation();
|
|
3706
3724
|
internalClose();
|
|
3707
3725
|
};
|
|
3708
|
-
return createPortal(jsxs(Fragment, { children: [jsx("div", { className: clsx(styles$
|
|
3709
|
-
[styles$
|
|
3710
|
-
}), onClick: handleOverlayClick, role: "presentation", "aria-hidden": "true", "data-testid": "drawer-overlay" }), jsxs("div", { className: clsx(styles$
|
|
3711
|
-
[styles$
|
|
3712
|
-
[styles$
|
|
3726
|
+
return createPortal(jsxs(Fragment, { children: [jsx("div", { className: clsx(styles$f['drawerShadow'], {
|
|
3727
|
+
[styles$f['drawerShadow--visible']]: isOpen,
|
|
3728
|
+
}), onClick: handleOverlayClick, role: "presentation", "aria-hidden": "true", "data-testid": "drawer-overlay" }), jsxs("div", { className: clsx(styles$f['drawerSidebar'], {
|
|
3729
|
+
[styles$f['drawerSidebar--open']]: isOpen,
|
|
3730
|
+
[styles$f['drawerSidebar--disabled']]: disabled,
|
|
3713
3731
|
}, className), style: {
|
|
3714
3732
|
'--drawer-custom-width': customWidth,
|
|
3715
|
-
}, onClick: handleDrawerClick, role: "dialog", "aria-modal": "true", "aria-labelledby": id ? `${id}-title` : 'drawer-title', "aria-hidden": !isOpen, "data-testid": "drawer-panel", id: id, ...rest, children: [jsxs("div", { className: styles$
|
|
3733
|
+
}, onClick: handleDrawerClick, role: "dialog", "aria-modal": "true", "aria-labelledby": id ? `${id}-title` : 'drawer-title', "aria-hidden": !isOpen, "data-testid": "drawer-panel", id: id, ...rest, children: [jsxs("div", { className: styles$f.drawerTitleClose, children: [jsx("div", { className: styles$f.drawerTitle, id: id ? `${id}-title` : 'drawer-title', children: title }), headerContent && (jsx("div", { className: styles$f.drawerHeaderContent, children: headerContent })), jsx(Button, { onClick: handleCloseClick, variant: 'outlined', iconOnly: true, icon: jsx(Dismiss16Regular, {}), size: 'lg', tooltipText: 'Fechar' })] }), jsx("div", { className: styles$f.drawerChildren, "data-testid": "drawer-content", children: children }), footer] })] }), document.body);
|
|
3734
|
+
};
|
|
3735
|
+
|
|
3736
|
+
var styles$e = {"container":"FileUpload-module__container___hFeKV","dropZone":"FileUpload-module__dropZone___716hF","disabled":"FileUpload-module__disabled___mwePo","alert":"FileUpload-module__alert___Dnzqc","dragging":"FileUpload-module__dragging___XZghy","emptyState":"FileUpload-module__emptyState___6Ll9D","uploadIcon":"FileUpload-module__uploadIcon___MkBLe","uploadText":"FileUpload-module__uploadText___VWc9g","alertIcon":"FileUpload-module__alertIcon___pTaMS","alertText":"FileUpload-module__alertText___sfV4z","fileList":"FileUpload-module__fileList___K6KQD","thumb":"FileUpload-module__thumb___eg59D","removeButton":"FileUpload-module__removeButton___jUFNv","thumbClip":"FileUpload-module__thumbClip___sP9wp","thumbImage":"FileUpload-module__thumbImage___Swxhd","thumbFile":"FileUpload-module__thumbFile___y7lg5","thumbFileName":"FileUpload-module__thumbFileName___LPSCX","helperText":"FileUpload-module__helperText___DzPqP","errorText":"FileUpload-module__errorText___cHd1Z"};
|
|
3737
|
+
|
|
3738
|
+
const truncateFileName = (fileName, maxChars = 18) => {
|
|
3739
|
+
if (fileName.length <= maxChars)
|
|
3740
|
+
return fileName;
|
|
3741
|
+
const lastDot = fileName.lastIndexOf('.');
|
|
3742
|
+
const hasExtension = lastDot > 0 && lastDot < fileName.length - 1;
|
|
3743
|
+
const baseName = hasExtension ? fileName.substring(0, lastDot) : fileName;
|
|
3744
|
+
const extension = hasExtension ? fileName.substring(lastDot) : '';
|
|
3745
|
+
const reserved = 3 + extension.length; // "..."
|
|
3746
|
+
const available = maxChars - reserved;
|
|
3747
|
+
if (available <= 1) {
|
|
3748
|
+
return fileName.substring(0, maxChars - 3) + '...';
|
|
3749
|
+
}
|
|
3750
|
+
return baseName.substring(0, available) + '...' + extension;
|
|
3751
|
+
};
|
|
3752
|
+
const matchesAccept = (file, accept) => {
|
|
3753
|
+
if (!accept)
|
|
3754
|
+
return true;
|
|
3755
|
+
const types = accept.split(',').map((t) => t.trim().toLowerCase());
|
|
3756
|
+
const fileName = file.name.toLowerCase();
|
|
3757
|
+
const fileType = file.type.toLowerCase();
|
|
3758
|
+
return types.some((type) => {
|
|
3759
|
+
if (type.startsWith('.')) {
|
|
3760
|
+
return fileName.endsWith(type);
|
|
3761
|
+
}
|
|
3762
|
+
if (type.endsWith('/*')) {
|
|
3763
|
+
return fileType.startsWith(type.slice(0, -1));
|
|
3764
|
+
}
|
|
3765
|
+
return fileType === type;
|
|
3766
|
+
});
|
|
3716
3767
|
};
|
|
3768
|
+
const FileUpload = forwardRef(({ value, onChange, helperText, error = false, errorMessage, maxFileSize, maxFilesQuantity, disabled = false, className, id, accept, multiple = true, description = 'Clique ou arraste os arquivos aqui', descriptionErrorMessage = 'Falha ao subir um ou mais arquivos.', ...rest }, ref) => {
|
|
3769
|
+
const generatedId = useId();
|
|
3770
|
+
const componentId = id || generatedId;
|
|
3771
|
+
const helperId = `${componentId}-helper`;
|
|
3772
|
+
const listId = `${componentId}-list`;
|
|
3773
|
+
const inputRef = useRef(null);
|
|
3774
|
+
const [internalFiles, setInternalFiles] = useState([]);
|
|
3775
|
+
const [isDragging, setIsDragging] = useState(false);
|
|
3776
|
+
const [objectUrls, setObjectUrls] = useState(new Map());
|
|
3777
|
+
const [internalError, setInternalError] = useState(null);
|
|
3778
|
+
const isControlled = value !== undefined;
|
|
3779
|
+
const files = isControlled ? value : internalFiles;
|
|
3780
|
+
useEffect(() => {
|
|
3781
|
+
return () => {
|
|
3782
|
+
objectUrls.forEach((url) => URL.revokeObjectURL(url));
|
|
3783
|
+
};
|
|
3784
|
+
}, [objectUrls]);
|
|
3785
|
+
const getObjectUrl = useCallback((file) => {
|
|
3786
|
+
const key = `${file.name}-${file.size}`;
|
|
3787
|
+
const existing = objectUrls.get(key);
|
|
3788
|
+
if (existing)
|
|
3789
|
+
return existing;
|
|
3790
|
+
const url = URL.createObjectURL(file);
|
|
3791
|
+
setObjectUrls((prev) => new Map(prev).set(key, url));
|
|
3792
|
+
return url;
|
|
3793
|
+
}, [objectUrls]);
|
|
3794
|
+
const revokeUrl = useCallback((file) => {
|
|
3795
|
+
const key = `${file.name}-${file.size}`;
|
|
3796
|
+
setObjectUrls((prev) => {
|
|
3797
|
+
const next = new Map(prev);
|
|
3798
|
+
const url = next.get(key);
|
|
3799
|
+
if (url)
|
|
3800
|
+
URL.revokeObjectURL(url);
|
|
3801
|
+
next.delete(key);
|
|
3802
|
+
return next;
|
|
3803
|
+
});
|
|
3804
|
+
}, []);
|
|
3805
|
+
const processFiles = useCallback((incoming) => {
|
|
3806
|
+
if (disabled)
|
|
3807
|
+
return;
|
|
3808
|
+
const all = Array.from(incoming);
|
|
3809
|
+
const validFiles = all.filter((file) => {
|
|
3810
|
+
if (maxFileSize && file.size > maxFileSize)
|
|
3811
|
+
return false;
|
|
3812
|
+
if (!matchesAccept(file, accept))
|
|
3813
|
+
return false;
|
|
3814
|
+
return true;
|
|
3815
|
+
});
|
|
3816
|
+
const merged = multiple
|
|
3817
|
+
? [...files, ...validFiles]
|
|
3818
|
+
: validFiles.slice(0, 1);
|
|
3819
|
+
const limited = maxFilesQuantity && multiple ? merged.slice(0, maxFilesQuantity) : merged;
|
|
3820
|
+
// Prioridade de erro: tipo > tamanho > quantidade
|
|
3821
|
+
const hasTypeError = all.some((file) => !matchesAccept(file, accept));
|
|
3822
|
+
const hasSizeError = all.some((file) => maxFileSize && file.size > maxFileSize);
|
|
3823
|
+
const hasQuantityError = maxFilesQuantity && multiple && merged.length > maxFilesQuantity;
|
|
3824
|
+
if (hasTypeError && hasSizeError) {
|
|
3825
|
+
setInternalError('Um ou mais arquivos possuem tipo ou tamanho inválido.');
|
|
3826
|
+
}
|
|
3827
|
+
else if (hasTypeError) {
|
|
3828
|
+
setInternalError('Um ou mais arquivos não são do tipo aceito.');
|
|
3829
|
+
}
|
|
3830
|
+
else if (hasSizeError) {
|
|
3831
|
+
setInternalError('Um ou mais arquivos excedem o tamanho máximo permitido.');
|
|
3832
|
+
}
|
|
3833
|
+
else if (hasQuantityError) {
|
|
3834
|
+
setInternalError(`Não é possível adicionar mais de ${maxFilesQuantity} arquivo(s).`);
|
|
3835
|
+
}
|
|
3836
|
+
else {
|
|
3837
|
+
setInternalError(null);
|
|
3838
|
+
}
|
|
3839
|
+
if (!isControlled)
|
|
3840
|
+
setInternalFiles(limited);
|
|
3841
|
+
onChange?.(limited);
|
|
3842
|
+
}, [disabled, files, isControlled, maxFilesQuantity, maxFileSize, multiple, onChange, accept]);
|
|
3843
|
+
const handleInputChange = useCallback((e) => {
|
|
3844
|
+
if (e.target.files) {
|
|
3845
|
+
processFiles(e.target.files);
|
|
3846
|
+
e.target.value = '';
|
|
3847
|
+
}
|
|
3848
|
+
}, [processFiles]);
|
|
3849
|
+
const handleClick = useCallback(() => {
|
|
3850
|
+
if (!disabled)
|
|
3851
|
+
inputRef.current?.click();
|
|
3852
|
+
}, [disabled]);
|
|
3853
|
+
const handleKeyDown = useCallback((e) => {
|
|
3854
|
+
if (!disabled && (e.key === 'Enter' || e.key === ' ')) {
|
|
3855
|
+
e.preventDefault();
|
|
3856
|
+
inputRef.current?.click();
|
|
3857
|
+
}
|
|
3858
|
+
}, [disabled]);
|
|
3859
|
+
const handleDragOver = useCallback((e) => {
|
|
3860
|
+
e.preventDefault();
|
|
3861
|
+
if (!disabled)
|
|
3862
|
+
setIsDragging(true);
|
|
3863
|
+
}, [disabled]);
|
|
3864
|
+
const handleDragLeave = useCallback((e) => {
|
|
3865
|
+
e.preventDefault();
|
|
3866
|
+
setIsDragging(false);
|
|
3867
|
+
}, []);
|
|
3868
|
+
const handleDrop = useCallback((e) => {
|
|
3869
|
+
e.preventDefault();
|
|
3870
|
+
setIsDragging(false);
|
|
3871
|
+
if (!disabled && e.dataTransfer.files.length > 0) {
|
|
3872
|
+
processFiles(e.dataTransfer.files);
|
|
3873
|
+
}
|
|
3874
|
+
}, [disabled, processFiles]);
|
|
3875
|
+
const handleRemove = useCallback((e, index) => {
|
|
3876
|
+
e.stopPropagation();
|
|
3877
|
+
const removed = files[index];
|
|
3878
|
+
revokeUrl(removed);
|
|
3879
|
+
const updated = files.filter((_, i) => i !== index);
|
|
3880
|
+
if (!isControlled)
|
|
3881
|
+
setInternalFiles(updated);
|
|
3882
|
+
onChange?.(updated);
|
|
3883
|
+
}, [files, isControlled, onChange, revokeUrl]);
|
|
3884
|
+
const hasFiles = files.length > 0;
|
|
3885
|
+
const isError = error || !!errorMessage || !!internalError;
|
|
3886
|
+
const displayedHelper = isError ? errorMessage || internalError || helperText : helperText;
|
|
3887
|
+
const setRefs = useCallback((node) => {
|
|
3888
|
+
inputRef.current = node;
|
|
3889
|
+
if (typeof ref === 'function')
|
|
3890
|
+
ref(node);
|
|
3891
|
+
else if (ref)
|
|
3892
|
+
ref.current = node;
|
|
3893
|
+
}, [ref]);
|
|
3894
|
+
return (jsxs("div", { id: componentId, className: clsx(styles$e.container, className), children: [jsx("input", { ref: setRefs, type: "file", accept: accept, multiple: multiple, disabled: disabled, "aria-hidden": "true", tabIndex: -1, style: { display: 'none' }, onChange: handleInputChange, ...rest }), jsxs("div", { role: "button", tabIndex: disabled ? -1 : 0, "aria-label": description, "aria-disabled": disabled, "aria-describedby": displayedHelper ? helperId : undefined, "aria-controls": hasFiles ? listId : undefined, "data-invalid": isError || undefined, className: clsx(styles$e.dropZone, isDragging && styles$e.dragging, isError && styles$e.alert, disabled && styles$e.disabled), onClick: handleClick, onKeyDown: handleKeyDown, onDragOver: handleDragOver, onDragLeave: handleDragLeave, onDrop: handleDrop, children: [!hasFiles && !isError && (jsxs("div", { className: styles$e.emptyState, "aria-hidden": "true", children: [jsx("span", { className: styles$e.uploadIcon, children: jsx(DocumentAdd24Regular, {}) }), jsx("span", { className: styles$e.uploadText, children: description })] })), !hasFiles && isError && (jsxs("div", { className: styles$e.emptyState, "aria-hidden": "true", children: [jsx("span", { className: styles$e.alertIcon, children: jsx(Warning24Regular, {}) }), descriptionErrorMessage && (jsx("span", { className: styles$e.alertText, children: descriptionErrorMessage }))] })), hasFiles && (jsx("ul", { id: listId, className: styles$e.fileList, "aria-label": `${files.length} arquivo${files.length !== 1 ? 's' : ''} selecionado${files.length !== 1 ? 's' : ''}`, "aria-live": "polite", children: files.map((file, index) => {
|
|
3895
|
+
const isImage = file.type.startsWith('image/');
|
|
3896
|
+
return (jsxs("li", { className: styles$e.thumb, children: [jsx("div", { className: styles$e.thumbClip, children: isImage ? (jsx("img", { src: getObjectUrl(file), alt: file.name, title: file.name, className: styles$e.thumbImage })) : (jsxs("div", { className: styles$e.thumbFile, "aria-hidden": "true", title: file.name, children: [jsx(Document24Regular, {}), jsx("span", { className: styles$e.thumbFileName, children: truncateFileName(file.name) })] })) }), jsx("button", { type: "button", className: styles$e.removeButton, "aria-label": `Remover ${file.name}`, disabled: disabled, onClick: (e) => handleRemove(e, index), onKeyDown: (e) => {
|
|
3897
|
+
if (e.key === 'Enter' || e.key === ' ') {
|
|
3898
|
+
e.preventDefault();
|
|
3899
|
+
handleRemove(e, index);
|
|
3900
|
+
}
|
|
3901
|
+
}, children: jsx(Dismiss16Regular, { "aria-hidden": "true" }) })] }, `${file.name}-${index}`));
|
|
3902
|
+
}) }))] }), displayedHelper && (jsx("span", { id: helperId, role: isError ? 'alert' : undefined, className: clsx(styles$e.helperText, isError && styles$e.errorText), children: displayedHelper }))] }));
|
|
3903
|
+
});
|
|
3904
|
+
FileUpload.displayName = 'FileUpload';
|
|
3717
3905
|
|
|
3718
3906
|
var styles$d = {"container":"Filter-module__container___cqntK","panel":"Filter-module__panel___19HqD","search":"Filter-module__search___f0gzj","list":"Filter-module__list___UpBk1","item":"Filter-module__item___oNdeY","itemSelected":"Filter-module__itemSelected___JIpJV","itemText":"Filter-module__itemText___RS--0","itemDisabled":"Filter-module__itemDisabled___X-ktg","itemIcon":"Filter-module__itemIcon___RjJSa","noResults":"Filter-module__noResults___3m6pn","footer":"Filter-module__footer___yYS5j","buttonContent":"Filter-module__buttonContent___28fKe","buttonArrow":"Filter-module__buttonArrow___VJlpc","buttonIcon":"Filter-module__buttonIcon___OOBpZ","triggerWrapper":"Filter-module__triggerWrapper___ptPRL","triggerContent":"Filter-module__triggerContent___LYo9j","body":"Filter-module__body___qsyhk","combinedFooter":"Filter-module__combinedFooter___kTnHP"};
|
|
3719
3907
|
|
|
@@ -4288,9 +4476,9 @@ const Menu = ({ items, children, onItemSelect, search, enableInfiniteScroll, onS
|
|
|
4288
4476
|
}, ...rest, children: [search && (jsx("div", { className: styles$9.searchWrapper, children: jsx(Search, { placeholder: "Buscar", onChange: handleSearchChange, value: searchInput, onKeyDown: handleSearchKeyDown }) })), jsxs("div", { className: styles$9.itemsWrapper, ref: itemsWrapperRef, style: { maxHeight: maxHeightStyle }, children: [filteredItems.length > 0 ? (filteredItems.map((item, index) => renderMenuItem(item, item.value || item.text || `item-${index}`))) : (jsx("div", { className: styles$9.emptyState, children: "Nenhum item encontrado" })), enableInfiniteScroll && isLoadingMore && (jsx("div", { className: styles$9.loadingMore, children: "Carregando mais itens..." })), enableInfiniteScroll && (jsx("div", { ref: sentinelRef, "data-scroll-sentinel": true, style: { height: '1px', visibility: 'hidden' } }))] })] }) })] }));
|
|
4289
4477
|
};
|
|
4290
4478
|
|
|
4291
|
-
var styles$8 = {"modalOverlay":"Modal-module__modalOverlay___rI8Wz","modalContent":"Modal-module__modalContent___6Cgb1","modalContent--fullscreen":"Modal-module__modalContent--fullscreen___QeBlG","modalHeader":"Modal-module__modalHeader___IuHIg","modalTitle":"Modal-module__modalTitle___9VDmr","modalBody":"Modal-module__modalBody___ohjQm"};
|
|
4479
|
+
var styles$8 = {"modalOverlay":"Modal-module__modalOverlay___rI8Wz","modalContent":"Modal-module__modalContent___6Cgb1","modalContent--fullscreen":"Modal-module__modalContent--fullscreen___QeBlG","modalHeader":"Modal-module__modalHeader___IuHIg","modalTitle":"Modal-module__modalTitle___9VDmr","modalBody":"Modal-module__modalBody___ohjQm","modalFooter":"Modal-module__modalFooter___TEqdK"};
|
|
4292
4480
|
|
|
4293
|
-
const Modal = ({ isOpen = false, onClose, title, children, headerContent, closeOnOverlayClick = true, className, id, footer, customWidth, fullscreen = false, ...rest }) => {
|
|
4481
|
+
const Modal = ({ isOpen = false, onClose, title, children, headerContent, closeOnOverlayClick = true, className, id, footer, customWidth, customHeight, fullscreen = false, ...rest }) => {
|
|
4294
4482
|
const contentRef = React.useRef(null);
|
|
4295
4483
|
const handleOpenChange = (open) => {
|
|
4296
4484
|
if (!open) {
|
|
@@ -4303,7 +4491,8 @@ const Modal = ({ isOpen = false, onClose, title, children, headerContent, closeO
|
|
|
4303
4491
|
};
|
|
4304
4492
|
return (jsx(Dialog$1.Root, { open: isOpen, onOpenChange: handleOpenChange, ...rest, children: jsxs(Dialog$1.Portal, { children: [jsx(Dialog$1.Overlay, { className: styles$8.modalOverlay }), jsxs(Dialog$1.Content, { ref: contentRef, className: clsx(styles$8.modalContent, fullscreen && styles$8['modalContent--fullscreen'], className), id: id, style: {
|
|
4305
4493
|
'--modal-custom-width': customWidth,
|
|
4306
|
-
|
|
4494
|
+
'--modal-custom-height': customHeight,
|
|
4495
|
+
}, onInteractOutside: !closeOnOverlayClick ? (e) => e.preventDefault() : undefined, onOpenAutoFocus: handleOpenAutoFocus, "aria-labelledby": id ? `${id}-title` : 'modal-title', tabIndex: -1, children: [jsxs("header", { className: styles$8.modalHeader, children: [title && (jsx(Dialog$1.Title, { className: styles$8.modalTitle, id: id ? `${id}-title` : 'modal-title', children: title })), headerContent && (jsx("div", { children: headerContent })), jsx(Dialog$1.Close, { asChild: true, children: jsx(Button, { variant: "outlined", iconOnly: true, icon: jsx(Dismiss16Regular, {}), size: "lg", tooltipText: 'Fechar' }) })] }), jsx("section", { className: styles$8.modalBody, children: children }), footer && (jsx("footer", { className: styles$8.modalFooter, children: footer }))] })] }) }));
|
|
4307
4496
|
};
|
|
4308
4497
|
|
|
4309
4498
|
var styles$7 = {"quantity":"Quantity-module__quantity___-vndR","quantityInput":"Quantity-module__quantityInput___xZG-v","disabled":"Quantity-module__disabled___X6p5l"};
|
|
@@ -5614,123 +5803,11 @@ const Switch = ({ disabled = false, defaultChecked = false, checked, onCheckedCh
|
|
|
5614
5803
|
return (jsx("div", { className: clsx(styles$1.container, className), style: { '--giro-scale': scale, ...style }, children: jsx(Switch$1.Root, { className: styles$1.switchRoot, disabled: disabled, defaultChecked: defaultChecked, checked: checked, onCheckedChange: onCheckedChange, ...rest, children: jsx(Switch$1.Thumb, { className: styles$1.switchThumb }) }) }));
|
|
5615
5804
|
};
|
|
5616
5805
|
|
|
5617
|
-
var styles = {"
|
|
5806
|
+
var styles = {"container":"VerificationCode-module__container___5Kxo6","inputGroup":"VerificationCode-module__inputGroup___ose3E","input":"VerificationCode-module__input___Vu-jM","inputError":"VerificationCode-module__inputError___gI-Bl","inputDisabled":"VerificationCode-module__inputDisabled___wUj2Y","errorMessage":"VerificationCode-module__errorMessage___NnYtO"};
|
|
5618
5807
|
|
|
5619
|
-
|
|
5620
|
-
* Mapa de regex para validação dos tipos de entrada
|
|
5621
|
-
*/
|
|
5622
|
-
const REGEX_MAP = {
|
|
5623
|
-
numeric: /^[0-9]$/,
|
|
5624
|
-
alpha: /^[a-zA-Z]$/,
|
|
5625
|
-
alphanumeric: /^[a-zA-Z0-9]$/,
|
|
5626
|
-
};
|
|
5627
|
-
/**
|
|
5628
|
-
* Componente VerificationCode para entrada de códigos de verificação
|
|
5629
|
-
*
|
|
5630
|
-
* @description Permite entrada de códigos com múltiplos dígitos,
|
|
5631
|
-
* suportando diferentes tipos de caracteres e navegação por teclado.
|
|
5632
|
-
*
|
|
5633
|
-
* @example
|
|
5634
|
-
* ```tsx
|
|
5635
|
-
* <VerificationCode
|
|
5636
|
-
* length={6}
|
|
5637
|
-
* inputType="numeric"
|
|
5638
|
-
* onComplete={(code) => console.log('Código:', code)}
|
|
5639
|
-
* hasError={false}
|
|
5640
|
-
* />
|
|
5641
|
-
* ```
|
|
5642
|
-
*/
|
|
5643
|
-
const VerificationCode = ({ length = 6, inputType = 'numeric', onComplete, hasError = false, errorMessage, disabled = false, className, ...rest }) => {
|
|
5808
|
+
const VerificationCode = ({ length = 6, validationType = 'numeric', value, defaultValue, onValueChange, autoSubmit = false, onAutoSubmit, name, form, hasError = false, errorMessage, disabled = false, readOnly = false, className, id, }) => {
|
|
5644
5809
|
const validLength = Math.min(Math.max(length, 1), 100);
|
|
5645
|
-
|
|
5646
|
-
const inputsRef = useRef([]);
|
|
5647
|
-
const currentRegex = REGEX_MAP[inputType] || REGEX_MAP.numeric;
|
|
5648
|
-
useEffect(() => {
|
|
5649
|
-
setValues(Array(validLength).fill(''));
|
|
5650
|
-
}, [inputType, validLength]);
|
|
5651
|
-
const handleChange = useCallback((index, value) => {
|
|
5652
|
-
if (!currentRegex.test(value))
|
|
5653
|
-
return;
|
|
5654
|
-
const newValues = [...values];
|
|
5655
|
-
newValues[index] = value;
|
|
5656
|
-
setValues(newValues);
|
|
5657
|
-
if (value && index < validLength - 1) {
|
|
5658
|
-
inputsRef.current[index + 1]?.focus();
|
|
5659
|
-
}
|
|
5660
|
-
if (newValues.every(v => v !== '')) {
|
|
5661
|
-
onComplete?.(newValues.join(''));
|
|
5662
|
-
}
|
|
5663
|
-
}, [values, currentRegex, onComplete, validLength]);
|
|
5664
|
-
const handlePaste = useCallback((e) => {
|
|
5665
|
-
e.preventDefault();
|
|
5666
|
-
const pasteData = e.clipboardData.getData('Text');
|
|
5667
|
-
const valuesToPaste = pasteData.split('').slice(0, validLength);
|
|
5668
|
-
const newValues = [...values];
|
|
5669
|
-
valuesToPaste.forEach((value, index) => {
|
|
5670
|
-
if (currentRegex.test(value)) {
|
|
5671
|
-
newValues[index] = value;
|
|
5672
|
-
}
|
|
5673
|
-
});
|
|
5674
|
-
setValues(newValues);
|
|
5675
|
-
const firstEmptyIndex = newValues.findIndex(v => v === '');
|
|
5676
|
-
const focusIndex = firstEmptyIndex === -1 ? validLength - 1 : firstEmptyIndex;
|
|
5677
|
-
inputsRef.current[focusIndex]?.focus();
|
|
5678
|
-
if (newValues.every(v => v !== '')) {
|
|
5679
|
-
onComplete?.(newValues.join(''));
|
|
5680
|
-
}
|
|
5681
|
-
}, [values, currentRegex, onComplete, validLength]);
|
|
5682
|
-
const handleKeyDown = useCallback((index, e) => {
|
|
5683
|
-
if (e.key === 'Backspace') {
|
|
5684
|
-
e.preventDefault();
|
|
5685
|
-
const newValues = [...values];
|
|
5686
|
-
if (values[index]) {
|
|
5687
|
-
newValues[index] = '';
|
|
5688
|
-
setValues(newValues);
|
|
5689
|
-
}
|
|
5690
|
-
else if (index > 0) {
|
|
5691
|
-
inputsRef.current[index - 1]?.focus();
|
|
5692
|
-
newValues[index - 1] = '';
|
|
5693
|
-
setValues(newValues);
|
|
5694
|
-
}
|
|
5695
|
-
}
|
|
5696
|
-
if (e.key === 'Delete') {
|
|
5697
|
-
e.preventDefault();
|
|
5698
|
-
const newValues = [...values];
|
|
5699
|
-
newValues[index] = '';
|
|
5700
|
-
setValues(newValues);
|
|
5701
|
-
if (index < validLength - 1) {
|
|
5702
|
-
inputsRef.current[index + 1]?.focus();
|
|
5703
|
-
}
|
|
5704
|
-
}
|
|
5705
|
-
if (e.key === 'ArrowLeft' && index > 0) {
|
|
5706
|
-
e.preventDefault();
|
|
5707
|
-
inputsRef.current[index - 1]?.focus();
|
|
5708
|
-
}
|
|
5709
|
-
if (e.key === 'ArrowRight' && index < validLength - 1) {
|
|
5710
|
-
e.preventDefault();
|
|
5711
|
-
inputsRef.current[index + 1]?.focus();
|
|
5712
|
-
}
|
|
5713
|
-
}, [values, validLength]);
|
|
5714
|
-
const handleKeyUp = useCallback((index, e) => {
|
|
5715
|
-
if (e.key === 'Enter') {
|
|
5716
|
-
e.preventDefault();
|
|
5717
|
-
if (values[index] && index < validLength - 1) {
|
|
5718
|
-
inputsRef.current[index + 1]?.focus();
|
|
5719
|
-
}
|
|
5720
|
-
else if (values[index] && index === validLength - 1) {
|
|
5721
|
-
inputsRef.current[index]?.blur();
|
|
5722
|
-
}
|
|
5723
|
-
}
|
|
5724
|
-
}, [values, validLength]);
|
|
5725
|
-
const handleFocus = useCallback((e) => {
|
|
5726
|
-
e.target.select();
|
|
5727
|
-
}, []);
|
|
5728
|
-
return (jsxs(Fragment, { children: [jsx("div", { className: clsx(styles['zds-verification-code__container'], className), ...rest, children: values.map((val, i) => (jsx("input", { id: `zds-verification-code__element-${i}`, ref: (el) => {
|
|
5729
|
-
inputsRef.current[i] = el;
|
|
5730
|
-
}, type: "text", inputMode: inputType === 'numeric' ? 'numeric' : 'text', maxLength: 1, value: val, onChange: (e) => handleChange(i, e.target.value), onKeyDown: (e) => handleKeyDown(i, e), onKeyUp: (e) => handleKeyUp(i, e), onPaste: i === 0 ? handlePaste : undefined, onFocus: handleFocus, disabled: disabled, className: clsx(styles['zds-verification-code__input'], {
|
|
5731
|
-
[styles['zds-verification-code__has-error']]: hasError,
|
|
5732
|
-
[styles['zds-verification-code__filled']]: val,
|
|
5733
|
-
}), "aria-invalid": hasError, "aria-label": `Dígito ${i + 1} de ${validLength}`, "aria-describedby": hasError && errorMessage ? 'verification-code-error' : undefined, autoComplete: "one-time-code" }, i))) }), hasError && errorMessage && (jsx("div", { id: "verification-code-error", className: styles['zds-verification-code__error'], role: "alert", "aria-live": "assertive", children: errorMessage }))] }));
|
|
5810
|
+
return (jsxs("div", { id: id, className: clsx(styles.container, className), children: [jsxs(unstable_OneTimePasswordField.Root, { className: styles.inputGroup, validationType: validationType, value: value, defaultValue: defaultValue, onValueChange: onValueChange, autoSubmit: autoSubmit, onAutoSubmit: onAutoSubmit, name: name, form: form, disabled: disabled, readOnly: readOnly, "data-error": hasError || undefined, children: [Array.from({ length: validLength }, (_, i) => (jsx(unstable_OneTimePasswordField.Input, { className: clsx(styles.input, hasError && styles.inputError, disabled && styles.inputDisabled) }, i))), jsx(unstable_OneTimePasswordField.HiddenInput, {})] }), hasError && errorMessage && (jsx("span", { className: styles.errorMessage, children: errorMessage }))] }));
|
|
5734
5811
|
};
|
|
5735
5812
|
|
|
5736
5813
|
function useApiSimulation(config = {}) {
|
|
@@ -6028,5 +6105,5 @@ function useInfiniteScroll({ status, page, lastPage, onLoadMore, threshold = 0.1
|
|
|
6028
6105
|
};
|
|
6029
6106
|
}
|
|
6030
6107
|
|
|
6031
|
-
export { Avatar, Badge, Button, Calendar, Callout, Card, Checkbox, MemoizedChips as Chips, Container, DatePicker_default as DatePicker, Dialog, Drawer, Filter, ListItem, Menu, Modal, Popover, memorizedQuantity as Quantity, Radio, Search, Select, Switch, Table, TableHeader, TablePagination, TableV2, TextArea_default as TextArea, TextField$1 as TextField, Toast, ToastContainer, ToastProvider, Tooltip, VerificationCode, VirtualKeyboard, normalizeText, useApiSimulation, useInfiniteScroll, useToast };
|
|
6108
|
+
export { Avatar, Badge, Button, Calendar, Callout, Card, Checkbox, MemoizedChips as Chips, Container, DatePicker_default as DatePicker, Dialog, Drawer, FileUpload, Filter, ListItem, Menu, Modal, Popover, memorizedQuantity as Quantity, Radio, Search, Select, Switch, Table, TableHeader, TablePagination, TableV2, TextArea_default as TextArea, TextField$1 as TextField, Toast, ToastContainer, ToastProvider, Tooltip, VerificationCode, VirtualKeyboard, normalizeText, useApiSimulation, useInfiniteScroll, useToast };
|
|
6032
6109
|
//# sourceMappingURL=index.esm.js.map
|