@mlw-packages/react-components 1.5.5 → 1.5.7
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.css +578 -36
- package/dist/index.d.mts +202 -5
- package/dist/index.d.ts +202 -5
- package/dist/index.js +2323 -449
- package/dist/index.mjs +2350 -465
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -347,6 +347,16 @@ declare const LabelBase: React$1.ForwardRefExoticComponent<Omit<React$1.Detailed
|
|
|
347
347
|
testid?: string;
|
|
348
348
|
} & React$1.RefAttributes<HTMLLabelElement>>;
|
|
349
349
|
|
|
350
|
+
declare const loadingVariants: (props?: ({
|
|
351
|
+
size?: "sm" | "lg" | "md" | "xl" | null | undefined;
|
|
352
|
+
} & class_variance_authority_dist_types.ClassProp) | undefined) => string;
|
|
353
|
+
interface LoadingBaseProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof loadingVariants> {
|
|
354
|
+
message?: string;
|
|
355
|
+
overlay?: boolean;
|
|
356
|
+
variant?: "spinner" | "dots";
|
|
357
|
+
}
|
|
358
|
+
declare const LoadingBase: React$1.ForwardRefExoticComponent<LoadingBaseProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
359
|
+
|
|
350
360
|
declare function NavigationMenuBase({ className, children, viewport, ...props }: React$1.ComponentProps<typeof NavigationMenuPrimitive.Root> & {
|
|
351
361
|
viewport?: boolean;
|
|
352
362
|
}): react_jsx_runtime.JSX.Element;
|
|
@@ -565,30 +575,40 @@ interface DateTimePickerProps {
|
|
|
565
575
|
date: Date | undefined;
|
|
566
576
|
onChange: (date: Date | undefined) => void;
|
|
567
577
|
hideSeconds?: boolean;
|
|
578
|
+
hideHour?: boolean;
|
|
579
|
+
hideMinute?: boolean;
|
|
568
580
|
fromDate?: Date;
|
|
569
581
|
toDate?: Date;
|
|
570
582
|
disabled?: boolean;
|
|
571
|
-
|
|
583
|
+
className?: string;
|
|
572
584
|
}
|
|
573
|
-
declare function DateTimePicker({ label, date, onChange, hideSeconds, fromDate, toDate, disabled,
|
|
585
|
+
declare function DateTimePicker({ label, date, onChange, hideSeconds, hideHour, hideMinute, fromDate, toDate, disabled, className, }: DateTimePickerProps): react_jsx_runtime.JSX.Element;
|
|
574
586
|
|
|
575
587
|
interface TimePickerProps {
|
|
576
588
|
date: Date | undefined;
|
|
577
589
|
setDate: (date: Date | undefined) => void;
|
|
578
590
|
hideSeconds?: boolean;
|
|
591
|
+
enableButton?: boolean;
|
|
579
592
|
}
|
|
580
|
-
declare function TimePicker({ date, setDate, hideSeconds }: TimePickerProps): react_jsx_runtime.JSX.Element;
|
|
593
|
+
declare function TimePicker({ date, setDate, hideSeconds, enableButton, }: TimePickerProps): react_jsx_runtime.JSX.Element;
|
|
581
594
|
|
|
582
595
|
type TimePickerType = "minutes" | "seconds" | "hours" | "12hours";
|
|
583
596
|
type Period = "AM" | "PM";
|
|
584
597
|
|
|
585
|
-
interface TimePickerInputProps extends React__default.InputHTMLAttributes<HTMLInputElement> {
|
|
598
|
+
interface TimePickerInputProps extends Omit<React__default.InputHTMLAttributes<HTMLInputElement>, "size"> {
|
|
586
599
|
picker: TimePickerType;
|
|
587
600
|
date: Date | undefined;
|
|
588
601
|
setDate: (date: Date | undefined) => void;
|
|
589
602
|
period?: Period;
|
|
590
603
|
onRightFocus?: () => void;
|
|
591
604
|
onLeftFocus?: () => void;
|
|
605
|
+
showArrows?: boolean;
|
|
606
|
+
label?: string;
|
|
607
|
+
error?: boolean;
|
|
608
|
+
inputSize?: "sm" | "md" | "lg";
|
|
609
|
+
enableButton?: boolean;
|
|
610
|
+
buttonText?: string;
|
|
611
|
+
buttonIcon?: React__default.ReactNode;
|
|
592
612
|
}
|
|
593
613
|
declare const TimePickerInput: React__default.ForwardRefExoticComponent<TimePickerInputProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
594
614
|
|
|
@@ -685,6 +705,183 @@ interface DestructiveDialogProps {
|
|
|
685
705
|
}
|
|
686
706
|
declare const DestructiveDialog: React$1.FC<DestructiveDialogProps>;
|
|
687
707
|
|
|
708
|
+
interface Props$4 {
|
|
709
|
+
processedData: Array<{
|
|
710
|
+
name: string;
|
|
711
|
+
}>;
|
|
712
|
+
onOpenPeriod: (periodName: string) => void;
|
|
713
|
+
rightOffset?: number;
|
|
714
|
+
topOffset?: number;
|
|
715
|
+
activePeriod?: string;
|
|
716
|
+
activePeriods?: string[];
|
|
717
|
+
}
|
|
718
|
+
declare function PeriodsDropdown({ processedData, onOpenPeriod, rightOffset, topOffset, activePeriod, activePeriods, }: Props$4): react_jsx_runtime.JSX.Element;
|
|
719
|
+
|
|
720
|
+
interface Props$3 {
|
|
721
|
+
showOnlyHighlighted: boolean;
|
|
722
|
+
setShowOnlyHighlighted: React__default.Dispatch<React__default.SetStateAction<boolean>>;
|
|
723
|
+
highlightedSeriesSize: number;
|
|
724
|
+
clearHighlights: () => void;
|
|
725
|
+
}
|
|
726
|
+
/**
|
|
727
|
+
* ShowOnly
|
|
728
|
+
* - Botão principal alterna entre mostrar somente os itens destacados ou mostrar todos
|
|
729
|
+
* - Botão secundário limpa os destaques quando houver algum
|
|
730
|
+
* - Acessibilidade: aria-pressed, aria-labels e estados desabilitados
|
|
731
|
+
*/
|
|
732
|
+
declare const ShowOnly: React__default.FC<Props$3>;
|
|
733
|
+
|
|
734
|
+
interface MapperEntry {
|
|
735
|
+
label?: string;
|
|
736
|
+
formatter?: (value: string | number) => string | number;
|
|
737
|
+
color?: string;
|
|
738
|
+
type?: string;
|
|
739
|
+
visible?: boolean;
|
|
740
|
+
}
|
|
741
|
+
interface Props$2 {
|
|
742
|
+
allKeys: string[];
|
|
743
|
+
mapperConfig: Record<string, MapperEntry>;
|
|
744
|
+
finalColors: Record<string, string>;
|
|
745
|
+
highlightedSeries: Set<string>;
|
|
746
|
+
toggleHighlight: (key: string) => void;
|
|
747
|
+
containerWidth?: number;
|
|
748
|
+
}
|
|
749
|
+
declare const Highlights: React__default.FC<Props$2>;
|
|
750
|
+
|
|
751
|
+
interface CloseAllButtonProps {
|
|
752
|
+
count: number;
|
|
753
|
+
onCloseAll: () => void;
|
|
754
|
+
position?: "top-left" | "top-right" | "top-center";
|
|
755
|
+
variant?: "floating" | "inline";
|
|
756
|
+
}
|
|
757
|
+
declare const CloseAllButton: React__default.FC<CloseAllButtonProps>;
|
|
758
|
+
|
|
759
|
+
interface TooltipData {
|
|
760
|
+
name: string;
|
|
761
|
+
[key: string]: string | number;
|
|
762
|
+
}
|
|
763
|
+
interface Position$1 {
|
|
764
|
+
top: number;
|
|
765
|
+
left: number;
|
|
766
|
+
}
|
|
767
|
+
interface DraggableTooltipProps {
|
|
768
|
+
id: string;
|
|
769
|
+
data: TooltipData;
|
|
770
|
+
position: Position$1;
|
|
771
|
+
isDragging?: boolean;
|
|
772
|
+
title?: string;
|
|
773
|
+
dataKeys: string[];
|
|
774
|
+
finalColors: Record<string, string>;
|
|
775
|
+
onMouseDown?: (id: string, e: React__default.MouseEvent) => void;
|
|
776
|
+
onClose: (id: string) => void;
|
|
777
|
+
periodLabel?: string;
|
|
778
|
+
dataLabel?: string;
|
|
779
|
+
showCloseAllButton?: boolean;
|
|
780
|
+
globalTooltipCount?: number;
|
|
781
|
+
onCloseAll?: () => void;
|
|
782
|
+
closeAllButtonPosition?: "top-left" | "top-right" | "top-center";
|
|
783
|
+
closeAllButtonVariant?: "floating" | "inline";
|
|
784
|
+
onPositionChange?: (id: string, position: Position$1) => void;
|
|
785
|
+
highlightedSeries?: Set<string>;
|
|
786
|
+
toggleHighlight?: (key: string) => void;
|
|
787
|
+
showOnlyHighlighted?: boolean;
|
|
788
|
+
}
|
|
789
|
+
declare const DraggableTooltip: React__default.NamedExoticComponent<DraggableTooltipProps>;
|
|
790
|
+
|
|
791
|
+
type TooltipPayloadItem$1 = {
|
|
792
|
+
dataKey: string;
|
|
793
|
+
value: number;
|
|
794
|
+
name: string;
|
|
795
|
+
color?: string;
|
|
796
|
+
};
|
|
797
|
+
interface Props$1 {
|
|
798
|
+
active?: boolean;
|
|
799
|
+
payload?: TooltipPayloadItem$1[];
|
|
800
|
+
label?: string;
|
|
801
|
+
finalColors?: Record<string, string>;
|
|
802
|
+
periodLabel?: string;
|
|
803
|
+
totalLabel?: string;
|
|
804
|
+
}
|
|
805
|
+
declare const RechartTooltipWithTotal: React__default.FC<Props$1>;
|
|
806
|
+
|
|
807
|
+
type TooltipPayloadItem = {
|
|
808
|
+
dataKey: string;
|
|
809
|
+
value: number;
|
|
810
|
+
name: string;
|
|
811
|
+
color?: string;
|
|
812
|
+
};
|
|
813
|
+
interface Props {
|
|
814
|
+
active?: boolean;
|
|
815
|
+
payload?: TooltipPayloadItem[];
|
|
816
|
+
label?: string;
|
|
817
|
+
finalColors?: Record<string, string>;
|
|
818
|
+
periodLabel?: string;
|
|
819
|
+
}
|
|
820
|
+
declare const TooltipSimple: React__default.FC<Props>;
|
|
821
|
+
|
|
822
|
+
declare const formatFieldName: (fieldName: string) => string;
|
|
823
|
+
declare const detectDataFields: (data: Record<string, unknown>[], xAxisKey: string) => string[];
|
|
824
|
+
declare const detectXAxis: (data: Record<string, unknown>[]) => string;
|
|
825
|
+
declare const generateAdditionalColors: (baseColors: string[], count: number) => string[];
|
|
826
|
+
declare const niceCeil: (value: number) => number;
|
|
827
|
+
declare const compactTick: (value: number) => string;
|
|
828
|
+
type Padding = number | Partial<{
|
|
829
|
+
left: number;
|
|
830
|
+
right: number;
|
|
831
|
+
top: number;
|
|
832
|
+
bottom: number;
|
|
833
|
+
}>;
|
|
834
|
+
type Margins = Partial<{
|
|
835
|
+
top: number;
|
|
836
|
+
right: number;
|
|
837
|
+
left: number;
|
|
838
|
+
bottom: number;
|
|
839
|
+
}>;
|
|
840
|
+
declare const resolveContainerPaddingLeft: (padding?: Padding, containerPaddingLeft?: number, defaultLeft?: number) => number;
|
|
841
|
+
declare const resolveChartMargins: (margins?: Margins, chartMargins?: Margins, showLabels?: boolean) => {
|
|
842
|
+
top: number;
|
|
843
|
+
right: number;
|
|
844
|
+
left: number;
|
|
845
|
+
bottom: number;
|
|
846
|
+
};
|
|
847
|
+
|
|
848
|
+
type Variant = "filled" | "outline" | "soft";
|
|
849
|
+
type LabelRendererProps = {
|
|
850
|
+
x?: number | string;
|
|
851
|
+
y?: number | string;
|
|
852
|
+
value?: number | string;
|
|
853
|
+
index?: number;
|
|
854
|
+
payload?: unknown;
|
|
855
|
+
width?: number | string;
|
|
856
|
+
height?: number | string;
|
|
857
|
+
viewBox?: {
|
|
858
|
+
x?: number;
|
|
859
|
+
y?: number;
|
|
860
|
+
width?: number;
|
|
861
|
+
height?: number;
|
|
862
|
+
} | Record<string, unknown> | undefined;
|
|
863
|
+
cx?: number | string;
|
|
864
|
+
cy?: number | string;
|
|
865
|
+
};
|
|
866
|
+
declare const renderPillLabel: (color: string, variant: Variant) => (props: LabelRendererProps) => react_jsx_runtime.JSX.Element;
|
|
867
|
+
|
|
688
868
|
declare function useIsMobile(): boolean;
|
|
689
869
|
|
|
690
|
-
|
|
870
|
+
interface Position {
|
|
871
|
+
top: number;
|
|
872
|
+
left: number;
|
|
873
|
+
}
|
|
874
|
+
interface UseDragOptions {
|
|
875
|
+
onDragStart?: (id: string) => void;
|
|
876
|
+
onDragEnd?: (id: string) => void;
|
|
877
|
+
onDrag?: (id: string, position: Position) => void;
|
|
878
|
+
}
|
|
879
|
+
declare const useDrag: (options?: UseDragOptions) => {
|
|
880
|
+
handleMouseDown: (id: string, e: React.MouseEvent) => void;
|
|
881
|
+
getPosition: (id: string) => Position;
|
|
882
|
+
setPosition: (id: string, position: Position) => void;
|
|
883
|
+
isElementDragging: (id: string) => boolean;
|
|
884
|
+
isDragging: boolean;
|
|
885
|
+
};
|
|
886
|
+
|
|
887
|
+
export { AlertDialogActionBase, AlertDialogBase, AlertDialogCancelBase, AlertDialogContentBase, AlertDialogDescriptionBase, AlertDialogFooterBase, AlertDialogHeaderBase, AlertDialogOverlayBase, AlertDialogPortalBase, AlertDialogTitleBase, AlertDialogTriggerBase, AvatarBase, AvatarFallbackBase, AvatarImageBase, BadgeBase, BreadcrumbBase, BreadcrumbEllipsisBase, BreadcrumbItemBase, BreadcrumbLinkBase, BreadcrumbListBase, BreadcrumbPageBase, BreadcrumbSeparatorBase, ButtonBase, ButtonGroupBase, type ButtonProps, CalendarBase, type CalendarProps, CardBase, CardContentBase, CardDescriptionBase, CardFooterBase, CardHeaderBase, CardTitleBase, type CarouselApi, CarouselBase, CarouselContentBase, CarouselItemBase, CarouselNextBase, CarouselPrevious, CheckboxBase, CloseAllButton, CollapsibleBase, CollapsibleContentBase, CollapsibleTriggerBase, Combobox, type ComboboxProps, type ComboboxTestIds, CommandBase, CommandDialogBase, CommandEmptyBase, CommandGroupBase, CommandInputBase, CommandItemBase, CommandListBase, CommandSeparatorBase, CommandShortcutBase, ContextMenuBase, ContextMenuCheckboxItemBase, ContextMenuContentBase, ContextMenuGroupBase, ContextMenuItemBase, ContextMenuLabelBase, ContextMenuPortalBase, ContextMenuRadioGroupBase, ContextMenuRadioItemBase, ContextMenuSeparatorBase, ContextMenuShortcutBase, ContextMenuSubBase, ContextMenuSubContentBase, ContextMenuSubTriggerBase, ContextMenuTriggerBase, DateTimePicker, DestructiveDialog, DialogBase, DialogCloseBase, DialogContentBase, DialogDescriptionBase, DialogFooterBase, DialogHeaderBase, DialogOverlayBase, DialogPortalBase, DialogTitleBase, DialogTriggerBase, DraggableTooltip, DrawerBase, DrawerCloseBase, DrawerContentBase, DrawerDescriptionBase, DrawerFooterBase, DrawerHeaderBase, DrawerOverlayBase, DrawerPortalBase, DrawerTitleBase, DrawerTriggerBase, DropDownMenuBase, DropDownMenuCheckboxItemBase, DropDownMenuContentBase, DropDownMenuGroupBase, DropDownMenuItemBase, DropDownMenuLabelBase, DropDownMenuPortalBase, DropDownMenuRadioGroupBase, DropDownMenuRadioItemBase, DropDownMenuSeparatorBase, DropDownMenuShortcutBase, DropDownMenuSubBase, DropDownMenuSubContentBase, DropDownMenuSubTriggerBase, DropDownMenuTriggerBase, Highlights, HoverCardBase, HoverCardContentBase, HoverCardTriggerBase, InputBase, type InputBaseProps, InputOTPBase, InputOTPGroupBase, InputOTPSeparatorBase, InputOTPSlotBase, LabelBase, LoadingBase, type Margins, ModeToggleBase, MultiCombobox, NavigationMenuBase, NavigationMenuContentBase, NavigationMenuIndicatorBase, NavigationMenuItemBase, NavigationMenuLinkBase, NavigationMenuListBase, NavigationMenuTriggerBase, NavigationMenuViewportBase, type Padding, PeriodsDropdown, PopoverAnchorBase, PopoverBase, PopoverContentBase, PopoverTriggerBase, ProgressBase, type ProgressBaseProps, ProgressCirclesBase, type ProgressCirclesBaseProps, ProgressPanelsBase, type ProgressPanelsBaseProps, ProgressSegmentsBase, type ProgressSegmentsBaseProps, ScrollAreaBase, ScrollBarBase, Select, SelectBase, SelectContentBase, SelectGroupBase, type SelectItem, SelectItemBase, SelectLabelBase, SelectScrollDownButtonBase, SelectScrollUpButtonBase, SelectSeparatorBase, SelectTriggerBase, SelectValueBase, SeparatorBase, SheetBase, SheetCloseBase, SheetContentBase, SheetDescriptionBase, SheetFooterBase, SheetHeaderBase, SheetOverlayBase, SheetPortalBase, SheetTitleBase, SheetTriggerBase, ShowOnly, SidebarBase, SidebarContentBase, SidebarFooterBase, SidebarGroupActionBase, SidebarGroupBase, SidebarGroupContentBase, SidebarGroupLabelBase, SidebarHeaderBase, SidebarInputBase, SidebarInsetBase, SidebarMenuActionBase, SidebarMenuBadgeBase, SidebarMenuBase, SidebarMenuButtonBase, SidebarMenuItemBase, SidebarMenuSkeletonBase, SidebarMenuSubBase, SidebarMenuSubButtonBase, SidebarMenuSubItemBase, SidebarProviderBase, SidebarRailBase, SidebarSeparatorBase, SidebarTriggerBase, SkeletonBase, SlideBase, type SliderBaseProps, SwitchBase, TableBase, TableBodyBase, TableCaptionBase, TableCellBase, TableFooterBase, TableHeadBase, TableHeaderBase, TableRowBase, TabsBase, TabsContentBase, TabsListBase, TabsTriggerBase, TextAreaBase, type Theme, ThemeProviderBase, TimePicker, TimePickerInput, type TimePickerInputProps, Toaster, TooltipBase, TooltipContentBase, TooltipProviderBase, TooltipSimple, TooltipTriggerBase, RechartTooltipWithTotal as TooltipWithTotal, UseSideBarBase, badgeVariants, buttonVariantsBase, compactTick, detectDataFields, detectXAxis, formatFieldName, generateAdditionalColors, niceCeil, renderPillLabel, resolveChartMargins, resolveContainerPaddingLeft, toast, useDrag, useIsMobile, useTheme };
|
package/dist/index.d.ts
CHANGED
|
@@ -347,6 +347,16 @@ declare const LabelBase: React$1.ForwardRefExoticComponent<Omit<React$1.Detailed
|
|
|
347
347
|
testid?: string;
|
|
348
348
|
} & React$1.RefAttributes<HTMLLabelElement>>;
|
|
349
349
|
|
|
350
|
+
declare const loadingVariants: (props?: ({
|
|
351
|
+
size?: "sm" | "lg" | "md" | "xl" | null | undefined;
|
|
352
|
+
} & class_variance_authority_dist_types.ClassProp) | undefined) => string;
|
|
353
|
+
interface LoadingBaseProps extends React$1.HTMLAttributes<HTMLDivElement>, VariantProps<typeof loadingVariants> {
|
|
354
|
+
message?: string;
|
|
355
|
+
overlay?: boolean;
|
|
356
|
+
variant?: "spinner" | "dots";
|
|
357
|
+
}
|
|
358
|
+
declare const LoadingBase: React$1.ForwardRefExoticComponent<LoadingBaseProps & React$1.RefAttributes<HTMLDivElement>>;
|
|
359
|
+
|
|
350
360
|
declare function NavigationMenuBase({ className, children, viewport, ...props }: React$1.ComponentProps<typeof NavigationMenuPrimitive.Root> & {
|
|
351
361
|
viewport?: boolean;
|
|
352
362
|
}): react_jsx_runtime.JSX.Element;
|
|
@@ -565,30 +575,40 @@ interface DateTimePickerProps {
|
|
|
565
575
|
date: Date | undefined;
|
|
566
576
|
onChange: (date: Date | undefined) => void;
|
|
567
577
|
hideSeconds?: boolean;
|
|
578
|
+
hideHour?: boolean;
|
|
579
|
+
hideMinute?: boolean;
|
|
568
580
|
fromDate?: Date;
|
|
569
581
|
toDate?: Date;
|
|
570
582
|
disabled?: boolean;
|
|
571
|
-
|
|
583
|
+
className?: string;
|
|
572
584
|
}
|
|
573
|
-
declare function DateTimePicker({ label, date, onChange, hideSeconds, fromDate, toDate, disabled,
|
|
585
|
+
declare function DateTimePicker({ label, date, onChange, hideSeconds, hideHour, hideMinute, fromDate, toDate, disabled, className, }: DateTimePickerProps): react_jsx_runtime.JSX.Element;
|
|
574
586
|
|
|
575
587
|
interface TimePickerProps {
|
|
576
588
|
date: Date | undefined;
|
|
577
589
|
setDate: (date: Date | undefined) => void;
|
|
578
590
|
hideSeconds?: boolean;
|
|
591
|
+
enableButton?: boolean;
|
|
579
592
|
}
|
|
580
|
-
declare function TimePicker({ date, setDate, hideSeconds }: TimePickerProps): react_jsx_runtime.JSX.Element;
|
|
593
|
+
declare function TimePicker({ date, setDate, hideSeconds, enableButton, }: TimePickerProps): react_jsx_runtime.JSX.Element;
|
|
581
594
|
|
|
582
595
|
type TimePickerType = "minutes" | "seconds" | "hours" | "12hours";
|
|
583
596
|
type Period = "AM" | "PM";
|
|
584
597
|
|
|
585
|
-
interface TimePickerInputProps extends React__default.InputHTMLAttributes<HTMLInputElement> {
|
|
598
|
+
interface TimePickerInputProps extends Omit<React__default.InputHTMLAttributes<HTMLInputElement>, "size"> {
|
|
586
599
|
picker: TimePickerType;
|
|
587
600
|
date: Date | undefined;
|
|
588
601
|
setDate: (date: Date | undefined) => void;
|
|
589
602
|
period?: Period;
|
|
590
603
|
onRightFocus?: () => void;
|
|
591
604
|
onLeftFocus?: () => void;
|
|
605
|
+
showArrows?: boolean;
|
|
606
|
+
label?: string;
|
|
607
|
+
error?: boolean;
|
|
608
|
+
inputSize?: "sm" | "md" | "lg";
|
|
609
|
+
enableButton?: boolean;
|
|
610
|
+
buttonText?: string;
|
|
611
|
+
buttonIcon?: React__default.ReactNode;
|
|
592
612
|
}
|
|
593
613
|
declare const TimePickerInput: React__default.ForwardRefExoticComponent<TimePickerInputProps & React__default.RefAttributes<HTMLInputElement>>;
|
|
594
614
|
|
|
@@ -685,6 +705,183 @@ interface DestructiveDialogProps {
|
|
|
685
705
|
}
|
|
686
706
|
declare const DestructiveDialog: React$1.FC<DestructiveDialogProps>;
|
|
687
707
|
|
|
708
|
+
interface Props$4 {
|
|
709
|
+
processedData: Array<{
|
|
710
|
+
name: string;
|
|
711
|
+
}>;
|
|
712
|
+
onOpenPeriod: (periodName: string) => void;
|
|
713
|
+
rightOffset?: number;
|
|
714
|
+
topOffset?: number;
|
|
715
|
+
activePeriod?: string;
|
|
716
|
+
activePeriods?: string[];
|
|
717
|
+
}
|
|
718
|
+
declare function PeriodsDropdown({ processedData, onOpenPeriod, rightOffset, topOffset, activePeriod, activePeriods, }: Props$4): react_jsx_runtime.JSX.Element;
|
|
719
|
+
|
|
720
|
+
interface Props$3 {
|
|
721
|
+
showOnlyHighlighted: boolean;
|
|
722
|
+
setShowOnlyHighlighted: React__default.Dispatch<React__default.SetStateAction<boolean>>;
|
|
723
|
+
highlightedSeriesSize: number;
|
|
724
|
+
clearHighlights: () => void;
|
|
725
|
+
}
|
|
726
|
+
/**
|
|
727
|
+
* ShowOnly
|
|
728
|
+
* - Botão principal alterna entre mostrar somente os itens destacados ou mostrar todos
|
|
729
|
+
* - Botão secundário limpa os destaques quando houver algum
|
|
730
|
+
* - Acessibilidade: aria-pressed, aria-labels e estados desabilitados
|
|
731
|
+
*/
|
|
732
|
+
declare const ShowOnly: React__default.FC<Props$3>;
|
|
733
|
+
|
|
734
|
+
interface MapperEntry {
|
|
735
|
+
label?: string;
|
|
736
|
+
formatter?: (value: string | number) => string | number;
|
|
737
|
+
color?: string;
|
|
738
|
+
type?: string;
|
|
739
|
+
visible?: boolean;
|
|
740
|
+
}
|
|
741
|
+
interface Props$2 {
|
|
742
|
+
allKeys: string[];
|
|
743
|
+
mapperConfig: Record<string, MapperEntry>;
|
|
744
|
+
finalColors: Record<string, string>;
|
|
745
|
+
highlightedSeries: Set<string>;
|
|
746
|
+
toggleHighlight: (key: string) => void;
|
|
747
|
+
containerWidth?: number;
|
|
748
|
+
}
|
|
749
|
+
declare const Highlights: React__default.FC<Props$2>;
|
|
750
|
+
|
|
751
|
+
interface CloseAllButtonProps {
|
|
752
|
+
count: number;
|
|
753
|
+
onCloseAll: () => void;
|
|
754
|
+
position?: "top-left" | "top-right" | "top-center";
|
|
755
|
+
variant?: "floating" | "inline";
|
|
756
|
+
}
|
|
757
|
+
declare const CloseAllButton: React__default.FC<CloseAllButtonProps>;
|
|
758
|
+
|
|
759
|
+
interface TooltipData {
|
|
760
|
+
name: string;
|
|
761
|
+
[key: string]: string | number;
|
|
762
|
+
}
|
|
763
|
+
interface Position$1 {
|
|
764
|
+
top: number;
|
|
765
|
+
left: number;
|
|
766
|
+
}
|
|
767
|
+
interface DraggableTooltipProps {
|
|
768
|
+
id: string;
|
|
769
|
+
data: TooltipData;
|
|
770
|
+
position: Position$1;
|
|
771
|
+
isDragging?: boolean;
|
|
772
|
+
title?: string;
|
|
773
|
+
dataKeys: string[];
|
|
774
|
+
finalColors: Record<string, string>;
|
|
775
|
+
onMouseDown?: (id: string, e: React__default.MouseEvent) => void;
|
|
776
|
+
onClose: (id: string) => void;
|
|
777
|
+
periodLabel?: string;
|
|
778
|
+
dataLabel?: string;
|
|
779
|
+
showCloseAllButton?: boolean;
|
|
780
|
+
globalTooltipCount?: number;
|
|
781
|
+
onCloseAll?: () => void;
|
|
782
|
+
closeAllButtonPosition?: "top-left" | "top-right" | "top-center";
|
|
783
|
+
closeAllButtonVariant?: "floating" | "inline";
|
|
784
|
+
onPositionChange?: (id: string, position: Position$1) => void;
|
|
785
|
+
highlightedSeries?: Set<string>;
|
|
786
|
+
toggleHighlight?: (key: string) => void;
|
|
787
|
+
showOnlyHighlighted?: boolean;
|
|
788
|
+
}
|
|
789
|
+
declare const DraggableTooltip: React__default.NamedExoticComponent<DraggableTooltipProps>;
|
|
790
|
+
|
|
791
|
+
type TooltipPayloadItem$1 = {
|
|
792
|
+
dataKey: string;
|
|
793
|
+
value: number;
|
|
794
|
+
name: string;
|
|
795
|
+
color?: string;
|
|
796
|
+
};
|
|
797
|
+
interface Props$1 {
|
|
798
|
+
active?: boolean;
|
|
799
|
+
payload?: TooltipPayloadItem$1[];
|
|
800
|
+
label?: string;
|
|
801
|
+
finalColors?: Record<string, string>;
|
|
802
|
+
periodLabel?: string;
|
|
803
|
+
totalLabel?: string;
|
|
804
|
+
}
|
|
805
|
+
declare const RechartTooltipWithTotal: React__default.FC<Props$1>;
|
|
806
|
+
|
|
807
|
+
type TooltipPayloadItem = {
|
|
808
|
+
dataKey: string;
|
|
809
|
+
value: number;
|
|
810
|
+
name: string;
|
|
811
|
+
color?: string;
|
|
812
|
+
};
|
|
813
|
+
interface Props {
|
|
814
|
+
active?: boolean;
|
|
815
|
+
payload?: TooltipPayloadItem[];
|
|
816
|
+
label?: string;
|
|
817
|
+
finalColors?: Record<string, string>;
|
|
818
|
+
periodLabel?: string;
|
|
819
|
+
}
|
|
820
|
+
declare const TooltipSimple: React__default.FC<Props>;
|
|
821
|
+
|
|
822
|
+
declare const formatFieldName: (fieldName: string) => string;
|
|
823
|
+
declare const detectDataFields: (data: Record<string, unknown>[], xAxisKey: string) => string[];
|
|
824
|
+
declare const detectXAxis: (data: Record<string, unknown>[]) => string;
|
|
825
|
+
declare const generateAdditionalColors: (baseColors: string[], count: number) => string[];
|
|
826
|
+
declare const niceCeil: (value: number) => number;
|
|
827
|
+
declare const compactTick: (value: number) => string;
|
|
828
|
+
type Padding = number | Partial<{
|
|
829
|
+
left: number;
|
|
830
|
+
right: number;
|
|
831
|
+
top: number;
|
|
832
|
+
bottom: number;
|
|
833
|
+
}>;
|
|
834
|
+
type Margins = Partial<{
|
|
835
|
+
top: number;
|
|
836
|
+
right: number;
|
|
837
|
+
left: number;
|
|
838
|
+
bottom: number;
|
|
839
|
+
}>;
|
|
840
|
+
declare const resolveContainerPaddingLeft: (padding?: Padding, containerPaddingLeft?: number, defaultLeft?: number) => number;
|
|
841
|
+
declare const resolveChartMargins: (margins?: Margins, chartMargins?: Margins, showLabels?: boolean) => {
|
|
842
|
+
top: number;
|
|
843
|
+
right: number;
|
|
844
|
+
left: number;
|
|
845
|
+
bottom: number;
|
|
846
|
+
};
|
|
847
|
+
|
|
848
|
+
type Variant = "filled" | "outline" | "soft";
|
|
849
|
+
type LabelRendererProps = {
|
|
850
|
+
x?: number | string;
|
|
851
|
+
y?: number | string;
|
|
852
|
+
value?: number | string;
|
|
853
|
+
index?: number;
|
|
854
|
+
payload?: unknown;
|
|
855
|
+
width?: number | string;
|
|
856
|
+
height?: number | string;
|
|
857
|
+
viewBox?: {
|
|
858
|
+
x?: number;
|
|
859
|
+
y?: number;
|
|
860
|
+
width?: number;
|
|
861
|
+
height?: number;
|
|
862
|
+
} | Record<string, unknown> | undefined;
|
|
863
|
+
cx?: number | string;
|
|
864
|
+
cy?: number | string;
|
|
865
|
+
};
|
|
866
|
+
declare const renderPillLabel: (color: string, variant: Variant) => (props: LabelRendererProps) => react_jsx_runtime.JSX.Element;
|
|
867
|
+
|
|
688
868
|
declare function useIsMobile(): boolean;
|
|
689
869
|
|
|
690
|
-
|
|
870
|
+
interface Position {
|
|
871
|
+
top: number;
|
|
872
|
+
left: number;
|
|
873
|
+
}
|
|
874
|
+
interface UseDragOptions {
|
|
875
|
+
onDragStart?: (id: string) => void;
|
|
876
|
+
onDragEnd?: (id: string) => void;
|
|
877
|
+
onDrag?: (id: string, position: Position) => void;
|
|
878
|
+
}
|
|
879
|
+
declare const useDrag: (options?: UseDragOptions) => {
|
|
880
|
+
handleMouseDown: (id: string, e: React.MouseEvent) => void;
|
|
881
|
+
getPosition: (id: string) => Position;
|
|
882
|
+
setPosition: (id: string, position: Position) => void;
|
|
883
|
+
isElementDragging: (id: string) => boolean;
|
|
884
|
+
isDragging: boolean;
|
|
885
|
+
};
|
|
886
|
+
|
|
887
|
+
export { AlertDialogActionBase, AlertDialogBase, AlertDialogCancelBase, AlertDialogContentBase, AlertDialogDescriptionBase, AlertDialogFooterBase, AlertDialogHeaderBase, AlertDialogOverlayBase, AlertDialogPortalBase, AlertDialogTitleBase, AlertDialogTriggerBase, AvatarBase, AvatarFallbackBase, AvatarImageBase, BadgeBase, BreadcrumbBase, BreadcrumbEllipsisBase, BreadcrumbItemBase, BreadcrumbLinkBase, BreadcrumbListBase, BreadcrumbPageBase, BreadcrumbSeparatorBase, ButtonBase, ButtonGroupBase, type ButtonProps, CalendarBase, type CalendarProps, CardBase, CardContentBase, CardDescriptionBase, CardFooterBase, CardHeaderBase, CardTitleBase, type CarouselApi, CarouselBase, CarouselContentBase, CarouselItemBase, CarouselNextBase, CarouselPrevious, CheckboxBase, CloseAllButton, CollapsibleBase, CollapsibleContentBase, CollapsibleTriggerBase, Combobox, type ComboboxProps, type ComboboxTestIds, CommandBase, CommandDialogBase, CommandEmptyBase, CommandGroupBase, CommandInputBase, CommandItemBase, CommandListBase, CommandSeparatorBase, CommandShortcutBase, ContextMenuBase, ContextMenuCheckboxItemBase, ContextMenuContentBase, ContextMenuGroupBase, ContextMenuItemBase, ContextMenuLabelBase, ContextMenuPortalBase, ContextMenuRadioGroupBase, ContextMenuRadioItemBase, ContextMenuSeparatorBase, ContextMenuShortcutBase, ContextMenuSubBase, ContextMenuSubContentBase, ContextMenuSubTriggerBase, ContextMenuTriggerBase, DateTimePicker, DestructiveDialog, DialogBase, DialogCloseBase, DialogContentBase, DialogDescriptionBase, DialogFooterBase, DialogHeaderBase, DialogOverlayBase, DialogPortalBase, DialogTitleBase, DialogTriggerBase, DraggableTooltip, DrawerBase, DrawerCloseBase, DrawerContentBase, DrawerDescriptionBase, DrawerFooterBase, DrawerHeaderBase, DrawerOverlayBase, DrawerPortalBase, DrawerTitleBase, DrawerTriggerBase, DropDownMenuBase, DropDownMenuCheckboxItemBase, DropDownMenuContentBase, DropDownMenuGroupBase, DropDownMenuItemBase, DropDownMenuLabelBase, DropDownMenuPortalBase, DropDownMenuRadioGroupBase, DropDownMenuRadioItemBase, DropDownMenuSeparatorBase, DropDownMenuShortcutBase, DropDownMenuSubBase, DropDownMenuSubContentBase, DropDownMenuSubTriggerBase, DropDownMenuTriggerBase, Highlights, HoverCardBase, HoverCardContentBase, HoverCardTriggerBase, InputBase, type InputBaseProps, InputOTPBase, InputOTPGroupBase, InputOTPSeparatorBase, InputOTPSlotBase, LabelBase, LoadingBase, type Margins, ModeToggleBase, MultiCombobox, NavigationMenuBase, NavigationMenuContentBase, NavigationMenuIndicatorBase, NavigationMenuItemBase, NavigationMenuLinkBase, NavigationMenuListBase, NavigationMenuTriggerBase, NavigationMenuViewportBase, type Padding, PeriodsDropdown, PopoverAnchorBase, PopoverBase, PopoverContentBase, PopoverTriggerBase, ProgressBase, type ProgressBaseProps, ProgressCirclesBase, type ProgressCirclesBaseProps, ProgressPanelsBase, type ProgressPanelsBaseProps, ProgressSegmentsBase, type ProgressSegmentsBaseProps, ScrollAreaBase, ScrollBarBase, Select, SelectBase, SelectContentBase, SelectGroupBase, type SelectItem, SelectItemBase, SelectLabelBase, SelectScrollDownButtonBase, SelectScrollUpButtonBase, SelectSeparatorBase, SelectTriggerBase, SelectValueBase, SeparatorBase, SheetBase, SheetCloseBase, SheetContentBase, SheetDescriptionBase, SheetFooterBase, SheetHeaderBase, SheetOverlayBase, SheetPortalBase, SheetTitleBase, SheetTriggerBase, ShowOnly, SidebarBase, SidebarContentBase, SidebarFooterBase, SidebarGroupActionBase, SidebarGroupBase, SidebarGroupContentBase, SidebarGroupLabelBase, SidebarHeaderBase, SidebarInputBase, SidebarInsetBase, SidebarMenuActionBase, SidebarMenuBadgeBase, SidebarMenuBase, SidebarMenuButtonBase, SidebarMenuItemBase, SidebarMenuSkeletonBase, SidebarMenuSubBase, SidebarMenuSubButtonBase, SidebarMenuSubItemBase, SidebarProviderBase, SidebarRailBase, SidebarSeparatorBase, SidebarTriggerBase, SkeletonBase, SlideBase, type SliderBaseProps, SwitchBase, TableBase, TableBodyBase, TableCaptionBase, TableCellBase, TableFooterBase, TableHeadBase, TableHeaderBase, TableRowBase, TabsBase, TabsContentBase, TabsListBase, TabsTriggerBase, TextAreaBase, type Theme, ThemeProviderBase, TimePicker, TimePickerInput, type TimePickerInputProps, Toaster, TooltipBase, TooltipContentBase, TooltipProviderBase, TooltipSimple, TooltipTriggerBase, RechartTooltipWithTotal as TooltipWithTotal, UseSideBarBase, badgeVariants, buttonVariantsBase, compactTick, detectDataFields, detectXAxis, formatFieldName, generateAdditionalColors, niceCeil, renderPillLabel, resolveChartMargins, resolveContainerPaddingLeft, toast, useDrag, useIsMobile, useTheme };
|