@arctura/atomics 0.0.1

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.
Files changed (87) hide show
  1. package/dist/hooks.cjs +1 -0
  2. package/dist/hooks.js +2 -0
  3. package/dist/index.cjs +1 -0
  4. package/dist/index.js +1980 -0
  5. package/dist/lib/hooks.d.ts +5 -0
  6. package/dist/lib/hooks.d.ts.map +1 -0
  7. package/dist/lib/index.d.ts +6 -0
  8. package/dist/lib/index.d.ts.map +1 -0
  9. package/dist/lib/useBreakpoints.d.ts +48 -0
  10. package/dist/lib/useBreakpoints.d.ts.map +1 -0
  11. package/dist/lib/useControlled.d.ts +38 -0
  12. package/dist/lib/useControlled.d.ts.map +1 -0
  13. package/dist/src/badge/Badge.d.ts +116 -0
  14. package/dist/src/badge/Badge.d.ts.map +1 -0
  15. package/dist/src/badge/index.d.ts +3 -0
  16. package/dist/src/badge/index.d.ts.map +1 -0
  17. package/dist/src/buttons/Button.d.ts +126 -0
  18. package/dist/src/buttons/Button.d.ts.map +1 -0
  19. package/dist/src/buttons/Fab.d.ts +114 -0
  20. package/dist/src/buttons/Fab.d.ts.map +1 -0
  21. package/dist/src/buttons/IconButton.d.ts +105 -0
  22. package/dist/src/buttons/IconButton.d.ts.map +1 -0
  23. package/dist/src/buttons/index.d.ts +9 -0
  24. package/dist/src/buttons/index.d.ts.map +1 -0
  25. package/dist/src/card/Card.d.ts +35 -0
  26. package/dist/src/card/Card.d.ts.map +1 -0
  27. package/dist/src/card/Footer.d.ts +67 -0
  28. package/dist/src/card/Footer.d.ts.map +1 -0
  29. package/dist/src/card/Header.d.ts +56 -0
  30. package/dist/src/card/Header.d.ts.map +1 -0
  31. package/dist/src/card/Media.d.ts +65 -0
  32. package/dist/src/card/Media.d.ts.map +1 -0
  33. package/dist/src/card/index.d.ts +11 -0
  34. package/dist/src/card/index.d.ts.map +1 -0
  35. package/dist/src/carousel/Carousel.d.ts +124 -0
  36. package/dist/src/carousel/Carousel.d.ts.map +1 -0
  37. package/dist/src/carousel/Hero.d.ts +156 -0
  38. package/dist/src/carousel/Hero.d.ts.map +1 -0
  39. package/dist/src/carousel/index.d.ts +4 -0
  40. package/dist/src/carousel/index.d.ts.map +1 -0
  41. package/dist/src/drawer/Drawer.d.ts +40 -0
  42. package/dist/src/drawer/Drawer.d.ts.map +1 -0
  43. package/dist/src/drawer/index.d.ts +5 -0
  44. package/dist/src/drawer/index.d.ts.map +1 -0
  45. package/dist/src/form/Form.d.ts +168 -0
  46. package/dist/src/form/Form.d.ts.map +1 -0
  47. package/dist/src/form/TextArea.d.ts +266 -0
  48. package/dist/src/form/TextArea.d.ts.map +1 -0
  49. package/dist/src/form/TextInput.d.ts +200 -0
  50. package/dist/src/form/TextInput.d.ts.map +1 -0
  51. package/dist/src/form/index.d.ts +7 -0
  52. package/dist/src/form/index.d.ts.map +1 -0
  53. package/dist/src/index.d.ts +21 -0
  54. package/dist/src/index.d.ts.map +1 -0
  55. package/dist/src/list/List.d.ts +122 -0
  56. package/dist/src/list/List.d.ts.map +1 -0
  57. package/dist/src/list/ListItem.d.ts +157 -0
  58. package/dist/src/list/ListItem.d.ts.map +1 -0
  59. package/dist/src/list/index.d.ts +6 -0
  60. package/dist/src/list/index.d.ts.map +1 -0
  61. package/dist/src/progress-stepper/Connector.d.ts +48 -0
  62. package/dist/src/progress-stepper/Connector.d.ts.map +1 -0
  63. package/dist/src/progress-stepper/Node.d.ts +75 -0
  64. package/dist/src/progress-stepper/Node.d.ts.map +1 -0
  65. package/dist/src/progress-stepper/ProgressStepper.d.ts +108 -0
  66. package/dist/src/progress-stepper/ProgressStepper.d.ts.map +1 -0
  67. package/dist/src/progress-stepper/Step.d.ts +93 -0
  68. package/dist/src/progress-stepper/Step.d.ts.map +1 -0
  69. package/dist/src/progress-stepper/index.d.ts +10 -0
  70. package/dist/src/progress-stepper/index.d.ts.map +1 -0
  71. package/dist/src/select/Select.d.ts +98 -0
  72. package/dist/src/select/Select.d.ts.map +1 -0
  73. package/dist/src/select/index.d.ts +5 -0
  74. package/dist/src/select/index.d.ts.map +1 -0
  75. package/dist/src/typography/Link.d.ts +86 -0
  76. package/dist/src/typography/Link.d.ts.map +1 -0
  77. package/dist/src/typography/Typography.d.ts +148 -0
  78. package/dist/src/typography/Typography.d.ts.map +1 -0
  79. package/dist/src/typography/index.d.ts +7 -0
  80. package/dist/src/typography/index.d.ts.map +1 -0
  81. package/dist/src/utils/capitalize.d.ts +3 -0
  82. package/dist/src/utils/capitalize.d.ts.map +1 -0
  83. package/dist/src/utils/index.d.ts +2 -0
  84. package/dist/src/utils/index.d.ts.map +1 -0
  85. package/dist/useBreakpoints-CXOalIdM.js +37 -0
  86. package/dist/useBreakpoints-nd-Blu7O.cjs +1 -0
  87. package/package.json +67 -0
@@ -0,0 +1,5 @@
1
+ import { useBreakpoints } from './useBreakpoints';
2
+ import type { Breakpoint } from './useBreakpoints';
3
+ export { useBreakpoints };
4
+ export type { Breakpoint };
5
+ //# sourceMappingURL=hooks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../lib/hooks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,OAAO,EAAE,cAAc,EAAE,CAAC;AAC1B,YAAY,EAAE,UAAU,EAAE,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { useControlled } from './useControlled';
2
+ import { useBreakpoints } from './useBreakpoints';
3
+ import type { Breakpoint } from './useBreakpoints';
4
+ export { useBreakpoints, useControlled };
5
+ export type { Breakpoint };
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,CAAC;AACzC,YAAY,EAAE,UAAU,EAAE,CAAC"}
@@ -0,0 +1,48 @@
1
+ import tokens from '@/tokens.json';
2
+ /**
3
+ * Viewport breakpoint names recognized by the app.
4
+ */
5
+ type Breakpoint = keyof typeof tokens.theme.breakpoints;
6
+ /**
7
+ * Mapping of breakpoint names to their min-width values.
8
+ */
9
+ type Breakpoints = Record<Breakpoint, string>;
10
+ /**
11
+ * React hook that exposes the current breakpoint and convenience guards.
12
+ *
13
+ * @returns The active breakpoint, the breakpoint map, and comparison helpers.
14
+ *
15
+ * @example
16
+ * ```tsx
17
+ * const { breakpoint, isAtLeast } = useBreakpoints();
18
+ *
19
+ * if (isAtLeast('lg')) {
20
+ * console.log('Desktop layout', breakpoint);
21
+ * }
22
+ * ```
23
+ *
24
+ * @example
25
+ * ```tsx
26
+ * const { isBelow } = useBreakpoints();
27
+ *
28
+ * if (isBelow('md')) {
29
+ * console.log('Mobile or tablet layout');
30
+ * }
31
+ * ```
32
+ *
33
+ * @example
34
+ * ```tsx
35
+ * const { breakpoints } = useBreakpoints();
36
+ *
37
+ * console.log(breakpoints.sm);
38
+ * ```
39
+ */
40
+ declare function useBreakpoints(): {
41
+ breakpoint: Breakpoint;
42
+ breakpoints: Breakpoints;
43
+ isAtLeast: (target: Breakpoint) => boolean;
44
+ isBelow: (target: Breakpoint) => boolean;
45
+ };
46
+ export { useBreakpoints };
47
+ export type { Breakpoint };
48
+ //# sourceMappingURL=useBreakpoints.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useBreakpoints.d.ts","sourceRoot":"","sources":["../../lib/useBreakpoints.ts"],"names":[],"mappings":"AAEA,OAAO,MAAM,MAAM,eAAe,CAAC;AAEnC;;GAEG;AACH,KAAK,UAAU,GAAG,MAAM,OAAO,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC;AAExD;;GAEG;AACH,KAAK,WAAW,GAAG,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;AAmE9C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,iBAAS,cAAc,IAAI;IACzB,UAAU,EAAE,UAAU,CAAC;IACvB,WAAW,EAAE,WAAW,CAAC;IACzB,SAAS,EAAE,CAAC,MAAM,EAAE,UAAU,KAAK,OAAO,CAAC;IAC3C,OAAO,EAAE,CAAC,MAAM,EAAE,UAAU,KAAK,OAAO,CAAC;CAC1C,CAkBA;AAED,OAAO,EAAE,cAAc,EAAE,CAAC;AAC1B,YAAY,EAAE,UAAU,EAAE,CAAC"}
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Props for the useControlled hook.
3
+ *
4
+ * @template StateType - The type of the state value.
5
+ * @property {StateType} [defaultValue] - The initial value for uncontrolled mode.
6
+ * @property {StateType} [value] - The controlled value (if provided, component is controlled).
7
+ */
8
+ interface useControlledProps<StateType> {
9
+ defaultValue?: StateType;
10
+ value?: StateType;
11
+ }
12
+ /**
13
+ * React hook for managing controlled and uncontrolled component state.
14
+ *
15
+ * If a `value` prop is provided, the hook acts as a controlled component (external state).
16
+ * If no `value` is provided, it manages its own state internally using `defaultValue`.
17
+ *
18
+ * @template StateType - The type of the state value.
19
+ * @param {Object} props - The props object.
20
+ * @param {StateType} [props.defaultValue] - The initial value for uncontrolled mode.
21
+ * @param {StateType} [props.value] - The controlled value (if provided, component is controlled).
22
+ * @returns {[StateType | undefined, (newValue: StateType) => void]} - The current value and a setter function.
23
+ *
24
+ * @example
25
+ * // Uncontrolled usage
26
+ * const [value, setValue] = useControlled({ defaultValue: 0 });
27
+ *
28
+ * @example
29
+ * // Controlled usage
30
+ * const [value, setValue] = useControlled({ value: externalValue });
31
+ *
32
+ * @see https://reactjs.org/docs/forms.html#controlled-components for more on controlled components.
33
+ * @see https://reactjs.org/docs/hooks-custom.html#using-a-custom-hook for more on custom hooks.
34
+ * @see useControlledProps
35
+ */
36
+ declare function useControlled<StateType>({ defaultValue, value }: useControlledProps<StateType>): readonly [StateType | undefined, (newValue: StateType) => void];
37
+ export { useControlled };
38
+ //# sourceMappingURL=useControlled.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useControlled.d.ts","sourceRoot":"","sources":["../../lib/useControlled.ts"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH,UAAU,kBAAkB,CAAC,SAAS;IACpC,YAAY,CAAC,EAAE,SAAS,CAAC;IACzB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AAED;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,iBAAS,aAAa,CAAC,SAAS,EAAE,EAAE,YAAY,EAAE,KAAK,EAAE,EAAE,kBAAkB,CAAC,SAAS,CAAC,+CAO1D,SAAS,WAOtC;AAED,OAAO,EAAE,aAAa,EAAE,CAAC"}
@@ -0,0 +1,116 @@
1
+ import type { AnchorHTMLAttributes, JSX, HTMLAttributes, ReactNode, Ref } from 'react';
2
+ import type { IconDefinition } from '@fortawesome/free-solid-svg-icons';
3
+ /**
4
+ * Supported color schemes for the Badge component.
5
+ *
6
+ * - 'primary': Main brand color
7
+ * - 'secondary': Secondary color
8
+ * - 'subtle': Neutral/subtle color
9
+ * - 'accent': Accent color
10
+ * - 'success': Success/positive color
11
+ * - 'danger': Error/negative color
12
+ * - 'warning': Warning/alert color
13
+ * - 'info': Informational color
14
+ */
15
+ type BadgeColor = 'primary' | 'secondary' | 'subtle' | 'accent' | 'success' | 'danger' | 'warning' | 'info';
16
+ /**
17
+ * Position of the icon relative to the badge content.
18
+ *
19
+ * - 'start': Icon appears before the content
20
+ * - 'end': Icon appears after the content
21
+ */
22
+ type IconPosition = 'start' | 'end';
23
+ /**
24
+ * Supported size options for the Badge component.
25
+ *
26
+ * - 'xs': Extra small
27
+ * - 'sm': Small
28
+ * - 'md': Medium (default)
29
+ * - 'lg': Large
30
+ */
31
+ type BadgeSize = 'xs' | 'sm' | 'md' | 'lg';
32
+ /**
33
+ * Visual style variants for the Badge component.
34
+ *
35
+ * - 'filled': Solid background and border
36
+ * - 'outline': Transparent background with border
37
+ * - 'ghost': Transparent background, no border
38
+ */
39
+ type BadgeVariant = 'filled' | 'outline' | 'ghost';
40
+ /**
41
+ * Common props for the Badge component, shared by both div and anchor variants.
42
+ *
43
+ * @property {ReactNode} [children] - Content to display inside the badge.
44
+ * @property {string} [className] - Additional CSS classes for the badge.
45
+ * @property {BadgeColor} [color] - Color scheme for the badge.
46
+ * @property {IconDefinition} [icon] - FontAwesome icon to display in the badge.
47
+ * @property {IconPosition} [iconPosition] - Position of the icon relative to the content ('start' or 'end').
48
+ * @property {BadgeSize} [size] - Size of the badge ('xs', 'sm', 'md', 'lg').
49
+ * @property {BadgeVariant} [variant] - Visual style variant ('filled', 'outline', 'ghost').
50
+ */
51
+ interface BaseProps {
52
+ children?: ReactNode;
53
+ className?: string;
54
+ color?: BadgeColor;
55
+ icon?: IconDefinition;
56
+ iconPosition?: IconPosition;
57
+ size?: BadgeSize;
58
+ variant?: BadgeVariant;
59
+ }
60
+ /**
61
+ * Props for a Badge rendered as a <div> (non-link).
62
+ *
63
+ * @property {never} [href] - Disallowed for div variant.
64
+ * @property {Ref<HTMLDivElement>} [ref] - Ref for the div element.
65
+ * @property {never} [target] - Disallowed for div variant.
66
+ */
67
+ interface DivProps extends HTMLAttributes<HTMLDivElement> {
68
+ href?: never;
69
+ ref?: Ref<HTMLDivElement>;
70
+ target?: never;
71
+ }
72
+ /**
73
+ * Props for a Badge rendered as an <a> (link).
74
+ *
75
+ * @property {string} href - URL for the anchor element.
76
+ * @property {Ref<HTMLAnchorElement>} [ref] - Ref for the anchor element.
77
+ * @property {string} [target] - Target attribute for the anchor (e.g., '_blank').
78
+ */
79
+ interface AnchorProps extends AnchorHTMLAttributes<HTMLAnchorElement> {
80
+ href: string;
81
+ ref?: Ref<HTMLAnchorElement>;
82
+ target?: string;
83
+ }
84
+ /**
85
+ * Badge component for displaying status, labels, or links with optional icon and color styling.
86
+ *
87
+ * Renders as either a <div> or <a> element depending on the presence of the 'href' prop. Supports different color schemes, sizes, variants, and icon positions.
88
+ *
89
+ * @param {BadgeProps} props - Props for configuring the badge appearance and behavior.
90
+ * @returns {JSX.Element} The rendered badge component.
91
+ *
92
+ * @example
93
+ * ```tsx
94
+ * import { Badge } from '@/src';
95
+ * import { faCheck } from '@fortawesome/free-solid-svg-icons';
96
+ *
97
+ * const MyBadge = () => (
98
+ * <Badge
99
+ * color="success"
100
+ * icon={faCheck}
101
+ * iconPosition="start"
102
+ * size="sm"
103
+ * variant="outline"
104
+ * >
105
+ * Active
106
+ * </Badge>
107
+ * );
108
+ * ```
109
+ */
110
+ declare function Badge(props: DivProps & BaseProps): JSX.Element;
111
+ declare function Badge(props: AnchorProps & BaseProps): JSX.Element;
112
+ declare namespace Badge {
113
+ var displayName: string;
114
+ }
115
+ export { Badge };
116
+ //# sourceMappingURL=Badge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../src/badge/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,GAAG,EAAE,cAAc,EAAE,SAAS,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAEvF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAGxE;;;;;;;;;;;GAWG;AACH,KAAK,UAAU,GACX,SAAS,GACT,WAAW,GACX,QAAQ,GACR,QAAQ,GACR,SAAS,GACT,QAAQ,GACR,SAAS,GACT,MAAM,CAAC;AAEX;;;;;GAKG;AACH,KAAK,YAAY,GAAG,OAAO,GAAG,KAAK,CAAC;AAEpC;;;;;;;GAOG;AACH,KAAK,SAAS,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAE3C;;;;;;GAMG;AACH,KAAK,YAAY,GAAG,QAAQ,GAAG,SAAS,GAAG,OAAO,CAAC;AAEnD;;;;;;;;;;GAUG;AACH,UAAU,SAAS;IACjB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,OAAO,CAAC,EAAE,YAAY,CAAC;CACxB;AAED;;;;;;GAMG;AACH,UAAU,QAAS,SAAQ,cAAc,CAAC,cAAc,CAAC;IACvD,IAAI,CAAC,EAAE,KAAK,CAAC;IACb,GAAG,CAAC,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;IAC1B,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB;AAED;;;;;;GAMG;AACH,UAAU,WAAY,SAAQ,oBAAoB,CAAC,iBAAiB,CAAC;IACnE,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAaD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,iBAAS,KAAK,CAAC,KAAK,EAAE,QAAQ,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;AACzD,iBAAS,KAAK,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;kBAAnD,KAAK;;;AA0Id,OAAO,EAAE,KAAK,EAAE,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { Badge } from './Badge';
2
+ export { Badge };
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/badge/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,OAAO,EAAE,KAAK,EAAE,CAAC"}
@@ -0,0 +1,126 @@
1
+ import type { AnchorHTMLAttributes, ButtonHTMLAttributes, JSX, ReactNode, Ref } from 'react';
2
+ import type { IconDefinition } from '@fortawesome/free-solid-svg-icons';
3
+ /**
4
+ * Supported adornments for the Button component: either a FontAwesome icon or an image.
5
+ */
6
+ type ButtonAdornment = IconDefinition | ButtonImage;
7
+ interface ButtonClasses {
8
+ adornment?: string;
9
+ button?: string;
10
+ }
11
+ /**
12
+ * Image object for use as a button adornment.
13
+ *
14
+ * @property {string} [src] - Image source URL.
15
+ * @property {string} [alt] - Alternative text for the image.
16
+ */
17
+ interface ButtonImage {
18
+ src?: string;
19
+ alt?: string;
20
+ }
21
+ /**
22
+ * Supported button types for the native button element.
23
+ *
24
+ * - 'button': Standard button (default)
25
+ * - 'submit': Submits a form
26
+ * - 'reset': Resets a form
27
+ */
28
+ type ButtonType = 'button' | 'submit' | 'reset';
29
+ /**
30
+ * Size options for the Button component.
31
+ *
32
+ * - 'sm': Small
33
+ * - 'md': Medium
34
+ * - 'lg': Large
35
+ */
36
+ type ButtonSize = 'sm' | 'md' | 'lg';
37
+ /**
38
+ * Visual style variants for the Button component.
39
+ *
40
+ * - 'primary': Main action button
41
+ * - 'secondary': Secondary action button
42
+ * - 'text': Text-only button
43
+ * - 'outline': Outlined button
44
+ */
45
+ type ButtonVariant = 'primary' | 'secondary' | 'text' | 'outline';
46
+ /**
47
+ * Common props for the Button component, shared by both anchor and button variants.
48
+ */
49
+ interface BaseProps {
50
+ children?: ReactNode;
51
+ classes?: ButtonClasses;
52
+ endAdornment?: ButtonAdornment;
53
+ fullWidth?: boolean;
54
+ responsive?: boolean;
55
+ size?: ButtonSize;
56
+ startAdornment?: ButtonAdornment;
57
+ ref?: Ref<HTMLAnchorElement>;
58
+ variant?: ButtonVariant;
59
+ }
60
+ /**
61
+ * Props for the anchor variant of the Button component.
62
+ *
63
+ * @property {ReactNode} [children] - The content of the anchor.
64
+ * @property {string} href - The URL to link to (required for anchor usage).
65
+ * @property {'sm' | 'md' | 'lg'} [size] - The size of the anchor button.
66
+ * @property {never} [type] - Not allowed for anchor usage.
67
+ * @property {Ref<HTMLAnchorElement>} [ref] - Ref for the anchor element.
68
+ * @property {'primary' | 'secondary' | 'text' | 'outline'} [variant] - The visual style of the anchor button.
69
+ */
70
+ interface AnchorProps extends Omit<AnchorHTMLAttributes<HTMLAnchorElement>, 'className'> {
71
+ href: string;
72
+ ref?: Ref<HTMLAnchorElement>;
73
+ target?: string;
74
+ type?: never;
75
+ }
76
+ /**
77
+ * Props for the button variant of the Button component.
78
+ *
79
+ * @property {ReactNode} [children] - The content of the button.
80
+ * @property {never} [href] - Not allowed for button usage.
81
+ * @property {'sm' | 'md' | 'lg'} [size] - The size of the button.
82
+ * @property {ButtonType} [type] - The button type attribute.
83
+ * @property {Ref<HTMLButtonElement>} [ref] - Ref for the button element.
84
+ * @property {'primary' | 'secondary' | 'text' | 'outline'} [variant] - The visual style of the button.
85
+ */
86
+ interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'className'> {
87
+ href?: never;
88
+ ref?: Ref<HTMLButtonElement>;
89
+ target?: never;
90
+ type?: ButtonType;
91
+ }
92
+ /**
93
+ * Button component supporting both anchor (<a>) and button (<button>) variants.
94
+ *
95
+ * Renders a styled button or anchor element with optional start/end adornments (icon or image),
96
+ * supporting multiple visual variants and sizes. The element type is determined by the presence of the 'href' prop:
97
+ * - If 'href' is provided, renders an anchor (<a>).
98
+ * - Otherwise, renders a native button (<button>).
99
+ *
100
+ * @param {ButtonComponentProps} props - Button or anchor props.
101
+ * @returns {JSX.Element} The rendered button or anchor element.
102
+ *
103
+ * @example
104
+ * ```tsx
105
+ * import { Button } from '@/src';
106
+ * import { faCoffee } from '@fortawesome/free-solid-svg-icons';
107
+ *
108
+ * const MyButton = () => (
109
+ * <Button
110
+ * variant="primary"
111
+ * size="md"
112
+ * startAdornment={faCoffee}
113
+ * >
114
+ * Click Me
115
+ * </Button>
116
+ * );
117
+ * ```
118
+ */
119
+ declare function Button(props: AnchorProps & BaseProps): JSX.Element;
120
+ declare function Button(props: ButtonProps & BaseProps): JSX.Element;
121
+ declare namespace Button {
122
+ var displayName: string;
123
+ }
124
+ export { Button };
125
+ export type { ButtonAdornment, ButtonClasses, ButtonVariant };
126
+ //# sourceMappingURL=Button.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../src/buttons/Button.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAI7F,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAExE;;GAEG;AACH,KAAK,eAAe,GAAG,cAAc,GAAG,WAAW,CAAC;AAEpD,UAAU,aAAa;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;;;GAKG;AACH,UAAU,WAAW;IACnB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED;;;;;;GAMG;AACH,KAAK,UAAU,GAAG,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEhD;;;;;;GAMG;AACH,KAAK,UAAU,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAErC;;;;;;;GAOG;AACH,KAAK,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,MAAM,GAAG,SAAS,CAAC;AAqBlE;;GAEG;AACH,UAAU,SAAS;IACjB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,YAAY,CAAC,EAAE,eAAe,CAAC;IAC/B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,cAAc,CAAC,EAAE,eAAe,CAAC;IACjC,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,OAAO,CAAC,EAAE,aAAa,CAAC;CACzB;AAED;;;;;;;;;GASG;AACH,UAAU,WAAY,SAAQ,IAAI,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,WAAW,CAAC;IACtF,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,KAAK,CAAC;CACd;AAED;;;;;;;;;GASG;AACH,UAAU,WAAY,SAAQ,IAAI,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,WAAW,CAAC;IACtF,IAAI,CAAC,EAAE,KAAK,CAAC;IACb,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,MAAM,CAAC,EAAE,KAAK,CAAC;IACf,IAAI,CAAC,EAAE,UAAU,CAAC;CACnB;AAoCD;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,iBAAS,MAAM,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;AAC7D,iBAAS,MAAM,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;kBAApD,MAAM;;;AA4Ef,OAAO,EAAE,MAAM,EAAE,CAAC;AAClB,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,aAAa,EAAE,CAAC"}
@@ -0,0 +1,114 @@
1
+ import type { AnchorHTMLAttributes, ButtonHTMLAttributes, JSX, MouseEvent, ReactNode, Ref } from 'react';
2
+ import type { IconDefinition } from '@fortawesome/free-solid-svg-icons';
3
+ /**
4
+ * Adornment used by the Fab. Can be a Font Awesome `IconDefinition`
5
+ * (rendered via `FontAwesomeIcon`) or an image payload (`FabImage`).
6
+ */
7
+ type FabAdornment = IconDefinition | FabImage;
8
+ interface FabClasses {
9
+ adornment?: string;
10
+ button?: string;
11
+ }
12
+ /**
13
+ * Allowed color theme names for the Fab component.
14
+ */
15
+ type FabColor = 'primary' | 'secondary' | 'accent' | 'error' | 'info' | 'success' | 'warning';
16
+ /**
17
+ * Image payload for a Fab adornment.
18
+ * @property {string} src - Image source URL or path.
19
+ * @property {string} [alt] - Optional alt text for the image.
20
+ */
21
+ type FabImage = {
22
+ alt?: string;
23
+ src: string;
24
+ };
25
+ /**
26
+ * Variant of the Fab component.
27
+ * - 'circular': round icon-only floating action button.
28
+ * - 'extended': pill-shaped button that can contain text and icons.
29
+ */
30
+ type FabVariant = 'circular' | 'extended';
31
+ /**
32
+ * Common props shared between anchor and button variants of `Fab`.
33
+ */
34
+ interface BaseProps {
35
+ /** Content placed inside the button. */
36
+ children?: ReactNode;
37
+ /** Additional CSS classes to apply. */
38
+ classes?: FabClasses;
39
+ /** Color theme for the Fab. */
40
+ color?: FabColor;
41
+ /** Adornment rendered after the children. */
42
+ endAdornment?: FabAdornment;
43
+ /** Size variant for the Fab: 'sm' | 'md' | 'lg'. */
44
+ size?: 'sm' | 'md' | 'lg';
45
+ /** Adornment rendered before the children. */
46
+ startAdornment?: FabAdornment;
47
+ /** Visual variant of the Fab: 'circular' or 'extended'. */
48
+ variant?: FabVariant;
49
+ }
50
+ /**
51
+ * Props when the `Fab` is rendered as an anchor (`<a>`).
52
+ * Extends native anchor attributes but disallows `type`.
53
+ */
54
+ interface AnchorProps extends Omit<AnchorHTMLAttributes<HTMLAnchorElement>, 'className'> {
55
+ /** Destination URL for the anchor. */
56
+ href?: string;
57
+ /** Click handler when rendered as an anchor. */
58
+ onClick?: (event: MouseEvent<HTMLAnchorElement>) => void;
59
+ /** Ref forwarded to the anchor element. */
60
+ ref?: Ref<HTMLAnchorElement>;
61
+ /** Link target (for example, '_blank'). */
62
+ target?: string;
63
+ /** Explicitly disallowed on the anchor variant. */
64
+ type?: never;
65
+ }
66
+ /**
67
+ * Props when the `Fab` is rendered as a button (`<button>`).
68
+ * Extends native button attributes but disallows `href` and `target`.
69
+ */
70
+ interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'className'> {
71
+ /** Explicitly disallowed on the button variant. */
72
+ href?: never;
73
+ /** Click handler when rendered as a button. */
74
+ onClick?: (event: MouseEvent<HTMLButtonElement>) => void;
75
+ /** Ref forwarded to the button element. */
76
+ ref?: Ref<HTMLButtonElement>;
77
+ /** Target is not applicable for button elements. */
78
+ target?: never;
79
+ /** Button `type` attribute (e.g. 'button' | 'submit' | 'reset'). */
80
+ type?: ButtonHTMLAttributes<HTMLButtonElement>['type'];
81
+ }
82
+ /**
83
+ * Floating Action Button (`Fab`) component.
84
+ * Renders either an anchor (`<a>`) when `href` is provided, or a native
85
+ * button (`<button>`) otherwise. Supports start/end adornments and
86
+ * multiple visual variants and sizes.
87
+ * @param {FabProps} props - Props for the Fab component (anchor or button variant).
88
+ * @returns {JSX.Element} The rendered Fab element.
89
+ *
90
+ * @example
91
+ * ```tsx
92
+ * import { Fab } from '@/src';
93
+ * import { faPlus } from '@fortawesome/free-solid-svg-icons';
94
+ *
95
+ * const MyComponent = () => (
96
+ * <Fab
97
+ * color="primary"
98
+ * variant="extended"
99
+ * startAdornment={faPlus}
100
+ * onClick={() => console.log('Fab clicked!')}
101
+ * >
102
+ * Add Item
103
+ *. </Fab>
104
+ * );
105
+ * ```
106
+ */
107
+ declare function Fab(props: AnchorProps & BaseProps): JSX.Element;
108
+ declare function Fab(props: ButtonProps & BaseProps): JSX.Element;
109
+ declare namespace Fab {
110
+ var displayName: string;
111
+ }
112
+ export { Fab };
113
+ export type { FabClasses };
114
+ //# sourceMappingURL=Fab.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Fab.d.ts","sourceRoot":"","sources":["../../../src/buttons/Fab.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,oBAAoB,EACpB,oBAAoB,EACpB,GAAG,EACH,UAAU,EACV,SAAS,EACT,GAAG,EACJ,MAAM,OAAO,CAAC;AACf,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAKxE;;;GAGG;AACH,KAAK,YAAY,GAAG,cAAc,GAAG,QAAQ,CAAC;AAE9C,UAAU,UAAU;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,KAAK,QAAQ,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,CAAC;AAE9F;;;;GAIG;AACH,KAAK,QAAQ,GAAG;IAAE,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAC;AAE9C;;;;GAIG;AACH,KAAK,UAAU,GAAG,UAAU,GAAG,UAAU,CAAC;AAE1C;;GAEG;AACH,UAAU,SAAS;IACjB,wCAAwC;IACxC,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,uCAAuC;IACvC,OAAO,CAAC,EAAE,UAAU,CAAC;IACrB,+BAA+B;IAC/B,KAAK,CAAC,EAAE,QAAQ,CAAC;IACjB,6CAA6C;IAC7C,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,oDAAoD;IACpD,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC1B,8CAA8C;IAC9C,cAAc,CAAC,EAAE,YAAY,CAAC;IAC9B,2DAA2D;IAC3D,OAAO,CAAC,EAAE,UAAU,CAAC;CACtB;AAED;;;GAGG;AACH,UAAU,WAAY,SAAQ,IAAI,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,WAAW,CAAC;IACtF,sCAAsC;IACtC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,gDAAgD;IAChD,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;IACzD,2CAA2C;IAC3C,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,2CAA2C;IAC3C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,mDAAmD;IACnD,IAAI,CAAC,EAAE,KAAK,CAAC;CACd;AAED;;;GAGG;AACH,UAAU,WAAY,SAAQ,IAAI,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,WAAW,CAAC;IACtF,mDAAmD;IACnD,IAAI,CAAC,EAAE,KAAK,CAAC;IACb,+CAA+C;IAC/C,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;IACzD,2CAA2C;IAC3C,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,oDAAoD;IACpD,MAAM,CAAC,EAAE,KAAK,CAAC;IACf,oEAAoE;IACpE,IAAI,CAAC,EAAE,oBAAoB,CAAC,iBAAiB,CAAC,CAAC,MAAM,CAAC,CAAC;CACxD;AAiCD;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,iBAAS,GAAG,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;AAC1D,iBAAS,GAAG,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;kBAAjD,GAAG;;;AAuFZ,OAAO,EAAE,GAAG,EAAE,CAAC;AACf,YAAY,EAAE,UAAU,EAAE,CAAC"}
@@ -0,0 +1,105 @@
1
+ import type { AnchorHTMLAttributes, ButtonHTMLAttributes, JSX, MouseEvent, ReactElement, Ref } from 'react';
2
+ import type { IconDefinition } from '@fortawesome/free-solid-svg-icons';
3
+ /** Child content supported by the icon button. */
4
+ type IconButtonChildren = IconDefinition | ReactElement;
5
+ /** Optional class name hooks for the icon button internals. */
6
+ interface IconButtonClasses {
7
+ /** Class names applied to the rendered child icon or image. */
8
+ children?: string;
9
+ /** Class names applied to the outer button or anchor element. */
10
+ iconButton?: string;
11
+ }
12
+ /**
13
+ * Color options for the IconButton component.
14
+ *
15
+ * - 'primary': Primary color style
16
+ * - 'secondary': Secondary color style
17
+ * - 'accent': Accent color style
18
+ */
19
+ type IconButtonColor = 'primary' | 'secondary' | 'accent';
20
+ /**
21
+ * Size options for the IconButton component.
22
+ *
23
+ * - 'sm': Small
24
+ * - 'md': Medium
25
+ * - 'lg': Large
26
+ */
27
+ type IconButtonSize = 'sm' | 'md' | 'lg';
28
+ /**
29
+ * Visual style variants for the IconButton component.
30
+ *
31
+ * - 'outline': Bordered, transparent background
32
+ * - 'filled': Solid background
33
+ */
34
+ type IconButtonVariant = 'outline' | 'filled';
35
+ /** Shared props for both anchor and button variants. */
36
+ interface BaseProps {
37
+ /** Icon or custom element rendered inside the control. */
38
+ children?: IconButtonChildren;
39
+ /** Optional class name hooks for inner and outer styling. */
40
+ classes?: IconButtonClasses;
41
+ /** Color token for the button styling. */
42
+ color?: IconButtonColor;
43
+ /** Size token controlling the visual scale of the control. */
44
+ size?: IconButtonSize;
45
+ /** Visual style variant for the control. */
46
+ variant?: IconButtonVariant;
47
+ }
48
+ /** Props for the anchor variant of the IconButton component. */
49
+ interface AnchorProps extends Omit<AnchorHTMLAttributes<HTMLAnchorElement>, 'children' | 'className'> {
50
+ /** Destination URL for the anchor variant. */
51
+ href?: string;
52
+ /** Click handler for the anchor variant. */
53
+ onClick?: (event: MouseEvent<HTMLAnchorElement>) => void;
54
+ /** Optional ref forwarded to the anchor element. */
55
+ ref?: Ref<HTMLAnchorElement>;
56
+ /** Optional target for the anchor element. */
57
+ target?: string;
58
+ }
59
+ /** Props for the button variant of the IconButton component. */
60
+ interface ButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'children' | 'className'> {
61
+ /** Disallowed for the button variant. */
62
+ href?: never;
63
+ /** Click handler for the button variant. */
64
+ onClick?: (event: MouseEvent<HTMLButtonElement>) => void;
65
+ /** Optional ref forwarded to the button element. */
66
+ ref?: Ref<HTMLButtonElement>;
67
+ /** Disallowed for the button variant. */
68
+ target?: never;
69
+ }
70
+ /**
71
+ * IconButton component.
72
+ *
73
+ * Renders a styled button or anchor containing a FontAwesome icon, supporting different sizes, variants, and color styles.
74
+ * The element type is determined by the presence of the 'href' prop:
75
+ * - If 'href' is provided, renders an anchor (<a>).
76
+ * - Otherwise, renders a native button (<button>).
77
+ *
78
+ * @param {AnchorProps | ButtonProps} props - Props for the anchor or button variant.
79
+ * @returns {JSX.Element} The rendered icon button element.
80
+ *
81
+ * @example
82
+ * ```tsx
83
+ * import { IconButton } from '@/src';
84
+ * import { faCoffee } from '@fortawesome/free-solid-svg-icons';
85
+ *
86
+ * const MyIconButton = () => (
87
+ * <IconButton
88
+ * color="primary"
89
+ * size="md"
90
+ * variant="outline"
91
+ * onClick={() => alert('Icon button clicked!')}
92
+ * >
93
+ * faCoffee
94
+ * </IconButton>
95
+ * );
96
+ * ```
97
+ */
98
+ declare function IconButton(props: AnchorProps & BaseProps): JSX.Element;
99
+ declare function IconButton(props: ButtonProps & BaseProps): JSX.Element;
100
+ declare namespace IconButton {
101
+ var displayName: string;
102
+ }
103
+ export { IconButton };
104
+ export type { IconButtonClasses, IconButtonVariant };
105
+ //# sourceMappingURL=IconButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IconButton.d.ts","sourceRoot":"","sources":["../../../src/buttons/IconButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,oBAAoB,EACpB,oBAAoB,EACpB,GAAG,EACH,UAAU,EACV,YAAY,EACZ,GAAG,EACJ,MAAM,OAAO,CAAC;AAEf,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAKxE,kDAAkD;AAClD,KAAK,kBAAkB,GAAG,cAAc,GAAG,YAAY,CAAC;AAExD,+DAA+D;AAC/D,UAAU,iBAAiB;IACzB,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,iEAAiE;IACjE,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;;;;GAMG;AACH,KAAK,eAAe,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,CAAC;AAE1D;;;;;;GAMG;AACH,KAAK,cAAc,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAEzC;;;;;GAKG;AACH,KAAK,iBAAiB,GAAG,SAAS,GAAG,QAAQ,CAAC;AAU9C,wDAAwD;AACxD,UAAU,SAAS;IACjB,0DAA0D;IAC1D,QAAQ,CAAC,EAAE,kBAAkB,CAAC;IAC9B,6DAA6D;IAC7D,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B,0CAA0C;IAC1C,KAAK,CAAC,EAAE,eAAe,CAAC;IACxB,8DAA8D;IAC9D,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,4CAA4C;IAC5C,OAAO,CAAC,EAAE,iBAAiB,CAAC;CAC7B;AAED,gEAAgE;AAChE,UAAU,WAAY,SAAQ,IAAI,CAChC,oBAAoB,CAAC,iBAAiB,CAAC,EACvC,UAAU,GAAG,WAAW,CACzB;IACC,8CAA8C;IAC9C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,4CAA4C;IAC5C,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;IACzD,oDAAoD;IACpD,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,8CAA8C;IAC9C,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,gEAAgE;AAChE,UAAU,WAAY,SAAQ,IAAI,CAChC,oBAAoB,CAAC,iBAAiB,CAAC,EACvC,UAAU,GAAG,WAAW,CACzB;IACC,yCAAyC;IACzC,IAAI,CAAC,EAAE,KAAK,CAAC;IACb,4CAA4C;IAC5C,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;IACzD,oDAAoD;IACpD,GAAG,CAAC,EAAE,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAC7B,yCAAyC;IACzC,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB;AAoCD;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,iBAAS,UAAU,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;AACjE,iBAAS,UAAU,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC;kBAAxD,UAAU;;;AAyEnB,OAAO,EAAE,UAAU,EAAE,CAAC;AACtB,YAAY,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { Button } from './Button';
2
+ import type { ButtonAdornment, ButtonClasses, ButtonVariant } from './Button';
3
+ import { IconButton } from './IconButton';
4
+ import type { IconButtonClasses, IconButtonVariant } from './IconButton';
5
+ import { Fab } from './Fab';
6
+ import type { FabClasses } from './Fab';
7
+ export { Button, Fab, IconButton };
8
+ export type { ButtonAdornment, ButtonClasses, ButtonVariant, FabClasses, IconButtonClasses, IconButtonVariant, };
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/buttons/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,KAAK,EAAE,eAAe,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAC9E,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,KAAK,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACzE,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,EAAE,CAAC;AACnC,YAAY,EACV,eAAe,EACf,aAAa,EACb,aAAa,EACb,UAAU,EACV,iBAAiB,EACjB,iBAAiB,GAClB,CAAC"}
@@ -0,0 +1,35 @@
1
+ import type { FC, HTMLAttributes, ReactNode, Ref } from 'react';
2
+ /**
3
+ * Props for the Card component.
4
+ *
5
+ * @property {ReactNode} [children] - Card content, typically Header, Media, and Footer components.
6
+ * @property {Ref<HTMLDivElement>} [ref] - Ref for the card container div.
7
+ */
8
+ interface CardProps extends HTMLAttributes<HTMLDivElement> {
9
+ children?: ReactNode;
10
+ ref?: Ref<HTMLDivElement>;
11
+ }
12
+ /**
13
+ * Card component for displaying content with optional Header, Media, and Footer slots.
14
+ *
15
+ * Automatically detects and arranges Header, Media, and Footer children. If Media is present without Header or Footer, it adds headerless/footerless props for styling.
16
+ *
17
+ * @param {CardProps} props - Props for configuring the card container and its children.
18
+ * @returns {JSX.Element} The rendered card component.
19
+ *
20
+ * @example
21
+ * ```tsx
22
+ * import { Card, Header, Media, Footer } from '@/src';
23
+ *
24
+ * const MyCard = () => (
25
+ * <Card>
26
+ * <Header title="Card Title" subtitle="Card Subtitle" />
27
+ * <Media src="/path/to/image.jpg" alt="Card Image" />
28
+ * <Footer actions={[{ label: 'Action', onClick: () => { console.log('Action clicked'); } }]} />
29
+ * </Card>
30
+ * );
31
+ * ```
32
+ */
33
+ declare const Card: FC<CardProps>;
34
+ export { Card };
35
+ //# sourceMappingURL=Card.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Card.d.ts","sourceRoot":"","sources":["../../../src/card/Card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAkB,EAAE,EAAE,cAAc,EAAgB,SAAS,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAM9F;;;;;GAKG;AACH,UAAU,SAAU,SAAQ,cAAc,CAAC,cAAc,CAAC;IACxD,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,GAAG,CAAC,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;CAC3B;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,QAAA,MAAM,IAAI,EAAE,EAAE,CAAC,SAAS,CA0CvB,CAAC;AAIF,OAAO,EAAE,IAAI,EAAE,CAAC"}