1var ERROR_CONTAINER_ID="form_module_container_errors",FIELD_ERROR_CLASS="form_module_field_error",SUCCESS_CONTAINER_ID="form_module_container_success";function nxgFormSubmission(e,n,o,t){e.preventDefault();var i=document.getElementById("form_"+n);if(i){t||(t="Submission Successful");var r=new XMLHttpRequest;nxgFormSubmission_disableSubmitButton(!0),nxgFormSubmission_breakDownNotifications(),r.onreadystatechange=function(){if(4===r.readyState)switch(nxgFormSubmission_disableSubmitButton(!1),r.status){case 200:nxgFormSubmission_submissionSuccessful(i,t,o);break;case 400:nxgFormSubmission_setUpErrors(i),nxgFormSubmission_setErrorOnForm(JSON.parse(r.responseText));break;default:alert("Unknown")}};var s=function(){r.open("post","/forms/submission/id/"+n),r.setRequestHeader("X-REQUESTED-WITH","XMLHttpRequest"),r.send(new FormData(i))},c=i.querySelectorAll('input[data-element="recaptcha_v3"]');if(c.length){if("undefined"==typeof Promise)return void s();for(var u=[],a=0;a<c.length;a++)u.push(executeRecaptchaV3(c[a]));Promise.all(u).then(s).catch((function(e){window.console&&"function"==typeof window.console.warn&&console.warn("reCAPTCHA v3 token generation failed",e),s()}))}else s()}}function nxgFormSubmission_setErrorOnForm(e){var n=document.getElementById(ERROR_CONTAINER_ID),o="";for(var t in e)if(e.hasOwnProperty(t)){var i=e[t],r=document.getElementById(t);for(var s in r&&r.classList&&r.classList.add(FIELD_ERROR_CLASS),i){if(i.hasOwnProperty(s))o+="<li>"+s+": "+i[s].join(", ")+' (<span class="goTo" onClick="nxgFormSubmission_scrollToError(\''+t+"')\">go to</span>)</li>"}}n&&(n.innerHTML="<h3>This form contains the following errors:</h3><ul>"+o+"</ul>")}function nxgFormSubmission_setUpErrors(e){var n=document.createElement("div");n.setAttribute("id",ERROR_CONTAINER_ID),e.prepend(n),nxgFormSubmission_isElementInView(n)||nxgFormSubmission_scrollToElement(n)}function nxgFormSubmission_breakDownNotifications(){var e=document.getElementById(ERROR_CONTAINER_ID),n=document.getElementById(SUCCESS_CONTAINER_ID),o=document.getElementsByClassName(FIELD_ERROR_CLASS);e&&e.parentNode.removeChild(e),n&&n.parentNode.removeChild(n);for(var t=0;t<o.length;t++)o[t].classList.remove(FIELD_ERROR_CLASS)}function nxgFormSubmission_disableSubmitButton(e){void 0===e&&(e=!1);for(var n=document.getElementsByName("Submit"),o=0;o<n.length;o++)n[o].disabled=e}function nxgFormSubmission_submissionSuccessful(e,n,o){if("null"===o||""===o){var t=document.createElement("div");t.setAttribute("id",SUCCESS_CONTAINER_ID),t.innerHTML=n,e.prepend(t),e.reset(),nxgFormSubmission_isElementInView(t)||nxgFormSubmission_scrollToElement(t)}else window.location.href=o}function nxgFormSubmission_scrollToError(e){var n=document.getElementById(e);n&&("function"==typeof n.focus&&n.focus(),nxgFormSubmission_isElementInView(n)||nxgFormSubmission_scrollToElement(n))}function nxgFormSubmission_isElementInView(e){var n=(window.pageYOffset||document.documentElement.scrollTop)-(document.documentElement.clientTop||0),o=n+window.innerHeight,t=offset(e);return t+e.clientHeight<=o&&t>=n}function nxgFormSubmission_scrollToElement(e){var n=offset(e)/2+100;document.body.scrollTop=n,document.documentElement.scrollTop=n}function isWindow(e){return null!=e&&e===e.window}function getWindow(e){return isWindow(e)?e:9===e.nodeType&&e.defaultView}function offset(e){var n,o,t={top:0,left:0},i=e&&e.ownerDocument;return n=i.documentElement,void 0!==e.getBoundingClientRect&&(t=e.getBoundingClientRect()),o=getWindow(i),t.top+o.pageYOffset-n.clientTop}function getGrecaptcha(){var e=window&&window.grecaptcha;return e&&"function"==typeof e.execute&&"function"==typeof e.ready?e:null}function waitForRecaptcha(e){return new Promise((function(e,n){var o=getGrecaptcha();if(o)e(o);else var t=0,i=window.setInterval((function(){t+=1;var o=getGrecaptcha();o?(window.clearInterval(i),e(o)):t>=30&&(window.clearInterval(i),n(new Error("reCAPTCHA v3 did not load in time.")))}),200)}))}function executeRecaptchaV3(e){var n=e.getAttribute("data-sitekey");if(!n)return Promise.resolve();var o=e.getAttribute("data-action")||e.name||"form_submission";return waitForRecaptcha(n).then((function(t){return new Promise((function(i,r){t.ready((function(){t.execute(n,{action:o}).then((function(n){e.value=n;try{var o;"function"==typeof Event?o=new Event("change",{bubbles:!0}):(o=document.createEvent("Event")).initEvent("change",!0,!0),e.dispatchEvent(o)}catch(e){window.console&&"function"==typeof window.console.warn&&console.warn("Unable to dispatch change event for reCAPTCHA field",e)}i()})).catch(r)}))}
1))}))}
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.