@giro-ds/react 11.1.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 +279 -205
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +80 -32
- package/dist/index.esm.js +281 -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) {
|
|
@@ -2668,6 +2668,10 @@ const removeKeyFromLayout = (layout, key) => Object.fromEntries(Object.entries(l
|
|
|
2668
2668
|
layoutName,
|
|
2669
2669
|
rows.map((row) => row.split(key).join(' ').replace(/\s+/g, ' ').trim()),
|
|
2670
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
|
+
]));
|
|
2671
2675
|
const QWERTY_LOWERCASE = [
|
|
2672
2676
|
'1 2 3 4 5 6 7 8 9 0',
|
|
2673
2677
|
'q w e r t y u i o p',
|
|
@@ -2725,7 +2729,7 @@ const NATIVE_LAYOUTS = {
|
|
|
2725
2729
|
const NATIVE_LAYOUT_KEYS = new Set([
|
|
2726
2730
|
'default', 'numeric',
|
|
2727
2731
|
]);
|
|
2728
|
-
const getNativeLayout = (type, Emoji = true, showDownKeyboardButton = true, isFixed = false, showEnterKey = true) => {
|
|
2732
|
+
const getNativeLayout = (type, Emoji = true, showDownKeyboardButton = true, isFixed = false, showEnterKey = true, showTypeSwitchKey = true) => {
|
|
2729
2733
|
const layout = NATIVE_LAYOUTS[type] ?? NATIVE_LAYOUTS.default ?? null;
|
|
2730
2734
|
if (!layout)
|
|
2731
2735
|
return null;
|
|
@@ -2739,6 +2743,10 @@ const getNativeLayout = (type, Emoji = true, showDownKeyboardButton = true, isFi
|
|
|
2739
2743
|
if (!showEnterKey) {
|
|
2740
2744
|
computedLayout = removeKeyFromLayout(computedLayout, ENTER_KEY);
|
|
2741
2745
|
}
|
|
2746
|
+
if (!showTypeSwitchKey) {
|
|
2747
|
+
computedLayout = removeKeyFromLayout(computedLayout, '{numbers}');
|
|
2748
|
+
computedLayout = replaceKeyWithBlank(computedLayout, '{abc}');
|
|
2749
|
+
}
|
|
2742
2750
|
if (isFixed) {
|
|
2743
2751
|
computedLayout = Object.fromEntries(Object.entries(computedLayout).map(([layoutName, rows]) => [
|
|
2744
2752
|
layoutName,
|
|
@@ -2764,7 +2772,7 @@ const SHIFT_TOGGLES = {
|
|
|
2764
2772
|
alt2: 'alt',
|
|
2765
2773
|
};
|
|
2766
2774
|
|
|
2767
|
-
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"};
|
|
2768
2776
|
|
|
2769
2777
|
const LONG_PRESS_DELAY_MS = 400;
|
|
2770
2778
|
const ACCENT_OPTIONS = {
|
|
@@ -2804,12 +2812,12 @@ const ACCENT_OPTIONS = {
|
|
|
2804
2812
|
* <VirtualKeyboard targetRef={inputRef} value={value} onChange={setValue} />
|
|
2805
2813
|
* ```
|
|
2806
2814
|
*/
|
|
2807
|
-
const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onChange, onKeyPress, maxLength, Emoji = false, className, id, textFieldPlaceholder = 'Digite aqui...', helperText, error, errorMessage, targetRef, textFieldScale = 1, showEnterKey = true, }) => {
|
|
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, }) => {
|
|
2808
2816
|
const [layoutName, setLayoutName] = useState('default');
|
|
2809
2817
|
const [capsLockOn, setCapsLockOn] = useState(false);
|
|
2810
2818
|
const [accentMenu, setAccentMenu] = useState(null);
|
|
2811
2819
|
const [accentMenuOffsetX, setAccentMenuOffsetX] = useState(0);
|
|
2812
|
-
const [activeLayout, setActiveLayout] = useState(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed', showEnterKey));
|
|
2820
|
+
const [activeLayout, setActiveLayout] = useState(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed', showEnterKey, showTypeSwitchKey));
|
|
2813
2821
|
const visualType = NATIVE_LAYOUT_KEYS.has(type) ? type : 'default';
|
|
2814
2822
|
const [isOpen, setIsOpen] = useState(variant !== 'native');
|
|
2815
2823
|
const hideTimeoutRef = useRef(null);
|
|
@@ -2848,6 +2856,9 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
2848
2856
|
useEffect(() => {
|
|
2849
2857
|
syncKeyboardInput(value);
|
|
2850
2858
|
}, [value, syncKeyboardInput]);
|
|
2859
|
+
useEffect(() => {
|
|
2860
|
+
onTypeChange?.(type);
|
|
2861
|
+
}, [type, onTypeChange]);
|
|
2851
2862
|
const scheduleHideIfBlurred = useCallback(() => {
|
|
2852
2863
|
if (variant !== 'native')
|
|
2853
2864
|
return;
|
|
@@ -2922,8 +2933,8 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
2922
2933
|
useEffect(() => {
|
|
2923
2934
|
setLayoutName('default');
|
|
2924
2935
|
setCapsLockOn(false);
|
|
2925
|
-
setActiveLayout(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed', showEnterKey));
|
|
2926
|
-
}, [type, Emoji, variant, showEnterKey]);
|
|
2936
|
+
setActiveLayout(getNativeLayout(type, Emoji, variant === 'native', variant === 'fixed', showEnterKey, showTypeSwitchKey));
|
|
2937
|
+
}, [type, Emoji, variant, showEnterKey, showTypeSwitchKey]);
|
|
2927
2938
|
useEffect(() => {
|
|
2928
2939
|
if (!Emoji && layoutName === 'emoticon') {
|
|
2929
2940
|
setLayoutName(type === 'numeric' ? 'abc' : 'default');
|
|
@@ -3165,10 +3176,12 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3165
3176
|
}
|
|
3166
3177
|
if (button === '{numbers}') {
|
|
3167
3178
|
setLayoutName('numbers');
|
|
3179
|
+
onTypeChange?.('numeric');
|
|
3168
3180
|
return;
|
|
3169
3181
|
}
|
|
3170
3182
|
if (button === '{abc}') {
|
|
3171
3183
|
setLayoutName(baseLayout);
|
|
3184
|
+
onTypeChange?.('default');
|
|
3172
3185
|
return;
|
|
3173
3186
|
}
|
|
3174
3187
|
if (button === '{alt}' || button === '{altright}') {
|
|
@@ -3223,6 +3236,7 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3223
3236
|
layoutName,
|
|
3224
3237
|
capsLockOn,
|
|
3225
3238
|
onKeyPress,
|
|
3239
|
+
onTypeChange,
|
|
3226
3240
|
Emoji,
|
|
3227
3241
|
variant,
|
|
3228
3242
|
closeAccentMenu,
|
|
@@ -3273,7 +3287,7 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3273
3287
|
'{bksp}': (baseDisplay['{bksp}'] ?? '').replace(/\s*Apagar$/, ''),
|
|
3274
3288
|
};
|
|
3275
3289
|
}, [visualType, variant]);
|
|
3276
|
-
const keyboardEl = activeLayout ? (jsxs("div", { ref: keyboardWrapperRef, className: clsx(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) => {
|
|
3277
3291
|
keyboardInstanceRef.current = instance;
|
|
3278
3292
|
if (instance) {
|
|
3279
3293
|
instance.setInput(valueRef.current);
|
|
@@ -3292,17 +3306,17 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3292
3306
|
}
|
|
3293
3307
|
return createPortal(createElement(Icon), slot, `icon-${key}`);
|
|
3294
3308
|
});
|
|
3295
|
-
})(), 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: {
|
|
3296
3310
|
top: keyPreview.top,
|
|
3297
3311
|
left: keyPreview.left + keyPreviewOffsetX,
|
|
3298
3312
|
width: portalSizes.preview,
|
|
3299
3313
|
height: portalSizes.preview,
|
|
3300
3314
|
...(portalSizes.fontSize ? { fontSize: portalSizes.fontSize } : {}),
|
|
3301
3315
|
}, "aria-hidden": true, children: keyPreview.char }), document.body), accentMenu && (typeof document !== 'undefined' &&
|
|
3302
|
-
createPortal(jsx("div", { ref: accentMenuRef, className: styles$
|
|
3316
|
+
createPortal(jsx("div", { ref: accentMenuRef, className: styles$k.accentMenu, style: {
|
|
3303
3317
|
top: accentMenu.top,
|
|
3304
3318
|
left: accentMenu.left + accentMenuOffsetX,
|
|
3305
|
-
}, 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: {
|
|
3306
3320
|
minWidth: portalSizes.option,
|
|
3307
3321
|
height: portalSizes.option,
|
|
3308
3322
|
...(portalSizes.fontSize ? { fontSize: portalSizes.fontSize } : {}),
|
|
@@ -3311,12 +3325,12 @@ const VirtualKeyboard = ({ variant = 'native', type = 'default', value = '', onC
|
|
|
3311
3325
|
event.stopPropagation();
|
|
3312
3326
|
}, onClick: () => handleAccentSelect(option), children: option }, `${accentMenu.sourceKey}-${option}`))) }, rowIndex))) }), document.body))] })) : null;
|
|
3313
3327
|
if (variant === 'native' && typeof document !== 'undefined') {
|
|
3314
|
-
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);
|
|
3315
3329
|
}
|
|
3316
|
-
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] }));
|
|
3317
3331
|
};
|
|
3318
3332
|
|
|
3319
|
-
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"};
|
|
3320
3334
|
|
|
3321
3335
|
const validateInput = ({ value, maxLength, errorMessage, required }) => {
|
|
3322
3336
|
if (required && value.trim() === '') {
|
|
@@ -3328,14 +3342,14 @@ const validateInput = ({ value, maxLength, errorMessage, required }) => {
|
|
|
3328
3342
|
return '';
|
|
3329
3343
|
};
|
|
3330
3344
|
|
|
3331
|
-
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"};
|
|
3332
3346
|
|
|
3333
3347
|
const LabelComponent = ({ children, htmlFor, required = false, tooltip = false, tooltipText, side = 'bottom', align = 'start', className, error = false, disabled = false, scale = 1, }) => {
|
|
3334
3348
|
const containerStyle = {
|
|
3335
3349
|
'--giro-scale': scale,
|
|
3336
3350
|
};
|
|
3337
|
-
const container = (jsxs("div", { className: clsx(styles$
|
|
3338
|
-
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, {}) }))] }));
|
|
3339
3353
|
if (tooltip) {
|
|
3340
3354
|
return (jsx(Tooltip, { side: side, align: align, text: tooltipText || '', children: container }));
|
|
3341
3355
|
}
|
|
@@ -3403,19 +3417,19 @@ const TextField = forwardRef(({ className, style, value, label, placeholder, typ
|
|
|
3403
3417
|
? `${componentId}-helper`
|
|
3404
3418
|
: undefined;
|
|
3405
3419
|
const containerStyle = { '--giro-scale': scale };
|
|
3406
|
-
const containerClass = clsx(styles$
|
|
3407
|
-
[styles$
|
|
3408
|
-
[styles$
|
|
3409
|
-
[styles$
|
|
3410
|
-
[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,
|
|
3411
3425
|
[className]: className,
|
|
3412
3426
|
});
|
|
3413
|
-
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$
|
|
3414
|
-
[styles$
|
|
3415
|
-
}) }), 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) => {
|
|
3416
3430
|
e.preventDefault();
|
|
3417
3431
|
handleClear();
|
|
3418
|
-
}, "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) => {
|
|
3419
3433
|
if (!disabled && (!maxLength || val.length <= maxLength)) {
|
|
3420
3434
|
setInputValue(val);
|
|
3421
3435
|
onChange?.(val);
|
|
@@ -3425,7 +3439,7 @@ const TextField = forwardRef(({ className, style, value, label, placeholder, typ
|
|
|
3425
3439
|
TextField.displayName = 'TextField';
|
|
3426
3440
|
var TextField$1 = React__default.memo(TextField);
|
|
3427
3441
|
|
|
3428
|
-
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"};
|
|
3429
3443
|
|
|
3430
3444
|
function formatDate(date, locale = 'pt-br') {
|
|
3431
3445
|
if (!date || !(date instanceof Date)) {
|
|
@@ -3647,7 +3661,7 @@ const DatePicker = ({ locale = 'pt-br', calendarSide = 'bottom', calendarAlign =
|
|
|
3647
3661
|
}
|
|
3648
3662
|
}
|
|
3649
3663
|
};
|
|
3650
|
-
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) => {
|
|
3651
3665
|
handleTextFieldChange(String(e));
|
|
3652
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: () => {
|
|
3653
3667
|
handleDateChange(null);
|
|
@@ -3656,11 +3670,11 @@ const DatePicker = ({ locale = 'pt-br', calendarSide = 'bottom', calendarAlign =
|
|
|
3656
3670
|
};
|
|
3657
3671
|
var DatePicker_default = React__default.memo(DatePicker);
|
|
3658
3672
|
|
|
3659
|
-
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-"};
|
|
3660
3674
|
|
|
3661
|
-
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 }) })] })] })] }) }));
|
|
3662
3676
|
|
|
3663
|
-
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"};
|
|
3664
3678
|
|
|
3665
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 }) => {
|
|
3666
3680
|
const internalClose = useCallback(() => {
|
|
@@ -3709,15 +3723,185 @@ const Drawer = ({ children, headerContent, footer, customWidth = '400px', onClos
|
|
|
3709
3723
|
event.stopPropagation();
|
|
3710
3724
|
internalClose();
|
|
3711
3725
|
};
|
|
3712
|
-
return createPortal(jsxs(Fragment, { children: [jsx("div", { className: clsx(styles$
|
|
3713
|
-
[styles$
|
|
3714
|
-
}), onClick: handleOverlayClick, role: "presentation", "aria-hidden": "true", "data-testid": "drawer-overlay" }), jsxs("div", { className: clsx(styles$
|
|
3715
|
-
[styles$
|
|
3716
|
-
[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,
|
|
3717
3731
|
}, className), style: {
|
|
3718
3732
|
'--drawer-custom-width': customWidth,
|
|
3719
|
-
}, 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
|
+
});
|
|
3720
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';
|
|
3721
3905
|
|
|
3722
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"};
|
|
3723
3907
|
|
|
@@ -4292,9 +4476,9 @@ const Menu = ({ items, children, onItemSelect, search, enableInfiniteScroll, onS
|
|
|
4292
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' } }))] })] }) })] }));
|
|
4293
4477
|
};
|
|
4294
4478
|
|
|
4295
|
-
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"};
|
|
4296
4480
|
|
|
4297
|
-
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 }) => {
|
|
4298
4482
|
const contentRef = React.useRef(null);
|
|
4299
4483
|
const handleOpenChange = (open) => {
|
|
4300
4484
|
if (!open) {
|
|
@@ -4307,7 +4491,8 @@ const Modal = ({ isOpen = false, onClose, title, children, headerContent, closeO
|
|
|
4307
4491
|
};
|
|
4308
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: {
|
|
4309
4493
|
'--modal-custom-width': customWidth,
|
|
4310
|
-
|
|
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 }))] })] }) }));
|
|
4311
4496
|
};
|
|
4312
4497
|
|
|
4313
4498
|
var styles$7 = {"quantity":"Quantity-module__quantity___-vndR","quantityInput":"Quantity-module__quantityInput___xZG-v","disabled":"Quantity-module__disabled___X6p5l"};
|
|
@@ -5618,123 +5803,11 @@ const Switch = ({ disabled = false, defaultChecked = false, checked, onCheckedCh
|
|
|
5618
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 }) }) }));
|
|
5619
5804
|
};
|
|
5620
5805
|
|
|
5621
|
-
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"};
|
|
5622
5807
|
|
|
5623
|
-
|
|
5624
|
-
* Mapa de regex para validação dos tipos de entrada
|
|
5625
|
-
*/
|
|
5626
|
-
const REGEX_MAP = {
|
|
5627
|
-
numeric: /^[0-9]$/,
|
|
5628
|
-
alpha: /^[a-zA-Z]$/,
|
|
5629
|
-
alphanumeric: /^[a-zA-Z0-9]$/,
|
|
5630
|
-
};
|
|
5631
|
-
/**
|
|
5632
|
-
* Componente VerificationCode para entrada de códigos de verificação
|
|
5633
|
-
*
|
|
5634
|
-
* @description Permite entrada de códigos com múltiplos dígitos,
|
|
5635
|
-
* suportando diferentes tipos de caracteres e navegação por teclado.
|
|
5636
|
-
*
|
|
5637
|
-
* @example
|
|
5638
|
-
* ```tsx
|
|
5639
|
-
* <VerificationCode
|
|
5640
|
-
* length={6}
|
|
5641
|
-
* inputType="numeric"
|
|
5642
|
-
* onComplete={(code) => console.log('Código:', code)}
|
|
5643
|
-
* hasError={false}
|
|
5644
|
-
* />
|
|
5645
|
-
* ```
|
|
5646
|
-
*/
|
|
5647
|
-
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, }) => {
|
|
5648
5809
|
const validLength = Math.min(Math.max(length, 1), 100);
|
|
5649
|
-
|
|
5650
|
-
const inputsRef = useRef([]);
|
|
5651
|
-
const currentRegex = REGEX_MAP[inputType] || REGEX_MAP.numeric;
|
|
5652
|
-
useEffect(() => {
|
|
5653
|
-
setValues(Array(validLength).fill(''));
|
|
5654
|
-
}, [inputType, validLength]);
|
|
5655
|
-
const handleChange = useCallback((index, value) => {
|
|
5656
|
-
if (!currentRegex.test(value))
|
|
5657
|
-
return;
|
|
5658
|
-
const newValues = [...values];
|
|
5659
|
-
newValues[index] = value;
|
|
5660
|
-
setValues(newValues);
|
|
5661
|
-
if (value && index < validLength - 1) {
|
|
5662
|
-
inputsRef.current[index + 1]?.focus();
|
|
5663
|
-
}
|
|
5664
|
-
if (newValues.every(v => v !== '')) {
|
|
5665
|
-
onComplete?.(newValues.join(''));
|
|
5666
|
-
}
|
|
5667
|
-
}, [values, currentRegex, onComplete, validLength]);
|
|
5668
|
-
const handlePaste = useCallback((e) => {
|
|
5669
|
-
e.preventDefault();
|
|
5670
|
-
const pasteData = e.clipboardData.getData('Text');
|
|
5671
|
-
const valuesToPaste = pasteData.split('').slice(0, validLength);
|
|
5672
|
-
const newValues = [...values];
|
|
5673
|
-
valuesToPaste.forEach((value, index) => {
|
|
5674
|
-
if (currentRegex.test(value)) {
|
|
5675
|
-
newValues[index] = value;
|
|
5676
|
-
}
|
|
5677
|
-
});
|
|
5678
|
-
setValues(newValues);
|
|
5679
|
-
const firstEmptyIndex = newValues.findIndex(v => v === '');
|
|
5680
|
-
const focusIndex = firstEmptyIndex === -1 ? validLength - 1 : firstEmptyIndex;
|
|
5681
|
-
inputsRef.current[focusIndex]?.focus();
|
|
5682
|
-
if (newValues.every(v => v !== '')) {
|
|
5683
|
-
onComplete?.(newValues.join(''));
|
|
5684
|
-
}
|
|
5685
|
-
}, [values, currentRegex, onComplete, validLength]);
|
|
5686
|
-
const handleKeyDown = useCallback((index, e) => {
|
|
5687
|
-
if (e.key === 'Backspace') {
|
|
5688
|
-
e.preventDefault();
|
|
5689
|
-
const newValues = [...values];
|
|
5690
|
-
if (values[index]) {
|
|
5691
|
-
newValues[index] = '';
|
|
5692
|
-
setValues(newValues);
|
|
5693
|
-
}
|
|
5694
|
-
else if (index > 0) {
|
|
5695
|
-
inputsRef.current[index - 1]?.focus();
|
|
5696
|
-
newValues[index - 1] = '';
|
|
5697
|
-
setValues(newValues);
|
|
5698
|
-
}
|
|
5699
|
-
}
|
|
5700
|
-
if (e.key === 'Delete') {
|
|
5701
|
-
e.preventDefault();
|
|
5702
|
-
const newValues = [...values];
|
|
5703
|
-
newValues[index] = '';
|
|
5704
|
-
setValues(newValues);
|
|
5705
|
-
if (index < validLength - 1) {
|
|
5706
|
-
inputsRef.current[index + 1]?.focus();
|
|
5707
|
-
}
|
|
5708
|
-
}
|
|
5709
|
-
if (e.key === 'ArrowLeft' && index > 0) {
|
|
5710
|
-
e.preventDefault();
|
|
5711
|
-
inputsRef.current[index - 1]?.focus();
|
|
5712
|
-
}
|
|
5713
|
-
if (e.key === 'ArrowRight' && index < validLength - 1) {
|
|
5714
|
-
e.preventDefault();
|
|
5715
|
-
inputsRef.current[index + 1]?.focus();
|
|
5716
|
-
}
|
|
5717
|
-
}, [values, validLength]);
|
|
5718
|
-
const handleKeyUp = useCallback((index, e) => {
|
|
5719
|
-
if (e.key === 'Enter') {
|
|
5720
|
-
e.preventDefault();
|
|
5721
|
-
if (values[index] && index < validLength - 1) {
|
|
5722
|
-
inputsRef.current[index + 1]?.focus();
|
|
5723
|
-
}
|
|
5724
|
-
else if (values[index] && index === validLength - 1) {
|
|
5725
|
-
inputsRef.current[index]?.blur();
|
|
5726
|
-
}
|
|
5727
|
-
}
|
|
5728
|
-
}, [values, validLength]);
|
|
5729
|
-
const handleFocus = useCallback((e) => {
|
|
5730
|
-
e.target.select();
|
|
5731
|
-
}, []);
|
|
5732
|
-
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) => {
|
|
5733
|
-
inputsRef.current[i] = el;
|
|
5734
|
-
}, 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'], {
|
|
5735
|
-
[styles['zds-verification-code__has-error']]: hasError,
|
|
5736
|
-
[styles['zds-verification-code__filled']]: val,
|
|
5737
|
-
}), "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 }))] }));
|
|
5738
5811
|
};
|
|
5739
5812
|
|
|
5740
5813
|
function useApiSimulation(config = {}) {
|
|
@@ -6032,5 +6105,5 @@ function useInfiniteScroll({ status, page, lastPage, onLoadMore, threshold = 0.1
|
|
|
6032
6105
|
};
|
|
6033
6106
|
}
|
|
6034
6107
|
|
|
6035
|
-
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 };
|
|
6036
6109
|
//# sourceMappingURL=index.esm.js.map
|