northants-design-system 0.2.30 → 0.3.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.
@@ -5401,6 +5401,8 @@ var ServiceIcon$5 = function (_a) {
5401
5401
  };
5402
5402
 
5403
5403
  var components = {
5404
+ accessibleparking: ServiceIcon$1X,
5405
+ accessibleparkingHover: ServiceIcon$1W,
5404
5406
  adults: ServiceIcon$1R,
5405
5407
  adultsHover: ServiceIcon$1Q,
5406
5408
  addresschange: ServiceIcon$1V,
@@ -5451,8 +5453,6 @@ var components = {
5451
5453
  dolsHover: ServiceIcon$1e,
5452
5454
  edit: ServiceIcon$1d,
5453
5455
  editHover: ServiceIcon$1c,
5454
- accessibleparking: ServiceIcon$1X,
5455
- accessibleparkingHover: ServiceIcon$1W,
5456
5456
  environment: ServiceIcon$1b,
5457
5457
  environmentHover: ServiceIcon$1a,
5458
5458
  finance: ServiceIcon$19,
@@ -6712,103 +6712,197 @@ var DropDownFilter = function (_a) {
6712
6712
  return (React.createElement(DropDownSelect, { id: id, label: label, options: options, onChange: optionPicked, selected: value, hideLabel: hideLabel }));
6713
6713
  };
6714
6714
 
6715
- const oneColStyles = props => {
6716
- if(props.oneCol) {
6717
- return css`width: 100%; display: block;`
6718
- }
6715
+ const oneColStyles = (props) => {
6716
+ if (props.oneCol) {
6717
+ return css`
6718
+ width: 100%;
6719
+ display: block;
6720
+ `;
6721
+ }
6719
6722
  };
6720
6723
 
6721
6724
  const PromotedLinks$1 = styled.div`
6722
- ${props => props.theme.fontStyles}
6723
- margin-top: 30px;
6725
+ ${(props) => props.theme.fontStyles}
6726
+ margin-top: 30px;
6724
6727
 
6725
- @media screen and (min-width: ${props => props.theme.theme_vars.breakpoints.s}){
6726
- display: -ms-flex;
6727
- display: -webkit-flex;
6728
- display: flex;
6729
- flex-wrap: wrap;
6730
- margin-top: 60px;
6731
- }
6732
- @media screen and (min-width: calc(${props => props.theme.theme_vars.breakpoints.l} + 60px)){
6733
- margin-top: 90px;
6734
- }
6735
- flex-direction: ${prop => prop.oneCol ? 'column' : 'inherit'};
6728
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
6729
+ display: -ms-flex;
6730
+ display: -webkit-flex;
6731
+ display: flex;
6732
+ flex-wrap: wrap;
6733
+ margin-top: 60px;
6734
+ }
6735
+ @media screen and (min-width: calc(${(props) => props.theme.theme_vars.breakpoints.l} + 60px)) {
6736
+ margin-top: 90px;
6737
+ }
6738
+ flex-direction: ${(prop) => (prop.oneCol ? 'column' : 'inherit')};
6736
6739
  `;
6737
6740
 
6738
6741
  const PromotedLink$1 = styled.a`
6739
- display: block;
6740
- @media screen and (min-width: calc(${props => props.theme.theme_vars.breakpoints.l} + 60px)){
6741
- box-sizing: border-box;
6742
- }
6743
- background: ${props => props.theme.theme_vars.colours.white};
6744
- background: ${props => props.theme.theme_vars.colours.white}F2;
6745
- border-radius: 3px;
6746
- box-shadow: 0px -4px 0px 0px ${props => props.theme.theme_vars.colours.action} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6747
- -webkit-box-shadow: 0px -4px 0px 0px ${props => props.theme.theme_vars.colours.action} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6748
- -moz-box-shadow: 0px -4px 0px 0px ${props => props.theme.theme_vars.colours.action} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6749
-
6750
- padding: 20px 15px;
6751
- width: calc(100% - 30px);
6752
- margin-bottom: 15px;
6742
+ display: block;
6743
+ height: 100%;
6744
+ @media screen and (min-width: calc(${(props) => props.theme.theme_vars.breakpoints.l} + 60px)) {
6745
+ box-sizing: border-box;
6746
+ }
6747
+ background: ${(props) => props.theme.theme_vars.colours.white};
6748
+ background: ${(props) => props.theme.theme_vars.colours.white}F2;
6749
+ border-radius: 3px;
6750
+ box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.action} inset,
6751
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6752
+ -webkit-box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.action} inset,
6753
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6754
+ -moz-box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.action} inset,
6755
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6753
6756
 
6754
- span {
6755
- ${props => props.theme.linkStyles};
6756
- }
6757
+ padding: 20px 15px;
6758
+ width: calc(100% - 30px);
6759
+ margin-bottom: 15px;
6757
6760
 
6758
- &:hover {
6759
- background: ${props => props.theme.theme_vars.colours.white};
6760
- }
6761
+ span {
6762
+ ${(props) => props.theme.linkStyles};
6763
+ }
6761
6764
 
6762
- &:focus {
6763
- ${props => props.theme.linkStylesFocus};
6764
- box-shadow: 0px -4px 0px 0px ${props => props.theme.theme_vars.colours.black} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6765
- -webkit-box-shadow: 0px -4px 0px 0px ${props => props.theme.theme_vars.colours.black} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6766
- -moz-box-shadow: 0px -4px 0px 0px ${props => props.theme.theme_vars.colours.black} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6765
+ &:hover {
6766
+ background: ${(props) => props.theme.theme_vars.colours.white};
6767
+ }
6768
+
6769
+ &:focus {
6770
+ ${(props) => props.theme.linkStylesFocus};
6771
+ box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.black} inset,
6772
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6773
+ -webkit-box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.black} inset,
6774
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6775
+ -moz-box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.black} inset,
6776
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6777
+ }
6778
+ &:active {
6779
+ ${(props) => props.theme.linkStylesActive};
6780
+ transform: translateY(3px);
6781
+ box-shadow: 0px -1px 0px 0px ${(props) => props.theme.theme_vars.colours.black} inset,
6782
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6783
+ -webkit-box-shadow: 0px -1px 0px 0px ${(props) => props.theme.theme_vars.colours.black} inset,
6784
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6785
+ -moz-box-shadow: 0px -1px 0px 0px ${(props) => props.theme.theme_vars.colours.black} inset,
6786
+ 0px 4px 15px rgba(0, 0, 0, 0.11);
6787
+ }
6788
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
6789
+ width: 100%;
6790
+ margin-right: 15px;
6791
+ flex: 0 0 calc(50% - 38px);
6792
+ &:nth-of-type(2n) {
6793
+ margin-right: 0;
6767
6794
  }
6768
- &:active {
6769
- ${props => props.theme.linkStylesActive};
6770
- transform: translateY(3px);
6771
- box-shadow: 0px -1px 0px 0px ${props => props.theme.theme_vars.colours.black} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6772
- -webkit-box-shadow: 0px -1px 0px 0px ${props => props.theme.theme_vars.colours.black} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6773
- -moz-box-shadow: 0px -1px 0px 0px ${props => props.theme.theme_vars.colours.black} inset, 0px 4px 15px rgba(0, 0, 0, 0.11);
6795
+ }
6796
+
6797
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
6798
+ width: 100%;
6799
+ margin-right: 30px;
6800
+
6801
+ margin-bottom: ${(prop) => (prop.oneCol ? '20px' : '0px')};
6802
+ padding: 30px;
6803
+ flex: 1;
6804
+
6805
+ &:nth-of-type(2n) {
6806
+ margin-right: 30px;
6774
6807
  }
6775
- @media screen and (min-width: ${props => props.theme.theme_vars.breakpoints.s}){
6776
- width: 100%;
6777
- margin-right: 15px;
6778
- flex: 0 0 calc(50% - 38px);
6779
- &:nth-of-type(2n) {
6780
- margin-right: 0;
6781
- }
6808
+ &:last-of-type {
6809
+ margin-right: 0;
6782
6810
  }
6811
+ }
6812
+ ${oneColStyles}
6813
+ `;
6783
6814
 
6784
- @media screen and (min-width: ${props => props.theme.theme_vars.breakpoints.m}){
6785
- width: 100%;
6786
- margin-right: 30px;
6815
+ const Container$R = styled.div`
6816
+ box-sizing: border-box;
6817
+ display: flex;
6818
+ flex-wrap: wrap;
6819
+ flex-direction: row;
6820
+ justify-content: start;
6821
+ align-items: stretch;
6822
+ margin: 0 -${(props) => props.theme.theme_vars.spacingSizes.small};
6823
+ border: ${(props) => (props.hasBorder ? `1px solid ${props.theme.theme_vars.colours.grey}` : 'none')};
6824
+ list-style: none;
6825
+ max-width: none !important;
6826
+ min-width: 100%;
6787
6827
 
6788
- margin-bottom: ${prop => prop.oneCol ? '20px' : '0px'};
6789
- padding: 30px;
6790
- flex: 1;
6828
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.l}) {
6829
+ flex-wrap: ${(props) => (props.hasWrap ? `wrap` : `nowrap`)};
6830
+ }
6831
+ `;
6791
6832
 
6792
- &:nth-of-type(2n) {
6793
- margin-right: 30px;
6794
- }
6795
- &:last-of-type {
6796
- margin-right: 0;
6797
- }
6833
+ var Row$1 = function (_a) {
6834
+ var _b = _a.hasBorder, hasBorder = _b === void 0 ? false : _b, _c = _a.isList, isList = _c === void 0 ? false : _c, _d = _a.hasWrap, hasWrap = _d === void 0 ? true : _d, children = _a.children;
6835
+ return (React.createElement(Container$R, { "data-testid": "Row", hasBorder: hasBorder, hasWrap: hasWrap, as: isList ? 'ul' : 'div' }, children));
6836
+ };
6798
6837
 
6838
+ const calculateWidth = (size) => {
6839
+ switch (size) {
6840
+ case 'full':
6841
+ return css`
6842
+ width: 100%;
6843
+ `;
6844
+ case 'one-half':
6845
+ return css`
6846
+ width: 50%;
6847
+ `;
6848
+ case 'one-third':
6849
+ return css`
6850
+ width: 33.333%;
6851
+ `;
6852
+ case 'two-thirds':
6853
+ return css`
6854
+ width: 66.666%;
6855
+ `;
6856
+ case 'one-quarter':
6857
+ return css`
6858
+ width: 25%;
6859
+ `;
6860
+ case 'three-quarters':
6861
+ return css`
6862
+ width: 75%;
6863
+ `;
6864
+ case 'auto':
6865
+ return css`
6866
+ flex-grow: 1;
6867
+ `;
6868
+ }
6869
+ };
6870
+
6871
+ const widths = (props) => {
6872
+ return css`
6873
+ ${calculateWidth(props.small)};
6799
6874
 
6875
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
6876
+ ${calculateWidth(props.medium)};
6800
6877
  }
6801
- ${oneColStyles}
6802
6878
 
6879
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.l}) {
6880
+ ${calculateWidth(props.large)};
6881
+ }
6803
6882
  `;
6883
+ };
6884
+
6885
+ const Container$Q = styled.div`
6886
+ box-sizing: border-box;
6887
+ display: block;
6888
+ padding: ${(props) => (props.hasPadding ? props.theme.theme_vars.spacingSizes.small : `0`)};
6889
+ border: ${(props) => (props.hasBorder ? `1px solid ${props.theme.theme_vars.colours.negative}` : 'none')};
6890
+ left: 0;
6891
+ ${widths};
6892
+ `;
6893
+
6894
+ var Column = function (_a) {
6895
+ var _b = _a.small, small = _b === void 0 ? 'full' : _b, _c = _a.medium, medium = _c === void 0 ? 'one-half' : _c, _d = _a.large, large = _d === void 0 ? 'one-third' : _d, _e = _a.hasPadding, hasPadding = _e === void 0 ? true : _e, _f = _a.hasBorder, hasBorder = _f === void 0 ? false : _f, _g = _a.isList, isList = _g === void 0 ? false : _g, children = _a.children;
6896
+ return (React.createElement(Container$Q, { "data-testid": "Column", small: small, medium: medium, large: large, hasPadding: hasPadding, hasBorder: hasBorder, as: isList ? 'li' : 'div' }, children));
6897
+ };
6804
6898
 
6805
6899
  var PromotedLinks = function (_a) {
6806
6900
  var promotedLinksArray = _a.promotedLinksArray, oneCol = _a.oneCol;
6807
6901
  if (promotedLinksArray.length > 0) {
6808
- return (React.createElement(PromotedLinks$1, { "data-testid": "PromotedLinks", oneCol: oneCol }, promotedLinksArray.map(function (link, i) {
6809
- return React.createElement(PromotedLink$1, { key: i, oneCol: oneCol, href: link.url, title: link.title },
6810
- React.createElement("span", null, link.title));
6811
- })));
6902
+ return (React.createElement(PromotedLinks$1, { "data-testid": "PromotedLinks", oneCol: oneCol },
6903
+ React.createElement(Row$1, { isList: true, hasWrap: false }, promotedLinksArray.map(function (link, i) { return (React.createElement(Column, { isList: true, small: "full", medium: "one-half", large: "auto", key: i },
6904
+ React.createElement(PromotedLink$1, { oneCol: oneCol, href: link.url, title: link.title },
6905
+ React.createElement("span", null, link.title)))); }))));
6812
6906
  }
6813
6907
  else {
6814
6908
  return null;
@@ -6827,7 +6921,7 @@ var TextInput = function (_a) {
6827
6921
 
6828
6922
  // Accordion
6829
6923
 
6830
- const Container$R = styled.div`
6924
+ const Container$P = styled.div`
6831
6925
  ${(props) => props.theme.fontStyles}
6832
6926
  margin-bottom: 20px;
6833
6927
  border-bottom: 1px solid ${(props) => props.theme.theme_vars.colours.grey};
@@ -7109,7 +7203,7 @@ var Accordion = function (_a) {
7109
7203
  setAccordionStates(newStatus);
7110
7204
  };
7111
7205
  var accordionId = "accordion".concat(uniqueID());
7112
- return (React.createElement(Container$R, { "data-testid": "Accordion", id: accordionId },
7206
+ return (React.createElement(Container$P, { "data-testid": "Accordion", id: accordionId },
7113
7207
  showControls && sections.length > 1 && (React.createElement(AccordionControls, null,
7114
7208
  React.createElement(OpenAllButton, { onClick: toggleAll, type: "button", "aria-expanded": !openAll },
7115
7209
  openAll ? 'Open all' : 'Close all',
@@ -7160,7 +7254,7 @@ var BlockQuote = function (_a) {
7160
7254
  citation && React.createElement(Citation, null, citation)));
7161
7255
  };
7162
7256
 
7163
- const Container$Q = styled.div`
7257
+ const Container$O = styled.div`
7164
7258
  margin-bottom: 30px;
7165
7259
  display: block;
7166
7260
 
@@ -7175,16 +7269,16 @@ const Container$Q = styled.div`
7175
7269
  */
7176
7270
  var CallToAction = function (_a) {
7177
7271
  var primary = _a.primary; _a.size; var text = _a.text, url = _a.url, isExternal = _a.isExternal, isDisabled = _a.isDisabled; __rest(_a, ["primary", "size", "text", "url", "isExternal", "isDisabled"]);
7178
- return (React.createElement(Container$Q, null,
7272
+ return (React.createElement(Container$O, null,
7179
7273
  React.createElement(Button$2, { primary: primary, size: "large", text: text, url: url, isExternal: isExternal, isDisabled: isDisabled })));
7180
7274
  };
7181
7275
 
7182
- const Container$P = styled.div`
7276
+ const Container$N = styled.div`
7183
7277
  display: block;
7184
7278
  ${(props) => props.theme.fontStyles}
7185
7279
  `;
7186
7280
 
7187
- const Row$1 = styled.div`
7281
+ const Row = styled.div`
7188
7282
  margin-bottom: 15px;
7189
7283
  border-bottom: 1px solid ${(props) => props.theme.theme_vars.colours.grey};
7190
7284
  `;
@@ -7280,78 +7374,6 @@ const ErrorText = styled.p`
7280
7374
  }
7281
7375
  `;
7282
7376
 
7283
- const calculateWidth = (size) => {
7284
- switch (size) {
7285
- case 'full':
7286
- return css`
7287
- width: 100%;
7288
- `;
7289
- case 'one-half':
7290
- return css`
7291
- width: 50%;
7292
- `;
7293
- case 'one-third':
7294
- return css`
7295
- width: 33.333%;
7296
- `;
7297
- case 'two-thirds':
7298
- return css`
7299
- width: 66.666%;
7300
- `;
7301
- case 'one-quarter':
7302
- return css`
7303
- width: 25%;
7304
- `;
7305
- case 'three-quarters':
7306
- return css`
7307
- width: 75%;
7308
- `;
7309
- }
7310
- };
7311
-
7312
- const widths = (props) => {
7313
- return css`
7314
- ${calculateWidth(props.small)};
7315
-
7316
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
7317
- ${calculateWidth(props.medium)};
7318
- }
7319
-
7320
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.l}) {
7321
- ${calculateWidth(props.large)};
7322
- }
7323
- `;
7324
- };
7325
-
7326
- const Container$O = styled.div`
7327
- box-sizing: border-box;
7328
- display: block;
7329
- padding: ${(props) => (props.hasPadding ? props.theme.theme_vars.spacingSizes.small : `0`)};
7330
- border: ${(props) => (props.hasBorder ? `1px solid ${props.theme.theme_vars.colours.negative}` : 'none')};
7331
- ${widths};
7332
- `;
7333
-
7334
- var Column = function (_a) {
7335
- var _b = _a.small, small = _b === void 0 ? 'full' : _b, _c = _a.medium, medium = _c === void 0 ? 'one-half' : _c, _d = _a.large, large = _d === void 0 ? 'one-third' : _d, _e = _a.hasPadding, hasPadding = _e === void 0 ? true : _e, _f = _a.hasBorder, hasBorder = _f === void 0 ? false : _f, children = _a.children;
7336
- return (React.createElement(Container$O, { "data-testid": "Column", small: small, medium: medium, large: large, hasPadding: hasPadding, hasBorder: hasBorder }, children));
7337
- };
7338
-
7339
- const Container$N = styled.div`
7340
- box-sizing: border-box;
7341
- display: flex;
7342
- flex-wrap: wrap;
7343
- flex-direction: row;
7344
- justify-content: start;
7345
- align-items: stretch;
7346
- margin: 0;
7347
- border: ${(props) => (props.hasBorder ? `1px solid ${props.theme.theme_vars.colours.grey}` : 'none')};
7348
- `;
7349
-
7350
- var Row = function (_a) {
7351
- var _b = _a.hasBorder, hasBorder = _b === void 0 ? false : _b, children = _a.children;
7352
- return (React.createElement(Container$N, { "data-testid": "Row", hasBorder: hasBorder }, children));
7353
- };
7354
-
7355
7377
  /**
7356
7378
  * An list of parishes, sorted alphabetically, containing parish council tax bands
7357
7379
  */
@@ -7427,15 +7449,15 @@ var CouncilTaxAlphabeticalDirectory = function (_a) {
7427
7449
  });
7428
7450
  return letterData;
7429
7451
  });
7430
- return (React.createElement(Container$P, { "data-testid": "AlphabeticalDirectory", ref: directoryRef },
7452
+ return (React.createElement(Container$N, { "data-testid": "AlphabeticalDirectory", ref: directoryRef },
7431
7453
  React.createElement(React.Fragment, null,
7432
7454
  parishes.length === 0 && (React.createElement(ErrorText, null, "There was an issue fetching the parish data. Please try again later.")),
7433
- parish === null ? (React.createElement(React.Fragment, null, sortedData.map(function (letter, i) { return (React.createElement(Row$1, { key: i },
7434
- React.createElement(Row, null,
7455
+ parish === null ? (React.createElement(React.Fragment, null, sortedData.map(function (letter, i) { return (React.createElement(Row, { key: i },
7456
+ React.createElement(Row$1, null,
7435
7457
  React.createElement(Column, { small: "full", medium: "one-quarter", large: "one-quarter" },
7436
7458
  React.createElement(Letter, null, letter.group)),
7437
7459
  React.createElement(Column, { small: "full", medium: "three-quarters", large: "three-quarters" },
7438
- React.createElement(Row, null, letter.children.map(function (letterData, i) { return (React.createElement(Column, { small: "one-half", medium: "one-half", large: "one-half", key: i },
7460
+ React.createElement(Row$1, null, letter.children.map(function (letterData, i) { return (React.createElement(Column, { small: "one-half", medium: "one-half", large: "one-half", key: i },
7439
7461
  React.createElement(Link$4, { onClick: function () { return showParish(letterData); } }, letterData.title))); })))))); }))) : (React.createElement(React.Fragment, null,
7440
7462
  React.createElement(BackButton, { onClick: function () { return setCurrentParish(null); } }, "Back"),
7441
7463
  React.createElement("div", { className: "table-container" },
@@ -19777,7 +19799,6 @@ function sanitizeHtml(html, options, _recursing) {
19777
19799
  delete frame.attribs[a];
19778
19800
  return;
19779
19801
  }
19780
- let parsed;
19781
19802
  // check allowedAttributesMap for the element and attribute and modify the value
19782
19803
  // as necessary if there are specific values defined.
19783
19804
  let passedAllowedAttributesMapCheck = false;
@@ -19825,14 +19846,14 @@ function sanitizeHtml(html, options, _recursing) {
19825
19846
  let allowed = true;
19826
19847
 
19827
19848
  try {
19828
- const parsed = new URL(value);
19849
+ const parsed = parseUrl(value);
19829
19850
 
19830
19851
  if (options.allowedScriptHostnames || options.allowedScriptDomains) {
19831
19852
  const allowedHostname = (options.allowedScriptHostnames || []).find(function (hostname) {
19832
- return hostname === parsed.hostname;
19853
+ return hostname === parsed.url.hostname;
19833
19854
  });
19834
19855
  const allowedDomain = (options.allowedScriptDomains || []).find(function(domain) {
19835
- return parsed.hostname === domain || parsed.hostname.endsWith(`.${domain}`);
19856
+ return parsed.url.hostname === domain || parsed.url.hostname.endsWith(`.${domain}`);
19836
19857
  });
19837
19858
  allowed = allowedHostname || allowedDomain;
19838
19859
  }
@@ -19849,29 +19870,9 @@ function sanitizeHtml(html, options, _recursing) {
19849
19870
  if (name === 'iframe' && a === 'src') {
19850
19871
  let allowed = true;
19851
19872
  try {
19852
- // Chrome accepts \ as a substitute for / in the // at the
19853
- // start of a URL, so rewrite accordingly to prevent exploit.
19854
- // Also drop any whitespace at that point in the URL
19855
- value = value.replace(/^(\w+:)?\s*[\\/]\s*[\\/]/, '$1//');
19856
- if (value.startsWith('relative:')) {
19857
- // An attempt to exploit our workaround for base URLs being
19858
- // mandatory for relative URL validation in the WHATWG
19859
- // URL parser, reject it
19860
- throw new Error('relative: exploit attempt');
19861
- }
19862
- // naughtyHref is in charge of whether protocol relative URLs
19863
- // are cool. Here we are concerned just with allowed hostnames and
19864
- // whether to allow relative URLs.
19865
- //
19866
- // Build a placeholder "base URL" against which any reasonable
19867
- // relative URL may be parsed successfully
19868
- let base = 'relative://relative-site';
19869
- for (let i = 0; (i < 100); i++) {
19870
- base += `/${i}`;
19871
- }
19872
- const parsed = new URL(value, base);
19873
- const isRelativeUrl = parsed && parsed.hostname === 'relative-site' && parsed.protocol === 'relative:';
19874
- if (isRelativeUrl) {
19873
+ const parsed = parseUrl(value);
19874
+
19875
+ if (parsed.isRelativeUrl) {
19875
19876
  // default value of allowIframeRelativeUrls is true
19876
19877
  // unless allowedIframeHostnames or allowedIframeDomains specified
19877
19878
  allowed = has(options, 'allowIframeRelativeUrls')
@@ -19879,10 +19880,10 @@ function sanitizeHtml(html, options, _recursing) {
19879
19880
  : (!options.allowedIframeHostnames && !options.allowedIframeDomains);
19880
19881
  } else if (options.allowedIframeHostnames || options.allowedIframeDomains) {
19881
19882
  const allowedHostname = (options.allowedIframeHostnames || []).find(function (hostname) {
19882
- return hostname === parsed.hostname;
19883
+ return hostname === parsed.url.hostname;
19883
19884
  });
19884
19885
  const allowedDomain = (options.allowedIframeDomains || []).find(function(domain) {
19885
- return parsed.hostname === domain || parsed.hostname.endsWith(`.${domain}`);
19886
+ return parsed.url.hostname === domain || parsed.url.hostname.endsWith(`.${domain}`);
19886
19887
  });
19887
19888
  allowed = allowedHostname || allowedDomain;
19888
19889
  }
@@ -19897,7 +19898,7 @@ function sanitizeHtml(html, options, _recursing) {
19897
19898
  }
19898
19899
  if (a === 'srcset') {
19899
19900
  try {
19900
- parsed = parseSrcset(value);
19901
+ let parsed = parseSrcset(value);
19901
19902
  parsed.forEach(function(value) {
19902
19903
  if (naughtyHref('srcset', value.url)) {
19903
19904
  value.evil = true;
@@ -20123,7 +20124,17 @@ function sanitizeHtml(html, options, _recursing) {
20123
20124
  // Clobber any comments in URLs, which the browser might
20124
20125
  // interpret inside an XML data island, allowing
20125
20126
  // a javascript: URL to be snuck through
20126
- href = href.replace(/<!--.*?-->/g, '');
20127
+ while (true) {
20128
+ const firstIndex = href.indexOf('<!--');
20129
+ if (firstIndex === -1) {
20130
+ break;
20131
+ }
20132
+ const lastIndex = href.indexOf('-->', firstIndex + 4);
20133
+ if (lastIndex === -1) {
20134
+ break;
20135
+ }
20136
+ href = href.substring(0, firstIndex) + href.substring(lastIndex + 3);
20137
+ }
20127
20138
  // Case insensitive so we don't get faked out by JAVASCRIPT #1
20128
20139
  // Allow more characters after the first so we don't get faked
20129
20140
  // out by certain schemes browsers accept
@@ -20146,6 +20157,33 @@ function sanitizeHtml(html, options, _recursing) {
20146
20157
  return !options.allowedSchemes || options.allowedSchemes.indexOf(scheme) === -1;
20147
20158
  }
20148
20159
 
20160
+ function parseUrl(value) {
20161
+ value = value.replace(/^(\w+:)?\s*[\\/]\s*[\\/]/, '$1//');
20162
+ if (value.startsWith('relative:')) {
20163
+ // An attempt to exploit our workaround for base URLs being
20164
+ // mandatory for relative URL validation in the WHATWG
20165
+ // URL parser, reject it
20166
+ throw new Error('relative: exploit attempt');
20167
+ }
20168
+ // naughtyHref is in charge of whether protocol relative URLs
20169
+ // are cool. Here we are concerned just with allowed hostnames and
20170
+ // whether to allow relative URLs.
20171
+ //
20172
+ // Build a placeholder "base URL" against which any reasonable
20173
+ // relative URL may be parsed successfully
20174
+ let base = 'relative://relative-site';
20175
+ for (let i = 0; (i < 100); i++) {
20176
+ base += `/${i}`;
20177
+ }
20178
+
20179
+ const parsed = new URL(value, base);
20180
+
20181
+ const isRelativeUrl = parsed && parsed.hostname === 'relative-site' && parsed.protocol === 'relative:';
20182
+ return {
20183
+ isRelativeUrl,
20184
+ url: parsed
20185
+ };
20186
+ }
20149
20187
  /**
20150
20188
  * Filters user input css properties by allowlisted regex attributes.
20151
20189
  * Modifies the abstractSyntaxTree object.
@@ -20328,7 +20366,7 @@ var Card = function (_a) {
20328
20366
  var Cards = function (_a) {
20329
20367
  var cards = _a.cards;
20330
20368
  return (React.createElement(Container$M, { "data-testid": "Cards" },
20331
- React.createElement(Row, null, cards.map(function (card, index) { return (React.createElement(Column, { small: "full", medium: "one-half", large: "one-third", key: index },
20369
+ React.createElement(Row$1, null, cards.map(function (card, index) { return (React.createElement(Column, { small: "full", medium: "one-half", large: "one-third", key: index },
20332
20370
  React.createElement(Card, __assign$2({}, card)))); }))));
20333
20371
  };
20334
20372
 
@@ -20337,91 +20375,85 @@ const Container$C = styled.div`
20337
20375
  `;
20338
20376
 
20339
20377
  const Outer = styled.div`
20340
- ${props => props.theme.fontStyles}
20341
- max-width: 725px;
20342
- &:not(:first-child) {
20343
- a {
20344
- margin-top: 30px;
20345
- &:before {
20346
- content: "";
20347
- height: 1px;
20348
- width: 100%;
20349
- position: absolute;
20350
- left: 0;
20351
- top: -15px;
20352
- background: ${props => props.theme.theme_vars.colours.grey_dark}80;
20353
- }
20354
- }
20355
- }
20378
+ ${(props) => props.theme.fontStyles}
20379
+ max-width: 725px;
20380
+ &:not(:first-child) {
20381
+ a {
20382
+ margin-top: 15px;
20383
+ border-top: 1px solid ${(props) => props.theme.theme_vars.colours.grey_dark}80;
20384
+ padding-top: 15px;
20385
+ }
20386
+ }
20356
20387
  `;
20357
20388
  const Link$3 = styled.a`
20358
- margin-bottom: 15px;
20359
- display: block;
20360
- width: fit-content;
20361
- position: relative;
20362
- min-width: 300px;
20389
+ margin-bottom: 15px;
20390
+ display: block;
20391
+ width: 100%;
20392
+ position: relative;
20393
+ min-width: 300px;
20363
20394
 
20364
- svg {
20365
- margin-right: 10px;
20366
- vertical-align: top;
20367
- margin-left: 5px;
20368
- margin-top: 5px;
20369
- g {
20370
- fill: ${props => props.theme.theme_vars.colours.grey_dark};
20371
- }
20395
+ svg {
20396
+ margin-right: 10px;
20397
+ vertical-align: top;
20398
+ margin-left: 5px;
20399
+ margin-top: 5px;
20400
+ g {
20401
+ fill: ${(props) => props.theme.theme_vars.colours.grey_dark};
20372
20402
  }
20403
+ }
20373
20404
 
20374
- &:hover {
20375
- .file-title {
20376
- color: ${props => props.theme.theme_vars.colours.action};
20377
- }
20378
- .file-details {
20379
- transform: translate(3px, 0px);
20380
- }
20381
- svg {
20382
- g {
20383
- fill: ${props => props.theme.theme_vars.colours.action};
20384
- }
20385
- }
20405
+ &:hover {
20406
+ .file-title {
20407
+ color: ${(props) => props.theme.theme_vars.colours.action};
20386
20408
  }
20387
-
20388
- &:focus {
20389
- outline: none;
20390
- background: ${props => props.theme.theme_vars.colours.focus};
20391
- box-shadow: 0px 0px 0px 3px ${props => props.theme.theme_vars.colours.focus}, 0px 3px 0px 3px ${props => props.theme.theme_vars.colours.black};
20392
- svg {
20393
- g {
20394
- fill: ${props => props.theme.theme_vars.colours.black};
20395
- }
20396
- }
20409
+ .file-details {
20410
+ transform: translate(3px, 0px);
20397
20411
  }
20398
- &:active {
20399
- transform: translateY(2px);
20400
- box-shadow: 0px 0px 0px 3px ${props => props.theme.theme_vars.colours.focus}, 0px 1px 0px 3px ${props => props.theme.theme_vars.colours.black};
20412
+ svg {
20413
+ g {
20414
+ fill: ${(props) => props.theme.theme_vars.colours.action};
20415
+ }
20401
20416
  }
20417
+ }
20418
+
20419
+ &:focus {
20420
+ outline: none;
20421
+ background: ${(props) => props.theme.theme_vars.colours.focus};
20422
+ box-shadow: 0px 0px 0px 3px ${(props) => props.theme.theme_vars.colours.focus},
20423
+ 0px 3px 0px 3px ${(props) => props.theme.theme_vars.colours.black};
20424
+ svg {
20425
+ g {
20426
+ fill: ${(props) => props.theme.theme_vars.colours.black};
20427
+ }
20428
+ }
20429
+ }
20430
+ &:active {
20431
+ transform: translateY(2px);
20432
+ box-shadow: 0px 0px 0px 3px ${(props) => props.theme.theme_vars.colours.focus},
20433
+ 0px 1px 0px 3px ${(props) => props.theme.theme_vars.colours.black};
20434
+ }
20402
20435
  `;
20403
20436
 
20404
- const FileDetails= styled.div`
20405
- display: inline-block;
20406
- max-width: calc(100% - 45px);
20407
- transition: transform 0.3s;
20437
+ const FileDetails = styled.div`
20438
+ display: inline-block;
20439
+ max-width: calc(100% - 45px);
20440
+ transition: transform 0.3s;
20408
20441
  `;
20409
20442
  const Title$7 = styled.span`
20410
- display: block;
20411
- color: ${props => props.theme.theme_vars.colours.action};
20412
- font-weight: 700;
20413
-
20443
+ display: block;
20444
+ color: ${(props) => props.theme.theme_vars.colours.action};
20445
+ font-weight: 700;
20414
20446
  `;
20415
20447
  const Type = styled.span`
20416
- color: ${props => props.theme.theme_vars.colours.black};
20417
- margin-right: 5px;
20418
- font-weight: 400 !important;
20419
- font-size: ${props => props.theme.theme_vars.fontSizes.extra_small};
20448
+ color: ${(props) => props.theme.theme_vars.colours.black};
20449
+ margin-right: 5px;
20450
+ font-weight: 400 !important;
20451
+ font-size: ${(props) => props.theme.theme_vars.fontSizes.extra_small};
20420
20452
  `;
20421
20453
  const Size = styled.span`
20422
- color: ${props => props.theme.theme_vars.colours.black};
20423
- font-size: ${props => props.theme.theme_vars.fontSizes.extra_small};
20424
- font-weight: 400 !important;
20454
+ color: ${(props) => props.theme.theme_vars.colours.black};
20455
+ font-size: ${(props) => props.theme.theme_vars.fontSizes.extra_small};
20456
+ font-weight: 400 !important;
20425
20457
  `;
20426
20458
 
20427
20459
  var IconDownload$2 = function (_a) {
@@ -20700,15 +20732,15 @@ const Container$A = styled.figure`
20700
20732
  : props.theme.theme_vars.colours.grey_light};
20701
20733
  border-bottom: 1px solid ${(props) => props.theme.theme_vars.colours.grey};
20702
20734
  margin-bottom: ${(props) => props.theme.theme_vars.spacingSizes.medium};
20703
- float: ${(props) => (props.wrapText === true ? 'left' : 'none')};
20704
- width: ${(props) => (props.wrapText === true ? '30%' : '100%')};
20705
20735
  margin-top: ${(props) => props.theme.theme_vars.spacingSizes.medium};
20706
- margin-right: ${(props) => (props.wrapText === true ? '1.5rem' : '0')};
20736
+ float: none;
20737
+ width: 100%;
20738
+ margin-right: 0;
20707
20739
 
20708
- @media screen and (max-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
20709
- float: none;
20710
- width: 100%;
20711
- margin-right: 0;
20740
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
20741
+ float: ${(props) => (props.wrapText === true ? 'left' : 'none')};
20742
+ width: ${(props) => (props.wrapText === true ? '30%' : '100%')};
20743
+ margin-right: ${(props) => (props.wrapText === true ? '1.5rem' : '0')};
20712
20744
  }
20713
20745
  `;
20714
20746
 
@@ -21353,7 +21385,9 @@ const HeadingContainer = styled.div`
21353
21385
  `;
21354
21386
 
21355
21387
  const Content$3 = styled.div`
21356
- margin: ${(props) => props.theme.theme_vars.spacingSizes.medium} 0;
21388
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
21389
+ margin: ${(props) => props.theme.theme_vars.spacingSizes.medium} 0;
21390
+ }
21357
21391
  `;
21358
21392
 
21359
21393
  /**
@@ -21362,7 +21396,7 @@ const Content$3 = styled.div`
21362
21396
  var ImageAndText = function (_a) {
21363
21397
  var heading = _a.heading, textContent = _a.textContent, image = _a.image;
21364
21398
  return (React.createElement(Container$z, { "data-testid": "ImageAndText" },
21365
- React.createElement(Row, null,
21399
+ React.createElement(Row$1, null,
21366
21400
  heading && (React.createElement(Column, { small: "full", medium: "full", large: "full" },
21367
21401
  React.createElement(HeadingContainer, null,
21368
21402
  React.createElement(Heading, { text: heading, level: 3 })))),
@@ -21382,8 +21416,6 @@ const Container$y = styled.div`
21382
21416
  props.theme.cardinal_name === 'north'
21383
21417
  ? props.theme.theme_vars.colours.white
21384
21418
  : props.theme.theme_vars.colours.grey_light};
21385
- margin-left: -15px;
21386
- width: calc(100% + 30px);
21387
21419
  border-bottom: 3px solid ${(props) => props.theme.theme_vars.colours.action};
21388
21420
 
21389
21421
  @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
@@ -21395,8 +21427,6 @@ const Container$y = styled.div`
21395
21427
  justify-content: space-between;
21396
21428
  align-items: center;
21397
21429
  flex-wrap: wrap;
21398
- margin-left: -30px;
21399
- width: calc(100% + 60px);
21400
21430
  border-bottom: none;
21401
21431
  }
21402
21432
  @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.l}) {
@@ -21490,6 +21520,9 @@ const PromoTilesContainer = styled.div`
21490
21520
  * A promo tile, containing image and text area
21491
21521
  */
21492
21522
  const PromoTile = styled.a`
21523
+ display: block;
21524
+ width: 100%;
21525
+ height: 100%;
21493
21526
  background: ${(props) =>
21494
21527
  props.theme.cardinal_name === 'north'
21495
21528
  ? props.theme.theme_vars.colours.white
@@ -21534,33 +21567,6 @@ const PromoTile = styled.a`
21534
21567
  -moz-box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.15),
21535
21568
  0px 2px 0px 0px ${(props) => props.theme.theme_vars.colours.black} !important;
21536
21569
  }
21537
-
21538
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
21539
- display: -ms-flex;
21540
- display: -webkit-flex;
21541
- display: flex;
21542
- width: 100%;
21543
- }
21544
-
21545
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
21546
- width: 100%;
21547
- margin-right: 30px;
21548
- margin-bottom: 20px;
21549
- display: block;
21550
- flex: 1;
21551
- max-width: 50%;
21552
- min-width: 30%;
21553
-
21554
- &:nth-of-type(2n) {
21555
- margin-right: 30px;
21556
- }
21557
- &:nth-of-type(3n) {
21558
- margin-right: 0;
21559
- }
21560
- &:last-of-type {
21561
- margin-right: 0;
21562
- }
21563
- }
21564
21570
  `;
21565
21571
 
21566
21572
  /**
@@ -21571,17 +21577,15 @@ const PromoImage = styled.span`
21571
21577
  width: 100%;
21572
21578
  height: ${imageHeightMobile$1}px;
21573
21579
  overflow: hidden;
21574
- background-image: url("${(props) => props.background}");
21580
+ background-image: url('${(props) => props.background}');
21575
21581
  background-size: cover;
21576
21582
  background-position: center;
21577
21583
  justify-self: center;
21578
21584
 
21579
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}){
21580
- flex: 0 0 40%;
21581
- height: 100%;
21582
- min-height: ${imageHeightMobile$1}px;
21585
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
21586
+ min-height: ${imageHeightDesktop$1}px;
21583
21587
  }
21584
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}){
21588
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
21585
21589
  flex: none;
21586
21590
  height: ${imageHeightDesktop$1}px;
21587
21591
  }
@@ -21665,22 +21669,20 @@ const PromoCallToAction = styled.p`
21665
21669
  */
21666
21670
  var PromoBlock = function (_a) {
21667
21671
  var promos = _a.promos;
21668
- if (promos && promos.length > 0) {
21669
- return (React.createElement(React.Fragment, null,
21670
- React.createElement(PromoTilesContainer, null, promos.map(function (promo, index) { return (React.createElement(PromoTile, { key: promo.callToActionURL, href: promo.callToActionURL },
21671
- React.createElement(LazyImage, { src: promo.imageMedium, placeholder: promo.imageSmall, visibilitySensorProps: {
21672
- partialVisibility: true,
21673
- } }, function (src) { return (React.createElement(PromoImage, { background: src, role: "img", "aria-label": promo.imageAltText ? promo.imageAltText : "" })); }),
21674
- React.createElement(PromoText, null,
21675
- React.createElement(PromoHeadline, { level: 3, text: promo.title }),
21676
- React.createElement(PromoContent, { dangerouslySetInnerHTML: {
21677
- __html: sanitizeHtml_1(promo.content),
21678
- } }),
21679
- React.createElement(PromoCallToAction, null, promo.callToActionText)))); }))));
21680
- }
21681
- else {
21682
- return React.createElement(React.Fragment, null);
21683
- }
21672
+ return (React.createElement(React.Fragment, null, promos && promos.length > 0 && (React.createElement(PromoTilesContainer, { "data-testid": "PromoBlock" },
21673
+ React.createElement(Row$1, { isList: true, hasWrap: false },
21674
+ promos.map(function (promo, index) { return (React.createElement(Column, { isList: true, small: "full", medium: "one-half", large: "auto", key: promo.callToActionURL },
21675
+ React.createElement(PromoTile, { href: promo.callToActionURL },
21676
+ React.createElement(LazyImage, { src: promo.imageMedium, placeholder: promo.imageSmall, visibilitySensorProps: {
21677
+ partialVisibility: true,
21678
+ } }, function (src) { return (React.createElement(PromoImage, { background: src, role: "img", "aria-label": promo.imageAltText ? promo.imageAltText : '' })); }),
21679
+ React.createElement(PromoText, null,
21680
+ React.createElement(PromoHeadline, { level: 3, text: promo.title }),
21681
+ React.createElement(PromoContent, { dangerouslySetInnerHTML: {
21682
+ __html: sanitizeHtml_1(promo.content),
21683
+ } }),
21684
+ React.createElement(PromoCallToAction, null, promo.callToActionText))))); }),
21685
+ promos.length === 1 && React.createElement(Column, { small: "full", medium: "one-half", large: "one-half" }))))));
21684
21686
  };
21685
21687
 
21686
21688
  /**
@@ -22006,40 +22008,48 @@ var IconDownload$1 = function (_a) {
22006
22008
  };
22007
22009
 
22008
22010
  const handleContainerPadding = (noBackground, noPadding) => {
22009
- if (noPadding || noBackground) {
22010
- return 0
22011
- } else {
22012
- return "50px";
22013
- }
22011
+ if (noPadding || noBackground) {
22012
+ return 0;
22013
+ } else {
22014
+ return '50px';
22015
+ }
22014
22016
  };
22015
22017
 
22016
22018
  const Container$w = styled.div`
22017
- background: ${props => props.noBackground ? "transparent" :
22018
- props.theme.cardinal_name === "north" ? (props.theme.theme_vars.colours.grey_light+"7a") : props.theme.theme_vars.colours.white};
22019
- overflow: ${props => props.noPadding ? "hidden" : "visible"};
22020
- padding-bottom: ${({ noBackground, noPadding }) => handleContainerPadding(noBackground, noPadding)};
22019
+ background: ${(props) =>
22020
+ props.noBackground
22021
+ ? 'transparent'
22022
+ : props.theme.cardinal_name === 'north'
22023
+ ? props.theme.theme_vars.colours.grey_light + '7a'
22024
+ : props.theme.theme_vars.colours.white};
22025
+ overflow: ${(props) => (props.noPadding ? 'hidden' : 'visible')};
22026
+ padding-bottom: ${({ noBackground, noPadding }) => handleContainerPadding(noBackground, noPadding)};
22021
22027
  `;
22022
22028
 
22023
22029
  const MaxWidth = styled.div`
22024
- ${props => props.theme.fontStyles}
22025
- margin-right: 15px;
22026
- margin-left: 15px;
22027
- overflow: ${props => props.overflowVisible ? "visible" : "hidden"};
22030
+ ${(props) => props.theme.fontStyles}
22031
+ padding-right: ${(props) => props.theme.theme_vars.spacingSizes.medium};
22032
+ padding-left: ${(props) => props.theme.theme_vars.spacingSizes.medium};
22033
+ overflow: ${(props) => (props.overflowVisible ? 'visible' : 'hidden')};
22028
22034
 
22029
- pre {
22030
- font-family: monospace;
22031
- white-space: pre;
22032
- }
22033
- @media screen and (min-width: ${props => props.theme.theme_vars.breakpoints.m}){
22034
- margin-right: 30px;
22035
- margin-left: 30px;
22036
- }
22035
+ pre {
22036
+ font-family: monospace;
22037
+ white-space: pre;
22038
+ }
22039
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
22040
+ margin-right: ${(props) => props.theme.theme_vars.spacingSizes.large};
22041
+ margin-left: ${(props) => props.theme.theme_vars.spacingSizes.large};
22042
+ padding-left: ${(props) => props.theme.theme_vars.spacingSizes.small};
22043
+ padding-right: ${(props) => props.theme.theme_vars.spacingSizes.small};
22044
+ }
22037
22045
 
22038
- @media screen and (min-width: calc(${props => props.theme.theme_vars.breakpoints.l} + 60px)){
22039
- margin-right: auto;
22040
- margin-left: auto;
22041
- max-width: ${props => props.theme.theme_vars.breakpoints.l};
22042
- }
22046
+ @media screen and (min-width: calc(${(props) => props.theme.theme_vars.breakpoints.l} + 60px)) {
22047
+ margin-right: auto;
22048
+ margin-left: auto;
22049
+ padding-left: ${(props) => props.theme.theme_vars.spacingSizes.small};
22050
+ padding-right: ${(props) => props.theme.theme_vars.spacingSizes.small};
22051
+ max-width: ${(props) => props.theme.theme_vars.breakpoints.l};
22052
+ }
22043
22053
  `;
22044
22054
 
22045
22055
  /**
@@ -22725,14 +22735,18 @@ const FooterListItem = styled.li`
22725
22735
  margin-bottom: 15px;
22726
22736
  `;
22727
22737
 
22728
- const SocialLinks = styled.div`
22729
- margin-bottom: 15px;
22730
- margin-top: 5px;
22738
+ const SocialLinks = styled.ul`
22739
+ margin: 5px 0 15px 0;
22740
+ list-style: none;
22741
+ `;
22742
+
22743
+ const SocialLinkItem = styled.li`
22744
+ left: 0;
22745
+ display: inline-block;
22731
22746
  `;
22732
22747
 
22733
22748
  const SocialLinkSingle = styled.a`
22734
22749
  display: inline-block;
22735
- margin-right: 15px;
22736
22750
  height: 36px;
22737
22751
 
22738
22752
  &:hover {
@@ -22865,16 +22879,21 @@ var Footer = function (_a) {
22865
22879
  footerLinksArray && (React.createElement(FooterList, null, footerLinksArray.map(function (link, i) { return (React.createElement(FooterListItem, { key: i },
22866
22880
  React.createElement(FooterLink, { key: link.title, href: link.url, title: link.title }, link.title))); }))),
22867
22881
  React.createElement(SocialLinks, null,
22868
- themeContext.theme_vars.twitter_link && (React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.twitter_link, title: "View our Twitter feed" },
22869
- React.createElement(ServiceIcon$2, { colourFill: themeContext.theme_vars.colours.white }))),
22870
- themeContext.theme_vars.facebook_link && (React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.facebook_link, title: "View our Facebook page" },
22871
- React.createElement(ServiceIcon$3, { colourFill: themeContext.theme_vars.colours.white }))),
22872
- themeContext.theme_vars.instagram_link && (React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.instagram_link, title: "View our Instagram feed" },
22873
- React.createElement(ServiceIcon$4, { colourFill: themeContext.theme_vars.colours.white }))),
22874
- themeContext.theme_vars.youtube_link && (React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.youtube_link, title: "View our YouTube channel" },
22875
- React.createElement(ServiceIcon, { colourFill: themeContext.theme_vars.colours.white }))),
22876
- themeContext.theme_vars.linkedin_link && (React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.linkedin_link, title: "View our LinkedIn page" },
22877
- React.createElement(ServiceIcon$1, { colourFill: themeContext.theme_vars.colours.white })))),
22882
+ themeContext.theme_vars.twitter_link && (React.createElement(SocialLinkItem, null,
22883
+ React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.twitter_link, title: "View our Twitter feed" },
22884
+ React.createElement(ServiceIcon$2, { colourFill: themeContext.theme_vars.colours.white })))),
22885
+ themeContext.theme_vars.facebook_link && (React.createElement(SocialLinkItem, null,
22886
+ React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.facebook_link, title: "View our Facebook page" },
22887
+ React.createElement(ServiceIcon$3, { colourFill: themeContext.theme_vars.colours.white })))),
22888
+ themeContext.theme_vars.instagram_link && (React.createElement(SocialLinkItem, null,
22889
+ React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.instagram_link, title: "View our Instagram feed" },
22890
+ React.createElement(ServiceIcon$4, { colourFill: themeContext.theme_vars.colours.white })))),
22891
+ themeContext.theme_vars.youtube_link && (React.createElement(SocialLinkItem, null,
22892
+ React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.youtube_link, title: "View our YouTube channel" },
22893
+ React.createElement(ServiceIcon, { colourFill: themeContext.theme_vars.colours.white })))),
22894
+ themeContext.theme_vars.linkedin_link && (React.createElement(SocialLinkItem, null,
22895
+ React.createElement(SocialLinkSingle, { href: themeContext.theme_vars.linkedin_link, title: "View our LinkedIn page" },
22896
+ React.createElement(ServiceIcon$1, { colourFill: themeContext.theme_vars.colours.white }))))),
22878
22897
  React.createElement(FooterCopy, null,
22879
22898
  "\u00A9\u00A0",
22880
22899
  themeContext.full_name,
@@ -23878,6 +23897,8 @@ const ArticleContainer$1 = styled.a`
23878
23897
  text-decoration: none !important;
23879
23898
  font-weight: normal !important;
23880
23899
  margin-bottom: 15px;
23900
+ width: 100%;
23901
+ height: 100%;
23881
23902
 
23882
23903
  &:hover {
23883
23904
  border-bottom: 5px solid ${(props) => props.theme.theme_vars.colours.action_dark};
@@ -23916,45 +23937,10 @@ const ArticleContainer$1 = styled.a`
23916
23937
  ${(props) => props.theme.linkStylesActive};
23917
23938
  }
23918
23939
  }
23919
-
23920
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
23921
- display: -ms-flex;
23922
- display: -webkit-flex;
23923
- display: flex;
23924
- width: 100%;
23925
- }
23926
-
23927
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
23928
- width: 100%;
23929
- margin-right: 30px;
23930
- margin-bottom: 20px;
23931
- display: block;
23932
- flex: 1;
23933
- max-width: 50%;
23934
- min-width: 30%;
23935
-
23936
- &:nth-of-type(2n) {
23937
- margin-right: 30px;
23938
- }
23939
- &:nth-of-type(3n) {
23940
- margin-right: 0;
23941
- }
23942
- &:last-of-type {
23943
- margin-right: 0;
23944
- }
23945
- }
23946
23940
  `;
23947
23941
 
23948
23942
  const ArticleContent$1 = styled.div`
23949
23943
  padding: 15px;
23950
- height: calc(100% - ${imageHeightMobile + 30}px);
23951
-
23952
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
23953
- display: flex;
23954
- flex-flow: row;
23955
- flex-wrap: wrap;
23956
- height: calc(100% - ${imageHeightDesktop + 30}px);
23957
- }
23958
23944
  `;
23959
23945
 
23960
23946
  const ImageContainer$3 = styled.span`
@@ -24000,14 +23986,19 @@ var NewsArticleFeaturedBlock = function (_a) {
24000
23986
  if (articles && articles.length > 0) {
24001
23987
  return (React.createElement(React.Fragment, null,
24002
23988
  !withoutTitle && React.createElement(Heading, { text: "News articles and press releases" }),
24003
- React.createElement(Container$k, null, articles.map(function (article) { return (React.createElement(ArticleContainer$1, { key: article.id, href: article.url },
24004
- article.image720x405 && (React.createElement(LazyImage, { src: article.image720x405, placeholder: article.image72x41, visibilitySensorProps: {
24005
- partialVisibility: true,
24006
- } }, function (src) { return (React.createElement(ImageContainer$3, { background: src, role: "img", "aria-label": article.imageAltText ? article.imageAltText : '' })); })),
24007
- React.createElement(ArticleContent$1, null,
24008
- React.createElement(Title$5, { className: "article_title" }, article.title),
24009
- React.createElement(DateContainer$1, null,
24010
- React.createElement(NewsArticleDate, { text: article.date.toString(), format: "X" }))))); })),
23989
+ React.createElement(Container$k, null,
23990
+ React.createElement(Row$1, { isList: true }, articles.map(function (article) { return (React.createElement(Column, { isList: true, small: "full", medium: "one-half", large: "one-third", key: article.id },
23991
+ React.createElement(ArticleContainer$1, { href: article.url },
23992
+ React.createElement(Row$1, null,
23993
+ article.image720x405 && (React.createElement(Column, { small: "full", medium: "full", large: "full", hasPadding: false },
23994
+ React.createElement(LazyImage, { src: article.image720x405, placeholder: article.image72x41, visibilitySensorProps: {
23995
+ partialVisibility: true,
23996
+ } }, function (src) { return (React.createElement(ImageContainer$3, { background: src, role: "img", "aria-label": article.imageAltText ? article.imageAltText : '' })); }))),
23997
+ React.createElement(Column, { small: "full", medium: "full", large: "full" },
23998
+ React.createElement(ArticleContent$1, null,
23999
+ React.createElement(Title$5, { className: "article_title" }, article.title),
24000
+ React.createElement(DateContainer$1, null,
24001
+ React.createElement(NewsArticleDate, { text: article.date.toString(), format: "X" })))))))); }))),
24011
24002
  viewAllLink && (React.createElement(ViewAllContainer, null,
24012
24003
  React.createElement(Button$2, { text: "View all news", primary: false, url: viewAllLink, size: "large" })))));
24013
24004
  }
@@ -24263,7 +24254,6 @@ var NewsArticleImage = function (_a) {
24263
24254
 
24264
24255
  const Container$h = styled.div`
24265
24256
  ${(props) => props.theme.fontStyles};
24266
- padding: 15px 0;
24267
24257
  `;
24268
24258
 
24269
24259
  const Title$4 = styled.div`
@@ -24321,7 +24311,7 @@ const ArticleContainer = styled.a`
24321
24311
  }
24322
24312
  }
24323
24313
 
24324
- margin-bottom: 40px;
24314
+ margin-bottom: ${(props) => props.theme.theme_vars.spacingSizes.medium};
24325
24315
 
24326
24316
  @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
24327
24317
  display: flex;
@@ -24383,17 +24373,19 @@ var NewsArticleList = function (_a) {
24383
24373
  var results = _a.results;
24384
24374
  var extractLength = 140;
24385
24375
  if (results && results.length > 0) {
24386
- return (React.createElement(Container$h, { "data-testid": "NewsArticleList" }, results.map(function (article) { return (React.createElement(ArticleContainer, { href: article.url, title: article.title, key: article.id },
24387
- article.image720x405 && (React.createElement(LazyImage, { src: article.image720x405, placeholder: article.image72x41, visibilitySensorProps: {
24388
- partialVisibility: true,
24389
- } }, function (src) { return (React.createElement(ImageContainer$1, { className: "news-article-list__image", background: src, role: "img", "aria-label": article.imageAltText ? article.imageAltText : 'News article' })); })),
24390
- React.createElement(ArticleContent, { withImage: article.image720x405 ? true : false },
24391
- React.createElement(Title$4, { className: "news-article-list__title" }, article.title),
24392
- article.excerpt.length > extractLength
24393
- ? article.excerpt.substr(0, extractLength - 1).trim() + String.fromCharCode(8230)
24394
- : article.excerpt,
24395
- React.createElement(DateContainer, null,
24396
- React.createElement(NewsArticleDate, { text: article.date.toString(), format: "X" }))))); })));
24376
+ return (React.createElement(Container$h, { "data-testid": "NewsArticleList" },
24377
+ React.createElement(Row$1, { isList: true }, results.map(function (article) { return (React.createElement(Column, { isList: true, small: "full", medium: "full", large: "full", key: article.id },
24378
+ React.createElement(ArticleContainer, { href: article.url, title: article.title },
24379
+ article.image720x405 && (React.createElement(LazyImage, { src: article.image720x405, placeholder: article.image72x41, visibilitySensorProps: {
24380
+ partialVisibility: true,
24381
+ } }, function (src) { return (React.createElement(ImageContainer$1, { className: "news-article-list__image", background: src, role: "img", "aria-label": article.imageAltText ? article.imageAltText : 'News article' })); })),
24382
+ React.createElement(ArticleContent, { withImage: article.image720x405 ? true : false },
24383
+ React.createElement(Title$4, { className: "news-article-list__title" }, article.title),
24384
+ article.excerpt.length > extractLength
24385
+ ? article.excerpt.substr(0, extractLength - 1).trim() + String.fromCharCode(8230)
24386
+ : article.excerpt,
24387
+ React.createElement(DateContainer, null,
24388
+ React.createElement(NewsArticleDate, { text: article.date.toString(), format: "X" })))))); }))));
24397
24389
  }
24398
24390
  else {
24399
24391
  return (React.createElement(Container$h, { "data-testid": "NewsArticleList" },
@@ -24889,16 +24881,16 @@ var PhaseBanner = function (_a) {
24889
24881
  };
24890
24882
 
24891
24883
  const Container$9 = styled.div`
24892
- ${props => props.theme.fontStyles};
24884
+ ${(props) => props.theme.fontStyles};
24893
24885
  `;
24894
24886
 
24895
24887
  const ResultInfo = styled.div`
24896
24888
  font-weight: bold;
24897
- margin: ${props => props.theme.theme_vars.spacingSizes.large} 0;
24889
+ margin: ${(props) => props.theme.theme_vars.spacingSizes.large} 0;
24898
24890
  `;
24899
24891
 
24900
24892
  const Result = styled.div`
24901
- margin-bottom: ${props => props.theme.theme_vars.spacingSizes.x_large};
24893
+ margin-bottom: ${(props) => props.theme.theme_vars.spacingSizes.x_large};
24902
24894
 
24903
24895
  &:first-of-type {
24904
24896
  margin-top: 0;
@@ -24906,7 +24898,7 @@ const Result = styled.div`
24906
24898
  `;
24907
24899
 
24908
24900
  const Title$3 = styled.a`
24909
- ${props => props.theme.linkStyles};
24901
+ ${(props) => props.theme.linkStyles};
24910
24902
  font-size: 1.2em;
24911
24903
  display: block;
24912
24904
  margin-bottom: 5px;
@@ -24916,10 +24908,13 @@ const ServiceArea = styled.p`
24916
24908
  font-size: 14px;
24917
24909
  font-size: 0.8rem;
24918
24910
  line-height: 1.3;
24919
- color: ${props => props.theme.theme_vars.colours.grey_dark};
24911
+ color: ${(props) =>
24912
+ props.theme.cardinal_name === 'west'
24913
+ ? props.theme.theme_vars.colours.grey_darke
24914
+ : props.theme.theme_vars.colours.grey_darkest};
24920
24915
  margin-bottom: 3px !important;
24921
24916
 
24922
- @media screen and (min-width: ${props => props.theme.theme_vars.breakpoints.s}){
24917
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
24923
24918
  font-size: 16px;
24924
24919
  font-size: 1rem;
24925
24920
  line-height: 1.4;
@@ -24927,7 +24922,7 @@ const ServiceArea = styled.p`
24927
24922
  `;
24928
24923
 
24929
24924
  const Summary$2 = styled.p`
24930
- margin-bottom: ${props => props.theme.theme_vars.spacingSizes.small};
24925
+ margin-bottom: ${(props) => props.theme.theme_vars.spacingSizes.small};
24931
24926
  `;
24932
24927
 
24933
24928
  const SignpostContainer = styled.div`
@@ -24950,8 +24945,7 @@ const SignpostContainer = styled.div`
24950
24945
  }
24951
24946
  }
24952
24947
 
24953
-
24954
- @media screen and (min-width: ${props => props.theme.theme_vars.breakpoints.s}){
24948
+ @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
24955
24949
  font-size: 16px;
24956
24950
  font-size: 1rem;
24957
24951
  line-height: 1.4;
@@ -25084,54 +25078,25 @@ const SectionTitle$1 = styled(Heading)`
25084
25078
  : props.theme.theme_vars.colours.grey_light};
25085
25079
  padding: 10px 15px;
25086
25080
  width: 100%;
25087
- margin-left: -15px;
25088
25081
  margin-bottom: 15px;
25089
25082
  max-width: none !important;
25090
25083
  border-radius: ${(props) => props.theme.theme_vars.border_radius};
25091
25084
 
25092
25085
  @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
25093
- width: calc(100% - 30px);
25086
+ width: 100%;
25094
25087
  margin-left: 0;
25095
25088
  margin-bottom: 25px;
25096
25089
  }
25097
25090
  `;
25098
25091
 
25099
- const LinksList$1 = styled.div`
25100
- display: flex;
25101
- -webkit-flex-direction: row;
25102
- -moz-flex-direction: row;
25103
- -ms-flex-direction: row;
25104
- flex-direction: row;
25105
- flex-wrap: wrap;
25106
- justify-content: space-between;
25107
- `;
25108
-
25109
- const PagelinkBlank$1 = styled.div`
25110
- display: none;
25111
-
25112
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
25113
- display: block;
25114
- padding: 15px;
25115
- width: calc(33.333% - 61px);
25116
- margin-bottom: 31px;
25117
- }
25118
- `;
25119
-
25120
25092
  const Pagelink = styled.a`
25121
25093
  color: ${(props) => props.theme.theme_vars.colours.black};
25122
25094
  text-decoration: none !important;
25123
25095
  display: block;
25124
- padding: 15px;
25096
+ padding: ${(props) => props.theme.theme_vars.spacingSizes.medium};
25125
25097
  border-radius: ${(props) => props.theme.theme_vars.border_radius};
25126
25098
  width: 100%;
25127
-
25128
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
25129
- width: calc(50% - 46px);
25130
- margin-bottom: 31px;
25131
- }
25132
- @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.m}) {
25133
- width: calc(33.333% - 61px);
25134
- }
25099
+ height: 100%;
25135
25100
 
25136
25101
  &:hover,
25137
25102
  &:focus {
@@ -25201,17 +25166,16 @@ var SectionLinks = function (_a) {
25201
25166
  var sectionTitle = _a.sectionTitle, _b = _a.displayTitle, displayTitle = _b === void 0 ? true : _b, sectionSlug = _a.sectionSlug, pageLinksArray = _a.pageLinksArray, _c = _a.hasImages, hasImages = _c === void 0 ? false : _c;
25202
25167
  return (React.createElement(Container$8, { id: sectionSlug, "data-testid": "SectionLinks" },
25203
25168
  displayTitle ? React.createElement(SectionTitle$1, { text: sectionTitle }) : React.createElement("br", null),
25204
- React.createElement(LinksList$1, null,
25205
- pageLinksArray.map(function (link, i) {
25206
- var _a;
25207
- return (React.createElement(Pagelink, { key: i, href: link.url, title: link.title },
25169
+ React.createElement(Row$1, { isList: true }, pageLinksArray.map(function (link, i) {
25170
+ var _a;
25171
+ return (React.createElement(Column, { isList: true, small: "full", medium: "one-half", large: "one-third", key: i },
25172
+ React.createElement(Pagelink, { href: link.url, title: link.title },
25208
25173
  hasImages && (React.createElement(React.Fragment, null, ((_a = link.imageLarge) === null || _a === void 0 ? void 0 : _a.trim()) ? (React.createElement(LazyImage, { placeholder: link.imageSmall, src: link.imageLarge, visibilitySensorProps: {
25209
25174
  partialVisibility: true,
25210
25175
  } }, function (src) { return (React.createElement(ImageContainer, { image: src, role: "img", "aria-label": link.imageAltText })); })) : (React.createElement(ImageContainer, null)))),
25211
25176
  React.createElement(Title$2, null, link.title),
25212
- React.createElement(Summary$1, null, link.summary)));
25213
- }),
25214
- pageLinksArray.length > 1 && (pageLinksArray.length + 1) % 3 === 0 && React.createElement(PagelinkBlank$1, null))));
25177
+ React.createElement(Summary$1, null, link.summary))));
25178
+ }))));
25215
25179
  };
25216
25180
 
25217
25181
  const Container$7 = styled.aside`
@@ -25564,7 +25528,8 @@ const QuickLinksInnerContainer = styled.div`
25564
25528
  background: ${(props) => props.theme.theme_vars.colours.action_light};
25565
25529
  border-top: ${(props) => props.theme.theme_vars.border_width_thin} solid
25566
25530
  ${(props) => props.theme.theme_vars.colours.action};
25567
- padding: ${(props) => props.theme.theme_vars.spacingSizes.medium} 0;
25531
+ padding: ${(props) => props.theme.theme_vars.spacingSizes.medium}
25532
+ ${(props) => props.theme.theme_vars.spacingSizes.small};
25568
25533
  box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.action} inset;
25569
25534
  -webkit-box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.action} inset;
25570
25535
  -moz-box-shadow: 0px -4px 0px 0px ${(props) => props.theme.theme_vars.colours.action} inset;
@@ -25622,7 +25587,7 @@ var ServiceLinksBoxed = function (_a) {
25622
25587
  return (_a = refs.current[index]) !== null && _a !== void 0 ? _a : React.createRef();
25623
25588
  });
25624
25589
  return (React.createElement(Container$5, { "data-testid": "ServiceLinksBoxed" },
25625
- React.createElement(Row, null, serviceLinksArray.map(function (serviceLink, index) {
25590
+ React.createElement(Row$1, null, serviceLinksArray.map(function (serviceLink, index) {
25626
25591
  var _a;
25627
25592
  return (React.createElement(Column, { small: "full", medium: "one-half", large: "one-third", key: index },
25628
25593
  React.createElement(ServiceLink, { onClick: function () { return toggleActive(index); }, show: index === activeServiceLink, "aria-label": index === activeServiceLink ? 'Close ' + serviceLink.title : 'View ' + serviceLink.title },
@@ -25631,8 +25596,8 @@ var ServiceLinksBoxed = function (_a) {
25631
25596
  React.createElement("span", { className: "serviceLinkChevron" })),
25632
25597
  React.createElement(QuickLinksContainer, { show: index === activeServiceLink, ref: refs.current[index] },
25633
25598
  React.createElement(QuickLinksInnerContainer, null,
25634
- React.createElement(Row, null, (_a = serviceLink.quickLinksArray) === null || _a === void 0 ? void 0 :
25635
- _a.map(function (quickLink, quickLinkIndex) { return (React.createElement(Column, { small: "full", medium: "one-half", large: "one-third", key: quickLinkIndex },
25599
+ React.createElement(Row$1, { isList: true }, (_a = serviceLink.quickLinksArray) === null || _a === void 0 ? void 0 :
25600
+ _a.map(function (quickLink, quickLinkIndex) { return (React.createElement(Column, { isList: true, small: "full", medium: "one-half", large: "one-third", key: quickLinkIndex },
25636
25601
  React.createElement(QuickLink, { href: quickLink.url }, quickLink.title))); }),
25637
25602
  React.createElement(Column, { small: "full", medium: "one-half", large: "one-third" },
25638
25603
  React.createElement(QuickLink, { href: serviceLink.url },
@@ -25668,7 +25633,7 @@ const Container$4 = styled.div`
25668
25633
 
25669
25634
  @media screen and (min-width: ${(props) => props.theme.theme_vars.breakpoints.s}) {
25670
25635
  max-height: none;
25671
- margin-top: 30px;
25636
+ margin-top: 15px;
25672
25637
  }
25673
25638
  `;
25674
25639