hmrc-frontend 6.78.0 → 6.80.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.
@@ -1,3 +1,3 @@
1
1
  !function(){"use strict";function t(t){if(t.includes("#"))return t.split("#").pop()}function e(t){const e=`--govuk-breakpoint-${t}`;return{property:e,value:window.getComputedStyle(document.documentElement).getPropertyValue(e)||void 0}}function n(t,e={}){var n;const i=t.getAttribute("tabindex");function s(){var n;null==(n=e.onBlur)||n.call(t),i||t.removeAttribute("tabindex")}i||t.setAttribute("tabindex","-1"),t.addEventListener("focus",(function(){t.addEventListener("blur",s,{once:!0})}),{once:!0}),null==(n=e.onBeforeFocus)||n.call(t),t.focus()}function i(t=document.body){return!!t&&t.classList.contains("govuk-frontend-supported")}function s(t){return!!t&&"object"==typeof t&&!function(t){return Array.isArray(t)}(t)}function o(t,e){return`${t.moduleName}: ${e}`}class r extends Error{constructor(...t){super(...t),this.name="GOVUKFrontendError"}}class a extends r{constructor(t=document.body){const e="noModule"in HTMLScriptElement.prototype?'GOV.UK Frontend initialised without `<body class="govuk-frontend-supported">` from template `<script>` snippet':"GOV.UK Frontend is not supported in this browser";super(t?e:'GOV.UK Frontend initialised without `<script type="module">`'),this.name="SupportError"}}class c extends r{constructor(...t){super(...t),this.name="ConfigError"}}class u extends r{constructor(t){let e="string"==typeof t?t:"";if("object"==typeof t){const{component:n,identifier:i,element:s,expectedType:r}=t;e=i,e+=s?` is not of type ${null!=r?r:"HTMLElement"}`:" not found",e=o(n,e)}super(e),this.name="ElementError"}}class l extends r{constructor(t){super("string"==typeof t?t:o(t,"Root element (`$root`) already initialised")),this.name="InitError"}}class d{get $root(){return this._$root}constructor(t){this._$root=void 0;const e=this.constructor;if("string"!=typeof e.moduleName)throw new l("`moduleName` not defined in component");if(!(t instanceof e.elementType))throw new u({element:t,component:e,identifier:"Root element (`$root`)",expectedType:e.elementType.name});this._$root=t,e.checkSupport(),this.checkInitialised();const n=e.moduleName;this.$root.setAttribute(`data-${n}-init`,"")}checkInitialised(){const t=this.constructor,e=t.moduleName;if(e&&function(t,e){return t instanceof HTMLElement&&t.hasAttribute(`data-${e}-init`)}(this.$root,e))throw new l(t)}static checkSupport(){if(!i())throw new a}}d.elementType=HTMLElement;const h=Symbol.for("configOverride");class m extends d{[h](t){return{}}get config(){return this._config}constructor(t,e){super(t),this._config=void 0;const n=this.constructor;if(!s(n.defaults))throw new c(o(n,"Config passed as parameter into constructor but no defaults defined"));const i=function(t,e){if(!s(t.schema))throw new c(o(t,"Config passed as parameter into constructor but no schema defined"));const n={},i=Object.entries(t.schema.properties);for(const s of i){const[i,o]=s,r=i.toString();r in e&&(n[r]=p(e[r],o)),"object"===(null==o?void 0:o.type)&&(n[r]=f(t.schema,e,i))}return n}(n,this._$root.dataset);this._config=g(n.defaults,null!=e?e:{},this[h](i),i)}}function p(t,e){const n=t?t.trim():"";let i,s=null==e?void 0:e.type;switch(s||(["true","false"].includes(n)&&(s="boolean"),n.length>0&&isFinite(Number(n))&&(s="number")),s){case"boolean":i="true"===n;break;case"number":i=Number(n);break;default:i=t}return i}function g(...t){const e={};for(const n of t)for(const t of Object.keys(n)){const i=e[t],o=n[t];s(i)&&s(o)?e[t]=g(i,o):e[t]=o}return e}function f(t,e,n){const i=t.properties[n];if("object"!==(null==i?void 0:i.type))return;const o={[n]:{}};for(const[t,i]of Object.entries(e)){let e=o;const r=t.split(".");for(const[o,a]of r.entries())s(e)&&(o<r.length-1?(s(e[a])||(e[a]={}),e=e[a]):t!==n&&(e[a]=p(i)))}return o[n]}class v{constructor(t={},e={}){var n;this.translations=void 0,this.locale=void 0,this.translations=t,this.locale=null!=(n=e.locale)?n:document.documentElement.lang||"en"}t(t,e){if(!t)throw new Error("i18n: lookup key missing");let n=this.translations[t];if("number"==typeof(null==e?void 0:e.count)&&"object"==typeof n){const i=n[this.getPluralSuffix(t,e.count)];i&&(n=i)}if("string"==typeof n){if(n.match(/%{(.\S+)}/)){if(!e)throw new Error("i18n: cannot replace placeholders in string if no option data provided");return this.replacePlaceholders(n,e)}return n}return t}replacePlaceholders(t,e){const n=Intl.NumberFormat.supportedLocalesOf(this.locale).length?new Intl.NumberFormat(this.locale):void 0;return t.replace(/%{(.\S+)}/g,(function(t,i){if(Object.prototype.hasOwnProperty.call(e,i)){const t=e[i];return!1===t||"number"!=typeof t&&"string"!=typeof t?"":"number"==typeof t?n?n.format(t):`${t}`:t}throw new Error(`i18n: no data found to replace ${t} placeholder in string`)}))}hasIntlPluralRulesSupport(){return Boolean("PluralRules"in window.Intl&&Intl.PluralRules.supportedLocalesOf(this.locale).length)}getPluralSuffix(t,e){if(e=Number(e),!isFinite(e))return"other";const n=this.translations[t],i=this.hasIntlPluralRulesSupport()?new Intl.PluralRules(this.locale).select(e):this.selectPluralFormUsingFallbackRules(e);if("object"==typeof n){if(i in n)return i;if("other"in n)return console.warn(`i18n: Missing plural form ".${i}" for "${this.locale}" locale. Falling back to ".other".`),"other"}throw new Error(`i18n: Plural form ".other" is required for "${this.locale}" locale`)}selectPluralFormUsingFallbackRules(t){t=Math.abs(Math.floor(t));const e=this.getPluralRulesForLocale();return e?v.pluralRules[e](t):"other"}getPluralRulesForLocale(){const t=this.locale.split("-")[0];for(const e in v.pluralRulesMap){const n=v.pluralRulesMap[e];if(n.includes(this.locale)||n.includes(t))return e}}}v.pluralRulesMap={arabic:["ar"],chinese:["my","zh","id","ja","jv","ko","ms","th","vi"],french:["hy","bn","fr","gu","hi","fa","pa","zu"],german:["af","sq","az","eu","bg","ca","da","nl","en","et","fi","ka","de","el","hu","lb","no","so","sw","sv","ta","te","tr","ur"],irish:["ga"],russian:["ru","uk"],scottish:["gd"],spanish:["pt-PT","it","es"],welsh:["cy"]},v.pluralRules={arabic:t=>0===t?"zero":1===t?"one":2===t?"two":t%100>=3&&t%100<=10?"few":t%100>=11&&t%100<=99?"many":"other",chinese:()=>"other",french:t=>0===t||1===t?"one":"other",german:t=>1===t?"one":"other",irish:t=>1===t?"one":2===t?"two":t>=3&&t<=6?"few":t>=7&&t<=10?"many":"other",russian(t){const e=t%100,n=e%10;return 1===n&&11!==e?"one":n>=2&&n<=4&&!(e>=12&&e<=14)?"few":0===n||n>=5&&n<=9||e>=11&&e<=14?"many":"other"},scottish:t=>1===t||11===t?"one":2===t||12===t?"two":t>=3&&t<=10||t>=13&&t<=19?"few":"other",spanish:t=>1===t?"one":t%1e6==0&&0!==t?"many":"other",welsh:t=>0===t?"zero":1===t?"one":2===t?"two":3===t?"few":6===t?"many":"other"};class b extends m{constructor(t,e={}){super(t,e),this.i18n=void 0,this.controlsClass="govuk-accordion__controls",this.showAllClass="govuk-accordion__show-all",this.showAllTextClass="govuk-accordion__show-all-text",this.sectionClass="govuk-accordion__section",this.sectionExpandedClass="govuk-accordion__section--expanded",this.sectionButtonClass="govuk-accordion__section-button",this.sectionHeaderClass="govuk-accordion__section-header",this.sectionHeadingClass="govuk-accordion__section-heading",this.sectionHeadingDividerClass="govuk-accordion__section-heading-divider",this.sectionHeadingTextClass="govuk-accordion__section-heading-text",this.sectionHeadingTextFocusClass="govuk-accordion__section-heading-text-focus",this.sectionShowHideToggleClass="govuk-accordion__section-toggle",this.sectionShowHideToggleFocusClass="govuk-accordion__section-toggle-focus",this.sectionShowHideTextClass="govuk-accordion__section-toggle-text",this.upChevronIconClass="govuk-accordion-nav__chevron",this.downChevronIconClass="govuk-accordion-nav__chevron--down",this.sectionSummaryClass="govuk-accordion__section-summary",this.sectionSummaryFocusClass="govuk-accordion__section-summary-focus",this.sectionContentClass="govuk-accordion__section-content",this.$sections=void 0,this.$showAllButton=null,this.$showAllIcon=null,this.$showAllText=null,this.i18n=new v(this.config.i18n);const n=this.$root.querySelectorAll(`.${this.sectionClass}`);if(!n.length)throw new u({component:b,identifier:`Sections (\`<div class="${this.sectionClass}">\`)`});this.$sections=n,this.initControls(),this.initSectionHeaders(),this.updateShowAllButton(this.areAllSectionsOpen())}initControls(){this.$showAllButton=document.createElement("button"),this.$showAllButton.setAttribute("type","button"),this.$showAllButton.setAttribute("class",this.showAllClass),this.$showAllButton.setAttribute("aria-expanded","false"),this.$showAllIcon=document.createElement("span"),this.$showAllIcon.classList.add(this.upChevronIconClass),this.$showAllButton.appendChild(this.$showAllIcon);const t=document.createElement("div");t.setAttribute("class",this.controlsClass),t.appendChild(this.$showAllButton),this.$root.insertBefore(t,this.$root.firstChild),this.$showAllText=document.createElement("span"),this.$showAllText.classList.add(this.showAllTextClass),this.$showAllButton.appendChild(this.$showAllText),this.$showAllButton.addEventListener("click",(()=>this.onShowOrHideAllToggle())),"onbeforematch"in document&&document.addEventListener("beforematch",(t=>this.onBeforeMatch(t)))}initSectionHeaders(){this.$sections.forEach(((t,e)=>{const n=t.querySelector(`.${this.sectionHeaderClass}`);if(!n)throw new u({component:b,identifier:`Section headers (\`<div class="${this.sectionHeaderClass}">\`)`});this.constructHeaderMarkup(n,e),this.setExpanded(this.isExpanded(t),t),n.addEventListener("click",(()=>this.onSectionToggle(t))),this.setInitialState(t)}))}constructHeaderMarkup(t,e){const n=t.querySelector(`.${this.sectionButtonClass}`),i=t.querySelector(`.${this.sectionHeadingClass}`),s=t.querySelector(`.${this.sectionSummaryClass}`);if(!i)throw new u({component:b,identifier:`Section heading (\`.${this.sectionHeadingClass}\`)`});if(!n)throw new u({component:b,identifier:`Section button placeholder (\`<span class="${this.sectionButtonClass}">\`)`});const o=document.createElement("button");o.setAttribute("type","button"),o.setAttribute("aria-controls",`${this.$root.id}-content-${e+1}`);for(const t of Array.from(n.attributes))"id"!==t.name&&o.setAttribute(t.name,t.value);const r=document.createElement("span");r.classList.add(this.sectionHeadingTextClass),r.id=n.id;const a=document.createElement("span");a.classList.add(this.sectionHeadingTextFocusClass),r.appendChild(a),Array.from(n.childNodes).forEach((t=>a.appendChild(t)));const c=document.createElement("span");c.classList.add(this.sectionShowHideToggleClass),c.setAttribute("data-nosnippet","");const l=document.createElement("span");l.classList.add(this.sectionShowHideToggleFocusClass),c.appendChild(l);const d=document.createElement("span"),h=document.createElement("span");if(h.classList.add(this.upChevronIconClass),l.appendChild(h),d.classList.add(this.sectionShowHideTextClass),l.appendChild(d),o.appendChild(r),o.appendChild(this.getButtonPunctuationEl()),s){const t=document.createElement("span"),e=document.createElement("span");e.classList.add(this.sectionSummaryFocusClass),t.appendChild(e);for(const e of Array.from(s.attributes))t.setAttribute(e.name,e.value);Array.from(s.childNodes).forEach((t=>e.appendChild(t))),s.remove(),o.appendChild(t),o.appendChild(this.getButtonPunctuationEl())}o.appendChild(c),i.removeChild(n),i.appendChild(o)}onBeforeMatch(t){const e=t.target;if(!(e instanceof Element))return;const n=e.closest(`.${this.sectionClass}`);n&&this.setExpanded(!0,n)}onSectionToggle(t){const e=!this.isExpanded(t);this.setExpanded(e,t),this.storeState(t,e)}onShowOrHideAllToggle(){const t=!this.areAllSectionsOpen();this.$sections.forEach((e=>{this.setExpanded(t,e),this.storeState(e,t)})),this.updateShowAllButton(t)}setExpanded(t,e){const n=e.querySelector(`.${this.upChevronIconClass}`),i=e.querySelector(`.${this.sectionShowHideTextClass}`),s=e.querySelector(`.${this.sectionButtonClass}`),o=e.querySelector(`.${this.sectionContentClass}`);if(!o)throw new u({component:b,identifier:`Section content (\`<div class="${this.sectionContentClass}">\`)`});if(!n||!i||!s)return;const r=t?this.i18n.t("hideSection"):this.i18n.t("showSection");i.textContent=r,s.setAttribute("aria-expanded",`${t}`);const a=[],c=e.querySelector(`.${this.sectionHeadingTextClass}`);c&&a.push(`${c.textContent}`.trim());const l=e.querySelector(`.${this.sectionSummaryClass}`);l&&a.push(`${l.textContent}`.trim());const d=t?this.i18n.t("hideSectionAriaLabel"):this.i18n.t("showSectionAriaLabel");a.push(d),s.setAttribute("aria-label",a.join(" , ")),t?(o.removeAttribute("hidden"),e.classList.add(this.sectionExpandedClass),n.classList.remove(this.downChevronIconClass)):(o.setAttribute("hidden","until-found"),e.classList.remove(this.sectionExpandedClass),n.classList.add(this.downChevronIconClass)),this.updateShowAllButton(this.areAllSectionsOpen())}isExpanded(t){return t.classList.contains(this.sectionExpandedClass)}areAllSectionsOpen(){return Array.from(this.$sections).every((t=>this.isExpanded(t)))}updateShowAllButton(t){this.$showAllButton&&this.$showAllText&&this.$showAllIcon&&(this.$showAllButton.setAttribute("aria-expanded",t.toString()),this.$showAllText.textContent=t?this.i18n.t("hideAllSections"):this.i18n.t("showAllSections"),this.$showAllIcon.classList.toggle(this.downChevronIconClass,!t))}getIdentifier(t){const e=t.querySelector(`.${this.sectionButtonClass}`);return null==e?void 0:e.getAttribute("aria-controls")}storeState(t,e){if(!this.config.rememberExpanded)return;const n=this.getIdentifier(t);if(n)try{window.sessionStorage.setItem(n,e.toString())}catch(t){}}setInitialState(t){if(!this.config.rememberExpanded)return;const e=this.getIdentifier(t);if(e)try{const n=window.sessionStorage.getItem(e);null!==n&&this.setExpanded("true"===n,t)}catch(t){}}getButtonPunctuationEl(){const t=document.createElement("span");return t.classList.add("govuk-visually-hidden",this.sectionHeadingDividerClass),t.textContent=", ",t}}b.moduleName="govuk-accordion",b.defaults=Object.freeze({i18n:{hideAllSections:"Hide all sections",hideSection:"Hide",hideSectionAriaLabel:"Hide this section",showAllSections:"Show all sections",showSection:"Show",showSectionAriaLabel:"Show this section"},rememberExpanded:!0}),b.schema=Object.freeze({properties:{i18n:{type:"object"},rememberExpanded:{type:"boolean"}}});class w extends m{constructor(t,e={}){super(t,e),this.debounceFormSubmitTimer=null,this.$root.addEventListener("keydown",(t=>this.handleKeyDown(t))),this.$root.addEventListener("click",(t=>this.debounce(t)))}handleKeyDown(t){const e=t.target;" "===t.key&&e instanceof HTMLElement&&"button"===e.getAttribute("role")&&(t.preventDefault(),e.click())}debounce(t){if(this.config.preventDoubleClick)return this.debounceFormSubmitTimer?(t.preventDefault(),!1):void(this.debounceFormSubmitTimer=window.setTimeout((()=>{this.debounceFormSubmitTimer=null}),1e3))}}function y(t,e){const n=t.closest(`[${e}]`);return n?n.getAttribute(e):null}w.moduleName="govuk-button",w.defaults=Object.freeze({preventDoubleClick:!1}),w.schema=Object.freeze({properties:{preventDoubleClick:{type:"boolean"}}});class $ extends m{[h](t){let e={};return("maxwords"in t||"maxlength"in t)&&(e={maxlength:void 0,maxwords:void 0}),e}constructor(t,e={}){var n,i;super(t,e),this.$textarea=void 0,this.$visibleCountMessage=void 0,this.$screenReaderCountMessage=void 0,this.lastInputTimestamp=null,this.lastInputValue="",this.valueChecker=null,this.i18n=void 0,this.maxLength=void 0;const s=this.$root.querySelector(".govuk-js-character-count");if(!(s instanceof HTMLTextAreaElement||s instanceof HTMLInputElement))throw new u({component:$,element:s,expectedType:"HTMLTextareaElement or HTMLInputElement",identifier:"Form field (`.govuk-js-character-count`)"});const r=function(t,e){const n=[];for(const[i,s]of Object.entries(t)){const t=[];if(Array.isArray(s)){for(const{required:n,errorMessage:i}of s)n.every((t=>!!e[t]))||t.push(i);"anyOf"!==i||s.length-t.length>=1||n.push(...t)}}return n}($.schema,this.config);if(r[0])throw new c(o($,r[0]));this.i18n=new v(this.config.i18n,{locale:y(this.$root,"lang")}),this.maxLength=null!=(n=null!=(i=this.config.maxwords)?i:this.config.maxlength)?n:1/0,this.$textarea=s;const a=`${this.$textarea.id}-info`,l=document.getElementById(a);if(!l)throw new u({component:$,element:l,identifier:`Count message (\`id="${a}"\`)`});this.$errorMessage=this.$root.querySelector(".govuk-error-message"),`${l.textContent}`.match(/^\s*$/)&&(l.textContent=this.i18n.t("textareaDescription",{count:this.maxLength})),this.$textarea.insertAdjacentElement("afterend",l);const d=document.createElement("div");d.className="govuk-character-count__sr-status govuk-visually-hidden",d.setAttribute("aria-live","polite"),this.$screenReaderCountMessage=d,l.insertAdjacentElement("afterend",d);const h=document.createElement("div");h.className=l.className,h.classList.add("govuk-character-count__status"),h.setAttribute("aria-hidden","true"),this.$visibleCountMessage=h,l.insertAdjacentElement("afterend",h),l.classList.add("govuk-visually-hidden"),this.$textarea.removeAttribute("maxlength"),this.bindChangeEvents(),window.addEventListener("pageshow",(()=>this.updateCountMessage())),this.updateCountMessage()}bindChangeEvents(){this.$textarea.addEventListener("keyup",(()=>this.handleKeyUp())),this.$textarea.addEventListener("focus",(()=>this.handleFocus())),this.$textarea.addEventListener("blur",(()=>this.handleBlur()))}handleKeyUp(){this.updateVisibleCountMessage(),this.lastInputTimestamp=Date.now()}handleFocus(){this.valueChecker=window.setInterval((()=>{(!this.lastInputTimestamp||Date.now()-500>=this.lastInputTimestamp)&&this.updateIfValueChanged()}),1e3)}handleBlur(){this.valueChecker&&window.clearInterval(this.valueChecker)}updateIfValueChanged(){this.$textarea.value!==this.lastInputValue&&(this.lastInputValue=this.$textarea.value,this.updateCountMessage())}updateCountMessage(){this.updateVisibleCountMessage(),this.updateScreenReaderCountMessage()}updateVisibleCountMessage(){const t=this.maxLength-this.count(this.$textarea.value)<0;this.$visibleCountMessage.classList.toggle("govuk-character-count__message--disabled",!this.isOverThreshold()),this.$errorMessage||this.$textarea.classList.toggle("govuk-textarea--error",t),this.$visibleCountMessage.classList.toggle("govuk-error-message",t),this.$visibleCountMessage.classList.toggle("govuk-hint",!t),this.$visibleCountMessage.textContent=this.getCountMessage()}updateScreenReaderCountMessage(){this.isOverThreshold()?this.$screenReaderCountMessage.removeAttribute("aria-hidden"):this.$screenReaderCountMessage.setAttribute("aria-hidden","true"),this.$screenReaderCountMessage.textContent=this.getCountMessage()}count(t){var e;return this.config.maxwords?(null!=(e=t.match(/\S+/g))?e:[]).length:t.length}getCountMessage(){const t=this.maxLength-this.count(this.$textarea.value),e=this.config.maxwords?"words":"characters";return this.formatCountMessage(t,e)}formatCountMessage(t,e){if(0===t)return this.i18n.t(`${e}AtLimit`);const n=t<0?"OverLimit":"UnderLimit";return this.i18n.t(`${e}${n}`,{count:Math.abs(t)})}isOverThreshold(){if(!this.config.threshold)return!0;const t=this.count(this.$textarea.value);return this.maxLength*this.config.threshold/100<=t}}$.moduleName="govuk-character-count",$.defaults=Object.freeze({threshold:0,i18n:{charactersUnderLimit:{one:"You have %{count} character remaining",other:"You have %{count} characters remaining"},charactersAtLimit:"You have 0 characters remaining",charactersOverLimit:{one:"You have %{count} character too many",other:"You have %{count} characters too many"},wordsUnderLimit:{one:"You have %{count} word remaining",other:"You have %{count} words remaining"},wordsAtLimit:"You have 0 words remaining",wordsOverLimit:{one:"You have %{count} word too many",other:"You have %{count} words too many"},textareaDescription:{other:""}}}),$.schema=Object.freeze({properties:{i18n:{type:"object"},maxwords:{type:"number"},maxlength:{type:"number"},threshold:{type:"number"}},anyOf:[{required:["maxwords"],errorMessage:'Either "maxlength" or "maxwords" must be provided'},{required:["maxlength"],errorMessage:'Either "maxlength" or "maxwords" must be provided'}]});class k extends d{constructor(t){super(t),this.$inputs=void 0;const e=this.$root.querySelectorAll('input[type="checkbox"]');if(!e.length)throw new u({component:k,identifier:'Form inputs (`<input type="checkbox">`)'});this.$inputs=e,this.$inputs.forEach((t=>{const e=t.getAttribute("data-aria-controls");if(e){if(!document.getElementById(e))throw new u({component:k,identifier:`Conditional reveal (\`id="${e}"\`)`});t.setAttribute("aria-controls",e),t.removeAttribute("data-aria-controls")}})),window.addEventListener("pageshow",(()=>this.syncAllConditionalReveals())),this.syncAllConditionalReveals(),this.$root.addEventListener("click",(t=>this.handleClick(t)))}syncAllConditionalReveals(){this.$inputs.forEach((t=>this.syncConditionalRevealWithInputState(t)))}syncConditionalRevealWithInputState(t){const e=t.getAttribute("aria-controls");if(!e)return;const n=document.getElementById(e);if(null!=n&&n.classList.contains("govuk-checkboxes__conditional")){const e=t.checked;t.setAttribute("aria-expanded",e.toString()),n.classList.toggle("govuk-checkboxes__conditional--hidden",!e)}}unCheckAllInputsExcept(t){document.querySelectorAll(`input[type="checkbox"][name="${t.name}"]`).forEach((e=>{t.form===e.form&&e!==t&&(e.checked=!1,this.syncConditionalRevealWithInputState(e))}))}unCheckExclusiveInputs(t){document.querySelectorAll(`input[data-behaviour="exclusive"][type="checkbox"][name="${t.name}"]`).forEach((e=>{t.form===e.form&&(e.checked=!1,this.syncConditionalRevealWithInputState(e))}))}handleClick(t){const e=t.target;e instanceof HTMLInputElement&&"checkbox"===e.type&&(e.getAttribute("aria-controls")&&this.syncConditionalRevealWithInputState(e),e.checked&&("exclusive"===e.getAttribute("data-behaviour")?this.unCheckAllInputsExcept(e):this.unCheckExclusiveInputs(e)))}}k.moduleName="govuk-checkboxes";class C extends m{constructor(t,e={}){super(t,e),this.config.disableAutoFocus||n(this.$root),this.$root.addEventListener("click",(t=>this.handleClick(t)))}handleClick(t){const e=t.target;e&&this.focusTarget(e)&&t.preventDefault()}focusTarget(e){if(!(e instanceof HTMLAnchorElement))return!1;const n=t(e.href);if(!n)return!1;const i=document.getElementById(n);if(!i)return!1;const s=this.getAssociatedLegendOrLabel(i);return!!s&&(s.scrollIntoView(),i.focus({preventScroll:!0}),!0)}getAssociatedLegendOrLabel(t){var e;const n=t.closest("fieldset");if(n){const e=n.getElementsByTagName("legend");if(e.length){const n=e[0];if(t instanceof HTMLInputElement&&("checkbox"===t.type||"radio"===t.type))return n;const i=n.getBoundingClientRect().top,s=t.getBoundingClientRect();if(s.height&&window.innerHeight&&s.top+s.height-i<window.innerHeight/2)return n}}return null!=(e=document.querySelector(`label[for='${t.getAttribute("id")}']`))?e:t.closest("label")}}C.moduleName="govuk-error-summary",C.defaults=Object.freeze({disableAutoFocus:!1}),C.schema=Object.freeze({properties:{disableAutoFocus:{type:"boolean"}}});class A extends m{constructor(t,e={}){super(t,e),this.i18n=void 0,this.$button=void 0,this.$skiplinkButton=null,this.$updateSpan=null,this.$indicatorContainer=null,this.$overlay=null,this.keypressCounter=0,this.lastKeyWasModified=!1,this.timeoutTime=5e3,this.keypressTimeoutId=null,this.timeoutMessageId=null;const n=this.$root.querySelector(".govuk-exit-this-page__button");if(!(n instanceof HTMLAnchorElement))throw new u({component:A,element:n,expectedType:"HTMLAnchorElement",identifier:"Button (`.govuk-exit-this-page__button`)"});this.i18n=new v(this.config.i18n),this.$button=n;const i=document.querySelector(".govuk-js-exit-this-page-skiplink");i instanceof HTMLAnchorElement&&(this.$skiplinkButton=i),this.buildIndicator(),this.initUpdateSpan(),this.initButtonClickHandler(),"govukFrontendExitThisPageKeypress"in document.body.dataset||(document.addEventListener("keyup",this.handleKeypress.bind(this),!0),document.body.dataset.govukFrontendExitThisPageKeypress="true"),window.addEventListener("pageshow",this.resetPage.bind(this))}initUpdateSpan(){this.$updateSpan=document.createElement("span"),this.$updateSpan.setAttribute("role","status"),this.$updateSpan.className="govuk-visually-hidden",this.$root.appendChild(this.$updateSpan)}initButtonClickHandler(){this.$button.addEventListener("click",this.handleClick.bind(this)),this.$skiplinkButton&&this.$skiplinkButton.addEventListener("click",this.handleClick.bind(this))}buildIndicator(){this.$indicatorContainer=document.createElement("div"),this.$indicatorContainer.className="govuk-exit-this-page__indicator",this.$indicatorContainer.setAttribute("aria-hidden","true");for(let t=0;t<3;t++){const t=document.createElement("div");t.className="govuk-exit-this-page__indicator-light",this.$indicatorContainer.appendChild(t)}this.$button.appendChild(this.$indicatorContainer)}updateIndicator(){this.$indicatorContainer&&(this.$indicatorContainer.classList.toggle("govuk-exit-this-page__indicator--visible",this.keypressCounter>0),this.$indicatorContainer.querySelectorAll(".govuk-exit-this-page__indicator-light").forEach(((t,e)=>{t.classList.toggle("govuk-exit-this-page__indicator-light--on",e<this.keypressCounter)})))}exitPage(){this.$updateSpan&&(this.$updateSpan.textContent="",document.body.classList.add("govuk-exit-this-page-hide-content"),this.$overlay=document.createElement("div"),this.$overlay.className="govuk-exit-this-page-overlay",this.$overlay.setAttribute("role","alert"),document.body.appendChild(this.$overlay),this.$overlay.textContent=this.i18n.t("activated"),window.location.href=this.$button.href)}handleClick(t){t.preventDefault(),this.exitPage()}handleKeypress(t){this.$updateSpan&&("Shift"!==t.key||this.lastKeyWasModified?this.keypressTimeoutId&&this.resetKeypressTimer():(this.keypressCounter+=1,this.updateIndicator(),this.timeoutMessageId&&(window.clearTimeout(this.timeoutMessageId),this.timeoutMessageId=null),this.keypressCounter>=3?(this.keypressCounter=0,this.keypressTimeoutId&&(window.clearTimeout(this.keypressTimeoutId),this.keypressTimeoutId=null),this.exitPage()):1===this.keypressCounter?this.$updateSpan.textContent=this.i18n.t("pressTwoMoreTimes"):this.$updateSpan.textContent=this.i18n.t("pressOneMoreTime"),this.setKeypressTimer()),this.lastKeyWasModified=t.shiftKey)}setKeypressTimer(){this.keypressTimeoutId&&window.clearTimeout(this.keypressTimeoutId),this.keypressTimeoutId=window.setTimeout(this.resetKeypressTimer.bind(this),this.timeoutTime)}resetKeypressTimer(){if(!this.$updateSpan)return;this.keypressTimeoutId&&(window.clearTimeout(this.keypressTimeoutId),this.keypressTimeoutId=null);const t=this.$updateSpan;this.keypressCounter=0,t.textContent=this.i18n.t("timedOut"),this.timeoutMessageId=window.setTimeout((()=>{t.textContent=""}),this.timeoutTime),this.updateIndicator()}resetPage(){document.body.classList.remove("govuk-exit-this-page-hide-content"),this.$overlay&&(this.$overlay.remove(),this.$overlay=null),this.$updateSpan&&(this.$updateSpan.setAttribute("role","status"),this.$updateSpan.textContent=""),this.updateIndicator(),this.keypressTimeoutId&&window.clearTimeout(this.keypressTimeoutId),this.timeoutMessageId&&window.clearTimeout(this.timeoutMessageId)}}A.moduleName="govuk-exit-this-page",A.defaults=Object.freeze({i18n:{activated:"Loading.",timedOut:"Exit this page expired.",pressTwoMoreTimes:"Shift, press 2 more times to exit.",pressOneMoreTime:"Shift, press 1 more time to exit."}}),A.schema=Object.freeze({properties:{i18n:{type:"object"}}});class E extends m{constructor(t,e={}){super(t,e),this.$input=void 0,this.$button=void 0,this.$status=void 0,this.i18n=void 0,this.id=void 0,this.$announcements=void 0,this.enteredAnotherElement=void 0;const n=this.$root.querySelector("input");if(null===n)throw new u({component:E,identifier:'File inputs (`<input type="file">`)'});if("file"!==n.type)throw new u(o(E,'File input (`<input type="file">`) attribute (`type`) is not `file`'));if(this.$input=n,this.$input.setAttribute("hidden","true"),!this.$input.id)throw new u({component:E,identifier:'File input (`<input type="file">`) attribute (`id`)'});this.id=this.$input.id,this.i18n=new v(this.config.i18n,{locale:y(this.$root,"lang")});const i=this.findLabel();i.id||(i.id=`${this.id}-label`),this.$input.id=`${this.id}-input`;const s=document.createElement("button");s.classList.add("govuk-file-upload-button"),s.type="button",s.id=this.id,s.classList.add("govuk-file-upload-button--empty");const r=this.$input.getAttribute("aria-describedby");r&&s.setAttribute("aria-describedby",r);const a=document.createElement("span");a.className="govuk-body govuk-file-upload-button__status",a.setAttribute("aria-live","polite"),a.innerText=this.i18n.t("noFileChosen"),s.appendChild(a);const c=document.createElement("span");c.className="govuk-visually-hidden",c.innerText=", ",c.id=`${this.id}-comma`,s.appendChild(c);const l=document.createElement("span");l.className="govuk-file-upload-button__pseudo-button-container";const d=document.createElement("span");d.className="govuk-button govuk-button--secondary govuk-file-upload-button__pseudo-button",d.innerText=this.i18n.t("chooseFilesButton"),l.appendChild(d),l.insertAdjacentText("beforeend"," ");const h=document.createElement("span");h.className="govuk-body govuk-file-upload-button__instruction",h.innerText=this.i18n.t("dropInstruction"),l.appendChild(h),s.appendChild(l),s.setAttribute("aria-labelledby",`${i.id} ${c.id} ${s.id}`),s.addEventListener("click",this.onClick.bind(this)),s.addEventListener("dragover",(t=>{t.preventDefault()})),this.$root.insertAdjacentElement("afterbegin",s),this.$input.setAttribute("tabindex","-1"),this.$input.setAttribute("aria-hidden","true"),this.$button=s,this.$status=a,this.$input.addEventListener("change",this.onChange.bind(this)),this.updateDisabledState(),this.observeDisabledState(),this.$announcements=document.createElement("span"),this.$announcements.classList.add("govuk-file-upload-announcements"),this.$announcements.classList.add("govuk-visually-hidden"),this.$announcements.setAttribute("aria-live","assertive"),this.$root.insertAdjacentElement("afterend",this.$announcements),this.$button.addEventListener("drop",this.onDrop.bind(this)),document.addEventListener("dragenter",this.updateDropzoneVisibility.bind(this)),document.addEventListener("dragenter",(()=>{this.enteredAnotherElement=!0})),document.addEventListener("dragleave",(()=>{this.enteredAnotherElement||this.$button.disabled||(this.hideDraggingState(),this.$announcements.innerText=this.i18n.t("leftDropZone")),this.enteredAnotherElement=!1}))}updateDropzoneVisibility(t){this.$button.disabled||t.target instanceof Node&&(this.$root.contains(t.target)?t.dataTransfer&&x(t.dataTransfer)&&(this.$button.classList.contains("govuk-file-upload-button--dragging")||(this.showDraggingState(),this.$announcements.innerText=this.i18n.t("enteredDropZone"))):this.$button.classList.contains("govuk-file-upload-button--dragging")&&(this.hideDraggingState(),this.$announcements.innerText=this.i18n.t("leftDropZone")))}showDraggingState(){this.$button.classList.add("govuk-file-upload-button--dragging")}hideDraggingState(){this.$button.classList.remove("govuk-file-upload-button--dragging")}onDrop(t){t.preventDefault(),t.dataTransfer&&x(t.dataTransfer)&&(this.$input.files=t.dataTransfer.files,this.$input.dispatchEvent(new CustomEvent("change")),this.hideDraggingState())}onChange(){const t=this.$input.files.length;0===t?(this.$status.innerText=this.i18n.t("noFileChosen"),this.$button.classList.add("govuk-file-upload-button--empty")):(this.$status.innerText=1===t?this.$input.files[0].name:this.i18n.t("multipleFilesChosen",{count:t}),this.$button.classList.remove("govuk-file-upload-button--empty"))}findLabel(){const t=document.querySelector(`label[for="${this.$input.id}"]`);if(!t)throw new u({component:E,identifier:`Field label (\`<label for=${this.$input.id}>\`)`});return t}onClick(){this.$input.click()}observeDisabledState(){new MutationObserver((t=>{for(const e of t)"attributes"===e.type&&"disabled"===e.attributeName&&this.updateDisabledState()})).observe(this.$input,{attributes:!0})}updateDisabledState(){this.$button.disabled=this.$input.disabled,this.$root.classList.toggle("govuk-drop-zone--disabled",this.$button.disabled)}}function x(t){const e=0===t.types.length,n=t.types.some((t=>"Files"===t));return e||n}E.moduleName="govuk-file-upload",E.defaults=Object.freeze({i18n:{chooseFilesButton:"Choose file",dropInstruction:"or drop file",noFileChosen:"No file chosen",multipleFilesChosen:{one:"%{count} file chosen",other:"%{count} files chosen"},enteredDropZone:"Entered drop zone",leftDropZone:"Left drop zone"}}),E.schema=Object.freeze({properties:{i18n:{type:"object"}}});class S extends d{constructor(t){super(t),this.$menuButton=void 0,this.$menu=void 0,this.menuIsOpen=!1,this.mql=null;const e=this.$root.querySelector(".govuk-js-header-toggle");if(!e)return this;this.$root.classList.add("govuk-header--with-js-navigation");const n=e.getAttribute("aria-controls");if(!n)throw new u({component:S,identifier:'Navigation button (`<button class="govuk-js-header-toggle">`) attribute (`aria-controls`)'});const i=document.getElementById(n);if(!i)throw new u({component:S,element:i,identifier:`Navigation (\`<ul id="${n}">\`)`});this.$menu=i,this.$menuButton=e,this.setupResponsiveChecks(),this.$menuButton.addEventListener("click",(()=>this.handleMenuButtonClick()))}setupResponsiveChecks(){const t=e("desktop");if(!t.value)throw new u({component:S,identifier:`CSS custom property (\`${t.property}\`) on pseudo-class \`:root\``});this.mql=window.matchMedia(`(min-width: ${t.value})`),"addEventListener"in this.mql?this.mql.addEventListener("change",(()=>this.checkMode())):this.mql.addListener((()=>this.checkMode())),this.checkMode()}checkMode(){this.mql&&this.$menu&&this.$menuButton&&(this.mql.matches?(this.$menu.removeAttribute("hidden"),this.$menuButton.setAttribute("hidden","")):(this.$menuButton.removeAttribute("hidden"),this.$menuButton.setAttribute("aria-expanded",this.menuIsOpen.toString()),this.menuIsOpen?this.$menu.removeAttribute("hidden"):this.$menu.setAttribute("hidden","")))}handleMenuButtonClick(){this.menuIsOpen=!this.menuIsOpen,this.checkMode()}}S.moduleName="govuk-header";class L extends m{constructor(t,e={}){super(t,e),"alert"!==this.$root.getAttribute("role")||this.config.disableAutoFocus||n(this.$root)}}L.moduleName="govuk-notification-banner",L.defaults=Object.freeze({disableAutoFocus:!1}),L.schema=Object.freeze({properties:{disableAutoFocus:{type:"boolean"}}});class T extends m{constructor(t,e={}){super(t,e),this.i18n=void 0,this.$input=void 0,this.$showHideButton=void 0,this.$screenReaderStatusMessage=void 0;const n=this.$root.querySelector(".govuk-js-password-input-input");if(!(n instanceof HTMLInputElement))throw new u({component:T,element:n,expectedType:"HTMLInputElement",identifier:"Form field (`.govuk-js-password-input-input`)"});if("password"!==n.type)throw new u("Password input: Form field (`.govuk-js-password-input-input`) must be of type `password`.");const i=this.$root.querySelector(".govuk-js-password-input-toggle");if(!(i instanceof HTMLButtonElement))throw new u({component:T,element:i,expectedType:"HTMLButtonElement",identifier:"Button (`.govuk-js-password-input-toggle`)"});if("button"!==i.type)throw new u("Password input: Button (`.govuk-js-password-input-toggle`) must be of type `button`.");this.$input=n,this.$showHideButton=i,this.i18n=new v(this.config.i18n,{locale:y(this.$root,"lang")}),this.$showHideButton.removeAttribute("hidden");const s=document.createElement("div");s.className="govuk-password-input__sr-status govuk-visually-hidden",s.setAttribute("aria-live","polite"),this.$screenReaderStatusMessage=s,this.$input.insertAdjacentElement("afterend",s),this.$showHideButton.addEventListener("click",this.toggle.bind(this)),this.$input.form&&this.$input.form.addEventListener("submit",(()=>this.hide())),window.addEventListener("pageshow",(t=>{t.persisted&&"password"!==this.$input.type&&this.hide()})),this.hide()}toggle(t){t.preventDefault(),"password"!==this.$input.type?this.hide():this.show()}show(){this.setType("text")}hide(){this.setType("password")}setType(t){if(t===this.$input.type)return;this.$input.setAttribute("type",t);const e="password"===t,n=e?"show":"hide",i=e?"passwordHidden":"passwordShown";this.$showHideButton.innerText=this.i18n.t(`${n}Password`),this.$showHideButton.setAttribute("aria-label",this.i18n.t(`${n}PasswordAriaLabel`)),this.$screenReaderStatusMessage.innerText=this.i18n.t(`${i}Announcement`)}}T.moduleName="govuk-password-input",T.defaults=Object.freeze({i18n:{showPassword:"Show",hidePassword:"Hide",showPasswordAriaLabel:"Show password",hidePasswordAriaLabel:"Hide password",passwordShownAnnouncement:"Your password is visible",passwordHiddenAnnouncement:"Your password is hidden"}}),T.schema=Object.freeze({properties:{i18n:{type:"object"}}});class M extends d{constructor(t){super(t),this.$inputs=void 0;const e=this.$root.querySelectorAll('input[type="radio"]');if(!e.length)throw new u({component:M,identifier:'Form inputs (`<input type="radio">`)'});this.$inputs=e,this.$inputs.forEach((t=>{const e=t.getAttribute("data-aria-controls");if(e){if(!document.getElementById(e))throw new u({component:M,identifier:`Conditional reveal (\`id="${e}"\`)`});t.setAttribute("aria-controls",e),t.removeAttribute("data-aria-controls")}})),window.addEventListener("pageshow",(()=>this.syncAllConditionalReveals())),this.syncAllConditionalReveals(),this.$root.addEventListener("click",(t=>this.handleClick(t)))}syncAllConditionalReveals(){this.$inputs.forEach((t=>this.syncConditionalRevealWithInputState(t)))}syncConditionalRevealWithInputState(t){const e=t.getAttribute("aria-controls");if(!e)return;const n=document.getElementById(e);if(null!=n&&n.classList.contains("govuk-radios__conditional")){const e=t.checked;t.setAttribute("aria-expanded",e.toString()),n.classList.toggle("govuk-radios__conditional--hidden",!e)}}handleClick(t){const e=t.target;if(!(e instanceof HTMLInputElement)||"radio"!==e.type)return;const n=document.querySelectorAll('input[type="radio"][aria-controls]'),i=e.form,s=e.name;n.forEach((t=>{const e=t.form===i;t.name===s&&e&&this.syncConditionalRevealWithInputState(t)}))}}M.moduleName="govuk-radios";class _ extends d{constructor(t){super(t),this.$menuButton=void 0,this.$menu=void 0,this.menuIsOpen=!1,this.mql=null;const e=this.$root.querySelector(".govuk-js-service-navigation-toggle");if(!e)return this;const n=e.getAttribute("aria-controls");if(!n)throw new u({component:_,identifier:'Navigation button (`<button class="govuk-js-service-navigation-toggle">`) attribute (`aria-controls`)'});const i=document.getElementById(n);if(!i)throw new u({component:_,element:i,identifier:`Navigation (\`<ul id="${n}">\`)`});this.$menu=i,this.$menuButton=e,this.setupResponsiveChecks(),this.$menuButton.addEventListener("click",(()=>this.handleMenuButtonClick()))}setupResponsiveChecks(){const t=e("tablet");if(!t.value)throw new u({component:_,identifier:`CSS custom property (\`${t.property}\`) on pseudo-class \`:root\``});this.mql=window.matchMedia(`(min-width: ${t.value})`),"addEventListener"in this.mql?this.mql.addEventListener("change",(()=>this.checkMode())):this.mql.addListener((()=>this.checkMode())),this.checkMode()}checkMode(){this.mql&&this.$menu&&this.$menuButton&&(this.mql.matches?(this.$menu.removeAttribute("hidden"),this.$menuButton.setAttribute("hidden","")):(this.$menuButton.removeAttribute("hidden"),this.$menuButton.setAttribute("aria-expanded",this.menuIsOpen.toString()),this.menuIsOpen?this.$menu.removeAttribute("hidden"):this.$menu.setAttribute("hidden","")))}handleMenuButtonClick(){this.menuIsOpen=!this.menuIsOpen,this.checkMode()}}_.moduleName="govuk-service-navigation";class I extends d{constructor(e){var i;super(e);const s=this.$root.hash,o=null!=(i=this.$root.getAttribute("href"))?i:"";let r;try{r=new window.URL(this.$root.href)}catch(t){throw new u(`Skip link: Target link (\`href="${o}"\`) is invalid`)}if(r.origin!==window.location.origin||r.pathname!==window.location.pathname)return;const a=t(s);if(!a)throw new u(`Skip link: Target link (\`href="${o}"\`) has no hash fragment`);const c=document.getElementById(a);if(!c)throw new u({component:I,element:c,identifier:`Target content (\`id="${a}"\`)`});this.$root.addEventListener("click",(()=>n(c,{onBeforeFocus(){c.classList.add("govuk-skip-link-focused-element")},onBlur(){c.classList.remove("govuk-skip-link-focused-element")}})))}}I.elementType=HTMLAnchorElement,I.moduleName="govuk-skip-link";class B extends d{constructor(t){super(t),this.$tabs=void 0,this.$tabList=void 0,this.$tabListItems=void 0,this.jsHiddenClass="govuk-tabs__panel--hidden",this.changingHash=!1,this.boundTabClick=void 0,this.boundTabKeydown=void 0,this.boundOnHashChange=void 0,this.mql=null;const e=this.$root.querySelectorAll("a.govuk-tabs__tab");if(!e.length)throw new u({component:B,identifier:'Links (`<a class="govuk-tabs__tab">`)'});this.$tabs=e,this.boundTabClick=this.onTabClick.bind(this),this.boundTabKeydown=this.onTabKeydown.bind(this),this.boundOnHashChange=this.onHashChange.bind(this);const n=this.$root.querySelector(".govuk-tabs__list"),i=this.$root.querySelectorAll("li.govuk-tabs__list-item");if(!n)throw new u({component:B,identifier:'List (`<ul class="govuk-tabs__list">`)'});if(!i.length)throw new u({component:B,identifier:'List items (`<li class="govuk-tabs__list-item">`)'});this.$tabList=n,this.$tabListItems=i,this.setupResponsiveChecks()}setupResponsiveChecks(){const t=e("tablet");if(!t.value)throw new u({component:B,identifier:`CSS custom property (\`${t.property}\`) on pseudo-class \`:root\``});this.mql=window.matchMedia(`(min-width: ${t.value})`),"addEventListener"in this.mql?this.mql.addEventListener("change",(()=>this.checkMode())):this.mql.addListener((()=>this.checkMode())),this.checkMode()}checkMode(){var t;null!=(t=this.mql)&&t.matches?this.setup():this.teardown()}setup(){var t;this.$tabList.setAttribute("role","tablist"),this.$tabListItems.forEach((t=>{t.setAttribute("role","presentation")})),this.$tabs.forEach((t=>{this.setAttributes(t),t.addEventListener("click",this.boundTabClick,!0),t.addEventListener("keydown",this.boundTabKeydown,!0),this.hideTab(t)}));const e=null!=(t=this.getTab(window.location.hash))?t:this.$tabs[0];this.showTab(e),window.addEventListener("hashchange",this.boundOnHashChange,!0)}teardown(){this.$tabList.removeAttribute("role"),this.$tabListItems.forEach((t=>{t.removeAttribute("role")})),this.$tabs.forEach((t=>{t.removeEventListener("click",this.boundTabClick,!0),t.removeEventListener("keydown",this.boundTabKeydown,!0),this.unsetAttributes(t)})),window.removeEventListener("hashchange",this.boundOnHashChange,!0)}onHashChange(){const t=window.location.hash,e=this.getTab(t);if(!e)return;if(this.changingHash)return void(this.changingHash=!1);const n=this.getCurrentTab();n&&(this.hideTab(n),this.showTab(e),e.focus())}hideTab(t){this.unhighlightTab(t),this.hidePanel(t)}showTab(t){this.highlightTab(t),this.showPanel(t)}getTab(t){return this.$root.querySelector(`a.govuk-tabs__tab[href="${t}"]`)}setAttributes(e){const n=t(e.href);if(!n)return;e.setAttribute("id",`tab_${n}`),e.setAttribute("role","tab"),e.setAttribute("aria-controls",n),e.setAttribute("aria-selected","false"),e.setAttribute("tabindex","-1");const i=this.getPanel(e);i&&(i.setAttribute("role","tabpanel"),i.setAttribute("aria-labelledby",e.id),i.classList.add(this.jsHiddenClass))}unsetAttributes(t){t.removeAttribute("id"),t.removeAttribute("role"),t.removeAttribute("aria-controls"),t.removeAttribute("aria-selected"),t.removeAttribute("tabindex");const e=this.getPanel(t);e&&(e.removeAttribute("role"),e.removeAttribute("aria-labelledby"),e.classList.remove(this.jsHiddenClass))}onTabClick(t){const e=this.getCurrentTab(),n=t.currentTarget;e&&n instanceof HTMLAnchorElement&&(t.preventDefault(),this.hideTab(e),this.showTab(n),this.createHistoryEntry(n))}createHistoryEntry(t){const e=this.getPanel(t);if(!e)return;const n=e.id;e.id="",this.changingHash=!0,window.location.hash=n,e.id=n}onTabKeydown(t){switch(t.key){case"ArrowLeft":case"Left":this.activatePreviousTab(),t.preventDefault();break;case"ArrowRight":case"Right":this.activateNextTab(),t.preventDefault()}}activateNextTab(){const t=this.getCurrentTab();if(null==t||!t.parentElement)return;const e=t.parentElement.nextElementSibling;if(!e)return;const n=e.querySelector("a.govuk-tabs__tab");n&&(this.hideTab(t),this.showTab(n),n.focus(),this.createHistoryEntry(n))}activatePreviousTab(){const t=this.getCurrentTab();if(null==t||!t.parentElement)return;const e=t.parentElement.previousElementSibling;if(!e)return;const n=e.querySelector("a.govuk-tabs__tab");n&&(this.hideTab(t),this.showTab(n),n.focus(),this.createHistoryEntry(n))}getPanel(e){const n=t(e.href);return n?this.$root.querySelector(`#${n}`):null}showPanel(t){const e=this.getPanel(t);e&&e.classList.remove(this.jsHiddenClass)}hidePanel(t){const e=this.getPanel(t);e&&e.classList.add(this.jsHiddenClass)}unhighlightTab(t){t.parentElement&&(t.setAttribute("aria-selected","false"),t.parentElement.classList.remove("govuk-tabs__list-item--selected"),t.setAttribute("tabindex","-1"))}highlightTab(t){t.parentElement&&(t.setAttribute("aria-selected","true"),t.parentElement.classList.add("govuk-tabs__list-item--selected"),t.setAttribute("tabindex","0"))}getCurrentTab(){return this.$root.querySelector(".govuk-tabs__list-item--selected a.govuk-tabs__tab")}}B.moduleName="govuk-tabs";var O={xs:0,mobile:320,tablet:641,desktop:769};function H(t){return Object.keys(O).reduce((function(e,n){return(t||window.innerWidth)>=O[n]?n:e}))}var j=function(t){return t.innerWidth<=768};function N(t){this.$module=document.querySelector(t),this.$moduleBottomMargin=this.$module.style.marginBottom,this.$mainNav=this.$module.querySelector(".hmrc-account-menu__main"),this.$showNavLinkMobile=this.$module.querySelector(".hmrc-account-menu__link--menu"),this.$currentBreakpoint=H()}function q(t,e,n){this.$module=t,this.window=e,this.document=n}function D(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,R(i.key),i)}}function F(t,e,n){return(e=R(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function P(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function R(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,e||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:e+""}function U(t){return U="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},U(t)}N.prototype.init=function(){this.setup(),this.$showNavLinkMobile.addEventListener("click",this.eventHandlers.showNavLinkMobileClick.bind(this)),window.addEventListener("resize",function(t,e,n){var i,s=this;return function(){for(var o=arguments.length,r=new Array(o),a=0;a<o;a++)r[a]=arguments[a];var c=s,u=n&&!i;clearTimeout(i),i=setTimeout((function(){i=null,n||t.apply(c,r)}),e),u&&t.apply(c,r)}}(this.reinstantiate.bind(this)))},N.prototype.reinstantiate=function(t){var e=H(t.target.innerWidth);this.$currentBreakpoint!==e&&(this.$currentBreakpoint=e,this.setup())},N.prototype.eventHandlers={showNavLinkMobileClick:function(t){t.preventDefault(),j(window)&&(this.$mainNav.classList.contains("main-nav-is-open")?this.hideMainNavMobile(t.currentTarget):this.showMainNavMobile())}},N.prototype.setup=function(){j(window)?(this.$module.classList.add("is-smaller"),this.$showNavLinkMobile.setAttribute("aria-hidden","false"),this.$showNavLinkMobile.removeAttribute("tabindex"),this.$showNavLinkMobile.classList.remove("js-hidden"),this.hideMainNavMobile(this.$showNavLinkMobile)):(this.$module.classList.remove("is-smaller"),this.$mainNav.classList.remove("main-nav-is-open","js-hidden"),this.$showNavLinkMobile.setAttribute("aria-hidden","true"),this.$showNavLinkMobile.setAttribute("tabindex","-1"),this.$showNavLinkMobile.classList.add("js-hidden"))},N.prototype.showMainNavMobile=function(){this.$mainNav.classList.remove("js-hidden"),this.$mainNav.classList.add("main-nav-is-open"),this.$mainNav.setAttribute("aria-expanded","true"),this.$showNavLinkMobile.setAttribute("aria-expanded","true"),this.$showNavLinkMobile.classList.add("hmrc-account-home--account--is-open")},N.prototype.hideMainNavMobile=function(t){this.$mainNav.classList.remove("main-nav-is-open"),this.$mainNav.setAttribute("aria-expanded","false"),t.classList.contains("hmrc-account-menu__link--menu")&&(this.$mainNav.classList.add("js-hidden"),this.$showNavLinkMobile.setAttribute("aria-expanded","false"),this.$showNavLinkMobile.classList.remove("hmrc-account-home--account--is-open"))},q.prototype.init=function(){var t=this;this.window.history&&(this.window.history.replaceState&&"function"==typeof this.window.history.replaceState&&this.window.history.replaceState(null,null,this.window.location.href),this.$module.addEventListener("click",(function(e){e.preventDefault(),t.window.history.back&&"function"==typeof t.window.history.back&&t.window.history.back()})))};var z=console.warn,K={generateDomElementFromString:function(t){var e=document.createElement("div");return e.innerHTML=t,e.firstChild},generateDomElementFromStringAndAppendText:function(t,e){var n=K.generateDomElementFromString(t);return n.innerText=e,n},hasClass:function(t,e){return document.querySelector(t).classList.contains(e)},addClass:function(t,e){document.querySelectorAll(t).forEach((function(t){t.classList.add(e)}))},removeClass:function(t,e){document.querySelectorAll(t).forEach((function(t){t.classList.remove(e)}))},removeElement:function(t){var e=t.parentNode;e?e.removeChild(t):z("couldn't find parent for elem",t)},ajaxGet:function(t,e){var n=new XMLHttpRequest;return n.open("GET",t),n.onreadystatechange=function(){n.readyState>3&&200===n.status&&e(n.responseText)},n.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.send(),n}};var V={displayDialog:function(t){var e=K.generateDomElementFromString('<div id="hmrc-timeout-dialog" tabindex="-1" role="dialog" aria-modal="true" class="hmrc-timeout-dialog">'),n=K.generateDomElementFromString('<div id="hmrc-timeout-overlay" class="hmrc-timeout-overlay">'),i="string"==typeof t?K.generateDomElementFromString(t):t,s=[],o=[];e.appendChild(i),K.hasClass("html","noScroll")||(K.addClass("html","noScroll"),s.push((function(){K.removeClass("html","noScroll")}))),document.body.appendChild(e),document.body.appendChild(n),s.push((function(){K.removeElement(e),K.removeElement(n)}));var r,a=document.querySelectorAll(["#skiplink-container","body > header","#global-cookie-message","main","body > footer","body > .govuk-skip-link",".cbanner-govuk-cookie-banner","body > .govuk-width-container"].join(", ")),c=function(){for(;s.length>0;){s.shift()()}};return a.forEach((function(t){var e=t.getAttribute("aria-hidden");t.setAttribute("aria-hidden","true"),s.push((function(){e?t.setAttribute("aria-hidden",e):t.removeAttribute("aria-hidden")}))})),function(){function t(t){var e=document.getElementById("hmrc-timeout-dialog");e&&(t.target===e||e.contains(t.target)||(t.stopPropagation(),e.focus()))}var n=document.activeElement;e.focus(),document.addEventListener("focus",t,!0),s.push((function(){document.removeEventListener("focus",t),n.focus()}))}(),function(){function t(t){27===t.keyCode&&(o.forEach((function(t){t()})),c())}document.addEventListener("keydown",t),s.push((function(){document.removeEventListener("keydown",t)}))}(),r=function(t){1===(t.touches||t.changedTouches||[]).length&&t.preventDefault()},document.addEventListener("touchmove",r,!0),s.push((function(){document.removeEventListener("touchmove",r,!0)})),{closeDialog:function(){c()},setAriaLabelledBy:function(t){t?e.setAttribute("aria-labelledby",t):e.removeAttribute("aria-labelledby")},addCloseHandler:function(t){o.push(t)}}}};function W(){}function Y(){}function G(t,e){var n,i={},s={},o=[],r=e;var a=function(){s.synchroniseTabs&&r.onActivity((function(t){var e=t.timestamp;f(),l(e)}))},c=function(t){var e=[];if(["timeout","countdown","keepAliveUrl","signOutUrl"].forEach((function(n){t[n]||e.push("data-".concat(n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()))})),e.length>0)throw new Error("Missing config item(s): [".concat(e.join(", "),"]"))},u=function t(e,n){var i=function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?P(Object(n),!0).forEach((function(e){F(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({},e);return Object.keys(n).forEach((function(s){"object"===U(i[s])&&(i[s]=t(e[s],n[s])),void 0!==i[s]&&""!==i[s]||(i[s]=n[s])})),i},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m(),e=t+1e3*s.timeout,i=m()-t,r=s.timeout-s.countdown,a=window.setTimeout((function(){d(e)}),1e3*r-i);o.push((function(){window.clearTimeout(a),n&&window.clearTimeout(n)}))},d=function(t){var e=K.generateDomElementFromString("<div>");if(s.title){var i=K.generateDomElementFromStringAndAppendText('<h1 id="hmrc-timeout-heading" class="govuk-heading-m push--top">',s.title);e.appendChild(i)}var r=K.generateDomElementFromString('<span id="hmrc-timeout-countdown" class="hmrc-timeout-dialog__countdown">'),a=K.generateDomElementFromString('<p id="hmrc-timeout-message" class="govuk-visually-hidden screenreader-content" aria-live="assertive">'),c=K.generateDomElementFromStringAndAppendText('<p class="govuk-body hmrc-timeout-dialog__message" aria-hidden="true">',s.message);c.appendChild(document.createTextNode(" ")),c.appendChild(r),s.messageSuffix&&c.appendChild(document.createTextNode(" ".concat(s.messageSuffix)));var u=K.generateDomElementFromStringAndAppendText('<button id="hmrc-timeout-keep-signin-btn" class="govuk-button">',s.keepAliveButtonText),l=document.createElement("div");if(l.classList.add("govuk-button-group"),l.appendChild(u),e.appendChild(c),e.appendChild(a),u.addEventListener("click",h),e.appendChild(document.createTextNode(" ")),!s.hideSignOutButton){var d=K.generateDomElementFromStringAndAppendText('<a id="hmrc-timeout-sign-out-link" class="govuk-link hmrc-timeout-dialog__link">',s.signOutButtonText);d.addEventListener("click",p),d.setAttribute("href",s.signOutUrl),l.appendChild(d)}e.appendChild(l);var f=V.displayDialog(e);o.push((function(){f.closeDialog()})),f.addCloseHandler(h),f.setAriaLabelledBy("hmrc-timeout-heading hmrc-timeout-message");var v=function(){return t-m()},b=function(t){var e,n;return t<60?n="".concat(t," ").concat(s.properties[1!==t?"seconds":"second"],"."):(e=Math.ceil(t/60),n="".concat(e," ").concat(s.properties[1===e?"minute":"minutes"],".")),n},w=function(t){return t>60?t:t<20?20:20*Math.ceil(t/20)},y=function(t,e){t.innerText!==e&&(t.innerText=e)},$=function(t){var e=b(t),n=function(t){var e=b(w(t)),n=[s.message," ",e];return s.messageSuffix&&(n.push(" "),n.push(s.messageSuffix)),n.join("")}(t);y(r,e),y(a,n)};!function t(){var e,i,s=Math.max(Math.round(v()/1e3),0);$(s),0===s?g():n=window.setTimeout(t,(e=v(),(i=1e3*Math.floor(v()/1e3))<=6e4?e-i||1e3:e-(i-(i%6e4||6e4))))}()},h=function(){f(),l(),K.ajaxGet(s.keepAliveUrl,(function(){})),r.logActivity()},m=function(){return Date.now()},p=function(){Y.redirectToUrl(s.signOutUrl)},g=function(){Y.redirectToUrl(s.timeoutUrl)},f=function(){for(;o.length>0;){o.shift()()}};return{init:function(){var e=W;function n(e){return(t.attributes.getNamedItem(e)||{}).value}var o="cy"===e.string(n("data-language"))?{title:"Rydych ar fin cael eich allgofnodi",message:"Er eich diogelwch, byddwn yn eich allgofnodi cyn pen",keepAliveButtonText:"Parhau i fod wedi’ch mewngofnodi",signOutButtonText:"Allgofnodi",properties:{minutes:"funud",minute:"funud",seconds:"eiliad",second:"eiliad"}}:{title:"You’re about to be signed out",message:"For your security, we will sign you out in",keepAliveButtonText:"Stay signed in",signOutButtonText:"Sign out",properties:{minutes:"minutes",minute:"minute",seconds:"seconds",second:"second"}};(i={timeout:e.int(n("data-timeout")),countdown:e.int(n("data-countdown")),keepAliveUrl:e.string(n("data-keep-alive-url")),signOutUrl:e.string(n("data-sign-out-url")),timeoutUrl:e.string(n("data-timeout-url")),title:e.string(n("data-title")),message:e.string(n("data-message")),messageSuffix:e.string(n("data-message-suffix")),keepAliveButtonText:e.string(n("data-keep-alive-button-text")),signOutButtonText:e.string(n("data-sign-out-button-text")),synchroniseTabs:e.boolean(n("data-synchronise-tabs")||!1),hideSignOutButton:e.boolean(n("data-hide-sign-out-button")||!1)}).timeoutUrl=i.timeoutUrl||i.signOutUrl,c(i),s=u(i,o),l(),a()},cleanup:f}}W.int=function(t){var e=parseInt(t,10);return Number.isNaN(e)?void 0:e},W.string=function(t){return"string"==typeof t?t:void 0},W.boolean=function(t){return"true"===String(t).toLowerCase()},Y.redirectToUrl=function(t){window.location.href=t},G.dialog=V,G.redirectHelper=Y,G.utils=K;function Z(t){this.$module=t,this.$closeLink=this.$module.querySelector(".hmrc-user-research-banner__close"),this.cookieName="mdtpurr",this.cookieExpiryDays=28}Z.prototype.init=function(){null==function(t){for(var e="".concat(t,"="),n=document.cookie.split(";"),i=0,s=n.length;i<s;i+=1){for(var o=n[i];" "===o.charAt(0);)o=o.substring(1,o.length);if(0===o.indexOf(e))return decodeURIComponent(o.substring(e.length))}return null}(this.cookieName)&&(this.$module.classList.add("hmrc-user-research-banner--show"),this.$closeLink.addEventListener("click",this.eventHandlers.noThanksClick.bind(this)))},Z.prototype.eventHandlers={noThanksClick:function(t){t.preventDefault(),function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i="".concat(t,"=").concat(e,"; path=/");if(n.days){var s=new Date;s.setTime(s.getTime()+24*n.days*60*60*1e3),i="".concat(i,"; expires=").concat(s.toGMTString())}"https:"===window.location.protocol&&(i+="; Secure"),document.cookie=i}(this.cookieName,"suppress_for_all_services",{days:this.cookieExpiryDays}),this.$module.classList.remove("hmrc-user-research-banner--show")}};var X=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.activityChannel=e&&new e("session-activity")}return function(t,e,n){e&&D(t.prototype,e),n&&D(t,n),Object.defineProperty(t,"prototype",{writable:!1})}(t,[{key:"logActivity",value:function(){if(this.activityChannel){var t={timestamp:Date.now()};this.activityChannel.postMessage(t)}}},{key:"onActivity",value:function(t){this.activityChannel&&(this.activityChannel.onmessage=function(e){t(e.data)})}}]),t}();function J(t,e){this.$module=t,this.window=e}J.prototype.init=function(){var t=this;this.$module.addEventListener("click",(function(e){e.preventDefault(),t.window.print()}))};var Q={initAll:function(){function t(t){try{t()}catch(t){console.error("hmrc-frontend component initialisation failed",t)}}var e='[data-module="hmrc-account-menu"]';document.querySelector(e)&&t((function(){new N(e).init()})),document.querySelectorAll('a[data-module="hmrc-print-link"]').forEach((function(e){t((function(){new J(e,window).init()}))}));var n=new X(window.BroadcastChannel);n.logActivity();var i=document.querySelector('meta[name="hmrc-timeout-dialog"]');i&&t((function(){new G(i,n).init()}));var s=document.querySelector('[data-module="hmrc-user-research-banner"]');s&&t((function(){new Z(s).init()})),document.querySelectorAll('[data-module="hmrc-back-link"]').forEach((function(e){t((function(){new q(e,window,document).init()}))}))},AccountMenu:N,TimeoutDialog:G,UserResearchBanner:Z,BackLinkHelper:q};!function(t){var e;if(t=void 0!==t?t:{},!i())return void(t.onError?t.onError(new a,{config:t}):console.log(new a));const n=[[b,t.accordion],[w,t.button],[$,t.characterCount],[k],[C,t.errorSummary],[A,t.exitThisPage],[E,t.fileUpload],[S],[L,t.notificationBanner],[T,t.passwordInput],[M],[_],[I],[B]],s={scope:null!=(e=t.scope)?e:document,onError:t.onError};n.forEach((([t,e])=>{!function(t,e,n){let s,o=document;var r;"object"==typeof n&&(o=null!=(r=n.scope)?r:o,s=n.onError),"function"==typeof n&&(s=n),n instanceof HTMLElement&&(o=n);const c=o.querySelectorAll(`[data-module="${t.moduleName}"]`);i()?Array.from(c).map((n=>{try{return void 0!==e?new t(n,e):new t(n)}catch(i){return s?s(i,{element:n,component:t,config:e}):console.log(i),null}})).filter(Boolean):s?s(new a,{component:t,config:e}):console.log(new a)}(t,e,s)}))}(),Q.initAll()}();
2
2
 
3
- //# sourceMappingURL=maps/hmrc-frontend-6.78.0.min.js.map
3
+ //# sourceMappingURL=maps/hmrc-frontend-6.80.0.min.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/accessible-autocomplete/dist/accessible-autocomplete.min.css","accessible-autocomplete.css","govuk-frontend/dist/govuk/settings/govuk-frontend/dist/govuk/tools/govuk-frontend/dist/govuk/helpers/accessible-autocomplete/dist/accessible-autocomplete.min%22;%0A%0A.autocomplete__wrapper,%0A.autocomplete__input,%0A.autocomplete__option,%0A.autocomplete__hint%20%7B%0A%20%20@include%20govuk-font($size:%2019);%0A%7D%0A%0A/%20the%20following%20makes%20the%20autocomplete%20inherit%20error%20styles%0A/%20it%20won't%20work%20in%20IE11%20but%20selects%20won't%20be%20enhanced%20into%20autocompletes%20in%20IE11%0A%0A.govuk-form-group--error%20div:has(+%20.govuk-select--error%5Bdata-module='hmrc-accessible-autocomplete'%5D)%20%3E%20.autocomplete__wrapper%20.autocomplete__input%20%7B%0A%20%20border-color:%20%23d4351c;%0A%7D%0A%0A/%20the%20following%20makes%20the%20dropdown%20arrow%20appear%20when%20showing%20all%20values%0A%0A.autocomplete__dropdown-arrow-down%20%7B%0A%20%20z-index:%200;%0A%20%20pointer-events:%20none;%0A%7D%0A","file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/govuk-frontend/dist/govuk/helpers/_typography.scss","file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.scss","file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/govuk-frontend/dist/govuk/vendor/_sass-mq.scss"],"names":[],"mappings":"AAAA,uBAAuB,iBCgDvB,CDhDyC,yCAAyC,uBAAA,CAAwB,oBAAA,CAAA,eAAA,CAAgB,wBAAA,CAAyB,eAAA,CAAgB,6BAAA,CAAA,qBAAA,CAAsB,aAAA,CAAc,gBAAA,CAAiB,eAAA,CAAgB,UC4DxO,CD5DmP,qBAAqB,8BAAA,CAA6B,iBCiErS,CDjEuT,oBAAoB,aAAA,CAAc,iBCsEzV,CDtE2W,8BAA8B,WC0EzY,CD1EqZ,8BAA8B,kCAAA,CAAA,0BAAA,CAA2B,sBAAA,CAAuB,gBCgFre,CDhFsf,sCAAsC,cAAA,CAAe,wBCqF3iB,CDrFokB,mCAAmC,oBAAA,CAAqB,WAAA,CAAY,iBAAA,CAAkB,SAAA,CAAU,QAAA,CAAS,UAAA,CAAW,UC+FxrB,CD/FmsB,oBAAoB,qBAAA,CAAsB,wBAAA,CAAyB,YAAA,CAAa,aAAA,CAAc,QAAA,CAAS,gBAAA,CAAiB,iBAAA,CAAkB,SAAA,CAAU,UAAA,CAAW,sBC4Gl2B,CD5Gy3B,6BAA6B,aCgHt5B,CDhHo6B,4BAA4B,YCoHh8B,CDpH68B,6BAA6B,6CAAA,CAAA,qCAAA,CAAsC,MAAA,CAAO,iBAAA,CAAkB,QAAA,CAAS,WC4HljC,CD5H8jC,4BAA4B,iBCgI1lC,CDhI4mC,sBAAsB,+BAAA,CAAgC,mBAAA,CAAoB,oBAAA,CAAqB,oBAAA,CAAqB,cAAA,CAAe,aAAA,CAAc,iBC0I7vC,CD1I+wC,wBAAwB,mBC8IvyC,CD9I2zC,oCAAoC,kBCkJ/1C,CDlJk3C,mCAAmC,qBCsJr5C,CDtJ26C,2BAA2B,wBC0Jt8C,CD1J+9C,2DAA2D,wBAAA,CAAyB,oBAAA,CAAqB,UAAA,CAAW,YCiKnlD,CDjKgmD,yDAAyD,oBAAoB,sBCsK3qD,CDtKksD,sBAAsB,sBAAA,CAAuB,eC0K/uD,CD1K+vD,2DAA2D,0BAAA,CAA2B,6BAAA,CAA8B,yBAAA,CAA0B,mBAAA,CAAoB,sBAAA,CAAuB,wBAAA,CAAyB,8BCmLj9D,CACF,CDpLm/D,kCAAkC,wBAAA,CAAyB,aAAA,CAAc,kBCyL5jE,CDzL+kE,+DAA+D,cAAA,CAAe,eC8L7pE,CD9L6qE,0CAA0C,WCkMvtE,CDlMmuE,yBAAyB,+DAA+D,mBAAA,CAAoB,wBCwM70E,CACF,CClMA,sFCQE,0CCFkB,CDGlB,kCAAA,CACA,iCAAA,CAkCA,eAAA,CA4LI,cAJc,CAKd,gBF3BN,CIeQ,aH7NR,sFCmBI,sBFkMF,CACF,CIOQ,6BH7NR,sFCiPQ,mBAbY,CAcZ,wBFpBN,CACF,CIFQ,aH7NR,sFC4OQ,cATQ,CAUR,gBFNN,CACF,CC9NA,8IACE,oBDiOF,CC5NA,mCACE,SAAA,CACA,mBD+NF","file":"../accessible-autocomplete-6.78.0.css","sourcesContent":[".autocomplete__wrapper{position:relative}.autocomplete__hint,.autocomplete__input{-webkit-appearance:none;appearance:none;border:2px solid #0b0c0c;border-radius:0;box-sizing:border-box;height:2.5rem;line-height:1.25;margin-bottom:0;width:100%}.autocomplete__input{background-color:transparent;position:relative}.autocomplete__hint{color:#505a5f;position:absolute}.autocomplete__input--default{padding:5px}.autocomplete__input--focused{box-shadow:inset 0 0 0 2px;outline:3px solid #fd0;outline-offset:0}.autocomplete__input--show-all-values{cursor:pointer;padding:5px 35px 5px 5px}.autocomplete__dropdown-arrow-down{display:inline-block;height:24px;position:absolute;right:8px;top:10px;width:24px;z-index:-1}.autocomplete__menu{background-color:#fff;border:2px solid #0b0c0c;border-top:0;color:#0b0c0c;margin:0;max-height:342px;overflow-x:hidden;padding:0;width:100%;width:calc(100% - 4px)}.autocomplete__menu--visible{display:block}.autocomplete__menu--hidden{display:none}.autocomplete__menu--overlay{box-shadow:0 2px 6px rgba(0,0,0,.257);left:0;position:absolute;top:100%;z-index:100}.autocomplete__menu--inline{position:relative}.autocomplete__option{border-bottom:1px solid #b1b4b6;border-left-width:0;border-right-width:0;border-top-width:1px;cursor:pointer;display:block;position:relative}.autocomplete__option>*{pointer-events:none}.autocomplete__option:first-of-type{border-top-width:0}.autocomplete__option:last-of-type{border-bottom-width:0}.autocomplete__option--odd{background-color:#f3f2f1}.autocomplete__option--focused,.autocomplete__option:hover{background-color:#1d70b8;border-color:#1d70b8;color:#fff;outline:none}@media (-ms-high-contrast:active),(forced-colors:active){.autocomplete__menu{border-color:FieldText}.autocomplete__option{background-color:Field;color:FieldText}.autocomplete__option--focused,.autocomplete__option:hover{background-color:Highlight;background-color:SelectedItem;border-color:SelectedItem;color:HighlightText;color:SelectedItemText;forced-color-adjust:none;outline-color:SelectedItemText}}.autocomplete__option--no-results{background-color:#f3f2f1;color:#505a5f;cursor:not-allowed}.autocomplete__hint,.autocomplete__input,.autocomplete__option{font-size:1rem;font-weight:400}.autocomplete__hint,.autocomplete__option{padding:5px}@media (min-width:641px){.autocomplete__hint,.autocomplete__input,.autocomplete__option{font-size:1.1875rem;line-height:1.3157894737}}\n\n/*# sourceMappingURL=accessible-autocomplete.min.css.map*/","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.autocomplete__wrapper {\n position: relative;\n}\n\n.autocomplete__hint, .autocomplete__input {\n -webkit-appearance: none;\n appearance: none;\n border: 2px solid #0b0c0c;\n border-radius: 0;\n box-sizing: border-box;\n height: 2.5rem;\n line-height: 1.25;\n margin-bottom: 0;\n width: 100%;\n}\n\n.autocomplete__input {\n background-color: transparent;\n position: relative;\n}\n\n.autocomplete__hint {\n color: #505a5f;\n position: absolute;\n}\n\n.autocomplete__input--default {\n padding: 5px;\n}\n\n.autocomplete__input--focused {\n box-shadow: inset 0 0 0 2px;\n outline: 3px solid #fd0;\n outline-offset: 0;\n}\n\n.autocomplete__input--show-all-values {\n cursor: pointer;\n padding: 5px 35px 5px 5px;\n}\n\n.autocomplete__dropdown-arrow-down {\n display: inline-block;\n height: 24px;\n position: absolute;\n right: 8px;\n top: 10px;\n width: 24px;\n z-index: -1;\n}\n\n.autocomplete__menu {\n background-color: #fff;\n border: 2px solid #0b0c0c;\n border-top: 0;\n color: #0b0c0c;\n margin: 0;\n max-height: 342px;\n overflow-x: hidden;\n padding: 0;\n width: 100%;\n width: calc(100% - 4px);\n}\n\n.autocomplete__menu--visible {\n display: block;\n}\n\n.autocomplete__menu--hidden {\n display: none;\n}\n\n.autocomplete__menu--overlay {\n box-shadow: 0 2px 6px rgba(0, 0, 0, 0.257);\n left: 0;\n position: absolute;\n top: 100%;\n z-index: 100;\n}\n\n.autocomplete__menu--inline {\n position: relative;\n}\n\n.autocomplete__option {\n border-bottom: 1px solid #b1b4b6;\n border-left-width: 0;\n border-right-width: 0;\n border-top-width: 1px;\n cursor: pointer;\n display: block;\n position: relative;\n}\n\n.autocomplete__option > * {\n pointer-events: none;\n}\n\n.autocomplete__option:first-of-type {\n border-top-width: 0;\n}\n\n.autocomplete__option:last-of-type {\n border-bottom-width: 0;\n}\n\n.autocomplete__option--odd {\n background-color: #f3f2f1;\n}\n\n.autocomplete__option--focused, .autocomplete__option:hover {\n background-color: #1d70b8;\n border-color: #1d70b8;\n color: #fff;\n outline: none;\n}\n\n@media (-ms-high-contrast: active), (forced-colors: active) {\n .autocomplete__menu {\n border-color: FieldText;\n }\n .autocomplete__option {\n background-color: Field;\n color: FieldText;\n }\n .autocomplete__option--focused, .autocomplete__option:hover {\n background-color: Highlight;\n background-color: SelectedItem;\n border-color: SelectedItem;\n color: HighlightText;\n color: SelectedItemText;\n forced-color-adjust: none;\n outline-color: SelectedItemText;\n }\n}\n.autocomplete__option--no-results {\n background-color: #f3f2f1;\n color: #505a5f;\n cursor: not-allowed;\n}\n\n.autocomplete__hint, .autocomplete__input, .autocomplete__option {\n font-size: 1rem;\n font-weight: 400;\n}\n\n.autocomplete__hint, .autocomplete__option {\n padding: 5px;\n}\n\n@media (min-width: 641px) {\n .autocomplete__hint, .autocomplete__input, .autocomplete__option {\n font-size: 1.1875rem;\n line-height: 1.3157894737;\n }\n}\n\n.autocomplete__wrapper,\n.autocomplete__input,\n.autocomplete__option,\n.autocomplete__hint {\n font-family: \"GDS Transport\", arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n font-weight: 400;\n font-size: 1rem;\n line-height: 1.25;\n}\n@media print {\n .autocomplete__wrapper,\n .autocomplete__input,\n .autocomplete__option,\n .autocomplete__hint {\n font-family: sans-serif;\n }\n}\n@media (min-width: 40.0625em) {\n .autocomplete__wrapper,\n .autocomplete__input,\n .autocomplete__option,\n .autocomplete__hint {\n font-size: 1.1875rem;\n line-height: 1.3157894737;\n }\n}\n@media print {\n .autocomplete__wrapper,\n .autocomplete__input,\n .autocomplete__option,\n .autocomplete__hint {\n font-size: 14pt;\n line-height: 1.15;\n }\n}\n\n.govuk-form-group--error div:has(+ .govuk-select--error[data-module=hmrc-accessible-autocomplete]) > .autocomplete__wrapper .autocomplete__input {\n border-color: #d4351c;\n}\n\n.autocomplete__dropdown-arrow-down {\n z-index: 0;\n pointer-events: none;\n}","$govuk-include-default-font-face: false;\n\n@import \"../../govuk-frontend/dist/govuk/settings/index\";\n@import \"../../govuk-frontend/dist/govuk/tools/index\";\n@import \"../../govuk-frontend/dist/govuk/helpers/index\";\n@import \"../../accessible-autocomplete/dist/accessible-autocomplete.min\";\n\n.autocomplete__wrapper,\n.autocomplete__input,\n.autocomplete__option,\n.autocomplete__hint {\n @include govuk-font($size: 19);\n}\n\n// the following makes the autocomplete inherit error styles\n// it won't work in IE11 but selects won't be enhanced into autocompletes in IE11\n\n.govuk-form-group--error div:has(+ .govuk-select--error[data-module='hmrc-accessible-autocomplete']) > .autocomplete__wrapper .autocomplete__input {\n border-color: #d4351c;\n}\n\n// the following makes the dropdown arrow appear when showing all values\n\n.autocomplete__dropdown-arrow-down {\n z-index: 0;\n pointer-events: none;\n}\n","////\n/// @group helpers/typography\n////\n\n@import \"../tools/px-to-rem\";\n\n/// 'Common typography' helper\n///\n/// Sets the font family and associated properties, such as font smoothing. Also\n/// overrides the font for print.\n///\n/// @param {List} $font-family [$govuk-font-family] Font family to use\n/// @access public\n\n@mixin govuk-typography-common($font-family: $govuk-font-family) {\n font-family: $font-family;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n\n // If the user is using the default GDS Transport font we need to include\n // the font-face declarations.\n @if $govuk-include-default-font-face {\n @include _govuk-font-face-gds-transport;\n }\n\n @include govuk-media-query($media-type: print) {\n font-family: $govuk-font-family-print;\n }\n}\n\n/// Text colour helper\n///\n/// Sets the text colour, including a suitable override for print.\n///\n/// @access public\n\n@mixin govuk-text-colour {\n color: $govuk-text-colour;\n\n @include govuk-media-query($media-type: print) {\n color: $govuk-print-text-colour;\n }\n}\n\n/// Regular font weight helper\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally Used to create override classes.\n/// @access public\n\n@mixin govuk-typography-weight-regular($important: false) {\n font-weight: $govuk-font-weight-regular if($important, !important, null);\n}\n\n/// Bold font weight helper\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally Used to create override classes.\n/// @access public\n\n@mixin govuk-typography-weight-bold($important: false) {\n font-weight: $govuk-font-weight-bold if($important, !important, null);\n}\n\n/// Tabular number helper\n///\n/// Switches numerical glyphs (0–9) to use alternative forms with a\n/// monospaced bounding box. This ensures that columns of numbers, such\n/// as those in tables, remain horizontally aligned with one another.\n/// This also has the useful side effect of making numbers more legible\n/// in some situations, such as reference codes, as the numbers are more\n/// distinct and visually separated from one another.\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally Used to create override classes.\n/// @access public\n\n@mixin govuk-font-tabular-numbers($important: false) {\n font-variant-numeric: tabular-nums if($important, !important, null);\n}\n\n/// Word break helper\n///\n/// Forcibly breaks long words that lack spaces, such as email addresses,\n/// across multiple lines when they wouldn't otherwise fit.\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally used to create override classes.\n/// @access public\n\n@mixin govuk-text-break-word($important: false) {\n // IE 11 and Edge 16–17 only support the non-standard `word-wrap` property\n word-wrap: break-word if($important, !important, null);\n\n // All other browsers support `overflow-wrap`\n overflow-wrap: break-word if($important, !important, null);\n}\n\n/// Convert line-heights specified in pixels into a relative value, unless\n/// they are already unit-less (and thus already treated as relative values)\n/// or the units do not match the units used for the font size.\n///\n/// @param {Number} $line-height Line height\n/// @param {Number} $font-size Font size\n/// @return {Number} The line height as either a relative value or unmodified\n///\n/// @access private\n\n@function _govuk-line-height($line-height, $font-size) {\n @if not unitless($line-height) and unit($line-height) == unit($font-size) {\n $line-height: $line-height / $font-size;\n }\n\n @return $line-height;\n}\n\n/// Font size and line height helper\n///\n/// @param {Number} $size - Point from the type scale (the size as it would\n/// appear on tablet and above)\n/// @param {Number} $override-line-height [false] - Non responsive custom line\n/// height. Omit to use the line height from the font map.\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`.\n///\n/// @throw if `$size` is not a valid point from the type scale\n///\n/// @access public\n///\n/// @alias govuk-font-size\n/// @deprecated Use `govuk-font-size` instead\n\n@mixin govuk-typography-responsive($size, $override-line-height: false, $important: false) {\n @include _warning(\n \"govuk-typography-responsive\",\n \"govuk-typography-responsive is deprecated. Use govuk-font-size instead.\"\n );\n @include govuk-font-size($size, $override-line-height, $important);\n}\n\n/// Font size and line height helper\n///\n/// Takes a point from the responsive 'font map' as an argument (the size as it\n/// would appear on tablet and above), and uses it to create font-size and\n/// line-height declarations for different breakpoints, and print.\n///\n/// Example font map:\n///\n/// ```scss\n/// 19: (\n/// null: (\n/// font-size: 16px,\n/// line-height: 20px\n/// ),\n/// tablet: (\n/// font-size: 19px,\n/// line-height: 25px\n/// ),\n/// print: (\n/// font-size: 14pt,\n/// line-height: 1.15\n/// )\n/// );\n/// ```\n///\n/// @param {Number | String} $size - Point from the type scale (the size as\n/// it would appear on tablet and above)\n/// @param {Number} $line-height [false] - Non responsive custom line\n/// height. Omit to use the line height from the font map.\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`.\n///\n/// @throw if `$size` is not a valid point from the type scale\n///\n/// @access public\n\n@mixin govuk-font-size($size, $line-height: false, $important: false) {\n // Flag font sizes that start with underscores so we can suppress warnings on\n // deprecated sizes used internally, for example `govuk-font($size: \"_14\")`\n $size-internal-use-only: str-slice(#{$size}, 1, 1) == \"_\";\n\n // Remove underscore from font sizes flagged for internal use\n @if $size-internal-use-only {\n $size: str-slice(#{$size}, 2);\n }\n\n // Check for a font map exactly matching the given size\n $font-map: map-get($govuk-typography-scale, $size);\n\n // No match? Try with string type (e.g. $size: \"16\" not 16)\n @if not $font-map {\n @each $font-size in map-keys($govuk-typography-scale) {\n @if not $font-map and \"#{$font-size}\" == \"#{$size}\" {\n $font-map: map-get($govuk-typography-scale, $font-size);\n }\n }\n }\n\n // Still no match? Throw error\n @if not $font-map {\n @error \"Unknown font size `#{$size}` - expected a point from the type scale.\";\n }\n\n // Check for a deprecation within the type scale\n $deprecation: map-get($font-map, \"deprecation\");\n\n @if $deprecation {\n // Warn on deprecated font sizes unless flagged for internal use\n @if not $size-internal-use-only {\n @include _warning(map-get($deprecation, \"key\"), map-get($deprecation, \"message\"));\n }\n\n // remove the deprecation map keys so they do not break the breakpoint loop\n $font-map: map-remove($font-map, \"deprecation\");\n }\n\n @each $breakpoint, $breakpoint-map in $font-map {\n $font-size: map-get($breakpoint-map, \"font-size\");\n $font-size-rem: govuk-px-to-rem($font-size);\n\n // $calculated-line-height is a separate variable from $line-height,\n // as otherwise the value would get redefined with each loop and\n // eventually break _govuk-line-height.\n //\n // We continue to call the param $line-height to stay consistent with the\n // naming with govuk-font.\n $calculated-line-height: _govuk-line-height(\n $line-height: if($line-height, $line-height, map-get($breakpoint-map, \"line-height\")),\n $font-size: $font-size\n );\n\n // Mark rules as !important if $important is true - this will result in\n // these variables becoming strings, so this needs to happen *after* they\n // are used in calculations\n $font-size: $font-size if($important, !important, null);\n $font-size-rem: $font-size-rem if($important, !important, null);\n $calculated-line-height: $calculated-line-height if($important, !important, null);\n\n @if not $breakpoint {\n font-size: $font-size-rem;\n line-height: $calculated-line-height;\n } @else if $breakpoint == \"print\" {\n @include govuk-media-query($media-type: print) {\n font-size: $font-size;\n line-height: $calculated-line-height;\n }\n } @else {\n @include govuk-media-query($from: $breakpoint) {\n font-size: $font-size-rem;\n line-height: $calculated-line-height;\n }\n }\n }\n}\n\n/// Font helper\n///\n/// @param {Number | Boolean | String} $size Point from the type scale (the\n/// size as it would appear on tablet and above). Use `false` to avoid setting\n/// a size.\n/// @param {String} $weight [regular] - Weight: `bold` or `regular`\n/// @param {Boolean} $tabular [false] - Whether to use tabular numbers or not\n/// @param {Number} $line-height [false] - Line-height, if overriding the\n/// default\n///\n/// @throw if `$size` is not a valid point from the type scale (or false)\n///\n/// @access public\n\n@mixin govuk-font($size, $weight: regular, $tabular: false, $line-height: false) {\n @include govuk-typography-common;\n\n @if $tabular {\n @include govuk-font-tabular-numbers;\n }\n\n @if $weight == regular {\n @include govuk-typography-weight-regular;\n } @else if $weight == bold {\n @include govuk-typography-weight-bold;\n }\n\n @if $size {\n @include govuk-font-size($size, $line-height);\n }\n}\n\n/*# sourceMappingURL=_typography.scss.map */\n","////\n/// @group settings/typography\n////\n\n// =========================================================\n// Font families\n// =========================================================\n\n/// Font families to use for all typography on screen media\n///\n/// @type List\n/// @access public\n\n$govuk-font-family: \"GDS Transport\", arial, sans-serif !default;\n\n/// Font families to use for print media\n///\n/// We recommend that you use system fonts when printing. This will avoid issues\n/// with some printer drivers and operating systems.\n///\n/// @type List\n/// @access public\n\n$govuk-font-family-print: sans-serif !default;\n\n/// Include the default @font-face declarations\n///\n/// Defaults to true if \"GDS Transport\" appears in the $govuk-font-family\n/// setting.\n///\n/// @type Boolean\n/// @access public\n\n$govuk-include-default-font-face: if(index($govuk-font-family, \"GDS Transport\"), true, false) !default;\n\n// =========================================================\n// Font weights\n// =========================================================\n\n/// Font weight for regular typography\n///\n/// @type Number\n/// @access public\n$govuk-font-weight-regular: 400 !default;\n\n/// Font weight for bold typography\n///\n/// @type Number\n/// @access public\n$govuk-font-weight-bold: 700 !default;\n\n/*# sourceMappingURL=_typography-font.scss.map */\n","// mq() v4.0.2\n// sass-mq/sass-mq\n\n@charset \"UTF-8\"; // Fixes an issue where Ruby locale is not set properly\n // See https://github.com/sass-mq/sass-mq/pull/10\n\n/// Base font size on the `<body>` element\n/// @type Number (unit)\n$mq-base-font-size: 16px !default;\n\n/// Responsive mode\n///\n/// Set to `false` to enable support for browsers that do not support @media queries,\n/// (IE <= 8, Firefox <= 3, Opera <= 9)\n///\n/// You could create a stylesheet served exclusively to older browsers,\n/// where @media queries are rasterized\n///\n/// @example scss\n/// // old-ie.scss\n/// $mq-responsive: false;\n/// @import 'main'; // @media queries in this file will be rasterized up to $mq-static-breakpoint\n/// // larger breakpoints will be ignored\n///\n/// @type Boolean\n/// @link https://github.com/sass-mq/sass-mq#responsive-mode-off Disabled responsive mode documentation\n$mq-responsive: true !default;\n\n/// Breakpoint list\n///\n/// Name your breakpoints in a way that creates a ubiquitous language\n/// across team members. It will improve communication between\n/// stakeholders, designers, developers, and testers.\n///\n/// @type Map\n/// @link https://github.com/sass-mq/sass-mq#seeing-the-currently-active-breakpoint Full documentation and examples\n$mq-breakpoints: (\n mobile: 320px,\n tablet: 740px,\n desktop: 980px,\n wide: 1300px\n) !default;\n\n/// Static breakpoint (for fixed-width layouts)\n///\n/// Define the breakpoint from $mq-breakpoints that should\n/// be used as the target width for the fixed-width layout\n/// (i.e. when $mq-responsive is set to 'false') in a old-ie.scss\n///\n/// @example scss\n/// // tablet-only.scss\n/// //\n/// // Ignore all styles above tablet breakpoint,\n/// // and fix the styles (e.g. layout) at tablet width\n/// $mq-responsive: false;\n/// $mq-static-breakpoint: tablet;\n/// @import 'main'; // @media queries in this file will be rasterized up to tablet\n/// // larger breakpoints will be ignored\n///\n/// @type String\n/// @link https://github.com/sass-mq/sass-mq#adding-custom-breakpoints Full documentation and examples\n$mq-static-breakpoint: desktop !default;\n\n/// Show breakpoints in the top right corner\n///\n/// If you want to display the currently active breakpoint in the top\n/// right corner of your site during development, add the breakpoints\n/// to this list, ordered by width, e.g. (mobile, tablet, desktop).\n///\n/// @type map\n$mq-show-breakpoints: () !default;\n\n/// Customize the media type (e.g. `@media screen` or `@media print`)\n/// By default sass-mq uses an \"all\" media type (`@media all and …`)\n///\n/// @type String\n/// @link https://github.com/sass-mq/sass-mq#changing-media-type Full documentation and examples\n$mq-media-type: all !default;\n\n/// Convert pixels to ems\n///\n/// @param {Number} $px - value to convert\n/// @param {Number} $base-font-size ($mq-base-font-size) - `<body>` font size\n///\n/// @example scss\n/// $font-size-in-ems: mq-px2em(16px);\n/// p { font-size: mq-px2em(16px); }\n///\n/// @requires $mq-base-font-size\n/// @returns {Number}\n@function mq-px2em($px, $base-font-size: $mq-base-font-size) {\n @if unitless($px) {\n @warn \"Assuming #{$px} to be in pixels, attempting to convert it into pixels.\";\n @return mq-px2em($px * 1px, $base-font-size);\n } @else if unit($px) == em {\n @return $px;\n }\n @return ($px / $base-font-size) * 1em;\n}\n\n/// Get a breakpoint's width\n///\n/// @param {String} $name - Name of the breakpoint. One of $mq-breakpoints\n///\n/// @example scss\n/// $tablet-width: mq-get-breakpoint-width(tablet);\n/// @media (min-width: mq-get-breakpoint-width(desktop)) {}\n///\n/// @requires {Variable} $mq-breakpoints\n///\n/// @returns {Number} Value in pixels\n@function mq-get-breakpoint-width($name, $breakpoints: $mq-breakpoints) {\n @if map-has-key($breakpoints, $name) {\n @return map-get($breakpoints, $name);\n } @else {\n @warn \"Breakpoint #{$name} wasn't found in $breakpoints.\";\n }\n}\n\n/// Media Query mixin\n///\n/// @param {String | Boolean} $from (false) - One of $mq-breakpoints\n/// @param {String | Boolean} $until (false) - One of $mq-breakpoints\n/// @param {String | Boolean} $and (false) - Additional media query parameters\n/// @param {String} $media-type ($mq-media-type) - Media type: screen, print…\n///\n/// @ignore Undocumented API, for advanced use only:\n/// @ignore @param {Map} $breakpoints ($mq-breakpoints)\n/// @ignore @param {String} $static-breakpoint ($mq-static-breakpoint)\n///\n/// @content styling rules, wrapped into a @media query when $responsive is true\n///\n/// @requires {Variable} $mq-media-type\n/// @requires {Variable} $mq-breakpoints\n/// @requires {Variable} $mq-static-breakpoint\n/// @requires {function} mq-px2em\n/// @requires {function} mq-get-breakpoint-width\n///\n/// @link https://github.com/sass-mq/sass-mq#responsive-mode-on-default Full documentation and examples\n///\n/// @example scss\n/// .element {\n/// @include mq($from: mobile) {\n/// color: red;\n/// }\n/// @include mq($until: tablet) {\n/// color: blue;\n/// }\n/// @include mq(mobile, tablet) {\n/// color: green;\n/// }\n/// @include mq($from: tablet, $and: '(orientation: landscape)') {\n/// color: teal;\n/// }\n/// @include mq(950px) {\n/// color: hotpink;\n/// }\n/// @include mq(tablet, $media-type: screen) {\n/// color: hotpink;\n/// }\n/// // Advanced use:\n/// $my-breakpoints: (L: 900px, XL: 1200px);\n/// @include mq(L, $breakpoints: $my-breakpoints, $static-breakpoint: L) {\n/// color: hotpink;\n/// }\n/// }\n@mixin mq(\n $from: false,\n $until: false,\n $and: false,\n $media-type: $mq-media-type,\n $breakpoints: $mq-breakpoints,\n $responsive: $mq-responsive,\n $static-breakpoint: $mq-static-breakpoint\n) {\n $min-width: 0;\n $max-width: 0;\n $media-query: '';\n\n // From: this breakpoint (inclusive)\n @if $from {\n @if type-of($from) == number {\n $min-width: mq-px2em($from);\n } @else {\n $min-width: mq-px2em(mq-get-breakpoint-width($from, $breakpoints));\n }\n }\n\n // Until: that breakpoint (exclusive)\n @if $until {\n @if type-of($until) == number {\n $max-width: mq-px2em($until);\n } @else {\n $max-width: mq-px2em(mq-get-breakpoint-width($until, $breakpoints)) - .01em;\n }\n }\n\n // Responsive support is disabled, rasterize the output outside @media blocks\n // The browser will rely on the cascade itself.\n @if $responsive == false {\n $static-breakpoint-width: mq-get-breakpoint-width($static-breakpoint, $breakpoints);\n $target-width: mq-px2em($static-breakpoint-width);\n\n // Output only rules that start at or span our target width\n @if (\n $and == false\n and $min-width <= $target-width\n and (\n $until == false or $max-width >= $target-width\n )\n and $media-type != 'print'\n ) {\n @content;\n }\n }\n\n // Responsive support is enabled, output rules inside @media queries\n @else {\n @if $min-width != 0 { $media-query: '#{$media-query} and (min-width: #{$min-width})'; }\n @if $max-width != 0 { $media-query: '#{$media-query} and (max-width: #{$max-width})'; }\n @if $and { $media-query: '#{$media-query} and #{$and}'; }\n\n // Remove unnecessary media query prefix 'all and '\n @if ($media-type == 'all' and $media-query != '') {\n $media-type: '';\n $media-query: str-slice(unquote($media-query), 6);\n }\n\n @media #{$media-type + $media-query} {\n @content;\n }\n }\n}\n\n/// Quick sort\n///\n/// @author Sam Richards\n/// @access private\n/// @param {List} $list - List to sort\n/// @returns {List} Sorted List\n@function _mq-quick-sort($list) {\n $less: ();\n $equal: ();\n $large: ();\n\n @if length($list) > 1 {\n $seed: nth($list, ceil(length($list) / 2));\n\n @each $item in $list {\n @if ($item == $seed) {\n $equal: append($equal, $item);\n } @else if ($item < $seed) {\n $less: append($less, $item);\n } @else if ($item > $seed) {\n $large: append($large, $item);\n }\n }\n\n @return join(join(_mq-quick-sort($less), $equal), _mq-quick-sort($large));\n }\n\n @return $list;\n}\n\n/// Sort a map by values (works with numbers only)\n///\n/// @access private\n/// @param {Map} $map - Map to sort\n/// @returns {Map} Map sorted by value\n@function _mq-map-sort-by-value($map) {\n $map-sorted: ();\n $map-keys: map-keys($map);\n $map-values: map-values($map);\n $map-values-sorted: _mq-quick-sort($map-values);\n\n // Reorder key/value pairs based on key values\n @each $value in $map-values-sorted {\n $index: index($map-values, $value);\n $key: nth($map-keys, $index);\n $map-sorted: map-merge($map-sorted, ($key: $value));\n\n // Unset the value in $map-values to prevent the loop\n // from finding the same index twice\n $map-values: set-nth($map-values, $index, 0);\n }\n\n @return $map-sorted;\n}\n\n/// Add a breakpoint\n///\n/// @param {String} $name - Name of the breakpoint\n/// @param {Number} $width - Width of the breakpoint\n///\n/// @requires {Variable} $mq-breakpoints\n///\n/// @example scss\n/// @include mq-add-breakpoint(tvscreen, 1920px);\n/// @include mq(tvscreen) {}\n@mixin mq-add-breakpoint($name, $width) {\n $new-breakpoint: ($name: $width);\n $mq-breakpoints: map-merge($mq-breakpoints, $new-breakpoint) !global;\n $mq-breakpoints: _mq-map-sort-by-value($mq-breakpoints) !global;\n}\n\n/// Show the active breakpoint in the top right corner of the viewport\n/// @link https://github.com/sass-mq/sass-mq#seeing-the-currently-active-breakpoint\n///\n/// @param {List} $show-breakpoints ($mq-show-breakpoints) - List of breakpoints to show in the top right corner\n/// @param {Map} $breakpoints ($mq-breakpoints) - Breakpoint names and sizes\n///\n/// @requires {Variable} $mq-breakpoints\n/// @requires {Variable} $mq-show-breakpoints\n///\n/// @example scss\n/// // Show breakpoints using global settings\n/// @include mq-show-breakpoints;\n///\n/// // Show breakpoints using custom settings\n/// @include mq-show-breakpoints((L, XL), (S: 300px, L: 800px, XL: 1200px));\n@mixin mq-show-breakpoints($show-breakpoints: $mq-show-breakpoints, $breakpoints: $mq-breakpoints) {\n body::before {\n background-color: #FCF8E3;\n border-bottom: 1px solid #FBEED5;\n border-left: 1px solid #FBEED5;\n color: #C09853;\n font: small-caption;\n padding: 3px 6px;\n pointer-events: none;\n position: fixed;\n right: 0;\n top: 0;\n z-index: 100;\n\n // Loop through the breakpoints that should be shown\n @each $show-breakpoint in $show-breakpoints {\n $width: mq-get-breakpoint-width($show-breakpoint, $breakpoints);\n @include mq($show-breakpoint, $breakpoints: $breakpoints) {\n content: \"#{$show-breakpoint} ≥ #{$width} (#{mq-px2em($width)})\";\n }\n }\n }\n}\n\n@if length($mq-show-breakpoints) > 0 {\n @include mq-show-breakpoints;\n}\n\n/*# sourceMappingURL=_sass-mq.scss.map */\n"]}
1
+ {"version":3,"sources":["file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/accessible-autocomplete/dist/accessible-autocomplete.min.css","accessible-autocomplete.css","govuk-frontend/dist/govuk/settings/govuk-frontend/dist/govuk/tools/govuk-frontend/dist/govuk/helpers/accessible-autocomplete/dist/accessible-autocomplete.min%22;%0A%0A.autocomplete__wrapper,%0A.autocomplete__input,%0A.autocomplete__option,%0A.autocomplete__hint%20%7B%0A%20%20@include%20govuk-font($size:%2019);%0A%7D%0A%0A/%20the%20following%20makes%20the%20autocomplete%20inherit%20error%20styles%0A/%20it%20won't%20work%20in%20IE11%20but%20selects%20won't%20be%20enhanced%20into%20autocompletes%20in%20IE11%0A%0A.govuk-form-group--error%20div:has(+%20.govuk-select--error%5Bdata-module='hmrc-accessible-autocomplete'%5D)%20%3E%20.autocomplete__wrapper%20.autocomplete__input%20%7B%0A%20%20border-color:%20%23d4351c;%0A%7D%0A%0A/%20the%20following%20makes%20the%20dropdown%20arrow%20appear%20when%20showing%20all%20values%0A%0A.autocomplete__dropdown-arrow-down%20%7B%0A%20%20z-index:%200;%0A%20%20pointer-events:%20none;%0A%7D%0A","file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/govuk-frontend/dist/govuk/helpers/_typography.scss","file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/govuk-frontend/dist/govuk/settings/_typography-font.scss","file:/home/jenkins/workspace/PlatUI/Libraries/hmrc-frontend/node_modules/govuk-frontend/dist/govuk/vendor/_sass-mq.scss"],"names":[],"mappings":"AAAA,uBAAuB,iBCgDvB,CDhDyC,yCAAyC,uBAAA,CAAwB,oBAAA,CAAA,eAAA,CAAgB,wBAAA,CAAyB,eAAA,CAAgB,6BAAA,CAAA,qBAAA,CAAsB,aAAA,CAAc,gBAAA,CAAiB,eAAA,CAAgB,UC4DxO,CD5DmP,qBAAqB,8BAAA,CAA6B,iBCiErS,CDjEuT,oBAAoB,aAAA,CAAc,iBCsEzV,CDtE2W,8BAA8B,WC0EzY,CD1EqZ,8BAA8B,kCAAA,CAAA,0BAAA,CAA2B,sBAAA,CAAuB,gBCgFre,CDhFsf,sCAAsC,cAAA,CAAe,wBCqF3iB,CDrFokB,mCAAmC,oBAAA,CAAqB,WAAA,CAAY,iBAAA,CAAkB,SAAA,CAAU,QAAA,CAAS,UAAA,CAAW,UC+FxrB,CD/FmsB,oBAAoB,qBAAA,CAAsB,wBAAA,CAAyB,YAAA,CAAa,aAAA,CAAc,QAAA,CAAS,gBAAA,CAAiB,iBAAA,CAAkB,SAAA,CAAU,UAAA,CAAW,sBC4Gl2B,CD5Gy3B,6BAA6B,aCgHt5B,CDhHo6B,4BAA4B,YCoHh8B,CDpH68B,6BAA6B,6CAAA,CAAA,qCAAA,CAAsC,MAAA,CAAO,iBAAA,CAAkB,QAAA,CAAS,WC4HljC,CD5H8jC,4BAA4B,iBCgI1lC,CDhI4mC,sBAAsB,+BAAA,CAAgC,mBAAA,CAAoB,oBAAA,CAAqB,oBAAA,CAAqB,cAAA,CAAe,aAAA,CAAc,iBC0I7vC,CD1I+wC,wBAAwB,mBC8IvyC,CD9I2zC,oCAAoC,kBCkJ/1C,CDlJk3C,mCAAmC,qBCsJr5C,CDtJ26C,2BAA2B,wBC0Jt8C,CD1J+9C,2DAA2D,wBAAA,CAAyB,oBAAA,CAAqB,UAAA,CAAW,YCiKnlD,CDjKgmD,yDAAyD,oBAAoB,sBCsK3qD,CDtKksD,sBAAsB,sBAAA,CAAuB,eC0K/uD,CD1K+vD,2DAA2D,0BAAA,CAA2B,6BAAA,CAA8B,yBAAA,CAA0B,mBAAA,CAAoB,sBAAA,CAAuB,wBAAA,CAAyB,8BCmLj9D,CACF,CDpLm/D,kCAAkC,wBAAA,CAAyB,aAAA,CAAc,kBCyL5jE,CDzL+kE,+DAA+D,cAAA,CAAe,eC8L7pE,CD9L6qE,0CAA0C,WCkMvtE,CDlMmuE,yBAAyB,+DAA+D,mBAAA,CAAoB,wBCwM70E,CACF,CClMA,sFCQE,0CCFkB,CDGlB,kCAAA,CACA,iCAAA,CAkCA,eAAA,CA4LI,cAJc,CAKd,gBF3BN,CIeQ,aH7NR,sFCmBI,sBFkMF,CACF,CIOQ,6BH7NR,sFCiPQ,mBAbY,CAcZ,wBFpBN,CACF,CIFQ,aH7NR,sFC4OQ,cATQ,CAUR,gBFNN,CACF,CC9NA,8IACE,oBDiOF,CC5NA,mCACE,SAAA,CACA,mBD+NF","file":"../accessible-autocomplete-6.80.0.css","sourcesContent":[".autocomplete__wrapper{position:relative}.autocomplete__hint,.autocomplete__input{-webkit-appearance:none;appearance:none;border:2px solid #0b0c0c;border-radius:0;box-sizing:border-box;height:2.5rem;line-height:1.25;margin-bottom:0;width:100%}.autocomplete__input{background-color:transparent;position:relative}.autocomplete__hint{color:#505a5f;position:absolute}.autocomplete__input--default{padding:5px}.autocomplete__input--focused{box-shadow:inset 0 0 0 2px;outline:3px solid #fd0;outline-offset:0}.autocomplete__input--show-all-values{cursor:pointer;padding:5px 35px 5px 5px}.autocomplete__dropdown-arrow-down{display:inline-block;height:24px;position:absolute;right:8px;top:10px;width:24px;z-index:-1}.autocomplete__menu{background-color:#fff;border:2px solid #0b0c0c;border-top:0;color:#0b0c0c;margin:0;max-height:342px;overflow-x:hidden;padding:0;width:100%;width:calc(100% - 4px)}.autocomplete__menu--visible{display:block}.autocomplete__menu--hidden{display:none}.autocomplete__menu--overlay{box-shadow:0 2px 6px rgba(0,0,0,.257);left:0;position:absolute;top:100%;z-index:100}.autocomplete__menu--inline{position:relative}.autocomplete__option{border-bottom:1px solid #b1b4b6;border-left-width:0;border-right-width:0;border-top-width:1px;cursor:pointer;display:block;position:relative}.autocomplete__option>*{pointer-events:none}.autocomplete__option:first-of-type{border-top-width:0}.autocomplete__option:last-of-type{border-bottom-width:0}.autocomplete__option--odd{background-color:#f3f2f1}.autocomplete__option--focused,.autocomplete__option:hover{background-color:#1d70b8;border-color:#1d70b8;color:#fff;outline:none}@media (-ms-high-contrast:active),(forced-colors:active){.autocomplete__menu{border-color:FieldText}.autocomplete__option{background-color:Field;color:FieldText}.autocomplete__option--focused,.autocomplete__option:hover{background-color:Highlight;background-color:SelectedItem;border-color:SelectedItem;color:HighlightText;color:SelectedItemText;forced-color-adjust:none;outline-color:SelectedItemText}}.autocomplete__option--no-results{background-color:#f3f2f1;color:#505a5f;cursor:not-allowed}.autocomplete__hint,.autocomplete__input,.autocomplete__option{font-size:1rem;font-weight:400}.autocomplete__hint,.autocomplete__option{padding:5px}@media (min-width:641px){.autocomplete__hint,.autocomplete__input,.autocomplete__option{font-size:1.1875rem;line-height:1.3157894737}}\n\n/*# sourceMappingURL=accessible-autocomplete.min.css.map*/","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.autocomplete__wrapper {\n position: relative;\n}\n\n.autocomplete__hint, .autocomplete__input {\n -webkit-appearance: none;\n appearance: none;\n border: 2px solid #0b0c0c;\n border-radius: 0;\n box-sizing: border-box;\n height: 2.5rem;\n line-height: 1.25;\n margin-bottom: 0;\n width: 100%;\n}\n\n.autocomplete__input {\n background-color: transparent;\n position: relative;\n}\n\n.autocomplete__hint {\n color: #505a5f;\n position: absolute;\n}\n\n.autocomplete__input--default {\n padding: 5px;\n}\n\n.autocomplete__input--focused {\n box-shadow: inset 0 0 0 2px;\n outline: 3px solid #fd0;\n outline-offset: 0;\n}\n\n.autocomplete__input--show-all-values {\n cursor: pointer;\n padding: 5px 35px 5px 5px;\n}\n\n.autocomplete__dropdown-arrow-down {\n display: inline-block;\n height: 24px;\n position: absolute;\n right: 8px;\n top: 10px;\n width: 24px;\n z-index: -1;\n}\n\n.autocomplete__menu {\n background-color: #fff;\n border: 2px solid #0b0c0c;\n border-top: 0;\n color: #0b0c0c;\n margin: 0;\n max-height: 342px;\n overflow-x: hidden;\n padding: 0;\n width: 100%;\n width: calc(100% - 4px);\n}\n\n.autocomplete__menu--visible {\n display: block;\n}\n\n.autocomplete__menu--hidden {\n display: none;\n}\n\n.autocomplete__menu--overlay {\n box-shadow: 0 2px 6px rgba(0, 0, 0, 0.257);\n left: 0;\n position: absolute;\n top: 100%;\n z-index: 100;\n}\n\n.autocomplete__menu--inline {\n position: relative;\n}\n\n.autocomplete__option {\n border-bottom: 1px solid #b1b4b6;\n border-left-width: 0;\n border-right-width: 0;\n border-top-width: 1px;\n cursor: pointer;\n display: block;\n position: relative;\n}\n\n.autocomplete__option > * {\n pointer-events: none;\n}\n\n.autocomplete__option:first-of-type {\n border-top-width: 0;\n}\n\n.autocomplete__option:last-of-type {\n border-bottom-width: 0;\n}\n\n.autocomplete__option--odd {\n background-color: #f3f2f1;\n}\n\n.autocomplete__option--focused, .autocomplete__option:hover {\n background-color: #1d70b8;\n border-color: #1d70b8;\n color: #fff;\n outline: none;\n}\n\n@media (-ms-high-contrast: active), (forced-colors: active) {\n .autocomplete__menu {\n border-color: FieldText;\n }\n .autocomplete__option {\n background-color: Field;\n color: FieldText;\n }\n .autocomplete__option--focused, .autocomplete__option:hover {\n background-color: Highlight;\n background-color: SelectedItem;\n border-color: SelectedItem;\n color: HighlightText;\n color: SelectedItemText;\n forced-color-adjust: none;\n outline-color: SelectedItemText;\n }\n}\n.autocomplete__option--no-results {\n background-color: #f3f2f1;\n color: #505a5f;\n cursor: not-allowed;\n}\n\n.autocomplete__hint, .autocomplete__input, .autocomplete__option {\n font-size: 1rem;\n font-weight: 400;\n}\n\n.autocomplete__hint, .autocomplete__option {\n padding: 5px;\n}\n\n@media (min-width: 641px) {\n .autocomplete__hint, .autocomplete__input, .autocomplete__option {\n font-size: 1.1875rem;\n line-height: 1.3157894737;\n }\n}\n\n.autocomplete__wrapper,\n.autocomplete__input,\n.autocomplete__option,\n.autocomplete__hint {\n font-family: \"GDS Transport\", arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n font-weight: 400;\n font-size: 1rem;\n line-height: 1.25;\n}\n@media print {\n .autocomplete__wrapper,\n .autocomplete__input,\n .autocomplete__option,\n .autocomplete__hint {\n font-family: sans-serif;\n }\n}\n@media (min-width: 40.0625em) {\n .autocomplete__wrapper,\n .autocomplete__input,\n .autocomplete__option,\n .autocomplete__hint {\n font-size: 1.1875rem;\n line-height: 1.3157894737;\n }\n}\n@media print {\n .autocomplete__wrapper,\n .autocomplete__input,\n .autocomplete__option,\n .autocomplete__hint {\n font-size: 14pt;\n line-height: 1.15;\n }\n}\n\n.govuk-form-group--error div:has(+ .govuk-select--error[data-module=hmrc-accessible-autocomplete]) > .autocomplete__wrapper .autocomplete__input {\n border-color: #d4351c;\n}\n\n.autocomplete__dropdown-arrow-down {\n z-index: 0;\n pointer-events: none;\n}","$govuk-include-default-font-face: false;\n\n@import \"../../govuk-frontend/dist/govuk/settings/index\";\n@import \"../../govuk-frontend/dist/govuk/tools/index\";\n@import \"../../govuk-frontend/dist/govuk/helpers/index\";\n@import \"../../accessible-autocomplete/dist/accessible-autocomplete.min\";\n\n.autocomplete__wrapper,\n.autocomplete__input,\n.autocomplete__option,\n.autocomplete__hint {\n @include govuk-font($size: 19);\n}\n\n// the following makes the autocomplete inherit error styles\n// it won't work in IE11 but selects won't be enhanced into autocompletes in IE11\n\n.govuk-form-group--error div:has(+ .govuk-select--error[data-module='hmrc-accessible-autocomplete']) > .autocomplete__wrapper .autocomplete__input {\n border-color: #d4351c;\n}\n\n// the following makes the dropdown arrow appear when showing all values\n\n.autocomplete__dropdown-arrow-down {\n z-index: 0;\n pointer-events: none;\n}\n","////\n/// @group helpers/typography\n////\n\n@import \"../tools/px-to-rem\";\n\n/// 'Common typography' helper\n///\n/// Sets the font family and associated properties, such as font smoothing. Also\n/// overrides the font for print.\n///\n/// @param {List} $font-family [$govuk-font-family] Font family to use\n/// @access public\n\n@mixin govuk-typography-common($font-family: $govuk-font-family) {\n font-family: $font-family;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n\n // If the user is using the default GDS Transport font we need to include\n // the font-face declarations.\n @if $govuk-include-default-font-face {\n @include _govuk-font-face-gds-transport;\n }\n\n @include govuk-media-query($media-type: print) {\n font-family: $govuk-font-family-print;\n }\n}\n\n/// Text colour helper\n///\n/// Sets the text colour, including a suitable override for print.\n///\n/// @access public\n\n@mixin govuk-text-colour {\n color: $govuk-text-colour;\n\n @include govuk-media-query($media-type: print) {\n color: $govuk-print-text-colour;\n }\n}\n\n/// Regular font weight helper\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally Used to create override classes.\n/// @access public\n\n@mixin govuk-typography-weight-regular($important: false) {\n font-weight: $govuk-font-weight-regular if($important, !important, null);\n}\n\n/// Bold font weight helper\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally Used to create override classes.\n/// @access public\n\n@mixin govuk-typography-weight-bold($important: false) {\n font-weight: $govuk-font-weight-bold if($important, !important, null);\n}\n\n/// Tabular number helper\n///\n/// Switches numerical glyphs (0–9) to use alternative forms with a\n/// monospaced bounding box. This ensures that columns of numbers, such\n/// as those in tables, remain horizontally aligned with one another.\n/// This also has the useful side effect of making numbers more legible\n/// in some situations, such as reference codes, as the numbers are more\n/// distinct and visually separated from one another.\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally Used to create override classes.\n/// @access public\n\n@mixin govuk-font-tabular-numbers($important: false) {\n font-variant-numeric: tabular-nums if($important, !important, null);\n}\n\n/// Word break helper\n///\n/// Forcibly breaks long words that lack spaces, such as email addresses,\n/// across multiple lines when they wouldn't otherwise fit.\n///\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`. Generally used to create override classes.\n/// @access public\n\n@mixin govuk-text-break-word($important: false) {\n // IE 11 and Edge 16–17 only support the non-standard `word-wrap` property\n word-wrap: break-word if($important, !important, null);\n\n // All other browsers support `overflow-wrap`\n overflow-wrap: break-word if($important, !important, null);\n}\n\n/// Convert line-heights specified in pixels into a relative value, unless\n/// they are already unit-less (and thus already treated as relative values)\n/// or the units do not match the units used for the font size.\n///\n/// @param {Number} $line-height Line height\n/// @param {Number} $font-size Font size\n/// @return {Number} The line height as either a relative value or unmodified\n///\n/// @access private\n\n@function _govuk-line-height($line-height, $font-size) {\n @if not unitless($line-height) and unit($line-height) == unit($font-size) {\n $line-height: $line-height / $font-size;\n }\n\n @return $line-height;\n}\n\n/// Font size and line height helper\n///\n/// @param {Number} $size - Point from the type scale (the size as it would\n/// appear on tablet and above)\n/// @param {Number} $override-line-height [false] - Non responsive custom line\n/// height. Omit to use the line height from the font map.\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`.\n///\n/// @throw if `$size` is not a valid point from the type scale\n///\n/// @access public\n///\n/// @alias govuk-font-size\n/// @deprecated Use `govuk-font-size` instead\n\n@mixin govuk-typography-responsive($size, $override-line-height: false, $important: false) {\n @include _warning(\n \"govuk-typography-responsive\",\n \"govuk-typography-responsive is deprecated. Use govuk-font-size instead.\"\n );\n @include govuk-font-size($size, $override-line-height, $important);\n}\n\n/// Font size and line height helper\n///\n/// Takes a point from the responsive 'font map' as an argument (the size as it\n/// would appear on tablet and above), and uses it to create font-size and\n/// line-height declarations for different breakpoints, and print.\n///\n/// Example font map:\n///\n/// ```scss\n/// 19: (\n/// null: (\n/// font-size: 16px,\n/// line-height: 20px\n/// ),\n/// tablet: (\n/// font-size: 19px,\n/// line-height: 25px\n/// ),\n/// print: (\n/// font-size: 14pt,\n/// line-height: 1.15\n/// )\n/// );\n/// ```\n///\n/// @param {Number | String} $size - Point from the type scale (the size as\n/// it would appear on tablet and above)\n/// @param {Number} $line-height [false] - Non responsive custom line\n/// height. Omit to use the line height from the font map.\n/// @param {Boolean} $important [false] - Whether to mark declarations as\n/// `!important`.\n///\n/// @throw if `$size` is not a valid point from the type scale\n///\n/// @access public\n\n@mixin govuk-font-size($size, $line-height: false, $important: false) {\n // Flag font sizes that start with underscores so we can suppress warnings on\n // deprecated sizes used internally, for example `govuk-font($size: \"_14\")`\n $size-internal-use-only: str-slice(#{$size}, 1, 1) == \"_\";\n\n // Remove underscore from font sizes flagged for internal use\n @if $size-internal-use-only {\n $size: str-slice(#{$size}, 2);\n }\n\n // Check for a font map exactly matching the given size\n $font-map: map-get($govuk-typography-scale, $size);\n\n // No match? Try with string type (e.g. $size: \"16\" not 16)\n @if not $font-map {\n @each $font-size in map-keys($govuk-typography-scale) {\n @if not $font-map and \"#{$font-size}\" == \"#{$size}\" {\n $font-map: map-get($govuk-typography-scale, $font-size);\n }\n }\n }\n\n // Still no match? Throw error\n @if not $font-map {\n @error \"Unknown font size `#{$size}` - expected a point from the type scale.\";\n }\n\n // Check for a deprecation within the type scale\n $deprecation: map-get($font-map, \"deprecation\");\n\n @if $deprecation {\n // Warn on deprecated font sizes unless flagged for internal use\n @if not $size-internal-use-only {\n @include _warning(map-get($deprecation, \"key\"), map-get($deprecation, \"message\"));\n }\n\n // remove the deprecation map keys so they do not break the breakpoint loop\n $font-map: map-remove($font-map, \"deprecation\");\n }\n\n @each $breakpoint, $breakpoint-map in $font-map {\n $font-size: map-get($breakpoint-map, \"font-size\");\n $font-size-rem: govuk-px-to-rem($font-size);\n\n // $calculated-line-height is a separate variable from $line-height,\n // as otherwise the value would get redefined with each loop and\n // eventually break _govuk-line-height.\n //\n // We continue to call the param $line-height to stay consistent with the\n // naming with govuk-font.\n $calculated-line-height: _govuk-line-height(\n $line-height: if($line-height, $line-height, map-get($breakpoint-map, \"line-height\")),\n $font-size: $font-size\n );\n\n // Mark rules as !important if $important is true - this will result in\n // these variables becoming strings, so this needs to happen *after* they\n // are used in calculations\n $font-size: $font-size if($important, !important, null);\n $font-size-rem: $font-size-rem if($important, !important, null);\n $calculated-line-height: $calculated-line-height if($important, !important, null);\n\n @if not $breakpoint {\n font-size: $font-size-rem;\n line-height: $calculated-line-height;\n } @else if $breakpoint == \"print\" {\n @include govuk-media-query($media-type: print) {\n font-size: $font-size;\n line-height: $calculated-line-height;\n }\n } @else {\n @include govuk-media-query($from: $breakpoint) {\n font-size: $font-size-rem;\n line-height: $calculated-line-height;\n }\n }\n }\n}\n\n/// Font helper\n///\n/// @param {Number | Boolean | String} $size Point from the type scale (the\n/// size as it would appear on tablet and above). Use `false` to avoid setting\n/// a size.\n/// @param {String} $weight [regular] - Weight: `bold` or `regular`\n/// @param {Boolean} $tabular [false] - Whether to use tabular numbers or not\n/// @param {Number} $line-height [false] - Line-height, if overriding the\n/// default\n///\n/// @throw if `$size` is not a valid point from the type scale (or false)\n///\n/// @access public\n\n@mixin govuk-font($size, $weight: regular, $tabular: false, $line-height: false) {\n @include govuk-typography-common;\n\n @if $tabular {\n @include govuk-font-tabular-numbers;\n }\n\n @if $weight == regular {\n @include govuk-typography-weight-regular;\n } @else if $weight == bold {\n @include govuk-typography-weight-bold;\n }\n\n @if $size {\n @include govuk-font-size($size, $line-height);\n }\n}\n\n/*# sourceMappingURL=_typography.scss.map */\n","////\n/// @group settings/typography\n////\n\n// =========================================================\n// Font families\n// =========================================================\n\n/// Font families to use for all typography on screen media\n///\n/// @type List\n/// @access public\n\n$govuk-font-family: \"GDS Transport\", arial, sans-serif !default;\n\n/// Font families to use for print media\n///\n/// We recommend that you use system fonts when printing. This will avoid issues\n/// with some printer drivers and operating systems.\n///\n/// @type List\n/// @access public\n\n$govuk-font-family-print: sans-serif !default;\n\n/// Include the default @font-face declarations\n///\n/// Defaults to true if \"GDS Transport\" appears in the $govuk-font-family\n/// setting.\n///\n/// @type Boolean\n/// @access public\n\n$govuk-include-default-font-face: if(index($govuk-font-family, \"GDS Transport\"), true, false) !default;\n\n// =========================================================\n// Font weights\n// =========================================================\n\n/// Font weight for regular typography\n///\n/// @type Number\n/// @access public\n$govuk-font-weight-regular: 400 !default;\n\n/// Font weight for bold typography\n///\n/// @type Number\n/// @access public\n$govuk-font-weight-bold: 700 !default;\n\n/*# sourceMappingURL=_typography-font.scss.map */\n","// mq() v4.0.2\n// sass-mq/sass-mq\n\n@charset \"UTF-8\"; // Fixes an issue where Ruby locale is not set properly\n // See https://github.com/sass-mq/sass-mq/pull/10\n\n/// Base font size on the `<body>` element\n/// @type Number (unit)\n$mq-base-font-size: 16px !default;\n\n/// Responsive mode\n///\n/// Set to `false` to enable support for browsers that do not support @media queries,\n/// (IE <= 8, Firefox <= 3, Opera <= 9)\n///\n/// You could create a stylesheet served exclusively to older browsers,\n/// where @media queries are rasterized\n///\n/// @example scss\n/// // old-ie.scss\n/// $mq-responsive: false;\n/// @import 'main'; // @media queries in this file will be rasterized up to $mq-static-breakpoint\n/// // larger breakpoints will be ignored\n///\n/// @type Boolean\n/// @link https://github.com/sass-mq/sass-mq#responsive-mode-off Disabled responsive mode documentation\n$mq-responsive: true !default;\n\n/// Breakpoint list\n///\n/// Name your breakpoints in a way that creates a ubiquitous language\n/// across team members. It will improve communication between\n/// stakeholders, designers, developers, and testers.\n///\n/// @type Map\n/// @link https://github.com/sass-mq/sass-mq#seeing-the-currently-active-breakpoint Full documentation and examples\n$mq-breakpoints: (\n mobile: 320px,\n tablet: 740px,\n desktop: 980px,\n wide: 1300px\n) !default;\n\n/// Static breakpoint (for fixed-width layouts)\n///\n/// Define the breakpoint from $mq-breakpoints that should\n/// be used as the target width for the fixed-width layout\n/// (i.e. when $mq-responsive is set to 'false') in a old-ie.scss\n///\n/// @example scss\n/// // tablet-only.scss\n/// //\n/// // Ignore all styles above tablet breakpoint,\n/// // and fix the styles (e.g. layout) at tablet width\n/// $mq-responsive: false;\n/// $mq-static-breakpoint: tablet;\n/// @import 'main'; // @media queries in this file will be rasterized up to tablet\n/// // larger breakpoints will be ignored\n///\n/// @type String\n/// @link https://github.com/sass-mq/sass-mq#adding-custom-breakpoints Full documentation and examples\n$mq-static-breakpoint: desktop !default;\n\n/// Show breakpoints in the top right corner\n///\n/// If you want to display the currently active breakpoint in the top\n/// right corner of your site during development, add the breakpoints\n/// to this list, ordered by width, e.g. (mobile, tablet, desktop).\n///\n/// @type map\n$mq-show-breakpoints: () !default;\n\n/// Customize the media type (e.g. `@media screen` or `@media print`)\n/// By default sass-mq uses an \"all\" media type (`@media all and …`)\n///\n/// @type String\n/// @link https://github.com/sass-mq/sass-mq#changing-media-type Full documentation and examples\n$mq-media-type: all !default;\n\n/// Convert pixels to ems\n///\n/// @param {Number} $px - value to convert\n/// @param {Number} $base-font-size ($mq-base-font-size) - `<body>` font size\n///\n/// @example scss\n/// $font-size-in-ems: mq-px2em(16px);\n/// p { font-size: mq-px2em(16px); }\n///\n/// @requires $mq-base-font-size\n/// @returns {Number}\n@function mq-px2em($px, $base-font-size: $mq-base-font-size) {\n @if unitless($px) {\n @warn \"Assuming #{$px} to be in pixels, attempting to convert it into pixels.\";\n @return mq-px2em($px * 1px, $base-font-size);\n } @else if unit($px) == em {\n @return $px;\n }\n @return ($px / $base-font-size) * 1em;\n}\n\n/// Get a breakpoint's width\n///\n/// @param {String} $name - Name of the breakpoint. One of $mq-breakpoints\n///\n/// @example scss\n/// $tablet-width: mq-get-breakpoint-width(tablet);\n/// @media (min-width: mq-get-breakpoint-width(desktop)) {}\n///\n/// @requires {Variable} $mq-breakpoints\n///\n/// @returns {Number} Value in pixels\n@function mq-get-breakpoint-width($name, $breakpoints: $mq-breakpoints) {\n @if map-has-key($breakpoints, $name) {\n @return map-get($breakpoints, $name);\n } @else {\n @warn \"Breakpoint #{$name} wasn't found in $breakpoints.\";\n }\n}\n\n/// Media Query mixin\n///\n/// @param {String | Boolean} $from (false) - One of $mq-breakpoints\n/// @param {String | Boolean} $until (false) - One of $mq-breakpoints\n/// @param {String | Boolean} $and (false) - Additional media query parameters\n/// @param {String} $media-type ($mq-media-type) - Media type: screen, print…\n///\n/// @ignore Undocumented API, for advanced use only:\n/// @ignore @param {Map} $breakpoints ($mq-breakpoints)\n/// @ignore @param {String} $static-breakpoint ($mq-static-breakpoint)\n///\n/// @content styling rules, wrapped into a @media query when $responsive is true\n///\n/// @requires {Variable} $mq-media-type\n/// @requires {Variable} $mq-breakpoints\n/// @requires {Variable} $mq-static-breakpoint\n/// @requires {function} mq-px2em\n/// @requires {function} mq-get-breakpoint-width\n///\n/// @link https://github.com/sass-mq/sass-mq#responsive-mode-on-default Full documentation and examples\n///\n/// @example scss\n/// .element {\n/// @include mq($from: mobile) {\n/// color: red;\n/// }\n/// @include mq($until: tablet) {\n/// color: blue;\n/// }\n/// @include mq(mobile, tablet) {\n/// color: green;\n/// }\n/// @include mq($from: tablet, $and: '(orientation: landscape)') {\n/// color: teal;\n/// }\n/// @include mq(950px) {\n/// color: hotpink;\n/// }\n/// @include mq(tablet, $media-type: screen) {\n/// color: hotpink;\n/// }\n/// // Advanced use:\n/// $my-breakpoints: (L: 900px, XL: 1200px);\n/// @include mq(L, $breakpoints: $my-breakpoints, $static-breakpoint: L) {\n/// color: hotpink;\n/// }\n/// }\n@mixin mq(\n $from: false,\n $until: false,\n $and: false,\n $media-type: $mq-media-type,\n $breakpoints: $mq-breakpoints,\n $responsive: $mq-responsive,\n $static-breakpoint: $mq-static-breakpoint\n) {\n $min-width: 0;\n $max-width: 0;\n $media-query: '';\n\n // From: this breakpoint (inclusive)\n @if $from {\n @if type-of($from) == number {\n $min-width: mq-px2em($from);\n } @else {\n $min-width: mq-px2em(mq-get-breakpoint-width($from, $breakpoints));\n }\n }\n\n // Until: that breakpoint (exclusive)\n @if $until {\n @if type-of($until) == number {\n $max-width: mq-px2em($until);\n } @else {\n $max-width: mq-px2em(mq-get-breakpoint-width($until, $breakpoints)) - .01em;\n }\n }\n\n // Responsive support is disabled, rasterize the output outside @media blocks\n // The browser will rely on the cascade itself.\n @if $responsive == false {\n $static-breakpoint-width: mq-get-breakpoint-width($static-breakpoint, $breakpoints);\n $target-width: mq-px2em($static-breakpoint-width);\n\n // Output only rules that start at or span our target width\n @if (\n $and == false\n and $min-width <= $target-width\n and (\n $until == false or $max-width >= $target-width\n )\n and $media-type != 'print'\n ) {\n @content;\n }\n }\n\n // Responsive support is enabled, output rules inside @media queries\n @else {\n @if $min-width != 0 { $media-query: '#{$media-query} and (min-width: #{$min-width})'; }\n @if $max-width != 0 { $media-query: '#{$media-query} and (max-width: #{$max-width})'; }\n @if $and { $media-query: '#{$media-query} and #{$and}'; }\n\n // Remove unnecessary media query prefix 'all and '\n @if ($media-type == 'all' and $media-query != '') {\n $media-type: '';\n $media-query: str-slice(unquote($media-query), 6);\n }\n\n @media #{$media-type + $media-query} {\n @content;\n }\n }\n}\n\n/// Quick sort\n///\n/// @author Sam Richards\n/// @access private\n/// @param {List} $list - List to sort\n/// @returns {List} Sorted List\n@function _mq-quick-sort($list) {\n $less: ();\n $equal: ();\n $large: ();\n\n @if length($list) > 1 {\n $seed: nth($list, ceil(length($list) / 2));\n\n @each $item in $list {\n @if ($item == $seed) {\n $equal: append($equal, $item);\n } @else if ($item < $seed) {\n $less: append($less, $item);\n } @else if ($item > $seed) {\n $large: append($large, $item);\n }\n }\n\n @return join(join(_mq-quick-sort($less), $equal), _mq-quick-sort($large));\n }\n\n @return $list;\n}\n\n/// Sort a map by values (works with numbers only)\n///\n/// @access private\n/// @param {Map} $map - Map to sort\n/// @returns {Map} Map sorted by value\n@function _mq-map-sort-by-value($map) {\n $map-sorted: ();\n $map-keys: map-keys($map);\n $map-values: map-values($map);\n $map-values-sorted: _mq-quick-sort($map-values);\n\n // Reorder key/value pairs based on key values\n @each $value in $map-values-sorted {\n $index: index($map-values, $value);\n $key: nth($map-keys, $index);\n $map-sorted: map-merge($map-sorted, ($key: $value));\n\n // Unset the value in $map-values to prevent the loop\n // from finding the same index twice\n $map-values: set-nth($map-values, $index, 0);\n }\n\n @return $map-sorted;\n}\n\n/// Add a breakpoint\n///\n/// @param {String} $name - Name of the breakpoint\n/// @param {Number} $width - Width of the breakpoint\n///\n/// @requires {Variable} $mq-breakpoints\n///\n/// @example scss\n/// @include mq-add-breakpoint(tvscreen, 1920px);\n/// @include mq(tvscreen) {}\n@mixin mq-add-breakpoint($name, $width) {\n $new-breakpoint: ($name: $width);\n $mq-breakpoints: map-merge($mq-breakpoints, $new-breakpoint) !global;\n $mq-breakpoints: _mq-map-sort-by-value($mq-breakpoints) !global;\n}\n\n/// Show the active breakpoint in the top right corner of the viewport\n/// @link https://github.com/sass-mq/sass-mq#seeing-the-currently-active-breakpoint\n///\n/// @param {List} $show-breakpoints ($mq-show-breakpoints) - List of breakpoints to show in the top right corner\n/// @param {Map} $breakpoints ($mq-breakpoints) - Breakpoint names and sizes\n///\n/// @requires {Variable} $mq-breakpoints\n/// @requires {Variable} $mq-show-breakpoints\n///\n/// @example scss\n/// // Show breakpoints using global settings\n/// @include mq-show-breakpoints;\n///\n/// // Show breakpoints using custom settings\n/// @include mq-show-breakpoints((L, XL), (S: 300px, L: 800px, XL: 1200px));\n@mixin mq-show-breakpoints($show-breakpoints: $mq-show-breakpoints, $breakpoints: $mq-breakpoints) {\n body::before {\n background-color: #FCF8E3;\n border-bottom: 1px solid #FBEED5;\n border-left: 1px solid #FBEED5;\n color: #C09853;\n font: small-caption;\n padding: 3px 6px;\n pointer-events: none;\n position: fixed;\n right: 0;\n top: 0;\n z-index: 100;\n\n // Loop through the breakpoints that should be shown\n @each $show-breakpoint in $show-breakpoints {\n $width: mq-get-breakpoint-width($show-breakpoint, $breakpoints);\n @include mq($show-breakpoint, $breakpoints: $breakpoints) {\n content: \"#{$show-breakpoint} ≥ #{$width} (#{mq-px2em($width)})\";\n }\n }\n }\n}\n\n@if length($mq-show-breakpoints) > 0 {\n @include mq-show-breakpoints;\n}\n\n/*# sourceMappingURL=_sass-mq.scss.map */\n"]}