@geomak/ui 6.5.0 → 6.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +356 -196
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +134 -1
- package/dist/index.d.ts +134 -1
- package/dist/index.js +169 -12
- package/dist/index.js.map +1 -1
- package/dist/styles.css +84 -0
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1016,6 +1016,139 @@ interface BadgeProps {
|
|
|
1016
1016
|
*/
|
|
1017
1017
|
declare function Badge({ children, tone, variant, size, icon, count, max, dot, showZero, className, style, }: BadgeProps): react_jsx_runtime.JSX.Element;
|
|
1018
1018
|
|
|
1019
|
+
type KbdSize = 'sm' | 'md';
|
|
1020
|
+
interface KbdProps {
|
|
1021
|
+
/** A single key's label when `keys` is not used. */
|
|
1022
|
+
children?: React__default.ReactNode;
|
|
1023
|
+
/**
|
|
1024
|
+
* A key combination — each entry renders as its own key cap, joined by
|
|
1025
|
+
* `separator`. e.g. `['Ctrl', 'K']` → `Ctrl + K`.
|
|
1026
|
+
*/
|
|
1027
|
+
keys?: string[];
|
|
1028
|
+
/** Joiner between caps in a combo. Default `'+'`. */
|
|
1029
|
+
separator?: React__default.ReactNode;
|
|
1030
|
+
/** Size preset. Default `'md'`. */
|
|
1031
|
+
size?: KbdSize;
|
|
1032
|
+
className?: string;
|
|
1033
|
+
style?: React__default.CSSProperties;
|
|
1034
|
+
}
|
|
1035
|
+
/**
|
|
1036
|
+
* Renders keyboard keys as styled caps — a single key via `children`, or a
|
|
1037
|
+
* combination via `keys` (each rendered as its own cap, joined by `separator`).
|
|
1038
|
+
*
|
|
1039
|
+
* @example
|
|
1040
|
+
* <Kbd>Esc</Kbd>
|
|
1041
|
+
* <Kbd keys={['Ctrl', 'K']} />
|
|
1042
|
+
* <Kbd keys={['⌘', '⇧', 'P']} size="sm" />
|
|
1043
|
+
*/
|
|
1044
|
+
declare function Kbd({ children, keys, separator, size, className, style, }: KbdProps): react_jsx_runtime.JSX.Element;
|
|
1045
|
+
|
|
1046
|
+
type Pad = 'none' | 'sm' | 'md' | 'lg';
|
|
1047
|
+
interface CardProps {
|
|
1048
|
+
children: React__default.ReactNode;
|
|
1049
|
+
/**
|
|
1050
|
+
* Make the whole card a single interactive surface: hover lift, pointer
|
|
1051
|
+
* cursor, focus ring, and (with `onClick`) button semantics + Enter/Space
|
|
1052
|
+
* activation.
|
|
1053
|
+
*/
|
|
1054
|
+
interactive?: boolean;
|
|
1055
|
+
/** Click handler. With `interactive`, the card becomes keyboard-activatable. */
|
|
1056
|
+
onClick?: React__default.MouseEventHandler;
|
|
1057
|
+
/**
|
|
1058
|
+
* Padding on the root. Leave `'none'` (default) when composing with
|
|
1059
|
+
* `Card.Header` / `Card.Body` / `Card.Footer` (they bring their own); set a
|
|
1060
|
+
* value for a quick flat card.
|
|
1061
|
+
*/
|
|
1062
|
+
padding?: Pad;
|
|
1063
|
+
/** Drop the border + shadow for a flat, borderless surface. */
|
|
1064
|
+
flush?: boolean;
|
|
1065
|
+
className?: string;
|
|
1066
|
+
style?: React__default.CSSProperties;
|
|
1067
|
+
}
|
|
1068
|
+
/**
|
|
1069
|
+
* A surface container with optional header / media / body / footer sections.
|
|
1070
|
+
*
|
|
1071
|
+
* @example Composed
|
|
1072
|
+
* ```tsx
|
|
1073
|
+
* <Card>
|
|
1074
|
+
* <Card.Media><img src={cover} alt="" /></Card.Media>
|
|
1075
|
+
* <Card.Header title="Aurora" subtitle="Bulk carrier" action={<IconButton … />} />
|
|
1076
|
+
* <Card.Body>Last seen off the North Sea, en route to Rotterdam.</Card.Body>
|
|
1077
|
+
* <Card.Footer><Button content="Track" /></Card.Footer>
|
|
1078
|
+
* </Card>
|
|
1079
|
+
* ```
|
|
1080
|
+
*
|
|
1081
|
+
* @example Quick flat card
|
|
1082
|
+
* ```tsx
|
|
1083
|
+
* <Card padding="md" interactive onClick={open}>Click me</Card>
|
|
1084
|
+
* ```
|
|
1085
|
+
*/
|
|
1086
|
+
declare function Card({ children, interactive, onClick, padding, flush, className, style }: CardProps): react_jsx_runtime.JSX.Element;
|
|
1087
|
+
declare namespace Card {
|
|
1088
|
+
var Media: typeof CardMedia;
|
|
1089
|
+
var Header: typeof CardHeader;
|
|
1090
|
+
var Body: typeof CardBody;
|
|
1091
|
+
var Footer: typeof CardFooter;
|
|
1092
|
+
}
|
|
1093
|
+
interface CardMediaProps {
|
|
1094
|
+
children: React__default.ReactNode;
|
|
1095
|
+
className?: string;
|
|
1096
|
+
}
|
|
1097
|
+
declare function CardMedia({ children, className }: CardMediaProps): react_jsx_runtime.JSX.Element;
|
|
1098
|
+
interface CardHeaderProps {
|
|
1099
|
+
title?: React__default.ReactNode;
|
|
1100
|
+
subtitle?: React__default.ReactNode;
|
|
1101
|
+
/** Trailing slot — actions, menu, badge. */
|
|
1102
|
+
action?: React__default.ReactNode;
|
|
1103
|
+
/** Leading slot — avatar / icon. */
|
|
1104
|
+
avatar?: React__default.ReactNode;
|
|
1105
|
+
children?: React__default.ReactNode;
|
|
1106
|
+
className?: string;
|
|
1107
|
+
}
|
|
1108
|
+
declare function CardHeader({ title, subtitle, action, avatar, children, className }: CardHeaderProps): react_jsx_runtime.JSX.Element;
|
|
1109
|
+
interface CardBodyProps {
|
|
1110
|
+
children: React__default.ReactNode;
|
|
1111
|
+
className?: string;
|
|
1112
|
+
}
|
|
1113
|
+
declare function CardBody({ children, className }: CardBodyProps): react_jsx_runtime.JSX.Element;
|
|
1114
|
+
interface CardFooterProps {
|
|
1115
|
+
children: React__default.ReactNode;
|
|
1116
|
+
/** Drop the top divider. */
|
|
1117
|
+
noDivider?: boolean;
|
|
1118
|
+
className?: string;
|
|
1119
|
+
}
|
|
1120
|
+
declare function CardFooter({ children, noDivider, className }: CardFooterProps): react_jsx_runtime.JSX.Element;
|
|
1121
|
+
|
|
1122
|
+
interface CardCarouselProps {
|
|
1123
|
+
/** The slides — typically `Card`s. Each becomes a snap target. */
|
|
1124
|
+
children: React__default.ReactNode;
|
|
1125
|
+
/** Width of each slide. Number → px. Default `280`. */
|
|
1126
|
+
itemWidth?: number | string;
|
|
1127
|
+
/** Gap between slides in px. Default `16`. */
|
|
1128
|
+
gap?: number;
|
|
1129
|
+
/** Show prev / next arrow buttons. Default `true`. */
|
|
1130
|
+
showArrows?: boolean;
|
|
1131
|
+
/** Show position dots. Default `false`. */
|
|
1132
|
+
showDots?: boolean;
|
|
1133
|
+
/** Accessible label for the region. Default `'Carousel'`. */
|
|
1134
|
+
'aria-label'?: string;
|
|
1135
|
+
className?: string;
|
|
1136
|
+
style?: React__default.CSSProperties;
|
|
1137
|
+
}
|
|
1138
|
+
/**
|
|
1139
|
+
* A horizontal, scroll-snap carousel for cards. Native scrolling drives it
|
|
1140
|
+
* (trackpad / touch / wheel), with optional arrow buttons and position dots.
|
|
1141
|
+
* Arrows disable at the ends; the scrollbar is hidden but scrolling is intact.
|
|
1142
|
+
*
|
|
1143
|
+
* @example
|
|
1144
|
+
* ```tsx
|
|
1145
|
+
* <CardCarousel itemWidth={300} showDots>
|
|
1146
|
+
* {vessels.map((v) => <Card key={v.id}>…</Card>)}
|
|
1147
|
+
* </CardCarousel>
|
|
1148
|
+
* ```
|
|
1149
|
+
*/
|
|
1150
|
+
declare function CardCarousel({ children, itemWidth, gap, showArrows, showDots, 'aria-label': ariaLabel, className, style, }: CardCarouselProps): react_jsx_runtime.JSX.Element;
|
|
1151
|
+
|
|
1019
1152
|
/** ─────────────────── types ─────────────────── */
|
|
1020
1153
|
type NotificationType = 'info' | 'success' | 'warning' | 'danger';
|
|
1021
1154
|
type NotificationPosition = 'top-right' | 'top-left' | 'top-center' | 'bottom-right' | 'bottom-left' | 'bottom-center';
|
|
@@ -4084,4 +4217,4 @@ declare function expiryError(value: string, now?: Date): string | undefined;
|
|
|
4084
4217
|
/** Validate the CVV against the detected brand's expected length. */
|
|
4085
4218
|
declare function cvvError(value: string, cardNumber: string): string | undefined;
|
|
4086
4219
|
|
|
4087
|
-
export { Accordion, type AccordionItemProps, type AccordionProps, AppShell, type AppShellProps, AutoComplete, type AutoCompleteProps, Avatar, type AvatarProps, type AvatarShape, type AvatarSize, type AvatarStatus, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BadgeVariant, Box, type BoxBackground, type BoxBorder, type BoxProps, type BoxRadius, type BoxShadow, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, CARD_BRANDS, type CardBrand, Catalog, CatalogCarousel, type CatalogCarouselProps, CatalogGrid, type CatalogGridProps, type CatalogProps, Checkbox, type CheckboxProps, ColorPicker, type ColorPickerProps, ContextMenu, type ContextMenuActionItem, type ContextMenuPosition, type ContextMenuProps, CreditCardForm, type CreditCardFormProps, type CreditCardValue, type DatePickerProps, type DateRange, DateRangePicker, type DateRangePickerProps, type DateRangePreset, Drawer, type DrawerProps, Dropdown, type DropdownItem, type DropdownProps, type ErrorMap, type ExpandRowOptions, FadingBase, type FadingBaseProps, Field, type FieldArrayItem, type FieldBindings, FieldHelpIcon, type FieldKind, FieldLabel, type FieldLabelProps, type FieldProps, type FieldRule, type FieldRules, type FieldShellOptions, type FieldSize, type FieldSnapshot, FileInput, type FileInputProps, Flex, type FlexAlign, type FlexDirection, type FlexJustify, type FlexProps, type FlexWrap, Form, FormContext, FormField, type FormFieldProps, type FormProps, FormStore, type FormStoreOptions, type FormValues, Grid, GridCard, type GridCardItem, type GridCardProps, type GridProps, Icon, IconButton, type IconButtonProps, List, type ListItem, type ListProps, LoadingSpinner, type LoadingSpinnerProps, MegaMenu, type MegaMenuFeaturedProps, type MegaMenuItemProps, type MegaMenuLinkProps, type MegaMenuPanelProps, type MegaMenuProps, type MegaMenuSectionProps, Modal, type ModalProps, type NotificationPayload, NotificationProvider, NumberInput, type NumberInputProps, OpaqueGridCard, type OpaqueGridCardProps, OtpInput, type OtpInputProps, type PaginationOptions, Password, type PasswordProps, Portal, type PortalProps, RadioGroup, type RadioGroupProps, type RadioOption, Rating, type RatingProps, type RulesMap, ScalableContainer, type ScalableContainerProps, SearchInput, type SearchInputProps, SegmentedControl, type SegmentedControlProps, type SegmentedOption, Sidebar, type SidebarItem, type SidebarProps, type SidebarSection, SkeletonBox, type SkeletonBoxProps, SkeletonCard, type SkeletonCardProps, SkeletonCircle, type SkeletonCircleProps, SkeletonText, type SkeletonTextProps, Slider, type SliderMark, type SliderProps, type SliderValue, type Spacing, Switch, type SwitchInputProps, Table, type TableColumn, type TableProps, Tabs, type TabsAddProps, type TabsListProps, type TabsOrientation, type TabsPanelProps, type TabsProps, type TabsSize, type TabsTriggerProps, type TabsVariant, TagsInput, type TagsInputProps, DatePicker as Temporal, type TemporalPickerProps, TextArea, type TextAreaProps, TextInput, type TextInputProps, type ThemeColors, type ThemeConfig, type ThemeDensity, type ThemeMotion, ThemeProvider, type ThemeProviderProps, type ThemeRadius, type ThemeShadows, ThemeSwitch, type ThemeSwitchProps, type ThemeTypography, TimePicker, type TimePickerProps, Tooltip, type TooltipProps, TooltipProvider, TopBar, type TopBarProps, Tree, type TreeItemClickPayload, type TreeNode, type TreeProps, TreeSelect, type TreeSelectProps, Typography, type TypographyAlign, type TypographyColor, type TypographyProps, type TypographyVariant, type TypographyWeight, type UseFieldArrayReturn, type UseFormFieldOptions, type UseFormReturn, type ValidateTrigger, Wizard, type WizardProps, type WizardStep, cardNumberError, cvvError, detectBrand, expiryError, fieldShell, formatCardNumber, formatExpiry, isRequired, luhnValid, onlyDigits, patterns, runFieldRules, useFieldArray, useForm, useFormField, useFormStore, useNotification };
|
|
4220
|
+
export { Accordion, type AccordionItemProps, type AccordionProps, AppShell, type AppShellProps, AutoComplete, type AutoCompleteProps, Avatar, type AvatarProps, type AvatarShape, type AvatarSize, type AvatarStatus, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BadgeVariant, Box, type BoxBackground, type BoxBorder, type BoxProps, type BoxRadius, type BoxShadow, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, CARD_BRANDS, Card, type CardBodyProps, type CardBrand, CardCarousel, type CardCarouselProps, type CardFooterProps, type CardHeaderProps, type CardMediaProps, type CardProps, Catalog, CatalogCarousel, type CatalogCarouselProps, CatalogGrid, type CatalogGridProps, type CatalogProps, Checkbox, type CheckboxProps, ColorPicker, type ColorPickerProps, ContextMenu, type ContextMenuActionItem, type ContextMenuPosition, type ContextMenuProps, CreditCardForm, type CreditCardFormProps, type CreditCardValue, type DatePickerProps, type DateRange, DateRangePicker, type DateRangePickerProps, type DateRangePreset, Drawer, type DrawerProps, Dropdown, type DropdownItem, type DropdownProps, type ErrorMap, type ExpandRowOptions, FadingBase, type FadingBaseProps, Field, type FieldArrayItem, type FieldBindings, FieldHelpIcon, type FieldKind, FieldLabel, type FieldLabelProps, type FieldProps, type FieldRule, type FieldRules, type FieldShellOptions, type FieldSize, type FieldSnapshot, FileInput, type FileInputProps, Flex, type FlexAlign, type FlexDirection, type FlexJustify, type FlexProps, type FlexWrap, Form, FormContext, FormField, type FormFieldProps, type FormProps, FormStore, type FormStoreOptions, type FormValues, Grid, GridCard, type GridCardItem, type GridCardProps, type GridProps, Icon, IconButton, type IconButtonProps, Kbd, type KbdProps, type KbdSize, List, type ListItem, type ListProps, LoadingSpinner, type LoadingSpinnerProps, MegaMenu, type MegaMenuFeaturedProps, type MegaMenuItemProps, type MegaMenuLinkProps, type MegaMenuPanelProps, type MegaMenuProps, type MegaMenuSectionProps, Modal, type ModalProps, type NotificationPayload, NotificationProvider, NumberInput, type NumberInputProps, OpaqueGridCard, type OpaqueGridCardProps, OtpInput, type OtpInputProps, type PaginationOptions, Password, type PasswordProps, Portal, type PortalProps, RadioGroup, type RadioGroupProps, type RadioOption, Rating, type RatingProps, type RulesMap, ScalableContainer, type ScalableContainerProps, SearchInput, type SearchInputProps, SegmentedControl, type SegmentedControlProps, type SegmentedOption, Sidebar, type SidebarItem, type SidebarProps, type SidebarSection, SkeletonBox, type SkeletonBoxProps, SkeletonCard, type SkeletonCardProps, SkeletonCircle, type SkeletonCircleProps, SkeletonText, type SkeletonTextProps, Slider, type SliderMark, type SliderProps, type SliderValue, type Spacing, Switch, type SwitchInputProps, Table, type TableColumn, type TableProps, Tabs, type TabsAddProps, type TabsListProps, type TabsOrientation, type TabsPanelProps, type TabsProps, type TabsSize, type TabsTriggerProps, type TabsVariant, TagsInput, type TagsInputProps, DatePicker as Temporal, type TemporalPickerProps, TextArea, type TextAreaProps, TextInput, type TextInputProps, type ThemeColors, type ThemeConfig, type ThemeDensity, type ThemeMotion, ThemeProvider, type ThemeProviderProps, type ThemeRadius, type ThemeShadows, ThemeSwitch, type ThemeSwitchProps, type ThemeTypography, TimePicker, type TimePickerProps, Tooltip, type TooltipProps, TooltipProvider, TopBar, type TopBarProps, Tree, type TreeItemClickPayload, type TreeNode, type TreeProps, TreeSelect, type TreeSelectProps, Typography, type TypographyAlign, type TypographyColor, type TypographyProps, type TypographyVariant, type TypographyWeight, type UseFieldArrayReturn, type UseFormFieldOptions, type UseFormReturn, type ValidateTrigger, Wizard, type WizardProps, type WizardStep, cardNumberError, cvvError, detectBrand, expiryError, fieldShell, formatCardNumber, formatExpiry, isRequired, luhnValid, onlyDigits, patterns, runFieldRules, useFieldArray, useForm, useFormField, useFormStore, useNotification };
|
package/dist/index.d.ts
CHANGED
|
@@ -1016,6 +1016,139 @@ interface BadgeProps {
|
|
|
1016
1016
|
*/
|
|
1017
1017
|
declare function Badge({ children, tone, variant, size, icon, count, max, dot, showZero, className, style, }: BadgeProps): react_jsx_runtime.JSX.Element;
|
|
1018
1018
|
|
|
1019
|
+
type KbdSize = 'sm' | 'md';
|
|
1020
|
+
interface KbdProps {
|
|
1021
|
+
/** A single key's label when `keys` is not used. */
|
|
1022
|
+
children?: React__default.ReactNode;
|
|
1023
|
+
/**
|
|
1024
|
+
* A key combination — each entry renders as its own key cap, joined by
|
|
1025
|
+
* `separator`. e.g. `['Ctrl', 'K']` → `Ctrl + K`.
|
|
1026
|
+
*/
|
|
1027
|
+
keys?: string[];
|
|
1028
|
+
/** Joiner between caps in a combo. Default `'+'`. */
|
|
1029
|
+
separator?: React__default.ReactNode;
|
|
1030
|
+
/** Size preset. Default `'md'`. */
|
|
1031
|
+
size?: KbdSize;
|
|
1032
|
+
className?: string;
|
|
1033
|
+
style?: React__default.CSSProperties;
|
|
1034
|
+
}
|
|
1035
|
+
/**
|
|
1036
|
+
* Renders keyboard keys as styled caps — a single key via `children`, or a
|
|
1037
|
+
* combination via `keys` (each rendered as its own cap, joined by `separator`).
|
|
1038
|
+
*
|
|
1039
|
+
* @example
|
|
1040
|
+
* <Kbd>Esc</Kbd>
|
|
1041
|
+
* <Kbd keys={['Ctrl', 'K']} />
|
|
1042
|
+
* <Kbd keys={['⌘', '⇧', 'P']} size="sm" />
|
|
1043
|
+
*/
|
|
1044
|
+
declare function Kbd({ children, keys, separator, size, className, style, }: KbdProps): react_jsx_runtime.JSX.Element;
|
|
1045
|
+
|
|
1046
|
+
type Pad = 'none' | 'sm' | 'md' | 'lg';
|
|
1047
|
+
interface CardProps {
|
|
1048
|
+
children: React__default.ReactNode;
|
|
1049
|
+
/**
|
|
1050
|
+
* Make the whole card a single interactive surface: hover lift, pointer
|
|
1051
|
+
* cursor, focus ring, and (with `onClick`) button semantics + Enter/Space
|
|
1052
|
+
* activation.
|
|
1053
|
+
*/
|
|
1054
|
+
interactive?: boolean;
|
|
1055
|
+
/** Click handler. With `interactive`, the card becomes keyboard-activatable. */
|
|
1056
|
+
onClick?: React__default.MouseEventHandler;
|
|
1057
|
+
/**
|
|
1058
|
+
* Padding on the root. Leave `'none'` (default) when composing with
|
|
1059
|
+
* `Card.Header` / `Card.Body` / `Card.Footer` (they bring their own); set a
|
|
1060
|
+
* value for a quick flat card.
|
|
1061
|
+
*/
|
|
1062
|
+
padding?: Pad;
|
|
1063
|
+
/** Drop the border + shadow for a flat, borderless surface. */
|
|
1064
|
+
flush?: boolean;
|
|
1065
|
+
className?: string;
|
|
1066
|
+
style?: React__default.CSSProperties;
|
|
1067
|
+
}
|
|
1068
|
+
/**
|
|
1069
|
+
* A surface container with optional header / media / body / footer sections.
|
|
1070
|
+
*
|
|
1071
|
+
* @example Composed
|
|
1072
|
+
* ```tsx
|
|
1073
|
+
* <Card>
|
|
1074
|
+
* <Card.Media><img src={cover} alt="" /></Card.Media>
|
|
1075
|
+
* <Card.Header title="Aurora" subtitle="Bulk carrier" action={<IconButton … />} />
|
|
1076
|
+
* <Card.Body>Last seen off the North Sea, en route to Rotterdam.</Card.Body>
|
|
1077
|
+
* <Card.Footer><Button content="Track" /></Card.Footer>
|
|
1078
|
+
* </Card>
|
|
1079
|
+
* ```
|
|
1080
|
+
*
|
|
1081
|
+
* @example Quick flat card
|
|
1082
|
+
* ```tsx
|
|
1083
|
+
* <Card padding="md" interactive onClick={open}>Click me</Card>
|
|
1084
|
+
* ```
|
|
1085
|
+
*/
|
|
1086
|
+
declare function Card({ children, interactive, onClick, padding, flush, className, style }: CardProps): react_jsx_runtime.JSX.Element;
|
|
1087
|
+
declare namespace Card {
|
|
1088
|
+
var Media: typeof CardMedia;
|
|
1089
|
+
var Header: typeof CardHeader;
|
|
1090
|
+
var Body: typeof CardBody;
|
|
1091
|
+
var Footer: typeof CardFooter;
|
|
1092
|
+
}
|
|
1093
|
+
interface CardMediaProps {
|
|
1094
|
+
children: React__default.ReactNode;
|
|
1095
|
+
className?: string;
|
|
1096
|
+
}
|
|
1097
|
+
declare function CardMedia({ children, className }: CardMediaProps): react_jsx_runtime.JSX.Element;
|
|
1098
|
+
interface CardHeaderProps {
|
|
1099
|
+
title?: React__default.ReactNode;
|
|
1100
|
+
subtitle?: React__default.ReactNode;
|
|
1101
|
+
/** Trailing slot — actions, menu, badge. */
|
|
1102
|
+
action?: React__default.ReactNode;
|
|
1103
|
+
/** Leading slot — avatar / icon. */
|
|
1104
|
+
avatar?: React__default.ReactNode;
|
|
1105
|
+
children?: React__default.ReactNode;
|
|
1106
|
+
className?: string;
|
|
1107
|
+
}
|
|
1108
|
+
declare function CardHeader({ title, subtitle, action, avatar, children, className }: CardHeaderProps): react_jsx_runtime.JSX.Element;
|
|
1109
|
+
interface CardBodyProps {
|
|
1110
|
+
children: React__default.ReactNode;
|
|
1111
|
+
className?: string;
|
|
1112
|
+
}
|
|
1113
|
+
declare function CardBody({ children, className }: CardBodyProps): react_jsx_runtime.JSX.Element;
|
|
1114
|
+
interface CardFooterProps {
|
|
1115
|
+
children: React__default.ReactNode;
|
|
1116
|
+
/** Drop the top divider. */
|
|
1117
|
+
noDivider?: boolean;
|
|
1118
|
+
className?: string;
|
|
1119
|
+
}
|
|
1120
|
+
declare function CardFooter({ children, noDivider, className }: CardFooterProps): react_jsx_runtime.JSX.Element;
|
|
1121
|
+
|
|
1122
|
+
interface CardCarouselProps {
|
|
1123
|
+
/** The slides — typically `Card`s. Each becomes a snap target. */
|
|
1124
|
+
children: React__default.ReactNode;
|
|
1125
|
+
/** Width of each slide. Number → px. Default `280`. */
|
|
1126
|
+
itemWidth?: number | string;
|
|
1127
|
+
/** Gap between slides in px. Default `16`. */
|
|
1128
|
+
gap?: number;
|
|
1129
|
+
/** Show prev / next arrow buttons. Default `true`. */
|
|
1130
|
+
showArrows?: boolean;
|
|
1131
|
+
/** Show position dots. Default `false`. */
|
|
1132
|
+
showDots?: boolean;
|
|
1133
|
+
/** Accessible label for the region. Default `'Carousel'`. */
|
|
1134
|
+
'aria-label'?: string;
|
|
1135
|
+
className?: string;
|
|
1136
|
+
style?: React__default.CSSProperties;
|
|
1137
|
+
}
|
|
1138
|
+
/**
|
|
1139
|
+
* A horizontal, scroll-snap carousel for cards. Native scrolling drives it
|
|
1140
|
+
* (trackpad / touch / wheel), with optional arrow buttons and position dots.
|
|
1141
|
+
* Arrows disable at the ends; the scrollbar is hidden but scrolling is intact.
|
|
1142
|
+
*
|
|
1143
|
+
* @example
|
|
1144
|
+
* ```tsx
|
|
1145
|
+
* <CardCarousel itemWidth={300} showDots>
|
|
1146
|
+
* {vessels.map((v) => <Card key={v.id}>…</Card>)}
|
|
1147
|
+
* </CardCarousel>
|
|
1148
|
+
* ```
|
|
1149
|
+
*/
|
|
1150
|
+
declare function CardCarousel({ children, itemWidth, gap, showArrows, showDots, 'aria-label': ariaLabel, className, style, }: CardCarouselProps): react_jsx_runtime.JSX.Element;
|
|
1151
|
+
|
|
1019
1152
|
/** ─────────────────── types ─────────────────── */
|
|
1020
1153
|
type NotificationType = 'info' | 'success' | 'warning' | 'danger';
|
|
1021
1154
|
type NotificationPosition = 'top-right' | 'top-left' | 'top-center' | 'bottom-right' | 'bottom-left' | 'bottom-center';
|
|
@@ -4084,4 +4217,4 @@ declare function expiryError(value: string, now?: Date): string | undefined;
|
|
|
4084
4217
|
/** Validate the CVV against the detected brand's expected length. */
|
|
4085
4218
|
declare function cvvError(value: string, cardNumber: string): string | undefined;
|
|
4086
4219
|
|
|
4087
|
-
export { Accordion, type AccordionItemProps, type AccordionProps, AppShell, type AppShellProps, AutoComplete, type AutoCompleteProps, Avatar, type AvatarProps, type AvatarShape, type AvatarSize, type AvatarStatus, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BadgeVariant, Box, type BoxBackground, type BoxBorder, type BoxProps, type BoxRadius, type BoxShadow, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, CARD_BRANDS, type CardBrand, Catalog, CatalogCarousel, type CatalogCarouselProps, CatalogGrid, type CatalogGridProps, type CatalogProps, Checkbox, type CheckboxProps, ColorPicker, type ColorPickerProps, ContextMenu, type ContextMenuActionItem, type ContextMenuPosition, type ContextMenuProps, CreditCardForm, type CreditCardFormProps, type CreditCardValue, type DatePickerProps, type DateRange, DateRangePicker, type DateRangePickerProps, type DateRangePreset, Drawer, type DrawerProps, Dropdown, type DropdownItem, type DropdownProps, type ErrorMap, type ExpandRowOptions, FadingBase, type FadingBaseProps, Field, type FieldArrayItem, type FieldBindings, FieldHelpIcon, type FieldKind, FieldLabel, type FieldLabelProps, type FieldProps, type FieldRule, type FieldRules, type FieldShellOptions, type FieldSize, type FieldSnapshot, FileInput, type FileInputProps, Flex, type FlexAlign, type FlexDirection, type FlexJustify, type FlexProps, type FlexWrap, Form, FormContext, FormField, type FormFieldProps, type FormProps, FormStore, type FormStoreOptions, type FormValues, Grid, GridCard, type GridCardItem, type GridCardProps, type GridProps, Icon, IconButton, type IconButtonProps, List, type ListItem, type ListProps, LoadingSpinner, type LoadingSpinnerProps, MegaMenu, type MegaMenuFeaturedProps, type MegaMenuItemProps, type MegaMenuLinkProps, type MegaMenuPanelProps, type MegaMenuProps, type MegaMenuSectionProps, Modal, type ModalProps, type NotificationPayload, NotificationProvider, NumberInput, type NumberInputProps, OpaqueGridCard, type OpaqueGridCardProps, OtpInput, type OtpInputProps, type PaginationOptions, Password, type PasswordProps, Portal, type PortalProps, RadioGroup, type RadioGroupProps, type RadioOption, Rating, type RatingProps, type RulesMap, ScalableContainer, type ScalableContainerProps, SearchInput, type SearchInputProps, SegmentedControl, type SegmentedControlProps, type SegmentedOption, Sidebar, type SidebarItem, type SidebarProps, type SidebarSection, SkeletonBox, type SkeletonBoxProps, SkeletonCard, type SkeletonCardProps, SkeletonCircle, type SkeletonCircleProps, SkeletonText, type SkeletonTextProps, Slider, type SliderMark, type SliderProps, type SliderValue, type Spacing, Switch, type SwitchInputProps, Table, type TableColumn, type TableProps, Tabs, type TabsAddProps, type TabsListProps, type TabsOrientation, type TabsPanelProps, type TabsProps, type TabsSize, type TabsTriggerProps, type TabsVariant, TagsInput, type TagsInputProps, DatePicker as Temporal, type TemporalPickerProps, TextArea, type TextAreaProps, TextInput, type TextInputProps, type ThemeColors, type ThemeConfig, type ThemeDensity, type ThemeMotion, ThemeProvider, type ThemeProviderProps, type ThemeRadius, type ThemeShadows, ThemeSwitch, type ThemeSwitchProps, type ThemeTypography, TimePicker, type TimePickerProps, Tooltip, type TooltipProps, TooltipProvider, TopBar, type TopBarProps, Tree, type TreeItemClickPayload, type TreeNode, type TreeProps, TreeSelect, type TreeSelectProps, Typography, type TypographyAlign, type TypographyColor, type TypographyProps, type TypographyVariant, type TypographyWeight, type UseFieldArrayReturn, type UseFormFieldOptions, type UseFormReturn, type ValidateTrigger, Wizard, type WizardProps, type WizardStep, cardNumberError, cvvError, detectBrand, expiryError, fieldShell, formatCardNumber, formatExpiry, isRequired, luhnValid, onlyDigits, patterns, runFieldRules, useFieldArray, useForm, useFormField, useFormStore, useNotification };
|
|
4220
|
+
export { Accordion, type AccordionItemProps, type AccordionProps, AppShell, type AppShellProps, AutoComplete, type AutoCompleteProps, Avatar, type AvatarProps, type AvatarShape, type AvatarSize, type AvatarStatus, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BadgeVariant, Box, type BoxBackground, type BoxBorder, type BoxProps, type BoxRadius, type BoxShadow, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, CARD_BRANDS, Card, type CardBodyProps, type CardBrand, CardCarousel, type CardCarouselProps, type CardFooterProps, type CardHeaderProps, type CardMediaProps, type CardProps, Catalog, CatalogCarousel, type CatalogCarouselProps, CatalogGrid, type CatalogGridProps, type CatalogProps, Checkbox, type CheckboxProps, ColorPicker, type ColorPickerProps, ContextMenu, type ContextMenuActionItem, type ContextMenuPosition, type ContextMenuProps, CreditCardForm, type CreditCardFormProps, type CreditCardValue, type DatePickerProps, type DateRange, DateRangePicker, type DateRangePickerProps, type DateRangePreset, Drawer, type DrawerProps, Dropdown, type DropdownItem, type DropdownProps, type ErrorMap, type ExpandRowOptions, FadingBase, type FadingBaseProps, Field, type FieldArrayItem, type FieldBindings, FieldHelpIcon, type FieldKind, FieldLabel, type FieldLabelProps, type FieldProps, type FieldRule, type FieldRules, type FieldShellOptions, type FieldSize, type FieldSnapshot, FileInput, type FileInputProps, Flex, type FlexAlign, type FlexDirection, type FlexJustify, type FlexProps, type FlexWrap, Form, FormContext, FormField, type FormFieldProps, type FormProps, FormStore, type FormStoreOptions, type FormValues, Grid, GridCard, type GridCardItem, type GridCardProps, type GridProps, Icon, IconButton, type IconButtonProps, Kbd, type KbdProps, type KbdSize, List, type ListItem, type ListProps, LoadingSpinner, type LoadingSpinnerProps, MegaMenu, type MegaMenuFeaturedProps, type MegaMenuItemProps, type MegaMenuLinkProps, type MegaMenuPanelProps, type MegaMenuProps, type MegaMenuSectionProps, Modal, type ModalProps, type NotificationPayload, NotificationProvider, NumberInput, type NumberInputProps, OpaqueGridCard, type OpaqueGridCardProps, OtpInput, type OtpInputProps, type PaginationOptions, Password, type PasswordProps, Portal, type PortalProps, RadioGroup, type RadioGroupProps, type RadioOption, Rating, type RatingProps, type RulesMap, ScalableContainer, type ScalableContainerProps, SearchInput, type SearchInputProps, SegmentedControl, type SegmentedControlProps, type SegmentedOption, Sidebar, type SidebarItem, type SidebarProps, type SidebarSection, SkeletonBox, type SkeletonBoxProps, SkeletonCard, type SkeletonCardProps, SkeletonCircle, type SkeletonCircleProps, SkeletonText, type SkeletonTextProps, Slider, type SliderMark, type SliderProps, type SliderValue, type Spacing, Switch, type SwitchInputProps, Table, type TableColumn, type TableProps, Tabs, type TabsAddProps, type TabsListProps, type TabsOrientation, type TabsPanelProps, type TabsProps, type TabsSize, type TabsTriggerProps, type TabsVariant, TagsInput, type TagsInputProps, DatePicker as Temporal, type TemporalPickerProps, TextArea, type TextAreaProps, TextInput, type TextInputProps, type ThemeColors, type ThemeConfig, type ThemeDensity, type ThemeMotion, ThemeProvider, type ThemeProviderProps, type ThemeRadius, type ThemeShadows, ThemeSwitch, type ThemeSwitchProps, type ThemeTypography, TimePicker, type TimePickerProps, Tooltip, type TooltipProps, TooltipProvider, TopBar, type TopBarProps, Tree, type TreeItemClickPayload, type TreeNode, type TreeProps, TreeSelect, type TreeSelectProps, Typography, type TypographyAlign, type TypographyColor, type TypographyProps, type TypographyVariant, type TypographyWeight, type UseFieldArrayReturn, type UseFormFieldOptions, type UseFormReturn, type ValidateTrigger, Wizard, type WizardProps, type WizardStep, cardNumberError, cvvError, detectBrand, expiryError, fieldShell, formatCardNumber, formatExpiry, isRequired, luhnValid, onlyDigits, patterns, runFieldRules, useFieldArray, useForm, useFormField, useFormStore, useNotification };
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { colors_default } from './chunk-GKXP6OJJ.js';
|
|
2
2
|
export { colors_default as COLORS, PALETTE as palette, semanticTokens, vars } from './chunk-GKXP6OJJ.js';
|
|
3
3
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
4
|
-
import
|
|
4
|
+
import React16, { createContext, useState, useEffect, useMemo, useId, useCallback, useRef, useContext, useLayoutEffect, useSyncExternalStore } from 'react';
|
|
5
5
|
import { createPortal } from 'react-dom';
|
|
6
6
|
import * as AvatarPrimitive from '@radix-ui/react-avatar';
|
|
7
7
|
import * as Dialog from '@radix-ui/react-dialog';
|
|
@@ -1616,6 +1616,163 @@ function Badge({
|
|
|
1616
1616
|
!hidden && /* @__PURE__ */ jsx("span", { className: "absolute -top-1 -right-1 flex", children: indicator })
|
|
1617
1617
|
] });
|
|
1618
1618
|
}
|
|
1619
|
+
var SIZE3 = {
|
|
1620
|
+
sm: "h-5 min-w-[20px] px-1.5 text-[11px]",
|
|
1621
|
+
md: "h-6 min-w-[24px] px-2 text-xs"
|
|
1622
|
+
};
|
|
1623
|
+
var cap = "inline-flex items-center justify-center rounded-md border border-border border-b-2 bg-surface-raised font-medium text-foreground-secondary leading-none select-none font-sans shadow-sm";
|
|
1624
|
+
function Kbd({
|
|
1625
|
+
children,
|
|
1626
|
+
keys,
|
|
1627
|
+
separator = "+",
|
|
1628
|
+
size = "md",
|
|
1629
|
+
className = "",
|
|
1630
|
+
style
|
|
1631
|
+
}) {
|
|
1632
|
+
if (keys && keys.length > 0) {
|
|
1633
|
+
return /* @__PURE__ */ jsx("span", { className: ["inline-flex items-center gap-1", className].filter(Boolean).join(" "), style, children: keys.map((k, i) => /* @__PURE__ */ jsxs(React16.Fragment, { children: [
|
|
1634
|
+
i > 0 && /* @__PURE__ */ jsx("span", { className: "text-foreground-muted text-xs select-none", children: separator }),
|
|
1635
|
+
/* @__PURE__ */ jsx("kbd", { className: [cap, SIZE3[size]].join(" "), children: k })
|
|
1636
|
+
] }, `${k}-${i}`)) });
|
|
1637
|
+
}
|
|
1638
|
+
return /* @__PURE__ */ jsx("kbd", { className: [cap, SIZE3[size], className].filter(Boolean).join(" "), style, children });
|
|
1639
|
+
}
|
|
1640
|
+
var PAD = { none: "", sm: "p-3", md: "p-5", lg: "p-6" };
|
|
1641
|
+
function Card({ children, interactive, onClick, padding: padding2 = "none", flush, className = "", style }) {
|
|
1642
|
+
const base = [
|
|
1643
|
+
"rounded-xl overflow-hidden bg-surface",
|
|
1644
|
+
flush ? "" : "border border-border shadow-sm",
|
|
1645
|
+
PAD[padding2],
|
|
1646
|
+
interactive ? "transition-[transform,box-shadow] duration-200 ease-out hover:-translate-y-0.5 hover:shadow-md cursor-pointer focus:outline-none focus-visible:ring-2 focus-visible:ring-accent" : "",
|
|
1647
|
+
className
|
|
1648
|
+
].filter(Boolean).join(" ");
|
|
1649
|
+
if (interactive && onClick) {
|
|
1650
|
+
return /* @__PURE__ */ jsx(
|
|
1651
|
+
"div",
|
|
1652
|
+
{
|
|
1653
|
+
role: "button",
|
|
1654
|
+
tabIndex: 0,
|
|
1655
|
+
onClick,
|
|
1656
|
+
onKeyDown: (e) => {
|
|
1657
|
+
if (e.key === "Enter" || e.key === " ") {
|
|
1658
|
+
e.preventDefault();
|
|
1659
|
+
onClick(e);
|
|
1660
|
+
}
|
|
1661
|
+
},
|
|
1662
|
+
className: base,
|
|
1663
|
+
style,
|
|
1664
|
+
children
|
|
1665
|
+
}
|
|
1666
|
+
);
|
|
1667
|
+
}
|
|
1668
|
+
return /* @__PURE__ */ jsx("div", { onClick, className: base, style, children });
|
|
1669
|
+
}
|
|
1670
|
+
function CardMedia({ children, className = "" }) {
|
|
1671
|
+
return /* @__PURE__ */ jsx("div", { className: ["[&>img]:block [&>img]:w-full [&>img]:object-cover", className].filter(Boolean).join(" "), children });
|
|
1672
|
+
}
|
|
1673
|
+
function CardHeader({ title, subtitle, action, avatar, children, className = "" }) {
|
|
1674
|
+
return /* @__PURE__ */ jsxs("div", { className: ["flex items-start gap-3 px-5 pt-5", children ? "pb-0" : "pb-3", className].filter(Boolean).join(" "), children: [
|
|
1675
|
+
avatar && /* @__PURE__ */ jsx("div", { className: "flex-shrink-0", children: avatar }),
|
|
1676
|
+
/* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1", children: [
|
|
1677
|
+
title && /* @__PURE__ */ jsx("div", { className: "text-sm font-semibold text-foreground leading-snug", children: title }),
|
|
1678
|
+
subtitle && /* @__PURE__ */ jsx("div", { className: "text-xs text-foreground-muted leading-snug mt-0.5", children: subtitle }),
|
|
1679
|
+
children
|
|
1680
|
+
] }),
|
|
1681
|
+
action && /* @__PURE__ */ jsx("div", { className: "flex-shrink-0 -mt-1 -mr-1", children: action })
|
|
1682
|
+
] });
|
|
1683
|
+
}
|
|
1684
|
+
function CardBody({ children, className = "" }) {
|
|
1685
|
+
return /* @__PURE__ */ jsx("div", { className: ["px-5 py-4 text-sm text-foreground-secondary leading-relaxed", className].filter(Boolean).join(" "), children });
|
|
1686
|
+
}
|
|
1687
|
+
function CardFooter({ children, noDivider, className = "" }) {
|
|
1688
|
+
return /* @__PURE__ */ jsx("div", { className: ["flex items-center gap-2 px-5 py-3", noDivider ? "" : "border-t border-border", className].filter(Boolean).join(" "), children });
|
|
1689
|
+
}
|
|
1690
|
+
Card.Media = CardMedia;
|
|
1691
|
+
Card.Header = CardHeader;
|
|
1692
|
+
Card.Body = CardBody;
|
|
1693
|
+
Card.Footer = CardFooter;
|
|
1694
|
+
var Card_default = Card;
|
|
1695
|
+
var Arrow2 = ({ dir }) => /* @__PURE__ */ jsx("svg", { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, "aria-hidden": "true", className: "h-5 w-5", children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: dir === "left" ? "M15 19l-7-7 7-7" : "M9 5l7 7-7 7" }) });
|
|
1696
|
+
function CardCarousel({
|
|
1697
|
+
children,
|
|
1698
|
+
itemWidth = 280,
|
|
1699
|
+
gap = 16,
|
|
1700
|
+
showArrows = true,
|
|
1701
|
+
showDots = false,
|
|
1702
|
+
"aria-label": ariaLabel = "Carousel",
|
|
1703
|
+
className = "",
|
|
1704
|
+
style
|
|
1705
|
+
}) {
|
|
1706
|
+
const scrollerRef = useRef(null);
|
|
1707
|
+
const slides = React16.Children.toArray(children);
|
|
1708
|
+
const [active, setActive] = useState(0);
|
|
1709
|
+
const [atStart, setAtStart] = useState(true);
|
|
1710
|
+
const [atEnd, setAtEnd] = useState(false);
|
|
1711
|
+
const width = typeof itemWidth === "number" ? `${itemWidth}px` : itemWidth;
|
|
1712
|
+
const update = useCallback(() => {
|
|
1713
|
+
const el = scrollerRef.current;
|
|
1714
|
+
if (!el) return;
|
|
1715
|
+
el.clientWidth;
|
|
1716
|
+
setAtStart(el.scrollLeft <= 1);
|
|
1717
|
+
setAtEnd(el.scrollLeft + el.clientWidth >= el.scrollWidth - 1);
|
|
1718
|
+
const first = el.firstElementChild;
|
|
1719
|
+
const slideW = first ? first.getBoundingClientRect().width + gap : el.clientWidth;
|
|
1720
|
+
setActive(Math.round(el.scrollLeft / slideW));
|
|
1721
|
+
}, [gap]);
|
|
1722
|
+
useEffect(() => {
|
|
1723
|
+
update();
|
|
1724
|
+
const el = scrollerRef.current;
|
|
1725
|
+
if (!el) return;
|
|
1726
|
+
el.addEventListener("scroll", update, { passive: true });
|
|
1727
|
+
window.addEventListener("resize", update);
|
|
1728
|
+
return () => {
|
|
1729
|
+
el.removeEventListener("scroll", update);
|
|
1730
|
+
window.removeEventListener("resize", update);
|
|
1731
|
+
};
|
|
1732
|
+
}, [update]);
|
|
1733
|
+
const scrollByDir = (dir) => {
|
|
1734
|
+
const el = scrollerRef.current;
|
|
1735
|
+
if (!el) return;
|
|
1736
|
+
const first = el.firstElementChild;
|
|
1737
|
+
const slideW = first ? first.getBoundingClientRect().width + gap : el.clientWidth;
|
|
1738
|
+
el.scrollBy({ left: dir * slideW, behavior: "smooth" });
|
|
1739
|
+
};
|
|
1740
|
+
const scrollTo = (i) => {
|
|
1741
|
+
const el = scrollerRef.current;
|
|
1742
|
+
if (!el) return;
|
|
1743
|
+
const first = el.firstElementChild;
|
|
1744
|
+
const slideW = first ? first.getBoundingClientRect().width + gap : el.clientWidth;
|
|
1745
|
+
el.scrollTo({ left: i * slideW, behavior: "smooth" });
|
|
1746
|
+
};
|
|
1747
|
+
const arrowBtn = "absolute top-1/2 -translate-y-1/2 z-10 flex h-9 w-9 items-center justify-center rounded-full border border-border bg-surface text-foreground-secondary shadow-md transition hover:text-foreground hover:bg-surface-raised disabled:opacity-0 disabled:pointer-events-none focus:outline-none focus-visible:ring-2 focus-visible:ring-accent";
|
|
1748
|
+
return /* @__PURE__ */ jsxs("section", { "aria-label": ariaLabel, className: ["relative", className].filter(Boolean).join(" "), style, children: [
|
|
1749
|
+
showArrows && /* @__PURE__ */ jsx("button", { type: "button", "aria-label": "Previous", onClick: () => scrollByDir(-1), disabled: atStart, className: `${arrowBtn} left-1`, children: /* @__PURE__ */ jsx(Arrow2, { dir: "left" }) }),
|
|
1750
|
+
/* @__PURE__ */ jsx(
|
|
1751
|
+
"div",
|
|
1752
|
+
{
|
|
1753
|
+
ref: scrollerRef,
|
|
1754
|
+
className: "flex overflow-x-auto snap-x snap-mandatory hidden-scrollbar scroll-smooth",
|
|
1755
|
+
style: { gap },
|
|
1756
|
+
children: slides.map((slide, i) => /* @__PURE__ */ jsx("div", { className: "snap-start flex-shrink-0", style: { width }, children: slide }, i))
|
|
1757
|
+
}
|
|
1758
|
+
),
|
|
1759
|
+
showArrows && /* @__PURE__ */ jsx("button", { type: "button", "aria-label": "Next", onClick: () => scrollByDir(1), disabled: atEnd, className: `${arrowBtn} right-1`, children: /* @__PURE__ */ jsx(Arrow2, { dir: "right" }) }),
|
|
1760
|
+
showDots && slides.length > 1 && /* @__PURE__ */ jsx("div", { className: "mt-3 flex items-center justify-center gap-1.5", children: slides.map((_, i) => /* @__PURE__ */ jsx(
|
|
1761
|
+
"button",
|
|
1762
|
+
{
|
|
1763
|
+
type: "button",
|
|
1764
|
+
"aria-label": `Go to slide ${i + 1}`,
|
|
1765
|
+
"aria-current": i === active,
|
|
1766
|
+
onClick: () => scrollTo(i),
|
|
1767
|
+
className: [
|
|
1768
|
+
"h-1.5 rounded-full transition-all duration-200 focus:outline-none focus-visible:ring-2 focus-visible:ring-accent",
|
|
1769
|
+
i === active ? "w-5 bg-accent" : "w-1.5 bg-border hover:bg-foreground-muted"
|
|
1770
|
+
].join(" ")
|
|
1771
|
+
},
|
|
1772
|
+
i
|
|
1773
|
+
)) })
|
|
1774
|
+
] });
|
|
1775
|
+
}
|
|
1619
1776
|
var NotificationContext = createContext({
|
|
1620
1777
|
open: () => void 0,
|
|
1621
1778
|
close: () => void 0
|
|
@@ -2719,7 +2876,7 @@ function Field({
|
|
|
2719
2876
|
);
|
|
2720
2877
|
}
|
|
2721
2878
|
var SearchIcon = /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", className: "w-4 h-4", "aria-hidden": "true", children: /* @__PURE__ */ jsx("path", { fillRule: "evenodd", d: "M10.5 3.75a6.75 6.75 0 100 13.5 6.75 6.75 0 000-13.5zM2.25 10.5a8.25 8.25 0 1114.59 5.28l4.69 4.69a.75.75 0 11-1.06 1.06l-4.69-4.69A8.25 8.25 0 012.25 10.5z", clipRule: "evenodd" }) });
|
|
2722
|
-
var SearchInput =
|
|
2879
|
+
var SearchInput = React16.forwardRef(function SearchInput2({ value, onChange, disabled, label, htmlFor, placeholder, name, inputStyle, style, layout = "vertical", size = "md", icon, helperText, className }, ref) {
|
|
2723
2880
|
return /* @__PURE__ */ jsx(Field, { className, label, htmlFor, layout, helperText, children: /* @__PURE__ */ jsxs(
|
|
2724
2881
|
"div",
|
|
2725
2882
|
{
|
|
@@ -3220,7 +3377,7 @@ function TableBody({
|
|
|
3220
3377
|
return /* @__PURE__ */ jsx("tbody", { children: rows.map((row, i) => {
|
|
3221
3378
|
const rowKey = getRowKey(row, i);
|
|
3222
3379
|
const isExpanded = expanded.has(rowKey);
|
|
3223
|
-
return /* @__PURE__ */ jsxs(
|
|
3380
|
+
return /* @__PURE__ */ jsxs(React16.Fragment, { children: [
|
|
3224
3381
|
/* @__PURE__ */ jsxs(
|
|
3225
3382
|
"tr",
|
|
3226
3383
|
{
|
|
@@ -3764,8 +3921,8 @@ function MegaMenuLink({ href, icon, description, active, onClick, children, clas
|
|
|
3764
3921
|
function MegaMenuFeatured({ children, className = "" }) {
|
|
3765
3922
|
return /* @__PURE__ */ jsx("div", { className: ["min-w-0 rounded-lg bg-surface-raised border border-border p-4 flex flex-col", className].filter(Boolean).join(" "), children });
|
|
3766
3923
|
}
|
|
3767
|
-
var elementsOfType = (children, type) =>
|
|
3768
|
-
(c) =>
|
|
3924
|
+
var elementsOfType = (children, type) => React16.Children.toArray(children).filter(
|
|
3925
|
+
(c) => React16.isValidElement(c) && c.type === type
|
|
3769
3926
|
);
|
|
3770
3927
|
var MOBILE_CHEVRON = /* @__PURE__ */ jsx(
|
|
3771
3928
|
"svg",
|
|
@@ -3802,9 +3959,9 @@ function MobileLinkRow({ link, onNavigate }) {
|
|
|
3802
3959
|
);
|
|
3803
3960
|
}
|
|
3804
3961
|
function MobilePanel({ panel, onNavigate }) {
|
|
3805
|
-
const nodes =
|
|
3962
|
+
const nodes = React16.Children.toArray(panel.props.children);
|
|
3806
3963
|
return /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-4 px-2 pb-3 pt-1", children: nodes.map((node, i) => {
|
|
3807
|
-
if (!
|
|
3964
|
+
if (!React16.isValidElement(node)) return null;
|
|
3808
3965
|
const el = node;
|
|
3809
3966
|
if (el.type === MegaMenuSection) {
|
|
3810
3967
|
const { title, children } = el.props;
|
|
@@ -4097,7 +4254,7 @@ function ThemeProvider({
|
|
|
4097
4254
|
className = "",
|
|
4098
4255
|
style
|
|
4099
4256
|
}) {
|
|
4100
|
-
const id =
|
|
4257
|
+
const id = React16.useId().replace(/:/g, "");
|
|
4101
4258
|
const scopeClass = `geo-th-${id}`;
|
|
4102
4259
|
const divRef = useRef(null);
|
|
4103
4260
|
useEffect(() => {
|
|
@@ -5692,7 +5849,7 @@ function TextArea({
|
|
|
5692
5849
|
}
|
|
5693
5850
|
);
|
|
5694
5851
|
}
|
|
5695
|
-
var
|
|
5852
|
+
var SIZE4 = {
|
|
5696
5853
|
sm: { h: "h-control-sm", text: "text-xs", pad: "px-2.5" },
|
|
5697
5854
|
md: { h: "h-control-md", text: "text-sm", pad: "px-3.5" },
|
|
5698
5855
|
lg: { h: "h-control-lg", text: "text-sm", pad: "px-4" }
|
|
@@ -5714,7 +5871,7 @@ function SegmentedControl({
|
|
|
5714
5871
|
errorMessage,
|
|
5715
5872
|
"aria-label": ariaLabel
|
|
5716
5873
|
}) {
|
|
5717
|
-
const sz =
|
|
5874
|
+
const sz = SIZE4[size];
|
|
5718
5875
|
const groupId = useId();
|
|
5719
5876
|
const errorId = useId();
|
|
5720
5877
|
const hasError = errorMessage != null;
|
|
@@ -6101,7 +6258,7 @@ function OtpInput({
|
|
|
6101
6258
|
emit(valid.join(""));
|
|
6102
6259
|
focusBox(valid.length);
|
|
6103
6260
|
};
|
|
6104
|
-
return /* @__PURE__ */ jsx(Field, { className, label, htmlFor, errorId, errorMessage, required, layout, helperText, children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2", role: "group", "aria-label": typeof label === "string" ? label : "One-time code", children: chars.map((char, idx) => /* @__PURE__ */ jsxs(
|
|
6261
|
+
return /* @__PURE__ */ jsx(Field, { className, label, htmlFor, errorId, errorMessage, required, layout, helperText, children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2", role: "group", "aria-label": typeof label === "string" ? label : "One-time code", children: chars.map((char, idx) => /* @__PURE__ */ jsxs(React16.Fragment, { children: [
|
|
6105
6262
|
/* @__PURE__ */ jsx(
|
|
6106
6263
|
"input",
|
|
6107
6264
|
{
|
|
@@ -7315,6 +7472,6 @@ function CreditCardForm({
|
|
|
7315
7472
|
);
|
|
7316
7473
|
}
|
|
7317
7474
|
|
|
7318
|
-
export { Accordion_default as Accordion, AppShell, AutoComplete, Avatar, Badge, Box, Breadcrumbs, Button, CARD_BRANDS, Catalog, CatalogCarousel, CatalogGrid, Checkbox, ColorPicker, ContextMenu, CreditCardForm, DateRangePicker, Drawer, Dropdown, FadingBase, Field, FieldHelpIcon, FieldLabel, FileInput, Flex, Form, FormContext, FormField, FormStore, Grid2 as Grid, GridCard, icons_default as Icon, IconButton, List2 as List, LoadingSpinner, MegaMenu_default as MegaMenu, Modal, NotificationProvider, NumberInput, OpaqueGridCard, OtpInput, Password, Portal, RadioGroup, Rating, ScalableContainer, SearchInput_default as SearchInput, SegmentedControl, Sidebar, SkeletonBox, SkeletonCard, SkeletonCircle, SkeletonText, Slider, Switch, Table, Tabs_default as Tabs, TagsInput, DatePicker as Temporal, TextArea, TextInput, ThemeProvider, ThemeSwitch, TimePicker, Tooltip, TooltipProvider, TopBar, Tree, TreeSelect, Typography, Wizard, cardNumberError, cvvError, detectBrand, expiryError, fieldShell, formatCardNumber, formatExpiry, isRequired, luhnValid, onlyDigits, patterns, runFieldRules, useFieldArray, useForm, useFormField, useFormStore, useNotification };
|
|
7475
|
+
export { Accordion_default as Accordion, AppShell, AutoComplete, Avatar, Badge, Box, Breadcrumbs, Button, CARD_BRANDS, Card_default as Card, CardCarousel, Catalog, CatalogCarousel, CatalogGrid, Checkbox, ColorPicker, ContextMenu, CreditCardForm, DateRangePicker, Drawer, Dropdown, FadingBase, Field, FieldHelpIcon, FieldLabel, FileInput, Flex, Form, FormContext, FormField, FormStore, Grid2 as Grid, GridCard, icons_default as Icon, IconButton, Kbd, List2 as List, LoadingSpinner, MegaMenu_default as MegaMenu, Modal, NotificationProvider, NumberInput, OpaqueGridCard, OtpInput, Password, Portal, RadioGroup, Rating, ScalableContainer, SearchInput_default as SearchInput, SegmentedControl, Sidebar, SkeletonBox, SkeletonCard, SkeletonCircle, SkeletonText, Slider, Switch, Table, Tabs_default as Tabs, TagsInput, DatePicker as Temporal, TextArea, TextInput, ThemeProvider, ThemeSwitch, TimePicker, Tooltip, TooltipProvider, TopBar, Tree, TreeSelect, Typography, Wizard, cardNumberError, cvvError, detectBrand, expiryError, fieldShell, formatCardNumber, formatExpiry, isRequired, luhnValid, onlyDigits, patterns, runFieldRules, useFieldArray, useForm, useFormField, useFormStore, useNotification };
|
|
7319
7476
|
//# sourceMappingURL=index.js.map
|
|
7320
7477
|
//# sourceMappingURL=index.js.map
|