| @@ -1 +1 @@ | ||
| 1 | -var D=Object.defineProperty;var S=e=>{throw TypeError(e)};var J=(e,t,n)=>t in e?D(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var w=(e,t,n)=>J(e,typeof t!="symbol"?t+"":t,n),O=(e,t,n)=>t.has(e)||S("Cannot "+n);var l=(e,t,n)=>(O(e,t,"read from private field"),n?n.call(e):t.get(e)),h=(e,t,n)=>t.has(e)?S("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),j=(e,t,n,s)=>(O(e,t,"write to private field"),s?s.call(e,n):t.set(e,n),n),u=(e,t,n)=>(O(e,t,"access private method"),n);import{J as U}from"./vue.esm-bundler.js?ver=1.6.2";import{A as B}from"./Arr.js?ver=1.6.2";class _{constructor(){w(this,"_data",{})}static form(t){const n=new this;return n._data=t,n}get(t=null,n=""){return t===null?this._data:B.get(this._data,t,n)}}var t,o,d,i,E,p;const r=class r{static onShopUpdate(t){l(r,d).push(t)}static setConfig(t){var n;if(u(n=r,i,p).call(n,t),Object.keys(r._data).forEach(s=>delete r._data[s]),Object.assign(r._data,t),l(r,o))try{l(r,o).postMessage({type:"set",config:JSON.parse(JSON.stringify(t))})}catch{}}static mergeConfig(t){var n;if(u(n=r,i,p).call(n,t),Object.assign(r._data,t),l(r,o))try{l(r,o).postMessage({type:"merge",config:JSON.parse(JSON.stringify(t))})}catch{}}static get(t=null,n=null){return t===null?r._data:_.form(r._data).get(t,n)}static assetUrl(t=""){return r.get("asset_url")+t}static get shop(){return _.form(r.get("shop"))}static get config(){return _.form(r.get("app_config"))}};o=new WeakMap,d=new WeakMap,i=new WeakSet,E=function(){l(r,d).forEach(t=>t())},p=function(t){if(!t||typeof t!="object")return;const n=document.createElement("textarea");t.shop&&t.shop.currency_sign&&(n.innerHTML=t.shop.currency_sign,t.shop.currency_sign=n.value),t.currency_signs&&typeof t.currency_signs=="object"&&Object.keys(t.currency_signs).forEach(function(s){n.innerHTML=t.currency_signs[s],t.currency_signs[s]=n.value})},h(r,i),w(r,"_data",U(window.fluentCartAdminApp||{})),h(r,o,null),h(r,d,[]),u(t=r,i,p).call(t,r._data),typeof BroadcastChannel<"u"&&(j(r,o,new BroadcastChannel("fluent-cart-config:"+window.location.origin)),l(r,o).onmessage=function(n){var a,c,g,C;const s=n.data;if(s){if(s.type==="merge"&&s.config)u(a=r,i,p).call(a,s.config),Object.assign(r._data,s.config),s.config.shop&&(u(c=r,i,E).call(c),window.dispatchEvent(new CustomEvent("fluentCartCurrencyChange")));else if(s.type==="set"&&s.config){u(g=r,i,p).call(g,s.config);const A=r._data.shop&&r._data.shop.currency_sign;Object.keys(r._data).forEach(L=>delete r._data[L]),Object.assign(r._data,s.config);const N=r._data.shop&&r._data.shop.currency_sign;A!==N&&(u(C=r,i,E).call(C),window.dispatchEvent(new CustomEvent("fluentCartCurrencyChange")))}}});let f=r;window.fluentCartAdminApp=f._data;const y="fluent-cart",v="";let I=null;function H(){return window.wp&&window.wp.i18n||null}function m(){return f.get("trans")||{}}function T(){const e=H();if(!e)return null;const t=m();if(t===I)return e;I=t;const n={"":{domain:y,lang:f.get("wp_locale")||""}};return Object.keys(t).forEach(s=>{const a=t[s];if(typeof a!="string")return;const c=s.indexOf(v);(c===-1?s:s.slice(c+1))!==a&&(n[s]=[a])}),e.setLocaleData(n,y),e}function x(e,t){if(t.length===0)return e;const n=/%(\d*\$?)s|%d/g;let s=0;return e.replace(n,(a,c)=>{if(c){const g=parseInt(c,10)-1;return g<t.length?t[g]:a}else return s<t.length?t[s++]:a})}function M(e){f.get("app_config.env")==="dev"&&(m()[e]||window.console.warn("Missing translation:",e))}function b(e){M(e);const t=T(),n=t?t.__(e,y):m()[e]||e;return x(n,Array.prototype.slice.call(arguments,1))}function P(e,t){const n=t+v+e;M(n);const s=T(),a=m();let c=s?s._x(e,t,y):a[n]||e;return c===e&&(c=a[e]||e),x(c,Array.prototype.slice.call(arguments,2))}function R(e,t,n,s=null){let a=parseInt(n.toString().replace(/,/g,""),10);return a>1?b(t,n):b(a===0?s??e:e,n)}function W(e){const t=f.get("datei18");e=e.toString();const s=(t.numericSystem||"0_1_2_3_4_5_6_7_8_9").split("_");return e.split("").map(c=>s[c]||c).join("")}export{f as A,P as _,W as a,R as p,b as t}; | |
| 1 | +var D=Object.defineProperty;var S=e=>{throw TypeError(e)};var J=(e,t,n)=>t in e?D(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var w=(e,t,n)=>J(e,typeof t!="symbol"?t+"":t,n),O=(e,t,n)=>t.has(e)||S("Cannot "+n);var l=(e,t,n)=>(O(e,t,"read from private field"),n?n.call(e):t.get(e)),h=(e,t,n)=>t.has(e)?S("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),j=(e,t,n,s)=>(O(e,t,"write to private field"),s?s.call(e,n):t.set(e,n),n),u=(e,t,n)=>(O(e,t,"access private method"),n);import{L as U}from"./vue.esm-bundler.js?ver=1.6.6";import{A as B}from"./Arr.js?ver=1.6.6";class _{constructor(){w(this,"_data",{})}static form(t){const n=new this;return n._data=t,n}get(t=null,n=""){return t===null?this._data:B.get(this._data,t,n)}}var t,o,d,i,E,p;const r=class r{static onShopUpdate(t){l(r,d).push(t)}static setConfig(t){var n;if(u(n=r,i,p).call(n,t),Object.keys(r._data).forEach(s=>delete r._data[s]),Object.assign(r._data,t),l(r,o))try{l(r,o).postMessage({type:"set",config:JSON.parse(JSON.stringify(t))})}catch{}}static mergeConfig(t){var n;if(u(n=r,i,p).call(n,t),Object.assign(r._data,t),l(r,o))try{l(r,o).postMessage({type:"merge",config:JSON.parse(JSON.stringify(t))})}catch{}}static get(t=null,n=null){return t===null?r._data:_.form(r._data).get(t,n)}static assetUrl(t=""){return r.get("asset_url")+t}static get shop(){return _.form(r.get("shop"))}static get config(){return _.form(r.get("app_config"))}};o=new WeakMap,d=new WeakMap,i=new WeakSet,E=function(){l(r,d).forEach(t=>t())},p=function(t){if(!t||typeof t!="object")return;const n=document.createElement("textarea");t.shop&&t.shop.currency_sign&&(n.innerHTML=t.shop.currency_sign,t.shop.currency_sign=n.value),t.currency_signs&&typeof t.currency_signs=="object"&&Object.keys(t.currency_signs).forEach(function(s){n.innerHTML=t.currency_signs[s],t.currency_signs[s]=n.value})},h(r,i),w(r,"_data",U(window.fluentCartAdminApp||{})),h(r,o,null),h(r,d,[]),u(t=r,i,p).call(t,r._data),typeof BroadcastChannel<"u"&&(j(r,o,new BroadcastChannel("fluent-cart-config:"+window.location.origin)),l(r,o).onmessage=function(n){var a,c,g,C;const s=n.data;if(s){if(s.type==="merge"&&s.config)u(a=r,i,p).call(a,s.config),Object.assign(r._data,s.config),s.config.shop&&(u(c=r,i,E).call(c),window.dispatchEvent(new CustomEvent("fluentCartCurrencyChange")));else if(s.type==="set"&&s.config){u(g=r,i,p).call(g,s.config);const A=r._data.shop&&r._data.shop.currency_sign;Object.keys(r._data).forEach(N=>delete r._data[N]),Object.assign(r._data,s.config);const L=r._data.shop&&r._data.shop.currency_sign;A!==L&&(u(C=r,i,E).call(C),window.dispatchEvent(new CustomEvent("fluentCartCurrencyChange")))}}});let f=r;window.fluentCartAdminApp=f._data;const y="fluent-cart",v="";let I=null;function H(){return window.wp&&window.wp.i18n||null}function m(){return f.get("trans")||{}}function T(){const e=H();if(!e)return null;const t=m();if(t===I)return e;I=t;const n={"":{domain:y,lang:f.get("wp_locale")||""}};return Object.keys(t).forEach(s=>{const a=t[s];if(typeof a!="string")return;const c=s.indexOf(v);(c===-1?s:s.slice(c+1))!==a&&(n[s]=[a])}),e.setLocaleData(n,y),e}function x(e,t){if(t.length===0)return e;const n=/%(\d*\$?)s|%d/g;let s=0;return e.replace(n,(a,c)=>{if(c){const g=parseInt(c,10)-1;return g<t.length?t[g]:a}else return s<t.length?t[s++]:a})}function M(e){f.get("app_config.env")==="dev"&&(m()[e]||window.console.warn("Missing translation:",e))}function b(e){M(e);const t=T(),n=t?t.__(e,y):m()[e]||e;return x(n,Array.prototype.slice.call(arguments,1))}function P(e,t){const n=t+v+e;M(n);const s=T(),a=m();let c=s?s._x(e,t,y):a[n]||e;return c===e&&(c=a[e]||e),x(c,Array.prototype.slice.call(arguments,2))}function R(e,t,n,s=null){let a=parseInt(n.toString().replace(/,/g,""),10);return a>1?b(t,n):b(a===0?s??e:e,n)}function W(e){const t=f.get("datei18");e=e.toString();const s=(t.numericSystem||"0_1_2_3_4_5_6_7_8_9").split("_");return e.split("").map(c=>s[c]||c).join("")}export{f as A,P as _,W as a,R as p,b as t}; | |