@hmlr/govuk-react-components-library 1.2.2 → 1.2.3

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.
package/dist/index.cjs.js CHANGED
@@ -249,7 +249,7 @@ const Button = (props) => {
249
249
  iconHtml = (jsxRuntime.jsx("svg", { className: "govuk-button__start-icon", xmlns: "http://www.w3.org/2000/svg", width: "17.5", height: "19", viewBox: "0 0 33 40", "aria-hidden": "true", focusable: "false", children: jsxRuntime.jsx("path", { fill: "currentColor", d: "M0 0h13l20 20-20 20H0l20-20z" }) }));
250
250
  }
251
251
  const commonAttributes = {
252
- className: `govuk-button ${className || ""}${disabled ? " govuk-button--disabled" : ""} ${isStartButton ? "govuk-button--start" : ""}`,
252
+ className: `govuk-button ${className || ""} ${isStartButton ? "govuk-button--start" : ""}`,
253
253
  // ref: buttonRef,
254
254
  };
255
255
  if (preventDoubleClick) {
@@ -633,28 +633,36 @@ const defaultProps$1 = {
633
633
  name: "",
634
634
  };
635
635
  const Textarea = React.forwardRef((props = defaultProps$1, ref) => {
636
- const { className, "aria-describedby": describedBy, errorMessage, formGroup, hint, label, id, ...attributes } = props;
636
+ const { className, "aria-describedby": describedBy, errorMessage, formGroup, hint, label, id, name, ...attributes } = props;
637
+ // Mirrors govuk-frontend's Nunjucks macro, which defaults id to name when
638
+ // id isn't given - without this the textarea has no id, so its <label for>
639
+ // (and hint/error aria-describedby) can never associate with it.
640
+ const resolvedId = id || name;
637
641
  let describedByValue = describedBy || "";
638
642
  let hintComponent = null;
639
643
  let errorMessageComponent = null;
640
644
  if (hint) {
641
- const hintId = `${id}-hint`;
645
+ const hintId = `${resolvedId}-hint`;
642
646
  describedByValue += ` ${hintId}`;
643
647
  hintComponent = jsxRuntime.jsx(Hint, { ...hint, id: hintId });
644
648
  }
645
649
  if (errorMessage) {
646
- const errorId = id ? `${id}-error` : "";
650
+ const errorId = resolvedId ? `${resolvedId}-error` : "";
647
651
  describedByValue += ` ${errorId}`;
648
652
  errorMessageComponent = jsxRuntime.jsx(ErrorMessage, { ...errorMessage, id: errorId });
649
653
  }
650
- return (jsxRuntime.jsxs("div", { className: `govuk-form-group${errorMessage ? " govuk-form-group--error" : ""} ${formGroup?.className || ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: id }), hintComponent, errorMessageComponent, jsxRuntime.jsx("textarea", { ...attributes, id: id, ref: ref, className: `govuk-textarea${errorMessage ? " govuk-textarea--error" : ""} ${className || ""}`, "aria-describedby": describedByValue?.trim() || undefined })] }));
654
+ return (jsxRuntime.jsxs("div", { className: `govuk-form-group${errorMessage ? " govuk-form-group--error" : ""} ${formGroup?.className || ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: resolvedId }), hintComponent, errorMessageComponent, jsxRuntime.jsx("textarea", { name: name, ...attributes, id: resolvedId, ref: ref, className: `govuk-textarea${errorMessage ? " govuk-textarea--error" : ""} ${className || ""}`, "aria-describedby": describedByValue?.trim() || undefined })] }));
651
655
  });
652
656
  Textarea.displayName = "Textarea";
653
657
 
654
658
  const CharacterCount = (props) => {
655
- const { id, className, maxlength, threshold, maxwords, errorMessage, countMessage, ...attributes } = props;
656
- const characterCountInfoId = `${id}-info`;
657
- return (jsxRuntime.jsxs("div", { className: "govuk-character-count", "data-module": "govuk-character-count", "data-maxlength": maxlength, "data-threshold": threshold, "data-maxwords": maxwords, children: [jsxRuntime.jsx(Textarea, { id: id, ...attributes, errorMessage: errorMessage, className: `govuk-js-character-count ${className || ""}${errorMessage ? " govuk-textarea--error" : ""}`, "aria-describedby": characterCountInfoId }), jsxRuntime.jsxs(Hint, { id: characterCountInfoId, className: `govuk-hint govuk-character-count__message ${countMessage?.className || ""}`, "aria-live": "polite", children: ["You have ", maxlength || maxwords, " ", maxwords ? "words" : "characters", " ", "remaining"] })] }));
659
+ const { id, name, className, maxlength, threshold, maxwords, errorMessage, countMessage, ...attributes } = props;
660
+ // Mirrors govuk-frontend's Nunjucks macro, which defaults id to name when
661
+ // id isn't given - without this the count message's id (referenced by the
662
+ // textarea's aria-describedby) would render as literally "undefined-info".
663
+ const resolvedId = id || name;
664
+ const characterCountInfoId = `${resolvedId}-info`;
665
+ return (jsxRuntime.jsxs("div", { className: "govuk-character-count", "data-module": "govuk-character-count", "data-maxlength": maxlength, "data-threshold": threshold, "data-maxwords": maxwords, children: [jsxRuntime.jsx(Textarea, { id: resolvedId, name: name, ...attributes, errorMessage: errorMessage, className: `govuk-js-character-count ${className || ""}${errorMessage ? " govuk-textarea--error" : ""}`, "aria-describedby": characterCountInfoId }), jsxRuntime.jsxs(Hint, { id: characterCountInfoId, className: `govuk-hint govuk-character-count__message ${countMessage?.className || ""}`, "aria-live": "polite", children: ["You have ", maxlength || maxwords, " ", maxwords ? "words" : "characters", " ", "remaining"] })] }));
658
666
  };
659
667
  CharacterCount.displayName = "CharacterCount";
660
668
 
@@ -702,21 +710,25 @@ const defaultProps = {
702
710
  };
703
711
  const Input = React.forwardRef((props = defaultProps, ref) => {
704
712
  const { className, "aria-describedby": describedBy, errorMessage, formGroup, hint, label, name, id, prefix, suffix, ...attributes } = props;
713
+ // Mirrors govuk-frontend's Nunjucks macro, which defaults id to name when
714
+ // id isn't given - without this the input has no id, so its <label for>
715
+ // (and hint/error aria-describedby) can never associate with it.
716
+ const resolvedId = id || name;
705
717
  let describedByValue = describedBy || "";
706
718
  let hintComponent = null;
707
719
  let errorMessageComponent = null;
708
720
  if (hint) {
709
- const hintId = `${id}-hint`;
721
+ const hintId = `${resolvedId}-hint`;
710
722
  describedByValue += ` ${hintId}`;
711
723
  hintComponent = jsxRuntime.jsx(Hint, { ...hint, id: hintId });
712
724
  }
713
725
  if (errorMessage) {
714
- const errorId = id ? `${id}-error` : "";
726
+ const errorId = resolvedId ? `${resolvedId}-error` : "";
715
727
  describedByValue += ` ${errorId}`;
716
728
  errorMessageComponent = jsxRuntime.jsx(ErrorMessage, { ...errorMessage, id: errorId });
717
729
  }
718
- const input = (jsxRuntime.jsx("input", { ref: ref, id: id, className: `govuk-input ${className || ""} ${errorMessage ? " govuk-input--error" : ""}`, name: name || id, "aria-describedby": describedByValue || undefined, ...attributes }));
719
- return (jsxRuntime.jsxs("div", { className: `govuk-form-group ${formGroup?.className || ""} ${errorMessage ? "govuk-form-group--error" : ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: id }), hintComponent, errorMessageComponent, prefix || suffix ? (jsxRuntime.jsxs("div", { className: "govuk-input__wrapper", children: [prefix ? (jsxRuntime.jsx("div", { "aria-hidden": "true", ...prefix,
730
+ const input = (jsxRuntime.jsx("input", { ref: ref, id: resolvedId, className: `govuk-input ${className || ""} ${errorMessage ? " govuk-input--error" : ""}`, name: name || resolvedId, "aria-describedby": describedByValue || undefined, ...attributes }));
731
+ return (jsxRuntime.jsxs("div", { className: `govuk-form-group ${formGroup?.className || ""} ${errorMessage ? "govuk-form-group--error" : ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: resolvedId }), hintComponent, errorMessageComponent, prefix || suffix ? (jsxRuntime.jsxs("div", { className: "govuk-input__wrapper", children: [prefix ? (jsxRuntime.jsx("div", { "aria-hidden": "true", ...prefix,
720
732
  className: `govuk-input__prefix ${prefix.className ? prefix.className : ""}` })) : null, input, suffix ? (jsxRuntime.jsx("div", { "aria-hidden": "true", ...suffix,
721
733
  className: `govuk-input__suffix ${suffix.className ? suffix.className : ""}` })) : null] })) : (input)] }));
722
734
  });
@@ -897,21 +909,25 @@ function ConfigureOverallExitThisPage($scope) {
897
909
  }
898
910
 
899
911
  const FileUpload = (props) => {
900
- const { className, errorMessage, formGroup, hint, label, "aria-describedby": describedBy, id, ...attributes } = props;
912
+ const { className, errorMessage, formGroup, hint, label, "aria-describedby": describedBy, id, name, ...attributes } = props;
913
+ // Mirrors govuk-frontend's Nunjucks macro, which defaults id to name when
914
+ // id isn't given - without this the input has no id, so its <label for>
915
+ // (and hint/error aria-describedby) can never associate with it.
916
+ const resolvedId = id || name;
901
917
  let hintComponent;
902
918
  let errorMessageComponent;
903
919
  let describedByValue = describedBy || "";
904
920
  if (hint) {
905
- const hintId = `${props.id}-hint`;
921
+ const hintId = `${resolvedId}-hint`;
906
922
  describedByValue += ` ${hintId}`;
907
- hintComponent = jsxRuntime.jsx(Hint, { ...props.hint, id: hintId });
923
+ hintComponent = jsxRuntime.jsx(Hint, { ...hint, id: hintId });
908
924
  }
909
925
  if (errorMessage) {
910
- const errorId = `${id}-error`;
926
+ const errorId = `${resolvedId}-error`;
911
927
  describedByValue += ` ${errorId}`;
912
928
  errorMessageComponent = jsxRuntime.jsx(ErrorMessage, { ...errorMessage, id: errorId });
913
929
  }
914
- return (jsxRuntime.jsxs("div", { className: `govuk-form-group${errorMessage ? " govuk-form-group--error" : ""} ${formGroup?.className || ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: id }), hintComponent, errorMessageComponent, jsxRuntime.jsx("input", { ...attributes, id: id, className: `govuk-file-upload ${className || ""}${errorMessage ? " govuk-file-upload--error" : ""}`, type: "file", "aria-describedby": describedByValue || undefined })] }));
930
+ return (jsxRuntime.jsxs("div", { className: `govuk-form-group${errorMessage ? " govuk-form-group--error" : ""} ${formGroup?.className || ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: resolvedId }), hintComponent, errorMessageComponent, jsxRuntime.jsx("input", { name: name, ...attributes, id: resolvedId, className: `govuk-file-upload ${className || ""}${errorMessage ? " govuk-file-upload--error" : ""}`, type: "file", "aria-describedby": describedByValue || undefined })] }));
915
931
  };
916
932
  FileUpload.displayName = "FileUpload";
917
933
 
@@ -1072,7 +1088,7 @@ const Pagination = ({ previous, next, items, className, }) => {
1072
1088
  // Block layout is used when there are no numbered page items — govuk renders
1073
1089
  // the nav with an extra class and the link title with --decorated modifier.
1074
1090
  const isBlockLayout = !items || items.length === 0;
1075
- return (jsxRuntime.jsxs("nav", { className: `govuk-pagination${isBlockLayout ? " govuk-pagination--block" : ""}${className ? ` ${className}` : ""}`, role: "navigation", "aria-label": "Pagination", children: [previous && (jsxRuntime.jsx("div", { className: "govuk-pagination__prev", children: jsxRuntime.jsx(NavigationButton, { type: "previous", ...previous }) })), items && items.length > 0 && (jsxRuntime.jsx("ul", { className: "govuk-pagination__list", children: items.map((item, index) => item.ellipsis ? (jsxRuntime.jsx("li", { className: "govuk-pagination__item govuk-pagination__item--ellipses", children: DOTS }, index)) : (jsxRuntime.jsx("li", { className: `govuk-pagination__item${item.current ? " govuk-pagination__item--current" : ""}`, children: jsxRuntime.jsx("a", { className: "govuk-link govuk-pagination__link", href: item.href ?? "#", "aria-label": `Page ${item.number}`, ...(item.current ? { "aria-current": "page" } : {}), children: item.number }) }, index))) })), next && (jsxRuntime.jsx("div", { className: "govuk-pagination__next", children: jsxRuntime.jsx(NavigationButton, { type: "next", ...next }) }))] }));
1091
+ return (jsxRuntime.jsxs("nav", { className: `govuk-pagination${isBlockLayout ? " govuk-pagination--block" : ""}${className ? ` ${className}` : ""}`, role: "navigation", "aria-label": "Pagination", children: [previous && (jsxRuntime.jsx("div", { className: "govuk-pagination__prev", children: jsxRuntime.jsx(NavigationButton, { type: "previous", ...previous }) })), items && items.length > 0 && (jsxRuntime.jsx("ul", { className: "govuk-pagination__list", children: items.map((item, index) => item.ellipsis ? (jsxRuntime.jsx("li", { className: "govuk-pagination__item govuk-pagination__item--ellipsis", children: DOTS }, index)) : (jsxRuntime.jsx("li", { className: `govuk-pagination__item${item.current ? " govuk-pagination__item--current" : ""}`, children: jsxRuntime.jsx("a", { className: "govuk-link govuk-pagination__link", href: item.href ?? "#", "aria-label": `Page ${item.number}`, ...(item.current ? { "aria-current": "page" } : {}), children: item.number }) }, index))) })), next && (jsxRuntime.jsx("div", { className: "govuk-pagination__next", children: jsxRuntime.jsx(NavigationButton, { type: "next", ...next }) }))] }));
1076
1092
  };
1077
1093
 
1078
1094
  const Panel = (props) => {
@@ -1083,16 +1099,21 @@ const Panel = (props) => {
1083
1099
 
1084
1100
  const PasswordInput = React.forwardRef((props, ref) => {
1085
1101
  const { className, "aria-describedby": describedBy, errorMessage, formGroup, hint, label, name, id, autoComplete = "current-password", showPasswordText = "Show", hidePasswordText = "Hide", showPasswordAriaLabelText = "Show password", hidePasswordAriaLabelText = "Hide password", passwordShownAnnouncementText, passwordHiddenAnnouncementText, ...attributes } = props;
1102
+ // Mirrors govuk-frontend's Nunjucks macro, which defaults id to name
1103
+ // when id isn't given - without this the input has no id, so its
1104
+ // <label for> (and hint/error aria-describedby) can never associate
1105
+ // with it.
1106
+ const resolvedId = id || name;
1086
1107
  let describedByValue = describedBy || "";
1087
1108
  let hintComponent = null;
1088
1109
  let errorMessageComponent = null;
1089
1110
  if (hint) {
1090
- const hintId = `${id}-hint`;
1111
+ const hintId = `${resolvedId}-hint`;
1091
1112
  describedByValue += ` ${hintId}`;
1092
1113
  hintComponent = jsxRuntime.jsx(Hint, { ...hint, id: hintId });
1093
1114
  }
1094
1115
  if (errorMessage) {
1095
- const errorId = id ? `${id}-error` : "";
1116
+ const errorId = resolvedId ? `${resolvedId}-error` : "";
1096
1117
  describedByValue += ` ${errorId}`;
1097
1118
  errorMessageComponent = jsxRuntime.jsx(ErrorMessage, { ...errorMessage, id: errorId });
1098
1119
  }
@@ -1115,8 +1136,8 @@ const PasswordInput = React.forwardRef((props, ref) => {
1115
1136
  i18nProps["data-i18n.password-hidden-announcement"] =
1116
1137
  passwordHiddenAnnouncementText;
1117
1138
  // Label handles isPageHeading internally — no extra wrapper needed here
1118
- const labelEl = jsxRuntime.jsx(Label, { ...label, htmlFor: id });
1119
- return (jsxRuntime.jsxs("div", { className: `govuk-form-group${formGroup?.className ? ` ${formGroup.className}` : ""}${errorMessage ? " govuk-form-group--error" : ""} govuk-password-input`, "data-module": "govuk-password-input", ...i18nProps, children: [labelEl, hintComponent, errorMessageComponent, jsxRuntime.jsxs("div", { className: "govuk-input__wrapper govuk-password-input__wrapper", children: [jsxRuntime.jsx("input", { ref: ref, id: id, className: `govuk-input govuk-password-input__input govuk-js-password-input-input${className ? ` ${className}` : ""}${errorMessage ? " govuk-input--error" : ""}`, name: name || id, type: "password", spellCheck: false, autoComplete: autoComplete, autoCapitalize: "none", "aria-describedby": describedByValue.trim() || undefined, ...attributes }), jsxRuntime.jsx("button", { type: "button", className: "govuk-button govuk-button--secondary govuk-password-input__toggle govuk-js-password-input-toggle", "data-module": "govuk-button", "aria-controls": id, "aria-label": showPasswordAriaLabelText, hidden: true, children: showPasswordText })] })] }));
1139
+ const labelEl = jsxRuntime.jsx(Label, { ...label, htmlFor: resolvedId });
1140
+ return (jsxRuntime.jsxs("div", { className: `govuk-form-group${formGroup?.className ? ` ${formGroup.className}` : ""}${errorMessage ? " govuk-form-group--error" : ""} govuk-password-input`, "data-module": "govuk-password-input", ...i18nProps, children: [labelEl, hintComponent, errorMessageComponent, jsxRuntime.jsxs("div", { className: "govuk-input__wrapper govuk-password-input__wrapper", children: [jsxRuntime.jsx("input", { ref: ref, id: resolvedId, className: `govuk-input govuk-password-input__input govuk-js-password-input-input${className ? ` ${className}` : ""}${errorMessage ? " govuk-input--error" : ""}`, name: name || resolvedId, type: "password", spellCheck: false, autoComplete: autoComplete, autoCapitalize: "none", "aria-describedby": describedByValue.trim() || undefined, ...attributes }), jsxRuntime.jsx("button", { type: "button", className: "govuk-button govuk-button--secondary govuk-password-input__toggle govuk-js-password-input-toggle", "data-module": "govuk-button", "aria-controls": resolvedId, "aria-label": showPasswordAriaLabelText, hidden: true, children: showPasswordText })] })] }));
1120
1141
  });
1121
1142
  PasswordInput.displayName = "PasswordInput";
1122
1143
 
@@ -1492,17 +1513,21 @@ function ConfigureOverallRadios($scope) {
1492
1513
  }
1493
1514
 
1494
1515
  const Select = (props) => {
1495
- const { className, "aria-describedby": describedBy, errorMessage, formGroup, hint, id, items, label, ...attributes } = props;
1516
+ const { className, "aria-describedby": describedBy, errorMessage, formGroup, hint, id, name, items, label, ...attributes } = props;
1517
+ // Mirrors govuk-frontend's Nunjucks macro, which defaults id to name when
1518
+ // id isn't given - without this the select has no id, so its <label for>
1519
+ // (and hint/error aria-describedby) can never associate with it.
1520
+ const resolvedId = id || name;
1496
1521
  let describedByValue = describedBy || "";
1497
1522
  let hintComponent;
1498
1523
  let errorMessageComponent;
1499
1524
  if (hint) {
1500
- const hintId = `${id}-hint`;
1525
+ const hintId = `${resolvedId}-hint`;
1501
1526
  describedByValue += ` ${hintId}`;
1502
1527
  hintComponent = jsxRuntime.jsx(Hint, { ...hint, id: hintId });
1503
1528
  }
1504
1529
  if (errorMessage) {
1505
- const errorId = id ? `${id}-error` : "";
1530
+ const errorId = resolvedId ? `${resolvedId}-error` : "";
1506
1531
  describedByValue += ` ${errorId}`;
1507
1532
  errorMessageComponent = jsxRuntime.jsx(ErrorMessage, { ...errorMessage, id: errorId });
1508
1533
  }
@@ -1514,12 +1539,12 @@ const Select = (props) => {
1514
1539
  return (React.createElement("option", { ...optionAttributes, key: reactListKey || index }, children));
1515
1540
  })
1516
1541
  : null;
1517
- return (jsxRuntime.jsxs("div", { className: `govuk-form-group${errorMessage ? " govuk-form-group--error" : ""} ${formGroup?.className || ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: id }), hintComponent, errorMessageComponent, jsxRuntime.jsx("select", { className: `govuk-select ${className || ""}${errorMessage ? " govuk-select--error" : ""}`, id: id, "aria-describedby": describedByValue || undefined, ...attributes, children: options })] }));
1542
+ return (jsxRuntime.jsxs("div", { className: `govuk-form-group${errorMessage ? " govuk-form-group--error" : ""} ${formGroup?.className || ""}`, children: [jsxRuntime.jsx(Label, { ...label, htmlFor: resolvedId }), hintComponent, errorMessageComponent, jsxRuntime.jsx("select", { className: `govuk-select ${className || ""}${errorMessage ? " govuk-select--error" : ""}`, id: resolvedId, name: name, "aria-describedby": describedByValue || undefined, ...attributes, children: options })] }));
1518
1543
  };
1519
1544
 
1520
1545
  const ServiceNavigation = (props) => {
1521
1546
  const { className, containerClassName = "govuk-width-container", menuButtonLabel = "Show or hide menu", navigation, navigationClassName, navigationLabel = "Menu", serviceName, serviceUrlHref, serviceUrlTo, ...attributes } = props;
1522
- return (jsxRuntime.jsx("section", { "aria-label": "Service information", className: `govuk-service-navigation ${className || ""}`, "data-module": "govuk-service-navigation", ...attributes, children: jsxRuntime.jsx("div", { className: `govuk-width-container ${containerClassName}`, children: jsxRuntime.jsxs("div", { className: "govuk-service-navigation__container", children: [serviceName ? (jsxRuntime.jsx("span", { className: "govuk-service-navigation__service-name", children: jsxRuntime.jsx(LinkWithRef, { href: serviceUrlHref, to: serviceUrlTo, className: "govuk-header__link govuk-header__link--service-name", children: serviceName }) })) : null, navigation ? (jsxRuntime.jsxs("nav", { "aria-label": navigationLabel, className: `govuk-service-navigation__wrapper ${navigationClassName || ""}`, children: [jsxRuntime.jsx("button", { type: "button", className: "govuk-service-navigation__toggle govuk-js-service-navigation-toggle", "aria-controls": "navigation", "aria-label": menuButtonLabel, hidden: true, children: "Menu" }), jsxRuntime.jsx("ul", { className: "govuk-service-navigation__list", id: "navigation", children: navigation.map((item, index) => {
1547
+ return (jsxRuntime.jsx("section", { "aria-label": "Service information", className: `govuk-service-navigation ${className || ""}`, "data-module": "govuk-service-navigation", ...attributes, children: jsxRuntime.jsx("div", { className: `govuk-width-container ${containerClassName}`, children: jsxRuntime.jsxs("div", { className: "govuk-service-navigation__container", children: [serviceName ? (jsxRuntime.jsx("span", { className: "govuk-service-navigation__service-name", children: jsxRuntime.jsx(LinkWithRef, { href: serviceUrlHref, to: serviceUrlTo, className: "govuk-service-navigation__link", children: serviceName }) })) : null, navigation ? (jsxRuntime.jsxs("nav", { "aria-label": navigationLabel, className: `govuk-service-navigation__wrapper ${navigationClassName || ""}`, children: [jsxRuntime.jsx("button", { type: "button", className: "govuk-service-navigation__toggle govuk-js-service-navigation-toggle", "aria-controls": "navigation", "aria-label": menuButtonLabel, hidden: true, children: "Menu" }), jsxRuntime.jsx("ul", { className: "govuk-service-navigation__list", id: "navigation", children: navigation.map((item, index) => {
1523
1548
  const { active: itemActive, className: itemClassName, children: itemChildren, reactListKey, ...itemAttributes } = item;
1524
1549
  return itemChildren ? (jsxRuntime.jsx("li", { className: `govuk-service-navigation__item${itemActive
1525
1550
  ? " govuk-service-navigation__item--active"