@giro-ds/react 11.1.0 → 12.0.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.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import * as React$1 from 'react';
2
2
  import React__default, { ReactNode, ReactElement, RefObject, ComponentPropsWithoutRef, CSSProperties } from 'react';
3
- import * as react_jsx_runtime from 'react/jsx-runtime';
4
- import { Matcher } from 'react-day-picker';
3
+ import { DateRange, Matcher } from 'react-day-picker';
4
+ export { DateRange } from 'react-day-picker';
5
5
  import { RowData, ColumnDef } from '@tanstack/react-table';
6
6
  export { ColumnDef as TableColumnDefinition, createColumnHelper as createTableColumnHelper } from '@tanstack/react-table';
7
7
  import { Toast as Toast$1 } from 'radix-ui';
@@ -56,8 +56,8 @@ interface AvatarProps extends Omit<BaseProps, 'disabled'> {
56
56
  size?: Size;
57
57
  /** URL da imagem do avatar. Quando fornecido, exibe a imagem; caso contrário, mostra o ícone */
58
58
  src?: string;
59
- /** Texto alternativo da imagem do avatar, usado como as iniciais do nome */
60
- initialLetters?: string;
59
+ /** Texto alternativo exibido no fallback (ex.: iniciais). Limitado a no máximo 2 caracteres */
60
+ text?: string;
61
61
  /** Classe CSS opcional */
62
62
  className?: string;
63
63
  }
@@ -94,6 +94,36 @@ interface BadgeProps extends BaseProps {
94
94
 
95
95
  declare const Badge: React__default.FC<BadgeProps>;
96
96
 
97
+ /**
98
+ * Props base compartilhadas por todas as configurações de tooltip do botão.
99
+ */
100
+ interface BaseTooltipConfig$3 {
101
+ /** Lado em que o tooltip será exibido */
102
+ tooltipSide?: 'top' | 'bottom' | 'left' | 'right';
103
+ /** Alinhamento do tooltip */
104
+ tooltipAlign?: 'start' | 'center' | 'end';
105
+ }
106
+ /**
107
+ * Configuração de tooltip com texto.
108
+ * Exibe um tooltip ao redor do botão — útil especialmente para botões icon-only.
109
+ */
110
+ interface WithTooltip$3 extends BaseTooltipConfig$3 {
111
+ /** Texto do tooltip exibido no hover */
112
+ tooltipText: string;
113
+ }
114
+ /**
115
+ * Configuração sem tooltip.
116
+ */
117
+ interface WithoutTooltip$3 {
118
+ tooltipText?: never;
119
+ tooltipSide?: never;
120
+ tooltipAlign?: never;
121
+ }
122
+ /**
123
+ * Union type representando a configuração de tooltip do botão.
124
+ * Pode ter tooltip com texto (e opcionalmente side/align) ou sem tooltip.
125
+ */
126
+ type ButtonTooltipConfig = WithTooltip$3 | WithoutTooltip$3;
97
127
  /**
98
128
  * Props base do Button, independentes da variante iconOnly/icon.
99
129
  * `target`, `rel`, `type` e `onClick` são declarados aqui para garantir
@@ -128,19 +158,13 @@ type ButtonOwnPropsBase = {
128
158
  ariaLabel?: string;
129
159
  /** Estado de carregamento (exibe spinner) */
130
160
  loading?: boolean;
131
- /** Texto do tooltip exibido quando o botão é apenas ícone */
132
- tooltipText?: string;
133
- /** Lado em que o tooltip será exibido */
134
- tooltipSide?: 'top' | 'bottom' | 'left' | 'right';
135
- /** Alinhamento do tooltip */
136
- tooltipAlign?: 'start' | 'center' | 'end';
137
161
  /**
138
162
  * Classe CSS adicional para customização. Use com moderação e prefira as variantes e estilos pré-definidos do design system.
139
163
  */
140
164
  className?: string;
141
165
  /** Handler de clique; tipado em HTMLElement para ser compatível com todos os modos */
142
166
  onClick?: React__default.MouseEventHandler<HTMLElement>;
143
- } & ScalableProps;
167
+ } & ScalableProps & ButtonTooltipConfig;
144
168
  /**
145
169
  * Props próprias do componente Button.
146
170
  * Quando `iconOnly: true`, a prop `icon` é **obrigatória**.
@@ -187,13 +211,25 @@ type ButtonAsCustom = ButtonOwnProps & Omit<React__default.HTMLAttributes<HTMLEl
187
211
  */
188
212
  type ButtonProps = ButtonAsButton | ButtonAsAnchor | ButtonAsCustom;
189
213
 
190
- declare const Button: React__default.ForwardRefExoticComponent<ButtonProps & React__default.RefAttributes<HTMLButtonElement | HTMLAnchorElement>>;
214
+ declare const Button: {
215
+ ({ ref, as, children, variant, iconPosition, href, to, external, target, rel, disabled, onClick, size, scale, className, type, id, icon, fullWidth, ariaLabel, iconOnly, loading, tooltipText, tooltipSide, tooltipAlign, ...rest }: ButtonProps & {
216
+ ref?: React__default.Ref<HTMLButtonElement | HTMLAnchorElement>;
217
+ }): React__default.JSX.Element;
218
+ displayName: string;
219
+ };
191
220
 
192
221
  /** Formato de exibição da data aceito pelo componente. */
193
222
  type DateFormat = 'dd/mm/yyyy' | 'mm/dd/yyyy' | (string & {});
194
223
  interface CalendarBaseProps extends Omit<ScalableProps, 'disabled'> {
195
- /** Data selecionada atualmente (usada pelo DatePicker). */
224
+ /**
225
+ * Modo de seleção de datas.
226
+ * @default 'single'
227
+ */
228
+ mode?: 'single' | 'range';
229
+ /** Data selecionada atualmente (modo `single`). */
196
230
  selected?: Date | null;
231
+ /** Intervalo de datas selecionado (modo `range`). */
232
+ selectedRange?: DateRange | null;
197
233
  /**
198
234
  * Mês exibido no calendário. Use junto com `onDateChange` para
199
235
  * controlar a navegação externamente.
@@ -208,8 +244,15 @@ interface CalendarBaseProps extends Omit<ScalableProps, 'disabled'> {
208
244
  startMonth?: Date;
209
245
  /** Último mês navegável. */
210
246
  endMonth?: Date;
211
- /** Chamado quando o usuário seleciona um dia. */
247
+ /**
248
+ * Quantidade de meses exibidos simultaneamente.
249
+ * @default 1
250
+ */
251
+ numberOfMonths?: number;
252
+ /** Chamado quando o usuário seleciona um dia (modo `single`). */
212
253
  onDaySelect?: (date: Date) => void;
254
+ /** Chamado quando o usuário seleciona um intervalo (modo `range`). */
255
+ onRangeSelect?: (range: DateRange | undefined) => void;
213
256
  /** Chamado quando o usuário navega entre meses. */
214
257
  onDateChange?: (date: Date) => void;
215
258
  /** Chamado quando o usuário limpa a seleção. */
@@ -242,7 +285,7 @@ interface CalendarBaseProps extends Omit<ScalableProps, 'disabled'> {
242
285
  }
243
286
  type CalendarProps = CalendarBaseProps;
244
287
 
245
- declare const Calendar: ({ selected, currentDate, defaultMonth, startMonth, endMonth, onDaySelect, onDateChange, onClear: _onClear, minDate, maxDate, disabled, format: _format, locale, autoFocus, className, style, scale, id, "aria-label": ariaLabel, ...rest }: CalendarProps) => react_jsx_runtime.JSX.Element;
288
+ declare const Calendar: ({ mode, selected, selectedRange, currentDate, defaultMonth, startMonth, endMonth, onDaySelect, onRangeSelect, onDateChange, onClear, minDate, maxDate, disabled, format: _format, locale, autoFocus, numberOfMonths, className, style, scale, id, "aria-label": ariaLabel, ...rest }: CalendarProps) => React$1.JSX.Element;
246
289
 
247
290
  /**
248
291
  * Props do componente Callout
@@ -316,7 +359,7 @@ interface CardProps {
316
359
  hoverable?: boolean;
317
360
  }
318
361
 
319
- declare function Card({ children, className, hoverable }: CardProps): react_jsx_runtime.JSX.Element;
362
+ declare function Card({ children, className, hoverable }: CardProps): React$1.JSX.Element;
320
363
 
321
364
  /**
322
365
  * Props do componente Checkbox
@@ -405,7 +448,7 @@ interface ContainerProps {
405
448
  className?: string;
406
449
  }
407
450
 
408
- declare function Container({ children, className }: ContainerProps): react_jsx_runtime.JSX.Element;
451
+ declare function Container({ children, className }: ContainerProps): React$1.JSX.Element;
409
452
 
410
453
  /**
411
454
  * Props do componente DatePicker
@@ -550,6 +593,46 @@ interface DrawerProps extends BaseProps {
550
593
 
551
594
  declare const Drawer: React__default.FC<DrawerProps>;
552
595
 
596
+ interface FileUploadProps extends Omit<React__default.InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'accept' | 'multiple'> {
597
+ /** Tipos de arquivo aceitos pelo seletor nativo (ex: "image/*", ".pdf,.docx") */
598
+ accept?: string;
599
+ /** Permite selecionar múltiplos arquivos */
600
+ multiple?: boolean;
601
+ /** Lista controlada de arquivos */
602
+ value?: File[];
603
+ /** Callback disparado quando a lista de arquivos muda */
604
+ onChange?: (files: File[]) => void;
605
+ /** Texto auxiliar exibido abaixo da zona de drop */
606
+ helperText?: string;
607
+ /** Sinaliza estado de erro */
608
+ error?: boolean;
609
+ /** Mensagem de erro exibida no helperText quando em estado de erro.
610
+ * Erros internos de tipo (accept), tamanho (maxFileSize) e quantidade (maxFilesQuantity)
611
+ * também preenchem o helperText com mensagens padrão. */
612
+ errorMessage?: string;
613
+ /** Mensagem de erro exibida abaixo do icone de erro, caso não tenha a mensagem não ira aparecer nada */
614
+ descriptionErrorMessage?: string;
615
+ /** Tamanho máximo em bytes por arquivo */
616
+ maxFileSize?: number;
617
+ /** Número máximo de arquivos permitidos (exige multiple=true para mais de 1) */
618
+ maxFilesQuantity?: number;
619
+ /** Quando true, o componente está desabilitado */
620
+ disabled?: boolean;
621
+ /** Classes CSS adicionais */
622
+ className?: string;
623
+ /** Identificador único */
624
+ id?: string;
625
+ /** Texto de instrução exibido na zona vazia */
626
+ description?: string;
627
+ }
628
+
629
+ declare const FileUpload: {
630
+ ({ ref, value, onChange, helperText, error, errorMessage, maxFileSize, maxFilesQuantity, disabled, className, id, accept, multiple, description, descriptionErrorMessage, ...rest }: FileUploadProps & {
631
+ ref?: React__default.Ref<HTMLInputElement>;
632
+ }): React__default.JSX.Element;
633
+ displayName: string;
634
+ };
635
+
553
636
  interface FilterItem$2 {
554
637
  /** Identificador único do item (usado em `selectedIds` e `onApplyFilter`) */
555
638
  id?: BaseProps['id'];
@@ -562,7 +645,7 @@ interface FilterItem$2 {
562
645
  /** Desabilita o item, impedindo sua seleção */
563
646
  disabled?: BaseProps['disabled'];
564
647
  }
565
- type FilterType = 'single' | 'multiple' | 'calendar';
648
+ type FilterTypes = 'single' | 'multiple' | 'calendar';
566
649
  /**
567
650
  * Props do componente Filter
568
651
  * @example
@@ -591,7 +674,7 @@ interface FilterProps extends BaseProps {
591
674
  /** Array de itens para filtros do tipo dropdown */
592
675
  items?: FilterItem$2[];
593
676
  /** Tipo do filtro (dropdown ou calendário) */
594
- type?: FilterType;
677
+ type?: FilterTypes;
595
678
  /** IDs dos itens selecionados */
596
679
  selectedIds?: string[];
597
680
  /** Callback executado ao aplicar filtro: (selectedIds) => void */
@@ -638,8 +721,8 @@ interface FilterProps extends BaseProps {
638
721
  drawerWidth?: string;
639
722
  /** Título do painel lateral (padrão: 'Filtrar') */
640
723
  title?: string;
641
- /** Número de filtros ativos exibido como badge no botão */
642
- activeCount?: number;
724
+ /** Número de filtros aplicados exibido como badge no botão */
725
+ appliedFilterCount?: number;
643
726
  /** Conteúdo customizado no cabeçalho do Drawer */
644
727
  drawerHeaderContent?: ReactNode;
645
728
  /** Conteúdo do painel lateral no modo combined */
@@ -831,6 +914,8 @@ interface ModalProps extends BaseProps {
831
914
  footer?: ReactNode;
832
915
  /** Largura customizada do modal (ex: '500px', '80%') */
833
916
  customWidth?: string;
917
+ /** Altura customizada do modal (ex: '500px', '80%') */
918
+ customHeight?: string;
834
919
  /** Define se o modal ocupa toda a tela. Tem prioridade sobre customWidth */
835
920
  fullscreen?: boolean;
836
921
  /** Classe CSS opcional */
@@ -1032,12 +1117,20 @@ interface VirtualKeyboardProps extends Omit<BaseProps, 'disabled'> {
1032
1117
  onChange?: (value: string) => void;
1033
1118
  /** Callback executado quando uma tecla é pressionada: (key) => void */
1034
1119
  onKeyPress?: (key: string) => void;
1120
+ /**
1121
+ * Callback executado sempre que o `type` do teclado muda.
1122
+ * Útil para que o consumidor saiba o tipo atual e possa reagir à mudança
1123
+ * (ex.: buscar dados diferentes, ajustar layout, etc.).
1124
+ *
1125
+ * Sempre dispara na montagem inicial, servindo como fallback para consulta do tipo atual.
1126
+ */
1127
+ onTypeChange?: (type: VirtualKeyboardType) => void;
1035
1128
  /** Limite máximo de caracteres */
1036
1129
  maxLength?: number;
1037
1130
  /** Controla a exibição do botão {emoticon} nos layouts suportados */
1038
1131
  Emoji?: boolean;
1039
1132
  /** Placeholder do TextField exibido no modo `fixed` */
1040
- textFieldPlaceholder?: string;
1133
+ placeholder?: string;
1041
1134
  /** Escala do TextField exibido no modo `fixed` */
1042
1135
  textFieldScale?: 1 | 1.5 | 2;
1043
1136
  /**
@@ -1045,6 +1138,13 @@ interface VirtualKeyboardProps extends Omit<BaseProps, 'disabled'> {
1045
1138
  * @default true
1046
1139
  */
1047
1140
  showEnterKey?: boolean;
1141
+ /**
1142
+ * Controla a exibição da tecla de alternância entre os layouts default ("123") e numeric ("ABC").
1143
+ * Quando `false`, a tecla "123" (no layout default) é removida — a tecla espaço cresce para ocupar o espaço —
1144
+ * e a tecla "ABC" (no layout numeric) é substituída por um espaço vazio.
1145
+ * @default true
1146
+ */
1147
+ showTypeSwitchKey?: boolean;
1048
1148
  /** Texto de ajuda do TextField exibido no modo `fixed` */
1049
1149
  helperText?: string;
1050
1150
  /** Sinaliza erro no TextField exibido no modo `fixed` */
@@ -1118,8 +1218,43 @@ interface SearchProps extends ScalableProps, NativeInputProps {
1118
1218
  virtualKeyboard?: VirtualKeyboardType;
1119
1219
  }
1120
1220
 
1121
- declare const Search: React__default.ForwardRefExoticComponent<SearchProps & React__default.RefAttributes<HTMLInputElement>>;
1221
+ declare const Search: {
1222
+ ({ ref, placeholder, disabled, value, onChange, onKeyDown, onFocus, onBlur, onClear, onClick, onMouseDown, searchMode, onSearch, id, scale, className, style, virtualKeyboard, "data-testid": testId, ...rest }: SearchProps & {
1223
+ ref?: React__default.Ref<HTMLInputElement>;
1224
+ }): React__default.JSX.Element;
1225
+ displayName: string;
1226
+ };
1122
1227
 
1228
+ /**
1229
+ * Props base compartilhadas por todas as configurações de tooltip do select.
1230
+ */
1231
+ interface BaseTooltipConfig$2 {
1232
+ /** Lado em que o tooltip será exibido */
1233
+ tooltipSide?: 'top' | 'bottom' | 'left' | 'right';
1234
+ /** Alinhamento do tooltip */
1235
+ tooltipAlign?: 'start' | 'center' | 'end';
1236
+ }
1237
+ /**
1238
+ * Configuração de tooltip com texto.
1239
+ * Exibe um tooltip ao redor da label do select.
1240
+ */
1241
+ interface WithTooltip$2 extends BaseTooltipConfig$2 {
1242
+ /** Texto do tooltip exibido no hover */
1243
+ tooltipText: string;
1244
+ }
1245
+ /**
1246
+ * Configuração sem tooltip.
1247
+ */
1248
+ interface WithoutTooltip$2 {
1249
+ tooltipText?: never;
1250
+ tooltipSide?: never;
1251
+ tooltipAlign?: never;
1252
+ }
1253
+ /**
1254
+ * Union type representando a configuração de tooltip do select.
1255
+ * Pode ter tooltip com texto (e opcionalmente side/align) ou sem tooltip.
1256
+ */
1257
+ type SelectTooltipConfig = WithTooltip$2 | WithoutTooltip$2;
1123
1258
  /**
1124
1259
  * Representa um item do select
1125
1260
  */
@@ -1166,7 +1301,7 @@ type SelectVariant = 'text' | 'icon' | 'checkbox';
1166
1301
  * />
1167
1302
  * ```
1168
1303
  */
1169
- interface SelectProps extends ScalableProps {
1304
+ interface SelectPropsBase extends ScalableProps {
1170
1305
  /** Array de itens do select */
1171
1306
  items: SelectItemProps[];
1172
1307
  /** Callback executado quando o valor muda: (value) => void */
@@ -1191,20 +1326,14 @@ interface SelectProps extends ScalableProps {
1191
1326
  helperText?: string;
1192
1327
  /** Largura máxima do select */
1193
1328
  maxWidth?: number;
1329
+ /** Indica estado de erro externo */
1330
+ error?: boolean;
1194
1331
  /** Mensagem de erro a ser exibida */
1195
1332
  errorMessage?: string;
1196
1333
  /** Label acessível para leitores de tela */
1197
1334
  'aria-label'?: string;
1198
1335
  /** ID para testes automatizados */
1199
1336
  'data-testid'?: string;
1200
- /** Habilita tooltip */
1201
- tooltip?: boolean;
1202
- /** Texto do tooltip */
1203
- tooltipText?: string;
1204
- /** Lado onde o dropdown abre */
1205
- side?: Side;
1206
- /** Alinhamento do dropdown */
1207
- align?: Align;
1208
1337
  /** Habilita scroll infinito */
1209
1338
  enableInfiniteScroll?: boolean;
1210
1339
  /** Callback executado ao chegar ao final do scroll: () => void */
@@ -1218,6 +1347,13 @@ interface SelectProps extends ScalableProps {
1218
1347
  /** Estado de busca em andamento */
1219
1348
  isSearching?: boolean;
1220
1349
  }
1350
+ /**
1351
+ * Props completas do Select, incluindo a configuração de tooltip.
1352
+ *
1353
+ * O tooltip é ativado automaticamente quando `tooltipText` é informado,
1354
+ * e as props `tooltipSide` e `tooltipAlign` ficam disponíveis para posicionamento.
1355
+ */
1356
+ type SelectProps = SelectPropsBase & SelectTooltipConfig;
1221
1357
 
1222
1358
  declare const Select: React__default.FC<SelectProps>;
1223
1359
 
@@ -1290,7 +1426,7 @@ interface TableProps<T = TableRowData> extends BaseProps {
1290
1426
  };
1291
1427
  }
1292
1428
 
1293
- declare const Table: <T extends TableRowData = TableRowData>({ columns, dataSource, className, loading, rowSelection, locale, onRow, ...rest }: TableProps<T>) => react_jsx_runtime.JSX.Element | null;
1429
+ declare const Table: <T extends TableRowData = TableRowData>({ columns, dataSource, className, loading, rowSelection, locale, onRow, ...rest }: TableProps<T>) => React__default.JSX.Element | null;
1294
1430
 
1295
1431
  interface BaseFilterItem$1 {
1296
1432
  id?: string;
@@ -1351,7 +1487,7 @@ declare module '@tanstack/react-table' {
1351
1487
  interface ColumnMeta<TData extends RowData, TValue> {
1352
1488
  /** Alinhamento do conteúdo da célula */
1353
1489
  align?: 'left' | 'center' | 'right';
1354
- /** Altura máxima do conteúdo da célula (ex: 48, '3rem'). Aplica overflow: hidden */
1490
+ /** Altura máxima do conteúdo da célula (padrão: 64px). Aplica overflow: hidden */
1355
1491
  maxHeight?: number | string;
1356
1492
  }
1357
1493
  }
@@ -1601,32 +1737,42 @@ interface TableV2Props<T = Record<string, unknown>> extends EmptyStateProps {
1601
1737
  };
1602
1738
  }
1603
1739
 
1604
- declare const TableV2: <T>({ columns, data, rowSelection: rowSelectionConfig, enableSorting, bulkActions, header, footer, loading, emptyIcon, emptyTitle, emptyText, onRow, className, }: TableV2Props<T>) => react_jsx_runtime.JSX.Element;
1740
+ declare const TableV2: <T>({ columns, data, rowSelection: rowSelectionConfig, enableSorting, bulkActions, header, footer, loading, emptyIcon, emptyTitle, emptyText, onRow, className, }: TableV2Props<T>) => React$1.JSX.Element;
1605
1741
 
1606
1742
  /**
1607
- * Props do componente TextArea
1608
- * @example
1609
- * ```tsx
1610
- * <TextArea
1611
- * label="Descrição"
1612
- * value={description}
1613
- * onChange={setDescription}
1614
- * placeholder="Digite uma descrição"
1615
- * />
1616
- * ```
1617
- * @example
1618
- * ```tsx
1619
- * <TextArea
1620
- * label="Comentário"
1621
- * required
1622
- * maxLength={500}
1623
- * showCharCount
1624
- * helperText="Máximo de 500 caracteres"
1625
- * errorMessage={error}
1626
- * />
1627
- * ```
1743
+ * Props base compartilhadas por todas as configurações de tooltip do TextArea.
1744
+ */
1745
+ interface BaseTooltipConfig$1 {
1746
+ /** Lado em que o tooltip será exibido */
1747
+ tooltipSide?: Side;
1748
+ /** Alinhamento do tooltip */
1749
+ tooltipAlign?: Align;
1750
+ }
1751
+ /**
1752
+ * Configuração de tooltip com texto.
1753
+ * Exibe um tooltip ao redor da label do TextArea.
1754
+ */
1755
+ interface WithTooltip$1 extends BaseTooltipConfig$1 {
1756
+ /** Texto do tooltip exibido no hover */
1757
+ tooltipText: string;
1758
+ }
1759
+ /**
1760
+ * Configuração sem tooltip.
1628
1761
  */
1629
- interface TextAreaProps extends Omit<React__default.TextareaHTMLAttributes<HTMLTextAreaElement>, 'onChange' | 'value'> {
1762
+ interface WithoutTooltip$1 {
1763
+ tooltipText?: never;
1764
+ tooltipSide?: never;
1765
+ tooltipAlign?: never;
1766
+ }
1767
+ /**
1768
+ * Union type representando a configuração de tooltip do TextArea.
1769
+ * Pode ter tooltip com texto (e opcionalmente side/align) ou sem tooltip.
1770
+ */
1771
+ type TextAreaTooltipConfig = WithTooltip$1 | WithoutTooltip$1;
1772
+ /**
1773
+ * Props base do componente TextArea.
1774
+ */
1775
+ interface TextAreaPropsBase extends Omit<React__default.TextareaHTMLAttributes<HTMLTextAreaElement>, 'onChange' | 'value'> {
1630
1776
  /** Valor controlado do campo */
1631
1777
  value?: string;
1632
1778
  /** Callback executado quando o valor muda: (value) => void */
@@ -1635,14 +1781,6 @@ interface TextAreaProps extends Omit<React__default.TextareaHTMLAttributes<HTMLT
1635
1781
  label?: string;
1636
1782
  /** Texto de ajuda exibido abaixo do campo */
1637
1783
  helperText?: string;
1638
- /** Habilita tooltip */
1639
- tooltip?: boolean;
1640
- /** Texto do tooltip */
1641
- tooltipText?: string;
1642
- /** Lado onde o tooltip aparece */
1643
- side?: Side;
1644
- /** Alinhamento do tooltip */
1645
- align?: Align;
1646
1784
  /**
1647
1785
  * Mensagem de erro exibida no campo.
1648
1786
  * Usada tanto pela validação interna (required, etc.)
@@ -1654,7 +1792,7 @@ interface TextAreaProps extends Omit<React__default.TextareaHTMLAttributes<HTMLT
1654
1792
  /** Controla o redimensionamento do textarea */
1655
1793
  resize?: 'none' | 'vertical' | 'both';
1656
1794
  /** Exibe contador de caracteres (requer maxLength) */
1657
- showCharCount?: boolean;
1795
+ charCount?: boolean;
1658
1796
  /** Altura do textarea em pixels */
1659
1797
  height?: number;
1660
1798
  /** Classe CSS opcional */
@@ -1662,13 +1800,55 @@ interface TextAreaProps extends Omit<React__default.TextareaHTMLAttributes<HTMLT
1662
1800
  /** Tipo do teclado virtual (padrão: undefined = desabilitado) */
1663
1801
  virtualKeyboard?: VirtualKeyboardType;
1664
1802
  }
1803
+ /**
1804
+ * Props completas do TextArea, incluindo a configuração de tooltip.
1805
+ *
1806
+ * O tooltip é ativado automaticamente quando `tooltipText` é informado,
1807
+ * e as props `tooltipSide` e `tooltipAlign` ficam disponíveis para posicionamento.
1808
+ */
1809
+ type TextAreaProps = TextAreaPropsBase & TextAreaTooltipConfig;
1665
1810
 
1666
- declare const _default$1: React__default.NamedExoticComponent<TextAreaProps & React__default.RefAttributes<HTMLTextAreaElement>>;
1811
+ declare const _default$1: React__default.MemoExoticComponent<{
1812
+ ({ ref, className, value, label, placeholder, onChange, disabled, maxLength, required, helperText, tooltipText, tooltipSide, tooltipAlign, errorMessage, error, id, onBlur, onFocus, name, resize, charCount, height, virtualKeyboard, ...rest }: TextAreaProps & {
1813
+ ref?: React__default.Ref<HTMLTextAreaElement>;
1814
+ }): React__default.JSX.Element;
1815
+ displayName: string;
1816
+ }>;
1667
1817
 
1668
1818
  /** Tipos de input suportados pelo TextField */
1669
1819
  type TextFieldType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url';
1670
1820
  /**
1671
- * Props do componente TextField
1821
+ * Props base compartilhadas por todas as configurações de tooltip do TextField.
1822
+ */
1823
+ interface BaseTooltipConfig {
1824
+ /** Lado em que o tooltip será exibido */
1825
+ tooltipSide?: Side;
1826
+ /** Alinhamento do tooltip */
1827
+ tooltipAlign?: Align;
1828
+ }
1829
+ /**
1830
+ * Configuração de tooltip com texto.
1831
+ * Exibe um tooltip ao redor da label do TextField.
1832
+ */
1833
+ interface WithTooltip extends BaseTooltipConfig {
1834
+ /** Texto do tooltip exibido no hover */
1835
+ tooltipText: string;
1836
+ }
1837
+ /**
1838
+ * Configuração sem tooltip.
1839
+ */
1840
+ interface WithoutTooltip {
1841
+ tooltipText?: never;
1842
+ tooltipSide?: never;
1843
+ tooltipAlign?: never;
1844
+ }
1845
+ /**
1846
+ * Union type representando a configuração de tooltip do TextField.
1847
+ * Pode ter tooltip com texto (e opcionalmente side/align) ou sem tooltip.
1848
+ */
1849
+ type TextFieldTooltipConfig = WithTooltip | WithoutTooltip;
1850
+ /**
1851
+ * Props base do componente TextField
1672
1852
  * @example
1673
1853
  * ```tsx
1674
1854
  * <TextField
@@ -1687,13 +1867,12 @@ type TextFieldType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url';
1687
1867
  * required
1688
1868
  * helperText="Mínimo 8 caracteres"
1689
1869
  * errorMessage={error}
1690
- * tooltip={true}
1691
1870
  * tooltipText="Deve conter letras e números"
1692
1871
  * icon={<LockIcon />}
1693
1872
  * />
1694
1873
  * ```
1695
1874
  */
1696
- interface TextFieldProps extends ScalableProps, Omit<React__default.InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'type'> {
1875
+ interface TextFieldPropsBase extends ScalableProps, Omit<React__default.InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'type'> {
1697
1876
  /** Valor controlado do campo */
1698
1877
  value?: string | number;
1699
1878
  /** Callback executado quando o valor muda: (value) => void */
@@ -1704,14 +1883,6 @@ interface TextFieldProps extends ScalableProps, Omit<React__default.InputHTMLAtt
1704
1883
  type?: TextFieldType;
1705
1884
  /** Texto de ajuda exibido abaixo do campo */
1706
1885
  helperText?: string;
1707
- /** Habilita tooltip */
1708
- tooltip?: boolean;
1709
- /** Texto do tooltip */
1710
- tooltipText?: string;
1711
- /** Lado onde o tooltip aparece */
1712
- tooltipSide?: Side;
1713
- /** Alinhamento do tooltip */
1714
- tooltipAlign?: Align;
1715
1886
  /**
1716
1887
  * Mensagem de erro exibida no campo.
1717
1888
  * Usada tanto pela validação interna (required, formato, etc.)
@@ -1731,8 +1902,20 @@ interface TextFieldProps extends ScalableProps, Omit<React__default.InputHTMLAtt
1731
1902
  /** Desabilita o autocomplete nativo do browser (padrão: false) */
1732
1903
  disableAutoComplete?: boolean;
1733
1904
  }
1905
+ /**
1906
+ * Props completas do TextField, incluindo a configuração de tooltip.
1907
+ *
1908
+ * O tooltip é ativado automaticamente quando `tooltipText` é informado,
1909
+ * e as props `tooltipSide` e `tooltipAlign` ficam disponíveis para posicionamento.
1910
+ */
1911
+ type TextFieldProps = TextFieldPropsBase & TextFieldTooltipConfig;
1734
1912
 
1735
- declare const _default: React__default.NamedExoticComponent<TextFieldProps & React__default.RefAttributes<HTMLInputElement>>;
1913
+ declare const _default: React__default.MemoExoticComponent<{
1914
+ ({ ref, className, style, value, label, placeholder, type, onChange, disabled, maxLength, required, helperText, tooltipText, tooltipSide, tooltipAlign, errorMessage, error, id, icon, scale, onBlur, onFocus, name, persistIcon, virtualKeyboard, attachedToVirtualKeyboard, disableAutoComplete, ...rest }: TextFieldProps & {
1915
+ ref?: React__default.Ref<HTMLInputElement>;
1916
+ }): React__default.JSX.Element;
1917
+ displayName: string;
1918
+ }>;
1736
1919
 
1737
1920
  /**
1738
1921
  * Props do componente individual de notificação `Toast`.
@@ -1970,61 +2153,57 @@ interface SwitchProps extends ScalableProps {
1970
2153
 
1971
2154
  declare const Switch: React$1.FC<SwitchProps>;
1972
2155
 
1973
- /** Tipos de entrada suportados pelo VerificationCode */
1974
- type InputType = 'numeric' | 'alpha' | 'alphanumeric';
2156
+ /** Tipos de validação suportados pelo VerificationCode */
2157
+ type OTPValidationType = 'numeric' | 'alphanumeric' | 'alpha';
1975
2158
  /**
1976
2159
  * Props do componente VerificationCode
1977
2160
  * @example
1978
2161
  * ```tsx
1979
2162
  * <VerificationCode
1980
2163
  * length={6}
1981
- * inputType="numeric"
1982
- * onComplete={(code) => handleVerification(code)}
2164
+ * validationType="numeric"
2165
+ * onValueChange={(v) => console.log(v)}
1983
2166
  * />
1984
2167
  * ```
1985
2168
  * @example
1986
2169
  * ```tsx
1987
2170
  * <VerificationCode
1988
2171
  * length={4}
1989
- * inputType="alphanumeric"
1990
- * onComplete={handleCode}
2172
+ * name="otp"
2173
+ * autoSubmit
2174
+ * onAutoSubmit={(v) => handleVerify(v)}
1991
2175
  * hasError={!!error}
1992
2176
  * errorMessage="Código inválido"
1993
- * disabled={isVerifying}
1994
2177
  * />
1995
2178
  * ```
1996
2179
  */
1997
2180
  interface VerificationCodeProps extends BaseProps {
1998
- /** Número de dígitos do código (padrão: 6) */
2181
+ /** Número de campos/dígitos (padrão: 6) */
1999
2182
  length?: number;
2000
- /** Tipo de entrada permitida (padrão: "numeric") */
2001
- inputType?: InputType;
2002
- /** Callback executado quando todos os campos são preenchidos: (value) => void */
2003
- onComplete?: (value: string) => void;
2183
+ /** Tipo de validação aceita pelo campo (padrão: 'numeric') */
2184
+ validationType?: OTPValidationType;
2185
+ /** Valor controlado do campo */
2186
+ value?: string;
2187
+ /** Valor inicial não controlado */
2188
+ defaultValue?: string;
2189
+ /** Callback chamado quando o valor muda */
2190
+ onValueChange?: (value: string) => void;
2191
+ /** Submete o formulário associado automaticamente ao completar */
2192
+ autoSubmit?: boolean;
2193
+ /** Callback chamado ao completar (quando autoSubmit está ativo) */
2194
+ onAutoSubmit?: (value: string) => void;
2195
+ /** Nome do campo para envio em formulários */
2196
+ name?: string;
2197
+ /** ID do formulário associado */
2198
+ form?: string;
2004
2199
  /** Define se o campo está em estado de erro */
2005
2200
  hasError?: boolean;
2006
2201
  /** Mensagem de erro exibida abaixo do componente */
2007
2202
  errorMessage?: string;
2008
- /** Props adicionais passadas para os inputs */
2009
- [key: string]: any;
2203
+ /** Define o campo como somente leitura */
2204
+ readOnly?: boolean;
2010
2205
  }
2011
2206
 
2012
- /**
2013
- * Componente VerificationCode para entrada de códigos de verificação
2014
- *
2015
- * @description Permite entrada de códigos com múltiplos dígitos,
2016
- * suportando diferentes tipos de caracteres e navegação por teclado.
2017
- *
2018
- * @example
2019
- * ```tsx
2020
- * <VerificationCode
2021
- * length={6}
2022
- * inputType="numeric"
2023
- * onComplete={(code) => console.log('Código:', code)}
2024
- * hasError={false}
2025
- * />
2026
- * ```
2027
- */
2028
2207
  declare const VerificationCode: React__default.FC<VerificationCodeProps>;
2029
2208
 
2030
2209
  /**
@@ -2150,5 +2329,5 @@ declare function useInfiniteScroll({ status, page, lastPage, onLoadMore, thresho
2150
2329
 
2151
2330
  declare const normalizeText: (text: React.ReactNode) => string;
2152
2331
 
2153
- export { Avatar, Badge, Button, Calendar, Callout, Card, Checkbox, MemoizedChips as Chips, Container, _default$2 as DatePicker, Dialog, Drawer, Filter, ListItem, Menu, Modal, Popover, memorizedQuantity as Quantity, Radio, Search, Select, Switch, Table, TableHeader, TablePagination, TableV2, _default$1 as TextArea, _default as TextField, Toast, ToastContainer, ToastProvider, Tooltip, VerificationCode, VirtualKeyboard, normalizeText, useApiSimulation, useInfiniteScroll, useToast };
2154
- export type { AvatarProps, BadgeProps, ButtonProps, CalendarProps, CalloutProps, CardProps, CheckboxProps, ChipsProps, ContainerProps, DatePickerProps, DialogProps, DrawerProps, FilterItem$1 as FilterItem, FilterProps, ListItemProps, MenuProps, ModalProps, PopoverProps, QuantityProps, RadioGroupProps, RadioProps, SearchProps, SelectProps, SwitchProps, TableHeaderProps, TablePaginationProps, TableProps, TableV2FooterProps, TableV2HeaderProps, TableV2Props, TextAreaProps, TextFieldProps, ToastProps, TooltipProps, VerificationCodeProps, VirtualKeyboardProps, VirtualKeyboardVariant };
2332
+ export { Avatar, Badge, Button, Calendar, Callout, Card, Checkbox, MemoizedChips as Chips, Container, _default$2 as DatePicker, Dialog, Drawer, FileUpload, Filter, ListItem, Menu, Modal, Popover, memorizedQuantity as Quantity, Radio, Search, Select, Switch, Table, TableHeader, TablePagination, TableV2, _default$1 as TextArea, _default as TextField, Toast, ToastContainer, ToastProvider, Tooltip, VerificationCode, VirtualKeyboard, normalizeText, useApiSimulation, useInfiniteScroll, useToast };
2333
+ export type { AvatarProps, BadgeProps, ButtonProps, CalendarProps, CalloutProps, CardProps, CheckboxProps, ChipsProps, ContainerProps, DatePickerProps, DialogProps, DrawerProps, FileUploadProps, FilterItem$1 as FilterItem, FilterProps, ListItemProps, MenuProps, ModalProps, PopoverProps, QuantityProps, RadioGroupProps, RadioProps, SearchProps, SelectProps, SwitchProps, TableHeaderProps, TablePaginationProps, TableProps, TableV2FooterProps, TableV2HeaderProps, TableV2Props, TextAreaProps, TextFieldProps, ToastProps, TooltipProps, VerificationCodeProps, VirtualKeyboardProps, VirtualKeyboardVariant };