@norges-domstoler/dds-components 2.5.1 → 3.0.0

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 (74) hide show
  1. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +10 -4
  2. package/dist/components/Breadcrumbs/Breadcrumbs.stories.d.ts +6 -1
  3. package/dist/components/Button/Button.d.ts +8 -1
  4. package/dist/components/Button/Button.stories.d.ts +8 -1
  5. package/dist/components/Button/Button.types.d.ts +5 -2
  6. package/dist/components/Card/Card.d.ts +13 -13
  7. package/dist/components/Card/CardAccordion/CardAccordion.d.ts +10 -4
  8. package/dist/components/Card/CardAccordion/CardAccordionBody.d.ts +10 -4
  9. package/dist/components/Card/CardAccordion/CardAccordionHeader.d.ts +9 -3
  10. package/dist/components/Checkbox/Checkbox.d.ts +9 -1
  11. package/dist/components/Checkbox/Checkbox.stories.d.ts +9 -1
  12. package/dist/components/Checkbox/Checkbox.types.d.ts +5 -2
  13. package/dist/components/Chip/Chip.d.ts +8 -4
  14. package/dist/components/Chip/Chip.stories.d.ts +4 -1
  15. package/dist/components/DescriptionList/DescriptionList.d.ts +10 -4
  16. package/dist/components/DescriptionList/DescriptionList.stories.d.ts +6 -1
  17. package/dist/components/DescriptionList/DescriptionListDesc.d.ts +10 -4
  18. package/dist/components/DescriptionList/DescriptionListGroup.d.ts +10 -4
  19. package/dist/components/Divider/Divider.d.ts +8 -4
  20. package/dist/components/Divider/Divider.stories.d.ts +4 -1
  21. package/dist/components/Drawer/Drawer.d.ts +10 -4
  22. package/dist/components/Drawer/Drawer.stories.d.ts +6 -1
  23. package/dist/components/Drawer/DrawerGroup.d.ts +2 -2
  24. package/dist/components/GlobalMessage/GlobalMessage.d.ts +10 -4
  25. package/dist/components/GlobalMessage/GlobalMessage.stories.d.ts +6 -1
  26. package/dist/components/IconWrapper/IconWrapper.d.ts +8 -3
  27. package/dist/components/InputMessage/InputMessage.d.ts +9 -4
  28. package/dist/components/InputMessage/InputMessage.stories.d.ts +4 -1
  29. package/dist/components/InternalHeader/InternalHeader.d.ts +1 -1
  30. package/dist/components/InternalHeader/InternalHeader.stories.d.ts +1 -1
  31. package/dist/components/InternalHeader/InternalHeader.styles.d.ts +8 -2
  32. package/dist/components/InternalHeader/InternalHeader.types.d.ts +8 -6
  33. package/dist/components/List/List.d.ts +10 -4
  34. package/dist/components/List/List.stories.d.ts +6 -1
  35. package/dist/components/LocalMessage/LocalMessage.d.ts +10 -4
  36. package/dist/components/LocalMessage/LocalMessage.stories.d.ts +6 -1
  37. package/dist/components/Modal/Modal.d.ts +10 -4
  38. package/dist/components/Modal/Modal.stories.d.ts +6 -1
  39. package/dist/components/Modal/ModalBody.d.ts +10 -4
  40. package/dist/components/OverflowMenu/OverflowMenu.d.ts +8 -2
  41. package/dist/components/OverflowMenu/OverflowMenu.stories.d.ts +11 -5
  42. package/dist/components/OverflowMenu/OverflowMenu.types.d.ts +6 -4
  43. package/dist/components/OverflowMenu/OverflowMenuItem.d.ts +12 -5
  44. package/dist/components/Pagination/Pagination.d.ts +7 -3
  45. package/dist/components/Pagination/Pagination.stories.d.ts +4 -1
  46. package/dist/components/Popover/Popover.d.ts +10 -4
  47. package/dist/components/Popover/Popover.stories.d.ts +6 -1
  48. package/dist/components/RadioButton/RadioButton.d.ts +12 -1
  49. package/dist/components/RadioButton/RadioButton.stories.d.ts +12 -1
  50. package/dist/components/RadioButton/RadioButton.types.d.ts +5 -2
  51. package/dist/components/RadioButton/RadioButtonGroup.d.ts +4 -3
  52. package/dist/components/RadioButton/RadioButtonGroup.stories.d.ts +1 -1
  53. package/dist/components/SkipToContent/SkipToContent.d.ts +8 -4
  54. package/dist/components/SkipToContent/SkipToContent.stories.d.ts +4 -1
  55. package/dist/components/Spinner/Spinner.d.ts +5 -4
  56. package/dist/components/Tabs/Tab.d.ts +9 -3
  57. package/dist/components/Tabs/TabPanel.d.ts +10 -4
  58. package/dist/components/Tabs/Tabs.d.ts +9 -4
  59. package/dist/components/Tag/Tag.d.ts +8 -4
  60. package/dist/components/Tag/Tag.stories.d.ts +4 -1
  61. package/dist/components/TextInput/CharCounter.d.ts +5 -4
  62. package/dist/components/ToggleButton/ToggleButton.d.ts +7 -3
  63. package/dist/components/ToggleButton/ToggleButton.stories.d.ts +4 -1
  64. package/dist/components/ToggleButton/ToggleButtonGroup.d.ts +5 -4
  65. package/dist/components/ToggleButton/{ToggelButtonGroup.stories.d.ts → ToggleButtonGroup.stories.d.ts} +1 -1
  66. package/dist/components/Tooltip/Tooltip.d.ts +8 -3
  67. package/dist/components/Tooltip/Tooltip.stories.d.ts +9 -1
  68. package/dist/components/Typography/Typography.d.ts +23 -10
  69. package/dist/components/Typography/Typography.types.d.ts +10 -6
  70. package/dist/index.es.js +640 -499
  71. package/dist/index.js +640 -499
  72. package/dist/types/BaseComponentProps.d.ts +308 -0
  73. package/dist/types/index.d.ts +1 -0
  74. package/package.json +3 -2
package/dist/index.es.js CHANGED
@@ -12893,17 +12893,16 @@ function IconWrapper$1(_a) {
12893
12893
  color = _a.color,
12894
12894
  className = _a.className,
12895
12895
  style = _a.style,
12896
- rest = __rest(_a, ["Icon", "iconSize", "color", "className", "style"]);
12897
-
12896
+ svgProps = _a.svgProps;
12898
12897
  var PropIcon = Icon;
12899
12898
  var size = getSize(iconSize);
12900
- return jsxRuntime.exports.jsx(PropIcon, __assign({
12899
+ return jsxRuntime.exports.jsx(PropIcon, __assign({}, svgProps, {
12901
12900
  className: className,
12902
12901
  style: __assign(__assign({}, style), {
12903
12902
  color: color ? color : 'inherit',
12904
12903
  fontSize: size
12905
12904
  })
12906
- }, rest));
12905
+ }));
12907
12906
  }
12908
12907
 
12909
12908
  var LaunchOutlined = {};
@@ -20127,7 +20126,7 @@ default_1$k = LaunchOutlined.default = _default$k;
20127
20126
  var getElementType = function getElementType(element) {
20128
20127
  switch (element) {
20129
20128
  case 'a':
20130
- return element;
20129
+ return 'a';
20131
20130
 
20132
20131
  case 'headingSans01':
20133
20132
  return 'h6';
@@ -20226,31 +20225,47 @@ var StyledTypography = styled$3.p.withConfig({
20226
20225
  var underline = _a.underline;
20227
20226
  return underline && Ae(templateObject_12$3 || (templateObject_12$3 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), typographyTokens.style.underline.base);
20228
20227
  });
20229
- var Typography = /*#__PURE__*/forwardRef(function (_a, ref) {
20230
- var _b = _a.typographyType,
20228
+
20229
+ var isAnchorProps$1 = function isAnchorProps(props) {
20230
+ return props.typographyType === 'a';
20231
+ };
20232
+
20233
+ var Typography = /*#__PURE__*/forwardRef(function (props, ref) {
20234
+ var _a;
20235
+
20236
+ var _b = props.typographyType,
20231
20237
  typographyType = _b === void 0 ? 'bodySans02' : _b,
20232
- propAs = _a.as,
20233
- externalLink = _a.externalLink,
20234
- target = _a.target,
20235
- children = _a.children,
20236
- rest = __rest(_a, ["typographyType", "as", "externalLink", "target", "children"]);
20238
+ propAs = props.as,
20239
+ children = props.children,
20240
+ rest = __rest(props, ["typographyType", "as", "children"]);
20237
20241
 
20238
20242
  var as = propAs ? propAs : getElementType(typographyType);
20243
+ var relProp;
20244
+ var targetProp;
20245
+ var renderWrapper = false;
20239
20246
 
20240
- var typographyProps = __assign({
20247
+ if (isAnchorProps$1(props)) {
20248
+ var externalLink = props.externalLink,
20249
+ target = props.target;
20250
+ renderWrapper = (_a = as === 'a' && externalLink) !== null && _a !== void 0 ? _a : false;
20251
+ relProp = as === 'a' ? 'noopener noreferer' : undefined;
20252
+ targetProp = as !== 'a' ? undefined : externalLink ? '_blank' : target;
20253
+ }
20254
+
20255
+ var typographyProps = __assign(__assign({}, rest), {
20241
20256
  typographyType: typographyType,
20242
20257
  as: as,
20243
- rel: as === 'a' ? 'noopener noreferer' : undefined,
20244
- target: as !== 'a' ? undefined : externalLink ? '_blank' : target
20245
- }, rest);
20258
+ rel: relProp,
20259
+ target: targetProp
20260
+ });
20246
20261
 
20247
20262
  return jsxRuntime.exports.jsxs(StyledTypography, __assign({
20248
20263
  ref: ref
20249
20264
  }, typographyProps, {
20250
- children: [children, ' ', as === 'a' && externalLink ? jsxRuntime.exports.jsx(LinkIconWrapper, {
20265
+ children: [children, renderWrapper && jsxRuntime.exports.jsx(LinkIconWrapper, {
20251
20266
  Icon: default_1$k,
20252
20267
  iconSize: "inline"
20253
- }) : '']
20268
+ })]
20254
20269
  }));
20255
20270
  });
20256
20271
  var templateObject_1$Z, templateObject_2$J, templateObject_3$v, templateObject_4$p, templateObject_5$g, templateObject_6$e, templateObject_7$a, templateObject_8$8, templateObject_9$6, templateObject_10$5, templateObject_11$4, templateObject_12$3, templateObject_13$2;
@@ -20387,6 +20402,39 @@ var Container$j = styled$3.label.withConfig({
20387
20402
  }, CustomRadioButton, radioButtonTokens.checkmark.base);
20388
20403
  var templateObject_1$Y, templateObject_2$I, templateObject_3$u, templateObject_4$o, templateObject_5$f, templateObject_6$d;
20389
20404
 
20405
+ /**
20406
+ * Slår sammen htmlProps, id, og unknownProps til ett objekt som
20407
+ * kan spreades som baseprops for en komponent. `unknownProps` er
20408
+ * med for å sikre at aria- og data- attributter blir spreadet, alle
20409
+ * komponenter må derfor ta hensyn til `...rest` når de leser props.
20410
+ *
20411
+ * Typisk bruk:
20412
+ * ```
20413
+ * const Props = BaseComponentProps<HTMLElement, {
20414
+ * propA: string,
20415
+ * propB: string,
20416
+ * }>
20417
+ *
20418
+ * const MyComponent = (props: Props) => {
20419
+ * const { propA, propB, id, htmlProps, ...rest } = props;
20420
+ *
20421
+ * const wrapperProps = getBaseHTMLProps(id, htmlProps, rest)
20422
+ *
20423
+ * return <div {...wrapperProps}>innhold</div>
20424
+ * }
20425
+ * ```
20426
+ * @param id id fra props til komponenten.
20427
+ * @param htmlProps htmlProps fra komponenten.
20428
+ * @param unknownProps andre ukjente props som skal spreades, kommer typisk fra `...rest` når man leser props til komponenten.
20429
+ * @returns Objekt med alle argumentene som kan spreades.
20430
+ */
20431
+
20432
+ var getBaseHTMLProps = function getBaseHTMLProps(id, htmlProps, unknownProps) {
20433
+ return __assign(__assign(__assign({}, unknownProps), htmlProps), {
20434
+ id: id
20435
+ });
20436
+ };
20437
+
20390
20438
  var nextUniqueId$h = 0;
20391
20439
 
20392
20440
  var isValueEqualToGroupValueOrFalsy = function isValueEqualToGroupValueOrFalsy(value, group) {
@@ -20401,22 +20449,26 @@ var isValueEqualToGroupValueOrFalsy = function isValueEqualToGroupValueOrFalsy(v
20401
20449
  return !!value;
20402
20450
  };
20403
20451
 
20404
- var RadioButton = /*#__PURE__*/forwardRef(function (_a, ref) {
20405
- var id = _a.id,
20406
- name = _a.name,
20407
- label = _a.label,
20408
- disabled = _a.disabled,
20409
- readOnly = _a.readOnly,
20410
- error = _a.error,
20411
- style = _a.style,
20412
- checked = _a.checked,
20413
- value = _a.value,
20414
- className = _a.className,
20415
- children = _a.children,
20416
- required = _a.required,
20417
- onChange = _a.onChange,
20418
- ariaDescribedby = _a["aria-describedby"],
20419
- rest = __rest(_a, ["id", "name", "label", "disabled", "readOnly", "error", "style", "checked", "value", "className", "children", "required", "onChange", 'aria-describedby']);
20452
+ var RadioButton = /*#__PURE__*/forwardRef(function (props, ref) {
20453
+ var id = props.id,
20454
+ name = props.name,
20455
+ label = props.label,
20456
+ disabled = props.disabled,
20457
+ readOnly = props.readOnly,
20458
+ error = props.error,
20459
+ checked = props.checked,
20460
+ value = props.value,
20461
+ children = props.children,
20462
+ required = props.required,
20463
+ onChange = props.onChange,
20464
+ ariaDescribedby = props["aria-describedby"],
20465
+ _a = props.htmlProps,
20466
+ htmlProps = _a === void 0 ? {} : _a,
20467
+ rest = __rest(props, ["id", "name", "label", "disabled", "readOnly", "error", "checked", "value", "children", "required", "onChange", 'aria-describedby', "htmlProps"]);
20468
+
20469
+ var className = htmlProps.className,
20470
+ style = htmlProps.style,
20471
+ restHtmlProps = __rest(htmlProps, ["className", "style"]);
20420
20472
 
20421
20473
  var uniqueId = useState(id !== null && id !== void 0 ? id : "radioButton-".concat(nextUniqueId$h++))[0];
20422
20474
  var radioButtonGroup = useRadioButtonGroup();
@@ -20430,7 +20482,7 @@ var RadioButton = /*#__PURE__*/forwardRef(function (_a, ref) {
20430
20482
  if (radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.errorMessageId) describedByIds.push(radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.errorMessageId);
20431
20483
  if (ariaDescribedby) describedByIds.push(ariaDescribedby);
20432
20484
 
20433
- var inputProps = __assign({
20485
+ var inputProps = __assign(__assign({}, getBaseHTMLProps(id, restHtmlProps, rest)), {
20434
20486
  id: uniqueId,
20435
20487
  name: name !== null && name !== void 0 ? name : radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.name,
20436
20488
  disabled: disabled || readOnly || (radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.disabled) || (radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.readOnly),
@@ -20440,7 +20492,7 @@ var RadioButton = /*#__PURE__*/forwardRef(function (_a, ref) {
20440
20492
  value: value,
20441
20493
  'aria-describedby': describedByIds.length > 0 ? describedByIds.join(' ') : undefined,
20442
20494
  'aria-invalid': error || (radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.error) ? true : undefined
20443
- }, rest);
20495
+ });
20444
20496
 
20445
20497
  var containerProps = {
20446
20498
  error: error || (radioButtonGroup === null || radioButtonGroup === void 0 ? void 0 : radioButtonGroup.error),
@@ -20769,15 +20821,17 @@ var InputMessageWrapper = styled$3.div.withConfig({
20769
20821
  var messageType = _a.messageType;
20770
20822
  return messageType && Ae(templateObject_1$S || (templateObject_1$S = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), inputMessageTokens[messageType].base);
20771
20823
  }, inputMessageTokens.icon.spaceRight);
20772
- var InputMessage = /*#__PURE__*/forwardRef(function (_a, ref) {
20773
- var message = _a.message,
20774
- messageType = _a.messageType,
20775
- rest = __rest(_a, ["message", "messageType"]);
20776
-
20777
- var wrapperProps = __assign({
20824
+ var InputMessage = /*#__PURE__*/forwardRef(function (props, ref) {
20825
+ var message = props.message,
20826
+ messageType = props.messageType,
20827
+ id = props.id,
20828
+ htmlProps = props.htmlProps,
20829
+ rest = __rest(props, ["message", "messageType", "id", "htmlProps"]);
20830
+
20831
+ var wrapperProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
20778
20832
  ref: ref,
20779
20833
  messageType: messageType
20780
- }, rest);
20834
+ });
20781
20835
 
20782
20836
  var isError = messageType === 'error';
20783
20837
  return jsxRuntime.exports.jsxs(InputMessageWrapper, __assign({}, wrapperProps, {
@@ -20886,9 +20940,9 @@ var RadioButtonGroup = function RadioButtonGroup(_a) {
20886
20940
  children = _a.children,
20887
20941
  required = _a.required,
20888
20942
  onChange = _a.onChange,
20889
- className = _a.className,
20890
- style = _a.style,
20891
- rest = __rest(_a, ["name", "label", "groupId", "errorMessage", "tip", "disabled", "readOnly", "direction", "value", "children", "required", "onChange", "className", "style"]);
20943
+ id = _a.id,
20944
+ htmlProps = _a.htmlProps,
20945
+ rest = __rest(_a, ["name", "label", "groupId", "errorMessage", "tip", "disabled", "readOnly", "direction", "value", "children", "required", "onChange", "id", "htmlProps"]);
20892
20946
 
20893
20947
  var _c = useState(value),
20894
20948
  groupValue = _c[0],
@@ -20904,12 +20958,6 @@ var RadioButtonGroup = function RadioButtonGroup(_a) {
20904
20958
  var hasTip = !!tip;
20905
20959
  var tipId = hasTip ? "".concat(uniqueGroupId, "-tip") : undefined;
20906
20960
  var errorMessageId = hasErrorMessage ? "".concat(uniqueGroupId, "-errorMessage") : undefined;
20907
-
20908
- var containerProps = __assign({
20909
- className: className,
20910
- style: style
20911
- }, rest);
20912
-
20913
20961
  var contextProps = {
20914
20962
  name: name,
20915
20963
  disabled: disabled,
@@ -20920,7 +20968,7 @@ var RadioButtonGroup = function RadioButtonGroup(_a) {
20920
20968
  value: groupValue,
20921
20969
  onChange: handleChange
20922
20970
  };
20923
- return jsxRuntime.exports.jsxs(Container$i, __assign({}, containerProps, {
20971
+ return jsxRuntime.exports.jsxs(Container$i, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
20924
20972
  children: [jsxRuntime.exports.jsxs(Label$4, __assign({
20925
20973
  forwardedAs: "span",
20926
20974
  typographyType: "supportingStyleLabel01",
@@ -21130,21 +21178,26 @@ var useCheckboxGroup = function useCheckboxGroup() {
21130
21178
  };
21131
21179
 
21132
21180
  var nextUniqueId$g = 0;
21133
- var Checkbox = /*#__PURE__*/forwardRef(function (_a, ref) {
21134
- var id = _a.id,
21135
- name = _a.name,
21136
- label = _a.label,
21137
- error = _a.error,
21138
- disabled = _a.disabled,
21139
- readOnly = _a.readOnly,
21140
- indeterminate = _a.indeterminate,
21141
- ariaDescribedby = _a["aria-describedby"],
21142
- className = _a.className,
21143
- style = _a.style,
21144
- rest = __rest(_a, ["id", "name", "label", "error", "disabled", "readOnly", "indeterminate", 'aria-describedby', "className", "style"]);
21181
+ var Checkbox = /*#__PURE__*/forwardRef(function (props, ref) {
21182
+ var id = props.id,
21183
+ name = props.name,
21184
+ label = props.label,
21185
+ error = props.error,
21186
+ disabled = props.disabled,
21187
+ readOnly = props.readOnly,
21188
+ indeterminate = props.indeterminate,
21189
+ ariaDescribedby = props["aria-describedby"],
21190
+ _a = props.htmlProps,
21191
+ htmlProps = _a === void 0 ? {} : _a,
21192
+ rest = __rest(props, ["id", "name", "label", "error", "disabled", "readOnly", "indeterminate", 'aria-describedby', "htmlProps"]);
21145
21193
 
21146
21194
  var uniqueId = useState(id !== null && id !== void 0 ? id : "checkbox-".concat(nextUniqueId$g++))[0];
21147
21195
  var checkboxGroup = useCheckboxGroup();
21196
+
21197
+ var className = htmlProps.className,
21198
+ style = htmlProps.style,
21199
+ restHtmlProps = __rest(htmlProps, ["className", "style"]);
21200
+
21148
21201
  var containerProps = {
21149
21202
  error: error || (checkboxGroup === null || checkboxGroup === void 0 ? void 0 : checkboxGroup.error),
21150
21203
  disabled: disabled,
@@ -21156,7 +21209,7 @@ var Checkbox = /*#__PURE__*/forwardRef(function (_a, ref) {
21156
21209
  style: style
21157
21210
  };
21158
21211
 
21159
- var inputProps = __assign({
21212
+ var inputProps = __assign(__assign({}, getBaseHTMLProps(id, restHtmlProps, rest)), {
21160
21213
  ref: ref,
21161
21214
  id: uniqueId,
21162
21215
  name: name,
@@ -21167,7 +21220,7 @@ var Checkbox = /*#__PURE__*/forwardRef(function (_a, ref) {
21167
21220
  'aria-labelledby': checkboxGroup === null || checkboxGroup === void 0 ? void 0 : checkboxGroup.uniqueGroupId,
21168
21221
  'aria-checked': indeterminate ? 'mixed' : undefined,
21169
21222
  'aria-readonly': readOnly
21170
- }, rest);
21223
+ });
21171
21224
 
21172
21225
  return jsxRuntime.exports.jsxs(Container$h, __assign({}, containerProps, {
21173
21226
  children: [jsxRuntime.exports.jsx(Input$4, __assign({}, inputProps, {
@@ -21805,22 +21858,24 @@ var Circle = styled$3.circle.withConfig({
21805
21858
  return innerAnimationDelay;
21806
21859
  });
21807
21860
  var nextUniqueId$f = 0;
21808
- function Spinner(_a) {
21809
- var _b = _a.size,
21810
- size = _b === void 0 ? ddsBaseTokens.iconSizes.DdsIconsizeMedium : _b,
21811
- _c = _a.color,
21812
- color = _c === void 0 ? 'interactive' : _c,
21813
- rest = __rest(_a, ["size", "color"]);
21861
+ function Spinner(props) {
21862
+ var _a = props.size,
21863
+ size = _a === void 0 ? ddsBaseTokens.iconSizes.DdsIconsizeMedium : _a,
21864
+ _b = props.color,
21865
+ color = _b === void 0 ? 'interactive' : _b,
21866
+ id = props.id,
21867
+ htmlProps = props.htmlProps,
21868
+ rest = __rest(props, ["size", "color", "id", "htmlProps"]);
21814
21869
 
21815
21870
  var mountTime = React__default.useRef(Date.now());
21816
21871
  var outerAnimationDelay = -(mountTime.current % 2000);
21817
21872
  var innerAnimationDelay = -(mountTime.current % 1500);
21818
21873
  var uniqueId = useState("spinnerTitle-".concat(nextUniqueId$f++))[0];
21819
21874
 
21820
- var spinnerProps = __assign({
21875
+ var spinnerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
21821
21876
  outerAnimationDelay: outerAnimationDelay,
21822
21877
  size: size
21823
- }, rest);
21878
+ });
21824
21879
 
21825
21880
  var circleProps = {
21826
21881
  innerAnimationDelay: innerAnimationDelay,
@@ -21897,33 +21952,35 @@ var Label$2 = styled$3.span.withConfig({
21897
21952
  });
21898
21953
  var templateObject_1$N, templateObject_2$A, templateObject_3$o, templateObject_4$i, templateObject_5$c, templateObject_6$a, templateObject_7$7, templateObject_8$5, templateObject_9$3, templateObject_10$3, templateObject_11$2, templateObject_12$1, templateObject_13, templateObject_14, templateObject_15, templateObject_16;
21899
21954
 
21900
- var Button$1 = /*#__PURE__*/forwardRef(function (_a, ref) {
21901
- var label = _a.label,
21902
- disabled = _a.disabled,
21903
- _b = _a.purpose,
21904
- purpose = _b === void 0 ? 'primary' : _b,
21905
- _c = _a.size,
21906
- size = _c === void 0 ? 'medium' : _c,
21907
- _d = _a.iconPosition,
21908
- iconPosition = _d === void 0 ? 'left' : _d,
21909
- _e = _a.appearance,
21910
- appearance = _e === void 0 ? 'filled' : _e,
21911
- href = _a.href,
21912
- target = _a.target,
21913
- _f = _a.loading,
21914
- loading = _f === void 0 ? false : _f,
21915
- _g = _a.fullWidth,
21916
- fullWidth = _g === void 0 ? false : _g,
21917
- className = _a.className,
21918
- style = _a.style,
21919
- Icon = _a.Icon,
21920
- rest = __rest(_a, ["label", "disabled", "purpose", "size", "iconPosition", "appearance", "href", "target", "loading", "fullWidth", "className", "style", "Icon"]);
21955
+ var Button$1 = /*#__PURE__*/forwardRef(function (props, ref) {
21956
+ var label = props.label,
21957
+ _a = props.purpose,
21958
+ purpose = _a === void 0 ? 'primary' : _a,
21959
+ _b = props.size,
21960
+ size = _b === void 0 ? 'medium' : _b,
21961
+ _c = props.iconPosition,
21962
+ iconPosition = _c === void 0 ? 'left' : _c,
21963
+ _d = props.appearance,
21964
+ appearance = _d === void 0 ? 'filled' : _d,
21965
+ href = props.href,
21966
+ target = props.target,
21967
+ _e = props.loading,
21968
+ loading = _e === void 0 ? false : _e,
21969
+ _f = props.fullWidth,
21970
+ fullWidth = _f === void 0 ? false : _f,
21971
+ Icon = props.Icon,
21972
+ onClick = props.onClick,
21973
+ onFocus = props.onFocus,
21974
+ onBlur = props.onBlur,
21975
+ id = props.id,
21976
+ htmlProps = props.htmlProps,
21977
+ rest = __rest(props, ["label", "purpose", "size", "iconPosition", "appearance", "href", "target", "loading", "fullWidth", "Icon", "onClick", "onFocus", "onBlur", "id", "htmlProps"]);
21921
21978
 
21922
21979
  var as = href ? 'a' : 'button';
21923
21980
  var hasLabel = !!label;
21924
21981
  var hasIcon = !!Icon;
21925
21982
 
21926
- var wrapperProps = __assign({
21983
+ var wrapperProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
21927
21984
  href: href,
21928
21985
  label: label,
21929
21986
  as: as,
@@ -21937,11 +21994,11 @@ var Button$1 = /*#__PURE__*/forwardRef(function (_a, ref) {
21937
21994
  hasLabel: hasLabel,
21938
21995
  hasIcon: hasIcon,
21939
21996
  isLoading: loading,
21940
- disabled: disabled,
21941
21997
  size: size,
21942
- className: className,
21943
- style: style
21944
- }, rest);
21998
+ onClick: onClick,
21999
+ onFocus: onFocus,
22000
+ onBlur: onBlur
22001
+ });
21945
22002
 
21946
22003
  var isIconButton = !hasLabel && hasIcon;
21947
22004
 
@@ -22036,19 +22093,20 @@ var Wrapper$7 = styled$3(Typography).withConfig({
22036
22093
  })(templateObject_1$M || (templateObject_1$M = __makeTemplateObject(["\n margin-left: auto;\n ", "\n"], ["\n margin-left: auto;\n ", "\n"])), charCounterTokens.base);
22037
22094
  var nextUniqueId$e = 0;
22038
22095
 
22039
- function CharCounter(_a) {
22040
- var current = _a.current,
22041
- max = _a.max,
22042
- id = _a.id,
22043
- rest = __rest(_a, ["current", "max", "id"]);
22096
+ function CharCounter(props) {
22097
+ var current = props.current,
22098
+ max = props.max,
22099
+ id = props.id,
22100
+ htmlProps = props.htmlProps,
22101
+ rest = __rest(props, ["current", "max", "id", "htmlProps"]);
22044
22102
 
22045
22103
  var uniqueId = useState(id !== null && id !== void 0 ? id : "characterCounter-".concat(nextUniqueId$e++))[0];
22046
- return jsxRuntime.exports.jsxs(Wrapper$7, __assign({
22104
+ return jsxRuntime.exports.jsxs(Wrapper$7, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
22047
22105
  forwardedAs: "div",
22048
22106
  typographyType: "supportingStyleHelperText01",
22049
22107
  id: uniqueId,
22050
22108
  "aria-label": "".concat(current, " av ").concat(max, " tegn skrevet")
22051
- }, rest, {
22109
+ }, {
22052
22110
  children: [current, "/", max]
22053
22111
  }));
22054
22112
  }
@@ -27570,25 +27628,27 @@ var ContentContainer$4 = styled$3.div.withConfig({
27570
27628
  var closable = _a.closable;
27571
27629
  return closable && Ae(templateObject_5$9 || (templateObject_5$9 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), globalMessageTokens.contentContainer.withClosable.base);
27572
27630
  });
27573
- var GlobalMessage = /*#__PURE__*/forwardRef(function (_a, ref) {
27574
- var message = _a.message,
27575
- _b = _a.purpose,
27576
- purpose = _b === void 0 ? 'info' : _b,
27577
- closable = _a.closable,
27578
- onClose = _a.onClose,
27579
- children = _a.children,
27580
- rest = __rest(_a, ["message", "purpose", "closable", "onClose", "children"]);
27631
+ var GlobalMessage = /*#__PURE__*/forwardRef(function (props, ref) {
27632
+ var message = props.message,
27633
+ _a = props.purpose,
27634
+ purpose = _a === void 0 ? 'info' : _a,
27635
+ closable = props.closable,
27636
+ onClose = props.onClose,
27637
+ children = props.children,
27638
+ id = props.id,
27639
+ htmlProps = props.htmlProps,
27640
+ rest = __rest(props, ["message", "purpose", "closable", "onClose", "children", "id", "htmlProps"]);
27581
27641
 
27582
- var _c = useState(false),
27583
- isClosed = _c[0],
27584
- setClosed = _c[1];
27642
+ var _b = useState(false),
27643
+ isClosed = _b[0],
27644
+ setClosed = _b[1];
27585
27645
 
27586
27646
  var buttonPurpose = globalMessageTokens.button[purpose].purpose;
27587
27647
 
27588
- var containerProps = __assign({
27648
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
27589
27649
  ref: ref,
27590
27650
  purpose: purpose
27591
- }, rest);
27651
+ });
27592
27652
 
27593
27653
  return !isClosed ? jsxRuntime.exports.jsxs(Container$e, __assign({}, containerProps, {
27594
27654
  children: [jsxRuntime.exports.jsxs(ContentContainer$4, __assign({
@@ -27845,31 +27905,33 @@ var TopContainer = styled$3.div.withConfig({
27845
27905
  var closable = _a.closable;
27846
27906
  return closable && Ae(templateObject_9$1 || (templateObject_9$1 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), localMessageTokens.topContainer.withClosable.base);
27847
27907
  });
27848
- var LocalMessage = /*#__PURE__*/forwardRef(function (_a, ref) {
27849
- var message = _a.message,
27850
- _b = _a.purpose,
27851
- purpose = _b === void 0 ? 'info' : _b,
27852
- closable = _a.closable,
27853
- onClose = _a.onClose,
27854
- _c = _a.width,
27855
- width = _c === void 0 ? localMessageTokens.container.defaultWidth : _c,
27856
- _d = _a.layout,
27857
- layout = _d === void 0 ? 'horisontal' : _d,
27858
- children = _a.children,
27859
- rest = __rest(_a, ["message", "purpose", "closable", "onClose", "width", "layout", "children"]);
27908
+ var LocalMessage = /*#__PURE__*/forwardRef(function (props, ref) {
27909
+ var message = props.message,
27910
+ _a = props.purpose,
27911
+ purpose = _a === void 0 ? 'info' : _a,
27912
+ closable = props.closable,
27913
+ onClose = props.onClose,
27914
+ _b = props.width,
27915
+ width = _b === void 0 ? localMessageTokens.container.defaultWidth : _b,
27916
+ _c = props.layout,
27917
+ layout = _c === void 0 ? 'horisontal' : _c,
27918
+ children = props.children,
27919
+ id = props.id,
27920
+ htmlProps = props.htmlProps,
27921
+ rest = __rest(props, ["message", "purpose", "closable", "onClose", "width", "layout", "children", "id", "htmlProps"]);
27860
27922
 
27861
- var _e = useState(false),
27862
- isClosed = _e[0],
27863
- setClosed = _e[1];
27923
+ var _d = useState(false),
27924
+ isClosed = _d[0],
27925
+ setClosed = _d[1];
27864
27926
 
27865
27927
  var buttonPurpose = localMessageTokens.button[purpose].purpose;
27866
27928
 
27867
- var containerProps = __assign({
27929
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
27868
27930
  purpose: purpose,
27869
27931
  width: width,
27870
27932
  layout: layout,
27871
27933
  ref: ref
27872
- }, rest);
27934
+ });
27873
27935
 
27874
27936
  var contentContainerProps = {
27875
27937
  layout: layout,
@@ -28548,16 +28610,16 @@ var Breadcrumb = /*#__PURE__*/forwardRef(function (_a, ref) {
28548
28610
  href = _a.href,
28549
28611
  rest = __rest(_a, ["children", "href"]);
28550
28612
 
28551
- return href ? jsxRuntime.exports.jsx(Typography, __assign({
28613
+ return href ? jsxRuntime.exports.jsx(Typography, __assign({}, rest, {
28552
28614
  ref: ref,
28553
28615
  href: href,
28554
28616
  typographyType: "a"
28555
- }, rest, {
28617
+ }, {
28556
28618
  children: children
28557
- })) : jsxRuntime.exports.jsx(Typography, __assign({
28619
+ })) : jsxRuntime.exports.jsx(Typography, __assign({}, rest, {
28558
28620
  ref: ref,
28559
28621
  color: "interactive"
28560
- }, rest, {
28622
+ }, {
28561
28623
  children: children
28562
28624
  }));
28563
28625
  });
@@ -28637,10 +28699,12 @@ var BackIcon = styled$3(default_1$7).withConfig({
28637
28699
  displayName: "Breadcrumbs__BackIcon",
28638
28700
  componentId: "sc-xdj21o-3"
28639
28701
  })(templateObject_4$a || (templateObject_4$a = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), breadcrumbTokens.icon.base);
28640
- var Breadcrumbs = /*#__PURE__*/forwardRef(function (_a, ref) {
28641
- var smallScreen = _a.smallScreen,
28642
- children = _a.children,
28643
- rest = __rest(_a, ["smallScreen", "children"]);
28702
+ var Breadcrumbs = /*#__PURE__*/forwardRef(function (props, ref) {
28703
+ var smallScreen = props.smallScreen,
28704
+ children = props.children,
28705
+ id = props.id,
28706
+ htmlProps = props.htmlProps,
28707
+ rest = __rest(props, ["smallScreen", "children", "id", "htmlProps"]);
28644
28708
 
28645
28709
  var breadcrumbIconSize = breadcrumbTokens.icon.size;
28646
28710
  var childrenArray = Children.toArray(children);
@@ -28659,10 +28723,10 @@ var Breadcrumbs = /*#__PURE__*/forwardRef(function (_a, ref) {
28659
28723
  }) : '', item]
28660
28724
  }, "breadcrumb-".concat(index));
28661
28725
  });
28662
- return jsxRuntime.exports.jsx("nav", __assign({
28726
+ return jsxRuntime.exports.jsx("nav", __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
28663
28727
  ref: ref,
28664
28728
  "aria-label": "br\xF8dsmulesti"
28665
- }, rest, {
28729
+ }, {
28666
28730
  children: jsxRuntime.exports.jsx(List$2, {
28667
28731
  children: breadcrumbChildren
28668
28732
  })
@@ -28831,18 +28895,18 @@ var IndicatorsContainer = styled$3.div.withConfig({
28831
28895
  displayName: "Pagination__IndicatorsContainer",
28832
28896
  componentId: "sc-5ltegq-4"
28833
28897
  })(templateObject_8$2 || (templateObject_8$2 = __makeTemplateObject(["\n display: grid;\n grid-auto-flow: column;\n align-items: center;\n gap: ", ";\n"], ["\n display: grid;\n grid-auto-flow: column;\n align-items: center;\n gap: ", ";\n"])), paginationTokens.indicatorsContainer.spacing);
28834
- var Pagination = /*#__PURE__*/forwardRef(function (_a, ref) {
28835
- var itemsAmount = _a.itemsAmount,
28836
- _b = _a.defaultItemsPerPage,
28837
- defaultItemsPerPage = _b === void 0 ? 10 : _b,
28838
- _c = _a.defaultActivePage,
28839
- defaultActivePage = _c === void 0 ? 1 : _c,
28840
- _d = _a.withPagination,
28841
- withPagination = _d === void 0 ? true : _d,
28842
- withCounter = _a.withCounter,
28843
- withSelect = _a.withSelect,
28844
- _e = _a.selectOptions,
28845
- selectOptions = _e === void 0 ? [{
28898
+ var Pagination = /*#__PURE__*/forwardRef(function (props, ref) {
28899
+ var itemsAmount = props.itemsAmount,
28900
+ _a = props.defaultItemsPerPage,
28901
+ defaultItemsPerPage = _a === void 0 ? 10 : _a,
28902
+ _b = props.defaultActivePage,
28903
+ defaultActivePage = _b === void 0 ? 1 : _b,
28904
+ _c = props.withPagination,
28905
+ withPagination = _c === void 0 ? true : _c,
28906
+ withCounter = props.withCounter,
28907
+ withSelect = props.withSelect,
28908
+ _d = props.selectOptions,
28909
+ selectOptions = _d === void 0 ? [{
28846
28910
  label: '10',
28847
28911
  value: 10
28848
28912
  }, {
@@ -28854,19 +28918,21 @@ var Pagination = /*#__PURE__*/forwardRef(function (_a, ref) {
28854
28918
  }, {
28855
28919
  label: 'Alle',
28856
28920
  value: itemsAmount
28857
- }] : _e,
28858
- smallScreen = _a.smallScreen,
28859
- onChange = _a.onChange,
28860
- onSelectOptionChange = _a.onSelectOptionChange,
28861
- rest = __rest(_a, ["itemsAmount", "defaultItemsPerPage", "defaultActivePage", "withPagination", "withCounter", "withSelect", "selectOptions", "smallScreen", "onChange", "onSelectOptionChange"]);
28862
-
28863
- var _f = useState(defaultActivePage),
28864
- activePage = _f[0],
28865
- setActivePage = _f[1];
28866
-
28867
- var _g = useState(defaultItemsPerPage),
28868
- itemsPerPage = _g[0],
28869
- setItemsPerPage = _g[1];
28921
+ }] : _d,
28922
+ smallScreen = props.smallScreen,
28923
+ onChange = props.onChange,
28924
+ onSelectOptionChange = props.onSelectOptionChange,
28925
+ id = props.id,
28926
+ htmlProps = props.htmlProps,
28927
+ rest = __rest(props, ["itemsAmount", "defaultItemsPerPage", "defaultActivePage", "withPagination", "withCounter", "withSelect", "selectOptions", "smallScreen", "onChange", "onSelectOptionChange", "id", "htmlProps"]);
28928
+
28929
+ var _e = useState(defaultActivePage),
28930
+ activePage = _e[0],
28931
+ setActivePage = _e[1];
28932
+
28933
+ var _f = useState(defaultItemsPerPage),
28934
+ itemsPerPage = _f[0],
28935
+ setItemsPerPage = _f[1];
28870
28936
 
28871
28937
  var pagesLength = Math.ceil(itemsAmount / itemsPerPage);
28872
28938
  var items = PaginationGenerator(pagesLength, activePage);
@@ -28927,11 +28993,11 @@ var Pagination = /*#__PURE__*/forwardRef(function (_a, ref) {
28927
28993
  "aria-label": "G\xE5 til neste siden"
28928
28994
  });
28929
28995
 
28930
- var navProps = !withSelect && !withCounter && __assign({}, rest);
28996
+ var navProps = !withSelect && !withCounter && __assign({}, getBaseHTMLProps(id, htmlProps, rest));
28931
28997
 
28932
- var containerProps = __assign({
28998
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
28933
28999
  smallScreen: smallScreen
28934
- }, rest);
29000
+ });
28935
29001
 
28936
29002
  var isOnFirstPage = activePage === 1;
28937
29003
  var isOnLastPage = activePage === pagesLength;
@@ -29058,14 +29124,16 @@ var DividerLine = styled$3.hr.withConfig({
29058
29124
  var color = _a.color;
29059
29125
  return color && Ae(templateObject_1$w || (templateObject_1$w = __makeTemplateObject(["\n border-color: ", ";\n "], ["\n border-color: ", ";\n "])), dividerColors[color]);
29060
29126
  });
29061
- var Divider = /*#__PURE__*/forwardRef(function (_a, ref) {
29062
- var _b = _a.color,
29063
- color = _b === void 0 ? 'primary' : _b,
29064
- rest = __rest(_a, ["color"]);
29065
-
29066
- var lineProps = __assign({
29127
+ var Divider = /*#__PURE__*/forwardRef(function (props, ref) {
29128
+ var _a = props.color,
29129
+ color = _a === void 0 ? 'primary' : _a,
29130
+ id = props.id,
29131
+ htmlProps = props.htmlProps,
29132
+ rest = __rest(props, ["color", "id", "htmlProps"]);
29133
+
29134
+ var lineProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29067
29135
  color: color
29068
- }, rest);
29136
+ });
29069
29137
 
29070
29138
  return jsxRuntime.exports.jsx(DividerLine, __assign({
29071
29139
  ref: ref
@@ -29143,22 +29211,24 @@ var StyledList = styled$3.ul.withConfig({
29143
29211
  var listType = _a.listType;
29144
29212
  return listType === 'unordered' ? Ae(templateObject_2$m || (templateObject_2$m = __makeTemplateObject(["\n padding-left: ", ";\n list-style: none;\n li {\n position: relative;\n padding-left: ", ";\n &:before {\n content: '';\n display: inline-block;\n height: 1em;\n width: 1em;\n position: absolute;\n top: ", ";\n left: 0;\n background-size: contain;\n background-repeat: no-repeat;\n // disable eslint to ensure double quotes in url due to svg data URI in image bundle that requires them, as the attributes use single quotes\n // eslint-disable-next-line\n // prettier-ignore\n background-image: url(\"", "\");\n }\n ul > li:before {\n // disable eslint to ensure double quotes in url due to svg data URI in image bundle that requires them, as the attributes use single quotes\n // eslint-disable-next-line\n // prettier-ignore\n background-image: url(\"", "\");\n }\n ul > li > ul > li:before {\n // disable eslint to ensure double quotes in url due to svg data URI in image bundle that requires them, as the attributes use single quotes\n // eslint-disable-next-line\n // prettier-ignore\n background-image: url(\"", "\");\n }\n }\n "], ["\n padding-left: ", ";\n list-style: none;\n li {\n position: relative;\n padding-left: ", ";\n &:before {\n content: '';\n display: inline-block;\n height: 1em;\n width: 1em;\n position: absolute;\n top: ", ";\n left: 0;\n background-size: contain;\n background-repeat: no-repeat;\n // disable eslint to ensure double quotes in url due to svg data URI in image bundle that requires them, as the attributes use single quotes\n // eslint-disable-next-line\n // prettier-ignore\n background-image: url(\"", "\");\n }\n ul > li:before {\n // disable eslint to ensure double quotes in url due to svg data URI in image bundle that requires them, as the attributes use single quotes\n // eslint-disable-next-line\n // prettier-ignore\n background-image: url(\"", "\");\n }\n ul > li > ul > li:before {\n // disable eslint to ensure double quotes in url due to svg data URI in image bundle that requires them, as the attributes use single quotes\n // eslint-disable-next-line\n // prettier-ignore\n background-image: url(\"", "\");\n }\n }\n "])), "calc(".concat(ulPaddingLeft, ")"), "calc(".concat(liTextPadding, ")"), "calc((".concat(listItemTokens.base.lineHeight, " / 2) - 0.5em )"), img$3, img$2, img$1) : Ae(templateObject_3$d || (templateObject_3$d = __makeTemplateObject(["\n padding-left: ", ";\n & > li > ol {\n list-style-type: lower-alpha;\n }\n & > li > ol > li > ol {\n list-style-type: lower-roman;\n }\n "], ["\n padding-left: ", ";\n & > li > ol {\n list-style-type: lower-alpha;\n }\n & > li > ol > li > ol {\n list-style-type: lower-roman;\n }\n "])), listTokens.spaceLeft);
29145
29213
  });
29146
- var List = /*#__PURE__*/forwardRef(function (_a, ref) {
29147
- var _b = _a.listType,
29148
- listType = _b === void 0 ? 'unordered' : _b,
29149
- _c = _a.typographyType,
29150
- typographyType = _c === void 0 ? 'inherit' : _c,
29151
- children = _a.children,
29152
- rest = __rest(_a, ["listType", "typographyType", "children"]);
29214
+ var List = /*#__PURE__*/forwardRef(function (props, ref) {
29215
+ var _a = props.listType,
29216
+ listType = _a === void 0 ? 'unordered' : _a,
29217
+ _b = props.typographyType,
29218
+ typographyType = _b === void 0 ? 'inherit' : _b,
29219
+ children = props.children,
29220
+ id = props.id,
29221
+ htmlProps = props.htmlProps,
29222
+ rest = __rest(props, ["listType", "typographyType", "children", "id", "htmlProps"]);
29153
29223
 
29154
29224
  var as = listType === 'ordered' ? 'ol' : 'ul';
29155
29225
 
29156
- var listProps = __assign({
29226
+ var listProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29157
29227
  listType: listType,
29158
29228
  typographyType: typographyType,
29159
29229
  as: as,
29160
29230
  ref: ref
29161
- }, rest);
29231
+ });
29162
29232
 
29163
29233
  return jsxRuntime.exports.jsx(StyledList, __assign({}, listProps, {
29164
29234
  children: children
@@ -29215,16 +29285,18 @@ var DList = styled$3.dl.withConfig({
29215
29285
  var appearance = _a.appearance;
29216
29286
  return appearance && Ae(templateObject_1$t || (templateObject_1$t = __makeTemplateObject(["\n dt {\n ", "\n }\n "], ["\n dt {\n ", "\n }\n "])), descriptionListTermTokens.appearance[appearance].base);
29217
29287
  }, descriptionListTermTokens.unwrappedTopAndBottomSpace, descriptionListTermTokens.unwrappedTopAndBottomSpace, descriptionListTermTokens.unwrappedBetweenSpace);
29218
- var DescriptionList = /*#__PURE__*/forwardRef(function (_a, ref) {
29219
- var _b = _a.appearance,
29220
- appearance = _b === void 0 ? 'bold' : _b,
29221
- children = _a.children,
29222
- rest = __rest(_a, ["appearance", "children"]);
29223
-
29224
- var dListProps = __assign({
29288
+ var DescriptionList = /*#__PURE__*/forwardRef(function (props, ref) {
29289
+ var _a = props.appearance,
29290
+ appearance = _a === void 0 ? 'bold' : _a,
29291
+ children = props.children,
29292
+ id = props.id,
29293
+ htmlProps = props.htmlProps,
29294
+ rest = __rest(props, ["appearance", "children", "id", "htmlProps"]);
29295
+
29296
+ var dListProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29225
29297
  appearance: appearance,
29226
29298
  ref: ref
29227
- }, rest);
29299
+ });
29228
29300
 
29229
29301
  return jsxRuntime.exports.jsx(DList, __assign({}, dListProps, {
29230
29302
  children: children
@@ -29276,15 +29348,17 @@ var StyledIconWrapper$1 = styled$3(IconWrapper$1).withConfig({
29276
29348
  displayName: "DescriptionListDesc__StyledIconWrapper",
29277
29349
  componentId: "sc-1djcf0s-1"
29278
29350
  })(templateObject_2$k || (templateObject_2$k = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), descriptionListDescTokens.icon.base);
29279
- var DescriptionListDesc = /*#__PURE__*/forwardRef(function (_a, ref) {
29280
- var children = _a.children,
29281
- Icon = _a.Icon,
29282
- rest = __rest(_a, ["children", "Icon"]);
29351
+ var DescriptionListDesc = /*#__PURE__*/forwardRef(function (props, ref) {
29352
+ var children = props.children,
29353
+ Icon = props.Icon,
29354
+ id = props.id,
29355
+ htmlProps = props.htmlProps,
29356
+ rest = __rest(props, ["children", "Icon", "id", "htmlProps"]);
29283
29357
 
29284
- var dListDescProps = __assign({
29358
+ var dListDescProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29285
29359
  children: children,
29286
29360
  ref: ref
29287
- }, rest);
29361
+ });
29288
29362
 
29289
29363
  return jsxRuntime.exports.jsxs(DListDesc, __assign({}, dListDescProps, {
29290
29364
  children: [Icon && jsxRuntime.exports.jsx(StyledIconWrapper$1, {
@@ -29309,14 +29383,18 @@ var DListGroup = styled$3.div.withConfig({
29309
29383
  var margin = _a.margin;
29310
29384
  return margin && Ae(templateObject_1$q || (templateObject_1$q = __makeTemplateObject(["\n margin: ", ";\n "], ["\n margin: ", ";\n "])), margin);
29311
29385
  });
29312
- var DescriptionListGroup = /*#__PURE__*/forwardRef(function (_a, ref) {
29313
- var children = _a.children,
29314
- rest = __rest(_a, ["children"]);
29386
+ var DescriptionListGroup = /*#__PURE__*/forwardRef(function (props, ref) {
29387
+ var children = props.children,
29388
+ margin = props.margin,
29389
+ id = props.id,
29390
+ htmlProps = props.htmlProps,
29391
+ rest = __rest(props, ["children", "margin", "id", "htmlProps"]);
29315
29392
 
29316
- var dListGroupProps = __assign({
29393
+ var dListGroupProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29317
29394
  children: children,
29318
- ref: ref
29319
- }, rest);
29395
+ ref: ref,
29396
+ margin: margin
29397
+ });
29320
29398
 
29321
29399
  return jsxRuntime.exports.jsx(DListGroup, __assign({}, dListGroupProps, {
29322
29400
  children: children
@@ -29394,28 +29472,37 @@ var Container$a = styled$3.div.withConfig({
29394
29472
  return cardType === 'navigation' ? Ae(templateObject_2$i || (templateObject_2$i = __makeTemplateObject(["\n text-decoration: none;\n &:hover {\n ", "\n }\n &:focus {\n outline: none;\n ", "\n }\n "], ["\n text-decoration: none;\n &:hover {\n ", "\n }\n &:focus {\n outline: none;\n ", "\n }\n "])), cardTokens.navigation.hover.base, cardTokens.navigation.focus.base) : cardType === 'expandable' ? Ae(templateObject_3$c || (templateObject_3$c = __makeTemplateObject(["\n width: 100%;\n box-sizing: border-box;\n &:not(:first-of-type) {\n border-top: none;\n }\n "], ["\n width: 100%;\n box-sizing: border-box;\n &:not(:first-of-type) {\n border-top: none;\n }\n "]))) : '';
29395
29473
  });
29396
29474
  var Card = function Card(props) {
29397
- var _a;
29398
-
29399
- var color = (_a = props.color) !== null && _a !== void 0 ? _a : 'filledLight';
29400
-
29401
- if (props.cardType === 'navigation') {
29402
- return jsxRuntime.exports.jsx(Container$a, __assign({}, props, {
29403
- cardType: props.cardType,
29475
+ var _a = props.color,
29476
+ color = _a === void 0 ? 'filledLight' : _a,
29477
+ cardType = props.cardType,
29478
+ cardRef = props.cardRef,
29479
+ children = props.children,
29480
+ id = props.id,
29481
+ htmlProps = props.htmlProps,
29482
+ rest = __rest(props, ["color", "cardType", "cardRef", "children", "id", "htmlProps"]);
29483
+
29484
+ if (cardType === 'navigation') {
29485
+ var href = props.href,
29486
+ target = props.target;
29487
+ return jsxRuntime.exports.jsx(Container$a, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
29488
+ cardType: cardType,
29404
29489
  color: color,
29405
29490
  as: "a",
29406
- ref: props.cardRef
29491
+ ref: cardRef,
29492
+ href: href,
29493
+ target: target
29407
29494
  }, {
29408
- children: props.children
29495
+ children: children
29409
29496
  }));
29410
29497
  }
29411
29498
 
29412
- return jsxRuntime.exports.jsx(Container$a, __assign({}, props, {
29413
- cardType: props.cardType,
29499
+ return jsxRuntime.exports.jsx(Container$a, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
29500
+ cardType: cardType,
29414
29501
  color: color,
29415
29502
  as: "div",
29416
- ref: props.cardRef
29503
+ ref: cardRef
29417
29504
  }, {
29418
- children: props.children
29505
+ children: children
29419
29506
  }));
29420
29507
  };
29421
29508
  var templateObject_1$p, templateObject_2$i, templateObject_3$c, templateObject_4$7;
@@ -29425,16 +29512,17 @@ var Wrapper$4 = styled$3.div.withConfig({
29425
29512
  componentId: "sc-1ctxrby-0"
29426
29513
  })(templateObject_1$o || (templateObject_1$o = __makeTemplateObject([""], [""])));
29427
29514
  var nextUniqueId$a = 0;
29428
- var CardAccordion = /*#__PURE__*/forwardRef(function (_a, ref) {
29429
- var _b = _a.isExpanded,
29430
- isExpanded = _b === void 0 ? false : _b,
29431
- id = _a.id,
29432
- children = _a.children,
29433
- rest = __rest(_a, ["isExpanded", "id", "children"]);
29434
-
29435
- var _c = useState(isExpanded),
29436
- expanded = _c[0],
29437
- setExpanded = _c[1];
29515
+ var CardAccordion = /*#__PURE__*/forwardRef(function (props, ref) {
29516
+ var _a = props.isExpanded,
29517
+ isExpanded = _a === void 0 ? false : _a,
29518
+ id = props.id,
29519
+ children = props.children,
29520
+ htmlProps = props.htmlProps,
29521
+ rest = __rest(props, ["isExpanded", "id", "children", "htmlProps"]);
29522
+
29523
+ var _b = useState(isExpanded),
29524
+ expanded = _b[0],
29525
+ setExpanded = _b[1];
29438
29526
 
29439
29527
  var uniqueId = nextUniqueId$a++;
29440
29528
  var accordionId = useState(id !== null && id !== void 0 ? id : "cardAccordion-".concat(uniqueId))[0];
@@ -29461,11 +29549,11 @@ var CardAccordion = /*#__PURE__*/forwardRef(function (_a, ref) {
29461
29549
  }));
29462
29550
  });
29463
29551
 
29464
- var props = __assign({
29552
+ var wrapperProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29465
29553
  ref: ref
29466
- }, rest);
29554
+ });
29467
29555
 
29468
- return jsxRuntime.exports.jsx(Wrapper$4, __assign({}, props, {
29556
+ return jsxRuntime.exports.jsx(Wrapper$4, __assign({}, wrapperProps, {
29469
29557
  children: Children$1
29470
29558
  }));
29471
29559
  });
@@ -29524,13 +29612,15 @@ var ChevronWrapper = styled$3.span.withConfig({
29524
29612
  displayName: "CardAccordionHeader__ChevronWrapper",
29525
29613
  componentId: "sc-1qs6bkj-3"
29526
29614
  })(templateObject_4$6 || (templateObject_4$6 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n ", "\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n ", "\n"])), cardAccordionHeaderTokens.chevronWrapper.base);
29527
- var CardAccordionHeader = /*#__PURE__*/forwardRef(function (_a, ref) {
29528
- var children = _a.children,
29529
- _b = _a.isExpanded,
29530
- isExpanded = _b === void 0 ? false : _b,
29531
- toggleExpanded = _a.toggleExpanded,
29532
- bodyId = _a.bodyId,
29533
- rest = __rest(_a, ["children", "isExpanded", "toggleExpanded", "bodyId"]);
29615
+ var CardAccordionHeader = /*#__PURE__*/forwardRef(function (props, ref) {
29616
+ var children = props.children,
29617
+ _a = props.isExpanded,
29618
+ isExpanded = _a === void 0 ? false : _a,
29619
+ toggleExpanded = props.toggleExpanded,
29620
+ bodyId = props.bodyId,
29621
+ id = props.id,
29622
+ htmlProps = props.htmlProps,
29623
+ rest = __rest(props, ["children", "isExpanded", "toggleExpanded", "bodyId", "id", "htmlProps"]);
29534
29624
 
29535
29625
  var handleClick = function handleClick() {
29536
29626
  if (toggleExpanded) {
@@ -29538,12 +29628,12 @@ var CardAccordionHeader = /*#__PURE__*/forwardRef(function (_a, ref) {
29538
29628
  }
29539
29629
  };
29540
29630
 
29541
- var headerWrapperProps = __assign({
29631
+ var headerWrapperProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29542
29632
  'aria-expanded': isExpanded,
29543
29633
  'aria-controls': bodyId,
29544
29634
  ref: ref,
29545
29635
  onClick: handleClick
29546
- }, rest);
29636
+ });
29547
29637
 
29548
29638
  var chevronProps = {
29549
29639
  isUp: isExpanded,
@@ -29594,17 +29684,19 @@ var BodyContainer = styled$3.div.withConfig({
29594
29684
  var maxHeight = _a.maxHeight;
29595
29685
  return maxHeight ? maxHeight : 0;
29596
29686
  });
29597
- var CardAccordionBody = /*#__PURE__*/forwardRef(function (_a, ref) {
29598
- var children = _a.children,
29599
- isExpanded = _a.isExpanded,
29600
- headerId = _a.headerId,
29601
- rest = __rest(_a, ["children", "isExpanded", "headerId"]);
29687
+ var CardAccordionBody = /*#__PURE__*/forwardRef(function (props, ref) {
29688
+ var children = props.children,
29689
+ isExpanded = props.isExpanded,
29690
+ headerId = props.headerId,
29691
+ id = props.id,
29692
+ htmlProps = props.htmlProps,
29693
+ rest = __rest(props, ["children", "isExpanded", "headerId", "id", "htmlProps"]);
29602
29694
 
29603
29695
  var bodyRef = useRef(null);
29604
29696
 
29605
- var _b = useState(0),
29606
- maxHeight = _b[0],
29607
- setMaxHeight = _b[1];
29697
+ var _a = useState(0),
29698
+ maxHeight = _a[0],
29699
+ setMaxHeight = _a[1];
29608
29700
 
29609
29701
  useEffect(function () {
29610
29702
  if (!isExpanded) {
@@ -29614,21 +29706,21 @@ var CardAccordionBody = /*#__PURE__*/forwardRef(function (_a, ref) {
29614
29706
  }
29615
29707
  }, [isExpanded]);
29616
29708
 
29617
- var bodyProps = __assign({
29709
+ var bodyProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
29618
29710
  ref: ref,
29619
29711
  isExpanded: isExpanded,
29620
29712
  role: 'region'
29621
- }, rest);
29713
+ });
29622
29714
 
29623
29715
  var bodyContainerProps = {
29624
29716
  ref: bodyRef,
29625
29717
  maxHeight: maxHeight,
29626
29718
  isExpanded: isExpanded
29627
29719
  };
29628
- return jsxRuntime.exports.jsx(Body, __assign({
29720
+ return jsxRuntime.exports.jsx(Body, __assign({}, bodyProps, {
29629
29721
  "aria-labelledby": headerId,
29630
29722
  "aria-hidden": !isExpanded
29631
- }, bodyProps, {
29723
+ }, {
29632
29724
  children: jsxRuntime.exports.jsxs(BodyContainer, __assign({}, bodyContainerProps, {
29633
29725
  children: [" ", children, " "]
29634
29726
  }))
@@ -31544,16 +31636,35 @@ var StyledIconWrapper = styled$3(IconWrapper$1).withConfig({
31544
31636
  displayName: "OverflowMenuItem__StyledIconWrapper",
31545
31637
  componentId: "sc-1ka2asi-2"
31546
31638
  })(templateObject_3$9 || (templateObject_3$9 = __makeTemplateObject([""], [""])));
31547
- var OverflowMenuItem = /*#__PURE__*/forwardRef(function (_a, ref) {
31548
- var title = _a.title,
31549
- href = _a.href,
31550
- onClick = _a.onClick,
31551
- onKeyDown = _a.onKeyDown,
31552
- Icon = _a.Icon,
31553
- focus = _a.focus,
31554
- setFocus = _a.setFocus,
31555
- index = _a.index,
31556
- rest = __rest(_a, ["title", "href", "onClick", "onKeyDown", "Icon", "focus", "setFocus", "index"]);
31639
+
31640
+ var isAnchorProps = function isAnchorProps(props) {
31641
+ return props.href !== undefined;
31642
+ };
31643
+
31644
+ var isButtonProps = function isButtonProps(props) {
31645
+ return props.href === undefined && props.onClick !== undefined;
31646
+ };
31647
+
31648
+ var OverflowMenuItem = /*#__PURE__*/forwardRef(function (props, ref) {
31649
+ var title = props.title,
31650
+ Icon = props.Icon,
31651
+ focus = props.focus,
31652
+ setFocus = props.setFocus,
31653
+ index = props.index,
31654
+ id = props.id,
31655
+ _a = props.htmlProps,
31656
+ htmlProps = _a === void 0 ? {} : _a,
31657
+ rest = __rest(props, ["title", "Icon", "focus", "setFocus", "index", "id", "htmlProps"]);
31658
+
31659
+ var onKeyDown = htmlProps.onKeyDown;
31660
+ var href;
31661
+ var onClick;
31662
+
31663
+ if (isAnchorProps(props)) {
31664
+ href = props.href;
31665
+ } else if (isButtonProps(props)) {
31666
+ onClick = props.onClick;
31667
+ }
31557
31668
 
31558
31669
  var itemRef = useRef(null);
31559
31670
  var combinedRef = useCombinedRef(ref, itemRef);
@@ -31580,10 +31691,6 @@ var OverflowMenuItem = /*#__PURE__*/forwardRef(function (_a, ref) {
31580
31691
  onKeyDown && onKeyDown(e);
31581
31692
  };
31582
31693
 
31583
- var elementProps = __assign({
31584
- ref: ref
31585
- }, rest);
31586
-
31587
31694
  var linkProps = {
31588
31695
  href: href,
31589
31696
  onClick: handleOnClick,
@@ -31598,24 +31705,24 @@ var OverflowMenuItem = /*#__PURE__*/forwardRef(function (_a, ref) {
31598
31705
  });
31599
31706
 
31600
31707
  if (!href && !onClick) {
31601
- return jsxRuntime.exports.jsxs(Span, __assign({}, elementProps, {
31708
+ return jsxRuntime.exports.jsxs(Span, __assign({}, __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
31709
+ ref: ref
31710
+ }), {
31602
31711
  children: [icon, title]
31603
31712
  }));
31604
31713
  }
31605
31714
 
31606
31715
  if (!href) {
31607
- return jsxRuntime.exports.jsxs(Link$2, __assign({
31608
- as: "button"
31609
- }, linkProps, rest, {
31716
+ return jsxRuntime.exports.jsxs(Link$2, __assign({}, getBaseHTMLProps(id, htmlProps, rest), linkProps, {
31717
+ as: "button",
31610
31718
  ref: combinedRef
31611
31719
  }, {
31612
31720
  children: [icon, title]
31613
31721
  }));
31614
31722
  }
31615
31723
 
31616
- return jsxRuntime.exports.jsxs(Link$2, __assign({
31617
- as: "a"
31618
- }, linkProps, rest, {
31724
+ return jsxRuntime.exports.jsxs(Link$2, __assign({}, getBaseHTMLProps(id, htmlProps, rest), linkProps, {
31725
+ as: "a",
31619
31726
  ref: combinedRef
31620
31727
  }, {
31621
31728
  children: [icon, title]
@@ -31657,35 +31764,39 @@ var StyledDivider = styled$3(Divider).withConfig({
31657
31764
  displayName: "OverflowMenu__StyledDivider",
31658
31765
  componentId: "sc-kh744b-2"
31659
31766
  })(templateObject_3$8 || (templateObject_3$8 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), overflowMenuTokens.divider.base);
31660
- var OverflowMenu = /*#__PURE__*/forwardRef(function (_a, ref) {
31661
- var _b, _c;
31662
-
31663
- var anchorRef = _a.anchorRef,
31664
- onClose = _a.onClose,
31665
- _d = _a.isOpen,
31666
- isOpen = _d === void 0 ? false : _d,
31667
- _e = _a.placement,
31668
- placement = _e === void 0 ? 'bottom-end' : _e,
31669
- items = _a.items,
31670
- navItems = _a.navItems,
31671
- userProps = _a.userProps,
31672
- id = _a.id,
31673
- _f = _a.offset,
31674
- offset = _f === void 0 ? overflowMenuTokens.offset : _f,
31675
- style = _a.style,
31676
- rest = __rest(_a, ["anchorRef", "onClose", "isOpen", "placement", "items", "navItems", "userProps", "id", "offset", "style"]);
31677
-
31678
- var _g = useFloatPosition(null, placement, offset),
31679
- reference = _g.reference,
31680
- floating = _g.floating,
31681
- refs = _g.refs,
31682
- styles = _g.styles;
31767
+ var OverflowMenu = /*#__PURE__*/forwardRef(function (props, ref) {
31768
+ var _a, _b;
31769
+
31770
+ var anchorRef = props.anchorRef,
31771
+ onClose = props.onClose,
31772
+ _c = props.isOpen,
31773
+ isOpen = _c === void 0 ? false : _c,
31774
+ _d = props.placement,
31775
+ placement = _d === void 0 ? 'bottom-end' : _d,
31776
+ items = props.items,
31777
+ navItems = props.navItems,
31778
+ userProps = props.userProps,
31779
+ id = props.id,
31780
+ _e = props.offset,
31781
+ offset = _e === void 0 ? overflowMenuTokens.offset : _e,
31782
+ _f = props.htmlProps,
31783
+ htmlProps = _f === void 0 ? {} : _f,
31784
+ rest = __rest(props, ["anchorRef", "onClose", "isOpen", "placement", "items", "navItems", "userProps", "id", "offset", "htmlProps"]);
31785
+
31786
+ var _g = htmlProps.style,
31787
+ style = _g === void 0 ? {} : _g;
31788
+
31789
+ var _h = useFloatPosition(null, placement, offset),
31790
+ reference = _h.reference,
31791
+ floating = _h.floating,
31792
+ refs = _h.refs,
31793
+ styles = _h.styles;
31683
31794
 
31684
31795
  var combinedRef = useCombinedRef(ref, floating);
31685
31796
  useEffect(function () {
31686
31797
  anchorRef ? reference(anchorRef.current) : reference(null);
31687
31798
  }, [anchorRef]);
31688
- useOnClickOutside([(_b = refs === null || refs === void 0 ? void 0 : refs.floating) === null || _b === void 0 ? void 0 : _b.current, (_c = refs === null || refs === void 0 ? void 0 : refs.reference) === null || _c === void 0 ? void 0 : _c.current], function () {
31799
+ useOnClickOutside([(_a = refs === null || refs === void 0 ? void 0 : refs.floating) === null || _a === void 0 ? void 0 : _a.current, (_b = refs === null || refs === void 0 ? void 0 : refs.reference) === null || _b === void 0 ? void 0 : _b.current], function () {
31689
31800
  if (isOpen) onClose && onClose();
31690
31801
  });
31691
31802
  useOnKeyDown(['Esc', 'Escape'], function () {
@@ -31703,9 +31814,9 @@ var OverflowMenu = /*#__PURE__*/forwardRef(function (_a, ref) {
31703
31814
  var hasContextItems = !!items && items.length > 0;
31704
31815
  var hasNavItems = !!navItems && navItems.length > 0;
31705
31816
 
31706
- var _h = userProps || {},
31707
- username = _h.name,
31708
- userPropsRest = __rest(_h, ["name"]);
31817
+ var _j = userProps || {},
31818
+ username = _j.name,
31819
+ userPropsRest = __rest(_j, ["name"]);
31709
31820
 
31710
31821
  var hasStaticUser = username && userProps && !userProps.href && !userProps.onClick;
31711
31822
  var hasInteractiveUser = username && userProps && (!!userProps.href || !!userProps.onClick);
@@ -31716,9 +31827,9 @@ var OverflowMenu = /*#__PURE__*/forwardRef(function (_a, ref) {
31716
31827
  hasContextItems && interactiveItems.push.apply(interactiveItems, items);
31717
31828
  var hasInteractiveItems = interactiveItems.length > 0;
31718
31829
 
31719
- var _j = useRoveFocus(interactiveItems && interactiveItems.length, !isOpen),
31720
- focus = _j[0],
31721
- setFocus = _j[1];
31830
+ var _k = useRoveFocus(interactiveItems && interactiveItems.length, !isOpen),
31831
+ focus = _k[0],
31832
+ setFocus = _k[1];
31722
31833
 
31723
31834
  var interactiveItemsList = hasInteractiveItems ? interactiveItems.map(function (item, index) {
31724
31835
  return jsxRuntime.exports.jsx("li", {
@@ -31760,12 +31871,11 @@ var OverflowMenu = /*#__PURE__*/forwardRef(function (_a, ref) {
31760
31871
  }
31761
31872
  };
31762
31873
 
31763
- var containerProps = __assign(__assign({
31874
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
31764
31875
  ref: combinedRef,
31765
31876
  id: id !== null && id !== void 0 ? id : useId('overflowMenu'),
31766
31877
  isOpen: isOpen,
31767
- style: __assign(__assign({}, style), styles.floating)
31768
- }, rest), {
31878
+ style: __assign(__assign({}, style), styles.floating),
31769
31879
  'aria-hidden': !isOpen,
31770
31880
  role: 'menu'
31771
31881
  });
@@ -31831,8 +31941,8 @@ var OverflowMenuGroup = function OverflowMenuGroup(_a) {
31831
31941
  anchorRef: buttonRef
31832
31942
  }));
31833
31943
  });
31834
- return jsxRuntime.exports.jsxs(jsxRuntime.exports.Fragment, {
31835
- children: [" ", Children$1, " "]
31944
+ return jsxRuntime.exports.jsx(jsxRuntime.exports.Fragment, {
31945
+ children: Children$1
31836
31946
  });
31837
31947
  };
31838
31948
 
@@ -31923,23 +32033,25 @@ var InternalHeaderListItem = /*#__PURE__*/forwardRef(function (_a, ref) {
31923
32033
  });
31924
32034
  var templateObject_1$h;
31925
32035
 
31926
- var InternalHeader = function InternalHeader(_a) {
31927
- var applicationName = _a.applicationName,
31928
- smallScreen = _a.smallScreen,
31929
- navigationElements = _a.navigationElements,
31930
- contextMenuElements = _a.contextMenuElements,
31931
- currentPageHref = _a.currentPageHref,
31932
- userProps = _a.userProps,
31933
- onCurrentPageChange = _a.onCurrentPageChange,
31934
- rest = __rest(_a, ["applicationName", "smallScreen", "navigationElements", "contextMenuElements", "currentPageHref", "userProps", "onCurrentPageChange"]);
31935
-
31936
- var _b = useState(true),
31937
- contextMenuIsClosed = _b[0],
31938
- setContextMenuIsClosed = _b[1];
31939
-
31940
- var _c = useState(currentPageHref),
31941
- currentPage = _c[0],
31942
- setCurrentPage = _c[1];
32036
+ var InternalHeader = function InternalHeader(props) {
32037
+ var applicationName = props.applicationName,
32038
+ smallScreen = props.smallScreen,
32039
+ navigationElements = props.navigationElements,
32040
+ contextMenuElements = props.contextMenuElements,
32041
+ currentPageHref = props.currentPageHref,
32042
+ userProps = props.userProps,
32043
+ onCurrentPageChange = props.onCurrentPageChange,
32044
+ id = props.id,
32045
+ htmlProps = props.htmlProps,
32046
+ rest = __rest(props, ["applicationName", "smallScreen", "navigationElements", "contextMenuElements", "currentPageHref", "userProps", "onCurrentPageChange", "id", "htmlProps"]);
32047
+
32048
+ var _a = useState(true),
32049
+ contextMenuIsClosed = _a[0],
32050
+ setContextMenuIsClosed = _a[1];
32051
+
32052
+ var _b = useState(currentPageHref),
32053
+ currentPage = _b[0],
32054
+ setCurrentPage = _b[1];
31943
32055
 
31944
32056
  var buttonRef = useRef(null);
31945
32057
 
@@ -31982,7 +32094,7 @@ var InternalHeader = function InternalHeader(_a) {
31982
32094
  })
31983
32095
  })) : null;
31984
32096
  var hasContextMenu = hasContextMenuElements || !!userProps || hasNavInContextMenu;
31985
- return jsxRuntime.exports.jsxs(Wrapper$3, __assign({}, rest, {
32097
+ return jsxRuntime.exports.jsxs(Wrapper$3, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
31986
32098
  children: [jsxRuntime.exports.jsx(BannerWrapper, __assign({
31987
32099
  hasContextMenu: hasContextMenu
31988
32100
  }, {
@@ -32178,14 +32290,19 @@ var Link = styled$3.a.withConfig({
32178
32290
  displayName: "SkipToContent__Link",
32179
32291
  componentId: "sc-57o1qv-1"
32180
32292
  })(templateObject_2$b || (templateObject_2$b = __makeTemplateObject(["\n ", "\n &:focus {\n ", "\n transition: ", ";\n }\n &:hover {\n ", "\n }\n"], ["\n ", "\n &:focus {\n ", "\n transition: ", ";\n }\n &:hover {\n ", "\n }\n"])), skipToContentTokens.link.base, skipToContentTokens.link.focus.base, focusVisibleTransitionValue, skipToContentTokens.link.hover.base);
32181
- var SkipToContent = /*#__PURE__*/forwardRef(function (_a, ref) {
32182
- var _b = _a.text,
32183
- text = _b === void 0 ? 'Til hovedinnhold' : _b,
32184
- _c = _a.top,
32185
- top = _c === void 0 ? 0 : _c,
32186
- style = _a.style,
32187
- className = _a.className,
32188
- rest = __rest(_a, ["text", "top", "style", "className"]);
32293
+ var SkipToContent = /*#__PURE__*/forwardRef(function (props, ref) {
32294
+ var _a = props.text,
32295
+ text = _a === void 0 ? 'Til hovedinnhold' : _a,
32296
+ _b = props.top,
32297
+ top = _b === void 0 ? 0 : _b,
32298
+ id = props.id,
32299
+ _c = props.htmlProps,
32300
+ htmlProps = _c === void 0 ? {} : _c,
32301
+ rest = __rest(props, ["text", "top", "id", "htmlProps"]);
32302
+
32303
+ var className = htmlProps.className,
32304
+ style = htmlProps.style,
32305
+ restHtmlProps = __rest(htmlProps, ["className", "style"]);
32189
32306
 
32190
32307
  var wrapperProps = {
32191
32308
  top: top,
@@ -32193,9 +32310,9 @@ var SkipToContent = /*#__PURE__*/forwardRef(function (_a, ref) {
32193
32310
  style: style
32194
32311
  };
32195
32312
  return jsxRuntime.exports.jsx(Wrapper$2, __assign({}, wrapperProps, {
32196
- children: jsxRuntime.exports.jsx(Link, __assign({
32313
+ children: jsxRuntime.exports.jsx(Link, __assign({}, getBaseHTMLProps(id, restHtmlProps, rest), {
32197
32314
  ref: ref
32198
- }, rest, {
32315
+ }, {
32199
32316
  children: text
32200
32317
  }))
32201
32318
  }));
@@ -32254,35 +32371,37 @@ var TooltipWrapper = styled$3.div.withConfig({
32254
32371
  var templateObject_1$e, templateObject_2$a, templateObject_3$6, templateObject_4$3;
32255
32372
 
32256
32373
  var nextUniqueId$7 = 0;
32257
- var Tooltip = /*#__PURE__*/forwardRef(function (_a, ref) {
32258
- var text = _a.text,
32259
- _b = _a.placement,
32260
- placement = _b === void 0 ? 'bottom' : _b,
32261
- children = _a.children,
32262
- tooltipId = _a.tooltipId,
32263
- _c = _a.delay,
32264
- delay = _c === void 0 ? 100 : _c,
32265
- style = _a.style,
32266
- onMouseLeave = _a.onMouseLeave,
32267
- onMouseOver = _a.onMouseOver,
32268
- className = _a.className,
32269
- rest = __rest(_a, ["text", "placement", "children", "tooltipId", "delay", "style", "onMouseLeave", "onMouseOver", "className"]);
32374
+ var Tooltip = /*#__PURE__*/forwardRef(function (props, ref) {
32375
+ var text = props.text,
32376
+ _a = props.placement,
32377
+ placement = _a === void 0 ? 'bottom' : _a,
32378
+ children = props.children,
32379
+ tooltipId = props.tooltipId,
32380
+ _b = props.delay,
32381
+ delay = _b === void 0 ? 100 : _b,
32382
+ style = props.style,
32383
+ onMouseLeave = props.onMouseLeave,
32384
+ onMouseOver = props.onMouseOver,
32385
+ className = props.className,
32386
+ id = props.id,
32387
+ htmlProps = props.htmlProps,
32388
+ rest = __rest(props, ["text", "placement", "children", "tooltipId", "delay", "style", "onMouseLeave", "onMouseOver", "className", "id", "htmlProps"]);
32270
32389
 
32271
32390
  var uniqueId = nextUniqueId$7++;
32272
32391
  var uniqueTooltipId = useState(tooltipId !== null && tooltipId !== void 0 ? tooltipId : "tooltip-".concat(uniqueId))[0];
32273
32392
 
32274
- var _d = useState(false),
32275
- open = _d[0],
32276
- setOpen = _d[1];
32393
+ var _c = useState(false),
32394
+ open = _c[0],
32395
+ setOpen = _c[1];
32277
32396
 
32278
- var _e = useState(null),
32279
- arrowElement = _e[0],
32280
- setArrowElement = _e[1];
32397
+ var _d = useState(null),
32398
+ arrowElement = _d[0],
32399
+ setArrowElement = _d[1];
32281
32400
 
32282
- var _f = useFloatPosition(arrowElement, placement),
32283
- reference = _f.reference,
32284
- floating = _f.floating,
32285
- styles = _f.styles;
32401
+ var _e = useFloatPosition(arrowElement, placement),
32402
+ reference = _e.reference,
32403
+ floating = _e.floating,
32404
+ styles = _e.styles;
32286
32405
 
32287
32406
  var combinedRef = useCombinedRef(ref, floating);
32288
32407
  var timer;
@@ -32316,6 +32435,14 @@ var Tooltip = /*#__PURE__*/forwardRef(function (_a, ref) {
32316
32435
  onBlur: combineHandlers(closeTooltip, anchorProps.onBlur),
32317
32436
  'aria-describedby': uniqueTooltipId
32318
32437
  }));
32438
+
32439
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
32440
+ style: style,
32441
+ className: className,
32442
+ onMouseLeave: combineHandlers(closeTooltip, onMouseLeave),
32443
+ onMouseOver: combineHandlers(openTooltip, onMouseOver)
32444
+ });
32445
+
32319
32446
  var wrapperProps = {
32320
32447
  id: uniqueTooltipId,
32321
32448
  ref: combinedRef,
@@ -32324,14 +32451,6 @@ var Tooltip = /*#__PURE__*/forwardRef(function (_a, ref) {
32324
32451
  open: open,
32325
32452
  style: __assign({}, styles.floating)
32326
32453
  };
32327
-
32328
- var containerProps = __assign({
32329
- style: style,
32330
- className: className,
32331
- onMouseLeave: combineHandlers(closeTooltip, onMouseLeave),
32332
- onMouseOver: combineHandlers(openTooltip, onMouseOver)
32333
- }, rest);
32334
-
32335
32454
  var arrowWrapperProps = {
32336
32455
  ref: setArrowElement,
32337
32456
  style: styles.arrow
@@ -32415,17 +32534,18 @@ var StyledButton$2 = styled$3(Button$1).withConfig({
32415
32534
  componentId: "sc-12c14zx-3"
32416
32535
  })(templateObject_4$2 || (templateObject_4$2 = __makeTemplateObject(["\n align-self: flex-end;\n"], ["\n align-self: flex-end;\n"])));
32417
32536
  var nextUniqueId$6 = 0;
32418
- var Modal = /*#__PURE__*/forwardRef(function (_a, ref) {
32419
- var _b = _a.isOpen,
32420
- isOpen = _b === void 0 ? false : _b,
32421
- _c = _a.parentElement,
32422
- parentElement = _c === void 0 ? document.body : _c,
32423
- children = _a.children,
32424
- header = _a.header,
32425
- onClose = _a.onClose,
32426
- id = _a.id,
32427
- triggerRef = _a.triggerRef,
32428
- rest = __rest(_a, ["isOpen", "parentElement", "children", "header", "onClose", "id", "triggerRef"]);
32537
+ var Modal = /*#__PURE__*/forwardRef(function (props, ref) {
32538
+ var _a = props.isOpen,
32539
+ isOpen = _a === void 0 ? false : _a,
32540
+ _b = props.parentElement,
32541
+ parentElement = _b === void 0 ? document.body : _b,
32542
+ children = props.children,
32543
+ header = props.header,
32544
+ onClose = props.onClose,
32545
+ id = props.id,
32546
+ triggerRef = props.triggerRef,
32547
+ htmlProps = props.htmlProps,
32548
+ rest = __rest(props, ["isOpen", "parentElement", "children", "header", "onClose", "id", "triggerRef", "htmlProps"]);
32429
32549
 
32430
32550
  var uniqueId = nextUniqueId$6++;
32431
32551
  var modalId = useState(id !== null && id !== void 0 ? id : "modal-".concat(uniqueId))[0];
@@ -32460,7 +32580,7 @@ var Modal = /*#__PURE__*/forwardRef(function (_a, ref) {
32460
32580
  isOpen: hasTransitionedIn && isOpen
32461
32581
  };
32462
32582
 
32463
- var containerProps = __assign({
32583
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
32464
32584
  ref: combinedRef,
32465
32585
  role: 'dialog',
32466
32586
  'aria-modal': true,
@@ -32468,7 +32588,7 @@ var Modal = /*#__PURE__*/forwardRef(function (_a, ref) {
32468
32588
  tabIndex: -1,
32469
32589
  'aria-labelledby': headerId,
32470
32590
  id: modalId
32471
- }, rest);
32591
+ });
32472
32592
 
32473
32593
  var headerContainerProps = {
32474
32594
  id: headerId
@@ -32503,16 +32623,18 @@ var Container$6 = styled$3.div.withConfig({
32503
32623
  var scrollable = _a.scrollable;
32504
32624
  return scrollable && Ae(templateObject_1$c || (templateObject_1$c = __makeTemplateObject(["\n ", "\n &:focus-visible, &.focus-visible {\n ", "\n }\n "], ["\n ", "\n &:focus-visible, &.focus-visible {\n ", "\n }\n "])), modalTokens.bodyScrollable.base, modalTokens.bodyScrollable.focus.base);
32505
32625
  });
32506
- var ModalBody = /*#__PURE__*/forwardRef(function (_a, ref) {
32507
- var children = _a.children,
32508
- scrollable = _a.scrollable,
32509
- rest = __rest(_a, ["children", "scrollable"]);
32626
+ var ModalBody = /*#__PURE__*/forwardRef(function (props, ref) {
32627
+ var children = props.children,
32628
+ scrollable = props.scrollable,
32629
+ id = props.id,
32630
+ htmlProps = props.htmlProps,
32631
+ rest = __rest(props, ["children", "scrollable", "id", "htmlProps"]);
32510
32632
 
32511
- var containerProps = __assign({
32633
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
32512
32634
  ref: ref,
32513
32635
  tabIndex: scrollable ? 0 : undefined,
32514
32636
  scrollable: scrollable
32515
- }, rest);
32637
+ });
32516
32638
 
32517
32639
  return jsxRuntime.exports.jsx(Container$6, __assign({}, containerProps, {
32518
32640
  children: children
@@ -32596,21 +32718,22 @@ var StyledButton$1 = styled$3(Button$1).withConfig({
32596
32718
  componentId: "sc-i9luw3-3"
32597
32719
  })(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n align-self: flex-end;\n"], ["\n align-self: flex-end;\n"])));
32598
32720
  var nextUniqueId$5 = 0;
32599
- var Drawer = /*#__PURE__*/forwardRef(function (_a, ref) {
32600
- var children = _a.children,
32601
- onClose = _a.onClose,
32602
- header = _a.header,
32603
- _b = _a.isOpen,
32604
- isOpen = _b === void 0 ? false : _b,
32605
- _c = _a.placement,
32606
- placement = _c === void 0 ? 'right' : _c,
32607
- _d = _a.parentElement,
32608
- parentElement = _d === void 0 ? document.body : _d,
32609
- _e = _a.size,
32610
- size = _e === void 0 ? 'small' : _e,
32611
- triggerRef = _a.triggerRef,
32612
- id = _a.id,
32613
- rest = __rest(_a, ["children", "onClose", "header", "isOpen", "placement", "parentElement", "size", "triggerRef", "id"]);
32721
+ var Drawer = /*#__PURE__*/forwardRef(function (props, ref) {
32722
+ var children = props.children,
32723
+ onClose = props.onClose,
32724
+ header = props.header,
32725
+ _a = props.isOpen,
32726
+ isOpen = _a === void 0 ? false : _a,
32727
+ _b = props.placement,
32728
+ placement = _b === void 0 ? 'right' : _b,
32729
+ _c = props.parentElement,
32730
+ parentElement = _c === void 0 ? document.body : _c,
32731
+ _d = props.size,
32732
+ size = _d === void 0 ? 'small' : _d,
32733
+ triggerRef = props.triggerRef,
32734
+ id = props.id,
32735
+ htmlProps = props.htmlProps,
32736
+ rest = __rest(props, ["children", "onClose", "header", "isOpen", "placement", "parentElement", "size", "triggerRef", "id", "htmlProps"]);
32614
32737
 
32615
32738
  var uniqueId = useState(id !== null && id !== void 0 ? id : "drawer-".concat(nextUniqueId$5++))[0];
32616
32739
  var hasHeader = !!header;
@@ -32632,7 +32755,7 @@ var Drawer = /*#__PURE__*/forwardRef(function (_a, ref) {
32632
32755
  });
32633
32756
  var hasTransitionedIn = useMountTransition(isOpen, 500);
32634
32757
 
32635
- var containerProps = __assign({
32758
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
32636
32759
  placement: placement,
32637
32760
  ref: combinedRef,
32638
32761
  isOpen: hasTransitionedIn && isOpen,
@@ -32641,7 +32764,7 @@ var Drawer = /*#__PURE__*/forwardRef(function (_a, ref) {
32641
32764
  id: uniqueId,
32642
32765
  'aria-labelledby': headerId,
32643
32766
  size: size
32644
- }, rest);
32767
+ });
32645
32768
 
32646
32769
  var headerContainerProps = {
32647
32770
  id: headerId
@@ -32781,22 +32904,24 @@ var StyledButton = styled$3(Button$1).withConfig({
32781
32904
  displayName: "Popover__StyledButton",
32782
32905
  componentId: "sc-1fecd7e-3"
32783
32906
  })(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), popoverTokens.button.base);
32784
- var Popover = /*#__PURE__*/forwardRef(function (_a, ref) {
32785
- var title = _a.title,
32786
- _b = _a.isOpen,
32787
- isOpen = _b === void 0 ? false : _b,
32788
- _c = _a.withCloseButton,
32789
- withCloseButton = _c === void 0 ? true : _c,
32790
- onCloseButtonClick = _a.onCloseButtonClick,
32791
- onCloseButtonBlur = _a.onCloseButtonBlur,
32792
- anchorElement = _a.anchorElement,
32793
- children = _a.children,
32794
- _d = _a.placement,
32795
- placement = _d === void 0 ? 'bottom' : _d,
32796
- _e = _a.offset,
32797
- offset = _e === void 0 ? Spacing$2.SizesDdsSpacingLocalX05NumberPx : _e,
32798
- style = _a.style,
32799
- rest = __rest(_a, ["title", "isOpen", "withCloseButton", "onCloseButtonClick", "onCloseButtonBlur", "anchorElement", "children", "placement", "offset", "style"]);
32907
+ var Popover = /*#__PURE__*/forwardRef(function (props, ref) {
32908
+ var title = props.title,
32909
+ _a = props.isOpen,
32910
+ isOpen = _a === void 0 ? false : _a,
32911
+ _b = props.withCloseButton,
32912
+ withCloseButton = _b === void 0 ? true : _b,
32913
+ onCloseButtonClick = props.onCloseButtonClick,
32914
+ onCloseButtonBlur = props.onCloseButtonBlur,
32915
+ anchorElement = props.anchorElement,
32916
+ children = props.children,
32917
+ _c = props.placement,
32918
+ placement = _c === void 0 ? 'bottom' : _c,
32919
+ _d = props.offset,
32920
+ offset = _d === void 0 ? Spacing$2.SizesDdsSpacingLocalX05NumberPx : _d,
32921
+ id = props.id,
32922
+ _e = props.htmlProps,
32923
+ htmlProps = _e === void 0 ? {} : _e,
32924
+ rest = __rest(props, ["title", "isOpen", "withCloseButton", "onCloseButtonClick", "onCloseButtonBlur", "anchorElement", "children", "placement", "offset", "id", "htmlProps"]);
32800
32925
 
32801
32926
  var _f = useFloatPosition(null, placement, offset),
32802
32927
  reference = _f.reference,
@@ -32811,11 +32936,10 @@ var Popover = /*#__PURE__*/forwardRef(function (_a, ref) {
32811
32936
  };
32812
32937
  }, [anchorElement, isOpen]);
32813
32938
 
32814
- var wrapperProps = __assign(__assign({
32939
+ var wrapperProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
32815
32940
  ref: multiRef,
32816
32941
  isOpen: isOpen,
32817
- style: __assign(__assign({}, style), styles.floating)
32818
- }, rest), {
32942
+ style: __assign(__assign({}, htmlProps.style), styles.floating),
32819
32943
  role: 'dialog'
32820
32944
  });
32821
32945
 
@@ -32988,15 +33112,16 @@ var ToggleButton = /*#__PURE__*/forwardRef(function (_a, ref) {
32988
33112
  var id = _a.id,
32989
33113
  label = _a.label,
32990
33114
  Icon = _a.Icon,
32991
- rest = __rest(_a, ["id", "label", "Icon"]);
33115
+ htmlProps = _a.htmlProps,
33116
+ rest = __rest(_a, ["id", "label", "Icon", "htmlProps"]);
32992
33117
 
32993
33118
  var uniqueId = useState(id !== null && id !== void 0 ? id : "toggleButton-".concat(nextUniqueId$2++))[0];
32994
33119
 
32995
- var inputProps = __assign({
33120
+ var inputProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
32996
33121
  ref: ref,
32997
33122
  id: uniqueId,
32998
33123
  type: 'checkbox'
32999
- }, rest);
33124
+ });
33000
33125
 
33001
33126
  var containerProps = {
33002
33127
  htmlFor: uniqueId
@@ -33024,23 +33149,25 @@ var Container$2 = styled$3.div.withConfig({
33024
33149
  componentId: "sc-14ijdag-1"
33025
33150
  })(templateObject_3$1 || (templateObject_3$1 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), toggleButtonTokens.container.base);
33026
33151
  var nextUniqueId$1 = 0;
33027
- var ToggleButtonGroup = function ToggleButtonGroup(_a) {
33028
- var children = _a.children,
33029
- _b = _a.direction,
33030
- direction = _b === void 0 ? 'row' : _b,
33031
- label = _a.label,
33032
- labelId = _a.labelId,
33033
- props = __rest(_a, ["children", "direction", "label", "labelId"]);
33152
+ var ToggleButtonGroup = function ToggleButtonGroup(props) {
33153
+ var children = props.children,
33154
+ _a = props.direction,
33155
+ direction = _a === void 0 ? 'row' : _a,
33156
+ label = props.label,
33157
+ labelId = props.labelId,
33158
+ id = props.id,
33159
+ htmlProps = props.htmlProps,
33160
+ rest = __rest(props, ["children", "direction", "label", "labelId", "id", "htmlProps"]);
33034
33161
 
33035
33162
  var uniqueLabelId = useState(labelId !== null && labelId !== void 0 ? labelId : "ToggleButtonGroupLabel-".concat(nextUniqueId$1++))[0];
33036
33163
  var groupProps = {
33037
33164
  direction: direction
33038
33165
  };
33039
33166
 
33040
- var containerProps = __assign({
33167
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
33041
33168
  role: 'group',
33042
33169
  'aria-labelledby': label ? uniqueLabelId : undefined
33043
- }, props);
33170
+ });
33044
33171
 
33045
33172
  return jsxRuntime.exports.jsxs(Container$2, __assign({}, containerProps, {
33046
33173
  children: [!!label && jsxRuntime.exports.jsx(Typography, __assign({
@@ -33080,26 +33207,28 @@ var Container$1 = styled$3.div.withConfig({
33080
33207
  componentId: "sc-7ta5g2-0"
33081
33208
  })(templateObject_1$6 || (templateObject_1$6 = __makeTemplateObject([""], [""])));
33082
33209
  var nextUniqueId = 0;
33083
- var Tabs = /*#__PURE__*/forwardRef(function (_a, ref) {
33084
- var id = _a.id,
33085
- _b = _a.activeTab,
33086
- activeTab = _b === void 0 ? 0 : _b,
33087
- onChange = _a.onChange,
33088
- _c = _a.tabContentDirection,
33089
- tabContentDirection = _c === void 0 ? 'row' : _c,
33090
- _d = _a.tabWidth,
33091
- tabWidth = _d === void 0 ? '150px' : _d,
33092
- rest = __rest(_a, ["id", "activeTab", "onChange", "tabContentDirection", "tabWidth"]);
33210
+ var Tabs = /*#__PURE__*/forwardRef(function (props, ref) {
33211
+ var id = props.id,
33212
+ _a = props.activeTab,
33213
+ activeTab = _a === void 0 ? 0 : _a,
33214
+ onChange = props.onChange,
33215
+ _b = props.tabContentDirection,
33216
+ tabContentDirection = _b === void 0 ? 'row' : _b,
33217
+ _c = props.tabWidth,
33218
+ tabWidth = _c === void 0 ? '150px' : _c,
33219
+ children = props.children,
33220
+ htmlProps = props.htmlProps,
33221
+ rest = __rest(props, ["id", "activeTab", "onChange", "tabContentDirection", "tabWidth", "children", "htmlProps"]);
33093
33222
 
33094
33223
  var uniqueId = useState(id !== null && id !== void 0 ? id : "tabs-".concat(nextUniqueId++))[0];
33095
33224
 
33096
- var _e = useState(activeTab),
33097
- thisActiveTab = _e[0],
33098
- setActiveTab = _e[1];
33225
+ var _d = useState(activeTab),
33226
+ thisActiveTab = _d[0],
33227
+ setActiveTab = _d[1];
33099
33228
 
33100
- var _f = useState(false),
33101
- hasTabFocus = _f[0],
33102
- setHasTabFocus = _f[1];
33229
+ var _e = useState(false),
33230
+ hasTabFocus = _e[0],
33231
+ setHasTabFocus = _e[1];
33103
33232
 
33104
33233
  var tabListRef = useRef(null);
33105
33234
  var tabPanelsRef = useRef(null);
@@ -33109,10 +33238,10 @@ var Tabs = /*#__PURE__*/forwardRef(function (_a, ref) {
33109
33238
  onChange && onChange(index);
33110
33239
  };
33111
33240
 
33112
- var containerProps = __assign({
33241
+ var containerProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
33113
33242
  ref: ref,
33114
33243
  id: uniqueId
33115
- }, rest);
33244
+ });
33116
33245
 
33117
33246
  return jsxRuntime.exports.jsx(TabsContext.Provider, __assign({
33118
33247
  value: {
@@ -33127,7 +33256,9 @@ var Tabs = /*#__PURE__*/forwardRef(function (_a, ref) {
33127
33256
  tabWidth: tabWidth
33128
33257
  }
33129
33258
  }, {
33130
- children: jsxRuntime.exports.jsx(Container$1, __assign({}, containerProps))
33259
+ children: jsxRuntime.exports.jsx(Container$1, __assign({}, containerProps, {
33260
+ children: children
33261
+ }))
33131
33262
  }));
33132
33263
  });
33133
33264
  var templateObject_1$6;
@@ -33241,28 +33372,30 @@ var Button = styled$3.button.withConfig({
33241
33372
  var active = _a.active;
33242
33373
  return active && Ae(templateObject_1$5 || (templateObject_1$5 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), tabsTokens.tab.active.base);
33243
33374
  }, tabsTokens.tab.focus.base, tabsTokens.tab.hover.base);
33244
- var Tab = /*#__PURE__*/forwardRef(function (_a, ref) {
33245
- var _b = _a.active,
33246
- active = _b === void 0 ? false : _b,
33247
- width = _a.width,
33248
- Icon = _a.Icon,
33249
- children = _a.children,
33250
- focus = _a.focus,
33251
- setFocus = _a.setFocus,
33252
- index = _a.index,
33253
- onClick = _a.onClick,
33254
- onKeyDown = _a.onKeyDown,
33255
- rest = __rest(_a, ["active", "width", "Icon", "children", "focus", "setFocus", "index", "onClick", "onKeyDown"]);
33375
+ var Tab = /*#__PURE__*/forwardRef(function (props, ref) {
33376
+ var _a = props.active,
33377
+ active = _a === void 0 ? false : _a,
33378
+ width = props.width,
33379
+ Icon = props.Icon,
33380
+ children = props.children,
33381
+ focus = props.focus,
33382
+ setFocus = props.setFocus,
33383
+ index = props.index,
33384
+ onClick = props.onClick,
33385
+ onKeyDown = props.onKeyDown,
33386
+ id = props.id,
33387
+ htmlProps = props.htmlProps,
33388
+ rest = __rest(props, ["active", "width", "Icon", "children", "focus", "setFocus", "index", "onClick", "onKeyDown", "id", "htmlProps"]);
33256
33389
 
33257
33390
  var itemRef = useRef(null);
33258
33391
  var combinedRef = useCombinedRef(ref, itemRef);
33259
33392
 
33260
- var _c = useTabsContext(),
33261
- tabPanelsRef = _c.tabPanelsRef,
33262
- hasTabFocus = _c.hasTabFocus,
33263
- setHasTabFocus = _c.setHasTabFocus,
33264
- tabContentDirection = _c.tabContentDirection,
33265
- tabWidth = _c.tabWidth;
33393
+ var _b = useTabsContext(),
33394
+ tabPanelsRef = _b.tabPanelsRef,
33395
+ hasTabFocus = _b.hasTabFocus,
33396
+ setHasTabFocus = _b.setHasTabFocus,
33397
+ tabContentDirection = _b.tabContentDirection,
33398
+ tabWidth = _b.tabWidth;
33266
33399
 
33267
33400
  useEffect(function () {
33268
33401
  var _a;
@@ -33295,7 +33428,7 @@ var Tab = /*#__PURE__*/forwardRef(function (_a, ref) {
33295
33428
  onKeyDown && onKeyDown(e);
33296
33429
  };
33297
33430
 
33298
- var buttonProps = __assign({
33431
+ var buttonProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
33299
33432
  ref: combinedRef,
33300
33433
  'aria-selected': active,
33301
33434
  role: 'tab',
@@ -33305,7 +33438,7 @@ var Tab = /*#__PURE__*/forwardRef(function (_a, ref) {
33305
33438
  onClick: handleOnClick,
33306
33439
  onKeyDown: handleOnKeyDown,
33307
33440
  tabIndex: focus ? 0 : -1
33308
- }, rest);
33441
+ });
33309
33442
 
33310
33443
  return jsxRuntime.exports.jsxs(Button, __assign({}, buttonProps, {
33311
33444
  children: [Icon && jsxRuntime.exports.jsx(IconWrapper$1, {
@@ -33373,14 +33506,14 @@ var TabList = /*#__PURE__*/forwardRef(function (_a, ref) {
33373
33506
  onFocus && onFocus(event);
33374
33507
  };
33375
33508
 
33376
- var tabListProps = __assign({
33509
+ var tabListProps = __assign(__assign({}, rest), {
33377
33510
  ref: combinedRef,
33378
33511
  role: 'tablist',
33379
33512
  'aria-label': 'Bruk venste og høyre piltast for å bla',
33380
33513
  id: uniqueId,
33381
33514
  tabIndex: 0,
33382
33515
  onFocus: handleOnFocus
33383
- }, rest);
33516
+ });
33384
33517
 
33385
33518
  return jsxRuntime.exports.jsx(TabRow, __assign({}, tabListProps, {
33386
33519
  children: tabListChildren
@@ -33399,14 +33532,16 @@ var TabPanel = /*#__PURE__*/forwardRef(function (_a, ref) {
33399
33532
  var _b = _a.active,
33400
33533
  active = _b === void 0 ? false : _b,
33401
33534
  children = _a.children,
33402
- rest = __rest(_a, ["active", "children"]);
33535
+ id = _a.id,
33536
+ htmlProps = _a.htmlProps,
33537
+ rest = __rest(_a, ["active", "children", "id", "htmlProps"]);
33403
33538
 
33404
- var panelProps = __assign({
33539
+ var panelProps = __assign(__assign({}, getBaseHTMLProps(id, htmlProps, rest)), {
33405
33540
  ref: ref,
33406
33541
  tabIndex: 0,
33407
33542
  role: 'tabpanel',
33408
33543
  active: active
33409
- }, rest);
33544
+ });
33410
33545
 
33411
33546
  return jsxRuntime.exports.jsx(Panel, __assign({}, panelProps, {
33412
33547
  children: children
@@ -33506,18 +33641,20 @@ var Inner = styled$3.span.withConfig({
33506
33641
  displayName: "Tag__Inner",
33507
33642
  componentId: "sc-rdxtch-1"
33508
33643
  })(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), tagTokens.inner.base);
33509
- var Tag = /*#__PURE__*/forwardRef(function (_a, ref) {
33510
- var text = _a.text,
33511
- _b = _a.purpose,
33512
- purpose = _b === void 0 ? 'default' : _b,
33513
- rest = __rest(_a, ["text", "purpose"]);
33514
-
33515
- return jsxRuntime.exports.jsx(Wrapper, __assign({
33644
+ var Tag = /*#__PURE__*/forwardRef(function (props, ref) {
33645
+ var text = props.text,
33646
+ _a = props.purpose,
33647
+ purpose = _a === void 0 ? 'default' : _a,
33648
+ id = props.id,
33649
+ htmlProps = props.htmlProps,
33650
+ rest = __rest(props, ["text", "purpose", "id", "htmlProps"]);
33651
+
33652
+ return jsxRuntime.exports.jsx(Wrapper, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
33516
33653
  forwardedAs: "span",
33517
33654
  typographyType: "bodySans01",
33518
33655
  ref: ref,
33519
33656
  purpose: purpose
33520
- }, rest, {
33657
+ }, {
33521
33658
  children: jsxRuntime.exports.jsx(Inner, {
33522
33659
  children: text
33523
33660
  })
@@ -33571,11 +33708,15 @@ var TextWrapper = styled$3.span.withConfig({
33571
33708
  displayName: "Chip__TextWrapper",
33572
33709
  componentId: "sc-1l242zs-1"
33573
33710
  })(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), chipTokens.text.base);
33574
- var Chip = /*#__PURE__*/forwardRef(function (_a, ref) {
33575
- var text = _a.text,
33576
- onClose = _a.onClose,
33577
- ariaLabel = _a["aria-label"],
33578
- rest = __rest(_a, ["text", "onClose", 'aria-label']);
33711
+ var Chip = /*#__PURE__*/forwardRef(function (props, ref) {
33712
+ var text = props.text,
33713
+ onClose = props.onClose,
33714
+ id = props.id,
33715
+ _a = props.htmlProps,
33716
+ htmlProps = _a === void 0 ? {} : _a,
33717
+ rest = __rest(props, ["text", "onClose", "id", "htmlProps"]);
33718
+
33719
+ var ariaLabel = htmlProps["aria-label"];
33579
33720
 
33580
33721
  var _b = useState(true),
33581
33722
  isOpen = _b[0],
@@ -33586,7 +33727,7 @@ var Chip = /*#__PURE__*/forwardRef(function (_a, ref) {
33586
33727
  onClose && onClose();
33587
33728
  };
33588
33729
 
33589
- return isOpen ? jsxRuntime.exports.jsxs(Container, __assign({}, rest, {
33730
+ return isOpen ? jsxRuntime.exports.jsxs(Container, __assign({}, getBaseHTMLProps(id, htmlProps, rest), {
33590
33731
  ref: ref
33591
33732
  }, {
33592
33733
  children: [jsxRuntime.exports.jsx(TextWrapper, {