PageSourceSearch

https://www.landrover.com.au/etc.clientlibs/jlr/clientlibs/clientl…-portal-override-js.3093c6aaac3fe29cb63d.js

js landrover.com.au collected 2026-10-02 03:38:18 UTC 9,415 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkaem_maven_archetype=self.webpackChunkaem_maven_archetype||[]).push([["components-configuratorprompt-customer-portal-override-js"],{71674:function(t,e,r){function n(t){return n="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},n(t)}function o(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,i(n.key),n)}}function i(t){var e=function(t,e){if("object"!=n(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var o=r.call(t,e||"default");if("object"!=n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==n(e)?e:e+""}r.r(e),r.d(e,{customerPortalOverride:function(){return O},fetchCustomerDataFromCDX:function(){return g},getConfigData:function(){return w},getCustomerPortalEndpointUrl:function(){return j},getValidNameplates:function(){return k}});var a=function(){return t=function t(){var e,r,n,o=this,a=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),e=this,n=function(){return o.hasExhaustedAttempts()?(o.cleanup(),o.reject(!0)):o.hasNotFound()?(o.schedule(),!1):(o.cleanup(),o.resolve(!0))},(r=i(r="testVariableLoaded"))in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n;
1var u=a.maxAttempts,c=a.lookForVariable,f=a.timeout;this.maxAttempts=u,this.lookForVariable=c,this.timeout=f||1e3,this.attempts=0,this.intervalId=null,this.reject=function(){},this.resolve=function(){}},(e=[{key:"find",value:function(){var t=this;return new Promise(function(e,r){t.reject=r,t.resolve=e,t.schedule(),window.addEventListener("load",t.testVariableLoaded)})}},{key:"hasExhaustedAttempts",value:function(){return this.attempts>this.maxAttempts}},{key:"hasFound",value:function(){return this.lookForVariable&&r.g[this.lookForVariable]}},{key:"hasNotFound",value:function(){return!this.hasFound()}},{key:"cleanup",value:function(){this.intervalId&&clearTimeout(this.intervalId),window.removeEventListener("load",this.testVariableLoaded)}},{key:"schedule",value:function(){this.attempts+=1,this.intervalId=setTimeout(this.testVariableLoaded,this.timeout)}}])&&o(t.prototype,e),n&&o(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e,n}(),u=new Map;function c(t){return c="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},c(t)}function f(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function l(t,e,r){return(e=function(t){var e=function(t,e){if("object"!=c(t)||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=c(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==c(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var s=function(){return new Promise(function(t,e){(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.lookForVariable;if(!u.has(e)){var r=new a(t);u.set(e,r.find())}return u.get(e)})({lookForVariable:"_GigyaToken",maxAttempts:20,timeout:500}).then(function(){t()}).catch(function(){e()})})},p=function(t){return new Promise(function(e){window.gigya.accounts.getJWT(function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?f(Object(r),!0).forEach(function(e){l(t,e,r[e])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):f(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))})}return t}({callback:function(t){e(t)}},t))})};function d(t){return function(t){if(Array.isArray(t))return m(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return m(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?m(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function y(){var t,e,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toStringTag||"@@toStringTag";function i(r,n,o,i){var c=n&&n.prototype instanceof u?n:u,f=Object.create(c.prototype);return b(f,"_invoke",function(r,n,o){var i,u,c,f=0,l=o||[],s=!1,p={p:0,n:0,v:t,a:d,f:d.bind(t,4),d:function(e,r){return i=e,u=0,c=t,p.n=r,a}};function d(r,n){for(u=r,c=n,e=0;!s&&f&&!o&&e<l.length;e++){var o,i=l[e],d=p.p,m=i[2];r>3?(o=m===n)&&(c=i[(u=i[4])?5:(u=3,3)],i[4]=i[5]=t):i[0]<=d&&((o=r<2&&d<i[1])?(u=0,p.v=n,p.n=i[1]):d<m&&(o=r<3||i[0]>n||n>m)&&(i[4]=r,i[5]=n,p.n=m,u=0))}if(o||r>1)return a;throw s=!0,n}return function(o,l,m){if(f>1)throw TypeError("Generator is already running");for(s&&1===l&&d(l,m),u=l,c=m;(e=u<2?t:c)||!s;){i||(u?u<3?(u>1&&(p.n=-1),d(u,c)):p.n=c:p.v=c);
1try{if(f=2,i){if(u||(o="next"),e=i[o]){if(!(e=e.call(i,c)))throw TypeError("iterator result is not an object");if(!e.done)return e;c=e.value,u<2&&(u=0)}else 1===u&&(e=i.return)&&e.call(i),u<2&&(c=TypeError("The iterator does not provide a '"+o+"' method"),u=1);i=t}else if((e=(s=p.n<0)?c:r.call(n,p))!==a)break}catch(e){i=t,u=1,c=e}finally{f=1}}return{value:e,done:s}}}(r,o,i),!0),f}var a={};function u(){}function c(){}function f(){}e=Object.getPrototypeOf;var l=[][n]?e(e([][n]())):(b(e={},n,function(){return this}),e),s=f.prototype=u.prototype=Object.create(l);function p(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,f):(t.__proto__=f,b(t,o,"GeneratorFunction")),t.prototype=Object.create(s),t}return c.prototype=f,b(s,"constructor",f),b(f,"constructor",c),c.displayName="GeneratorFunction",b(f,o,"GeneratorFunction"),b(s),b(s,o,"Generator"),b(s,n,function(){return this}),b(s,"toString",function(){return"[object Generator]"}),(y=function(){return{w:i,m:p}})()}function b(t,e,r,n){var o=Object.defineProperty;try{o({},"",{})}catch(t){o=0}b=function(t,e,r,n){if(e)o?o(t,e,{value:r,enumerable:!n,configurable:!n,writable:!n}):t[e]=r;else{var i=function(e,r){b(t,e,function(t){return this._invoke(e,r,t)})};i("next",0),i("throw",1),i("return",2)}},b(t,e,r,n)}function v(t,e,r,n,o,i,a){try{var u=t[i](a),c=u.value}catch(t){return void r(t)}u.done?e(c):Promise.resolve(c).then(n,o)}function h(t){return function(){var e=this,r=arguments;return new Promise(function(n,o){var i=t.apply(e,r);function a(t){v(i,n,o,a,u,"next",t)}function u(t){v(i,n,o,a,u,"throw",t)}a(void 0)})}}var g=function(){var t=h(y().m(function t(e,r){var n,o,i;return y().w(function(t){for(;;)switch(t.n){case 0:return t.n=1,fetch(r,{method:"GET",withCredentials:!0,credentials:"include",headers:{Authorization:"Bearer ".concat(e)}});case 1:if(n=t.v,o=function(t){return t.sort(function(t,e){return e.lastModified-t.lastModified})},!n.ok||200!==n.status){t.n=3;break}return t.n=2,n.json();case 2:return i=t.v,t.a(2,o(i.Configurations));case 3:return t.a(2,{})}},t)}));return function(e,r){return t.apply(this,arguments)}}(),w=function(t){return $.ajax({method:"GET",url:t.rulesEngineUrl,dataType:"jsonp",jsonpCallback:"rcjson"})},j=function(){var t=document.querySelector("[data-cdx-api-endpoint-url]"),e=t&&t.getAttribute("data-cdx-api-endpoint-url");return e&&"cdx.api.endpoint.url"!==e?e:null},k=function(){return d(document.querySelectorAll(".ConfiguratorPrompt[data-nameplate]")).map(function(t){return t.getAttribute("data-nameplate")})},O=function(){var t=h(y().m(function t(){var e,r,n,o,i,a,u,c,f,l;return y().w(function(t){for(;;)switch(t.n){case 0:if(e=j(),r=k(),(n=document.querySelector(".ConfiguratorPrompt__saved-build-data").dataset).cdxEnabled&&"true"===n.cdxEnabled&&document.querySelector(".ConfiguratorPrompt[data-use-my-jlr-call]")){t.n=1;break}return t.a(2,!1);case 1:return t.n=2,s().then(function(){return!0}).catch(function(){return!1});case 2:if(t.v){t.n=3;break}return t.a(2,!1);case 3:return t.n=4,p({fields:"data.crm_id,profile.firstName,profile.lastName",expiration:10});case 4:if((o=t.v)&&"FAIL"!==o.status&&o.id_token){t.n=5;break}return t.a(2,!1);case 5:return t.n=6,g(o.id_token,e);case 6:i=t.v,a=!1,u=0;case 7:if(!(u<i.length)){t.n=10;break}return t.n=8,w(i[u],u);case 8:if(!(c=t.v).metadata||"200"!==c.metadata.status){t.n=9;break}if(f=c["feature-dictionary"].vehicle.description||!1,l=Object.values(f)[0]||!1,!(0===r.length||l&&r.includes(l.toLowerCase()))){t.n=9;break}return a={configData:c,customerData:i[u]},t.a(3,10);case 9:u+=1,t.n=7;break;case 10:return t.a(2,a)}},t)}));return function(){return t.apply(this,arguments)}}()}}]);

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.