@vector-business-services/cristal-ds-web 0.23.0 → 0.25.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.cts CHANGED
@@ -42,12 +42,12 @@ interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'
42
42
  declare const Accordion: react.ForwardRefExoticComponent<AccordionProps & react.RefAttributes<HTMLDivElement>>;
43
43
 
44
44
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
45
- type InputVariant = 'outline' | 'filled';
45
+ type InputTextVariant = 'outline' | 'filled';
46
46
  /** Size no Figma: 32, 36, 42 e 48px de altura do campo. */
47
- type InputSize = 'xsmall' | 'small' | 'medium' | 'large';
48
- interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'value' | 'children'> {
49
- variant?: InputVariant;
50
- size?: InputSize;
47
+ type InputTextSize = 'xsmall' | 'small' | 'medium' | 'large';
48
+ interface InputTextProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'value' | 'children'> {
49
+ variant?: InputTextVariant;
50
+ size?: InputTextSize;
51
51
  /** Rótulo acima do campo (Label no Figma). Sem rótulo, passe `aria-label`. */
52
52
  label?: string;
53
53
  /** Valor do campo (controlado). */
@@ -61,10 +61,18 @@ interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'
61
61
  /** Mensagem de erro: deixa o campo no estado Error e mostra a dica de erro no lugar da dica. */
62
62
  error?: string;
63
63
  }
64
- declare const Input: react.ForwardRefExoticComponent<InputProps & react.RefAttributes<HTMLInputElement>>;
64
+ declare const InputText: react.ForwardRefExoticComponent<InputTextProps & react.RefAttributes<HTMLInputElement>>;
65
+ /** @deprecated Use `InputText` (o nome do PrimeNG 19). */
66
+ declare const Input: react.ForwardRefExoticComponent<InputTextProps & react.RefAttributes<HTMLInputElement>>;
67
+ /** @deprecated Use `InputTextProps`. */
68
+ type InputProps = InputTextProps;
69
+ /** @deprecated Use `InputTextSize`. */
70
+ type InputSize = InputTextSize;
71
+ /** @deprecated Use `InputTextVariant`. */
72
+ type InputVariant = InputTextVariant;
65
73
 
66
- type AutoCompleteVariant = InputVariant;
67
- type AutoCompleteSize = InputSize;
74
+ type AutoCompleteVariant = InputTextVariant;
75
+ type AutoCompleteSize = InputTextSize;
68
76
  interface AutoCompleteProps extends Omit<AutoCompleteProps$1, 'size' | 'variant' | 'invalid' | 'multiple' | 'selectionLimit' | 'selectedItemTemplate' | 'removeTokenIcon' | 'dropdownIcon' | 'showEmptyMessage' | 'emptyMessage' | 'loadingIcon' | 'inputClassName' | 'panelClassName' | 'scrollHeight' | 'inputRef' | 'pt' | 'ptOptions' | 'unstyled' | 'children'> {
69
77
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
70
78
  variant?: AutoCompleteVariant;
@@ -191,8 +199,13 @@ interface ChartProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'chi
191
199
  helpLabel?: string;
192
200
  /** Botões à direita do título (IconButton tertiary xsmall no Figma). */
193
201
  actions?: ReactNode;
194
- /** Altura da área do gráfico, com os eixos. Padrão: 266px, a do Figma. */
195
- height?: number;
202
+ /**
203
+ * Altura da área do gráfico, com os eixos: em px, ou `'100%'` para ocupar a altura do contêiner
204
+ * (que precisa ter altura definida). Padrão: 266px, a do Figma.
205
+ */
206
+ height?: number | '100%';
207
+ /** Legenda abaixo do gráfico. Padrão: com 2 ou mais séries. */
208
+ legend?: boolean;
196
209
  id?: string;
197
210
  className?: string;
198
211
  }
@@ -377,11 +390,11 @@ declare const DATE_PERIODS: {
377
390
  };
378
391
  };
379
392
 
380
- type DatePickerVariant = InputVariant;
381
- type DatePickerSize = InputSize;
393
+ type DatePickerVariant = InputTextVariant;
394
+ type DatePickerSize = InputTextSize;
382
395
  /**
383
396
  * Props do Calendar do PrimeReact (`selectionMode` single, range ou multiple, `numberOfMonths`,
384
- * `view`, `dateFormat`, `minDate`, `maxDate`, `disabledDates`, `showTime`...), mais o campo do Input
397
+ * `view`, `dateFormat`, `minDate`, `maxDate`, `disabledDates`, `showTime`...), mais o campo do InputText
385
398
  * do Cristal. O visual (pt e unstyled), o ícone e as setas são do Cristal.
386
399
  */
387
400
  interface DatePickerProps<TMode extends CalendarSelectionMode = 'single'> extends Omit<CalendarProps$1<TMode>, 'pt' | 'ptOptions' | 'unstyled' | 'inline' | 'prevIcon' | 'nextIcon' | 'showIcon' | 'icon' | 'iconPos' | 'invalid' | 'variant' | 'inputClassName' | 'panelClassName'> {
@@ -687,13 +700,13 @@ declare const Message: react.ForwardRefExoticComponent<MessageProps & react.RefA
687
700
  * Size no Figma: Small (520px), Medium (768px) e Large (1200 x 720px; abaixo de 768px de tela
688
701
  * vira tela cheia, como o Responsive=360 do Figma).
689
702
  */
690
- type ModalSize = 'small' | 'medium' | 'large';
691
- /** Controle do Modal pela ref: o elemento só existe com o modal aberto. */
692
- interface ModalHandle {
703
+ type DialogSize = 'small' | 'medium' | 'large';
704
+ /** Controle do Dialog pela ref: o elemento só existe com o modal aberto. */
705
+ interface DialogHandle {
693
706
  /** O role=dialog do modal (null fechado). */
694
707
  getElement: () => HTMLDivElement | null;
695
708
  }
696
- interface ModalProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'children' | 'content' | 'onClick'> {
709
+ interface DialogProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'children' | 'content' | 'onClick'> {
697
710
  visible: boolean;
698
711
  /** Pedido para fechar (X, Esc ou clique fora, com dismissableMask). */
699
712
  onHide: () => void;
@@ -705,7 +718,7 @@ interface ModalProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'chi
705
718
  /** Título do cabeçalho; também é o nome acessível do modal. */
706
719
  title: string;
707
720
  /** Padrão: large. */
708
- size?: ModalSize;
721
+ size?: DialogSize;
709
722
  /** Mostra o botão de ajuda (QuestionMark) ao lado do X, no small e no medium. */
710
723
  onHelp?: () => void;
711
724
  helpLabel?: string;
@@ -718,7 +731,15 @@ interface ModalProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'chi
718
731
  id?: string;
719
732
  className?: string;
720
733
  }
721
- declare const Modal: react.ForwardRefExoticComponent<ModalProps & react.RefAttributes<ModalHandle>>;
734
+ declare const Dialog: react.ForwardRefExoticComponent<DialogProps & react.RefAttributes<DialogHandle>>;
735
+ /** @deprecated Use `Dialog` (o nome do PrimeNG 19). */
736
+ declare const Modal: react.ForwardRefExoticComponent<DialogProps & react.RefAttributes<DialogHandle>>;
737
+ /** @deprecated Use `DialogHandle`. */
738
+ type ModalHandle = DialogHandle;
739
+ /** @deprecated Use `DialogProps`. */
740
+ type ModalProps = DialogProps;
741
+ /** @deprecated Use `DialogSize`. */
742
+ type ModalSize = DialogSize;
722
743
 
723
744
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
724
745
  type MultiSelectVariant = 'outline' | 'filled';
@@ -798,7 +819,7 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'>
798
819
  backLabel?: string;
799
820
  /** Texto da Tag depois do título (Show Tag no Figma). */
800
821
  tag?: ReactNode;
801
- /** Segment Control das ferramentas (Show Segment Control no Figma): um `<SegmentControl>`. */
822
+ /** Segment Control das ferramentas (Show Segment Control no Figma): um `<SelectButton>`. */
802
823
  segmentControl?: ReactNode;
803
824
  /** Botões das ferramentas (Show Buttons no Figma), 8px entre eles. */
804
825
  actions?: ReactNode;
@@ -855,15 +876,15 @@ type PanelProps = Omit<HTMLAttributes<HTMLDivElement>, 'onToggle'>;
855
876
  declare const Panel: react.ForwardRefExoticComponent<PanelProps & react.RefAttributes<HTMLDivElement>>;
856
877
 
857
878
  /** Label Size no Figma: Default (uma linha, com reticências) e Full (quebra em várias linhas). */
858
- type RadioLabelSize = 'default' | 'full';
879
+ type RadioButtonLabelSize = 'default' | 'full';
859
880
  /** As demais props vão no <input> (aria-describedby, onBlur, data-*...); className e style, na raiz. */
860
- interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
881
+ interface RadioButtonProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
861
882
  /** Texto ao lado do controle (Label no Figma). Sem rótulo visível, vira o nome acessível. */
862
883
  label: ReactNode;
863
884
  /** Mostra o rótulo. Padrão: true. */
864
885
  showLabel?: boolean;
865
886
  /** Padrão: default. */
866
- labelSize?: RadioLabelSize;
887
+ labelSize?: RadioButtonLabelSize;
867
888
  checked?: boolean;
868
889
  /** Valor da opção, devolvido no `onChange`. */
869
890
  value?: unknown;
@@ -877,7 +898,13 @@ interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChan
877
898
  className?: string;
878
899
  style?: CSSProperties;
879
900
  }
880
- declare const Radio: react.ForwardRefExoticComponent<RadioProps & react.RefAttributes<HTMLInputElement>>;
901
+ declare const RadioButton: react.ForwardRefExoticComponent<RadioButtonProps & react.RefAttributes<HTMLInputElement>>;
902
+ /** @deprecated Use `RadioButton` (o nome do PrimeNG 19). */
903
+ declare const Radio: react.ForwardRefExoticComponent<RadioButtonProps & react.RefAttributes<HTMLInputElement>>;
904
+ /** @deprecated Use `RadioButtonLabelSize`. */
905
+ type RadioLabelSize = RadioButtonLabelSize;
906
+ /** @deprecated Use `RadioButtonProps`. */
907
+ type RadioProps = RadioButtonProps;
881
908
 
882
909
  interface ScrollPanelProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'> {
883
910
  children?: ReactNode;
@@ -895,20 +922,20 @@ declare const ScrollPanel: react.ForwardRefExoticComponent<ScrollPanelProps & re
895
922
  * No Figma: Primary é o Header Segment Control (pílula em fill/brand/subtlest) e Secondary é o
896
923
  * Segment Control (cinza, com ícones).
897
924
  */
898
- type SegmentControlVariant = 'primary' | 'secondary';
899
- interface SegmentControlOption {
925
+ type SelectButtonVariant = 'primary' | 'secondary';
926
+ interface SelectButtonOption {
900
927
  label: string;
901
928
  value: string | number;
902
929
  /** Ícone de 16px antes do texto (o Secondary do Figma usa). */
903
930
  icon?: ReactNode;
904
931
  disabled?: boolean;
905
932
  }
906
- interface SegmentControlProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children' | 'onChange' | 'defaultValue' | 'unselectable'> {
907
- options: SegmentControlOption[];
933
+ interface SelectButtonProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children' | 'onChange' | 'defaultValue' | 'unselectable'> {
934
+ options: SelectButtonOption[];
908
935
  /** Valor do segmento ativo (controlado). */
909
936
  value?: string | number;
910
937
  onChange?: (value: string | number) => void;
911
- variant?: SegmentControlVariant;
938
+ variant?: SelectButtonVariant;
912
939
  /** O que o grupo controla, para o leitor de tela (ex.: "Visualização"). */
913
940
  'aria-label'?: string;
914
941
  'aria-labelledby'?: string;
@@ -916,7 +943,15 @@ interface SegmentControlProps extends Omit<HTMLAttributes<HTMLDivElement>, 'chil
916
943
  id?: string;
917
944
  className?: string;
918
945
  }
919
- declare const SegmentControl: react.ForwardRefExoticComponent<SegmentControlProps & react.RefAttributes<HTMLDivElement>>;
946
+ declare const SelectButton: react.ForwardRefExoticComponent<SelectButtonProps & react.RefAttributes<HTMLDivElement>>;
947
+ /** @deprecated Use `SelectButton` (o nome do PrimeNG 19). */
948
+ declare const SegmentControl: react.ForwardRefExoticComponent<SelectButtonProps & react.RefAttributes<HTMLDivElement>>;
949
+ /** @deprecated Use `SelectButtonOption`. */
950
+ type SegmentControlOption = SelectButtonOption;
951
+ /** @deprecated Use `SelectButtonProps`. */
952
+ type SegmentControlProps = SelectButtonProps;
953
+ /** @deprecated Use `SelectButtonVariant`. */
954
+ type SegmentControlVariant = SelectButtonVariant;
920
955
 
921
956
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
922
957
  type SelectVariant = 'outline' | 'filled';
@@ -973,19 +1008,19 @@ interface SkeletonProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'>
973
1008
  declare const Skeleton: react.ForwardRefExoticComponent<SkeletonProps & react.RefAttributes<HTMLDivElement>>;
974
1009
 
975
1010
  /** Size no Figma: Medium (48x28) e Small (32x20). */
976
- type SwitchSize = 'medium' | 'small';
1011
+ type ToggleSwitchSize = 'medium' | 'small';
977
1012
  /** Label Position no Figma: lado do rótulo em relação ao switch. */
978
- type SwitchLabelPosition = 'right' | 'left';
1013
+ type ToggleSwitchLabelPosition = 'right' | 'left';
979
1014
  /** As demais props vão no <input> (aria-describedby, onBlur, data-*...); className e style, na raiz. */
980
- interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
1015
+ interface ToggleSwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
981
1016
  /** Texto ao lado do switch (Label no Figma). Sem rótulo visível, vira o nome acessível. */
982
1017
  label: ReactNode;
983
1018
  /** Mostra o rótulo. Padrão: true. */
984
1019
  showLabel?: boolean;
985
1020
  /** Padrão: right. */
986
- labelPosition?: SwitchLabelPosition;
1021
+ labelPosition?: ToggleSwitchLabelPosition;
987
1022
  /** Padrão: medium. */
988
- size?: SwitchSize;
1023
+ size?: ToggleSwitchSize;
989
1024
  checked?: boolean;
990
1025
  onChange?: (event: InputSwitchChangeEvent) => void;
991
1026
  disabled?: boolean;
@@ -995,7 +1030,15 @@ interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onCha
995
1030
  className?: string;
996
1031
  style?: CSSProperties;
997
1032
  }
998
- declare const Switch: react.ForwardRefExoticComponent<SwitchProps & react.RefAttributes<HTMLInputElement>>;
1033
+ declare const ToggleSwitch: react.ForwardRefExoticComponent<ToggleSwitchProps & react.RefAttributes<HTMLInputElement>>;
1034
+ /** @deprecated Use `ToggleSwitch` (o nome do PrimeNG 19). */
1035
+ declare const Switch: react.ForwardRefExoticComponent<ToggleSwitchProps & react.RefAttributes<HTMLInputElement>>;
1036
+ /** @deprecated Use `ToggleSwitchLabelPosition`. */
1037
+ type SwitchLabelPosition = ToggleSwitchLabelPosition;
1038
+ /** @deprecated Use `ToggleSwitchProps`. */
1039
+ type SwitchProps = ToggleSwitchProps;
1040
+ /** @deprecated Use `ToggleSwitchSize`. */
1041
+ type SwitchSize = ToggleSwitchSize;
999
1042
 
1000
1043
  /** Uma aba (.Tab Item no Figma) e o conteúdo dela. */
1001
1044
  interface TabPanelProps {
@@ -1190,5 +1233,5 @@ interface ToastProps {
1190
1233
  }
1191
1234
  declare const Toast: react.ForwardRefExoticComponent<ToastProps & react.RefAttributes<ToastHandle>>;
1192
1235
 
1193
- export { Accordion, AccordionTab, AutoComplete, Badge, Button, Calendar, Card, Chart, Checkbox, Chip, Column, ContextMenu, DATE_PERIODS, DatePicker, DateRangeButton, Divider, Drawer, IconButton, Input, Menu, MenuPrincipal, Menubar, Message, Modal, MultiSelect, PageHeader, Paginator, Panel, Radio, ScrollPanel, SegmentControl, Select, Skeleton, Switch, TabPanel, Table, TableRowActions, TableToolbar, Tabs, Tag, Toast, Tooltip };
1194
- export type { AccordionProps, AccordionTabProps, AutoCompleteProps, AutoCompleteSize, AutoCompleteVariant, BadgeProps, BadgeSize, BadgeVariant, ButtonProps, ButtonSize, ButtonVariant, CalendarHandle, CalendarProps, CardPadding, CardProps, ChartAxis, ChartColor, ChartProps, ChartSeries, CheckboxLabelSize, CheckboxPosition, CheckboxProps, ChipProps, ChipSize, ChipVariant, ColumnProps, ContextMenuHandle, ContextMenuItem, ContextMenuProps, DatePickerHandle, DatePickerProps, DatePickerSize, DatePickerVariant, DateRange, DateRangeButtonChangeEvent, DateRangeButtonProps, DateRangePeriod, DividerOrientation, DividerProps, DividerVariant, DrawerBehavior, DrawerHandle, DrawerProps, DrawerSide, DrawerSize, IconButtonProps, IconButtonSize, IconButtonVariant, InputProps, InputSize, InputVariant, MenuDensity, MenuHandle, MenuItem, MenuPrincipalEntry, MenuPrincipalGroup, MenuPrincipalHandle, MenuPrincipalItem, MenuPrincipalProps, MenuProps, MenubarProps, MenubarTool, MenubarUser, MessageProps, MessageType, ModalHandle, ModalProps, ModalSize, MultiSelectDensity, MultiSelectProps, MultiSelectSize, MultiSelectVariant, PageHeaderProps, PageHeaderTab, PageHeaderVariant, PaginatorPageChangeEvent, PaginatorProps, PanelProps, RadioLabelSize, RadioProps, ScrollPanelProps, SegmentControlOption, SegmentControlProps, SegmentControlVariant, SelectProps, SelectSize, SelectVariant, SkeletonProps, SkeletonShape, SwitchLabelPosition, SwitchProps, SwitchSize, TabPanelProps, TableFilter, TableHandle, TableProps, TableRowActionsProps, TableToolbarAction, TableToolbarProps, TabsProps, TagProps, TagSize, TagVariant, ToastHandle, ToastMessage, ToastPosition, ToastProps, ToastType, TooltipPosition, TooltipProps, TooltipType };
1236
+ export { Accordion, AccordionTab, AutoComplete, Badge, Button, Calendar, Card, Chart, Checkbox, Chip, Column, ContextMenu, DATE_PERIODS, DatePicker, DateRangeButton, Dialog, Divider, Drawer, IconButton, Input, InputText, Menu, MenuPrincipal, Menubar, Message, Modal, MultiSelect, PageHeader, Paginator, Panel, Radio, RadioButton, ScrollPanel, SegmentControl, Select, SelectButton, Skeleton, Switch, TabPanel, Table, TableRowActions, TableToolbar, Tabs, Tag, Toast, ToggleSwitch, Tooltip };
1237
+ export type { AccordionProps, AccordionTabProps, AutoCompleteProps, AutoCompleteSize, AutoCompleteVariant, BadgeProps, BadgeSize, BadgeVariant, ButtonProps, ButtonSize, ButtonVariant, CalendarHandle, CalendarProps, CardPadding, CardProps, ChartAxis, ChartColor, ChartProps, ChartSeries, CheckboxLabelSize, CheckboxPosition, CheckboxProps, ChipProps, ChipSize, ChipVariant, ColumnProps, ContextMenuHandle, ContextMenuItem, ContextMenuProps, DatePickerHandle, DatePickerProps, DatePickerSize, DatePickerVariant, DateRange, DateRangeButtonChangeEvent, DateRangeButtonProps, DateRangePeriod, DialogHandle, DialogProps, DialogSize, DividerOrientation, DividerProps, DividerVariant, DrawerBehavior, DrawerHandle, DrawerProps, DrawerSide, DrawerSize, IconButtonProps, IconButtonSize, IconButtonVariant, InputProps, InputSize, InputTextProps, InputTextSize, InputTextVariant, InputVariant, MenuDensity, MenuHandle, MenuItem, MenuPrincipalEntry, MenuPrincipalGroup, MenuPrincipalHandle, MenuPrincipalItem, MenuPrincipalProps, MenuProps, MenubarProps, MenubarTool, MenubarUser, MessageProps, MessageType, ModalHandle, ModalProps, ModalSize, MultiSelectDensity, MultiSelectProps, MultiSelectSize, MultiSelectVariant, PageHeaderProps, PageHeaderTab, PageHeaderVariant, PaginatorPageChangeEvent, PaginatorProps, PanelProps, RadioButtonLabelSize, RadioButtonProps, RadioLabelSize, RadioProps, ScrollPanelProps, SegmentControlOption, SegmentControlProps, SegmentControlVariant, SelectButtonOption, SelectButtonProps, SelectButtonVariant, SelectProps, SelectSize, SelectVariant, SkeletonProps, SkeletonShape, SwitchLabelPosition, SwitchProps, SwitchSize, TabPanelProps, TableFilter, TableHandle, TableProps, TableRowActionsProps, TableToolbarAction, TableToolbarProps, TabsProps, TagProps, TagSize, TagVariant, ToastHandle, ToastMessage, ToastPosition, ToastProps, ToastType, ToggleSwitchLabelPosition, ToggleSwitchProps, ToggleSwitchSize, TooltipPosition, TooltipProps, TooltipType };
package/dist/index.d.ts CHANGED
@@ -42,12 +42,12 @@ interface AccordionProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'
42
42
  declare const Accordion: react.ForwardRefExoticComponent<AccordionProps & react.RefAttributes<HTMLDivElement>>;
43
43
 
44
44
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
45
- type InputVariant = 'outline' | 'filled';
45
+ type InputTextVariant = 'outline' | 'filled';
46
46
  /** Size no Figma: 32, 36, 42 e 48px de altura do campo. */
47
- type InputSize = 'xsmall' | 'small' | 'medium' | 'large';
48
- interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'value' | 'children'> {
49
- variant?: InputVariant;
50
- size?: InputSize;
47
+ type InputTextSize = 'xsmall' | 'small' | 'medium' | 'large';
48
+ interface InputTextProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'value' | 'children'> {
49
+ variant?: InputTextVariant;
50
+ size?: InputTextSize;
51
51
  /** Rótulo acima do campo (Label no Figma). Sem rótulo, passe `aria-label`. */
52
52
  label?: string;
53
53
  /** Valor do campo (controlado). */
@@ -61,10 +61,18 @@ interface InputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'
61
61
  /** Mensagem de erro: deixa o campo no estado Error e mostra a dica de erro no lugar da dica. */
62
62
  error?: string;
63
63
  }
64
- declare const Input: react.ForwardRefExoticComponent<InputProps & react.RefAttributes<HTMLInputElement>>;
64
+ declare const InputText: react.ForwardRefExoticComponent<InputTextProps & react.RefAttributes<HTMLInputElement>>;
65
+ /** @deprecated Use `InputText` (o nome do PrimeNG 19). */
66
+ declare const Input: react.ForwardRefExoticComponent<InputTextProps & react.RefAttributes<HTMLInputElement>>;
67
+ /** @deprecated Use `InputTextProps`. */
68
+ type InputProps = InputTextProps;
69
+ /** @deprecated Use `InputTextSize`. */
70
+ type InputSize = InputTextSize;
71
+ /** @deprecated Use `InputTextVariant`. */
72
+ type InputVariant = InputTextVariant;
65
73
 
66
- type AutoCompleteVariant = InputVariant;
67
- type AutoCompleteSize = InputSize;
74
+ type AutoCompleteVariant = InputTextVariant;
75
+ type AutoCompleteSize = InputTextSize;
68
76
  interface AutoCompleteProps extends Omit<AutoCompleteProps$1, 'size' | 'variant' | 'invalid' | 'multiple' | 'selectionLimit' | 'selectedItemTemplate' | 'removeTokenIcon' | 'dropdownIcon' | 'showEmptyMessage' | 'emptyMessage' | 'loadingIcon' | 'inputClassName' | 'panelClassName' | 'scrollHeight' | 'inputRef' | 'pt' | 'ptOptions' | 'unstyled' | 'children'> {
69
77
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
70
78
  variant?: AutoCompleteVariant;
@@ -191,8 +199,13 @@ interface ChartProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'chi
191
199
  helpLabel?: string;
192
200
  /** Botões à direita do título (IconButton tertiary xsmall no Figma). */
193
201
  actions?: ReactNode;
194
- /** Altura da área do gráfico, com os eixos. Padrão: 266px, a do Figma. */
195
- height?: number;
202
+ /**
203
+ * Altura da área do gráfico, com os eixos: em px, ou `'100%'` para ocupar a altura do contêiner
204
+ * (que precisa ter altura definida). Padrão: 266px, a do Figma.
205
+ */
206
+ height?: number | '100%';
207
+ /** Legenda abaixo do gráfico. Padrão: com 2 ou mais séries. */
208
+ legend?: boolean;
196
209
  id?: string;
197
210
  className?: string;
198
211
  }
@@ -377,11 +390,11 @@ declare const DATE_PERIODS: {
377
390
  };
378
391
  };
379
392
 
380
- type DatePickerVariant = InputVariant;
381
- type DatePickerSize = InputSize;
393
+ type DatePickerVariant = InputTextVariant;
394
+ type DatePickerSize = InputTextSize;
382
395
  /**
383
396
  * Props do Calendar do PrimeReact (`selectionMode` single, range ou multiple, `numberOfMonths`,
384
- * `view`, `dateFormat`, `minDate`, `maxDate`, `disabledDates`, `showTime`...), mais o campo do Input
397
+ * `view`, `dateFormat`, `minDate`, `maxDate`, `disabledDates`, `showTime`...), mais o campo do InputText
385
398
  * do Cristal. O visual (pt e unstyled), o ícone e as setas são do Cristal.
386
399
  */
387
400
  interface DatePickerProps<TMode extends CalendarSelectionMode = 'single'> extends Omit<CalendarProps$1<TMode>, 'pt' | 'ptOptions' | 'unstyled' | 'inline' | 'prevIcon' | 'nextIcon' | 'showIcon' | 'icon' | 'iconPos' | 'invalid' | 'variant' | 'inputClassName' | 'panelClassName'> {
@@ -687,13 +700,13 @@ declare const Message: react.ForwardRefExoticComponent<MessageProps & react.RefA
687
700
  * Size no Figma: Small (520px), Medium (768px) e Large (1200 x 720px; abaixo de 768px de tela
688
701
  * vira tela cheia, como o Responsive=360 do Figma).
689
702
  */
690
- type ModalSize = 'small' | 'medium' | 'large';
691
- /** Controle do Modal pela ref: o elemento só existe com o modal aberto. */
692
- interface ModalHandle {
703
+ type DialogSize = 'small' | 'medium' | 'large';
704
+ /** Controle do Dialog pela ref: o elemento só existe com o modal aberto. */
705
+ interface DialogHandle {
693
706
  /** O role=dialog do modal (null fechado). */
694
707
  getElement: () => HTMLDivElement | null;
695
708
  }
696
- interface ModalProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'children' | 'content' | 'onClick'> {
709
+ interface DialogProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'children' | 'content' | 'onClick'> {
697
710
  visible: boolean;
698
711
  /** Pedido para fechar (X, Esc ou clique fora, com dismissableMask). */
699
712
  onHide: () => void;
@@ -705,7 +718,7 @@ interface ModalProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'chi
705
718
  /** Título do cabeçalho; também é o nome acessível do modal. */
706
719
  title: string;
707
720
  /** Padrão: large. */
708
- size?: ModalSize;
721
+ size?: DialogSize;
709
722
  /** Mostra o botão de ajuda (QuestionMark) ao lado do X, no small e no medium. */
710
723
  onHelp?: () => void;
711
724
  helpLabel?: string;
@@ -718,7 +731,15 @@ interface ModalProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'chi
718
731
  id?: string;
719
732
  className?: string;
720
733
  }
721
- declare const Modal: react.ForwardRefExoticComponent<ModalProps & react.RefAttributes<ModalHandle>>;
734
+ declare const Dialog: react.ForwardRefExoticComponent<DialogProps & react.RefAttributes<DialogHandle>>;
735
+ /** @deprecated Use `Dialog` (o nome do PrimeNG 19). */
736
+ declare const Modal: react.ForwardRefExoticComponent<DialogProps & react.RefAttributes<DialogHandle>>;
737
+ /** @deprecated Use `DialogHandle`. */
738
+ type ModalHandle = DialogHandle;
739
+ /** @deprecated Use `DialogProps`. */
740
+ type ModalProps = DialogProps;
741
+ /** @deprecated Use `DialogSize`. */
742
+ type ModalSize = DialogSize;
722
743
 
723
744
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
724
745
  type MultiSelectVariant = 'outline' | 'filled';
@@ -798,7 +819,7 @@ interface PageHeaderProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'>
798
819
  backLabel?: string;
799
820
  /** Texto da Tag depois do título (Show Tag no Figma). */
800
821
  tag?: ReactNode;
801
- /** Segment Control das ferramentas (Show Segment Control no Figma): um `<SegmentControl>`. */
822
+ /** Segment Control das ferramentas (Show Segment Control no Figma): um `<SelectButton>`. */
802
823
  segmentControl?: ReactNode;
803
824
  /** Botões das ferramentas (Show Buttons no Figma), 8px entre eles. */
804
825
  actions?: ReactNode;
@@ -855,15 +876,15 @@ type PanelProps = Omit<HTMLAttributes<HTMLDivElement>, 'onToggle'>;
855
876
  declare const Panel: react.ForwardRefExoticComponent<PanelProps & react.RefAttributes<HTMLDivElement>>;
856
877
 
857
878
  /** Label Size no Figma: Default (uma linha, com reticências) e Full (quebra em várias linhas). */
858
- type RadioLabelSize = 'default' | 'full';
879
+ type RadioButtonLabelSize = 'default' | 'full';
859
880
  /** As demais props vão no <input> (aria-describedby, onBlur, data-*...); className e style, na raiz. */
860
- interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
881
+ interface RadioButtonProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
861
882
  /** Texto ao lado do controle (Label no Figma). Sem rótulo visível, vira o nome acessível. */
862
883
  label: ReactNode;
863
884
  /** Mostra o rótulo. Padrão: true. */
864
885
  showLabel?: boolean;
865
886
  /** Padrão: default. */
866
- labelSize?: RadioLabelSize;
887
+ labelSize?: RadioButtonLabelSize;
867
888
  checked?: boolean;
868
889
  /** Valor da opção, devolvido no `onChange`. */
869
890
  value?: unknown;
@@ -877,7 +898,13 @@ interface RadioProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChan
877
898
  className?: string;
878
899
  style?: CSSProperties;
879
900
  }
880
- declare const Radio: react.ForwardRefExoticComponent<RadioProps & react.RefAttributes<HTMLInputElement>>;
901
+ declare const RadioButton: react.ForwardRefExoticComponent<RadioButtonProps & react.RefAttributes<HTMLInputElement>>;
902
+ /** @deprecated Use `RadioButton` (o nome do PrimeNG 19). */
903
+ declare const Radio: react.ForwardRefExoticComponent<RadioButtonProps & react.RefAttributes<HTMLInputElement>>;
904
+ /** @deprecated Use `RadioButtonLabelSize`. */
905
+ type RadioLabelSize = RadioButtonLabelSize;
906
+ /** @deprecated Use `RadioButtonProps`. */
907
+ type RadioProps = RadioButtonProps;
881
908
 
882
909
  interface ScrollPanelProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'> {
883
910
  children?: ReactNode;
@@ -895,20 +922,20 @@ declare const ScrollPanel: react.ForwardRefExoticComponent<ScrollPanelProps & re
895
922
  * No Figma: Primary é o Header Segment Control (pílula em fill/brand/subtlest) e Secondary é o
896
923
  * Segment Control (cinza, com ícones).
897
924
  */
898
- type SegmentControlVariant = 'primary' | 'secondary';
899
- interface SegmentControlOption {
925
+ type SelectButtonVariant = 'primary' | 'secondary';
926
+ interface SelectButtonOption {
900
927
  label: string;
901
928
  value: string | number;
902
929
  /** Ícone de 16px antes do texto (o Secondary do Figma usa). */
903
930
  icon?: ReactNode;
904
931
  disabled?: boolean;
905
932
  }
906
- interface SegmentControlProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children' | 'onChange' | 'defaultValue' | 'unselectable'> {
907
- options: SegmentControlOption[];
933
+ interface SelectButtonProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children' | 'onChange' | 'defaultValue' | 'unselectable'> {
934
+ options: SelectButtonOption[];
908
935
  /** Valor do segmento ativo (controlado). */
909
936
  value?: string | number;
910
937
  onChange?: (value: string | number) => void;
911
- variant?: SegmentControlVariant;
938
+ variant?: SelectButtonVariant;
912
939
  /** O que o grupo controla, para o leitor de tela (ex.: "Visualização"). */
913
940
  'aria-label'?: string;
914
941
  'aria-labelledby'?: string;
@@ -916,7 +943,15 @@ interface SegmentControlProps extends Omit<HTMLAttributes<HTMLDivElement>, 'chil
916
943
  id?: string;
917
944
  className?: string;
918
945
  }
919
- declare const SegmentControl: react.ForwardRefExoticComponent<SegmentControlProps & react.RefAttributes<HTMLDivElement>>;
946
+ declare const SelectButton: react.ForwardRefExoticComponent<SelectButtonProps & react.RefAttributes<HTMLDivElement>>;
947
+ /** @deprecated Use `SelectButton` (o nome do PrimeNG 19). */
948
+ declare const SegmentControl: react.ForwardRefExoticComponent<SelectButtonProps & react.RefAttributes<HTMLDivElement>>;
949
+ /** @deprecated Use `SelectButtonOption`. */
950
+ type SegmentControlOption = SelectButtonOption;
951
+ /** @deprecated Use `SelectButtonProps`. */
952
+ type SegmentControlProps = SelectButtonProps;
953
+ /** @deprecated Use `SelectButtonVariant`. */
954
+ type SegmentControlVariant = SelectButtonVariant;
920
955
 
921
956
  /** Type no Figma: Outline (com borda) e Filled (com fundo). */
922
957
  type SelectVariant = 'outline' | 'filled';
@@ -973,19 +1008,19 @@ interface SkeletonProps extends Omit<HTMLAttributes<HTMLDivElement>, 'children'>
973
1008
  declare const Skeleton: react.ForwardRefExoticComponent<SkeletonProps & react.RefAttributes<HTMLDivElement>>;
974
1009
 
975
1010
  /** Size no Figma: Medium (48x28) e Small (32x20). */
976
- type SwitchSize = 'medium' | 'small';
1011
+ type ToggleSwitchSize = 'medium' | 'small';
977
1012
  /** Label Position no Figma: lado do rótulo em relação ao switch. */
978
- type SwitchLabelPosition = 'right' | 'left';
1013
+ type ToggleSwitchLabelPosition = 'right' | 'left';
979
1014
  /** As demais props vão no <input> (aria-describedby, onBlur, data-*...); className e style, na raiz. */
980
- interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
1015
+ interface ToggleSwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onChange' | 'value' | 'checked' | 'defaultChecked' | 'defaultValue' | 'size' | 'type' | 'children'> {
981
1016
  /** Texto ao lado do switch (Label no Figma). Sem rótulo visível, vira o nome acessível. */
982
1017
  label: ReactNode;
983
1018
  /** Mostra o rótulo. Padrão: true. */
984
1019
  showLabel?: boolean;
985
1020
  /** Padrão: right. */
986
- labelPosition?: SwitchLabelPosition;
1021
+ labelPosition?: ToggleSwitchLabelPosition;
987
1022
  /** Padrão: medium. */
988
- size?: SwitchSize;
1023
+ size?: ToggleSwitchSize;
989
1024
  checked?: boolean;
990
1025
  onChange?: (event: InputSwitchChangeEvent) => void;
991
1026
  disabled?: boolean;
@@ -995,7 +1030,15 @@ interface SwitchProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'onCha
995
1030
  className?: string;
996
1031
  style?: CSSProperties;
997
1032
  }
998
- declare const Switch: react.ForwardRefExoticComponent<SwitchProps & react.RefAttributes<HTMLInputElement>>;
1033
+ declare const ToggleSwitch: react.ForwardRefExoticComponent<ToggleSwitchProps & react.RefAttributes<HTMLInputElement>>;
1034
+ /** @deprecated Use `ToggleSwitch` (o nome do PrimeNG 19). */
1035
+ declare const Switch: react.ForwardRefExoticComponent<ToggleSwitchProps & react.RefAttributes<HTMLInputElement>>;
1036
+ /** @deprecated Use `ToggleSwitchLabelPosition`. */
1037
+ type SwitchLabelPosition = ToggleSwitchLabelPosition;
1038
+ /** @deprecated Use `ToggleSwitchProps`. */
1039
+ type SwitchProps = ToggleSwitchProps;
1040
+ /** @deprecated Use `ToggleSwitchSize`. */
1041
+ type SwitchSize = ToggleSwitchSize;
999
1042
 
1000
1043
  /** Uma aba (.Tab Item no Figma) e o conteúdo dela. */
1001
1044
  interface TabPanelProps {
@@ -1190,5 +1233,5 @@ interface ToastProps {
1190
1233
  }
1191
1234
  declare const Toast: react.ForwardRefExoticComponent<ToastProps & react.RefAttributes<ToastHandle>>;
1192
1235
 
1193
- export { Accordion, AccordionTab, AutoComplete, Badge, Button, Calendar, Card, Chart, Checkbox, Chip, Column, ContextMenu, DATE_PERIODS, DatePicker, DateRangeButton, Divider, Drawer, IconButton, Input, Menu, MenuPrincipal, Menubar, Message, Modal, MultiSelect, PageHeader, Paginator, Panel, Radio, ScrollPanel, SegmentControl, Select, Skeleton, Switch, TabPanel, Table, TableRowActions, TableToolbar, Tabs, Tag, Toast, Tooltip };
1194
- export type { AccordionProps, AccordionTabProps, AutoCompleteProps, AutoCompleteSize, AutoCompleteVariant, BadgeProps, BadgeSize, BadgeVariant, ButtonProps, ButtonSize, ButtonVariant, CalendarHandle, CalendarProps, CardPadding, CardProps, ChartAxis, ChartColor, ChartProps, ChartSeries, CheckboxLabelSize, CheckboxPosition, CheckboxProps, ChipProps, ChipSize, ChipVariant, ColumnProps, ContextMenuHandle, ContextMenuItem, ContextMenuProps, DatePickerHandle, DatePickerProps, DatePickerSize, DatePickerVariant, DateRange, DateRangeButtonChangeEvent, DateRangeButtonProps, DateRangePeriod, DividerOrientation, DividerProps, DividerVariant, DrawerBehavior, DrawerHandle, DrawerProps, DrawerSide, DrawerSize, IconButtonProps, IconButtonSize, IconButtonVariant, InputProps, InputSize, InputVariant, MenuDensity, MenuHandle, MenuItem, MenuPrincipalEntry, MenuPrincipalGroup, MenuPrincipalHandle, MenuPrincipalItem, MenuPrincipalProps, MenuProps, MenubarProps, MenubarTool, MenubarUser, MessageProps, MessageType, ModalHandle, ModalProps, ModalSize, MultiSelectDensity, MultiSelectProps, MultiSelectSize, MultiSelectVariant, PageHeaderProps, PageHeaderTab, PageHeaderVariant, PaginatorPageChangeEvent, PaginatorProps, PanelProps, RadioLabelSize, RadioProps, ScrollPanelProps, SegmentControlOption, SegmentControlProps, SegmentControlVariant, SelectProps, SelectSize, SelectVariant, SkeletonProps, SkeletonShape, SwitchLabelPosition, SwitchProps, SwitchSize, TabPanelProps, TableFilter, TableHandle, TableProps, TableRowActionsProps, TableToolbarAction, TableToolbarProps, TabsProps, TagProps, TagSize, TagVariant, ToastHandle, ToastMessage, ToastPosition, ToastProps, ToastType, TooltipPosition, TooltipProps, TooltipType };
1236
+ export { Accordion, AccordionTab, AutoComplete, Badge, Button, Calendar, Card, Chart, Checkbox, Chip, Column, ContextMenu, DATE_PERIODS, DatePicker, DateRangeButton, Dialog, Divider, Drawer, IconButton, Input, InputText, Menu, MenuPrincipal, Menubar, Message, Modal, MultiSelect, PageHeader, Paginator, Panel, Radio, RadioButton, ScrollPanel, SegmentControl, Select, SelectButton, Skeleton, Switch, TabPanel, Table, TableRowActions, TableToolbar, Tabs, Tag, Toast, ToggleSwitch, Tooltip };
1237
+ export type { AccordionProps, AccordionTabProps, AutoCompleteProps, AutoCompleteSize, AutoCompleteVariant, BadgeProps, BadgeSize, BadgeVariant, ButtonProps, ButtonSize, ButtonVariant, CalendarHandle, CalendarProps, CardPadding, CardProps, ChartAxis, ChartColor, ChartProps, ChartSeries, CheckboxLabelSize, CheckboxPosition, CheckboxProps, ChipProps, ChipSize, ChipVariant, ColumnProps, ContextMenuHandle, ContextMenuItem, ContextMenuProps, DatePickerHandle, DatePickerProps, DatePickerSize, DatePickerVariant, DateRange, DateRangeButtonChangeEvent, DateRangeButtonProps, DateRangePeriod, DialogHandle, DialogProps, DialogSize, DividerOrientation, DividerProps, DividerVariant, DrawerBehavior, DrawerHandle, DrawerProps, DrawerSide, DrawerSize, IconButtonProps, IconButtonSize, IconButtonVariant, InputProps, InputSize, InputTextProps, InputTextSize, InputTextVariant, InputVariant, MenuDensity, MenuHandle, MenuItem, MenuPrincipalEntry, MenuPrincipalGroup, MenuPrincipalHandle, MenuPrincipalItem, MenuPrincipalProps, MenuProps, MenubarProps, MenubarTool, MenubarUser, MessageProps, MessageType, ModalHandle, ModalProps, ModalSize, MultiSelectDensity, MultiSelectProps, MultiSelectSize, MultiSelectVariant, PageHeaderProps, PageHeaderTab, PageHeaderVariant, PaginatorPageChangeEvent, PaginatorProps, PanelProps, RadioButtonLabelSize, RadioButtonProps, RadioLabelSize, RadioProps, ScrollPanelProps, SegmentControlOption, SegmentControlProps, SegmentControlVariant, SelectButtonOption, SelectButtonProps, SelectButtonVariant, SelectProps, SelectSize, SelectVariant, SkeletonProps, SkeletonShape, SwitchLabelPosition, SwitchProps, SwitchSize, TabPanelProps, TableFilter, TableHandle, TableProps, TableRowActionsProps, TableToolbarAction, TableToolbarProps, TabsProps, TagProps, TagSize, TagVariant, ToastHandle, ToastMessage, ToastPosition, ToastProps, ToastType, ToggleSwitchLabelPosition, ToggleSwitchProps, ToggleSwitchSize, TooltipPosition, TooltipProps, TooltipType };