@royaloperahouse/chord 2.2.5-a-chord-development → 2.2.5-b-select-test

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/chord.esm.js CHANGED
@@ -2,6 +2,7 @@ import React__default, { createElement, memo, useRef, useCallback, useEffect, us
2
2
  import styled, { css, ThemeProvider, createGlobalStyle } from 'styled-components';
3
3
  import moment from 'moment';
4
4
  import { renderToString } from 'react-dom/server';
5
+ import ReactSelect, { components } from 'react-select';
5
6
  import Modal from 'react-modal';
6
7
  import ScrollLock from 'react-scrolllock';
7
8
 
@@ -2171,14 +2172,12 @@ var Icon = /*#__PURE__*/memo(function (_ref) {
2171
2172
  });
2172
2173
  Icon.displayName = 'Icon';
2173
2174
 
2174
- var _excluded = ["children", "iconName", "iconDirection", "color"];
2175
-
2176
2175
  var Button = function Button(_ref) {
2177
2176
  var children = _ref.children,
2178
2177
  iconName = _ref.iconName,
2179
2178
  iconDirection = _ref.iconDirection,
2180
2179
  color = _ref.color,
2181
- rest = _objectWithoutPropertiesLoose(_ref, _excluded);
2180
+ rest = _objectWithoutPropertiesLoose(_ref, ["children", "iconName", "iconDirection", "color"]);
2182
2181
 
2183
2182
  var truncatedString = children.substring(0, 30);
2184
2183
  return /*#__PURE__*/React__default.createElement(ButtonWrapper, Object.assign({}, rest, {
@@ -2254,11 +2253,9 @@ var ButtonType;
2254
2253
  ButtonType["Tertiary"] = "Tertiary";
2255
2254
  })(ButtonType || (ButtonType = {}));
2256
2255
 
2257
- var _excluded$1 = ["children"];
2258
-
2259
2256
  var PrimaryButton = function PrimaryButton(_ref) {
2260
2257
  var children = _ref.children,
2261
- props = _objectWithoutPropertiesLoose(_ref, _excluded$1);
2258
+ props = _objectWithoutPropertiesLoose(_ref, ["children"]);
2262
2259
 
2263
2260
  return /*#__PURE__*/React__default.createElement(PrimaryButtonWrapper, Object.assign({
2264
2261
  color: Colors.White
@@ -2272,11 +2269,9 @@ var PrimaryButtonWrapper$1 = /*#__PURE__*/styled(Button)(_templateObject$5 || (_
2272
2269
  return color ? "var(--base-color-" + color + ")" : theme.colors.primary;
2273
2270
  });
2274
2271
 
2275
- var _excluded$2 = ["children"];
2276
-
2277
2272
  var SecondaryButton = function SecondaryButton(_ref) {
2278
2273
  var children = _ref.children,
2279
- props = _objectWithoutPropertiesLoose(_ref, _excluded$2);
2274
+ props = _objectWithoutPropertiesLoose(_ref, ["children"]);
2280
2275
 
2281
2276
  return /*#__PURE__*/React__default.createElement(PrimaryButtonWrapper$1, Object.assign({
2282
2277
  color: Colors.Primary
@@ -2290,12 +2285,10 @@ var TertiaryButtonWrapper = /*#__PURE__*/styled.a(_templateObject$6 || (_templat
2290
2285
  });
2291
2286
  var TertiaryIconWrapper = /*#__PURE__*/styled.span(_templateObject2 || (_templateObject2 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n width: var(--button-icon-width);\n min-width: 20px;\n height: var(--button-icon-height);\n margin-left: var(--button-icon-margin);\n display: inline-block;\n"])));
2292
2287
 
2293
- var _excluded$3 = ["children", "color"];
2294
-
2295
2288
  var Button$1 = function Button(_ref) {
2296
2289
  var children = _ref.children,
2297
2290
  color = _ref.color,
2298
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
2291
+ rest = _objectWithoutPropertiesLoose(_ref, ["children", "color"]);
2299
2292
 
2300
2293
  var truncatedString = children.substring(0, 100);
2301
2294
  return /*#__PURE__*/React__default.createElement(TertiaryButtonWrapper, Object.assign({}, rest, {
@@ -3257,8 +3250,6 @@ var TabLinkWrapper = /*#__PURE__*/styled.a(_templateObject$l || (_templateObject
3257
3250
  });
3258
3251
  var TabLinkIconWrapper = /*#__PURE__*/styled.span(_templateObject2$9 || (_templateObject2$9 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n width: var(--button-icon-width);\n height: var(--button-icon-height);\n margin-right: var(--button-icon-margin);\n"])));
3259
3252
 
3260
- var _excluded$4 = ["children", "iconName", "iconDirection", "color", "hoverColor"];
3261
-
3262
3253
  var TabLink = function TabLink(_ref) {
3263
3254
  var children = _ref.children,
3264
3255
  iconName = _ref.iconName,
@@ -3267,7 +3258,7 @@ var TabLink = function TabLink(_ref) {
3267
3258
  color = _ref$color === void 0 ? Colors.DarkGrey : _ref$color,
3268
3259
  _ref$hoverColor = _ref.hoverColor,
3269
3260
  hoverColor = _ref$hoverColor === void 0 ? Colors.Primary : _ref$hoverColor,
3270
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
3261
+ rest = _objectWithoutPropertiesLoose(_ref, ["children", "iconName", "iconDirection", "color", "hoverColor"]);
3271
3262
 
3272
3263
  return /*#__PURE__*/React__default.createElement(TabLinkWrapper, Object.assign({
3273
3264
  color: color,
@@ -3317,7 +3308,6 @@ var TextAreaError = /*#__PURE__*/styled.div(_templateObject4$2 || (_templateObje
3317
3308
  return darkMode ? 'var(--base-color-white)' : 'var(--base-color-errorstate)';
3318
3309
  });
3319
3310
 
3320
- var _excluded$5 = ["label", "error", "width", "darkMode", "height", "columnStartDesktop", "columnStartDevice", "columnSpanDesktop", "columnSpanDevice", "maxLength", "tabIndex"];
3321
3311
  /**
3322
3312
  * An HTML textarea component for Chord.
3323
3313
  *
@@ -3379,7 +3369,7 @@ var TextArea = function TextArea(_ref) {
3379
3369
  maxLength = _ref$maxLength === void 0 ? 950 : _ref$maxLength,
3380
3370
  _ref$tabIndex = _ref.tabIndex,
3381
3371
  tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex,
3382
- textareaProps = _objectWithoutPropertiesLoose(_ref, _excluded$5);
3372
+ textareaProps = _objectWithoutPropertiesLoose(_ref, ["label", "error", "width", "darkMode", "height", "columnStartDesktop", "columnStartDevice", "columnSpanDesktop", "columnSpanDevice", "maxLength", "tabIndex"]);
3383
3373
 
3384
3374
  return /*#__PURE__*/React__default.createElement(GridItem, {
3385
3375
  columnStartDesktop: columnStartDesktop,
@@ -3439,7 +3429,6 @@ var ErrorLabel = /*#__PURE__*/styled.div(_templateObject6 || (_templateObject6 =
3439
3429
  return "var(--base-color-errorstate)";
3440
3430
  });
3441
3431
 
3442
- var _excluded$6 = ["label", "type", "error", "darkMode", "width"];
3443
3432
  /**
3444
3433
  * A text field component, that wraps around the native `<input />` element
3445
3434
  * and adds some extra states and information around it (i.e. a text and an error labels,
@@ -3487,7 +3476,7 @@ var TextField = /*#__PURE__*/forwardRef(function (_ref, ref) {
3487
3476
  _ref$darkMode = _ref.darkMode,
3488
3477
  darkMode = _ref$darkMode === void 0 ? false : _ref$darkMode,
3489
3478
  width = _ref.width,
3490
- inputProps = _objectWithoutPropertiesLoose(_ref, _excluded$6);
3479
+ inputProps = _objectWithoutPropertiesLoose(_ref, ["label", "type", "error", "darkMode", "width"]);
3491
3480
 
3492
3481
  var _useState = useState(false),
3493
3482
  showPassword = _useState[0],
@@ -3545,14 +3534,12 @@ var TextLinkWrapper = /*#__PURE__*/styled.a(_templateObject$o || (_templateObjec
3545
3534
  });
3546
3535
  var TextLinkIconWrapper = /*#__PURE__*/styled.span(_templateObject2$c || (_templateObject2$c = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n width: var(--button-icon-width);\n height: var(--button-icon-height);\n margin-left: var(--button-icon-margin);\n"])));
3547
3536
 
3548
- var _excluded$7 = ["children", "iconName", "iconDirection", "color"];
3549
-
3550
3537
  var TextLink = function TextLink(_ref) {
3551
3538
  var children = _ref.children,
3552
3539
  iconName = _ref.iconName,
3553
3540
  iconDirection = _ref.iconDirection,
3554
3541
  color = _ref.color,
3555
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$7);
3542
+ rest = _objectWithoutPropertiesLoose(_ref, ["children", "iconName", "iconDirection", "color"]);
3556
3543
 
3557
3544
  var truncatedString = children.substring(0, 30);
3558
3545
  return /*#__PURE__*/React__default.createElement(TextLinkWrapper, Object.assign({
@@ -5160,8 +5147,6 @@ var ContactNewsletter = function ContactNewsletter(_ref) {
5160
5147
  }, contact.title))));
5161
5148
  };
5162
5149
 
5163
- var _excluded$8 = ["dataRoh"];
5164
-
5165
5150
  var Footer = function Footer(_ref) {
5166
5151
  var data = _ref.data;
5167
5152
  var policyLinks = data.policyLinks;
@@ -5171,7 +5156,7 @@ var Footer = function Footer(_ref) {
5171
5156
 
5172
5157
  var _data$artsLogo = data.artsLogo,
5173
5158
  artsDataRoh = _data$artsLogo.dataRoh,
5174
- artsLogo = _objectWithoutPropertiesLoose(_data$artsLogo, _excluded$8);
5159
+ artsLogo = _objectWithoutPropertiesLoose(_data$artsLogo, ["dataRoh"]);
5175
5160
 
5176
5161
  var additionalInfo = data.additionalInfo;
5177
5162
  return /*#__PURE__*/React__default.createElement(FooterSection, null, /*#__PURE__*/React__default.createElement(Grid, null, /*#__PURE__*/React__default.createElement(GridItem, {
@@ -5226,8 +5211,6 @@ var ArrowsContainer = /*#__PURE__*/styled.div(_templateObject5$9 || (_templateOb
5226
5211
  });
5227
5212
  var ArrowWrapper = /*#__PURE__*/styled.div(_templateObject6$7 || (_templateObject6$7 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n width: 24px;\n height: 24px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: flex-center;\n\n :hover {\n && svg path {\n fill: var(--base-color-primary);\n }\n }\n"])));
5228
5213
 
5229
- var _excluded$9 = ["id", "text"];
5230
-
5231
5214
  var AnchorTabBar = function AnchorTabBar(_ref) {
5232
5215
  var tabs = _ref.tabs,
5233
5216
  onTabClick = _ref.onTabClick,
@@ -5442,7 +5425,7 @@ var AnchorTabBar = function AnchorTabBar(_ref) {
5442
5425
  }, tabs.map(function (_ref4) {
5443
5426
  var id = _ref4.id,
5444
5427
  text = _ref4.text,
5445
- rest = _objectWithoutPropertiesLoose(_ref4, _excluded$9);
5428
+ rest = _objectWithoutPropertiesLoose(_ref4, ["id", "text"]);
5446
5429
 
5447
5430
  return /*#__PURE__*/React__default.createElement("li", {
5448
5431
  key: id
@@ -5498,9 +5481,6 @@ var PrimaryButtonReverse = /*#__PURE__*/styled(PrimaryButton)(_templateObject8$3
5498
5481
  var MessageWrapper = /*#__PURE__*/styled.div(_templateObject9$1 || (_templateObject9$1 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n align-items: center;\n margin-right: var(--grid-outer-margin);\n height: var(--button-height);\n\n h6 {\n margin: 0;\n padding: 0;\n }\n\n @media ", " {\n & {\n margin-right: var(--grid-margin);\n }\n }\n\n @media ", " {\n & {\n display: none;\n }\n }\n"])), devices.tablet, devices.mobile);
5499
5482
  var MessageWrapperMobile = /*#__PURE__*/styled.div(_templateObject10$1 || (_templateObject10$1 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n h6 {\n margin: 0;\n padding: 0;\n }\n display: none;\n\n @media ", " {\n & {\n display: flex;\n align-items: center;\n margin-left: var(--grid-margin);\n padding: 12px 0;\n }\n }\n"])), devices.mobile);
5500
5483
 
5501
- var _excluded$a = ["text"],
5502
- _excluded2 = ["text"];
5503
-
5504
5484
  var TitleWithCTA = function TitleWithCTA(_ref) {
5505
5485
  var title = _ref.title,
5506
5486
  links = _ref.links,
@@ -5510,11 +5490,11 @@ var TitleWithCTA = function TitleWithCTA(_ref) {
5510
5490
 
5511
5491
  var _ref2 = (links == null ? void 0 : links[0]) || {},
5512
5492
  primaryButtonText = _ref2.text,
5513
- primaryButtonProps = _objectWithoutPropertiesLoose(_ref2, _excluded$a);
5493
+ primaryButtonProps = _objectWithoutPropertiesLoose(_ref2, ["text"]);
5514
5494
 
5515
5495
  var _ref3 = (links == null ? void 0 : links[1]) || {},
5516
5496
  secondaryButtonText = _ref3.text,
5517
- secondaryButtonProps = _objectWithoutPropertiesLoose(_ref3, _excluded2);
5497
+ secondaryButtonProps = _objectWithoutPropertiesLoose(_ref3, ["text"]);
5518
5498
 
5519
5499
  return /*#__PURE__*/React__default.createElement(TitleCTAGridWrapper, {
5520
5500
  sticky: sticky
@@ -5790,8 +5770,7 @@ var Accordions = function Accordions(_ref) {
5790
5770
  visibleStandfirst: accordion.visibleStandfirst,
5791
5771
  contentType: accordion.contentType,
5792
5772
  displayLevel: accordion.displayLevel,
5793
- semanticLevel: accordion.semanticLevel,
5794
- initOpen: accordion.initOpen
5773
+ semanticLevel: accordion.semanticLevel
5795
5774
  }, accordion.children);
5796
5775
  }));
5797
5776
  };
@@ -5996,9 +5975,6 @@ var truncateReactNodeString = function truncateReactNodeString(node, resultLengt
5996
5975
  return truncateHtmlString(nodeString, resultLength, addDots);
5997
5976
  };
5998
5977
 
5999
- var _excluded$b = ["text"],
6000
- _excluded2$1 = ["text"];
6001
-
6002
5978
  var _buttonTypeToButton;
6003
5979
  var LENGTH_LARGE_TEXT$1 = 28;
6004
5980
  var LENGTH_SMALL_TEXT$2 = 19;
@@ -6049,7 +6025,7 @@ var Card = function Card(_ref) {
6049
6025
  var _ref2 = firstButton || {},
6050
6026
  _ref2$text = _ref2.text,
6051
6027
  firstButtonText = _ref2$text === void 0 ? '' : _ref2$text,
6052
- restFirstButton = _objectWithoutPropertiesLoose(_ref2, _excluded$b);
6028
+ restFirstButton = _objectWithoutPropertiesLoose(_ref2, ["text"]);
6053
6029
 
6054
6030
  var primaryButtonTextTruncate = size === 'small' ? truncate(firstButtonText, LENGTH_SMALL_TEXT$2) : truncate(firstButtonText, LENGTH_LARGE_TEXT$1);
6055
6031
  var secondButton = links == null ? void 0 : links[1];
@@ -6057,7 +6033,7 @@ var Card = function Card(_ref) {
6057
6033
  var _ref3 = secondButton || {},
6058
6034
  _ref3$text = _ref3.text,
6059
6035
  secondButtonText = _ref3$text === void 0 ? '' : _ref3$text,
6060
- restSecondButton = _objectWithoutPropertiesLoose(_ref3, _excluded2$1);
6036
+ restSecondButton = _objectWithoutPropertiesLoose(_ref3, ["text"]);
6061
6037
 
6062
6038
  var tertiaryButtonTextTruncate = size === 'small' ? truncate(secondButtonText, LENGTH_SMALL_TEXT$2) : truncate(secondButtonText, LENGTH_LARGE_TEXT$1);
6063
6039
 
@@ -6561,8 +6537,6 @@ var LogoWrapper$2 = /*#__PURE__*/styled.div(_templateObject6$c || (_templateObje
6561
6537
  var ButtonWrapper$1 = /*#__PURE__*/styled.div(_templateObject7$9 || (_templateObject7$9 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n grid-area: button;\n justify-self: end;\n align-self: end;\n\n @media ", " {\n & {\n justify-self: center;\n align-self: center;\n width: 100%;\n margin-top: 16px;\n }\n }\n"])), devices.mobile);
6562
6538
  var PageHeadingText = /*#__PURE__*/styled.div(_templateObject8$6 || (_templateObject8$6 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n font-size: var(--font-size-altHeader-6);\n font-weight: var(--font-weight-altHeader-6);\n letter-spacing: var(--letter-spacing-altHeader-6);\n line-height: var(--line-height-altHeader-6);\n font-feature-settings: var(--font-feature-settings-altHeader);\n font-family: var(--font-family-altHeader);\n text-transform: var(--text-transform-altHeader);\n word-break: var(--word-break-altHeader);\n"])));
6563
6539
 
6564
- var _excluded$c = ["text"];
6565
-
6566
6540
  var PageHeading = function PageHeading(_ref) {
6567
6541
  var title = _ref.title,
6568
6542
  text = _ref.text,
@@ -6573,7 +6547,7 @@ var PageHeading = function PageHeading(_ref) {
6573
6547
 
6574
6548
  var _ref2 = link || {},
6575
6549
  linkText = _ref2.text,
6576
- restLink = _objectWithoutPropertiesLoose(_ref2, _excluded$c);
6550
+ restLink = _objectWithoutPropertiesLoose(_ref2, ["text"]);
6577
6551
 
6578
6552
  var truncatedText = text == null ? void 0 : text.substring(0, 250);
6579
6553
  var truncatedTitle = title && title.substring(0, 40);
@@ -6601,11 +6575,9 @@ var PageHeading = function PageHeading(_ref) {
6601
6575
  }, /*#__PURE__*/React__default.createElement(PrimaryButton, Object.assign({}, restLink), linkText)) : null));
6602
6576
  };
6603
6577
 
6604
- var _excluded$d = ["link"];
6605
-
6606
6578
  var PageHeadingCore = function PageHeadingCore(_ref) {
6607
6579
  var link = _ref.link,
6608
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$d);
6580
+ rest = _objectWithoutPropertiesLoose(_ref, ["link"]);
6609
6581
 
6610
6582
  var coreLink = link && _extends({}, link, {
6611
6583
  color: Colors.White,
@@ -6619,11 +6591,9 @@ var PageHeadingCore = function PageHeadingCore(_ref) {
6619
6591
  })));
6620
6592
  };
6621
6593
 
6622
- var _excluded$e = ["link"];
6623
-
6624
6594
  var PageHeadingCinema = function PageHeadingCinema(_ref) {
6625
6595
  var link = _ref.link,
6626
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$e);
6596
+ rest = _objectWithoutPropertiesLoose(_ref, ["link"]);
6627
6597
 
6628
6598
  var cinemaLink = link && _extends({}, link, {
6629
6599
  color: Colors.Black,
@@ -6647,8 +6617,6 @@ var TextWrapper$1 = /*#__PURE__*/styled.div(_templateObject6$d || (_templateObje
6647
6617
  var ButtonWrapper$2 = /*#__PURE__*/styled.div(_templateObject7$a || (_templateObject7$a = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n grid-area: button;\n align-self: end;\n display: flex;\n justify-content: center;\n margin-top: 40px;\n\n @media ", " {\n & {\n margin-top: 0px;\n margin-bottom: 20px;\n }\n }\n"])), devices.mobile);
6648
6618
  var ScrollDownWrapper = /*#__PURE__*/styled.div(_templateObject8$7 || (_templateObject8$7 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n position: absolute;\n bottom: 20px;\n left: var(--grid-outer-margin);\n width: fit-content;\n z-index: ", ";\n\n @keyframes UpDown {\n 0%,\n 100% {\n transform: translateY(0);\n }\n 50% {\n transform: translateY(8px);\n }\n }\n\n a {\n font-size: var(--font-size-overline-1);\n font-weight: var(--font-weight-overline-1);\n letter-spacing: var(--letter-spacing-overline-1);\n border: none;\n padding: 0;\n :hover {\n border: none;\n\n > span {\n animation: UpDown 1500ms linear infinite;\n }\n }\n }\n\n @media ", " {\n & {\n display: none;\n }\n }\n\n @media ", " {\n & {\n display: none;\n }\n }\n"])), zIndexes.contentOverlay, devices.mobile, devices.tablet);
6649
6619
 
6650
- var _excluded$f = ["text"];
6651
-
6652
6620
  var PageHeadingImpact = function PageHeadingImpact(_ref) {
6653
6621
  var children = _ref.children,
6654
6622
  text = _ref.text,
@@ -6665,7 +6633,7 @@ var PageHeadingImpact = function PageHeadingImpact(_ref) {
6665
6633
 
6666
6634
  var _ref2 = link || {},
6667
6635
  linkText = _ref2.text,
6668
- restLink = _objectWithoutPropertiesLoose(_ref2, _excluded$f);
6636
+ restLink = _objectWithoutPropertiesLoose(_ref2, ["text"]);
6669
6637
 
6670
6638
  return /*#__PURE__*/React__default.createElement(ImpactWrapper, {
6671
6639
  bgUrlDesktop: bgUrlDesktop,
@@ -6758,11 +6726,9 @@ var PageHeadingPanel = function PageHeadingPanel(_ref) {
6758
6726
  var _templateObject$W;
6759
6727
  var StreamWrapper = /*#__PURE__*/styled.div(_templateObject$W || (_templateObject$W = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n h2::selection,\n div::selection {\n color: #1866dc;\n background-color: #fff;\n }\n"])));
6760
6728
 
6761
- var _excluded$g = ["link"];
6762
-
6763
6729
  var PageHeadingStream = function PageHeadingStream(_ref) {
6764
6730
  var link = _ref.link,
6765
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$g);
6731
+ rest = _objectWithoutPropertiesLoose(_ref, ["link"]);
6766
6732
 
6767
6733
  var streamLink = link && _extends({}, link, {
6768
6734
  color: Colors.Black,
@@ -6911,7 +6877,7 @@ var CompactHeaderBranding = function CompactHeaderBranding(_ref) {
6911
6877
  var isIOS = function isIOS() {
6912
6878
  try {
6913
6879
  console.warn('Do not use this on server side rendering, it may throw an error.');
6914
- if (typeof navigator === 'undefined') return false;
6880
+ if (typeof navigator === undefined) return false;
6915
6881
  return ['iPad Simulator', 'iPhone Simulator', 'iPod Simulator', 'iPad', 'iPhone', 'iPod'].includes(navigator.platform) || // iPad on iOS 13 detection
6916
6882
  navigator.userAgent.includes('Mac') && 'ontouchend' in document;
6917
6883
  } catch (e) {
@@ -6927,7 +6893,7 @@ var useIOS = function useIOS() {
6927
6893
  setIOS = _useState[1];
6928
6894
 
6929
6895
  useEffect(function () {
6930
- if (typeof navigator === 'undefined') return;
6896
+ if (typeof navigator === undefined) return;
6931
6897
  setIOS(isIOS());
6932
6898
  }, []);
6933
6899
  return IOS;
@@ -6956,8 +6922,6 @@ var useMobile = function useMobile() {
6956
6922
  return mobile;
6957
6923
  };
6958
6924
 
6959
- var _excluded$h = ["text"];
6960
-
6961
6925
  var useResponsiveVideo = function useResponsiveVideo(video, poster) {
6962
6926
  var mobileVideo = video.mobile || video.desktop;
6963
6927
  var desktopVideo = video.desktop || video.mobile;
@@ -7072,7 +7036,7 @@ var PageHeadingCompact = function PageHeadingCompact(_ref4) {
7072
7036
 
7073
7037
  var _ref5 = link || {},
7074
7038
  linkText = _ref5.text,
7075
- restLink = _objectWithoutPropertiesLoose(_ref5, _excluded$h);
7039
+ restLink = _objectWithoutPropertiesLoose(_ref5, ["text"]);
7076
7040
 
7077
7041
  var titleSize = title && title.length > 20 ? 4 : 3;
7078
7042
  var video = {
@@ -7248,8 +7212,8 @@ var PeopleListing = function PeopleListing(_ref) {
7248
7212
  var _templateObject$_, _templateObject2$I, _templateObject3$A, _templateObject4$s;
7249
7213
  var ReplacementWrapper = /*#__PURE__*/styled.div(_templateObject$_ || (_templateObject$_ = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: var(--base-color-darkgrey);\n"])));
7250
7214
  var CreditListingWrapper = /*#__PURE__*/styled(PeopleListingGrid)(_templateObject2$I || (_templateObject2$I = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n p {\n line-height: 1.5;\n }\n"])));
7251
- var DescriptionWrapper = /*#__PURE__*/styled.div(_templateObject3$A || (_templateObject3$A = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: var(--base-color-darkgrey);\n p {\n line-height: 1.5;\n margin-bottom: 4px;\n }\n"])));
7252
- var RoleWrapper$1 = /*#__PURE__*/styled.div(_templateObject4$s || (_templateObject4$s = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: var(--base-color-darkgrey);\n overflow-wrap: break-word;\n"])));
7215
+ var DescriptionWrapper = /*#__PURE__*/styled.div(_templateObject3$A || (_templateObject3$A = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: var(--base-color-darkgrey);\n p {\n line-height: 25px;\n margin-bottom: 3px;\n }\n"])));
7216
+ var RoleWrapper$1 = /*#__PURE__*/styled.div(_templateObject4$s || (_templateObject4$s = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: var(--base-color-darkgrey);\n overflow-wrap: break-word;\n min-height: 1.5em;\n"])));
7253
7217
 
7254
7218
  var getConcatenatedPropLength = function getConcatenatedPropLength(array, prop) {
7255
7219
  return array.reduce(function (acc, item) {
@@ -7260,18 +7224,12 @@ var getConcatenatedPropLength = function getConcatenatedPropLength(array, prop)
7260
7224
  var concatenateMusicTitle = function concatenateMusicTitle(musicTitle) {
7261
7225
  return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, musicTitle.map(function (title, index) {
7262
7226
  if (musicTitle.length > 1 && index === musicTitle.length - 1) {
7263
- return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, ' ', "and ", /*#__PURE__*/React__default.createElement("i", {
7264
- key: index
7265
- }, title));
7227
+ return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, ' ', "and ", /*#__PURE__*/React__default.createElement("i", null, title));
7266
7228
  } else if (index > 0) {
7267
- return /*#__PURE__*/React__default.createElement("i", {
7268
- key: index
7269
- }, ", ", title);
7229
+ return /*#__PURE__*/React__default.createElement("i", null, ", ", title);
7270
7230
  }
7271
7231
 
7272
- return /*#__PURE__*/React__default.createElement("i", {
7273
- key: index
7274
- }, title);
7232
+ return /*#__PURE__*/React__default.createElement("i", null, title);
7275
7233
  }));
7276
7234
  };
7277
7235
 
@@ -7412,10 +7370,6 @@ var PromoWithTagsContainer = /*#__PURE__*/styled.div(_templateObject19 || (_temp
7412
7370
  var TimerWrapper$1 = /*#__PURE__*/styled.div(_templateObject20 || (_templateObject20 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin-bottom: 32px;\n"])));
7413
7371
  var EndDateText = /*#__PURE__*/styled.div(_templateObject21 || (_templateObject21 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n border-bottom: 1px solid var(--base-color-black);\n padding-bottom: 32px;\n margin-bottom: 32px;\n\n @media ", " {\n padding-bottom: 20px;\n margin-bottom: 20px;\n }\n"])), devices.mobile);
7414
7372
 
7415
- var _excluded$i = ["text"],
7416
- _excluded2$2 = ["text"],
7417
- _excluded3 = ["text"];
7418
-
7419
7373
  var _buttonTypeToButton$1;
7420
7374
  var LENGTH_TEXT$1 = 28;
7421
7375
  var LENGTH_TEXT_PARAGRAPH = 130;
@@ -7486,7 +7440,7 @@ var PromoWithTags = function PromoWithTags(_ref) {
7486
7440
  var _ref2 = firstButton || {},
7487
7441
  _ref2$text = _ref2.text,
7488
7442
  firstButtonText = _ref2$text === void 0 ? '' : _ref2$text,
7489
- restFirstButton = _objectWithoutPropertiesLoose(_ref2, _excluded$i);
7443
+ restFirstButton = _objectWithoutPropertiesLoose(_ref2, ["text"]);
7490
7444
 
7491
7445
  var primaryButtonTextTruncate = truncate(firstButtonText, LENGTH_TEXT$1);
7492
7446
  var secondButton = links == null ? void 0 : links[1];
@@ -7494,7 +7448,7 @@ var PromoWithTags = function PromoWithTags(_ref) {
7494
7448
  var _ref3 = secondButton || {},
7495
7449
  _ref3$text = _ref3.text,
7496
7450
  secondButtonText = _ref3$text === void 0 ? '' : _ref3$text,
7497
- restSecondButton = _objectWithoutPropertiesLoose(_ref3, _excluded2$2);
7451
+ restSecondButton = _objectWithoutPropertiesLoose(_ref3, ["text"]);
7498
7452
 
7499
7453
  var secondButtonTextTruncate = truncate(secondButtonText, LENGTH_TEXT$1);
7500
7454
  var textTruncate = asCard ? truncate(text || '', LENGTH_TEXT_PARAGRAPH) : text;
@@ -7503,7 +7457,7 @@ var PromoWithTags = function PromoWithTags(_ref) {
7503
7457
  var textLinkItems = textLinks ? textLinks.map(function (link, index) {
7504
7458
  var _link$text = link.text,
7505
7459
  textLinkText = _link$text === void 0 ? '' : _link$text,
7506
- restTextLink = _objectWithoutPropertiesLoose(link, _excluded3);
7460
+ restTextLink = _objectWithoutPropertiesLoose(link, ["text"]);
7507
7461
 
7508
7462
  return /*#__PURE__*/React__default.createElement(TextLinkWrapper$2, {
7509
7463
  key: index
@@ -7661,8 +7615,6 @@ var ButtonsContainer$3 = /*#__PURE__*/styled.div(_templateObject7$d || (_templat
7661
7615
  return '';
7662
7616
  });
7663
7617
 
7664
- var _excluded$j = ["text"],
7665
- _excluded2$3 = ["text"];
7666
7618
  var LENGTH_TEXT$3 = 28;
7667
7619
 
7668
7620
  var PromoWithTitle = function PromoWithTitle(_ref) {
@@ -7688,7 +7640,7 @@ var PromoWithTitle = function PromoWithTitle(_ref) {
7688
7640
  var _ref2 = primaryButton || {},
7689
7641
  _ref2$text = _ref2.text,
7690
7642
  primaryButtonText = _ref2$text === void 0 ? '' : _ref2$text,
7691
- restPrimaryButton = _objectWithoutPropertiesLoose(_ref2, _excluded$j);
7643
+ restPrimaryButton = _objectWithoutPropertiesLoose(_ref2, ["text"]);
7692
7644
 
7693
7645
  var primaryButtonTextTruncate = truncate(primaryButtonText, LENGTH_TEXT$3);
7694
7646
  var tertiaryButton = links == null ? void 0 : links[1];
@@ -7696,7 +7648,7 @@ var PromoWithTitle = function PromoWithTitle(_ref) {
7696
7648
  var _ref3 = tertiaryButton || {},
7697
7649
  _ref3$text = _ref3.text,
7698
7650
  tertiaryButtonText = _ref3$text === void 0 ? '' : _ref3$text,
7699
- restTertiaryButton = _objectWithoutPropertiesLoose(_ref3, _excluded2$3);
7651
+ restTertiaryButton = _objectWithoutPropertiesLoose(_ref3, ["text"]);
7700
7652
 
7701
7653
  var tertiaryButtonTextTruncate = truncate(tertiaryButtonText, LENGTH_TEXT$3);
7702
7654
  return /*#__PURE__*/React__default.createElement(PromoWithTitleGrid, {
@@ -7869,426 +7821,72 @@ var SectionTitle = function SectionTitle(_ref) {
7869
7821
  }, description))));
7870
7822
  };
7871
7823
 
7872
- var _templateObject$14, _templateObject2$M, _templateObject3$E, _templateObject4$v, _templateObject5$n, _templateObject6$i, _templateObject7$e, _templateObject8$a, _templateObject9$5, _templateObject10$5, _templateObject11$3;
7873
- var stateStyles = /*#__PURE__*/css(_templateObject$14 || (_templateObject$14 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n &:focus,\n &.focus {\n outline: ", ";\n }\n\n &.disabled {\n background-color: ", ";\n color: ", ";\n pointer-events: none;\n cursor: none;\n }\n"])), function (_ref) {
7874
- var theme = _ref.theme;
7875
- return "3px solid " + theme.colors.lapisLazuli;
7824
+ var _templateObject$14, _templateObject2$M, _templateObject3$E, _templateObject4$v;
7825
+ var Container$1 = /*#__PURE__*/styled.div(_templateObject$14 || (_templateObject$14 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: column;\n"])));
7826
+ var SelectWrapper = /*#__PURE__*/styled.div(_templateObject2$M || (_templateObject2$M = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n position: relative;\n width: auto;\n max-width: ", ";\n\n .chord-select__control {\n min-height: 48px;\n border-radius: 0;\n border: ", ";\n &:hover {\n border-color: ", ";\n }\n }\n .chord-select__control--is-focused {\n border-color: var(--base-color-darkgrey);\n box-shadow: ", ";\n }\n .chord-select__indicator-separator {\n display: none;\n }\n .chord-select__control--menu-is-open {\n .chord-select__indicator {\n svg {\n transform: rotate(180deg);\n }\n }\n }\n .chord-select__indicator {\n font-size: 25px;\n padding: 0;\n margin-right: 12px;\n color: var(--base-color-black);\n svg {\n height: 1em;\n width: 1em;\n color: inherit;\n path {\n fill: currentColor;\n color: inherit;\n }\n }\n }\n .chord-select__single-value,\n .chord-select__placeholder {\n margin-left: 0;\n margin-right: 0;\n font-family: var(--font-family-altHeader);\n font-feature-settings: var(--font-feature-settings-altHeader);\n font-size: var(--font-size-altHeader-6);\n font-weight: var(--font-weight-altHeader-6);\n letter-spacing: var(--letter-spacing-altHeader-6);\n line-height: var(--line-height-altHeader-6);\n text-transform: var(--text-transform-altHeader);\n }\n .chord-select__placeholder {\n color: var(--base-color-darkgrey);\n }\n .chord-select__single-value {\n color: var(--base-color-black);\n }\n .chord-select__value-container {\n padding-left: 20px;\n padding-right: 15px;\n padding-top: 1px;\n padding-bottom: 0px;\n }\n .chord-select--is-disabled {\n .chord-select__control {\n border: 1px solid var(--base-color-lightgrey);\n background: var(--base-color-lightgrey);\n }\n .chord-select__indicator,\n .chord-select__single-value {\n color: var(--base-color-darkgrey);\n }\n }\n .chord-select__menu {\n margin-top: -1px;\n box-shadow: none;\n border-radius: 0;\n border: 1px solid var(--base-color-darkgrey);\n background: var(--base-color-lightgrey);\n }\n .chord-select__menu-list {\n padding-top: 0;\n padding-bottom: 0;\n }\n .chord-select__option {\n padding: 10px 20px;\n font-family: var(--font-family-altHeader);\n font-feature-settings: var(--font-feature-settings-altHeader);\n font-size: var(--font-size-altHeader-6);\n font-weight: var(--font-weight-altHeader-6);\n letter-spacing: var(--letter-spacing-altHeader-6);\n line-height: var(--line-height-altHeader-6);\n text-transform: var(--text-transform-altHeader);\n color: var(--base-color-black);\n &:active,\n &.chord-select__option--is-focused {\n background: var(--base-color-midgrey);\n }\n }\n .chord-select__option--is-selected {\n color: var(--base-color-black);\n background: none;\n }\n .chord-select__input-container {\n margin: 0;\n padding-top: 0;\n padding-bottom: 0;\n font-family: var(--font-family-altHeader);\n font-feature-settings: var(--font-feature-settings-altHeader);\n font-size: var(--font-size-altHeader-6);\n font-weight: var(--font-weight-altHeader-6);\n letter-spacing: var(--letter-spacing-altHeader-6);\n line-height: var(--line-height-altHeader-6);\n text-transform: var(--text-transform-altHeader);\n color: var(--base-color-black);\n }\n .chord-select__menu-notice {\n font-family: var(--font-family-altHeader);\n font-feature-settings: var(--font-feature-settings-altHeader);\n font-size: var(--font-size-altHeader-6);\n font-weight: var(--font-weight-altHeader-6);\n letter-spacing: var(--letter-spacing-altHeader-6);\n line-height: var(--line-height-altHeader-6);\n text-transform: var(--text-transform-altHeader);\n color: var(--base-color-darkgrey);\n padding: 10px 20px;\n text-align: left;\n }\n .chord-select__group-heading {\n padding: 0 20px;\n text-transform: none;\n font-family: var(--font-family-body);\n font-feature-settings: var(--font-feature-settings-body);\n font-size: var(--font-size-body-2);\n font-weight: var(--font-weight-body-2);\n color: var(--base-color-darkgrey);\n &:not(:empty) {\n margin-bottom: 5px;\n }\n }\n .chord-select__group {\n padding-top: 0;\n padding-bottom: 10px;\n &:last-child {\n padding-bottom: 0;\n }\n }\n"])), function (_ref) {
7827
+ var width = _ref.width;
7828
+ if (!width) return 'none';
7829
+ return width + 'px';
7876
7830
  }, function (_ref2) {
7877
- var theme = _ref2.theme;
7878
- return theme.colors.lightgrey;
7831
+ var error = _ref2.error;
7832
+ if (error !== undefined) return "1px solid var(--base-color-errorstate)";
7833
+ return "1px solid var(--base-color-darkgrey)";
7879
7834
  }, function (_ref3) {
7880
- var theme = _ref3.theme;
7881
- return theme.colors.lightgrey;
7835
+ var error = _ref3.error;
7836
+ if (error !== undefined) return "var(--base-color-errorstate)";
7837
+ return "var(--base-color-darkgrey)";
7838
+ }, function (_ref4) {
7839
+ var darkMode = _ref4.darkMode;
7840
+ if (darkMode) return "0 0 0 4px var(--base-color-lemonchiffon)";
7841
+ return "0 0 0 3px var(--base-color-lapislazuli)";
7882
7842
  });
7883
- var borderStyles = /*#__PURE__*/css(_templateObject2$M || (_templateObject2$M = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n border-radius: 0;\n outline: 1px solid ", ";\n"])), function (_ref4) {
7884
- var theme = _ref4.theme;
7885
- return theme.colors.darkgrey;
7843
+ var TextLabel$1 = /*#__PURE__*/styled.p(_templateObject3$E || (_templateObject3$E = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin: 0 0 20px;\n color: ", ";\n"])), function (_ref5) {
7844
+ var darkMode = _ref5.darkMode;
7845
+ if (darkMode) return "var(--base-color-white)";
7846
+ return "var(--base-color-black)";
7847
+ });
7848
+ var ErrorLabel$1 = /*#__PURE__*/styled.p(_templateObject4$v || (_templateObject4$v = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin: 20px 0 0;\n color: ", ";\n"])), function (_ref6) {
7849
+ var darkMode = _ref6.darkMode;
7850
+ if (darkMode) return "var(--base-color-white)";
7851
+ return "var(--base-color-errorstate)";
7886
7852
  });
7887
- var noMarginAndPaddingStyles = /*#__PURE__*/css(_templateObject3$E || (_templateObject3$E = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin: 0;\n padding: 0;\n"])));
7888
- var listItemStyles = /*#__PURE__*/css(_templateObject4$v || (_templateObject4$v = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n list-style: none;\n user-select: none;\n"])));
7889
- var ArrowIcon = /*#__PURE__*/styled(Icon).attrs(function (_ref5) {
7890
- var theme = _ref5.theme;
7891
- return {
7892
- iconName: 'DropdownArrow',
7893
- color: theme.colors.black,
7894
- title: 'Select Arrow'
7895
- };
7896
- })(_templateObject5$n || (_templateObject5$n = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n pointer-events: none;\n\n max-width: 24px;\n max-height: 24px;\n\n svg {\n width: 24px;\n height: 24px;\n }\n"])));
7897
- var Wrapper$5 = /*#__PURE__*/styled.div(_templateObject6$i || (_templateObject6$i = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n ", "\n height: initial;\n\n display: flex;\n flex-direction: column;\n gap: 20px;\n"])), noMarginAndPaddingStyles);
7898
- var SelectWrapper = /*#__PURE__*/styled.div(_templateObject7$e || (_templateObject7$e = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n ", "\n height: inherit;\n"])), noMarginAndPaddingStyles);
7899
- var Options = /*#__PURE__*/styled.div(_templateObject8$a || (_templateObject8$a = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n z-index: 1;\n\n ", "\n ", "\n"])), noMarginAndPaddingStyles, borderStyles);
7900
- var Option = /*#__PURE__*/styled.li(_templateObject9$5 || (_templateObject9$5 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n ", "\n ", "\n\n ", "\n"])), noMarginAndPaddingStyles, listItemStyles, function (_ref6) {
7901
- var theme = _ref6.theme,
7902
- hover = _ref6.hover;
7903
- var _theme$colors = theme.colors,
7904
- lightgrey = _theme$colors.lightgrey,
7905
- midgrey = _theme$colors.midgrey;
7906
- if (hover) return "background-color: " + midgrey;
7907
- return "\n background-color: " + lightgrey + ";\n &:hover { background-color: " + midgrey + " }\n ";
7908
- });
7909
-
7910
- var selectStyles = function selectStyles(width, height) {
7911
- return css(_templateObject10$5 || (_templateObject10$5 = _taggedTemplateLiteralLoose(["\n position: relative;\n z-index: ", ";\n\n width: ", ";\n height: ", ";\n\n * {\n width: ", ";\n }\n\n ", " {\n position: absolute;\n top: ", ";\n }\n ", " {\n height: ", ";\n }\n p {\n height: ", ";\n padding-inline: 20px;\n\n display: flex;\n align-items: center;\n }\n"])), zIndexes[3], width, height, width, Options, height, Option, height, height);
7912
- };
7913
-
7914
- var SelectList = /*#__PURE__*/styled.ul(_templateObject11$3 || (_templateObject11$3 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n ", "\n\n ", "\n ", "\n ", "\n ", "\n\n & ", " {\n position: absolute;\n\n top: 13px;\n right: 16px;\n }\n"])), function (_ref7) {
7915
- var width = _ref7.width,
7916
- height = _ref7.height;
7917
- return selectStyles(width === 'default' ? "354px" : width + "px", height === 'default' ? "48px" : height + "px");
7918
- }, stateStyles, noMarginAndPaddingStyles, listItemStyles, borderStyles, ArrowIcon);
7919
-
7920
- var useKeyboardAccessibility = function useKeyboardAccessibility(_ref) {
7921
- var selectRef = _ref.selectRef,
7922
- optionsRef = _ref.optionsRef,
7923
- shouldHighlightOption = _ref.shouldHighlightOption;
7924
-
7925
- var _useState = useState(-1),
7926
- itemToHighlight = _useState[0],
7927
- setItemToHighlight = _useState[1];
7928
-
7929
- var clampIndex = function clampIndex(index) {
7930
- if (index < -1) return -1;
7931
- if (index > optionsRef.current.length - 1) return optionsRef.current.length - 1;
7932
- return index;
7933
- };
7934
-
7935
- var highlightNextOption = function highlightNextOption() {
7936
- return setItemToHighlight(function (prev) {
7937
- return clampIndex(prev + 1);
7938
- });
7939
- };
7940
-
7941
- var highlightPrevOption = function highlightPrevOption() {
7942
- return setItemToHighlight(function (prev) {
7943
- return clampIndex(prev - 1);
7944
- });
7945
- };
7946
-
7947
- var reset = function reset() {
7948
- var _selectRef$current;
7949
-
7950
- (_selectRef$current = selectRef.current) == null ? void 0 : _selectRef$current.blur();
7951
- setItemToHighlight(-1);
7952
- };
7953
-
7954
- var handleKeyUp = function handleKeyUp(event) {
7955
- if (!shouldHighlightOption) return;
7956
- var shouldHighlightOptionNext = event.key === 'ArrowDown';
7957
- var shouldHighlightOptionPrev = event.key === 'ArrowUp';
7958
- if (shouldHighlightOptionNext) return highlightNextOption();
7959
- if (shouldHighlightOptionPrev) return highlightPrevOption();
7960
- };
7961
-
7962
- var preventScrollingWhileNavigating = function preventScrollingWhileNavigating(event) {
7963
- if (!shouldHighlightOption) return;
7964
- if (!['ArrowDown', 'ArrowUp'].includes(event.key)) return;
7965
- event.preventDefault();
7966
- };
7967
-
7968
- var handleHighlighted = function handleHighlighted(cb) {
7969
- return function (event) {
7970
- if (itemToHighlight === -1) return;
7971
- if (event.key !== 'Enter') return;
7972
- cb(itemToHighlight);
7973
- reset();
7974
- };
7975
- };
7976
-
7977
- useEffect(function () {
7978
- if (shouldHighlightOption) return;
7979
- reset();
7980
- }, [shouldHighlightOption]);
7981
- return {
7982
- handleKeyUp: handleKeyUp,
7983
- preventScrollingWhileNavigating: preventScrollingWhileNavigating,
7984
- handleHighlighted: handleHighlighted,
7985
- itemToHighlight: itemToHighlight
7986
- };
7987
- };
7988
-
7989
- var useVisualAccessibility = function useVisualAccessibility(_ref2) {
7990
- var selectRef = _ref2.selectRef,
7991
- isSelectDisabled = _ref2.isSelectDisabled;
7992
-
7993
- var addFocusClass = function addFocusClass() {
7994
- var _selectRef$current2;
7995
-
7996
- (_selectRef$current2 = selectRef.current) == null ? void 0 : _selectRef$current2.classList.add('focus');
7997
- };
7998
-
7999
- var removeFocusClass = function removeFocusClass() {
8000
- var _selectRef$current3;
8001
-
8002
- (_selectRef$current3 = selectRef.current) == null ? void 0 : _selectRef$current3.classList.remove('focus');
8003
- };
8004
-
8005
- var toggleFocus = function toggleFocus() {
8006
- var _selectRef$current4;
8007
-
8008
- if ((_selectRef$current4 = selectRef.current) != null && _selectRef$current4.classList.contains('focus')) removeFocusClass();else addFocusClass();
8009
- };
8010
-
8011
- var withClickAwayHandler = function withClickAwayHandler(cb) {
8012
- return function (event) {
8013
- if (!selectRef.current) return;
8014
- if (selectRef.current.contains(event.target)) return;
8015
- removeFocusClass();
8016
- cb();
8017
- };
8018
- };
8019
-
8020
- useEffect(function () {
8021
- if (!selectRef.current) return;
8022
-
8023
- if (isSelectDisabled) {
8024
- selectRef.current.classList.add('disabled');
8025
- } else selectRef.current.classList.remove('disabled');
8026
- }, [isSelectDisabled]);
8027
- return {
8028
- withClickAwayHandler: withClickAwayHandler,
8029
- toggleFocus: toggleFocus,
8030
- addFocusClass: addFocusClass,
8031
- removeFocusClass: removeFocusClass
8032
- };
8033
- };
8034
-
8035
- var useAccessibility = function useAccessibility(props) {
8036
- var selectRef = props.selectRef;
8037
-
8038
- var _useKeyboardAccessibi = useKeyboardAccessibility(props),
8039
- handleKeyUp = _useKeyboardAccessibi.handleKeyUp,
8040
- preventScrollingWhileNavigating = _useKeyboardAccessibi.preventScrollingWhileNavigating,
8041
- handleHighlighted = _useKeyboardAccessibi.handleHighlighted,
8042
- itemToHighlight = _useKeyboardAccessibi.itemToHighlight;
8043
-
8044
- var _useVisualAccessibili = useVisualAccessibility(props),
8045
- addFocusClass = _useVisualAccessibili.addFocusClass,
8046
- removeFocusClass = _useVisualAccessibili.removeFocusClass,
8047
- toggleFocus = _useVisualAccessibili.toggleFocus,
8048
- withClickAwayHandler = _useVisualAccessibili.withClickAwayHandler;
8049
-
8050
- useEffect(function () {
8051
- if (!selectRef.current) return;
8052
- selectRef.current.addEventListener('keydown', preventScrollingWhileNavigating);
8053
- selectRef.current.addEventListener('keyup', handleKeyUp);
8054
- selectRef.current.addEventListener('click', toggleFocus);
8055
- selectRef.current.addEventListener('focus', addFocusClass);
8056
- selectRef.current.addEventListener('blur', removeFocusClass);
8057
- return function () {
8058
- var _selectRef$current5, _selectRef$current6, _selectRef$current7, _selectRef$current8, _selectRef$current9;
8059
7853
 
8060
- (_selectRef$current5 = selectRef.current) == null ? void 0 : _selectRef$current5.removeEventListener('keydown', preventScrollingWhileNavigating);
8061
- (_selectRef$current6 = selectRef.current) == null ? void 0 : _selectRef$current6.removeEventListener('keyup', handleKeyUp);
8062
- (_selectRef$current7 = selectRef.current) == null ? void 0 : _selectRef$current7.removeEventListener('click', toggleFocus);
8063
- (_selectRef$current8 = selectRef.current) == null ? void 0 : _selectRef$current8.removeEventListener('focus', addFocusClass);
8064
- (_selectRef$current9 = selectRef.current) == null ? void 0 : _selectRef$current9.removeEventListener('blur', removeFocusClass);
8065
- };
8066
- });
8067
- return {
8068
- withClickAwayHandler: withClickAwayHandler,
8069
- handleHighlighted: handleHighlighted,
8070
- itemToHighlight: itemToHighlight
8071
- };
7854
+ var DropdownIndicator = function DropdownIndicator(props) {
7855
+ return /*#__PURE__*/React__default.createElement(components.DropdownIndicator, Object.assign({}, props), /*#__PURE__*/React__default.createElement(Icon, {
7856
+ iconName: 'DropdownArrow'
7857
+ }));
8072
7858
  };
8073
- /**
8074
- * A select component, created using <ul> and <li> elements, with bespoke accessibility
8075
- * logic.
8076
- *
8077
- * # Usage
8078
- * ## Defining a component that uses a typical Select element
8079
- * ```tsx
8080
- * const MyComponent = () => {
8081
- * const handleSelect = (value: number, text: string) => {
8082
- * console.log("Selected", value);
8083
- * };
8084
- *
8085
- * return <>
8086
- * <Select
8087
- * label="This is a label"
8088
- * options={[
8089
- * { text: "Option 1", value: 1 },
8090
- * { text: "Option 2", value: 2 },
8091
- * ]}
8092
- * onSelect={handleSelect}
8093
- * />
8094
- * </>
8095
- * }
8096
- * ```
8097
- *
8098
- * ## Defining a component that uses a disabled Select element
8099
- * ```tsx
8100
- * const MyComponent = () => {
8101
- * const handleSelect = (value: number, text: string) => {
8102
- * console.log("Selected", value);
8103
- * };
8104
- *
8105
- * return <>
8106
- * <Select
8107
- * disabled // Select component disabled explicitely
8108
- * label="This is a label"
8109
- * options={[
8110
- * { text: "Option 1", value: 1 },
8111
- * { text: "Option 2", value: 2 },
8112
- * ]}
8113
- * onSelect={handleSelect}
8114
- * />
8115
- * <Select
8116
- * label="This is a label"
8117
- * options={[]} // Select component disabled implicitely by passing an empty array of options
8118
- * onSelect={handleSelect}
8119
- * />
8120
- * </>
8121
- * }
8122
- * ```
8123
- *
8124
- * ## Defining a component with a non-labelled Select element
8125
- * ```tsx
8126
- * const MyComponent = () => {
8127
- * const handleSelect = (value: number, text: string) => {
8128
- * console.log("Selected", value);
8129
- * };
8130
- *
8131
- * return <>
8132
- * <Select
8133
- * label=""
8134
- * options={[
8135
- * { text: "Option 1", value: 1 },
8136
- * { text: "Option 2", value: 2 },
8137
- * ]}
8138
- * onSelect={handleSelect}
8139
- * />
8140
- * </>
8141
- * }
8142
- * ```
8143
- *
8144
- * ## Changing the dimensions of a Select element (px)
8145
- * ```tsx
8146
- * const MyComponent = () => {
8147
- * const handleSelect = (value: number, text: string) => {
8148
- * console.log("Selected", value);
8149
- * };
8150
- *
8151
- * const selectWidthPx = 100;
8152
- * const selectHeightPx = 27;
8153
- *
8154
- * return <>
8155
- * <Select
8156
- * label="This is a label"
8157
- * options={[
8158
- * { text: "Option 1", value: 1 },
8159
- * { text: "Option 2", value: 2 },
8160
- * ]}
8161
- * onSelect={handleSelect}
8162
- * width={selectWidthPx}
8163
- * height={selectHeightPx}
8164
- * />
8165
- * </>
8166
- * }
8167
- * ```
8168
- */
8169
-
8170
-
8171
- function Select(_ref3) {
8172
- var _ref4, _selectedValue$text, _options$;
8173
-
8174
- var label = _ref3.label,
8175
- options = _ref3.options,
8176
- onSelect = _ref3.onSelect,
8177
- _ref3$disabled = _ref3.disabled,
8178
- disabled = _ref3$disabled === void 0 ? false : _ref3$disabled,
8179
- _ref3$resetWhenOption = _ref3.resetWhenOptionsUpdate,
8180
- resetWhenOptionsUpdate = _ref3$resetWhenOption === void 0 ? false : _ref3$resetWhenOption,
8181
- _ref3$width = _ref3.width,
8182
- width = _ref3$width === void 0 ? 'default' : _ref3$width,
8183
- _ref3$height = _ref3.height,
8184
- height = _ref3$height === void 0 ? 'default' : _ref3$height;
8185
- var selectRef = useRef(null);
8186
- var optionsRef = useRef([]);
8187
7859
 
8188
- var _useState2 = useState(null),
8189
- selectedValue = _useState2[0],
8190
- setSelectedValue = _useState2[1];
8191
-
8192
- var _useState3 = useState(false),
8193
- isOpen = _useState3[0],
8194
- setIsOpen = _useState3[1];
8195
-
8196
- var isDisabled = disabled || options.length === 0;
8197
-
8198
- var _useAccessibility = useAccessibility({
8199
- selectRef: selectRef,
8200
- optionsRef: optionsRef,
8201
- shouldHighlightOption: isOpen,
8202
- isSelectDisabled: isDisabled
8203
- }),
8204
- withClickAwayHandler = _useAccessibility.withClickAwayHandler,
8205
- handleHighlighted = _useAccessibility.handleHighlighted,
8206
- itemToHighlight = _useAccessibility.itemToHighlight;
8207
-
8208
- var openSelect = function openSelect() {
8209
- return setIsOpen(true);
8210
- };
8211
-
8212
- var closeSelect = function closeSelect() {
8213
- return setIsOpen(false);
8214
- };
8215
-
8216
- var toggleSelect = function toggleSelect() {
8217
- return setIsOpen(function (prev) {
8218
- return !prev;
8219
- });
8220
- };
8221
-
8222
- var closeSelectOnBlur = withClickAwayHandler(closeSelect);
8223
-
8224
- var handleOptionSelection = function handleOptionSelection(index) {
8225
- var option = options[index];
8226
- setSelectedValue(option);
8227
- onSelect(option.value, option.text);
8228
- };
8229
-
8230
- useEffect(function () {
8231
- document.addEventListener('click', closeSelectOnBlur, false);
8232
- return function () {
8233
- document.removeEventListener('click', closeSelectOnBlur, false);
8234
- };
8235
- }, []);
8236
- useEffect(function () {
8237
- if (!resetWhenOptionsUpdate) return;
8238
-
8239
- if (options.length === 0) {
8240
- setSelectedValue(null);
8241
- return;
8242
- }
7860
+ function Select(_ref) {
7861
+ var label = _ref.label,
7862
+ darkMode = _ref.darkMode,
7863
+ width = _ref.width,
7864
+ error = _ref.error,
7865
+ _ref$isSearchable = _ref.isSearchable,
7866
+ isSearchable = _ref$isSearchable === void 0 ? false : _ref$isSearchable,
7867
+ selectProps = _objectWithoutPropertiesLoose(_ref, ["label", "darkMode", "width", "error", "isSearchable"]);
8243
7868
 
8244
- setSelectedValue(options[0]);
8245
- }, [options, resetWhenOptionsUpdate]);
8246
- return /*#__PURE__*/React__default.createElement(Wrapper$5, null, label !== '' && /*#__PURE__*/React__default.createElement(BodyText, {
8247
- level: 1,
8248
- tag: "p",
8249
- "data-testid": "select-label"
8250
- }, label), /*#__PURE__*/React__default.createElement(SelectList, {
8251
- id: "select",
8252
- ref: selectRef,
8253
- onClick: toggleSelect,
8254
- onFocus: openSelect,
8255
- onBlur: closeSelect,
8256
- onMouseDown: function onMouseDown(e) {
8257
- return e.preventDefault();
8258
- },
8259
- onKeyUp: handleHighlighted(handleOptionSelection),
7869
+ return /*#__PURE__*/React__default.createElement(Container$1, null, /*#__PURE__*/React__default.createElement("label", null, !!label && /*#__PURE__*/React__default.createElement(TextLabel$1, {
7870
+ darkMode: darkMode,
7871
+ "data-testid": "text-field-text-label"
7872
+ }, /*#__PURE__*/React__default.createElement(AltHeader, {
7873
+ level: 6
7874
+ }, label)), /*#__PURE__*/React__default.createElement(SelectWrapper, {
8260
7875
  width: width,
8261
- height: height,
8262
- role: "listbox",
8263
- tabIndex: 0,
8264
- "aria-labelledby": label,
8265
- "aria-selected": isOpen,
8266
- "aria-disabled": isDisabled,
8267
- "data-testid": "select"
8268
- }, /*#__PURE__*/React__default.createElement(SelectWrapper, null, /*#__PURE__*/React__default.createElement(BodyText, {
8269
- level: 1,
8270
- tag: "p",
8271
- "data-testid": "selected-value"
8272
- }, (_ref4 = (_selectedValue$text = selectedValue == null ? void 0 : selectedValue.text) != null ? _selectedValue$text : (_options$ = options[0]) == null ? void 0 : _options$.text) != null ? _ref4 : ''), isOpen && /*#__PURE__*/React__default.createElement(Options, {
8273
- "data-testid": "options"
8274
- }, options.map(function (option, index) {
8275
- return /*#__PURE__*/React__default.createElement(Option, {
8276
- ref: function ref(element) {
8277
- if (!element || optionsRef.current.length === options.length) return;
8278
- optionsRef.current.push(element);
8279
- },
8280
- role: "option",
8281
- tabIndex: index + 1,
8282
- hover: index === itemToHighlight,
8283
- key: option.text,
8284
- onClick: function onClick() {
8285
- return handleOptionSelection(index);
8286
- }
8287
- }, /*#__PURE__*/React__default.createElement(BodyText, {
8288
- level: 1,
8289
- tag: "p"
8290
- }, option.text));
8291
- }))), /*#__PURE__*/React__default.createElement(ArrowIcon, null)));
7876
+ error: error
7877
+ }, /*#__PURE__*/React__default.createElement(ReactSelect, Object.assign({
7878
+ components: {
7879
+ DropdownIndicator: DropdownIndicator
7880
+ },
7881
+ isSearchable: isSearchable,
7882
+ className: "chord-select-container",
7883
+ classNamePrefix: "chord-select"
7884
+ }, selectProps)))), !!error && /*#__PURE__*/React__default.createElement(ErrorLabel$1, {
7885
+ darkMode: darkMode,
7886
+ "data-testid": "text-field-error-label"
7887
+ }, /*#__PURE__*/React__default.createElement(AltHeader, {
7888
+ level: 6
7889
+ }, error)));
8292
7890
  }
8293
7891
 
8294
7892
  var _templateObject$15;
@@ -8321,7 +7919,7 @@ var TextOnly = function TextOnly(_ref) {
8321
7919
  };
8322
7920
 
8323
7921
  var _templateObject$16, _templateObject2$N;
8324
- var Wrapper$6 = /*#__PURE__*/styled.div(_templateObject$16 || (_templateObject$16 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: column;\n height: 100%;\n width: fit-content;\n\n ", " {\n height: calc(100% - 12px - var(--line-height-body-2));\n @supports not (aspect-ratio: ", ") {\n width: ", ";\n }\n }\n"])), ImageAspectRatioWrapper, function (_ref) {
7922
+ var Wrapper$5 = /*#__PURE__*/styled.div(_templateObject$16 || (_templateObject$16 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: column;\n height: 100%;\n width: fit-content;\n\n ", " {\n height: calc(100% - 12px - var(--line-height-body-2));\n @supports not (aspect-ratio: ", ") {\n width: ", ";\n }\n }\n"])), ImageAspectRatioWrapper, function (_ref) {
8325
7923
  var _ref$aspectRatio = _ref.aspectRatio,
8326
7924
  aspectRatio = _ref$aspectRatio === void 0 ? AspectRatio['1:1'] : _ref$aspectRatio;
8327
7925
  return aspectRatio;
@@ -8360,7 +7958,7 @@ var ImageWithCaption = function ImageWithCaption(_ref) {
8360
7958
  return window.removeEventListener('resize', setWrapperHeight);
8361
7959
  };
8362
7960
  }, [wrapperRef]);
8363
- return /*#__PURE__*/React__default.createElement(Wrapper$6, {
7961
+ return /*#__PURE__*/React__default.createElement(Wrapper$5, {
8364
7962
  aspectRatio: aspectRatio,
8365
7963
  ref: wrapperRef,
8366
7964
  height: height
@@ -8399,13 +7997,13 @@ var Quote = function Quote(_ref) {
8399
7997
  }, attribution))));
8400
7998
  };
8401
7999
 
8402
- var _templateObject$18, _templateObject2$P, _templateObject3$G, _templateObject4$w, _templateObject5$o, _templateObject6$j;
8000
+ var _templateObject$18, _templateObject2$P, _templateObject3$G, _templateObject4$w, _templateObject5$n, _templateObject6$i;
8403
8001
  var CardContainer$1 = /*#__PURE__*/styled.div(_templateObject$18 || (_templateObject$18 = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n cursor: pointer;\n width: 100%;\n display: grid;\n grid-template-columns: repeat(7, minmax(0, 1fr));\n gap: 15px;\n min-height: 50px;\n"])));
8404
8002
  var ContentContainer$4 = /*#__PURE__*/styled.div(_templateObject2$P || (_templateObject2$P = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n height: 100%;\n display: flex;\n flex-direction: column;\n justify-content: center;\n"])));
8405
8003
  var StyledImage = /*#__PURE__*/styled.img(_templateObject3$G || (_templateObject3$G = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n border: 1px solid var(--base-color-white);\n"])));
8406
8004
  var ImageWrapper = /*#__PURE__*/styled.div(_templateObject4$w || (_templateObject4$w = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n position: relative;\n"])));
8407
- var IconWrapper$3 = /*#__PURE__*/styled.div(_templateObject5$o || (_templateObject5$o = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n background: rgba(0, 0, 0, 0.4);\n position: absolute;\n top: 0;\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n span {\n width: 40px;\n height: 40px;\n @media ", " {\n width: 24px;\n height: 24px;\n }\n @media ", " {\n width: 18px;\n height: 18px;\n }\n }\n"])), devices.tablet, devices.mobile);
8408
- var TitleWrapper$2 = /*#__PURE__*/styled.div(_templateObject6$j || (_templateObject6$j = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin-top: 8px;\n div {\n @media ", " {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n }\n"])), devices.mobile);
8005
+ var IconWrapper$3 = /*#__PURE__*/styled.div(_templateObject5$n || (_templateObject5$n = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n background: rgba(0, 0, 0, 0.4);\n position: absolute;\n top: 0;\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n span {\n width: 40px;\n height: 40px;\n @media ", " {\n width: 24px;\n height: 24px;\n }\n @media ", " {\n width: 18px;\n height: 18px;\n }\n }\n"])), devices.tablet, devices.mobile);
8006
+ var TitleWrapper$2 = /*#__PURE__*/styled.div(_templateObject6$i || (_templateObject6$i = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin-top: 8px;\n div {\n @media ", " {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n }\n"])), devices.mobile);
8409
8007
 
8410
8008
  var MiniCard = function MiniCard(_ref) {
8411
8009
  var _ref$title = _ref.title,
@@ -8545,19 +8143,101 @@ var ReadMore = function ReadMore(_ref) {
8545
8143
  }, isFullTextOpen ? "" + hideText : "" + showMoreText)));
8546
8144
  };
8547
8145
 
8548
- var _templateObject$1a, _templateObject2$R, _templateObject3$I, _templateObject4$y, _templateObject5$p, _templateObject6$k;
8549
- var Container$1 = /*#__PURE__*/styled.div(_templateObject$1a || (_templateObject$1a = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: column;\n gap: 10px;\n"])));
8550
- var Sections = /*#__PURE__*/styled.div(_templateObject2$R || (_templateObject2$R = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: row;\n gap: 8px;\n"])));
8551
- var Section = /*#__PURE__*/styled.div(_templateObject3$I || (_templateObject3$I = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n flex: 1;\n height: 2px;\n background-color: ", ";\n"])), function (_ref) {
8146
+ var _templateObject$1a, _templateObject2$R, _templateObject3$I, _templateObject4$y;
8147
+ var MenuContainer$2 = /*#__PURE__*/styled.menu(_templateObject$1a || (_templateObject$1a = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n position: relative;\n padding: 0;\n margin: 0;\n"])));
8148
+ var MenuList = /*#__PURE__*/styled.ul(_templateObject2$R || (_templateObject2$R = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n padding: 0;\n margin: 0;\n list-style: none;\n border-right: 1px solid var(--base-color-", ");\n li {\n margin-left: -5px;\n @media ", " {\n margin-left: 0px;\n }\n }\n @media ", " {\n display: ", ";\n background: var(--base-color-", ");\n border: 1px solid var(--base-color-", ");\n border-top: 0;\n position: absolute;\n top: 100%;\n left: 0;\n right: 0;\n }\n"])), Colors.LightGrey, devices.mobile, devices.mobile, function (_ref) {
8149
+ var mobileOpen = _ref.mobileOpen;
8150
+ return mobileOpen ? "block" : 'none';
8151
+ }, Colors.White, Colors.DarkGrey);
8152
+ var MenuItem$1 = /*#__PURE__*/styled.button(_templateObject3$I || (_templateObject3$I = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n line-height: var(--line-height-navigation);\n font-size: var(--font-size-navigation);\n font-family: var(--font-family-navigation);\n font-weight: var(--font-weight-navigation);\n letter-spacing: var(--letter-spacing-navigation);\n color: var(--base-color-", ");\n text-transform: uppercase;\n margin: 0;\n padding: 16px 20px 15px 5px;\n border: 0;\n border-radius: 0;\n display: block;\n width: 100%;\n text-align: left;\n background: ", ";\n cursor: pointer;\n &:hover {\n background: var(--base-color-", ");\n }\n @media ", " {\n padding: 16px 20px 15px 20px;\n }\n"])), Colors.Black, function (_ref2) {
8153
+ var active = _ref2.active;
8154
+ return active ? "var(--base-color-" + Colors.MidGrey + ")" : 'none';
8155
+ }, Colors.MidGrey, devices.mobile);
8156
+ var MobileButton = /*#__PURE__*/styled.button(_templateObject4$y || (_templateObject4$y = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n line-height: var(--line-height-navigation);\n font-size: var(--font-size-navigation);\n font-family: var(--font-family-navigation);\n font-weight: var(--font-weight-navigation);\n letter-spacing: var(--letter-spacing-navigation);\n color: var(--base-color-", ");\n text-transform: uppercase;\n margin: 0;\n padding: 16px 46px 14px 20px;\n background: var(--base-color-", ");\n border: 1px solid var(--base-color-", ");\n border-radius: 0;\n display: none;\n width: 100%;\n text-align: left;\n cursor: pointer;\n position: relative;\n span {\n width: 25px;\n height: 25px;\n position: absolute;\n top: 50%;\n margin-top: -12px;\n right: 10px;\n }\n @media ", " {\n display: block;\n }\n"])), Colors.Black, Colors.White, Colors.DarkGrey, devices.mobile);
8157
+
8158
+ /**
8159
+ * Vertical menu component uses for navigation
8160
+ * inside website chapter. It looks like a vertical
8161
+ * list with clickable items on desktop and dropdown
8162
+ * list on mobile.
8163
+ *
8164
+ * ## Menu items
8165
+ * Menu items should be passed as `items` prop. This
8166
+ * should be an array of objects. Each object should
8167
+ * have `text` (text displayed as a menu item) and
8168
+ * `onClick` (click handler function)
8169
+ *
8170
+ * ## Active menu item
8171
+ * Active menu item should be passed as component `activeItem`
8172
+ * prop. This indicates on which menu item should be highlighted
8173
+ * as active one. Should be equal to `text` prop from one of the `items`
8174
+ */
8175
+
8176
+ var AuxiliaryNav = function AuxiliaryNav(_ref) {
8177
+ var items = _ref.items,
8178
+ activeItem = _ref.activeItem;
8179
+
8180
+ var _useState = useState(false),
8181
+ mobileOpen = _useState[0],
8182
+ setMobileOpen = _useState[1];
8183
+
8184
+ var containerRef = useRef(null);
8185
+
8186
+ var mobileButtonClickHandler = function mobileButtonClickHandler() {
8187
+ setMobileOpen(function (prev) {
8188
+ return !prev;
8189
+ });
8190
+ };
8191
+
8192
+ var outsideClickHandler = function outsideClickHandler(event) {
8193
+ if (containerRef.current && !containerRef.current.contains(event.target)) {
8194
+ setMobileOpen(false);
8195
+ }
8196
+ };
8197
+
8198
+ useEffect(function () {
8199
+ document.addEventListener('mousedown', outsideClickHandler);
8200
+ return function () {
8201
+ document.removeEventListener('mousedown', outsideClickHandler);
8202
+ };
8203
+ }, [containerRef]);
8204
+ return /*#__PURE__*/React__default.createElement(MenuContainer$2, {
8205
+ ref: containerRef,
8206
+ "data-testid": "nav-menu-container"
8207
+ }, /*#__PURE__*/React__default.createElement(MobileButton, {
8208
+ mobileOpen: mobileOpen,
8209
+ onClick: mobileButtonClickHandler,
8210
+ "data-testid": "nav-menu-mobile-button"
8211
+ }, activeItem, /*#__PURE__*/React__default.createElement(Icon, {
8212
+ iconName: "DropdownArrow",
8213
+ direction: mobileOpen ? 'left' : 'right'
8214
+ })), /*#__PURE__*/React__default.createElement(MenuList, {
8215
+ mobileOpen: mobileOpen,
8216
+ "data-testid": "nav-menu-list"
8217
+ }, items.map(function (item, idx) {
8218
+ return /*#__PURE__*/React__default.createElement("li", {
8219
+ key: item.text + "-" + idx
8220
+ }, /*#__PURE__*/React__default.createElement(MenuItem$1, {
8221
+ onClick: item.onClick,
8222
+ active: item.text === activeItem,
8223
+ "data-testid": "nav-menu-item" + (item.text === activeItem ? '-active' : '')
8224
+ }, item.text));
8225
+ })));
8226
+ };
8227
+
8228
+ var _templateObject$1b, _templateObject2$S, _templateObject3$J, _templateObject4$z, _templateObject5$o, _templateObject6$j;
8229
+ var Container$2 = /*#__PURE__*/styled.div(_templateObject$1b || (_templateObject$1b = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: column;\n gap: 10px;\n"])));
8230
+ var Sections = /*#__PURE__*/styled.div(_templateObject2$S || (_templateObject2$S = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: row;\n gap: 8px;\n"])));
8231
+ var Section = /*#__PURE__*/styled.div(_templateObject3$J || (_templateObject3$J = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n flex: 1;\n height: 2px;\n background-color: ", ";\n"])), function (_ref) {
8552
8232
  var color = _ref.color;
8553
8233
  return "var(--base-color-" + color + ")";
8554
8234
  });
8555
- var BottomLine = /*#__PURE__*/styled.div(_templateObject4$y || (_templateObject4$y = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n gap: 20px;\n"])));
8556
- var Text = /*#__PURE__*/styled.div(_templateObject5$p || (_templateObject5$p = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: ", ";\n"])), function (_ref2) {
8235
+ var BottomLine = /*#__PURE__*/styled.div(_templateObject4$z || (_templateObject4$z = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n gap: 20px;\n"])));
8236
+ var Text = /*#__PURE__*/styled.div(_templateObject5$o || (_templateObject5$o = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n color: ", ";\n"])), function (_ref2) {
8557
8237
  var color = _ref2.color;
8558
8238
  return "var(--base-color-" + color + ")";
8559
8239
  });
8560
- var LabelText = /*#__PURE__*/styled.div(_templateObject6$k || (_templateObject6$k = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin-top: 1px;\n white-space: nowrap;\n color: ", ";\n"])), function (_ref3) {
8240
+ var LabelText = /*#__PURE__*/styled.div(_templateObject6$j || (_templateObject6$j = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n margin-top: 1px;\n white-space: nowrap;\n color: ", ";\n"])), function (_ref3) {
8561
8241
  var color = _ref3.color;
8562
8242
  return "var(--base-color-" + color + ")";
8563
8243
  });
@@ -8618,7 +8298,7 @@ var PasswordStrength = function PasswordStrength(_ref) {
8618
8298
  return index < activeSections ? 'password-strength-section-active' : 'password-strength-section';
8619
8299
  };
8620
8300
 
8621
- return /*#__PURE__*/React__default.createElement(Container$1, {
8301
+ return /*#__PURE__*/React__default.createElement(Container$2, {
8622
8302
  "data-testid": "password-strength-container"
8623
8303
  }, /*#__PURE__*/React__default.createElement(Sections, {
8624
8304
  "data-testid": "password-strength-sections"
@@ -8643,88 +8323,6 @@ var PasswordStrength = function PasswordStrength(_ref) {
8643
8323
  }, strengthLabel))));
8644
8324
  };
8645
8325
 
8646
- var _templateObject$1b, _templateObject2$S, _templateObject3$J, _templateObject4$z;
8647
- var MenuContainer$2 = /*#__PURE__*/styled.menu(_templateObject$1b || (_templateObject$1b = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n position: relative;\n padding: 0;\n margin: 0;\n"])));
8648
- var MenuList = /*#__PURE__*/styled.ul(_templateObject2$S || (_templateObject2$S = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n padding: 0;\n margin: 0;\n list-style: none;\n border-right: 1px solid var(--base-color-", ");\n li {\n margin-left: -5px;\n @media ", " {\n margin-left: 0px;\n }\n }\n @media ", " {\n display: ", ";\n background: var(--base-color-", ");\n border: 1px solid var(--base-color-", ");\n border-top: 0;\n position: absolute;\n top: 100%;\n left: 0;\n right: 0;\n }\n"])), Colors.LightGrey, devices.mobile, devices.mobile, function (_ref) {
8649
- var mobileOpen = _ref.mobileOpen;
8650
- return mobileOpen ? "block" : 'none';
8651
- }, Colors.White, Colors.DarkGrey);
8652
- var MenuItem$1 = /*#__PURE__*/styled.button(_templateObject3$J || (_templateObject3$J = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n line-height: var(--line-height-navigation);\n font-size: var(--font-size-navigation);\n font-family: var(--font-family-navigation);\n font-weight: var(--font-weight-navigation);\n letter-spacing: var(--letter-spacing-navigation);\n color: var(--base-color-", ");\n text-transform: uppercase;\n margin: 0;\n padding: 16px 20px 15px 5px;\n border: 0;\n border-radius: 0;\n display: block;\n width: 100%;\n text-align: left;\n background: ", ";\n cursor: pointer;\n &:hover {\n background: var(--base-color-", ");\n }\n @media ", " {\n padding: 16px 20px 15px 20px;\n }\n"])), Colors.Black, function (_ref2) {
8653
- var active = _ref2.active;
8654
- return active ? "var(--base-color-" + Colors.MidGrey + ")" : 'none';
8655
- }, Colors.MidGrey, devices.mobile);
8656
- var MobileButton = /*#__PURE__*/styled.button(_templateObject4$z || (_templateObject4$z = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n line-height: var(--line-height-navigation);\n font-size: var(--font-size-navigation);\n font-family: var(--font-family-navigation);\n font-weight: var(--font-weight-navigation);\n letter-spacing: var(--letter-spacing-navigation);\n color: var(--base-color-", ");\n text-transform: uppercase;\n margin: 0;\n padding: 16px 46px 14px 20px;\n background: var(--base-color-", ");\n border: 1px solid var(--base-color-", ");\n border-radius: 0;\n display: none;\n width: 100%;\n text-align: left;\n cursor: pointer;\n position: relative;\n span {\n width: 25px;\n height: 25px;\n position: absolute;\n top: 50%;\n margin-top: -12px;\n right: 10px;\n }\n @media ", " {\n display: block;\n }\n"])), Colors.Black, Colors.White, Colors.DarkGrey, devices.mobile);
8657
-
8658
- /**
8659
- * Vertical menu component uses for navigation
8660
- * inside website chapter. It looks like a vertical
8661
- * list with clickable items on desktop and dropdown
8662
- * list on mobile.
8663
- *
8664
- * ## Menu items
8665
- * Menu items should be passed as `items` prop. This
8666
- * should be an array of objects. Each object should
8667
- * have `text` (text displayed as a menu item) and
8668
- * `onClick` (click handler function)
8669
- *
8670
- * ## Active menu item
8671
- * Active menu item should be passed as component `activeItem`
8672
- * prop. This indicates on which menu item should be highlighted
8673
- * as active one. Should be equal to `text` prop from one of the `items`
8674
- */
8675
-
8676
- var AuxiliaryNav = function AuxiliaryNav(_ref) {
8677
- var items = _ref.items,
8678
- activeItem = _ref.activeItem;
8679
-
8680
- var _useState = useState(false),
8681
- mobileOpen = _useState[0],
8682
- setMobileOpen = _useState[1];
8683
-
8684
- var containerRef = useRef(null);
8685
-
8686
- var mobileButtonClickHandler = function mobileButtonClickHandler() {
8687
- setMobileOpen(function (prev) {
8688
- return !prev;
8689
- });
8690
- };
8691
-
8692
- var outsideClickHandler = function outsideClickHandler(event) {
8693
- if (containerRef.current && !containerRef.current.contains(event.target)) {
8694
- setMobileOpen(false);
8695
- }
8696
- };
8697
-
8698
- useEffect(function () {
8699
- document.addEventListener('mousedown', outsideClickHandler);
8700
- return function () {
8701
- document.removeEventListener('mousedown', outsideClickHandler);
8702
- };
8703
- }, [containerRef]);
8704
- return /*#__PURE__*/React__default.createElement(MenuContainer$2, {
8705
- ref: containerRef,
8706
- "data-testid": "nav-menu-container"
8707
- }, /*#__PURE__*/React__default.createElement(MobileButton, {
8708
- mobileOpen: mobileOpen,
8709
- onClick: mobileButtonClickHandler,
8710
- "data-testid": "nav-menu-mobile-button"
8711
- }, activeItem, /*#__PURE__*/React__default.createElement(Icon, {
8712
- iconName: "DropdownArrow",
8713
- direction: mobileOpen ? 'left' : 'right'
8714
- })), /*#__PURE__*/React__default.createElement(MenuList, {
8715
- mobileOpen: mobileOpen,
8716
- "data-testid": "nav-menu-list"
8717
- }, items.map(function (item, idx) {
8718
- return /*#__PURE__*/React__default.createElement("li", {
8719
- key: item.text + "-" + idx
8720
- }, /*#__PURE__*/React__default.createElement(MenuItem$1, {
8721
- onClick: item.onClick,
8722
- active: item.text === activeItem,
8723
- "data-testid": "nav-menu-item" + (item.text === activeItem ? '-active' : '')
8724
- }, item.text));
8725
- })));
8726
- };
8727
-
8728
8326
  var UpsellSection = function UpsellSection(_ref) {
8729
8327
  var title = _ref.title,
8730
8328
  richText = _ref.richText,
@@ -8849,7 +8447,6 @@ var CloseButton = /*#__PURE__*/styled.button(_templateObject2$U || (_templateObj
8849
8447
  var ContentWrapper$1 = /*#__PURE__*/styled.div(_templateObject3$K || (_templateObject3$K = /*#__PURE__*/_taggedTemplateLiteralLoose([""])));
8850
8448
  var Overlay = /*#__PURE__*/styled(Grid)(_templateObject4$A || (_templateObject4$A = /*#__PURE__*/_taggedTemplateLiteralLoose(["\n position: fixed;\n top: 0;\n left: 0;\n width: 100%;\n height: 100vh;\n align-content: center;\n background-color: rgba(0, 0, 0, 0.4);\n"])));
8851
8449
 
8852
- var _excluded$k = ["isOpen", "setIsOpen", "children", "appElementId"];
8853
8450
  var MAX_Z_INDEX = 9999999999;
8854
8451
 
8855
8452
  if (Modal.defaultStyles.content) {
@@ -8926,7 +8523,7 @@ var ModalWindow = function ModalWindow(_ref) {
8926
8523
  setIsOpen = _ref.setIsOpen,
8927
8524
  children = _ref.children,
8928
8525
  appElementId = _ref.appElementId,
8929
- modalProps = _objectWithoutPropertiesLoose(_ref, _excluded$k);
8526
+ modalProps = _objectWithoutPropertiesLoose(_ref, ["isOpen", "setIsOpen", "children", "appElementId"]);
8930
8527
 
8931
8528
  var isMobile = useMobile();
8932
8529
  var customStyles = {