@arkyn/components 3.0.1-beta.142 → 3.0.1-beta.144

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 (207) hide show
  1. package/dist/bundle.css +1 -1
  2. package/dist/components/alert/alertContainer/index.d.ts +27 -43
  3. package/dist/components/alert/alertContainer/index.d.ts.map +1 -1
  4. package/dist/components/alert/alertContainer/index.js +20 -40
  5. package/dist/components/alert/alertContent/index.d.ts +11 -36
  6. package/dist/components/alert/alertContent/index.d.ts.map +1 -1
  7. package/dist/components/alert/alertContent/index.js +11 -31
  8. package/dist/components/alert/alertDescription/index.d.ts +10 -38
  9. package/dist/components/alert/alertDescription/index.d.ts.map +1 -1
  10. package/dist/components/alert/alertDescription/index.js +10 -33
  11. package/dist/components/alert/alertIcon/index.d.ts +14 -38
  12. package/dist/components/alert/alertIcon/index.d.ts.map +1 -1
  13. package/dist/components/alert/alertIcon/index.js +14 -32
  14. package/dist/components/alert/alertTitle/index.d.ts +12 -35
  15. package/dist/components/alert/alertTitle/index.d.ts.map +1 -1
  16. package/dist/components/alert/alertTitle/index.js +12 -27
  17. package/dist/components/audioPlayer/index.d.ts +24 -32
  18. package/dist/components/audioPlayer/index.d.ts.map +1 -1
  19. package/dist/components/audioPlayer/index.js +15 -18
  20. package/dist/components/audioUpload/index.d.ts +37 -48
  21. package/dist/components/audioUpload/index.d.ts.map +1 -1
  22. package/dist/components/audioUpload/index.js +23 -48
  23. package/dist/components/badge/index.d.ts +31 -22
  24. package/dist/components/badge/index.d.ts.map +1 -1
  25. package/dist/components/badge/index.js +14 -22
  26. package/dist/components/button/index.d.ts +38 -28
  27. package/dist/components/button/index.d.ts.map +1 -1
  28. package/dist/components/button/index.js +18 -28
  29. package/dist/components/cardTab/cardTabButton/index.d.ts +14 -52
  30. package/dist/components/cardTab/cardTabButton/index.d.ts.map +1 -1
  31. package/dist/components/cardTab/cardTabButton/index.js +12 -52
  32. package/dist/components/cardTab/cardTabContainer/index.d.ts +16 -58
  33. package/dist/components/cardTab/cardTabContainer/index.d.ts.map +1 -1
  34. package/dist/components/cardTab/cardTabContainer/index.js +12 -58
  35. package/dist/components/checkbox/index.d.ts +38 -37
  36. package/dist/components/checkbox/index.d.ts.map +1 -1
  37. package/dist/components/checkbox/index.js +21 -37
  38. package/dist/components/clientOnly.d.ts +13 -66
  39. package/dist/components/clientOnly.d.ts.map +1 -1
  40. package/dist/components/clientOnly.js +11 -66
  41. package/dist/components/currencyInput/index.d.ts +67 -50
  42. package/dist/components/currencyInput/index.d.ts.map +1 -1
  43. package/dist/components/currencyInput/index.js +28 -50
  44. package/dist/components/divider/index.d.ts +12 -25
  45. package/dist/components/divider/index.d.ts.map +1 -1
  46. package/dist/components/divider/index.js +8 -25
  47. package/dist/components/drawer/drawerContainer/index.d.ts +16 -50
  48. package/dist/components/drawer/drawerContainer/index.d.ts.map +1 -1
  49. package/dist/components/drawer/drawerContainer/index.js +13 -50
  50. package/dist/components/drawer/drawerHeader/index.d.ts +9 -33
  51. package/dist/components/drawer/drawerHeader/index.d.ts.map +1 -1
  52. package/dist/components/drawer/drawerHeader/index.js +8 -33
  53. package/dist/components/facebookPixel/index.d.ts +47 -0
  54. package/dist/components/facebookPixel/index.d.ts.map +1 -1
  55. package/dist/components/facebookPixel/index.js +35 -0
  56. package/dist/components/fieldError/index.d.ts +4 -11
  57. package/dist/components/fieldError/index.d.ts.map +1 -1
  58. package/dist/components/fieldError/index.js +4 -11
  59. package/dist/components/fieldLabel/index.d.ts +6 -21
  60. package/dist/components/fieldLabel/index.d.ts.map +1 -1
  61. package/dist/components/fieldLabel/index.js +5 -21
  62. package/dist/components/fieldWrapper/index.d.ts +12 -22
  63. package/dist/components/fieldWrapper/index.d.ts.map +1 -1
  64. package/dist/components/fieldWrapper/index.js +7 -22
  65. package/dist/components/fileUpload/index.d.ts +36 -61
  66. package/dist/components/fileUpload/index.d.ts.map +1 -1
  67. package/dist/components/fileUpload/index.js +23 -61
  68. package/dist/components/googleAnalytics/index.d.ts +11 -7
  69. package/dist/components/googleAnalytics/index.d.ts.map +1 -1
  70. package/dist/components/googleAnalytics/index.js +9 -7
  71. package/dist/components/googleTagManager/index.d.ts +27 -21
  72. package/dist/components/googleTagManager/index.d.ts.map +1 -1
  73. package/dist/components/googleTagManager/index.js +20 -21
  74. package/dist/components/iconButton/index.d.ts +31 -15
  75. package/dist/components/iconButton/index.d.ts.map +1 -1
  76. package/dist/components/iconButton/index.js +12 -15
  77. package/dist/components/imageUpload/index.d.ts +47 -75
  78. package/dist/components/imageUpload/index.d.ts.map +1 -1
  79. package/dist/components/imageUpload/index.js +27 -75
  80. package/dist/components/input/index.d.ts +51 -44
  81. package/dist/components/input/index.d.ts.map +1 -1
  82. package/dist/components/input/index.js +24 -44
  83. package/dist/components/mapView/index.d.ts +44 -0
  84. package/dist/components/mapView/index.d.ts.map +1 -1
  85. package/dist/components/mapView/index.js +35 -0
  86. package/dist/components/maskedInput/index.d.ts +66 -51
  87. package/dist/components/maskedInput/index.d.ts.map +1 -1
  88. package/dist/components/maskedInput/index.js +28 -51
  89. package/dist/components/modal/modalContainer/index.d.ts +17 -57
  90. package/dist/components/modal/modalContainer/index.d.ts.map +1 -1
  91. package/dist/components/modal/modalContainer/index.js +15 -57
  92. package/dist/components/modal/modalFooter/index.d.ts +17 -50
  93. package/dist/components/modal/modalFooter/index.d.ts.map +1 -1
  94. package/dist/components/modal/modalFooter/index.js +10 -50
  95. package/dist/components/modal/modalHeader/index.d.ts +13 -47
  96. package/dist/components/modal/modalHeader/index.d.ts.map +1 -1
  97. package/dist/components/modal/modalHeader/index.js +12 -47
  98. package/dist/components/multiSelect/index.d.ts +67 -62
  99. package/dist/components/multiSelect/index.d.ts.map +1 -1
  100. package/dist/components/multiSelect/index.js +28 -62
  101. package/dist/components/pagination/index.d.ts +18 -9
  102. package/dist/components/pagination/index.d.ts.map +1 -1
  103. package/dist/components/pagination/index.js +18 -9
  104. package/dist/components/phoneInput/index.d.ts +65 -30
  105. package/dist/components/phoneInput/index.d.ts.map +1 -1
  106. package/dist/components/phoneInput/index.js +35 -30
  107. package/dist/components/popover/index.d.ts +34 -114
  108. package/dist/components/popover/index.d.ts.map +1 -1
  109. package/dist/components/popover/index.js +25 -114
  110. package/dist/components/radio/radioBox/index.d.ts +17 -65
  111. package/dist/components/radio/radioBox/index.d.ts.map +1 -1
  112. package/dist/components/radio/radioBox/index.js +14 -65
  113. package/dist/components/radio/radioGroup/index.d.ts +36 -67
  114. package/dist/components/radio/radioGroup/index.d.ts.map +1 -1
  115. package/dist/components/radio/radioGroup/index.js +25 -67
  116. package/dist/components/richText/index.d.ts +33 -47
  117. package/dist/components/richText/index.d.ts.map +1 -1
  118. package/dist/components/richText/index.js +30 -44
  119. package/dist/components/searchPlaces.d.ts +52 -50
  120. package/dist/components/searchPlaces.d.ts.map +1 -1
  121. package/dist/components/searchPlaces.js +23 -30
  122. package/dist/components/select/index.d.ts +68 -63
  123. package/dist/components/select/index.d.ts.map +1 -1
  124. package/dist/components/select/index.js +29 -63
  125. package/dist/components/slider/index.d.ts +20 -34
  126. package/dist/components/slider/index.d.ts.map +1 -1
  127. package/dist/components/slider/index.js +15 -33
  128. package/dist/components/switch/index.d.ts +42 -58
  129. package/dist/components/switch/index.d.ts.map +1 -1
  130. package/dist/components/switch/index.js +24 -58
  131. package/dist/components/tab/tabButton/index.d.ts +14 -52
  132. package/dist/components/tab/tabButton/index.d.ts.map +1 -1
  133. package/dist/components/tab/tabButton/index.js +12 -52
  134. package/dist/components/tab/tabContainer/index.d.ts +16 -58
  135. package/dist/components/tab/tabContainer/index.d.ts.map +1 -1
  136. package/dist/components/tab/tabContainer/index.js +12 -58
  137. package/dist/components/table/tableBody/index.d.ts +13 -47
  138. package/dist/components/table/tableBody/index.d.ts.map +1 -1
  139. package/dist/components/table/tableBody/index.js +12 -47
  140. package/dist/components/table/tableCaption/index.d.ts +6 -46
  141. package/dist/components/table/tableCaption/index.d.ts.map +1 -1
  142. package/dist/components/table/tableCaption/index.js +6 -46
  143. package/dist/components/table/tableContainer/index.d.ts +12 -41
  144. package/dist/components/table/tableContainer/index.d.ts.map +1 -1
  145. package/dist/components/table/tableContainer/index.js +12 -41
  146. package/dist/components/table/tableFooter/index.d.ts +5 -29
  147. package/dist/components/table/tableFooter/index.d.ts.map +1 -1
  148. package/dist/components/table/tableFooter/index.js +5 -29
  149. package/dist/components/table/tableHeader/index.d.ts +4 -25
  150. package/dist/components/table/tableHeader/index.d.ts.map +1 -1
  151. package/dist/components/table/tableHeader/index.js +4 -25
  152. package/dist/components/textarea/index.d.ts +32 -64
  153. package/dist/components/textarea/index.d.ts.map +1 -1
  154. package/dist/components/textarea/index.js +16 -64
  155. package/dist/components/tooltip/index.d.ts +27 -55
  156. package/dist/components/tooltip/index.d.ts.map +1 -1
  157. package/dist/components/tooltip/index.js +16 -55
  158. package/dist/hooks/useAutomation.d.ts +18 -26
  159. package/dist/hooks/useAutomation.d.ts.map +1 -1
  160. package/dist/hooks/useAutomation.js +18 -26
  161. package/dist/hooks/useDrawer.d.ts +19 -64
  162. package/dist/hooks/useDrawer.d.ts.map +1 -1
  163. package/dist/hooks/useForm.d.ts +12 -29
  164. package/dist/hooks/useForm.d.ts.map +1 -1
  165. package/dist/hooks/useForm.js +12 -29
  166. package/dist/hooks/useHydrated.d.ts +8 -63
  167. package/dist/hooks/useHydrated.d.ts.map +1 -1
  168. package/dist/hooks/useHydrated.js +8 -63
  169. package/dist/hooks/useModal.d.ts +19 -59
  170. package/dist/hooks/useModal.d.ts.map +1 -1
  171. package/dist/hooks/useScopedParams.d.ts +17 -69
  172. package/dist/hooks/useScopedParams.d.ts.map +1 -1
  173. package/dist/hooks/useScopedParams.js +17 -69
  174. package/dist/hooks/useScrollLock.d.ts +11 -27
  175. package/dist/hooks/useScrollLock.d.ts.map +1 -1
  176. package/dist/hooks/useScrollLock.js +11 -33
  177. package/dist/hooks/useSearchAutomation.d.ts +16 -34
  178. package/dist/hooks/useSearchAutomation.d.ts.map +1 -1
  179. package/dist/hooks/useSearchAutomation.js +16 -34
  180. package/dist/hooks/useSlider.d.ts +5 -19
  181. package/dist/hooks/useSlider.d.ts.map +1 -1
  182. package/dist/hooks/useSlider.js +5 -19
  183. package/dist/hooks/useToast.d.ts +8 -52
  184. package/dist/hooks/useToast.d.ts.map +1 -1
  185. package/dist/hooks/useToast.js +8 -52
  186. package/dist/providers/drawerProvider.d.ts +15 -81
  187. package/dist/providers/drawerProvider.d.ts.map +1 -1
  188. package/dist/providers/drawerProvider.js +15 -81
  189. package/dist/providers/formProvider.d.ts +17 -53
  190. package/dist/providers/formProvider.d.ts.map +1 -1
  191. package/dist/providers/formProvider.js +17 -53
  192. package/dist/providers/modalProvider.d.ts +16 -77
  193. package/dist/providers/modalProvider.d.ts.map +1 -1
  194. package/dist/providers/modalProvider.js +16 -77
  195. package/dist/providers/placesProvider.d.ts +16 -11
  196. package/dist/providers/placesProvider.d.ts.map +1 -1
  197. package/dist/providers/placesProvider.js +16 -11
  198. package/dist/providers/toastProvider.d.ts +10 -21
  199. package/dist/providers/toastProvider.d.ts.map +1 -1
  200. package/dist/providers/toastProvider.js +10 -21
  201. package/dist/services/toHtml.d.ts +11 -10
  202. package/dist/services/toHtml.d.ts.map +1 -1
  203. package/dist/services/toHtml.js +11 -10
  204. package/dist/services/toRichTextValue.d.ts +11 -17
  205. package/dist/services/toRichTextValue.d.ts.map +1 -1
  206. package/dist/services/toRichTextValue.js +11 -17
  207. package/package.json +1 -1
@@ -2,61 +2,41 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { createContext, useContext, } from "react";
3
3
  import { AlertTitle } from "../alertTitle";
4
4
  import "./styles.css";
5
- /**
6
- * Context for sharing alert container properties with child components
7
- * @internal
8
- */
9
5
  const AlertContainerContext = createContext({});
10
- /**
11
- * Custom hook to access the AlertContainer context
12
- *
13
- * @returns {AlertContainerProps} The current alert container properties including schema and HTML attributes
14
- *
15
- * @example
16
- * function CustomAlertContent() {
17
- * const { schema } = useAlertContainer();
18
- * return <div>Current schema: {schema}</div>;
19
- * }
20
- */
6
+ /** @internal Accesses the schema and HTML props of the enclosing `AlertContainer`. */
21
7
  function useAlertContainer() {
22
8
  return useContext(AlertContainerContext);
23
9
  }
24
10
  /**
25
- * AlertContainer - A flexible alert component that displays messages with different visual styles
26
- *
27
- * This component automatically adjusts its layout based on whether an AlertTitle component
28
- * is present among its children. When AlertTitle is detected, the content is left-aligned;
29
- * otherwise, it's centered.
11
+ * AlertContainer root wrapper for the Alert component set. Provides schema context to child components.
30
12
  *
31
- * @component
32
- * @memberof Alert
13
+ * Automatically detects whether an `AlertTitle` is present among children and adjusts layout:
14
+ * centered when no title, left-aligned when a title is present.
33
15
  *
34
- * @param {AlertContainerProps} props - Component properties
35
- * @param {"success" | "danger" | "warning" | "info"} props.schema - Determines the visual styling and semantic meaning of the alert
36
- * @param {ReactNode} props.children - Content to be rendered inside the alert, can include AlertTitle and other components
37
- * @param {string} [props.className] - Additional CSS classes to customize the alert appearance
16
+ * @param props.schema - Visual style variant. Required.
17
+ * @param props.children - Alert sub-components: `AlertIcon`, `AlertContent`, `AlertTitle`, `AlertDescription`.
38
18
  *
39
- * @returns {JSX.Element} A styled alert container with context provider for child components
19
+ * **...Other valid HTML properties for `<div>`**
40
20
  *
41
- * @requires react - For createContext, useContext, ReactNode
21
+ * @returns AlertContainer JSX element.
42
22
  *
43
23
  * @example
44
- * // Basic usage
24
+ * ```tsx
25
+ * // Inline alert — no title, centered layout
45
26
  * <AlertContainer schema="success">
46
- * {children}
27
+ * <AlertIcon />
28
+ * <AlertContent>Your subscription has been activated.</AlertContent>
47
29
  * </AlertContainer>
48
30
  *
49
- * @example
50
- * // Complete alert example
51
- * <AlertContainer schema="success">
52
- * <AlertIcon />
53
- * <AlertContent>
54
- * <AlertTitle>Success!</AlertTitle>
55
- * <AlertDescription>
56
- * You are premium user now!
57
- * </AlertDescription>
58
- * </AlertContent>
31
+ * // Full alert with title and description — left-aligned layout
32
+ * <AlertContainer schema="danger">
33
+ * <AlertIcon />
34
+ * <AlertContent>
35
+ * <AlertTitle>Payment failed</AlertTitle>
36
+ * <AlertDescription>Please check your card details and try again.</AlertDescription>
37
+ * </AlertContent>
59
38
  * </AlertContainer>
39
+ * ```
60
40
  */
61
41
  function AlertContainer(props) {
62
42
  const { schema, children, className: baseClassName, ...rest } = props;
@@ -1,48 +1,23 @@
1
1
  import { HTMLAttributes, JSX } from "react";
2
2
  import "./styles.css";
3
- /**
4
- * @typedef {Object} AlertContentProps
5
- * @extends {HTMLAttributes<HTMLDivElement>}
6
- * @description Props for the AlertContent component, extending standard HTML div attributes.
7
- */
8
3
  type AlertContentProps = HTMLAttributes<HTMLDivElement>;
9
4
  /**
10
- * AlertContent component that renders the main content area of an alert.
11
- *
12
- * @component
13
- * @memberof Alert
14
- *
15
- * @description
16
- * This component serves as a container for the main content within an Alert component.
17
- * Supports all standard HTML div attributes for maximum flexibility.
5
+ * AlertContent text/content area inside an `AlertContainer`. Wraps `AlertTitle` and `AlertDescription`.
18
6
  *
19
- * @param {AlertContentProps} props - Component props extending HTMLDivElement attributes
20
- * @param {string} [props.className] - Additional CSS classes to apply to the content container
21
- * @param {React.ReactNode} [props.children] - Content to be displayed inside the alert
7
+ * Accepts all standard `<div>` HTML attributes.
22
8
  *
23
- * @returns {JSX.Element} A div element with the alert content styling
24
- *
25
- * @requires react
26
- *
27
- * @example
28
- * // Basic usage
29
- * <AlertContainer schema="success">
30
- * <AlertContent>
31
- * {children}
32
- * </AlertContent>
33
- * </AlertContainer>
9
+ * @returns AlertContent JSX element.
34
10
  *
35
11
  * @example
36
- * // Complete alert example
37
- * <AlertContainer schema="success">
38
- * <AlertIcon />
39
- * <AlertContent>
40
- * <AlertTitle>Success!</AlertTitle>
41
- * <AlertDescription>
42
- * You are premium user now!
43
- * </AlertDescription>
44
- * </AlertContent>
12
+ * ```tsx
13
+ * <AlertContainer schema="warning">
14
+ * <AlertIcon />
15
+ * <AlertContent>
16
+ * <AlertTitle>Session expiring</AlertTitle>
17
+ * <AlertDescription>You will be logged out in 5 minutes.</AlertDescription>
18
+ * </AlertContent>
45
19
  * </AlertContainer>
20
+ * ```
46
21
  */
47
22
  declare function AlertContent(props: AlertContentProps): JSX.Element;
48
23
  export { AlertContent };
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertContent/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,cAAc,CAAC;AAEtB;;;;GAIG;AACH,KAAK,iBAAiB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAExD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AAEH,iBAAS,YAAY,CAAC,KAAK,EAAE,iBAAiB,GAAG,GAAG,CAAC,OAAO,CAK3D;AAED,OAAO,EAAE,YAAY,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertContent/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,cAAc,CAAC;AAEtB,KAAK,iBAAiB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAExD;;;;;;;;;;;;;;;;;GAiBG;AAEH,iBAAS,YAAY,CAAC,KAAK,EAAE,iBAAiB,GAAG,GAAG,CAAC,OAAO,CAK3D;AAED,OAAO,EAAE,YAAY,EAAE,CAAC"}
@@ -1,42 +1,22 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "./styles.css";
3
3
  /**
4
- * AlertContent component that renders the main content area of an alert.
4
+ * AlertContent text/content area inside an `AlertContainer`. Wraps `AlertTitle` and `AlertDescription`.
5
5
  *
6
- * @component
7
- * @memberof Alert
6
+ * Accepts all standard `<div>` HTML attributes.
8
7
  *
9
- * @description
10
- * This component serves as a container for the main content within an Alert component.
11
- * Supports all standard HTML div attributes for maximum flexibility.
12
- *
13
- * @param {AlertContentProps} props - Component props extending HTMLDivElement attributes
14
- * @param {string} [props.className] - Additional CSS classes to apply to the content container
15
- * @param {React.ReactNode} [props.children] - Content to be displayed inside the alert
16
- *
17
- * @returns {JSX.Element} A div element with the alert content styling
18
- *
19
- * @requires react
20
- *
21
- * @example
22
- * // Basic usage
23
- * <AlertContainer schema="success">
24
- * <AlertContent>
25
- * {children}
26
- * </AlertContent>
27
- * </AlertContainer>
8
+ * @returns AlertContent JSX element.
28
9
  *
29
10
  * @example
30
- * // Complete alert example
31
- * <AlertContainer schema="success">
32
- * <AlertIcon />
33
- * <AlertContent>
34
- * <AlertTitle>Success!</AlertTitle>
35
- * <AlertDescription>
36
- * You are premium user now!
37
- * </AlertDescription>
38
- * </AlertContent>
11
+ * ```tsx
12
+ * <AlertContainer schema="warning">
13
+ * <AlertIcon />
14
+ * <AlertContent>
15
+ * <AlertTitle>Session expiring</AlertTitle>
16
+ * <AlertDescription>You will be logged out in 5 minutes.</AlertDescription>
17
+ * </AlertContent>
39
18
  * </AlertContainer>
19
+ * ```
40
20
  */
41
21
  function AlertContent(props) {
42
22
  const { className: baseClassName, ...rest } = props;
@@ -1,50 +1,22 @@
1
1
  import { HTMLAttributes, JSX } from "react";
2
2
  import "./styles.css";
3
- /**
4
- * Props for the AlertDescription component.
5
- * @typedef {Object} AlertDescriptionProps
6
- * @extends {HTMLAttributes<HTMLDivElement>}
7
- */
8
3
  type AlertDescriptionProps = HTMLAttributes<HTMLDivElement>;
9
4
  /**
10
- * AlertDescription component displays descriptive text content within an Alert component.
11
- *
12
- * This component provides a semantic wrapper for alert descriptions with appropriate styling
13
- * through the `arkynAlertDescription` CSS class. It extends all standard HTML div attributes,
14
- * making it flexible for various content and accessibility requirements.
15
- *
16
- * @component
17
- * @memberof Alert
5
+ * AlertDescription body text for an alert. Place inside `AlertContent`.
18
6
  *
19
- * @param {AlertDescriptionProps} props - Component props extending HTML div attributes
20
- * @param {string} [props.className] - Additional CSS classes to apply to the description
21
- * @param {React.ReactNode} [props.children] - The description content to display
7
+ * Accepts all standard `<div>` HTML attributes.
22
8
  *
23
- * @returns {JSX.Element} A div element with alert description styling
24
- *
25
- * @requires react
26
- *
27
- * @example
28
- * // Basic usage
29
- * <AlertContainer schema="success">
30
- * <AlertContent>
31
- * <AlertDescription>
32
- * Your are premium user now!
33
- * </AlertDescription>
34
- * </AlertContent>
35
- * </AlertContainer>
9
+ * @returns AlertDescription JSX element.
36
10
  *
37
11
  * @example
38
- * // Complete alert example
39
- * <AlertContainer schema="success">
40
- * <AlertIcon />
41
- * <AlertContent>
42
- * <AlertTitle>Success!</AlertTitle>
43
- * <AlertDescription>
44
- * You are premium user now!
45
- * </AlertDescription>
46
- * </AlertContent>
12
+ * ```tsx
13
+ * <AlertContainer schema="info">
14
+ * <AlertContent>
15
+ * <AlertTitle>Maintenance scheduled</AlertTitle>
16
+ * <AlertDescription>The service will be unavailable on Sunday from 2–4 AM UTC.</AlertDescription>
17
+ * </AlertContent>
47
18
  * </AlertContainer>
19
+ * ```
48
20
  */
49
21
  declare function AlertDescription(props: AlertDescriptionProps): JSX.Element;
50
22
  export { AlertDescription };
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertDescription/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,cAAc,CAAC;AAEtB;;;;GAIG;AACH,KAAK,qBAAqB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAE5D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AAEH,iBAAS,gBAAgB,CAAC,KAAK,EAAE,qBAAqB,GAAG,GAAG,CAAC,OAAO,CAKnE;AAED,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertDescription/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,cAAc,CAAC;AAEtB,KAAK,qBAAqB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAE5D;;;;;;;;;;;;;;;;GAgBG;AAEH,iBAAS,gBAAgB,CAAC,KAAK,EAAE,qBAAqB,GAAG,GAAG,CAAC,OAAO,CAKnE;AAED,OAAO,EAAE,gBAAgB,EAAE,CAAC"}
@@ -1,44 +1,21 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "./styles.css";
3
3
  /**
4
- * AlertDescription component displays descriptive text content within an Alert component.
4
+ * AlertDescription body text for an alert. Place inside `AlertContent`.
5
5
  *
6
- * This component provides a semantic wrapper for alert descriptions with appropriate styling
7
- * through the `arkynAlertDescription` CSS class. It extends all standard HTML div attributes,
8
- * making it flexible for various content and accessibility requirements.
6
+ * Accepts all standard `<div>` HTML attributes.
9
7
  *
10
- * @component
11
- * @memberof Alert
12
- *
13
- * @param {AlertDescriptionProps} props - Component props extending HTML div attributes
14
- * @param {string} [props.className] - Additional CSS classes to apply to the description
15
- * @param {React.ReactNode} [props.children] - The description content to display
16
- *
17
- * @returns {JSX.Element} A div element with alert description styling
18
- *
19
- * @requires react
20
- *
21
- * @example
22
- * // Basic usage
23
- * <AlertContainer schema="success">
24
- * <AlertContent>
25
- * <AlertDescription>
26
- * Your are premium user now!
27
- * </AlertDescription>
28
- * </AlertContent>
29
- * </AlertContainer>
8
+ * @returns AlertDescription JSX element.
30
9
  *
31
10
  * @example
32
- * // Complete alert example
33
- * <AlertContainer schema="success">
34
- * <AlertIcon />
35
- * <AlertContent>
36
- * <AlertTitle>Success!</AlertTitle>
37
- * <AlertDescription>
38
- * You are premium user now!
39
- * </AlertDescription>
40
- * </AlertContent>
11
+ * ```tsx
12
+ * <AlertContainer schema="info">
13
+ * <AlertContent>
14
+ * <AlertTitle>Maintenance scheduled</AlertTitle>
15
+ * <AlertDescription>The service will be unavailable on Sunday from 2–4 AM UTC.</AlertDescription>
16
+ * </AlertContent>
41
17
  * </AlertContainer>
18
+ * ```
42
19
  */
43
20
  function AlertDescription(props) {
44
21
  const { className: baseClassName, ...rest } = props;
@@ -1,53 +1,29 @@
1
1
  import { LucideProps } from "lucide-react";
2
2
  import { JSX } from "react";
3
3
  import "./styles.css";
4
- /**
5
- * Props for the AlertIcon component.
6
- * Extends all props from Lucide's icon components.
7
- *
8
- * @typedef {LucideProps} AlertIconProps
9
- */
10
4
  type AlertIconProps = LucideProps;
11
5
  /**
12
- * AlertIcon component that renders different icons based on the alert schema.
13
- *
14
- * @component
15
- * @memberof Alert
6
+ * AlertIcon renders a schema-appropriate icon from `AlertContainer` context.
16
7
  *
17
- * @description
18
- * This component automatically selects and renders the appropriate icon based on the
19
- * alert schema from the AlertContainer context. It supports four schemas:
20
- * - success: Renders a CheckCircle2 icon
21
- * - danger: Renders an XCircle icon
22
- * - warning: Renders an AlertTriangle icon
23
- * - info: Renders an Info icon
8
+ * - `success` → `CheckCircle2`
9
+ * - `danger` `XCircle`
10
+ * - `warning` `AlertTriangle`
11
+ * - `info` `Info`
24
12
  *
25
- * @param {AlertIconProps} props - Component props extending LucideProps
26
- * @param {string} [props.className] - Additional CSS class names to apply to the icon
13
+ * Must be placed inside an `AlertContainer`. Accepts all Lucide icon props.
27
14
  *
28
- * @returns {JSX.Element} The rendered icon component based on the alert schema
29
- *
30
- * @requires lucide-react - For icon components (CheckCircle2, XCircle, AlertTriangle, Info)
31
- * @requires useAlertContainer - Hook to access the alert schema from context
15
+ * @returns The schema-matched Lucide icon element.
32
16
  *
33
17
  * @example
34
- * // This component is used internally within an Alert component
35
- * // and should not be used standalone as it depends on AlertContainer context
36
- * <AlertContainer schema="success">
18
+ * ```tsx
19
+ * <AlertContainer schema="danger">
37
20
  * <AlertIcon />
21
+ * <AlertContent>
22
+ * <AlertTitle>Payment failed</AlertTitle>
23
+ * <AlertDescription>Please check your card details.</AlertDescription>
24
+ * </AlertContent>
38
25
  * </AlertContainer>
39
- *
40
- * @example
41
- * // Complete alert example
42
- * <AlertContainer schema="success">
43
- * <AlertIcon />
44
- * <AlertContent>
45
- * <AlertTitle>Success!</AlertTitle>
46
- * <AlertDescription>
47
- * You are premium user now!
48
- * </AlertDescription>
49
- * </AlertContent>
50
- * </AlertContainer>
26
+ * ```
51
27
  */
52
28
  declare function AlertIcon(props: AlertIconProps): JSX.Element;
53
29
  export { AlertIcon };
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertIcon/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAIL,WAAW,EAEZ,MAAM,cAAc,CAAC;AAEtB,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAE5B,OAAO,cAAc,CAAC;AAEtB;;;;;GAKG;AACH,KAAK,cAAc,GAAG,WAAW,CAAC;AAElC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,iBAAS,SAAS,CAAC,KAAK,EAAE,cAAc,GAAG,GAAG,CAAC,OAAO,CAgBrD;AAED,OAAO,EAAE,SAAS,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertIcon/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAIL,WAAW,EAEZ,MAAM,cAAc,CAAC;AAEtB,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAE5B,OAAO,cAAc,CAAC;AAEtB,KAAK,cAAc,GAAG,WAAW,CAAC;AAElC;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,iBAAS,SAAS,CAAC,KAAK,EAAE,cAAc,GAAG,GAAG,CAAC,OAAO,CAgBrD;AAED,OAAO,EAAE,SAAS,EAAE,CAAC"}
@@ -3,45 +3,27 @@ import { AlertTriangle, CheckCircle2, Info, XCircle, } from "lucide-react";
3
3
  import { useAlertContainer } from "../alertContainer";
4
4
  import "./styles.css";
5
5
  /**
6
- * AlertIcon component that renders different icons based on the alert schema.
6
+ * AlertIcon renders a schema-appropriate icon from `AlertContainer` context.
7
7
  *
8
- * @component
9
- * @memberof Alert
8
+ * - `success` → `CheckCircle2`
9
+ * - `danger` → `XCircle`
10
+ * - `warning` → `AlertTriangle`
11
+ * - `info` → `Info`
10
12
  *
11
- * @description
12
- * This component automatically selects and renders the appropriate icon based on the
13
- * alert schema from the AlertContainer context. It supports four schemas:
14
- * - success: Renders a CheckCircle2 icon
15
- * - danger: Renders an XCircle icon
16
- * - warning: Renders an AlertTriangle icon
17
- * - info: Renders an Info icon
13
+ * Must be placed inside an `AlertContainer`. Accepts all Lucide icon props.
18
14
  *
19
- * @param {AlertIconProps} props - Component props extending LucideProps
20
- * @param {string} [props.className] - Additional CSS class names to apply to the icon
21
- *
22
- * @returns {JSX.Element} The rendered icon component based on the alert schema
23
- *
24
- * @requires lucide-react - For icon components (CheckCircle2, XCircle, AlertTriangle, Info)
25
- * @requires useAlertContainer - Hook to access the alert schema from context
15
+ * @returns The schema-matched Lucide icon element.
26
16
  *
27
17
  * @example
28
- * // This component is used internally within an Alert component
29
- * // and should not be used standalone as it depends on AlertContainer context
30
- * <AlertContainer schema="success">
18
+ * ```tsx
19
+ * <AlertContainer schema="danger">
31
20
  * <AlertIcon />
21
+ * <AlertContent>
22
+ * <AlertTitle>Payment failed</AlertTitle>
23
+ * <AlertDescription>Please check your card details.</AlertDescription>
24
+ * </AlertContent>
32
25
  * </AlertContainer>
33
- *
34
- * @example
35
- * // Complete alert example
36
- * <AlertContainer schema="success">
37
- * <AlertIcon />
38
- * <AlertContent>
39
- * <AlertTitle>Success!</AlertTitle>
40
- * <AlertDescription>
41
- * You are premium user now!
42
- * </AlertDescription>
43
- * </AlertContent>
44
- * </AlertContainer>
26
+ * ```
45
27
  */
46
28
  function AlertIcon(props) {
47
29
  const { className: baseClassName, ...rest } = props;
@@ -1,47 +1,24 @@
1
1
  import { HTMLAttributes, JSX } from "react";
2
2
  import "./styles.css";
3
- /**
4
- * Props for the AlertTitle component.
5
- * Extends all standard HTML div element attributes.
6
- *
7
- * @typedef {Object} AlertTitleProps
8
- * @property {string} [className] - Additional CSS class names to apply to the alert title
9
- * @extends {HTMLAttributes<HTMLDivElement>}
10
- */
11
3
  type AlertTitleProps = HTMLAttributes<HTMLDivElement>;
12
4
  /**
13
- * AlertTitle component - Displays the title section of an alert message.
14
- *
15
- * This component renders a styled title for alert components, providing semantic structure
16
- * and consistent styling across the application.
17
- *
18
- * @component
19
- * @memberof Alert
5
+ * AlertTitle bold heading for an alert. Place inside `AlertContent`.
20
6
  *
21
- * @param {AlertTitleProps} props - Component props extending HTML div attributes
7
+ * Its presence is detected by `AlertContainer` to switch the layout from centered to left-aligned.
8
+ * Accepts all standard `<div>` HTML attributes.
22
9
  *
23
- * @returns {JSX.Element} A div element with alert title styling
24
- *
25
- * @requires react
26
- *
27
- * @example
28
- * // Basic usage
29
- * <AlertContainer schema="success">
30
- * <AlertTitle>Success!</AlertTitle>
31
- * <AlertDescription>Your changes have been saved.</AlertDescription>
32
- * </AlertContainer>
10
+ * @returns AlertTitle JSX element.
33
11
  *
34
12
  * @example
35
- * // Complete alert example
36
- * <AlertContainer schema="success">
37
- * <AlertIcon />
38
- * <AlertContent>
39
- * <AlertTitle>Success!</AlertTitle>
40
- * <AlertDescription>
41
- * You are premium user now!
42
- * </AlertDescription>
43
- * </AlertContent>
13
+ * ```tsx
14
+ * <AlertContainer schema="danger">
15
+ * <AlertIcon />
16
+ * <AlertContent>
17
+ * <AlertTitle>Access denied</AlertTitle>
18
+ * <AlertDescription>You don't have permission to view this page.</AlertDescription>
19
+ * </AlertContent>
44
20
  * </AlertContainer>
21
+ * ```
45
22
  */
46
23
  declare function AlertTitle(props: AlertTitleProps): JSX.Element;
47
24
  export { AlertTitle };
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertTitle/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,cAAc,CAAC;AAEtB;;;;;;;GAOG;AACH,KAAK,eAAe,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAEtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,iBAAS,UAAU,CAAC,KAAK,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAKvD;AAED,OAAO,EAAE,UAAU,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/alert/alertTitle/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,cAAc,CAAC;AAEtB,KAAK,eAAe,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAEtD;;;;;;;;;;;;;;;;;;GAkBG;AACH,iBAAS,UAAU,CAAC,KAAK,EAAE,eAAe,GAAG,GAAG,CAAC,OAAO,CAKvD;AAED,OAAO,EAAE,UAAU,EAAE,CAAC"}
@@ -1,38 +1,23 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "./styles.css";
3
3
  /**
4
- * AlertTitle component - Displays the title section of an alert message.
4
+ * AlertTitle bold heading for an alert. Place inside `AlertContent`.
5
5
  *
6
- * This component renders a styled title for alert components, providing semantic structure
7
- * and consistent styling across the application.
6
+ * Its presence is detected by `AlertContainer` to switch the layout from centered to left-aligned.
7
+ * Accepts all standard `<div>` HTML attributes.
8
8
  *
9
- * @component
10
- * @memberof Alert
11
- *
12
- * @param {AlertTitleProps} props - Component props extending HTML div attributes
13
- *
14
- * @returns {JSX.Element} A div element with alert title styling
15
- *
16
- * @requires react
17
- *
18
- * @example
19
- * // Basic usage
20
- * <AlertContainer schema="success">
21
- * <AlertTitle>Success!</AlertTitle>
22
- * <AlertDescription>Your changes have been saved.</AlertDescription>
23
- * </AlertContainer>
9
+ * @returns AlertTitle JSX element.
24
10
  *
25
11
  * @example
26
- * // Complete alert example
27
- * <AlertContainer schema="success">
28
- * <AlertIcon />
29
- * <AlertContent>
30
- * <AlertTitle>Success!</AlertTitle>
31
- * <AlertDescription>
32
- * You are premium user now!
33
- * </AlertDescription>
34
- * </AlertContent>
12
+ * ```tsx
13
+ * <AlertContainer schema="danger">
14
+ * <AlertIcon />
15
+ * <AlertContent>
16
+ * <AlertTitle>Access denied</AlertTitle>
17
+ * <AlertDescription>You don't have permission to view this page.</AlertDescription>
18
+ * </AlertContent>
35
19
  * </AlertContainer>
20
+ * ```
36
21
  */
37
22
  function AlertTitle(props) {
38
23
  const { className: baseClassName, ...rest } = props;