@bi-digital/react 0.2.10 → 0.2.12

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 (147) hide show
  1. package/README.md +1 -54
  2. package/dist/chunk-2C3XKBNM.js +1 -0
  3. package/dist/chunk-2PYB72CX.js +1 -0
  4. package/dist/{chunk-3OKTD2AD.js → chunk-3XRBNC3R.js} +2 -2
  5. package/dist/chunk-3XRBNC3R.js.map +1 -0
  6. package/dist/chunk-4WOE4T43.js +1 -0
  7. package/dist/chunk-BBMVGCDE.js +1 -0
  8. package/dist/{chunk-45MAIFC5.js → chunk-DT6EO53O.js} +3 -3
  9. package/dist/chunk-DT6EO53O.js.map +1 -0
  10. package/dist/chunk-DZDPC6SE.js +1 -0
  11. package/dist/chunk-IT2O6DB2.js +53 -0
  12. package/dist/chunk-IT2O6DB2.js.map +1 -0
  13. package/dist/chunk-LLNHMZB2.js +1 -0
  14. package/dist/{chunk-6UM2LO6A.js → chunk-MXDZGWL4.js} +3 -3
  15. package/dist/chunk-MXDZGWL4.js.map +1 -0
  16. package/dist/{chunk-4SI37MJP.js → chunk-NLZRLXFN.js} +2 -2
  17. package/dist/chunk-NLZRLXFN.js.map +1 -0
  18. package/dist/chunk-PD4PXDK2.js +1 -0
  19. package/dist/chunk-RAZCAHWX.js +1 -0
  20. package/dist/chunk-RELDFXH4.js +1 -0
  21. package/dist/{chunk-V5WV7RSY.js → chunk-RONRQXS6.js} +2 -2
  22. package/dist/chunk-RONRQXS6.js.map +1 -0
  23. package/dist/chunk-RVKE5NZR.js +1 -0
  24. package/dist/{chunk-PZHZKBNQ.js → chunk-SGVCN25U.js} +2 -2
  25. package/dist/chunk-SGVCN25U.js.map +1 -0
  26. package/dist/chunk-SHVA4JJZ.js +1 -0
  27. package/dist/{chunk-2O4QJORU.js → chunk-SX22Q2HZ.js} +4 -4
  28. package/dist/chunk-SX22Q2HZ.js.map +1 -0
  29. package/dist/chunk-TUJK53CY.js +1 -0
  30. package/dist/chunk-VPE7VEBG.js +8 -0
  31. package/dist/chunk-VPE7VEBG.js.map +1 -0
  32. package/dist/{button → components/button}/button.d.ts +16 -20
  33. package/dist/components/button/button.js +9 -0
  34. package/dist/{button → components/button}/index.d.ts +1 -0
  35. package/dist/components/button/index.js +10 -0
  36. package/dist/components/form/error-message/error-message.js +7 -0
  37. package/dist/components/form/error-message/index.js +8 -0
  38. package/dist/components/form/index.js +24 -0
  39. package/dist/components/form/input/index.js +14 -0
  40. package/dist/components/form/input/input.js +13 -0
  41. package/dist/components/form/input-group/index.js +12 -0
  42. package/dist/components/form/input-group/input-group.js +11 -0
  43. package/dist/components/form/label/index.js +8 -0
  44. package/dist/components/form/label/label.js +7 -0
  45. package/dist/components/index.d.ts +11 -0
  46. package/dist/components/index.js +45 -0
  47. package/dist/{logo → components/logo}/index.d.ts +1 -0
  48. package/dist/components/logo/index.js +8 -0
  49. package/dist/{logo → components/logo}/logo.d.ts +4 -3
  50. package/dist/components/logo/logo.js +7 -0
  51. package/dist/{navbar → components/navbar}/index.d.ts +1 -0
  52. package/dist/components/navbar/index.js +10 -0
  53. package/dist/components/navbar/index.js.map +1 -0
  54. package/dist/{navbar → components/navbar}/navbar.d.ts +4 -3
  55. package/dist/components/navbar/navbar.js +9 -0
  56. package/dist/components/navbar/navbar.js.map +1 -0
  57. package/dist/{spinner → components/spinner}/index.d.ts +1 -0
  58. package/dist/components/spinner/index.js +8 -0
  59. package/dist/components/spinner/index.js.map +1 -0
  60. package/dist/{spinner → components/spinner}/spinner.d.ts +4 -3
  61. package/dist/components/spinner/spinner.js +7 -0
  62. package/dist/components/spinner/spinner.js.map +1 -0
  63. package/dist/main.d.ts +10 -8
  64. package/dist/main.js +29 -22
  65. package/dist/utilities/hooks/index.d.ts +2 -0
  66. package/dist/utilities/hooks/index.js +8 -0
  67. package/dist/utilities/hooks/index.js.map +1 -0
  68. package/dist/utilities/hooks/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.d.ts +5 -0
  69. package/dist/utilities/hooks/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.js +7 -0
  70. package/dist/utilities/hooks/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.js.map +1 -0
  71. package/dist/utilities/index.d.ts +3 -0
  72. package/dist/utilities/index.js +9 -0
  73. package/dist/utilities/index.js.map +1 -0
  74. package/dist/utilities/types.d.ts +7 -0
  75. package/dist/utilities/types.js +1 -0
  76. package/dist/utilities/types.js.map +1 -0
  77. package/package.json +15 -4
  78. package/dist/button/button.js +0 -9
  79. package/dist/button/index.js +0 -10
  80. package/dist/chunk-2O4QJORU.js.map +0 -1
  81. package/dist/chunk-3OKTD2AD.js.map +0 -1
  82. package/dist/chunk-45MAIFC5.js.map +0 -1
  83. package/dist/chunk-4SI37MJP.js.map +0 -1
  84. package/dist/chunk-6UM2LO6A.js.map +0 -1
  85. package/dist/chunk-7IV4F742.js +0 -72
  86. package/dist/chunk-7IV4F742.js.map +0 -1
  87. package/dist/chunk-HFJQRD6C.js +0 -1
  88. package/dist/chunk-JEOMA4Z3.js +0 -1
  89. package/dist/chunk-KTNWYSLR.js +0 -1
  90. package/dist/chunk-NTOVYJTA.js +0 -1
  91. package/dist/chunk-OXOTNHAS.js +0 -1
  92. package/dist/chunk-PZHZKBNQ.js.map +0 -1
  93. package/dist/chunk-QQRONISI.js +0 -1
  94. package/dist/chunk-RJYRALJA.js +0 -1
  95. package/dist/chunk-V5WV7RSY.js.map +0 -1
  96. package/dist/chunk-VELDZOU2.js +0 -1
  97. package/dist/chunk-ZGRDMFHX.js +0 -1
  98. package/dist/form/error-message/error-message.js +0 -7
  99. package/dist/form/error-message/index.js +0 -8
  100. package/dist/form/index.js +0 -24
  101. package/dist/form/input/index.js +0 -14
  102. package/dist/form/input/input.js +0 -13
  103. package/dist/form/input-group/index.js +0 -12
  104. package/dist/form/input-group/input-group.js +0 -11
  105. package/dist/form/label/index.js +0 -8
  106. package/dist/form/label/label.js +0 -7
  107. package/dist/logo/index.js +0 -8
  108. package/dist/logo/logo.js +0 -7
  109. package/dist/navbar/index.js +0 -10
  110. package/dist/navbar/navbar.js +0 -9
  111. package/dist/spinner/index.js +0 -8
  112. package/dist/spinner/spinner.js +0 -7
  113. /package/dist/{button/button.js.map → chunk-2C3XKBNM.js.map} +0 -0
  114. /package/dist/{button/index.js.map → chunk-2PYB72CX.js.map} +0 -0
  115. /package/dist/{chunk-HFJQRD6C.js.map → chunk-4WOE4T43.js.map} +0 -0
  116. /package/dist/{chunk-JEOMA4Z3.js.map → chunk-BBMVGCDE.js.map} +0 -0
  117. /package/dist/{chunk-KTNWYSLR.js.map → chunk-DZDPC6SE.js.map} +0 -0
  118. /package/dist/{chunk-NTOVYJTA.js.map → chunk-LLNHMZB2.js.map} +0 -0
  119. /package/dist/{chunk-OXOTNHAS.js.map → chunk-PD4PXDK2.js.map} +0 -0
  120. /package/dist/{chunk-QQRONISI.js.map → chunk-RAZCAHWX.js.map} +0 -0
  121. /package/dist/{chunk-RJYRALJA.js.map → chunk-RELDFXH4.js.map} +0 -0
  122. /package/dist/{chunk-VELDZOU2.js.map → chunk-RVKE5NZR.js.map} +0 -0
  123. /package/dist/{chunk-ZGRDMFHX.js.map → chunk-SHVA4JJZ.js.map} +0 -0
  124. /package/dist/{form/error-message/error-message.js.map → chunk-TUJK53CY.js.map} +0 -0
  125. /package/dist/{form/error-message/index.js.map → components/button/button.js.map} +0 -0
  126. /package/dist/{form → components/button}/index.js.map +0 -0
  127. /package/dist/{form → components/form}/error-message/error-message.d.ts +0 -0
  128. /package/dist/{form/input-group/index.js.map → components/form/error-message/error-message.js.map} +0 -0
  129. /package/dist/{form → components/form}/error-message/index.d.ts +0 -0
  130. /package/dist/{form/input → components/form/error-message}/index.js.map +0 -0
  131. /package/dist/{form → components/form}/index.d.ts +0 -0
  132. /package/dist/{form/label → components/form}/index.js.map +0 -0
  133. /package/dist/{form → components/form}/input/index.d.ts +0 -0
  134. /package/dist/{navbar → components/form/input}/index.js.map +0 -0
  135. /package/dist/{form → components/form}/input/input.d.ts +0 -0
  136. /package/dist/{form → components/form}/input/input.js.map +0 -0
  137. /package/dist/{form → components/form}/input-group/index.d.ts +0 -0
  138. /package/dist/{logo → components/form/input-group}/index.js.map +0 -0
  139. /package/dist/{form → components/form}/input-group/input-group.d.ts +0 -0
  140. /package/dist/{form → components/form}/input-group/input-group.js.map +0 -0
  141. /package/dist/{form → components/form}/label/index.d.ts +0 -0
  142. /package/dist/{spinner → components/form/label}/index.js.map +0 -0
  143. /package/dist/{form → components/form}/label/label.d.ts +0 -0
  144. /package/dist/{form → components/form}/label/label.js.map +0 -0
  145. /package/dist/{logo/logo.js.map → components/index.js.map} +0 -0
  146. /package/dist/{navbar/navbar.js.map → components/logo/index.js.map} +0 -0
  147. /package/dist/{spinner/spinner.js.map → components/logo/logo.js.map} +0 -0
@@ -1,7 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { ComponentProps, Ref } from 'react';
2
+ import { HTMLAttributes, Ref } from 'react';
3
+ import { MergeRight } from '../../utilities/types.js';
3
4
 
4
- type LogoProps = Omit<ComponentProps<'span'>, 'children'> & {
5
+ type LogoProps = MergeRight<Omit<HTMLAttributes<HTMLSpanElement>, 'children'>, {
5
6
  /**
6
7
  * Determines if the logo should be displayed in the negative version,
7
8
  * useful when displaying the logo on a dark background.
@@ -25,7 +26,7 @@ type LogoProps = Omit<ComponentProps<'span'>, 'children'> & {
25
26
  */
26
27
  size?: 'xs' | 'small' | 'medium' | 'large' | 'xl' | 'xxl';
27
28
  ref?: Ref<HTMLSpanElement>;
28
- };
29
+ }>;
29
30
  declare const Logo: ({ dark, international, vertical, size, className, ref, ...props }: LogoProps) => react_jsx_runtime.JSX.Element;
30
31
 
31
32
  export { Logo, type LogoProps };
@@ -0,0 +1,7 @@
1
+ import {
2
+ Logo
3
+ } from "../../chunk-NLZRLXFN.js";
4
+ export {
5
+ Logo
6
+ };
7
+ //# sourceMappingURL=logo.js.map
@@ -1,3 +1,4 @@
1
1
  export { Navbar, NavbarProps } from './navbar.js';
2
2
  import 'react/jsx-runtime';
3
3
  import 'react';
4
+ import '../../utilities/types.js';
@@ -0,0 +1,10 @@
1
+ import "../../chunk-4WOE4T43.js";
2
+ import {
3
+ Navbar
4
+ } from "../../chunk-MXDZGWL4.js";
5
+ import "../../chunk-SHVA4JJZ.js";
6
+ import "../../chunk-NLZRLXFN.js";
7
+ export {
8
+ Navbar
9
+ };
10
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -1,7 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { ComponentProps, ReactNode, Ref } from 'react';
2
+ import { HTMLAttributes, ReactNode, Ref } from 'react';
3
+ import { MergeRight } from '../../utilities/types.js';
3
4
 
4
- type NavbarProps = ComponentProps<'nav'> & {
5
+ type NavbarProps = MergeRight<HTMLAttributes<HTMLDivElement>, {
5
6
  /**
6
7
  * Determines if the navbar should be dark or light.
7
8
  * @default false
@@ -36,7 +37,7 @@ type NavbarProps = ComponentProps<'nav'> & {
36
37
  */
37
38
  logo?: ReactNode;
38
39
  ref?: Ref<HTMLElement>;
39
- };
40
+ }>;
40
41
  declare const Navbar: ({ dark, fixed, menuAreaLabel, homeAriaLabel, skipLink, homeHref, logo, children, className, ref, ...props }: NavbarProps) => react_jsx_runtime.JSX.Element;
41
42
 
42
43
  export { Navbar, type NavbarProps };
@@ -0,0 +1,9 @@
1
+ import {
2
+ Navbar
3
+ } from "../../chunk-MXDZGWL4.js";
4
+ import "../../chunk-SHVA4JJZ.js";
5
+ import "../../chunk-NLZRLXFN.js";
6
+ export {
7
+ Navbar
8
+ };
9
+ //# sourceMappingURL=navbar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -1,3 +1,4 @@
1
1
  export { Spinner, SpinnerProps } from './spinner.js';
2
2
  import 'react/jsx-runtime';
3
3
  import 'react';
4
+ import '../../utilities/types.js';
@@ -0,0 +1,8 @@
1
+ import "../../chunk-2C3XKBNM.js";
2
+ import {
3
+ Spinner
4
+ } from "../../chunk-RONRQXS6.js";
5
+ export {
6
+ Spinner
7
+ };
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -1,7 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { ComponentProps } from 'react';
2
+ import { HTMLAttributes } from 'react';
3
+ import { MergeRight } from '../../utilities/types.js';
3
4
 
4
- type SpinnerProps = Omit<ComponentProps<'span'>, 'color'> & {
5
+ type SpinnerProps = MergeRight<HTMLAttributes<HTMLSpanElement>, {
5
6
  /**
6
7
  * The color of the spinner.
7
8
  * @default 'inherit'
@@ -12,7 +13,7 @@ type SpinnerProps = Omit<ComponentProps<'span'>, 'color'> & {
12
13
  * It sets the font-size as the width and height is `1em`. If not set, the spinner will inherit the font size of its parent.
13
14
  */
14
15
  size?: 'small' | 'medium' | 'large' | 'xl' | '2xl';
15
- };
16
+ }>;
16
17
  declare const Spinner: ({ color, size, className, ...props }: SpinnerProps) => react_jsx_runtime.JSX.Element;
17
18
 
18
19
  export { Spinner, type SpinnerProps };
@@ -0,0 +1,7 @@
1
+ import {
2
+ Spinner
3
+ } from "../../chunk-RONRQXS6.js";
4
+ export {
5
+ Spinner
6
+ };
7
+ //# sourceMappingURL=spinner.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
package/dist/main.d.ts CHANGED
@@ -1,10 +1,12 @@
1
- export { Button, ButtonProps } from './button/button.js';
2
- export { ErrorMessage, ErrorMessageProps } from './form/error-message/error-message.js';
3
- export { Input, InputProps } from './form/input/input.js';
4
- export { InputGroup, InputGroupProps } from './form/input-group/input-group.js';
5
- export { Label, LabelProps } from './form/label/label.js';
6
- export { Logo, LogoProps } from './logo/logo.js';
7
- export { Navbar, NavbarProps } from './navbar/navbar.js';
8
- export { Spinner, SpinnerProps } from './spinner/spinner.js';
1
+ export { Button, ButtonProps } from './components/button/button.js';
2
+ export { ErrorMessage, ErrorMessageProps } from './components/form/error-message/error-message.js';
3
+ export { Input, InputProps } from './components/form/input/input.js';
4
+ export { InputGroup, InputGroupProps } from './components/form/input-group/input-group.js';
5
+ export { Label, LabelProps } from './components/form/label/label.js';
6
+ export { Logo, LogoProps } from './components/logo/logo.js';
7
+ export { Navbar, NavbarProps } from './components/navbar/navbar.js';
8
+ export { Spinner, SpinnerProps } from './components/spinner/spinner.js';
9
+ export { useIsomorphicLayoutEffect } from './utilities/hooks/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.js';
10
+ export { MergeRight } from './utilities/types.js';
9
11
  import 'react/jsx-runtime';
10
12
  import 'react';
package/dist/main.js CHANGED
@@ -1,36 +1,42 @@
1
- import "./chunk-NTOVYJTA.js";
1
+ import "./chunk-2PYB72CX.js";
2
+ import "./chunk-4WOE4T43.js";
3
+ import {
4
+ Navbar
5
+ } from "./chunk-MXDZGWL4.js";
6
+ import "./chunk-SHVA4JJZ.js";
7
+ import {
8
+ Logo
9
+ } from "./chunk-NLZRLXFN.js";
10
+ import "./chunk-TUJK53CY.js";
11
+ import "./chunk-DZDPC6SE.js";
12
+ import {
13
+ useIsomorphicLayoutEffect
14
+ } from "./chunk-VPE7VEBG.js";
15
+ import "./chunk-BBMVGCDE.js";
2
16
  import {
3
17
  Button
4
- } from "./chunk-7IV4F742.js";
5
- import "./chunk-ZGRDMFHX.js";
18
+ } from "./chunk-IT2O6DB2.js";
19
+ import "./chunk-2C3XKBNM.js";
6
20
  import {
7
21
  Spinner
8
- } from "./chunk-V5WV7RSY.js";
9
- import "./chunk-VELDZOU2.js";
10
- import "./chunk-JEOMA4Z3.js";
22
+ } from "./chunk-RONRQXS6.js";
23
+ import "./chunk-PD4PXDK2.js";
24
+ import "./chunk-LLNHMZB2.js";
11
25
  import {
12
26
  Input
13
- } from "./chunk-45MAIFC5.js";
14
- import "./chunk-OXOTNHAS.js";
27
+ } from "./chunk-DT6EO53O.js";
28
+ import "./chunk-RAZCAHWX.js";
15
29
  import {
16
30
  InputGroup
17
- } from "./chunk-2O4QJORU.js";
18
- import "./chunk-RJYRALJA.js";
31
+ } from "./chunk-SX22Q2HZ.js";
32
+ import "./chunk-RVKE5NZR.js";
33
+ import "./chunk-RELDFXH4.js";
19
34
  import {
20
35
  Label
21
- } from "./chunk-3OKTD2AD.js";
22
- import "./chunk-HFJQRD6C.js";
36
+ } from "./chunk-3XRBNC3R.js";
23
37
  import {
24
38
  ErrorMessage
25
- } from "./chunk-PZHZKBNQ.js";
26
- import "./chunk-QQRONISI.js";
27
- import {
28
- Navbar
29
- } from "./chunk-6UM2LO6A.js";
30
- import "./chunk-KTNWYSLR.js";
31
- import {
32
- Logo
33
- } from "./chunk-4SI37MJP.js";
39
+ } from "./chunk-SGVCN25U.js";
34
40
  export {
35
41
  Button,
36
42
  ErrorMessage,
@@ -39,6 +45,7 @@ export {
39
45
  Label,
40
46
  Logo,
41
47
  Navbar,
42
- Spinner
48
+ Spinner,
49
+ useIsomorphicLayoutEffect
43
50
  };
44
51
  //# sourceMappingURL=main.js.map
@@ -0,0 +1,2 @@
1
+ export { useIsomorphicLayoutEffect } from './useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.js';
2
+ import 'react';
@@ -0,0 +1,8 @@
1
+ import "../../chunk-DZDPC6SE.js";
2
+ import {
3
+ useIsomorphicLayoutEffect
4
+ } from "../../chunk-VPE7VEBG.js";
5
+ export {
6
+ useIsomorphicLayoutEffect
7
+ };
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,5 @@
1
+ import { useLayoutEffect } from 'react';
2
+
3
+ declare const useIsomorphicLayoutEffect: typeof useLayoutEffect;
4
+
5
+ export { useIsomorphicLayoutEffect };
@@ -0,0 +1,7 @@
1
+ import {
2
+ useIsomorphicLayoutEffect
3
+ } from "../../../chunk-VPE7VEBG.js";
4
+ export {
5
+ useIsomorphicLayoutEffect
6
+ };
7
+ //# sourceMappingURL=useIsomorphicLayoutEffect.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,3 @@
1
+ export { useIsomorphicLayoutEffect } from './hooks/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.js';
2
+ export { MergeRight } from './types.js';
3
+ import 'react';
@@ -0,0 +1,9 @@
1
+ import "../chunk-TUJK53CY.js";
2
+ import "../chunk-DZDPC6SE.js";
3
+ import {
4
+ useIsomorphicLayoutEffect
5
+ } from "../chunk-VPE7VEBG.js";
6
+ export {
7
+ useIsomorphicLayoutEffect
8
+ };
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Create a new type with the properties of the first type merged with the properties of the second type.
3
+ * If a key exists in both types, the property from the *second* type will be used.
4
+ */
5
+ type MergeRight<T1, T2> = Omit<T1, keyof T2> & T2;
6
+
7
+ export type { MergeRight };
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bi-digital/react",
3
- "version": "0.2.10",
3
+ "version": "0.2.12",
4
4
  "type": "module",
5
5
  "description": "React components from BI Digital",
6
6
  "author": "BI Digital",
@@ -15,25 +15,36 @@
15
15
  "access": "public"
16
16
  },
17
17
  "dependencies": {
18
+ "@radix-ui/react-slot": "^1.2.2",
18
19
  "clsx": "^2.1.1"
19
20
  },
20
21
  "devDependencies": {
22
+ "@testing-library/dom": "^10.4.0",
23
+ "@testing-library/jest-dom": "^6.6.3",
24
+ "@testing-library/react": "^16.3.0",
25
+ "@testing-library/user-event": "^14.6.1",
21
26
  "@types/node": "^22.14.1",
22
27
  "@types/react": "^19.0.7",
23
28
  "@types/react-dom": "^19.0.3",
29
+ "@vitest/coverage-v8": "3.1.3",
30
+ "@vitest/expect": "^3.1.3",
31
+ "jsdom": "^26.1.0",
24
32
  "react": "^19.0.0",
25
33
  "react-dom": "^19.0.0",
34
+ "tsconfck": "^3.1.5",
26
35
  "tsup": "^8.4.0",
27
- "typescript": "^5.7.2"
36
+ "typescript": "^5.7.2",
37
+ "vitest": "3.1.3"
28
38
  },
29
39
  "peerDependencies": {
30
40
  "react": "^19",
31
41
  "react-dom": "^19",
32
- "@bi-digital/css": "0.2.10"
42
+ "@bi-digital/css": "0.2.12"
33
43
  },
34
44
  "scripts": {
35
45
  "build": "tsup",
36
46
  "dev": "tsup --watch",
37
- "lint": "eslint ."
47
+ "lint": "eslint .",
48
+ "test": "vitest run"
38
49
  }
39
50
  }
@@ -1,9 +0,0 @@
1
- import {
2
- Button
3
- } from "../chunk-7IV4F742.js";
4
- import "../chunk-ZGRDMFHX.js";
5
- import "../chunk-V5WV7RSY.js";
6
- export {
7
- Button
8
- };
9
- //# sourceMappingURL=button.js.map
@@ -1,10 +0,0 @@
1
- import "../chunk-NTOVYJTA.js";
2
- import {
3
- Button
4
- } from "../chunk-7IV4F742.js";
5
- import "../chunk-ZGRDMFHX.js";
6
- import "../chunk-V5WV7RSY.js";
7
- export {
8
- Button
9
- };
10
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/form/input-group/input-group.tsx"],"sourcesContent":["import { useId, Children, isValidElement, cloneElement } from 'react';\nimport type { ComponentProps, LabelHTMLAttributes, ReactNode, Ref } from 'react';\nimport clsx from 'clsx';\nimport { ErrorMessage, type ErrorMessageProps } from '../error-message';\nimport { Label } from '../label';\n\ninterface InputProps {\n 'aria-describedby'?: string;\n 'aria-invalid'?: boolean;\n id?: string;\n className?: string;\n}\n\nexport type InputGroupProps = ComponentProps<'div'> & {\n dark?: boolean;\n stretch?: boolean;\n errorMessage?: ReactNode;\n errorMessageProps?: Partial<ErrorMessageProps>;\n labelProps?: LabelHTMLAttributes<HTMLLabelElement>;\n label: ReactNode;\n disabled?: boolean;\n readOnly?: boolean;\n required?: boolean;\n /**\n * `children` must be a single input element.\n */\n children: Exclude<ReactNode, Iterable<ReactNode>>;\n /** Add an adornment to the start of the input. */\n startAdornment?: ReactNode;\n /** Add an adornment to the end of the input. */\n endAdornment?: ReactNode;\n ref?: Ref<HTMLDivElement>;\n};\n\nexport const InputGroup = ({\n id,\n className,\n style,\n dark = false,\n stretch = false,\n errorMessage,\n errorMessageProps,\n labelProps: { className: labelClassName, ...labelProps } = {},\n label,\n disabled,\n readOnly,\n required,\n children,\n startAdornment,\n endAdornment,\n ref,\n ...props\n}: InputGroupProps) => {\n const errorMessageId = useId();\n const inputId = useId();\n\n const renderInput = () => {\n const inputProps: InputProps = {\n 'aria-describedby': errorMessage ? errorMessageId : undefined,\n 'aria-invalid': errorMessage ? true : undefined,\n id: id ?? inputId,\n className: 'bi-input',\n };\n\n const input: ReactNode = Children.toArray(children)[0];\n\n if (!isValidElement<InputProps>(input)) {\n return;\n }\n\n return cloneElement<InputProps>(input, {\n ...inputProps,\n ...input.props,\n className: `${inputProps.className} ${input.props.className ?? ''}`,\n });\n };\n\n return (\n <div\n className={clsx('bi-input-group', className)}\n data-dark={dark}\n data-stretch={stretch}\n ref={ref}\n style={style}\n {...props}\n >\n <Label className={labelClassName} required={required} {...labelProps} htmlFor={id ?? inputId}>\n {label}\n </Label>\n <div\n className={clsx('bi-input-group__input-wrapper')}\n data-disabled={disabled}\n data-readonly={readOnly}\n data-error={errorMessage ? true : undefined}\n >\n {startAdornment && <span data-start-adornment='true'>{startAdornment}</span>}\n {renderInput()}\n {endAdornment && <span data-end-adornment='true'>{endAdornment}</span>}\n </div>\n <ErrorMessage id={errorMessageId} {...errorMessageProps}>\n {errorMessage}\n </ErrorMessage>\n </div>\n );\n};\n"],"mappings":";;;;;;;;AAAA,SAAS,OAAO,UAAU,gBAAgB,oBAAoB;AAE9D,OAAO,UAAU;AAoFX,cAGA,YAHA;AApDC,IAAM,aAAa,CAAC;AAAA,EACzB;AAAA,EACA;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP,UAAU;AAAA,EACV;AAAA,EACA;AAAA,EACA,YAAY,EAAE,WAAW,gBAAgB,GAAG,WAAW,IAAI,CAAC;AAAA,EAC5D;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAuB;AACrB,QAAM,iBAAiB,MAAM;AAC7B,QAAM,UAAU,MAAM;AAEtB,QAAM,cAAc,MAAM;AACxB,UAAM,aAAyB;AAAA,MAC7B,oBAAoB,eAAe,iBAAiB;AAAA,MACpD,gBAAgB,eAAe,OAAO;AAAA,MACtC,IAAI,MAAM;AAAA,MACV,WAAW;AAAA,IACb;AAEA,UAAM,QAAmB,SAAS,QAAQ,QAAQ,EAAE,CAAC;AAErD,QAAI,CAAC,eAA2B,KAAK,GAAG;AACtC;AAAA,IACF;AAEA,WAAO,aAAyB,OAAO;AAAA,MACrC,GAAG;AAAA,MACH,GAAG,MAAM;AAAA,MACT,WAAW,GAAG,WAAW,SAAS,IAAI,MAAM,MAAM,aAAa,EAAE;AAAA,IACnE,CAAC;AAAA,EACH;AAEA,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW,KAAK,kBAAkB,SAAS;AAAA,MAC3C,aAAW;AAAA,MACX,gBAAc;AAAA,MACd;AAAA,MACA;AAAA,MACC,GAAG;AAAA,MAEJ;AAAA,4BAAC,SAAM,WAAW,gBAAgB,UAAqB,GAAG,YAAY,SAAS,MAAM,SAClF,iBACH;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YACC,WAAW,KAAK,+BAA+B;AAAA,YAC/C,iBAAe;AAAA,YACf,iBAAe;AAAA,YACf,cAAY,eAAe,OAAO;AAAA,YAEjC;AAAA,gCAAkB,oBAAC,UAAK,wBAAqB,QAAQ,0BAAe;AAAA,cACpE,YAAY;AAAA,cACZ,gBAAgB,oBAAC,UAAK,sBAAmB,QAAQ,wBAAa;AAAA;AAAA;AAAA,QACjE;AAAA,QACA,oBAAC,gBAAa,IAAI,gBAAiB,GAAG,mBACnC,wBACH;AAAA;AAAA;AAAA,EACF;AAEJ;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/form/label/label.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport { ComponentProps } from 'react';\n\nexport type LabelProps = ComponentProps<'label'> & {\n /** The font style of the label. */\n labelFontStyle?: 'regular' | 'bold';\n htmlFor?: string;\n required?: boolean;\n disabled?: boolean;\n /** Is the component displayed on a dark background. */\n dark?: boolean;\n /**\n * The type of label. `label` is used for labeling specific elements. `legend` is a broad label used for a group of objects.\n * @default 'label'\n */\n type?: 'label' | 'legend';\n};\n\n/**\n * Accessible label component that can be used to display a label and help text for form fields.\n */\nexport const Label = ({\n children,\n labelFontStyle,\n htmlFor,\n required,\n disabled,\n dark,\n className,\n ...props\n}: LabelProps) => {\n return (\n <label\n {...props}\n className={clsx('bi-label', className)}\n data-dark={dark}\n data-required={required}\n data-font-style={labelFontStyle}\n aria-disabled={disabled}\n htmlFor={htmlFor}\n >\n {children}\n </label>\n );\n};\n"],"mappings":";AAAA,OAAO,UAAU;AAgCb;AAXG,IAAM,QAAQ,CAAC;AAAA,EACpB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAkB;AAChB,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACJ,WAAW,KAAK,YAAY,SAAS;AAAA,MACrC,aAAW;AAAA,MACX,iBAAe;AAAA,MACf,mBAAiB;AAAA,MACjB,iBAAe;AAAA,MACf;AAAA,MAEC;AAAA;AAAA,EACH;AAEJ;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/form/input/input.tsx"],"sourcesContent":["import type { InputHTMLAttributes, Ref } from 'react';\nimport { InputGroup } from '../input-group';\nimport type { InputGroupProps } from '../input-group';\n\nexport type InputProps = Omit<InputGroupProps & InputHTMLAttributes<HTMLInputElement>, 'children'> & {\n ref?: Ref<HTMLInputElement>;\n};\n\nexport const Input = ({\n dark = false,\n className,\n errorMessage,\n labelProps,\n label,\n id,\n style,\n stretch,\n disabled,\n readOnly,\n startAdornment,\n endAdornment,\n ref,\n ...props\n}: InputProps) => {\n return (\n <InputGroup\n className={className}\n disabled={disabled}\n dark={dark}\n stretch={stretch}\n errorMessage={errorMessage}\n id={id}\n label={label}\n labelProps={labelProps}\n readOnly={readOnly}\n style={style}\n startAdornment={startAdornment}\n endAdornment={endAdornment}\n >\n <input {...props} className='bi-input' disabled={disabled} readOnly={readOnly} ref={ref} />\n </InputGroup>\n );\n};\n"],"mappings":";;;;;AAuCM;AA/BC,IAAM,QAAQ,CAAC;AAAA,EACpB,OAAO;AAAA,EACP;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAkB;AAChB,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MAEA,8BAAC,WAAO,GAAG,OAAO,WAAU,YAAW,UAAoB,UAAoB,KAAU;AAAA;AAAA,EAC3F;AAEJ;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/logo/logo.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport type { ComponentProps, Ref } from 'react';\n\nexport type LogoProps = Omit<ComponentProps<'span'>, 'children'> & {\n /**\n * Determines if the logo should be displayed in the negative version,\n * useful when displaying the logo on a dark background.\n * @default false\n */\n dark?: boolean;\n /**\n * Determines if the international logo should be used.\n * @default false\n */\n international?: boolean;\n /**\n * Determines if the logo text should be displayed vertically.\n * Only applies when `international` is `true`.\n * @default false\n */\n vertical?: boolean;\n /**\n * Determines the height of the logo.\n * @default 'medium'\n */\n size?: 'xs' | 'small' | 'medium' | 'large' | 'xl' | 'xxl';\n ref?: Ref<HTMLSpanElement>;\n};\n\nexport const Logo = ({\n dark = false,\n international = false,\n vertical = false,\n size = 'medium',\n className,\n ref,\n ...props\n}: LogoProps) => {\n return (\n <span\n {...props}\n className={clsx('bi-logo', className)}\n data-dark={dark}\n data-international={international}\n data-vertical={vertical}\n data-size={size}\n ref={ref}\n />\n );\n};\n"],"mappings":";AAAA,OAAO,UAAU;AAuCb;AAVG,IAAM,OAAO,CAAC;AAAA,EACnB,OAAO;AAAA,EACP,gBAAgB;AAAA,EAChB,WAAW;AAAA,EACX,OAAO;AAAA,EACP;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAiB;AACf,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACJ,WAAW,KAAK,WAAW,SAAS;AAAA,MACpC,aAAW;AAAA,MACX,sBAAoB;AAAA,MACpB,iBAAe;AAAA,MACf,aAAW;AAAA,MACX;AAAA;AAAA,EACF;AAEJ;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/navbar/navbar.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport type { ComponentProps, ReactNode, Ref } from 'react';\nimport { Logo } from '../logo';\n\nexport type NavbarProps = ComponentProps<'nav'> & {\n /**\n * Determines if the navbar should be dark or light.\n * @default false\n */\n dark?: boolean;\n /**\n * Skip link.\n */\n skipLink?: { label: string; href: string };\n /**\n * Text for menu area label.\n */\n menuAreaLabel: string;\n /**\n * Determines if the navbar should be fixed.\n * @default false\n */\n fixed?: boolean;\n /**\n * Aria label for the home link.\n */\n homeAriaLabel: string;\n /**\n * Href for the home link.\n */\n homeHref: string;\n /**\n * Override the default logo\n */\n logo?: ReactNode;\n ref?: Ref<HTMLElement>;\n};\n\nexport const Navbar = ({\n dark = false,\n fixed = false,\n menuAreaLabel,\n homeAriaLabel,\n skipLink,\n homeHref,\n logo,\n children,\n className,\n ref,\n ...props\n}: NavbarProps) => {\n return (\n <nav {...props} className={clsx('bi-navbar', className)} data-fixed={fixed} data-dark={dark} ref={ref}>\n {skipLink && (\n <a className='bi-navbar__skip-link' href={skipLink.href}>\n {skipLink.label}\n </a>\n )}\n <header className='bi-navbar__header' aria-label={menuAreaLabel}>\n <a aria-label={homeAriaLabel} href={homeHref}>\n {logo || <Logo dark={dark} />}\n </a>\n {children}\n </header>\n </nav>\n );\n};\n"],"mappings":";;;;;AAAA,OAAO,UAAU;AAsDT,cAIF,YAJE;AAhBD,IAAM,SAAS,CAAC;AAAA,EACrB,OAAO;AAAA,EACP,QAAQ;AAAA,EACR;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAmB;AACjB,SACE,qBAAC,SAAK,GAAG,OAAO,WAAW,KAAK,aAAa,SAAS,GAAG,cAAY,OAAO,aAAW,MAAM,KAC1F;AAAA,gBACC,oBAAC,OAAE,WAAU,wBAAuB,MAAM,SAAS,MAChD,mBAAS,OACZ;AAAA,IAEF,qBAAC,YAAO,WAAU,qBAAoB,cAAY,eAChD;AAAA,0BAAC,OAAE,cAAY,eAAe,MAAM,UACjC,kBAAQ,oBAAC,QAAK,MAAY,GAC7B;AAAA,MACC;AAAA,OACH;AAAA,KACF;AAEJ;","names":[]}
@@ -1,72 +0,0 @@
1
- import {
2
- Spinner
3
- } from "./chunk-V5WV7RSY.js";
4
-
5
- // src/button/button.tsx
6
- import clsx from "clsx";
7
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
8
- var Button = ({
9
- variant = "filled",
10
- size = "medium",
11
- stretch,
12
- dark,
13
- disabled,
14
- submitting,
15
- icon,
16
- children,
17
- className,
18
- startIcon,
19
- endIcon,
20
- active,
21
- href,
22
- target,
23
- ref,
24
- ...props
25
- }) => {
26
- const child = /* @__PURE__ */ jsx(Fragment, { children: icon ? submitting ? /* @__PURE__ */ jsx(Spinner, { "aria-hidden": "true" }) : children : /* @__PURE__ */ jsxs(Fragment, { children: [
27
- submitting ? /* @__PURE__ */ jsx(Spinner, { "aria-hidden": "true", className: "bi-button--start-icon" }) : startIcon && /* @__PURE__ */ jsx("span", { className: "bi-button--start-icon", children: startIcon }),
28
- children,
29
- endIcon && /* @__PURE__ */ jsx("span", { className: "bi-button--end-icon", children: endIcon })
30
- ] }) });
31
- if (href || target) {
32
- return /* @__PURE__ */ jsx(
33
- "a",
34
- {
35
- ...props,
36
- className: clsx("bi-button", className),
37
- "data-variant": variant,
38
- "data-size": size,
39
- "data-stretch": stretch,
40
- "data-dark": dark,
41
- "data-icon": icon,
42
- "data-active": active,
43
- "data-disabled": disabled,
44
- href,
45
- target,
46
- ref,
47
- children: child
48
- }
49
- );
50
- }
51
- return /* @__PURE__ */ jsx(
52
- "button",
53
- {
54
- ...props,
55
- className: clsx("bi-button", className),
56
- "data-variant": variant,
57
- "data-size": size,
58
- "data-stretch": stretch,
59
- "data-dark": dark,
60
- "data-icon": icon,
61
- "data-active": active,
62
- disabled,
63
- ref,
64
- children: child
65
- }
66
- );
67
- };
68
-
69
- export {
70
- Button
71
- };
72
- //# sourceMappingURL=chunk-7IV4F742.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/button/button.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport type { ComponentProps, ReactNode, Ref } from 'react';\nimport { Spinner } from '../spinner';\n\nexport type ButtonProps = ComponentProps<'button' | 'a'> & {\n /**\n * The button size.\n * @default 'medium'\n */\n size?: 'small' | 'medium' | 'large';\n /**\n * The button variant.\n * @default 'filled'\n */\n variant?: 'filled' | 'outlined' | 'text' | 'flat';\n /**\n * Stretch the button to the full width.\n * @default false\n */\n stretch?: boolean;\n /**\n * Is the component displayed on a dark background.\n * @default false\n */\n dark?: boolean;\n /**\n * Decides if the button is disabled.\n * @default false\n */\n disabled?: boolean;\n /**\n * Display a loading animation with the Spinner-component.\n * Replaces the `startIcon` if used\n * @default false\n */\n submitting?: boolean;\n /**\n * Display as icon-button, only use when showing an icon as the label.\n * Not compatible with the icon-slots or `stretch`.\n * Always provide a descriptive aria-label for accessibility when set to true.\n * @default false\n */\n icon?: boolean;\n /**\n * Contains a URL or a URL fragment that the hyperlink points to.\n * If this property is set, a link styled as a button will be rendered.\n */\n href?: string;\n /**\n * Specifies where to display the linked URL.\n * Only applies when an `href` is provided.\n */\n target?: '_blank' | '_self' | '_parent' | '_top';\n /** Set an icon before the button label, no effect if `icon=true` */\n startIcon?: ReactNode;\n /** Set an icon after the button label, no effect if `icon=true` */\n endIcon?: ReactNode;\n /** Make the button active by showing an active state. */\n active?: boolean;\n ref?: Ref<HTMLAnchorElement | HTMLButtonElement>;\n};\n\nexport const Button = ({\n variant = 'filled',\n size = 'medium',\n stretch,\n dark,\n disabled,\n submitting,\n icon,\n children,\n className,\n startIcon,\n endIcon,\n active,\n href,\n target,\n ref,\n ...props\n}: ButtonProps) => {\n const child = (\n <>\n {icon ? (\n submitting ? (\n <Spinner aria-hidden='true' />\n ) : (\n children\n )\n ) : (\n <>\n {submitting ? (\n <Spinner aria-hidden='true' className='bi-button--start-icon' />\n ) : (\n startIcon && <span className='bi-button--start-icon'>{startIcon}</span>\n )}\n {children}\n {endIcon && <span className='bi-button--end-icon'>{endIcon}</span>}\n </>\n )}\n </>\n );\n\n if (href || target) {\n return (\n <a\n {...props}\n className={clsx('bi-button', className)}\n data-variant={variant}\n data-size={size}\n data-stretch={stretch}\n data-dark={dark}\n data-icon={icon}\n data-active={active}\n data-disabled={disabled}\n href={href}\n target={target}\n // @ts-expect-error It's tricky to ensure that this ref is an anchor-element ref, therefore ignoring the error\n ref={ref}\n >\n {child}\n </a>\n );\n }\n\n return (\n <button\n {...props}\n className={clsx('bi-button', className)}\n data-variant={variant}\n data-size={size}\n data-stretch={stretch}\n data-dark={dark}\n data-icon={icon}\n data-active={active}\n disabled={disabled}\n // @ts-expect-error It's tricky to ensure that this ref is an button-element ref, therefore ignoring the error\n ref={ref}\n >\n {child}\n </button>\n );\n};\n"],"mappings":";;;;;AAAA,OAAO,UAAU;AAoFP,SAKF,UALE,KAKF,YALE;AAtBH,IAAM,SAAS,CAAC;AAAA,EACrB,UAAU;AAAA,EACV,OAAO;AAAA,EACP;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAmB;AACjB,QAAM,QACJ,gCACG,iBACC,aACE,oBAAC,WAAQ,eAAY,QAAO,IAE5B,WAGF,iCACG;AAAA,iBACC,oBAAC,WAAQ,eAAY,QAAO,WAAU,yBAAwB,IAE9D,aAAa,oBAAC,UAAK,WAAU,yBAAyB,qBAAU;AAAA,IAEjE;AAAA,IACA,WAAW,oBAAC,UAAK,WAAU,uBAAuB,mBAAQ;AAAA,KAC7D,GAEJ;AAGF,MAAI,QAAQ,QAAQ;AAClB,WACE;AAAA,MAAC;AAAA;AAAA,QACE,GAAG;AAAA,QACJ,WAAW,KAAK,aAAa,SAAS;AAAA,QACtC,gBAAc;AAAA,QACd,aAAW;AAAA,QACX,gBAAc;AAAA,QACd,aAAW;AAAA,QACX,aAAW;AAAA,QACX,eAAa;AAAA,QACb,iBAAe;AAAA,QACf;AAAA,QACA;AAAA,QAEA;AAAA,QAEC;AAAA;AAAA,IACH;AAAA,EAEJ;AAEA,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACJ,WAAW,KAAK,aAAa,SAAS;AAAA,MACtC,gBAAc;AAAA,MACd,aAAW;AAAA,MACX,gBAAc;AAAA,MACd,aAAW;AAAA,MACX,aAAW;AAAA,MACX,eAAa;AAAA,MACb;AAAA,MAEA;AAAA,MAEC;AAAA;AAAA,EACH;AAEJ;","names":[]}
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-HFJQRD6C.js.map
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-JEOMA4Z3.js.map
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-KTNWYSLR.js.map
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-NTOVYJTA.js.map
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-OXOTNHAS.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/form/error-message/error-message.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport type { ComponentProps, Ref } from 'react';\n\nexport type ErrorMessageProps = Omit<ComponentProps<'div'>, 'id'> & {\n id: string;\n ref?: Ref<HTMLElement>;\n};\n\nexport const ErrorMessage = ({ children, id, className, ref, ...props }: ErrorMessageProps) => {\n return (\n <div aria-live='polite' className={clsx('bi-error-message', className as undefined)} id={id} ref={ref} {...props}>\n {children}\n </div>\n );\n};\n"],"mappings":";AAAA,OAAO,UAAU;AAUb;AAFG,IAAM,eAAe,CAAC,EAAE,UAAU,IAAI,WAAW,KAAK,GAAG,MAAM,MAAyB;AAC7F,SACE,oBAAC,SAAI,aAAU,UAAS,WAAW,KAAK,oBAAoB,SAAsB,GAAG,IAAQ,KAAW,GAAG,OACxG,UACH;AAEJ;","names":[]}
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-QQRONISI.js.map
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-RJYRALJA.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/spinner/spinner.tsx"],"sourcesContent":["import clsx from 'clsx';\nimport type { ComponentProps } from 'react';\n\nexport type SpinnerProps = Omit<ComponentProps<'span'>, 'color'> & {\n /**\n * The color of the spinner.\n * @default 'inherit'\n */\n color?: 'inherit' | 'black';\n /**\n * The size of the spinner.\n * It sets the font-size as the width and height is `1em`. If not set, the spinner will inherit the font size of its parent.\n */\n size?: 'small' | 'medium' | 'large' | 'xl' | '2xl';\n};\n\nexport const Spinner = ({ color = 'inherit', size, className, ...props }: SpinnerProps) => {\n return <span className={clsx('bi-spinner', className)} data-size={size} data-color={color} {...props} />;\n};\n"],"mappings":";AAAA,OAAO,UAAU;AAiBR;AADF,IAAM,UAAU,CAAC,EAAE,QAAQ,WAAW,MAAM,WAAW,GAAG,MAAM,MAAoB;AACzF,SAAO,oBAAC,UAAK,WAAW,KAAK,cAAc,SAAS,GAAG,aAAW,MAAM,cAAY,OAAQ,GAAG,OAAO;AACxG;","names":[]}
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-VELDZOU2.js.map
@@ -1 +0,0 @@
1
- //# sourceMappingURL=chunk-ZGRDMFHX.js.map
@@ -1,7 +0,0 @@
1
- import {
2
- ErrorMessage
3
- } from "../../chunk-PZHZKBNQ.js";
4
- export {
5
- ErrorMessage
6
- };
7
- //# sourceMappingURL=error-message.js.map
@@ -1,8 +0,0 @@
1
- import "../../chunk-HFJQRD6C.js";
2
- import {
3
- ErrorMessage
4
- } from "../../chunk-PZHZKBNQ.js";
5
- export {
6
- ErrorMessage
7
- };
8
- //# sourceMappingURL=index.js.map
@@ -1,24 +0,0 @@
1
- import "../chunk-VELDZOU2.js";
2
- import "../chunk-JEOMA4Z3.js";
3
- import {
4
- Input
5
- } from "../chunk-45MAIFC5.js";
6
- import "../chunk-OXOTNHAS.js";
7
- import {
8
- InputGroup
9
- } from "../chunk-2O4QJORU.js";
10
- import "../chunk-RJYRALJA.js";
11
- import {
12
- Label
13
- } from "../chunk-3OKTD2AD.js";
14
- import "../chunk-HFJQRD6C.js";
15
- import {
16
- ErrorMessage
17
- } from "../chunk-PZHZKBNQ.js";
18
- export {
19
- ErrorMessage,
20
- Input,
21
- InputGroup,
22
- Label
23
- };
24
- //# sourceMappingURL=index.js.map
@@ -1,14 +0,0 @@
1
- import "../../chunk-JEOMA4Z3.js";
2
- import {
3
- Input
4
- } from "../../chunk-45MAIFC5.js";
5
- import "../../chunk-OXOTNHAS.js";
6
- import "../../chunk-2O4QJORU.js";
7
- import "../../chunk-RJYRALJA.js";
8
- import "../../chunk-3OKTD2AD.js";
9
- import "../../chunk-HFJQRD6C.js";
10
- import "../../chunk-PZHZKBNQ.js";
11
- export {
12
- Input
13
- };
14
- //# sourceMappingURL=index.js.map
@@ -1,13 +0,0 @@
1
- import {
2
- Input
3
- } from "../../chunk-45MAIFC5.js";
4
- import "../../chunk-OXOTNHAS.js";
5
- import "../../chunk-2O4QJORU.js";
6
- import "../../chunk-RJYRALJA.js";
7
- import "../../chunk-3OKTD2AD.js";
8
- import "../../chunk-HFJQRD6C.js";
9
- import "../../chunk-PZHZKBNQ.js";
10
- export {
11
- Input
12
- };
13
- //# sourceMappingURL=input.js.map
@@ -1,12 +0,0 @@
1
- import "../../chunk-OXOTNHAS.js";
2
- import {
3
- InputGroup
4
- } from "../../chunk-2O4QJORU.js";
5
- import "../../chunk-RJYRALJA.js";
6
- import "../../chunk-3OKTD2AD.js";
7
- import "../../chunk-HFJQRD6C.js";
8
- import "../../chunk-PZHZKBNQ.js";
9
- export {
10
- InputGroup
11
- };
12
- //# sourceMappingURL=index.js.map