@digdir/designsystemet-react 1.1.5 → 1.1.6

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 (218) hide show
  1. package/dist/cjs/components/breadcrumbs/index.js +6 -6
  2. package/dist/cjs/components/card/index.js +3 -3
  3. package/dist/cjs/components/chip/index.js +6 -6
  4. package/dist/cjs/components/details/index.js +4 -4
  5. package/dist/cjs/components/dialog/index.js +5 -5
  6. package/dist/cjs/components/dropdown/dropdown-button.js +12 -0
  7. package/dist/cjs/components/dropdown/dropdown-heading.js +8 -0
  8. package/dist/cjs/components/dropdown/dropdown-item.js +12 -0
  9. package/dist/cjs/components/dropdown/dropdown-list.js +12 -0
  10. package/dist/cjs/components/dropdown/dropdown-trigger-context.js +9 -9
  11. package/dist/cjs/components/dropdown/dropdown-trigger.js +16 -0
  12. package/dist/cjs/components/dropdown/index.js +20 -9
  13. package/dist/cjs/components/error-summary/error-summary-heading.js +8 -0
  14. package/dist/cjs/components/error-summary/error-summary-item.js +4 -4
  15. package/dist/cjs/components/error-summary/error-summary-link.js +8 -1
  16. package/dist/cjs/components/error-summary/error-summary-list.js +15 -0
  17. package/dist/cjs/components/error-summary/index.js +6 -6
  18. package/dist/cjs/components/field/field-description.js +6 -0
  19. package/dist/cjs/components/field/index.js +6 -6
  20. package/dist/cjs/components/fieldset/fieldset-description.js +2 -2
  21. package/dist/cjs/components/fieldset/fieldset-legend.js +1 -1
  22. package/dist/cjs/components/fieldset/index.js +4 -4
  23. package/dist/cjs/components/list/index.js +5 -5
  24. package/dist/cjs/components/list/list-item.js +6 -0
  25. package/dist/cjs/components/list/lists.js +8 -8
  26. package/dist/cjs/components/pagination/index.js +5 -5
  27. package/dist/cjs/components/pagination/pagination-button.js +3 -3
  28. package/dist/cjs/components/pagination/pagination-item.js +5 -5
  29. package/dist/cjs/components/pagination/pagination-list.js +5 -5
  30. package/dist/cjs/components/popover/index.js +4 -4
  31. package/dist/cjs/components/popover/popover-trigger-context.js +3 -3
  32. package/dist/cjs/components/popover/popover-trigger.js +6 -6
  33. package/dist/cjs/components/search/index.js +5 -5
  34. package/dist/cjs/components/search/search-button.js +2 -2
  35. package/dist/cjs/components/search/search-clear.js +2 -2
  36. package/dist/cjs/components/search/search-input.js +1 -1
  37. package/dist/cjs/components/select/index.js +4 -4
  38. package/dist/cjs/components/select/select-optgroup.js +4 -4
  39. package/dist/cjs/components/select/select-option.js +2 -2
  40. package/dist/cjs/components/table/index.js +9 -9
  41. package/dist/cjs/components/table/table-body.js +6 -6
  42. package/dist/cjs/components/table/table-cell.js +1 -1
  43. package/dist/cjs/components/table/table-foot.js +6 -6
  44. package/dist/cjs/components/table/table-head.js +6 -6
  45. package/dist/cjs/components/table/table-header-cell.js +1 -1
  46. package/dist/cjs/components/table/table-row.js +4 -4
  47. package/dist/cjs/components/tabs/index.js +5 -5
  48. package/dist/cjs/components/tabs/tabs-list.js +4 -4
  49. package/dist/cjs/components/tabs/tabs-panel.js +1 -1
  50. package/dist/cjs/components/tabs/tabs-tab.js +1 -1
  51. package/dist/cjs/components/toggle-group/index.js +3 -3
  52. package/dist/cjs/components/toggle-group/toggle-group-item.js +1 -1
  53. package/dist/esm/components/breadcrumbs/index.js +7 -7
  54. package/dist/esm/components/card/index.js +4 -4
  55. package/dist/esm/components/checkbox/checkbox.js +2 -2
  56. package/dist/esm/components/chip/index.js +6 -6
  57. package/dist/esm/components/details/index.js +5 -5
  58. package/dist/esm/components/dialog/index.js +6 -6
  59. package/dist/esm/components/dropdown/dropdown-button.js +12 -0
  60. package/dist/esm/components/dropdown/dropdown-heading.js +8 -0
  61. package/dist/esm/components/dropdown/dropdown-item.js +12 -0
  62. package/dist/esm/components/dropdown/dropdown-list.js +12 -0
  63. package/dist/esm/components/dropdown/dropdown-trigger-context.js +9 -9
  64. package/dist/esm/components/dropdown/dropdown-trigger.js +16 -0
  65. package/dist/esm/components/dropdown/index.js +21 -10
  66. package/dist/esm/components/error-summary/error-summary-heading.js +8 -0
  67. package/dist/esm/components/error-summary/error-summary-item.js +4 -4
  68. package/dist/esm/components/error-summary/error-summary-link.js +8 -1
  69. package/dist/esm/components/error-summary/error-summary-list.js +17 -2
  70. package/dist/esm/components/error-summary/index.js +7 -7
  71. package/dist/esm/components/field/field-description.js +6 -0
  72. package/dist/esm/components/field/index.js +7 -7
  73. package/dist/esm/components/fieldset/fieldset-description.js +2 -2
  74. package/dist/esm/components/fieldset/fieldset-legend.js +1 -1
  75. package/dist/esm/components/fieldset/index.js +5 -5
  76. package/dist/esm/components/list/index.js +5 -5
  77. package/dist/esm/components/list/list-item.js +6 -0
  78. package/dist/esm/components/list/lists.js +8 -8
  79. package/dist/esm/components/pagination/index.js +6 -6
  80. package/dist/esm/components/pagination/pagination-button.js +3 -3
  81. package/dist/esm/components/pagination/pagination-item.js +5 -5
  82. package/dist/esm/components/pagination/pagination-list.js +5 -5
  83. package/dist/esm/components/popover/index.js +5 -5
  84. package/dist/esm/components/popover/popover-trigger-context.js +3 -3
  85. package/dist/esm/components/popover/popover-trigger.js +6 -6
  86. package/dist/esm/components/radio/radio.js +2 -2
  87. package/dist/esm/components/search/index.js +6 -6
  88. package/dist/esm/components/search/search-button.js +2 -2
  89. package/dist/esm/components/search/search-clear.js +2 -2
  90. package/dist/esm/components/search/search-input.js +1 -1
  91. package/dist/esm/components/select/index.js +5 -5
  92. package/dist/esm/components/select/select-optgroup.js +4 -4
  93. package/dist/esm/components/select/select-option.js +2 -2
  94. package/dist/esm/components/suggestion/suggestion.js +2 -2
  95. package/dist/esm/components/switch/switch.js +2 -2
  96. package/dist/esm/components/table/index.js +10 -10
  97. package/dist/esm/components/table/table-body.js +6 -6
  98. package/dist/esm/components/table/table-cell.js +1 -1
  99. package/dist/esm/components/table/table-foot.js +6 -6
  100. package/dist/esm/components/table/table-head.js +6 -6
  101. package/dist/esm/components/table/table-header-cell.js +1 -1
  102. package/dist/esm/components/table/table-row.js +4 -4
  103. package/dist/esm/components/tabs/index.js +6 -6
  104. package/dist/esm/components/tabs/tabs-list.js +4 -4
  105. package/dist/esm/components/tabs/tabs-panel.js +1 -1
  106. package/dist/esm/components/tabs/tabs-tab.js +1 -1
  107. package/dist/esm/components/textfield/textfield.js +2 -2
  108. package/dist/esm/components/toggle-group/index.js +4 -4
  109. package/dist/esm/components/toggle-group/toggle-group-item.js +1 -1
  110. package/dist/react-types.d.ts +1 -2
  111. package/dist/types/colors.d.ts +1 -23
  112. package/dist/types/colors.d.ts.map +1 -1
  113. package/dist/types/components/Combobox/Combobox.d.ts +2 -2
  114. package/dist/types/components/Combobox/useFormField/useFormField.d.ts +1 -1
  115. package/dist/types/components/Combobox/useFormField/useFormField.d.ts.map +1 -1
  116. package/dist/types/components/alert/alert.d.ts +1 -1
  117. package/dist/types/components/alert/alert.d.ts.map +1 -1
  118. package/dist/types/components/avatar/avatar.d.ts +2 -1
  119. package/dist/types/components/avatar/avatar.d.ts.map +1 -1
  120. package/dist/types/components/badge/badge.d.ts +1 -1
  121. package/dist/types/components/badge/badge.d.ts.map +1 -1
  122. package/dist/types/components/badge/index.d.ts +1 -1
  123. package/dist/types/components/breadcrumbs/index.d.ts +48 -12
  124. package/dist/types/components/breadcrumbs/index.d.ts.map +1 -1
  125. package/dist/types/components/button/button.d.ts +3 -3
  126. package/dist/types/components/button/button.d.ts.map +1 -1
  127. package/dist/types/components/card/index.d.ts +18 -10
  128. package/dist/types/components/card/index.d.ts.map +1 -1
  129. package/dist/types/components/chip/index.d.ts +33 -14
  130. package/dist/types/components/chip/index.d.ts.map +1 -1
  131. package/dist/types/components/details/index.d.ts +19 -7
  132. package/dist/types/components/details/index.d.ts.map +1 -1
  133. package/dist/types/components/dialog/dialog-trigger.d.ts +1 -1
  134. package/dist/types/components/dialog/index.d.ts +46 -25
  135. package/dist/types/components/dialog/index.d.ts.map +1 -1
  136. package/dist/types/components/dropdown/dropdown-button.d.ts +12 -0
  137. package/dist/types/components/dropdown/dropdown-button.d.ts.map +1 -1
  138. package/dist/types/components/dropdown/dropdown-heading.d.ts +8 -0
  139. package/dist/types/components/dropdown/dropdown-heading.d.ts.map +1 -1
  140. package/dist/types/components/dropdown/dropdown-item.d.ts +12 -0
  141. package/dist/types/components/dropdown/dropdown-item.d.ts.map +1 -1
  142. package/dist/types/components/dropdown/dropdown-list.d.ts +12 -0
  143. package/dist/types/components/dropdown/dropdown-list.d.ts.map +1 -1
  144. package/dist/types/components/dropdown/dropdown-trigger-context.d.ts +9 -9
  145. package/dist/types/components/dropdown/dropdown-trigger.d.ts +16 -0
  146. package/dist/types/components/dropdown/dropdown-trigger.d.ts.map +1 -1
  147. package/dist/types/components/dropdown/index.d.ts +99 -19
  148. package/dist/types/components/dropdown/index.d.ts.map +1 -1
  149. package/dist/types/components/error-summary/error-summary-heading.d.ts +8 -0
  150. package/dist/types/components/error-summary/error-summary-heading.d.ts.map +1 -1
  151. package/dist/types/components/error-summary/error-summary-item.d.ts +4 -4
  152. package/dist/types/components/error-summary/error-summary-link.d.ts +8 -1
  153. package/dist/types/components/error-summary/error-summary-link.d.ts.map +1 -1
  154. package/dist/types/components/error-summary/error-summary-list.d.ts +15 -0
  155. package/dist/types/components/error-summary/error-summary-list.d.ts.map +1 -1
  156. package/dist/types/components/error-summary/index.d.ts +52 -20
  157. package/dist/types/components/error-summary/index.d.ts.map +1 -1
  158. package/dist/types/components/field/field-counter.d.ts +1 -1
  159. package/dist/types/components/field/field-description.d.ts +6 -0
  160. package/dist/types/components/field/field-description.d.ts.map +1 -1
  161. package/dist/types/components/field/index.d.ts +45 -17
  162. package/dist/types/components/field/index.d.ts.map +1 -1
  163. package/dist/types/components/fieldset/fieldset-description.d.ts +2 -2
  164. package/dist/types/components/fieldset/fieldset-legend.d.ts +1 -1
  165. package/dist/types/components/fieldset/index.d.ts +21 -9
  166. package/dist/types/components/fieldset/index.d.ts.map +1 -1
  167. package/dist/types/components/list/index.d.ts +32 -11
  168. package/dist/types/components/list/index.d.ts.map +1 -1
  169. package/dist/types/components/list/list-item.d.ts +6 -0
  170. package/dist/types/components/list/list-item.d.ts.map +1 -1
  171. package/dist/types/components/list/lists.d.ts +8 -8
  172. package/dist/types/components/pagination/index.d.ts +38 -15
  173. package/dist/types/components/pagination/index.d.ts.map +1 -1
  174. package/dist/types/components/pagination/pagination-button.d.ts +3 -3
  175. package/dist/types/components/pagination/pagination-item.d.ts +5 -5
  176. package/dist/types/components/pagination/pagination-list.d.ts +5 -5
  177. package/dist/types/components/popover/index.d.ts +39 -18
  178. package/dist/types/components/popover/index.d.ts.map +1 -1
  179. package/dist/types/components/popover/popover-trigger-context.d.ts +3 -3
  180. package/dist/types/components/popover/popover-trigger.d.ts +6 -6
  181. package/dist/types/components/popover/popover.d.ts +1 -1
  182. package/dist/types/components/popover/popover.d.ts.map +1 -1
  183. package/dist/types/components/search/index.d.ts +34 -15
  184. package/dist/types/components/search/index.d.ts.map +1 -1
  185. package/dist/types/components/search/search-button.d.ts +3 -3
  186. package/dist/types/components/search/search-clear.d.ts +2 -2
  187. package/dist/types/components/search/search-input.d.ts +1 -1
  188. package/dist/types/components/select/index.d.ts +27 -12
  189. package/dist/types/components/select/index.d.ts.map +1 -1
  190. package/dist/types/components/select/select-optgroup.d.ts +4 -4
  191. package/dist/types/components/select/select-option.d.ts +2 -2
  192. package/dist/types/components/suggestion/suggestion.d.ts +8 -8
  193. package/dist/types/components/table/index.d.ts +65 -16
  194. package/dist/types/components/table/index.d.ts.map +1 -1
  195. package/dist/types/components/table/table-body.d.ts +6 -6
  196. package/dist/types/components/table/table-cell.d.ts +1 -1
  197. package/dist/types/components/table/table-foot.d.ts +6 -6
  198. package/dist/types/components/table/table-head.d.ts +6 -6
  199. package/dist/types/components/table/table-header-cell.d.ts +1 -1
  200. package/dist/types/components/table/table-row.d.ts +4 -4
  201. package/dist/types/components/tabs/index.d.ts +29 -14
  202. package/dist/types/components/tabs/index.d.ts.map +1 -1
  203. package/dist/types/components/tabs/tabs-list.d.ts +4 -4
  204. package/dist/types/components/tabs/tabs-panel.d.ts +1 -1
  205. package/dist/types/components/tabs/tabs-tab.d.ts +1 -1
  206. package/dist/types/components/tag/tag.d.ts +1 -1
  207. package/dist/types/components/tag/tag.d.ts.map +1 -1
  208. package/dist/types/components/toggle-group/index.d.ts +11 -11
  209. package/dist/types/components/toggle-group/index.d.ts.map +1 -1
  210. package/dist/types/components/toggle-group/toggle-group-item.d.ts +1 -1
  211. package/dist/types/components/validation-message/validation-message.d.ts +1 -1
  212. package/dist/types/components/validation-message/validation-message.d.ts.map +1 -1
  213. package/dist/types/index.d.ts +4 -1
  214. package/dist/types/index.d.ts.map +1 -1
  215. package/dist/types/types.d.ts +1 -1
  216. package/dist/types/types.d.ts.map +1 -1
  217. package/dist/types/utilities/roving-focus/use-roving-focus.d.ts +2 -2
  218. package/package.json +8 -7
@@ -1,4 +1,4 @@
1
- import type { Color, SeverityColors } from '@digdir/designsystemet-react/colors';
1
+ import type { Color, SeverityColors } from '@digdir/designsystemet/types';
2
2
  import type { Placement } from '@floating-ui/dom';
3
3
  import type { HTMLAttributes } from 'react';
4
4
  import type { DefaultProps } from '../../types';
@@ -1 +1 @@
1
- {"version":3,"file":"popover.d.ts","sourceRoot":"","sources":["../../../src/components/popover/popover.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,KAAK,EACL,cAAc,EACf,MAAM,qCAAqC,CAAC;AAC7C,OAAO,KAAK,EAAmB,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAUnE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAMlD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,KAAK,CAAC,GAAG,CAAC;QAClB,UAAU,mBAAmB;YAC3B,aAAa,CAAC,EAAE,MAAM,CAAC;SACxB;KACF;IACD,UAAU,KAAK,CAAC;QAEd,UAAU,cAAc,CAAC,CAAC;YACxB,aAAa,CAAC,EAAE,MAAM,CAAC;SACxB;KACF;CACF;AAED,MAAM,MAAM,YAAY,GAAG,UAAU,CACnC,YAAY,GAAG,cAAc,CAAC,cAAc,CAAC,EAC7C;IACE;;OAEG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;;OAGG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB;;;OAGG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;;;;OAIG;IACH,OAAO,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC/B;;OAEG;IACH,YAAY,CAAC,EAAE,KAAK,GAAG,cAAc,CAAC;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;OAGG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CACF,CAAC;AAEF;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,OAAO;IA9DhB;;OAEG;SACE,MAAM;IACX;;;OAGG;gBACS,SAAS;IACrB;;;OAGG;WACI,OAAO;IACd;;;;OAIG;cACO,SAAS,GAAG,QAAQ;IAC9B;;OAEG;mBACY,KAAK,GAAG,cAAc;IACrC;;OAEG;aACM,MAAM,IAAI;IACnB;;OAEG;cACO,MAAM,IAAI;IACpB;;;OAGG;oBACa,OAAO;IACvB;;;OAGG;cACO,OAAO;wCAgIpB,CAAC"}
1
+ {"version":3,"file":"popover.d.ts","sourceRoot":"","sources":["../../../src/components/popover/popover.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC1E,OAAO,KAAK,EAAmB,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAUnE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAMlD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,KAAK,CAAC,GAAG,CAAC;QAClB,UAAU,mBAAmB;YAC3B,aAAa,CAAC,EAAE,MAAM,CAAC;SACxB;KACF;IACD,UAAU,KAAK,CAAC;QAEd,UAAU,cAAc,CAAC,CAAC;YACxB,aAAa,CAAC,EAAE,MAAM,CAAC;SACxB;KACF;CACF;AAED,MAAM,MAAM,YAAY,GAAG,UAAU,CACnC,YAAY,GAAG,cAAc,CAAC,cAAc,CAAC,EAC7C;IACE;;OAEG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;;OAGG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB;;;OAGG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;;;;OAIG;IACH,OAAO,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC;IAC/B;;OAEG;IACH,YAAY,CAAC,EAAE,KAAK,GAAG,cAAc,CAAC;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;OAGG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CACF,CAAC;AAEF;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,OAAO;IA9DhB;;OAEG;SACE,MAAM;IACX;;;OAGG;gBACS,SAAS;IACrB;;;OAGG;WACI,OAAO;IACd;;;;OAIG;cACO,SAAS,GAAG,QAAQ;IAC9B;;OAEG;mBACY,KAAK,GAAG,cAAc;IACrC;;OAEG;aACM,MAAM,IAAI;IACnB;;OAEG;cACO,MAAM,IAAI;IACpB;;;OAGG;oBACa,OAAO;IACvB;;;OAGG;cACO,OAAO;wCAgIpB,CAAC"}
@@ -1,6 +1,38 @@
1
+ import { Search as SearchRoot } from './search';
1
2
  import { SearchButton } from './search-button';
2
3
  import { SearchClear } from './search-clear';
3
4
  import { SearchInput } from './search-input';
5
+ type Search = typeof SearchRoot & {
6
+ /**
7
+ * Search.Clear component, used to display a clear button when the search input is not empty.
8
+ *
9
+ * @example
10
+ * <Search>
11
+ * <Search.Input aria-label='Søk' />
12
+ * <Search.Clear />
13
+ * </Search>
14
+ */
15
+ Clear: typeof SearchClear;
16
+ /**
17
+ * Search.Button component, used to display a search button within a Search component.
18
+ *
19
+ * @example
20
+ * <Search>
21
+ * <Search.Input aria-label='Søk' />
22
+ * <Search.Button>Søk</Search.Button>
23
+ * </Search>
24
+ */
25
+ Button: typeof SearchButton;
26
+ /**
27
+ * Search.Input component, used to display a search input within the Search component.
28
+ *
29
+ * @example
30
+ * <Search>
31
+ * <Search.Input aria-label='Søk' />
32
+ * </Search>
33
+ */
34
+ Input: typeof SearchInput;
35
+ };
4
36
  /**
5
37
  * Search component, use to display different variations of a search input
6
38
  *
@@ -17,23 +49,10 @@ import { SearchInput } from './search-input';
17
49
  * <Search.Clear />
18
50
  * </Search>
19
51
  */
20
- declare const Search: React.ForwardRefExoticComponent<import("../../types").DefaultProps & React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>> & {
21
- Clear: React.ForwardRefExoticComponent<Omit<import("..").ButtonProps, "children" | "variant"> & {
22
- 'aria-label'?: string;
23
- } & React.RefAttributes<HTMLButtonElement>>;
24
- Button: React.ForwardRefExoticComponent<Omit<import("../../types").DefaultProps & React.ButtonHTMLAttributes<HTMLButtonElement>, "type" | "data-color" | "variant" | "icon" | "loading" | "asChild"> & {
25
- variant?: "primary" | "secondary" | "tertiary";
26
- 'data-color'?: import("../../colors").Color | import("../../colors").SeverityDanger;
27
- icon?: boolean;
28
- loading?: boolean | React.ReactNode;
29
- asChild?: boolean;
30
- type?: React.ButtonHTMLAttributes<HTMLButtonElement>["type"];
31
- } & React.RefAttributes<HTMLButtonElement>>;
32
- Input: React.ForwardRefExoticComponent<import("../../types").DefaultProps & Omit<React.InputHTMLAttributes<HTMLInputElement>, "type" | "readOnly"> & React.RefAttributes<HTMLInputElement>>;
33
- };
52
+ declare const SearchComponent: Search;
34
53
  export type { SearchProps } from './search';
35
54
  export type { SearchButtonProps } from './search-button';
36
55
  export type { SearchClearProps } from './search-clear';
37
56
  export type { SearchInputProps } from './search-input';
38
- export { SearchClear, SearchButton, SearchInput, Search };
57
+ export { SearchClear, SearchButton, SearchInput, SearchComponent as Search };
39
58
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/search/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C;;;;;;;;;;;;;;;GAeG;AACH,QAAA,MAAM,MAAM;;;;;;;;;;;;;CAIV,CAAC;AAMH,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACzD,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/search/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,UAAU,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,KAAK,MAAM,GAAG,OAAO,UAAU,GAAG;IAChC;;;;;;;;OAQG;IACH,KAAK,EAAE,OAAO,WAAW,CAAC;IAC1B;;;;;;;;OAQG;IACH,MAAM,EAAE,OAAO,YAAY,CAAC;IAC5B;;;;;;;OAOG;IACH,KAAK,EAAE,OAAO,WAAW,CAAC;CAC3B,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,QAAA,MAAM,eAAe,EAAE,MAIrB,CAAC;AAMH,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACzD,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,WAAW,EAAE,eAAe,IAAI,MAAM,EAAE,CAAC"}
@@ -18,13 +18,13 @@ export type SearchButtonProps = MergeRight<ButtonProps, {
18
18
  *
19
19
  * @example
20
20
  * <Search>
21
- * <Search.Input aria-label='Søk' />
22
- * <Search.Button>Søk</Search.Button>
21
+ * <SearchInput aria-label='Søk' />
22
+ * <SearchButton>Søk</SearchButton>
23
23
  * </Search>
24
24
  */
25
25
  export declare const SearchButton: React.ForwardRefExoticComponent<Omit<import("../../types").DefaultProps & React.ButtonHTMLAttributes<HTMLButtonElement>, "type" | "data-color" | "variant" | "icon" | "loading" | "asChild"> & {
26
26
  variant?: "primary" | "secondary" | "tertiary";
27
- 'data-color'?: import("../../colors").Color | import("../../colors").SeverityDanger;
27
+ 'data-color'?: import("packages/cli/dist/src/types").Color | Extract<import("packages/cli/dist/src/types").SeverityColors, "danger">;
28
28
  icon?: boolean;
29
29
  loading?: boolean | ReactNode;
30
30
  asChild?: boolean;
@@ -11,8 +11,8 @@ export type SearchClearProps = Omit<ButtonProps, 'variant' | 'children'> & {
11
11
  *
12
12
  * @example
13
13
  * <Search>
14
- * <Search.Input aria-label='Søk' />
15
- * <Search.Clear />
14
+ * <SearchInput aria-label='Søk' />
15
+ * <SearchClear />
16
16
  * </Search>
17
17
  */
18
18
  export declare const SearchClear: React.ForwardRefExoticComponent<Omit<ButtonProps, "children" | "variant"> & {
@@ -5,7 +5,7 @@ export type SearchInputProps = DefaultProps & Omit<React.InputHTMLAttributes<HTM
5
5
  *
6
6
  * @example
7
7
  * <Search>
8
- * <Search.Input aria-label='Søk' />
8
+ * <SearchInput aria-label='Søk' />
9
9
  * </Search>
10
10
  */
11
11
  export declare const SearchInput: React.ForwardRefExoticComponent<DefaultProps & Omit<React.InputHTMLAttributes<HTMLInputElement>, "type" | "readOnly"> & React.RefAttributes<HTMLInputElement>>;
@@ -1,5 +1,30 @@
1
+ import { Select as SelectParent } from './select';
1
2
  import { SelectOptgroup } from './select-optgroup';
2
3
  import { SelectOption } from './select-option';
4
+ type Select = typeof SelectParent & {
5
+ /**
6
+ * Select.Option component, used to display a native option within a select.
7
+ *
8
+ * @example
9
+ * <Select>
10
+ * <Select.Option value='1'>Option 1</Select.Option>
11
+ * <Select.Option value='2'>Option 2</Select.Option>
12
+ * </Select>
13
+ */
14
+ Option: typeof SelectOption;
15
+ /**
16
+ * Select.Optgroup component, used to display a native optgroup within a select.
17
+ *
18
+ * @example
19
+ * <Select>
20
+ * <Select.Optgroup label='Group 1'>
21
+ * <Select.Option value='1'>Option 1</Select.Option>
22
+ * <Select.Option value='2'>Option 2</Select.Option>
23
+ * </Select.Optgroup>
24
+ * </Select>
25
+ */
26
+ Optgroup: typeof SelectOptgroup;
27
+ };
3
28
  /**
4
29
  * Select component, used to display a native select.
5
30
  *
@@ -9,19 +34,9 @@ import { SelectOption } from './select-option';
9
34
  * <Select.Option value='2'>Option 2</Select.Option>
10
35
  * </Select>
11
36
  */
12
- declare const Select: React.ForwardRefExoticComponent<Omit<Omit<import("../../types").DefaultProps, "data-color"> & Omit<React.SelectHTMLAttributes<HTMLSelectElement>, "multiple" | "size">, "readOnly" | "width"> & {
13
- readOnly?: boolean;
14
- width?: "full" | "auto";
15
- } & React.RefAttributes<HTMLSelectElement>> & {
16
- Option: React.ForwardRefExoticComponent<{
17
- asChild?: boolean;
18
- } & React.OptionHTMLAttributes<HTMLOptionElement> & React.RefAttributes<HTMLOptionElement>>;
19
- Optgroup: React.ForwardRefExoticComponent<{
20
- asChild?: boolean;
21
- } & React.OptgroupHTMLAttributes<HTMLOptGroupElement> & React.RefAttributes<HTMLOptGroupElement>>;
22
- };
37
+ declare const SelectComponent: Select;
23
38
  export type { SelectProps } from './select';
24
39
  export type { SelectOptgroupProps } from './select-optgroup';
25
40
  export type { SelectOptionProps } from './select-option';
26
- export { Select, SelectOption, SelectOptgroup };
41
+ export { SelectComponent as Select, SelectOption, SelectOptgroup };
27
42
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/select/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C;;;;;;;;GAQG;AACH,QAAA,MAAM,MAAM;;;;;;;;;;CAGV,CAAC;AAKH,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,YAAY,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,EAAE,MAAM,EAAE,YAAY,EAAE,cAAc,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/select/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,YAAY,EAAE,MAAM,UAAU,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C,KAAK,MAAM,GAAG,OAAO,YAAY,GAAG;IAClC;;;;;;;;OAQG;IACH,MAAM,EAAE,OAAO,YAAY,CAAC;IAC5B;;;;;;;;;;OAUG;IACH,QAAQ,EAAE,OAAO,cAAc,CAAC;CACjC,CAAC;AAEF;;;;;;;;GAQG;AACH,QAAA,MAAM,eAAe,EAAE,MAGrB,CAAC;AAKH,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,YAAY,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACzD,OAAO,EAAE,eAAe,IAAI,MAAM,EAAE,YAAY,EAAE,cAAc,EAAE,CAAC"}
@@ -11,10 +11,10 @@ export type SelectOptgroupProps = {
11
11
  *
12
12
  * @example
13
13
  * <Select>
14
- * <Select.Optgroup label='Group 1'>
15
- * <Select.Option value='1'>Option 1</Select.Option>
16
- * <Select.Option value='2'>Option 2</Select.Option>
17
- * </Select.Optgroup>
14
+ * <SelectOptgroup label='Group 1'>
15
+ * <SelectOption value='1'>Option 1</SelectOption>
16
+ * <SelectOption value='2'>Option 2</SelectOption>
17
+ * </SelectOptgroup>
18
18
  * </Select>
19
19
  */
20
20
  export declare const SelectOptgroup: React.ForwardRefExoticComponent<{
@@ -11,8 +11,8 @@ export type SelectOptionProps = {
11
11
  *
12
12
  * @example
13
13
  * <Select>
14
- * <Select.Option value='1'>Option 1</Select.Option>
15
- * <Select.Option value='2'>Option 2</Select.Option>
14
+ * <SelectOption value='1'>Option 1</SelectOption>
15
+ * <SelectOption value='2'>Option 2</SelectOption>
16
16
  * </Select>
17
17
  */
18
18
  export declare const SelectOption: React.ForwardRefExoticComponent<{
@@ -69,11 +69,11 @@ export type SuggestionProps = {
69
69
  *
70
70
  * If `label` and `value` is different, you must use `{ value: string; label: string}[]`.
71
71
  *
72
- * Using this makes the component controlled and it must be used in combination with {@linkcode SuggestionProps.onSelectedChange|onSelectedChange}.
72
+ * Using this makes the component controlled and it must be used in combination with `onSelectedChange`.
73
73
  */
74
74
  selected?: SuggestionSelected;
75
75
  /**
76
- * @deprecated Use {@linkcode SuggestionProps.selected|selected} instead
76
+ * @deprecated Use `selected` instead
77
77
  */
78
78
  value?: SuggestionSelected;
79
79
  /**
@@ -81,7 +81,7 @@ export type SuggestionProps = {
81
81
  */
82
82
  defaultSelected?: SuggestionSelected;
83
83
  /**
84
- * @deprecated Use `{@linkcode SuggestionProps.defaultSelected|defaultSelected} instead
84
+ * @deprecated Use `defaultSelected` instead
85
85
  */
86
86
  defaultValue?: SuggestionSelected;
87
87
  /**
@@ -89,7 +89,7 @@ export type SuggestionProps = {
89
89
  */
90
90
  onSelectedChange?: (value: Item[]) => void;
91
91
  /**
92
- * @deprecated Use {@linkcode SuggestionProps.onSelectedChange|onSelectedChange} instead
92
+ * @deprecated Use `onSelectedChange` instead
93
93
  */
94
94
  onValueChange?: (value: Item[]) => void;
95
95
  /**
@@ -140,11 +140,11 @@ export declare const Suggestion: React.ForwardRefExoticComponent<{
140
140
  *
141
141
  * If `label` and `value` is different, you must use `{ value: string; label: string}[]`.
142
142
  *
143
- * Using this makes the component controlled and it must be used in combination with {@linkcode SuggestionProps.onSelectedChange|onSelectedChange}.
143
+ * Using this makes the component controlled and it must be used in combination with `onSelectedChange`.
144
144
  */
145
145
  selected?: SuggestionSelected;
146
146
  /**
147
- * @deprecated Use {@linkcode SuggestionProps.selected|selected} instead
147
+ * @deprecated Use `selected` instead
148
148
  */
149
149
  value?: SuggestionSelected;
150
150
  /**
@@ -152,7 +152,7 @@ export declare const Suggestion: React.ForwardRefExoticComponent<{
152
152
  */
153
153
  defaultSelected?: SuggestionSelected;
154
154
  /**
155
- * @deprecated Use `{@linkcode SuggestionProps.defaultSelected|defaultSelected} instead
155
+ * @deprecated Use `defaultSelected` instead
156
156
  */
157
157
  defaultValue?: SuggestionSelected;
158
158
  /**
@@ -160,7 +160,7 @@ export declare const Suggestion: React.ForwardRefExoticComponent<{
160
160
  */
161
161
  onSelectedChange?: (value: Item[]) => void;
162
162
  /**
163
- * @deprecated Use {@linkcode SuggestionProps.onSelectedChange|onSelectedChange} instead
163
+ * @deprecated Use `onSelectedChange` instead
164
164
  */
165
165
  onValueChange?: (value: Item[]) => void;
166
166
  /**
@@ -1,4 +1,5 @@
1
1
  import type { TableProps } from './table';
2
+ import { Table as TableRoot } from './table';
2
3
  import type { TableBodyProps } from './table-body';
3
4
  import { TableBody } from './table-body';
4
5
  import type { TableCellProps } from './table-cell';
@@ -11,6 +12,68 @@ import type { TableHeaderCellProps } from './table-header-cell';
11
12
  import { TableHeaderCell } from './table-header-cell';
12
13
  import type { TableRowProps } from './table-row';
13
14
  import { TableRow } from './table-row';
15
+ type Table = typeof TableRoot & {
16
+ /**
17
+ * TableHead component, used to display the header of a table. Renders a native HTML thead element.
18
+ *
19
+ * @example
20
+ * <Table.Head>
21
+ * <Table.Row>
22
+ * <Table.HeaderCell>Name</Table.HeaderCell>
23
+ * <Table.HeaderCell>Age</Table.HeaderCell>
24
+ * </Table.Row>
25
+ * </Table.Head>
26
+ */
27
+ Head: typeof TableHead;
28
+ /**
29
+ * Table.Body component, used to display the body of a table. Renders a native HTML tbody element.
30
+ *
31
+ * @example
32
+ * <Table.Body>
33
+ * <Table.Row>
34
+ * <Table.Cell>John</Table.Cell>
35
+ * <Table.Cell>25</Table.Cell>
36
+ * </Table.Row>
37
+ * </Table.Body>
38
+ */
39
+ Body: typeof TableBody;
40
+ /**
41
+ * Table.Row component, used to display the rows of a table. Renders a native HTML tr element.
42
+ *
43
+ * @example
44
+ * <Table.Row>
45
+ * <Table.Cell>John</Table.Cell>
46
+ * <Table.Cell>25</Table.Cell>
47
+ * </Table.Row>
48
+ */
49
+ Row: typeof TableRow;
50
+ /**
51
+ * Table.Cell component, used to display the cells of a table. Renders a native HTML td element.
52
+ *
53
+ * @example
54
+ * <Table.Cell>John</Table.Cell>
55
+ */
56
+ Cell: typeof TableCell;
57
+ /**
58
+ * Table.HeaderCell component, used to display the header cells of a table. Renders a native HTML th element.
59
+ *
60
+ * @example
61
+ * <Table.HeaderCell>Name</Table.HeaderCell>
62
+ */
63
+ HeaderCell: typeof TableHeaderCell;
64
+ /**
65
+ * Table.Foot component, used to display the footer of a table. Renders a native HTML tfoot element.
66
+ *
67
+ * @example
68
+ * <Table.Foot>
69
+ * <Table.Row>
70
+ * <Table.Cell>Total</Table.Cell>
71
+ * <Table.Cell>2</Table.Cell>
72
+ * </Table.Row>
73
+ * </Table.Foot>
74
+ */
75
+ Foot: typeof TableFoot;
76
+ };
14
77
  /**
15
78
  * Table component, used to display tabular data. Renders a native HTML table element.
16
79
  *
@@ -36,21 +99,7 @@ import { TableRow } from './table-row';
36
99
  * </Table.Foot>
37
100
  * </Table>
38
101
  */
39
- declare const Table: React.ForwardRefExoticComponent<{
40
- zebra?: boolean;
41
- stickyHeader?: boolean;
42
- border?: boolean;
43
- hover?: boolean;
44
- } & Omit<React.TableHTMLAttributes<HTMLTableElement>, "border"> & import("../../types").DefaultProps & React.RefAttributes<HTMLTableElement>> & {
45
- Head: React.ForwardRefExoticComponent<TableHeadProps & React.RefAttributes<HTMLTableSectionElement>>;
46
- Body: React.ForwardRefExoticComponent<TableBodyProps & React.RefAttributes<HTMLTableSectionElement>>;
47
- Row: React.ForwardRefExoticComponent<TableRowProps & React.RefAttributes<HTMLTableRowElement>>;
48
- Cell: React.ForwardRefExoticComponent<TableCellProps & React.RefAttributes<HTMLTableCellElement>>;
49
- HeaderCell: React.ForwardRefExoticComponent<{
50
- sort?: React.AriaAttributes["aria-sort"];
51
- } & React.ThHTMLAttributes<HTMLTableCellElement> & React.RefAttributes<HTMLTableCellElement>>;
52
- Foot: React.ForwardRefExoticComponent<TableFootProps & React.RefAttributes<HTMLTableSectionElement>>;
53
- };
54
- export { Table, TableHead, TableBody, TableRow, TableCell, TableHeaderCell, TableFoot, };
102
+ declare const TableComponent: Table;
103
+ export { TableComponent as Table, TableHead, TableBody, TableRow, TableCell, TableHeaderCell, TableFoot, };
55
104
  export type { TableProps, TableHeadProps, TableBodyProps, TableRowProps, TableCellProps, TableHeaderCellProps, TableFootProps, };
56
105
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/table/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAE1C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,QAAA,MAAM,KAAK;;;;;;;;;;;;;;CAOT,CAAC;AAUH,OAAO,EACL,KAAK,EACL,SAAS,EACT,SAAS,EACT,QAAQ,EACR,SAAS,EACT,eAAe,EACf,SAAS,GACV,CAAC;AACF,YAAY,EACV,UAAU,EACV,cAAc,EACd,cAAc,EACd,aAAa,EACb,cAAc,EACd,oBAAoB,EACpB,cAAc,GACf,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/table/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,SAAS,CAAC;AAC7C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,KAAK,KAAK,GAAG,OAAO,SAAS,GAAG;IAC9B;;;;;;;;;;OAUG;IACH,IAAI,EAAE,OAAO,SAAS,CAAC;IACvB;;;;;;;;;;OAUG;IACH,IAAI,EAAE,OAAO,SAAS,CAAC;IACvB;;;;;;;;OAQG;IACH,GAAG,EAAE,OAAO,QAAQ,CAAC;IACrB;;;;;OAKG;IACH,IAAI,EAAE,OAAO,SAAS,CAAC;IACvB;;;;;OAKG;IACH,UAAU,EAAE,OAAO,eAAe,CAAC;IACnC;;;;;;;;;;OAUG;IACH,IAAI,EAAE,OAAO,SAAS,CAAC;CACxB,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,QAAA,MAAM,cAAc,EAAE,KAOpB,CAAC;AAUH,OAAO,EACL,cAAc,IAAI,KAAK,EACvB,SAAS,EACT,SAAS,EACT,QAAQ,EACR,SAAS,EACT,eAAe,EACf,SAAS,GACV,CAAC;AACF,YAAY,EACV,UAAU,EACV,cAAc,EACd,cAAc,EACd,aAAa,EACb,cAAc,EACd,oBAAoB,EACpB,cAAc,GACf,CAAC"}
@@ -4,12 +4,12 @@ export type TableBodyProps = HTMLAttributes<HTMLTableSectionElement>;
4
4
  * TableBody component, used to display the body of a table. Renders a native HTML tbody element.
5
5
  *
6
6
  * @example
7
- * <Table.Body>
8
- * <Table.Row>
9
- * <Table.Cell>John</Table.Cell>
10
- * <Table.Cell>25</Table.Cell>
11
- * </Table.Row>
12
- * </Table.Body>
7
+ * <TableBody>
8
+ * <TableRow>
9
+ * <TableCell>John</TableCell>
10
+ * <TableCell>25</TableCell>
11
+ * </TableRow>
12
+ * </TableBody>
13
13
  */
14
14
  export declare const TableBody: React.ForwardRefExoticComponent<TableBodyProps & React.RefAttributes<HTMLTableSectionElement>>;
15
15
  //# sourceMappingURL=table-body.d.ts.map
@@ -4,7 +4,7 @@ export type TableCellProps = TdHTMLAttributes<HTMLTableCellElement>;
4
4
  * TableCell component, used to display the cells of a table. Renders a native HTML td element.
5
5
  *
6
6
  * @example
7
- * <Table.Cell>John</Table.Cell>
7
+ * <TableCell>John</TableCell>
8
8
  */
9
9
  export declare const TableCell: React.ForwardRefExoticComponent<TableCellProps & React.RefAttributes<HTMLTableCellElement>>;
10
10
  //# sourceMappingURL=table-cell.d.ts.map
@@ -4,12 +4,12 @@ export type TableFootProps = HTMLAttributes<HTMLTableSectionElement>;
4
4
  * TableFoot component, used to display the footer of a table. Renders a native HTML tfoot element.
5
5
  *
6
6
  * @example
7
- * <Table.Foot>
8
- * <Table.Row>
9
- * <Table.Cell>Total</Table.Cell>
10
- * <Table.Cell>2</Table.Cell>
11
- * </Table.Row>
12
- * </Table.Foot>
7
+ * <TableFoot>
8
+ * <TableRow>
9
+ * <TableCell>Total</TableCell>
10
+ * <TableCell>2</TableCell>
11
+ * </TableRow>
12
+ * </TableFoot>
13
13
  */
14
14
  export declare const TableFoot: React.ForwardRefExoticComponent<TableFootProps & React.RefAttributes<HTMLTableSectionElement>>;
15
15
  //# sourceMappingURL=table-foot.d.ts.map
@@ -4,12 +4,12 @@ export type TableHeadProps = HTMLAttributes<HTMLTableSectionElement>;
4
4
  * TableHead component, used to display the header of a table. Renders a native HTML thead element.
5
5
  *
6
6
  * @example
7
- * <Table.Head>
8
- * <Table.Row>
9
- * <Table.HeaderCell>Name</Table.HeaderCell>
10
- * <Table.HeaderCell>Age</Table.HeaderCell>
11
- * </Table.Row>
12
- * </Table.Head>
7
+ * <TableHead>
8
+ * <TableRow>
9
+ * <TableHeaderCell>Name</TableHeaderCell>
10
+ * <TableHeaderCell>Age</TableHeaderCell>
11
+ * </TableRow>
12
+ * </TableHead>
13
13
  */
14
14
  export declare const TableHead: React.ForwardRefExoticComponent<TableHeadProps & React.RefAttributes<HTMLTableSectionElement>>;
15
15
  //# sourceMappingURL=table-head.d.ts.map
@@ -11,7 +11,7 @@ export type TableHeaderCellProps = {
11
11
  * TableHeaderCell component, used to display the header cells of a table. Renders a native HTML th element.
12
12
  *
13
13
  * @example
14
- * <Table.HeaderCell>Name</Table.HeaderCell>
14
+ * <TableHeaderCell>Name</TableHeaderCell>
15
15
  */
16
16
  export declare const TableHeaderCell: React.ForwardRefExoticComponent<{
17
17
  /**
@@ -4,10 +4,10 @@ export type TableRowProps = HTMLAttributes<HTMLTableRowElement>;
4
4
  * TableRow component, used to display the rows of a table. Renders a native HTML tr element.
5
5
  *
6
6
  * @example
7
- * <Table.Row>
8
- * <Table.Cell>John</Table.Cell>
9
- * <Table.Cell>25</Table.Cell>
10
- * </Table.Row>
7
+ * <TableRow>
8
+ * <TableCell>John</TableCell>
9
+ * <TableCell>25</TableCell>
10
+ * </TableRow>
11
11
  */
12
12
  export declare const TableRow: React.ForwardRefExoticComponent<TableRowProps & React.RefAttributes<HTMLTableRowElement>>;
13
13
  //# sourceMappingURL=table-row.d.ts.map
@@ -1,6 +1,33 @@
1
+ import { Tabs as TabsParent } from './tabs';
1
2
  import { TabsList } from './tabs-list';
2
3
  import { TabsPanel } from './tabs-panel';
3
4
  import { TabsTab } from './tabs-tab';
5
+ type Tabs = typeof TabsParent & {
6
+ /**
7
+ * The container for all `Tab` components.
8
+ *
9
+ * @example
10
+ * <Tabs.List>
11
+ * <Tabs.Tab value='1'>Tab 1</Tabs.Tab>
12
+ * <Tabs.Tab value='2'>Tab 2</Tabs.Tab>
13
+ * </Tabs.List>
14
+ */
15
+ List: typeof TabsList;
16
+ /**
17
+ * A single item in a Tabs component.
18
+ *
19
+ * @example
20
+ * <Tabs.Tab value='1'>Tab 1</Tabs.Tab>
21
+ */
22
+ Tab: typeof TabsTab;
23
+ /**
24
+ * A single content item in a Tabs component.
25
+ *
26
+ * @example
27
+ * <Tabs.Panel value='1'>content 1</Tabs.Panel>
28
+ */
29
+ Panel: typeof TabsPanel;
30
+ };
4
31
  /**
5
32
  * Display a group of tabs that can be toggled between.
6
33
  *
@@ -16,22 +43,10 @@ import { TabsTab } from './tabs-tab';
16
43
  * <Tabs.Panel value='3'>content 3</Tabs.Panel>
17
44
  * </Tabs>
18
45
  */
19
- declare const Tabs: React.ForwardRefExoticComponent<Omit<import("../../types").DefaultProps & Omit<React.HTMLAttributes<HTMLDivElement>, "value" | "onChange">, "value" | "onChange" | "defaultValue"> & {
20
- value?: string;
21
- defaultValue?: string;
22
- onChange?: (value: string) => void;
23
- } & React.RefAttributes<HTMLDivElement>> & {
24
- List: React.ForwardRefExoticComponent<import("./tabs-list").TabsListProps & React.RefAttributes<HTMLDivElement>>;
25
- Tab: React.ForwardRefExoticComponent<{
26
- value: string;
27
- } & Omit<React.HTMLAttributes<HTMLButtonElement>, "value"> & React.RefAttributes<HTMLButtonElement>>;
28
- Panel: React.ForwardRefExoticComponent<{
29
- value: string;
30
- } & Omit<React.HTMLAttributes<HTMLDivElement>, "value"> & React.RefAttributes<HTMLDivElement>>;
31
- };
46
+ declare const TabsComponent: Tabs;
32
47
  export type { TabsProps } from './tabs';
33
48
  export type { TabsListProps } from './tabs-list';
34
49
  export type { TabsPanelProps } from './tabs-panel';
35
50
  export type { TabsTabProps } from './tabs-tab';
36
- export { Tabs, TabsTab, TabsList, TabsPanel };
51
+ export { TabsComponent as Tabs, TabsTab, TabsList, TabsPanel };
37
52
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/tabs/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAErC;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,IAAI;;;;;;;;;;;;CAIR,CAAC;AAMH,YAAY,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AACxC,YAAY,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,YAAY,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,YAAY,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC/C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/tabs/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,IAAI,UAAU,EAAE,MAAM,QAAQ,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAErC,KAAK,IAAI,GAAG,OAAO,UAAU,GAAG;IAC9B;;;;;;;;OAQG;IACH,IAAI,EAAE,OAAO,QAAQ,CAAC;IACtB;;;;;OAKG;IACH,GAAG,EAAE,OAAO,OAAO,CAAC;IACpB;;;;;OAKG;IACH,KAAK,EAAE,OAAO,SAAS,CAAC;CACzB,CAAC;AAEF;;;;;;;;;;;;;;GAcG;AACH,QAAA,MAAM,aAAa,EAAE,IAInB,CAAC;AAMH,YAAY,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AACxC,YAAY,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AACjD,YAAY,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACnD,YAAY,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC/C,OAAO,EAAE,aAAa,IAAI,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC"}
@@ -4,10 +4,10 @@ export type TabsListProps = HTMLAttributes<HTMLDivElement>;
4
4
  * The container for all `Tab` components.
5
5
  *
6
6
  * @example
7
- * <Tabs.List>
8
- * <Tabs.Tab value='1'>Tab 1</Tabs.Tab>
9
- * <Tabs.Tab value='2'>Tab 2</Tabs.Tab>
10
- * </Tabs.List>
7
+ * <TabsList>
8
+ * <TabsTab value='1'>Tab 1</TabsTab>
9
+ * <TabsTab value='2'>Tab 2</TabsTab>
10
+ * </TabsList>
11
11
  */
12
12
  export declare const TabsList: React.ForwardRefExoticComponent<TabsListProps & React.RefAttributes<HTMLDivElement>>;
13
13
  //# sourceMappingURL=tabs-list.d.ts.map
@@ -10,7 +10,7 @@ export type TabsPanelProps = {
10
10
  * A single content item in a Tabs component.
11
11
  *
12
12
  * @example
13
- * <Tabs.Panel value='1'>content 1</Tabs.Panel>
13
+ * <TabsPanel value='1'>content 1</TabsPanel>
14
14
  */
15
15
  export declare const TabsPanel: React.ForwardRefExoticComponent<{
16
16
  /**
@@ -9,7 +9,7 @@ export type TabsTabProps = {
9
9
  * A single item in a Tabs component.
10
10
  *
11
11
  * @example
12
- * <Tabs.Tab value='1'>Tab 1</Tabs.Tab>
12
+ * <TabsTab value='1'>Tab 1</TabsTab>
13
13
  */
14
14
  export declare const TabsTab: React.ForwardRefExoticComponent<{
15
15
  /**
@@ -1,4 +1,4 @@
1
- import type { Color, SeverityColors } from '@digdir/designsystemet-react/colors';
1
+ import type { Color, SeverityColors } from '@digdir/designsystemet/types';
2
2
  import type { HTMLAttributes } from 'react';
3
3
  import type { DefaultProps } from '../../types';
4
4
  import type { MergeRight } from '../../utilities';
@@ -1 +1 @@
1
- {"version":3,"file":"tag.d.ts","sourceRoot":"","sources":["../../../src/components/tag/tag.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,KAAK,EACL,cAAc,EACf,MAAM,qCAAqC,CAAC;AAE7C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,MAAM,QAAQ,GAAG,UAAU,CAC/B,YAAY,GAAG,cAAc,CAAC,eAAe,CAAC,EAC9C;IACE;;OAEG;IACH,YAAY,CAAC,EAAE,KAAK,GAAG,cAAc,CAAC;CACvC,CACF,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,GAAG;IAbZ;;OAEG;mBACY,KAAK,GAAG,cAAc;yCAevC,CAAC"}
1
+ {"version":3,"file":"tag.d.ts","sourceRoot":"","sources":["../../../src/components/tag/tag.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE1E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,MAAM,QAAQ,GAAG,UAAU,CAC/B,YAAY,GAAG,cAAc,CAAC,eAAe,CAAC,EAC9C;IACE;;OAEG;IACH,YAAY,CAAC,EAAE,KAAK,GAAG,cAAc,CAAC;CACvC,CACF,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,GAAG;IAbZ;;OAEG;mBACY,KAAK,GAAG,cAAc;yCAevC,CAAC"}
@@ -1,4 +1,13 @@
1
+ import { ToggleGroup as ToggleGroupParent } from './toggle-group';
1
2
  import { ToggleGroupItem } from './toggle-group-item';
3
+ type ToggleGroup = typeof ToggleGroupParent & {
4
+ /**
5
+ * A single item in a ToggleGroup.
6
+ * @example
7
+ * <ToggleGroup.Item value='1'>Toggle 1</ToggleGroup.Item>
8
+ */
9
+ Item: typeof ToggleGroupItem;
10
+ };
2
11
  /**
3
12
  * Display a group of buttons that can be toggled between.
4
13
  *
@@ -9,17 +18,8 @@ import { ToggleGroupItem } from './toggle-group-item';
9
18
  * <ToggleGroup.Item value='3'>Toggle 3</ToggleGroup.Item>
10
19
  * </ToggleGroup>
11
20
  */
12
- declare const ToggleGroup: React.ForwardRefExoticComponent<Omit<import("../../types").DefaultProps & Omit<React.HTMLAttributes<HTMLDivElement>, "value" | "onChange">, "name" | "value" | "onChange" | "defaultValue"> & {
13
- value?: string;
14
- defaultValue?: string;
15
- onChange?: (value: string) => void;
16
- name?: string;
17
- } & React.RefAttributes<HTMLDivElement>> & {
18
- Item: React.ForwardRefExoticComponent<{
19
- value?: string;
20
- } & Omit<import("..").ButtonProps, "value" | "variant" | "loading"> & React.RefAttributes<HTMLButtonElement>>;
21
- };
21
+ declare const ToggleGroupComponent: ToggleGroup;
22
22
  export type { ToggleGroupProps } from './toggle-group';
23
23
  export type { ToggleGroupItemProps } from './toggle-group-item';
24
- export { ToggleGroup, ToggleGroupItem };
24
+ export { ToggleGroupComponent as ToggleGroup, ToggleGroupItem };
25
25
  //# sourceMappingURL=index.d.ts.map