PageSourceSearch

https://www.apprenticeship.gov/themes/journeyperson/build/js/modules/stateOffices.bundle.js?tlcz5r

js apprenticeship.gov collected 2026-09-24 08:51:56 UTC 6,520 bytes, 2 lines download raw bytes

1(()=>{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,t){this.name="AggregateError",this.errors=e,this.message=t||""}t.prototype=Error.prototype;function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}var r=setTimeout;function o(e){return Boolean(e&&void 0!==e.length)}function i(){}function c(e){if(!(this instanceof c))throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],d(e,this)}function a(e,t){for(;3===e._state;)e=e._value;0!==e._state?(e._handled=!0,c._immediateFn(function(){var n=1===e._state?t.onFulfilled:t.onRejected;if(null!==n){var r;try{r=n(e._value)}catch(e){return void u(t.promise,e)}s(t.promise,r)}else(1===e._state?s:u)(t.promise,e._value)})):e._deferreds.push(t)}function s(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&("object"===n(t)||"function"==typeof t)){var r=t.then;if(t instanceof c)return e._state=3,e._value=t,void l(e);if("function"==typeof r)return void d((o=r,i=t,function(){o.apply(i,arguments)}),e)}e._state=1,e._value=t,l(e)}catch(t){u(e,t)}var o,i}function u(e,t){e._state=2,e._value=t,l(e)}function l(e){2===e._state&&0===e._deferreds.length&&c._immediateFn(function(){e._handled||c._unhandledRejectionFn(e._value)});for(var t=0,n=e._deferreds.length;t<n;t++)a(e,e._deferreds[t]);e._deferreds=null}function f(e,t,n){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.promise=n}function d(e,t){var n=!1;try{e(function(e){n||(n=!0,s(t,e))},function(e){n||(n=!0,u(t,e))})}catch(e){if(n)return;n=!0,u(t,e)}}c.prototype.catch=function(e){return this.then(null,e)},c.prototype.then=function(e,t){var n=new this.constructor(i);return a(this,new f(e,t,n)),n},c.prototype.finally=function(e){var t=this.constructor;return this.then(function(n){return t.resolve(e()).then(function(){return n})},function(n){return t.resolve(e()).then(function(){return t.reject(n)})})},c.all=function(e){return new c(function(t,r){if(!o(e))return r(new TypeError("Promise.all accepts an array"));var i=Array.prototype.slice.call(e);if(0===i.length)return t([]);var c=i.length;function a(e,o){try{if(o&&("object"===n(o)||"function"==typeof o)){var s=o.then;if("function"==typeof s)return void s.call(o,function(t){a(e,t)},r)}i[e]=o,0===--c&&t(i)}catch(e){r(e)}}for(var s=0;s<i.length;s++)a(s,i[s])})},c.any=function(e){var n=this;return new n(function(r,o){if(!e||void 0===e.length)return o(new TypeError("Promise.any accepts an array"));var i=Array.prototype.slice.call(e);if(0===i.length)return o();for(var c=[],a=0;a<i.length;a++)try{n.resolve(i[a]).then(r).catch(function(e){c.push(e),c.length===i.length&&o(new t(c,"All promises were rejected"))})}catch(e){o(e)}})},c.allSettled=function(t){return new this(function(n,r){if(!t||void 0===t.length)return r(new TypeError(e(t)+" "+t+" is not iterable(cannot read property Symbol(Symbol.iterator))"));var o=Array.prototype.slice.call(t);if(0===o.length)return n([]);var i=o.length;function c(t,r){if(r&&("object"===e(r)||"function"==typeof r)){var a=r.then;if("function"==typeof a)return void a.call(r,function(e){c(t,e)},function(e){o[t]={status:"rejected",reason:e},0===--i&&n(o)})}o[t]={status:"fulfilled",value:r},0===--i&&n(o)}for(var a=0;a<o.length;a++)c(a,o[a])})},c.resolve=function(e){return e&&"object"===n(e)&&e.constructor===c?e:new c(function(t){t(e)})},c.reject=function(e){return new c(function(t,n){n(e)})},c.race=function(e){return new c(function(t,n){if(!o(e))return n(new TypeError("Promise.race accepts an array"));for(var r=0,i=e.length;r<i;r++)c.resolve(e[r]).then(t,n)})},c._immediateFn="function"==typeof setImmediate&&function(e){setImmediate(e)}||function(e){r(e,0)},c._unhandledRejectionFn=function(e){"undefined"!=typeof console&&console&&console.warn("Possible Unhandled Promise Rejection:",e)};const p=c;window.Promise||(window.Promise=p),document.querySelectorAll(".us-states-and-territories").forEach(function(e){e.addEventListener("submit",function(t){t.preventDefault();var n=e.querySelector("select"),r=n.options[n.selectedIndex].value;document.querySelector(".state-office").classList.add("jp-hidden"),document.querySelector(".state-office").setAttribute("aria-hidden","true"),document.querySelector(".partner-resources__loading").classList.remove("jp-hidden"),document.querySelector(".partner-resources__loading").setAttribute("aria-hidden","false");var o=fetch("/api/partner-resources/offices?search=".concat(r,"&regional=false"),{method:"GET"}).then(function(e){return e.json()});Promise.all([o]).then(function(e){var t=e[0].value;document.querySelector(".partner-resources__loading").classList.add("jp-hidden"),document.querySelector(".partner-resources__loading").setAttribute("aria-hidden","true"),document.querySelector(".state-office").classList.remove("jp-hidden"),document.querySelector(".state-office").setAttribute("aria-hidden","false");var n="";t.forEach(function(e){var t;t="<h4>".concat(e.name,"</h4>"),t+="<address>";var r=""!==e.Address.line1?"".concat(e.Address.line1,"<br />"):"",o=""!==e.Address.line2?"".concat(e.Address.line2,"<br />"):"";t+='<p class="state-office__address">'.concat(r).concat(o).concat(e.Address.city,", ").concat(e.Address.state," ").concat(e.Address.zip,"</p>"),t+='<div class="state-office__info">',t+='<div class="state-office__item">',t+='<p class="cell">Contact: </p>';var i=JSON.parse(e.additionalProperties),c=i.contactPerson?i.contactPerson.split(", "):["",""];t+='<p class="state-office__value cell">'.concat(c[0]),t+="</div>",i.phone&&(t+='<div class="state-office__item">',t+='<p class="cell">Phone: </p>',t+='<p class="state-office__value cell">'.concat(i.phone,"</p>"),t+="</div>"),t+="</div>",i.email&&(t+='<p><a class="btn state-office__email" href="mailto:'.concat(i.email,'" aria-label="Email ').concat(i.email,'">Email</a></p>')),n+=t+="</address>"}),""===n&&(n="<p class='margin-top-1'>There are no offices at the selected location.</p>"),document.querySelector(".state-office").innerHTML=n})})},!1)})();
2//# sourceMappingURL=stateOffices.bundle.js.map

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.