@postenbring/hedwig-react 0.0.71 → 0.0.73

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 (123) hide show
  1. package/dist/_tsup-dts-rollup.d.mts +99 -28
  2. package/dist/_tsup-dts-rollup.d.ts +99 -28
  3. package/dist/{breadcrumb/index.js → breadcrumbs/breadcrumbs.js} +12 -11
  4. package/dist/breadcrumbs/breadcrumbs.js.map +1 -0
  5. package/dist/{breadcrumb/breadcrumb.mjs → breadcrumbs/breadcrumbs.mjs} +2 -2
  6. package/dist/{breadcrumb/breadcrumb.js → breadcrumbs/index.js} +14 -9
  7. package/dist/breadcrumbs/index.js.map +1 -0
  8. package/dist/breadcrumbs/index.mjs +9 -0
  9. package/dist/button/button.js +1 -4
  10. package/dist/button/button.js.map +1 -1
  11. package/dist/button/button.mjs +1 -1
  12. package/dist/button/index.js +1 -4
  13. package/dist/button/index.js.map +1 -1
  14. package/dist/button/index.mjs +1 -1
  15. package/dist/chunk-3LYJRAOC.mjs +1 -0
  16. package/dist/{chunk-OUHO4LGN.mjs → chunk-BWFFP6BB.mjs} +2 -5
  17. package/dist/chunk-BWFFP6BB.mjs.map +1 -0
  18. package/dist/chunk-CFAH2LID.mjs +1 -0
  19. package/dist/{chunk-K2HG7WRK.mjs → chunk-CSAEHQ4R.mjs} +2 -2
  20. package/dist/{chunk-ZRFDCZ62.mjs → chunk-CSFSJGLY.mjs} +5 -5
  21. package/dist/chunk-E2RTLHMZ.mjs +54 -0
  22. package/dist/chunk-E2RTLHMZ.mjs.map +1 -0
  23. package/dist/chunk-EMI7NAO2.mjs +45 -0
  24. package/dist/chunk-EMI7NAO2.mjs.map +1 -0
  25. package/dist/chunk-GGEQEVZ4.mjs +22 -0
  26. package/dist/chunk-GGEQEVZ4.mjs.map +1 -0
  27. package/dist/chunk-HSIL53A5.mjs +118 -0
  28. package/dist/chunk-HSIL53A5.mjs.map +1 -0
  29. package/dist/chunk-ISAHCU7C.mjs +1 -0
  30. package/dist/chunk-ISAHCU7C.mjs.map +1 -0
  31. package/dist/chunk-JBWAZQKM.mjs +1 -0
  32. package/dist/chunk-JBWAZQKM.mjs.map +1 -0
  33. package/dist/{chunk-O32FZU7E.mjs → chunk-S3BGPCLK.mjs} +4 -4
  34. package/dist/{chunk-FOZSX44S.mjs → chunk-VM345XBI.mjs} +6 -6
  35. package/dist/chunk-Z753E3XF.mjs +33 -0
  36. package/dist/chunk-Z753E3XF.mjs.map +1 -0
  37. package/dist/description-list/description-list.d.mts +1 -1
  38. package/dist/description-list/description-list.d.ts +1 -1
  39. package/dist/description-list/description-list.js +19 -21
  40. package/dist/description-list/description-list.js.map +1 -1
  41. package/dist/description-list/description-list.mjs +1 -1
  42. package/dist/description-list/index.js +19 -21
  43. package/dist/description-list/index.js.map +1 -1
  44. package/dist/description-list/index.mjs +1 -1
  45. package/dist/footer/footer.js +1 -4
  46. package/dist/footer/footer.js.map +1 -1
  47. package/dist/footer/footer.mjs +2 -2
  48. package/dist/footer/index.js +1 -4
  49. package/dist/footer/index.js.map +1 -1
  50. package/dist/footer/index.mjs +3 -3
  51. package/dist/form/index.mjs +14 -14
  52. package/dist/help-text/help-text.d.mts +1 -0
  53. package/dist/help-text/help-text.d.ts +1 -0
  54. package/dist/help-text/help-text.js +186 -0
  55. package/dist/help-text/help-text.js.map +1 -0
  56. package/dist/help-text/help-text.mjs +10 -0
  57. package/dist/help-text/help-text.mjs.map +1 -0
  58. package/dist/help-text/index.d.mts +1 -0
  59. package/dist/help-text/index.d.ts +1 -0
  60. package/dist/help-text/index.js +188 -0
  61. package/dist/help-text/index.js.map +1 -0
  62. package/dist/help-text/index.mjs +11 -0
  63. package/dist/help-text/index.mjs.map +1 -0
  64. package/dist/index-no-css.d.mts +2 -0
  65. package/dist/index-no-css.d.ts +2 -0
  66. package/dist/index-no-css.js +414 -316
  67. package/dist/index-no-css.js.map +1 -1
  68. package/dist/index-no-css.mjs +112 -102
  69. package/dist/index.d.mts +2 -0
  70. package/dist/index.d.ts +2 -0
  71. package/dist/index.js +414 -316
  72. package/dist/index.js.map +1 -1
  73. package/dist/index.mjs +112 -102
  74. package/dist/index.mjs.map +1 -1
  75. package/dist/layout/index.mjs +6 -6
  76. package/dist/navbar/index.mjs +5 -5
  77. package/dist/show-more/index.js +91 -39
  78. package/dist/show-more/index.js.map +1 -1
  79. package/dist/show-more/index.mjs +2 -1
  80. package/dist/table/index.d.mts +1 -0
  81. package/dist/table/index.d.ts +1 -0
  82. package/dist/table/index.js +94 -0
  83. package/dist/table/index.js.map +1 -0
  84. package/dist/table/index.mjs +9 -0
  85. package/dist/table/index.mjs.map +1 -0
  86. package/dist/table/table.d.mts +1 -0
  87. package/dist/table/table.d.ts +1 -0
  88. package/dist/table/table.js +92 -0
  89. package/dist/table/table.js.map +1 -0
  90. package/dist/table/table.mjs +8 -0
  91. package/dist/table/table.mjs.map +1 -0
  92. package/dist/tabs/index.mjs +5 -5
  93. package/dist/utilities/auto-animate-height.js +89 -37
  94. package/dist/utilities/auto-animate-height.js.map +1 -1
  95. package/dist/utilities/auto-animate-height.mjs +2 -1
  96. package/dist/utilities/index.js +89 -37
  97. package/dist/utilities/index.js.map +1 -1
  98. package/dist/utilities/index.mjs +2 -1
  99. package/package.json +6 -5
  100. package/dist/breadcrumb/breadcrumb.js.map +0 -1
  101. package/dist/breadcrumb/index.js.map +0 -1
  102. package/dist/breadcrumb/index.mjs +0 -9
  103. package/dist/chunk-AKYK3XFN.mjs +0 -95
  104. package/dist/chunk-AKYK3XFN.mjs.map +0 -1
  105. package/dist/chunk-OUHO4LGN.mjs.map +0 -1
  106. package/dist/chunk-XMB45ILT.mjs +0 -35
  107. package/dist/chunk-XMB45ILT.mjs.map +0 -1
  108. package/dist/chunk-YKDKFWP2.mjs +0 -19
  109. package/dist/chunk-YKDKFWP2.mjs.map +0 -1
  110. package/dist/chunk-YWNVB7TY.mjs +0 -1
  111. package/dist/chunk-ZOCMUEOX.mjs +0 -1
  112. package/dist/{breadcrumb/breadcrumb.d.mts → breadcrumbs/breadcrumbs.d.mts} +1 -1
  113. package/dist/{breadcrumb/breadcrumb.d.ts → breadcrumbs/breadcrumbs.d.ts} +1 -1
  114. /package/dist/{breadcrumb/breadcrumb.mjs.map → breadcrumbs/breadcrumbs.mjs.map} +0 -0
  115. /package/dist/{breadcrumb → breadcrumbs}/index.d.mts +0 -0
  116. /package/dist/{breadcrumb → breadcrumbs}/index.d.ts +0 -0
  117. /package/dist/{breadcrumb → breadcrumbs}/index.mjs.map +0 -0
  118. /package/dist/{chunk-YWNVB7TY.mjs.map → chunk-3LYJRAOC.mjs.map} +0 -0
  119. /package/dist/{chunk-ZOCMUEOX.mjs.map → chunk-CFAH2LID.mjs.map} +0 -0
  120. /package/dist/{chunk-K2HG7WRK.mjs.map → chunk-CSAEHQ4R.mjs.map} +0 -0
  121. /package/dist/{chunk-ZRFDCZ62.mjs.map → chunk-CSFSJGLY.mjs.map} +0 -0
  122. /package/dist/{chunk-O32FZU7E.mjs.map → chunk-S3BGPCLK.mjs.map} +0 -0
  123. /package/dist/{chunk-FOZSX44S.mjs.map → chunk-VM345XBI.mjs.map} +0 -0
@@ -164,6 +164,12 @@ declare interface AutoAnimateHeightProps {
164
164
  * default is "quick"
165
165
  */
166
166
  animationDuration?: "quick" | "normal" | "slow";
167
+ /**
168
+ * Callback fired when animiation transition ends
169
+ * Use this to do effects after resizing is done, e.g. scrolling to the element
170
+ * using `element.scrollIntoView()`
171
+ */
172
+ onTransitionEnd?: () => void;
167
173
  /**
168
174
  * Which hedwig easing function to use, default is "normal"
169
175
  */
@@ -293,18 +299,14 @@ export { BoxProps as BoxProps_alias_3 }
293
299
  * </nav>
294
300
  * ```
295
301
  */
296
- declare function Breadcrumbs({ olProps, children, ...rest }: BreadcrumbsProps): JSX_2.Element;
297
-
298
- declare namespace Breadcrumbs {
299
- var displayName: string;
300
- }
302
+ declare const Breadcrumbs: ForwardRefExoticComponent<BreadcrumbsProps & RefAttributes<HTMLDivElement>>;
301
303
  export { Breadcrumbs }
302
304
  export { Breadcrumbs as Breadcrumbs_alias_1 }
303
305
  export { Breadcrumbs as Breadcrumbs_alias_2 }
304
306
  export { Breadcrumbs as Breadcrumbs_alias_3 }
305
307
 
306
308
  declare interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
307
- children: ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];
309
+ children: ReactNode | ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];
308
310
  /**
309
311
  * Props passed to the `ol` html element
310
312
  */
@@ -319,27 +321,15 @@ declare type Breakpoints = "initial" | "small" | "medium" | "large" | "xlarge";
319
321
 
320
322
  export declare const ButtonAsLink: Story_18;
321
323
 
322
- declare type ButtonProps = ButtonPropsInternal & ({
323
- /**
324
- * The background fill of the button
325
- */
326
- fill?: "contained" | "outline";
327
- } | {
328
- /**
329
- * @deprecated use `fill='outline'` instead
330
- */
331
- fill?: "outlined";
332
- });
333
- export { ButtonProps }
334
- export { ButtonProps as ButtonProps_alias_1 }
335
- export { ButtonProps as ButtonProps_alias_2 }
336
- export { ButtonProps as ButtonProps_alias_3 }
337
-
338
- declare interface ButtonPropsInternal extends React.ButtonHTMLAttributes<HTMLButtonElement> {
324
+ declare interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
339
325
  /**
340
326
  * The height, font size and padding of the button
341
327
  */
342
328
  size?: "small" | "medium" | "large";
329
+ /**
330
+ * The background fill of the button
331
+ */
332
+ fill?: "contained" | "outline";
343
333
  /**
344
334
  * Make the button use 100% width available.
345
335
  * Using the "mobile" it only stretch to full width on smaller screens
@@ -351,6 +341,10 @@ declare interface ButtonPropsInternal extends React.ButtonHTMLAttributes<HTMLBut
351
341
  icon?: React.ReactNode;
352
342
  children?: React.ReactNode;
353
343
  }
344
+ export { ButtonProps }
345
+ export { ButtonProps as ButtonProps_alias_1 }
346
+ export { ButtonProps as ButtonProps_alias_2 }
347
+ export { ButtonProps as ButtonProps_alias_3 }
354
348
 
355
349
  export declare const Card_alias_2: Story_6;
356
350
 
@@ -742,11 +736,7 @@ export declare const DefaultWithError: Story_15;
742
736
  * </DescriptionList>
743
737
  * ```
744
738
  */
745
- declare function DescriptionList({ variant, className, ...rest }: DescriptionListProps): JSX_2.Element;
746
-
747
- declare namespace DescriptionList {
748
- var displayName: string;
749
- }
739
+ declare const DescriptionList: ForwardRefExoticComponent<DescriptionListProps & RefAttributes<HTMLDListElement>>;
750
740
  export { DescriptionList }
751
741
  export { DescriptionList as DescriptionList_alias_1 }
752
742
  export { DescriptionList as DescriptionList_alias_2 }
@@ -1053,6 +1043,59 @@ declare interface HeadingProps {
1053
1043
  as: React_3.ElementType;
1054
1044
  }
1055
1045
 
1046
+ /**
1047
+ * Show a help text for a word or phrase when clicked
1048
+ *
1049
+ * Useful for providing explanations for domain-specific terms, acronyms or phrases that could do with further elaboration
1050
+ *
1051
+ * **Usage**
1052
+ * ```tsx
1053
+ * <p>
1054
+ * En annen avgjørende faktor for avgifter er om nettbutikken er registrert i{" "}
1055
+ * <HelpText helpText={`VOEC er en forkortelse for "VAT on E-commerce" (mva. på e-handel).`}>
1056
+ * VOEC
1057
+ * </HelpText>
1058
+ * </p>
1059
+ * ```
1060
+ */
1061
+ declare const HelpText: ForwardRefExoticComponent<HelpTextProps & RefAttributes<HTMLButtonElement>>;
1062
+ export { HelpText }
1063
+ export { HelpText as HelpText_alias_1 }
1064
+ export { HelpText as HelpText_alias_2 }
1065
+ export { HelpText as HelpText_alias_3 }
1066
+
1067
+ declare interface HelpTextProps extends React.HTMLAttributes<HTMLButtonElement> {
1068
+ className?: string;
1069
+ /**
1070
+ * The content of the help text, often a word or phrase that could use some explanation
1071
+ */
1072
+ children: React.ReactNode;
1073
+ /**
1074
+ * The help text that will be shown when the user clicks the trigger
1075
+ */
1076
+ helpText: React.ReactNode;
1077
+ /**
1078
+ * The title of the help text. Used by screen readers and if the user hover over the help text
1079
+ */
1080
+ title?: string;
1081
+ /**
1082
+ * Props for the `Box` that contains the help text
1083
+ */
1084
+ boxProps?: React.ComponentProps<typeof BoxComponent>;
1085
+ /**
1086
+ * The side of the trigger the popover should be attached to
1087
+ *
1088
+ * default is `top`
1089
+ */
1090
+ side?: "top" | "right" | "bottom" | "left";
1091
+ /**
1092
+ * The alignment of the popover content
1093
+ *
1094
+ * default is `start`
1095
+ */
1096
+ align?: "center" | "end" | "start";
1097
+ }
1098
+
1056
1099
  export declare const Horizontal: Story_7;
1057
1100
 
1058
1101
  export declare const Horizontal_alias_1: Story_28;
@@ -2013,6 +2056,34 @@ export { TabContentsProps as TabContentsProps_alias_1 }
2013
2056
  export { TabContentsProps as TabContentsProps_alias_2 }
2014
2057
  export { TabContentsProps as TabContentsProps_alias_3 }
2015
2058
 
2059
+ declare const Table: ForwardRefExoticComponent<TableProps & RefAttributes<HTMLTableElement>>;
2060
+ export { Table }
2061
+ export { Table as Table_alias_1 }
2062
+ export { Table as Table_alias_2 }
2063
+ export { Table as Table_alias_3 }
2064
+
2065
+ declare interface TableProps extends React.HTMLAttributes<HTMLTableElement> {
2066
+ className?: string;
2067
+ /**
2068
+ * Size of the table
2069
+ *
2070
+ * Use `compressed` for a more compact table, or `mobile-compressed` for a compact table on mobile screens only.
2071
+ */
2072
+ size?: "default" | "compressed" | "mobile-compressed";
2073
+ /**
2074
+ * The table caption
2075
+ *
2076
+ * You can also set this by passing `<caption>` as a first child of the table
2077
+ */
2078
+ caption?: React.ReactNode;
2079
+ /**
2080
+ * Optional description of the table displayed underneath the table
2081
+ *
2082
+ * Ensures the `aria-describedby` attribute is set on the table, making it accessible for screen readers.
2083
+ */
2084
+ description?: React.ReactNode;
2085
+ }
2086
+
2016
2087
  declare interface TabListProps extends HTMLAttributes<HTMLDivElement> {
2017
2088
  children: ReactElement<TabsTabProps> | ReactElement<TabsTabProps>[];
2018
2089
  /**
@@ -164,6 +164,12 @@ declare interface AutoAnimateHeightProps {
164
164
  * default is "quick"
165
165
  */
166
166
  animationDuration?: "quick" | "normal" | "slow";
167
+ /**
168
+ * Callback fired when animiation transition ends
169
+ * Use this to do effects after resizing is done, e.g. scrolling to the element
170
+ * using `element.scrollIntoView()`
171
+ */
172
+ onTransitionEnd?: () => void;
167
173
  /**
168
174
  * Which hedwig easing function to use, default is "normal"
169
175
  */
@@ -293,18 +299,14 @@ export { BoxProps as BoxProps_alias_3 }
293
299
  * </nav>
294
300
  * ```
295
301
  */
296
- declare function Breadcrumbs({ olProps, children, ...rest }: BreadcrumbsProps): JSX_2.Element;
297
-
298
- declare namespace Breadcrumbs {
299
- var displayName: string;
300
- }
302
+ declare const Breadcrumbs: ForwardRefExoticComponent<BreadcrumbsProps & RefAttributes<HTMLDivElement>>;
301
303
  export { Breadcrumbs }
302
304
  export { Breadcrumbs as Breadcrumbs_alias_1 }
303
305
  export { Breadcrumbs as Breadcrumbs_alias_2 }
304
306
  export { Breadcrumbs as Breadcrumbs_alias_3 }
305
307
 
306
308
  declare interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {
307
- children: ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];
309
+ children: ReactNode | ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];
308
310
  /**
309
311
  * Props passed to the `ol` html element
310
312
  */
@@ -319,27 +321,15 @@ declare type Breakpoints = "initial" | "small" | "medium" | "large" | "xlarge";
319
321
 
320
322
  export declare const ButtonAsLink: Story_18;
321
323
 
322
- declare type ButtonProps = ButtonPropsInternal & ({
323
- /**
324
- * The background fill of the button
325
- */
326
- fill?: "contained" | "outline";
327
- } | {
328
- /**
329
- * @deprecated use `fill='outline'` instead
330
- */
331
- fill?: "outlined";
332
- });
333
- export { ButtonProps }
334
- export { ButtonProps as ButtonProps_alias_1 }
335
- export { ButtonProps as ButtonProps_alias_2 }
336
- export { ButtonProps as ButtonProps_alias_3 }
337
-
338
- declare interface ButtonPropsInternal extends React.ButtonHTMLAttributes<HTMLButtonElement> {
324
+ declare interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
339
325
  /**
340
326
  * The height, font size and padding of the button
341
327
  */
342
328
  size?: "small" | "medium" | "large";
329
+ /**
330
+ * The background fill of the button
331
+ */
332
+ fill?: "contained" | "outline";
343
333
  /**
344
334
  * Make the button use 100% width available.
345
335
  * Using the "mobile" it only stretch to full width on smaller screens
@@ -351,6 +341,10 @@ declare interface ButtonPropsInternal extends React.ButtonHTMLAttributes<HTMLBut
351
341
  icon?: React.ReactNode;
352
342
  children?: React.ReactNode;
353
343
  }
344
+ export { ButtonProps }
345
+ export { ButtonProps as ButtonProps_alias_1 }
346
+ export { ButtonProps as ButtonProps_alias_2 }
347
+ export { ButtonProps as ButtonProps_alias_3 }
354
348
 
355
349
  export declare const Card_alias_2: Story_6;
356
350
 
@@ -742,11 +736,7 @@ export declare const DefaultWithError: Story_15;
742
736
  * </DescriptionList>
743
737
  * ```
744
738
  */
745
- declare function DescriptionList({ variant, className, ...rest }: DescriptionListProps): JSX_2.Element;
746
-
747
- declare namespace DescriptionList {
748
- var displayName: string;
749
- }
739
+ declare const DescriptionList: ForwardRefExoticComponent<DescriptionListProps & RefAttributes<HTMLDListElement>>;
750
740
  export { DescriptionList }
751
741
  export { DescriptionList as DescriptionList_alias_1 }
752
742
  export { DescriptionList as DescriptionList_alias_2 }
@@ -1053,6 +1043,59 @@ declare interface HeadingProps {
1053
1043
  as: React_3.ElementType;
1054
1044
  }
1055
1045
 
1046
+ /**
1047
+ * Show a help text for a word or phrase when clicked
1048
+ *
1049
+ * Useful for providing explanations for domain-specific terms, acronyms or phrases that could do with further elaboration
1050
+ *
1051
+ * **Usage**
1052
+ * ```tsx
1053
+ * <p>
1054
+ * En annen avgjørende faktor for avgifter er om nettbutikken er registrert i{" "}
1055
+ * <HelpText helpText={`VOEC er en forkortelse for "VAT on E-commerce" (mva. på e-handel).`}>
1056
+ * VOEC
1057
+ * </HelpText>
1058
+ * </p>
1059
+ * ```
1060
+ */
1061
+ declare const HelpText: ForwardRefExoticComponent<HelpTextProps & RefAttributes<HTMLButtonElement>>;
1062
+ export { HelpText }
1063
+ export { HelpText as HelpText_alias_1 }
1064
+ export { HelpText as HelpText_alias_2 }
1065
+ export { HelpText as HelpText_alias_3 }
1066
+
1067
+ declare interface HelpTextProps extends React.HTMLAttributes<HTMLButtonElement> {
1068
+ className?: string;
1069
+ /**
1070
+ * The content of the help text, often a word or phrase that could use some explanation
1071
+ */
1072
+ children: React.ReactNode;
1073
+ /**
1074
+ * The help text that will be shown when the user clicks the trigger
1075
+ */
1076
+ helpText: React.ReactNode;
1077
+ /**
1078
+ * The title of the help text. Used by screen readers and if the user hover over the help text
1079
+ */
1080
+ title?: string;
1081
+ /**
1082
+ * Props for the `Box` that contains the help text
1083
+ */
1084
+ boxProps?: React.ComponentProps<typeof BoxComponent>;
1085
+ /**
1086
+ * The side of the trigger the popover should be attached to
1087
+ *
1088
+ * default is `top`
1089
+ */
1090
+ side?: "top" | "right" | "bottom" | "left";
1091
+ /**
1092
+ * The alignment of the popover content
1093
+ *
1094
+ * default is `start`
1095
+ */
1096
+ align?: "center" | "end" | "start";
1097
+ }
1098
+
1056
1099
  export declare const Horizontal: Story_7;
1057
1100
 
1058
1101
  export declare const Horizontal_alias_1: Story_28;
@@ -2013,6 +2056,34 @@ export { TabContentsProps as TabContentsProps_alias_1 }
2013
2056
  export { TabContentsProps as TabContentsProps_alias_2 }
2014
2057
  export { TabContentsProps as TabContentsProps_alias_3 }
2015
2058
 
2059
+ declare const Table: ForwardRefExoticComponent<TableProps & RefAttributes<HTMLTableElement>>;
2060
+ export { Table }
2061
+ export { Table as Table_alias_1 }
2062
+ export { Table as Table_alias_2 }
2063
+ export { Table as Table_alias_3 }
2064
+
2065
+ declare interface TableProps extends React.HTMLAttributes<HTMLTableElement> {
2066
+ className?: string;
2067
+ /**
2068
+ * Size of the table
2069
+ *
2070
+ * Use `compressed` for a more compact table, or `mobile-compressed` for a compact table on mobile screens only.
2071
+ */
2072
+ size?: "default" | "compressed" | "mobile-compressed";
2073
+ /**
2074
+ * The table caption
2075
+ *
2076
+ * You can also set this by passing `<caption>` as a first child of the table
2077
+ */
2078
+ caption?: React.ReactNode;
2079
+ /**
2080
+ * Optional description of the table displayed underneath the table
2081
+ *
2082
+ * Ensures the `aria-describedby` attribute is set on the table, making it accessible for screen readers.
2083
+ */
2084
+ description?: React.ReactNode;
2085
+ }
2086
+
2016
2087
  declare interface TabListProps extends HTMLAttributes<HTMLDivElement> {
2017
2088
  children: ReactElement<TabsTabProps> | ReactElement<TabsTabProps>[];
2018
2089
  /**
@@ -46,23 +46,24 @@ var __copyProps = (to, from, except, desc) => {
46
46
  };
47
47
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
48
48
 
49
- // src/breadcrumb/index.tsx
50
- var breadcrumb_exports = {};
51
- __export(breadcrumb_exports, {
49
+ // src/breadcrumbs/breadcrumbs.tsx
50
+ var breadcrumbs_exports = {};
51
+ __export(breadcrumbs_exports, {
52
52
  Breadcrumbs: () => Breadcrumbs
53
53
  });
54
- module.exports = __toCommonJS(breadcrumb_exports);
55
-
56
- // src/breadcrumb/breadcrumb.tsx
54
+ module.exports = __toCommonJS(breadcrumbs_exports);
55
+ var import_react = require("react");
57
56
  var import_typed_classname = require("@postenbring/hedwig-css/typed-classname");
58
57
  var import_jsx_runtime = require("react/jsx-runtime");
59
- function Breadcrumbs(_a) {
60
- var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
61
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
62
- }
58
+ var Breadcrumbs = (0, import_react.forwardRef)(
59
+ (_a, ref) => {
60
+ var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
61
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({ ref }, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
62
+ }
63
+ );
63
64
  Breadcrumbs.displayName = "Breadcrumbs";
64
65
  // Annotate the CommonJS export names for ESM import in node:
65
66
  0 && (module.exports = {
66
67
  Breadcrumbs
67
68
  });
68
- //# sourceMappingURL=index.js.map
69
+ //# sourceMappingURL=breadcrumbs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/breadcrumbs/breadcrumbs.tsx"],"sourcesContent":["import { forwardRef, type HTMLAttributes, type ReactElement, type ReactNode } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\n\nexport interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {\n children: ReactNode | ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];\n\n /**\n * Props passed to the `ol` html element\n */\n olProps?: HTMLAttributes<HTMLElement>;\n}\n\n/**\n * A breadcrumbs navigation menu\n *\n * **Usage**\n *\n * ```tsx\n * <Breadcrumbs data-testid=\"breadcrumbs\">\n * <li><Link href=\"../\">Previous page</Link></li>\n * <li aria-current=\"page\">Current page</li>\n * </Breadcrumbs>\n * ```\n *\n * Outputs this html structure\n *\n * ```html\n * <nav data-testid=\"breadcrumbs\">\n * <ol>\n * <li><a href=\"../\">Previous page</a></li>\n * <li aria-current=\"page\">Current page</li>\n * </ol>\n * </nav>\n * ```\n */\nexport const Breadcrumbs = forwardRef<HTMLDivElement, BreadcrumbsProps>(\n ({ olProps, children, ...rest }, ref) => {\n return (\n <nav ref={ref} {...rest}>\n <ol {...olProps} className={clsx(\"hds-breadcrumbs\", olProps?.className as undefined)}>\n {children}\n </ol>\n </nav>\n );\n },\n);\nBreadcrumbs.displayName = \"Breadcrumbs\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAmF;AACnF,6BAAqB;AAsCb;AAJD,IAAM,kBAAc;AAAA,EACzB,CAAC,IAAgC,QAAQ;AAAxC,iBAAE,WAAS,SApCd,IAoCG,IAAwB,iBAAxB,IAAwB,CAAtB,WAAS;AACV,WACE,4CAAC,sCAAI,OAAc,OAAlB,EACC,sDAAC,uCAAO,UAAP,EAAgB,eAAW,6BAAK,mBAAmB,mCAAS,SAAsB,GAChF,WACH,IACF;AAAA,EAEJ;AACF;AACA,YAAY,cAAc;","names":[]}
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  Breadcrumbs
3
- } from "../chunk-YKDKFWP2.mjs";
3
+ } from "../chunk-GGEQEVZ4.mjs";
4
4
  import "../chunk-R4SQKVDQ.mjs";
5
5
  export {
6
6
  Breadcrumbs
7
7
  };
8
- //# sourceMappingURL=breadcrumb.mjs.map
8
+ //# sourceMappingURL=breadcrumbs.mjs.map
@@ -46,21 +46,26 @@ var __copyProps = (to, from, except, desc) => {
46
46
  };
47
47
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
48
48
 
49
- // src/breadcrumb/breadcrumb.tsx
50
- var breadcrumb_exports = {};
51
- __export(breadcrumb_exports, {
49
+ // src/breadcrumbs/index.tsx
50
+ var breadcrumbs_exports = {};
51
+ __export(breadcrumbs_exports, {
52
52
  Breadcrumbs: () => Breadcrumbs
53
53
  });
54
- module.exports = __toCommonJS(breadcrumb_exports);
54
+ module.exports = __toCommonJS(breadcrumbs_exports);
55
+
56
+ // src/breadcrumbs/breadcrumbs.tsx
57
+ var import_react = require("react");
55
58
  var import_typed_classname = require("@postenbring/hedwig-css/typed-classname");
56
59
  var import_jsx_runtime = require("react/jsx-runtime");
57
- function Breadcrumbs(_a) {
58
- var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
59
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({}, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
60
- }
60
+ var Breadcrumbs = (0, import_react.forwardRef)(
61
+ (_a, ref) => {
62
+ var _b = _a, { olProps, children } = _b, rest = __objRest(_b, ["olProps", "children"]);
63
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("nav", __spreadProps(__spreadValues({ ref }, rest), { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ol", __spreadProps(__spreadValues({}, olProps), { className: (0, import_typed_classname.clsx)("hds-breadcrumbs", olProps == null ? void 0 : olProps.className), children })) }));
64
+ }
65
+ );
61
66
  Breadcrumbs.displayName = "Breadcrumbs";
62
67
  // Annotate the CommonJS export names for ESM import in node:
63
68
  0 && (module.exports = {
64
69
  Breadcrumbs
65
70
  });
66
- //# sourceMappingURL=breadcrumb.js.map
71
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/breadcrumbs/index.tsx","../../src/breadcrumbs/breadcrumbs.tsx"],"sourcesContent":["export { Breadcrumbs } from \"./breadcrumbs\";\n\nexport type * from \"./breadcrumbs\";\n","import { forwardRef, type HTMLAttributes, type ReactElement, type ReactNode } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\n\nexport interface BreadcrumbsProps extends HTMLAttributes<HTMLOListElement> {\n children: ReactNode | ReactElement<HTMLLIElement> | ReactElement<HTMLLIElement>[];\n\n /**\n * Props passed to the `ol` html element\n */\n olProps?: HTMLAttributes<HTMLElement>;\n}\n\n/**\n * A breadcrumbs navigation menu\n *\n * **Usage**\n *\n * ```tsx\n * <Breadcrumbs data-testid=\"breadcrumbs\">\n * <li><Link href=\"../\">Previous page</Link></li>\n * <li aria-current=\"page\">Current page</li>\n * </Breadcrumbs>\n * ```\n *\n * Outputs this html structure\n *\n * ```html\n * <nav data-testid=\"breadcrumbs\">\n * <ol>\n * <li><a href=\"../\">Previous page</a></li>\n * <li aria-current=\"page\">Current page</li>\n * </ol>\n * </nav>\n * ```\n */\nexport const Breadcrumbs = forwardRef<HTMLDivElement, BreadcrumbsProps>(\n ({ olProps, children, ...rest }, ref) => {\n return (\n <nav ref={ref} {...rest}>\n <ol {...olProps} className={clsx(\"hds-breadcrumbs\", olProps?.className as undefined)}>\n {children}\n </ol>\n </nav>\n );\n },\n);\nBreadcrumbs.displayName = \"Breadcrumbs\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,mBAAmF;AACnF,6BAAqB;AAsCb;AAJD,IAAM,kBAAc;AAAA,EACzB,CAAC,IAAgC,QAAQ;AAAxC,iBAAE,WAAS,SApCd,IAoCG,IAAwB,iBAAxB,IAAwB,CAAtB,WAAS;AACV,WACE,4CAAC,sCAAI,OAAc,OAAlB,EACC,sDAAC,uCAAO,UAAP,EAAgB,eAAW,6BAAK,mBAAmB,mCAAS,SAAsB,GAChF,WACH,IACF;AAAA,EAEJ;AACF;AACA,YAAY,cAAc;","names":[]}
@@ -0,0 +1,9 @@
1
+ import "../chunk-ISAHCU7C.mjs";
2
+ import {
3
+ Breadcrumbs
4
+ } from "../chunk-GGEQEVZ4.mjs";
5
+ import "../chunk-R4SQKVDQ.mjs";
6
+ export {
7
+ Breadcrumbs
8
+ };
9
+ //# sourceMappingURL=index.mjs.map
@@ -78,9 +78,6 @@ var BaseButton = (0, import_react.forwardRef)(
78
78
  "icon",
79
79
  "className"
80
80
  ]);
81
- if (fill === "outlined") {
82
- console.warn("The `fill` value `outlined` is deprecated, use `fill='outline'` instead");
83
- }
84
81
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
85
82
  Component,
86
83
  __spreadProps(__spreadValues({
@@ -89,7 +86,7 @@ var BaseButton = (0, import_react.forwardRef)(
89
86
  `hds-button--${size}`,
90
87
  {
91
88
  [`hds-button--${variant}`]: fill === "contained",
92
- [`hds-button--outline-${variant}`]: fill === "outline" || fill === "outlined",
89
+ [`hds-button--outline-${variant}`]: fill === "outline",
93
90
  "hds-button--full": fullWidth === true,
94
91
  "hds-button--mobile-full": fullWidth === "mobile",
95
92
  "hds-button--icon-only": icon && !children
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/button/button.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\nimport type { OverridableComponent } from \"../utils\";\n\ninterface ButtonPropsInternal extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /**\n * The height, font size and padding of the button\n */\n size?: \"small\" | \"medium\" | \"large\";\n\n /**\n * Make the button use 100% width available.\n * Using the \"mobile\" it only stretch to full width on smaller screens\n */\n fullWidth?: boolean | \"mobile\";\n\n /**\n * Use an icon inside the button\n */\n icon?: React.ReactNode;\n\n children?: React.ReactNode;\n}\n\nexport type ButtonProps = ButtonPropsInternal &\n (\n | {\n /**\n * The background fill of the button\n */\n fill?: \"contained\" | \"outline\";\n }\n | {\n /**\n * @deprecated use `fill='outline'` instead\n */\n fill?: \"outlined\";\n }\n );\n\nexport const BaseButton: OverridableComponent<\n ButtonProps & { variant: \"primary\" | \"secondary\" },\n HTMLButtonElement\n> = forwardRef(\n (\n {\n as: Component = \"button\",\n children,\n variant,\n size = \"medium\",\n fullWidth = false,\n fill = \"contained\",\n icon,\n className,\n ...rest\n },\n ref,\n ) => {\n // TODO: Remove deprecated fill value name at some point\n // Deprecated at 10. march 2024\n if (fill === \"outlined\") {\n // eslint-disable-next-line no-console -- Deprecation warning\n console.warn(\"The `fill` value `outlined` is deprecated, use `fill='outline'` instead\");\n }\n return (\n <Component\n className={clsx(\n \"hds-button\",\n `hds-button--${size}`,\n {\n [`hds-button--${variant}`]: fill === \"contained\",\n [`hds-button--outline-${variant}`]: fill === \"outline\" || fill === \"outlined\",\n \"hds-button--full\": fullWidth === true,\n \"hds-button--mobile-full\": fullWidth === \"mobile\",\n \"hds-button--icon-only\": icon && !children,\n },\n className as undefined,\n )}\n ref={ref}\n {...rest}\n >\n {icon && !children ? icon : null}\n {children}\n </Component>\n );\n },\n);\nBaseButton.displayName = \"BaseButton\";\n\n/**\n * ## TODO\n *\n * - [x] Handle links that looks like buttons\n * - [ ] Revisit how to handle outline\n * - [ ] Figure out outline-white\n */\n\nexport const PrimaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"primary\" />;\n },\n);\n\nPrimaryButton.displayName = \"PrimaryButton\";\n\nexport const SecondaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"secondary\" />;\n },\n);\n\nSecondaryButton.displayName = \"SecondaryButton\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAA2B;AAC3B,6BAAqB;AAgEf;AAzBC,IAAM,iBAGT;AAAA,EACF,CACE,IAWA,QACG;AAZH,iBACE;AAAA,UAAI,YAAY;AAAA,MAChB;AAAA,MACA;AAAA,MACA,OAAO;AAAA,MACP,YAAY;AAAA,MACZ,OAAO;AAAA,MACP;AAAA,MACA;AAAA,IArDN,IA6CI,IASK,iBATL,IASK;AAAA,MARH;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAOF,QAAI,SAAS,YAAY;AAEvB,cAAQ,KAAK,yEAAyE;AAAA,IACxF;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,eAAW;AAAA,UACT;AAAA,UACA,eAAe,IAAI;AAAA,UACnB;AAAA,YACE,CAAC,eAAe,OAAO,EAAE,GAAG,SAAS;AAAA,YACrC,CAAC,uBAAuB,OAAO,EAAE,GAAG,SAAS,aAAa,SAAS;AAAA,YACnE,oBAAoB,cAAc;AAAA,YAClC,2BAA2B,cAAc;AAAA,YACzC,yBAAyB,QAAQ,CAAC;AAAA,UACpC;AAAA,UACA;AAAA,QACF;AAAA,QACA;AAAA,SACI,OAdL;AAAA,QAgBE;AAAA,kBAAQ,CAAC,WAAW,OAAO;AAAA,UAC3B;AAAA;AAAA;AAAA,IACH;AAAA,EAEJ;AACF;AACA,WAAW,cAAc;AAUlB,IAAM,oBAAsE;AAAA,EACjF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,YAAU;AAAA,EAC5D;AACF;AAEA,cAAc,cAAc;AAErB,IAAM,sBAAwE;AAAA,EACnF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,cAAY;AAAA,EAC9D;AACF;AAEA,gBAAgB,cAAc;","names":[]}
1
+ {"version":3,"sources":["../../src/button/button.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\nimport type { OverridableComponent } from \"../utils\";\n\nexport interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /**\n * The height, font size and padding of the button\n */\n size?: \"small\" | \"medium\" | \"large\";\n\n /**\n * The background fill of the button\n */\n fill?: \"contained\" | \"outline\";\n\n /**\n * Make the button use 100% width available.\n * Using the \"mobile\" it only stretch to full width on smaller screens\n */\n fullWidth?: boolean | \"mobile\";\n\n /**\n * Use an icon inside the button\n */\n icon?: React.ReactNode;\n\n children?: React.ReactNode;\n}\n\nexport const BaseButton: OverridableComponent<\n ButtonProps & { variant: \"primary\" | \"secondary\" },\n HTMLButtonElement\n> = forwardRef(\n (\n {\n as: Component = \"button\",\n children,\n variant,\n size = \"medium\",\n fullWidth = false,\n fill = \"contained\",\n icon,\n className,\n ...rest\n },\n ref,\n ) => {\n return (\n <Component\n className={clsx(\n \"hds-button\",\n `hds-button--${size}`,\n {\n [`hds-button--${variant}`]: fill === \"contained\",\n [`hds-button--outline-${variant}`]: fill === \"outline\",\n \"hds-button--full\": fullWidth === true,\n \"hds-button--mobile-full\": fullWidth === \"mobile\",\n \"hds-button--icon-only\": icon && !children,\n },\n className as undefined,\n )}\n ref={ref}\n {...rest}\n >\n {icon && !children ? icon : null}\n {children}\n </Component>\n );\n },\n);\nBaseButton.displayName = \"BaseButton\";\n\n/**\n * ## TODO\n *\n * - [x] Handle links that looks like buttons\n * - [ ] Revisit how to handle outline\n * - [ ] Figure out outline-white\n */\n\nexport const PrimaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"primary\" />;\n },\n);\n\nPrimaryButton.displayName = \"PrimaryButton\";\n\nexport const SecondaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"secondary\" />;\n },\n);\n\nSecondaryButton.displayName = \"SecondaryButton\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAA2B;AAC3B,6BAAqB;AA+Cf;AAnBC,IAAM,iBAGT;AAAA,EACF,CACE,IAWA,QACG;AAZH,iBACE;AAAA,UAAI,YAAY;AAAA,MAChB;AAAA,MACA;AAAA,MACA,OAAO;AAAA,MACP,YAAY;AAAA,MACZ,OAAO;AAAA,MACP;AAAA,MACA;AAAA,IA1CN,IAkCI,IASK,iBATL,IASK;AAAA,MARH;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAKF,WACE;AAAA,MAAC;AAAA;AAAA,QACC,eAAW;AAAA,UACT;AAAA,UACA,eAAe,IAAI;AAAA,UACnB;AAAA,YACE,CAAC,eAAe,OAAO,EAAE,GAAG,SAAS;AAAA,YACrC,CAAC,uBAAuB,OAAO,EAAE,GAAG,SAAS;AAAA,YAC7C,oBAAoB,cAAc;AAAA,YAClC,2BAA2B,cAAc;AAAA,YACzC,yBAAyB,QAAQ,CAAC;AAAA,UACpC;AAAA,UACA;AAAA,QACF;AAAA,QACA;AAAA,SACI,OAdL;AAAA,QAgBE;AAAA,kBAAQ,CAAC,WAAW,OAAO;AAAA,UAC3B;AAAA;AAAA;AAAA,IACH;AAAA,EAEJ;AACF;AACA,WAAW,cAAc;AAUlB,IAAM,oBAAsE;AAAA,EACjF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,YAAU;AAAA,EAC5D;AACF;AAEA,cAAc,cAAc;AAErB,IAAM,sBAAwE;AAAA,EACnF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,cAAY;AAAA,EAC9D;AACF;AAEA,gBAAgB,cAAc;","names":[]}
@@ -2,7 +2,7 @@ import {
2
2
  BaseButton,
3
3
  PrimaryButton,
4
4
  SecondaryButton
5
- } from "../chunk-OUHO4LGN.mjs";
5
+ } from "../chunk-BWFFP6BB.mjs";
6
6
  import "../chunk-R4SQKVDQ.mjs";
7
7
  export {
8
8
  BaseButton,
@@ -79,9 +79,6 @@ var BaseButton = (0, import_react.forwardRef)(
79
79
  "icon",
80
80
  "className"
81
81
  ]);
82
- if (fill === "outlined") {
83
- console.warn("The `fill` value `outlined` is deprecated, use `fill='outline'` instead");
84
- }
85
82
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
86
83
  Component,
87
84
  __spreadProps(__spreadValues({
@@ -90,7 +87,7 @@ var BaseButton = (0, import_react.forwardRef)(
90
87
  `hds-button--${size}`,
91
88
  {
92
89
  [`hds-button--${variant}`]: fill === "contained",
93
- [`hds-button--outline-${variant}`]: fill === "outline" || fill === "outlined",
90
+ [`hds-button--outline-${variant}`]: fill === "outline",
94
91
  "hds-button--full": fullWidth === true,
95
92
  "hds-button--mobile-full": fullWidth === "mobile",
96
93
  "hds-button--icon-only": icon && !children
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/button/index.tsx","../../src/button/button.tsx"],"sourcesContent":["export { PrimaryButton, SecondaryButton } from \"./button\";\n\nexport type * from \"./button\";\n","import { forwardRef } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\nimport type { OverridableComponent } from \"../utils\";\n\ninterface ButtonPropsInternal extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /**\n * The height, font size and padding of the button\n */\n size?: \"small\" | \"medium\" | \"large\";\n\n /**\n * Make the button use 100% width available.\n * Using the \"mobile\" it only stretch to full width on smaller screens\n */\n fullWidth?: boolean | \"mobile\";\n\n /**\n * Use an icon inside the button\n */\n icon?: React.ReactNode;\n\n children?: React.ReactNode;\n}\n\nexport type ButtonProps = ButtonPropsInternal &\n (\n | {\n /**\n * The background fill of the button\n */\n fill?: \"contained\" | \"outline\";\n }\n | {\n /**\n * @deprecated use `fill='outline'` instead\n */\n fill?: \"outlined\";\n }\n );\n\nexport const BaseButton: OverridableComponent<\n ButtonProps & { variant: \"primary\" | \"secondary\" },\n HTMLButtonElement\n> = forwardRef(\n (\n {\n as: Component = \"button\",\n children,\n variant,\n size = \"medium\",\n fullWidth = false,\n fill = \"contained\",\n icon,\n className,\n ...rest\n },\n ref,\n ) => {\n // TODO: Remove deprecated fill value name at some point\n // Deprecated at 10. march 2024\n if (fill === \"outlined\") {\n // eslint-disable-next-line no-console -- Deprecation warning\n console.warn(\"The `fill` value `outlined` is deprecated, use `fill='outline'` instead\");\n }\n return (\n <Component\n className={clsx(\n \"hds-button\",\n `hds-button--${size}`,\n {\n [`hds-button--${variant}`]: fill === \"contained\",\n [`hds-button--outline-${variant}`]: fill === \"outline\" || fill === \"outlined\",\n \"hds-button--full\": fullWidth === true,\n \"hds-button--mobile-full\": fullWidth === \"mobile\",\n \"hds-button--icon-only\": icon && !children,\n },\n className as undefined,\n )}\n ref={ref}\n {...rest}\n >\n {icon && !children ? icon : null}\n {children}\n </Component>\n );\n },\n);\nBaseButton.displayName = \"BaseButton\";\n\n/**\n * ## TODO\n *\n * - [x] Handle links that looks like buttons\n * - [ ] Revisit how to handle outline\n * - [ ] Figure out outline-white\n */\n\nexport const PrimaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"primary\" />;\n },\n);\n\nPrimaryButton.displayName = \"PrimaryButton\";\n\nexport const SecondaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"secondary\" />;\n },\n);\n\nSecondaryButton.displayName = \"SecondaryButton\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,mBAA2B;AAC3B,6BAAqB;AAgEf;AAzBC,IAAM,iBAGT;AAAA,EACF,CACE,IAWA,QACG;AAZH,iBACE;AAAA,UAAI,YAAY;AAAA,MAChB;AAAA,MACA;AAAA,MACA,OAAO;AAAA,MACP,YAAY;AAAA,MACZ,OAAO;AAAA,MACP;AAAA,MACA;AAAA,IArDN,IA6CI,IASK,iBATL,IASK;AAAA,MARH;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAOF,QAAI,SAAS,YAAY;AAEvB,cAAQ,KAAK,yEAAyE;AAAA,IACxF;AACA,WACE;AAAA,MAAC;AAAA;AAAA,QACC,eAAW;AAAA,UACT;AAAA,UACA,eAAe,IAAI;AAAA,UACnB;AAAA,YACE,CAAC,eAAe,OAAO,EAAE,GAAG,SAAS;AAAA,YACrC,CAAC,uBAAuB,OAAO,EAAE,GAAG,SAAS,aAAa,SAAS;AAAA,YACnE,oBAAoB,cAAc;AAAA,YAClC,2BAA2B,cAAc;AAAA,YACzC,yBAAyB,QAAQ,CAAC;AAAA,UACpC;AAAA,UACA;AAAA,QACF;AAAA,QACA;AAAA,SACI,OAdL;AAAA,QAgBE;AAAA,kBAAQ,CAAC,WAAW,OAAO;AAAA,UAC3B;AAAA;AAAA;AAAA,IACH;AAAA,EAEJ;AACF;AACA,WAAW,cAAc;AAUlB,IAAM,oBAAsE;AAAA,EACjF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,YAAU;AAAA,EAC5D;AACF;AAEA,cAAc,cAAc;AAErB,IAAM,sBAAwE;AAAA,EACnF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,cAAY;AAAA,EAC9D;AACF;AAEA,gBAAgB,cAAc;","names":[]}
1
+ {"version":3,"sources":["../../src/button/index.tsx","../../src/button/button.tsx"],"sourcesContent":["export { PrimaryButton, SecondaryButton } from \"./button\";\n\nexport type * from \"./button\";\n","import { forwardRef } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\nimport type { OverridableComponent } from \"../utils\";\n\nexport interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /**\n * The height, font size and padding of the button\n */\n size?: \"small\" | \"medium\" | \"large\";\n\n /**\n * The background fill of the button\n */\n fill?: \"contained\" | \"outline\";\n\n /**\n * Make the button use 100% width available.\n * Using the \"mobile\" it only stretch to full width on smaller screens\n */\n fullWidth?: boolean | \"mobile\";\n\n /**\n * Use an icon inside the button\n */\n icon?: React.ReactNode;\n\n children?: React.ReactNode;\n}\n\nexport const BaseButton: OverridableComponent<\n ButtonProps & { variant: \"primary\" | \"secondary\" },\n HTMLButtonElement\n> = forwardRef(\n (\n {\n as: Component = \"button\",\n children,\n variant,\n size = \"medium\",\n fullWidth = false,\n fill = \"contained\",\n icon,\n className,\n ...rest\n },\n ref,\n ) => {\n return (\n <Component\n className={clsx(\n \"hds-button\",\n `hds-button--${size}`,\n {\n [`hds-button--${variant}`]: fill === \"contained\",\n [`hds-button--outline-${variant}`]: fill === \"outline\",\n \"hds-button--full\": fullWidth === true,\n \"hds-button--mobile-full\": fullWidth === \"mobile\",\n \"hds-button--icon-only\": icon && !children,\n },\n className as undefined,\n )}\n ref={ref}\n {...rest}\n >\n {icon && !children ? icon : null}\n {children}\n </Component>\n );\n },\n);\nBaseButton.displayName = \"BaseButton\";\n\n/**\n * ## TODO\n *\n * - [x] Handle links that looks like buttons\n * - [ ] Revisit how to handle outline\n * - [ ] Figure out outline-white\n */\n\nexport const PrimaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"primary\" />;\n },\n);\n\nPrimaryButton.displayName = \"PrimaryButton\";\n\nexport const SecondaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"secondary\" />;\n },\n);\n\nSecondaryButton.displayName = \"SecondaryButton\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,mBAA2B;AAC3B,6BAAqB;AA+Cf;AAnBC,IAAM,iBAGT;AAAA,EACF,CACE,IAWA,QACG;AAZH,iBACE;AAAA,UAAI,YAAY;AAAA,MAChB;AAAA,MACA;AAAA,MACA,OAAO;AAAA,MACP,YAAY;AAAA,MACZ,OAAO;AAAA,MACP;AAAA,MACA;AAAA,IA1CN,IAkCI,IASK,iBATL,IASK;AAAA,MARH;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAKF,WACE;AAAA,MAAC;AAAA;AAAA,QACC,eAAW;AAAA,UACT;AAAA,UACA,eAAe,IAAI;AAAA,UACnB;AAAA,YACE,CAAC,eAAe,OAAO,EAAE,GAAG,SAAS;AAAA,YACrC,CAAC,uBAAuB,OAAO,EAAE,GAAG,SAAS;AAAA,YAC7C,oBAAoB,cAAc;AAAA,YAClC,2BAA2B,cAAc;AAAA,YACzC,yBAAyB,QAAQ,CAAC;AAAA,UACpC;AAAA,UACA;AAAA,QACF;AAAA,QACA;AAAA,SACI,OAdL;AAAA,QAgBE;AAAA,kBAAQ,CAAC,WAAW,OAAO;AAAA,UAC3B;AAAA;AAAA;AAAA,IACH;AAAA,EAEJ;AACF;AACA,WAAW,cAAc;AAUlB,IAAM,oBAAsE;AAAA,EACjF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,YAAU;AAAA,EAC5D;AACF;AAEA,cAAc,cAAc;AAErB,IAAM,sBAAwE;AAAA,EACnF,CAAC,OAAO,QAAQ;AACd,WAAO,4CAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,cAAY;AAAA,EAC9D;AACF;AAEA,gBAAgB,cAAc;","names":[]}
@@ -2,7 +2,7 @@ import "../chunk-HT2EIJAD.mjs";
2
2
  import {
3
3
  PrimaryButton,
4
4
  SecondaryButton
5
- } from "../chunk-OUHO4LGN.mjs";
5
+ } from "../chunk-BWFFP6BB.mjs";
6
6
  import "../chunk-R4SQKVDQ.mjs";
7
7
  export {
8
8
  PrimaryButton,
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=chunk-3LYJRAOC.mjs.map
@@ -29,9 +29,6 @@ var BaseButton = forwardRef(
29
29
  "icon",
30
30
  "className"
31
31
  ]);
32
- if (fill === "outlined") {
33
- console.warn("The `fill` value `outlined` is deprecated, use `fill='outline'` instead");
34
- }
35
32
  return /* @__PURE__ */ jsxs(
36
33
  Component,
37
34
  __spreadProps(__spreadValues({
@@ -40,7 +37,7 @@ var BaseButton = forwardRef(
40
37
  `hds-button--${size}`,
41
38
  {
42
39
  [`hds-button--${variant}`]: fill === "contained",
43
- [`hds-button--outline-${variant}`]: fill === "outline" || fill === "outlined",
40
+ [`hds-button--outline-${variant}`]: fill === "outline",
44
41
  "hds-button--full": fullWidth === true,
45
42
  "hds-button--mobile-full": fullWidth === "mobile",
46
43
  "hds-button--icon-only": icon && !children
@@ -76,4 +73,4 @@ export {
76
73
  PrimaryButton,
77
74
  SecondaryButton
78
75
  };
79
- //# sourceMappingURL=chunk-OUHO4LGN.mjs.map
76
+ //# sourceMappingURL=chunk-BWFFP6BB.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/button/button.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport { clsx } from \"@postenbring/hedwig-css/typed-classname\";\nimport type { OverridableComponent } from \"../utils\";\n\nexport interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /**\n * The height, font size and padding of the button\n */\n size?: \"small\" | \"medium\" | \"large\";\n\n /**\n * The background fill of the button\n */\n fill?: \"contained\" | \"outline\";\n\n /**\n * Make the button use 100% width available.\n * Using the \"mobile\" it only stretch to full width on smaller screens\n */\n fullWidth?: boolean | \"mobile\";\n\n /**\n * Use an icon inside the button\n */\n icon?: React.ReactNode;\n\n children?: React.ReactNode;\n}\n\nexport const BaseButton: OverridableComponent<\n ButtonProps & { variant: \"primary\" | \"secondary\" },\n HTMLButtonElement\n> = forwardRef(\n (\n {\n as: Component = \"button\",\n children,\n variant,\n size = \"medium\",\n fullWidth = false,\n fill = \"contained\",\n icon,\n className,\n ...rest\n },\n ref,\n ) => {\n return (\n <Component\n className={clsx(\n \"hds-button\",\n `hds-button--${size}`,\n {\n [`hds-button--${variant}`]: fill === \"contained\",\n [`hds-button--outline-${variant}`]: fill === \"outline\",\n \"hds-button--full\": fullWidth === true,\n \"hds-button--mobile-full\": fullWidth === \"mobile\",\n \"hds-button--icon-only\": icon && !children,\n },\n className as undefined,\n )}\n ref={ref}\n {...rest}\n >\n {icon && !children ? icon : null}\n {children}\n </Component>\n );\n },\n);\nBaseButton.displayName = \"BaseButton\";\n\n/**\n * ## TODO\n *\n * - [x] Handle links that looks like buttons\n * - [ ] Revisit how to handle outline\n * - [ ] Figure out outline-white\n */\n\nexport const PrimaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"primary\" />;\n },\n);\n\nPrimaryButton.displayName = \"PrimaryButton\";\n\nexport const SecondaryButton: OverridableComponent<ButtonProps, HTMLButtonElement> = forwardRef(\n (props, ref) => {\n return <BaseButton {...props} ref={ref} variant=\"secondary\" />;\n },\n);\n\nSecondaryButton.displayName = \"SecondaryButton\";\n"],"mappings":";;;;;;;AAAA,SAAS,kBAAkB;AAC3B,SAAS,YAAY;AA+Cf,SAkCK,KAlCL;AAnBC,IAAM,aAGT;AAAA,EACF,CACE,IAWA,QACG;AAZH,iBACE;AAAA,UAAI,YAAY;AAAA,MAChB;AAAA,MACA;AAAA,MACA,OAAO;AAAA,MACP,YAAY;AAAA,MACZ,OAAO;AAAA,MACP;AAAA,MACA;AAAA,IA1CN,IAkCI,IASK,iBATL,IASK;AAAA,MARH;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAKF,WACE;AAAA,MAAC;AAAA;AAAA,QACC,WAAW;AAAA,UACT;AAAA,UACA,eAAe,IAAI;AAAA,UACnB;AAAA,YACE,CAAC,eAAe,OAAO,EAAE,GAAG,SAAS;AAAA,YACrC,CAAC,uBAAuB,OAAO,EAAE,GAAG,SAAS;AAAA,YAC7C,oBAAoB,cAAc;AAAA,YAClC,2BAA2B,cAAc;AAAA,YACzC,yBAAyB,QAAQ,CAAC;AAAA,UACpC;AAAA,UACA;AAAA,QACF;AAAA,QACA;AAAA,SACI,OAdL;AAAA,QAgBE;AAAA,kBAAQ,CAAC,WAAW,OAAO;AAAA,UAC3B;AAAA;AAAA;AAAA,IACH;AAAA,EAEJ;AACF;AACA,WAAW,cAAc;AAUlB,IAAM,gBAAsE;AAAA,EACjF,CAAC,OAAO,QAAQ;AACd,WAAO,oBAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,YAAU;AAAA,EAC5D;AACF;AAEA,cAAc,cAAc;AAErB,IAAM,kBAAwE;AAAA,EACnF,CAAC,OAAO,QAAQ;AACd,WAAO,oBAAC,6CAAe,QAAf,EAAsB,KAAU,SAAQ,cAAY;AAAA,EAC9D;AACF;AAEA,gBAAgB,cAAc;","names":[]}
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=chunk-CFAH2LID.mjs.map
@@ -4,7 +4,7 @@ import {
4
4
  FooterLinkSection,
5
5
  FooterLinkSections,
6
6
  FooterLogo
7
- } from "./chunk-O32FZU7E.mjs";
7
+ } from "./chunk-S3BGPCLK.mjs";
8
8
 
9
9
  // src/footer/index.tsx
10
10
  var FooterComponent = Footer;
@@ -16,4 +16,4 @@ FooterComponent.LinkSection = FooterLinkSection;
16
16
  export {
17
17
  FooterComponent
18
18
  };
19
- //# sourceMappingURL=chunk-K2HG7WRK.mjs.map
19
+ //# sourceMappingURL=chunk-CSAEHQ4R.mjs.map