PageSourceSearch

https://modyrvale.co.uk/Scripts/dist/NHS.bundle.js

js modyrvale.co.uk collected 2026-09-29 23:29:19 UTC 22,468 bytes, 1 lines download raw bytes

1var NHS;(()=>{var e={320:e=>{e.exports={toggleAttribute:(e,t)=>{if(!e||!t)return;const s="true"===e.getAttribute(t)?"false":"true";e.setAttribute(t,s)},toggleConditionalInput:(e,t)=>{if(!e||!t)return;const s=e.getAttribute("aria-controls");if(s){const n=document.getElementById(s);n&&(e.checked?(n.classList.remove(t),e.setAttribute("aria-expanded","true")):(n.classList.add(t),e.setAttribute("aria-expanded","false")))}},generateUniqueID:function(){let e=(new Date).getTime();return void 0!==window.performance&&"function"==typeof window.performance.now&&(e+=window.performance.now()),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){const s=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"===t?s:3&s|8).toString(16)}))},setFocus:function(e,t={}){const s=e.getAttribute("tabindex");function n(){e.removeEventListener("blur",n),t.onBlur&&t.onBlur.call(e),s||e.removeAttribute("tabindex")}s||e.setAttribute("tabindex","-1"),e.addEventListener("focus",(function t(){e.removeEventListener("focus",t),e.addEventListener("blur",n)})),t.onBeforeFocus&&t.onBeforeFocus.call(e),e.focus()}}},431:e=>{class t{constructor(e){if(!e)return this;this.$module=e,this.debounceFormSubmitTimer=null,this.$module.addEventListener("keydown",this.handleKeyDown.bind(this)),this.$module.addEventListener("click",this.debounce.bind(this))}handleKeyDown(e){const{target:t}=e;"button"===t.getAttribute("role")&&32===e.keyCode&&(e.preventDefault(),t.click())}debounce(e){const{target:t}=e;if("true"===t.getAttribute("data-prevent-double-click"))return this.debounceFormSubmitTimer?(e.preventDefault(),!1):void(this.debounceFormSubmitTimer=setTimeout((()=>{this.debounceFormSubmitTimer=null}),1e3))}}e.exports=({scope:e=document}={})=>{e.querySelectorAll('[data-module="nhsuk-button"]').forEach((e=>{new t(e)}))}},957:e=>{class t{constructor(e){if(!e)return this;const s=e.querySelector(".nhsuk-js-character-count");if(!s)return this;this.$module=e,this.$textarea=s,this.$visibleCountMessage=null,this.$screenReaderCountMessage=null,this.lastInputTimestamp=null;const n=document.getElementById(`${this.$textarea.id}-info`);this.$textarea.insertAdjacentElement("afterend",n);const i=document.createElement("div");i.className="nhsuk-character-count__sr-status nhsuk-u-visually-hidden",i.setAttribute("aria-live","polite"),this.$screenReaderCountMessage=i,n.insertAdjacentElement("afterend",i);const o=document.createElement("div");o.className=n.className,o.classList.add("nhsuk-character-count__status"),o.setAttribute("aria-hidden","true"),this.$visibleCountMessage=o,n.insertAdjacentElement("afterend",o),n.classList.add("nhsuk-u-visually-hidden"),this.options=t.getDataset(this.$module);let a=this.defaults.characterCountAttribute;this.options.maxwords&&(a=this.defaults.wordCountAttribute),this.maxLength=this.$module.getAttribute(a),this.maxLength&&(this.$textarea.removeAttribute("maxlength"),this.bindChangeEvents(),"onpageshow"in window?window.addEventListener("pageshow",this.updateCountMessage.bind(this)):window.addEventListener("DOMContentLoaded",this.updateCountMessage.bind(this)),this.updateCountMessage())}static getDataset(e){const t={},{attributes:s}=e;if(s)for(let e=0;e<s.length;e++){const n=s[e],i=n.name.match(/^data-(.+)/);i&&(t[i[1]]=n.value)}return t}count(e){let t;return t=this.options.maxwords?(e.match(/\S+/g)||[]).length:e.length,t}bindChangeEvents(){const{$textarea:e}=this;e.addEventListener("keyup",this.handleKeyUp.bind(this)),e.addEventListener("focus",this.handleFocus.bind(this)),e.addEventListener("blur",this.handleBlur.bind(this))}checkIfValueChanged(){this.$textarea.oldValue||(this.$textarea.oldValue=""),this.$textarea.value!==this.$textarea.oldValue&&(this.$textarea.oldValue=this.$textarea.value,this.updateCountMessage())}updateCountMessage(){this.updateVisibleCountMessage(),this.updateScreenReaderCountMessage()}updateVisibleCountMessage(){const{$textarea:e}=this,{$visibleCountMessage:t}=this,s=this.maxLength-this.count(e.value);this.isOverThreshold()?t.classList.remove("nhsuk-character-count__message--disabled"):t.classList.add("nhsuk-character-count__message--disabled"),s<0?(e.classList.add("nhsuk-textarea--error"),t.classList.remove("nhsuk-hint"),t.classList.add("nhsuk-error-message")):(e.classList.remove("nhsuk-textarea--error"),t.classList.remove("nhsuk-error-message"),t.classList.add("nhsuk-hint")),t.innerHTML=this.formattedUpdateMessage()}updateScreenReaderCountMessage(){const{$screenReaderCountMessage:e}=this;this.isOverThreshold()?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",!0),e.innerHTML=this.formattedUpdateMessage()}formattedUpdateMessage(){const{$textarea:e}=this,{options:t}=this,s=this.maxLength-this.count(e.value);let n="remaining",i="character",o=s;return t.maxwords&&(i="word"),i+=-1===s||1===s?"":"s",n=s<0?"too many":"remaining",o=Math.abs(s),`You have ${o} ${i} ${n}`}isOverThreshold(){const{$textarea:e}=this,{options:t}=this,s=this.count(e.value),{maxLength:n}=this;return n*(t.threshold?t.threshold:0)/100<=s}handleKeyUp(){this.updateVisibleCountMessage(),this.lastInputTimestamp=Date.now()}handleFocus(){this.valueChecker=setInterval((()=>{(!this.lastInputTimestamp||Date.now()-500>=this.lastInputTimestamp)&&this.checkIfValueChanged()}),1e3)}handleBlur(){clearInterval(this.valueChecker)}}t.prototype.defaults={characterCountAttribute:"data-maxlength",wordCountAttribute:"data-maxwords"},e.exports=({scope:e=document}={})=>
1{e.querySelectorAll('[data-module="nhsuk-character-count"]').forEach((e=>{new t(e)}))}},249:(e,t,s)=>{const{toggleConditionalInput:n}=s(320),i=function(e){e.form.querySelectorAll('input[type="checkbox"]').forEach((e=>n(e,"nhsuk-checkboxes__conditional--hidden")))};e.exports=({scope:e=document}={})=>{const t=e.querySelectorAll(".nhsuk-checkboxes .nhsuk-checkboxes__input"),s=e=>{var t;n(e.target,"nhsuk-checkboxes__conditional--hidden"),e.target.checked&&(e.target.hasAttribute("data-checkbox-exclusive")?((t=e.target).form.querySelectorAll(`input[type="checkbox"][data-checkbox-exclusive-group="${t.getAttribute("data-checkbox-exclusive-group")}"]`).forEach((e=>{t.form===e.form&&e!==t&&(e.checked=!1)})),i(t)):function(e){e.form.querySelectorAll(`input[type="checkbox"][data-checkbox-exclusive][data-checkbox-exclusive-group="${e.getAttribute("data-checkbox-exclusive-group")}"]`).forEach((t=>{e.form===t.form&&(t.checked=!1)})),i(e)}(e.target))};"onpageshow"in window?window.addEventListener("pageshow",(()=>t.forEach((e=>i(e))))):window.addEventListener("DOMContentLoaded",(()=>t.forEach((e=>i(e))))),t.forEach((e=>i(e))),t.forEach((e=>{e.addEventListener("change",s)}))}},101:(e,t,s)=>{const{generateUniqueID:n,toggleAttribute:i}=s(320);e.exports=({scope:e=document}={})=>{e.querySelectorAll("details").forEach((e=>{"HTMLDetailsElement"in window&&e instanceof HTMLDetailsElement||e.hasAttribute("nhsuk-polyfilled")||(e=>{e.setAttribute("nhsuk-polyfilled","true");const t=e.querySelector(".nhsuk-details__text");t.id||t.setAttribute("id",`details-content-${n()}`);const s=e.querySelector(".nhsuk-details__summary");s.setAttribute("role","button"),s.setAttribute("aria-controls",t.id),s.setAttribute("tabIndex","0"),1==(null!==e.getAttribute("open"))?(s.setAttribute("aria-expanded","true"),t.setAttribute("aria-hidden","false")):(s.setAttribute("aria-expanded","false"),t.setAttribute("aria-hidden","true"),t.style.display="none"),s.addEventListener("click",(()=>{i(s,"aria-expanded"),i(t,"aria-hidden"),t.style.display="true"===t.getAttribute("aria-hidden")?"none":"",e.hasAttribute("open")?e.removeAttribute("open"):e.setAttribute("open","open")})),s.addEventListener("keydown",(e=>{13!==e.keyCode&&32!==e.keyCode||(e.preventDefault(),s.click())}))})(e)}))}},833:e=>{function t(e){(function(e){if("A"!==e.tagName||!1===e.href)return!1;const t=document.querySelector(e.hash);if(!t)return!1;const s=function(e){const t=e.closest("fieldset");if(t){const s=t.getElementsByTagName("legend");if(s.length){const t=s[0];if("checkbox"===e.type||"radio"===e.type)return t;const n=t.getBoundingClientRect().top,i=e.getBoundingClientRect();if(i.height&&window.innerHeight&&i.top+i.height-n<window.innerHeight/2)return t}}return document.querySelector(`label[for='${e.getAttribute("id")}']`)||e.closest("label")}(t);return!!s&&(s.scrollIntoView(),t.focus({preventScroll:!0}),!0)})(e.target)&&e.preventDefault()}e.exports=({focusOnPageLoad:e=!0,scope:s=document}={})=>{const n=s.querySelector(".nhsuk-error-summary");n&&(e&&n.focus(),n.addEventListener("click",t))}},169:e=>{class t{constructor(e){return e?(this.$module=e,this.navigationList=this.$module.querySelector(".nhsuk-header__navigation-list"),this.navigationItems=this.$module.querySelectorAll(".nhsuk-header__navigation-item"),this.mobileMenuToggleButton=this.$module.querySelector(".nhsuk-header__menu-toggle"),this.mobileMenuContainer=this.$module.querySelector(".nhsuk-mobile-menu-container"),this.navigationList&&this.navigationItems&&this.navigationItems.length&&this.mobileMenuToggleButton&&this.mobileMenuContainer?(this.mobileMenu=document.createElement("ul"),this.menuIsEnabled=!1,this.menuIsOpen=!1,this.handleEscapeKey=this.onEscapeKey.bind(this),this.handleUpdateNavigation=this.debounce(this.updateNavigation),this.handleToggleMobileMenu=this.toggleMobileMenu.bind(this),this.setupNavigation(),void this.updateNavigation()):this):this}debounce(e,t=100){let s;return(...n)=>{clearTimeout(s),s=setTimeout((()=>{e.apply(this,n)}),t)}}resetNavigation(){let e=0;this.breakpoints.forEach((t=>{this.navigationList.insertBefore(t.element,this.mobileMenuContainer),e+=t.element.offsetWidth,t.right=e})),this.width=this.navigationList.offsetWidth}setupNavigation(){this.breakpoints=[],this.navigationItems.forEac
1h((e=>{this.breakpoints.push({element:e,right:0})})),window.addEventListener("resize",this.handleUpdateNavigation)}setupMobileMenu(){this.mobileMenu.parentElement||(this.mobileMenuContainer.appendChild(this.mobileMenu),this.mobileMenu.classList.add("nhsuk-header__drop-down","nhsuk-header__drop-down--hidden"))}enableMobileMenu(){this.menuIsEnabled||(this.menuIsEnabled=!0,this.mobileMenuToggleButton.classList.add("nhsuk-header__menu-toggle--visible"),this.mobileMenuContainer.classList.add("nhsuk-mobile-menu-container--visible"),this.mobileMenuToggleButton.addEventListener("click",this.handleToggleMobileMenu))}disableMobileMenu(){this.menuIsEnabled&&(this.closeMobileMenu(),this.menuIsEnabled=!1,this.mobileMenuToggleButton.classList.remove("nhsuk-header__menu-toggle--visible"),this.mobileMenuContainer.classList.remove("nhsuk-mobile-menu-container--visible"),this.mobileMenuToggleButton.removeEventListener("click",this.handleToggleMobileMenu))}closeMobileMenu(){this.menuIsEnabled&&this.menuIsOpen&&(this.menuIsOpen=!1,this.mobileMenu.classList.add("nhsuk-header__drop-down--hidden"),this.$module.style.marginBottom=0,this.mobileMenuToggleButton.setAttribute("aria-expanded","false"),document.removeEventListener("keydown",this.handleEscapeKey))}onEscapeKey(e){"Escape"===e.key&&this.closeMobileMenu()}openMobileMenu(){if(!this.menuIsEnabled||this.menuIsOpen)return;this.menuIsOpen=!0,this.mobileMenu.classList.remove("nhsuk-header__drop-down--hidden");const e=this.mobileMenu.offsetHeight;this.$module.style.marginBottom=`${e}px`,this.mobileMenuToggleButton.setAttribute("aria-expanded","true"),document.addEventListener("keydown",this.handleEscapeKey)}toggleMobileMenu(){this.menuIsEnabled&&(this.menuIsOpen?this.closeMobileMenu():this.openMobileMenu())}updateNavigation(){this.resetNavigation(),this.breakpoints.filter((e=>e.right>this.width)).length?(this.setupMobileMenu(),this.enableMobileMenu(),this.width-=this.mobileMenuContainer.offsetWidth,this.breakpoints.forEach((e=>{e.right>this.width&&this.mobileMenu.insertAdjacentElement("beforeend",e.element)}))):this.disableMobileMenu()}}e.exports=(e={})=>{const s=(e.scope||document).querySelector(".nhsuk-navigation");new t(s)}},887:(e,t,s)=>{const{toggleConditionalInput:n}=s(320);e.exports=({scope:e=document}={})=>{const t=e.querySelectorAll(".nhsuk-radios--conditional .nhsuk-radios__input"),s=()=>{t.forEach((e=>n(e,"nhsuk-radios__conditional--hidden")))};"onpageshow"in window?window.addEventListener("pageshow",s):window.addEventListener("DOMContentLoaded",s),s(),t.forEach((e=>{e.addEventListener("change",s)}))}},413:(e,t,s)=>{const{setFocus:n}=s(320);e.exports=(e={})=>{const t=(e.scope||document).querySelector(".nhsuk-skip-link");if(!(t&&t instanceof HTMLAnchorElement))return;const s=t.hash.split("#").pop(),i=s?document.getElementById(s):null;i&&t.addEventListener("click",(()=>n(i,{onBeforeFocus(){i.classList.add("nhsuk-skip-link-focused-element")},onBlur(){i.classList.remove("nhsuk-skip-link-focused-element")}})))}},583:e=>{class t{constructor(e){this.$module=e,this.$tabs=e.querySelectorAll(".nhsuk-tabs__tab"),this.keys={down:40,left:37,right:39,up:38},this.jsHiddenClass="nhsuk-tabs__panel--hidden",this.showEvent=new CustomEvent("tab.show"),this.hideEvent=new CustomEvent("tab.hide"),"function"==typeof window.matchMedia?this.setupResponsiveChecks():this.setup()}setupResponsiveChecks(){this.mql=window.matchMedia("(min-width: 641px)"),"addEventListener"in this.mql?this.mql.addEventListener("change",this.checkMode.bind(this)):this.mql.addListener(this.checkMode.bind(this)),this.checkMode()}checkMode(){this.mql.matches?this.setup():this.teardown()}setup(){const{$module:e}=this,{$tabs:t}=this,s=e.querySelector(".nhsuk-tabs__list"),n=e.querySelectorAll(".nhsuk-tabs__list-item");if(!t||!s||!n)return;s.setAttribute("role","tablist"),n.forEach((e=>{e.setAttribute("role","presentation")})),t.forEach((e=>{this.setAttributes(e),e.boundTabClick=this.onTabClick.bind(this),e.boundTabKeydown=this.onTabKeydown.bind(this),e.addEventListener("click",e.boundTabClick,!0),e.addEventListener("keydown",e.boundTabKeydown,!0),this.hideTab(e)}));const i=this.getTab(window.location.hash)||this.$tabs[0];this.showTab(i),e.boundOnHashChange=this.onHashChange.bind(this),window.addEventListener("hashchange",e.boun
1dOnHashChange,!0)}teardown(){const{$module:e}=this,{$tabs:t}=this,s=e.querySelector(".nhsuk-tabs__list"),n=e.querySelectorAll(".nhsuk-tabs__list-item");t&&s&&n&&(s.removeAttribute("role"),n.forEach((e=>{e.removeAttribute("role","presentation")})),t.forEach((e=>{e.removeEventListener("click",e.boundTabClick,!0),e.removeEventListener("keydown",e.boundTabKeydown,!0),this.unsetAttributes(e)})),window.removeEventListener("hashchange",e.boundOnHashChange,!0))}onHashChange(){const{hash:e}=window.location,t=this.getTab(e);if(!t)return;if(this.changingHash)return void(this.changingHash=!1);const s=this.getCurrentTab();this.hideTab(s),this.showTab(t),t.focus()}hideTab(e){this.unhighlightTab(e),this.hidePanel(e)}showTab(e){this.highlightTab(e),this.showPanel(e)}getTab(e){return this.$module.querySelector(`.nhsuk-tabs__tab[href="${e}"]`)}setAttributes(e){const s=t.getHref(e).slice(1);e.setAttribute("id",`tab_${s}`),e.setAttribute("role","tab"),e.setAttribute("aria-controls",s),e.setAttribute("aria-selected","false"),e.setAttribute("tabindex","-1");const n=this.getPanel(e);n.setAttribute("role","tabpanel"),n.setAttribute("aria-labelledby",e.id),n.classList.add(this.jsHiddenClass)}unsetAttributes(e){e.removeAttribute("id"),e.removeAttribute("role"),e.removeAttribute("aria-controls"),e.removeAttribute("aria-selected"),e.removeAttribute("tabindex");const t=this.getPanel(e);t.removeAttribute("role"),t.removeAttribute("aria-labelledby"),t.removeAttribute("tabindex"),t.classList.remove(this.jsHiddenClass)}onTabClick(e){e.target.classList.contains("nhsuk-tabs__tab")||(e.stopPropagation(),e.preventDefault()),e.preventDefault();const t=e.target,s=this.getCurrentTab();this.hideTab(s),this.showTab(t),this.createHistoryEntry(t)}createHistoryEntry(e){const s=this.getPanel(e),{id:n}=s;s.id="",this.changingHash=!0,window.location.hash=t.getHref(e).slice(1),s.id=n}onTabKeydown(e){switch(e.keyCode){case this.keys.left:case this.keys.up:this.activatePreviousTab(),e.preventDefault();break;case this.keys.right:case this.keys.down:this.activateNextTab(),e.preventDefault()}}activateNextTab(){const e=this.getCurrentTab(),t=e.parentNode.nextElementSibling;let s;t&&(s=t.querySelector(".nhsuk-tabs__tab")),s&&(this.hideTab(e),this.showTab(s),s.focus(),this.createHistoryEntry(s))}activatePreviousTab(){const e=this.getCurrentTab(),t=e.parentNode.previousElementSibling;let s;t&&(s=t.querySelector(".nhsuk-tabs__tab")),s&&(this.hideTab(e),this.showTab(s),s.focus(),this.createHistoryEntry(s))}getPanel(e){return this.$module.querySelector(t.getHref(e))}showPanel(e){const t=this.getPanel(e);t.classList.remove(this.jsHiddenClass),t.dispatchEvent(this.showEvent)}hidePanel(e){const t=this.getPanel(e);t.classList.add(this.jsHiddenClass),t.dispatchEvent(this.hideEvent)}unhighlightTab(e){e.setAttribute("aria-selected","false"),e.parentNode.classList.remove("nhsuk-tabs__list-item--selected"),e.setAttribute("tabindex","-1")}highlightTab(e){e.setAttribute("aria-selected","true"),e.parentNode.classList.add("nhsuk-tabs__list-item--selected"),e.setAttribute("tabindex","0")}getCurrentTab(){return this.$module.querySelector(".nhsuk-tabs__list-item--selected .nhsuk-tabs__tab")}static getHref(e){const t=e.getAttribute("href");return t.slice(t.indexOf("#"),t.length)}}e.exports=({scope:e=document}={})=>{e.querySelectorAll('[data-module="nhsuk-tabs"]').forEach((e=>{new t(e)}))}},545:(e,t,s)=>{const n=s(431),i=s(957),o=s(249),a=s(101),r=s(833),u=s(169),h=s(887),l=s(413),d=s(583);s(317),e.exports={initButton:n,initCharacterCount:i,initCheckboxes:o,initDetails:a,initErrorSummary:r,initHeader:u,initRadios:h,initSkipLink:l,initTabs:d,initAll:function(e){u({scope:e}),l({scope:e}),n({scope:e}),i({scope:e}),o({scope:e}),a({scope:e}),r({scope:e}),h({scope:e}),d({scope:e})}}},317:()=>{NodeList.prototype.forEach||(NodeList.prototype.forEach=Array.prototype.forEach),Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{enumerable:!1,value(e){return this.filter((t=>t===e)).length>0}}),Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(e){var t=this;do{if(Element.prototype.matches.call(t,e))return t;t=t.parentElement||t.parentNode}while(null!==t&&1===t.nodeType);return null}),"function"!=typeof window.CustomEvent&&(window.CustomEvent=function(e,t){t=t||{bubbles:!1,cancelable:!1,detail:null};var s=document.createEvent("CustomEvent");
1return s.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),s})}},t={};function s(n){var i=t[n];if(void 0!==i)return i.exports;var o=t[n]={exports:{}};return e[n](o,o.exports,s),o.exports}s.d=(e,t)=>{for(var n in t)s.o(t,n)&&!s.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},s.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),s.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};(()=>{"use strict";s.r(n),s.d(n,{Helpers:()=>t});var e=s(545);const t={updatePageTitleError:()=>{const e=document.title.startsWith("Error: ");$(".nhsuk-error-summary:not(.d-none)").length?e||(document.title=`Error: ${document.title}`):e&&(document.title=document.title.substring(7))}};function i(e,s){const n=e.children(".nhsuk-error-summary"),i=["nhsuk-input","nhsuk-select","nhsuk-radios__input","nhsuk-date-input","nhsuk-textarea"],o=e=>e.find(i.map((e=>`.${e}`)).join(",")).first(),a=(e,t)=>{const s=o(e),n=e.find(".nhsuk-error-message");return e.toggleClass("nhsuk-form-group--error",!!t),i.forEach((e=>{s.hasClass(e)&&s.toggleClass(`${e}--error`,!!t)})),n.toggleClass("d-none",!t).children(".nhsuk-error-message-text").text(t),t},r=e.serialize(),u=e.attr("action");$.ajax({url:u,data:r,type:"POST",cache:!1,success:i=>{i.Success?(n.addClass("d-none"),n.find(".nhsuk-error-summary__list").empty(),e.find(".nhsuk-form-group").each(((e,t)=>a($(t))))):(t=>{const s=Object.fromEntries(t.map((e=>[e.Key,e.Error]))),i=e.find(".nhsuk-form-group").filter(((e,t)=>{const n=$(t),i=o(n),r=s[i.attr("name")];return a(n,r)})).map(((e,t)=>{const n=o($(t)),i=o(n);return`<li><a href="#${(i.length?i:n).attr("id")}">${s[n.attr("name")]}</a></li>`}));s.Error&&i.push(`<li>${s.Error}</li>`),(e=>{n.removeClass("d-none").focus(),n.find(".nhsuk-error-summary__list").html(e)}
1)(i.toArray())})(i.Errors),t.updatePageTitleError(),s(e,i)}})}const o=(e,t)=>{const s=(e,t)=>{if(t.Success){const t=e.parent();t.siblings(".alert-success").removeClass("d-none"),t.hide()}};$(e).on("submit",(e=>{e.preventDefault();const n=$(e.target),o=n.find("input[name='sitekey']").val();grecaptcha.ready((()=>{try{grecaptcha.execute(o,{action:t}).then((e=>{n.find("[name='Captcha']").val(e),i(n,s)}))}catch(e){console.error(e);const t="<li>There was an error contacting reCAPTCHA, Please try again</li>",s=n.children(".nhsuk-error-summary");s.removeClass("d-none").focus(),s.find(".nhsuk-error-summary__list").html(t)}}))}))};function a(){$(".nhsuk-date-input").each(((e,t)=>{$(t).find('input[type="text"]').on("input",(()=>{const e=$(t).find('input[name="day"]')[0].value,s=$(t).find('input[name="month"]')[0].value,n=$(t).find('input[name="year"]')[0].value,i=e=>("0"+e).slice(-2);$(t).find('input[type="hidden"]')[0].value=`${i(e)}-${i(s)}-${n}`}))})),$(".nhsuk-select__conditional").each(((e,t)=>{$(t).siblings(".nhsuk-select").on("change",(e=>{const s=$(e.target).children("[data-is-other]:selected").length;$(t).toggleClass("nhsuk-select__conditional--hidden",!s),$(e.target).attr("aria-expanded",!!+s)}))})),$(".nhsuk-checkboxes").each(((e,t)=>{$(t).find(".nhsuk-checkboxes__input").on("change",(()=>{const e=$(t).find(".nhsuk-checkboxes__input:checked").map(((e,t)=>$(t).val())).toArray().join(",");$(t).find('input[type="hidden"]').val(e)}))}))}s(317),$(window).on("DOMContentLoaded",(()=>{(0,e.initAll)(),a(),o(".newsletter-signup-nhs","newsletterwidget"),o(".fft-submit-nhs","fftwidget"),o(".ppg-signup-nhs","ppgsignup"),o(".ppg-contact-nhs","ppgcontact"),(()=>{const e=(e,t)=>{t.Success?$("#search-results").html(t.Content):$("#search-results").empty()};$(".services-near-me-nhs").on("submit",(t=>{t.preventDefault();const s=$(t.target);s.find("[name='Page']").val(1),i(s,e)})),$(document).on("click",".page-link",(t=>{const s=$(t.target).data("page"),n=$(".services-near-me-nhs");n.find("[name='Page']").val(s),i(n,e)}))})()})),$(window).on("registerNhsFormBuilderEvents",a)})(),NHS=n})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.