design-zystem 1.0.443 → 1.0.445
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/ui/index.d.mts +28 -21
- package/dist/ui/index.d.ts +28 -21
- package/dist/ui/index.js +91 -49
- package/dist/ui/index.mjs +91 -49
- package/package.json +1 -1
package/dist/ui/index.d.mts
CHANGED
|
@@ -2055,35 +2055,42 @@ interface DatePickerProps {
|
|
|
2055
2055
|
declare const DatePicker: ({ mode, value, onChange, startDate, endDate, onRangeChange, showPresets, presets, placeholder, disabled, minDate, maxDate, width, align, className, }: DatePickerProps) => react.JSX.Element;
|
|
2056
2056
|
|
|
2057
2057
|
declare const ZONE_POSITIONS: {
|
|
2058
|
-
readonly front: readonly [
|
|
2059
|
-
readonly hood: readonly [
|
|
2060
|
-
readonly windshield: readonly [
|
|
2061
|
-
readonly roof: readonly [
|
|
2062
|
-
readonly trunk: readonly [
|
|
2063
|
-
readonly rear: readonly [
|
|
2064
|
-
readonly
|
|
2065
|
-
readonly
|
|
2066
|
-
readonly
|
|
2067
|
-
readonly
|
|
2068
|
-
readonly
|
|
2069
|
-
readonly
|
|
2070
|
-
readonly
|
|
2071
|
-
readonly
|
|
2072
|
-
readonly
|
|
2073
|
-
readonly
|
|
2074
|
-
readonly
|
|
2075
|
-
readonly
|
|
2058
|
+
readonly front: readonly [32, 70];
|
|
2059
|
+
readonly hood: readonly [62, 70];
|
|
2060
|
+
readonly windshield: readonly [86, 70];
|
|
2061
|
+
readonly roof: readonly [128, 70];
|
|
2062
|
+
readonly trunk: readonly [188, 70];
|
|
2063
|
+
readonly rear: readonly [208, 70];
|
|
2064
|
+
readonly frontRightCorner: readonly [44, 36];
|
|
2065
|
+
readonly frontLeftCorner: readonly [44, 104];
|
|
2066
|
+
readonly frontRightWheel: readonly [66, 25];
|
|
2067
|
+
readonly frontLeftWheel: readonly [66, 115];
|
|
2068
|
+
readonly frontRightSide: readonly [104, 31];
|
|
2069
|
+
readonly frontLeftSide: readonly [104, 109];
|
|
2070
|
+
readonly rearRightSide: readonly [146, 31];
|
|
2071
|
+
readonly rearLeftSide: readonly [146, 109];
|
|
2072
|
+
readonly rearRightWheel: readonly [174, 25];
|
|
2073
|
+
readonly rearLeftWheel: readonly [174, 115];
|
|
2074
|
+
readonly rearRightCorner: readonly [196, 36];
|
|
2075
|
+
readonly rearLeftCorner: readonly [196, 104];
|
|
2076
2076
|
};
|
|
2077
2077
|
type VehicleDamageZone = keyof typeof ZONE_POSITIONS;
|
|
2078
2078
|
declare const VEHICLE_DAMAGE_ZONES: VehicleDamageZone[];
|
|
2079
2079
|
interface VehicleDamageMark {
|
|
2080
2080
|
zone: VehicleDamageZone;
|
|
2081
|
-
|
|
2081
|
+
content?: string;
|
|
2082
2082
|
label?: string;
|
|
2083
|
-
tone?: 'danger' | 'warning';
|
|
2083
|
+
tone?: 'danger' | 'warning' | 'neutral';
|
|
2084
|
+
}
|
|
2085
|
+
interface VehicleDamageMapSideLabels {
|
|
2086
|
+
front: string;
|
|
2087
|
+
rear: string;
|
|
2088
|
+
left: string;
|
|
2089
|
+
right: string;
|
|
2084
2090
|
}
|
|
2085
2091
|
interface VehicleDamageMapProps extends HTMLAttributes<HTMLDivElement> {
|
|
2086
2092
|
marks: VehicleDamageMark[];
|
|
2093
|
+
sideLabels?: VehicleDamageMapSideLabels;
|
|
2087
2094
|
selectedZone?: VehicleDamageZone | null;
|
|
2088
2095
|
onZoneClick?: (zone: VehicleDamageZone) => void;
|
|
2089
2096
|
width?: number;
|
|
@@ -2346,4 +2353,4 @@ interface TourTargetProps {
|
|
|
2346
2353
|
declare const TourTarget: ({ id, children }: TourTargetProps) => react.JSX.Element;
|
|
2347
2354
|
declare const Tour: ({ steps, open, step, onStepChange, onClose, labels, targetTimeout, }: TourProps) => null;
|
|
2348
2355
|
|
|
2349
|
-
export { type ActivityFeedItem, ActivityFeedPanel, type ActivityFeedPanelProps, Attachment, type AttachmentProps, type AttachmentStatus, AudioPlayer, type AudioPlayerProps, Avatar, AvatarBadge, type AvatarBadgeConfig, type AvatarBadgeProps, AvatarFallback, type AvatarFallbackProps, AvatarGroup, type AvatarGroupProps, AvatarImage, type AvatarImageProps, type AvatarProps, Badge, type BadgeProps, Banner, type BannerAction, type BannerJustify, type BannerProps, type BannerToggle, Box, type BoxProps, Bulk, type BulkProps, type BulkSection, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, COLOR_TOKENS, Checkbox, type CheckboxProps, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColorKey, ColorPicker, type ColorPickerProps, type ColorToken, ColorTokenPicker, type ColorTokenPickerProps, DatePicker, type DatePickerMode, type DatePickerProps, type DatePreset, Divider, type DividerProps, Drawer, DrawerBody, DrawerClose, DrawerDescription, type DrawerDirection, DrawerFooter, DrawerHeader, type DrawerProps, DrawerTitle, EmailInput, type EmailInputProps, EmptyState, type EmptyStateProps, FAB_EDGE_MARGIN, FAB_SIZE, FilePicker, type FilePickerProps, FileUploadZone, type FileUploadZoneProps, type FloatingAction, FloatingButton, type FloatingButtonProps, type FloatingSafeArea, Gantt, type GanttBand, type GanttBar, type GanttDay, GanttDot, type GanttProps, type GanttRow, GanttSwatch, type HeaderCheckState, type HexColor, HistoryButton, type HistoryButtonProps, type HistoryChange, HistoryDrawer, type HistoryDrawerProps, type HistoryEntry, type HistoryFilter, HistoryList, type HistoryListProps, Icon, IconBadge, type IconBadgeProps, type IconColor, type IconFamily, type IconProps, type IconSize, type IconTabItem, IconTabs, type IconTabsProps, IconTooltip, type IconTooltipProps, type IconVariant, Image, type ImageProps, InfoTooltip, type InfoTooltipProps, type InfoTooltipVariant, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, InputGroupButton, type InputGroupButtonProps, type InputGroupProps, type InputProps, Item, ItemActions, ItemContent, ItemDescription, ItemMedia, type ItemMediaProps, type ItemProps, ItemTitle, Label, type LabelProps, Layout, type LayoutProps, Link, type LinkProps, Message, MessageDateSeparator, type MessageDateSeparatorProps, type MessageProps, MessageScroller, type MessageScrollerProps, type MessageSeparatorTone, type MessageVariant, MetricCard, type MetricCardProps, Modal, ModalBody, ModalClose, ModalDescription, ModalFooter, ModalHeader, type ModalProps, ModalTitle, type MultiSelectProps, type OptimizeImageOptions, type OptimizeImageResult, PageContainer, type PageContainerProps, Pagination, type PaginationProps, PasswordInput, type PasswordInputProps, PdfPreview, type PdfPreviewProps, PhoneInput, type PhoneInputMeta, type PhoneInputProps, Popover, type PopoverMenuItem, type PopoverProps, ProgressBar, type ProgressBarProps, type ProgressMarker, type ProgressSegment, Radio, type RadioOption, type RadioProps, type RowId, type RowSelection, ScrollArea, type ScrollAreaProps, SearchInput, type SearchInputProps, Select, type SelectBubbleOption, type SelectGroup, type SelectItem, type SelectOption, type SelectProps, Sidebar, SidebarActionCard, type SidebarActionCardProps, SidebarContent, type SidebarContentProps, SidebarFooter, type SidebarFooterProps, SidebarGroup, type SidebarGroupProps, SidebarHeader, type SidebarHeaderProps, SidebarMenuButton, type SidebarMenuButtonProps, SidebarMenuSearchInput, type SidebarMenuSearchInputProps, SidebarMenuSub, SidebarMenuSubButton, type SidebarMenuSubButtonProps, SidebarMenuSubItem, type SidebarMenuSubItemProps, type SidebarMenuSubProps, type SidebarProps, SidebarSupportInfo, type SidebarSupportInfoProps, SidebarTrigger, type SidebarTriggerProps, SidebarUserMenu, type SidebarUserMenuAction, type SidebarUserMenuLeafAction, type SidebarUserMenuProps, type SingleSelectProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, type SpinnerSize, Stepper, type StepperProps, Switch, type SwitchProps, TOUR_TARGET_ATTRIBUTE, type TabItem, Table, type TableAction, TableActionsCell, type TableActionsCellProps, type TableAlertAction, TableAlertRow, type TableAlertRowProps, type TableAlertTone, TableCell, type TableCellProps, type TableCellTheme, TableClientCell, type TableClientCellProps, type TableColumnsAlign, type TableEmptyState, TableExpandedRow, type TableExpandedRowProps, TableFooter, TableFooterCell, type TableFooterCellProps, type TableFooterProps, TableFooterRow, type TableFooterRowProps, TableHeader, TableHeaderCell, type TableHeaderCellProps, type TableHeaderProps, TableHeaderRow, type TableHeaderRowProps, type TablePagination, TablePersonCell, type TablePersonCellProps, type TableProps, TableRow, type TableRowProps, TableSectionRow, type TableSectionRowProps, TableSelectCell, type TableSelectCellProps, TableSelectHeaderCell, type TableSelectHeaderCellProps, type TableSelection, TableStatusCell, type TableStatusCellProps, TableSubgroupRow, type TableSubgroupRowProps, type TableToolbarProps, type TableToolbarSearch, type TableToolbarStatusFilter, type TableVariant, Tabs, type TabsProps, type TabsVariant, TagBubble, type TagBubbleProps, type TagLevelItem, TagLevelPicker, type TagLevelPickerProps, type TagLevelPickerSize, type TagOption, type TagSearchOption, TagSelect, type TagSelectProps, Text, type TextProps, Textarea, type TextareaProps, type TextareaVariant, Tile, type TileProps, type TileVariant, Timeline, type TimelineItem, type TimelineProps, type ToastId, type ToastOptions, type ToastType, Toaster, Tooltip, type TooltipProps, Tour, type TourCloseReason, type TourLabels, type TourPlacement, type TourProps, type TourStep, TourTarget, type TourTargetProps, type UseRowSelectionOptions, VEHICLE_DAMAGE_ZONES, VehicleDamageMap, type VehicleDamageMapProps, type VehicleDamageMark, type VehicleDamageZone, VideoPlayer, type VideoPlayerProps, addBusinessDays, allowAutofill, appendCacheBuster, appendQueryParam, buttonGroupVariants, buttonVariants, capitalizeFirstLetter, colors, easterDate, formatAddress, formatCityFromFormattedAddress, formatCityWithPostalCode, formatDate, formatDateWithTime, formatDistance, formatDuration, formatEuro, formatKM, formatLocality, formatName, formatNameWithInitial, formatPhoneNumber, formatPlate, formatPlateWithoutDashes, formatPostalCodeFromFormattedAddress, formatRegionCode, formatTime, formatVideoDuration, formatVin, generateHexColor, getAvatarColor, getCleanFileName, getElapsedTime, getFileIconByMimeType, getFileKind, getFileNameFromUrl, getInitials, getMimeCategory, getPastelColorPair, getRelativeTime, isHoliday, isSameDay, isolateCity, linkVariants, noAutofillProps, optimizeImage, parseAmount, parseIsoDate, toast, truncateFileName, truncateText, useAvatarSize, useRowSelection };
|
|
2356
|
+
export { type ActivityFeedItem, ActivityFeedPanel, type ActivityFeedPanelProps, Attachment, type AttachmentProps, type AttachmentStatus, AudioPlayer, type AudioPlayerProps, Avatar, AvatarBadge, type AvatarBadgeConfig, type AvatarBadgeProps, AvatarFallback, type AvatarFallbackProps, AvatarGroup, type AvatarGroupProps, AvatarImage, type AvatarImageProps, type AvatarProps, Badge, type BadgeProps, Banner, type BannerAction, type BannerJustify, type BannerProps, type BannerToggle, Box, type BoxProps, Bulk, type BulkProps, type BulkSection, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, COLOR_TOKENS, Checkbox, type CheckboxProps, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColorKey, ColorPicker, type ColorPickerProps, type ColorToken, ColorTokenPicker, type ColorTokenPickerProps, DatePicker, type DatePickerMode, type DatePickerProps, type DatePreset, Divider, type DividerProps, Drawer, DrawerBody, DrawerClose, DrawerDescription, type DrawerDirection, DrawerFooter, DrawerHeader, type DrawerProps, DrawerTitle, EmailInput, type EmailInputProps, EmptyState, type EmptyStateProps, FAB_EDGE_MARGIN, FAB_SIZE, FilePicker, type FilePickerProps, FileUploadZone, type FileUploadZoneProps, type FloatingAction, FloatingButton, type FloatingButtonProps, type FloatingSafeArea, Gantt, type GanttBand, type GanttBar, type GanttDay, GanttDot, type GanttProps, type GanttRow, GanttSwatch, type HeaderCheckState, type HexColor, HistoryButton, type HistoryButtonProps, type HistoryChange, HistoryDrawer, type HistoryDrawerProps, type HistoryEntry, type HistoryFilter, HistoryList, type HistoryListProps, Icon, IconBadge, type IconBadgeProps, type IconColor, type IconFamily, type IconProps, type IconSize, type IconTabItem, IconTabs, type IconTabsProps, IconTooltip, type IconTooltipProps, type IconVariant, Image, type ImageProps, InfoTooltip, type InfoTooltipProps, type InfoTooltipVariant, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, InputGroupButton, type InputGroupButtonProps, type InputGroupProps, type InputProps, Item, ItemActions, ItemContent, ItemDescription, ItemMedia, type ItemMediaProps, type ItemProps, ItemTitle, Label, type LabelProps, Layout, type LayoutProps, Link, type LinkProps, Message, MessageDateSeparator, type MessageDateSeparatorProps, type MessageProps, MessageScroller, type MessageScrollerProps, type MessageSeparatorTone, type MessageVariant, MetricCard, type MetricCardProps, Modal, ModalBody, ModalClose, ModalDescription, ModalFooter, ModalHeader, type ModalProps, ModalTitle, type MultiSelectProps, type OptimizeImageOptions, type OptimizeImageResult, PageContainer, type PageContainerProps, Pagination, type PaginationProps, PasswordInput, type PasswordInputProps, PdfPreview, type PdfPreviewProps, PhoneInput, type PhoneInputMeta, type PhoneInputProps, Popover, type PopoverMenuItem, type PopoverProps, ProgressBar, type ProgressBarProps, type ProgressMarker, type ProgressSegment, Radio, type RadioOption, type RadioProps, type RowId, type RowSelection, ScrollArea, type ScrollAreaProps, SearchInput, type SearchInputProps, Select, type SelectBubbleOption, type SelectGroup, type SelectItem, type SelectOption, type SelectProps, Sidebar, SidebarActionCard, type SidebarActionCardProps, SidebarContent, type SidebarContentProps, SidebarFooter, type SidebarFooterProps, SidebarGroup, type SidebarGroupProps, SidebarHeader, type SidebarHeaderProps, SidebarMenuButton, type SidebarMenuButtonProps, SidebarMenuSearchInput, type SidebarMenuSearchInputProps, SidebarMenuSub, SidebarMenuSubButton, type SidebarMenuSubButtonProps, SidebarMenuSubItem, type SidebarMenuSubItemProps, type SidebarMenuSubProps, type SidebarProps, SidebarSupportInfo, type SidebarSupportInfoProps, SidebarTrigger, type SidebarTriggerProps, SidebarUserMenu, type SidebarUserMenuAction, type SidebarUserMenuLeafAction, type SidebarUserMenuProps, type SingleSelectProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, type SpinnerSize, Stepper, type StepperProps, Switch, type SwitchProps, TOUR_TARGET_ATTRIBUTE, type TabItem, Table, type TableAction, TableActionsCell, type TableActionsCellProps, type TableAlertAction, TableAlertRow, type TableAlertRowProps, type TableAlertTone, TableCell, type TableCellProps, type TableCellTheme, TableClientCell, type TableClientCellProps, type TableColumnsAlign, type TableEmptyState, TableExpandedRow, type TableExpandedRowProps, TableFooter, TableFooterCell, type TableFooterCellProps, type TableFooterProps, TableFooterRow, type TableFooterRowProps, TableHeader, TableHeaderCell, type TableHeaderCellProps, type TableHeaderProps, TableHeaderRow, type TableHeaderRowProps, type TablePagination, TablePersonCell, type TablePersonCellProps, type TableProps, TableRow, type TableRowProps, TableSectionRow, type TableSectionRowProps, TableSelectCell, type TableSelectCellProps, TableSelectHeaderCell, type TableSelectHeaderCellProps, type TableSelection, TableStatusCell, type TableStatusCellProps, TableSubgroupRow, type TableSubgroupRowProps, type TableToolbarProps, type TableToolbarSearch, type TableToolbarStatusFilter, type TableVariant, Tabs, type TabsProps, type TabsVariant, TagBubble, type TagBubbleProps, type TagLevelItem, TagLevelPicker, type TagLevelPickerProps, type TagLevelPickerSize, type TagOption, type TagSearchOption, TagSelect, type TagSelectProps, Text, type TextProps, Textarea, type TextareaProps, type TextareaVariant, Tile, type TileProps, type TileVariant, Timeline, type TimelineItem, type TimelineProps, type ToastId, type ToastOptions, type ToastType, Toaster, Tooltip, type TooltipProps, Tour, type TourCloseReason, type TourLabels, type TourPlacement, type TourProps, type TourStep, TourTarget, type TourTargetProps, type UseRowSelectionOptions, VEHICLE_DAMAGE_ZONES, VehicleDamageMap, type VehicleDamageMapProps, type VehicleDamageMapSideLabels, type VehicleDamageMark, type VehicleDamageZone, VideoPlayer, type VideoPlayerProps, addBusinessDays, allowAutofill, appendCacheBuster, appendQueryParam, buttonGroupVariants, buttonVariants, capitalizeFirstLetter, colors, easterDate, formatAddress, formatCityFromFormattedAddress, formatCityWithPostalCode, formatDate, formatDateWithTime, formatDistance, formatDuration, formatEuro, formatKM, formatLocality, formatName, formatNameWithInitial, formatPhoneNumber, formatPlate, formatPlateWithoutDashes, formatPostalCodeFromFormattedAddress, formatRegionCode, formatTime, formatVideoDuration, formatVin, generateHexColor, getAvatarColor, getCleanFileName, getElapsedTime, getFileIconByMimeType, getFileKind, getFileNameFromUrl, getInitials, getMimeCategory, getPastelColorPair, getRelativeTime, isHoliday, isSameDay, isolateCity, linkVariants, noAutofillProps, optimizeImage, parseAmount, parseIsoDate, toast, truncateFileName, truncateText, useAvatarSize, useRowSelection };
|
package/dist/ui/index.d.ts
CHANGED
|
@@ -2055,35 +2055,42 @@ interface DatePickerProps {
|
|
|
2055
2055
|
declare const DatePicker: ({ mode, value, onChange, startDate, endDate, onRangeChange, showPresets, presets, placeholder, disabled, minDate, maxDate, width, align, className, }: DatePickerProps) => react.JSX.Element;
|
|
2056
2056
|
|
|
2057
2057
|
declare const ZONE_POSITIONS: {
|
|
2058
|
-
readonly front: readonly [
|
|
2059
|
-
readonly hood: readonly [
|
|
2060
|
-
readonly windshield: readonly [
|
|
2061
|
-
readonly roof: readonly [
|
|
2062
|
-
readonly trunk: readonly [
|
|
2063
|
-
readonly rear: readonly [
|
|
2064
|
-
readonly
|
|
2065
|
-
readonly
|
|
2066
|
-
readonly
|
|
2067
|
-
readonly
|
|
2068
|
-
readonly
|
|
2069
|
-
readonly
|
|
2070
|
-
readonly
|
|
2071
|
-
readonly
|
|
2072
|
-
readonly
|
|
2073
|
-
readonly
|
|
2074
|
-
readonly
|
|
2075
|
-
readonly
|
|
2058
|
+
readonly front: readonly [32, 70];
|
|
2059
|
+
readonly hood: readonly [62, 70];
|
|
2060
|
+
readonly windshield: readonly [86, 70];
|
|
2061
|
+
readonly roof: readonly [128, 70];
|
|
2062
|
+
readonly trunk: readonly [188, 70];
|
|
2063
|
+
readonly rear: readonly [208, 70];
|
|
2064
|
+
readonly frontRightCorner: readonly [44, 36];
|
|
2065
|
+
readonly frontLeftCorner: readonly [44, 104];
|
|
2066
|
+
readonly frontRightWheel: readonly [66, 25];
|
|
2067
|
+
readonly frontLeftWheel: readonly [66, 115];
|
|
2068
|
+
readonly frontRightSide: readonly [104, 31];
|
|
2069
|
+
readonly frontLeftSide: readonly [104, 109];
|
|
2070
|
+
readonly rearRightSide: readonly [146, 31];
|
|
2071
|
+
readonly rearLeftSide: readonly [146, 109];
|
|
2072
|
+
readonly rearRightWheel: readonly [174, 25];
|
|
2073
|
+
readonly rearLeftWheel: readonly [174, 115];
|
|
2074
|
+
readonly rearRightCorner: readonly [196, 36];
|
|
2075
|
+
readonly rearLeftCorner: readonly [196, 104];
|
|
2076
2076
|
};
|
|
2077
2077
|
type VehicleDamageZone = keyof typeof ZONE_POSITIONS;
|
|
2078
2078
|
declare const VEHICLE_DAMAGE_ZONES: VehicleDamageZone[];
|
|
2079
2079
|
interface VehicleDamageMark {
|
|
2080
2080
|
zone: VehicleDamageZone;
|
|
2081
|
-
|
|
2081
|
+
content?: string;
|
|
2082
2082
|
label?: string;
|
|
2083
|
-
tone?: 'danger' | 'warning';
|
|
2083
|
+
tone?: 'danger' | 'warning' | 'neutral';
|
|
2084
|
+
}
|
|
2085
|
+
interface VehicleDamageMapSideLabels {
|
|
2086
|
+
front: string;
|
|
2087
|
+
rear: string;
|
|
2088
|
+
left: string;
|
|
2089
|
+
right: string;
|
|
2084
2090
|
}
|
|
2085
2091
|
interface VehicleDamageMapProps extends HTMLAttributes<HTMLDivElement> {
|
|
2086
2092
|
marks: VehicleDamageMark[];
|
|
2093
|
+
sideLabels?: VehicleDamageMapSideLabels;
|
|
2087
2094
|
selectedZone?: VehicleDamageZone | null;
|
|
2088
2095
|
onZoneClick?: (zone: VehicleDamageZone) => void;
|
|
2089
2096
|
width?: number;
|
|
@@ -2346,4 +2353,4 @@ interface TourTargetProps {
|
|
|
2346
2353
|
declare const TourTarget: ({ id, children }: TourTargetProps) => react.JSX.Element;
|
|
2347
2354
|
declare const Tour: ({ steps, open, step, onStepChange, onClose, labels, targetTimeout, }: TourProps) => null;
|
|
2348
2355
|
|
|
2349
|
-
export { type ActivityFeedItem, ActivityFeedPanel, type ActivityFeedPanelProps, Attachment, type AttachmentProps, type AttachmentStatus, AudioPlayer, type AudioPlayerProps, Avatar, AvatarBadge, type AvatarBadgeConfig, type AvatarBadgeProps, AvatarFallback, type AvatarFallbackProps, AvatarGroup, type AvatarGroupProps, AvatarImage, type AvatarImageProps, type AvatarProps, Badge, type BadgeProps, Banner, type BannerAction, type BannerJustify, type BannerProps, type BannerToggle, Box, type BoxProps, Bulk, type BulkProps, type BulkSection, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, COLOR_TOKENS, Checkbox, type CheckboxProps, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColorKey, ColorPicker, type ColorPickerProps, type ColorToken, ColorTokenPicker, type ColorTokenPickerProps, DatePicker, type DatePickerMode, type DatePickerProps, type DatePreset, Divider, type DividerProps, Drawer, DrawerBody, DrawerClose, DrawerDescription, type DrawerDirection, DrawerFooter, DrawerHeader, type DrawerProps, DrawerTitle, EmailInput, type EmailInputProps, EmptyState, type EmptyStateProps, FAB_EDGE_MARGIN, FAB_SIZE, FilePicker, type FilePickerProps, FileUploadZone, type FileUploadZoneProps, type FloatingAction, FloatingButton, type FloatingButtonProps, type FloatingSafeArea, Gantt, type GanttBand, type GanttBar, type GanttDay, GanttDot, type GanttProps, type GanttRow, GanttSwatch, type HeaderCheckState, type HexColor, HistoryButton, type HistoryButtonProps, type HistoryChange, HistoryDrawer, type HistoryDrawerProps, type HistoryEntry, type HistoryFilter, HistoryList, type HistoryListProps, Icon, IconBadge, type IconBadgeProps, type IconColor, type IconFamily, type IconProps, type IconSize, type IconTabItem, IconTabs, type IconTabsProps, IconTooltip, type IconTooltipProps, type IconVariant, Image, type ImageProps, InfoTooltip, type InfoTooltipProps, type InfoTooltipVariant, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, InputGroupButton, type InputGroupButtonProps, type InputGroupProps, type InputProps, Item, ItemActions, ItemContent, ItemDescription, ItemMedia, type ItemMediaProps, type ItemProps, ItemTitle, Label, type LabelProps, Layout, type LayoutProps, Link, type LinkProps, Message, MessageDateSeparator, type MessageDateSeparatorProps, type MessageProps, MessageScroller, type MessageScrollerProps, type MessageSeparatorTone, type MessageVariant, MetricCard, type MetricCardProps, Modal, ModalBody, ModalClose, ModalDescription, ModalFooter, ModalHeader, type ModalProps, ModalTitle, type MultiSelectProps, type OptimizeImageOptions, type OptimizeImageResult, PageContainer, type PageContainerProps, Pagination, type PaginationProps, PasswordInput, type PasswordInputProps, PdfPreview, type PdfPreviewProps, PhoneInput, type PhoneInputMeta, type PhoneInputProps, Popover, type PopoverMenuItem, type PopoverProps, ProgressBar, type ProgressBarProps, type ProgressMarker, type ProgressSegment, Radio, type RadioOption, type RadioProps, type RowId, type RowSelection, ScrollArea, type ScrollAreaProps, SearchInput, type SearchInputProps, Select, type SelectBubbleOption, type SelectGroup, type SelectItem, type SelectOption, type SelectProps, Sidebar, SidebarActionCard, type SidebarActionCardProps, SidebarContent, type SidebarContentProps, SidebarFooter, type SidebarFooterProps, SidebarGroup, type SidebarGroupProps, SidebarHeader, type SidebarHeaderProps, SidebarMenuButton, type SidebarMenuButtonProps, SidebarMenuSearchInput, type SidebarMenuSearchInputProps, SidebarMenuSub, SidebarMenuSubButton, type SidebarMenuSubButtonProps, SidebarMenuSubItem, type SidebarMenuSubItemProps, type SidebarMenuSubProps, type SidebarProps, SidebarSupportInfo, type SidebarSupportInfoProps, SidebarTrigger, type SidebarTriggerProps, SidebarUserMenu, type SidebarUserMenuAction, type SidebarUserMenuLeafAction, type SidebarUserMenuProps, type SingleSelectProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, type SpinnerSize, Stepper, type StepperProps, Switch, type SwitchProps, TOUR_TARGET_ATTRIBUTE, type TabItem, Table, type TableAction, TableActionsCell, type TableActionsCellProps, type TableAlertAction, TableAlertRow, type TableAlertRowProps, type TableAlertTone, TableCell, type TableCellProps, type TableCellTheme, TableClientCell, type TableClientCellProps, type TableColumnsAlign, type TableEmptyState, TableExpandedRow, type TableExpandedRowProps, TableFooter, TableFooterCell, type TableFooterCellProps, type TableFooterProps, TableFooterRow, type TableFooterRowProps, TableHeader, TableHeaderCell, type TableHeaderCellProps, type TableHeaderProps, TableHeaderRow, type TableHeaderRowProps, type TablePagination, TablePersonCell, type TablePersonCellProps, type TableProps, TableRow, type TableRowProps, TableSectionRow, type TableSectionRowProps, TableSelectCell, type TableSelectCellProps, TableSelectHeaderCell, type TableSelectHeaderCellProps, type TableSelection, TableStatusCell, type TableStatusCellProps, TableSubgroupRow, type TableSubgroupRowProps, type TableToolbarProps, type TableToolbarSearch, type TableToolbarStatusFilter, type TableVariant, Tabs, type TabsProps, type TabsVariant, TagBubble, type TagBubbleProps, type TagLevelItem, TagLevelPicker, type TagLevelPickerProps, type TagLevelPickerSize, type TagOption, type TagSearchOption, TagSelect, type TagSelectProps, Text, type TextProps, Textarea, type TextareaProps, type TextareaVariant, Tile, type TileProps, type TileVariant, Timeline, type TimelineItem, type TimelineProps, type ToastId, type ToastOptions, type ToastType, Toaster, Tooltip, type TooltipProps, Tour, type TourCloseReason, type TourLabels, type TourPlacement, type TourProps, type TourStep, TourTarget, type TourTargetProps, type UseRowSelectionOptions, VEHICLE_DAMAGE_ZONES, VehicleDamageMap, type VehicleDamageMapProps, type VehicleDamageMark, type VehicleDamageZone, VideoPlayer, type VideoPlayerProps, addBusinessDays, allowAutofill, appendCacheBuster, appendQueryParam, buttonGroupVariants, buttonVariants, capitalizeFirstLetter, colors, easterDate, formatAddress, formatCityFromFormattedAddress, formatCityWithPostalCode, formatDate, formatDateWithTime, formatDistance, formatDuration, formatEuro, formatKM, formatLocality, formatName, formatNameWithInitial, formatPhoneNumber, formatPlate, formatPlateWithoutDashes, formatPostalCodeFromFormattedAddress, formatRegionCode, formatTime, formatVideoDuration, formatVin, generateHexColor, getAvatarColor, getCleanFileName, getElapsedTime, getFileIconByMimeType, getFileKind, getFileNameFromUrl, getInitials, getMimeCategory, getPastelColorPair, getRelativeTime, isHoliday, isSameDay, isolateCity, linkVariants, noAutofillProps, optimizeImage, parseAmount, parseIsoDate, toast, truncateFileName, truncateText, useAvatarSize, useRowSelection };
|
|
2356
|
+
export { type ActivityFeedItem, ActivityFeedPanel, type ActivityFeedPanelProps, Attachment, type AttachmentProps, type AttachmentStatus, AudioPlayer, type AudioPlayerProps, Avatar, AvatarBadge, type AvatarBadgeConfig, type AvatarBadgeProps, AvatarFallback, type AvatarFallbackProps, AvatarGroup, type AvatarGroupProps, AvatarImage, type AvatarImageProps, type AvatarProps, Badge, type BadgeProps, Banner, type BannerAction, type BannerJustify, type BannerProps, type BannerToggle, Box, type BoxProps, Bulk, type BulkProps, type BulkSection, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, COLOR_TOKENS, Checkbox, type CheckboxProps, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColorKey, ColorPicker, type ColorPickerProps, type ColorToken, ColorTokenPicker, type ColorTokenPickerProps, DatePicker, type DatePickerMode, type DatePickerProps, type DatePreset, Divider, type DividerProps, Drawer, DrawerBody, DrawerClose, DrawerDescription, type DrawerDirection, DrawerFooter, DrawerHeader, type DrawerProps, DrawerTitle, EmailInput, type EmailInputProps, EmptyState, type EmptyStateProps, FAB_EDGE_MARGIN, FAB_SIZE, FilePicker, type FilePickerProps, FileUploadZone, type FileUploadZoneProps, type FloatingAction, FloatingButton, type FloatingButtonProps, type FloatingSafeArea, Gantt, type GanttBand, type GanttBar, type GanttDay, GanttDot, type GanttProps, type GanttRow, GanttSwatch, type HeaderCheckState, type HexColor, HistoryButton, type HistoryButtonProps, type HistoryChange, HistoryDrawer, type HistoryDrawerProps, type HistoryEntry, type HistoryFilter, HistoryList, type HistoryListProps, Icon, IconBadge, type IconBadgeProps, type IconColor, type IconFamily, type IconProps, type IconSize, type IconTabItem, IconTabs, type IconTabsProps, IconTooltip, type IconTooltipProps, type IconVariant, Image, type ImageProps, InfoTooltip, type InfoTooltipProps, type InfoTooltipVariant, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, InputGroupButton, type InputGroupButtonProps, type InputGroupProps, type InputProps, Item, ItemActions, ItemContent, ItemDescription, ItemMedia, type ItemMediaProps, type ItemProps, ItemTitle, Label, type LabelProps, Layout, type LayoutProps, Link, type LinkProps, Message, MessageDateSeparator, type MessageDateSeparatorProps, type MessageProps, MessageScroller, type MessageScrollerProps, type MessageSeparatorTone, type MessageVariant, MetricCard, type MetricCardProps, Modal, ModalBody, ModalClose, ModalDescription, ModalFooter, ModalHeader, type ModalProps, ModalTitle, type MultiSelectProps, type OptimizeImageOptions, type OptimizeImageResult, PageContainer, type PageContainerProps, Pagination, type PaginationProps, PasswordInput, type PasswordInputProps, PdfPreview, type PdfPreviewProps, PhoneInput, type PhoneInputMeta, type PhoneInputProps, Popover, type PopoverMenuItem, type PopoverProps, ProgressBar, type ProgressBarProps, type ProgressMarker, type ProgressSegment, Radio, type RadioOption, type RadioProps, type RowId, type RowSelection, ScrollArea, type ScrollAreaProps, SearchInput, type SearchInputProps, Select, type SelectBubbleOption, type SelectGroup, type SelectItem, type SelectOption, type SelectProps, Sidebar, SidebarActionCard, type SidebarActionCardProps, SidebarContent, type SidebarContentProps, SidebarFooter, type SidebarFooterProps, SidebarGroup, type SidebarGroupProps, SidebarHeader, type SidebarHeaderProps, SidebarMenuButton, type SidebarMenuButtonProps, SidebarMenuSearchInput, type SidebarMenuSearchInputProps, SidebarMenuSub, SidebarMenuSubButton, type SidebarMenuSubButtonProps, SidebarMenuSubItem, type SidebarMenuSubItemProps, type SidebarMenuSubProps, type SidebarProps, SidebarSupportInfo, type SidebarSupportInfoProps, SidebarTrigger, type SidebarTriggerProps, SidebarUserMenu, type SidebarUserMenuAction, type SidebarUserMenuLeafAction, type SidebarUserMenuProps, type SingleSelectProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, type SpinnerSize, Stepper, type StepperProps, Switch, type SwitchProps, TOUR_TARGET_ATTRIBUTE, type TabItem, Table, type TableAction, TableActionsCell, type TableActionsCellProps, type TableAlertAction, TableAlertRow, type TableAlertRowProps, type TableAlertTone, TableCell, type TableCellProps, type TableCellTheme, TableClientCell, type TableClientCellProps, type TableColumnsAlign, type TableEmptyState, TableExpandedRow, type TableExpandedRowProps, TableFooter, TableFooterCell, type TableFooterCellProps, type TableFooterProps, TableFooterRow, type TableFooterRowProps, TableHeader, TableHeaderCell, type TableHeaderCellProps, type TableHeaderProps, TableHeaderRow, type TableHeaderRowProps, type TablePagination, TablePersonCell, type TablePersonCellProps, type TableProps, TableRow, type TableRowProps, TableSectionRow, type TableSectionRowProps, TableSelectCell, type TableSelectCellProps, TableSelectHeaderCell, type TableSelectHeaderCellProps, type TableSelection, TableStatusCell, type TableStatusCellProps, TableSubgroupRow, type TableSubgroupRowProps, type TableToolbarProps, type TableToolbarSearch, type TableToolbarStatusFilter, type TableVariant, Tabs, type TabsProps, type TabsVariant, TagBubble, type TagBubbleProps, type TagLevelItem, TagLevelPicker, type TagLevelPickerProps, type TagLevelPickerSize, type TagOption, type TagSearchOption, TagSelect, type TagSelectProps, Text, type TextProps, Textarea, type TextareaProps, type TextareaVariant, Tile, type TileProps, type TileVariant, Timeline, type TimelineItem, type TimelineProps, type ToastId, type ToastOptions, type ToastType, Toaster, Tooltip, type TooltipProps, Tour, type TourCloseReason, type TourLabels, type TourPlacement, type TourProps, type TourStep, TourTarget, type TourTargetProps, type UseRowSelectionOptions, VEHICLE_DAMAGE_ZONES, VehicleDamageMap, type VehicleDamageMapProps, type VehicleDamageMapSideLabels, type VehicleDamageMark, type VehicleDamageZone, VideoPlayer, type VideoPlayerProps, addBusinessDays, allowAutofill, appendCacheBuster, appendQueryParam, buttonGroupVariants, buttonVariants, capitalizeFirstLetter, colors, easterDate, formatAddress, formatCityFromFormattedAddress, formatCityWithPostalCode, formatDate, formatDateWithTime, formatDistance, formatDuration, formatEuro, formatKM, formatLocality, formatName, formatNameWithInitial, formatPhoneNumber, formatPlate, formatPlateWithoutDashes, formatPostalCodeFromFormattedAddress, formatRegionCode, formatTime, formatVideoDuration, formatVin, generateHexColor, getAvatarColor, getCleanFileName, getElapsedTime, getFileIconByMimeType, getFileKind, getFileNameFromUrl, getInitials, getMimeCategory, getPastelColorPair, getRelativeTime, isHoliday, isSameDay, isolateCity, linkVariants, noAutofillProps, optimizeImage, parseAmount, parseIsoDate, toast, truncateFileName, truncateText, useAvatarSize, useRowSelection };
|
package/dist/ui/index.js
CHANGED
|
@@ -3943,7 +3943,7 @@ var TableSelectAllResultsBar = ({
|
|
|
3943
3943
|
}) => {
|
|
3944
3944
|
if (selection.isAllResultsSelected)
|
|
3945
3945
|
return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: "border-b border-grey-200 bg-blue-50 px-3 py-2 text-center text-xs font-semibold text-blue-900", children: [
|
|
3946
|
-
`Les ${selection.totalCount} r\xE9sultats sont s\xE9lectionn\xE9s.`,
|
|
3946
|
+
selection.selectedCount === selection.totalCount ? `Les ${selection.totalCount} r\xE9sultats sont s\xE9lectionn\xE9s.` : `${selection.selectedCount} r\xE9sultats sur ${selection.totalCount} sont s\xE9lectionn\xE9s.`,
|
|
3947
3947
|
" ",
|
|
3948
3948
|
/* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
3949
3949
|
"button",
|
|
@@ -5183,29 +5183,38 @@ var useRowSelection = ({
|
|
|
5183
5183
|
}) => {
|
|
5184
5184
|
const [selectedIds, setSelectedIds] = (0, import_react32.useState)(/* @__PURE__ */ new Set());
|
|
5185
5185
|
const [isAllResultsSelected, setIsAllResultsSelected] = (0, import_react32.useState)(false);
|
|
5186
|
+
const [excludedIds, setExcludedIds] = (0, import_react32.useState)(/* @__PURE__ */ new Set());
|
|
5186
5187
|
const anchorId = (0, import_react32.useRef)(null);
|
|
5188
|
+
const isRowSelected = (id) => isAllResultsSelected ? !excludedIds.has(id) : selectedIds.has(id);
|
|
5187
5189
|
const resolvedTotal = totalCount != null ? totalCount : rowIds.length;
|
|
5188
|
-
const selectedOnPage = rowIds.filter(
|
|
5190
|
+
const selectedOnPage = rowIds.filter(isRowSelected).length;
|
|
5189
5191
|
const isPageFullySelected = rowIds.length > 0 && selectedOnPage === rowIds.length;
|
|
5190
5192
|
const canSelectAllResults = isPageFullySelected && !isAllResultsSelected && resolvedTotal > rowIds.length;
|
|
5191
|
-
const headerState =
|
|
5193
|
+
const headerState = isPageFullySelected ? true : selectedOnPage > 0 ? "indeterminate" : false;
|
|
5192
5194
|
const clear = (0, import_react32.useCallback)(() => {
|
|
5193
5195
|
setSelectedIds(/* @__PURE__ */ new Set());
|
|
5194
5196
|
setIsAllResultsSelected(false);
|
|
5197
|
+
setExcludedIds(/* @__PURE__ */ new Set());
|
|
5195
5198
|
anchorId.current = null;
|
|
5196
5199
|
}, []);
|
|
5197
|
-
const isRowSelected = (id) => isAllResultsSelected || selectedIds.has(id);
|
|
5198
5200
|
const getGroupState = (groupIds) => {
|
|
5199
5201
|
const selectedInGroup = groupIds.filter(isRowSelected).length;
|
|
5200
5202
|
if (selectedInGroup === 0) return false;
|
|
5201
5203
|
return selectedInGroup === groupIds.length ? true : "indeterminate";
|
|
5202
5204
|
};
|
|
5203
5205
|
const applyToRows = (idsToApply, willSelect) => {
|
|
5204
|
-
|
|
5206
|
+
if (isAllResultsSelected) {
|
|
5207
|
+
const nextExcluded = new Set(excludedIds);
|
|
5208
|
+
idsToApply.forEach(
|
|
5209
|
+
(rowId) => willSelect ? nextExcluded.delete(rowId) : nextExcluded.add(rowId)
|
|
5210
|
+
);
|
|
5211
|
+
setExcludedIds(nextExcluded);
|
|
5212
|
+
return;
|
|
5213
|
+
}
|
|
5214
|
+
const next = new Set(selectedIds);
|
|
5205
5215
|
idsToApply.forEach(
|
|
5206
5216
|
(rowId) => willSelect ? next.add(rowId) : next.delete(rowId)
|
|
5207
5217
|
);
|
|
5208
|
-
setIsAllResultsSelected(false);
|
|
5209
5218
|
setSelectedIds(next);
|
|
5210
5219
|
};
|
|
5211
5220
|
const toggleGroup = (groupIds) => applyToRows(groupIds, getGroupState(groupIds) !== true);
|
|
@@ -5221,7 +5230,7 @@ var useRowSelection = ({
|
|
|
5221
5230
|
applyToRows(idsToApply, willSelect);
|
|
5222
5231
|
};
|
|
5223
5232
|
const toggleAllOnPage = () => {
|
|
5224
|
-
if (isAllResultsSelected) {
|
|
5233
|
+
if (isAllResultsSelected && headerState === true) {
|
|
5225
5234
|
clear();
|
|
5226
5235
|
return;
|
|
5227
5236
|
}
|
|
@@ -5229,11 +5238,12 @@ var useRowSelection = ({
|
|
|
5229
5238
|
};
|
|
5230
5239
|
const selectAllResults = () => {
|
|
5231
5240
|
setSelectedIds(new Set(rowIds));
|
|
5241
|
+
setExcludedIds(/* @__PURE__ */ new Set());
|
|
5232
5242
|
setIsAllResultsSelected(true);
|
|
5233
5243
|
};
|
|
5234
5244
|
return {
|
|
5235
5245
|
selectedIds,
|
|
5236
|
-
selectedCount: isAllResultsSelected ? resolvedTotal : selectedIds.size,
|
|
5246
|
+
selectedCount: isAllResultsSelected ? resolvedTotal - excludedIds.size : selectedIds.size,
|
|
5237
5247
|
isRowSelected,
|
|
5238
5248
|
headerState,
|
|
5239
5249
|
isAllResultsSelected,
|
|
@@ -9776,36 +9786,39 @@ var DatePicker = ({
|
|
|
9776
9786
|
// src/ui/components/ui/VehicleDamageMap.tsx
|
|
9777
9787
|
var import_react65 = require("react");
|
|
9778
9788
|
var import_jsx_runtime117 = require("react/jsx-runtime");
|
|
9779
|
-
var WIDTH =
|
|
9780
|
-
var HEIGHT =
|
|
9789
|
+
var WIDTH = 240;
|
|
9790
|
+
var HEIGHT = 140;
|
|
9781
9791
|
var ZONE_POSITIONS = {
|
|
9782
|
-
front: [
|
|
9783
|
-
hood: [
|
|
9784
|
-
windshield: [
|
|
9785
|
-
roof: [
|
|
9786
|
-
trunk: [
|
|
9787
|
-
rear: [
|
|
9788
|
-
|
|
9789
|
-
|
|
9790
|
-
|
|
9791
|
-
|
|
9792
|
-
|
|
9793
|
-
|
|
9794
|
-
|
|
9795
|
-
|
|
9796
|
-
|
|
9797
|
-
|
|
9798
|
-
|
|
9799
|
-
|
|
9792
|
+
front: [32, 70],
|
|
9793
|
+
hood: [62, 70],
|
|
9794
|
+
windshield: [86, 70],
|
|
9795
|
+
roof: [128, 70],
|
|
9796
|
+
trunk: [188, 70],
|
|
9797
|
+
rear: [208, 70],
|
|
9798
|
+
frontRightCorner: [44, 36],
|
|
9799
|
+
frontLeftCorner: [44, 104],
|
|
9800
|
+
frontRightWheel: [66, 25],
|
|
9801
|
+
frontLeftWheel: [66, 115],
|
|
9802
|
+
frontRightSide: [104, 31],
|
|
9803
|
+
frontLeftSide: [104, 109],
|
|
9804
|
+
rearRightSide: [146, 31],
|
|
9805
|
+
rearLeftSide: [146, 109],
|
|
9806
|
+
rearRightWheel: [174, 25],
|
|
9807
|
+
rearLeftWheel: [174, 115],
|
|
9808
|
+
rearRightCorner: [196, 36],
|
|
9809
|
+
rearLeftCorner: [196, 104]
|
|
9800
9810
|
};
|
|
9801
9811
|
var VEHICLE_DAMAGE_ZONES = Object.keys(
|
|
9802
9812
|
ZONE_POSITIONS
|
|
9803
9813
|
);
|
|
9804
9814
|
var TONES = {
|
|
9805
9815
|
danger: colors.red_500,
|
|
9806
|
-
warning: colors.orange_500
|
|
9816
|
+
warning: colors.orange_500,
|
|
9817
|
+
neutral: colors.grey_500
|
|
9807
9818
|
};
|
|
9808
|
-
var VehicleOutline = (
|
|
9819
|
+
var VehicleOutline = ({
|
|
9820
|
+
sideLabels
|
|
9821
|
+
}) => /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)(
|
|
9809
9822
|
"svg",
|
|
9810
9823
|
{
|
|
9811
9824
|
viewBox: `0 0 ${WIDTH} ${HEIGHT}`,
|
|
@@ -9813,39 +9826,69 @@ var VehicleOutline = () => /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)(
|
|
|
9813
9826
|
"aria-hidden": true,
|
|
9814
9827
|
children: [
|
|
9815
9828
|
/* @__PURE__ */ (0, import_jsx_runtime117.jsxs)("g", { fill: colors.grey_600, children: [
|
|
9816
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "
|
|
9817
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "
|
|
9818
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "
|
|
9819
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "
|
|
9829
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "54", y: "20", width: "26", height: "10", rx: "3" }),
|
|
9830
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "54", y: "110", width: "26", height: "10", rx: "3" }),
|
|
9831
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "162", y: "20", width: "26", height: "10", rx: "3" }),
|
|
9832
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("rect", { x: "162", y: "110", width: "26", height: "10", rx: "3" })
|
|
9820
9833
|
] }),
|
|
9821
9834
|
/* @__PURE__ */ (0, import_jsx_runtime117.jsxs)("g", { fill: colors.grey_200, stroke: colors.grey_400, strokeWidth: "1.5", children: [
|
|
9822
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("ellipse", { cx: "
|
|
9823
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("ellipse", { cx: "
|
|
9824
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("path", { d: "
|
|
9835
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("ellipse", { cx: "94", cy: "26", rx: "3", ry: "5" }),
|
|
9836
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("ellipse", { cx: "94", cy: "114", rx: "3", ry: "5" }),
|
|
9837
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("path", { d: "M34 48 Q34 28 58 28 H184 Q206 28 206 48 V92 Q206 112 184 112 H58 Q34 112 34 92 Z" })
|
|
9825
9838
|
] }),
|
|
9826
9839
|
/* @__PURE__ */ (0, import_jsx_runtime117.jsxs)("g", { fill: colors.grey_300, stroke: colors.grey_400, strokeWidth: "1", children: [
|
|
9827
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("path", { d: "
|
|
9828
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("path", { d: "
|
|
9840
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("path", { d: "M78 40 L98 46 V94 L78 100 Q70 70 78 40 Z" }),
|
|
9841
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("path", { d: "M180 42 L166 47 V93 L180 98 Q186 70 180 42 Z" })
|
|
9829
9842
|
] }),
|
|
9830
9843
|
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
|
|
9831
9844
|
"rect",
|
|
9832
9845
|
{
|
|
9833
|
-
x: "
|
|
9834
|
-
y: "
|
|
9835
|
-
width: "
|
|
9836
|
-
height: "
|
|
9837
|
-
rx: "
|
|
9846
|
+
x: "102",
|
|
9847
|
+
y: "48",
|
|
9848
|
+
width: "60",
|
|
9849
|
+
height: "44",
|
|
9850
|
+
rx: "6",
|
|
9838
9851
|
fill: colors.grey_100,
|
|
9839
9852
|
stroke: colors.grey_400,
|
|
9840
9853
|
strokeWidth: "1"
|
|
9841
9854
|
}
|
|
9855
|
+
),
|
|
9856
|
+
sideLabels && /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)(
|
|
9857
|
+
"g",
|
|
9858
|
+
{
|
|
9859
|
+
fill: colors.grey_500,
|
|
9860
|
+
fontSize: "7",
|
|
9861
|
+
fontWeight: "600",
|
|
9862
|
+
textAnchor: "middle",
|
|
9863
|
+
letterSpacing: "0.5",
|
|
9864
|
+
children: [
|
|
9865
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("text", { x: "120", y: "11", children: sideLabels.right.toUpperCase() }),
|
|
9866
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("text", { x: "120", y: "135", children: sideLabels.left.toUpperCase() }),
|
|
9867
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("text", { x: "14", y: "70", transform: "rotate(-90 14 70)", children: sideLabels.front.toUpperCase() }),
|
|
9868
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)("text", { x: "226", y: "70", transform: "rotate(90 226 70)", children: sideLabels.rear.toUpperCase() })
|
|
9869
|
+
]
|
|
9870
|
+
}
|
|
9842
9871
|
)
|
|
9843
9872
|
]
|
|
9844
9873
|
}
|
|
9845
9874
|
);
|
|
9846
9875
|
var VehicleDamageMap = (0, import_react65.forwardRef)(
|
|
9847
9876
|
(_a, ref) => {
|
|
9848
|
-
var _b = _a, {
|
|
9877
|
+
var _b = _a, {
|
|
9878
|
+
marks,
|
|
9879
|
+
sideLabels,
|
|
9880
|
+
selectedZone,
|
|
9881
|
+
onZoneClick,
|
|
9882
|
+
width = 200,
|
|
9883
|
+
className
|
|
9884
|
+
} = _b, rest = __objRest(_b, [
|
|
9885
|
+
"marks",
|
|
9886
|
+
"sideLabels",
|
|
9887
|
+
"selectedZone",
|
|
9888
|
+
"onZoneClick",
|
|
9889
|
+
"width",
|
|
9890
|
+
"className"
|
|
9891
|
+
]);
|
|
9849
9892
|
return /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)(
|
|
9850
9893
|
"div",
|
|
9851
9894
|
__spreadProps(__spreadValues({
|
|
@@ -9854,7 +9897,7 @@ var VehicleDamageMap = (0, import_react65.forwardRef)(
|
|
|
9854
9897
|
style: { width, height: width * HEIGHT / WIDTH }
|
|
9855
9898
|
}, rest), {
|
|
9856
9899
|
children: [
|
|
9857
|
-
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)(VehicleOutline, {}),
|
|
9900
|
+
/* @__PURE__ */ (0, import_jsx_runtime117.jsx)(VehicleOutline, { sideLabels }),
|
|
9858
9901
|
marks.map((mark) => {
|
|
9859
9902
|
var _a2, _b2, _c;
|
|
9860
9903
|
const [x, y] = ZONE_POSITIONS[mark.zone];
|
|
@@ -9869,7 +9912,6 @@ var VehicleDamageMap = (0, import_react65.forwardRef)(
|
|
|
9869
9912
|
backgroundColor: TONES[(_a2 = mark.tone) != null ? _a2 : "danger"],
|
|
9870
9913
|
boxShadow: selected ? `0 0 0 2px ${colors.blue_950}` : void 0
|
|
9871
9914
|
};
|
|
9872
|
-
const content = mark.count && mark.count > 1 ? mark.count : null;
|
|
9873
9915
|
const pin = onZoneClick ? /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
|
|
9874
9916
|
"button",
|
|
9875
9917
|
{
|
|
@@ -9879,7 +9921,7 @@ var VehicleDamageMap = (0, import_react65.forwardRef)(
|
|
|
9879
9921
|
onClick: () => onZoneClick(mark.zone),
|
|
9880
9922
|
className: pinClassName,
|
|
9881
9923
|
style: pinStyle,
|
|
9882
|
-
children: content
|
|
9924
|
+
children: mark.content
|
|
9883
9925
|
}
|
|
9884
9926
|
) : /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
|
|
9885
9927
|
"span",
|
|
@@ -9888,7 +9930,7 @@ var VehicleDamageMap = (0, import_react65.forwardRef)(
|
|
|
9888
9930
|
"aria-label": (_c = mark.label) != null ? _c : mark.zone,
|
|
9889
9931
|
className: pinClassName,
|
|
9890
9932
|
style: pinStyle,
|
|
9891
|
-
children: content
|
|
9933
|
+
children: mark.content
|
|
9892
9934
|
}
|
|
9893
9935
|
);
|
|
9894
9936
|
return mark.label ? /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(Tooltip, { content: mark.label, children: pin }, mark.zone) : /* @__PURE__ */ (0, import_jsx_runtime117.jsx)("span", { children: pin }, mark.zone);
|
package/dist/ui/index.mjs
CHANGED
|
@@ -3737,7 +3737,7 @@ var TableSelectAllResultsBar = ({
|
|
|
3737
3737
|
}) => {
|
|
3738
3738
|
if (selection.isAllResultsSelected)
|
|
3739
3739
|
return /* @__PURE__ */ jsxs22("div", { className: "border-b border-grey-200 bg-blue-50 px-3 py-2 text-center text-xs font-semibold text-blue-900", children: [
|
|
3740
|
-
`Les ${selection.totalCount} r\xE9sultats sont s\xE9lectionn\xE9s.`,
|
|
3740
|
+
selection.selectedCount === selection.totalCount ? `Les ${selection.totalCount} r\xE9sultats sont s\xE9lectionn\xE9s.` : `${selection.selectedCount} r\xE9sultats sur ${selection.totalCount} sont s\xE9lectionn\xE9s.`,
|
|
3741
3741
|
" ",
|
|
3742
3742
|
/* @__PURE__ */ jsx41(
|
|
3743
3743
|
"button",
|
|
@@ -4984,29 +4984,38 @@ var useRowSelection = ({
|
|
|
4984
4984
|
}) => {
|
|
4985
4985
|
const [selectedIds, setSelectedIds] = useState8(/* @__PURE__ */ new Set());
|
|
4986
4986
|
const [isAllResultsSelected, setIsAllResultsSelected] = useState8(false);
|
|
4987
|
+
const [excludedIds, setExcludedIds] = useState8(/* @__PURE__ */ new Set());
|
|
4987
4988
|
const anchorId = useRef8(null);
|
|
4989
|
+
const isRowSelected = (id) => isAllResultsSelected ? !excludedIds.has(id) : selectedIds.has(id);
|
|
4988
4990
|
const resolvedTotal = totalCount != null ? totalCount : rowIds.length;
|
|
4989
|
-
const selectedOnPage = rowIds.filter(
|
|
4991
|
+
const selectedOnPage = rowIds.filter(isRowSelected).length;
|
|
4990
4992
|
const isPageFullySelected = rowIds.length > 0 && selectedOnPage === rowIds.length;
|
|
4991
4993
|
const canSelectAllResults = isPageFullySelected && !isAllResultsSelected && resolvedTotal > rowIds.length;
|
|
4992
|
-
const headerState =
|
|
4994
|
+
const headerState = isPageFullySelected ? true : selectedOnPage > 0 ? "indeterminate" : false;
|
|
4993
4995
|
const clear = useCallback2(() => {
|
|
4994
4996
|
setSelectedIds(/* @__PURE__ */ new Set());
|
|
4995
4997
|
setIsAllResultsSelected(false);
|
|
4998
|
+
setExcludedIds(/* @__PURE__ */ new Set());
|
|
4996
4999
|
anchorId.current = null;
|
|
4997
5000
|
}, []);
|
|
4998
|
-
const isRowSelected = (id) => isAllResultsSelected || selectedIds.has(id);
|
|
4999
5001
|
const getGroupState = (groupIds) => {
|
|
5000
5002
|
const selectedInGroup = groupIds.filter(isRowSelected).length;
|
|
5001
5003
|
if (selectedInGroup === 0) return false;
|
|
5002
5004
|
return selectedInGroup === groupIds.length ? true : "indeterminate";
|
|
5003
5005
|
};
|
|
5004
5006
|
const applyToRows = (idsToApply, willSelect) => {
|
|
5005
|
-
|
|
5007
|
+
if (isAllResultsSelected) {
|
|
5008
|
+
const nextExcluded = new Set(excludedIds);
|
|
5009
|
+
idsToApply.forEach(
|
|
5010
|
+
(rowId) => willSelect ? nextExcluded.delete(rowId) : nextExcluded.add(rowId)
|
|
5011
|
+
);
|
|
5012
|
+
setExcludedIds(nextExcluded);
|
|
5013
|
+
return;
|
|
5014
|
+
}
|
|
5015
|
+
const next = new Set(selectedIds);
|
|
5006
5016
|
idsToApply.forEach(
|
|
5007
5017
|
(rowId) => willSelect ? next.add(rowId) : next.delete(rowId)
|
|
5008
5018
|
);
|
|
5009
|
-
setIsAllResultsSelected(false);
|
|
5010
5019
|
setSelectedIds(next);
|
|
5011
5020
|
};
|
|
5012
5021
|
const toggleGroup = (groupIds) => applyToRows(groupIds, getGroupState(groupIds) !== true);
|
|
@@ -5022,7 +5031,7 @@ var useRowSelection = ({
|
|
|
5022
5031
|
applyToRows(idsToApply, willSelect);
|
|
5023
5032
|
};
|
|
5024
5033
|
const toggleAllOnPage = () => {
|
|
5025
|
-
if (isAllResultsSelected) {
|
|
5034
|
+
if (isAllResultsSelected && headerState === true) {
|
|
5026
5035
|
clear();
|
|
5027
5036
|
return;
|
|
5028
5037
|
}
|
|
@@ -5030,11 +5039,12 @@ var useRowSelection = ({
|
|
|
5030
5039
|
};
|
|
5031
5040
|
const selectAllResults = () => {
|
|
5032
5041
|
setSelectedIds(new Set(rowIds));
|
|
5042
|
+
setExcludedIds(/* @__PURE__ */ new Set());
|
|
5033
5043
|
setIsAllResultsSelected(true);
|
|
5034
5044
|
};
|
|
5035
5045
|
return {
|
|
5036
5046
|
selectedIds,
|
|
5037
|
-
selectedCount: isAllResultsSelected ? resolvedTotal : selectedIds.size,
|
|
5047
|
+
selectedCount: isAllResultsSelected ? resolvedTotal - excludedIds.size : selectedIds.size,
|
|
5038
5048
|
isRowSelected,
|
|
5039
5049
|
headerState,
|
|
5040
5050
|
isAllResultsSelected,
|
|
@@ -9600,36 +9610,39 @@ var DatePicker = ({
|
|
|
9600
9610
|
// src/ui/components/ui/VehicleDamageMap.tsx
|
|
9601
9611
|
import { forwardRef as forwardRef36 } from "react";
|
|
9602
9612
|
import { jsx as jsx117, jsxs as jsxs69 } from "react/jsx-runtime";
|
|
9603
|
-
var WIDTH =
|
|
9604
|
-
var HEIGHT =
|
|
9613
|
+
var WIDTH = 240;
|
|
9614
|
+
var HEIGHT = 140;
|
|
9605
9615
|
var ZONE_POSITIONS = {
|
|
9606
|
-
front: [
|
|
9607
|
-
hood: [
|
|
9608
|
-
windshield: [
|
|
9609
|
-
roof: [
|
|
9610
|
-
trunk: [
|
|
9611
|
-
rear: [
|
|
9612
|
-
|
|
9613
|
-
|
|
9614
|
-
|
|
9615
|
-
|
|
9616
|
-
|
|
9617
|
-
|
|
9618
|
-
|
|
9619
|
-
|
|
9620
|
-
|
|
9621
|
-
|
|
9622
|
-
|
|
9623
|
-
|
|
9616
|
+
front: [32, 70],
|
|
9617
|
+
hood: [62, 70],
|
|
9618
|
+
windshield: [86, 70],
|
|
9619
|
+
roof: [128, 70],
|
|
9620
|
+
trunk: [188, 70],
|
|
9621
|
+
rear: [208, 70],
|
|
9622
|
+
frontRightCorner: [44, 36],
|
|
9623
|
+
frontLeftCorner: [44, 104],
|
|
9624
|
+
frontRightWheel: [66, 25],
|
|
9625
|
+
frontLeftWheel: [66, 115],
|
|
9626
|
+
frontRightSide: [104, 31],
|
|
9627
|
+
frontLeftSide: [104, 109],
|
|
9628
|
+
rearRightSide: [146, 31],
|
|
9629
|
+
rearLeftSide: [146, 109],
|
|
9630
|
+
rearRightWheel: [174, 25],
|
|
9631
|
+
rearLeftWheel: [174, 115],
|
|
9632
|
+
rearRightCorner: [196, 36],
|
|
9633
|
+
rearLeftCorner: [196, 104]
|
|
9624
9634
|
};
|
|
9625
9635
|
var VEHICLE_DAMAGE_ZONES = Object.keys(
|
|
9626
9636
|
ZONE_POSITIONS
|
|
9627
9637
|
);
|
|
9628
9638
|
var TONES = {
|
|
9629
9639
|
danger: colors.red_500,
|
|
9630
|
-
warning: colors.orange_500
|
|
9640
|
+
warning: colors.orange_500,
|
|
9641
|
+
neutral: colors.grey_500
|
|
9631
9642
|
};
|
|
9632
|
-
var VehicleOutline = (
|
|
9643
|
+
var VehicleOutline = ({
|
|
9644
|
+
sideLabels
|
|
9645
|
+
}) => /* @__PURE__ */ jsxs69(
|
|
9633
9646
|
"svg",
|
|
9634
9647
|
{
|
|
9635
9648
|
viewBox: `0 0 ${WIDTH} ${HEIGHT}`,
|
|
@@ -9637,39 +9650,69 @@ var VehicleOutline = () => /* @__PURE__ */ jsxs69(
|
|
|
9637
9650
|
"aria-hidden": true,
|
|
9638
9651
|
children: [
|
|
9639
9652
|
/* @__PURE__ */ jsxs69("g", { fill: colors.grey_600, children: [
|
|
9640
|
-
/* @__PURE__ */ jsx117("rect", { x: "
|
|
9641
|
-
/* @__PURE__ */ jsx117("rect", { x: "
|
|
9642
|
-
/* @__PURE__ */ jsx117("rect", { x: "
|
|
9643
|
-
/* @__PURE__ */ jsx117("rect", { x: "
|
|
9653
|
+
/* @__PURE__ */ jsx117("rect", { x: "54", y: "20", width: "26", height: "10", rx: "3" }),
|
|
9654
|
+
/* @__PURE__ */ jsx117("rect", { x: "54", y: "110", width: "26", height: "10", rx: "3" }),
|
|
9655
|
+
/* @__PURE__ */ jsx117("rect", { x: "162", y: "20", width: "26", height: "10", rx: "3" }),
|
|
9656
|
+
/* @__PURE__ */ jsx117("rect", { x: "162", y: "110", width: "26", height: "10", rx: "3" })
|
|
9644
9657
|
] }),
|
|
9645
9658
|
/* @__PURE__ */ jsxs69("g", { fill: colors.grey_200, stroke: colors.grey_400, strokeWidth: "1.5", children: [
|
|
9646
|
-
/* @__PURE__ */ jsx117("ellipse", { cx: "
|
|
9647
|
-
/* @__PURE__ */ jsx117("ellipse", { cx: "
|
|
9648
|
-
/* @__PURE__ */ jsx117("path", { d: "
|
|
9659
|
+
/* @__PURE__ */ jsx117("ellipse", { cx: "94", cy: "26", rx: "3", ry: "5" }),
|
|
9660
|
+
/* @__PURE__ */ jsx117("ellipse", { cx: "94", cy: "114", rx: "3", ry: "5" }),
|
|
9661
|
+
/* @__PURE__ */ jsx117("path", { d: "M34 48 Q34 28 58 28 H184 Q206 28 206 48 V92 Q206 112 184 112 H58 Q34 112 34 92 Z" })
|
|
9649
9662
|
] }),
|
|
9650
9663
|
/* @__PURE__ */ jsxs69("g", { fill: colors.grey_300, stroke: colors.grey_400, strokeWidth: "1", children: [
|
|
9651
|
-
/* @__PURE__ */ jsx117("path", { d: "
|
|
9652
|
-
/* @__PURE__ */ jsx117("path", { d: "
|
|
9664
|
+
/* @__PURE__ */ jsx117("path", { d: "M78 40 L98 46 V94 L78 100 Q70 70 78 40 Z" }),
|
|
9665
|
+
/* @__PURE__ */ jsx117("path", { d: "M180 42 L166 47 V93 L180 98 Q186 70 180 42 Z" })
|
|
9653
9666
|
] }),
|
|
9654
9667
|
/* @__PURE__ */ jsx117(
|
|
9655
9668
|
"rect",
|
|
9656
9669
|
{
|
|
9657
|
-
x: "
|
|
9658
|
-
y: "
|
|
9659
|
-
width: "
|
|
9660
|
-
height: "
|
|
9661
|
-
rx: "
|
|
9670
|
+
x: "102",
|
|
9671
|
+
y: "48",
|
|
9672
|
+
width: "60",
|
|
9673
|
+
height: "44",
|
|
9674
|
+
rx: "6",
|
|
9662
9675
|
fill: colors.grey_100,
|
|
9663
9676
|
stroke: colors.grey_400,
|
|
9664
9677
|
strokeWidth: "1"
|
|
9665
9678
|
}
|
|
9679
|
+
),
|
|
9680
|
+
sideLabels && /* @__PURE__ */ jsxs69(
|
|
9681
|
+
"g",
|
|
9682
|
+
{
|
|
9683
|
+
fill: colors.grey_500,
|
|
9684
|
+
fontSize: "7",
|
|
9685
|
+
fontWeight: "600",
|
|
9686
|
+
textAnchor: "middle",
|
|
9687
|
+
letterSpacing: "0.5",
|
|
9688
|
+
children: [
|
|
9689
|
+
/* @__PURE__ */ jsx117("text", { x: "120", y: "11", children: sideLabels.right.toUpperCase() }),
|
|
9690
|
+
/* @__PURE__ */ jsx117("text", { x: "120", y: "135", children: sideLabels.left.toUpperCase() }),
|
|
9691
|
+
/* @__PURE__ */ jsx117("text", { x: "14", y: "70", transform: "rotate(-90 14 70)", children: sideLabels.front.toUpperCase() }),
|
|
9692
|
+
/* @__PURE__ */ jsx117("text", { x: "226", y: "70", transform: "rotate(90 226 70)", children: sideLabels.rear.toUpperCase() })
|
|
9693
|
+
]
|
|
9694
|
+
}
|
|
9666
9695
|
)
|
|
9667
9696
|
]
|
|
9668
9697
|
}
|
|
9669
9698
|
);
|
|
9670
9699
|
var VehicleDamageMap = forwardRef36(
|
|
9671
9700
|
(_a, ref) => {
|
|
9672
|
-
var _b = _a, {
|
|
9701
|
+
var _b = _a, {
|
|
9702
|
+
marks,
|
|
9703
|
+
sideLabels,
|
|
9704
|
+
selectedZone,
|
|
9705
|
+
onZoneClick,
|
|
9706
|
+
width = 200,
|
|
9707
|
+
className
|
|
9708
|
+
} = _b, rest = __objRest(_b, [
|
|
9709
|
+
"marks",
|
|
9710
|
+
"sideLabels",
|
|
9711
|
+
"selectedZone",
|
|
9712
|
+
"onZoneClick",
|
|
9713
|
+
"width",
|
|
9714
|
+
"className"
|
|
9715
|
+
]);
|
|
9673
9716
|
return /* @__PURE__ */ jsxs69(
|
|
9674
9717
|
"div",
|
|
9675
9718
|
__spreadProps(__spreadValues({
|
|
@@ -9678,7 +9721,7 @@ var VehicleDamageMap = forwardRef36(
|
|
|
9678
9721
|
style: { width, height: width * HEIGHT / WIDTH }
|
|
9679
9722
|
}, rest), {
|
|
9680
9723
|
children: [
|
|
9681
|
-
/* @__PURE__ */ jsx117(VehicleOutline, {}),
|
|
9724
|
+
/* @__PURE__ */ jsx117(VehicleOutline, { sideLabels }),
|
|
9682
9725
|
marks.map((mark) => {
|
|
9683
9726
|
var _a2, _b2, _c;
|
|
9684
9727
|
const [x, y] = ZONE_POSITIONS[mark.zone];
|
|
@@ -9693,7 +9736,6 @@ var VehicleDamageMap = forwardRef36(
|
|
|
9693
9736
|
backgroundColor: TONES[(_a2 = mark.tone) != null ? _a2 : "danger"],
|
|
9694
9737
|
boxShadow: selected ? `0 0 0 2px ${colors.blue_950}` : void 0
|
|
9695
9738
|
};
|
|
9696
|
-
const content = mark.count && mark.count > 1 ? mark.count : null;
|
|
9697
9739
|
const pin = onZoneClick ? /* @__PURE__ */ jsx117(
|
|
9698
9740
|
"button",
|
|
9699
9741
|
{
|
|
@@ -9703,7 +9745,7 @@ var VehicleDamageMap = forwardRef36(
|
|
|
9703
9745
|
onClick: () => onZoneClick(mark.zone),
|
|
9704
9746
|
className: pinClassName,
|
|
9705
9747
|
style: pinStyle,
|
|
9706
|
-
children: content
|
|
9748
|
+
children: mark.content
|
|
9707
9749
|
}
|
|
9708
9750
|
) : /* @__PURE__ */ jsx117(
|
|
9709
9751
|
"span",
|
|
@@ -9712,7 +9754,7 @@ var VehicleDamageMap = forwardRef36(
|
|
|
9712
9754
|
"aria-label": (_c = mark.label) != null ? _c : mark.zone,
|
|
9713
9755
|
className: pinClassName,
|
|
9714
9756
|
style: pinStyle,
|
|
9715
|
-
children: content
|
|
9757
|
+
children: mark.content
|
|
9716
9758
|
}
|
|
9717
9759
|
);
|
|
9718
9760
|
return mark.label ? /* @__PURE__ */ jsx117(Tooltip, { content: mark.label, children: pin }, mark.zone) : /* @__PURE__ */ jsx117("span", { children: pin }, mark.zone);
|