@texturehq/edges 0.0.15 → 0.0.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1,9 +1,63 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { ButtonProps as ButtonProps$1, TextProps, TextFieldProps as TextFieldProps$1, ValidationResult, ListBoxProps as ListBoxProps$1, SelectProps as SelectProps$1, Key, NumberFieldProps as NumberFieldProps$1, TimeFieldProps as TimeFieldProps$1, TimeValue, DateValue, DateFieldProps as DateFieldProps$1, TooltipProps as TooltipProps$1, PopoverProps as PopoverProps$1, SwitchProps as SwitchProps$1, ProgressBarProps as ProgressBarProps$1, RangeCalendarProps as RangeCalendarProps$1, ListBoxItemProps, FormProps, DateRangePickerProps as DateRangePickerProps$1, DialogProps, CalendarProps as CalendarProps$1, CheckboxProps as CheckboxProps$1, CheckboxRenderProps } from 'react-aria-components';
3
2
  import * as React$1 from 'react';
4
- import React__default, { ComponentProps, ReactNode } from 'react';
3
+ import React__default, { ComponentProps, ReactNode, Component, ErrorInfo } from 'react';
4
+ import { Key, ValidationResult, ButtonProps as ButtonProps$1, DateValue, CalendarProps as CalendarProps$1, CheckboxProps as CheckboxProps$1, CheckboxRenderProps, DateFieldProps as DateFieldProps$1, DateRangePickerProps as DateRangePickerProps$1, DialogProps, TextProps, FormProps, ListBoxProps as ListBoxProps$1, ListBoxItemProps, NumberFieldProps as NumberFieldProps$1, PopoverProps as PopoverProps$1, ProgressBarProps as ProgressBarProps$1, RangeCalendarProps as RangeCalendarProps$1, SelectProps as SelectProps$1, SwitchProps as SwitchProps$1, TabProps as TabProps$1, TabListProps, TabPanelProps, TabsProps, TextFieldProps as TextFieldProps$1, TimeFieldProps as TimeFieldProps$1, TimeValue, TooltipProps as TooltipProps$1 } from 'react-aria-components';
5
5
  import * as _phosphor_icons_react from '@phosphor-icons/react';
6
6
 
7
+ interface Item {
8
+ id: string;
9
+ name: string;
10
+ }
11
+ interface Section {
12
+ name: string;
13
+ items: Item[];
14
+ }
15
+ type RequestMethod = "GET" | "POST";
16
+ interface BaseRequestConfig {
17
+ url: string;
18
+ headers?: Record<string, string>;
19
+ transformResponse: (data: unknown) => Item[];
20
+ }
21
+ interface RestRequestConfig extends BaseRequestConfig {
22
+ requestType: "REST";
23
+ method?: RequestMethod;
24
+ queryKey?: string;
25
+ extraParams?: Record<string, string>;
26
+ shouldLoad?: (filterText: string) => boolean;
27
+ }
28
+ interface GraphQLRequestConfig extends BaseRequestConfig {
29
+ requestType: "GraphQL";
30
+ graphqlQuery: string;
31
+ variableKey?: string;
32
+ responsePath?: string;
33
+ shouldLoad?: (filterText: string) => boolean;
34
+ }
35
+ type AutocompleteRequestConfig = RestRequestConfig | GraphQLRequestConfig;
36
+ interface AutocompleteProps {
37
+ label?: string;
38
+ staticItems?: Item[];
39
+ sections?: Section[];
40
+ selectedKey?: Key | null;
41
+ defaultSelectedKey?: Key | null;
42
+ onSelectionChange?: (key: Key | null) => void;
43
+ requestConfig?: AutocompleteRequestConfig;
44
+ defaultFilter?: (textValue: string, inputValue: string) => boolean;
45
+ placeholder?: string;
46
+ renderItem?: (item: Item) => React__default.ReactNode;
47
+ renderLeftIcon?: (isLoading: boolean) => React__default.ReactNode;
48
+ errorMessage?: string | ((validation: ValidationResult) => string);
49
+ description?: string;
50
+ size?: "sm" | "md" | "lg" | "xl";
51
+ tooltip?: string;
52
+ isRequired?: boolean;
53
+ isDisabled?: boolean;
54
+ validationResult?: ValidationResult;
55
+ showErrors?: boolean;
56
+ autoFocus?: boolean;
57
+ onLoadError?: (error: Error) => void;
58
+ }
59
+ declare function Autocomplete({ label, staticItems, sections, selectedKey, defaultSelectedKey, onSelectionChange, requestConfig, defaultFilter, errorMessage, size, tooltip, isRequired, isDisabled, renderLeftIcon, autoFocus, onLoadError, }: AutocompleteProps): react_jsx_runtime.JSX.Element;
60
+
7
61
  declare const iconMapping: {
8
62
  readonly AppWindow: _phosphor_icons_react.Icon;
9
63
  readonly ArrowCircleUp: _phosphor_icons_react.Icon;
@@ -181,6 +235,120 @@ interface ButtonProps extends BaseButtonProps {
181
235
  }
182
236
  declare function Button(props: ButtonProps): react_jsx_runtime.JSX.Element;
183
237
 
238
+ interface CalendarProps<T extends DateValue> extends Omit<CalendarProps$1<T>, "visibleDuration"> {
239
+ errorMessage?: string;
240
+ }
241
+ declare function Calendar<T extends DateValue>({ errorMessage, ...props }: CalendarProps<T>): react_jsx_runtime.JSX.Element;
242
+
243
+ interface CardProps {
244
+ heading?: React__default.ReactNode;
245
+ upperRightText?: React__default.ReactNode;
246
+ withPadding?: boolean;
247
+ isGhost?: boolean;
248
+ children?: React__default.ReactNode;
249
+ className?: string;
250
+ isLoading?: boolean;
251
+ }
252
+ declare const Card: React__default.FC<CardProps>;
253
+
254
+ interface CheckboxProps extends Omit<CheckboxProps$1, "children"> {
255
+ children?: ReactNode | ((props: CheckboxRenderProps) => ReactNode);
256
+ }
257
+ declare function Checkbox(props: CheckboxProps): react_jsx_runtime.JSX.Element;
258
+
259
+ interface CopyToClipboardProps {
260
+ /**
261
+ * The value to copy to clipboard. If not provided, will use the text content of children
262
+ */
263
+ value?: string;
264
+ /**
265
+ * The content to display
266
+ */
267
+ children: React__default.ReactNode;
268
+ /**
269
+ * Optional className for the container
270
+ */
271
+ className?: string;
272
+ /**
273
+ * Size of the copy button, defaults to "sm"
274
+ */
275
+ size?: "sm" | "md";
276
+ }
277
+ declare function CopyToClipboard({ value, children, className, size }: CopyToClipboardProps): react_jsx_runtime.JSX.Element;
278
+
279
+ interface DateFieldProps<T extends DateValue> extends DateFieldProps$1<T> {
280
+ label?: string;
281
+ description?: string;
282
+ errorMessage?: string | ((validation: ValidationResult) => string);
283
+ }
284
+ declare function DateField<T extends DateValue>({ label, description, errorMessage, ...props }: DateFieldProps<T>): react_jsx_runtime.JSX.Element;
285
+
286
+ interface DateRangePickerProps<T extends DateValue> extends DateRangePickerProps$1<T> {
287
+ label?: string;
288
+ description?: string;
289
+ errorMessage?: string | ((validation: ValidationResult) => string);
290
+ }
291
+ declare function DateRangePicker<T extends DateValue>({ label, description, errorMessage, ...props }: DateRangePickerProps<T>): react_jsx_runtime.JSX.Element;
292
+
293
+ declare function Dialog(props: DialogProps): react_jsx_runtime.JSX.Element;
294
+
295
+ type BaseDialogHeaderProps = {
296
+ title?: string;
297
+ onClose: () => void;
298
+ titleAlign?: "left" | "center";
299
+ headerContent?: React__default.ReactNode;
300
+ };
301
+ type WithBackArrow = BaseDialogHeaderProps & {
302
+ hasBackArrow: true;
303
+ onBack: () => void;
304
+ };
305
+ type WithoutBackArrow = BaseDialogHeaderProps & {
306
+ hasBackArrow?: false;
307
+ onBack?: never;
308
+ };
309
+ type DialogHeaderProps = WithBackArrow | WithoutBackArrow;
310
+ declare const DialogHeader: React__default.FC<DialogHeaderProps>;
311
+
312
+ interface DrawerAction {
313
+ label: string;
314
+ onPress: () => void;
315
+ variant?: "default" | "primary" | "secondary" | "destructive" | "icon" | "link" | "unstyled" | "ghost";
316
+ size?: "sm" | "md" | "lg";
317
+ isLoading?: boolean;
318
+ isDisabled?: boolean;
319
+ }
320
+ interface DrawerProps {
321
+ title?: string;
322
+ headerContent?: React__default.ReactNode;
323
+ children?: React__default.ReactNode;
324
+ isOpen: boolean;
325
+ slideInFrom?: "left" | "right";
326
+ transparentOverlay?: boolean;
327
+ onClose?: () => void;
328
+ className?: string;
329
+ primaryAction?: DrawerAction;
330
+ secondaryAction?: DrawerAction;
331
+ footerContent?: React__default.ReactNode;
332
+ }
333
+ declare const Drawer: React__default.FC<DrawerProps>;
334
+
335
+ interface Props {
336
+ children: ReactNode;
337
+ fallback?: ReactNode;
338
+ title?: string;
339
+ }
340
+ interface State {
341
+ hasError: boolean;
342
+ error?: Error;
343
+ }
344
+ declare class ErrorBoundary extends Component<Props, State> {
345
+ state: State;
346
+ static getDerivedStateFromError(error: Error): State;
347
+ componentDidCatch(error: Error, errorInfo: ErrorInfo): void;
348
+ private handleRetry;
349
+ render(): string | number | boolean | react_jsx_runtime.JSX.Element | Iterable<ReactNode> | null | undefined;
350
+ }
351
+
184
352
  interface InputStyleProps {
185
353
  /** Whether the input is in an invalid state */
186
354
  isInvalid?: boolean;
@@ -290,7 +458,7 @@ declare function getInputStateStyles(props: {
290
458
  declare function getInputBackgroundStyles(props: {
291
459
  transparent?: boolean;
292
460
  isDisabled?: boolean;
293
- }): "bg-transparent" | "bg-background-muted" | "bg-background-input";
461
+ }): "bg-background-muted" | "bg-transparent" | "bg-background-input";
294
462
  /**
295
463
  * Generates the complete set of base styles for input components.
296
464
  * This includes state styles, background, sizing, and custom classes.
@@ -380,32 +548,130 @@ declare function Input({ size, isInvalid, isDisabled, isFocused, transparent, cl
380
548
  */
381
549
  declare function FieldGroup(props: FieldGroupProps): react_jsx_runtime.JSX.Element;
382
550
 
383
- interface TextFieldProps extends Omit<TextFieldProps$1, "isRequired" | "size" | "className">, BaseInputProps {
551
+ declare function Form(props: FormProps): react_jsx_runtime.JSX.Element;
552
+
553
+ declare const sizeVariants: {
554
+ readonly xs: "text-lg font-semibold";
555
+ readonly sm: "text-xl font-semibold";
556
+ readonly md: "text-2xl font-semibold";
557
+ readonly lg: "text-3xl font-semibold";
558
+ readonly xl: "text-4xl font-semibold";
559
+ };
560
+ declare const heightVariants: {
561
+ readonly page: "h-16 leading-[62px]";
562
+ };
563
+ type HeadingSize = keyof typeof sizeVariants;
564
+ type HeadingHeight = keyof typeof heightVariants;
565
+ interface HeadingProps {
566
+ tag?: keyof JSX.IntrinsicElements;
567
+ size?: HeadingSize;
568
+ height?: HeadingHeight;
569
+ className?: string;
570
+ children?: React__default.ReactNode;
571
+ }
572
+ declare function Heading({ tag: Tag, size, height, className, children }: HeadingProps): react_jsx_runtime.JSX.Element;
573
+
574
+ interface ListBoxProps<T> extends Omit<ListBoxProps$1<T>, "layout" | "orientation"> {
575
+ }
576
+ declare function ListBox<T extends object>({ children, ...props }: ListBoxProps<T>): react_jsx_runtime.JSX.Element;
577
+
578
+ interface ExtendedListBoxItemProps extends Omit<ListBoxItemProps, "className"> {
579
+ size?: "sm" | "md" | "lg" | "xl";
580
+ className?: string;
581
+ }
582
+ declare function ListBoxItem({ size, className, ...props }: ExtendedListBoxItemProps): react_jsx_runtime.JSX.Element;
583
+
584
+ interface LoaderProps {
585
+ /**
586
+ * Optional className for custom styling
587
+ */
588
+ className?: string;
589
+ /**
590
+ * Size of the loader in pixels
591
+ * @default 24
592
+ */
593
+ size?: number;
594
+ /**
595
+ * Color of the loader
596
+ * @default "text-action-primary"
597
+ */
598
+ color?: string;
599
+ }
600
+ declare const Loader: ({ className, size, color }: LoaderProps) => react_jsx_runtime.JSX.Element;
601
+
602
+ interface LogoProps {
603
+ className?: string;
604
+ showWordmark?: boolean;
605
+ }
606
+ declare const Logo: ({ className, showWordmark }: LogoProps) => react_jsx_runtime.JSX.Element;
607
+
608
+ interface NumberFieldProps extends Omit<NumberFieldProps$1, "size" | "className">, BaseInputProps {
609
+ value?: number;
610
+ defaultValue?: number;
611
+ onChange?: (value: number) => void;
612
+ minValue?: number;
613
+ maxValue?: number;
614
+ step?: number;
615
+ formatOptions?: Intl.NumberFormatOptions;
616
+ id?: string;
384
617
  label?: string;
385
618
  description?: string;
386
619
  errorMessage?: string | ((validation: ValidationResult) => string);
387
- placeholder?: string;
388
620
  tooltip?: string;
389
621
  isRequired?: boolean;
390
622
  className?: string;
391
623
  validationResult?: ValidationResult;
392
624
  }
393
- declare function TextField({ label, description, errorMessage, size, tooltip, isRequired, transparent, showSearchIcon, isClearable, onClear, type, validationResult, ...props }: TextFieldProps): react_jsx_runtime.JSX.Element;
625
+ declare function NumberField({ label, description, errorMessage, size, tooltip, isRequired, transparent, validationResult, ...props }: NumberFieldProps): react_jsx_runtime.JSX.Element;
394
626
 
395
- interface TextAreaProps extends Omit<React__default.TextareaHTMLAttributes<HTMLTextAreaElement>, "size">, BaseInputProps {
627
+ interface Place {
628
+ id: string;
629
+ place_name: string;
630
+ place_type: string[];
631
+ center: [number, number];
632
+ }
633
+ type SearchType = "country" | "region" | "district" | "place" | "locality" | "neighborhood" | "address" | "street";
634
+ interface PlaceSearchProps {
396
635
  label?: string;
397
- description?: string;
636
+ selectedKey?: Key | null;
637
+ defaultSelectedKey?: Key | null;
638
+ onSelectionChange?: (key: Key | null) => void;
639
+ placeholder?: string;
398
640
  errorMessage?: string | ((validation: ValidationResult) => string);
641
+ description?: string;
642
+ size?: "sm" | "md" | "lg" | "xl";
399
643
  tooltip?: string;
400
- size?: Size;
401
- isInvalid?: boolean;
644
+ isRequired?: boolean;
645
+ isDisabled?: boolean;
646
+ showErrors?: boolean;
647
+ autoFocus?: boolean;
648
+ onSelect: (place: Place) => void;
649
+ searchTypes?: SearchType[];
650
+ defaultFilter?: (textValue: string, inputValue: string) => boolean;
402
651
  validationResult?: ValidationResult;
652
+ countryRestrictions?: string[];
653
+ proximity?: "ip" | [number, number];
403
654
  }
404
- declare function TextArea({ label, description, errorMessage, size, tooltip, required, transparent, isInvalid, className, validationResult, ...props }: TextAreaProps): react_jsx_runtime.JSX.Element;
655
+ declare function PlaceSearch({ label, selectedKey, defaultSelectedKey, onSelectionChange, placeholder, errorMessage, description, size, tooltip, isRequired, isDisabled, showErrors, autoFocus, onSelect, searchTypes, defaultFilter, validationResult, countryRestrictions, proximity, }: PlaceSearchProps): react_jsx_runtime.JSX.Element;
405
656
 
406
- interface ListBoxProps<T> extends Omit<ListBoxProps$1<T>, "layout" | "orientation"> {
657
+ interface PopoverProps extends Omit<PopoverProps$1, "children"> {
658
+ showArrow?: boolean;
659
+ children: React__default.ReactNode;
407
660
  }
408
- declare function ListBox<T extends object>({ children, ...props }: ListBoxProps<T>): react_jsx_runtime.JSX.Element;
661
+ declare function Popover({ children, showArrow, className, ...props }: PopoverProps): react_jsx_runtime.JSX.Element;
662
+
663
+ interface ProgressBarProps extends ProgressBarProps$1 {
664
+ label?: string;
665
+ rightLabel?: string;
666
+ progressWidth?: number;
667
+ hideLabels?: boolean;
668
+ }
669
+ declare function ProgressBar({ label, rightLabel, progressWidth, hideLabels, ...props }: ProgressBarProps): react_jsx_runtime.JSX.Element;
670
+
671
+ interface RangeCalendarProps<T extends DateValue> extends Omit<RangeCalendarProps$1<T>, "visibleDuration"> {
672
+ errorMessage?: string;
673
+ }
674
+ declare function RangeCalendar<T extends DateValue>({ errorMessage, ...props }: RangeCalendarProps<T>): react_jsx_runtime.JSX.Element;
409
675
 
410
676
  /**
411
677
  * Interface defining the shape of items in the Select component
@@ -454,26 +720,49 @@ interface SelectProps<T extends SelectItem> extends Omit<SelectProps$1<T>, "chil
454
720
  }
455
721
  declare function Select<T extends SelectItem>({ label, description, errorMessage, children, items, size, selectedKey: controlledSelectedKey, defaultSelectedKey, onSelectionChange, placeholder, showErrors, tooltip, isRequired, transparent, ...props }: SelectProps<T>): react_jsx_runtime.JSX.Element;
456
722
 
457
- interface NumberFieldProps extends Omit<NumberFieldProps$1, "size" | "className">, BaseInputProps {
458
- value?: number;
459
- defaultValue?: number;
460
- onChange?: (value: number) => void;
461
- minValue?: number;
462
- maxValue?: number;
463
- step?: number;
464
- formatOptions?: Intl.NumberFormatOptions;
465
- id?: string;
466
- label?: string;
467
- description?: string;
468
- errorMessage?: string | ((validation: ValidationResult) => string);
469
- tooltip?: string;
470
- isRequired?: boolean;
723
+ interface SkeletonProps {
724
+ width?: number | string;
725
+ height?: number | string;
726
+ variant?: "text" | "rect" | "circle";
727
+ animation?: "pulse" | "wave" | "none";
728
+ gradient?: boolean;
729
+ flex?: boolean;
730
+ stack?: (number | string)[];
731
+ responsive?: Record<string, string | number>;
732
+ delay?: number;
733
+ adjustAnimationSpeedBasedOnWidth?: boolean;
734
+ ariaLabel?: string;
471
735
  className?: string;
736
+ "data-testid"?: string;
737
+ }
738
+ declare const Skeleton: React__default.FC<SkeletonProps>;
739
+
740
+ interface SwitchProps extends Omit<SwitchProps$1, "children"> {
741
+ children: React__default.ReactNode;
742
+ }
743
+ declare function Switch({ children, ...props }: SwitchProps): react_jsx_runtime.JSX.Element;
744
+
745
+ type TabProps = TabProps$1 & {
746
+ isSelected?: boolean;
747
+ id?: string;
748
+ };
749
+ declare function Tabs(props: TabsProps): react_jsx_runtime.JSX.Element;
750
+ declare function TabList<T extends object>(props: TabListProps<T>): react_jsx_runtime.JSX.Element;
751
+ declare function Tab(props: TabProps): react_jsx_runtime.JSX.Element;
752
+ declare function TabPanel(props: TabPanelProps): react_jsx_runtime.JSX.Element;
753
+
754
+ interface TextAreaProps extends Omit<React__default.TextareaHTMLAttributes<HTMLTextAreaElement>, "size">, BaseInputProps {
755
+ label?: string;
756
+ description?: string;
757
+ errorMessage?: string | ((validation: ValidationResult) => string);
758
+ tooltip?: string;
759
+ size?: Size;
760
+ isInvalid?: boolean;
472
761
  validationResult?: ValidationResult;
473
762
  }
474
- declare function NumberField({ label, description, errorMessage, size, tooltip, isRequired, transparent, validationResult, ...props }: NumberFieldProps): react_jsx_runtime.JSX.Element;
763
+ declare function TextArea({ label, description, errorMessage, size, tooltip, required, transparent, isInvalid, className, validationResult, ...props }: TextAreaProps): react_jsx_runtime.JSX.Element;
475
764
 
476
- interface TimeFieldProps extends Omit<TimeFieldProps$1<TimeValue>, "size" | "className">, BaseInputProps {
765
+ interface TextFieldProps extends Omit<TextFieldProps$1, "isRequired" | "size" | "className">, BaseInputProps {
477
766
  label?: string;
478
767
  description?: string;
479
768
  errorMessage?: string | ((validation: ValidationResult) => string);
@@ -483,14 +772,33 @@ interface TimeFieldProps extends Omit<TimeFieldProps$1<TimeValue>, "size" | "cla
483
772
  className?: string;
484
773
  validationResult?: ValidationResult;
485
774
  }
486
- declare function TimeField({ label, description, errorMessage, size, tooltip, isRequired, transparent, validationResult, ...props }: TimeFieldProps): react_jsx_runtime.JSX.Element;
775
+ declare function TextField({ label, description, errorMessage, size, tooltip, isRequired, transparent, showSearchIcon, isClearable, onClear, type, validationResult, ...props }: TextFieldProps): react_jsx_runtime.JSX.Element;
487
776
 
488
- interface DateFieldProps<T extends DateValue> extends DateFieldProps$1<T> {
777
+ interface TextLinkProps {
778
+ href?: string;
779
+ children: ReactNode;
780
+ className?: string;
781
+ external?: boolean;
782
+ title?: string;
783
+ variant?: "default" | "primary" | "muted";
784
+ onClick?: (e: React.MouseEvent<HTMLAnchorElement>) => void;
785
+ asButton?: boolean;
786
+ onPress?: () => void;
787
+ showArrow?: boolean;
788
+ }
789
+ declare const TextLink: ({ href, children, className, external, title, variant, onClick, asButton, onPress, showArrow, }: TextLinkProps) => react_jsx_runtime.JSX.Element;
790
+
791
+ interface TimeFieldProps extends Omit<TimeFieldProps$1<TimeValue>, "size" | "className">, BaseInputProps {
489
792
  label?: string;
490
793
  description?: string;
491
794
  errorMessage?: string | ((validation: ValidationResult) => string);
795
+ placeholder?: string;
796
+ tooltip?: string;
797
+ isRequired?: boolean;
798
+ className?: string;
799
+ validationResult?: ValidationResult;
492
800
  }
493
- declare function DateField<T extends DateValue>({ label, description, errorMessage, ...props }: DateFieldProps<T>): react_jsx_runtime.JSX.Element;
801
+ declare function TimeField({ label, description, errorMessage, size, tooltip, isRequired, transparent, validationResult, ...props }: TimeFieldProps): react_jsx_runtime.JSX.Element;
494
802
 
495
803
  type IconName = ComponentProps<typeof Icon>["name"];
496
804
  interface ToggleButtonProps {
@@ -525,235 +833,4 @@ interface TooltipProps extends Omit<TooltipProps$1, "children"> {
525
833
  }
526
834
  declare function Tooltip({ children, content, ...props }: TooltipProps): react_jsx_runtime.JSX.Element;
527
835
 
528
- interface TextLinkProps {
529
- href?: string;
530
- children: ReactNode;
531
- className?: string;
532
- external?: boolean;
533
- title?: string;
534
- variant?: "default" | "primary" | "muted";
535
- onClick?: (e: React.MouseEvent<HTMLAnchorElement>) => void;
536
- asButton?: boolean;
537
- onPress?: () => void;
538
- showArrow?: boolean;
539
- }
540
- declare const TextLink: ({ href, children, className, external, title, variant, onClick, asButton, onPress, showArrow, }: TextLinkProps) => react_jsx_runtime.JSX.Element;
541
-
542
- interface SkeletonProps {
543
- width?: number | string;
544
- height?: number | string;
545
- variant?: "text" | "rect" | "circle";
546
- animation?: "pulse" | "wave" | "none";
547
- gradient?: boolean;
548
- flex?: boolean;
549
- stack?: (number | string)[];
550
- responsive?: Record<string, string | number>;
551
- delay?: number;
552
- adjustAnimationSpeedBasedOnWidth?: boolean;
553
- ariaLabel?: string;
554
- className?: string;
555
- "data-testid"?: string;
556
- }
557
- declare const Skeleton: React__default.FC<SkeletonProps>;
558
-
559
- interface LogoProps {
560
- className?: string;
561
- showWordmark?: boolean;
562
- }
563
- declare const Logo: ({ className, showWordmark }: LogoProps) => react_jsx_runtime.JSX.Element;
564
-
565
- interface PopoverProps extends Omit<PopoverProps$1, "children"> {
566
- showArrow?: boolean;
567
- children: React__default.ReactNode;
568
- }
569
- declare function Popover({ children, showArrow, className, ...props }: PopoverProps): react_jsx_runtime.JSX.Element;
570
-
571
- interface LoaderProps {
572
- /**
573
- * Optional className for custom styling
574
- */
575
- className?: string;
576
- /**
577
- * Size of the loader in pixels
578
- * @default 24
579
- */
580
- size?: number;
581
- /**
582
- * Color of the loader
583
- * @default "text-action-primary"
584
- */
585
- color?: string;
586
- }
587
- declare const Loader: ({ className, size, color }: LoaderProps) => react_jsx_runtime.JSX.Element;
588
-
589
- declare const sizeVariants: {
590
- readonly xs: "text-lg font-semibold";
591
- readonly sm: "text-xl font-semibold";
592
- readonly md: "text-2xl font-semibold";
593
- readonly lg: "text-3xl font-semibold";
594
- readonly xl: "text-4xl font-semibold";
595
- };
596
- declare const heightVariants: {
597
- readonly page: "h-16 leading-[62px]";
598
- };
599
- type HeadingSize = keyof typeof sizeVariants;
600
- type HeadingHeight = keyof typeof heightVariants;
601
- interface HeadingProps {
602
- tag?: keyof JSX.IntrinsicElements;
603
- size?: HeadingSize;
604
- height?: HeadingHeight;
605
- className?: string;
606
- children?: React__default.ReactNode;
607
- }
608
- declare function Heading({ tag: Tag, size, height, className, children }: HeadingProps): react_jsx_runtime.JSX.Element;
609
-
610
- interface CopyToClipboardProps {
611
- /**
612
- * The value to copy to clipboard. If not provided, will use the text content of children
613
- */
614
- value?: string;
615
- /**
616
- * The content to display
617
- */
618
- children: React__default.ReactNode;
619
- /**
620
- * Optional className for the container
621
- */
622
- className?: string;
623
- /**
624
- * Size of the copy button, defaults to "sm"
625
- */
626
- size?: "sm" | "md";
627
- }
628
- declare function CopyToClipboard({ value, children, className, size }: CopyToClipboardProps): react_jsx_runtime.JSX.Element;
629
-
630
- interface SwitchProps extends Omit<SwitchProps$1, "children"> {
631
- children: React__default.ReactNode;
632
- }
633
- declare function Switch({ children, ...props }: SwitchProps): react_jsx_runtime.JSX.Element;
634
-
635
- interface ProgressBarProps extends ProgressBarProps$1 {
636
- label?: string;
637
- rightLabel?: string;
638
- progressWidth?: number;
639
- hideLabels?: boolean;
640
- }
641
- declare function ProgressBar({ label, rightLabel, progressWidth, hideLabels, ...props }: ProgressBarProps): react_jsx_runtime.JSX.Element;
642
-
643
- interface RangeCalendarProps<T extends DateValue> extends Omit<RangeCalendarProps$1<T>, "visibleDuration"> {
644
- errorMessage?: string;
645
- }
646
- declare function RangeCalendar<T extends DateValue>({ errorMessage, ...props }: RangeCalendarProps<T>): react_jsx_runtime.JSX.Element;
647
-
648
- interface Place {
649
- id: string;
650
- place_name: string;
651
- place_type: string[];
652
- center: [number, number];
653
- }
654
- type SearchType = "country" | "region" | "district" | "place" | "locality" | "neighborhood" | "address" | "street";
655
- interface PlaceSearchProps {
656
- label?: string;
657
- selectedKey?: Key | null;
658
- defaultSelectedKey?: Key | null;
659
- onSelectionChange?: (key: Key | null) => void;
660
- placeholder?: string;
661
- errorMessage?: string | ((validation: ValidationResult) => string);
662
- description?: string;
663
- size?: "sm" | "md" | "lg" | "xl";
664
- tooltip?: string;
665
- isRequired?: boolean;
666
- isDisabled?: boolean;
667
- showErrors?: boolean;
668
- autoFocus?: boolean;
669
- onSelect: (place: Place) => void;
670
- searchTypes?: SearchType[];
671
- defaultFilter?: (textValue: string, inputValue: string) => boolean;
672
- validationResult?: ValidationResult;
673
- countryRestrictions?: string[];
674
- proximity?: "ip" | [number, number];
675
- }
676
- declare function PlaceSearch({ label, selectedKey, defaultSelectedKey, onSelectionChange, placeholder, errorMessage, description, size, tooltip, isRequired, isDisabled, showErrors, autoFocus, onSelect, searchTypes, defaultFilter, validationResult, countryRestrictions, proximity, }: PlaceSearchProps): react_jsx_runtime.JSX.Element;
677
-
678
- interface ExtendedListBoxItemProps extends Omit<ListBoxItemProps, "className"> {
679
- size?: "sm" | "md" | "lg" | "xl";
680
- className?: string;
681
- }
682
- declare function ListBoxItem({ size, className, ...props }: ExtendedListBoxItemProps): react_jsx_runtime.JSX.Element;
683
-
684
- declare function Form(props: FormProps): react_jsx_runtime.JSX.Element;
685
-
686
- interface DateRangePickerProps<T extends DateValue> extends DateRangePickerProps$1<T> {
687
- label?: string;
688
- description?: string;
689
- errorMessage?: string | ((validation: ValidationResult) => string);
690
- }
691
- declare function DateRangePicker<T extends DateValue>({ label, description, errorMessage, ...props }: DateRangePickerProps<T>): react_jsx_runtime.JSX.Element;
692
-
693
- declare function Dialog(props: DialogProps): react_jsx_runtime.JSX.Element;
694
-
695
- interface CalendarProps<T extends DateValue> extends Omit<CalendarProps$1<T>, "visibleDuration"> {
696
- errorMessage?: string;
697
- }
698
- declare function Calendar<T extends DateValue>({ errorMessage, ...props }: CalendarProps<T>): react_jsx_runtime.JSX.Element;
699
-
700
- interface CheckboxProps extends Omit<CheckboxProps$1, "children"> {
701
- children?: ReactNode | ((props: CheckboxRenderProps) => ReactNode);
702
- }
703
- declare function Checkbox(props: CheckboxProps): react_jsx_runtime.JSX.Element;
704
-
705
- interface Item {
706
- id: string;
707
- name: string;
708
- }
709
- interface Section {
710
- name: string;
711
- items: Item[];
712
- }
713
- type RequestMethod = "GET" | "POST";
714
- interface BaseRequestConfig {
715
- url: string;
716
- headers?: Record<string, string>;
717
- transformResponse: (data: unknown) => Item[];
718
- }
719
- interface RestRequestConfig extends BaseRequestConfig {
720
- requestType: "REST";
721
- method?: RequestMethod;
722
- queryKey?: string;
723
- extraParams?: Record<string, string>;
724
- shouldLoad?: (filterText: string) => boolean;
725
- }
726
- interface GraphQLRequestConfig extends BaseRequestConfig {
727
- requestType: "GraphQL";
728
- graphqlQuery: string;
729
- variableKey?: string;
730
- responsePath?: string;
731
- shouldLoad?: (filterText: string) => boolean;
732
- }
733
- type AutocompleteRequestConfig = RestRequestConfig | GraphQLRequestConfig;
734
- interface AutocompleteProps {
735
- label?: string;
736
- staticItems?: Item[];
737
- sections?: Section[];
738
- selectedKey?: Key | null;
739
- defaultSelectedKey?: Key | null;
740
- onSelectionChange?: (key: Key | null) => void;
741
- requestConfig?: AutocompleteRequestConfig;
742
- defaultFilter?: (textValue: string, inputValue: string) => boolean;
743
- placeholder?: string;
744
- renderItem?: (item: Item) => React__default.ReactNode;
745
- renderLeftIcon?: (isLoading: boolean) => React__default.ReactNode;
746
- errorMessage?: string | ((validation: ValidationResult) => string);
747
- description?: string;
748
- size?: "sm" | "md" | "lg" | "xl";
749
- tooltip?: string;
750
- isRequired?: boolean;
751
- isDisabled?: boolean;
752
- validationResult?: ValidationResult;
753
- showErrors?: boolean;
754
- autoFocus?: boolean;
755
- onLoadError?: (error: Error) => void;
756
- }
757
- declare function Autocomplete({ label, staticItems, sections, selectedKey, defaultSelectedKey, onSelectionChange, requestConfig, defaultFilter, errorMessage, size, tooltip, isRequired, isDisabled, renderLeftIcon, autoFocus, onLoadError, }: AutocompleteProps): react_jsx_runtime.JSX.Element;
758
-
759
- export { Autocomplete, type BaseInputProps, type BaseProps, Button, Calendar, Checkbox, ClearButton, CopyToClipboard, DateField, DateRangePicker, Description, type DescriptionProps, Dialog, FieldError, type FieldErrorProps, FieldGroup, type FieldGroupProps, Form, Heading, Icon, Input, type InputProps, type InputStyleProps, InputWrapper, Label, type LabelProps, ListBox, ListBoxItem, Loader, Logo, NumberField, PlaceSearch, Popover, ProgressBar, RangeCalendar, Select, Skeleton, Switch, TextArea, TextField, TextLink, TimeField, ToggleButton, Tooltip, getFieldGroupStyles, getInputBackgroundStyles, getInputBaseStyles, getInputStateStyles, useInputFocus };
836
+ export { Autocomplete, type BaseInputProps, type BaseProps, Button, Calendar, Card, Checkbox, ClearButton, CopyToClipboard, DateField, DateRangePicker, Description, type DescriptionProps, Dialog, DialogHeader, Drawer, ErrorBoundary, FieldError, type FieldErrorProps, FieldGroup, type FieldGroupProps, Form, Heading, Icon, Input, type InputProps, type InputStyleProps, InputWrapper, Label, type LabelProps, ListBox, ListBoxItem, Loader, Logo, NumberField, PlaceSearch, Popover, ProgressBar, RangeCalendar, Select, Skeleton, Switch, Tab, TabList, TabPanel, Tabs, TextArea, TextField, TextLink, TimeField, ToggleButton, Tooltip, getFieldGroupStyles, getInputBackgroundStyles, getInputBaseStyles, getInputStateStyles, useInputFocus };