@geomak/ui 6.8.0 → 6.10.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 +381 -206
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +92 -1
- package/dist/index.d.ts +92 -1
- package/dist/index.js +188 -15
- package/dist/index.js.map +1 -1
- package/dist/styles.css +40 -0
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1198,6 +1198,97 @@ interface StatisticProps {
|
|
|
1198
1198
|
*/
|
|
1199
1199
|
declare function Statistic({ label, value, prefix, suffix, icon, delta, helpText, size, align, className, style, }: StatisticProps): react_jsx_runtime.JSX.Element;
|
|
1200
1200
|
|
|
1201
|
+
type FABPosition = 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
|
|
1202
|
+
type FABSize = 'md' | 'lg';
|
|
1203
|
+
type FABTone = 'accent' | 'neutral';
|
|
1204
|
+
interface FABAction {
|
|
1205
|
+
icon: React__default.ReactNode;
|
|
1206
|
+
/** Accessible label + the text shown on the action's pill. */
|
|
1207
|
+
label: string;
|
|
1208
|
+
onClick?: React__default.MouseEventHandler;
|
|
1209
|
+
}
|
|
1210
|
+
interface FABProps {
|
|
1211
|
+
/** Main button icon. */
|
|
1212
|
+
icon: React__default.ReactNode;
|
|
1213
|
+
/** Accessible label for the main button (required — it's icon-only). */
|
|
1214
|
+
label: string;
|
|
1215
|
+
/** Click handler. Ignored when `actions` is provided (the button toggles the dial). */
|
|
1216
|
+
onClick?: React__default.MouseEventHandler;
|
|
1217
|
+
/** Speed-dial sub-actions. When set, the main button opens/closes the dial. */
|
|
1218
|
+
actions?: FABAction[];
|
|
1219
|
+
/** Corner placement. Default `'bottom-right'`. */
|
|
1220
|
+
position?: FABPosition;
|
|
1221
|
+
/** Size preset. Default `'lg'`. */
|
|
1222
|
+
size?: FABSize;
|
|
1223
|
+
/** Colour. Default `'accent'`. */
|
|
1224
|
+
tone?: FABTone;
|
|
1225
|
+
/**
|
|
1226
|
+
* `position: fixed` to the viewport (default) or `absolute` to the nearest
|
|
1227
|
+
* positioned ancestor — set `false` to anchor inside a `relative` container.
|
|
1228
|
+
*/
|
|
1229
|
+
fixed?: boolean;
|
|
1230
|
+
className?: string;
|
|
1231
|
+
style?: React__default.CSSProperties;
|
|
1232
|
+
}
|
|
1233
|
+
/**
|
|
1234
|
+
* A floating action button. On its own it's a single round action; given
|
|
1235
|
+
* `actions`, it becomes a speed dial that expands a labelled stack on click.
|
|
1236
|
+
* Positions to a viewport corner by default (or a relative container with
|
|
1237
|
+
* `fixed={false}`).
|
|
1238
|
+
*
|
|
1239
|
+
* @example Single
|
|
1240
|
+
* <FAB icon={<PlusIcon />} label="New record" onClick={create} />
|
|
1241
|
+
*
|
|
1242
|
+
* @example Speed dial
|
|
1243
|
+
* <FAB icon={<PlusIcon />} label="Create" actions={[
|
|
1244
|
+
* { icon: <FileIcon />, label: 'Document', onClick: newDoc },
|
|
1245
|
+
* { icon: <FolderIcon />, label: 'Folder', onClick: newFolder },
|
|
1246
|
+
* ]} />
|
|
1247
|
+
*/
|
|
1248
|
+
declare function FAB({ icon, label, onClick, actions, position, size, tone, fixed, className, style, }: FABProps): react_jsx_runtime.JSX.Element;
|
|
1249
|
+
|
|
1250
|
+
type PopConfirmTone = 'default' | 'danger';
|
|
1251
|
+
interface PopConfirmProps {
|
|
1252
|
+
/** The trigger element. Cloned as the popover anchor (rendered `asChild`). */
|
|
1253
|
+
children: React__default.ReactElement;
|
|
1254
|
+
/** The confirmation question / heading. */
|
|
1255
|
+
title: React__default.ReactNode;
|
|
1256
|
+
/** Optional secondary line under the title. */
|
|
1257
|
+
description?: React__default.ReactNode;
|
|
1258
|
+
/** Runs on confirm. If it returns a promise, the confirm button shows a loading state until it settles. */
|
|
1259
|
+
onConfirm?: () => void | Promise<void>;
|
|
1260
|
+
/** Runs on cancel / dismiss. */
|
|
1261
|
+
onCancel?: () => void;
|
|
1262
|
+
/** Confirm button label. Default `'Confirm'`. */
|
|
1263
|
+
confirmText?: React__default.ReactNode;
|
|
1264
|
+
/** Cancel button label. Default `'Cancel'`. */
|
|
1265
|
+
cancelText?: React__default.ReactNode;
|
|
1266
|
+
/** `'danger'` colours the confirm button red. Default `'default'`. */
|
|
1267
|
+
tone?: PopConfirmTone;
|
|
1268
|
+
/** Leading icon shown beside the title. */
|
|
1269
|
+
icon?: React__default.ReactNode;
|
|
1270
|
+
/** Side of the trigger to open on. Default `'top'`. */
|
|
1271
|
+
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
1272
|
+
/** Controlled open state (optional). */
|
|
1273
|
+
open?: boolean;
|
|
1274
|
+
onOpenChange?: (open: boolean) => void;
|
|
1275
|
+
className?: string;
|
|
1276
|
+
}
|
|
1277
|
+
/**
|
|
1278
|
+
* A lightweight confirm prompt anchored to its trigger, on Radix Popover. Use it
|
|
1279
|
+
* for in-place "are you sure?" gates (delete, archive) instead of a full Modal.
|
|
1280
|
+
* An async `onConfirm` keeps the confirm button in a loading state until it
|
|
1281
|
+
* resolves, then closes.
|
|
1282
|
+
*
|
|
1283
|
+
* @example
|
|
1284
|
+
* ```tsx
|
|
1285
|
+
* <PopConfirm title="Delete this vessel?" tone="danger" confirmText="Delete" onConfirm={remove}>
|
|
1286
|
+
* <Button content="Delete" variant="danger" />
|
|
1287
|
+
* </PopConfirm>
|
|
1288
|
+
* ```
|
|
1289
|
+
*/
|
|
1290
|
+
declare function PopConfirm({ children, title, description, onConfirm, onCancel, confirmText, cancelText, tone, icon, side, open, onOpenChange, className, }: PopConfirmProps): react_jsx_runtime.JSX.Element;
|
|
1291
|
+
|
|
1201
1292
|
/** ─────────────────── types ─────────────────── */
|
|
1202
1293
|
type NotificationType = 'info' | 'success' | 'warning' | 'danger';
|
|
1203
1294
|
type NotificationPosition = 'top-right' | 'top-left' | 'top-center' | 'bottom-right' | 'bottom-left' | 'bottom-center';
|
|
@@ -4266,4 +4357,4 @@ declare function expiryError(value: string, now?: Date): string | undefined;
|
|
|
4266
4357
|
/** Validate the CVV against the detected brand's expected length. */
|
|
4267
4358
|
declare function cvvError(value: string, cardNumber: string): string | undefined;
|
|
4268
4359
|
|
|
4269
|
-
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, type DeltaDirection, 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, Statistic, type StatisticDelta, type StatisticProps, type StatisticSize, 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 };
|
|
4360
|
+
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, type DeltaDirection, Drawer, type DrawerProps, Dropdown, type DropdownItem, type DropdownProps, type ErrorMap, type ExpandRowOptions, FAB, type FABAction, type FABPosition, type FABProps, type FABSize, type FABTone, 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, PopConfirm, type PopConfirmProps, type PopConfirmTone, 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, Statistic, type StatisticDelta, type StatisticProps, type StatisticSize, 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
|
@@ -1198,6 +1198,97 @@ interface StatisticProps {
|
|
|
1198
1198
|
*/
|
|
1199
1199
|
declare function Statistic({ label, value, prefix, suffix, icon, delta, helpText, size, align, className, style, }: StatisticProps): react_jsx_runtime.JSX.Element;
|
|
1200
1200
|
|
|
1201
|
+
type FABPosition = 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
|
|
1202
|
+
type FABSize = 'md' | 'lg';
|
|
1203
|
+
type FABTone = 'accent' | 'neutral';
|
|
1204
|
+
interface FABAction {
|
|
1205
|
+
icon: React__default.ReactNode;
|
|
1206
|
+
/** Accessible label + the text shown on the action's pill. */
|
|
1207
|
+
label: string;
|
|
1208
|
+
onClick?: React__default.MouseEventHandler;
|
|
1209
|
+
}
|
|
1210
|
+
interface FABProps {
|
|
1211
|
+
/** Main button icon. */
|
|
1212
|
+
icon: React__default.ReactNode;
|
|
1213
|
+
/** Accessible label for the main button (required — it's icon-only). */
|
|
1214
|
+
label: string;
|
|
1215
|
+
/** Click handler. Ignored when `actions` is provided (the button toggles the dial). */
|
|
1216
|
+
onClick?: React__default.MouseEventHandler;
|
|
1217
|
+
/** Speed-dial sub-actions. When set, the main button opens/closes the dial. */
|
|
1218
|
+
actions?: FABAction[];
|
|
1219
|
+
/** Corner placement. Default `'bottom-right'`. */
|
|
1220
|
+
position?: FABPosition;
|
|
1221
|
+
/** Size preset. Default `'lg'`. */
|
|
1222
|
+
size?: FABSize;
|
|
1223
|
+
/** Colour. Default `'accent'`. */
|
|
1224
|
+
tone?: FABTone;
|
|
1225
|
+
/**
|
|
1226
|
+
* `position: fixed` to the viewport (default) or `absolute` to the nearest
|
|
1227
|
+
* positioned ancestor — set `false` to anchor inside a `relative` container.
|
|
1228
|
+
*/
|
|
1229
|
+
fixed?: boolean;
|
|
1230
|
+
className?: string;
|
|
1231
|
+
style?: React__default.CSSProperties;
|
|
1232
|
+
}
|
|
1233
|
+
/**
|
|
1234
|
+
* A floating action button. On its own it's a single round action; given
|
|
1235
|
+
* `actions`, it becomes a speed dial that expands a labelled stack on click.
|
|
1236
|
+
* Positions to a viewport corner by default (or a relative container with
|
|
1237
|
+
* `fixed={false}`).
|
|
1238
|
+
*
|
|
1239
|
+
* @example Single
|
|
1240
|
+
* <FAB icon={<PlusIcon />} label="New record" onClick={create} />
|
|
1241
|
+
*
|
|
1242
|
+
* @example Speed dial
|
|
1243
|
+
* <FAB icon={<PlusIcon />} label="Create" actions={[
|
|
1244
|
+
* { icon: <FileIcon />, label: 'Document', onClick: newDoc },
|
|
1245
|
+
* { icon: <FolderIcon />, label: 'Folder', onClick: newFolder },
|
|
1246
|
+
* ]} />
|
|
1247
|
+
*/
|
|
1248
|
+
declare function FAB({ icon, label, onClick, actions, position, size, tone, fixed, className, style, }: FABProps): react_jsx_runtime.JSX.Element;
|
|
1249
|
+
|
|
1250
|
+
type PopConfirmTone = 'default' | 'danger';
|
|
1251
|
+
interface PopConfirmProps {
|
|
1252
|
+
/** The trigger element. Cloned as the popover anchor (rendered `asChild`). */
|
|
1253
|
+
children: React__default.ReactElement;
|
|
1254
|
+
/** The confirmation question / heading. */
|
|
1255
|
+
title: React__default.ReactNode;
|
|
1256
|
+
/** Optional secondary line under the title. */
|
|
1257
|
+
description?: React__default.ReactNode;
|
|
1258
|
+
/** Runs on confirm. If it returns a promise, the confirm button shows a loading state until it settles. */
|
|
1259
|
+
onConfirm?: () => void | Promise<void>;
|
|
1260
|
+
/** Runs on cancel / dismiss. */
|
|
1261
|
+
onCancel?: () => void;
|
|
1262
|
+
/** Confirm button label. Default `'Confirm'`. */
|
|
1263
|
+
confirmText?: React__default.ReactNode;
|
|
1264
|
+
/** Cancel button label. Default `'Cancel'`. */
|
|
1265
|
+
cancelText?: React__default.ReactNode;
|
|
1266
|
+
/** `'danger'` colours the confirm button red. Default `'default'`. */
|
|
1267
|
+
tone?: PopConfirmTone;
|
|
1268
|
+
/** Leading icon shown beside the title. */
|
|
1269
|
+
icon?: React__default.ReactNode;
|
|
1270
|
+
/** Side of the trigger to open on. Default `'top'`. */
|
|
1271
|
+
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
1272
|
+
/** Controlled open state (optional). */
|
|
1273
|
+
open?: boolean;
|
|
1274
|
+
onOpenChange?: (open: boolean) => void;
|
|
1275
|
+
className?: string;
|
|
1276
|
+
}
|
|
1277
|
+
/**
|
|
1278
|
+
* A lightweight confirm prompt anchored to its trigger, on Radix Popover. Use it
|
|
1279
|
+
* for in-place "are you sure?" gates (delete, archive) instead of a full Modal.
|
|
1280
|
+
* An async `onConfirm` keeps the confirm button in a loading state until it
|
|
1281
|
+
* resolves, then closes.
|
|
1282
|
+
*
|
|
1283
|
+
* @example
|
|
1284
|
+
* ```tsx
|
|
1285
|
+
* <PopConfirm title="Delete this vessel?" tone="danger" confirmText="Delete" onConfirm={remove}>
|
|
1286
|
+
* <Button content="Delete" variant="danger" />
|
|
1287
|
+
* </PopConfirm>
|
|
1288
|
+
* ```
|
|
1289
|
+
*/
|
|
1290
|
+
declare function PopConfirm({ children, title, description, onConfirm, onCancel, confirmText, cancelText, tone, icon, side, open, onOpenChange, className, }: PopConfirmProps): react_jsx_runtime.JSX.Element;
|
|
1291
|
+
|
|
1201
1292
|
/** ─────────────────── types ─────────────────── */
|
|
1202
1293
|
type NotificationType = 'info' | 'success' | 'warning' | 'danger';
|
|
1203
1294
|
type NotificationPosition = 'top-right' | 'top-left' | 'top-center' | 'bottom-right' | 'bottom-left' | 'bottom-center';
|
|
@@ -4266,4 +4357,4 @@ declare function expiryError(value: string, now?: Date): string | undefined;
|
|
|
4266
4357
|
/** Validate the CVV against the detected brand's expected length. */
|
|
4267
4358
|
declare function cvvError(value: string, cardNumber: string): string | undefined;
|
|
4268
4359
|
|
|
4269
|
-
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, type DeltaDirection, 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, Statistic, type StatisticDelta, type StatisticProps, type StatisticSize, 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 };
|
|
4360
|
+
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, type DeltaDirection, Drawer, type DrawerProps, Dropdown, type DropdownItem, type DropdownProps, type ErrorMap, type ExpandRowOptions, FAB, type FABAction, type FABPosition, type FABProps, type FABSize, type FABTone, 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, PopConfirm, type PopConfirmProps, type PopConfirmTone, 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, Statistic, type StatisticDelta, type StatisticProps, type StatisticSize, 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 React18, { 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';
|
|
@@ -9,8 +9,8 @@ import { useReducedMotion, AnimatePresence, motion } from 'framer-motion';
|
|
|
9
9
|
import * as TooltipPrimitive from '@radix-ui/react-tooltip';
|
|
10
10
|
import * as TabsPrimitive from '@radix-ui/react-tabs';
|
|
11
11
|
import * as AccordionPrimitive from '@radix-ui/react-accordion';
|
|
12
|
-
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
|
13
12
|
import * as Popover from '@radix-ui/react-popover';
|
|
13
|
+
import * as ContextMenuPrimitive from '@radix-ui/react-context-menu';
|
|
14
14
|
import * as SwitchPrimitive from '@radix-ui/react-switch';
|
|
15
15
|
import * as NavigationMenu from '@radix-ui/react-navigation-menu';
|
|
16
16
|
import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
|
|
@@ -1630,7 +1630,7 @@ function Kbd({
|
|
|
1630
1630
|
style
|
|
1631
1631
|
}) {
|
|
1632
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(
|
|
1633
|
+
return /* @__PURE__ */ jsx("span", { className: ["inline-flex items-center gap-1", className].filter(Boolean).join(" "), style, children: keys.map((k, i) => /* @__PURE__ */ jsxs(React18.Fragment, { children: [
|
|
1634
1634
|
i > 0 && /* @__PURE__ */ jsx("span", { className: "text-foreground-muted text-xs select-none", children: separator }),
|
|
1635
1635
|
/* @__PURE__ */ jsx("kbd", { className: [cap, SIZE3[size]].join(" "), children: k })
|
|
1636
1636
|
] }, `${k}-${i}`)) });
|
|
@@ -1704,7 +1704,7 @@ function CardCarousel({
|
|
|
1704
1704
|
style
|
|
1705
1705
|
}) {
|
|
1706
1706
|
const scrollerRef = useRef(null);
|
|
1707
|
-
const slides =
|
|
1707
|
+
const slides = React18.Children.toArray(children);
|
|
1708
1708
|
const [active, setActive] = useState(0);
|
|
1709
1709
|
const [atStart, setAtStart] = useState(true);
|
|
1710
1710
|
const [atEnd, setAtEnd] = useState(false);
|
|
@@ -1826,6 +1826,179 @@ function Statistic({
|
|
|
1826
1826
|
}
|
|
1827
1827
|
);
|
|
1828
1828
|
}
|
|
1829
|
+
var POS = {
|
|
1830
|
+
"bottom-right": "bottom-6 right-6 items-end",
|
|
1831
|
+
"bottom-left": "bottom-6 left-6 items-start",
|
|
1832
|
+
"top-right": "top-6 right-6 items-end",
|
|
1833
|
+
"top-left": "top-6 left-6 items-start"
|
|
1834
|
+
};
|
|
1835
|
+
var SIZE4 = {
|
|
1836
|
+
md: "h-12 w-12",
|
|
1837
|
+
lg: "h-14 w-14"
|
|
1838
|
+
};
|
|
1839
|
+
var TONE3 = {
|
|
1840
|
+
accent: "bg-accent text-accent-fg hover:bg-accent-hover",
|
|
1841
|
+
neutral: "bg-foreground-secondary text-background hover:opacity-90"
|
|
1842
|
+
};
|
|
1843
|
+
function FAB({
|
|
1844
|
+
icon,
|
|
1845
|
+
label,
|
|
1846
|
+
onClick,
|
|
1847
|
+
actions,
|
|
1848
|
+
position = "bottom-right",
|
|
1849
|
+
size = "lg",
|
|
1850
|
+
tone = "accent",
|
|
1851
|
+
fixed = true,
|
|
1852
|
+
className = "",
|
|
1853
|
+
style
|
|
1854
|
+
}) {
|
|
1855
|
+
const [open, setOpen] = useState(false);
|
|
1856
|
+
const reduced = useReducedMotion();
|
|
1857
|
+
const hasDial = !!actions && actions.length > 0;
|
|
1858
|
+
const bottom = position.startsWith("bottom");
|
|
1859
|
+
const alignRight = position.endsWith("right");
|
|
1860
|
+
const dial = hasDial && /* @__PURE__ */ jsx(AnimatePresence, { children: open && /* @__PURE__ */ jsx(
|
|
1861
|
+
motion.ul,
|
|
1862
|
+
{
|
|
1863
|
+
className: `flex flex-col gap-3 ${bottom ? "mb-3" : "mt-3 order-last"} ${alignRight ? "items-end" : "items-start"}`,
|
|
1864
|
+
initial: "hidden",
|
|
1865
|
+
animate: "show",
|
|
1866
|
+
exit: "hidden",
|
|
1867
|
+
variants: { show: { transition: { staggerChildren: reduced ? 0 : 0.04, staggerDirection: bottom ? -1 : 1 } } },
|
|
1868
|
+
children: actions.map((a, i) => /* @__PURE__ */ jsxs(
|
|
1869
|
+
motion.li,
|
|
1870
|
+
{
|
|
1871
|
+
className: `flex items-center gap-2 ${alignRight ? "flex-row" : "flex-row-reverse"}`,
|
|
1872
|
+
variants: {
|
|
1873
|
+
hidden: { opacity: 0, y: reduced ? 0 : bottom ? 8 : -8, scale: reduced ? 1 : 0.9 },
|
|
1874
|
+
show: { opacity: 1, y: 0, scale: 1 }
|
|
1875
|
+
},
|
|
1876
|
+
children: [
|
|
1877
|
+
/* @__PURE__ */ jsx("span", { className: "rounded-md bg-surface px-2 py-1 text-xs font-medium text-foreground shadow-md border border-border whitespace-nowrap", children: a.label }),
|
|
1878
|
+
/* @__PURE__ */ jsx(
|
|
1879
|
+
"button",
|
|
1880
|
+
{
|
|
1881
|
+
type: "button",
|
|
1882
|
+
"aria-label": a.label,
|
|
1883
|
+
onClick: (e) => {
|
|
1884
|
+
a.onClick?.(e);
|
|
1885
|
+
setOpen(false);
|
|
1886
|
+
},
|
|
1887
|
+
className: "flex h-11 w-11 items-center justify-center rounded-full bg-surface text-foreground-secondary shadow-lg border border-border transition hover:text-foreground hover:bg-surface-raised focus:outline-none focus-visible:ring-2 focus-visible:ring-accent",
|
|
1888
|
+
children: /* @__PURE__ */ jsx("span", { className: "h-5 w-5 inline-flex items-center justify-center", children: a.icon })
|
|
1889
|
+
}
|
|
1890
|
+
)
|
|
1891
|
+
]
|
|
1892
|
+
},
|
|
1893
|
+
i
|
|
1894
|
+
))
|
|
1895
|
+
}
|
|
1896
|
+
) });
|
|
1897
|
+
return /* @__PURE__ */ jsxs(
|
|
1898
|
+
"div",
|
|
1899
|
+
{
|
|
1900
|
+
className: [fixed ? "fixed" : "absolute", "z-40 flex flex-col", POS[position], className].filter(Boolean).join(" "),
|
|
1901
|
+
style,
|
|
1902
|
+
children: [
|
|
1903
|
+
bottom && dial,
|
|
1904
|
+
/* @__PURE__ */ jsx(
|
|
1905
|
+
"button",
|
|
1906
|
+
{
|
|
1907
|
+
type: "button",
|
|
1908
|
+
"aria-label": label,
|
|
1909
|
+
"aria-expanded": hasDial ? open : void 0,
|
|
1910
|
+
onClick: (e) => hasDial ? setOpen((o) => !o) : onClick?.(e),
|
|
1911
|
+
className: [
|
|
1912
|
+
"flex items-center justify-center rounded-full shadow-lg transition-[background-color,transform] duration-200",
|
|
1913
|
+
"focus:outline-none focus-visible:ring-2 focus-visible:ring-accent focus-visible:ring-offset-2",
|
|
1914
|
+
SIZE4[size],
|
|
1915
|
+
TONE3[tone],
|
|
1916
|
+
hasDial && open ? "rotate-45" : ""
|
|
1917
|
+
].filter(Boolean).join(" "),
|
|
1918
|
+
children: /* @__PURE__ */ jsx("span", { className: "h-6 w-6 inline-flex items-center justify-center", children: icon })
|
|
1919
|
+
}
|
|
1920
|
+
),
|
|
1921
|
+
!bottom && dial
|
|
1922
|
+
]
|
|
1923
|
+
}
|
|
1924
|
+
);
|
|
1925
|
+
}
|
|
1926
|
+
function PopConfirm({
|
|
1927
|
+
children,
|
|
1928
|
+
title,
|
|
1929
|
+
description,
|
|
1930
|
+
onConfirm,
|
|
1931
|
+
onCancel,
|
|
1932
|
+
confirmText = "Confirm",
|
|
1933
|
+
cancelText = "Cancel",
|
|
1934
|
+
tone = "default",
|
|
1935
|
+
icon,
|
|
1936
|
+
side = "top",
|
|
1937
|
+
open,
|
|
1938
|
+
onOpenChange,
|
|
1939
|
+
className = ""
|
|
1940
|
+
}) {
|
|
1941
|
+
const [uncontrolledOpen, setUncontrolledOpen] = useState(false);
|
|
1942
|
+
const [loading, setLoading] = useState(false);
|
|
1943
|
+
const isOpen = open ?? uncontrolledOpen;
|
|
1944
|
+
const setOpen = (next) => {
|
|
1945
|
+
onOpenChange?.(next);
|
|
1946
|
+
if (open === void 0) setUncontrolledOpen(next);
|
|
1947
|
+
};
|
|
1948
|
+
const handleConfirm = async () => {
|
|
1949
|
+
try {
|
|
1950
|
+
setLoading(true);
|
|
1951
|
+
await onConfirm?.();
|
|
1952
|
+
setOpen(false);
|
|
1953
|
+
} finally {
|
|
1954
|
+
setLoading(false);
|
|
1955
|
+
}
|
|
1956
|
+
};
|
|
1957
|
+
const handleCancel = () => {
|
|
1958
|
+
onCancel?.();
|
|
1959
|
+
setOpen(false);
|
|
1960
|
+
};
|
|
1961
|
+
return /* @__PURE__ */ jsxs(Popover.Root, { open: isOpen, onOpenChange: (o) => o ? setOpen(true) : handleCancel(), children: [
|
|
1962
|
+
/* @__PURE__ */ jsx(Popover.Trigger, { asChild: true, children }),
|
|
1963
|
+
/* @__PURE__ */ jsx(Popover.Portal, { children: /* @__PURE__ */ jsxs(
|
|
1964
|
+
Popover.Content,
|
|
1965
|
+
{
|
|
1966
|
+
side,
|
|
1967
|
+
sideOffset: 8,
|
|
1968
|
+
collisionPadding: 12,
|
|
1969
|
+
className: [
|
|
1970
|
+
"z-[400] w-64 rounded-lg border border-border bg-surface p-3.5 shadow-lg",
|
|
1971
|
+
"data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",
|
|
1972
|
+
"data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
|
|
1973
|
+
className
|
|
1974
|
+
].filter(Boolean).join(" "),
|
|
1975
|
+
children: [
|
|
1976
|
+
/* @__PURE__ */ jsxs("div", { className: "flex gap-2.5", children: [
|
|
1977
|
+
icon && /* @__PURE__ */ jsx("span", { className: `mt-0.5 flex h-5 w-5 flex-shrink-0 items-center justify-center ${tone === "danger" ? "text-status-error" : "text-status-warning"}`, children: icon }),
|
|
1978
|
+
/* @__PURE__ */ jsxs("div", { className: "min-w-0", children: [
|
|
1979
|
+
/* @__PURE__ */ jsx("div", { className: "text-sm font-medium text-foreground", children: title }),
|
|
1980
|
+
description && /* @__PURE__ */ jsx("div", { className: "mt-1 text-xs text-foreground-secondary leading-snug", children: description })
|
|
1981
|
+
] })
|
|
1982
|
+
] }),
|
|
1983
|
+
/* @__PURE__ */ jsxs("div", { className: "mt-3 flex justify-end gap-2", children: [
|
|
1984
|
+
/* @__PURE__ */ jsx(Button, { content: cancelText, size: "sm", variant: "ghost", onClick: handleCancel }),
|
|
1985
|
+
/* @__PURE__ */ jsx(
|
|
1986
|
+
Button,
|
|
1987
|
+
{
|
|
1988
|
+
content: confirmText,
|
|
1989
|
+
size: "sm",
|
|
1990
|
+
variant: tone === "danger" ? "danger" : "primary",
|
|
1991
|
+
loading,
|
|
1992
|
+
onClick: handleConfirm
|
|
1993
|
+
}
|
|
1994
|
+
)
|
|
1995
|
+
] }),
|
|
1996
|
+
/* @__PURE__ */ jsx(Popover.Arrow, { className: "fill-surface" })
|
|
1997
|
+
]
|
|
1998
|
+
}
|
|
1999
|
+
) })
|
|
2000
|
+
] });
|
|
2001
|
+
}
|
|
1829
2002
|
var NotificationContext = createContext({
|
|
1830
2003
|
open: () => void 0,
|
|
1831
2004
|
close: () => void 0
|
|
@@ -2929,7 +3102,7 @@ function Field({
|
|
|
2929
3102
|
);
|
|
2930
3103
|
}
|
|
2931
3104
|
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" }) });
|
|
2932
|
-
var SearchInput =
|
|
3105
|
+
var SearchInput = React18.forwardRef(function SearchInput2({ value, onChange, disabled, label, htmlFor, placeholder, name, inputStyle, style, layout = "vertical", size = "md", icon, helperText, className }, ref) {
|
|
2933
3106
|
return /* @__PURE__ */ jsx(Field, { className, label, htmlFor, layout, helperText, children: /* @__PURE__ */ jsxs(
|
|
2934
3107
|
"div",
|
|
2935
3108
|
{
|
|
@@ -3430,7 +3603,7 @@ function TableBody({
|
|
|
3430
3603
|
return /* @__PURE__ */ jsx("tbody", { children: rows.map((row, i) => {
|
|
3431
3604
|
const rowKey = getRowKey(row, i);
|
|
3432
3605
|
const isExpanded = expanded.has(rowKey);
|
|
3433
|
-
return /* @__PURE__ */ jsxs(
|
|
3606
|
+
return /* @__PURE__ */ jsxs(React18.Fragment, { children: [
|
|
3434
3607
|
/* @__PURE__ */ jsxs(
|
|
3435
3608
|
"tr",
|
|
3436
3609
|
{
|
|
@@ -3974,8 +4147,8 @@ function MegaMenuLink({ href, icon, description, active, onClick, children, clas
|
|
|
3974
4147
|
function MegaMenuFeatured({ children, className = "" }) {
|
|
3975
4148
|
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 });
|
|
3976
4149
|
}
|
|
3977
|
-
var elementsOfType = (children, type) =>
|
|
3978
|
-
(c) =>
|
|
4150
|
+
var elementsOfType = (children, type) => React18.Children.toArray(children).filter(
|
|
4151
|
+
(c) => React18.isValidElement(c) && c.type === type
|
|
3979
4152
|
);
|
|
3980
4153
|
var MOBILE_CHEVRON = /* @__PURE__ */ jsx(
|
|
3981
4154
|
"svg",
|
|
@@ -4012,9 +4185,9 @@ function MobileLinkRow({ link, onNavigate }) {
|
|
|
4012
4185
|
);
|
|
4013
4186
|
}
|
|
4014
4187
|
function MobilePanel({ panel, onNavigate }) {
|
|
4015
|
-
const nodes =
|
|
4188
|
+
const nodes = React18.Children.toArray(panel.props.children);
|
|
4016
4189
|
return /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-4 px-2 pb-3 pt-1", children: nodes.map((node, i) => {
|
|
4017
|
-
if (!
|
|
4190
|
+
if (!React18.isValidElement(node)) return null;
|
|
4018
4191
|
const el = node;
|
|
4019
4192
|
if (el.type === MegaMenuSection) {
|
|
4020
4193
|
const { title, children } = el.props;
|
|
@@ -4307,7 +4480,7 @@ function ThemeProvider({
|
|
|
4307
4480
|
className = "",
|
|
4308
4481
|
style
|
|
4309
4482
|
}) {
|
|
4310
|
-
const id =
|
|
4483
|
+
const id = React18.useId().replace(/:/g, "");
|
|
4311
4484
|
const scopeClass = `geo-th-${id}`;
|
|
4312
4485
|
const divRef = useRef(null);
|
|
4313
4486
|
useEffect(() => {
|
|
@@ -5902,7 +6075,7 @@ function TextArea({
|
|
|
5902
6075
|
}
|
|
5903
6076
|
);
|
|
5904
6077
|
}
|
|
5905
|
-
var
|
|
6078
|
+
var SIZE5 = {
|
|
5906
6079
|
sm: { h: "h-control-sm", text: "text-xs", pad: "px-2.5" },
|
|
5907
6080
|
md: { h: "h-control-md", text: "text-sm", pad: "px-3.5" },
|
|
5908
6081
|
lg: { h: "h-control-lg", text: "text-sm", pad: "px-4" }
|
|
@@ -5924,7 +6097,7 @@ function SegmentedControl({
|
|
|
5924
6097
|
errorMessage,
|
|
5925
6098
|
"aria-label": ariaLabel
|
|
5926
6099
|
}) {
|
|
5927
|
-
const sz =
|
|
6100
|
+
const sz = SIZE5[size];
|
|
5928
6101
|
const groupId = useId();
|
|
5929
6102
|
const errorId = useId();
|
|
5930
6103
|
const hasError = errorMessage != null;
|
|
@@ -6311,7 +6484,7 @@ function OtpInput({
|
|
|
6311
6484
|
emit(valid.join(""));
|
|
6312
6485
|
focusBox(valid.length);
|
|
6313
6486
|
};
|
|
6314
|
-
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(
|
|
6487
|
+
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(React18.Fragment, { children: [
|
|
6315
6488
|
/* @__PURE__ */ jsx(
|
|
6316
6489
|
"input",
|
|
6317
6490
|
{
|
|
@@ -7525,6 +7698,6 @@ function CreditCardForm({
|
|
|
7525
7698
|
);
|
|
7526
7699
|
}
|
|
7527
7700
|
|
|
7528
|
-
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, Statistic, 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 };
|
|
7701
|
+
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, FAB, 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, PopConfirm, Portal, RadioGroup, Rating, ScalableContainer, SearchInput_default as SearchInput, SegmentedControl, Sidebar, SkeletonBox, SkeletonCard, SkeletonCircle, SkeletonText, Slider, Statistic, 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 };
|
|
7529
7702
|
//# sourceMappingURL=index.js.map
|
|
7530
7703
|
//# sourceMappingURL=index.js.map
|