https://www.arsdesignio.de/theme/34044974d1e591008225efa031a8c681/…/zeobv-get-notified.js?1791366288
1(()=>{"use strict";var e={857:e=>{var t=function(e){var t;return!!e&&"object"==typeof e&&"[object RegExp]"!==(t=Object.prototype.toString.call(e))&&"[object Date]"!==t&&e.$$typeof!==s},s="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function r(e,t){return!1!==t.clone&&t.isMergeableObject(e)?o(Array.isArray(e)?[]:{},e,t):e}function i(e,t,s){return e.concat(t).map(function(e){return r(e,s)})}function n(e){return Object.keys(e).concat(Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[])}function a(e,t){try{return t in e}catch(e){return!1}}function o(e,s,c){(c=c||{}).arrayMerge=c.arrayMerge||i,c.isMergeableObject=c.isMergeableObject||t,c.cloneUnlessOtherwiseSpecified=r;var l,u,h=Array.isArray(s);return h!==Array.isArray(e)?r(s,c):h?c.arrayMerge(e,s,c):(u={},(l=c).isMergeableObject(e)&&n(e).forEach(function(t){u[t]=r(e[t],l)}),n(s).forEach(function(t){(!a(e,t)||Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))&&(a(e,t)&&l.isMergeableObject(s[t])?u[t]=(function(e,t){if(!t.customMerge)return o;var s=t.customMerge(e);return"function"==typeof s?s:o})(t,l)(e[t],s[t],l):u[t]=r(s[t],l))}),u)}o.all=function(e,t){if(!Array.isArray(e))throw Error("first argument should be an array");return e.reduce(function(e,s){return o(e,s,t)},{})},e.exports=o}},t={};function s(r){var i=t[r];if(void 0!==i)return i.exports;var n=t[r]={exports:{}};return e[r](n,n.exports,s),n.exports}(()=>{s.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return s.d(t,{a:t}),t}})(),(()=>{s.d=(e,t)=>{for(var r in t)s.o(t,r)&&!s.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}})(),(()=>{s.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t)})(),(()=>{var e=s(857),t=s.n(e);class r{static ucFirst(e){return e.charAt(0).toUpperCase()+e.slice(1)}static lcFirst(e){return e.charAt(0).toLowerCase()+e.slice(1)}static toDashCase(e){return e.replace(/([A-Z])/g,"-$1").replace(/^-/,"").toLowerCase()}static toLowerCamelCase(e,t){let s=r.toUpperCamelCase(e,t);return r.lcFirst(s)}static toUpperCamelCase(e,t){return t?e.split(t).map(e=>r.ucFirst(e.toLowerCase())).join(""):r.ucFirst(e.toLowerCase())}static parsePrimitive(e){try{return/^\d+(.|,)\d+$/.test(e)&&(e=e.replace(",",".")),JSON.parse(e)}catch(t){return e.toString()}}}class i{static isNode(e){return"object"==typeof e&&null!==e&&(e===document||e===window||e instanceof Node)}static hasAttribute(e,t){if(!i.isNode(e))throw Error("The element must be a valid HTML Node!");return"function"==typeof e.hasAttribute&&e.hasAttribute(t)}static getAttribute(e,t){let s=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(s&&!1===i.hasAttribute(e,t))throw Error('The required property "'.concat(t,'" does not exist!'));if("function"!=typeof e.getAttribute){if(s)throw Error("This node doesn't support the getAttribute function!");return}return e.getAttribute(t)}static getDataAttribute(e,t){let s=!(arguments.length>2)||void 0===arguments[2]||arguments[2],n=t.replace(/^data(|-)/,""),a=r.toLowerCamelCase(n,"-");if(!i.isNode(e)){if(s)throw Error("The passed node is not a valid HTML Node!");return}if(void 0===e.dataset){if(s)throw Error("This node doesn't support the dataset attribute!");return}let o=e.dataset[a];if(void 0===o){if(s)throw Error('The required data attribute "'.concat(t,'" does not exist on ').concat(e,"!"));return o}return r.parsePrimitive(o)}static querySelector(e,t){let s=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(s&&!i.isNode(e))throw Error("The parent node is not a valid HTML Node!");let r=e.querySelector(t)||!1;if(s&&!1===r)throw Error('The required element "'.concat(t,'" does not exist in parent node!'));return r}static querySelectorAll(e,t){let s=!(arguments.length>2)||void 0===arguments[2]||arguments[2];if(s&&!i.isNode(e))throw Error("The parent node is not a valid HTML Node!");let r=e.querySelectorAll(t);if(0===r.length&&(r=!1),s&&!1===r)throw Error('At least one item of "'.concat(t,'" must exist in parent node!'));return r}static getFocusableElements(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return e.querySelectorAll('\n input:not([tabindex^="-"]):not([disabled]):not([type="hidden"]),\n select:not([tabindex^="-"]):not([disabled]),\n textarea:not([tabindex^="-"]):not([disabled]),\n button:not([tabindex^="-"]):not([disabled]),\n a[href]:not([tabindex^="-"]):not([disabled]),\n [tabindex]:not
1([tabindex^="-"]):not([disabled])\n ')}static getFirstFocusableElement(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return this.getFocusableElements(e)[0]}static getLastFocusableElement(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document,t=this.getFocusableElements(e);return t[t.length-1]}}class n{publish(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=new CustomEvent(e,{detail:t,cancelable:s});return this.el.dispatchEvent(r),r}subscribe(e,t){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this,i=e.split("."),n=s.scope?t.bind(s.scope):t;if(s.once&&!0===s.once){let t=n;n=function(s){r.unsubscribe(e),t(s)}}return this.el.addEventListener(i[0],n),this.listeners.push({splitEventName:i,opts:s,cb:n}),!0}unsubscribe(e){let t=e.split(".");return this.listeners=this.listeners.reduce((e,s)=>([...s.splitEventName].sort().toString()===t.sort().toString()?this.el.removeEventListener(s.splitEventName[0],s.cb):e.push(s),e),[]),!0}reset(){return this.listeners.forEach(e=>{this.el.removeEventListener(e.splitEventName[0],e.cb)}),this.listeners=[],!0}get el(){return this._el}set el(e){this._el=e}get listeners(){return this._listeners}set listeners(e){this._listeners=e}constructor(e=document){this._el=e,e.$emitter=this,this._listeners=[]}}class a{init(){throw Error('The "init" method for the plugin "'.concat(this._pluginName,'" is not defined.'))}update(){}_init(){this._initialized||(this.init(),this._initialized=!0)}_update(){this._initialized&&this.update()}_mergeOptions(e){let s=r.toDashCase(this._pluginName),n=i.getDataAttribute(this.el,"data-".concat(s,"-config"),!1),a=i.getAttribute(this.el,"data-".concat(s,"-options"),!1),o=[this.constructor.options,this.options,e];n&&o.push(window.PluginConfigManager.get(this._pluginName,n));try{a&&o.push(JSON.parse(a))}catch(e){throw console.error(this.el),Error('The data attribute "data-'.concat(s,'-options" could not be parsed to json: ').concat(e.message))}return t().all(o.filter(e=>e instanceof Object&&!(e instanceof Array)).map(e=>e||{}))}_registerInstance(){window.PluginManager.getPluginInstancesFromElement(this.el).set(this._pluginName,this),window.PluginManager.getPlugin(this._pluginName,!1).get("instances").push(this)}_getPluginName(e){return e||(e=this.constructor.name),e}constructor(e,t={},s=!1){if(!i.isNode(e))throw Error("There is no valid element given.");this.el=e,this.$emitter=new n(this.el),this._pluginName=this._getPluginName(s),this.options=this._mergeOptions(t),this._initialized=!1,this._registerInstance(),this._init()}}let o=class{get(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{Accept:"application/json"},s=this._createPreparedRequest("GET",e,t);return this._sendRequest(s,null,t)}post(e,t){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{"Content-Type":"application/json",Accept:"application/json"},r=this._createPreparedRequest("POST",e,s);return this._sendRequest(r,JSON.stringify(t),s)}patch(e,t){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{"Content-Type":"application/json",Accept:"application/json"},r=this._createPreparedRequest("PATCH",e,s);return this._sendRequest(r,JSON.stringify(t),s)}delete(e,t){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{"Content-Type":"application/json",Accept:"application/json"},r=this._createPreparedRequest("DELETE",e,s);return this._sendRequest(r,JSON.stringify(t),s)}abort(){this._request&&this._request.abort()}_sendRequest(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,s=arguments.length>2?arguments[2]:void 0;return new Promise((r,i)=>{e.onload=()=>{this._request=null,e.status>=200&&e.status<300?204!==e.status&&"application/json"===s.Accept?r(JSON.parse(e.response)):r(e.response):i({status:e.status,statusText:e.statusText})},e.onerror=()=>{this._request=null,i({status:e.status,statusText:e.statusText})},e.send(t)})}_createPreparedRequest(e,t,s){for(let r in this._request&&this._request.abort(),this._request=new XMLHttpRequest,this._request.open(e,t),s)this._request.setRequestHeader(r,s[r]);return this._request}constructor(){this._request=null}};class c extends a{init(){this.client=new o,this._initGoogleRecaptcha(),this._registerEvents()}_initGoogleRecaptcha(){let e=this.el.querySelector('[data-google-re-captcha-v3="true"]');e&&(this.recaptchaV3PluginInstances=window.PluginManager.getPluginInstancesFromElement(e)),this.recaptchaV3PluginInstances&&this.recaptchaV3PluginInstances.forEac
1h(e=>{"object"==typeof e.grecaptcha&&(this.grecaptcha=e.grecaptcha,this.grecaptchaSiteKey=e.options.siteKey,this.grecaptchaInputSelector=e.options.grecaptchaInputSelector)});let t=this.el.querySelector('[data-google-re-captcha-v2="true"]');t&&JSON.parse(t.dataset.googleReCaptchaV2Options).invisible&&this._showFeedback(!1,"Invisible Recaptcha V2 is not supported, please use Recaptcha V2 or update to Recaptcha V3",1e4)}_registerEvents(){let e=this;this._checkProductSubscribed(),this.el.addEventListener("submit",t=>{e._onsubmit(t)})}_onsubmit(e){e.preventDefault();let t=new FormData(e.target);if(this.formData=this._parseFormData(t),this.url=e.target.dataset.action,this.grecaptcha){this.grecaptcha.ready(this._onGoogleRecaptchaReady.bind(this));return}this._subscribe()}_onGoogleRecaptchaReady(){this.grecaptcha.execute(this.grecaptchaSiteKey,{action:"submit"}).then(e=>{this._subscribe({[this.el.querySelector(this.grecaptchaInputSelector).getAttribute("name")]:e})})}_subscribe(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=this.options.snippets,s=this.formData;this.client.post(this.url,{...s,...e}).then(e=>{let s;if(e.success)s="subscription_updated"===e.action?t.updateSuccessMessage:t.successMessage;else if(e.error)s="invalidEmailMessage"===e.error?this.options.snippets.invalidEmailMessage:"salesChannelDomainsExceptionMessage"===e.error?this.options.snippets.salesChannelDomainsExceptionMessage:e.error;else if(e[0].alert){let t=document.createElement("div");t.innerHTML=e[0].alert,s=t.querySelector(".alert-content").innerHTML}var r=document.getElementById("backInStockEmail"+this.options.subscribeData.productId);r&&(r.value=""),this._showFeedback(e.success,s)}).catch(e=>{if(e.status>=500){this._showFeedback(!1,t.exceptionMessage);return}if(e.status>=400){this._showFeedback(!1,t.failedMessage);return}})}_showFeedback(e,t){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.options.snippets.notificationConfirmationMessageTime,r=this.el.querySelector("#message-container");r.querySelector("#message-label").innerHTML=t,e?(r.classList.remove("alert-danger"),r.classList.add("alert-success")):(r.classList.remove("alert-success"),r.classList.add("alert-danger")),r.classList.replace("d-none","d-flex"),r.classList.add("alert-has-icon"),setTimeout(()=>{r.classList.replace("d-flex","d-none"),r.classList.remove("alert-has-icon")},s)}_parseFormData(e){let t={};
1for(let s of e.entries()){let e=s[0].split(/(?:\[|\])/).filter(Boolean);e.length>2?(t[e[0]]||(t[e[0]]={[e[1]]:{}}),t[e[0]][e[1]][e[2]]=s[1]):t[e[0]]=s[1]}return t}_checkProductSubscribed(){this.subscribedProduct()}subscribedProduct(){arguments.length>0&&void 0!==arguments[0]&&arguments[0];let e=JSON.parse(JSON.stringify({productId:this.options.subscribeData.productId})).productId;this.client.post(this.options.subscribeData.checkProductSubscribedUrl,[{productId:e}]).then(e=>{e.success&&this._showSubscribedProductMessage()}).catch(e=>{})}_showSubscribedProductMessage(){let e=this.el.querySelector("#message-container-"+this.options.subscribeData.productId);e.classList.remove("alert-danger"),e.classList.add("alert-success"),e.classList.replace("d-none","d-flex"),setTimeout(()=>{e.classList.replace("d-flex","d-none")},4e3)}}c.options={snippets:{successMessage:"",updateSuccessMessage:"",failedMessage:"",exceptionMessage:"",salesChannelDomainsExceptionMessage:"",invalidEmailMessage:"",notificationConfirmationMessageTime:""},subscribeData:{productId:"",checkProductSubscribedUrl:""}},window.PluginManager.register("ZeobvStockNotificationForm",c,"[data-zeobv-stock-notification-form]")})()})();
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.