@pisapp/core 7.0.0-dev.20260916-153034

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/LICENSE +28 -0
  2. package/THIRD-PARTY-NOTICES.txt +43 -0
  3. package/catalogs.d.ts +7725 -0
  4. package/catalogs.js +3 -0
  5. package/chunks/catalogs-domain-DJxK_B5E.js +9060 -0
  6. package/chunks/catalogs-domain-DJxK_B5E.js.map +1 -0
  7. package/chunks/classifications-domain-DdIJaF1D.js +1980 -0
  8. package/chunks/classifications-domain-DdIJaF1D.js.map +1 -0
  9. package/chunks/icons-shared-B8v5z3BE.js +1387 -0
  10. package/chunks/icons-shared-B8v5z3BE.js.map +1 -0
  11. package/chunks/products-domain-99vJaUyI.js +22587 -0
  12. package/chunks/products-domain-99vJaUyI.js.map +1 -0
  13. package/classifications.d.ts +7725 -0
  14. package/classifications.js +3 -0
  15. package/core.d.ts +7711 -0
  16. package/core.js +7 -0
  17. package/index.d.ts +7992 -0
  18. package/index.js +12 -0
  19. package/migration/API_V1_TO_V2_MIGRATION.md +1424 -0
  20. package/migration/legacy-option-rules.json +93 -0
  21. package/migration/v7.json +4101 -0
  22. package/migration/v7.schema.json +595 -0
  23. package/package.json +68 -0
  24. package/pis-csp.js +97 -0
  25. package/pis-csp.js.map +1 -0
  26. package/pis.js +105 -0
  27. package/pis.js.map +1 -0
  28. package/products.d.ts +7746 -0
  29. package/products.js +2 -0
  30. package/styles/fonts.css +1 -0
  31. package/styles/pis.css +1 -0
  32. package/styles/theme-abb.css +1 -0
  33. package/styles/theme-abb.optimized.css +1 -0
  34. package/styles/theme-cux2-blue-dark.css +1 -0
  35. package/styles/theme-cux2-blue-dark.optimized.css +1 -0
  36. package/styles/theme-cux2-blue-light.css +1 -0
  37. package/styles/theme-cux2-blue-light.optimized.css +1 -0
  38. package/styles/theme-cux2-lilac-dark.css +1 -0
  39. package/styles/theme-cux2-lilac-dark.optimized.css +1 -0
  40. package/styles/theme-cux2-lilac-light.css +1 -0
  41. package/styles/theme-cux2-lilac-light.optimized.css +1 -0
  42. package/styles/theme-cux2-mono-dark.css +1 -0
  43. package/styles/theme-cux2-mono-dark.optimized.css +1 -0
  44. package/styles/theme-cux2-mono-light.css +1 -0
  45. package/styles/theme-cux2-mono-light.optimized.css +1 -0
  46. package/styles/theme-cux2-red-dark.css +1 -0
  47. package/styles/theme-cux2-red-dark.optimized.css +1 -0
  48. package/styles/theme-cux2-red-light.css +1 -0
  49. package/styles/theme-cux2-red-light.optimized.css +1 -0
  50. package/types.d.ts +8893 -0
  51. package/types.js +0 -0
package/pis-csp.js ADDED
@@ -0,0 +1,97 @@
1
+ (function(){var e=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports);function t(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var n={},r=[],i=()=>{},a=()=>!1,o=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),s=e=>e.startsWith(`onUpdate:`),c=Object.assign,l=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},u=Object.prototype.hasOwnProperty,d=(e,t)=>u.call(e,t),f=Array.isArray,p=e=>S(e)===`[object Map]`,m=e=>S(e)===`[object Set]`,h=e=>S(e)===`[object Date]`,g=e=>typeof e==`function`,_=e=>typeof e==`string`,v=e=>typeof e==`symbol`,y=e=>typeof e==`object`&&!!e,b=e=>(y(e)||g(e))&&g(e.then)&&g(e.catch),x=Object.prototype.toString,S=e=>x.call(e),C=e=>S(e).slice(8,-1),w=e=>S(e)===`[object Object]`,T=e=>_(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,E=t(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),D=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},ee=/-\w/g,O=D(e=>e.replace(ee,e=>e.slice(1).toUpperCase())),te=/\B([A-Z])/g,ne=D(e=>e.replace(te,`-$1`).toLowerCase()),re=D(e=>e.charAt(0).toUpperCase()+e.slice(1)),ie=D(e=>e?`on${re(e)}`:``),ae=(e,t)=>!Object.is(e,t),oe=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},se=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},ce=e=>{let t=parseFloat(e);return isNaN(t)?e:t},le=e=>{let t=_(e)?Number(e):NaN;return isNaN(t)?e:t},ue,de=()=>ue||(ue=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{});function k(e){if(f(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=_(r)?he(r):k(r);if(i)for(let e in i)t[e]=i[e]}return t}if(_(e)||y(e))return e}var fe=/;(?![^(]*\))/g,pe=/:([^]+)/,me=/\/\*[^]*?\*\//g;function he(e){let t={};return e.replace(me,``).split(fe).forEach(e=>{if(e){let n=e.split(pe);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function A(e){let t=``;if(_(e))t=e;else if(f(e))for(let n=0;n<e.length;n++){let r=A(e[n]);r&&(t+=r+` `)}else if(y(e))for(let n in e)e[n]&&(t+=n+` `);return t.trim()}function ge(e){if(!e)return null;let{class:t,style:n}=e;return t&&!_(t)&&(e.class=A(t)),n&&(e.style=k(n)),e}var _e=`itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`,ve=t(_e);_e+``;function ye(e){return!!e||e===``}function be(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=xe(e[r],t[r]);return n}function xe(e,t){if(e===t)return!0;let n=h(e),r=h(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=v(e),r=v(t),n||r)return e===t;if(n=f(e),r=f(t),n||r)return n&&r?be(e,t):!1;if(n=y(e),r=y(t),n||r){if(!n||!r||Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e){let r=e.hasOwnProperty(n),i=t.hasOwnProperty(n);if(r&&!i||!r&&i||!xe(e[n],t[n]))return!1}}return String(e)===String(t)}function Se(e,t){return e.findIndex(e=>xe(e,t))}var Ce=e=>!!(e&&e.__v_isRef===!0),j=e=>_(e)?e:e==null?``:f(e)||y(e)&&(e.toString===x||!g(e.toString))?Ce(e)?j(e.value):JSON.stringify(e,we,2):String(e),we=(e,t)=>Ce(t)?we(e,t.value):p(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Te(t,r)+` =>`]=n,e),{})}:m(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Te(e))}:v(t)?Te(t):y(t)&&!f(t)&&!w(t)?String(t):t,Te=(e,t=``)=>v(e)?`Symbol(${e.description??t})`:e;function Ee(e){return e==null?`initial`:typeof e==`string`?e===``?` `:e:String(e)}var De,Oe=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&De&&(De.active?(this.parent=De,this.index=(De.scopes||(De.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}let n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){let t=De;try{return De=this,e()}finally{De=t}}}on(){++this._on===1&&(this.prevScope=De,De=this)}off(){if(this._on>0&&--this._on===0){if(De===this)De=this.prevScope;else{let e=De;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){let e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}};function ke(e){return new Oe(e)}function Ae(){return De}function je(e,t=!1){De&&De.cleanups.push(e)}var Me,Ne=new WeakSet,Pe=class{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,De&&(De.active?De.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Ne.has(this)&&(Ne.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Re(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Qe(this),Ve(this);let e=Me,t=Je;Me=this,Je=!0;try{return this.fn()}finally{He(this),Me=e,Je=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Ge(e);this.deps=this.depsTail=void 0,Qe(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Ne.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Ue(this)&&this.run()}get dirty(){return Ue(this)}},Fe=0,Ie,Le;function Re(e,t=!1){if(e.flags|=8,t){e.next=Le,Le=e;return}e.next=Ie,Ie=e}function ze(){Fe++}function Be(){if(--Fe>0)return;if(Le){let e=Le;for(Le=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;Ie;){let t=Ie;for(Ie=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||(e=t)}t=n}}if(e)throw e}function Ve(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function He(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),Ge(r),Ke(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function Ue(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(We(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function We(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===$e)||(e.globalVersion=$e,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Ue(e))))return;e.flags|=2;let t=e.dep,n=Me,r=Je;Me=e,Je=!0;try{Ve(e);let n=e.fn(e._value);(t.version===0||ae(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{Me=n,Je=r,He(e),e.flags&=-3}}function Ge(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)Ge(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Ke(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}function qe(e,t){e.effect instanceof Pe&&(e=e.effect.fn);let n=new Pe(e);t&&c(n,t);try{n.run()}catch(e){throw n.stop(),e}let r=n.run.bind(n);return r.effect=n,r}var Je=!0,Ye=[];function Xe(){Ye.push(Je),Je=!1}function Ze(){let e=Ye.pop();Je=e===void 0||e}function Qe(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=Me;Me=void 0;try{t()}finally{Me=e}}}var $e=0,et=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},tt=class{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!Me||!Je||Me===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==Me)t=this.activeLink=new et(Me,this),Me.deps?(t.prevDep=Me.depsTail,Me.depsTail.nextDep=t,Me.depsTail=t):Me.deps=Me.depsTail=t,nt(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=Me.depsTail,t.nextDep=void 0,Me.depsTail.nextDep=t,Me.depsTail=t,Me.deps===t&&(Me.deps=e)}return t}trigger(e){this.version++,$e++,this.notify(e)}notify(e){ze();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Be()}}};function nt(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)nt(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var rt=new WeakMap,it=Symbol(``),at=Symbol(``),ot=Symbol(``);function st(e,t,n){if(Je&&Me){let t=rt.get(e);t||rt.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new tt),r.map=t,r.key=n),r.track()}}function ct(e,t,n,r,i,a){let o=rt.get(e);if(!o){$e++;return}let s=e=>{e&&e.trigger()};if(ze(),t===`clear`)o.forEach(s);else{let i=f(e),a=i&&T(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===ot||!v(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get(ot)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(it)),p(e)&&s(o.get(at)));break;case`delete`:i||(s(o.get(it)),p(e)&&s(o.get(at)));break;case`set`:p(e)&&s(o.get(it))}}Be()}function lt(e,t){let n=rt.get(e);return n&&n.get(t)}function ut(e){let t=Zt(e);return t===e?t:(st(t,`iterate`,ot),Yt(e)?t:t.map($t))}function dt(e){return st(e=Zt(e),`iterate`,ot),e}function ft(e,t){return Jt(e)?en(qt(e)?$t(t):t):$t(t)}var pt={__proto__:null,[Symbol.iterator](){return mt(this,Symbol.iterator,e=>ft(this,e))},concat(...e){return ut(this).concat(...e.map(e=>f(e)?ut(e):e))},entries(){return mt(this,`entries`,e=>(e[1]=ft(this,e[1]),e))},every(e,t){return gt(this,`every`,e,t,void 0,arguments)},filter(e,t){return gt(this,`filter`,e,t,e=>e.map(e=>ft(this,e)),arguments)},find(e,t){return gt(this,`find`,e,t,e=>ft(this,e),arguments)},findIndex(e,t){return gt(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return gt(this,`findLast`,e,t,e=>ft(this,e),arguments)},findLastIndex(e,t){return gt(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return gt(this,`forEach`,e,t,void 0,arguments)},includes(...e){return vt(this,`includes`,e)},indexOf(...e){return vt(this,`indexOf`,e)},join(e){return ut(this).join(e)},lastIndexOf(...e){return vt(this,`lastIndexOf`,e)},map(e,t){return gt(this,`map`,e,t,void 0,arguments)},pop(){return yt(this,`pop`)},push(...e){return yt(this,`push`,e)},reduce(e,...t){return _t(this,`reduce`,e,t)},reduceRight(e,...t){return _t(this,`reduceRight`,e,t)},shift(){return yt(this,`shift`)},some(e,t){return gt(this,`some`,e,t,void 0,arguments)},splice(...e){return yt(this,`splice`,e)},toReversed(){return ut(this).toReversed()},toSorted(e){return ut(this).toSorted(e)},toSpliced(...e){return ut(this).toSpliced(...e)},unshift(...e){return yt(this,`unshift`,e)},values(){return mt(this,`values`,e=>ft(this,e))}};function mt(e,t,n){let r=dt(e),i=r[t]();return r!==e&&!Yt(e)&&(i._next=i.next,i.next=()=>{let e=i._next();return e.done||(e.value=n(e.value)),e}),i}var ht=Array.prototype;function gt(e,t,n,r,i,a){let o=dt(e),s=o!==e&&!Yt(e),c=o[t];if(c!==ht[t]){let t=c.apply(e,a);return s?$t(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,ft(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function _t(e,t,n,r){let i=dt(e),a=i!==e&&!Yt(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=ft(e,t)),n.call(this,t,ft(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?ft(e,c):c}function vt(e,t,n){let r=Zt(e);st(r,`iterate`,ot);let i=r[t](...n);return(i===-1||i===!1)&&Xt(n[0])?(n[0]=Zt(n[0]),r[t](...n)):i}function yt(e,t,n=[]){Xe(),ze();let r=Zt(e)[t].apply(e,n);return Be(),Ze(),r}var bt=t(`__proto__,__v_isRef,__isVue`),xt=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(v));function St(e){v(e)||(e=String(e));let t=Zt(this);return st(t,`has`,e),t.hasOwnProperty(e)}var Ct=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Vt:Bt:i?zt:Rt).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=f(e);if(!r){let e;if(a&&(e=pt[t]))return e;if(t===`hasOwnProperty`)return St}let o=Reflect.get(e,t,tn(e)?e:n);if((v(t)?xt.has(t):bt(t))||(r||st(e,`get`,t),i))return o;if(tn(o)){let e=a&&T(t)?o:o.value;return r&&y(e)?Gt(e):e}return y(o)?r?Gt(o):Ut(o):o}},wt=class extends Ct{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=f(e)&&T(t);if(!this._isShallow){let e=Jt(i);if(!Yt(n)&&!Jt(n)&&(i=Zt(i),n=Zt(n)),!a&&tn(i)&&!tn(n))return e||(i.value=n),!0}let o=a?Number(t)<e.length:d(e,t),s=Reflect.set(e,t,n,tn(e)?e:r);return e===Zt(r)&&s&&(o?ae(n,i)&&ct(e,`set`,t,n,i):ct(e,`add`,t,n)),s}deleteProperty(e,t){let n=d(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&ct(e,`delete`,t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return(!v(t)||!xt.has(t))&&st(e,`has`,t),n}ownKeys(e){return st(e,`iterate`,f(e)?`length`:it),Reflect.ownKeys(e)}},Tt=class extends Ct{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}},Et=new wt,Dt=new Tt,Ot=new wt(!0),kt=e=>e,At=e=>Reflect.getPrototypeOf(e);function jt(e,t,n){return function(...r){let i=this.__v_raw,a=Zt(i),o=p(a),s=e===`entries`||e===Symbol.iterator&&o,l=e===`keys`&&o,u=i[e](...r),d=n?kt:t?en:$t;return!t&&st(a,`iterate`,l?at:it),c(Object.create(u),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:s?[d(e[0]),d(e[1])]:d(e),done:t}}})}}function Mt(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function Nt(e,t){let n={get(n){let r=this.__v_raw,i=Zt(r),a=Zt(n);e||(ae(n,a)&&st(i,`get`,n),st(i,`get`,a));let{has:o}=At(i),s=t?kt:e?en:$t;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&st(Zt(t),`iterate`,it),t.size},has(t){let n=this.__v_raw,r=Zt(n),i=Zt(t);return e||(ae(t,i)&&st(r,`has`,t),st(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=Zt(a),s=t?kt:e?en:$t;return!e&&st(o,`iterate`,it),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return c(n,e?{add:Mt(`add`),set:Mt(`set`),delete:Mt(`delete`),clear:Mt(`clear`)}:{add(e){let n=Zt(this),r=At(n),i=Zt(e),a=!t&&!Yt(e)&&!Jt(e)?i:e;return r.has.call(n,a)||ae(e,a)&&r.has.call(n,e)||ae(i,a)&&r.has.call(n,i)||(n.add(a),ct(n,`add`,a,a)),this},set(e,n){!t&&!Yt(n)&&!Jt(n)&&(n=Zt(n));let r=Zt(this),{has:i,get:a}=At(r),o=i.call(r,e);o||(e=Zt(e),o=i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?ae(n,s)&&ct(r,`set`,e,n,s):ct(r,`add`,e,n),this},delete(e){let t=Zt(this),{has:n,get:r}=At(t),i=n.call(t,e);i||(e=Zt(e),i=n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&ct(t,`delete`,e,void 0,a),o},clear(){let e=Zt(this),t=e.size!==0,n=e.clear();return t&&ct(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=jt(r,e,t)}),n}function Pt(e,t){let n=Nt(e,t);return(t,r,i)=>r===`__v_isReactive`?!e:r===`__v_isReadonly`?e:r===`__v_raw`?t:Reflect.get(d(n,r)&&r in t?n:t,r,i)}var Ft={get:Pt(!1,!1)},It={get:Pt(!1,!0)},Lt={get:Pt(!0,!1)},Rt=new WeakMap,zt=new WeakMap,Bt=new WeakMap,Vt=new WeakMap;function Ht(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Ut(e){return Jt(e)?e:Kt(e,!1,Et,Ft,Rt)}function Wt(e){return Kt(e,!1,Ot,It,zt)}function Gt(e){return Kt(e,!0,Dt,Lt,Bt)}function Kt(e,t,n,r,i){if(!y(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let a=i.get(e);if(a)return a;let o=Ht(C(e));if(o===0)return e;let s=new Proxy(e,o===2?r:n);return i.set(e,s),s}function qt(e){return Jt(e)?qt(e.__v_raw):!!(e&&e.__v_isReactive)}function Jt(e){return!!(e&&e.__v_isReadonly)}function Yt(e){return!!(e&&e.__v_isShallow)}function Xt(e){return e?!!e.__v_raw:!1}function Zt(e){let t=e&&e.__v_raw;return t?Zt(t):e}function Qt(e){return!d(e,`__v_skip`)&&Object.isExtensible(e)&&se(e,`__v_skip`,!0),e}var $t=e=>y(e)?Ut(e):e,en=e=>y(e)?Gt(e):e;function tn(e){return e?e.__v_isRef===!0:!1}function M(e){return rn(e,!1)}function nn(e){return rn(e,!0)}function rn(e,t){return tn(e)?e:new an(e,t)}var an=class{constructor(e,t){this.dep=new tt,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:Zt(e),this._value=t?e:$t(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||Yt(e)||Jt(e);e=n?e:Zt(e),ae(e,t)&&(this._rawValue=e,this._value=n?e:$t(e),this.dep.trigger())}};function on(e){return tn(e)?e.value:e}function N(e){return g(e)?e():on(e)}var sn={get:(e,t,n)=>t===`__v_raw`?e:on(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return tn(i)&&!tn(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function cn(e){return qt(e)?e:new Proxy(e,sn)}function ln(e){let t=f(e)?Array(e.length):{};for(let n in e)t[n]=dn(e,n);return t}var un=class{constructor(e,t,n){this._object=e,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0,this._key=v(t)?t:String(t),this._raw=Zt(e);let r=!0,i=e;if(!f(e)||v(this._key)||!T(this._key))do r=!Xt(i)||Yt(i);while(r&&(i=i.__v_raw));this._shallow=r}get value(){let e=this._object[this._key];return this._shallow&&(e=on(e)),this._value=e===void 0?this._defaultValue:e}set value(e){if(this._shallow&&tn(this._raw[this._key])){let t=this._object[this._key];if(tn(t)){t.value=e;return}}this._object[this._key]=e}get dep(){return lt(this._raw,this._key)}};function dn(e,t,n){return new un(e,t,n)}var fn=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new tt(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=$e-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&Me!==this)return Re(this,!0),!0}get value(){let e=this.dep.track();return We(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function pn(e,t,n=!1){let r,i;return g(e)?r=e:(r=e.get,i=e.set),new fn(r,i,n)}var mn={},hn=new WeakMap,gn=void 0;function _n(e,t=!1,n=gn){if(n){let t=hn.get(n);t||hn.set(n,t=[]),t.push(e)}}function vn(e,t,r=n){let{immediate:a,deep:o,once:s,scheduler:c,augmentJob:u,call:d}=r,p=e=>o?e:Yt(e)||o===!1||o===0?yn(e,1):yn(e),m,h,_,v,y=!1,b=!1;if(tn(e)?(h=()=>e.value,y=Yt(e)):qt(e)?(h=()=>p(e),y=!0):f(e)?(b=!0,y=e.some(e=>qt(e)||Yt(e)),h=()=>e.map(e=>{if(tn(e))return e.value;if(qt(e))return p(e);if(g(e))return d?d(e,2):e()})):h=g(e)?t?d?()=>d(e,2):e:()=>{if(_){Xe();try{_()}finally{Ze()}}let t=gn;gn=m;try{return d?d(e,3,[v]):e(v)}finally{gn=t}}:i,t&&o){let e=h,t=o===!0?1/0:o;h=()=>yn(e(),t)}let x=Ae(),S=()=>{m.stop(),x&&x.active&&l(x.effects,m)};if(s&&t){let e=t;t=(...t)=>{let n=e(...t);return S(),n}}let C=b?Array(e.length).fill(mn):mn,w=e=>{if(!(!(m.flags&1)||!m.dirty&&!e))if(t){let n=m.run();if(e||o||y||(b?n.some((e,t)=>ae(e,C[t])):ae(n,C))){_&&_();let e=gn;gn=m;try{let e=[n,C===mn?void 0:b&&C[0]===mn?[]:C,v];C=n,d?d(t,3,e):t(...e)}finally{gn=e}}}else m.run()};return u&&u(w),m=new Pe(h),m.scheduler=c?()=>c(w,!1):w,v=e=>_n(e,!1,m),_=m.onStop=()=>{let e=hn.get(m);if(e){if(d)d(e,4);else for(let t of e)t();hn.delete(m)}},t?a?w(!0):C=m.run():c?c(w.bind(null,!0),!0):m.run(),S.pause=m.pause.bind(m),S.resume=m.resume.bind(m),S.stop=S,S}function yn(e,t=1/0,n){if(t<=0||!y(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,tn(e))yn(e.value,t,n);else if(f(e))for(let r=0;r<e.length;r++)yn(e[r],t,n);else if(m(e)||p(e))e.forEach(e=>{yn(e,t,n)});else if(w(e)){for(let r in e)yn(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&yn(e[r],t,n)}return e}function bn(e,t,n,r){try{return r?e(...r):e()}catch(e){Sn(e,t,n)}}function xn(e,t,n,r){if(g(e)){let i=bn(e,t,n,r);return i&&b(i)&&i.catch(e=>{Sn(e,t,n)}),i}if(f(e)){let i=[];for(let a=0;a<e.length;a++)i.push(xn(e[a],t,n,r));return i}}function Sn(e,t,r,i=!0){let a=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||n;if(t){let n=t.parent,i=t.proxy,a=`https://vuejs.org/error-reference/#runtime-${r}`;for(;n;){let t=n.ec;if(t){for(let n=0;n<t.length;n++)if(t[n](e,i,a)===!1)return}n=n.parent}if(o){Xe(),bn(o,null,10,[e,i,a]),Ze();return}}Cn(e,r,a,i,s)}function Cn(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}var wn=[],Tn=-1,En=[],Dn=null,On=0,kn=Promise.resolve(),An=null;function jn(e){let t=An||kn;return e?t.then(this?e.bind(this):e):t}function Mn(e){let t=Tn+1,n=wn.length;for(;t<n;){let r=t+n>>>1,i=wn[r],a=Rn(i);a<e||a===e&&i.flags&2?t=r+1:n=r}return t}function Nn(e){if(!(e.flags&1)){let t=Rn(e),n=wn[wn.length-1];!n||!(e.flags&2)&&t>=Rn(n)?wn.push(e):wn.splice(Mn(t),0,e),e.flags|=1,Pn()}}function Pn(){An||(An=kn.then(zn))}function Fn(e){f(e)?En.push(...e):Dn&&e.id===-1?Dn.splice(On+1,0,e):e.flags&1||(En.push(e),e.flags|=1),Pn()}function In(e,t,n=Tn+1){for(;n<wn.length;n++){let t=wn[n];if(t&&t.flags&2){if(e&&t.id!==e.uid)continue;wn.splice(n,1),n--,t.flags&4&&(t.flags&=-2),t(),t.flags&4||(t.flags&=-2)}}}function Ln(e){if(En.length){let e=[...new Set(En)].sort((e,t)=>Rn(e)-Rn(t));if(En.length=0,Dn){Dn.push(...e);return}for(Dn=e,On=0;On<Dn.length;On++){let e=Dn[On];e.flags&4&&(e.flags&=-2),e.flags&8||e(),e.flags&=-2}Dn=null,On=0}}var Rn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function zn(e){try{for(Tn=0;Tn<wn.length;Tn++){let e=wn[Tn];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),bn(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;Tn<wn.length;Tn++){let e=wn[Tn];e&&(e.flags&=-2)}Tn=-1,wn.length=0,Ln(e),An=null,(wn.length||En.length)&&zn(e)}}var Bn=null,Vn=null;function Hn(e){let t=Bn;return Bn=e,Vn=e&&e.type.__scopeId||null,t}function P(e,t=Bn,n){if(!t||e._n)return e;let r=(...n)=>{r._d&&ga(-1);let i=Hn(t),a=fa.length,o;try{o=e(...n)}finally{for(let e=fa.length;e>a;e--)ma();Hn(i),r._d&&ga(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function F(e,t){if(Bn===null)return e;let r=Ya(Bn),i=e.dirs||(e.dirs=[]);for(let e=0;e<t.length;e++){let[a,o,s,c=n]=t[e];a&&(g(a)&&(a={mounted:a,updated:a}),a.deep&&yn(o),i.push({dir:a,instance:r,value:o,oldValue:void 0,arg:s,modifiers:c}))}return e}function Un(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let o=0;o<i.length;o++){let s=i[o];a&&(s.oldValue=a[o].value);let c=s.dir[r];c&&(Xe(),xn(c,n,8,[e.el,s,e,t]),Ze())}}function Wn(e,t){if(Na){let n=Na.provides,r=Na.parent&&Na.parent.provides;r===n&&(n=Na.provides=Object.create(r)),n[e]=t}}function Gn(e,t,n=!1){let r=Pa();if(r||yi){let i=yi?yi._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&g(t)?t.call(r&&r.proxy):t}}var Kn=Symbol.for(`v-scx`),qn=()=>Gn(Kn);function Jn(e,t){return Yn(e,null,t)}function I(e,t,n){return Yn(e,t,n)}function Yn(e,t,r=n){let{immediate:a,deep:o,flush:s,once:l}=r,u=c({},r),d=t&&a||!t&&s!==`post`,f;if(Ba){if(s===`sync`){let e=qn();f=e.__watcherHandles||(e.__watcherHandles=[])}else if(!d){let e=()=>{};return e.stop=i,e.resume=i,e.pause=i,e}}let p=Na;u.call=(e,t,n)=>xn(e,p,t,n);let m=!1;s===`post`?u.scheduler=e=>{Xi(e,p&&p.suspense)}:s!==`sync`&&(m=!0,u.scheduler=(e,t)=>{t?e():Nn(e)}),u.augmentJob=e=>{t&&(e.flags|=4),m&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};let h=vn(e,t,u);return Ba&&(f?f.push(h):d&&h()),h}function Xn(e,t,n){let r=this.proxy,i=_(e)?e.includes(`.`)?Zn(r,e):()=>r[e]:e.bind(r,r),a;g(t)?a=t:(a=t.handler,n=t);let o=La(this),s=Yn(i,a.bind(r),n);return o(),s}function Zn(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}var Qn=Symbol(`_vte`),$n=e=>e.__isTeleport,er=Symbol(`_leaveCb`),tr=Symbol(`_enterCb`);function nr(){let e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return kr(()=>{e.isMounted=!0}),Mr(()=>{e.isUnmounting=!0}),e}var rr=[Function,Array],ir={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:rr,onEnter:rr,onAfterEnter:rr,onEnterCancelled:rr,onBeforeLeave:rr,onLeave:rr,onAfterLeave:rr,onLeaveCancelled:rr,onBeforeAppear:rr,onAppear:rr,onAfterAppear:rr,onAppearCancelled:rr},ar=e=>{let t=e.subTree;return t.component?ar(t.component):t},or={name:`BaseTransition`,props:ir,setup(e,{slots:t}){let n=Pa(),r=nr();return()=>{let i=t.default&&mr(t.default(),!0),a=i&&i.length?sr(i):n.subTree?J():void 0;if(!a)return;let o=Zt(e),{mode:s}=o;if(r.isLeaving)return dr(a);let c=fr(a);if(!c)return dr(a);let l=ur(c,o,r,n,e=>l=e);c.type!==ua&&pr(c,l);let u=n.subTree&&fr(n.subTree);if(u&&u.type!==ua&&!ya(u,c)&&ar(n).type!==ua){let e=ur(u,o,r,n);if(pr(u,e),s===`out-in`&&c.type!==ua)return r.isLeaving=!0,e.afterLeave=()=>{r.isLeaving=!1,n.job.flags&8||n.update(),delete e.afterLeave,u=void 0},dr(a);s===`in-out`&&c.type!==ua?e.delayLeave=(e,t,n)=>{let i=lr(r,u);i[String(u.key)]=u,e[er]=()=>{t(),e[er]=void 0,delete l.delayedLeave,u=void 0},l.delayedLeave=()=>{n(),delete l.delayedLeave,u=void 0}}:u=void 0}else u&&(u=void 0);return a}}};function sr(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==ua){t=n;break}}return t}var cr=or;function lr(e,t){let{leavingVNodes:n}=e,r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function ur(e,t,n,r,i){let{appear:a,mode:o,persisted:s=!1,onBeforeEnter:c,onEnter:l,onAfterEnter:u,onEnterCancelled:d,onBeforeLeave:p,onLeave:m,onAfterLeave:h,onLeaveCancelled:g,onBeforeAppear:_,onAppear:v,onAfterAppear:y,onAppearCancelled:b}=t,x=String(e.key),S=lr(n,e),C=(e,t)=>{e&&xn(e,r,9,t)},w=(e,t)=>{let n=t[1];C(e,t),f(e)?e.every(e=>e.length<=1)&&n():e.length<=1&&n()},T={mode:o,persisted:s,beforeEnter(t){let r=c;if(!n.isMounted)if(a)r=_||c;else return;t[er]&&t[er](!0);let i=S[x];i&&ya(e,i)&&i.el[er]&&i.el[er](),C(r,[t])},enter(t){if(S[x]===e)return;let r=l,i=u,o=d;if(!n.isMounted)if(a)r=v||l,i=y||u,o=b||d;else return;let s=!1;t[tr]=e=>{s||(s=!0,C(e?o:i,[t]),T.delayedLeave&&T.delayedLeave(),t[tr]=void 0)};let c=t[tr].bind(null,!1);r?w(r,[t,c]):c()},leave(t,r){let i=String(e.key);if(t[tr]&&t[tr](!0),n.isUnmounting)return r();C(p,[t]);let a=!1;t[er]=n=>{a||(a=!0,r(),C(n?g:h,[t]),t[er]=void 0,S[i]===e&&delete S[i])};let o=t[er].bind(null,!1);S[i]=e,m?w(m,[t,o]):o()},clone(e){let a=ur(e,t,n,r,i);return i&&i(a),a}};return T}function dr(e){if(xr(e))return e=wa(e),e.children=null,e}function fr(e){if(!xr(e))return $n(e.type)&&e.children?sr(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&g(n.default))return n.default()}}function pr(e,t){e.shapeFlag&6&&e.component?(e.transition=t,pr(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function mr(e,t=!1,n){let r=[],i=0;for(let a=0;a<e.length;a++){let o=e[a],s=n==null?o.key:String(n)+String(o.key==null?a:o.key);o.type===V?(o.patchFlag&128&&i++,r=r.concat(mr(o.children,t,s))):(t||o.type!==ua)&&r.push(s==null?o:wa(o,{key:s}))}if(i>1)for(let e=0;e<r.length;e++)r[e].patchFlag=-2;return r}function L(e,t){return g(e)?c({name:e.name},t,{setup:e}):e}function hr(e){e.ids=[e.ids[0]+e.ids[2]+++`-`,0,0]}function gr(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var _r=new WeakMap;function vr(e,t,r,i,o=!1){if(f(e)){e.forEach((e,n)=>vr(e,t&&(f(t)?t[n]:t),r,i,o));return}if(br(i)&&!o){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&vr(e,t,r,i.component.subTree);return}let s=i.shapeFlag&4?Ya(i.component):i.el,c=o?null:s,{i:u,r:p}=e,m=t&&t.r,h=u.refs===n?u.refs={}:u.refs,v=u.setupState,y=Zt(v),b=v===n?a:e=>!gr(h,e)&&d(y,e),x=(e,t)=>!(t&&gr(h,t));if(m!=null&&m!==p){if(yr(t),_(m))h[m]=null,b(m)&&(v[m]=null);else if(tn(m)){let e=t;x(m,e.k)&&(m.value=null),e.k&&(h[e.k]=null)}}if(g(p))bn(p,u,12,[c,h]);else{let t=_(p),n=tn(p);if(t||n){let i=()=>{if(e.f){let n=t?b(p)?v[p]:h[p]:x(p)||!e.k?p.value:h[e.k];if(o)f(n)&&l(n,s);else if(f(n))n.includes(s)||n.push(s);else if(t)h[p]=[s],b(p)&&(v[p]=h[p]);else{let t=[s];x(p,e.k)&&(p.value=t),e.k&&(h[e.k]=t)}}else t?(h[p]=c,b(p)&&(v[p]=c)):n&&(x(p,e.k)&&(p.value=c),e.k&&(h[e.k]=c))};if(c){let t=()=>{i(),_r.delete(e)};t.id=-1,_r.set(e,t),Xi(t,r)}else yr(e),i()}}}function yr(e){let t=_r.get(e);t&&(t.flags|=8,_r.delete(e))}de().requestIdleCallback,de().cancelIdleCallback;var br=e=>!!e.type.__asyncLoader,xr=e=>e.type.__isKeepAlive;function Sr(e,t){wr(e,`a`,t)}function Cr(e,t){wr(e,`da`,t)}function wr(e,t,n=Na){let r=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()});if(Er(t,r,n),n){let e=n.parent;for(;e&&e.parent;)xr(e.parent.vnode)&&Tr(r,t,n,e),e=e.parent}}function Tr(e,t,n,r){let i=Er(t,e,r,!0);Nr(()=>{l(r[t],i)},n)}function Er(e,t,n=Na,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||(t.__weh=(...r)=>{Xe();let i=La(n),a=xn(t,n,e,r);return i(),Ze(),a});return r?i.unshift(a):i.push(a),a}}var Dr=e=>(t,n=Na)=>{(!Ba||e===`sp`)&&Er(e,(...e)=>t(...e),n)},Or=Dr(`bm`),kr=Dr(`m`),Ar=Dr(`bu`),jr=Dr(`u`),Mr=Dr(`bum`),Nr=Dr(`um`),Pr=Dr(`sp`),Fr=Dr(`rtg`),Ir=Dr(`rtc`);function Lr(e,t=Na){Er(`ec`,e,t)}var Rr=`components`,zr=`directives`;function R(e,t){return Ur(Rr,e,!0,t)||e}var Br=Symbol.for(`v-ndc`);function Vr(e){return _(e)?Ur(Rr,e,!1)||e:e||Br}function Hr(e){return Ur(zr,e)}function Ur(e,t,n=!0,r=!1){let i=Bn||Na;if(i){let n=i.type;if(e===Rr){let e=Xa(n,!1);if(e&&(e===t||e===O(t)||e===re(O(t))))return n}let a=Wr(i[e]||n[e],t)||Wr(i.appContext[e],t);return!a&&r?n:a}}function Wr(e,t){return e&&(e[t]||e[O(t)]||e[re(O(t))])}function z(e,t,n,r){let i,a=n&&n[r],o=f(e);if(o||_(e)){let n=o&&qt(e),r=!1,s=!1;n&&(r=!Yt(e),s=Jt(e),e=dt(e)),i=Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(r?s?en($t(e[n])):$t(e[n]):e[n],n,void 0,a&&a[n])}else if(typeof e==`number`){i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}else if(y(e))if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,o=n.length;r<o;r++){let o=n[r];i[r]=t(e[o],o,r,a&&a[r])}}else i=[];return n&&(n[r]=i),i}function Gr(e,t){for(let n=0;n<t.length;n++){let r=t[n];if(f(r))for(let t=0;t<r.length;t++)e[r[t].name]=r[t].fn;else r&&(e[r.name]=r.key?(...e)=>{let t=r.fn(...e);return t&&(t.key=r.key),t}:r.fn)}return e}function B(e,t,n={},r,i,a){if(Bn.ce||Bn.parent&&br(Bn.parent)&&Bn.parent.ce){let e=a!=null&&n.key==null?c({},n,{key:a}):n,i=Object.keys(e).length>0;return t!=="default"&&(e.name=t),H(),W(V,null,[K(`slot`,e,r&&r())],i?-2:64)}let o=e[t];o&&o._c&&(o._d=!1);let s=fa.length;H();let l;try{let i=o&&Kr(o(n)),s=n.key||a||i&&i.key;l=W(V,{key:(s&&!v(s)?s:`_${t}`)+(!i&&r?`_fb`:``)},i||(r?r():[]),i&&e._===1?64:-2)}catch(e){for(let e=fa.length;e>s;e--)ma();throw e}finally{o&&o._c&&(o._d=!0)}return!i&&l.scopeId&&(l.slotScopeIds=[l.scopeId+`-s`]),l}function Kr(e){return e.some(e=>!va(e)||!(e.type===ua||e.type===V&&!Kr(e.children)))?e:null}function qr(e,t){let n={};for(let r in e)n[t&&/[A-Z]/.test(r)?`on:${r}`:ie(r)]=e[r];return n}var Jr=e=>e?za(e)?Ya(e):Jr(e.parent):null,Yr=c(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Jr(e.parent),$root:e=>Jr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>oi(e),$forceUpdate:e=>e.f||(e.f=()=>{Nn(e.update)}),$nextTick:e=>e.n||(e.n=jn.bind(e.proxy)),$watch:e=>Xn.bind(e)}),Xr=(e,t)=>e!==n&&!e.__isScriptSetup&&d(e,t),Zr={get({_:e},t){if(t===`__v_skip`)return!0;let{ctx:r,setupState:i,data:a,props:o,accessCache:s,type:c,appContext:l}=e;if(t[0]!==`$`){let e=s[t];if(e!==void 0)switch(e){case 1:return i[t];case 2:return a[t];case 4:return r[t];case 3:return o[t]}else if(Xr(i,t))return s[t]=1,i[t];else if(a!==n&&d(a,t))return s[t]=2,a[t];else if(d(o,t))return s[t]=3,o[t];else if(r!==n&&d(r,t))return s[t]=4,r[t];else ti&&(s[t]=0)}let u=Yr[t],f,p;if(u)return t===`$attrs`&&st(e.attrs,`get`,``),u(e);if((f=c.__cssModules)&&(f=f[t]))return f;if(r!==n&&d(r,t))return s[t]=4,r[t];if(p=l.config.globalProperties,d(p,t))return p[t]},set({_:e},t,r){let{data:i,setupState:a,ctx:o}=e;return Xr(a,t)?(a[t]=r,!0):i!==n&&d(i,t)?(i[t]=r,!0):d(e.props,t)||t[0]===`$`&&t.slice(1)in e?!1:(o[t]=r,!0)},has({_:{data:e,setupState:t,accessCache:r,ctx:i,appContext:a,props:o,type:s}},c){let l;return!!(r[c]||e!==n&&c[0]!==`$`&&d(e,c)||Xr(t,c)||d(o,c)||d(i,c)||d(Yr,c)||d(a.config.globalProperties,c)||(l=s.__cssModules)&&l[c])},defineProperty(e,t,n){return n.get==null?d(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function Qr(){return $r(`useSlots`).slots}function $r(e){let t=Pa();return t.setupContext||(t.setupContext=Ja(t))}function ei(e){return f(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}var ti=!0;function ni(e){let t=oi(e),n=e.proxy,r=e.ctx;ti=!1,t.beforeCreate&&ii(t.beforeCreate,e,`bc`);let{data:a,computed:o,methods:s,watch:c,provide:l,inject:u,created:d,beforeMount:p,mounted:m,beforeUpdate:h,updated:_,activated:v,deactivated:b,beforeDestroy:x,beforeUnmount:S,destroyed:C,unmounted:w,render:T,renderTracked:E,renderTriggered:D,errorCaptured:ee,serverPrefetch:O,expose:te,inheritAttrs:ne,components:re,directives:ie,filters:ae}=t;if(u&&ri(u,r,null),s)for(let e in s){let t=s[e];g(t)&&(r[e]=t.bind(n))}if(a){let t=a.call(n,n);y(t)&&(e.data=Ut(t))}if(ti=!0,o)for(let e in o){let t=o[e],a=Y({get:g(t)?t.bind(n,n):g(t.get)?t.get.bind(n,n):i,set:!g(t)&&g(t.set)?t.set.bind(n):i});Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>a.value,set:e=>a.value=e})}if(c)for(let e in c)ai(c[e],r,n,e);if(l){let e=g(l)?l.call(n):l;Reflect.ownKeys(e).forEach(t=>{Wn(t,e[t])})}d&&ii(d,e,`c`);function oe(e,t){f(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(oe(Or,p),oe(kr,m),oe(Ar,h),oe(jr,_),oe(Sr,v),oe(Cr,b),oe(Lr,ee),oe(Ir,E),oe(Fr,D),oe(Mr,S),oe(Nr,w),oe(Pr,O),f(te))if(te.length){let t=e.exposed||(e.exposed={});te.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||(e.exposed={});T&&e.render===i&&(e.render=T),ne!=null&&(e.inheritAttrs=ne),re&&(e.components=re),ie&&(e.directives=ie),O&&hr(e)}function ri(e,t,n=i){f(e)&&(e=di(e));for(let n in e){let r=e[n],i;i=y(r)?`default`in r?Gn(r.from||n,r.default,!0):Gn(r.from||n):Gn(r),tn(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function ii(e,t,n){xn(f(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function ai(e,t,n,r){let i=r.includes(`.`)?Zn(n,r):()=>n[r];if(_(e)){let n=t[e];g(n)&&I(i,n)}else if(g(e))I(i,e.bind(n));else if(y(e))if(f(e))e.forEach(e=>ai(e,t,n,r));else{let r=g(e.handler)?e.handler.bind(n):t[e.handler];g(r)&&I(i,r,e)}}function oi(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>si(c,e,o,!0)),si(c,t,o)),y(t)&&a.set(t,c),c}function si(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&si(e,a,n,!0),i&&i.forEach(t=>si(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=ci[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var ci={data:li,props:mi,emits:mi,methods:pi,computed:pi,beforeCreate:fi,created:fi,beforeMount:fi,mounted:fi,beforeUpdate:fi,updated:fi,beforeDestroy:fi,beforeUnmount:fi,destroyed:fi,unmounted:fi,activated:fi,deactivated:fi,errorCaptured:fi,serverPrefetch:fi,components:pi,directives:pi,watch:hi,provide:li,inject:ui};function li(e,t){return t?e?function(){return c(g(e)?e.call(this,this):e,g(t)?t.call(this,this):t)}:t:e}function ui(e,t){return pi(di(e),di(t))}function di(e){if(f(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function fi(e,t){return e?[...new Set([].concat(e,t))]:t}function pi(e,t){return e?c(Object.create(null),e,t):t}function mi(e,t){return e?f(e)&&f(t)?[...new Set([...e,...t])]:c(Object.create(null),ei(e),ei(t??{})):t}function hi(e,t){if(!e)return t;if(!t)return e;let n=c(Object.create(null),e);for(let r in t)n[r]=fi(e[r],t[r]);return n}function gi(){return{app:null,config:{isNativeTag:a,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}var _i=0;function vi(e,t){return function(n,r=null){g(n)||(n=c({},n)),r!=null&&!y(r)&&(r=null);let i=gi(),a=new WeakSet,o=[],s=!1,l=i.app={_uid:_i++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:$a,get config(){return i.config},set config(e){},use(e,...t){return a.has(e)||(e&&g(e.install)?(a.add(e),e.install(l,...t)):g(e)&&(a.add(e),e(l,...t))),l},mixin(e){return i.mixins.includes(e)||i.mixins.push(e),l},component(e,t){return t?(i.components[e]=t,l):i.components[e]},directive(e,t){return t?(i.directives[e]=t,l):i.directives[e]},mount(a,o,c){if(!s){let u=l._ceVNode||K(n,r);return u.appContext=i,c===!0?c=`svg`:c===!1&&(c=void 0),o&&t?t(u,a):e(u,a,c),s=!0,l._container=a,a.__vue_app__=l,Ya(u.component)}},onUnmount(e){o.push(e)},unmount(){s&&(xn(o,l._instance,16),e(null,l._container),delete l._container.__vue_app__)},provide(e,t){return i.provides[e]=t,l},runWithContext(e){let t=yi;yi=l;try{return e()}finally{yi=t}}};return l}}var yi=null,bi=(e,t)=>t===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${O(t)}Modifiers`]||e[`${ne(t)}Modifiers`];function xi(e,t,...r){if(e.isUnmounted)return;let i=e.vnode.props||n,a=r,o=t.startsWith(`update:`),s=o&&bi(i,t.slice(7));s&&(s.trim&&(a=r.map(e=>_(e)?e.trim():e)),s.number&&(a=r.map(ce)));let c,l=i[c=ie(t)]||i[c=ie(O(t))];!l&&o&&(l=i[c=ie(ne(t))]),l&&xn(l,e,6,a);let u=i[c+`Once`];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[c])return;e.emitted[c]=!0,xn(u,e,6,a)}}var Si=new WeakMap;function Ci(e,t,n=!1){let r=n?Si:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},s=!1;if(!g(e)){let r=e=>{let n=Ci(e,t,!0);n&&(s=!0,c(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!s?(y(e)&&r.set(e,null),null):(f(a)?a.forEach(e=>o[e]=null):c(o,a),y(e)&&r.set(e,o),o)}function wi(e,t){return!e||!o(t)?!1:(t=t.slice(2),t=t===`Once`?t:t.replace(/Once$/,``),d(e,t[0].toLowerCase()+t.slice(1))||d(e,ne(t))||d(e,t))}function Ti(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:o,attrs:c,emit:l,render:u,renderCache:d,props:f,data:p,setupState:m,ctx:h,inheritAttrs:g}=e,_=Hn(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=Ta(u.call(t,e,d,f,m,p,h)),y=c}else{let e=t;v=Ta(e.length>1?e(f,{attrs:c,slots:o,emit:l}):e(f,null)),y=t.props?c:Ei(c)}}catch(t){fa.length=0,Sn(t,e,1),v=K(ua)}let b=v;if(y&&g!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(s)&&(y=Di(y,a)),b=wa(b,y,!1,!0))}return n.dirs&&(b=wa(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&pr(b,n.transition),v=b,Hn(_),v}var Ei=e=>{let t;for(let n in e)(n===`class`||n===`style`||o(n))&&((t||(t={}))[n]=e[n]);return t},Di=(e,t)=>{let n={};for(let r in e)(!s(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function Oi(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?ki(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(Ai(o,r,n)&&!wi(l,n))return!0}}}else return(i||s)&&(!s||!s.$stable)?!0:r===o?!1:r?!o||ki(r,o,l):!!o;return!1}function ki(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(Ai(t,e,a)&&!wi(n,a))return!0}return!1}function Ai(e,t,n){let r=e[n],i=t[n];return n===`style`&&y(r)&&y(i)?!xe(r,i):r!==i}function ji({vnode:e,parent:t,suspense:n},r){for(;t;){let n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.suspense.vnode.el=n.el=r,e=n),n===e)(e=t.vnode).el=r,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=r)}var Mi={},Ni=()=>Object.create(Mi),Pi=e=>Object.getPrototypeOf(e)===Mi;function Fi(e,t,n,r=!1){let i={},a=Ni();e.propsDefaults=Object.create(null),Li(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);e.props=n?r?i:Wt(i):e.type.props?i:a,e.attrs=a}function Ii(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=Zt(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(wi(e.emitsOptions,o))continue;let u=t[o];if(c)if(d(a,o))u!==a[o]&&(a[o]=u,l=!0);else{let t=O(o);i[t]=Ri(c,s,t,u,e,!1)}else u!==a[o]&&(a[o]=u,l=!0)}}}else{Li(e,t,i,a)&&(l=!0);let r;for(let a in s)(!t||!d(t,a)&&((r=ne(a))===a||!d(t,r)))&&(c?n&&(n[a]!==void 0||n[r]!==void 0)&&(i[a]=Ri(c,s,a,void 0,e,!0)):delete i[a]);if(a!==s)for(let e in a)(!t||!d(t,e))&&(delete a[e],l=!0)}l&&ct(e.attrs,`set`,``)}function Li(e,t,r,i){let[a,o]=e.propsOptions,s=!1,c;if(t)for(let n in t){if(E(n))continue;let l=t[n],u;a&&d(a,u=O(n))?!o||!o.includes(u)?r[u]=l:(c||(c={}))[u]=l:wi(e.emitsOptions,n)||(!(n in i)||l!==i[n])&&(i[n]=l,s=!0)}if(o){let t=Zt(r),i=c||n;for(let n=0;n<o.length;n++){let s=o[n];r[s]=Ri(a,t,s,i[s],e,!d(i,s))}}return s}function Ri(e,t,n,r,i,a){let o=e[n];if(o!=null){let e=d(o,`default`);if(e&&r===void 0){let e=o.default;if(o.type!==Function&&!o.skipFactory&&g(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let o=La(i);r=a[n]=e.call(null,t),o()}}else r=e;i.ce&&i.ce._setProp(n,r)}o[0]&&(a&&!e?r=!1:o[1]&&(r===``||r===ne(n))&&(r=!0))}return r}var zi=new WeakMap;function Bi(e,t,i=!1){let a=i?zi:t.propsCache,o=a.get(e);if(o)return o;let s=e.props,l={},u=[],p=!1;if(!g(e)){let n=e=>{p=!0;let[n,r]=Bi(e,t,!0);c(l,n),r&&u.push(...r)};!i&&t.mixins.length&&t.mixins.forEach(n),e.extends&&n(e.extends),e.mixins&&e.mixins.forEach(n)}if(!s&&!p)return y(e)&&a.set(e,r),r;if(f(s))for(let e=0;e<s.length;e++){let t=O(s[e]);Vi(t)&&(l[t]=n)}else if(s)for(let e in s){let t=O(e);if(Vi(t)){let n=s[e],r=l[t]=f(n)||g(n)?{type:n}:c({},n),i=r.type,a=!1,o=!0;if(f(i))for(let e=0;e<i.length;++e){let t=i[e],n=g(t)&&t.name;if(n===`Boolean`){a=!0;break}n===`String`&&(o=!1)}else a=g(i)&&i.name===`Boolean`;r[0]=a,r[1]=o,(a||d(r,`default`))&&u.push(t)}}let m=[l,u];return y(e)&&a.set(e,m),m}function Vi(e){return e[0]!==`$`&&!E(e)}var Hi=e=>e===`_`||e===`_ctx`||e===`$stable`,Ui=e=>f(e)?e.map(Ta):[Ta(e)],Wi=(e,t,n)=>{if(t._n)return t;let r=P((...e)=>Ui(t(...e)),n);return r._c=!1,r},Gi=(e,t,n)=>{let r=e._ctx;for(let n in e){if(Hi(n))continue;let i=e[n];if(g(i))t[n]=Wi(n,i,r);else if(i!=null){let e=Ui(i);t[n]=()=>e}}},Ki=(e,t)=>{let n=Ui(t);e.slots.default=()=>n},qi=(e,t,n)=>{for(let r in t)(n||!Hi(r))&&(e[r]=t[r])},Ji=(e,t,n)=>{let r=e.slots=Ni();if(e.vnode.shapeFlag&32){let e=t._;e?(qi(r,t,n),n&&se(r,`_`,e,!0)):Gi(t,r)}else t&&Ki(e,t)},Yi=(e,t,r)=>{let{vnode:i,slots:a}=e,o=!0,s=n;if(i.shapeFlag&32){let e=t._;e?r&&e===1?o=!1:qi(a,t,r):(o=!t.$stable,Gi(t,a)),s=t}else t&&(Ki(e,t),s={default:1});if(o)for(let e in a)!Hi(e)&&s[e]==null&&delete a[e]},Xi=ca;function Zi(e){return Qi(e)}function Qi(e,t){let a=de();a.__VUE__=!0;let{insert:o,remove:s,patchProp:c,createElement:l,createText:u,createComment:d,setText:f,setElementText:p,parentNode:m,nextSibling:h,setScopeId:g=i,insertStaticContent:_}=e,v=(e,t,n,r=null,i=null,a=null,o=void 0,s=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!ya(e,t)&&(r=ve(e),me(e,i,a,!0),e=null),t.patchFlag===-2&&(c=!1,t.dynamicChildren=null);let{type:l,ref:u,shapeFlag:d}=t;switch(l){case la:y(e,t,n,r);break;case ua:b(e,t,n,r);break;case da:e??x(t,n,r,o);break;case V:re(e,t,n,r,i,a,o,s,c);break;default:d&1?w(e,t,n,r,i,a,o,s,c):d&6?ie(e,t,n,r,i,a,o,s,c):(d&64||d&128)&&l.process(e,t,n,r,i,a,o,s,c,xe)}u!=null&&i?vr(u,e&&e.ref,a,t||e,!t):u==null&&e&&e.ref!=null&&vr(e.ref,null,a,e,!0)},y=(e,t,n,r)=>{if(e==null)o(t.el=u(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},b=(e,t,n,r)=>{e==null?o(t.el=d(t.children||``),n,r):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=h(e),o(e,n,r),e=i;o(t,n,r)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),s(e),e=n;s(t)},w=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)T(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),O(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},T=(e,t,n,r,i,a,s,u)=>{let d,f,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(d=e.el=l(e.type,a,m&&m.is,m),h&8?p(d,e.children):h&16&&ee(e.children,d,null,r,i,$i(e,a),s,u),_&&Un(e,null,r,`created`),D(d,e,e.scopeId,s,r),m){for(let e in m)e!==`value`&&!E(e)&&c(d,e,null,m[e],a,r);`value`in m&&c(d,`value`,null,m.value,a),(f=m.onVnodeBeforeMount)&&ka(f,r,e)}_&&Un(e,null,r,`beforeMount`);let v=ta(i,g);v&&g.beforeEnter(d),o(d,t,n),((f=m&&m.onVnodeMounted)||v||_)&&Xi(()=>{try{f&&ka(f,r,e),v&&g.enter(d),_&&Un(e,null,r,`mounted`)}finally{}},i)},D=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t<r.length;t++)g(e,r[t]);if(i){let n=i.subTree;if(t===n||sa(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;D(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},ee=(e,t,n,r,i,a,o,s,c=0)=>{for(let l=c;l<e.length;l++){let c=e[l]=s?Ea(e[l]):Ta(e[l]);v(null,c,t,n,r,i,a,o,s)}},O=(e,t,r,i,a,o,s)=>{let l=t.el=e.el,{patchFlag:u,dynamicChildren:d,dirs:f}=t;u|=e.patchFlag&16;let m=e.props||n,h=t.props||n,g;if(r&&ea(r,!1),(g=h.onVnodeBeforeUpdate)&&ka(g,r,t,e),f&&Un(t,e,r,`beforeUpdate`),r&&ea(r,!0),d&&(!e.dynamicChildren||e.dynamicChildren.length!==d.length)&&(u=0,s=!1,d=null),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&p(l,``),d?te(e.dynamicChildren,d,l,r,i,$i(t,a),o):s||ue(e,t,l,null,r,i,$i(t,a),o,!1),u>0){if(u&16)ne(l,m,h,r,a);else if(u&2&&m.class!==h.class&&c(l,`class`,null,h.class,a),u&4&&c(l,`style`,m.style,h.style,a),u&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t],i=m[n],o=h[n];(o!==i||n===`value`)&&c(l,n,i,o,a,r)}}u&1&&e.children!==t.children&&p(l,t.children)}else!s&&d==null&&ne(l,m,h,r,a);((g=h.onVnodeUpdated)||f)&&Xi(()=>{g&&ka(g,r,t,e),f&&Un(t,e,r,`updated`)},i)},te=(e,t,n,r,i,a,o)=>{for(let s=0;s<t.length;s++){let c=e[s],l=t[s],u=c.el&&(c.type===V||!ya(c,l)||c.shapeFlag&198)?m(c.el):n;v(c,l,u,null,r,i,a,o,!0)}},ne=(e,t,r,i,a)=>{if(t!==r){if(t!==n)for(let n in t)!E(n)&&!(n in r)&&c(e,n,t[n],null,a,i);for(let n in r){if(E(n))continue;let o=r[n],s=t[n];o!==s&&n!==`value`&&c(e,n,s,o,a,i)}`value`in r&&c(e,`value`,t.value,r.value,a)}},re=(e,t,n,r,i,a,s,c,l)=>{let d=t.el=e?e.el:u(``),f=t.anchor=e?e.anchor:u(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(c=c?c.concat(h):h),e==null?(o(d,n,r),o(f,n,r),ee(t.children||[],n,f,i,a,s,c,l)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(te(e.dynamicChildren,m,n,i,a,s,c),(t.key!=null||i&&t===i.subTree)&&na(e,t,!0)):ue(e,t,n,f,i,a,s,c,l)},ie=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):ae(t,n,r,i,a,o,c):se(e,t,c)},ae=(e,t,n,r,i,a,o)=>{let s=e.component=Ma(e,r,i);if(xr(e)&&(s.ctx.renderer=xe),Va(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,ce,o),!e.el){let r=s.subTree=K(ua);b(null,r,t,n),e.placeholder=r.el}}else ce(s,e,t,n,i,a,o)},se=(e,t,n)=>{let r=t.component=e.component;if(Oi(e,t,n))if(r.asyncDep&&!r.asyncResolved){le(r,t,n);return}else r.next=t,r.update();else t.el=e.el,r.vnode=t},ce=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=ia(e);if(n){t&&(t.el=c.el,le(e,t,o)),n.asyncDep.then(()=>{Xi(()=>{e.isUnmounted||l()},i)});return}}let u=t,d;ea(e,!1),t?(t.el=c.el,le(e,t,o)):t=c,n&&oe(n),(d=t.props&&t.props.onVnodeBeforeUpdate)&&ka(d,s,t,c),ea(e,!0);let f=Ti(e),p=e.subTree;e.subTree=f,v(p,f,m(p.el),ve(p),e,i,a),t.el=f.el,u===null&&ji(e,f.el),r&&Xi(r,i),(d=t.props&&t.props.onVnodeUpdated)&&Xi(()=>ka(d,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=br(t);if(ea(e,!1),l&&oe(l),!m&&(o=c&&c.onVnodeBeforeMount)&&ka(o,d,t),ea(e,!0),s&&Ce){let t=()=>{e.subTree=Ti(e),Ce(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=Ti(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&Xi(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;Xi(()=>ka(o,d,e),i)}(t.shapeFlag&256||d&&br(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&Xi(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new Pe(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>Nn(u),ea(e,!0),l()},le=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,Ii(e,t.props,r,n),Yi(e,t.children,n),Xe(),In(e),Ze()},ue=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:f,shapeFlag:m}=t;if(f>0){if(f&128){fe(l,d,n,r,i,a,o,s,c);return}if(f&256){k(l,d,n,r,i,a,o,s,c);return}}m&8?(u&16&&_e(l,i,a),d!==l&&p(n,d)):u&16?m&16?fe(l,d,n,r,i,a,o,s,c):_e(l,i,a,!0):(u&8&&p(n,``),m&16&&ee(d,n,r,i,a,o,s,c))},k=(e,t,n,i,a,o,s,c,l)=>{e=e||r,t=t||r;let u=e.length,d=t.length,f=Math.min(u,d),p;for(p=0;p<f;p++){let r=t[p]=l?Ea(t[p]):Ta(t[p]);v(e[p],r,n,null,a,o,s,c,l)}u>d?_e(e,a,o,!0,!1,f):ee(t,n,i,a,o,s,c,l,f)},fe=(e,t,n,i,a,o,s,c,l)=>{let u=0,d=t.length,f=e.length-1,p=d-1;for(;u<=f&&u<=p;){let r=e[u],i=t[u]=l?Ea(t[u]):Ta(t[u]);if(ya(r,i))v(r,i,n,null,a,o,s,c,l);else break;u++}for(;u<=f&&u<=p;){let r=e[f],i=t[p]=l?Ea(t[p]):Ta(t[p]);if(ya(r,i))v(r,i,n,null,a,o,s,c,l);else break;f--,p--}if(u>f){if(u<=p){let e=p+1,r=e<d?t[e].el:i;for(;u<=p;)v(null,t[u]=l?Ea(t[u]):Ta(t[u]),n,r,a,o,s,c,l),u++}}else if(u>p)for(;u<=f;)me(e[u],a,o,!0),u++;else{let m=u,h=u,g=new Map;for(u=h;u<=p;u++){let e=t[u]=l?Ea(t[u]):Ta(t[u]);e.key!=null&&g.set(e.key,u)}let _,y=0,b=p-h+1,x=!1,S=0,C=Array(b);for(u=0;u<b;u++)C[u]=0;for(u=m;u<=f;u++){let r=e[u];if(y>=b){me(r,a,o,!0);continue}let i;if(r.key!=null)i=g.get(r.key);else for(_=h;_<=p;_++)if(C[_-h]===0&&ya(r,t[_])){i=_;break}i===void 0?me(r,a,o,!0):(C[i-h]=u+1,i>=S?S=i:x=!0,v(r,t[i],n,null,a,o,s,c,l),y++)}let w=x?ra(C):r;for(_=w.length-1,u=b-1;u>=0;u--){let e=h+u,r=t[e],f=t[e+1],p=e+1<d?f.el||oa(f):i;C[u]===0?v(null,r,n,p,a,o,s,c,l):x&&(_<0||u!==w[_]?pe(r,n,p,2):_--)}}},pe=(e,t,n,r,i=null)=>{let{el:a,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6){pe(e.component.subTree,t,n,r);return}if(d&128){e.suspense.move(t,n,r);return}if(d&64){c.move(e,t,n,xe);return}if(c===V){o(a,t,n);for(let e=0;e<u.length;e++)pe(u[e],t,n,r);o(e.anchor,t,n);return}if(c===da){S(e,t,n);return}if(r!==2&&d&1&&l)if(r===0)l.persisted&&!a[er]?o(a,t,n):(l.beforeEnter(a),o(a,t,n),Xi(()=>l.enter(a),i));else{let{leave:r,delayLeave:i,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?s(a):o(a,t,n)},d=()=>{let e=a._isLeaving||!!a[er];a._isLeaving&&a[er](!0),l.persisted&&!e?u():r(a,()=>{u(),c&&c()})};i?i(a,u,d):d()}else o(a,t,n)},me=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p,memo:m}=e;if(d===-2&&(i=!1),s!=null&&(Xe(),vr(s,null,n,e,!0),Ze()),p!=null&&(t.renderCache[p]=void 0),u&256){t.ctx.deactivate(e);return}let h=u&1&&f,g=!br(e),_;if(g&&(_=o&&o.onVnodeBeforeUnmount)&&ka(_,t,e),u&6)ge(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}h&&Un(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,xe,r):l&&!l.hasOnce&&(a!==V||d>0&&d&64)?_e(l,t,n,!1,!0):(a===V&&d&384||!i&&u&16)&&_e(c,t,n),r&&he(e)}let v=m!=null&&p==null;(g&&(_=o&&o.onVnodeUnmounted)||h||v)&&Xi(()=>{_&&ka(_,t,e),h&&Un(e,null,t,`unmounted`),v&&(e.el=null)},n)},he=e=>{let{type:t,el:n,anchor:r,transition:i}=e;if(t===V){A(n,r);return}if(t===da){C(e);return}let a=()=>{s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(e.shapeFlag&1&&i&&!i.persisted){let{leave:t,delayLeave:r}=i,o=()=>t(n,a);r?r(e.el,a,o):o()}else a()},A=(e,t)=>{let n;for(;e!==t;)n=h(e),s(e),e=n;s(t)},ge=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;aa(c),aa(l),r&&oe(r),i.stop(),a&&(a.flags|=8,me(o,e,t,n)),s&&Xi(s,t),Xi(()=>{e.isUnmounted=!0},t)},_e=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o<e.length;o++)me(e[o],t,n,r,i)},ve=e=>{if(e.shapeFlag&6)return ve(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[Qn];return n?h(n):t},ye=!1,be=(e,t,n)=>{let r;e==null?t._vnode&&(me(t._vnode,null,null,!0),r=t._vnode.component):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e,ye||(ye=!0,In(r),Ln(),ye=!1)},xe={p:v,um:me,m:pe,r:he,mt:ae,mc:ee,pc:ue,pbc:te,n:ve,o:e},Se,Ce;return t&&([Se,Ce]=t(xe)),{render:be,hydrate:Se,createApp:vi(be,Se)}}function $i({type:e,props:t},n){return n===`svg`&&e===`foreignObject`||n===`mathml`&&e===`annotation-xml`&&t&&t.encoding&&t.encoding.includes(`html`)?void 0:n}function ea({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function ta(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function na(e,t,n=!1){let r=e.children,i=t.children;if(f(r)&&f(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[e]=Ea(i[e]),a.el=t.el),!n&&a.patchFlag!==-2&&na(t,a)),a.type===la&&(a.patchFlag===-1&&(a=i[e]=Ea(a)),a.el=t.el),a.type===ua&&!a.el&&(a.el=t.el)}}function ra(e){let t=e.slice(),n=[0],r,i,a,o,s,c=e.length;for(r=0;r<c;r++){let c=e[r];if(c!==0){if(i=n[n.length-1],e[i]<c){t[r]=i,n.push(r);continue}for(a=0,o=n.length-1;a<o;)s=a+o>>1,e[n[s]]<c?a=s+1:o=s;c<e[n[a]]&&(a>0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-->0;)n[a]=o,o=t[o];return n}function ia(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:ia(t)}function aa(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function oa(e){if(e.placeholder)return e.placeholder;let t=e.component;return t?oa(t.subTree):null}var sa=e=>e.__isSuspense;function ca(e,t){t&&t.pendingBranch?f(e)?t.effects.push(...e):t.effects.push(e):Fn(e)}var V=Symbol.for(`v-fgt`),la=Symbol.for(`v-txt`),ua=Symbol.for(`v-cmt`),da=Symbol.for(`v-stc`),fa=[],pa=null;function H(e=!1){fa.push(pa=e?null:[])}function ma(){fa.pop(),pa=fa[fa.length-1]||null}var ha=1;function ga(e,t=!1){ha+=e,e<0&&pa&&t&&(pa.hasOnce=!0)}function _a(e){return e.dynamicChildren=ha>0?pa||r:null,ma(),ha>0&&pa&&pa.push(e),e}function U(e,t,n,r,i,a){return _a(G(e,t,n,r,i,a,!0))}function W(e,t,n,r,i){return _a(K(e,t,n,r,i,!0))}function va(e){return e?e.__v_isVNode===!0:!1}function ya(e,t){return e.type===t.type&&e.key===t.key}var ba=({key:e})=>e??null,xa=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:_(e)||tn(e)||g(e)?{i:Bn,r:e,k:t,f:!!n}:e);function G(e,t=null,n=null,r=0,i=null,a=e===V?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&ba(t),ref:t&&xa(t),scopeId:Vn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Bn};return s?(Da(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=_(n)?8:16),ha>0&&!o&&pa&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&pa.push(c),c}var K=Sa;function Sa(e,t=null,n=null,r=0,i=null,a=!1){if((!e||e===Br)&&(e=ua),va(e)){let r=wa(e,t,!0);return n&&Da(r,n),ha>0&&!a&&pa&&(r.shapeFlag&6?pa[pa.indexOf(e)]=r:pa.push(r)),r.patchFlag=-2,r}if(Za(e)&&(e=e.__vccOpts),t){t=Ca(t);let{class:e,style:n}=t;e&&!_(e)&&(t.class=A(e)),y(n)&&(Xt(n)&&!f(n)&&(n=c({},n)),t.style=k(n))}let o=_(e)?1:sa(e)?128:$n(e)?64:y(e)?4:g(e)?2:0;return G(e,t,n,r,i,o,a,!0)}function Ca(e){return e?Xt(e)||Pi(e)?c({},e):e:null}function wa(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?Oa(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&ba(l),ref:t&&t.ref?n&&a?f(a)?a.concat(xa(t)):[a,xa(t)]:xa(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==V?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&wa(e.ssContent),ssFallback:e.ssFallback&&wa(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&r&&pr(u,c.clone(u)),u}function q(e=` `,t=0){return K(la,null,e,t)}function J(e=``,t=!1){return t?(H(),W(ua,null,e)):K(ua,null,e)}function Ta(e){return e==null||typeof e==`boolean`?K(ua):f(e)?K(V,null,e.slice()):va(e)?Ea(e):K(la,null,String(e))}function Ea(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:wa(e)}function Da(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(f(t))n=16;else if(typeof t==`object`)if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),Da(e,n()),n._c&&(n._d=!0));return}else{n=32;let r=t._;!r&&!Pi(t)?t._ctx=Bn:r===3&&Bn&&(Bn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(g(t)){if(r&65){Da(e,{default:t});return}t={default:t,_ctx:Bn},n=32}else t=String(t),r&64?(n=16,t=[q(t)]):n=8;e.children=t,e.shapeFlag|=n}function Oa(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if(e===`class`)t.class!==r.class&&(t.class=A([t.class,r.class]));else if(e===`style`)t.style=k([t.style,r.style]);else if(o(e)){let n=t[e],i=r[e];i&&n!==i&&!(f(n)&&n.includes(i))?t[e]=n?[].concat(n,i):i:i==null&&n==null&&!s(e)&&(t[e]=i)}else e!==``&&(t[e]=r[e])}return t}function ka(e,t,n,r=null){xn(e,t,7,[n,r])}var Aa=gi(),ja=0;function Ma(e,t,r){let i=e.type,a=(t?t.appContext:e.appContext)||Aa,o={uid:ja++,vnode:e,type:i,parent:t,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Oe(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(a.provides),ids:t?t.ids:[``,0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Bi(i,a),emitsOptions:Ci(i,a),emit:null,emitted:null,propsDefaults:n,inheritAttrs:i.inheritAttrs,ctx:n,data:n,props:n,attrs:n,slots:n,refs:n,setupState:n,setupContext:null,suspense:r,suspenseId:r?r.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=xi.bind(null,o),e.ce&&e.ce(o),o}var Na=null,Pa=()=>Na||Bn,Fa,Ia;{let e=de(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};Fa=t(`__VUE_INSTANCE_SETTERS__`,e=>Na=e),Ia=t(`__VUE_SSR_SETTERS__`,e=>Ba=e)}var La=e=>{let t=Na;return Fa(e),e.scope.on(),()=>{e.scope.off(),Fa(t)}},Ra=()=>{Na&&Na.scope.off(),Fa(null)};function za(e){return e.vnode.shapeFlag&4}var Ba=!1;function Va(e,t=!1,n=!1){t&&Ia(t);let{props:r,children:i}=e.vnode,a=za(e);Fi(e,r,a,t),Ji(e,i,n||t);let o=a?Ha(e,t):void 0;return t&&Ia(!1),o}function Ha(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Zr);let{setup:r}=n;if(r){Xe();let n=e.setupContext=r.length>1?Ja(e):null,i=La(e),a=bn(r,e,0,[e.props,n]),o=b(a);if(Ze(),i(),(o||e.sp)&&!br(e)&&hr(e),o){if(a.then(Ra,Ra),t)return a.then(n=>{Ua(e,n,t)}).catch(t=>{Sn(t,e,0)});e.asyncDep=a}else Ua(e,a,t)}else Ka(e,t)}function Ua(e,t,n){g(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:y(t)&&(e.setupState=cn(t)),Ka(e,n)}var Wa,Ga;function Ka(e,t,n){let r=e.type;if(!e.render){if(!t&&Wa&&!r.render){let t=r.template||oi(e).template;if(t){let{isCustomElement:n,compilerOptions:i}=e.appContext.config,{delimiters:a,compilerOptions:o}=r;r.render=Wa(t,c(c({isCustomElement:n,delimiters:a},i),o))}}e.render=r.render||i,Ga&&Ga(e)}{let t=La(e);Xe();try{ni(e)}finally{Ze(),t()}}}var qa={get(e,t){return st(e,`get`,``),e[t]}};function Ja(e){return{attrs:new Proxy(e.attrs,qa),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function Ya(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(cn(Qt(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Yr)return Yr[n](e)},has(e,t){return t in e||t in Yr}})):e.proxy}function Xa(e,t=!0){return g(e)?e.displayName||e.name:e.name||t&&e.__name}function Za(e){return g(e)&&`__vccOpts`in e}var Y=(e,t)=>pn(e,t,Ba);function Qa(e,t,n){try{ga(-1);let r=arguments.length;return r===2?y(t)&&!f(t)?va(t)?K(e,null,[t]):K(e,t):K(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&va(n)&&(n=[n]),K(e,t,n))}finally{ga(1)}}var $a=`3.5.40`,eo=void 0,to=typeof window<`u`&&window.trustedTypes;if(to)try{eo=to.createPolicy(`vue`,{createHTML:e=>e})}catch{}var no=eo?e=>eo.createHTML(e):e=>e,ro=`http://www.w3.org/2000/svg`,io=`http://www.w3.org/1998/Math/MathML`,ao=typeof document<`u`?document:null,oo=ao&&ao.createElement(`template`),so={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?ao.createElementNS(ro,e):t===`mathml`?ao.createElementNS(io,e):n?ao.createElement(e,{is:n}):ao.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>ao.createTextNode(e),createComment:e=>ao.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>ao.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===a||!(i=i.nextSibling)););else{oo.innerHTML=no(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=oo.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},co=`transition`,lo=`animation`,uo=Symbol(`_vtc`),fo={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},po=c({},ir,fo),mo=(e=>(e.displayName=`Transition`,e.props=po,e))((e,{slots:t})=>Qa(cr,_o(e),t)),ho=(e,t=[])=>{f(e)?e.forEach(e=>e(...t)):e&&e(...t)},go=e=>e?f(e)?e.some(e=>e.length>1):e.length>1:!1;function _o(e){let t={};for(let n in e)n in fo||(t[n]=e[n]);if(e.css===!1)return t;let{name:n=`v`,type:r,duration:i,enterFromClass:a=`${n}-enter-from`,enterActiveClass:o=`${n}-enter-active`,enterToClass:s=`${n}-enter-to`,appearFromClass:l=a,appearActiveClass:u=o,appearToClass:d=s,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:p=`${n}-leave-active`,leaveToClass:m=`${n}-leave-to`}=e,h=vo(i),g=h&&h[0],_=h&&h[1],{onBeforeEnter:v,onEnter:y,onEnterCancelled:b,onLeave:x,onLeaveCancelled:S,onBeforeAppear:C=v,onAppear:w=y,onAppearCancelled:T=b}=t,E=(e,t,n,r)=>{e._enterCancelled=r,xo(e,t?d:s),xo(e,t?u:o),n&&n()},D=(e,t)=>{e._isLeaving=!1,xo(e,f),xo(e,m),xo(e,p),t&&t()},ee=e=>(t,n)=>{let i=e?w:y,o=()=>E(t,e,n);ho(i,[t,o]),So(()=>{xo(t,e?l:a),bo(t,e?d:s),go(i)||wo(t,r,g,o)})};return c(t,{onBeforeEnter(e){ho(v,[e]),bo(e,a),bo(e,o)},onBeforeAppear(e){ho(C,[e]),bo(e,l),bo(e,u)},onEnter:ee(!1),onAppear:ee(!0),onLeave(e,t){e._isLeaving=!0;let n=()=>D(e,t);bo(e,f),e._enterCancelled?(bo(e,p),Oo(e)):(Oo(e),bo(e,p)),So(()=>{e._isLeaving&&(xo(e,f),bo(e,m),go(x)||wo(e,r,_,n))}),ho(x,[e,n])},onEnterCancelled(e){E(e,!1,void 0,!0),ho(b,[e])},onAppearCancelled(e){E(e,!0,void 0,!0),ho(T,[e])},onLeaveCancelled(e){D(e),ho(S,[e])}})}function vo(e){if(e==null)return null;if(y(e))return[yo(e.enter),yo(e.leave)];{let t=yo(e);return[t,t]}}function yo(e){return le(e)}function bo(e,t){t.split(/\s+/).forEach(t=>t&&e.classList.add(t)),(e[uo]||(e[uo]=new Set)).add(t)}function xo(e,t){t.split(/\s+/).forEach(t=>t&&e.classList.remove(t));let n=e[uo];n&&(n.delete(t),n.size||(e[uo]=void 0))}function So(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}var Co=0;function wo(e,t,n,r){let i=e._endId=++Co,a=()=>{i===e._endId&&r()};if(n!=null)return setTimeout(a,n);let{type:o,timeout:s,propCount:c}=To(e,t);if(!o)return r();let l=o+`end`,u=0,d=()=>{e.removeEventListener(l,f),a()},f=t=>{t.target===e&&++u>=c&&d()};setTimeout(()=>{u<c&&d()},s+1),e.addEventListener(l,f)}function To(e,t){let n=window.getComputedStyle(e),r=e=>(n[e]||``).split(`, `),i=r(`${co}Delay`),a=r(`${co}Duration`),o=Eo(i,a),s=r(`${lo}Delay`),c=r(`${lo}Duration`),l=Eo(s,c),u=null,d=0,f=0;t===co?o>0&&(u=co,d=o,f=a.length):t===lo?l>0&&(u=lo,d=l,f=c.length):(d=Math.max(o,l),u=d>0?o>l?co:lo:null,f=u?u===co?a.length:c.length:0);let p=u===co&&/\b(?:transform|all)(?:,|$)/.test(r(`${co}Property`).toString());return{type:u,timeout:d,propCount:f,hasTransform:p}}function Eo(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((t,n)=>Do(t)+Do(e[n])))}function Do(e){return e===`auto`?0:Number(e.slice(0,-1).replace(`,`,`.`))*1e3}function Oo(e){return(e?e.ownerDocument:document).body.offsetHeight}function ko(e,t,n){let r=e[uo];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var Ao=Symbol(`_vod`),jo=Symbol(`_vsh`),Mo={name:`show`,beforeMount(e,{value:t},{transition:n}){e[Ao]=e.style.display===`none`?``:e.style.display,n&&t?n.beforeEnter(e):No(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),No(e,!0),r.enter(e)):r.leave(e,()=>{No(e,!1)}):No(e,t))},beforeUnmount(e,{value:t}){No(e,t)}};function No(e,t){e.style.display=t?e[Ao]:`none`,e[jo]=!t}var Po=Symbol(``);function Fo(e){let t=Pa();if(!t)return;let n=t.ut=(n=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(e=>Lo(e,n))},r=()=>{let r=e(t.proxy);t.ce?Lo(t.ce,r):Io(t.subTree,r),n(r)};Ar(()=>{Fn(r)}),kr(()=>{I(r,i,{flush:`post`});let e=new MutationObserver(r);e.observe(t.subTree.el.parentNode,{childList:!0}),Nr(()=>e.disconnect())})}function Io(e,t){if(e.shapeFlag&128){let n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{Io(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)Lo(e.el,t);else if(e.type===V)e.children.forEach(e=>Io(e,t));else if(e.type===da){let{el:n,anchor:r}=e;for(;n&&(Lo(n,t),n!==r);)n=n.nextSibling}}function Lo(e,t){if(e.nodeType===1){let n=e.style,r=``;for(let e in t){let i=Ee(t[e]);n.setProperty(`--${e}`,i),r+=`--${e}: ${i};`}n[Po]=r}}var Ro=/(?:^|;)\s*display\s*:/;function zo(e,t,n){let r=e.style,i=_(n),a=!1;if(n&&!i){if(t)if(_(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??Vo(r,t,``)}else for(let e in t)n[e]??Vo(r,e,``);for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?Vo(r,i,``):Go(e,i,!_(t)&&t?t[i]:void 0,o)||Vo(r,i,o)}}else if(i){if(t!==n){let e=r[Po];e&&(n+=`;`+e),r.cssText=n,a=Ro.test(n)}}else t&&e.removeAttribute(`style`);Ao in e&&(e[Ao]=a?r.display:``,e[jo]&&(r.display=`none`))}var Bo=/\s*!important$/;function Vo(e,t,n){if(f(n))n.forEach(n=>Vo(e,t,n));else if(n??(n=``),t.startsWith(`--`))e.setProperty(t,n);else{let r=Wo(e,t);Bo.test(n)?e.setProperty(ne(r),n.replace(Bo,``),`important`):e[r]=n}}var Ho=[`Webkit`,`Moz`,`ms`],Uo={};function Wo(e,t){let n=Uo[t];if(n)return n;let r=O(t);if(r!==`filter`&&r in e)return Uo[t]=r;r=re(r);for(let n=0;n<Ho.length;n++){let i=Ho[n]+r;if(i in e)return Uo[t]=i}return t}function Go(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&_(r)&&n===r}var Ko=`http://www.w3.org/1999/xlink`;function qo(e,t,n,r,i,a=ve(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(Ko,t.slice(6,t.length)):e.setAttributeNS(Ko,t,n):n==null||a&&!ye(n)?e.removeAttribute(t):e.setAttribute(t,a?``:v(n)?String(n):n)}function Jo(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?no(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);(r!==i||!(`_value`in e))&&(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=ye(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function Yo(e,t,n,r){e.addEventListener(t,n,r)}function Xo(e,t,n,r){e.removeEventListener(t,n,r)}var Zo=Symbol(`_vei`);function Qo(e,t,n,r,i=null){let a=e[Zo]||(e[Zo]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=ts(t);r?Yo(e,n,a[t]=as(r,i),s):o&&(Xo(e,n,o,s),a[t]=void 0)}}var $o=/(Once|Passive|Capture)$/,es=/^on:?(?:Once|Passive|Capture)$/;function ts(e){let t,n;for(;(n=e.match($o))&&!es.test(e);)t||(t={}),e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===`:`?e.slice(3):ne(e.slice(2)),t]}var ns=0,rs=Promise.resolve(),is=()=>ns||(rs.then(()=>ns=0),ns=Date.now());function as(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;let r=n.value;if(f(r)){let n=e.stopImmediatePropagation;e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0};let i=r.slice(),a=[e];for(let n=0;n<i.length&&!e._stopped;n++){let e=i[n];e&&xn(e,t,5,a)}}else xn(r,t,5,[e])};return n.value=e,n.attached=is(),n}var os=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,ss=(e,t,n,r,i,a)=>{let c=i===`svg`;t===`class`?ko(e,r,c):t===`style`?zo(e,n,r):o(t)?s(t)||Qo(e,t,n,r,a):(t[0]===`.`?(t=t.slice(1),!0):t[0]===`^`?(t=t.slice(1),!1):cs(e,t,r,c))?(Jo(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&qo(e,t,r,c,a,t!==`value`)):e._isVueCE&&(ls(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!_(r)))?Jo(e,O(t),r,a,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),qo(e,t,r,c))};function cs(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&os(t)&&g(n));if(t===`spellcheck`||t===`draggable`||t===`translate`||t===`autocorrect`||t===`sandbox`&&e.tagName===`IFRAME`||t===`form`||t===`list`&&e.tagName===`INPUT`||t===`type`&&e.tagName===`TEXTAREA`)return!1;if(t===`width`||t===`height`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return os(t)&&_(n)?!1:t in e}function ls(e,t){let n=e._def.props;if(!n)return!1;let r=O(t);return Array.isArray(n)?n.some(e=>O(e)===r):Object.keys(n).some(e=>O(e)===r)}var us={};function ds(e,t,n){let r=L(e,t);w(r)&&(r=c({},r,t));class i extends ps{constructor(e){super(r,e,n)}}return i.def=r,i}var fs=typeof HTMLElement<`u`?HTMLElement:class{},ps=class e extends fs{constructor(e,t={},n=Rs){super(),this._def=e,this._props=t,this._createApp=n,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._patching=!1,this._dirty=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._styleAnchors=new WeakMap,this._ob=null,this.shadowRoot&&n!==Rs?this._root=this.shadowRoot:e.shadowRoot===!1?this._root=this:(this.attachShadow(c({},e.shadowRootOptions,{mode:`open`})),this._root=this.shadowRoot)}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let t=this;for(;t=t&&(t.assignedSlot||t.parentNode||t.host);)if(t instanceof e){this._parent=t;break}this._instance||(this._resolved?this._mount(this._def):t&&t._pendingResolve?this._pendingResolve=t._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(e=this._parent){e&&(this._instance.parent=e._instance,this._inheritParentContext(e))}_inheritParentContext(e=this._parent){e&&this._app&&Object.setPrototypeOf(this._app._context.provides,e._instance.provides)}disconnectedCallback(){this._connected=!1,jn(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&(this._teleportTargets.clear(),this._teleportTargets=void 0))})}_processMutations(e){for(let t of e)this._setAttr(t.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let e=0;e<this.attributes.length;e++)this._setAttr(this.attributes[e].name);this._ob=new MutationObserver(this._processMutations.bind(this)),this._ob.observe(this,{attributes:!0});let e=(e,t=!1)=>{this._resolved=!0,this._pendingResolve=void 0;let{props:n,styles:r}=e,i;if(n&&!f(n))for(let e in n){let t=n[e];(t===Number||t&&t.type===Number)&&(e in this._props&&(this._props[e]=le(this._props[e])),(i||(i=Object.create(null)))[O(e)]=!0)}this._numberProps=i,this._resolveProps(e),this.shadowRoot&&this._applyStyles(r),this._mount(e)},t=this._def.__asyncLoader;t?this._pendingResolve=t().then(t=>{t.configureApp=this._def.configureApp,e(this._def=t,!0)}):e(this._def)}_mount(e){this._app=this._createApp(e),this._inheritParentContext(),e.configureApp&&e.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);let t=this._instance&&this._instance.exposed;if(t)for(let e in t)d(this,e)||Object.defineProperty(this,e,{get:()=>on(t[e])})}_resolveProps(e){let{props:t}=e,n=f(t)?t:Object.keys(t||{});for(let e of Object.keys(this))e[0]!==`_`&&n.includes(e)&&this._setProp(e,this[e]);for(let e of n.map(O))Object.defineProperty(this,e,{get(){return this._getProp(e)},set(t){this._setProp(e,t,!0,!this._patching)}})}_setAttr(e){if(e.startsWith(`data-v-`))return;let t=this.hasAttribute(e),n=t?this.getAttribute(e):us,r=O(e);t&&this._numberProps&&this._numberProps[r]&&(n=le(n)),this._setProp(r,n,!1,!0)}_getProp(e){return this._props[e]}_setProp(e,t,n=!0,r=!1){if(t!==this._props[e]&&(this._dirty=!0,t===us?delete this._props[e]:(this._props[e]=t,e===`key`&&this._app&&(this._app._ceVNode.key=t)),r&&this._instance&&this._update(),n)){let n=this._ob;n&&(this._processMutations(n.takeRecords()),n.disconnect()),t===!0?this.setAttribute(ne(e),``):typeof t==`string`||typeof t==`number`?this.setAttribute(ne(e),t+``):t||this.removeAttribute(ne(e)),n&&n.observe(this,{attributes:!0})}}_update(){let e=this._createVNode();this._app&&(e.appContext=this._app._context),Ls(e,this._root)}_createVNode(){let e={};this.shadowRoot||(e.onVnodeMounted=e.onVnodeUpdated=this._renderSlots.bind(this));let t=K(this._def,c(e,this._props));return this._instance||(t.ce=e=>{this._instance=e,e.ce=this,e.isCE=!0;let t=(e,t)=>{this.dispatchEvent(new CustomEvent(e,w(t[0])?c({detail:t},t[0]):{detail:t}))};e.emit=(e,...n)=>{t(e,n),ne(e)!==e&&t(ne(e),n)},this._setParent()}),t}_applyStyles(e,t,n){if(!e)return;if(t){if(t===this._def||this._styleChildren.has(t))return;this._styleChildren.add(t)}let r=this._nonce,i=this.shadowRoot,a=n?this._getStyleAnchor(n)||this._getStyleAnchor(this._def):this._getRootStyleInsertionAnchor(i),o=null;for(let s=e.length-1;s>=0;s--){let c=document.createElement(`style`);r&&c.setAttribute(`nonce`,r),c.textContent=e[s],i.insertBefore(c,o||a),o=c,s===0&&(n||this._styleAnchors.set(this._def,c),t&&this._styleAnchors.set(t,c))}}_getStyleAnchor(e){if(!e)return null;let t=this._styleAnchors.get(e);return t&&t.parentNode===this.shadowRoot?t:(t&&this._styleAnchors.delete(e),null)}_getRootStyleInsertionAnchor(e){for(let t=0;t<e.childNodes.length;t++){let n=e.childNodes[t];if(!(n instanceof HTMLStyleElement))return n}return null}_parseSlots(){let e=this._slots={},t;for(;t=this.firstChild;){let n=t.nodeType===1&&t.getAttribute(`slot`)||`default`;(e[n]||(e[n]=[])).push(t),this.removeChild(t)}}_renderSlots(){let e=this._getSlots(),t=this._instance.type.__scopeId;for(let n=0;n<e.length;n++){let r=e[n],i=r.getAttribute(`name`)||`default`,a=this._slots[i],o=r.parentNode;if(a)for(let e of a){if(t&&e.nodeType===1){let n=t+`-s`,r=document.createTreeWalker(e,1);e.setAttribute(n,``);let i;for(;i=r.nextNode();)i.setAttribute(n,``)}o.insertBefore(e,r)}else for(;r.firstChild;)o.insertBefore(r.firstChild,r);o.removeChild(r)}}_getSlots(){let e=[this];this._teleportTargets&&e.push(...this._teleportTargets);let t=new Set;for(let n of e){let e=n.querySelectorAll(`slot`);for(let n=0;n<e.length;n++)t.add(e[n])}return Array.from(t)}_injectChildStyle(e,t){this._applyStyles(e.styles,e,t)}_beginPatch(){this._patching=!0,this._dirty=!1}_endPatch(){this._patching=!1,this._dirty&&this._instance&&this._update()}_hasShadowRoot(){return this._def.shadowRoot!==!1}_removeChildStyle(e){}},ms=e=>{let t=e.props[`onUpdate:modelValue`]||!1;return f(t)?e=>oe(t,e):t};function hs(e){e.target.composing=!0}function gs(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event(`input`)))}var _s=Symbol(`_assign`);function vs(e,t,n){return t&&(e=e.trim()),n&&(e=ce(e)),e}var ys={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e[_s]=ms(i);let a=r||i.props&&i.props.type===`number`;Yo(e,t?`change`:`input`,t=>{t.target.composing||e[_s](vs(e.value,n,a))}),(n||a)&&Yo(e,`change`,()=>{e.value=vs(e.value,n,a)}),t||(Yo(e,`compositionstart`,hs),Yo(e,`compositionend`,gs),Yo(e,`change`,gs))},mounted(e,{value:t}){e.value=t??``},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:a}},o){if(e[_s]=ms(o),e.composing)return;let s=(a||e.type===`number`)&&!/^0\d/.test(e.value)?ce(e.value):e.value,c=t??``;if(s===c)return;let l=e.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===e&&e.type!==`range`&&(r&&t===n||i&&e.value.trim()===c)||(e.value=c)}},bs={deep:!0,created(e,t,n){e[_s]=ms(n),Yo(e,`change`,()=>{let t=e._modelValue,n=Ts(e),r=e.checked,i=e[_s];if(f(t)){let e=Se(t,n),a=e!==-1;if(r&&!a)i(t.concat(n));else if(!r&&a){let n=[...t];n.splice(e,1),i(n)}}else if(m(t)){let e=new Set(t);r?e.add(n):e.delete(n),i(e)}else i(Es(e,r))})},mounted:xs,beforeUpdate(e,t,n){e[_s]=ms(n),xs(e,t,n)}};function xs(e,{value:t,oldValue:n},r){e._modelValue=t;let i;if(f(t))i=Se(t,r.props.value)>-1;else if(m(t))i=t.has(r.props.value);else{if(t===n)return;i=xe(t,Es(e,!0))}e.checked!==i&&(e.checked=i)}var Ss={created(e,{value:t},n){e.checked=xe(t,n.props.value),e[_s]=ms(n),Yo(e,`change`,()=>{e[_s](Ts(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[_s]=ms(r),t!==n&&(e.checked=xe(t,r.props.value))}},Cs={deep:!0,created(e,{value:t,modifiers:{number:n}},r){e._modelValue=t,Yo(e,`change`,()=>{let t=Array.prototype.filter.call(e.options,e=>e.selected).map(e=>n?ce(Ts(e)):Ts(e));e[_s](e.multiple?m(e._modelValue)?new Set(t):t:t[0]),e._assigning=!0,jn(()=>{e._assigning=!1})}),e[_s]=ms(r)},mounted(e,{value:t}){ws(e,t)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[_s]=ms(n)},updated(e,{value:t}){e._assigning||ws(e,t)}};function ws(e,t){let n=e.multiple,r=f(t);if(!(n&&!r&&!m(t))){for(let i=0,a=e.options.length;i<a;i++){let a=e.options[i],o=Ts(a);if(n)if(r){let e=typeof o;a.selected=e===`string`||e===`number`?t.some(e=>String(e)===String(o)):Se(t,o)>-1}else a.selected=t.has(o);else if(xe(Ts(a),t)){e.selectedIndex!==i&&(e.selectedIndex=i);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Ts(e){return`_value`in e?e._value:e.value}function Es(e,t){let n=t?`_trueValue`:`_falseValue`;return n in e?e[n]:t}var Ds={created(e,t,n){ks(e,t,n,null,`created`)},mounted(e,t,n){ks(e,t,n,null,`mounted`)},beforeUpdate(e,t,n,r){ks(e,t,n,r,`beforeUpdate`)},updated(e,t,n,r){ks(e,t,n,r,`updated`)}};function Os(e,t){switch(e){case`SELECT`:return Cs;case`TEXTAREA`:return ys;default:switch(t){case`checkbox`:return bs;case`radio`:return Ss;default:return ys}}}function ks(e,t,n,r,i){let a=Os(e.tagName,n.props&&n.props.type)[i];a&&a(e,t,n,r)}var As=[`ctrl`,`shift`,`alt`,`meta`],js={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,t)=>As.some(n=>e[`${n}Key`]&&!t.includes(n))},X=(e,t)=>{if(!e)return e;let n=e._withMods||(e._withMods={}),r=t.join(`.`);return n[r]||(n[r]=((n,...r)=>{for(let e=0;e<t.length;e++){let r=js[t[e]];if(r&&r(n,t))return}return e(n,...r)}))},Ms={esc:`escape`,space:` `,up:`arrow-up`,left:`arrow-left`,right:`arrow-right`,down:`arrow-down`,delete:`backspace`},Ns=(e,t)=>{let n=e._withKeys||(e._withKeys={}),r=t.join(`.`);return n[r]||(n[r]=(n=>{if(!(`key`in n))return;let r=ne(n.key);if(t.some(e=>e===r||Ms[e]===r))return e(n)}))},Ps=c({patchProp:ss},so),Fs;function Is(){return Fs||(Fs=Zi(Ps))}var Ls=((...e)=>{Is().render(...e)}),Rs=((...e)=>{let t=Is().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Bs(e);if(!r)return;let i=t._component;!g(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,zs(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function zs(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Bs(e){return _(e)?document.querySelector(e):e}function Vs(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r?r.push(n):e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var r=e.get(t);r&&r.slice().map(function(e){e(n)}),(r=e.get(`*`))&&r.slice().map(function(e){e(t,n)})}}}var Hs={edit:`CatalogEditAction`,import:`CatalogImportAction`,export:`CatalogExportAction`,makeDefault:`CatalogMakeDefaultAction`,unmakeDefault:`CatalogUnmakeDefaultAction`,importAliases:`CatalogImportAliasesAction`,exportAliases:`CatalogExportAliasesAction`,copy:`CatalogCopyAction`,delete:`CatalogDeleteAction`,history:`CatalogHistoryAction`,createNew:`CatalogCreateNewAction`,productEdit:`ProductEditAction`,productCopy:`ProductCopyAction`,productDelete:`ProductDeleteAction`,errors:`Errors`,aliasCreateNew:`AliasCreateNewAction`,aliasEdit:`AliasEditAction`,aliasDelete:`AliasDeleteAction`,aliasImport:`AliasImport`,aliasExport:`AliasExport`},Us=(e,t)=>{if(e&&e.attributes&&t){let n=e.attributes[t];if(n&&n.values&&n.values[0])return n.values[0].text??``}return``},Ws=(e,t)=>{if(e&&e.attributes&&t){let n=e.attributes[t];if(n&&n.values&&n.values.length)return n.values.map(e=>e.text)}return[]},Gs=e=>{if(!e||e.length===0)return``;if(e.length==1)return e[0].text||``;let t=``;return e.forEach(e=>{t+=`<li>${e.text}</li>`}),`<ul>${t}</ul>`},Ks=e=>{let t=``;return!e||e.length===0||e.forEach((n,r)=>{t+=n.attributeName+(r<e.length-1?`, `:``)}),t},qs={key:1,class:`fw-bold text-muted`},Js={key:2,class:`text-muted small`},Ys=L({__name:`AliasCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item),r=Y(()=>Us(n.value,`#DisplayName`)),i=Y(()=>n.value.productType===t.ctx.catalogProductType.Listed||n.value.productType===t.ctx.CatalogProductTypeEnum.LISTED),a=Y(()=>n.value.productType===t.ctx.catalogProductType.Configured||n.value.productType===t.ctx.CatalogProductTypeEnum.CONFIGURED),o=Y(()=>i.value&&!n.value.inactive);return(t,n)=>(H(),U(V,null,[o.value?(H(),U(`a`,{key:0,href:``,class:`fw-bold`,onClick:n[0]||(n[0]=X(t=>e.ctx.details(e.ctx.item),[`prevent`]))},j(r.value),1)):(H(),U(`span`,qs,j(r.value),1)),a.value?(H(),U(`div`,Js,[G(`em`,null,j(e.ctx.t(`ConfiguredProducts`)),1)])):J(``,!0)],64))}}),Xs=L({__name:`AliasValuesCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item.aliases??[]);return(e,t)=>(H(!0),U(V,null,z(n.value,(e,t)=>(H(),U(`div`,{key:e.value??t,class:`text-bold`},j(e.value??``),1))),128))}}),Zs=L({__name:`CatalogDateCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>{let e=t.ctx.item.dateModified;return e?new Date(e).toLocaleString([],{dateStyle:`medium`}):``});return(e,t)=>(H(),U(`span`,null,j(n.value),1))}}),Qs={key:0,class:`text-muted small`},$s=L({__name:`CatalogDescriptionCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item);return(t,r)=>(H(),U(V,null,[G(`span`,null,j(n.value.description??``),1),n.value.shared?(H(),U(`div`,Qs,j(e.ctx.t(`SharedCatalogEditInSourceSystem`)),1)):J(``,!0)],64))}}),ec={key:1,class:`fw-bold text-muted`},tc={key:2,class:`text-muted small`},nc={key:1,class:`fw-bold text-muted`},rc=L({__name:`CatalogProductNameCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item),r=Y(()=>Us(n.value,`#DisplayName`)),i=Y(()=>n.value.productType===t.ctx.catalogProductType.Configured||n.value.productType===t.ctx.CatalogProductTypeEnum.CONFIGURED);return(t,a)=>(H(),U(V,null,[n.value.inactive?(H(),U(`span`,ec,j(r.value),1)):(H(),U(`a`,{key:0,href:``,class:`fw-bold`,onClick:a[0]||(a[0]=X(t=>e.ctx.details(e.ctx.item),[`prevent`]))},j(r.value),1)),i.value||n.value.customerClassification||n.value.baseProduct?(H(),U(`div`,tc,[i.value?(H(),U(V,{key:0},[G(`em`,null,j(e.ctx.t(`ConfiguredProducts`)),1),a[2]||(a[2]=G(`br`,null,null,-1))],64)):J(``,!0),n.value.customerClassification?(H(),U(V,{key:1},[G(`em`,null,j(e.ctx.t(`CustomerClassification`))+`:\xA0`+j(n.value.customerClassification),1),a[3]||(a[3]=G(`br`,null,null,-1))],64)):J(``,!0),n.value.baseProduct?(H(),U(V,{key:2},[G(`em`,null,[q(j(e.ctx.t(`BaseProductId`))+`:\xA0 `,1),n.value.baseProduct.inactive?(H(),U(`span`,nc,j(n.value.baseProduct.productId??``),1)):(H(),U(`a`,{key:0,href:``,onClick:a[1]||(a[1]=X(t=>e.ctx.baseProductDetails(e.ctx.item.baseProduct),[`prevent`]))},j(n.value.baseProduct.productId??``),1))]),a[4]||(a[4]=G(`br`,null,null,-1))],64)):J(``,!0)])):J(``,!0)],64))}}),ic=L({__name:`TranslatedSpan`,props:{ctx:{},translationKey:{default:void 0},useCommon:{type:Boolean,default:!0},translationNamespace:{default:`products`}},setup(e){let t=e,n=Y(()=>{let e=t.translationKey??t.ctx.col.caption;if(!e)return``;let n=t.ctx.t(e,t.useCommon);return n===`{${t.useCommon?`common`:t.translationNamespace}:${e}}`?t.ctx.col.caption??``:n});return(e,t)=>(H(),U(`span`,null,j(n.value),1))}});function ac(e,t){return L({name:`TranslatedSpanTemplate`,props:{ctx:{type:Object,required:!0}},setup(n){return()=>Qa(ic,{ctx:n.ctx,translationKey:e,useCommon:t===`common`,translationNamespace:t})}})}var oc=L({__name:`TranslatedMenuItem`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item.text);return(t,r)=>(H(),U(`span`,null,j(n.value?e.ctx.t(n.value):``),1))}});function sc(e){"@babel/helpers - typeof";return sc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},sc(e)}function cc(e,t){if(sc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(sc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function lc(e){var t=cc(e,`string`);return sc(t)==`symbol`?t:t+``}function Z(e,t,n){return(t=lc(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var uc=ac(`ColumnCode`,`catalogs`),dc=ac(`ColumnDescription`,`catalogs`),fc=ac(`ColumnLastModified`,`catalogs`),pc=ac(`ProductListProduct`,`common`),mc=ac(`ProductListInformation`,`common`),hc=ac(`Aliases`,`catalogs`),gc=oc,_c=$s,vc=Zs,yc=rc,bc=Ys,xc=Xs,Sc=Object.entries(Hs).reduce((e,[t,n])=>({...e,[t]:`internal:${n}`}),{}),Cc=class{constructor(){Z(this,`appSettings`,{appCode:``,langCode:`en`}),Z(this,`export`,{pricesEnabled:!1}),Z(this,`styles`,[]),Z(this,`components`,{search:{common:{actions:{catalogListMenu:{visible:!0,items:[{text:`New Catalog`,code:Sc.createNew,visible:!0,itemTemplate:gc},{text:`Import/Export History`,code:Sc.history,visible:!0,itemTemplate:gc}]},catalogItemMenu:{visible:!0,items:[{text:`Favorites`,code:Sc.makeDefault,visible:e=>e.editable&&!e.default,itemTemplate:gc},{text:`Favorites`,code:Sc.unmakeDefault,visible:e=>e.editable&&e.default,itemTemplate:gc},{text:`Edit`,code:Sc.edit,visible:e=>e.editable,itemTemplate:gc},{text:`Copy`,code:Sc.copy,visible:!0,itemTemplate:gc},{text:`Import`,code:Sc.import,visible:e=>e.editable,itemTemplate:gc},{text:`Export`,code:Sc.export,visible:!0,itemTemplate:gc},{text:`Delete`,code:Sc.delete,visible:e=>e.editable,itemTemplate:gc}]},productListMenu:{visible:!1},productItemMenu:{visible:!0,items:[{text:`Edit`,code:Sc.productEdit,visible:e=>{var t;return!!((t=e.catalogs)!=null&&t.every(e=>e.editable))},itemTemplate:gc},{text:`Copy`,code:Sc.productCopy,visible:!0,itemTemplate:gc},{text:`Delete`,code:Sc.productDelete,visible:e=>{var t;return!!((t=e.catalogs)!=null&&t.every(e=>e.editable))},itemTemplate:gc}]},aliasListMenu:{visible:!0,items:[{text:`Import`,code:Sc.aliasImport,visible:!0,itemTemplate:gc},{text:`Export`,code:Sc.aliasExport,visible:!0,itemTemplate:gc}]},aliasItemMenu:{visible:!0,items:[{code:Sc.aliasEdit,visible:!0,icon:`edit`},{code:Sc.aliasDelete,icon:`trash`,visible:e=>{var t;return!!((t=e.aliases)!=null&&t.length)}}]}}},form:{visible:!0,useAutocomplete:!0},toolbar:{pageSizes:[10,20,50,100],visible:!0},header:{visible:!0},table:{visible:!0,columns:[{caption:`ColumnCode`,width:`33%`,dataField:`code`,headerTemplate:uc},{caption:`ColumnDescription`,dataField:`description`,headerTemplate:dc,cellTemplate:_c},{caption:`ColumnLastModified`,dataField:`dateModified`,width:`140px`,headerTemplate:fc,cellTemplate:vc}]}},products:{search:{form:{visible:!0,useAutocomplete:!0},toolbar:{visible:!0,pageSizes:[12,24,48,72],subViews:[`table`,`list`,`grid`]},productCategories:{visible:!0,card:!0,icon:!0,maxCategoriesVisible:12},partCategories:{visible:!0,card:!0,icon:!0,maxCategoriesVisible:12},filters:{visible:!0,card:!0,icon:!0,maxFiltersVisible:10,expandedFromNodeLevel:2,visibleFromNodeLevel:0},filtersStatus:{visible:!0},selection:{visible:!1,deselectAllVisible:!0,selectAllVisible:!0,persist:!0,countVisible:!0},table:{selectable:!1,detailsVisible:!0,visible:!0,columns:[{caption:`ProductListProduct`,dataField:`#DisplayName`,width:`33%`,showAllIdentifiers:!0,headerTemplate:pc,cellTemplate:yc},{caption:`ProductListInformation`,dataField:`#Description`,headerTemplate:mc},{caption:`ColumnLastModified`,dataField:`dateModified`,width:`140px`,headerTemplate:fc,cellTemplate:vc}]},list:{imageSize:`10rem`,visible:!0,navigateOnContentClick:!0,imagePadding:0,selectable:!1,detailsVisible:!0,showAllIdentifiers:!0},grid:{visible:!0,navigateOnContentClick:!0,selectable:!1,detailsVisible:!0,showAllIdentifiers:!0},gridHorizontal:{visible:!0,navigateOnContentClick:!0,selectable:!1,detailsVisible:!0,showAllIdentifiers:!0,carousel:{mouseDrag:!0,touchDrag:!0,transition:300,wrapAround:!1,defaults:{itemsToShow:1,itemsToScroll:1,snapAlign:`center`,margin:5,navigationVisible:!0,paginationVisible:!0},breakpoints:{576:{itemsToShow:2,itemsToScroll:1,snapAlign:`start`,margin:2,navigationVisible:!0,paginationVisible:!1},922:{itemsToShow:4,itemsToScroll:1,snapAlign:`start`,margin:2,navigationVisible:!0,paginationVisible:!1}}}},breadcrumbs:{visible:!0}},preview:{view:{visible:!0}}},aliases:{search:{common:{},filters:{visible:!0},table:{selectable:!1,visible:!0,columns:[{caption:`ProductListProduct`,dataField:`#DisplayName`,headerTemplate:pc,cellTemplate:bc},{caption:`ProductListInformation`,dataField:`#Description`,headerTemplate:mc},{caption:`Aliases`,headerTemplate:hc,cellTemplate:xc},{caption:`ColumnLastModified`,dataField:`dateModified`,width:`140px`,headerTemplate:fc,cellTemplate:vc}]}}},common:{viewSwitch:{defaultView:`catalog`,views:[`catalog`,`product`]}}}),Z(this,`allowMobileView`,!0),Z(this,`cacheTranslations`,!0)}},wc=class{constructor(e){Z(this,`args`,void 0),Z(this,`isHandled`,!1),Z(this,`excludeFromUserActions`,!1),Z(this,`source`,void 0),this.args=e}from(e){return this.source=e,this}},Tc=class extends Error{constructor(){super(`Command handled by application commandInterceptor`),this.name=`CommandHandledError`}},Ec=e=>{var t;return!!(e!=null&&(t=e.store)!=null&&(t=t.options)!=null&&t.onUserAction)},Dc=new WeakMap;function Oc(e,t){let n=Dc.get(e);n?n.push(t):Dc.set(e,[t])}function kc(e){var t;(t=Dc.get(e))==null||t.pop()}function Ac(e){let t=Dc.get(e);return t!=null&&t.length?t[t.length-1]:void 0}function jc(e,t){Mc(e,{trigger:`api`,...t})}function Mc(e,t){var n;let r=e==null||(n=e.store)==null||(n=n.options)==null?void 0:n.onUserAction;if(r)try{r({schemaVersion:1,domain:e.instanceType.toLowerCase(),instanceId:e.id,timestamp:Date.now(),...t})}catch{}}function Nc(e,t,n){return{status:`success`,...e===void 0?{}:{totalCount:e,noResults:e===0},...t===void 0?{}:{itemsOnPage:t.length},...t!=null&&t.length?{exactMatch:t.some(e=>e.exactMatch)}:{},durationMs:n}}var Pc=e=>e instanceof Error&&e.name===`AbortError`;function Fc(e){if(typeof e!=`object`||!e||Array.isArray(e))return!1;let t=Object.getPrototypeOf(e);return t===Object.prototype||t===null}function Ic(e){if(Array.isArray(e))return e.map(Ic);if(Fc(e)){let t={};for(let n of Object.keys(e))t[n]=Ic(e[n]);return t}return e}function Lc(e,t,n){for(let r of Object.keys(t)){let i=t[r];if(i===void 0){n&&(e[r]=null);continue}Array.isArray(i)?e[r]=i:Fc(i)?Fc(e[r])?Lc(e[r],i,n):e[r]=Ic(i):e[r]=i}}function Rc(e,t){t&&Lc(e,t,!0)}function zc(e,t){Lc(e,t,!1)}function Bc(e,t,n,r){if(r!==void 0&&n!=null&&n(r)||e===t||typeof e==`number`&&typeof t==`number`&&Number.isNaN(e)&&Number.isNaN(t))return!0;if(Array.isArray(e)&&Array.isArray(t))return e.length===t.length&&e.every((e,r)=>Bc(e,t[r],n));if(Fc(e)&&Fc(t)){let r=Object.keys(e),i=Object.keys(t);return r.length===i.length&&r.every(r=>r in t&&Bc(e[r],t[r],n,r))}return!1}async function Vc(e,t,n=`ui`){let r=e.store.options.commandInterceptor,i=Date.now(),a=r=>{if(t.excludeFromUserActions||!Ec(e))return;let a;try{a=Ic(t.args)}catch{a=t.args}Mc(e,{kind:`interaction`,action:t.name,trigger:n,source:t.source,args:a,outcome:{status:r,durationMs:Date.now()-i}})};if(r){let{execute:n,excludeFromUserActions:i,source:o,...s}=t,c=Ic(s);try{await r(c)}catch{e.logger.log(`CommandBase cancelled`,t),a(`cancelled`);return}if(c.isHandled)return a(`handled-by-app`),Promise.reject(new Tc)}Oc(e,{action:t.name,source:t.source,trigger:n});try{let n=await(t==null?void 0:t.execute(e));return a(`success`),n}catch(e){return a(`error`),Promise.reject(e)}finally{kc(e)}}function Hc(e,t){return e?e(t):t}function Uc(e,t,n){let r=Hc(e,n);return r.isHandled||t.push({type:`danger`,message:r.message||`Unknown error`}),r}var Wc=(e,t)=>(Uc(e.store.options.errorInterceptor,e.store.notifications,{type:`CommandError`,message:`Command "${t}" should be handled by the application via commandInterceptor.`,isHandled:!1}),Promise.resolve()),Gc=class{constructor(e,t,n){Z(this,`instance`,void 0),Z(this,`registry`,void 0),Z(this,`domainLabel`,void 0),this.instance=e,this.registry=t,this.domainLabel=n}async execute(e,t=`ui`){return Vc(this.instance,e,t)}async executeCommand(e,...t){let n=this.registry[e];if(!n)throw Error(`[PIS] Unknown ${this.domainLabel} command "${String(e)}".`);let[r]=t;return this.execute(new n(r),`api`)}},Kc=async(e,t)=>{let n=document.createElement(`a`);n.href=t,n.download=e,n.click(),n.remove()},qc={bodySerializer:e=>JSON.stringify(e,(e,t)=>typeof t==`bigint`?t.toString():t)},Jc=Object.entries({$body_:`body`,$headers_:`headers`,$path_:`path`,$query_:`query`});function Yc(e,t){t||(t=new Map);for(let n of e)`in`in n?n.key&&t.set(n.key,{in:n.in,map:n.map}):`key`in n?t.set(n.key,{map:n.map}):n.args&&Yc(n.args,t);return t}function Xc(e){for(let[t,n]of Object.entries(e))t!==`body`&&n&&typeof n==`object`&&!Array.isArray(n)&&!Object.keys(n).length&&delete e[t]}function Zc(e,t){let n={headers:Object.create(null),path:Object.create(null),query:Object.create(null)},r=Yc(t);function i(e,t,r){let i=n[e];i===void 0&&(i=Object.create(null),n[e]=i),i[t]=r}let a;for(let[o,s]of e.entries())if(t[o]&&(a=t[o]),a)if(`in`in a)if(a.key){let e=r.get(a.key),t=e.map||a.key;e.in&&i(e.in,t,s)}else n.body=s;else for(let[e,t]of Object.entries(s??{})){let o=r.get(e);if(o)if(o.in){let n=o.map||e;i(o.in,n,t)}else n[o.map]=t;else{let n=Jc.find(([t])=>e.startsWith(t));if(n){let[r,a]=n;i(a,e.slice(r.length),t)}else if(`allowExtra`in a&&a.allowExtra){for(let[n,r]of Object.entries(a.allowExtra))if(r){i(n,e,t);break}}}}return Xc(n),n}function Qc({onRequest:e,onSseError:t,onSseEvent:n,responseTransformer:r,responseValidator:i,sseDefaultRetryDelay:a,sseMaxRetryAttempts:o,sseMaxRetryDelay:s,sseSleepFn:c,url:l,...u}){let d,f=c??(e=>new Promise(t=>setTimeout(t,e)));return{stream:async function*(){let c=a??3e3,p=0,m=u.signal??new AbortController().signal;for(;!m.aborted;){p++;let a=u.headers instanceof Headers?u.headers:new Headers(u.headers);d!==void 0&&a.set(`Last-Event-ID`,d);try{let t={redirect:`follow`,...u,body:u.serializedBody,headers:a,signal:m},o=new Request(l,t);e&&(o=await e(l,t));let s=await(u.fetch??globalThis.fetch)(o);if(!s.ok)throw Error(`SSE failed: ${s.status} ${s.statusText}`);if(!s.body)throw Error(`No body in SSE response`);let f=s.body.pipeThrough(new TextDecoderStream).getReader(),p=``,h=()=>{try{f.cancel()}catch{}};m.addEventListener(`abort`,h);try{for(;;){let{done:e,value:t}=await f.read();if(e)break;p+=t,p=p.replace(/\r\n?/g,`
2
+ `);let a=p.split(`
3
+
4
+ `);p=a.pop()??``;for(let e of a){let t=e.split(`
5
+ `),a=[],o;for(let e of t)if(e.startsWith(`data:`))a.push(e.replace(/^data:\s*/,``));else if(e.startsWith(`event:`))o=e.replace(/^event:\s*/,``);else if(e.startsWith(`id:`))d=e.replace(/^id:\s*/,``);else if(e.startsWith(`retry:`)){let t=Number.parseInt(e.replace(/^retry:\s*/,``),10);Number.isNaN(t)||(c=t)}let s,l=!1;if(a.length){let e=a.join(`
6
+ `);try{s=JSON.parse(e),l=!0}catch{s=e}}l&&(i&&await i(s),r&&(s=await r(s))),n==null||n({data:s,event:o,id:d,retry:c}),a.length&&(yield s)}}}finally{m.removeEventListener(`abort`,h),f.releaseLock()}break}catch(e){if(t==null||t(e),o!==void 0&&p>=o)break;let n=Math.min(c*2**(p-1),s??3e4);await f(n)}}}()}}var $c=e=>{switch(e){case`label`:return`.`;case`matrix`:return`;`;case`simple`:return`,`;default:return`&`}},el=e=>{switch(e){case`form`:return`,`;case`pipeDelimited`:return`|`;case`spaceDelimited`:return`%20`;default:return`,`}},tl=e=>{switch(e){case`label`:return`.`;case`matrix`:return`;`;case`simple`:return`,`;default:return`&`}},nl=({allowReserved:e,explode:t,name:n,style:r,value:i})=>{if(!t){let t=(e?i:i.map(e=>encodeURIComponent(e))).join(el(r));switch(r){case`label`:return`.${t}`;case`matrix`:return`;${n}=${t}`;case`simple`:return t;default:return`${n}=${t}`}}let a=$c(r),o=i.map(t=>r===`label`||r===`simple`?e?t:encodeURIComponent(t):rl({allowReserved:e,name:n,value:t})).join(a);return r===`label`||r===`matrix`?a+o:o},rl=({allowReserved:e,name:t,value:n})=>{if(n==null)return``;if(typeof n==`object`)throw Error("Deeply-nested arrays/objects aren’t supported. Provide your own `querySerializer()` to handle these.");return`${t}=${e?n:encodeURIComponent(n)}`},il=({allowReserved:e,explode:t,name:n,style:r,value:i,valueOnly:a})=>{if(i instanceof Date)return a?i.toISOString():`${n}=${i.toISOString()}`;if(r!==`deepObject`&&!t){let t=[];Object.entries(i).forEach(([n,r])=>{t=[...t,n,e?r:encodeURIComponent(r)]});let a=t.join(`,`);switch(r){case`form`:return`${n}=${a}`;case`label`:return`.${a}`;case`matrix`:return`;${n}=${a}`;default:return a}}let o=tl(r),s=Object.entries(i).map(([t,i])=>rl({allowReserved:e,name:r===`deepObject`?`${n}[${t}]`:t,value:i})).join(o);return r===`label`||r===`matrix`?o+s:s},al=/\{[^{}]+\}/g,ol=({path:e,url:t})=>{let n=t,r=t.match(al);if(r)for(let t of r){let r=!1,i=t.substring(1,t.length-1),a=`simple`;i.endsWith(`*`)&&(r=!0,i=i.substring(0,i.length-1)),i.startsWith(`.`)?(i=i.substring(1),a=`label`):i.startsWith(`;`)&&(i=i.substring(1),a=`matrix`);let o=e[i];if(o==null)continue;if(Array.isArray(o)){n=n.replace(t,nl({explode:r,name:i,style:a,value:o}));continue}if(typeof o==`object`){n=n.replace(t,il({explode:r,name:i,style:a,value:o,valueOnly:!0}));continue}if(a===`matrix`){n=n.replace(t,`;${rl({name:i,value:o})}`);continue}let s=encodeURIComponent(a===`label`?`.${o}`:o);n=n.replace(t,s)}return n},sl=({baseUrl:e,path:t,query:n,querySerializer:r,url:i})=>{let a=i.startsWith(`/`)?i:`/${i}`,o=(e??``)+a;t&&(o=ol({path:t,url:o}));let s=n?r(n):``;return s.startsWith(`?`)&&(s=s.substring(1)),s&&(o+=`?${s}`),o};function cl(e){let t=e.body!==void 0;if(t&&e.bodySerializer)return`serializedBody`in e?e.serializedBody!==void 0&&e.serializedBody!==``?e.serializedBody:null:e.body===``?null:e.body;if(t)return e.body}var ll=async(e,t)=>{let n=typeof t==`function`?await t(e):t;if(n)return e.scheme===`bearer`?`Bearer ${n}`:e.scheme===`basic`?`Basic ${btoa(n)}`:n},ul=({parameters:e={},...t}={})=>n=>{let r=[];if(n&&typeof n==`object`)for(let i in n){let a=n[i];if(a==null)continue;let o=e[i]||t;if(Array.isArray(a)){let e=nl({allowReserved:o.allowReserved,explode:!0,name:i,style:`form`,value:a,...o.array});e&&r.push(e)}else if(typeof a==`object`){let e=il({allowReserved:o.allowReserved,explode:!0,name:i,style:`deepObject`,value:a,...o.object});e&&r.push(e)}else{let e=rl({allowReserved:o.allowReserved,name:i,value:a});e&&r.push(e)}}return r.join(`&`)},dl=e=>{var t;if(!e)return`stream`;let n=(t=e.split(`;`)[0])==null?void 0:t.trim();if(n){if(n.startsWith(`application/json`)||n.endsWith(`+json`))return`json`;if(n===`multipart/form-data`)return`formData`;if([`application/`,`audio/`,`image/`,`video/`].some(e=>n.startsWith(e)))return`blob`;if(n.startsWith(`text/`))return`text`}},fl=(e,t)=>{var n,r;return t?!!(e.headers.has(t)||(n=e.query)!=null&&n[t]||(r=e.headers.get(`Cookie`))!=null&&r.includes(`${t}=`)):!1};async function pl(e){for(let t of e.security??[]){if(fl(e,t.name))continue;let n=await ll(t,e.auth);if(!n)continue;let r=t.name??`Authorization`;switch(t.in){case`query`:e.query||(e.query={}),e.query[r]=n;break;case`cookie`:e.headers.append(`Cookie`,`${r}=${n}`);break;default:e.headers.set(r,n)}}}var ml=e=>sl({baseUrl:e.baseUrl,path:e.path,query:e.query,querySerializer:typeof e.querySerializer==`function`?e.querySerializer:ul(e.querySerializer),url:e.url}),hl=(e,t)=>{var n;let r={...e,...t};return(n=r.baseUrl)!=null&&n.endsWith(`/`)&&(r.baseUrl=r.baseUrl.substring(0,r.baseUrl.length-1)),r.headers=_l(e.headers,t.headers),r},gl=e=>{let t=[];return e.forEach((e,n)=>{t.push([n,e])}),t},_l=(...e)=>{let t=new Headers;for(let n of e){if(!n)continue;let e=n instanceof Headers?gl(n):Object.entries(n);for(let[n,r]of e)if(r===null)t.delete(n);else if(Array.isArray(r))for(let e of r)t.append(n,e);else r!==void 0&&t.set(n,typeof r==`object`?JSON.stringify(r):r)}return t},vl=class{constructor(){Z(this,`fns`,[])}clear(){this.fns=[]}eject(e){let t=this.getInterceptorIndex(e);this.fns[t]&&(this.fns[t]=null)}exists(e){let t=this.getInterceptorIndex(e);return!!this.fns[t]}getInterceptorIndex(e){return typeof e==`number`?this.fns[e]?e:-1:this.fns.indexOf(e)}update(e,t){let n=this.getInterceptorIndex(e);return this.fns[n]?(this.fns[n]=t,e):!1}use(e){return this.fns.push(e),this.fns.length-1}},yl=()=>({error:new vl,request:new vl,response:new vl}),bl=ul({allowReserved:!1,array:{explode:!0,style:`form`},object:{explode:!0,style:`deepObject`}}),xl={"Content-Type":`application/json`},Sl=(e={})=>({...qc,headers:xl,parseAs:`auto`,querySerializer:bl,...e}),Cl=(e={})=>{let t=hl(Sl(),e),n=()=>({...t}),r=e=>(t=hl(t,e),n()),i=yl(),a=async e=>{let n={...t,...e,fetch:e.fetch??t.fetch??globalThis.fetch,headers:_l(t.headers,e.headers),serializedBody:void 0};n.security&&await pl(n),n.requestValidator&&await n.requestValidator(n),n.body!==void 0&&n.bodySerializer&&(n.serializedBody=n.bodySerializer(n.body)),(n.body===void 0||n.serializedBody===``)&&n.headers.delete(`Content-Type`);let r=n;return{opts:r,url:ml(r)}},o=async e=>{let n=e.throwOnError??t.throwOnError,r=e.responseStyle??t.responseStyle,o,s;try{let{opts:t,url:n}=await a(e),r={redirect:`follow`,...t,body:cl(t)};o=new Request(n,r);for(let e of i.request.fns)e&&(o=await e(o,t));let c=t.fetch;s=await c(o);for(let e of i.response.fns)e&&(s=await e(s,o,t));let l={request:o,response:s};if(s.ok){let e=(t.parseAs===`auto`?dl(s.headers.get(`Content-Type`)):t.parseAs)??`json`;if(s.status===204||s.headers.get(`Content-Length`)===`0`){let n;switch(e){case`arrayBuffer`:case`blob`:case`text`:n=await s[e]();break;case`formData`:n=new FormData;break;case`stream`:n=s.body;break;default:n={}}return t.responseStyle===`data`?n:{data:n,...l}}let n;switch(e){case`arrayBuffer`:case`blob`:case`formData`:case`text`:n=await s[e]();break;case`json`:{let e=await s.text();n=e?JSON.parse(e):{};break}case`stream`:return t.responseStyle===`data`?s.body:{data:s.body,...l}}return e===`json`&&(t.responseValidator&&await t.responseValidator(n),t.responseTransformer&&(n=await t.responseTransformer(n))),t.responseStyle===`data`?n:{data:n,...l}}let u=await s.text(),d;try{d=JSON.parse(u)}catch{}throw d??u}catch(t){let a=t;for(let t of i.error.fns)t&&(a=await t(a,s,o,e));if(a=a||{},n)throw a;return r===`data`?void 0:{error:a,request:o,response:s}}},s=e=>t=>o({...t,method:e}),c=e=>async t=>{let{opts:n,url:r}=await a(t);return Qc({...n,body:n.body,method:e,onRequest:async(e,t)=>{let r=new Request(e,t);for(let e of i.request.fns)e&&(r=await e(r,n));return r},serializedBody:cl(n),url:r})};return{buildUrl:e=>ml({...t,...e}),connect:s(`CONNECT`),delete:s(`DELETE`),get:s(`GET`),getConfig:n,head:s(`HEAD`),interceptors:i,options:s(`OPTIONS`),patch:s(`PATCH`),post:s(`POST`),put:s(`PUT`),request:o,setConfig:r,sse:{connect:c(`CONNECT`),delete:c(`DELETE`),get:c(`GET`),head:c(`HEAD`),options:c(`OPTIONS`),patch:c(`PATCH`),post:c(`POST`),put:c(`PUT`),trace:c(`TRACE`)},trace:s(`TRACE`)}},wl=Cl(Sl({baseUrl:`/PisWebApi`,throwOnError:!0})),Tl=class{static catalogsAcquireTokenForClient(e,t){let n=Zc([e],[{args:[{key:`authorizeCatalogUser`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/AcquireTokenForClient`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAdd(e,t){let n=Zc([e],[{args:[{key:`catalogAddAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Add`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAutocomplete(e,t){let n=Zc([e],[{args:[{key:`catalogAutocompleteQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Autocomplete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsCopy(e,t){let n=Zc([e],[{args:[{key:`catalogCopyAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Copy`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsCopyToNew(e,t){let n=Zc([e],[{args:[{key:`catalogCopyToNewAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/CopyToNew`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsDelete(e,t){let n=Zc([e],[{args:[{key:`catalogAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).delete({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Delete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsDownload(e,t){let n=Zc([e],[{args:[{in:`query`,key:`guid`}]}]);return((t==null?void 0:t.client)??wl).get({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Download`,...t,...n})}static catalogsExport(e,t){let n=Zc([e],[{args:[{key:`catalogExportAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Export`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsGet(e,t){let n=Zc([e],[{args:[{key:`catalogGetQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Get`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsImport(e,t){let n=Zc([e],[{args:[{key:`catalogImportAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Import`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsOptions(e,t){let n=Zc([e],[{args:[{key:`catalogOptionsQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Options`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsSearch(e,t){let n=Zc([e],[{args:[{key:`catalogSearchQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Search`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsUpdate(e,t){let n=Zc([e],[{args:[{key:`catalogUpdateAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).patch({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Update`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},El=class{static catalogsAliasesAdd(e,t){let n=Zc([e],[{args:[{key:`aliasAddAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/Add`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAliasesDelete(e,t){let n=Zc([e],[{args:[{key:`aliasDeleteAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).delete({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/Delete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAliasesDownload(e,t){let n=Zc([e],[{args:[{in:`query`,key:`guid`}]}]);return((t==null?void 0:t.client)??wl).get({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/Download`,...t,...n})}static catalogsAliasesExport(e,t){let n=Zc([e],[{args:[{key:`aliasExportAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/Export`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAliasesImport(e,t){let n=Zc([e],[{args:[{key:`aliasImportAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/Import`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAliasesList(e,t){let n=Zc([e],[{args:[{key:`aliasListQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/List`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsAliasesSynchronize(e,t){let n=Zc([e],[{args:[{key:`aliasSynchronizeAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Aliases/Synchronize`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Dl=class{static catalogsJobsCancel(e,t){let n=Zc([e],[{args:[{key:`jobAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Jobs/Cancel`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsJobsDownload(e,t){let n=Zc([e],[{args:[{in:`query`,key:`guid`}]}]);return((t==null?void 0:t.client)??wl).get({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Jobs/Download`,...t,...n})}static catalogsJobsExport(e,t){let n=Zc([e],[{args:[{key:`jobAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Jobs/Export`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsJobsSearch(e,t){let n=Zc([e],[{args:[{key:`jobSearchQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Jobs/Search`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Ol=class{static catalogsProductsAdd(e,t){let n=Zc([e],[{args:[{key:`catalogProductAddAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Add`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsAddConfiguration(e,t){let n=Zc([e],[{args:[{key:`configurationAddAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/AddConfiguration`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsAddQuantity(e,t){let n=Zc([e],[{args:[{key:`quantityAddAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/AddQuantity`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsAutocomplete(e,t){let n=Zc([e],[{args:[{key:`catalogProductAutocompleteQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Autocomplete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsCopyQuantity(e,t){let n=Zc([e],[{args:[{key:`quantityCopyAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/CopyQuantity`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsCopyQuantityToNew(e,t){let n=Zc([e],[{args:[{key:`quantityCopyToNewAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/CopyQuantityToNew`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsCount(e,t){let n=Zc([e],[{args:[{key:`catalogProductCountQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Count`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsDelete(e,t){let n=Zc([e],[{args:[{key:`catalogProductDeleteAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).delete({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Delete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsDeleteConfiguration(e,t){let n=Zc([e],[{args:[{key:`configurationDeleteAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).delete({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/DeleteConfiguration`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsDeleteQuantity(e,t){let n=Zc([e],[{args:[{key:`quantityDeleteAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).delete({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/DeleteQuantity`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsFilters(e,t){let n=Zc([e],[{args:[{key:`catalogProductFiltersQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Filters`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsFilterValues(e,t){let n=Zc([e],[{args:[{key:`catalogProductFilterValuesQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/FilterValues`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsGetConfiguration(e,t){let n=Zc([e],[{args:[{key:`configurationGetQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/GetConfiguration`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsSearch(e,t){let n=Zc([e],[{args:[{key:`catalogProductSearchQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Search`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsUpdate(e,t){let n=Zc([e],[{args:[{key:`catalogProductUpdateAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).patch({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/Update`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsUpdateConfiguration(e,t){let n=Zc([e],[{args:[{key:`configurationUpdateAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).patch({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/UpdateConfiguration`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static catalogsProductsUpdateQuantity(e,t){let n=Zc([e],[{args:[{key:`quantityUpdateAction`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).patch({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Catalogs/Products/UpdateQuantity`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},kl=class{static classificationsBrowserAutocomplete(e,t){let n=Zc([e],[{args:[{key:`classificationsBrowserAutocompleteQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Browser/Autocomplete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static classificationsBrowserChildren(e,t){let n=Zc([e],[{args:[{key:`classificationsBrowserChildrenQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Browser/Children`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static classificationsBrowserSearch(e,t){let n=Zc([e],[{args:[{key:`classificationsBrowserSearchQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Browser/Search`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static classificationsBrowserValidate(e,t){let n=Zc([e],[{args:[{key:`classificationsBrowserValidateQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Browser/Validate`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Al=class{static classificationsNodes(e,t){let n=Zc([e],[{args:[{key:`classificationNodesQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Nodes`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static classificationsParents(e,t){let n=Zc([e],[{args:[{key:`classificationParentsQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Parents`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static classificationsTree(e,t){let n=Zc([e],[{args:[{key:`classificationQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Classifications/Tree`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},jl=class{static favoriteViewsDelete(e,t){let n=Zc([e],[{args:[{key:`favoriteViewDeleteQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/FavoriteViews/Delete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static favoriteViewsLoad(e,t){let n=Zc([e],[{args:[{key:`favoriteViewsQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/FavoriteViews/Load`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static favoriteViewsSave(e,t){let n=Zc([e],[{args:[{key:`favoriteViewSaveQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/FavoriteViews/Save`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Ml=class{static imagesGetByClassificationCids(e,t){let n=Zc([e],[{args:[{key:`imageByClassificationCidsQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Images/GetByClassificationCids`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static imagesGetByImageIds(e,t){let n=Zc([e],[{args:[{key:`imageByImageIdsQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Images/GetByImageIds`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static imagesGetByProductIds(e,t){let n=Zc([e],[{args:[{key:`imageByProductIdsQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Images/GetByProductIds`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Nl=class{static autocomplete(e,t){let n=Zc([e],[{args:[{key:`autocompleteQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Autocomplete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static compare(e,t){let n=Zc([e],[{args:[{key:`compareQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Compare`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static count(e,t){let n=Zc([e],[{args:[{key:`countQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Count`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static detail(e,t){let n=Zc([e],[{args:[{key:`detailQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Detail`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static filters(e,t){let n=Zc([e],[{args:[{key:`filtersQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Filters`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static filterValues(e,t){let n=Zc([e],[{args:[{key:`filterValueQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/FilterValues`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static list(e,t){let n=Zc([e],[{args:[{key:`listQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/List`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static pdfDownload(e,t){let n=Zc([e],[{args:[{in:`query`,key:`guid`}]}]);return((t==null?void 0:t.client)??wl).get({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Pdf/Download`,...t,...n})}static pdfGenerate(e,t){let n=Zc([e],[{args:[{key:`pdfQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Pdf/Generate`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static preview(e,t){let n=Zc([e],[{args:[{key:`previewQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Preview`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static relationshipAutocomplete(e,t){let n=Zc([e],[{args:[{key:`prmAutocompleteQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/RelationshipAutocomplete`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static relationshipFilters(e,t){let n=Zc([e],[{args:[{key:`prmFiltersQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/RelationshipFilters`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static relationshipFilterValues(e,t){let n=Zc([e],[{args:[{key:`prmFilterValueQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/RelationshipFilterValues`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static relationships(e,t){let n=Zc([e],[{args:[{key:`prmQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Relationships`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static search(e,t){let n=Zc([e],[{args:[{key:`searchQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Search`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}static variantsTable(e,t){let n=Zc([e],[{args:[{key:`productVariantsTableQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Products/Variants/Table`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Pl=class{static translations(e,t){let n=Zc([e],[{args:[{key:`translationQuery`,map:`body`}]}]);return((t==null?void 0:t.client)??wl).post({responseStyle:`data`,security:[{key:`User`,scheme:`bearer`,type:`http`},{key:`Application`,scheme:`bearer`,type:`http`}],url:`/v2/Translations`,...t,...n,headers:{"Content-Type":`application/json`,...t==null?void 0:t.headers,...n.headers}})}},Fl=function(e){return e.ALL=`All`,e.BLANK=`Blank`,e.POPULATED=`Populated`,e}({}),Il=function(e){return e.MERGE=`Merge`,e.FIRST_FOUND=`FirstFound`,e.FLAT=`Flat`,e}({}),Ll=function(e){return e.TEXT=`Text`,e.ENUM=`Enum`,e.TABLE=`Table`,e.NOT_APPLICABLE=`NotApplicable`,e.POPULATED=`Populated`,e}({}),Rl=function(e){return e.PRODUCT_CLASSIFICATIONS=`ProductClassifications`,e.PART_CLASSIFICATIONS=`PartClassifications`,e.PRODUCTS=`Products`,e.FILTERS=`Filters`,e.BREADCRUMBS=`Breadcrumbs`,e}({}),zl=function(e){return e.WITH_ALL_WORDS=`WithAllWords`,e.WITH_AT_LEAST_ONE_WORD=`WithAtLeastOneWord`,e.EXACT_PHRASE=`ExactPhrase`,e}({}),Bl=function(e){return e.LAST_IMPORT=`LastImport`,e.PRODUCT=`Product`,e.ALIAS=`Alias`,e.LAST_MODIFIED=`LastModified`,e.HIERARCHICAL=`Hierarchical`,e}({}),Vl=function(e){return e.LISTED=`Listed`,e.UNLISTED=`Unlisted`,e.CONFIGURED=`Configured`,e}({}),Hl=function(e){return e.CATALOG_CODE_AND_DESCRIPTION=`CatalogCodeAndDescription`,e.CREATED_BY=`CreatedBy`,e.CATALOG_CODE=`CatalogCode`,e}({}),Ul=function(e){return e.LAST_MODIFIED=`LastModified`,e.CODE=`Code`,e.DESCRIPTION=`Description`,e}({}),Wl=function(e){return e.COMPANY=`Company`,e.PERSONAL=`Personal`,e}({}),Gl=function(e){return e.OFFERING=`Offering`,e.PRODUCT_LINE=`ProductLine`,e}({}),Kl=function(e){return e.OFFERING=`Offering`,e.PRODUCT_LINE=`ProductLine`,e.FAVORITES=`Favorites`,e.OFFERING_AND_PRODUCT_LINE=`OfferingAndProductLine`,e}({}),ql=function(e){return e.AND=`And`,e.OR=`Or`,e}({}),Jl=function(e){return e.IN=`In`,e.HAS_VALUE=`HasValue`,e}({}),Yl=function(e){return e.PRODUCT_DETAILS=`ProductDetails`,e.PRODUCT_CLASSIFICATIONS=`ProductClassifications`,e.ATTRIBUTE_GROUPS=`AttributeGroups`,e.PRODUCT_RELATIONSHIPS=`ProductRelationships`,e.RELATED_LINKS=`RelatedLinks`,e.PRODUCT_VARIANTS_SELECTOR=`ProductVariantsSelector`,e.PRODUCT_VARIANTS_TABLE=`ProductVariantsTable`,e.PRODUCT_VARIANTS_DROPDOWN=`ProductVariantsDropdown`,e.EXTENDED_OBJECT_DATA=`ExtendedObjectData`,e.BREADCRUMBS=`Breadcrumbs`,e.RELATED_PRODUCTS=`RelatedProducts`,e}({}),Xl=function(e){return e.CATALOG=`Catalog`,e.JOB_TYPE=`JobType`,e.JOB_STATUS=`JobStatus`,e.LAST_MODIFIED=`LastModified`,e}({}),Zl=function(e){return e.IN_QUEUE=`InQueue`,e.RUNNING=`Running`,e.SUCCESS=`Success`,e.ERROR=`Error`,e.CANCELLED=`Cancelled`,e.CANCELLING=`Cancelling`,e}({}),Ql=function(e){return e.NONE=`None`,e.DETAIL=`Detail`,e.SEARCH=`Search`,e.CLASSIFICATION=`Classification`,e.DOCUMENT=`Document`,e.TECHNICAL_INFORMATION=`TechnicalInformation`,e}({}),$l=function(e){return e.ALL=`All`,e.STANDARD=`Standard`,e.EXCHANGE=`Exchange`,e.REPAIR=`Repair`,e.NEW_ADDITION=`NewAddition`,e.PREVENTATIVE_MAINTENANCE_KIT=`PreventativeMaintenanceKit`,e}({}),eu=function(e){return e.ALL=`All`,e.ACCESSORIES=`Accessories`,e.ALTERNATIVE_SELL=`AlternativeSell`,e.CONSISTS_OF=`ConsistsOf`,e.CROSS_SELL=`CrossSell`,e.DEVICE_TYPE_CODE=`DeviceTypeCode`,e.DEVICE_TYPE_LIST=`DeviceTypeList`,e.KIT_CONTENTS=`KitContents`,e.SOFTWARE_LIST=`SoftwareList`,e.UP_SELL=`UpSell`,e.SPARE_PART_SELECTION_LIST=`SparePartSelectionList`,e.SPARE_PART_USED_ON_LIST=`SparePartUsedOnList`,e.SUPER_CODE_BO_M=`SuperCodeBoM`,e.WHERE_USED=`WhereUsed`,e.ENHANCED_SPARE_PART_FILTERS=`EnhancedSparePartFilters`,e.VARIANTS=`Variants`,e}({}),tu=function(e){return e.NON_APPLICABLE=`NonApplicable`,e.VALID=`Valid`,e.INVALID=`Invalid`,e}({}),nu=function(e){return e.CLASSIFICATIONS=`Classifications`,e.PRODUCTS=`Products`,e.FILTERS=`Filters`,e.BREADCRUMBS=`Breadcrumbs`,e.CONFIGURATORS=`Configurators`,e.MASTER_PRODUCTS=`MasterProducts`,e.PART_TYPES=`PartTypes`,e}({}),ru=function(e){return e.WITH_ALL_WORDS=`WithAllWords`,e.WITH_AT_LEAST_ONE_WORD=`WithAtLeastOneWord`,e.EXACT_PHRASE=`ExactPhrase`,e.SPARE_PART_MASTER_IDENTIFIER=`SparePartMasterIdentifier`,e.HIERARCHICAL=`Hierarchical`,e}({}),iu=function(e){return e.ASCENDING=`Ascending`,e.DESCENDING=`Descending`,e}({}),au=function(e){return e.PRODUCT=`Product`,e.RELEVANCE=`Relevance`,e}({}),ou=function(e){return e.PRODUCTS=`Products`,e.PARTS=`Parts`,e}({}),su=function(e){return e.DROPDOWN=`Dropdown`,e.PILLS=`Pills`,e.IMAGES=`Images`,e}({}),cu=()=>({type:`group`,condition:ql.AND,rules:[]}),lu=({h:e,v:t,u:n})=>JSON.stringify([e??null,t,n??null]),uu=e=>{let[t,n,r]=JSON.parse(e);return{...t===null?{}:{h:t},v:n,...r===null?{}:{u:r}}},du=(e,t)=>lu(e)===lu(t),fu=e=>((e==null?void 0:e.rules)??[]).flatMap(e=>e.type===`group`?fu(e):[e]),pu=e=>({type:`group`,condition:ql.AND,rules:Object.entries(e).flatMap(([e,t])=>{let n=Object.entries(t).filter(([,e])=>e).map(([e])=>uu(e));return n.length?[{type:`attribute`,code:e,operator:Jl.IN,values:n}]:[]})}),mu=(e,t,n)=>{let r=(e.rules??[]).flatMap(e=>{if(e.type===`group`){let r=mu(e,t,n);return r.rules.length?[{...r,type:`group`}]:[]}if(e.code!==t||!e.values)return[e];let r=e.values.filter(e=>!du(e,n));return r.length?[{...e,values:r}]:[]});return{...e,rules:r}},hu=e=>e===Bl.LAST_MODIFIED?iu.DESCENDING:iu.ASCENDING,gu=class extends wc{},_u=class extends gu{constructor(...e){super(...e),Z(this,`name`,`details`),Z(this,`execute`,async e=>Wc(e,this.name))}},vu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-filter-search`),Z(this,`execute`,async e=>{var t;let n={view:`catalogs`,catalogs:{searchType:this.args.searchType,searchText:this.args.searchText,pagination:{page:1}}};return await((t=e.router)==null?void 0:t.setRoute(n))})}},yu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-filter-search`),Z(this,`execute`,async e=>{var t;let n={...e.router.routeData.products,searchType:this.args.searchType,searchText:this.args.searchText,pagination:{...e.router.routeData.products.pagination,page:1}};return this.args.resetCategories&&(n.cid=void 0,n.treeType=void 0),this.args.resetFilters&&(n.filters=void 0),await((t=e.router)==null?void 0:t.setRoute({...e.router.routeData,products:n}))})}},bu=async(e,t=!0)=>{var n,r,i,a,o,s;return(n=e.router)==null?void 0:n.setRouteForced({...(r=e.router)==null?void 0:r.routeData,view:`catalogs`,products:{...(i=e.router)==null?void 0:i.routeData.products,aliases:void 0},catalogs:{...(a=e.router)==null?void 0:a.routeData.catalogs,searchType:t||(o=e.router)==null?void 0:o.routeData.catalogs.searchType,searchText:t||(s=e.router)==null?void 0:s.routeData.catalogs.searchText,pagination:{page:1}}})},xu=async(e,t=!1)=>{var n,r,i,a,o,s;let c=e.router.routeData.view===`products`?(n=e.router)==null?void 0:n.routeData.products.sortField:Bl.LAST_IMPORT;return(!c||![Bl.LAST_IMPORT,Bl.LAST_MODIFIED,Bl.PRODUCT].includes(c))&&(c=Bl.LAST_IMPORT),(r=e.router)==null?void 0:r.setRouteForced({...(i=e.router)==null?void 0:i.routeData,view:`products`,products:{...(a=e.router)==null?void 0:a.routeData.products,sortField:c,sortDirection:hu(c),searchText:void 0,cid:t||(o=e.router)==null?void 0:o.routeData.products.cid,filters:void 0,catalogId:t||(s=e.router)==null?void 0:s.routeData.products.catalogId,pagination:{page:1},aliases:void 0}})},Su=async(e,t=!1)=>{var n,r,i,a,o;let s=(e.router.routeData.view===`aliases`?e.router.routeData.products.sortField:Bl.ALIAS)||Bl.ALIAS;return(n=e.router)==null?void 0:n.setRouteForced({...(r=e.router)==null?void 0:r.routeData,view:`aliases`,products:{...(i=e.router)==null?void 0:i.routeData.products,searchText:void 0,cid:t||(a=e.router)==null?void 0:a.routeData.products.cid,filters:void 0,catalogId:t||(o=e.router)==null?void 0:o.routeData.products.catalogId,pagination:{page:1},aliases:t?Fl.ALL:e.router.routeData.products.aliases,sortField:s,sortDirection:hu(s)}})},Cu=async(e,t,n)=>{if(!n){e.store.data.isLoadingData=!1;return}try{var r,i;e.store.data.isLoadingData=!0;let a=await n;if(e.store.data.isLoadingData=!1,a!=null&&(r=a.errors)!=null&&r.length||a!=null&&(i=a.warnings)!=null&&i.length){await e.execute(new Dd({errors:a.errors||[],warnings:a.warnings||[]}));return}if(a&&a.success===!0)await e.execute(new pd({type:`success`,message:t.onSuccessMessage}));else throw Error((a==null?void 0:a.message)||`Unknown error`);if(a&&a.success===!0)return a}catch(t){throw e.store.data.isLoadingData=!1,await e.execute(new pd({type:`danger`,message:t.message})),t}},wu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs`),Z(this,`execute`,async e=>bu(e,!1))}},Tu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products`),Z(this,`execute`,async e=>xu(e,!0))}},Eu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`aliases`),Z(this,`execute`,async e=>Su(e,!0))}},Du=class extends gu{constructor(...e){super(...e),Z(this,`name`,`aliases-reload`),Z(this,`execute`,async e=>Su(e,!1))}},Ou=class extends gu{constructor(...e){super(...e),Z(this,`name`,`aliases-filter`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({products:{aliases:this.args.aliasFilter}}))})}},ku=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-products`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({view:`products`,products:{searchText:void 0,cid:void 0,filters:void 0,catalogId:this.args.catalogId,pagination:{page:1,pageSize:e.getRouteData().products.pagination.pageSize}}}))})}},Au=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-filter-classification`),Z(this,`execute`,async e=>{var t;let n=e.getRouteData();return n.products.pagination.page=1,n.products.cid=this.args.cid,n.products.treeType=this.args.treeType,this.args.clearSearch&&(n.products.searchText=void 0),await((t=e.router)==null?void 0:t.setRoute(n))})}},ju=class extends gu{constructor(...e){super(...e),Z(this,`name`,`product-preview`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.preview(this.args.productId))})}},Mu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-filter-parametric-apply`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({view:`products`,products:{filters:this.args.filters,pagination:{page:1,pageSize:e.router.routeData.products.pagination.pageSize}}}))})}},Nu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-filter-parametric-remove`),Z(this,`execute`,async e=>{var t;let n=e.router.routeData.products.filters?mu(e.router.routeData.products.filters,this.args.attributeCode,this.args.value):void 0;return await((t=e.router)==null?void 0:t.setRoute({products:{filters:n,pagination:{page:1,pageSize:e.router.routeData.products.pagination.pageSize}}}))})}},Pu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-get-filter-values`),Z(this,`execute`,async e=>{var t;let n=e.getRouteData();return await((t=e.httpService)==null?void 0:t.filterValues(this.args.attributeCodes,n.products.catalogId))})}},Fu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-get-autocomplete`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.autocomplete(this.args.searchText))})}},Iu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-get-autocomplete`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.autocompleteCatalogs(this.args.searchText))})}},Lu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-sub-view`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({products:{subView:this.args.subView}}))})}},Ru=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-page-size`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({products:{pagination:{pageSize:this.args.pageSize,page:1}}}))})}},zu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-page-size`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({catalogs:{pagination:{pageSize:this.args.pageSize,page:1}}}))})}},Bu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-sort-by`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({products:{sortField:this.args.sortField,sortDirection:hu(this.args.sortField)}}))})}},Vu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`products-paginate`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({products:{pagination:{page:this.args.page}}}))})}},Hu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-paginate`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({catalogs:{pagination:{page:this.args.page}}}))})}},Uu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-update-product`),Z(this,`execute`,async e=>{var t;return Cu(e,this.args,(t=e.httpService)==null?void 0:t.updateCatalogProduct(this.args.product,this.args.catalogId))})}},Wu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-copy-product`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.copyCatalogProduct(this.args.sourceCatalogId,this.args.sourceQuantityIds,this.args.targetCatalogId)),xu(e)})}},Gu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-copy-product`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.copyCatalogProductToNew(this.args.sourceCatalogId,this.args.sourceQuantityIds,this.args.code,this.args.type,this.args.description)),xu(e)})}},Ku=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-sort-by`),Z(this,`execute`,async e=>{var t;let n={catalogs:{sortField:this.args.sortField,sortDirection:this.args.sortField==Ul.LAST_MODIFIED?iu.DESCENDING:iu.ASCENDING}};return await((t=e.router)==null?void 0:t.setRoute(n))})}},qu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-filter-by-date`),Z(this,`execute`,async e=>{var t;let n={catalogs:{createdWithinLastDays:this.args.days===void 0||this.args.days===null?void 0:Number(this.args.days)}};return await((t=e.router)==null?void 0:t.setRoute(n))})}},Ju=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-job-history-download`),Z(this,`execute`,async e=>{var t;return(t=e.httpService)==null?void 0:t.downloadJobHistory(this.args.sortSettings)})}},Yu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-configured-products`),Z(this,`execute`,async e=>{var t;return(t=e.httpService)==null?void 0:t.getConfigurationOption(this.args.configurationId,this.args.catalogId)})}},Xu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-job-download`),Z(this,`execute`,async e=>{var t;let n=await Cu(e,this.args,(t=e.httpService)==null?void 0:t.exportJobHistory(this.args.jobId));if(!n||!n.guid)throw Error(`Job download error`);let r=`${e.getOptions().baseUrl}/v2/Catalogs/Jobs/Download?guid=${n.guid}`;await Kc(`Export Job ${this.args.jobId}-${n.guid}.pdf`,r),e.eventBus.emit(`job-download-done`,r)})}},Zu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-job-cancel`),Z(this,`execute`,e=>{var t;return Cu(e,this.args,(t=e.httpService)==null?void 0:t.cancelJob(this.args.jobId))})}},Qu=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-import`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.importCatalog(this.args.catalogId,this.args.file,this.args.fileName)),bu(e)})}},$u=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-export`),Z(this,`execute`,async e=>{var t;let n=await Cu(e,this.args,(t=e.httpService)==null?void 0:t.exportCatalog(this.args.catalogId,this.args.priceSettings));if(!n)throw Error(`Catalog export error`);if(n&&n.guid&&n.type===`Download`){let t=`Export ${this.args.catalogCode}.pdf`,r=`${e.getOptions().baseUrl}/v2/Catalogs/Download?guid=${n.guid}`;return await Kc(t,r),e.eventBus.emit(`catalog-export-done`,r),!1}return!0})}},ed=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-create-new`),Z(this,`execute`,async e=>{var t,n;let r=await Cu(e,this.args,(t=e.httpService)==null?void 0:t.addCatalog(this.args.code,this.args.type,this.args.description));return r==null||(n=r.catalog)==null?void 0:n.id})}},td=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-get-options`),Z(this,`execute`,async e=>{var t;return(t=e.httpService)==null?void 0:t.getCatalogOptions()})}},nd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-update`),Z(this,`execute`,async e=>{var t;await Cu(e,this.args,(t=e.httpService)==null?void 0:t.updateCatalog(this.args.catalogId,this.args.description))})}},rd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-copy`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.copyCatalog(this.args.sourceCatalogId,this.args.targetCatalogId)),bu(e)})}},id=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-copy-to-new`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.copyToNewCatalog(this.args.sourceCatalogId,this.args.code,this.args.type,this.args.description)),bu(e)})}},ad=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-delete`),Z(this,`execute`,async e=>{var t;await Cu(e,this.args,(t=e.httpService)==null?void 0:t.deleteCatalog(this.args.catalogId)),await bu(e)})}},od=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-set-default`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.updateDefaultCatalog(this.args.catalogId,!0)),bu(e)})}},sd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-remove-default`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.updateDefaultCatalog(this.args.catalogId,!1)),bu(e)})}},cd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-product-delete`),Z(this,`execute`,async e=>{var t;await Cu(e,this.args,(t=e.httpService)==null?void 0:t.deleteCatalogProduct(this.args.products,this.args.catalogId)),await xu(e)})}},ld=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-import-aliases`),Z(this,`execute`,async e=>{var t;return await Cu(e,this.args,(t=e.httpService)==null?void 0:t.importCatalogAliases(this.args.file,this.args.fileName)),Su(e)})}},ud=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-export-aliases`),Z(this,`execute`,async e=>{var t;let n=await Cu(e,this.args,(t=e.httpService)==null?void 0:t.exportCatalogAliases());if(!n)throw Error(`Catalog aliases export error`);if(n&&n.guid){let t=`Export aliases ${n.guid}.pdf`,r=`${e.getOptions().baseUrl}/v2/Catalogs/Aliases/Download?guid=${n.guid}`;return await Kc(t,r),e.eventBus.emit(`catalog-export-aliases-done`,r),!1}return!0})}},dd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-add-aliases`),Z(this,`execute`,async e=>{var t;if(this.args.doNotHandleErrors===!0){let t;try{var n;e.store.data.isLoadingData=!0,t=await((n=e.httpService)==null?void 0:n.addAliases(this.args.aliases))}catch{}return e.store.data.isLoadingData=!1,t}return Cu(e,this.args,(t=e.httpService)==null?void 0:t.addAliases(this.args.aliases))})}},fd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-delete-aliases`),Z(this,`execute`,async e=>{var t;if(this.args.doNotHandleErrors===!0){let t;try{var n;e.store.data.isLoadingData=!0,t=await((n=e.httpService)==null?void 0:n.deleteAliases(this.args.aliases))}catch{}return e.store.data.isLoadingData=!1,t}return Cu(e,this.args,(t=e.httpService)==null?void 0:t.deleteAliases(this.args.aliases))})}},pd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`notification-show`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>{let t=0,n=this.args.dismissAfter;e.store.notifications.length&&(e.store.notifications=[],t=1e3),!n&&n!==0&&this.args.type!==`danger`&&(n=6e3,e.store.notifications=[]),n&&n!==0&&setTimeout(()=>{let t=e.store.notifications.indexOf(this.args);t!==-1&&e.store.notifications.splice(t,1)},this.args.dismissAfter),setTimeout(()=>e.store.notifications.push(this.args),t)})}},md=class extends gu{constructor(...e){super(...e),Z(this,`name`,`notification-hide`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>{let t=e.store.notifications.indexOf(this.args);t!==-1&&e.store.notifications.splice(t,1)})}},hd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-action-completed`),Z(this,`execute`,async e=>Object.assign(e.store.data.actions,{current:null,data:null}))}},gd=async(e,t,n)=>Object.assign(e.store.data.actions,{current:t,data:n}),_d=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-edit-action`),Z(this,`execute`,async e=>gd(e,Hs.edit,this.args))}},vd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-copy-action`),Z(this,`execute`,async e=>gd(e,Hs.copy,this.args))}},yd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-import-action`),Z(this,`execute`,async e=>gd(e,Hs.import,this.args))}},bd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-export-action`),Z(this,`execute`,async e=>gd(e,Hs.export,this.args))}},xd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-delete-action`),Z(this,`execute`,async e=>gd(e,Hs.delete,this.args))}},Sd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-history-action`),Z(this,`execute`,async e=>gd(e,Hs.history,this.args))}},Cd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-new-action`),Z(this,`execute`,async e=>gd(e,Hs.createNew,this.args))}},wd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-product-edit-action`),Z(this,`execute`,async e=>gd(e,Hs.productEdit,this.args))}},Td=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-product-copy-action`),Z(this,`execute`,async e=>gd(e,Hs.productCopy,this.args))}},Ed=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-product-delete-action`),Z(this,`execute`,async e=>gd(e,Hs.productDelete,this.args))}},Dd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-errors-action`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>gd(e,Hs.errors,this.args))}},Od=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-create-new-action`),Z(this,`execute`,async e=>gd(e,Hs.aliasCreateNew,this.args))}},kd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-edit-action`),Z(this,`execute`,async e=>gd(e,Hs.aliasEdit,this.args))}},Ad=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-delete-action`),Z(this,`execute`,async e=>gd(e,Hs.aliasDelete,this.args))}},jd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-import-action`),Z(this,`execute`,async e=>gd(e,Hs.aliasImport,this.args))}},Md=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-export-action`),Z(this,`execute`,async e=>gd(e,Hs.aliasExport,this.args))}},Nd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalogs-fetch`),Z(this,`execute`,async e=>{var t;let n=await((t=e.httpService)==null?void 0:t.getAllCatalogs());return!n||!n.items?[]:n.items})}},Pd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-fetch-by-id`),Z(this,`execute`,async e=>{var t;return(t=e.httpService)==null?void 0:t.getCatalogById(this.args.catalogId)})}},Fd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-list-action`),Z(this,`execute`,async e=>Wc(e,this.name))}},Id=class extends gu{constructor(...e){super(...e),Z(this,`name`,`catalog-item-action`),Z(this,`execute`,async e=>Wc(e,this.name))}},Ld=class extends gu{constructor(...e){super(...e),Z(this,`name`,`product-list-action`),Z(this,`execute`,async e=>Wc(e,this.name))}},Rd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`product-item-action`),Z(this,`execute`,async e=>Wc(e,this.name))}},zd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-list-action`),Z(this,`execute`,async e=>Wc(e,this.name))}},Bd=class extends gu{constructor(...e){super(...e),Z(this,`name`,`alias-item-action`),Z(this,`execute`,async e=>Wc(e,this.name))}},Vd=class extends Gc{constructor(e){super(e,Hd,`catalogs`)}},Hd={details:_u,"catalogs-filter-search":vu,"products-filter-search":yu,catalogs:wu,products:Tu,aliases:Eu,"aliases-reload":Du,"aliases-filter":Ou,"catalog-products":ku,"products-filter-classification":Au,"product-preview":ju,"products-filter-parametric-apply":Mu,"products-filter-parametric-remove":Nu,"products-get-filter-values":Pu,"products-get-autocomplete":Fu,"catalogs-get-autocomplete":Iu,"products-sub-view":Lu,"products-page-size":Ru,"catalogs-page-size":zu,"products-sort-by":Bu,"products-paginate":Vu,"catalogs-paginate":Hu,"catalog-update-product":Uu,"catalog-copy-product":Wu,"catalogs-sort-by":Ku,"catalogs-filter-by-date":qu,"catalogs-job-history-download":Ju,"catalog-configured-products":Yu,"catalogs-job-download":Xu,"catalogs-job-cancel":Zu,"catalog-import":Qu,"catalog-export":$u,"catalog-create-new":ed,"catalog-get-options":td,"catalog-update":nd,"catalog-copy":rd,"catalog-copy-to-new":id,"catalog-delete":ad,"catalog-set-default":od,"catalog-remove-default":sd,"catalog-product-delete":cd,"catalog-import-aliases":ld,"catalog-export-aliases":ud,"catalog-add-aliases":dd,"catalog-delete-aliases":fd,"notification-show":pd,"notification-hide":md,"catalog-action-completed":hd,"catalog-edit-action":_d,"catalog-copy-action":vd,"catalog-import-action":yd,"catalog-export-action":bd,"catalog-delete-action":xd,"catalog-history-action":Sd,"catalog-new-action":Cd,"catalog-product-edit-action":wd,"catalog-product-copy-action":Td,"catalog-product-delete-action":Ed,"catalog-errors-action":Dd,"alias-create-new-action":Od,"alias-edit-action":kd,"alias-delete-action":Ad,"alias-import-action":jd,"alias-export-action":Md,"catalogs-fetch":Nd,"catalog-fetch-by-id":Pd,"catalog-list-action":Fd,"catalog-item-action":Id,"product-list-action":Ld,"product-item-action":Rd,"alias-list-action":zd,"alias-item-action":Bd},Ud={ProductClassifications:Rl.PRODUCT_CLASSIFICATIONS,PartClassifications:Rl.PART_CLASSIFICATIONS,Filters:Rl.FILTERS,Breadcrumbs:Rl.BREADCRUMBS,Catalogs:`Catalogs`,Products:`Products`,ProductPreview:`ProductPreview`,Translations:`Translations`,Notifications:`Notifications`},Wd=class{constructor(e){Z(this,`instance`,void 0),this.instance=e}async setData(e,t){if(t===void 0){this.dispatchLoadEvent({type:e,data:void 0,instance:this.instance});return}let n=this.dataInterceptor(),r={type:e,data:Ut(t),instance:this.instance};n?this.dispatchLoadEvent(await n(r)):this.dispatchLoadEvent(r)}},Gd=new class{log(e,t){t?(console.group(`[LOGGER]`),console.log(e),console.log(t),console.groupEnd()):console.log(`[LOGGER]`,e)}},Kd={[Ud.Catalogs]:(e,t)=>{e.catalogs=t},[Ud.ProductPreview]:(e,t)=>{e.productPreview=t},[Ud.Products]:(e,t)=>{e.products=t},[Ud.ProductClassifications]:(e,t)=>{e.productClassifications=t},[Ud.PartClassifications]:(e,t)=>{e.partClassifications=t},[Ud.Filters]:(e,t)=>{e.filters=t},[Ud.Breadcrumbs]:(e,t)=>{e.breadcrumbs=t},[Ud.Translations]:(e,t)=>{Gd.log(`Setting store data not handled`,{type:Ud.Translations,data:t})},[Ud.Notifications]:(e,t)=>{Gd.log(`Setting store data not handled`,{type:Ud.Notifications,data:t})}},qd=class extends Wd{constructor(e){super(e)}dataInterceptor(){var e;return(e=this.instance.store)==null?void 0:e.options.dataInterceptor}dispatchLoadEvent(e){this.setStoreData(e)}setStoreData({type:e,data:t}){if(!this.instance.store)return;let n=Kd[e];n(this.instance.store.data,t)}};function Jd(e,t){return typeof e==`string`&&e.length>0?e:t}var Yd=Object.freeze({version:Jd(`7.0.0-dev.20260916-153034`,`0.0.0-unknown`),revision:Jd(`unknown`,`unknown`),builtAt:Jd(`unknown`,`unknown`)});Yd.version;var Xd=!1;function Zd(){return Yd.version&&Yd.version!==`0.0.0-unknown`?Yd.version:(Xd||(Xd=!0,console.warn(`[PIS] Component-Version header will be "unknown": the build did not stamp a version into BUILD_INFO. Rebuild from the published pipeline.`)),`unknown`)}var Qd=6e4;function $d(e){if(typeof AbortSignal.timeout==`function`)return AbortSignal.timeout(e);let t=new AbortController;return setTimeout(()=>{t.abort(new DOMException(`signal timed out`,`TimeoutError`))},e),t.signal}function ef(e){let t=e.filter(e=>e!=null);if(t.length===0)return null;if(typeof AbortSignal.any==`function`)return AbortSignal.any(t);let n=new AbortController,r=e=>n.abort(e.reason);for(let e of t){if(e.aborted)return r(e),n.signal;e.addEventListener(`abort`,()=>r(e),{once:!0})}return n.signal}function tf(e){return ef([e,$d(Qd)])}function nf(e,t,n){let r=Cl({baseUrl:t,responseStyle:`data`,throwOnError:!0});return r.interceptors.request.use(t=>{var r;let i=(r=e.store)==null||(r=r.options)==null?void 0:r.accessToken;t.headers.set(`Authorization`,`Bearer ${i||n}`),t.headers.set(`Component-Version`,Zd()),e.props.dashboard===!0&&t.headers.set(`dashboard`,`true`);let a=tf(t.signal);return a===t.signal?t:new Request(t,{signal:a})}),r.interceptors.error.use((t,n)=>{if(t instanceof DOMException&&t.name===`AbortError`)return t;let r=n&&typeof t==`object`&&t?t:void 0,i={type:(r==null?void 0:r.Type)??`ServerError`,message:(r==null?void 0:r.Message)??(t==null?void 0:t.message),isHandled:!1};if(r!=null&&r.TraceId&&(i.traceId=r.TraceId),e.store.options.errorInterceptor){let t=e.store.options.errorInterceptor(i);t.isHandled||e.store.notifications.push({type:`danger`,message:t.message||`Unknown error`})}else e.store.notifications.push({type:`danger`,message:i.message||`Unknown error`});return t}),r}async function rf(e,t,n){let r=t===!0&&typeof window<`u`;if(r)try{let t=window.sessionStorage.getItem(e);if(t)return JSON.parse(t)}catch{}let i=await n();if(r&&i)try{window.sessionStorage.setItem(e,JSON.stringify(i))}catch{}return i}var af=class{async loadImages(e){try{var t;return await Ml.imagesGetByProductIds({imageByProductIdsQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{productIds:e}}},{client:this.client})}catch(e){this.instance.logger.log(`Failed to fetch images`,e)}}async loadImagesById(e){try{var t;return await Ml.imagesGetByImageIds({imageByImageIdsQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{imageIds:e}}},{client:this.client})}catch(e){this.instance.logger.log(`Failed to fetch images`,e)}}async loadClassificationsNodes(e){var t;return await Al.classificationsNodes({classificationNodesQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{cids:e}}},{client:this.client})}async fetchTranslations(e,t){var n;let r=this.instance.store.options.cacheTranslations,i=((n=this.instance.store.options.appSettings)==null?void 0:n.langCode)??`en`;return await rf(e+`-`+i,r,async()=>{var e;let n={appSettings:(e=this.instance.store)==null?void 0:e.options.appSettings,domains:[]};if(t&&this.instance.store.options.httpInterceptor)try{let e=await this.instance.store.options.httpInterceptor({body:n,url:t,method:`post`});if(e)return e}catch{}return await Pl.translations({translationQuery:n},{client:this.client})})}},of=`pis-catalogs-translations`,sf=class extends af{constructor(e,t,n){super(),Z(this,`instance`,void 0),Z(this,`instanceType`,`Catalogs`),Z(this,`storeService`,void 0),Z(this,`client`,void 0),Z(this,`_lastFilterLoad`,{key:``,count:0}),this.instance=e,this.client=nf(e,t,n),this.storeService=new qd(e)}async load(e,t){if(!this.instance.router)return;let n=e||this.instance.router.routeData;switch(n.view){case`catalogs`:return await this.queryCatalogs(n);case`products`:return await this.queryProducts(n,t,!0);case`aliases`:return await this.queryProducts(n,t);default:throw Error(`Unknown view type "${n.view}" to be handled by HttpService`)}}async queryCatalogs({catalogs:e}){let{action:t,source:n,trigger:r=`ui`}=Ac(this.instance)??{};this.instance.store.data.isLoadingData=!0;let i=Date.now(),a=i=>Mc(this.instance,{kind:`search`,action:`search`,trigger:r,origin:t??`route`,...n?{source:n}:{},args:{searchText:e.searchText??null,searchType:e.searchType??null,page:e.pagination.page,pageSize:e.pagination.pageSize},outcome:i});try{var o;let t=await Tl.catalogsSearch({catalogSearchQuery:{appSettings:(o=this.instance.store)==null?void 0:o.options.appSettings,pager:{page:e.pagination.page,pageSize:e.pagination.pageSize},search:{searchText:e.searchText??void 0,searchType:e.searchType??Hl.CATALOG_CODE_AND_DESCRIPTION,createdWithinLastDays:e.createdWithinLastDays},sort:{field:e.sortField??Ul.LAST_MODIFIED,direction:e.sortDirection??iu.DESCENDING}}},{client:this.client});a(Nc(t.totalCount,t.items,Date.now()-i)),this.instance.eventBus.emit(`search-loaded`,t),t&&this.storeService.setData(Ud.Catalogs,t),this.instance.store.data.isLoadingData=!1,this.instance.eventBus.emit(`search-changed`)}catch(e){throw this.instance.store.data.isLoadingData=!1,a({status:`error`,durationMs:Date.now()-i}),e}}async queryProducts({view:e,products:t},n,r){let{action:i,source:a,trigger:o=`ui`}=Ac(this.instance)??{};this.instance.store.data.isLoadingData=!0;let s=Date.now(),c=e=>{var n;return Mc(this.instance,{kind:`search`,action:`search`,trigger:o,origin:i??`route`,...a?{source:a}:{},args:{searchText:t.searchText??null,searchType:t.searchType??null,cid:t.cid??null,catalogId:t.catalogId??null,page:t.pagination.page,pageSize:t.pagination.pageSize,appliedFilterCount:((n=t.filters)==null||(n=n.rules)==null?void 0:n.length)??0},outcome:e})},l=n?[Rl.PRODUCTS]:[Rl.PRODUCTS,Rl.BREADCRUMBS,Rl.PRODUCT_CLASSIFICATIONS,Rl.PART_CLASSIFICATIONS];!n&&r===!0&&l.push(Rl.FILTERS);try{var u,d,f,p;let r=await Ol.catalogsProductsSearch({catalogProductSearchQuery:{appSettings:(u=this.instance.store)==null?void 0:u.options.appSettings,pager:{page:t.pagination.page,pageSize:t.pagination.pageSize},search:{searchText:t.searchText??void 0,searchType:t.searchType??zl.WITH_ALL_WORDS,cid:t.cid,treeType:t.treeType,catalogId:t.catalogId,filter:t.filters,aliases:e==`aliases`?t.aliases??Fl.ALL:void 0},sort:{field:t.sortField??Bl.LAST_IMPORT,direction:t.sortDirection??iu.ASCENDING},dataTypes:l,maxProductImages:(d=this.instance.store.options.components)==null||(d=d.search)==null||(d=d.common)==null?void 0:d.maxProductImages}},{client:this.client});this.instance.eventBus.emit(`search-loaded`,r),c(Nc((f=r.products)==null?void 0:f.totalCount,(p=r.products)==null?void 0:p.items,Date.now()-s)),r.products&&this.storeService.setData(Ud.Products,r.products),n||(this.storeService.setData(Ud.ProductClassifications,r.productClassifications),this.storeService.setData(Ud.PartClassifications,r.partClassifications),this.storeService.setData(Ud.Filters,r.filters),this.storeService.setData(Ud.Breadcrumbs,r.breadcrumbs)),this.instance.store.data.isLoadingData=!1,this.instance.eventBus.emit(`search-changed`)}catch(e){throw this.instance.store.data.isLoadingData=!1,c({status:`error`,durationMs:Date.now()-s}),e}}async preview(e){this.instance.store.data.isLoadingData=!0;try{var t,n,r;let i=await Nl.preview({previewQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{productId:e,cid:(n=this.instance.getRouteData().products)==null?void 0:n.cid,filter:(r=this.instance.getRouteData().products)==null?void 0:r.filters}}},{client:this.client});this.instance.eventBus.emit(`preview-loaded`,i),i&&this.storeService.setData(Ud.ProductPreview,i),this.instance.store.data.isLoadingData=!1}catch(e){throw this.instance.store.data.isLoadingData=!1,e}}async filterValues(e,t){var n;let{products:r}=this.instance.router.routeData;return await Ol.catalogsProductsFilterValues({catalogProductFilterValuesQuery:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,search:{cid:r.cid,treeType:r.treeType,searchText:r.searchText,searchType:r.searchType||zl.WITH_ALL_WORDS,attributeCodes:e,filter:r.filters,catalogId:t}}},{client:this.client})}async loadTranslations(){var e;let t=await this.fetchTranslations(of),n=(e=this.instance.store)==null?void 0:e.options.dataInterceptor,r={type:Ud.Translations,data:Ut({items:t}),instance:this.instance};if(n){var i;let e=await n(r);return e.type===`Translations`?(i=e.data)==null?void 0:i.items:t}return t}async autocomplete(e){var t;let{action:n,source:r,trigger:i=`ui`}=Ac(this.instance)??{},{products:a}=this.instance.router.routeData,o=(t=this.instance.store.options.components)==null||(t=t.products)==null||(t=t.search)==null?void 0:t.form,s=Date.now(),c;try{var l;c=await Ol.catalogsProductsAutocomplete({catalogProductAutocompleteQuery:{appSettings:(l=this.instance.store)==null?void 0:l.options.appSettings,pager:{page:1,pageSize:5},search:{cid:a.cid,aliases:a.aliases,treeType:a.treeType,searchType:a.searchType||zl.WITH_ALL_WORDS,searchText:e??void 0,filter:a.filters,catalogId:a.catalogId},fetchProductImages:o==null?void 0:o.showProductImages}},{client:this.client})}catch(t){throw Mc(this.instance,{kind:`autocomplete`,action:`autocomplete`,trigger:i,...n?{origin:n}:{},...r?{source:r}:{},args:{searchText:e},outcome:{status:`error`,durationMs:Date.now()-s}}),t}return Mc(this.instance,{kind:`autocomplete`,action:`autocomplete`,trigger:i,...n?{origin:n}:{},...r?{source:r}:{},args:{searchText:e},outcome:Nc(c.totalCount,c.items,Date.now()-s)}),c}async autocompleteCatalogs(e){let{action:t,source:n,trigger:r=`ui`}=Ac(this.instance)??{},{catalogs:i}=this.instance.router.routeData,a=Date.now(),o;try{var s;o=await Tl.catalogsAutocomplete({catalogAutocompleteQuery:{appSettings:(s=this.instance.store)==null?void 0:s.options.appSettings,pager:{page:1,pageSize:5},search:{searchType:i.searchType||Hl.CATALOG_CODE_AND_DESCRIPTION,searchText:e??void 0}}},{client:this.client})}catch(i){throw Mc(this.instance,{kind:`autocomplete`,action:`autocomplete-catalogs`,trigger:r,...t?{origin:t}:{},...n?{source:n}:{},args:{searchText:e},outcome:{status:`error`,durationMs:Date.now()-a}}),i}return Mc(this.instance,{kind:`autocomplete`,action:`autocomplete-catalogs`,trigger:r,...t?{origin:t}:{},...n?{source:n}:{},args:{searchText:e},outcome:Nc(o.totalCount,o.items,Date.now()-a)}),o}async loadFiltersResultCount(e){var t;let{products:n}=this.instance.router.routeData,r={appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{cid:n.cid,treeType:n.treeType,searchType:n.searchType||zl.WITH_ALL_WORDS,searchText:n.searchText,filter:e,catalogId:n.catalogId}},i=JSON.stringify(r);if(this._lastFilterLoad.key==i)return Promise.resolve({totalCount:this._lastFilterLoad.count});let a=await Ol.catalogsProductsCount({catalogProductCountQuery:r},{client:this.client});return this._lastFilterLoad.key=i,this._lastFilterLoad.count=a.totalCount,a}async exportCatalog(e,t){var n;return Tl.catalogsExport({catalogExportAction:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,catalogId:e,priceSettings:t}},{client:this.client})}async downloadCatalog(e){return Tl.catalogsDownload({guid:e},{client:this.client})}async importCatalog(e,t,n){var r;return Tl.catalogsImport({catalogImportAction:{appSettings:(r=this.instance.store)==null?void 0:r.options.appSettings,catalogId:e,fileContentBase64:t,fileName:n}},{client:this.client})}async copyCatalog(e,t){var n;return Tl.catalogsCopy({catalogCopyAction:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,sourceCatalogId:e,targetCatalogId:t}},{client:this.client})}async copyToNewCatalog(e,t,n,r){var i;return Tl.catalogsCopyToNew({catalogCopyToNewAction:{appSettings:(i=this.instance.store)==null?void 0:i.options.appSettings,sourceCatalogId:e,code:t,type:n,description:r}},{client:this.client})}async addCatalog(e,t,n){var r;return Tl.catalogsAdd({catalogAddAction:{appSettings:(r=this.instance.store)==null?void 0:r.options.appSettings,description:n,code:e,type:t}},{client:this.client})}async updateCatalog(e,t,n){var r,i;let a=await Tl.catalogsUpdate({catalogUpdateAction:{appSettings:(r=this.instance.store)==null?void 0:r.options.appSettings,catalogId:e,description:t,default:n}},{client:this.client}),o=((i=this.instance.store.data.catalogs)==null?void 0:i.items)||[],s=o.find(t=>t.id===e);return s&&(s.description=t,(n===!0||n===!1)&&(s.default=n)),this.storeService.setData(Ud.Catalogs,{items:o,totalCount:o.length}),a}async getCatalogOptions(){var e;return Tl.catalogsOptions({catalogOptionsQuery:{appSettings:(e=this.instance.store)==null?void 0:e.options.appSettings}},{client:this.client})}async updateDefaultCatalog(e,t){var n;return Tl.catalogsUpdate({catalogUpdateAction:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,catalogId:e,default:t}},{client:this.client})}async deleteCatalog(e){var t,n;let r=await Tl.catalogsDelete({catalogAction:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,catalogId:e}},{client:this.client}),i=(((n=this.instance.store.data.catalogs)==null?void 0:n.items)||[]).filter(t=>t.id!==e);return this.storeService.setData(Ud.Catalogs,{items:i,totalCount:i.length}),r}async downloadJobHistory(e){var t;return Dl.catalogsJobsSearch({jobSearchQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,sort:e||void 0}},{client:this.client})}async exportJobHistory(e){var t;return Dl.catalogsJobsExport({jobAction:{jobId:e,appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings}},{client:this.client})}async cancelJob(e){var t;return Dl.catalogsJobsCancel({jobAction:{jobId:e,appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings}},{client:this.client})}async getConfigurationOption(e,t){var n;return await Ol.catalogsProductsGetConfiguration({configurationGetQuery:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,id:e,catalogId:t}},{client:this.client})}async importCatalogAliases(e,t){var n;return El.catalogsAliasesImport({aliasImportAction:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,fileContentBase64:e,fileName:t}},{client:this.client})}async exportCatalogAliases(){var e;return El.catalogsAliasesExport({aliasExportAction:{appSettings:(e=this.instance.store)==null?void 0:e.options.appSettings}},{client:this.client})}async updateCatalogProduct(e,t){var n,r,i;let a=await Ol.catalogsProductsUpdate({catalogProductUpdateAction:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,products:[e],catalogId:t}},{client:this.client}),o=(r=this.instance.store.data.products)==null?void 0:r.totalCount,s=[...((i=this.instance.store.data.products)==null?void 0:i.items)||[]].reduce((n,r)=>{if(r.productId===e.productId){var i;let n=Object.values(r.attributes).find(e=>e.attributeCode===`#Description`);n&&(n.values=[{text:e.description||``}]),Object.assign(r,{customerClassification:e.customerClassification,baseProductId:e.baseProductId,customFields:e.customFields}),(i=r.catalogs)==null||i.forEach(n=>{if(n.id===t){var r;(r=n.quantities)==null||r.forEach(t=>{t.unitOfMeasure===e.unitOfMeasure&&(t.value=e.quantity)})}})}return n.concat([r])},[]);return this.storeService.setData(Ud.Products,{totalCount:o,items:s}),a}async deleteCatalogProduct(e,t){var n,r,i;let a=await Ol.catalogsProductsDelete({catalogProductDeleteAction:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,catalogId:t,products:e}},{client:this.client}),o=this.instance.store.data.catalogs,s=this.instance.store.data.products,c=(s==null||(r=s.items)==null?void 0:r.filter(n=>{var r,i;let a=n.productId,o=(r=n.catalogs)==null?void 0:r.find(e=>e.id===t);return!o||!((i=o.quantities)!=null&&i.map(e=>e.unitOfMeasure))||!e.find(e=>e.productId===a)}))||[],l=(o==null?void 0:o.items)||[],u=l.find(e=>e.id===t);u&&(u.productsTotalCount=Math.abs(u.productsTotalCount-e.length));let d=Math.abs(((s==null||(i=s.items)==null?void 0:i.length)||0)-c.length);return this.storeService.setData(Ud.Catalogs,{items:l,totalCount:(o==null?void 0:o.totalCount)||0}),this.storeService.setData(Ud.Products,{items:c,totalCount:((s==null?void 0:s.totalCount)||0)-d}),a}async copyCatalogProduct(e,t,n){var r;return Ol.catalogsProductsCopyQuantity({quantityCopyAction:{appSettings:(r=this.instance.store)==null?void 0:r.options.appSettings,sourceCatalogId:e,sourceQuantityIds:t,targetCatalogId:n}},{client:this.client})}async copyCatalogProductToNew(e,t,n,r,i){var a;return Ol.catalogsProductsCopyQuantityToNew({quantityCopyToNewAction:{appSettings:(a=this.instance.store)==null?void 0:a.options.appSettings,sourceCatalogId:e,sourceQuantityIds:t,code:n,type:r,description:i}},{client:this.client})}async getAllCatalogs(){var e;return Tl.catalogsSearch({catalogSearchQuery:{appSettings:(e=this.instance.store)==null?void 0:e.options.appSettings,pager:{page:1,pageSize:1e3}}},{client:this.client})}async getCatalogById(e){var t;return Tl.catalogsGet({catalogGetQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,catalogId:e}},{client:this.client})}async addAliases(e){var t;return El.catalogsAliasesAdd({aliasAddAction:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,aliases:e}},{client:this.client})}async deleteAliases(e){var t;return El.catalogsAliasesDelete({aliasDeleteAction:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,aliases:e}},{client:this.client})}},cf={view:`catalogs`,catalogs:{searchText:void 0,searchType:Hl.CATALOG_CODE_AND_DESCRIPTION,pagination:{page:1,pageSize:10},sortField:Ul.LAST_MODIFIED,sortDirection:iu.DESCENDING},products:{searchText:void 0,searchType:zl.WITH_ALL_WORDS,cid:void 0,treeType:void 0,filters:void 0,pagination:{page:1,pageSize:12},subView:`table`,sortField:Bl.LAST_IMPORT,sortDirection:iu.DESCENDING}};function lf(e,t){let n=e.page;n!==null&&(e.page=parseInt(n,10),isNaN(e.page)&&(e.page=t==null?void 0:t.page));let r=e.pageSize;r!==null&&(e.pageSize=parseInt(r,10),isNaN(e.pageSize)&&(e.pageSize=t==null?void 0:t.pageSize))}function uf(e,t){for(let n of Object.keys(t)){let r=t[n];if(r!=null){if(Fc(r)){Fc(e[n])?uf(e[n],r):(e[n]===void 0||e[n]===null)&&(e[n]=Ic(r));continue}(e[n]===void 0||e[n]===null)&&(e[n]=Ic(r))}}}var df=class{constructor(e){Z(this,`instance`,void 0),Z(this,`routeData`,Ut(Ic(cf))),Z(this,`history`,[]),this.instance=e}async setRoute(e,t=!1){return this.setRouteInternal(e,{passive:t})}async setRouteForced(e){return this.setRouteInternal(e,{force:!0})}async setRouteInternal(e,t){let n=Ic(this.routeData);if(e){var r,i;if((r=e.products)!=null&&r.pagination){var a;lf(e.products.pagination,(a=this.routeData.products)==null?void 0:a.pagination)}if((i=e.catalogs)!=null&&i.pagination){var o;lf(e.catalogs.pagination,(o=this.routeData.catalogs)==null?void 0:o.pagination)}Rc(n,e),uf(n,cf)}if(!t.force&&this.history.length>0&&Bc(n,Ic(this.routeData)))return;let s=!1;if(!t.passive&&!t.force&&this.history.length>1&&n.view==`products`){let e=this.history[this.history.length-1];s=Bc(e,n,e=>e===`subView`)}if(s){this.commitRoute(n);return}let c=!1;if(!t.passive&&!t.force&&this.history.length>1&&n.view==`products`){let e=this.history[this.history.length-1];c=Bc(e.products,n.products,e=>e===`page`||e===`pageSize`)}this.instance.store.data.isInitialized&&this.instance.httpService&&(t.passive||await this.instance.httpService.load(n,c)),this.commitRoute(n)}async reload(){var e;await((e=this.instance.httpService)==null?void 0:e.load(this.routeData))}commitRoute(e){this.history.push({...e}),Rc(this.routeData,e),this.instance.eventBus.emit(`route-changed`,Ic(this.routeData))}async back(e=1){let t=this.history.length-e-1,n=this.history[t];n&&this.history.splice(t),this.setRoute(n??cf)}};function ff(e){return typeof e==`object`&&!!e}function pf(e){return`setup`in e||`render`in e||`template`in e||`mount`in e||`unmount`in e||`__vccOpts`in e}function mf(e){if(!ff(e)||Array.isArray(e))return!1;let t=e,n=Object.getPrototypeOf(e);return(n===Object.prototype||n===null)&&!pf(t)}function hf(e,t){return zc(e,t),e}function gf(e){let t=new WeakMap,n=new WeakMap,r=e=>ff(e)?n.get(e)??e:e,i=e=>{let a=t.get(e);if(a)return a;let o=new Proxy(e,{get(e,t,n){let r=Reflect.get(e,t,n);return mf(r)?i(r):r},set(e,t,n){let i=Reflect.get(e,t),a=r(n);return mf(i)&&mf(a)?(hf(i,a),!0):Reflect.set(e,t,a)}});return t.set(e,o),n.set(o,e),o};return i(e)}function _f(e){let t=Vs();return e.on(`*`,(e,n)=>{e.toString().startsWith(`internal:`)||t.emit(e,n)}),t}var vf=class{constructor(e){Z(this,`instance`,void 0),Z(this,`trackSelectionPaused`,!1),Z(this,`select`,e=>{let t=this.instance.eventBus;if(!this.data||!(e!=null&&e.length))return;let n=[];e.forEach(e=>{if(e&&e.productId&&!this.isSelected(e)){var t;(t=this.data)==null||t.set(e.productId,e),n.push(e)}}),n.length&&(t.emit(`selection-changed`,{added:n,removed:[],selected:this.selectedItems}),this.trackSelection(n,[]))}),Z(this,`deselect`,e=>{let t=this.instance.eventBus;if(!this.data||!(e!=null&&e.length))return;let n=[];e.forEach(e=>{if(e&&e.productId&&this.isSelected(e)){var t;(t=this.data)==null||t.delete(e.productId),n.push(e)}}),n.length&&(t.emit(`selection-changed`,{added:[],removed:n,selected:this.selectedItems}),this.trackSelection([],n))}),Z(this,`toggle`,e=>{this.isSelected(e)?this.deselect([e]):this.select([e])}),Z(this,`clear`,()=>{var e;let t=this.instance.eventBus;if(!this.data)return;let n=this.selectedItems;(e=this.data)==null||e.clear(),n.length&&(t.emit(`selection-changed`,{added:[],removed:n,selected:this.selectedItems}),this.trackSelection([],n))}),Z(this,`isSelected`,e=>this.data?this.data.has(e.productId):!1),this.instance=e,e.store.data.selectedItems||(e.store.data.selectedItems=new Map),e.on(`search-loaded`,()=>{var t,n;if(!(e.instanceType===`Products`?(t=e.store.options.components)!=null&&(t=t.search)!=null&&(t=t.selection)!=null&&t.persist:(n=e.store.options.components)!=null&&(n=n.products)!=null&&(n=n.search)!=null&&(n=n.selection)!=null&&n.persist)){this.trackSelectionPaused=!0;try{this.clear()}finally{this.trackSelectionPaused=!1}}})}trackSelection(e,t){this.trackSelectionPaused||Mc(this.instance,{kind:`selection`,action:`selection-changed`,trigger:`ui`,args:{added:e.length,removed:t.length,selected:this.selectedItems.length}})}get data(){return this.instance.store.data.selectedItems}get selectedItems(){return this.data?Array.from(this.data.values()):[]}get count(){return this.selectedItems.length}selectAll(){return new Promise(e=>{var t;if((t=this.instance.store.data.products)!=null&&t.items){let t=this.instance.store.data.products.items;this.select(t),e()}})}},yf=class{constructor(e){Z(this,`instance`,void 0),Z(this,`translations`,Ut({})),this.instance=e}async load(){var e;let t=await((e=this.instance.httpService)==null?void 0:e.loadTranslations());return t==null||t.forEach(({domain:e,key:t,value:n})=>{if(e&&t&&n){let r=e.toLowerCase();this.translations[r]||(this.translations[r]={}),this.translations[r][t]=n}}),this.instance.store.data.translationsReady=!0,this.translations}};function bf(e){try{let t=new URL(e);return t.protocol===`http:`||t.protocol===`https:`}catch{return!1}}function xf(e){if(typeof e!=`string`||e.length===0||/\s/.test(e))throw Error(`PIS initialization requires a non-empty baseUrl.`);if(e.startsWith(`/`)){if(!e.startsWith(`//`)&&!e.startsWith(`/\\`))return e;throw Error(`PIS initialization requires an origin-relative baseUrl path.`)}if(!bf(e))throw Error(`PIS initialization requires an absolute HTTP(S) or origin-relative baseUrl.`);return e}var Sf={products:[{from:`search`,to:`search.common`},{from:`searchForm`,to:`search.form`},{from:`searchToolbar`,to:`search.toolbar`},{from:`searchPagination`,to:`search.pagination`},{from:`searchHeader`,to:`search.header`},{from:`searchCategories`,to:`search.categories`},{from:`searchFilters`,to:`search.filters`},{from:`searchFiltersStatus`,to:`search.filtersStatus`},{from:`searchNarrowByProduct`,to:`search.narrowByProduct`},{from:`sparePartTypes`,to:`search.partTypes`},{from:`favoriteCategories`,to:`search.favoriteCategories`},{from:`favoriteViews`,to:`search.favoriteViews`},{from:`selection`,to:`search.selection`},{from:`itemsTable`,to:`search.table`},{from:`itemsList`,to:`search.list`},{from:`itemsGrid`,to:`search.grid`},{from:`itemsGridHorizontal`,to:`search.gridHorizontal`},{from:`configurators`,to:`search.common.configurators`},{from:`breadcrumbs`,to:`search.breadcrumbs`},{from:`details`,to:`details.data`,subKeyRoutes:{actionTemplate:`details.actions`}},{from:`detailsHeader`,to:`details.header`},{from:`detailsClassifications`,to:`details.classifications`},{from:`detailsGallery`,to:`details.gallery`},{from:`detailsVariantsSelector`,to:`details.variantsSelector`},{from:`detailsVariantsTable`,to:`details.variantsTable`},{from:`detailsVariantsDropdown`,to:`details.variantsDropdown`},{from:`relatedLinks`,to:`details.relatedLinks`},{from:`downloads`,to:`details.data.downloads`},{from:`exportMenu`,to:`search.toolbar.exportMenu`},{from:`preview`,to:`preview.view`},{from:`compare`,to:`compare.view`},{from:`attributesTable`,to:`removed (no v7 owner)`,removed:!0}],catalogs:[{from:`actions`,to:`search.common.actions`},{from:`search`,to:`search.common`},{from:`searchForm`,to:`search.form`},{from:`searchToolbar`,to:`search.toolbar`},{from:`searchTable`,to:`search.table`},{from:`searchHeader`,to:`search.header`},{from:`catalogsTable`,to:`search.table`},{from:`catalogsExport`,to:`search.table.export`},{from:`productsSearchForm`,to:`products.search.form`},{from:`productsSearchToolbar`,to:`products.search.toolbar`},{from:`searchProductCategories`,to:`products.search.productCategories`},{from:`searchPartCategories`,to:`products.search.partCategories`},{from:`productsSearchProductCategories`,to:`products.search.productCategories`},{from:`productsSearchPartCategories`,to:`products.search.partCategories`},{from:`searchFilters`,to:`products.search.filters`},{from:`searchFiltersStatus`,to:`products.search.filtersStatus`},{from:`productsSearchFilters`,to:`products.search.filters`},{from:`productsSearchFiltersStatus`,to:`products.search.filtersStatus`},{from:`itemsTable`,to:`products.search.table`},{from:`itemsList`,to:`products.search.list`},{from:`itemsGrid`,to:`products.search.grid`},{from:`itemsGridHorizontal`,to:`products.search.gridHorizontal`},{from:`productsSearchTable`,to:`products.search.table`},{from:`productsSearchList`,to:`products.search.list`},{from:`productsSearchGrid`,to:`products.search.grid`},{from:`productsSearchGridHorizontal`,to:`products.search.gridHorizontal`},{from:`selection`,to:`products.search.selection`},{from:`breadcrumbs`,to:`products.search.breadcrumbs`},{from:`productsBreadcrumbs`,to:`products.search.breadcrumbs`},{from:`preview`,to:`products.preview.view`},{from:`productsPreview`,to:`products.preview.view`},{from:`searchAliasFilters`,to:`aliases.search.filters`},{from:`aliasesTable`,to:`aliases.search.table`},{from:`aliasesSearchFilters`,to:`aliases.search.filters`},{from:`aliasesSearchTable`,to:`aliases.search.table`},{from:`viewSwitch`,to:`common.viewSwitch`},{from:`catalogProductSwitch`,to:`common.viewSwitch`}],classifications:[{from:`searchForm`,to:`browser.form`},{from:`searchToolbar`,to:`browser.common.toolbar`},{from:`tree`,to:`browser.tree`},{from:`selection`,to:`browser.selection`},{from:`favorites`,to:`browser.favorites`},{from:`treeTypeTabs`,to:`browser.tabs`,removedSubKeys:[`countsVisible`,`defaultDisplayMode`,`displayModes`]},{from:`note`,to:`browser.note`},{from:`actions`,to:`browser.actions`}]},Cf=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),wf=e=>typeof e==`object`&&!!e,Tf=(e,t)=>wf(e)&&t.some(t=>Cf(e,t)),Ef=(e,t)=>Tf(e,t),Df=e=>Tf(e,[`attributeCodes`,`actionTemplate`,`bottomNavigationSticky`,`hideBottomNavigation`,`showTabCounts`,`showTabIcons`,`relationships`,`maxProductImages`]),Of=e=>wf(e)&&Object.keys(e).some(e=>e!==`view`),kf={"products:search":e=>Ef(e,[`attributeCodes`,`maxProductImages`,`maxCategoryImages`,`includeProductClassifications`,`includeExtendedObjectData`]),"products:details":Df,"products:preview":Of,"products:compare":Of,"catalogs:search":e=>Ef(e,[`attributeCodes`,`maxProductImages`])};function Af(e,t){if(!wf(t)||!wf(t.components))return;let n=t.components,r=Sf[e].filter(t=>{if(!Cf(n,t.from))return!1;let r=kf[`${e}:${t.from}`];return!r||r(n[t.from])}),i=[];for(let t of Sf[e]){if(!t.subKeyRoutes||!t.to.startsWith(`${t.from}.`))continue;let e=wf(n[t.from])?n[t.from]:void 0;if(!e)continue;let r=t.to.split(`.`).slice(1),a=e;for(let e of r)a=wf(a)?a[e]:void 0;if(wf(a))for(let[e,n]of Object.entries(t.subKeyRoutes))Cf(a,e)&&i.push(`components.${t.to}.${e} -> components.${n}.${e}`)}let a=[];for(let t of Sf[e]){if(!t.removedSubKeys)continue;let e=n;for(let n of t.to.split(`.`))e=wf(e)?e[n]:void 0;if(wf(e))for(let n of t.removedSubKeys)Cf(e,n)&&a.push(`components.${t.to}.${n} (removed by the v7 redesign - no v7 owner)`)}if(e===`products`){let e=wf(n.details)&&wf(n.details.data)?n.details.data.relationships:void 0;wf(e)&&Cf(e,`displayModes`)&&a.push(`components.details.data.relationships.displayModes -> components.details.data.relationships.displayMode (per-relationship-type map with the All fallback)`)}if(r.length===0&&i.length===0&&a.length===0)return;let o=[...r.map(e=>`components.${e.from} -> components.${e.to}`),...i,...a].join(`; `);throw Error(`v6-to-v7 migration required: ${o}`)}function jf(e){if(!(!wf(e)||!Cf(e,`application`)))throw Error(`v6-to-v7 migration required: application -> appSettings`)}var Mf=class{constructor(e,t){Z(this,`id`,void 0),Z(this,`accessor`,void 0),Z(this,`instanceType`,`Catalogs`),Z(this,`props`,{}),Z(this,`httpService`,void 0),Z(this,`store`,Ut({notifications:[],data:{isInitialized:!1,actions:{current:null,data:null}},options:{isInitialized:!1}})),Z(this,`router`,new df(this)),Z(this,`translations`,new yf(this)),Z(this,`commandExecutor`,new Vd(this)),Z(this,`logger`,Gd),Z(this,`registeredComponents`,Ut(new Set)),Z(this,`dataTypesRequired`,Ut(new Set)),Z(this,`eventBus`,Vs()),Z(this,`eventBusExt`,_f(this.eventBus)),Z(this,`selection`,new vf(this)),this.id=e,this.accessor=t}isInitialized(){return this.store.data.isInitialized}async reload(){await this.translations.load(),await this.router.reload()}setRoute(e){this.router.setRoute(e)}async init(e,t){if(this.store.data.isInitialized)throw Error(`Instance "${this.id}" is already initialized`);Af(`catalogs`,e),jf(e);let n=xf(e==null?void 0:e.baseUrl),r=this.store.options.isInitialized?Ic(this.store.options):new Cc;hf(r,Ic(e)),this.store.options=r,this.store.options.isInitialized=!0,this.httpService=new sf(this,n,r.accessToken),this.store.data.isInitialized=!0,this.router.setRoute(t);try{return await this.translations.load(),Promise.resolve()}catch(e){this.store.data.isInitialized=!1;let t=Hc(r.errorInterceptor,{type:`InitError`,message:`PIS initialization error.`,isHandled:!1});return console.error(`[PIS] initialization error`,t,e),Promise.reject(Error(`PIS initialization error`,{cause:e}))}}update(e,t){Af(`catalogs`,e),jf(e);let n=this.store.options.isInitialized?this.store.options:new Cc;hf(n,Ic(e)),this.store.options=n,this.store.options.isInitialized=!0,t&&this.router.setRoute(t)}on(e,t){this.eventBusExt.on(e,t)}onReady(e){let t=I(()=>this.store.data,({isInitialized:n})=>{n&&(e(),t())},{deep:!0})}off(e,t){e?this.eventBusExt.off(e,t):this.eventBusExt.all.clear()}registerComponent(e){this.registeredComponents.add(e)}registerRequiredDataTypes(e){e.forEach(e=>this.dataTypesRequired.add(e))}getRegisteredSearchDataTypes(){if(this.dataTypesRequired&&this.dataTypesRequired.size){let e=Object.values(Rl),t=Array.from(this.dataTypesRequired).filter(t=>e.includes(t));return[...new Set(t)]}return[]}destroy(){return this.accessor.destroyInstance(this.id)}execute(e,t){return this.commandExecutor.execute(e,t)}executeCommand(e,...t){return this.commandExecutor.executeCommand(e,...t)}trackUserAction(e){jc(this,e)}getDefaultOptions(){return gf(new Cc)}getDefaultRouteData(){return Ic(cf)}getOptions(){return this.store.options}getRouteData(){return Ic(this.router.routeData)}},Nf=class{constructor(){Z(this,`instances`,Ut(new Map))}destroyInstance(e){try{var t;(t=this.instances.get(e))==null||t.off()}catch{}this.instances.delete(e)}getInstance(e){let t=this.instances.size;if(e!==void 0){if(this.instances.has(e))return this.instances.get(e);{let t=new Mf(e,this);return this.instances.set(e,t),t}}if(t===1)return this.instances.values().next().value;if(t>1)throw Error(`[PIS Catalogs] Cannot pick default instance if more than one exists`)}setAccessTokenInAllInstances(e){this.instances.forEach(t=>{t.getOptions().accessToken=e})}},Pf=new class{constructor(){Z(this,`accessors`,{}),Z(this,`version`,Yd.version),Z(this,`build`,Yd.revision)}get Products(){return this.getAccessor(`Products`)}get Catalogs(){return this.getAccessor(`Catalogs`)}get Classifications(){return this.getAccessor(`Classifications`)}registerProducts(e){this.accessors.Products||(this.accessors.Products=e)}registerCatalogs(e){this.accessors.Catalogs||(this.accessors.Catalogs=e)}registerClassifications(e){this.accessors.Classifications||(this.accessors.Classifications=e)}getAccessor(e){let t=this.accessors[e];if(!t)throw Error(`[PIS] ${e} is not registered. Import '@pisapp/core/${e.toLowerCase()}' before using PIS.${e}.`);return t}};function Ff(e){Pf.registerProducts(e)}function If(e){Pf.registerCatalogs(e)}function Lf(e){Pf.registerClassifications(e)}function Rf(){typeof window<`u`&&(window.PIS=Pf)}function zf(e,t){return Ae()?(je(e,t),!0):!1}var Bf=typeof window<`u`&&typeof document<`u`;typeof WorkerGlobalScope<`u`&&globalThis instanceof WorkerGlobalScope;var Vf=e=>e!=null,Hf=Object.prototype.toString,Uf=e=>Hf.call(e)===`[object Object]`,Wf=()=>{},Gf=Kf();function Kf(){var e,t,n;return Bf&&!!((e=window)!=null&&(e=e.navigator)!=null&&e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window)==null||(t=t.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test((n=window)==null?void 0:n.navigator.userAgent))}function qf(e){return Array.isArray(e)?e:[e]}function Jf(e,t,n){return I(e,t,{...n,immediate:!0})}var Yf=Bf?window:void 0;Bf&&window.document,Bf&&window.navigator,Bf&&window.location;function Xf(e){let t=N(e);return(t==null?void 0:t.$el)??t}function Zf(...e){let t=(e,t,n,r)=>(e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)),n=Y(()=>{let t=qf(N(e[0])).filter(e=>e!=null);return t.every(e=>typeof e!=`string`)?t:void 0});return Jf(()=>{var t;return[((t=n.value)==null?void 0:t.map(e=>Xf(e)))??[Yf].filter(e=>e!=null),qf(N(n.value?e[1]:e[0])),qf(on(n.value?e[2]:e[1])),N(n.value?e[3]:e[2])]},([e,n,r,i],a,o)=>{if(!(e!=null&&e.length)||!(n!=null&&n.length)||!(r!=null&&r.length))return;let s=Uf(i)?{...i}:i,c=e.flatMap(e=>n.flatMap(n=>r.map(r=>t(e,n,r,s))));o(()=>{c.forEach(e=>e())})},{flush:`post`})}var Qf=!1;function $f(e,t,n={}){let{window:r=Yf,ignore:i=[],capture:a=!0,detectIframe:o=!1,controls:s=!1}=n;if(!r)return s?{stop:Wf,cancel:Wf,trigger:Wf}:Wf;if(Gf&&!Qf){Qf=!0;let e={passive:!0};Array.from(r.document.body.children).forEach(t=>t.addEventListener(`click`,Wf,e)),r.document.documentElement.addEventListener(`click`,Wf,e)}let c=!0,l=e=>N(i).some(t=>{if(typeof t==`string`)return Array.from(r.document.querySelectorAll(t)).some(t=>t===e.target||e.composedPath().includes(t));{let n=Xf(t);return n&&(e.target===n||e.composedPath().includes(n))}});function u(e){let t=N(e);return t&&t.$.subTree.shapeFlag===16}function d(e,t){let n=N(e),r=n.$.subTree&&n.$.subTree.children;return r==null||!Array.isArray(r)?!1:r.some(e=>e.el===t.target||t.composedPath().includes(e.el))}let f=n=>{let r=Xf(e);if(n.target!=null&&!(!(r instanceof Element)&&u(e)&&d(e,n))&&!(!r||r===n.target||n.composedPath().includes(r))){if(`detail`in n&&n.detail===0&&(c=!l(n)),!c){c=!0;return}t(n)}},p=!1,m=[Zf(r,`click`,e=>{p||(p=!0,setTimeout(()=>{p=!1},0),f(e))},{passive:!0,capture:a}),Zf(r,`pointerdown`,t=>{let n=Xf(e);c=!l(t)&&!!(n&&!t.composedPath().includes(n))},{passive:!0}),o&&Zf(r,`blur`,n=>{setTimeout(()=>{let i=Xf(e),a=r.document.activeElement;for(;a!=null&&a.shadowRoot;)a=a.shadowRoot.activeElement;(a==null?void 0:a.tagName)===`IFRAME`&&!(i!=null&&i.contains(r.document.activeElement))&&t(n)},0)},{passive:!0})].filter(Boolean),h=()=>m.forEach(e=>e());return s?{stop:h,cancel:()=>{c=!1},trigger:e=>{c=!0,f(e),c=!1}}:h}function ep(){let e=nn(!1),t=Pa();return t&&kr(()=>{e.value=!0},t),e}function tp(e){let t=ep();return Y(()=>(t.value,!!e()))}function np(e,t,n={}){let{window:r=Yf,...i}=n,a,o=tp(()=>r&&`ResizeObserver`in r),s=()=>{a&&(a.disconnect(),a=void 0)},c=I(Y(()=>{let t=N(e);return Array.isArray(t)?t.map(e=>Xf(e)):[Xf(t)]}),e=>{if(s(),o.value&&r){a=new ResizeObserver(t);for(let t of e)t&&a.observe(t,i)}},{immediate:!0,flush:`post`}),l=()=>{s(),c()};return zf(l),{isSupported:o,stop:l}}function rp(e,t,n={}){let{root:r,rootMargin:i,threshold:a=0,window:o=Yf,immediate:s=!0}=n,c=tp(()=>o&&`IntersectionObserver`in o),l=Y(()=>qf(N(e)).map(Xf).filter(Vf)),u=Wf,d=nn(s),f=c.value?I(()=>[l.value,Xf(r),N(i),d.value],([e,n,r])=>{if(u(),!d.value||!e.length)return;let i=new IntersectionObserver(t,{root:Xf(n),rootMargin:r,threshold:a});e.forEach(e=>e&&i.observe(e)),u=()=>{i.disconnect(),u=Wf}},{immediate:s,flush:`post`}):Wf,p=()=>{u(),f(),d.value=!1};return zf(p),{isSupported:c,isActive:d,pause(){u(),d.value=!1},resume(){d.value=!0},stop:p}}var ip=()=>({filtersModel:M({}),filtersLoading:Ut(new Set),filtersFetched:Ut(new Map),allFilters:M(),allFiltersLoading:M(!1),allFiltersGeneration:0,filteredResultCount:M(),filteredResultCountLoading:M(!1),filtersOpen:Ut(new Set)}),ap=new WeakMap,op=(e,t)=>{if(!e)return t;let n=ap.get(e);return n||(n=ip(),ap.set(e,n)),n};function sp(e,t=0){let n;return((...r)=>{n&&clearTimeout(n),n=setTimeout(()=>e(...r),t)})}function cp(e,t){let n=0,r,i;return((...a)=>{let o=t-(Date.now()-n);o<=0?(n=Date.now(),e(...a)):(i=a,r||(r=setTimeout(()=>{r=void 0,n=Date.now(),i&&e(...i),i=void 0},o)))})}var lp={view:`search`,search:{searchText:void 0,searchType:ru.HIERARCHICAL,cid:void 0,filters:{type:`group`,condition:ql.AND,rules:[]},pagination:{page:1,pageSize:24},subView:`table`,sortField:au.PRODUCT,sortDirection:iu.ASCENDING,partsType:$l.ALL},detail:{productId:void 0}},up={},dp=[],fp=(e,t)=>{let n={productId:e,relationshipCode:t.code,filter:M(void 0),filtersAll:M([]),filtersPromoted:M([]),filtersAdditional:M([]),filtersModel:M({}),filtersLoading:Ut(new Set),filtersFetched:Ut(new Map),filtersOpen:Ut(new Set),saveSettings:()=>{dp.forEach(e=>{up[`${e.productId}${e.relationshipCode}`]={filter:e.filter.value,filterModel:{...e.filtersModel.value},filtersFetched:new Map(e.filtersFetched)}})},setFilters:e=>{n.filtersAll.value=[],n.filtersPromoted.value=[],n.filtersAdditional.value=[],e.forEach(e=>{let t={attributeCode:e.attributeCode,attributeName:e.attributeName,attributeNameHtml:e.attributeNameHtml,hitCount:e.hitCount,promoted:e.promoted,internal:e.internal};n.filtersAll.value.push(t),t.promoted?n.filtersPromoted.value.push(t):n.filtersAdditional.value.push(t),n.filtersModel.value[t.attributeCode]||(n.filtersModel.value[t.attributeCode]={})})},setFilterValues:e=>e.forEach(e=>{n.filtersLoading.delete(e.attributeCode),n.filtersFetched.set(e.attributeCode,e.values??[])}),getFiltersModelAsCriteriaGroup:()=>pu(n.filtersModel.value),resetFiltersApplied:()=>{n.filtersOpen.clear(),n.filtersFetched.clear(),Object.keys(n.filtersModel.value).forEach(e=>n.filtersModel.value[e]={})}};return dp.push(n),n},pp=(e,t)=>{let n=fp(e,t),r=up[`${e}${t.code}`];return r?(n.filter.value=r.filter,n.filtersModel.value=r.filterModel,r.filtersFetched.forEach((e,t)=>n.filtersFetched.set(t,e))):n.resetFiltersApplied(),n},mp=()=>{up={},dp=[]};function hp(e,t){for(let n=e.length-1;n>=0;n--)t(e[n])&&e.splice(n,1)}var gp=class extends wc{},_p=class extends Error{constructor(...e){super(...e),Z(this,`isHandled`,!0)}},vp=async(e,t,n)=>{if(!n){e.store.data.isLoadingData=!1;return}try{e.store.data.isLoadingData=!0;let i=await n;if(e.store.data.isLoadingData=!1,!i||!i.success){var r;throw i!=null&&(r=i.errors)!=null&&r.length?(await e.execute(new sm({errors:i.errors||[],warnings:i.warnings||[]})),new _p((i==null?void 0:i.message)||`Unknown error`)):Error((i==null?void 0:i.message)||`Unknown error`)}return await e.execute(new $p({type:`success`,message:t.onSuccessMessage})),i}catch(t){throw e.store.data.isLoadingData=!1,t instanceof _p||await e.execute(new $p({type:`danger`,message:t.message})),t}},yp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-search`),Z(this,`execute`,async e=>{var t;let n={sortField:this.args.searchText?au.RELEVANCE:au.PRODUCT,sortDirection:this.args.searchText.length==0?void 0:this.args.searchText?iu.DESCENDING:iu.ASCENDING,searchType:this.args.searchType,searchText:this.args.searchText.length==0?void 0:this.args.searchText,pagination:{page:1}};this.args.resetCategories&&(n.cid=void 0),this.args.resetFilters&&(n.filters=void 0),this.args.cid&&(n.cid=this.args.cid);let r={view:`search`,search:n};return await((t=e.router)==null?void 0:t.setRoute(r))})}},bp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`details`),Z(this,`execute`,async e=>{var t;return e.store.data.productPreview=void 0,await((t=e.router)==null?void 0:t.setRoute({view:`detail`,detail:{productId:this.args.productId}}))})}},xp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`preview`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.preview(this.args.productId))})}},Sp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`scroll-to-top`),Z(this,`execute`,async e=>(e.eventBus.emit(`internal:scroll-to-top`),Promise.resolve()))}},Cp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`document`),Z(this,`execute`,async e=>Wc(e,this.name))}},wp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`configurator`),Z(this,`execute`,async e=>Wc(e,this.name))}},Tp=class extends gp{constructor(e={step:1}){super(e),Z(this,`name`,`back`),Z(this,`execute`,async e=>{var t;if(((t=e.router)==null?void 0:t.history.length)==0){var n;(n=e.router)==null||n.setRoute(lp),mp()}else{var r,i;await((r=e.router)==null?void 0:r.back(this.args.step)),((i=e.router)==null?void 0:i.routeData.view)!==`detail`&&mp();return}})}},Ep=class extends gp{constructor(...e){super(...e),Z(this,`name`,`search-view`),Z(this,`execute`,async e=>{var t;return(t=e.router)==null?void 0:t.setRoute(lp)})}},Dp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`sub-view`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({search:{subView:this.args.subView}},!0))})}},Op=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-classification`),Z(this,`execute`,async e=>{var t;let n=e.getRouteData();return n.view=`search`,n.search&&(n.search.sortField=au.PRODUCT,n.search.pagination&&(n.search.pagination.page=1),n.search.cid=this.args.cid,this.args.clearSearch&&(n.search.searchText=void 0)),await((t=e.router)==null?void 0:t.setRoute(n))})}},kp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-parts-type`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({view:`search`,search:{sortField:au.PRODUCT,pagination:{page:1},partsType:this.args.partsType}}))})}},Ap=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-master-product`),Z(this,`execute`,async e=>{var t;return e.store.data.searchTitle=this.args.masterProductName,await((t=e.router)==null?void 0:t.setRoute({view:`search`,search:{sortField:au.PRODUCT,pagination:{page:1},masterProductId:this.args.masterProductId}}))})}},jp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`paginate`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({view:`search`,search:{pagination:{page:this.args.page}}}))})}},Mp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`page-size`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({view:`search`,search:{pagination:{pageSize:this.args.pageSize,page:1}}}))})}},Np=class extends gp{constructor(...e){super(...e),Z(this,`name`,`sort-by`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({view:`search`,search:{sortField:this.args.sortField}}))})}},Pp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-parametric-apply`),Z(this,`execute`,async e=>{var t,n;return await((t=e.router)==null?void 0:t.setRoute({view:`search`,search:{filters:this.args.filters,pagination:{page:1,pageSize:(n=e.router.routeData)==null||(n=n.search)==null||(n=n.pagination)==null?void 0:n.pageSize}}}))})}},Fp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-parametric-remove`),Z(this,`execute`,async e=>{var t,n,r;let i=(t=e.router.routeData.search)==null?void 0:t.filters,a=i?mu(i,this.args.attributeCode,this.args.value):cu();return await((n=e.router)==null?void 0:n.setRoute({search:{filters:a,pagination:{page:1,pageSize:(r=e.router.routeData)==null||(r=r.search)==null||(r=r.pagination)==null?void 0:r.pageSize}}}))})}},Ip=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-filter-values`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.filterValues(this.args.attributeCodes))})}},Lp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-variant-table-group`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.loadVariantTableGroup(this.args.attributeCode))})}},Rp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-filters`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.filters())})}},zp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-prm-list`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.loadPrmRelationship(this.args.search,this.args.pager))})}},Bp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-prm-autocomplete`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.loadPrmRelationshipAutocomplete(this.args.search,this.args.pager))})}},Vp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-autocomplete`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.autocomplete(this.args.searchText,this.args.categorySearch??!1))})}},Hp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-prm-filter-values`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.loadPrmRelationshipFilterValues(this.args))})}},Up=class extends gp{constructor(...e){super(...e),Z(this,`name`,`export`),Z(this,`execute`,async e=>Wc(e,this.name))}},Wp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`favorite-views-load`),Z(this,`execute`,async e=>{var t;let n={items:await((t=e.httpService)==null?void 0:t.loadFavoriteViews(this.args.ids))||[]};e.eventBus.emit(`favorite-views-loaded`,n)})}},Gp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`favorite-views-save`),Z(this,`execute`,async e=>{var t;let n=await((t=e.httpService)==null?void 0:t.saveFavoriteView(this.args.id,this.args.code,this.args.routeData));n&&e.eventBus.emit(`favorite-views-saved`,{item:n})})}},Kp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`favorite-views-delete`),Z(this,`execute`,async e=>{var t;let n=await((t=e.httpService)==null?void 0:t.deleteFavoriteView(this.args.id));n&&e.eventBus.emit(`favorite-views-deleted`,{id:n})})}},qp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`favorite-views-apply`),Z(this,`execute`,async e=>{let t=this.args.favoriteView.data;if(t){var n;let r=Object.assign({},e.router.routeData,{search:{searchText:t.search.searchText,searchType:t.search.searchType,cid:t.search.cid,filters:t.search.filter,pagination:t.pager,sortField:t.sort.field,sortDirection:t.sort.direction,masterProductId:t.search.masterProductId}});await((n=e.router)==null?void 0:n.setRoute(r)),e.eventBus.emit(`favorite-views-applied`,{routeData:e.router.routeData})}})}},Jp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`get-classifications-nodes`),Z(this,`execute`,async e=>{var t;if(this.args.cids)return await((t=e.httpService)==null?void 0:t.loadClassificationsNodes(this.args.cids))})}},Yp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`favorite-category-add`),Z(this,`execute`,async e=>{if(this.args.cid){var t,n,r,i;((t=e.store.options.appSettings)==null?void 0:t.treeType)===ou.PRODUCTS&&(n=e.store.options.components)!=null&&(n=n.search)!=null&&n.favoriteCategories?(e.store.options.components.search.favoriteCategories.productCids===void 0&&(e.store.options.components.search.favoriteCategories.productCids=[]),e.store.options.components.search.favoriteCategories.productCids.push(this.args.cid)):((r=e.store.options.appSettings)==null?void 0:r.treeType)===ou.PARTS&&(i=e.store.options.components)!=null&&(i=i.search)!=null&&i.favoriteCategories&&(e.store.options.components.search.favoriteCategories.partCids===void 0&&(e.store.options.components.search.favoriteCategories.partCids=[]),e.store.options.components.search.favoriteCategories.partCids.push(this.args.cid))}return e.eventBus.emit(`favorite-category-added`,this.args),Promise.resolve()})}},Xp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`favorite-category-remove`),Z(this,`execute`,async e=>{if(this.args.cid){var t,n;if(((t=e.store.options.appSettings)==null?void 0:t.treeType)===ou.PRODUCTS){var r,i,a;(r=e.store.options.components)!=null&&(r=r.search)!=null&&(r=r.favoriteCategories)!=null&&r.productCids&&hp((i=e.store.options.components)==null||(i=i.search)==null?void 0:i.favoriteCategories.productCids,e=>e===this.args.cid),(a=e.store)!=null&&(a=a.data)!=null&&(a=a.favoriteProductCategories)!=null&&a.items&&hp(e.store.data.favoriteProductCategories.items,e=>e.cid===this.args.cid)}else if(((n=e.store.options.appSettings)==null?void 0:n.treeType)===ou.PARTS){var o,s;(o=e.store.options.components)!=null&&(o=o.search)!=null&&(o=o.favoriteCategories)!=null&&o.partCids&&hp(e.store.options.components.search.favoriteCategories.partCids,e=>e===this.args.cid),(s=e.store)!=null&&(s=s.data)!=null&&(s=s.favoritePartCategories)!=null&&s.items&&hp(e.store.data.favoritePartCategories.items,e=>e.cid===this.args.cid)}}return e.eventBus.emit(`favorite-category-removed`,this.args),Promise.resolve()})}},Zp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`print-to-pdf`),Z(this,`execute`,async e=>{var t;let n=await((t=e.httpService)==null?void 0:t.generatePDFUrl(this.args.productId));n&&(await Kc(`Product ${this.args.productId}.pdf`,n),e.eventBus.emit(`print-to-pdf-done`,n))})}},Qp=class extends gp{constructor(...e){super(...e),Z(this,`name`,`show-print-view`),Z(this,`execute`,async e=>Wc(e,this.name))}},$p=class extends gp{constructor(...e){super(...e),Z(this,`name`,`notification-show`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>{let t=0,n=this.args.dismissAfter;e.store.notifications.length&&(e.store.notifications=[],t=1e3),!n&&n!==0&&this.args.type!==`danger`&&(n=6e3,e.store.notifications=[]),n&&n!==0&&setTimeout(()=>{let t=e.store.notifications.indexOf(this.args);t!==-1&&e.store.notifications.splice(t,1)},this.args.dismissAfter),setTimeout(()=>e.store.notifications.push(this.args),t)})}},em=class extends gp{constructor(...e){super(...e),Z(this,`name`,`notification-hide`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>{let t=e.store.notifications.indexOf(this.args);t!==-1&&e.store.notifications.splice(t,1)})}},tm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`filter-compare`),Z(this,`execute`,async e=>{var t;let n=e.getRouteData();return n.compare&&this.args.diffOnly!=null&&(n.compare.differencesOnly=this.args.diffOnly),n.compare&&this.args.cid&&(n.compare.cids=[this.args.cid]),await((t=e.router)==null?void 0:t.setRoute(n))})}},nm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`remove-compare-item`),Z(this,`execute`,async e=>{var t,n;let r=e.getRouteData();if((t=r.compare)!=null&&t.productIds){let e=r.compare.productIds.indexOf(this.args.item.productId)??-1;e>-1&&r.compare.productIds.splice(e,1)}return await((n=e.router)==null?void 0:n.setRoute(r))})}},rm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`show-compare-print-view`),Z(this,`execute`,async e=>Wc(e,this.name))}},im=async(e,t,n)=>Object.assign(e.store.data.actions,{current:t,data:n}),am=class extends gp{constructor(...e){super(...e),Z(this,`name`,`product-action-completed`),Z(this,`execute`,async e=>Object.assign(e.store.data.actions,{current:null,data:null}))}},om=class extends gp{constructor(...e){super(...e),Z(this,`name`,`add-to-catalog`),Z(this,`execute`,async e=>im(e,`ProductAddToCatalogAction`,this.args))}},sm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`product-errors-action`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>im(e,`Errors`,this.args))}},cm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`catalog-get-options`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.getCatalogOptions())})}},lm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`catalogs-fetch`),Z(this,`execute`,async e=>{var t;let n=await((t=e.httpService)==null?void 0:t.getAllCatalogs());return!n||!n.items?[]:n.items})}},um=class extends gp{constructor(...e){super(...e),Z(this,`name`,`catalog-create-new`),Z(this,`execute`,async e=>{var t,n;let r=await vp(e,this.args,(t=e.httpService)==null?void 0:t.addCatalog(this.args.code,this.args.type,this.args.description));return r==null||(n=r.catalog)==null?void 0:n.id})}},dm=class extends gp{constructor(...e){super(...e),Z(this,`name`,`product-add-to-catalog`),Z(this,`execute`,async e=>{var t;return vp(e,this.args,(t=e.httpService)==null?void 0:t.addProductToCatalog(this.args.id,this.args.products))})}},fm=class extends Gc{constructor(e){super(e,pm,`products`)}},pm={"filter-search":yp,details:bp,preview:xp,"scroll-to-top":Sp,document:Cp,configurator:wp,back:Tp,"search-view":Ep,"sub-view":Dp,"filter-classification":Op,"filter-parts-type":kp,"filter-master-product":Ap,paginate:jp,"page-size":Mp,"sort-by":Np,"filter-parametric-apply":Pp,"filter-parametric-remove":Fp,"get-filters":Rp,"get-filter-values":Ip,"get-variant-table-group":Lp,"get-autocomplete":Vp,"get-prm-list":zp,"get-prm-autocomplete":Bp,"get-prm-filter-values":Hp,export:Up,"favorite-views-load":Wp,"favorite-views-save":Gp,"favorite-views-delete":Kp,"favorite-views-apply":qp,"get-classifications-nodes":Jp,"favorite-category-add":Yp,"favorite-category-remove":Xp,"print-to-pdf":Zp,"show-print-view":Qp,"notification-show":$p,"notification-hide":em,"filter-compare":tm,"remove-compare-item":nm,"show-compare-print-view":rm,"product-action-completed":am,"add-to-catalog":om,"product-errors-action":sm,"catalog-get-options":cm,"catalogs-fetch":lm,"catalog-create-new":um,"product-add-to-catalog":dm},mm=(e,t)=>()=>{let n=ip(),r=()=>op(e.value,n),i=Y(()=>r().filtersModel.value),a=Y(()=>r().filtersOpen),o=Y(()=>r().filtersFetched),s=Y(()=>r().filtersLoading),c=Y(()=>r().allFiltersLoading.value),l=Y(()=>r().filteredResultCount.value),u=Y(()=>r().filteredResultCountLoading.value),d=()=>{var t;return((t=e.value)==null?void 0:t.instanceType)==`Products`?e.value:void 0},f=()=>{var t;return((t=e.value)==null?void 0:t.instanceType)==`Catalogs`?e.value:void 0},p=()=>{var e,t;return((e=d())==null||(e=e.router.routeData)==null||(e=e.search)==null?void 0:e.filters)??((t=f())==null||(t=t.router.routeData)==null?void 0:t.products.filters)},m=e=>Object.values(i.value[e]??{}).some(Boolean),h=e=>{let t=r(),n=new Set(fu(e).map(e=>e.code));for(let r of[...t.filtersFetched.keys()])!m(r)&&(!e||!n.has(r))&&(t.filtersFetched.delete(r),t.filtersOpen.delete(r))},g=Y(()=>{var e;return((e=d())==null||(e=e.store.options.components)==null||(e=e.search)==null||(e=e.filters)==null?void 0:e.hideSelectedValues)??!1}),_=e=>fu(e).map(e=>{var t,n;return{...e,attributeName:(t=y.value.find(({attributeCode:t})=>t===e.code))==null?void 0:t.attributeName,values:(n=e.values)==null?void 0:n.map(t=>{var n;return((n=r().filtersFetched.get(e.code))==null?void 0:n.find(e=>du(e.value,t)))??{text:t.v,value:t,hitCount:0}})}}),v=Y(()=>{let e=p();return e?_(e):[]}),y=Y(()=>{var e,t;let n=((e=d())==null||(e=e.store.data.filters)==null?void 0:e.items)??((t=f())==null||(t=t.store.data.filters)==null?void 0:t.items)??[];return g.value?n.filter(e=>!v.value.some(t=>t.code===e.attributeCode)):n}),b=Y(()=>y.value.filter(({promoted:e})=>!!e)),x=Y(()=>y.value.filter(({promoted:e})=>!e)),S=Y(()=>{let e=r().allFilters.value??y.value;return g.value?e.filter(e=>!v.value.some(t=>t.code===e.attributeCode)):e}),C=Y(()=>S.value.filter(({promoted:e})=>!!e)),w=Y(()=>S.value.filter(({promoted:e})=>!e)),T=Y(()=>{var e,t;return((e=d())==null||(e=e.store.data.filters)==null?void 0:e.totalCount)??((t=f())==null||(t=t.store.data.filters)==null?void 0:t.totalCount)??y.value.length}),E=Y(()=>v.value.length>0||Object.keys(i.value).some(m)),D=()=>pu(i.value),ee=()=>{let e=r();e.allFiltersGeneration++,e.allFilters.value=void 0,e.allFiltersRequest=void 0,e.allFiltersLoading.value=!1},O=async()=>{let e=d();if(!e||r().allFilters.value)return;let n=r();if(n.allFiltersRequest)return n.allFiltersRequest;let i=n.allFiltersGeneration;n.allFiltersLoading.value=!0;let a=(async()=>{try{let n=await e.execute(new Rp().from(t??`filters`)),a=r();a.allFiltersGeneration===i&&(a.allFilters.value=(n==null?void 0:n.items)??[])}catch{}finally{let e=r();e.allFiltersGeneration===i&&(e.allFiltersLoading.value=!1,e.allFiltersRequest=void 0)}})();return n.allFiltersRequest=a,a},te=async n=>{let i=new Set([...S.value.map(({attributeCode:e})=>e),...fu(p()).map(({code:e})=>e)]),a=n.filter(e=>i.has(e));if(a.length){a.forEach(e=>r().filtersLoading.add(e));try{var o;let n=(d()?new Ip({attributeCodes:a}):new Pu({attributeCodes:a})).from(t??`filters`),i=await((o=e.value)==null?void 0:o.execute(n));a.forEach(e=>{let t=r();if(t.filtersLoading.delete(e),i!=null&&i.items){i.items.forEach(e=>{e!=null&&e.values&&(e.values=e.values.map(e=>({...e,_key:lu(e.value)})))});let n=i.items.find(t=>t.attributeCode===e);t.filtersFetched.set(e,(n==null?void 0:n.values)??[])}})}catch{}}},ne=async e=>{let t=e.map(e=>e.attributeCode);await te(t),t.forEach(e=>r().filtersOpen.add(e))},re=()=>{r().filtersOpen.clear()},ie=()=>{let e=r();for(let t of[...e.filtersFetched.keys()])m(t)?e.filtersOpen.add(t):(e.filtersFetched.delete(t),e.filtersOpen.delete(t));return te(Array.from(e.filtersFetched.keys()))},ae=sp(async()=>{try{var e;if(r().filteredResultCountLoading.value=!0,r().filtersFetched.size===0){let e=Object.keys(r().filtersModel.value).filter(m);e.length&&await te(e)}let t=await((e=d()??f())==null||(e=e.httpService)==null?void 0:e.loadFiltersResultCount(D()));r().filteredResultCount.value=(t==null?void 0:t.totalCount)??void 0}catch{r().filteredResultCount.value=void 0}finally{r().filteredResultCountLoading.value=!1}},700),oe=async n=>{try{var r;h(n);let i=(d()?new Pp({filters:n}):new Mu({filters:n})).from(t??`filters`);return((r=e.value)==null?void 0:r.execute(i))??Promise.resolve()}catch{}};return I(S,e=>{let t=r().filtersModel.value;e==null||e.forEach(({attributeCode:e})=>{e&&!t[e]&&(t[e]={})})}),{filtersAll:y,filtersOpen:a,filtersModel:i,filtersApplied:v,filtersLoading:s,filtersFetched:o,filtersPromoted:b,filtersAdditional:x,modalFiltersAll:S,modalFiltersPromoted:C,modalFiltersAdditional:w,filtersTotalCount:T,allFiltersLoading:c,areFiltersApplied:E,refreshResultCount:ae,filteredResultCount:l,filteredResultCountLoading:u,applyFilters:oe,excludeFilter:async({code:n},i)=>{if(n)try{var a,o;(a=r().filtersModel.value)[n]??(a[n]={}),r().filtersModel.value[n][lu(i)]=!1;let s=(d()?new Fp({attributeCode:n,value:i}):new Nu({attributeCode:n,value:i})).from(t??`filters`);await((o=e.value)==null?void 0:o.execute(s)),ie(),ae()}catch{}},fetchFilterValues:te,fetchAllFilters:O,invalidateAllFilters:ee,applyModelFilters:async()=>{await oe(D())},resetFiltersApplied:()=>{let e=r();e.filtersOpen.clear(),e.filtersFetched.clear(),Object.keys(e.filtersModel.value).forEach(t=>e.filtersModel.value[t]={});let t=oe(cu());return e.filteredResultCount.value=void 0,ae(),t},syncSelectedFilters:()=>{setTimeout(async()=>{let e=p(),t=fu(e),n=t.map(({code:e})=>e).filter(e=>!r().filtersFetched.has(e));if(n.length&&await te(n),p()!==e)return;let i=r().filtersModel.value;for(let e in i)i[e]={};t.forEach(e=>{var t,n;i[t=e.code]??(i[t]={}),(n=e.values)==null||n.forEach(t=>i[e.code][lu(t)]=!0)})},1)},refreshFetchedFilterValues:ie,expandAllFilters:ne,collapseAllFilters:re,clearFiltersModelFromEmptyValues:h}};function hm(e,t,n){let r=!1,i=()=>{let n=e.getAttribute(`instance-id`);if(n!==null&&n!==``)return t.getInstanceById(n);let r=e.closest(t.instanceTag);if(r&&typeof r.getInstance==`function`)return r.getInstance()},a=e=>{r||!e||(r=!0,n(e))};a(i()),r||jn(()=>a(i()))}var gm={xs:320,sm:460,md:680,lg:800,xl:1024};function _m(e){let{getInstance:t,instanceTag:n,debounceResize:r=!0,isReadyIncludesOptions:i=!1,translationFallbackNamespace:a}=e;return function(e,o,s){let c=Pa(),l=c==null?void 0:c.type.name,u=(c==null?void 0:c.isCE)??!1,d=M(),f=M(),p=M(),m=M(0),h=e=>{e&&(d.value=e,f.value=e.store,p.value=e.router.routeData,e.registerComponent(l),s&&e.registerRequiredDataTypes(s))};o&&h(t(o)),kr(()=>{e!=null&&e.value&&!o&&hm(e.value,{getInstanceById:e=>t(e),instanceTag:n},h)});let g=e=>{let t=e[0];m.value=t.contentRect.width};np(e,r?sp(g,25):g);let _=e=>m.value>gm[e],v=e=>m.value<=gm[e],y=e=>m.value>e,b=e=>m.value<=e,x=Y(()=>{let e=f.value,t=(e==null?void 0:e.data.isInitialized)&&(e==null?void 0:e.data.translationsReady);return(i?t&&(e==null?void 0:e.options.isInitialized):t)??!1}),S=Y(()=>{var e;return((e=f.value)==null?void 0:e.data.translationsReady)??!1}),C=(e,t=!1,r)=>{let i=t?`common`:n.replace(/^pis-(.*)-instance$/,`$1`),o=w(e,i,r);if(o)return o;if(a){let t=w(e,a,r);if(t)return t}return`{${i}:${e}}`},w=(e,t,n)=>{var r;let i=(r=d.value)==null?void 0:r.translations.translations[t];if(i&&i[e]){let t=i[e];return n!=null&&n.length&&n.forEach((e,n)=>{t=t.replace(`{${n}}`,e||``)}),t}};return{componentName:l,isWebComponent:u,instance:d,store:f,routeData:p,isReady:x,translationsReady:S,widerThan:_,narrowerThan:v,widerThanPx:y,narrowerThanPx:b,t:C,emit:(e,t)=>{var n;(n=d.value)==null||n.eventBus.emit(e,t)},useProductsFilters:mm(d,l)}}}var vm=_m({getInstance:e=>Pf.Catalogs.getInstance(e),instanceTag:`pis-catalogs-instance`,translationFallbackNamespace:`products`});function ym(e,t,n){return vm(e,t,n)}function bm(e,t,n){let r=t=>e.value.execute(n?t.from(n):t),i={[Sc.createNew]:()=>new Cd,[Sc.history]:()=>new Sd},a={[Sc.makeDefault]:e=>new od({catalogId:e.id,onSuccessMessage:t(`CatalogSetAsDefaultSuccess`)}),[Sc.unmakeDefault]:e=>new sd({catalogId:e.id,onSuccessMessage:t(`CatalogUnsetAsDefaultSuccess`)}),[Sc.edit]:e=>new _d({catalog:e}),[Sc.copy]:e=>new vd({catalog:e}),[Sc.import]:e=>new yd({catalog:e}),[Sc.export]:e=>new bd({catalog:e}),[Sc.delete]:e=>new xd({catalog:e})},o={[Sc.productEdit]:(e,t)=>new wd({product:e,catalog:t}),[Sc.productCopy]:(e,t)=>new Td({product:e,catalog:t}),[Sc.productDelete]:(e,t)=>new Ed({product:e,catalog:t})},s={[Sc.aliasImport]:()=>new jd,[Sc.aliasExport]:()=>new Md},c={[Sc.aliasEdit]:e=>new kd({alias:e}),[Sc.aliasDelete]:e=>new Ad({aliases:e.aliases||[]})};return{onCatalogItemMenuAction:async(e,t)=>{let n=e.code&&a[e.code]?a[e.code](t):new Id({menuItem:e,catalog:t});try{return await r(n)}catch{}},onCatalogListMenuAction:async e=>{let t=e.code&&i[e.code]?i[e.code]():new Fd({menuItem:e});try{return await r(t)}catch{}},onProductListMenuAction:async e=>{try{return await r(new Ld({menuItem:e}))}catch{}},onProductItemMenuAction:async(e,t,n)=>{let i=await r(new Pd({catalogId:n}));if(!i)throw Error(`Catalog "${n}" not found!`);let a=e.code&&o[e.code]?o[e.code](t,i):new Rd({menuItem:e,product:t,catalog:i});try{return await r(a)}catch{}},onAliasListMenuAction:async e=>{try{let t=e.code&&s[e.code]?s[e.code]():new zd({menuItem:e});return await r(t)}catch{}},onAliasItemMenuAction:async(e,t)=>{let n=e.code&&c[e.code]?c[e.code](t):new Bd({menuItem:e,alias:t});try{return await r(n)}catch{}}}}var xm=L({name:`Clickable`,props:{disabled:{type:Boolean,default:!1}},emits:[`click`]}),Q=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n},Sm={key:0,class:`text-light pis-clickable pis-disabled`};function Cm(e,t,n,r,i,a){return e.disabled?(H(),U(`span`,Sm,[B(e.$slots,`default`)])):(H(),U(`a`,{key:1,tabindex:`0`,role:`button`,class:`pis-clickable`,style:{cursor:`pointer`},onClick:t[0]||(t[0]=t=>e.$emit(`click`,t)),onKeyup:t[1]||(t[1]=Ns(t=>e.$emit(`click`,t),[`enter`]))},[B(e.$slots,`default`)],32))}var wm=Q(xm,[[`render`,Cm]]),Tm=[16,24,32],Em={display:`inline-block`,verticalAlign:`-0.125em`,flexShrink:0};function Dm(e){return e.split(`-`).map(e=>e&&e[0].toUpperCase()+e.slice(1)).join(``)}function Om(e){let{name:t,viewBox:n,elements:r}=e;return L({name:`PisIcon${Dm(t)}`,props:{size:{type:Number,default:16,validator:e=>Tm.includes(e)},label:{type:String,default:``}},setup(e){return()=>Qa(`svg`,{width:e.size,height:e.size,viewBox:n,fill:`none`,"aria-hidden":e.label?void 0:`true`,role:e.label?`img`:void 0,"aria-label":e.label?e.label:void 0,style:Em},r.map(e=>Qa(e.tag,e.attrs)))}})}var km=Om({name:`arrow-right`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M2 15.9998C2 16.5521 2.44772 16.9998 3 16.9998L26.7487 16.9998L19.2221 25.3296C18.8519 25.7394 18.8839 26.3717 19.2937 26.742C19.7035 27.1122 20.3358 27.0802 20.7061 26.6704L29.742 16.6703C30.086 16.2895 30.086 15.7101 29.742 15.3294L20.7061 5.32957C20.3358 4.91979 19.7034 4.88777 19.2937 5.25805C18.8839 5.62832 18.8519 6.26067 19.2221 6.67045L26.7486 14.9998L3 14.9998C2.44772 14.9998 2 15.4475 2 15.9998Z`,fill:`currentColor`}}]}),Am=Om({name:`arrow-right-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M0 7.98143C-1.20706e-08 8.25757 0.223858 8.48143 0.5 8.48143L14.2156 8.48143L9.14818 13.1316C8.94472 13.3183 8.93114 13.6346 9.11784 13.8381C9.30455 14.0415 9.62084 14.0551 9.8243 13.8684L15.8381 8.34982C15.9415 8.25493 16.0002 8.12094 16 7.98059C15.9998 7.84023 15.9405 7.70644 15.8368 7.6119L9.82306 2.13047C9.61897 1.94445 9.30273 1.9591 9.11671 2.16318C8.93069 2.36727 8.94533 2.68351 9.14942 2.86953L14.2092 7.48143L0.5 7.48143C0.223858 7.48143 1.20706e-08 7.70528 0 7.98143Z`,fill:`currentColor`}}]}),jm=Om({name:`check-mark-circle`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M10.7373 15.2742C10.3504 14.8801 9.71724 14.8742 9.32311 15.2611C8.92897 15.6479 8.92309 16.2811 9.30996 16.6752L13.2553 20.6945C13.4418 20.8846 13.6965 20.9924 13.9628 20.994C14.2291 20.9957 14.485 20.891 14.6739 20.7033L22.7067 12.7189C23.0984 12.3296 23.1003 11.6964 22.7109 11.3047C22.3216 10.913 21.6884 10.9111 21.2967 11.3005L13.9777 18.5754L10.7373 15.2742Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M16 2C8.26801 2 2 8.26801 2 16C2 23.732 8.26801 30 16 30C23.732 30 30 23.732 30 16C30 8.26801 23.732 2 16 2ZM4 16C4 9.37258 9.37258 4 16 4C22.6274 4 28 9.37258 28 16C28 22.6274 22.6274 28 16 28C9.37258 28 4 22.6274 4 16Z`,fill:`currentColor`}}]}),Mm=Om({name:`check-mark-circle-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M4.86627 7.80765C4.67227 7.61114 4.35569 7.60911 4.15918 7.80311C3.96267 7.99712 3.96064 8.3137 4.15465 8.51021L6.4648 10.8502C6.55817 10.9447 6.68535 10.9982 6.81825 10.9989C6.95115 10.9995 7.07884 10.9472 7.1731 10.8535L11.8562 6.19863C12.052 6.00396 12.053 5.68738 11.8583 5.49153C11.6636 5.29568 11.3471 5.29472 11.1512 5.48939L6.82395 9.79058L4.86627 7.80765Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16C12.4183 16 16 12.4183 16 8C16 3.58172 12.4183 0 8 0ZM1 8C1 4.13401 4.13401 1 8 1C11.866 1 15 4.13401 15 8C15 11.866 11.866 15 8 15C4.13401 15 1 11.866 1 8Z`,fill:`currentColor`}}]}),Nm=Om({name:`chevron-down`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M7.29971 11.2818C7.69396 10.9009 8.32709 10.9069 8.71386 11.2951L16 18.6091L23.2861 11.2951C23.6729 10.9069 24.306 10.9009 24.7003 11.2818C25.0945 11.6626 25.1006 12.2861 24.7139 12.6744L16.7139 20.7049C16.5258 20.8936 16.2685 21 16 21C15.7315 21 15.4742 20.8936 15.2861 20.7049L7.28614 12.6744C6.89938 12.2861 6.90546 11.6626 7.29971 11.2818Z`,fill:`currentColor`}}]}),Pm=Om({name:`chevron-down-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M3.16703 5.12929C3.37231 4.94459 3.68845 4.96127 3.87316 5.16654L8.00024 9.75328L12.1267 5.17262C12.3115 4.96745 12.6277 4.95096 12.8328 5.13579C13.038 5.32061 13.0545 5.63677 12.8697 5.84193L8.37151 10.8352C8.27666 10.9405 8.14158 11.0006 7.99987 11.0006C7.85816 11.0005 7.72312 10.9403 7.62833 10.835L3.12978 5.83542C2.94508 5.63014 2.96175 5.314 3.16703 5.12929Z`,fill:`currentColor`}}]}),Fm=Om({name:`chevron-left`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M20.7182 24.7003C21.0991 24.306 21.0931 23.6729 20.7049 23.2861L13.3909 16L20.7049 8.71386C21.0931 8.32709 21.0991 7.69396 20.7182 7.29971C20.3374 6.90546 19.7139 6.89938 19.3256 7.28614L11.2951 15.2861C11.1064 15.4742 11 15.7315 11 16C11 16.2685 11.1064 16.5258 11.2951 16.7139L19.3256 24.7139C19.7139 25.1006 20.3374 25.0945 20.7182 24.7003Z`,fill:`currentColor`}}]}),Im=Om({name:`chevron-left-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M10.8713 3.16752C11.056 3.3728 11.0393 3.68894 10.834 3.87364L6.24728 8.00073L10.8279 12.1272C11.0331 12.312 11.0496 12.6282 10.8648 12.8333C10.6799 13.0385 10.3638 13.055 10.1586 12.8702L5.16534 8.372C5.06005 8.27715 4.99996 8.14207 5 8.00036C5.00004 7.85865 5.06022 7.72361 5.16556 7.62882L10.1651 3.13027C10.3704 2.94557 10.6866 2.96224 10.8713 3.16752Z`,fill:`currentColor`}}]}),Lm=Om({name:`chevron-right`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M11.2818 24.7003C10.9009 24.306 10.9069 23.6729 11.2951 23.2861L18.6091 16L11.2951 8.71386C10.9069 8.32709 10.9009 7.69396 11.2818 7.29971C11.6626 6.90546 12.2861 6.89938 12.6744 7.28614L20.7049 15.2861C20.8936 15.4742 21 15.7315 21 16C21 16.2685 20.8936 16.5258 20.7049 16.7139L12.6744 24.7139C12.2861 25.1006 11.6626 25.0945 11.2818 24.7003Z`,fill:`currentColor`}}]}),Rm=Om({name:`chevron-right-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M5.12832 12.8331C4.94361 12.6278 4.96029 12.3117 5.16557 12.127L9.7523 7.99991L5.17165 3.87345C4.96648 3.68862 4.94999 3.37247 5.13481 3.1673C5.31964 2.96213 5.63579 2.94564 5.84096 3.13047L10.8342 7.62864C10.9395 7.72349 10.9996 7.85857 10.9996 8.00028C10.9995 8.14199 10.9394 8.27703 10.834 8.37182L5.83444 12.8704C5.62917 13.0551 5.31302 13.0384 5.12832 12.8331Z`,fill:`currentColor`}}]}),zm=Om({name:`chevron-up`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M7.29971 20.7182C7.69396 21.0991 8.32709 21.0931 8.71386 20.7049L16 13.3909L23.2861 20.7049C23.6729 21.0931 24.306 21.0991 24.7003 20.7182C25.0945 20.3374 25.1006 19.7139 24.7139 19.3256L16.7139 11.2951C16.5258 11.1064 16.2685 11 16 11C15.7315 11 15.4742 11.1064 15.2861 11.2951L7.28614 19.3256C6.89938 19.7139 6.90546 20.3374 7.29971 20.7182Z`,fill:`currentColor`}}]}),Bm=Om({name:`chevron-up-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M3.16703 10.8722C3.37231 11.0569 3.68845 11.0403 3.87316 10.835L8.00024 6.24826L12.1267 10.8289C12.3115 11.0341 12.6277 11.0506 12.8328 10.8657C13.038 10.6809 13.0545 10.3648 12.8697 10.1596L8.37151 5.16632C8.27666 5.06103 8.14158 5.00094 7.99987 5.00098C7.85816 5.00102 7.72312 5.06119 7.62833 5.16654L3.12978 10.1661C2.94508 10.3714 2.96175 10.6875 3.16703 10.8722Z`,fill:`currentColor`}}]}),Vm=Om({name:`cross-close`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M7.29946 23.2861C6.90521 23.6729 6.89914 24.306 7.2859 24.7003C7.67266 25.0945 8.3058 25.1006 8.70005 24.7139L16 17.5526L23.3 24.7139C23.6942 25.1006 24.3273 25.0945 24.7141 24.7003C25.1009 24.306 25.0948 23.6729 24.7005 23.2861L17.2733 16L24.7005 8.71386C25.0948 8.32709 25.1009 7.69396 24.7141 7.29971C24.3273 6.90546 23.6942 6.89938 23.3 7.28614L16 14.4474L8.70005 7.28614C8.3058 6.89938 7.67266 6.90546 7.2859 7.29971C6.89914 7.69396 6.90521 8.32709 7.29946 8.71386L14.7267 16L7.29946 23.2861Z`,fill:`currentColor`}}]}),Hm=Om({name:`cross-close-circle`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M9.28627 22.7062C8.89951 22.3119 8.90558 21.6788 9.29983 21.292L14.6883 16.0059L9.29983 10.7197C8.90558 10.333 8.89951 9.69982 9.28627 9.30557C9.67303 8.91131 10.3062 8.90524 10.7004 9.292L16.0003 14.4912L21.3002 9.292C21.6944 8.90524 22.3276 8.91131 22.7143 9.30557C23.1011 9.69982 23.095 10.333 22.7008 10.7197L17.3123 16.0059L22.7008 21.292C23.095 21.6788 23.1011 22.3119 22.7143 22.7062C22.3276 23.1004 21.6944 23.1065 21.3002 22.7197L16.0003 17.5205L10.7004 22.7197C10.3062 23.1065 9.67303 23.1004 9.28627 22.7062Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M16 2C8.26801 2 2 8.26801 2 16C2 23.732 8.26801 30 16 30C23.732 30 30 23.732 30 16C30 8.26801 23.732 2 16 2ZM4 16C4 9.37258 9.37258 4 16 4C22.6274 4 28 9.37258 28 16C28 22.6274 22.6274 28 16 28C9.37258 28 4 22.6274 4 16Z`,fill:`currentColor`}}]}),Um=Om({name:`cross-close-circle-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M4.13178 11.8379C3.93653 11.6426 3.93654 11.3261 4.13181 11.1308L7.27814 7.98473L4.13181 4.83865C3.93654 4.6434 3.93653 4.32682 4.13178 4.13155C4.32704 3.93628 4.64362 3.93627 4.83889 4.13152L7.98584 7.27822L11.1318 4.1325C11.3271 3.93724 11.6437 3.93725 11.8389 4.13252C12.0342 4.32779 12.0342 4.64438 11.8389 4.83963L8.69256 7.98571L11.8389 11.1318C12.0342 11.327 12.0342 11.6436 11.8389 11.8389C11.6437 12.0342 11.3271 12.0342 11.1318 11.8389L7.98486 8.69222L4.83889 11.8379C4.64362 12.0332 4.32704 12.0332 4.13178 11.8379Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M0 8C0 3.58172 3.58172 0 8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8ZM8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1Z`,fill:`currentColor`}}]}),Wm=Om({name:`cross-close-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M3.14646 12.1455C2.95119 12.3408 2.95118 12.6574 3.14643 12.8526C3.34169 13.0479 3.65827 13.0479 3.85354 12.8527L7.99951 8.70701L12.1465 12.8536C12.3417 13.0489 12.6583 13.0489 12.8536 12.8536C13.0488 12.6583 13.0488 12.3417 12.8535 12.1465L8.70723 8.00052L12.8535 3.85454C13.0488 3.65929 13.0488 3.34271 12.8536 3.14744C12.6583 2.95217 12.3417 2.95215 12.1465 3.14741L8.00049 7.29305L3.85354 3.14643C3.65827 2.95118 3.34169 2.95119 3.14643 3.14646C2.95118 3.34173 2.95119 3.65831 3.14646 3.85357L7.29277 7.99954L3.14646 12.1455Z`,fill:`currentColor`}}]}),Gm=Om({name:`data-table-grid`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M5 4C3.34315 4 2 5.34314 2 7V25C2 26.6569 3.34315 28 5 28H27C28.6569 28 30 26.6569 30 25V7C30 5.34315 28.6569 4 27 4H5ZM4 7C4 6.44772 4.44771 6 5 6H27C27.5523 6 28 6.44772 28 7V10H4V7ZM4 12H10L10 26H5C4.44772 26 4 25.5523 4 25V12ZM20.001 26H12L12 12H20.001L20.001 26ZM22.001 26L22.001 12H28V25C28 25.5523 27.5523 26 27 26H22.001Z`,fill:`currentColor`}}]}),Km=Om({name:`data-table-grid-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M1.5 2C0.671573 2 0 2.67157 0 3.5V12.5C0 13.3284 0.671573 14 1.5 14H14.5C15.3284 14 16 13.3284 16 12.5V3.5C16 2.67157 15.3284 2 14.5 2H1.5ZM1 3.5C1 3.22386 1.22386 3 1.5 3H14.5C14.7761 3 15 3.22386 15 3.5V4.99609H1V3.5ZM1 5.99609H5L5 13H1.5C1.22386 13 1 12.7761 1 12.5V5.99609ZM10 13H6L6 5.99609H10L10 13ZM11 13L11 5.99609H15V12.5C15 12.7761 14.7761 13 14.5 13H11Z`,fill:`currentColor`}}]}),qm=Om({name:`download`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M17 4C17 3.44772 16.5523 3 16 3C15.4477 3 15 3.44772 15 4V20.5916L9.70682 15.3027C9.31614 14.9123 8.68297 14.9126 8.29261 15.3033C7.90224 15.6939 7.9025 16.3271 8.29318 16.7175L15.2932 23.7118C15.6836 24.1019 16.3164 24.1019 16.7068 23.7118L23.7068 16.7175C24.0975 16.3271 24.0978 15.6939 23.7074 15.3033C23.317 14.9126 22.6839 14.9123 22.2932 15.3027L17 20.5916V4Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M5 16.0098C5 15.4575 4.55228 15.0098 4 15.0098C3.44772 15.0098 3 15.4575 3 16.0098V26C3 27.6569 4.34315 29 6 29H26C27.6569 29 29 27.6569 29 26V16.0098C29 15.4575 28.5523 15.0098 28 15.0098C27.4477 15.0098 27 15.4575 27 16.0098V26C27 26.5523 26.5523 27 26 27H6C5.44772 27 5 26.5523 5 26V16.0098Z`,fill:`currentColor`}}]}),Jm=Om({name:`download-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M8.50047 1.5C8.50047 1.22386 8.27661 1 8.00047 1C7.72433 1 7.50047 1.22386 7.50047 1.5V10.1752L4.87468 7.16701C4.69308 6.95898 4.37723 6.93754 4.16919 7.11913C3.96116 7.30073 3.93972 7.61658 4.12131 7.82462L7.62379 11.8371C7.71855 11.9457 7.85554 12.0081 7.99963 12.0083C8.14373 12.0086 8.28093 11.9466 8.37605 11.8384L11.9023 7.82588C12.0846 7.61845 12.0642 7.30252 11.8568 7.12024C11.6493 6.93795 11.3334 6.95833 11.1511 7.16576L8.50047 10.1819V1.5Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2 7.50586C2 7.22972 1.77614 7.00586 1.5 7.00586C1.22386 7.00586 1 7.22972 1 7.50586V13.5C1 14.3285 1.67157 15 2.5 15H13.5C14.3284 15 15 14.3285 15 13.5V7.50586C15 7.22972 14.7761 7.00586 14.5 7.00586C14.2239 7.00586 14 7.22972 14 7.50586V13.5C14 13.7762 13.7761 14 13.5 14H2.5C2.22386 14 2 13.7762 2 13.5V7.50586Z`,fill:`currentColor`}}]}),Ym=Om({name:`expand-maximize`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M12.2963 13.7198C12.6863 14.1103 13.3187 14.1103 13.7087 13.7198C14.0987 13.3292 14.0987 12.6961 13.7087 12.3056L6.41019 4.99821L10.9952 4.99852C11.5468 4.99855 11.994 4.55087 11.994 3.99858C11.994 3.4463 11.5469 2.99855 10.9953 2.99852L3.99886 2.99805C3.73397 2.99803 3.47993 3.10338 3.29262 3.29091C3.1053 3.47845 3.00007 3.73281 3.00007 3.99804L3 11.0018C3 11.5541 3.44714 12.0019 3.99872 12.0019C4.5503 12.0019 4.99745 11.5542 4.99746 11.0019L4.9975 6.41214L12.2963 13.7198Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M19.7154 18.2907C19.3254 17.9001 18.693 17.9001 18.303 18.2907C17.913 18.6812 17.913 19.3143 18.303 19.7049L25.5899 27.0011L21.0048 27.0007C20.4532 27.0007 20.006 27.4484 20.006 28.0007C20.006 28.553 20.4531 29.0007 21.0047 29.0007L28.0011 29.0012C28.266 29.0012 28.5201 28.8959 28.7074 28.7083C28.8947 28.5208 28.9999 28.2664 28.9999 28.0012L29 20.9974C29 20.4451 28.5529 19.9974 28.0013 19.9974C27.4497 19.9974 27.0026 20.4451 27.0025 20.9974L27.0025 25.587L19.7154 18.2907Z`,fill:`currentColor`}}]}),Xm=Om({name:`expand-maximize-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M6.15245 6.89886C6.34667 7.09445 6.66261 7.09551 6.85813 6.90122C7.05365 6.70692 7.05471 6.39086 6.86049 6.19526L2.69823 2.00348L5.49912 2.004C5.77471 2.00406 5.99816 1.7806 5.99821 1.50491C5.99826 1.22922 5.7749 1.00568 5.49931 1.00563L1.49909 1.00488C1.36673 1.00486 1.23979 1.05744 1.14619 1.15106C1.05259 1.24468 1 1.37166 1 1.50407V5.50186C1 5.77756 1.22341 6.00105 1.499 6.00105C1.77458 6.00105 1.99799 5.77756 1.99799 5.50186L1.99799 2.71493L6.15245 6.89886Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.84959 9.14654C9.65472 8.95159 9.33877 8.95159 9.1439 9.14654C8.94903 9.34148 8.94903 9.65755 9.1439 9.8525L13.2961 14.0063L10.5009 14.0058C10.2253 14.0057 10.0018 14.2292 10.0018 14.5049C10.0017 14.7805 10.2251 15.0041 10.5007 15.0041L14.5009 15.0049C14.6333 15.0049 14.7602 14.9523 14.8538 14.8587C14.9474 14.7651 15 14.6381 15 14.5057V10.5079C15 10.2322 14.7766 10.0087 14.501 10.0087C14.2254 10.0087 14.002 10.2322 14.002 10.5079L14.002 13.3006L9.84959 9.14654Z`,fill:`currentColor`}}]}),Zm=Om({name:`eye-show-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M10.9875 7.99512C10.9875 9.65197 9.6444 10.9951 7.98755 10.9951C6.33069 10.9951 4.98755 9.65197 4.98755 7.99512C4.98755 6.33826 6.33069 4.99512 7.98755 4.99512C9.6444 4.99512 10.9875 6.33826 10.9875 7.99512Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M7.98759 1.99512C4.31542 1.99512 1.22275 4.45054 0.0561844 7.83206L0 7.99492L0.0560619 8.15782C1.22277 11.548 4.31596 13.9951 7.98759 13.9951C11.6592 13.9951 14.7524 11.548 15.9191 8.15782L15.9751 7.99512L15.9191 7.83241C14.7524 4.44221 11.6592 1.99512 7.98759 1.99512ZM7.98759 12.9951C4.84011 12.9951 2.14175 10.934 1.05965 7.99532C2.14198 5.06311 4.84074 2.99512 7.98759 2.99512C11.1351 2.99512 13.8336 5.0563 14.9156 7.99512C13.8336 10.9339 11.1351 12.9951 7.98759 12.9951Z`,fill:`currentColor`}}]}),Qm=Om({name:`file-document`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M9.98779 11H13.0527C13.605 11 14.0527 10.5523 14.0527 10C14.0527 9.44772 13.605 9 13.0527 9L9.98779 9C9.43551 9 8.98779 9.44772 8.98779 10C8.98779 10.5523 9.43551 11 9.98779 11Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M17.0007 15L9.9878 15C9.43551 15 8.98779 14.5523 8.98779 14C8.98779 13.4477 9.43551 13 9.98779 13L17.0006 13C17.5529 13 18.0007 13.4477 18.0007 14C18.0007 14.5523 17.5529 15 17.0007 15Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.98779 19L19.014 19C19.5663 19 20.014 18.5523 20.014 18C20.014 17.4477 19.5663 17 19.014 17L9.98779 17C9.43551 17 8.98779 17.4477 8.98779 18C8.98779 18.5523 9.43551 19 9.98779 19Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M18.2515 2L7.999 2.00006C6.34216 2.00007 4.99902 3.34321 4.99902 5.00006V27C4.99902 28.6569 6.34217 30 7.99902 30H23.9995C25.6564 30 26.9995 28.6568 26.9995 27V9.92C26.9995 9.0435 26.6162 8.21085 25.9503 7.64089L20.2024 2.72089C19.6588 2.25567 18.967 2 18.2515 2ZM7.99902 4.00006L18.2515 4C18.49 4 18.7207 4.08522 18.9018 4.2403L24.6498 9.1603C24.8717 9.35028 24.9995 9.62783 24.9995 9.92V27C24.9995 27.5523 24.5518 28 23.9995 28H7.99902C7.44674 28 6.99902 27.5523 6.99902 27V5.00006C6.99902 4.44778 7.44673 4.00007 7.99902 4.00006Z`,fill:`currentColor`}}]}),$m=Om({name:`file-document-analyse-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M3.55839 1.00004L9.54107 1C9.66911 0.999999 9.79264 1.04557 9.88791 1.12796L13.2497 4.03516C13.3594 4.12999 13.422 4.26525 13.422 4.4072V12.3183L14.4603 13.3183V4.4072C14.4603 3.98136 14.2723 3.57558 13.9434 3.29108L10.5816 0.383882C10.2958 0.136715 9.92519 -2.41383e-06 9.54107 0L3.55838 3.77895e-05C2.69825 4.32135e-05 2.00098 0.671616 2.00098 1.50004V14.5C2.00098 15.3284 2.69825 16 3.55839 16H12.8534L11.8151 15H3.55839C3.27168 15 3.03925 14.7761 3.03925 14.5V1.50004C3.03925 1.2239 3.27168 1.00004 3.55839 1.00004Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M10.3653 12.1961C9.811 12.6954 9.06586 13.0009 8.2454 13.0009C6.52513 13.0009 5.12522 11.6578 5.11861 10.001C5.11201 8.34411 6.5012 7.00098 8.22147 7.00098C9.94174 7.00098 11.3417 8.34411 11.3483 10.001C11.3503 10.5031 11.224 10.9765 10.9992 11.3924L14.8493 15.1006C15.0521 15.2958 15.0514 15.6118 14.8479 15.8063C14.6444 16.0008 14.3151 16.0002 14.1123 15.8049L10.3653 12.1961ZM10.3141 10.0047C10.3097 8.89593 9.37286 7.99707 8.22161 7.99707C7.07036 7.99707 6.14068 8.89593 6.1451 10.0047C6.14952 11.1135 7.08638 12.0124 8.23763 12.0124C9.38888 12.0124 10.3186 11.1135 10.3141 10.0047Z`,fill:`currentColor`}}]}),eh=Om({name:`file-document-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M4.50488 5.00195C4.22874 5.00195 4.00488 5.22581 4.00488 5.50195C4.00488 5.77809 4.22874 6.00195 4.50488 6.00195L6.50109 6.00196C6.77723 6.00196 7.00109 5.7781 7.00109 5.50196C7.00109 5.22581 6.77724 5.00196 6.50109 5.00196L4.50488 5.00195Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8.5034 8L4.50488 8.00001C4.22874 8.00001 4.00488 7.77615 4.00488 7.50001C4.00488 7.22387 4.22874 7.00001 4.50488 7.00001L8.50339 7C8.77954 7 9.00339 7.22386 9.00339 7.5C9.00339 7.77614 8.77954 8 8.5034 8Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M4.50488 10.0049L9.50391 10.0049C9.78005 10.0049 10.0039 9.78103 10.0039 9.50488C10.0039 9.22874 9.78005 9.00488 9.50391 9.00488L4.50488 9.00488C4.22874 9.00488 4.00488 9.22874 4.00488 9.50488C4.00488 9.78102 4.22874 10.0049 4.50488 10.0049Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M3.50195 0.000976562C2.67353 0.000976562 2.00195 0.672551 2.00195 1.50098V14.4983C2.00195 15.3267 2.67353 15.9983 3.50195 15.9983H12.502C13.3304 15.9983 14.002 15.3267 14.002 14.4983V4.9645C14.002 4.54538 13.8266 4.14538 13.5184 3.86138L9.75952 0.397864C9.48255 0.142655 9.11971 0.000976562 8.74309 0.000976562H3.50195ZM3.00195 1.50098C3.00195 1.22483 3.22581 1.00098 3.50195 1.00098H8.74309C8.86863 1.00098 8.98957 1.0482 9.0819 1.13327L12.8408 4.59679C12.9435 4.69146 13.002 4.82479 13.002 4.9645V14.4983C13.002 14.7744 12.7781 14.9983 12.502 14.9983H3.50195C3.22581 14.9983 3.00195 14.7744 3.00195 14.4983V1.50098Z`,fill:`currentColor`}}]}),th=Om({name:`folder-open`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M2 7C2 5.34315 3.34315 4 5 4H9.21505C10.1117 4 10.9613 4.40103 11.5311 5.09323L13.6338 7.6473C13.8238 7.87803 14.107 8.01171 14.4059 8.01171H22C23.6569 8.01171 25 9.35485 25 11.0117V12H26.9999C28.9931 12 30.4321 13.9077 29.8845 15.8242L27.0274 25.8242C26.6594 27.1121 25.4822 28 24.1428 28H5C3.34315 28 2 26.6569 2 25V7ZM4 22.1398L6.27542 14.1758C6.64339 12.8879 7.82055 12 9.15999 12H23V11.0117C23 10.4594 22.5523 10.0117 22 10.0117H14.4059C13.5093 10.0117 12.6596 9.61068 12.0898 8.91847L9.98708 6.36441C9.79712 6.13368 9.51392 6 9.21505 6H5C4.44772 6 4 6.44772 4 7V22.1398ZM8.19847 14.7253L5.34133 24.7253C5.15881 25.3641 5.63847 26 6.30285 26H24.1428C24.5893 26 24.9817 25.704 25.1043 25.2747L27.9615 15.2747C28.144 14.6359 27.6643 14 26.9999 14H9.15999C8.71351 14 8.32113 14.296 8.19847 14.7253Z`,fill:`currentColor`}}]}),nh=Om({name:`folder-open-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M0.00195312 2.50138C0.00195312 1.67327 0.67428 1.00195 1.50364 1.00195H4.24872C4.65792 1.00195 5.0494 1.16869 5.33262 1.46361L6.66676 2.85286C6.76116 2.95117 6.89165 3.00675 7.02806 3.00675H11.5213C12.3507 3.00675 13.023 3.67807 13.023 4.50618V5.99662H14.4993C15.4979 5.99662 16.2183 6.95159 15.9427 7.90988L14.2174 13.9091C14.0326 14.5519 13.4438 14.9947 12.7741 14.9947H11.6697C11.6209 14.9995 11.5714 15.002 11.5213 15.002H1.50364C0.674281 15.002 0.00195312 14.3306 0.00195312 13.5025V2.50138ZM1.00308 12.2455L2.48796 7.08221C2.6728 6.43946 3.26158 5.99662 3.93132 5.99662H12.0219V4.50618C12.0219 4.23014 11.7978 4.00637 11.5213 4.00637H7.02806C6.61885 4.00637 6.22737 3.83963 5.94415 3.54471L4.61002 2.15546C4.51561 2.05715 4.38512 2.00157 4.24872 2.00157H1.50364C1.22719 2.00157 1.00308 2.22534 1.00308 2.50138V12.2455ZM3.4502 7.3581L1.72491 13.3574C1.63305 13.6768 1.87319 13.9951 2.20603 13.9951H12.7741C12.9973 13.9951 13.1936 13.8475 13.2552 13.6332L14.9805 7.63399C15.0723 7.31456 14.8322 6.99624 14.4993 6.99624H3.93132C3.70807 6.99624 3.51181 7.14385 3.4502 7.3581Z`,fill:`currentColor`}}]}),rh=Om({name:`funnel-filter`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M5.71847 5.00069C5.32167 5.00069 5 5.32247 5 5.71941C5 5.90703 5.07334 6.08721 5.20435 6.22146L12.145 13.3339C12.692 13.8945 12.9982 14.6468 12.9982 15.4302V23.6271C12.9982 23.9802 13.1842 24.307 13.4877 24.4873L17.473 26.8545C18.1396 27.2505 18.9836 26.7699 18.9836 25.9944V15.4329C18.9836 14.6471 19.2917 13.8927 19.8417 13.3316L26.7911 6.24277C26.925 6.10619 27 5.92254 27 5.73125C27 5.32777 26.673 5.00069 26.2697 5.00069H5.71847ZM3 5.71941C3 4.21752 4.2171 3 5.71847 3H26.2697C27.7776 3 29 4.22282 29 5.73125C29 6.44639 28.7196 7.133 28.2191 7.64359L21.2696 14.7325C21.0863 14.9195 20.9836 15.1709 20.9836 15.4329V25.9944C20.9836 28.3209 18.4517 29.7626 16.4519 28.5748L12.4666 26.2076C11.5562 25.6668 10.9982 24.6862 10.9982 23.6271V15.4302C10.9982 15.1691 10.8962 14.9183 10.7138 14.7314L3.7732 7.61901C3.27749 7.11104 3 6.42929 3 5.71941Z`,fill:`currentColor`}}]}),ih=Om({name:`funnel-filter-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M2.42155 2.00051C2.18873 2.00051 2 2.18934 2 2.42228C2 2.53046 2.04155 2.63451 2.11607 2.71291L5.58739 6.36526C5.85254 6.64423 6.0004 7.01447 6.0004 7.39944V11.8262C6.0004 12.0077 6.09871 12.175 6.25726 12.2633L9.25831 13.9342C9.59158 14.1198 10.0014 13.8787 10.0014 13.4971V7.4C10.0014 7.01453 10.1497 6.64384 10.4155 6.36476L13.8818 2.7248C13.9577 2.64509 14 2.53922 14 2.42913C14 2.19241 13.8082 2.00051 13.5716 2.00051H2.42155ZM1 2.42228C1 1.63677 1.63645 1 2.42155 1H13.5716C14.3605 1 15 1.63984 15 2.42913C15 2.7962 14.8588 3.1492 14.6058 3.41496L11.1394 7.05492C11.0509 7.14795 11.0014 7.27151 11.0014 7.4V13.4971C11.0014 14.6419 9.77185 15.3651 8.77204 14.8085L5.771 13.1375C5.29532 12.8727 5.0004 12.3708 5.0004 11.8262V7.39944C5.0004 7.27112 4.95111 7.1477 4.86273 7.05471L1.3914 3.40237C1.14013 3.13799 1 2.78711 1 2.42228Z`,fill:`currentColor`}}]}),ah=Om({name:`grid-matrix`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M3 6C3 4.34315 4.34315 3 6 3C7.65685 3 9 4.34315 9 6C9 7.65685 7.65685 9 6 9C4.34315 9 3 7.65685 3 6Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M13.0005 6C13.0005 4.34315 14.3436 3 16.0005 3C17.6573 3 19.0005 4.34315 19.0005 6C19.0005 7.65685 17.6573 9 16.0005 9C14.3436 9 13.0005 7.65685 13.0005 6Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M26.001 3C24.3441 3 23.001 4.34315 23.001 6C23.001 7.65685 24.3441 9 26.001 9C27.6578 9 29.001 7.65685 29.001 6C29.001 4.34315 27.6578 3 26.001 3Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M3 16C3 14.3431 4.34315 13 6 13C7.65685 13 9 14.3431 9 16C9 17.6569 7.65685 19 6 19C4.34315 19 3 17.6569 3 16Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6 23C4.34315 23 3 24.3431 3 26C3 27.6569 4.34315 29 6 29C7.65685 29 9 27.6569 9 26C9 24.3431 7.65685 23 6 23Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M13.0005 16C13.0005 14.3431 14.3436 13 16.0005 13C17.6573 13 19.0005 14.3431 19.0005 16C19.0005 17.6569 17.6573 19 16.0005 19C14.3436 19 13.0005 17.6569 13.0005 16Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M16.0005 23C14.3436 23 13.0005 24.3431 13.0005 26C13.0005 27.6569 14.3436 29 16.0005 29C17.6573 29 19.0005 27.6569 19.0005 26C19.0005 24.3431 17.6573 23 16.0005 23Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M23.001 16C23.001 14.3431 24.3441 13 26.001 13C27.6578 13 29.001 14.3431 29.001 16C29.001 17.6569 27.6578 19 26.001 19C24.3441 19 23.001 17.6569 23.001 16Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M26.001 23C24.3441 23 23.001 24.3431 23.001 26C23.001 27.6569 24.3441 29 26.001 29C27.6578 29 29.001 27.6569 29.001 26C29.001 24.3431 27.6578 23 26.001 23Z`,fill:`currentColor`}}]}),oh=Om({name:`grid-matrix-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M0.999878 2.49805C0.999878 1.66962 1.67145 0.998047 2.49988 0.998047C3.32831 0.998047 3.99988 1.66962 3.99988 2.49805C3.99988 3.32647 3.32831 3.99805 2.49988 3.99805C1.67145 3.99805 0.999878 3.32647 0.999878 2.49805Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6.49982 2.49805C6.49982 1.66962 7.17139 0.998047 7.99982 0.998047C8.82824 0.998047 9.49982 1.66962 9.49982 2.49805C9.49982 3.32647 8.82824 3.99805 7.99982 3.99805C7.17139 3.99805 6.49982 3.32647 6.49982 2.49805Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M13.4999 0.998047C12.6715 0.998047 11.9999 1.66962 11.9999 2.49805C11.9999 3.32647 12.6715 3.99805 13.4999 3.99805C14.3283 3.99805 14.9999 3.32647 14.9999 2.49805C14.9999 1.66962 14.3283 0.998047 13.4999 0.998047Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M0.999512 7.99609C0.999512 7.16767 1.67108 6.49609 2.49951 6.49609C3.32794 6.49609 3.99951 7.16767 3.99951 7.99609C3.99951 8.82452 3.32794 9.49609 2.49951 9.49609C1.67108 9.49609 0.999512 8.82452 0.999512 7.99609Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2.49988 11.998C1.67145 11.998 0.999878 12.6696 0.999878 13.498C0.999878 14.3265 1.67145 14.998 2.49988 14.998C3.32831 14.998 3.99988 14.3265 3.99988 13.498C3.99988 12.6696 3.32831 11.998 2.49988 11.998Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6.49951 7.99609C6.49951 7.16767 7.17108 6.49609 7.99951 6.49609C8.82794 6.49609 9.49951 7.16767 9.49951 7.99609C9.49951 8.82452 8.82794 9.49609 7.99951 9.49609C7.17108 9.49609 6.49951 8.82452 6.49951 7.99609Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8.00354 11.998C7.17511 11.998 6.50354 12.6696 6.50354 13.498C6.50354 14.3265 7.17511 14.998 8.00354 14.998C8.83197 14.998 9.50354 14.3265 9.50354 13.498C9.50354 12.6696 8.83197 11.998 8.00354 11.998Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M11.9995 7.99609C11.9995 7.16767 12.6711 6.49609 13.4995 6.49609C14.3279 6.49609 14.9995 7.16767 14.9995 7.99609C14.9995 8.82452 14.3279 9.49609 13.4995 9.49609C12.6711 9.49609 11.9995 8.82452 11.9995 7.99609Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M13.4999 11.998C12.6715 11.998 11.9999 12.6696 11.9999 13.498C11.9999 14.3265 12.6715 14.998 13.4999 14.998C14.3283 14.998 14.9999 14.3265 14.9999 13.498C14.9999 12.6696 14.3283 11.998 13.4999 11.998Z`,fill:`currentColor`}}]}),sh=Om({name:`house-home`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M16.7196 5.30621C16.3264 4.89858 15.6736 4.89858 15.2804 5.30621L5.28036 15.6729C5.10051 15.8594 5 16.1084 5 16.3674V25.9993C5 26.5517 5.44772 26.9995 6 26.9995H11.0063C11.5586 26.9995 12.0063 26.5517 12.0063 25.9993V20.0015C12.0063 18.3442 13.3494 17.0008 15.0063 17.0008H16.986C18.6428 17.0008 19.986 18.3442 19.986 20.0015V25.9993C19.986 26.5517 20.4337 26.9995 20.986 26.9995H26C26.5523 26.9995 27 26.5517 27 25.9993V16.3674C27 16.1084 26.8995 15.8594 26.7196 15.6729L16.7196 5.30621ZM13.8411 3.91717C15.0207 2.69427 16.9793 2.69428 18.1589 3.91717L28.1589 14.2839C28.6985 14.8432 29 15.5902 29 16.3674V25.9993C29 27.6565 27.6569 29 26 29H20.986C19.3291 29 17.986 27.6565 17.986 25.9993V20.0015C17.986 19.4491 17.5383 19.0013 16.986 19.0013H15.0063C14.454 19.0013 14.0063 19.4491 14.0063 20.0015V25.9993C14.0063 27.6565 12.6631 29 11.0063 29H6C4.34315 29 3 27.6565 3 25.9993V16.3674C3 15.5902 3.30153 14.8432 3.84109 14.2839L13.8411 3.91717Z`,fill:`currentColor`}}]}),ch=Om({name:`house-home-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M8.36173 2.16121C8.16421 1.95101 7.83028 1.95107 7.63284 2.16135L2.13549 8.01633C2.04845 8.10903 2 8.23141 2 8.35857V13.4993C2 13.7755 2.22386 13.9993 2.5 13.9993H5.50371C5.77985 13.9993 6.00371 13.7755 6.00371 13.4993V10.4706C6.00371 9.64213 6.67528 8.97056 7.50371 8.97056H8.49809C9.3265 8.97056 9.99806 9.6421 9.99809 10.4705L9.9982 13.4963C9.99821 13.7724 10.2221 13.9962 10.4982 13.9962H13.5C13.7761 13.9962 14 13.7724 14 13.4962L13.9998 8.35947C13.9998 8.23225 13.9513 8.10981 13.8642 8.0171L8.36173 2.16121ZM6.90382 1.47686C7.49614 0.846013 8.49793 0.845822 9.09049 1.47644L14.593 7.33232C14.8543 7.61047 14.9998 7.97778 14.9998 8.35944L15 13.4962C15 14.3246 14.3284 14.9962 13.5 14.9962H10.4982C9.66979 14.9962 8.99823 14.3247 8.9982 13.4963L8.99809 10.4705C8.99808 10.1944 8.77423 9.97056 8.49809 9.97056H7.50371C7.22756 9.97056 7.00371 10.1944 7.00371 10.4706V13.4993C7.00371 14.3278 6.33213 14.9993 5.50371 14.9993H2.5C1.67157 14.9993 1 14.3278 1 13.4993V8.35857C1 7.97709 1.14535 7.60994 1.40647 7.33183L6.90382 1.47686Z`,fill:`currentColor`}}]}),lh=Om({name:`information-circle`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M15.9991 14.5601C16.5514 14.5601 16.9991 15.0078 16.9991 15.5601V22.5627C16.9991 23.115 16.5514 23.5627 15.9991 23.5627C15.4469 23.5627 14.9991 23.115 14.9991 22.5627V15.5601C14.9991 15.0078 15.4469 14.5601 15.9991 14.5601Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M15.9991 12.5449C16.8276 12.5449 17.4991 11.8733 17.4991 11.0449C17.4991 10.2165 16.8276 9.54492 15.9991 9.54492C15.1707 9.54492 14.4991 10.2165 14.4991 11.0449C14.4991 11.8733 15.1707 12.5449 15.9991 12.5449Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2.00024 16C2.00024 8.26801 8.26826 2 16.0002 2C23.7322 2 30.0002 8.26801 30.0002 16C30.0002 23.732 23.7322 30 16.0002 30C8.26826 30 2.00024 23.732 2.00024 16ZM16.0002 4C9.37283 4 4.00024 9.37258 4.00024 16C4.00024 22.6274 9.37283 28 16.0002 28C22.6277 28 28.0002 22.6274 28.0002 16C28.0002 9.37258 22.6277 4 16.0002 4Z`,fill:`currentColor`}}]}),uh=Om({name:`information-circle-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M9.24988 4.25195C9.24988 4.94231 8.69023 5.50195 7.99988 5.50195C7.30952 5.50195 6.74988 4.94231 6.74988 4.25195C6.74988 3.5616 7.30952 3.00195 7.99988 3.00195C8.69023 3.00195 9.24988 3.5616 9.24988 4.25195Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M7.99927 7C8.55155 7 8.99927 7.44772 8.99927 8V12C8.99927 12.5523 8.55155 13 7.99927 13C7.44698 13 6.99927 12.5523 6.99927 12V8C6.99927 7.44772 7.44698 7 7.99927 7Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M7.99951 0C3.58123 0 -0.000488281 3.58172 -0.000488281 8C-0.000488281 12.4183 3.58123 16 7.99951 16C12.4178 16 15.9995 12.4183 15.9995 8C15.9995 3.58172 12.4178 0 7.99951 0ZM0.999512 8C0.999512 4.13401 4.13352 1 7.99951 1C11.8655 1 14.9995 4.13401 14.9995 8C14.9995 11.866 11.8655 15 7.99951 15C4.13352 15 0.999512 11.866 0.999512 8Z`,fill:`currentColor`}}]}),dh=Om({name:`lens-search-find`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M5.93045 5.92829C2.0209 9.83268 2.0209 16.1629 5.93045 20.0673C9.59435 23.7264 15.3917 23.9563 19.3237 20.7571L27.2895 28.7074C27.6806 29.0977 28.3145 29.0975 28.7053 28.7069C29.0961 28.3164 29.0959 27.6834 28.7049 27.293L20.7433 19.3471C23.9839 15.4196 23.7655 9.60081 20.0882 5.92829C16.1786 2.0239 9.83999 2.0239 5.93045 5.92829ZM7.34622 18.6534C4.21859 15.5299 4.21859 10.4657 7.34622 7.3422C10.4739 4.21869 15.5448 4.21868 18.6724 7.3422C21.8 10.4657 21.8 15.5299 18.6724 18.6534C15.5448 21.7769 10.4739 21.7769 7.34622 18.6534Z`,fill:`currentColor`}}]}),fh=Om({name:`lens-search-find-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M2.6154 2.60642C0.461535 4.74831 0.461535 8.22099 2.6154 10.3629C4.63699 12.3732 7.8375 12.4967 10.0039 10.7333L14.1449 14.8514C14.3407 15.0461 14.6581 15.0461 14.8539 14.8514C15.0498 14.6567 15.0498 14.341 14.854 14.1463L10.7197 10.0348C12.5638 7.87992 12.4623 4.64211 10.4152 2.60642C8.26136 0.464528 4.76926 0.464528 2.6154 2.60642ZM3.32447 9.65775C1.56222 7.90529 1.56222 5.064 3.32447 3.31155C5.08672 1.5591 7.94389 1.5591 9.70615 3.31155C11.4684 5.064 11.4684 7.90529 9.70615 9.65775C7.94389 11.4102 5.08672 11.4102 3.32447 9.65775Z`,fill:`currentColor`}}]}),ph=Om({name:`link`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M14.0011 22C14.0011 22.5523 13.5534 23 13.0011 23H9C5.13401 23 2 19.866 2 16C2 12.134 5.13401 9 9 9H13.0011C13.5534 9 14.0011 9.44772 14.0011 10C14.0011 10.5523 13.5534 11 13.0011 11H9C6.23858 11 4 13.2386 4 16C4 18.7614 6.23858 21 9 21H13.0011C13.5534 21 14.0011 21.4477 14.0011 22Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M22.0021 16C22.0021 16.5523 21.5544 17 21.0021 17H11.001C10.4487 17 10.001 16.5523 10.001 16C10.001 15.4477 10.4487 15 11.001 15H21.0021C21.5544 15 22.0021 15.4477 22.0021 16Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M19 9C18.4477 9 18 9.44771 18 10C18 10.5523 18.4477 11 19 11H23.0001C25.7615 11 28.0001 13.2386 28.0001 16C28.0001 18.7614 25.7615 21 23.0001 21H19C18.4477 21 18 21.4477 18 22C18 22.5523 18.4477 23 19 23H23.0001C26.8661 23 30.0001 19.866 30.0001 16C30.0001 12.134 26.8661 9 23.0001 9H19Z`,fill:`currentColor`}}]}),mh=Om({name:`link-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M7.00049 11.4999C7.00049 11.7761 6.77663 11.9999 6.50049 11.9999H4.00045C1.79133 11.9999 0.000488281 10.2091 0.000488281 7.99996C0.000488281 5.79084 1.79133 4 4.00045 4H6.50049C6.77663 4 7.00049 4.22386 7.00049 4.5C7.00049 4.77614 6.77663 5 6.50049 5H4.00045C2.34362 5 1.00049 6.34313 1.00049 7.99996C1.00049 9.6568 2.34362 10.9999 4.00045 10.9999H6.50049C6.77663 10.9999 7.00049 11.2238 7.00049 11.4999Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M11.0021 8.00195C11.0021 8.2781 10.7783 8.50195 10.5021 8.50195L5.49795 8.50195C5.2218 8.50195 4.99795 8.2781 4.99795 8.00195C4.99795 7.72581 5.2218 7.50195 5.49795 7.50195L10.5021 7.50195C10.7783 7.50195 11.0021 7.72581 11.0021 8.00195Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.4978 4.00008C9.22166 4.00008 8.9978 4.22393 8.9978 4.50008C8.9978 4.77622 9.22166 5.00008 9.4978 5.00008H11.9978C13.6547 5.00008 14.9978 6.3432 14.9978 8.00004C14.9978 9.65687 13.6547 11 11.9978 11H9.4978C9.22166 11 8.9978 11.2239 8.9978 11.5C8.9978 11.7761 9.22166 12 9.4978 12H11.9978C14.207 12 15.9978 10.2092 15.9978 8.00004C15.9978 5.79092 14.207 4.00008 11.9978 4.00008L9.4978 4.00008Z`,fill:`currentColor`}}]}),hh=Om({name:`list-bullet-options`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M2.99878 11.0005L4.99631 11.0005C5.54791 11.0005 5.99507 10.5528 5.99506 10.0005C5.99505 9.44819 5.54789 9.00048 4.99628 9.00049L2.99875 9.00051C2.44715 9.00052 1.99999 9.44824 2 10.0005C2.00001 10.5528 2.44717 11.0005 2.99878 11.0005Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8.99148 10.0005C8.99148 9.44821 9.43864 9.00049 9.99024 9.00049H29.0012C29.5528 9.00049 30 9.4482 30 10.0005C30 10.5528 29.5528 11.0005 29.0012 11.0005L9.99024 11.0005C9.43864 11.0005 8.99148 10.5528 8.99148 10.0005Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.99024 14.9995C9.43864 14.9995 8.99148 15.4472 8.99148 15.9995C8.99148 16.5518 9.43864 16.9995 9.99024 16.9995H28.9647C29.5163 16.9995 29.9635 16.5518 29.9635 15.9995C29.9635 15.4472 29.5163 14.9995 28.9647 14.9995H9.99024Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.99024 20.9995C9.43864 20.9995 8.99148 21.4472 8.99148 21.9995C8.99148 22.5518 9.43864 22.9995 9.99024 22.9995H28.9647C29.5163 22.9995 29.9635 22.5518 29.9635 21.9995C29.9635 21.4472 29.5163 20.9995 28.9647 20.9995H9.99024Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M4.99631 16.9995L2.99878 16.9995C2.44717 16.9995 2.00001 16.5518 2 15.9996C1.99999 15.4473 2.44715 14.9995 2.99875 14.9995L4.99628 14.9995C5.54789 14.9995 5.99505 15.4472 5.99506 15.9995C5.99507 16.5518 5.54791 16.9995 4.99631 16.9995Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2.99878 22.9986L4.99631 22.9985C5.54791 22.9985 5.99507 22.5508 5.99506 21.9985C5.99505 21.4462 5.54789 20.9985 4.99628 20.9985L2.99875 20.9986C2.44715 20.9986 1.99999 21.4463 2 21.9986C2.00001 22.5509 2.44717 22.9986 2.99878 22.9986Z`,fill:`currentColor`}}]}),gh=Om({name:`list-bullet-options-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M4.05014 7.49463C4.05014 7.21875 4.27406 6.99511 4.55029 6.99511H15.4998C15.7761 6.99511 16 7.21875 16 7.49463C16 7.7705 15.7761 7.99414 15.4998 7.99414H4.55029C4.27406 7.99414 4.05014 7.7705 4.05014 7.49463Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M0.500165 10.998L1.50048 10.998C1.77671 10.998 2.00063 10.7744 2.00063 10.4985C2.00063 10.2226 1.77669 9.99901 1.50046 9.99901L0.50015 9.99902C0.223921 9.99903 -3.95782e-06 10.2227 0 10.4985C3.95792e-06 10.7744 0.223935 10.9981 0.500165 10.998Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M4.55029 9.99901C4.27406 9.99901 4.05014 10.2226 4.05014 10.4985C4.05014 10.7744 4.27406 10.998 4.55029 10.998H15.4998C15.7761 10.998 16 10.7744 16 10.4985C16 10.2226 15.7761 9.99901 15.4998 9.99901H4.55029Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M4.5034 3.99805C4.22717 3.99805 4.00325 4.22169 4.00325 4.49756C4.00325 4.77343 4.22717 4.99707 4.5034 4.99707L15.474 4.99707C15.7503 4.99707 15.9742 4.77343 15.9742 4.49756C15.9742 4.22169 15.7503 3.99805 15.474 3.99805L4.5034 3.99805Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M0.500165 5.00099L1.50048 5.00097C1.77671 5.00097 2.00063 4.77733 2.00063 4.50145C2.00063 4.22558 1.77669 4.00195 1.50046 4.00195L0.50015 4.00196C0.223921 4.00197 -3.9579e-06 4.22561 0 4.50148C3.95801e-06 4.77736 0.223935 5.00099 0.500165 5.00099Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M0.500165 7.99415L1.50048 7.99414C1.77671 7.99413 2.00063 7.77049 2.00063 7.49462C2.00063 7.21875 1.77669 6.99511 1.50046 6.99511L0.50015 6.99513C0.223921 6.99513 -3.95787e-06 7.21877 0 7.49465C3.95797e-06 7.77052 0.223935 7.99415 0.500165 7.99415Z`,fill:`currentColor`}}]}),_h=Om({name:`menu`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M7 9C6.44772 9 6 9.44772 6 10C6 10.5523 6.44772 11 7 11L24.9999 11C25.5522 11 25.9999 10.5523 25.9999 10C25.9999 9.44772 25.5522 9 24.9999 9H7Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6 15.999C6 15.4467 6.44772 14.999 7 14.999H24.9999C25.5522 14.999 25.9999 15.4467 25.9999 15.999C25.9999 16.5513 25.5522 16.999 24.9999 16.999H7C6.44772 16.999 6 16.5513 6 15.999Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6 21.999C6 21.4467 6.44772 20.999 7 20.999H24.9999C25.5522 20.999 25.9999 21.4467 25.9999 21.999C25.9999 22.5513 25.5522 22.999 24.9999 22.999H7C6.44772 22.999 6 22.5513 6 21.999Z`,fill:`currentColor`}}]}),vh=Om({name:`menu-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M2.5 3.99805C2.22386 3.99805 2 4.22156 2 4.49728C2 4.773 2.22386 4.99652 2.5 4.99652L13.5 4.99651C13.7761 4.99651 14 4.773 14 4.49728C14 4.22156 13.7761 3.99805 13.5 3.99805H2.5Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2.00006 7.49463C2.00006 7.21891 2.22392 6.9954 2.50006 6.9954H13.5C13.7762 6.9954 14 7.21891 14 7.49463C14 7.77035 13.7762 7.99387 13.5 7.99387H2.50006C2.22392 7.99387 2.00006 7.77035 2.00006 7.49463Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2.00006 10.4988C2.00006 10.2231 2.22392 9.99958 2.50006 9.99958H13.5C13.7762 9.99958 14 10.2231 14 10.4988C14 10.7745 13.7762 10.998 13.5 10.998H2.50006C2.22392 10.998 2.00006 10.7745 2.00006 10.4988Z`,fill:`currentColor`}}]}),yh=Om({name:`minus-remove`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M3 16C3 16.5523 3.44772 17 4 17H28C28.5523 17 29 16.5523 29 16C29 15.4477 28.5523 15 28 15H4C3.44772 15 3 15.4477 3 16Z`,fill:`currentColor`}}]}),bh=Om({name:`minus-remove-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M1 8.00005C1 7.72391 1.22386 7.50005 1.5 7.50005L14.5 7.5C14.7761 7.5 15 7.72386 15 8C15 8.27614 14.7761 8.5 14.5 8.5L1.5 8.50005C1.22386 8.50005 1 8.27619 1 8.00005Z`,fill:`currentColor`}}]}),xh=Om({name:`pen-edit`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M20.7934 3.88056C21.9656 2.70648 23.8661 2.70648 25.0383 3.88056L28.1209 6.96813C29.293 8.1422 29.293 10.0458 28.1209 11.2198L26.8337 12.5091L12.3222 27.1094C11.9103 27.5238 11.3866 27.809 10.8153 27.9298L6.02046 28.9442C4.20016 29.3293 2.61216 27.66 3.08406 25.8574L4.30593 21.1902C4.43905 20.6817 4.70296 20.2171 5.07133 19.8427L19.5055 5.1705L20.7934 3.88056ZM26.1255 10.3839L26.7059 9.8026C27.0966 9.41124 27.0966 8.77672 26.7059 8.38536L23.6233 5.29779C23.2326 4.90643 22.5991 4.90643 22.2084 5.29779L21.628 5.87913L26.1255 10.3839ZM20.2182 7.30161L6.49666 21.2494C6.37387 21.3742 6.28591 21.5291 6.24153 21.6986L5.01966 26.3658C4.92528 26.7263 5.24288 27.0602 5.60694 26.9832L10.4018 25.9688C10.5922 25.9285 10.7668 25.8335 10.9041 25.6953L24.7121 11.8028L20.2182 7.30161Z`,fill:`currentColor`}}]}),Sh=Om({name:`pen-edit-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M10.8764 1.44145C11.4602 0.855659 12.4067 0.85566 12.9905 1.44145L14.5622 3.01844C15.1459 3.60423 15.1459 4.55398 14.5622 5.13976L5.83278 13.8989C5.64373 14.0886 5.40743 14.2239 5.14852 14.2908L2.5578 14.9603C1.62868 15.2003 0.789202 14.3407 1.04731 13.4135L1.75661 10.8654C1.82576 10.617 1.95759 10.3907 2.13935 10.2083L10.8764 1.44145ZM12.2858 2.14855C12.0912 1.95329 11.7757 1.95329 11.5811 2.14855L11.1627 2.5684L13.439 4.8525L13.8574 4.43266C14.052 4.23739 14.052 3.92081 13.8574 3.72555L12.2858 2.14855ZM12.7343 5.55961L10.458 3.2755L2.84405 10.9154C2.78346 10.9762 2.73952 11.0516 2.71647 11.1344L2.00717 13.6825C1.95555 13.8679 2.12345 14.0399 2.30927 13.9919L4.89999 13.3224C4.98629 13.3001 5.06506 13.255 5.12808 13.1918L12.7343 5.55961Z`,fill:`currentColor`}}]}),Ch=Om({name:`photo-picture`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M19 7C16.7909 7 15 8.79086 15 11C15 13.2091 16.7909 15 19 15C21.2091 15 23 13.2091 23 11C23 8.79086 21.2091 7 19 7ZM17 11C17 9.89543 17.8954 9 19 9C20.1046 9 21 9.89543 21 11C21 12.1046 20.1046 13 19 13C17.8954 13 17 12.1046 17 11Z`,fill:`currentColor`}},{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M6 3C4.34315 3 3 4.34315 3 6V26C3 27.6569 4.34315 29.0007 6 29.0007L26 29C27.5837 29 28.8807 27.7729 28.9922 26.2176C28.9965 26.1585 28.999 26.0988 28.9998 26.0388L29 25.9995L29 6C29 4.34315 27.6569 3 26 3H6ZM26.9999 26.0129C26.9997 26.0327 26.9988 26.0523 26.9975 26.0718C26.9605 26.5903 26.528 26.9995 26 26.9995H17.9721C18.4417 22.2326 22.2331 18.4412 27 17.9716V26L26.9999 26.0129ZM17.558 21.928C19.4927 18.6078 22.9655 16.2941 27 15.9634V6C27 5.44772 26.5523 5 26 5H6C5.44772 5 5 5.44772 5 6V12.0002C11.0874 12.0355 16.1835 16.2548 17.558 21.928ZM5 14.0003V26C5 26.5523 5.44772 27 6 27H15.9231V25C15.9231 18.9505 11.0397 14.0416 5 14.0003Z`,fill:`currentColor`}}]}),wh=Om({name:`photo-picture-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M9.50232 6.99579C10.3301 6.99579 11.0012 6.32471 11.0012 5.49689C11.0012 4.66907 10.3301 3.99799 9.50232 3.99799C8.6745 3.99799 8.00342 4.66907 8.00342 5.49689C8.00342 6.32471 8.6745 6.99579 9.50232 6.99579Z`,fill:`currentColor`}},{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M2.49902 0.99823C1.6706 0.99823 0.999023 1.6698 0.999023 2.49823V13.5008C0.999023 14.3293 1.6706 15.0018 2.49902 15.0018L13.5016 15.0008C14.3301 15.0008 15.0016 14.3293 15.0016 13.5008V2.49823C15.0016 1.6698 14.3301 0.99823 13.5016 0.99823H2.49902ZM14.0016 7.91433C11.666 8.09171 9.67526 9.5032 8.67995 11.4982C7.79361 8.56939 5.16447 6.39756 1.99902 6.18925V2.49823C1.99902 2.22209 2.22288 1.99823 2.49902 1.99823H13.5016C13.7778 1.99823 14.0016 2.22209 14.0016 2.49823V7.91433ZM1.99902 7.19179V13.5008C1.99902 13.777 2.22288 14.0008 2.49902 14.0008H8.00043V13.6743C8.00043 10.2519 5.35602 7.44711 1.99902 7.19179ZM14.0009 8.91786C11.327 9.15876 9.20485 11.3129 9.01372 14.0008H13.5009C13.777 14.0008 14.0009 13.7769 14.0009 13.5008V8.91786Z`,fill:`currentColor`}}]}),Th=Om({name:`plus-add`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M3 16C3 15.4477 3.44772 15 4 15H15V4C15 3.44772 15.4477 3 16 3C16.5523 3 17 3.44772 17 4V15H28C28.5523 15 29 15.4477 29 16C29 16.5523 28.5523 17 28 17H17V28C17 28.5523 16.5523 29 16 29C15.4477 29 15 28.5523 15 28V17H4C3.44772 17 3 16.5523 3 16Z`,fill:`currentColor`}}]}),Eh=Om({name:`plus-add-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M7.5 1.5C7.5 1.22384 7.72389 0.999971 8.00005 1C8.27618 1.00003 8.5 1.22388 8.5 1.5L8.50001 7.5L14.5 7.49995C14.7761 7.49995 15 7.72381 15 7.99995C15 8.27609 14.7761 8.49995 14.5 8.49995L8.50001 8.5V14.4999C8.50001 14.7761 8.27615 14.9999 8 14.9999C7.72386 14.9999 7.5 14.7761 7.5 14.4999L7.50001 8.5H1.5C1.22386 8.5 1 8.27614 1 8C1 7.72386 1.22386 7.5 1.5 7.5H7.50001L7.5 1.5Z`,fill:`currentColor`}}]}),Dh=Om({name:`pop-out-window`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M8.5 25.0005C7.67157 25.0005 7 24.3289 7 23.5005V4.5C7 3.67157 7.67157 3 8.5 3H27.5005C28.3289 3 29.0005 3.67157 29.0005 4.5V23.5005C29.0005 24.3289 28.3289 25.0005 27.5005 25.0005H8.5ZM9 5V23.0005H27.0005V5H9Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6 29.0005C4.34315 29.0005 3 27.6573 3 26.0005V16.0003C3 15.448 3.44772 15.0003 4 15.0003C4.55228 15.0003 5 15.448 5 16.0003V26.0005C5 26.5528 5.44771 27.0005 6 27.0005H16.0002C16.5525 27.0005 17.0002 27.4482 17.0002 28.0005C17.0002 28.5528 16.5525 29.0005 16.0002 29.0005H6Z`,fill:`currentColor`}}]}),Oh=Om({name:`pop-out-window-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M3.7547 12.998C3.34049 12.998 3.0047 12.6623 3.0047 12.248V1.74805C3.0047 1.33383 3.34049 0.998047 3.7547 0.998047H14.2547C14.6689 0.998047 15.0047 1.33383 15.0047 1.74805V12.248C15.0047 12.6623 14.6689 12.998 14.2547 12.998H3.7547ZM4.0047 1.99805V11.998H14.0047V1.99805H4.0047Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2.50195 14.998C1.67353 14.998 1.00195 14.3265 1.00195 13.498V8.50351C1.00195 8.22737 1.22581 8.00351 1.50195 8.00351C1.7781 8.00351 2.00195 8.22737 2.00195 8.50351V13.498C2.00195 13.7742 2.22581 13.998 2.50195 13.998H7.50303C7.77917 13.998 8.00303 14.2219 8.00303 14.498C8.00303 14.7742 7.77917 14.998 7.50303 14.998H2.50195Z`,fill:`currentColor`}}]}),kh=Om({name:`printer`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M13.0057 15L6.99996 15C6.44767 15 5.99996 14.5523 5.99996 14C5.99996 13.4477 6.44768 13 6.99996 13L13.0057 13C13.558 13 14.0057 13.4477 14.0057 14C14.0057 14.5523 13.558 15 13.0057 15Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8 4C8 3.44772 8.44772 3 9 3H23C23.5523 3 24 3.44772 24 4V9H27C28.6569 9 30 10.3431 30 12V20C30 21.6569 28.6569 23 27 23H24V28C24 28.5523 23.5523 29 23 29H9C8.44772 29 8 28.5523 8 28V23H5C3.34315 23 2 21.6569 2 20V12C2 10.3431 3.34315 9 5 9H8V4ZM22 5H10V9H22V5ZM5 11C4.44772 11 4 11.4477 4 12V20C4 20.5523 4.44772 21 5 21H8V19C8 18.4477 8.44772 18 9 18H23C23.5523 18 24 18.4477 24 19V21H27C27.5523 21 28 20.5523 28 20V12C28 11.4477 27.5523 11 27 11H5ZM10 27H22V20H10V27Z`,fill:`currentColor`}}]}),Ah=Om({name:`printer-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M4.50397 7.00196L2.49804 7.00195C2.2219 7.00195 1.99804 6.77809 1.99804 6.50195C1.99804 6.22581 2.2219 6.00195 2.49804 6.00195L4.50397 6.00196C4.78011 6.00196 5.00397 6.22582 5.00397 6.50196C5.00397 6.7781 4.78011 7.00196 4.50397 7.00196Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M4.01733 0.5C4.01733 0.223858 4.24119 0 4.51733 0H11.4834C11.7595 0 11.9834 0.223858 11.9834 0.5V3.00391H14.5C15.3284 3.00391 16 3.67548 16 4.50391V10.5039C16 11.3323 15.3284 12.0039 14.5 12.0039H11.9836V15.4993C11.9836 15.7755 11.7598 15.9993 11.4836 15.9993H4.51758C4.24144 15.9993 4.01758 15.7755 4.01758 15.4993V12.0039H1.5C0.671573 12.0039 0 11.3323 0 10.5039V4.50391C0 3.67548 0.671573 3.00391 1.5 3.00391H4.01733V0.5ZM10.9834 1H5.01733V3.00391H10.9834V1ZM1.5 4.00391C1.22386 4.00391 1 4.22776 1 4.50391V10.5039C1 10.78 1.22386 11.0039 1.5 11.0039H4.01758V9.49609C4.01758 9.21995 4.24144 8.99609 4.51758 8.99609H11.4836C11.7598 8.99609 11.9836 9.21995 11.9836 9.49609V11.0039H14.5C14.7761 11.0039 15 10.78 15 10.5039V4.50391C15 4.22776 14.7761 4.00391 14.5 4.00391H1.5ZM5.01758 14.9993H10.9836V9.99609H5.01758V14.9993Z`,fill:`currentColor`}}]}),jh=Om({name:`shrink-minimise`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M4.70961 4.29278C4.31851 3.90241 3.68442 3.90241 3.29332 4.29278C2.90223 4.68314 2.90223 5.31605 3.29332 5.70642L11.7466 14.144L7.78838 14.1437C7.23529 14.1437 6.78688 14.5912 6.78685 15.1432C6.78681 15.6953 7.23515 16.1429 7.78825 16.1429L14.1645 16.1433C14.4301 16.1433 14.6848 16.038 14.8726 15.8506C15.0605 15.6631 15.166 15.4088 15.166 15.1437L15.166 8.78091C15.166 8.22884 14.7176 7.78131 14.1645 7.78131C13.6114 7.78131 13.1631 8.22884 13.1631 8.78091V12.7305L4.70961 4.29278Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M27.2919 28.7087C27.6839 29.0983 28.318 29.0969 28.7082 28.7057C29.0985 28.3145 29.0971 27.6816 28.7051 27.2921L20.2378 18.877L24.1886 18.8772C24.7417 18.8773 25.1901 18.4298 25.1901 17.8777C25.1902 17.3256 24.7418 16.8781 24.1887 16.878L17.8125 16.8776C17.5469 16.8776 17.2922 16.9829 17.1044 17.1704C16.9165 17.3578 16.811 17.6121 16.811 17.8772L16.811 24.24C16.811 24.7921 17.2594 25.2396 17.8125 25.2396C18.3656 25.2396 18.8139 24.7921 18.8139 24.24V20.2831L27.2919 28.7087Z`,fill:`currentColor`}}]}),Mh=Om({name:`shrink-minimise-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M1.85085 1.14649C1.65622 0.951833 1.34065 0.951818 1.146 1.14646C0.951348 1.3411 0.951332 1.65669 1.14596 1.85135L5.30263 6.00863L2.51057 6.00849C2.23531 6.00847 2.01215 6.23162 2.01214 6.5069C2.01212 6.78217 2.23526 7.00534 2.51052 7.00536L6.50585 7.00556C6.63804 7.00557 6.76482 6.95306 6.85829 6.85958C6.95177 6.76611 7.00428 6.63933 7.00428 6.50713L7.00428 2.51103C7.00428 2.23575 6.78114 2.01259 6.50587 2.0126C6.23061 2.0126 6.00746 2.23575 6.00746 2.51103V5.30372L1.85085 1.14649Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M14.1492 14.8545C14.3438 15.0492 14.6594 15.0492 14.854 14.8545C15.0487 14.6599 15.0487 14.3443 14.854 14.1496L10.7116 10.007L13.5036 10.0072C13.7789 10.0072 14.002 9.78403 14.0021 9.50875C14.0021 9.23347 13.7789 9.01031 13.5037 9.01029L9.50834 9.01009C9.37615 9.01008 9.24937 9.06259 9.1559 9.15606C9.06242 9.24954 9.00991 9.37632 9.00991 9.50852L9.00991 13.5046C9.00991 13.7799 9.23305 14.0031 9.50832 14.0031C9.78358 14.0031 10.0067 13.7799 10.0067 13.5046L10.0067 10.7118L14.1492 14.8545Z`,fill:`currentColor`}}]}),Nh=Om({name:`speech-bubble-comment`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M2 6.01422C1.99999 4.34951 3.34314 3 5 3H27C28.6568 3 30 4.34949 30 6.01419L30.0001 19.0738C30.0001 20.7385 28.6569 22.088 27.0001 22.088H15.81C15.5353 22.088 15.2728 22.2015 15.0839 22.4019L9.46059 28.3682C8.21729 29.6873 6.00839 28.8032 6.00839 26.9865V23.0927C6.00839 22.5405 5.55922 22.088 5.00422 22.088C3.35009 22.088 2.00006 20.7412 2.00005 19.0738L2 6.01422ZM5 5.00947C4.44771 5.00947 4 5.45931 4 6.01421L4.00005 19.0738C4.00006 19.626 4.44923 20.0785 5.00422 20.0785C6.65837 20.0785 8.00839 21.4253 8.00839 23.0927V26.9865L13.6317 21.0202C14.1983 20.419 14.986 20.0785 15.81 20.0785H27.0001C27.5523 20.0785 28.0001 19.6287 28.0001 19.0738L28 6.0142C28 5.4593 27.5523 5.00947 27 5.00947H5Z`,fill:`currentColor`}}]}),Ph=Om({name:`speech-bubble-comment-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M0 2.50389C-3.87831e-06 1.67331 0.672267 1 1.50156 1H14.4984C15.3277 1 16 1.67331 16 2.50387L16 9.51057C16 10.3411 15.3277 11.0145 14.4984 11.0145L7.79239 11.0145C7.66446 11.0145 7.54139 11.0635 7.44845 11.1516L3.67758 14.7238C3.03937 15.3284 1.98866 14.8752 1.98866 13.9954L1.98866 11.509C1.98866 11.2359 1.76758 11.0145 1.49487 11.0145C0.669295 11.0145 3.6516e-05 10.3442 3.26675e-05 9.51732L0 2.50389ZM1.50156 2.00259C1.22513 2.00259 1.00104 2.22703 1.00104 2.50388L1.00107 9.51732C1.00107 9.79045 1.22215 10.0119 1.49486 10.0119C2.32044 10.0119 2.9897 10.6822 2.9897 11.509L2.9897 13.9954L6.76057 10.4232C7.03939 10.159 7.40861 10.0119 7.79239 10.0119L14.4984 10.0119C14.7749 10.0119 14.999 9.78743 14.999 9.51057L14.9989 2.50388C14.9989 2.22702 14.7748 2.00259 14.4984 2.00259H1.50156Z`,fill:`currentColor`}}]}),Fh=Om({name:`star`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M15.9998 2C16.4392 2 16.8271 2.28676 16.9559 2.70679L19.8082 12.0071H29.0008C29.4312 12.0071 29.8132 12.2824 29.9494 12.6906C30.0856 13.0988 29.9454 13.5484 29.6013 13.8067L22.1544 19.3981L24.9643 28.7112C25.0891 29.1248 24.9342 29.5717 24.5802 29.8194C24.2263 30.0671 23.7533 30.0594 23.4075 29.8005L16 24.2536L8.59545 29.8004C8.24976 30.0594 7.77688 30.0671 7.42289 29.8196C7.06891 29.5721 6.91384 29.1253 7.03838 28.7117L9.843 19.3982L2.39852 13.8066C2.05446 13.5482 1.9143 13.0987 2.05052 12.6905C2.18673 12.2823 2.56879 12.0071 2.99909 12.0071H12.1915L15.0438 2.70679C15.1726 2.28676 15.5605 2 15.9998 2ZM15.9998 6.4105L13.8868 13.3003C13.758 13.7203 13.3701 14.0071 12.9308 14.0071H5.99554L11.6024 18.2184C11.9378 18.4703 12.0803 18.9047 11.9594 19.3064L9.83034 26.3764L15.4003 22.2039C15.7556 21.9377 16.2439 21.9377 16.5992 22.2038L22.1706 26.3757L20.0378 19.3069C19.9166 18.9051 20.0591 18.4703 20.3948 18.2183L26.0035 14.0071H19.0689C18.6296 14.0071 18.2417 13.7203 18.1129 13.3003L15.9998 6.4105Z`,fill:`currentColor`}}]}),Ih=Om({name:`star-fill`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M16.9566 2.70679C16.8278 2.28676 16.4399 2 16.0006 2C15.5612 2 15.1734 2.28676 15.0445 2.70679L12.1922 12.0071H2.99982C2.56952 12.0071 2.18747 12.2823 2.05125 12.6905C1.91503 13.0987 2.0552 13.5482 2.39925 13.8066L9.84373 19.3982L7.03912 28.7117C6.91457 29.1253 7.06964 29.5721 7.42362 29.8196C7.77761 30.0671 8.25049 30.0594 8.59618 29.8004L16.0007 24.2536L23.4082 29.8005C23.754 30.0594 24.227 30.0671 24.5809 29.8194C24.9349 29.5717 25.0898 29.1248 24.965 28.7112L22.1551 19.3981L29.602 13.8067C29.9461 13.5484 30.0863 13.0988 29.9502 12.6906C29.814 12.2824 29.4319 12.0071 29.0016 12.0071H19.8089L16.9566 2.70679Z`,fill:`currentColor`}}]}),Lh=Om({name:`star-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{"fill-rule":`evenodd`,"clip-rule":`evenodd`,d:`M8.00713 2.26304e-07C8.22881 0.000210094 8.42388 0.146358 8.48637 0.359047L10.1453 6.00512H15.501C15.7192 6.00512 15.9121 6.14654 15.9778 6.35455C16.0435 6.56256 15.9668 6.78915 15.7882 6.91443L11.4717 9.94283L13.1048 15.3556C13.1672 15.5624 13.0897 15.7858 12.9128 15.9097C12.7358 16.0335 12.4993 16.0297 12.3264 15.9002L8.00671 12.6656L3.68877 15.9002C3.51592 16.0297 3.27948 16.0335 3.10249 15.9098C2.9255 15.786 2.84796 15.5626 2.91023 15.3558L4.54013 9.94334L0.213316 6.91475C0.0345257 6.7896 -0.0424427 6.56295 0.0231652 6.35481C0.0887732 6.14667 0.281799 6.00512 0.500036 6.00512H5.85636L7.5272 0.358138C7.5901 0.145569 7.78545 -0.000209642 8.00713 2.26304e-07ZM8.00498 2.26794L6.7093 6.64698C6.64645 6.85938 6.45135 7.00512 6.22985 7.00512H2.0863L5.40992 9.33152C5.58677 9.45531 5.66421 9.67862 5.60196 9.88532L4.30621 14.1882L7.70688 11.6407C7.88454 11.5076 8.12867 11.5076 8.30635 11.6407L11.7079 14.1878L10.4099 9.88557C10.3476 9.679 10.4248 9.45576 10.6014 9.33183L13.9178 7.00512H9.7711C9.54925 7.00512 9.35392 6.85893 9.29138 6.64608L8.00498 2.26794Z`,fill:`currentColor`}}]}),Rh=Om({name:`star-reduced-fill`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M8.478 0.353394C8.41359 0.143378 8.21965 0 7.99998 0C7.78031 0 7.58637 0.143378 7.52196 0.353394L5.85971 5.7733H0.499544C0.284394 5.7733 0.0933671 5.91094 0.0252583 6.11502C-0.0428505 6.31911 0.0272318 6.54388 0.19926 6.67309L4.5371 9.93128L2.90356 15.3559C2.84129 15.5626 2.91883 15.786 3.09582 15.9098C3.27281 16.0336 3.50925 16.0297 3.6821 15.9002L8.00004 12.6656L12.3197 15.9003C12.4926 16.0297 12.7291 16.0335 12.9061 15.9097C13.0831 15.7859 13.1605 15.5624 13.0981 15.3556L11.4615 9.93122L15.8008 6.67314C15.9728 6.54395 16.0429 6.31917 15.9748 6.11506C15.9067 5.91096 15.7157 5.7733 15.5005 5.7733H10.1402L8.478 0.353394Z`,fill:`currentColor`}}]}),zh=Om({name:`stop-not-allowed`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M16 2C8.26801 2 2 8.26801 2 16C2 23.732 8.26801 30 16 30C23.732 30 30 23.732 30 16C30 8.26801 23.732 2 16 2ZM8.24799 6.83963C10.3391 5.06824 13.0448 4 16 4C22.6274 4 28 9.37258 28 16C28 18.9552 26.9318 21.6609 25.1604 23.752L8.24799 6.83963ZM6.83426 8.25433L23.7457 25.1657C21.6554 26.9339 18.9522 28 16 28C9.37258 28 4 22.6274 4 16C4 13.0478 5.06608 10.3446 6.83426 8.25433Z`,fill:`currentColor`}}]}),Bh=Om({name:`stop-not-allowed-reduced`,viewBox:`0 0 17 17`,elements:[{tag:`path`,attrs:{d:`M8.01465 0.0146484C3.59637 0.0146484 0.0146484 3.59637 0.0146484 8.01465C0.0146484 12.4329 3.59637 16.0146 8.01465 16.0146C12.4329 16.0146 16.0146 12.4329 16.0146 8.01465C16.0146 3.59637 12.4329 0.0146484 8.01465 0.0146484ZM3.43095 2.72397C4.65902 1.65908 6.26158 1.01465 8.01465 1.01465C11.8806 1.01465 15.0146 4.14865 15.0146 8.01465C15.0146 9.76772 14.3702 11.3703 13.3053 12.5983L3.43095 2.72397ZM2.72386 3.43108L12.5982 13.3054C11.3702 14.3703 9.76766 15.0146 8.01465 15.0146C4.14865 15.0146 1.01465 11.8806 1.01465 8.01465C1.01465 6.26164 1.65903 4.65914 2.72386 3.43108Z`,fill:`currentColor`}}]}),Vh=Om({name:`tool-edit`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M24.333 4.60957C24.462 5.22744 24.2745 5.89819 23.7916 6.38094L21.1294 9.04236L22.9656 10.878L25.6237 8.22065C26.1055 7.73904 26.7748 7.5511 27.3922 7.67893C28.0292 7.81083 28.5958 8.28225 28.7765 9.01791C29.412 11.6038 28.7201 14.4534 26.6962 16.4767C24.9629 18.2094 22.6271 18.9591 20.3711 18.7463C19.8649 18.6986 19.4608 18.8351 19.226 19.0699L10.1744 28.1187C9.00251 29.2903 7.10245 29.2903 5.93053 28.1187L3.88358 26.0724C2.71166 24.9008 2.71166 23.0013 3.88358 21.8297L12.9351 12.7809C13.17 12.5461 13.3065 12.1422 13.2587 11.636C13.0459 9.38074 13.7958 7.04568 15.5291 5.31289C17.559 3.28363 20.4024 2.59693 22.9893 3.2264C23.7265 3.40579 24.1998 3.97211 24.333 4.60957ZM22.2352 5.10844C20.3747 4.74975 18.3851 5.28612 16.9437 6.72711C15.6526 8.01781 15.0909 9.75644 15.2505 11.4482C15.3366 12.3609 15.1229 13.4222 14.3497 14.1951L5.29821 23.2439C4.90757 23.6345 4.90757 24.2676 5.29821 24.6581L7.34517 26.7045C7.73581 27.095 8.36916 27.095 8.7598 26.7045L17.8113 17.6556C18.5845 16.8827 19.646 16.6691 20.559 16.7552C22.2513 16.9147 23.9904 16.3531 25.2815 15.0624C26.7172 13.6272 27.2566 11.6342 26.8958 9.77738L24.3802 12.2922C23.5989 13.0733 22.3322 13.0733 21.551 12.2922L19.7148 10.4566C18.9335 9.67552 18.9335 8.40919 19.7148 7.62814L22.2352 5.10844Z`,fill:`currentColor`}}]}),Hh=Om({name:`tool-edit-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M12.5073 1.83153C12.5709 2.13977 12.4777 2.47441 12.2363 2.7157L10.7281 4.22376L11.778 5.2735L13.2839 3.76781C13.5247 3.52709 13.8586 3.43368 14.1665 3.49659C14.4833 3.56131 14.7665 3.7932 14.8618 4.15681C15.2292 5.55762 14.8643 7.11278 13.7647 8.21218C12.8236 9.15312 11.5507 9.55237 10.327 9.42154C10.0803 9.39516 9.87951 9.46252 9.7618 9.58022L4.78013 14.5611C4.19483 15.1463 3.24588 15.1463 2.66058 14.5611L1.43897 13.3397C0.853676 12.7545 0.853675 11.8057 1.43897 11.2205L6.42064 6.2396C6.53836 6.1219 6.60574 5.92119 6.57935 5.67449C6.4485 4.45093 6.84781 3.17827 7.7889 2.23734C8.89182 1.13459 10.4434 0.772623 11.8448 1.13669C12.2092 1.23134 12.442 1.51446 12.5073 1.83153ZM11.466 2.07316C10.4268 1.84741 9.30359 2.1357 8.49542 2.94374C7.77849 3.66055 7.4725 4.62988 7.57286 5.56828C7.62217 6.02941 7.51288 6.56034 7.12716 6.94601L2.14549 11.9269C1.95039 12.1219 1.95039 12.4382 2.14549 12.6333L3.3671 13.8547C3.5622 14.0498 3.87851 14.0498 4.07361 13.8547L9.05528 8.87382C9.44101 8.48816 9.97202 8.37888 10.4332 8.42819C11.3718 8.52853 12.3413 8.22259 13.0582 7.50578C13.8632 6.70091 14.1532 5.5755 13.9262 4.53844L12.4845 5.9799C12.0943 6.37004 11.4616 6.37004 11.0714 5.9799L10.0215 4.93016C9.63134 4.54002 9.63134 3.90749 10.0215 3.51735L11.466 2.07316Z`,fill:`currentColor`}}]}),Uh=Om({name:`trash-bin-delete`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M12.0063 24.9998V10.998C12.0063 10.4458 12.4538 9.99805 13.0059 9.99805C13.5579 9.99805 14.0055 10.4458 14.0055 10.998V24.9998C14.0055 25.5521 13.5579 25.9998 13.0059 25.9998C12.4538 25.9998 12.0063 25.5521 12.0063 24.9998Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M18.0037 10.998V24.9998C18.0037 25.5521 18.4513 25.9998 19.0033 25.9998C19.5553 25.9998 20.0029 25.5521 20.0029 24.9998V10.998C20.0029 10.4458 19.5553 9.99805 19.0033 9.99805C18.4513 9.99805 18.0037 10.4458 18.0037 10.998Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M13.0059 2C11.3497 2 10.0072 3.34315 10.0072 5V6H4.99957C4.44752 6 4 6.44772 4 7C4 7.55228 4.44752 8 4.99957 8H6.00668L6.88088 27.137C6.95406 28.7389 8.27355 30 9.87646 30H22.1438C23.7471 30 25.0668 28.7383 25.1394 27.1359L26.0067 8H27.0004C27.5525 8 28 7.55228 28 7C28 6.44772 27.5525 6 27.0004 6H22.002V5C22.002 3.34315 20.6594 2 19.0033 2H13.0059ZM20.0029 6H12.0063V5C12.0063 4.44772 12.4538 4 13.0059 4H19.0033C19.5553 4 20.0029 4.44772 20.0029 5V6ZM8.0079 8H24.0055L23.1423 27.0453C23.1181 27.5794 22.6782 28 22.1438 28H9.87646C9.34216 28 8.90233 27.5796 8.87793 27.0457L8.0079 8Z`,fill:`currentColor`}}]}),Wh=Om({name:`trash-bin-delete-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M6.02344 12.5148V5.50708C6.02344 5.23094 6.24729 5.00708 6.52344 5.00708C6.79958 5.00708 7.02344 5.23094 7.02344 5.50708V12.5148C7.02344 12.7909 6.79958 13.0148 6.52344 13.0148C6.24729 13.0148 6.02344 12.7909 6.02344 12.5148Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.01367 5.50708V12.5148C9.01367 12.7909 9.23753 13.0148 9.51367 13.0148C9.78981 13.0148 10.0137 12.7909 10.0137 12.5148V5.50708C10.0137 5.23094 9.78981 5.00708 9.51367 5.00708C9.23753 5.00708 9.01367 5.23094 9.01367 5.50708Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M6.12097 0.000244141C5.29254 0.000244141 4.62097 0.671817 4.62097 1.50024V1.9917L1.50195 1.99194C1.22581 1.99194 1.00195 2.2158 1.00195 2.49194C1.00195 2.76809 1.22581 2.99194 1.50195 2.99194H2.0045L2.55043 14.5705C2.58815 15.3706 3.24781 15.9999 4.04877 15.9999H11.9587C12.7598 15.9999 13.4196 15.3703 13.457 14.57L13.9987 2.99194H14.4979C14.774 2.99194 14.9979 2.76809 14.9979 2.49194C14.9979 2.2158 14.774 1.99194 14.4979 1.99194L11.3798 1.9917V1.50024C11.3798 0.671818 10.7082 0.000244141 9.87977 0.000244141H6.12097ZM10.3798 1.9917H5.62097V1.50024C5.62097 1.2241 5.84483 1.00024 6.12097 1.00024H9.87977C10.1559 1.00024 10.3798 1.2241 10.3798 1.50024V1.9917ZM12.9976 2.99194L12.4581 14.5232C12.4456 14.79 12.2257 14.9999 11.9587 14.9999H4.04877C3.78178 14.9999 3.56189 14.7901 3.54932 14.5234L3.00561 2.99194H12.9976Z`,fill:`currentColor`}}]}),Gh=Om({name:`warning-circle`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M15.9998 18C16.552 18 16.9998 17.5523 16.9998 17V9.99739C16.9998 9.44511 16.552 8.99739 15.9998 8.99739C15.4475 8.99739 14.9998 9.44511 14.9998 9.99739V17C14.9998 17.5523 15.4475 18 15.9998 18Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M15.9998 20C16.8282 20 17.4998 20.6716 17.4998 21.5C17.4998 22.3284 16.8282 23 15.9998 23C15.1713 23 14.4998 22.3284 14.4998 21.5C14.4998 20.6716 15.1713 20 15.9998 20Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M2 16C2 23.732 8.26801 30 16 30C23.732 30 30 23.732 30 16C30 8.26801 23.732 2 16 2C8.26801 2 2 8.26801 2 16ZM16 28C9.37258 28 4 22.6274 4 16C4 9.37258 9.37258 4 16 4C22.6274 4 28 9.37258 28 16C28 22.6274 22.6274 28 16 28Z`,fill:`currentColor`}}]}),Kh=Om({name:`warning-circle-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M8.00062 4.01562C8.27676 4.01563 8.50062 4.23948 8.50062 4.51562L8.50061 8.50902C8.50061 8.78516 8.27675 9.00902 8.00061 9.00902C7.72447 9.00902 7.50061 8.78516 7.50061 8.50902L7.50062 4.51562C7.50062 4.23948 7.72448 4.01562 8.00062 4.01562Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8.74963 10.752C8.74963 11.1662 8.41385 11.502 7.99963 11.502C7.58542 11.502 7.24963 11.1662 7.24963 10.752C7.24963 10.3377 7.58542 10.002 7.99963 10.002C8.41385 10.002 8.74963 10.3377 8.74963 10.752Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8 0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16C12.4183 16 16 12.4183 16 8C16 3.58172 12.4183 0 8 0ZM1 8C1 4.13401 4.13401 1 8 1C11.866 1 15 4.13401 15 8C15 11.866 11.866 15 8 15C4.13401 15 1 11.866 1 8Z`,fill:`currentColor`}}]}),qh=Om({name:`warning-triangle`,viewBox:`0 0 32 32`,elements:[{tag:`path`,attrs:{d:`M15.9996 19C16.5519 19 16.9996 18.5523 16.9996 18V10.9974C16.9996 10.4451 16.5519 9.99739 15.9996 9.99739C15.4473 9.99739 14.9996 10.4451 14.9996 10.9974V18C14.9996 18.5523 15.4473 19 15.9996 19Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M15.9996 21C16.8281 21 17.4996 21.6716 17.4996 22.5C17.4996 23.3284 16.8281 24 15.9996 24C15.1712 24 14.4996 23.3284 14.4996 22.5C14.4996 21.6716 15.1712 21 15.9996 21Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M13.4243 5.43883C14.5926 3.52093 17.3938 3.52026 18.563 5.4376L29.5609 23.4718C30.7732 25.4597 29.332 27.9999 26.9919 27.9999L5.00812 28C2.66864 28 1.22736 25.461 2.43837 23.4731L13.4243 5.43883ZM16.8504 6.46778C16.4606 5.82867 15.5269 5.82889 15.1375 6.46819L4.15153 24.5024C3.74786 25.1651 4.22829 26.0114 5.00812 26.0114L26.9919 26.0113C27.7719 26.0113 28.2523 25.1646 27.8482 24.502L16.8504 6.46778Z`,fill:`currentColor`}}]}),Jh=Om({name:`warning-triangle-reduced`,viewBox:`0 0 16 16`,elements:[{tag:`path`,attrs:{d:`M7.99933 4.94336C8.27547 4.94336 8.49933 5.16722 8.49933 5.44336V8.52093C8.49933 8.79707 8.27547 9.02093 7.99933 9.02093C7.72319 9.02093 7.49933 8.79707 7.49933 8.52093V5.44336C7.49933 5.16722 7.72319 4.94336 7.99933 4.94336Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M8.74908 10.75C8.74908 11.1642 8.4133 11.5 7.99908 11.5C7.58487 11.5 7.24908 11.1642 7.24908 10.75C7.24908 10.3358 7.58487 10 7.99908 10C8.4133 10 8.74908 10.3358 8.74908 10.75Z`,fill:`currentColor`}},{tag:`path`,attrs:{d:`M9.2513 1.68263C8.66034 0.771787 7.31588 0.77261 6.72607 1.68418L0.237631 11.7122C-0.402309 12.7013 0.314747 14 1.50075 14H14.4953C15.6822 14 16.3991 12.6996 15.7575 11.7107L9.2513 1.68263ZM7.56815 2.21872C7.76475 1.91486 8.2129 1.91458 8.40989 2.2182L14.916 12.2462C15.1299 12.5759 14.891 13.0093 14.4953 13.0093H1.50075C1.10541 13.0093 0.866395 12.5764 1.07971 12.2467L7.56815 2.21872Z`,fill:`currentColor`}}]});function Yh(e){return e.endsWith(`-reduced`)||e.endsWith(`-reduced-fill`)?null:e.endsWith(`-fill`)?`${e.slice(0,-5)}-reduced-fill`:`${e}-reduced`}function Xh(e){let t=(t,n)=>{if(n===16){let n=Yh(t);if(n&&e[n])return e[n]}return e[t]};return L({name:`PisIcon`,props:{name:{type:String,required:!0},size:{type:Number,default:16,validator:e=>Tm.includes(e)},label:{type:String,default:``}},setup(e){return()=>{let n=t(e.name,e.size);return n?Qa(n,{size:e.size,label:e.label?e.label:void 0}):(console.warn(`[@pisapp/icons] Unknown icon name "${e.name}" — icon not rendered.`),null)}}})}var Zh={"arrow-right":km,"check-mark-circle":jm,"chevron-left":Fm,"chevron-right":Lm,"cross-close":Vm,"cross-close-circle":Hm,"data-table-grid":Gm,download:qm,"expand-maximize":Ym,"eye-show":$m,"file-document":Qm,"folder-open":th,"funnel-filter":rh,"grid-matrix":ah,"house-home":sh,"information-circle":lh,"lens-search-find":dh,"list-bullet-options":hh,link:ph,menu:_h,"minus-remove":yh,"pen-edit":xh,"photo-picture":Ch,"plus-add":Th,"pop-out-window":Dh,printer:kh,"speech-bubble-comment":Nh,star:Fh,"star-fill":Ih,"shrink-minimise":jh,"stop-not-allowed":zh,"trash-bin-delete":Uh,"tool-edit":Vh,"warning-circle":Gh,"warning-triangle":qh,"chevron-up":zm,"chevron-down":Nm},Qh={"arrow-right-reduced":Am,"check-mark-circle-reduced":Mm,"chevron-left-reduced":Im,"chevron-right-reduced":Rm,"cross-close-reduced":Wm,"cross-close-circle-reduced":Um,"data-table-grid-reduced":Km,"download-reduced":Jm,"expand-maximize-reduced":Xm,"eye-show-reduced":Zm,"file-document-reduced":eh,"folder-open-reduced":nh,"funnel-filter-reduced":ih,"grid-matrix-reduced":oh,"house-home-reduced":ch,"information-circle-reduced":uh,"lens-search-find-reduced":fh,"list-bullet-options-reduced":gh,"link-reduced":mh,"menu-reduced":vh,"minus-remove-reduced":bh,"pen-edit-reduced":Sh,"photo-picture-reduced":wh,"plus-add-reduced":Eh,"pop-out-window-reduced":Oh,"printer-reduced":Ah,"speech-bubble-comment-reduced":Ph,"star-reduced":Lh,"star-reduced-fill":Rh,"shrink-minimise-reduced":Mh,"stop-not-allowed-reduced":Bh,"trash-bin-delete-reduced":Wh,"tool-edit-reduced":Hh,"warning-circle-reduced":Kh,"warning-triangle-reduced":Jh,"chevron-up-reduced":Bm,"chevron-down-reduced":Pm},$h=Xh({...Zh,...Qh});function eg(e){let t=new WeakMap;return{mount:(n,r)=>{if(t.has(n))return;let i=ke(),a={scope:i};t.set(n,a),i.run(()=>{let t;a.runner=qe(()=>{t==null||t();let i=e(n,r);t=typeof i==`function`?i:void 0}),je(()=>t==null?void 0:t())})},unmount:e=>{let n=t.get(e);n&&(n.scope.stop(),t.delete(e))}}}var tg=L({name:`MountPoint`,props:{callbacks:{type:[Object,Function,String],default:null},ctx:{type:Object,default:()=>({})}},setup(e){let t=M(),n,r=new WeakMap,i=rg(()=>e.ctx),a=Y(()=>ng(e.callbacks)),o=Y(()=>typeof e.callbacks==`string`),s=Y(()=>o.value&&!1),c=Y(()=>{let t=e.callbacks;return a.value&&t?Qt(Zt(t)):null}),l=()=>{if(a.value||o.value)return;if(typeof e.callbacks==`function`){let t=e.callbacks,n=r.get(t);return n||(n=eg(t),r.set(t,n)),n}let t=e.callbacks;if(!(!t||typeof t.mount!=`function`))return t},u=()=>{var r;if(a.value||o.value)return;let i=(r=l())==null?void 0:r.mount;if(i&&t.value){let r=i(t.value,e.ctx);n=typeof r==`function`?r:void 0}},d=()=>{var e;if(a.value||o.value||!t.value)return;n==null||n(),n=void 0;let r=(e=l())==null?void 0:e.unmount;r?r(t.value):ag(t.value)};return kr(()=>{if(o.value){ig();return}u()}),Mr(d),I(()=>e.ctx,(e,t)=>{e!==t&&!a.value&&!o.value&&(d(),u())}),{container:t,isVueComponent:a,isLegacyRuntimeTemplate:s,legacyTemplateProps:i,legacyRuntimeTemplate:void 0,resolvedComponent:c}}});function ng(e){if(!e||typeof e!=`object`)return!1;let t=e;return typeof t.setup==`function`||typeof t.render==`function`}function rg(e){return Qt(new Proxy({},{ownKeys:()=>Reflect.ownKeys(e()),getOwnPropertyDescriptor:(t,n)=>{if(n in e())return{configurable:!0,enumerable:!0,get:()=>e()[n]}},get:(t,n)=>e()[n],has:(t,n)=>n in e()}))}var ig=()=>{console.warn(`[pis MountPoint] legacy string templates require the compiler-enabled global pis.js build. The compiler-free builds (pis-csp.js, ESM entries) support Vue components and render functions only — translate the string to a render function or compileComponent.`)},ag=e=>{e.replaceChildren()},og={key:2,ref:`container`,class:`pis-mount-point`,style:{display:`contents`}};function sg(e,t,n,r,i,a){return e.isVueComponent?(H(),W(Vr(e.resolvedComponent),{key:0,ctx:e.ctx},null,8,[`ctx`])):e.isLegacyRuntimeTemplate?(H(),W(Vr(e.legacyRuntimeTemplate),{key:1,template:e.callbacks,"template-props":e.legacyTemplateProps},null,8,[`template`,`template-props`])):(H(),U(`div`,og,null,512))}var cg=Q(tg,[[`render`,sg]]);function lg(e){return Ut(e)}var ug=Symbol(`reactive-context-composite-key`);function dg(){return{primitiveChildren:new Map,objectChildren:new WeakMap}}function fg(e){return typeof e==`object`&&!!e||typeof e==`function`}function pg(e,t){if(fg(t)){let n=e.objectChildren.get(t);if(n)return n;let r=dg();return e.objectChildren.set(t,r),r}let n=e.primitiveChildren.get(t);if(n)return n;let r=dg();return e.primitiveChildren.set(t,r),r}function mg(e,t){if(!fg(t))return pg(e,t);let n=Object.keys(t).sort();if(!n.length)return pg(e,t);let r=pg(e,ug);r=pg(r,n.length);for(let e of n)r=pg(r,e),r=pg(r,t[e]);return r}function hg(e){let t=dg();return n=>{let r=mg(t,n),i=r.context;if(i){let t=e(n);for(let e of Object.keys(t))i[e]=t[e];return i}let a=Ut(e(n));return r.context=a,a}}var gg=L({name:`pis-catalogs-aliases-search-table`,components:{Icon:$h,Clickable:wm,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=Vl,{componentName:i,isReady:a,isWebComponent:o,instance:s,store:c,routeData:l,emit:u,t:d}=ym(t,e.instanceId,[Ud.Products]),{onAliasItemMenuAction:f}=bm(s,d,i),p=Y(()=>{var e;return(e=c.value)==null||(e=e.data.products)==null?void 0:e.items}),m=Y(()=>{var e;return((e=s.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-preview`))??!1}),h=Y(()=>{var e;return((e=c.value)==null||(e=e.options.components)==null||(e=e.aliases)==null||(e=e.search)==null?void 0:e.table)??{}}),g=Y(()=>h.value.columns),_=async e=>{try{var t;await((t=s.value)==null?void 0:t.execute(new ju({productId:e}).from(i)))}catch{}},v=Y(()=>{var e;return!((e=l.value)!=null&&e.products.catalogId)}),y=e=>{if(!e.inactive)try{var t;return(t=s.value)==null?void 0:t.execute(new _u(e).from(i))}catch{}},b=Y(()=>{var e;return(e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null||(e=e.actions)==null?void 0:e.aliasItemMenu}),x=e=>{var t;return(((t=b.value)==null?void 0:t.items)||[]).filter(t=>typeof t.visible==`function`?t.visible(e):t.visible)},S=Y(()=>{var e,t;return!!(n.value&&(e=s.value)!=null&&e.registeredComponents.has(`pis-catalogs-aliases-search-actions-modals`)&&(t=b.value)!=null&&t.visible)}),C=(e,t)=>typeof e.disabled==`function`?e.disabled(t):e.disabled,w=hg(e=>({col:e.col,item:e.item,instance:s.value,catalogProductType:r,CatalogProductTypeEnum:Vl,emit:u,details:y,attrValue:Us,attrValues:Ws,t:d})),T=hg(e=>({instance:s.value,item:e.item,emit:u,t:d})),E=async()=>{try{var e;let t=await((e=s.value)==null?void 0:e.execute(new td().from(i)));if(!t)throw Error(d(`CatalogOptionsLoadingError`));n.value=t.aliasesEditable||!1}catch(e){var t;await((t=s.value)==null?void 0:t.execute(new pd({type:`danger`,message:e.message}).from(i)))}};return kr(()=>{var e;if(!((e=s.value)!=null&&e.isInitialized())){let e=I(()=>{var e;return(e=s.value)==null?void 0:e.isInitialized()},t=>{if(t)return e(),E()});return}return E()}),{root:t,componentName:i,componentOptions:h,instance:s,isReady:a,isWebComponent:o,store:c,routeData:l,productsItems:p,previewEnabled:m,columns:g,showingAllCatalogs:v,catalogProductType:r,actionsEnabled:S,CatalogProductTypeEnum:Vl,aliasItemMenuItems:x,details:y,isDisabled:C,t:d,emit:u,previewByProductId:_,attrValue:Us,additionalInfo:Gs,attrValues:Ws,onAliasItemMenuAction:f,reactiveContext:lg,cellCtx:w,menuItemCtx:T}}}),_g={key:0,class:`table-responsive pis-scroll`},vg={class:`table`},yg={key:0,style:{width:`1%`}},bg={key:1,style:{width:`1%`}},xg={key:2,style:{width:`1%`}},Sg={key:0},Cg={key:1},wg={key:2},Tg={key:0},Eg={class:`ext-select-checkbox`},Dg=[`checked`,`onClick`],Og={key:1},kg={key:1},Ag={key:1,class:`fw-bold text-muted`},jg={key:2,class:`text-muted small`},Mg={key:2},Ng={key:2},Pg={class:`d-flex align-items-right list-unstyled mb-0`},Fg=[`disabled`,`onClick`],Ig={key:0};function Lg(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Icon`),c=R(`Clickable`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(V,{key:0},[e.productsItems&&e.productsItems.length?(H(),U(`div`,_g,[G(`table`,vg,[G(`colgroup`,null,[e.componentOptions.selectable?(H(),U(`col`,yg)):J(``,!0),e.previewEnabled?(H(),U(`col`,bg)):J(``,!0),(H(!0),U(V,null,z(e.columns,(e,t)=>(H(),U(`col`,{key:t,style:k({width:e.width})},null,4))),128)),e.actionsEnabled?(H(),U(`col`,xg)):J(``,!0)]),G(`thead`,null,[G(`tr`,null,[e.componentOptions.selectable?(H(),U(`th`,Sg)):J(``,!0),e.previewEnabled?(H(),U(`th`,Cg)):J(``,!0),(H(!0),U(V,null,z(e.columns,(t,n)=>(H(),U(`th`,{key:n},[t.headerTemplate?(H(),W(o,{key:0,callbacks:t.headerTemplate,ctx:e.reactiveContext({t:e.t,col:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(t.caption),1)],64))]))),128)),e.actionsEnabled?(H(),U(`th`,wg)):J(``,!0)])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.productsItems,(t,n)=>{var r,i;return H(),U(`tr`,{key:n,class:A({"bg-light":t.exactMatch,"no-border-bottom":t.expanded,"ext-selected":(r=e.instance)==null?void 0:r.selection.isSelected(t)})},[e.componentOptions.selectable?(H(),U(`td`,Tg,[G(`div`,Eg,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(i=e.instance)==null?void 0:i.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,Dg)])])):J(``,!0),e.previewEnabled?(H(),U(`td`,Og,[K(c,{class:`d-flex ext-icon-preview`,title:e.t(t.productType!==e.CatalogProductTypeEnum.LISTED||t.inactive?`PreviewNotAvailable`:`Preview`,!0),disabled:t.productType!==e.CatalogProductTypeEnum.LISTED||t.inactive,onClick:X(n=>t.productType===e.CatalogProductTypeEnum.LISTED&&!t.inactive&&e.previewByProductId(t.alternateProductId||t.productId),[`prevent`])},{default:P(()=>[K(s,{name:`eye-show`,size:24})]),_:1},8,[`title`,`disabled`,`onClick`])])):J(``,!0),(H(!0),U(V,null,z(e.columns,(n,r)=>(H(),U(`td`,{key:r,style:{"max-width":`100px`,"white-space":`nowrap`,overflow:`hidden`,"text-overflow":`ellipsis`}},[n.cellTemplate?(H(),W(o,{key:0,callbacks:n.cellTemplate,ctx:e.cellCtx({item:t,col:n})},null,8,[`callbacks`,`ctx`])):n.dataField==`ProductId`?(H(),U(`div`,kg,[t.inactive?(H(),U(`span`,Ag,j(e.attrValue(t,n.dataField)),1)):(H(),W(c,{key:0,onClick:n=>e.details(t)},{default:P(()=>[q(j(e.attrValue(t,n.dataField)),1)]),_:2},1032,[`onClick`])),t.productType==e.catalogProductType.CONFIGURED?(H(),U(`div`,jg,[G(`em`,null,j(e.t(`ConfiguredProducts`)),1)])):J(``,!0)])):(H(),U(`div`,Mg,j(e.attrValue(t,n.dataField)),1))]))),128)),e.actionsEnabled?(H(),U(`td`,Ng,[G(`ul`,Pg,[(H(!0),U(V,null,z(e.aliasItemMenuItems(t),(n,r)=>(H(),U(`li`,{key:r},[n.itemTemplate?(H(),W(o,{key:0,callbacks:n.itemTemplate,ctx:e.menuItemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(`button`,{key:1,type:`button`,class:`btn btn-link text-dark`,disabled:e.isDisabled(n,t),onClick:X(r=>!e.isDisabled(n,t)&&e.onAliasItemMenuAction(n,t),[`prevent`])},[n.text?(H(),U(`span`,Ig,j(n.text),1)):J(``,!0),n.icon?(H(),W(s,{key:1,name:n.icon},null,8,[`name`])):J(``,!0)],8,Fg))]))),128))])])):J(``,!0)],2)}),128))])])])):J(``,!0)],64)):J(``,!0)],2)}var Rg=Q(gg,[[`render`,Lg]]);function zg(e,t,n){var r,i,a,o,s;t??(t=100);function c(){var l=Date.now()-o;l<t&&l>=0?r=setTimeout(c,t-l):(r=null,n||(s=e.apply(a,i),a=i=null))}var l=function(){a=this,i=arguments,o=Date.now();var l=n&&!r;return r||(r=setTimeout(c,t)),l&&(s=e.apply(a,i),a=i=null),s};return l.clear=function(){r&&(clearTimeout(r),r=null)},l.flush=function(){r&&(s=e.apply(a,i),a=i=null,clearTimeout(r),r=null)},l}zg.debounce=zg;var Bg=zg;function Vg(e,t,n){tn(e)?I(e,(e,r)=>{r==null||r.removeEventListener(t,n),e==null||e.addEventListener(t,n)}):kr(()=>{e.addEventListener(t,n)}),Mr(()=>{var r;(r=on(e))==null||r.removeEventListener(t,n)})}function Hg(e,t){return typeof window>`u`||!window?void 0:Vg(window,`pointerdown`,n=>{let r=on(e);r&&(r===n.target||n.composedPath().includes(r)||t(n))})}function Ug(e,t,n){let r=null,i=M(!1);kr(()=>{(e.content!==void 0||n.value)&&(i.value=!0),r=new MutationObserver(a),r.observe(t.value,{childList:!0,subtree:!0})}),Mr(()=>r.disconnect()),I(n,e=>{e?i.value=!0:i.value=!1});let a=()=>{e.content?i.value=!0:i.value=!1};return{hasContent:i}}function Wg(e,t){var n=e.getBoundingClientRect(),r=1,i=1;return{width:n.width/r,height:n.height/i,top:n.top/i,right:n.right/r,bottom:n.bottom/i,left:n.left/r,x:n.left/r,y:n.top/i}}function Gg(e){if(e==null)return window;if(e.toString()!==`[object Window]`){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Kg(e){var t=Gg(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function qg(e){return e instanceof Gg(e).Element||e instanceof Element}function Jg(e){return e instanceof Gg(e).HTMLElement||e instanceof HTMLElement}function Yg(e){return typeof ShadowRoot>`u`?!1:e instanceof Gg(e).ShadowRoot||e instanceof ShadowRoot}function Xg(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Zg(e){return e===Gg(e)||!Jg(e)?Kg(e):Xg(e)}function Qg(e){return e?(e.nodeName||``).toLowerCase():null}function $g(e){return((qg(e)?e.ownerDocument:e.document)||window.document).documentElement}function e_(e){return Wg($g(e)).left+Kg(e).scrollLeft}function t_(e){return Gg(e).getComputedStyle(e)}function n_(e){var t=t_(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function r_(e){var t=e.getBoundingClientRect(),n=t.width/e.offsetWidth||1,r=t.height/e.offsetHeight||1;return n!==1||r!==1}function i_(e,t,n){n===void 0&&(n=!1);var r=Jg(t);Jg(t)&&r_(t);var i=$g(t),a=Wg(e),o={scrollLeft:0,scrollTop:0},s={x:0,y:0};return(r||!r&&!n)&&((Qg(t)!==`body`||n_(i))&&(o=Zg(t)),Jg(t)?(s=Wg(t),s.x+=t.clientLeft,s.y+=t.clientTop):i&&(s.x=e_(i))),{x:a.left+o.scrollLeft-s.x,y:a.top+o.scrollTop-s.y,width:a.width,height:a.height}}function a_(e){var t=Wg(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function o_(e){return Qg(e)===`html`?e:e.assignedSlot||e.parentNode||(Yg(e)?e.host:null)||$g(e)}function s_(e){return[`html`,`body`,`#document`].indexOf(Qg(e))>=0?e.ownerDocument.body:Jg(e)&&n_(e)?e:s_(o_(e))}function c_(e,t){var n;t===void 0&&(t=[]);var r=s_(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),a=Gg(r),o=i?[a].concat(a.visualViewport||[],n_(r)?r:[]):r,s=t.concat(o);return i?s:s.concat(c_(o_(o)))}function l_(e){return[`table`,`td`,`th`].indexOf(Qg(e))>=0}function u_(e){return!Jg(e)||t_(e).position===`fixed`?null:e.offsetParent}function d_(e){var t=navigator.userAgent.toLowerCase().indexOf(`firefox`)!==-1;if(navigator.userAgent.indexOf(`Trident`)!==-1&&Jg(e)&&t_(e).position===`fixed`)return null;for(var n=o_(e);Jg(n)&&[`html`,`body`].indexOf(Qg(n))<0;){var r=t_(n);if(r.transform!==`none`||r.perspective!==`none`||r.contain===`paint`||[`transform`,`perspective`].indexOf(r.willChange)!==-1||t&&r.willChange===`filter`||t&&r.filter&&r.filter!==`none`)return n;n=n.parentNode}return null}function f_(e){for(var t=Gg(e),n=u_(e);n&&l_(n)&&t_(n).position===`static`;)n=u_(n);return n&&(Qg(n)===`html`||Qg(n)===`body`&&t_(n).position===`static`)?t:n||d_(e)||t}var p_=`top`,m_=`bottom`,h_=`right`,g_=`left`,__=`auto`,v_=[p_,m_,h_,g_],y_=`start`,b_=`end`,x_=`clippingParents`,S_=`viewport`,C_=`popper`,w_=`reference`,T_=v_.reduce(function(e,t){return e.concat([t+`-`+y_,t+`-`+b_])},[]),E_=[].concat(v_,[__]).reduce(function(e,t){return e.concat([t,t+`-`+y_,t+`-`+b_])},[]),D_=[`beforeRead`,`read`,`afterRead`,`beforeMain`,`main`,`afterMain`,`beforeWrite`,`write`,`afterWrite`];function O_(e){var t=new Map,n=new Set,r=[];e.forEach(function(e){t.set(e.name,e)});function i(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!n.has(e)){var r=t.get(e);r&&i(r)}}),r.push(e)}return e.forEach(function(e){n.has(e.name)||i(e)}),r}function k_(e){var t=O_(e);return D_.reduce(function(e,n){return e.concat(t.filter(function(e){return e.phase===n}))},[])}function A_(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function j_(e){return e.split(`-`)[0]}function M_(e){var t=e.reduce(function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e},{});return Object.keys(t).map(function(e){return t[e]})}function N_(e){var t=Gg(e),n=$g(e),r=t.visualViewport,i=n.clientWidth,a=n.clientHeight,o=0,s=0;return r&&(i=r.width,a=r.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(o=r.offsetLeft,s=r.offsetTop)),{width:i,height:a,x:o+e_(e),y:s}}var P_=Math.max,F_=Math.min,I_=Math.round;function L_(e){var t,n=$g(e),r=Kg(e),i=(t=e.ownerDocument)==null?void 0:t.body,a=P_(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),o=P_(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-r.scrollLeft+e_(e),c=-r.scrollTop;return t_(i||n).direction===`rtl`&&(s+=P_(n.clientWidth,i?i.clientWidth:0)-a),{width:a,height:o,x:s,y:c}}function R_(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Yg(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function z_(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function B_(e){var t=Wg(e);return t.top+=e.clientTop,t.left+=e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}function V_(e,t){return t===S_?z_(N_(e)):Jg(t)?B_(t):z_(L_($g(e)))}function H_(e){var t=c_(o_(e)),n=[`absolute`,`fixed`].indexOf(t_(e).position)>=0&&Jg(e)?f_(e):e;return qg(n)?t.filter(function(e){return qg(e)&&R_(e,n)&&Qg(e)!==`body`}):[]}function U_(e,t,n){var r=t===`clippingParents`?H_(e):[].concat(t),i=[].concat(r,[n]),a=i[0],o=i.reduce(function(t,n){var r=V_(e,n);return t.top=P_(r.top,t.top),t.right=F_(r.right,t.right),t.bottom=F_(r.bottom,t.bottom),t.left=P_(r.left,t.left),t},V_(e,a));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function W_(e){return e.split(`-`)[1]}function G_(e){return[`top`,`bottom`].indexOf(e)>=0?`x`:`y`}function K_(e){var t=e.reference,n=e.element,r=e.placement,i=r?j_(r):null,a=r?W_(r):null,o=t.x+t.width/2-n.width/2,s=t.y+t.height/2-n.height/2,c;switch(i){case p_:c={x:o,y:t.y-n.height};break;case m_:c={x:o,y:t.y+t.height};break;case h_:c={x:t.x+t.width,y:s};break;case g_:c={x:t.x-n.width,y:s};break;default:c={x:t.x,y:t.y}}var l=i?G_(i):null;if(l!=null){var u=l===`y`?`height`:`width`;switch(a){case y_:c[l]=c[l]-(t[u]/2-n[u]/2);break;case b_:c[l]=c[l]+(t[u]/2-n[u]/2)}}return c}function q_(){return{top:0,right:0,bottom:0,left:0}}function J_(e){return Object.assign({},q_(),e)}function Y_(e,t){return t.reduce(function(t,n){return t[n]=e,t},{})}function X_(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=r===void 0?e.placement:r,a=n.boundary,o=a===void 0?x_:a,s=n.rootBoundary,c=s===void 0?S_:s,l=n.elementContext,u=l===void 0?C_:l,d=n.altBoundary,f=d!==void 0&&d,p=n.padding,m=p===void 0?0:p,h=J_(typeof m==`number`?Y_(m,v_):m),g=u===C_?w_:C_,_=e.rects.popper,v=e.elements[f?g:u],y=U_(qg(v)?v:v.contextElement||$g(e.elements.popper),o,c),b=Wg(e.elements.reference),x=K_({reference:b,element:_,strategy:`absolute`,placement:i}),S=z_(Object.assign({},_,x)),C=u===C_?S:b,w={top:y.top-C.top+h.top,bottom:C.bottom-y.bottom+h.bottom,left:y.left-C.left+h.left,right:C.right-y.right+h.right},T=e.modifiersData.offset;if(u===C_&&T){var E=T[i];Object.keys(w).forEach(function(e){var t=[h_,m_].indexOf(e)>=0?1:-1,n=[p_,m_].indexOf(e)>=0?`y`:`x`;w[e]+=E[n]*t})}return w}var Z_={placement:`bottom`,modifiers:[],strategy:`absolute`};function Q_(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(e){return!(e&&typeof e.getBoundingClientRect==`function`)})}function $_(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,i=t.defaultOptions,a=i===void 0?Z_:i;return function(e,t,n){n===void 0&&(n=a);var i={placement:`bottom`,orderedModifiers:[],options:Object.assign({},Z_,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},o=[],s=!1,c={state:i,setOptions:function(n){var o=typeof n==`function`?n(i.options):n;u(),i.options=Object.assign({},a,i.options,o),i.scrollParents={reference:qg(e)?c_(e):e.contextElement?c_(e.contextElement):[],popper:c_(t)};var s=k_(M_([].concat(r,i.options.modifiers)));return i.orderedModifiers=s.filter(function(e){return e.enabled}),l(),c.update()},forceUpdate:function(){if(!s){var e=i.elements,t=e.reference,n=e.popper;if(Q_(t,n)){i.rects={reference:i_(t,f_(n),i.options.strategy===`fixed`),popper:a_(n)},i.reset=!1,i.placement=i.options.placement,i.orderedModifiers.forEach(function(e){return i.modifiersData[e.name]=Object.assign({},e.data)});for(var r=0;r<i.orderedModifiers.length;r++){if(i.reset===!0){i.reset=!1,r=-1;continue}var a=i.orderedModifiers[r],o=a.fn,l=a.options,u=l===void 0?{}:l,d=a.name;typeof o==`function`&&(i=o({state:i,options:u,name:d,instance:c})||i)}}}},update:A_(function(){return new Promise(function(e){c.forceUpdate(),e(i)})}),destroy:function(){u(),s=!0}};if(!Q_(e,t))return c;c.setOptions(n).then(function(e){!s&&n.onFirstUpdate&&n.onFirstUpdate(e)});function l(){i.orderedModifiers.forEach(function(e){var t=e.name,n=e.options,r=n===void 0?{}:n,a=e.effect;if(typeof a==`function`){var s=a({state:i,name:t,instance:c,options:r});o.push(s||function(){})}})}function u(){o.forEach(function(e){return e()}),o=[]}return c}}var ev={passive:!0};function tv(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,a=i===void 0||i,o=r.resize,s=o===void 0||o,c=Gg(t.elements.popper),l=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&l.forEach(function(e){e.addEventListener(`scroll`,n.update,ev)}),s&&c.addEventListener(`resize`,n.update,ev),function(){a&&l.forEach(function(e){e.removeEventListener(`scroll`,n.update,ev)}),s&&c.removeEventListener(`resize`,n.update,ev)}}var nv={name:`eventListeners`,enabled:!0,phase:`write`,fn:function(){},effect:tv,data:{}};function rv(e){var t=e.state,n=e.name;t.modifiersData[n]=K_({reference:t.rects.reference,element:t.rects.popper,strategy:`absolute`,placement:t.placement})}var iv={name:`popperOffsets`,enabled:!0,phase:`read`,fn:rv,data:{}},av={top:`auto`,right:`auto`,bottom:`auto`,left:`auto`};function ov(e){var t=e.x,n=e.y,r=window.devicePixelRatio||1;return{x:I_(I_(t*r)/r)||0,y:I_(I_(n*r)/r)||0}}function sv(e){var t,n=e.popper,r=e.popperRect,i=e.placement,a=e.variation,o=e.offsets,s=e.position,c=e.gpuAcceleration,l=e.adaptive,u=e.roundOffsets,d=u===!0?ov(o):typeof u==`function`?u(o):o,f=d.x,p=f===void 0?0:f,m=d.y,h=m===void 0?0:m,g=o.hasOwnProperty(`x`),_=o.hasOwnProperty(`y`),v=g_,y=p_,b=window;if(l){var x=f_(n),S=`clientHeight`,C=`clientWidth`;x===Gg(n)&&(x=$g(n),t_(x).position!==`static`&&s===`absolute`&&(S=`scrollHeight`,C=`scrollWidth`)),x=x,(i===p_||(i===g_||i===h_)&&a===b_)&&(y=m_,h-=x[S]-r.height,h*=c?1:-1),(i===g_||(i===p_||i===m_)&&a===b_)&&(v=h_,p-=x[C]-r.width,p*=c?1:-1)}var w=Object.assign({position:s},l&&av);if(c){var T;return Object.assign({},w,(T={},T[y]=_?`0`:``,T[v]=g?`0`:``,T.transform=(b.devicePixelRatio||1)<=1?`translate(`+p+`px, `+h+`px)`:`translate3d(`+p+`px, `+h+`px, 0)`,T))}return Object.assign({},w,(t={},t[y]=_?h+`px`:``,t[v]=g?p+`px`:``,t.transform=``,t))}function cv(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=r===void 0||r,a=n.adaptive,o=a===void 0||a,s=n.roundOffsets,c=s===void 0||s,l={placement:j_(t.placement),variation:W_(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,sv(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,sv(Object.assign({},l,{offsets:t.modifiersData.arrow,position:`absolute`,adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var lv={name:`computeStyles`,enabled:!0,phase:`beforeWrite`,fn:cv,data:{}};function uv(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},i=t.elements[e];!Jg(i)||!Qg(i)||(Object.assign(i.style,n),Object.keys(r).forEach(function(e){var t=r[e];t===!1?i.removeAttribute(e):i.setAttribute(e,t===!0?``:t)}))})}function dv(e){var t=e.state,n={popper:{position:t.options.strategy,left:`0`,top:`0`,margin:`0`},arrow:{position:`absolute`},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(e){var r=t.elements[e],i=t.attributes[e]||{},a=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce(function(e,t){return e[t]=``,e},{});!Jg(r)||!Qg(r)||(Object.assign(r.style,a),Object.keys(i).forEach(function(e){r.removeAttribute(e)}))})}}var fv=$_({defaultModifiers:[nv,iv,lv,{name:`applyStyles`,enabled:!0,phase:`write`,fn:uv,effect:dv,requires:[`computeStyles`]}]});function pv(e){return e===`x`?`y`:`x`}function mv(e,t,n){return P_(e,F_(t,n))}function hv(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,a=i===void 0||i,o=n.altAxis,s=o!==void 0&&o,c=n.boundary,l=n.rootBoundary,u=n.altBoundary,d=n.padding,f=n.tether,p=f===void 0||f,m=n.tetherOffset,h=m===void 0?0:m,g=X_(t,{boundary:c,rootBoundary:l,padding:d,altBoundary:u}),_=j_(t.placement),v=W_(t.placement),y=!v,b=G_(_),x=pv(b),S=t.modifiersData.popperOffsets,C=t.rects.reference,w=t.rects.popper,T=typeof h==`function`?h(Object.assign({},t.rects,{placement:t.placement})):h,E={x:0,y:0};if(S){if(a||s){var D=b===`y`?p_:g_,ee=b===`y`?m_:h_,O=b===`y`?`height`:`width`,te=S[b],ne=S[b]+g[D],re=S[b]-g[ee],ie=p?-w[O]/2:0,ae=v===y_?C[O]:w[O],oe=v===y_?-w[O]:-C[O],se=t.elements.arrow,ce=p&&se?a_(se):{width:0,height:0},le=t.modifiersData[`arrow#persistent`]?t.modifiersData[`arrow#persistent`].padding:q_(),ue=le[D],de=le[ee],k=mv(0,C[O],ce[O]),fe=y?C[O]/2-ie-k-ue-T:ae-k-ue-T,pe=y?-C[O]/2+ie+k+de+T:oe+k+de+T,me=t.elements.arrow&&f_(t.elements.arrow),he=me?b===`y`?me.clientTop||0:me.clientLeft||0:0,A=t.modifiersData.offset?t.modifiersData.offset[t.placement][b]:0,ge=S[b]+fe-A-he,_e=S[b]+pe-A;if(a){var ve=mv(p?F_(ne,ge):ne,te,p?P_(re,_e):re);S[b]=ve,E[b]=ve-te}if(s){var ye=b===`x`?p_:g_,be=b===`x`?m_:h_,xe=S[x],Se=xe+g[ye],Ce=xe-g[be],j=mv(p?F_(Se,ge):Se,xe,p?P_(Ce,_e):Ce);S[x]=j,E[x]=j-xe}}t.modifiersData[r]=E}}var gv={name:`preventOverflow`,enabled:!0,phase:`main`,fn:hv,requiresIfExists:[`offset`]},_v={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function vv(e){return e.replace(/left|right|bottom|top/g,function(e){return _v[e]})}var yv={start:`end`,end:`start`};function bv(e){return e.replace(/start|end/g,function(e){return yv[e]})}function xv(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=n.boundary,a=n.rootBoundary,o=n.padding,s=n.flipVariations,c=n.allowedAutoPlacements,l=c===void 0?E_:c,u=W_(r),d=u?s?T_:T_.filter(function(e){return W_(e)===u}):v_,f=d.filter(function(e){return l.indexOf(e)>=0});f.length===0&&(f=d);var p=f.reduce(function(t,n){return t[n]=X_(e,{placement:n,boundary:i,rootBoundary:a,padding:o})[j_(n)],t},{});return Object.keys(p).sort(function(e,t){return p[e]-p[t]})}function Sv(e){if(j_(e)===__)return[];var t=vv(e);return[bv(e),t,bv(t)]}function Cv(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,a=i===void 0||i,o=n.altAxis,s=o===void 0||o,c=n.fallbackPlacements,l=n.padding,u=n.boundary,d=n.rootBoundary,f=n.altBoundary,p=n.flipVariations,m=p===void 0||p,h=n.allowedAutoPlacements,g=t.options.placement,_=j_(g)===g,v=c||(_||!m?[vv(g)]:Sv(g)),y=[g].concat(v).reduce(function(e,n){return e.concat(j_(n)===__?xv(t,{placement:n,boundary:u,rootBoundary:d,padding:l,flipVariations:m,allowedAutoPlacements:h}):n)},[]),b=t.rects.reference,x=t.rects.popper,S=new Map,C=!0,w=y[0],T=0;T<y.length;T++){var E=y[T],D=j_(E),ee=W_(E)===y_,O=[p_,m_].indexOf(D)>=0,te=O?`width`:`height`,ne=X_(t,{placement:E,boundary:u,rootBoundary:d,altBoundary:f,padding:l}),re=O?ee?h_:g_:ee?m_:p_;b[te]>x[te]&&(re=vv(re));var ie=vv(re),ae=[];if(a&&ae.push(ne[D]<=0),s&&ae.push(ne[re]<=0,ne[ie]<=0),ae.every(function(e){return e})){w=E,C=!1;break}S.set(E,ae)}if(C)for(var oe=m?3:1,se=function(e){var t=y.find(function(t){var n=S.get(t);if(n)return n.slice(0,e).every(function(e){return e})});if(t)return w=t,`break`},ce=oe;ce>0&&se(ce)!==`break`;ce--);t.placement!==w&&(t.modifiersData[r]._skip=!0,t.placement=w,t.reset=!0)}}var wv={name:`flip`,enabled:!0,phase:`main`,fn:Cv,requiresIfExists:[`offset`],data:{_skip:!1}};function Tv(e,t,n){var r=j_(e),i=[g_,p_].indexOf(r)>=0?-1:1,a=typeof n==`function`?n(Object.assign({},t,{placement:e})):n,o=a[0],s=a[1];return o=o||0,s=(s||0)*i,[g_,h_].indexOf(r)>=0?{x:s,y:o}:{x:o,y:s}}function Ev(e){var t=e.state,n=e.options,r=e.name,i=n.offset,a=i===void 0?[0,0]:i,o=E_.reduce(function(e,n){return e[n]=Tv(n,t.rects,a),e},{}),s=o[t.placement],c=s.x,l=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=l),t.modifiersData[r]=o}var Dv={name:`offset`,enabled:!0,phase:`main`,requires:[`popperOffsets`],fn:Ev},Ov=function(e,t){return e=typeof e==`function`?e(Object.assign({},t.rects,{placement:t.placement})):e,J_(typeof e==`number`?Y_(e,v_):e)};function kv(e){var t,n=e.state,r=e.name,i=e.options,a=n.elements.arrow,o=n.modifiersData.popperOffsets,s=j_(n.placement),c=G_(s),l=[g_,h_].indexOf(s)>=0?`height`:`width`;if(!(!a||!o)){var u=Ov(i.padding,n),d=a_(a),f=c===`y`?p_:g_,p=c===`y`?m_:h_,m=n.rects.reference[l]+n.rects.reference[c]-o[c]-n.rects.popper[l],h=o[c]-n.rects.reference[c],g=f_(a),_=g?c===`y`?g.clientHeight||0:g.clientWidth||0:0,v=m/2-h/2,y=u[f],b=_-d[l]-u[p],x=_/2-d[l]/2+v,S=mv(y,x,b),C=c;n.modifiersData[r]=(t={},t[C]=S,t.centerOffset=S-x,t)}}function Av(e){var t=e.state,n=e.options.element,r=n===void 0?`[data-popper-arrow]`:n;r!=null&&(typeof r==`string`&&(r=t.elements.popper.querySelector(r),!r)||R_(t.elements.popper,r)&&(t.elements.arrow=r))}var jv={name:`arrow`,enabled:!0,phase:`main`,fn:kv,effect:Av,requires:[`popperOffsets`],requiresIfExists:[`preventOverflow`]},Mv=e=>parseInt(e,10);function Nv({arrowPadding:e,emit:t,locked:n,offsetDistance:r,offsetSkid:i,placement:a,popperNode:o,triggerNode:s}){let c=Ut({isOpen:!1,popperInstance:null}),l=e=>{var t;(t=c.popperInstance)==null||t.setOptions(t=>({...t,modifiers:[...t.modifiers,{name:`eventListeners`,enabled:e}]}))},u=()=>l(!0),d=()=>l(!1),f=()=>{c.isOpen&&(c.isOpen=!1,t(`close:popper`))},p=()=>{c.isOpen||(c.isOpen=!0,t(`open:popper`))};I([()=>c.isOpen,a],async([e])=>{e?(await m(),u()):d()});let m=async()=>{await jn(),c.popperInstance=fv(s.value,o.value,{placement:a.value,modifiers:[gv,wv,{name:`flip`,enabled:!n.value},jv,{name:`arrow`,options:{padding:Mv(e.value)}},Dv,{name:`offset`,options:{offset:[Mv(i.value),Mv(r.value)]}}]}),c.popperInstance.update()};return Mr(()=>{var e;(e=c.popperInstance)==null||e.destroy()}),{...ln(c),open:p,close:f}}var Pv={id:`arrow`,"data-popper-arrow":``};function Fv(e,t){return H(),U(`div`,Pv)}function Iv(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(!e||typeof document>`u`)){var r=document.head||document.getElementsByTagName(`head`)[0],i=document.createElement(`style`);i.type=`text/css`,n===`top`&&r.firstChild?r.insertBefore(i,r.firstChild):r.appendChild(i),i.styleSheet?i.styleSheet.cssText=e:i.appendChild(document.createTextNode(e))}}Iv(`
7
+ #arrow[data-v-20b7fd4a],
8
+ #arrow[data-v-20b7fd4a]::before {
9
+ transition: background 250ms ease-in-out;
10
+ position: absolute;
11
+ width: calc(10px - var(--popper-theme-border-width, 0px));
12
+ height: calc(10px - var(--popper-theme-border-width, 0px));
13
+ box-sizing: border-box;
14
+ background: var(--popper-theme-background-color);
15
+ }
16
+ #arrow[data-v-20b7fd4a] {
17
+ visibility: hidden;
18
+ }
19
+ #arrow[data-v-20b7fd4a]::before {
20
+ visibility: visible;
21
+ content: "";
22
+ transform: rotate(45deg);
23
+ }
24
+
25
+ /* Top arrow */
26
+ .popper[data-popper-placement^="top"] > #arrow[data-v-20b7fd4a] {
27
+ bottom: -5px;
28
+ }
29
+ .popper[data-popper-placement^="top"] > #arrow[data-v-20b7fd4a]::before {
30
+ border-right: var(--popper-theme-border-width)
31
+ var(--popper-theme-border-style) var(--popper-theme-border-color);
32
+ border-bottom: var(--popper-theme-border-width)
33
+ var(--popper-theme-border-style) var(--popper-theme-border-color);
34
+ }
35
+
36
+ /* Bottom arrow */
37
+ .popper[data-popper-placement^="bottom"] > #arrow[data-v-20b7fd4a] {
38
+ top: -5px;
39
+ }
40
+ .popper[data-popper-placement^="bottom"] > #arrow[data-v-20b7fd4a]::before {
41
+ border-left: var(--popper-theme-border-width)
42
+ var(--popper-theme-border-style) var(--popper-theme-border-color);
43
+ border-top: var(--popper-theme-border-width)
44
+ var(--popper-theme-border-style) var(--popper-theme-border-color);
45
+ }
46
+
47
+ /* Left arrow */
48
+ .popper[data-popper-placement^="left"] > #arrow[data-v-20b7fd4a] {
49
+ right: -5px;
50
+ }
51
+ .popper[data-popper-placement^="left"] > #arrow[data-v-20b7fd4a]::before {
52
+ border-right: var(--popper-theme-border-width)
53
+ var(--popper-theme-border-style) var(--popper-theme-border-color);
54
+ border-top: var(--popper-theme-border-width)
55
+ var(--popper-theme-border-style) var(--popper-theme-border-color);
56
+ }
57
+
58
+ /* Right arrow */
59
+ .popper[data-popper-placement^="right"] > #arrow[data-v-20b7fd4a] {
60
+ left: -5px;
61
+ }
62
+ `);var Lv={};Lv.render=Fv,Lv.__scopeId=`data-v-20b7fd4a`;var Rv=Lv,zv=[`onKeyup`],Bv={props:{placement:{type:String,default:`bottom`,validator:function(e){return[`auto`,`auto-start`,`auto-end`,`top`,`top-start`,`top-end`,`bottom`,`bottom-start`,`bottom-end`,`right`,`right-start`,`right-end`,`left`,`left-start`,`left-end`].includes(e)}},disableClickAway:{type:Boolean,default:!1},offsetSkid:{type:String,default:`0`},offsetDistance:{type:String,default:`12`},hover:{type:Boolean,default:!1},show:{type:Boolean,default:null},disabled:{type:Boolean,default:!1},openDelay:{type:[Number,String],default:0},closeDelay:{type:[Number,String],default:0},zIndex:{type:[Number,String],default:9999},arrow:{type:Boolean,default:!1},arrowPadding:{type:String,default:`0`},interactive:{type:Boolean,default:!0},locked:{type:Boolean,default:!1},content:{type:String,default:null}},emits:[`open:popper`,`close:popper`],setup(e,{emit:t}){let n=e;Fo(t=>({c81fc0a4:e.zIndex}));let r=Qr(),i=M(null),a=M(null),o=M(null),s=M(!1);kr(()=>{let e=r.default();if(e&&e.length>1)return console.error(`[Popper]: The <Popper> component expects only one child element at its root. You passed ${e.length} child nodes.`)});let{arrowPadding:c,closeDelay:l,content:u,disableClickAway:d,disabled:f,interactive:p,locked:m,offsetDistance:h,offsetSkid:g,openDelay:_,placement:v,show:y}=ln(n),{isOpen:b,open:x,close:S}=Nv({arrowPadding:c,emit:t,locked:m,offsetDistance:h,offsetSkid:g,placement:v,popperNode:a,triggerNode:o}),{hasContent:C}=Ug(r,a,u),w=Y(()=>y.value!==null),T=Y(()=>f.value||!C.value),E=Y(()=>b.value&&!T.value),D=Y(()=>!d.value&&!w.value),ee=Y(()=>p.value?`border: ${h.value}px solid transparent; margin: -${h.value}px;`:null),O=Bg.debounce(x,_.value),te=Bg.debounce(S,l.value),ne=async()=>{T.value||w.value||(te.clear(),O())},re=async()=>{w.value||(O.clear(),te())},ie=()=>{b.value?re():ne()};return I([C,f],([e,t])=>{b.value&&(!e||t)&&S()}),I(b,e=>{e?s.value=!0:Bg.debounce(()=>{s.value=!1},200)}),Jn(()=>{w.value&&(y.value?O():te())}),Jn(()=>{D.value&&Hg(i,re)}),(t,n)=>(H(),U(`div`,{class:`inline-block`,style:k(on(ee)),onMouseleave:n[2]||(n[2]=t=>e.hover&&re()),ref:(e,t)=>{t.popperContainerNode=e,i.value=e}},[G(`div`,{ref:(e,t)=>{t.triggerNode=e,o.value=e},onMouseover:n[0]||(n[0]=t=>e.hover&&ne()),onClick:ie,onFocus:ne,onKeyup:Ns(re,[`esc`])},[B(t.$slots,`default`)],40,zv),K(mo,{name:`fade`},{default:P(()=>[F(G(`div`,{onClick:n[1]||(n[1]=e=>!on(p)&&re()),class:`popper`,ref:(e,t)=>{t.popperNode=e,a.value=e}},[B(t.$slots,`content`,{close:on(S),isOpen:s.value},()=>[q(j(on(u)),1)]),e.arrow?(H(),W(Rv,{key:0})):J(``,!0)],512),[[Mo,on(E)]])]),_:3})],36))}};Iv(`
63
+ .inline-block[data-v-5784ed69] {
64
+ display: inline-block;
65
+ }
66
+ .popper[data-v-5784ed69] {
67
+ transition: background 250ms ease-in-out;
68
+ background: var(--popper-theme-background-color);
69
+ padding: var(--popper-theme-padding);
70
+ color: var(--popper-theme-text-color);
71
+ border-radius: var(--popper-theme-border-radius);
72
+ border-width: var(--popper-theme-border-width);
73
+ border-style: var(--popper-theme-border-style);
74
+ border-color: var(--popper-theme-border-color);
75
+ box-shadow: var(--popper-theme-box-shadow);
76
+ z-index: var(--c81fc0a4);
77
+ }
78
+ .popper[data-v-5784ed69]:hover,
79
+ .popper:hover > #arrow[data-v-5784ed69]::before {
80
+ background: var(--popper-theme-background-color-hover);
81
+ }
82
+ .inline-block[data-v-5784ed69] {
83
+ display: inline-block;
84
+ }
85
+ .fade-enter-active[data-v-5784ed69],
86
+ .fade-leave-active[data-v-5784ed69] {
87
+ transition: opacity 0.2s ease;
88
+ }
89
+ .fade-enter-from[data-v-5784ed69],
90
+ .fade-leave-to[data-v-5784ed69] {
91
+ opacity: 0;
92
+ }
93
+ `),Bv.__scopeId=`data-v-5784ed69`;var Vv=(()=>{let e=Bv;return e.install=t=>{t.component(`Popper`,e)},e})(),Hv=L({name:`DropdownPopper`,components:{Popper:Vv},props:{top:{type:Boolean,default:!1}},setup(e){let t=M();return{open:()=>{let n=t.value;jn(()=>{let t=n.$el.querySelector(`.dropdown-menu`),r=n.$el.querySelector(`.btn`);if(t&&r){let n=-(t.clientWidth-r.clientWidth),i=0;e.top&&(i=-(t.clientHeight+r.clientHeight+24)),t.style.transform=`translate(${n}px, ${i}px)`,t.classList.add(`shadow-sm`)}})},popper:t}}});function Uv(e,t,n,r,i,a){let o=R(`Popper`);return H(),W(o,Oa({ref:`popper`},e.$attrs,{"onOpen:popper":e.open}),{content:P(({close:t})=>[B(e.$slots,`dropdown`,{close:t})]),default:P(()=>[B(e.$slots,`trigger`)]),_:3},16,[`onOpen:popper`])}var Wv=Q(Hv,[[`render`,Uv]]),Gv=L({props:{totalCount:{type:Number,default:0},page:{type:Number,default:0},pageSize:{type:Number,default:0},showingText:{type:String,default:void 0},ofText:{type:String,default:void 0}},setup(e){return{pageStart:Y(()=>((e.page??1)-1)*(e.pageSize??1)+1),pageEnd:Y(()=>Math.min((e.page??1)*(e.pageSize??1),e.totalCount))}}}),Kv={key:0,class:`mb-0`},qv={key:1,class:`mb-0`};function Jv(e,t,n,r,i,a){return e.totalCount>=e.pageSize?(H(),U(`p`,Kv,[q(j(e.showingText)+`\xA0`,1),G(`strong`,null,j(e.pageStart)+`-`+j(e.pageEnd),1),q(` `+j(e.ofText)+`\xA0`,1),G(`strong`,null,j(e.totalCount),1)])):(H(),U(`p`,qv,[q(j(e.showingText)+`\xA0`,1),G(`strong`,null,j(e.totalCount),1),q(` `+j(e.ofText)+`\xA0`,1),G(`strong`,null,j(e.totalCount),1)]))}var Yv=Q(Gv,[[`render`,Jv]]),Xv=L({name:`pis-catalogs-aliases-search-toolbar`,components:{PaginationAmount:Yv,DropdownPopper:Wv,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e,{emit:t}){let n=M(),r=M(!1),i=Bl,{componentName:a,isReady:o,isWebComponent:s,instance:c,store:l,routeData:u,t:d,widerThan:f,narrowerThan:p}=ym(n,e.instanceId),{onAliasListMenuAction:m}=bm(c,d,a),h=Y(()=>{var e;return(e=l.value)==null||(e=e.data.products)==null?void 0:e.totalCount}),g=Y(()=>{var e;return(e=u.value)==null?void 0:e.products.pagination}),_=Y({get:()=>{var e;return(e=u.value)==null?void 0:e.products.sortField},set:e=>{var t;return(t=c.value)==null?void 0:t.execute(new Bu({sortField:e}).from(a))}}),v=Y({get:()=>{var e;return((e=g.value)==null?void 0:e.pageSize)??24},set:e=>{var t;return(t=c.value)==null?void 0:t.execute(new Ru({pageSize:e}).from(a))}}),y=Y(()=>{var e;return(e=l.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.pageSizes}),b=Y(()=>{var e;return(e=l.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.visible}),x=Y(()=>{var e;return(e=l.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null||(e=e.actions)==null?void 0:e.aliasListMenu});return{root:n,componentName:a,isReady:o,isWebComponent:s,store:l,routeData:u,toolbarVisible:b,totalCount:h,pagination:g,sortByItems:i,sortBy:_,pageSizeItems:y,pageSize:v,exportMenuOpen:r,aliasListMenu:x,actionsEnabled:Y(()=>{var e,t;return((e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-aliases-search-actions-modals`))&&((t=x.value)==null?void 0:t.visible)}),instance:c,t:d,emit:t,widerThan:f,isDisabled:e=>typeof e.disabled==`function`?e.disabled():e.disabled,narrowerThan:p,aliasListMenuItems:()=>{var e;return(((e=x.value)==null?void 0:e.items)||[]).filter(e=>typeof e.visible==`function`?e.visible():e.visible)},onAliasListMenuAction:m,reactiveContext:lg,itemCtx:hg(e=>({instance:c.value,item:e.item,emit:t,t:d}))}}}),Zv={class:`d-flex flex-row justify-content-between align-items-center flex-wrap w-100`},Qv={key:0,class:`my-2 mx-2`},$v=[`value`],ey=[`value`,`textContent`],ty={class:`my-3 d-flex flex-row justify-content-end align-items-center flex-wrap`},ny={key:1,type:`button`,class:`btn btn-primary dropdown-toggle`},ry={class:`dropdown-menu show`},iy={key:0,class:`dropdown-divider`},ay={key:1,class:`dropdown-item text-muted`},oy=[`onClick`];function sy(e,t,n,r,i,a){var o;let s=R(`PaginationAmount`),c=R(`MountPoint`),l=R(`DropdownPopper`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.toolbarVisible?(H(),U(V,{key:0},[G(`div`,Zv,[e.totalCount&&e.pagination?(H(),U(`div`,Qv,[K(s,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0),class:A([e.narrowerThan(`sm`)&&`w-100 text-center`])},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`,`class`])])):J(``,!0),G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`SortBy`))+`:`,3),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.sortBy=t),class:A([`form-select ms-2`,[e.narrowerThan(`xl`)&&`w-100`]])},[(H(!0),U(V,null,z(e.sortByItems,(t,n)=>(H(),U(`option`,{key:n,value:t},j(e.t(`SortBy${t}`)),9,$v))),128))],2),[[Cs,e.sortBy]])],2),G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`PageSize`))+`:`,3),F(G(`select`,{"onUpdate:modelValue":t[1]||(t[1]=t=>e.pageSize=t),class:`form-select ms-2`},[(H(!0),U(V,null,z(e.pageSizeItems,e=>(H(),U(`option`,{key:e,value:e,textContent:j(e)},null,8,ey))),128))],512),[[Cs,e.pageSize]])],2)]),G(`div`,ty,[e.actionsEnabled&&(o=e.aliasListMenu)!=null&&o.items?(H(),U(`div`,{key:0,class:A([`d-flex my-1`,[e.narrowerThan(`sm`)&&`w-100 justify-content-end`]])},[K(l,{placement:`bottom-start`,interactive:!0},{trigger:P(()=>[e.aliasListMenu.buttonTemplate?(H(),W(c,{key:0,callbacks:e.aliasListMenu.buttonTemplate,ctx:e.reactiveContext({instance:e.instance,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])):(H(),U(`button`,ny,j(e.t(`Actions`)),1))]),dropdown:P(({close:t})=>[G(`ul`,ry,[(H(!0),U(V,null,z(e.aliasListMenuItems(),(n,r)=>(H(),U(`li`,{key:r},[n.text===`-`?(H(),U(`hr`,iy)):e.isDisabled(n)?(H(),U(`span`,ay,[n.itemTemplate?(H(),W(c,{key:0,callbacks:n.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(n.text),1)],64))])):(H(),U(`a`,{key:2,class:`dropdown-item`,href:``,onClick:X(r=>{e.onAliasListMenuAction(n),t()},[`prevent`])},[n.itemTemplate?(H(),W(c,{key:0,callbacks:n.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(n.text),1)],64))],8,oy))]))),128))])]),_:1})],2)):J(``,!0)])],64)):J(``,!0)],2)}var cy=Q(Xv,[[`render`,sy]]),ly=e=>e.path||e.composedPath&&e.composedPath()||[],uy=L({name:`pis-catalogs-aliases-search-filters`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!0),{isReady:r,isWebComponent:i,componentName:a,instance:o,store:s,routeData:c,t:l}=ym(t,e.instanceId,[Ud.ProductClassifications]),u=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.aliases)==null||(e=e.search)==null?void 0:e.filters)??{}}),d=Y(()=>u.value.visible),f=M(void 0),p=M(!1);return I(()=>{var e;return(e=c.value)==null?void 0:e.products.aliases},e=>f.value=e||Fl.ALL),{root:t,store:s,isReady:r,visible:d,trimList:n,isFiltering:p,AliasesEnum:Fl,componentName:a,isWebComponent:i,componentOptions:u,currentAliasType:f,t:l,onAliasTypeChange:async(e,t)=>{if(ly(e)[0].checked&&o.value&&t){f.value=t,p.value=!0;try{await o.value.execute(new Ou({aliasFilter:t}).from(a))}catch{}p.value=!1}}}}}),dy={key:0,class:`list-group list-group-flush`},fy={class:`list-group-item list-group-item-action`},py={class:`form-check mb-0 lh-sm`},my=[`value`,`disabled`,`checked`],hy={class:`form-check-label user-select-none pis-label`},gy={class:`list-group-item list-group-item-action`},_y={class:`form-check mb-0 lh-sm`},vy=[`value`,`disabled`,`checked`],yy={class:`form-check-label user-select-none pis-label`},by={class:`list-group-item list-group-item-action`},xy={class:`form-check mb-0 lh-sm`},Sy=[`value`,`disabled`,`checked`],Cy={class:`form-check-label user-select-none pis-label`};function wy(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,dy,[G(`label`,fy,[G(`div`,py,[G(`input`,{type:`radio`,class:`form-check-input me-2 flex-shrink-0`,value:e.AliasesEnum.ALL,disabled:e.isFiltering,checked:e.currentAliasType===e.AliasesEnum.ALL,onInput:t[0]||(t[0]=t=>e.onAliasTypeChange(t,e.AliasesEnum.ALL))},null,40,my),G(`span`,hy,j(e.t(`AllAliases`)),1)])]),G(`label`,gy,[G(`div`,_y,[G(`input`,{type:`radio`,class:`form-check-input me-2 flex-shrink-0`,value:e.AliasesEnum.BLANK,disabled:e.isFiltering,checked:e.currentAliasType===e.AliasesEnum.BLANK,onInput:t[1]||(t[1]=t=>e.onAliasTypeChange(t,e.AliasesEnum.BLANK))},null,40,vy),G(`span`,yy,j(e.t(`BlankAliases`)),1)])]),G(`label`,by,[G(`div`,xy,[G(`input`,{type:`radio`,class:`form-check-input me-2 flex-shrink-0`,value:e.AliasesEnum.POPULATED,disabled:e.isFiltering,checked:e.currentAliasType===e.AliasesEnum.POPULATED,onInput:t[2]||(t[2]=t=>e.onAliasTypeChange(t,e.AliasesEnum.POPULATED))},null,40,Sy),G(`span`,Cy,j(e.t(`PopulatedAliases`)),1)])])])):J(``,!0)],2)}var Ty=Q(uy,[[`render`,wy]]),Ey=L({props:{highlighted:Boolean,removable:Boolean,removeTitle:{type:String,default:void 0}},emits:[`remove`]}),Dy=[`title`];function Oy(e,t,n,r,i,a){return H(),U(`span`,{class:A([`d-inline-flex align-items-center badge rounded-pill`,[e.highlighted?`bg-primary text-light`:`bg-light text-body`]])},[B(e.$slots,`default`),e.removable?(H(),U(`button`,{key:0,class:`btn-close ms-1 ext-remove`,style:{"font-size":`0.65rem`},title:e.removeTitle,onClick:t[0]||(t[0]=X(t=>e.$emit(`remove`),[`prevent`]))},null,8,Dy)):J(``,!0)],2)}var ky=Q(Ey,[[`render`,Oy]]),Ay=L({props:{sm:Boolean}});function jy(e,t,n,r,i,a){return H(),U(`div`,{class:A([`spinner-border text-primary flex-shrink-0`,[e.sm&&`spinner-border-sm`]]),role:`status`},null,2)}var My=Q(Ay,[[`render`,jy]]),Ny=L({name:`Btn`,components:{Icon:$h,Badge:ky,Spinner:My},props:{link:Boolean,href:{type:String,default:void 0},lg:Boolean,icon:{type:String,default:void 0},vertical:Boolean,number:{type:Number,default:void 0},isLoading:Boolean,disabled:{type:Boolean,default:!1},primary:{type:Boolean,default:!1}}}),Py={key:0,class:`position-absolute top-50 start-50 translate-middle`};function Fy(e,t,n,r,i,a){let o=R(`Spinner`),s=R(`Icon`),c=R(`Badge`);return H(),W(Vr(e.link?`a`:`button`),{class:A([`btn position-relative`,[e.lg&&`btn-lg`,e.disabled&&`disabled`,e.primary?`btn-primary`:`btn-outline-primary`]]),"aria-disabled":e.disabled,href:e.link&&e.href?e.href:null,type:e.link?null:`submit`,disabled:e.disabled},{default:P(()=>[e.isLoading?(H(),U(`div`,Py,[t[0]||(t[0]=q(` \xA0`,-1)),K(o,{sm:``}),t[1]||(t[1]=q(`\xA0 `,-1))])):J(``,!0),G(`div`,{class:A([`d-flex align-items-center`,[e.isLoading&&`invisible`,e.vertical&&`flex-column py-2`]])},[e.icon?(H(),W(s,{key:0,class:A([`me-1`,[e.vertical&&`text-body`]]),name:e.icon,size:e.vertical?24:16},null,8,[`name`,`class`,`size`])):J(``,!0),B(e.$slots,`default`),e.number?(H(),W(c,{key:1,class:`mt-1`},{default:P(()=>[q(j(e.number),1)]),_:1})):J(``,!0)],2)]),_:3},8,[`aria-disabled`,`class`,`href`,`type`,`disabled`])}var Iy=Q(Ny,[[`render`,Fy]]),Ly=L({components:{Badge:ky,Clickable:wm},props:{categories:{type:Array,default:void 0},configuratorsNumberTitle:{type:String,default:void 0},configuratorsVisible:Boolean},emits:[`click-item`]}),Ry={class:`list-group list-group-flush`},zy={class:`pis-label text-break`},By={class:`d-flex align-items-center ms-auto`};function Vy(e,t,n,r,i,a){let o=R(`Badge`),s=R(`Clickable`);return H(),U(`div`,Ry,[(H(!0),U(V,null,z(e.categories,t=>(H(),W(s,{key:t.cid,class:`list-group-item list-group-item-action d-flex align-items-start pis-category-link border-0`,onClick:n=>e.$emit(`click-item`,t)},{default:P(()=>[G(`span`,zy,j(t.name),1),G(`span`,By,[K(o,{class:`ms-1`,textContent:j(t.hitCount)},null,8,[`textContent`]),e.configuratorsVisible&&t.configuratorHitCount?(H(),W(o,{key:0,class:`ms-1`,highlighted:``,title:e.configuratorsNumberTitle,textContent:j(t.configuratorHitCount)},null,8,[`title`,`textContent`])):J(``,!0)])]),_:2},1032,[`onClick`]))),128))])}var Hy=Q(Ly,[[`render`,Vy]]),Uy=[`modal-open`,`pis-modal-open`],Wy=L({props:{show:{type:[Boolean,Object],default:void 0},title:{type:String,default:void 0},lg:{type:Boolean,default:!1},xl:{type:Boolean,default:!1},closeOnOuterClick:{type:Boolean,default:!0},centered:{type:Boolean,default:!1}},emits:[`update:show`,`resize`],setup(e,{slots:t,emit:n}){let r=M(),i=M();np(i,e=>{let{width:t,height:r}=e[0].contentRect;n(`resize`,{width:t,height:r})});let a=()=>{e.closeOnOuterClick&&c()},o=()=>{let e=window.innerWidth-document.documentElement.clientWidth;document.body.classList.add(...Uy),document.body.style.overflow=`hidden`,document.body.style.paddingRight=e+`px`},s=()=>{document.body.classList.remove(...Uy),document.body.style.overflow=``,document.body.style.paddingRight=``},c=()=>{n(`update:show`,!1),l.value=!1,s()},l=M(!1);return I(()=>e.show,e=>{e?(o(),l.value=!0):(s(),l.value=!1)},{immediate:!0}),Mr(()=>{s()}),{visible:l,dialog:r,modalBody:i,slots:t,close:c,clickOutside:({target:t})=>{if(e.closeOnOuterClick){var n;t!==r.value&&!((n=r.value)!=null&&n.contains(t))&&c()}},overlayClose:a}}}),Gy={class:`modal-content`},Ky={class:`modal-header d-flex`},qy={class:`modal-title mt-1`},Jy={class:`d-flex flex-fill align-items-center justify-content-end`},Yy={ref:`modalBody`,class:`modal-body pis-scroll`},Xy={key:0,class:`modal-footer py-2`};function Zy(e,t,n,r,i,a){return H(),U(V,null,[G(`div`,{class:A([`modal fade`,{show:e.visible}]),tabindex:`-1`,role:`dialog`,style:k({display:e.visible?`block`:`none`}),onClick:t[1]||(t[1]=(...t)=>e.clickOutside&&e.clickOutside(...t))},[G(`div`,{ref:`dialog`,class:A([`modal-dialog modal-fullscreen-md-down`,[e.lg&&`modal-lg modal-fullscreen-md-down modal-fullscreen-sm-down modal-fullscreen-lg-down `,e.xl&&`modal-xl modal-fullscreen-lg-down modal-fullscreen-md-down modal-fullscreen-sm-down`,e.centered&&`modal-dialog-centered`]]),role:`document`},[G(`div`,Gy,[G(`div`,Ky,[G(`h5`,qy,j(e.title),1),G(`div`,Jy,[B(e.$slots,`header-actions`),G(`button`,{type:`button`,class:`btn-close ms-3`,"aria-label":`Close`,onClick:t[0]||(t[0]=X((...t)=>e.close&&e.close(...t),[`prevent`]))})])]),G(`div`,Yy,[B(e.$slots,`default`)],512),e.slots.footer?(H(),U(`div`,Xy,[B(e.$slots,`footer`)])):J(``,!0)])],2)],6),e.visible?(H(),U(`div`,{key:0,class:`modal-backdrop fade show`,onClick:t[2]||(t[2]=(...t)=>e.overlayClose&&e.overlayClose(...t))})):J(``,!0)],64)}var Qy=Q(Wy,[[`render`,Zy]]),$y=L({name:`pis-catalogs-aliases-search-mobile-nav`,components:{Btn:Iy,Modal:Qy,AliasFilters:Ty,CategoriesList:Hy},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=M(!1),i=M(!1),{componentName:a,isWebComponent:o,isReady:s,instance:c,store:l,t:u}=ym(t,e.instanceId,[Ud.Breadcrumbs]),d=Y(()=>{var e,t;return((e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-search-product-categories`))&&((t=l.value)==null||(t=t.options.components)==null||(t=t.products)==null||(t=t.search)==null||(t=t.productCategories)==null?void 0:t.visible)}),f=Y(()=>{var e,t;return((e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-search-part-categories`))&&((t=l.value)==null||(t=t.options.components)==null||(t=t.products)==null||(t=t.search)==null||(t=t.partCategories)==null?void 0:t.visible)});return{root:t,componentName:a,isWebComponent:o,categoriesShown:d,partCategoriesShown:f,categories:Y(()=>{var e;return((e=l.value)==null||(e=e.data.productClassifications)==null?void 0:e.items)??[]}),partCategories:Y(()=>{var e;return((e=l.value)==null||(e=e.data.partClassifications)==null?void 0:e.items)??[]}),isReady:s,store:l,columnsNumber:Y(()=>{let e=[d.value,f.value,!0].filter(Boolean).length;return e>3?3:e}),instance:c,aliasFiltersModalOpen:n,categoriesModalOpen:r,partCategoriesModalOpen:i,t:u,setCategory:async({cid:e})=>{if(c.value&&e){r.value=!1;try{await c.value.execute(new Au({cid:e,clearSearch:!1,treeType:`Products`}).from(a))}catch{}}},setPartCategory:async({cid:e})=>{if(c.value&&e){i.value=!1;try{await c.value.execute(new Au({cid:e,clearSearch:!1,treeType:`Parts`}).from(a))}catch{}}}}}}),eb={class:`mb-4 row g-2`};function tb(e,t,n,r,i,a){let o=R(`Btn`),s=R(`AliasFilters`),c=R(`Modal`),l=R(`CategoriesList`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(V,{key:0},[G(`nav`,eb,[G(`div`,{class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`funnel-filter`,class:`w-100 h-100`,vertical:``,onClick:t[0]||(t[0]=X(t=>e.aliasFiltersModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`AliasFilters`)),1)]),_:1})],2),e.categoriesShown?(H(),U(`div`,{key:0,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`folder-open`,class:`w-100 h-100`,vertical:``,disabled:!e.categories.length,number:e.categories.length,onClick:t[1]||(t[1]=X(t=>e.categoriesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`Products`)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0),e.partCategoriesShown?(H(),U(`div`,{key:1,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`folder-open`,class:`w-100 h-100`,vertical:``,disabled:!e.partCategories.length,number:e.partCategories.length,onClick:t[2]||(t[2]=X(t=>e.partCategoriesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`PartsAndServices`)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0)]),K(c,{show:e.aliasFiltersModalOpen,"onUpdate:show":t[3]||(t[3]=t=>e.aliasFiltersModalOpen=t),title:e.t(`AliasFilters`)},{default:P(()=>[K(s)]),_:1},8,[`show`,`title`]),K(c,{show:e.categoriesModalOpen,"onUpdate:show":t[4]||(t[4]=t=>e.categoriesModalOpen=t),title:e.t(`AllOfferings`)},{default:P(()=>[K(l,{categories:e.categories,"configurators-visible":!1,onClickItem:e.setCategory},null,8,[`categories`,`onClickItem`])]),_:1},8,[`show`,`title`]),K(c,{show:e.partCategoriesModalOpen,"onUpdate:show":t[5]||(t[5]=t=>e.partCategoriesModalOpen=t),title:e.t(`PartsAndServices`)},{default:P(()=>[K(l,{categories:e.partCategories,"configurators-visible":!1,onClickItem:e.setPartCategory},null,8,[`categories`,`onClickItem`])]),_:1},8,[`show`,`title`])],64)):J(``,!0)],2)}var nb=Q($y,[[`render`,tb]]),rb=e(((e,t)=>{t.exports=(function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={exports:{},id:r,loaded:!1};return e[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}return n.m=e,n.c=t,n.p=``,n(0)})([(function(e,t,n){e.exports=n(1)}),(function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(2);Object.defineProperty(t,"combineChunks",{enumerable:!0,get:function(){return r.combineChunks}}),Object.defineProperty(t,"fillInChunks",{enumerable:!0,get:function(){return r.fillInChunks}}),Object.defineProperty(t,"findAll",{enumerable:!0,get:function(){return r.findAll}}),Object.defineProperty(t,"findChunks",{enumerable:!0,get:function(){return r.findChunks}})}),(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.findAll=function(e){var t=e.autoEscape,a=e.caseSensitive,o=a!==void 0&&a,s=e.findChunks,c=s===void 0?r:s,l=e.sanitize,u=e.searchWords,d=e.textToHighlight;return i({chunksToHighlight:n({chunks:c({autoEscape:t,caseSensitive:o,sanitize:l,searchWords:u,textToHighlight:d})}),totalLength:d?d.length:0})};var n=t.combineChunks=function(e){var t=e.chunks;return t=t.sort(function(e,t){return e.start-t.start}).reduce(function(e,t){if(e.length===0)return[t];var n=e.pop();if(t.start<n.end){var r=Math.max(n.end,t.end);e.push({highlight:!1,start:n.start,end:r})}else e.push(n,t);return e},[]),t},r=function(e){var t=e.autoEscape,n=e.caseSensitive,r=e.sanitize,i=r===void 0?a:r,s=e.searchWords,c=e.textToHighlight;return c=i(c),s.filter(function(e){return e}).reduce(function(e,r){r=i(r),t&&(r=o(r));for(var a=new RegExp(r,n?`g`:`gi`),s=void 0;s=a.exec(c);){var l=s.index,u=a.lastIndex;u>l&&e.push({highlight:!1,start:l,end:u}),s.index===a.lastIndex&&a.lastIndex++}return e},[])};t.findChunks=r;var i=t.fillInChunks=function(e){var t=e.chunksToHighlight,n=e.totalLength,r=[],i=function(e,t,n){t-e>0&&r.push({start:e,end:t,highlight:n})};if(t.length===0)i(0,n,!1);else{var a=0;t.forEach(function(e){i(a,e.start,!1),i(e.start,e.end,!0),a=e.end}),i(a,n,!1)}return r};function a(e){return e}function o(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,`\\$&`)}})])}))(),ib=(e,t)=>{let n=ob(e,(0,rb.findAll)({autoEscape:e.autoEscape,caseSensitive:e.caseSensitive,findChunks:e.findChunks,sanitize:e.sanitize,searchWords:e.searchWords,textToHighlight:e.textToHighlight})),r=t.slots;return r.default?r.default&&r.default(n):Qa(`span`,{...t.attrs},n.map(({chunk:e,text:t,attrs:n})=>e.highlight?Qa(`mark`,n,[t]):t))},ab={};function ob(e,t){let n=-1,r=``,i={},{textToHighlight:a,highlightClassName:o,highlightStyle:s=ab,activeIndex:c,activeClassName:l,activeStyle:u=ab}=e;return t.map((e,t)=>{let d=a.substr(e.start,e.end-e.start);if(e.highlight){n++;let a=n===+(c||-1);return r=`${o} ${a?l:``}`,i=a===!0&&u!=null?{...s,...u}:s,{chunk:e,text:d,attrs:{class:r,key:t,style:i,highlightIndex:n}}}return{chunk:e,text:d}})}ib.props={activeClassName:String,activeIndex:Number,activeStyle:Object,autoEscape:Boolean,caseSensitive:{type:Boolean,defualt:!1},findChunks:Function,custom:{type:Boolean,default:!1},highlightClassName:String,highlightStyle:Object,sanitize:Function,searchWords:{type:Array,validator(e){return e.every(e=>typeof e==`string`)},required:!0},textToHighlight:{type:String,required:!0}};var sb=ib,cb={top:`100%`,right:`auto`,bottom:`auto`,left:0},lb=L({props:{open:Boolean,items:{type:Array,default:void 0},width:{type:String,default:void 0},minWidth:{type:String,default:void 0},maxHeight:{type:String,default:`400px`}},emits:[`update:open`],setup(e,{emit:t}){let n=({top:e,right:t,bottom:n,left:r})=>[e,t,n,r].join(` `),r=M(),i=M(),a=M([]),o=M(0),s=M(n(cb)),c=()=>t(`update:open`,!1),l=Y(()=>(e.items??[]).filter(e=>(e==null?void 0:e.location)===`top`)),u=Y(()=>(e.items??[]).filter(e=>(e==null?void 0:e.location)!==`top`)),d=e=>{var t;(t=a.value[e])==null||t.focus()},f={keyup(t){e.open&&([`ArrowDown`,`ArrowUp`].includes(t.key)?(t.stopPropagation(),d(o.value)):t.key===`Escape`&&c())},focus(){o.value=0}},p=e=>{let t=ly(e)[0].querySelector(`button, a`);t&&(t.click(),c())},m=e=>{e.preventDefault(),o.value<a.value.length-1&&(o.value++,d(o.value))},h=e=>{e.preventDefault(),o.value>0&&(o.value--,d(o.value))},g=cp(()=>{jn(()=>{if(r.value&&i.value){let{bottom:e,right:t,width:a}=r.value.getBoundingClientRect(),{height:o,width:c}=i.value.getBoundingClientRect(),l={...cb};e+o>=document.documentElement.clientHeight&&(l.bottom=`100%`,l.top=`auto`),t+c-a>=document.documentElement.clientWidth&&(l.right=0,l.left=`auto`),s.value=n(l)}})},200);return I(()=>e.open,e=>{e?(g(),document.addEventListener(`scroll`,g)):document.removeEventListener(`scroll`,g)}),Ar(()=>{a.value=[]}),$f(r,c),{wrapperEl:r,menuEl:i,itemElements:a,topItems:l,bottomItems:u,eventHandlers:f,inset:s,close:c,onItemEnter:p,onItemArrowDown:m,onItemArrowUp:h}}}),ub={ref:`wrapperEl`,class:`dropdown`},db={key:0,class:`dropdown-item-text text-muted text-sm`};function fb(e,t,n,r,i,a){return H(),U(`div`,ub,[B(e.$slots,`activator`,{on:e.eventHandlers}),G(`ul`,{ref:`menuEl`,class:A([`dropdown-menu mt-1 overflow pis-scroll`,[e.open&&`show`]]),style:k([{"overflow-y":`auto`,"max-width":`94vw`},{width:e.width??`auto`,"max-height":e.maxHeight,"min-width":e.minWidth??`auto`,inset:e.inset}])},[B(e.$slots,`item-top-title`),(H(!0),U(V,null,z(e.topItems,(n,r)=>(H(),U(`li`,{key:`top-${r}`,ref_for:!0,ref:t=>e.itemElements[r]=t,tabindex:`0`,onKeyup:t[0]||(t[0]=Ns((...t)=>e.onItemEnter&&e.onItemEnter(...t),[`enter`])),onKeydown:[t[1]||(t[1]=Ns((...t)=>e.onItemArrowUp&&e.onItemArrowUp(...t),[`arrow-up`])),t[2]||(t[2]=Ns((...t)=>e.onItemArrowDown&&e.onItemArrowDown(...t),[`arrow-down`])),t[3]||(t[3]=Ns((...t)=>e.close&&e.close(...t),[`escape`]))]},[B(e.$slots,`item-top`,{item:n})],32))),128)),B(e.$slots,`item-title`),(H(!0),U(V,null,z(e.bottomItems,(n,r)=>(H(),U(`li`,{key:r,ref_for:!0,ref:t=>e.itemElements[r+e.topItems.length]=t,tabindex:`0`,onKeyup:t[4]||(t[4]=Ns((...t)=>e.onItemEnter&&e.onItemEnter(...t),[`enter`])),onKeydown:[t[5]||(t[5]=Ns((...t)=>e.onItemArrowUp&&e.onItemArrowUp(...t),[`arrow-up`])),t[6]||(t[6]=Ns((...t)=>e.onItemArrowDown&&e.onItemArrowDown(...t),[`arrow-down`])),t[7]||(t[7]=Ns((...t)=>e.close&&e.close(...t),[`escape`]))]},[B(e.$slots,`item`,{item:n},()=>[q(j(n),1)])],32))),128)),e.$slots.footer?(H(),U(`li`,db,[B(e.$slots,`footer`)])):J(``,!0)],6)],512)}var pb=Q(lb,[[`render`,fb]]),mb={required:`required`,email:`email`,commaSeparatedEmails:`csemails`,minLength:`minLength`,min:`min`,max:`max`},hb=e=>typeof e==`string`,gb=e=>{let t=parseInt(`${e}`,10);return isNaN(t)||t.toString().length!==`${e}`.length?null:t},_b=e=>e?null:{},vb=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,yb=e=>vb.test(`${e}`)?null:{},bb={required:_b,email:yb,csemails:e=>{let t=`${e}`.split(`,`).map(e=>e.trim());return t.length&&t.every(e=>yb(e,{})===null)?null:{}},minLength:(e,t)=>hb(e)&&e.length>=t.minLength?null:{},min:(e,t)=>{let n=gb(e);return n===null||n<t.min?{}:null},max:(e,t)=>{let n=gb(e);return n===null||n>t.max?{}:null}},xb=(e,t)=>Object.entries(t).reduce((t,[n,r])=>{let i=bb[n];if(!i)throw Error(`Invalid validator name ${n}!`);let a=i(e,r);return a&&(t[n]=a),t},{}),Sb=L({props:{modelValue:{type:String,default:void 0},placeholder:{type:String,default:void 0},classInner:{type:String,default:void 0},lg:Boolean,clearable:{type:Boolean,default:!0},validators:{type:Object,default:null},type:{type:String,required:!1,default:`text`}},emits:[`update:modelValue`,`update:validation`,`change`,`clear`],setup(e,{emit:t}){let n=M(``),r=M(!1),i=M(!0),a=M({}),o=Y({get:()=>n.value,set:e=>{let i=`${e}`;n.value=i,r.value=!0,t(`update:modelValue`,i)}}),s=e=>{setTimeout(()=>{n.value=e},10)},c=()=>{s(``),t(`clear`),t(`update:modelValue`,``)},l=()=>s(e.modelValue);return I(()=>e.modelValue,()=>l()),I(()=>n.value,n=>{let o={};r.value&&e.validators&&Object.assign(o,xb(n,e.validators)),a.value=o,i.value=!Object.keys(o).length,t(`update:validation`,a.value)}),kr(()=>l()),{isValid:i,innerValue:n,computedValue:o,validationErrors:a,clear:c}}}),Cb=[`type`,`placeholder`],wb={key:1,class:`invalid-feedback d-block`},Tb={key:0},Eb={key:1},Db={key:2},Ob={key:3},kb={key:4},Ab={key:5};function jb(e,t,n,r,i,a){var o;return H(),U(`div`,{class:A([`position-relative flex-grow-1 has-validation pis-form-input-clearable`,[`pis-form-input-clearable-${e.type}`]])},[F(G(`input`,Oa({"onUpdate:modelValue":t[0]||(t[0]=t=>e.computedValue=t)},e.$attrs,{type:e.type,class:[`form-control`,[e.lg&&`form-control-lg`,e.classInner,e.isValid||`is-invalid`]],placeholder:e.placeholder}),null,16,Cb),[[Ds,e.computedValue]]),(o=e.innerValue)!=null&&o.length?(H(),U(`div`,{key:0,class:A([`clearing-container position-absolute top-50 end-0 translate-middle-y`,[e.isValid||`is-invalid`,e.type===`number`?e.isValid?`me-4`:`me-5`:`me-1`]]),style:k([e.type===`number`&&!e.isValid?`padding-bottom:1.4em`:``])},[e.clearable?(H(),U(`button`,{key:0,type:`button`,class:`btn-close`,style:{"background-size":`0.7em`},onClick:t[1]||(t[1]=X((...t)=>e.clear&&e.clear(...t),[`prevent`]))})):J(``,!0)],6)):J(``,!0),e.isValid?J(``,!0):(H(),U(`div`,wb,[e.validationErrors.required?(H(),U(`p`,Tb,j(`Field is required`))):e.validationErrors.email?(H(),U(`p`,Eb,j(`Field must be an email`))):e.validationErrors.csemails?(H(),U(`p`,Db,j(`Field must be a comma separated emails`))):e.validationErrors.minLength?(H(),U(`p`,Ob,j(`Field must be at least ${e.validators.minLength.minLength} characters long`),1)):e.validationErrors.min?(H(),U(`p`,kb,j(`Field value must not be lower than ${e.validators.min.min}`),1)):e.validationErrors.max?(H(),U(`p`,Ab,j(`Field value must not be greater than ${e.validators.max.max}`),1)):J(``,!0)]))],2)}var Mb=Q(Sb,[[`render`,jb]]),Nb={value:Hl.CATALOG_CODE_AND_DESCRIPTION,translate:`SearchByCodeAndDescription`},Pb={value:Hl.CREATED_BY,translate:`SearchByCreatedBy`},Fb=L({name:`pis-catalogs-search-form`,components:{Btn:Iy,Dropdown:pb,FormInputClearable:Mb,Clickable:wm,Spinner:My,Highlighter:sb,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=Ut({text:``,type:Hl.CATALOG_CODE_AND_DESCRIPTION,isDirty:!1}),r=M({totalCount:0,itemsCount:0,items:[]}),i=M(!1),a=M(!1),{componentName:o,isReady:s,isWebComponent:c,instance:l,store:u,routeData:d,widerThan:f,narrowerThan:p,t:m,emit:h}=ym(t,e.instanceId),g=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.form}),_=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.form)==null?void 0:e.visible}),v=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.form)==null?void 0:e.useAutocomplete}),y=[Nb,Pb],b=Y(()=>y),x=async()=>{i.value=!1;try{var e;await((e=l.value)==null?void 0:e.execute(new vu({searchText:n.text,searchType:n.type}).from(o))),n.isDirty=!1}catch{}},S=e=>{n.text=e,x()},C=()=>{n.isDirty||(n.text=``,r.value.items=[],r.value.totalCount=0,x())},w=()=>{var e;v.value&&n.text!=((e=d.value)==null?void 0:e.catalogs.searchText)&&n.text.length>2&&(i.value=!0)},T=()=>{i.value=!1},E=sp(async e=>{if(!v.value)return;let t=(e||``).trim(),n=t!=null&&t.length>2;if(i.value=n,n){a.value=!0;let t=[];try{var s;let n=await((s=l.value)==null?void 0:s.execute(new Iu({searchText:e}).from(o)));if(n){var c;let e=(n.items||[]).map(e=>({productId:``,attributes:{},text:e.code||``,description:e.description||``,images:void 0,type:`item`,location:`bottom`,sparePart:!1,exactMatch:!1})),i={totalCount:n.totalCount||0,itemsCount:((c=n.items)==null?void 0:c.length)||0,items:[]};i.items=t.concat(e),r.value=i}}catch{}finally{a.value=!1}}},300);return I(()=>{var e;return(e=d.value)==null?void 0:e.products.searchText},(e,t)=>{e!==t&&(n.text=e??``)}),I(()=>{var e;return(e=d.value)==null?void 0:e.catalogs.searchType},(e,t)=>{e&&e!==t&&(n.type=e)}),I(()=>n.type,()=>{d.value&&(d.value.catalogs.searchType=n.type)}),{root:t,componentName:o,isReady:s,isWebComponent:c,store:u,searchModel:n,searchTypeOptions:b,autocomplete:r,isAutocompleteVisible:i,isAutocompleteLoading:a,highlightTerms:Y(()=>{if(!n.text)return[];let e=n.text.trim().toLowerCase().split(/[._-\s/]+/);e.push(n.text.trim());let t=n.text.match(/\d+/g),r=n.text;t&&t.forEach(t=>{e.push(t),r=r.replace(t,`$`)});let i=r.trim().toLowerCase().split(`$`);return e.push(...i),e}),widerThan:f,narrowerThan:p,t:m,onSearch:x,onSearchInput:()=>{var e,t;n.isDirty=((e=n.text)==null?void 0:e.length)>0&&n.text!=((t=d.value)==null?void 0:t.catalogs.searchText),E(n.text)},onClear:C,searchText:S,openAutocomplete:w,closeAutocomplete:T,visible:_,componentOptions:g,instance:l,emit:h,itemCtx:hg(e=>({instance:l.value,item:e.item,emit:h,t:m}))}}}),Ib={key:0,class:`mb-4`},Lb={class:`fw-bold ext-display-name`},Rb={key:0,class:`small ext-description text-wrap`},zb={key:0,class:`text-center`},Bb={key:1},Vb={key:2},Hb=[`value`,`textContent`];function Ub(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Highlighter`),c=R(`Clickable`),l=R(`Spinner`),u=R(`FormInputClearable`),d=R(`Btn`),f=R(`Dropdown`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,Ib,[K(f,{open:e.isAutocompleteVisible,"onUpdate:open":t[3]||(t[3]=t=>e.isAutocompleteVisible=t),"min-width":`340px`,items:e.autocomplete.items},{item:P(({item:t})=>[K(c,{class:`dropdown-item`,onClick:n=>e.searchText(t.text)},{default:P(()=>{var n,r;return[(n=e.componentOptions)!=null&&n.autocompleteItemTemplate?(H(),W(o,{key:0,callbacks:(r=e.componentOptions)==null?void 0:r.autocompleteItemTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[G(`div`,Lb,[K(s,{"highlight-class-name":`text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":t.text},null,8,[`search-words`,`text-to-highlight`])]),t.text==t.description?J(``,!0):(H(),U(`div`,Rb,[K(s,{"highlight-class-name":`fw-bold text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":t.description},null,8,[`search-words`,`text-to-highlight`])]))],64))]}),_:2},1032,[`onClick`])]),footer:P(()=>[e.isAutocompleteLoading?(H(),U(`div`,zb,[K(l,{sm:``})])):e.autocomplete.totalCount?(H(),U(`small`,Bb,j(e.t(`ShowingNOfNMatches`,!1,[`${e.autocomplete.itemsCount||0}`,`${e.autocomplete.totalCount||0}`])),1)):(H(),U(`small`,Vb,j(e.t(`NoResults`)),1))]),activator:P(({on:n})=>[G(`form`,{class:A([e.widerThan(`sm`)&&`input-group flex-nowrap`]),onSubmit:t[2]||(t[2]=X(t=>e.onSearch(),[`prevent`]))},[K(u,Oa({modelValue:e.searchModel.text,"onUpdate:modelValue":t[0]||(t[0]=t=>e.searchModel.text=t),"class-inner":e.widerThan(`sm`)?`border-end-0`:`mb-1`,lg:e.widerThan(`sm`),placeholder:e.t(`SearchCatalogsInputPlaceholder`)},qr(n),{"onUpdate:modelValue":e.onSearchInput,onClear:e.onClear,onFocus:e.openAutocomplete}),null,16,[`modelValue`,`class-inner`,`lg`,`placeholder`,`onUpdate:modelValue`,`onClear`,`onFocus`]),F(G(`select`,{"onUpdate:modelValue":t[1]||(t[1]=t=>e.searchModel.type=t),class:A([`form-select px-2`,[e.narrowerThan(`sm`)&&`mb-1`]]),style:k({"min-width":e.widerThan(`sm`)?`200px`:`100%`,"max-width":e.widerThan(`sm`)?`300px`:`100%`})},[(H(!0),U(V,null,z(e.searchTypeOptions,t=>(H(),U(`option`,{key:t.value,value:t.value,textContent:j(e.t(t.translate))},null,8,Hb))),128))],6),[[Cs,e.searchModel.type]]),K(d,{"aria-label":e.t(`SearchButtonText`),icon:`lens-search-find`,class:A([e.narrowerThan(`sm`)&&`w-100 d-flex justify-content-center`])},{default:P(()=>[G(`span`,null,j(e.t(`SearchButtonText`)),1)]),_:1},8,[`aria-label`,`class`])],34)]),_:1},8,[`open`,`items`])])):J(``,!0)],2)}var Wb=Q(Fb,[[`render`,Ub]]),Gb=L({components:{Icon:$h},props:{dir:{type:String,default:`right`},size:{type:Number,default:16}},setup:e=>({angle:Y(()=>{switch(e.dir){case`down`:return 90;case`left`:return 180;case`up`:return 270;default:return 0}})})});function Kb(e,t,n,r,i,a){let o=R(`Icon`);return H(),W(o,{name:`chevron-right-reduced`,size:e.size,style:k({transform:`rotate(${e.angle}deg)`})},null,8,[`size`,`style`])}var qb=Q(Gb,[[`render`,Kb]]),Jb=L({components:{Arrow:qb,Clickable:wm},props:{total:{type:Number,default:1},current:{type:Number,default:1},trimTo:{type:Number,default:5},narrowThan:{type:Function,default:void 0}},emits:[`change`],setup(e,{emit:t}){let n=Y(()=>{let t=e.trimTo;return e.narrowThan&&(e.narrowThan(`sm`)?t=Math.min(t,1):e.narrowThan(`md`)&&(t=Math.min(t,3))),t}),r=Y(()=>Math.floor(n.value/2)),i=Y(()=>{let{current:t}=e;return t>=n.value?t-r.value:1}),a=Y(()=>{let{total:t,current:i}=e,a=n.value;return t<a||i>t-a?t:i>=a?i+r.value:a});return{threshold:r,start:i,end:a,pagesToDisplay:Y(()=>[...Array(a.value-i.value+1)].map((e,t)=>i.value+t)),goTo:e=>t(`change`,e)}}}),Yb={class:`pagination`},Xb={key:0,class:`page-item`},Zb={class:`page-item`},Qb={class:`page-item`},$b={key:3,class:`page-item`};function ex(e,t,n,r,i,a){let o=R(`Arrow`),s=R(`Clickable`);return H(),U(`ul`,Yb,[e.current>1?(H(),U(`li`,Xb,[K(s,{class:`page-link`,onClick:t[0]||(t[0]=t=>e.goTo(e.current-1))},{default:P(()=>[K(o,{dir:`left`})]),_:1})])):J(``,!0),e.start===1?J(``,!0):(H(),U(V,{key:1},[G(`li`,Zb,[K(s,{class:`page-link`,title:`First`,"aria-label":`First`,onClick:t[1]||(t[1]=t=>e.goTo(1))},{default:P(()=>[...t[4]||(t[4]=[q(`1`,-1)])]),_:1})]),t[5]||(t[5]=G(`li`,{class:`page-item px-3`},`...`,-1))],64)),(H(!0),U(V,null,z(e.pagesToDisplay,t=>(H(),U(`li`,{key:t,class:A([`page-item`,[t===e.current&&`active`]])},[K(s,{class:`page-link`,onClick:n=>e.goTo(t)},{default:P(()=>[q(j(t),1)]),_:2},1032,[`onClick`])],2))),128)),e.current<e.total-e.trimTo+1?(H(),U(V,{key:2},[t[6]||(t[6]=G(`li`,{class:`page-item px-3`},`...`,-1)),G(`li`,Qb,[K(s,{class:`page-link`,title:`Last`,"aria-label":`Last`,onClick:t[2]||(t[2]=t=>e.goTo(e.total))},{default:P(()=>[q(j(e.total),1)]),_:1})])],64)):J(``,!0),e.current<e.total?(H(),U(`li`,$b,[K(s,{class:`page-link`,title:`Next`,"aria-label":`Next`,onClick:t[3]||(t[3]=t=>e.goTo(e.current+1))},{default:P(()=>[K(o)]),_:1})])):J(``,!0)])}var tx=Q(Jb,[[`render`,ex]]),nx=L({name:`pis-catalogs-search-pagination`,components:{Pagination:tx,PaginationAmount:Yv},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isWebComponent:r,isReady:i,instance:a,store:o,routeData:s,t:c,widerThan:l,narrowerThan:u}=ym(t,e.instanceId,[Ud.Catalogs]);return{root:t,componentName:n,isWebComponent:r,isReady:i,store:o,totalCount:Y(()=>{var e;return((e=o.value)==null||(e=e.data.catalogs)==null?void 0:e.totalCount)??0}),pagination:Y(()=>{var e;return(e=s.value)==null?void 0:e.catalogs.pagination}),routeData:s,t:c,widerThan:l,narrowerThan:u,changePage:e=>{a.value&&a.value.execute(new Hu({page:e}).from(n))}}}}),rx={ref:`root`,class:`pis-component`,"aria-label":`Items page navigation`},ix={class:`my-2`};function ax(e,t,n,r,i,a){let o=R(`PaginationAmount`),s=R(`Pagination`);return H(),U(`nav`,rx,[e.isReady?(H(),U(V,{key:0},[e.totalCount&&e.pagination?(H(),U(`div`,{key:0,class:A([`d-flex align-items-center justify-content-between mt-4`,[e.widerThan(`md`)?`flex-row`:`flex-column`]])},[G(`div`,ix,[K(o,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0)},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`])]),K(s,{class:A([`my-2`,e.componentName]),total:Math.ceil(e.totalCount/e.pagination.pageSize),current:e.pagination.page,"narrow-than":e.narrowerThan,onChange:e.changePage},null,8,[`class`,`total`,`current`,`narrow-than`,`onChange`])],2)):J(``,!0)],64)):J(``,!0)],512)}var ox=Q(nx,[[`render`,ax]]),sx=`bottom`,cx=`right`,lx=`left`,ux=`auto`,dx=[`top`,sx,cx,lx],fx=`start`,px=`clippingParents`,mx=`viewport`,hx=`popper`,gx=`reference`,_x=dx.reduce(function(e,t){return e.concat([t+`-`+fx,t+`-end`])},[]),vx=[].concat(dx,[ux]).reduce(function(e,t){return e.concat([t,t+`-`+fx,t+`-end`])},[]),yx=[`beforeRead`,`read`,`afterRead`,`beforeMain`,`main`,`afterMain`,`beforeWrite`,`write`,`afterWrite`];function bx(e){return e?(e.nodeName||``).toLowerCase():null}function xx(e){if(e==null)return window;if(e.toString()!==`[object Window]`){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Sx(e){return e instanceof xx(e).Element||e instanceof Element}function Cx(e){return e instanceof xx(e).HTMLElement||e instanceof HTMLElement}function wx(e){return typeof ShadowRoot>`u`?!1:e instanceof xx(e).ShadowRoot||e instanceof ShadowRoot}function Tx(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},i=t.elements[e];!Cx(i)||!bx(i)||(Object.assign(i.style,n),Object.keys(r).forEach(function(e){var t=r[e];t===!1?i.removeAttribute(e):i.setAttribute(e,t===!0?``:t)}))})}function Ex(e){var t=e.state,n={popper:{position:t.options.strategy,left:`0`,top:`0`,margin:`0`},arrow:{position:`absolute`},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(e){var r=t.elements[e],i=t.attributes[e]||{},a=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce(function(e,t){return e[t]=``,e},{});!Cx(r)||!bx(r)||(Object.assign(r.style,a),Object.keys(i).forEach(function(e){r.removeAttribute(e)}))})}}var Dx={name:`applyStyles`,enabled:!0,phase:`write`,fn:Tx,effect:Ex,requires:[`computeStyles`]};function Ox(e){return e.split(`-`)[0]}var kx=Math.max,Ax=Math.min,jx=Math.round;function Mx(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+`/`+e.version}).join(` `):navigator.userAgent}function Nx(){return!/^((?!chrome|android).)*safari/i.test(Mx())}function Px(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),i=1,a=1;t&&Cx(e)&&(i=e.offsetWidth>0&&jx(r.width)/e.offsetWidth||1,a=e.offsetHeight>0&&jx(r.height)/e.offsetHeight||1);var o=(Sx(e)?xx(e):window).visualViewport,s=!Nx()&&n,c=(r.left+(s&&o?o.offsetLeft:0))/i,l=(r.top+(s&&o?o.offsetTop:0))/a,u=r.width/i,d=r.height/a;return{width:u,height:d,top:l,right:c+u,bottom:l+d,left:c,x:c,y:l}}function Fx(e){var t=Px(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Ix(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&wx(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function Lx(e){return xx(e).getComputedStyle(e)}function Rx(e){return[`table`,`td`,`th`].indexOf(bx(e))>=0}function zx(e){return((Sx(e)?e.ownerDocument:e.document)||window.document).documentElement}function Bx(e){return bx(e)===`html`?e:e.assignedSlot||e.parentNode||(wx(e)?e.host:null)||zx(e)}function Vx(e){return!Cx(e)||Lx(e).position===`fixed`?null:e.offsetParent}function Hx(e){var t=/firefox/i.test(Mx());if(/Trident/i.test(Mx())&&Cx(e)&&Lx(e).position===`fixed`)return null;var n=Bx(e);for(wx(n)&&(n=n.host);Cx(n)&&[`html`,`body`].indexOf(bx(n))<0;){var r=Lx(n);if(r.transform!==`none`||r.perspective!==`none`||r.contain===`paint`||[`transform`,`perspective`].indexOf(r.willChange)!==-1||t&&r.willChange===`filter`||t&&r.filter&&r.filter!==`none`)return n;n=n.parentNode}return null}function Ux(e){for(var t=xx(e),n=Vx(e);n&&Rx(n)&&Lx(n).position===`static`;)n=Vx(n);return n&&(bx(n)===`html`||bx(n)===`body`&&Lx(n).position===`static`)?t:n||Hx(e)||t}function Wx(e){return[`top`,`bottom`].indexOf(e)>=0?`x`:`y`}function Gx(e,t,n){return kx(e,Ax(t,n))}function Kx(e,t,n){var r=Gx(e,t,n);return r>n?n:r}function qx(){return{top:0,right:0,bottom:0,left:0}}function Jx(e){return Object.assign({},qx(),e)}function Yx(e,t){return t.reduce(function(t,n){return t[n]=e,t},{})}var Xx=function(e,t){return e=typeof e==`function`?e(Object.assign({},t.rects,{placement:t.placement})):e,Jx(typeof e==`number`?Yx(e,dx):e)};function Zx(e){var t,n=e.state,r=e.name,i=e.options,a=n.elements.arrow,o=n.modifiersData.popperOffsets,s=Ox(n.placement),c=Wx(s),l=[`left`,`right`].indexOf(s)>=0?`height`:`width`;if(!(!a||!o)){var u=Xx(i.padding,n),d=Fx(a),f=c===`y`?`top`:lx,p=c===`y`?sx:cx,m=n.rects.reference[l]+n.rects.reference[c]-o[c]-n.rects.popper[l],h=o[c]-n.rects.reference[c],g=Ux(a),_=g?c===`y`?g.clientHeight||0:g.clientWidth||0:0,v=m/2-h/2,y=u[f],b=_-d[l]-u[p],x=_/2-d[l]/2+v,S=Gx(y,x,b),C=c;n.modifiersData[r]=(t={},t[C]=S,t.centerOffset=S-x,t)}}function Qx(e){var t=e.state,n=e.options.element,r=n===void 0?`[data-popper-arrow]`:n;r!=null&&(typeof r==`string`&&(r=t.elements.popper.querySelector(r),!r)||Ix(t.elements.popper,r)&&(t.elements.arrow=r))}var $x={name:`arrow`,enabled:!0,phase:`main`,fn:Zx,effect:Qx,requires:[`popperOffsets`],requiresIfExists:[`preventOverflow`]};function eS(e){return e.split(`-`)[1]}var tS={top:`auto`,right:`auto`,bottom:`auto`,left:`auto`};function nS(e,t){var n=e.x,r=e.y,i=t.devicePixelRatio||1;return{x:jx(n*i)/i||0,y:jx(r*i)/i||0}}function rS(e){var t,n=e.popper,r=e.popperRect,i=e.placement,a=e.variation,o=e.offsets,s=e.position,c=e.gpuAcceleration,l=e.adaptive,u=e.roundOffsets,d=e.isFixed,f=o.x,p=f===void 0?0:f,m=o.y,h=m===void 0?0:m,g=typeof u==`function`?u({x:p,y:h}):{x:p,y:h};p=g.x,h=g.y;var _=o.hasOwnProperty(`x`),v=o.hasOwnProperty(`y`),y=lx,b=`top`,x=window;if(l){var S=Ux(n),C=`clientHeight`,w=`clientWidth`;if(S===xx(n)&&(S=zx(n),Lx(S).position!==`static`&&s===`absolute`&&(C=`scrollHeight`,w=`scrollWidth`)),S=S,i===`top`||(i===`left`||i===`right`)&&a===`end`){b=sx;var T=d&&S===x&&x.visualViewport?x.visualViewport.height:S[C];h-=T-r.height,h*=c?1:-1}if(i===`left`||(i===`top`||i===`bottom`)&&a===`end`){y=cx;var E=d&&S===x&&x.visualViewport?x.visualViewport.width:S[w];p-=E-r.width,p*=c?1:-1}}var D=Object.assign({position:s},l&&tS),ee=u===!0?nS({x:p,y:h},xx(n)):{x:p,y:h};if(p=ee.x,h=ee.y,c){var O;return Object.assign({},D,(O={},O[b]=v?`0`:``,O[y]=_?`0`:``,O.transform=(x.devicePixelRatio||1)<=1?`translate(`+p+`px, `+h+`px)`:`translate3d(`+p+`px, `+h+`px, 0)`,O))}return Object.assign({},D,(t={},t[b]=v?h+`px`:``,t[y]=_?p+`px`:``,t.transform=``,t))}function iS(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=r===void 0||r,a=n.adaptive,o=a===void 0||a,s=n.roundOffsets,c=s===void 0||s,l={placement:Ox(t.placement),variation:eS(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy===`fixed`};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,rS(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,rS(Object.assign({},l,{offsets:t.modifiersData.arrow,position:`absolute`,adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var aS={name:`computeStyles`,enabled:!0,phase:`beforeWrite`,fn:iS,data:{}},oS={passive:!0};function sS(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,a=i===void 0||i,o=r.resize,s=o===void 0||o,c=xx(t.elements.popper),l=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&l.forEach(function(e){e.addEventListener(`scroll`,n.update,oS)}),s&&c.addEventListener(`resize`,n.update,oS),function(){a&&l.forEach(function(e){e.removeEventListener(`scroll`,n.update,oS)}),s&&c.removeEventListener(`resize`,n.update,oS)}}var cS={name:`eventListeners`,enabled:!0,phase:`write`,fn:function(){},effect:sS,data:{}},lS={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function uS(e){return e.replace(/left|right|bottom|top/g,function(e){return lS[e]})}var dS={start:`end`,end:`start`};function fS(e){return e.replace(/start|end/g,function(e){return dS[e]})}function pS(e){var t=xx(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function mS(e){return Px(zx(e)).left+pS(e).scrollLeft}function hS(e,t){var n=xx(e),r=zx(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;var l=Nx();(l||!l&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}return{width:a,height:o,x:s+mS(e),y:c}}function gS(e){var t,n=zx(e),r=pS(e),i=(t=e.ownerDocument)==null?void 0:t.body,a=kx(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),o=kx(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-r.scrollLeft+mS(e),c=-r.scrollTop;return Lx(i||n).direction===`rtl`&&(s+=kx(n.clientWidth,i?i.clientWidth:0)-a),{width:a,height:o,x:s,y:c}}function _S(e){var t=Lx(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function vS(e){return[`html`,`body`,`#document`].indexOf(bx(e))>=0?e.ownerDocument.body:Cx(e)&&_S(e)?e:vS(Bx(e))}function yS(e,t){var n;t===void 0&&(t=[]);var r=vS(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),a=xx(r),o=i?[a].concat(a.visualViewport||[],_S(r)?r:[]):r,s=t.concat(o);return i?s:s.concat(yS(Bx(o)))}function bS(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function xS(e,t){var n=Px(e,!1,t===`fixed`);return n.top+=e.clientTop,n.left+=e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function SS(e,t,n){return t===`viewport`?bS(hS(e,n)):Sx(t)?xS(t,n):bS(gS(zx(e)))}function CS(e){var t=yS(Bx(e)),n=[`absolute`,`fixed`].indexOf(Lx(e).position)>=0&&Cx(e)?Ux(e):e;return Sx(n)?t.filter(function(e){return Sx(e)&&Ix(e,n)&&bx(e)!==`body`}):[]}function wS(e,t,n,r){var i=t===`clippingParents`?CS(e):[].concat(t),a=[].concat(i,[n]),o=a[0],s=a.reduce(function(t,n){var i=SS(e,n,r);return t.top=kx(i.top,t.top),t.right=Ax(i.right,t.right),t.bottom=Ax(i.bottom,t.bottom),t.left=kx(i.left,t.left),t},SS(e,o,r));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function TS(e){var t=e.reference,n=e.element,r=e.placement,i=r?Ox(r):null,a=r?eS(r):null,o=t.x+t.width/2-n.width/2,s=t.y+t.height/2-n.height/2,c;switch(i){case`top`:c={x:o,y:t.y-n.height};break;case sx:c={x:o,y:t.y+t.height};break;case cx:c={x:t.x+t.width,y:s};break;case lx:c={x:t.x-n.width,y:s};break;default:c={x:t.x,y:t.y}}var l=i?Wx(i):null;if(l!=null){var u=l===`y`?`height`:`width`;switch(a){case fx:c[l]=c[l]-(t[u]/2-n[u]/2);break;case`end`:c[l]=c[l]+(t[u]/2-n[u]/2)}}return c}function ES(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=r===void 0?e.placement:r,a=n.strategy,o=a===void 0?e.strategy:a,s=n.boundary,c=s===void 0?px:s,l=n.rootBoundary,u=l===void 0?mx:l,d=n.elementContext,f=d===void 0?hx:d,p=n.altBoundary,m=p!==void 0&&p,h=n.padding,g=h===void 0?0:h,_=Jx(typeof g==`number`?Yx(g,dx):g),v=f===`popper`?gx:hx,y=e.rects.popper,b=e.elements[m?v:f],x=wS(Sx(b)?b:b.contextElement||zx(e.elements.popper),c,u,o),S=Px(e.elements.reference),C=TS({reference:S,element:y,strategy:`absolute`,placement:i}),w=bS(Object.assign({},y,C)),T=f===`popper`?w:S,E={top:x.top-T.top+_.top,bottom:T.bottom-x.bottom+_.bottom,left:x.left-T.left+_.left,right:T.right-x.right+_.right},D=e.modifiersData.offset;if(f===`popper`&&D){var ee=D[i];Object.keys(E).forEach(function(e){var t=[`right`,`bottom`].indexOf(e)>=0?1:-1,n=[`top`,`bottom`].indexOf(e)>=0?`y`:`x`;E[e]+=ee[n]*t})}return E}function DS(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=n.boundary,a=n.rootBoundary,o=n.padding,s=n.flipVariations,c=n.allowedAutoPlacements,l=c===void 0?vx:c,u=eS(r),d=u?s?_x:_x.filter(function(e){return eS(e)===u}):dx,f=d.filter(function(e){return l.indexOf(e)>=0});f.length===0&&(f=d);var p=f.reduce(function(t,n){return t[n]=ES(e,{placement:n,boundary:i,rootBoundary:a,padding:o})[Ox(n)],t},{});return Object.keys(p).sort(function(e,t){return p[e]-p[t]})}function OS(e){if(Ox(e)===`auto`)return[];var t=uS(e);return[fS(e),t,fS(t)]}function kS(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,a=i===void 0||i,o=n.altAxis,s=o===void 0||o,c=n.fallbackPlacements,l=n.padding,u=n.boundary,d=n.rootBoundary,f=n.altBoundary,p=n.flipVariations,m=p===void 0||p,h=n.allowedAutoPlacements,g=t.options.placement,_=Ox(g)===g,v=c||(_||!m?[uS(g)]:OS(g)),y=[g].concat(v).reduce(function(e,n){return e.concat(Ox(n)===`auto`?DS(t,{placement:n,boundary:u,rootBoundary:d,padding:l,flipVariations:m,allowedAutoPlacements:h}):n)},[]),b=t.rects.reference,x=t.rects.popper,S=new Map,C=!0,w=y[0],T=0;T<y.length;T++){var E=y[T],D=Ox(E),ee=eS(E)===fx,O=[`top`,sx].indexOf(D)>=0,te=O?`width`:`height`,ne=ES(t,{placement:E,boundary:u,rootBoundary:d,altBoundary:f,padding:l}),re=O?ee?cx:lx:ee?sx:`top`;b[te]>x[te]&&(re=uS(re));var ie=uS(re),ae=[];if(a&&ae.push(ne[D]<=0),s&&ae.push(ne[re]<=0,ne[ie]<=0),ae.every(function(e){return e})){w=E,C=!1;break}S.set(E,ae)}if(C)for(var oe=m?3:1,se=function(e){var t=y.find(function(t){var n=S.get(t);if(n)return n.slice(0,e).every(function(e){return e})});if(t)return w=t,`break`},ce=oe;ce>0&&se(ce)!==`break`;ce--);t.placement!==w&&(t.modifiersData[r]._skip=!0,t.placement=w,t.reset=!0)}}var AS={name:`flip`,enabled:!0,phase:`main`,fn:kS,requiresIfExists:[`offset`],data:{_skip:!1}};function jS(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function MS(e){return[`top`,cx,sx,lx].some(function(t){return e[t]>=0})}function NS(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,a=t.modifiersData.preventOverflow,o=ES(t,{elementContext:`reference`}),s=ES(t,{altBoundary:!0}),c=jS(o,r),l=jS(s,i,a),u=MS(c),d=MS(l);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:l,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}var PS={name:`hide`,enabled:!0,phase:`main`,requiresIfExists:[`preventOverflow`],fn:NS};function FS(e,t,n){var r=Ox(e),i=[`left`,`top`].indexOf(r)>=0?-1:1,a=typeof n==`function`?n(Object.assign({},t,{placement:e})):n,o=a[0],s=a[1];return o=o||0,s=(s||0)*i,[`left`,`right`].indexOf(r)>=0?{x:s,y:o}:{x:o,y:s}}function IS(e){var t=e.state,n=e.options,r=e.name,i=n.offset,a=i===void 0?[0,0]:i,o=vx.reduce(function(e,n){return e[n]=FS(n,t.rects,a),e},{}),s=o[t.placement],c=s.x,l=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=l),t.modifiersData[r]=o}var LS={name:`offset`,enabled:!0,phase:`main`,requires:[`popperOffsets`],fn:IS};function RS(e){var t=e.state,n=e.name;t.modifiersData[n]=TS({reference:t.rects.reference,element:t.rects.popper,strategy:`absolute`,placement:t.placement})}var zS={name:`popperOffsets`,enabled:!0,phase:`read`,fn:RS,data:{}};function BS(e){return e===`x`?`y`:`x`}function VS(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,a=i===void 0||i,o=n.altAxis,s=o!==void 0&&o,c=n.boundary,l=n.rootBoundary,u=n.altBoundary,d=n.padding,f=n.tether,p=f===void 0||f,m=n.tetherOffset,h=m===void 0?0:m,g=ES(t,{boundary:c,rootBoundary:l,padding:d,altBoundary:u}),_=Ox(t.placement),v=eS(t.placement),y=!v,b=Wx(_),x=BS(b),S=t.modifiersData.popperOffsets,C=t.rects.reference,w=t.rects.popper,T=typeof h==`function`?h(Object.assign({},t.rects,{placement:t.placement})):h,E=typeof T==`number`?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,ee={x:0,y:0};if(S){if(a){var O=b===`y`?`top`:lx,te=b===`y`?sx:cx,ne=b===`y`?`height`:`width`,re=S[b],ie=re+g[O],ae=re-g[te],oe=p?-w[ne]/2:0,se=v===`start`?C[ne]:w[ne],ce=v===`start`?-w[ne]:-C[ne],le=t.elements.arrow,ue=p&&le?Fx(le):{width:0,height:0},de=t.modifiersData[`arrow#persistent`]?t.modifiersData[`arrow#persistent`].padding:qx(),k=de[O],fe=de[te],pe=Gx(0,C[ne],ue[ne]),me=y?C[ne]/2-oe-pe-k-E.mainAxis:se-pe-k-E.mainAxis,he=y?-C[ne]/2+oe+pe+fe+E.mainAxis:ce+pe+fe+E.mainAxis,A=t.elements.arrow&&Ux(t.elements.arrow),ge=A?b===`y`?A.clientTop||0:A.clientLeft||0:0,_e=(D==null?void 0:D[b])??0,ve=re+me-_e-ge,ye=re+he-_e,be=Gx(p?Ax(ie,ve):ie,re,p?kx(ae,ye):ae);S[b]=be,ee[b]=be-re}if(s){var xe=b===`x`?`top`:lx,Se=b===`x`?sx:cx,Ce=S[x],j=x===`y`?`height`:`width`,we=Ce+g[xe],Te=Ce-g[Se],Ee=[`top`,lx].indexOf(_)!==-1,De=(D==null?void 0:D[x])??0,Oe=Ee?we:Ce-C[j]-w[j]-De+E.altAxis,ke=Ee?Ce+C[j]+w[j]-De-E.altAxis:Te,Ae=p&&Ee?Kx(Oe,Ce,ke):Gx(p?Oe:we,Ce,p?ke:Te);S[x]=Ae,ee[x]=Ae-Ce}t.modifiersData[r]=ee}}var HS={name:`preventOverflow`,enabled:!0,phase:`main`,fn:VS,requiresIfExists:[`offset`]};function US(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function WS(e){return e===xx(e)||!Cx(e)?pS(e):US(e)}function GS(e){var t=e.getBoundingClientRect(),n=jx(t.width)/e.offsetWidth||1,r=jx(t.height)/e.offsetHeight||1;return n!==1||r!==1}function KS(e,t,n){n===void 0&&(n=!1);var r=Cx(t),i=Cx(t)&&GS(t),a=zx(t),o=Px(e,i,n),s={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((bx(t)!==`body`||_S(a))&&(s=WS(t)),Cx(t)?(c=Px(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):a&&(c.x=mS(a))),{x:o.left+s.scrollLeft-c.x,y:o.top+s.scrollTop-c.y,width:o.width,height:o.height}}function qS(e){var t=new Map,n=new Set,r=[];e.forEach(function(e){t.set(e.name,e)});function i(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!n.has(e)){var r=t.get(e);r&&i(r)}}),r.push(e)}return e.forEach(function(e){n.has(e.name)||i(e)}),r}function JS(e){var t=qS(e);return yx.reduce(function(e,n){return e.concat(t.filter(function(e){return e.phase===n}))},[])}function YS(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function XS(e){var t=e.reduce(function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e},{});return Object.keys(t).map(function(e){return t[e]})}var ZS={placement:`bottom`,modifiers:[],strategy:`absolute`};function QS(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(e){return!(e&&typeof e.getBoundingClientRect==`function`)})}function $S(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,i=t.defaultOptions,a=i===void 0?ZS:i;return function(e,t,n){n===void 0&&(n=a);var i={placement:`bottom`,orderedModifiers:[],options:Object.assign({},ZS,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},o=[],s=!1,c={state:i,setOptions:function(n){var o=typeof n==`function`?n(i.options):n;u(),i.options=Object.assign({},a,i.options,o),i.scrollParents={reference:Sx(e)?yS(e):e.contextElement?yS(e.contextElement):[],popper:yS(t)};var s=JS(XS([].concat(r,i.options.modifiers)));return i.orderedModifiers=s.filter(function(e){return e.enabled}),l(),c.update()},forceUpdate:function(){if(!s){var e=i.elements,t=e.reference,n=e.popper;if(QS(t,n)){i.rects={reference:KS(t,Ux(n),i.options.strategy===`fixed`),popper:Fx(n)},i.reset=!1,i.placement=i.options.placement,i.orderedModifiers.forEach(function(e){return i.modifiersData[e.name]=Object.assign({},e.data)});for(var r=0;r<i.orderedModifiers.length;r++){if(i.reset===!0){i.reset=!1,r=-1;continue}var a=i.orderedModifiers[r],o=a.fn,l=a.options,u=l===void 0?{}:l,d=a.name;typeof o==`function`&&(i=o({state:i,options:u,name:d,instance:c})||i)}}}},update:YS(function(){return new Promise(function(e){c.forceUpdate(),e(i)})}),destroy:function(){u(),s=!0}};if(!QS(e,t))return c;c.setOptions(n).then(function(e){!s&&n.onFirstUpdate&&n.onFirstUpdate(e)});function l(){i.orderedModifiers.forEach(function(e){var t=e.name,n=e.options,r=n===void 0?{}:n,a=e.effect;if(typeof a==`function`){var s=a({state:i,name:t,instance:c,options:r});o.push(s||function(){})}})}function u(){o.forEach(function(e){return e()}),o=[]}return c}}var eC=$S({defaultModifiers:[cS,zS,aS,Dx,LS,AS,HS,$x,PS]});function tC(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function nC(e){if(Array.isArray(e))return e}function rC(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t!==0)for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function iC(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
94
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function aC(e,t){return nC(e)||rC(e,t)||oC(e,t)||iC()}function oC(e,t){if(e){if(typeof e==`string`)return tC(e,t);var n={}.toString.call(e).slice(8,-1);return n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`?Array.from(e):n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?tC(e,t):void 0}}var sC=Object.entries,cC=Object.setPrototypeOf,lC=Object.isFrozen,uC=Object.getPrototypeOf,dC=Object.getOwnPropertyDescriptor,fC=Object.freeze,pC=Object.seal,mC=Object.create,hC=typeof Reflect<`u`&&Reflect,gC=hC.apply,_C=hC.construct;fC||(fC=function(e){return e}),pC||(pC=function(e){return e}),gC||(gC=function(e,t){for(var n=arguments.length,r=Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return e.apply(t,r)}),_C||(_C=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new e(...n)});var vC=RC(Array.prototype.forEach),yC=RC(Array.prototype.lastIndexOf),bC=RC(Array.prototype.pop),xC=RC(Array.prototype.push),SC=RC(Array.prototype.splice),CC=Array.isArray,wC=RC(String.prototype.toLowerCase),TC=RC(String.prototype.toString),EC=RC(String.prototype.match),DC=RC(String.prototype.replace),OC=RC(String.prototype.indexOf),kC=RC(String.prototype.trim),AC=RC(Number.prototype.toString),jC=RC(Boolean.prototype.toString),MC=typeof BigInt>`u`?null:RC(BigInt.prototype.toString),NC=typeof Symbol>`u`?null:RC(Symbol.prototype.toString),PC=RC(Object.prototype.hasOwnProperty),FC=RC(Object.prototype.toString),IC=RC(RegExp.prototype.test),LC=zC(TypeError);function RC(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return gC(e,t,r)}}function zC(e){return function(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];return _C(e,n)}}function BC(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:wC;if(cC&&cC(e,null),!CC(t))return e;let r=t.length;for(;r--;){let i=t[r];if(typeof i==`string`){let e=n(i);e!==i&&(lC(t)||(t[r]=e),i=e)}e[i]=!0}return e}function VC(e){for(let t=0;t<e.length;t++)PC(e,t)||(e[t]=null);return e}function HC(e){let t=mC(null);for(let r of sC(e)){var n=aC(r,2);let i=n[0],a=n[1];PC(e,i)&&(t[i]=CC(a)?VC(a):a&&typeof a==`object`&&a.constructor===Object?HC(a):a)}return t}function UC(e){switch(typeof e){case`string`:return e;case`number`:return AC(e);case`boolean`:return jC(e);case`bigint`:return MC?MC(e):`0`;case`symbol`:return NC?NC(e):`Symbol()`;case`undefined`:return FC(e);case`function`:case`object`:{if(e===null)return FC(e);let t=e,n=WC(t,`toString`);if(typeof n==`function`){let e=n(t);return typeof e==`string`?e:FC(e)}return FC(e)}default:return FC(e)}}function WC(e,t){for(;e!==null;){let n=dC(e,t);if(n){if(n.get)return RC(n.get);if(typeof n.value==`function`)return RC(n.value)}e=uC(e)}function n(){return null}return n}function GC(e){try{return IC(e,``),!0}catch{return!1}}var KC=fC(`a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr`.split(`.`)),qC=fC(`svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern`.split(`.`)),JC=fC([`feBlend`,`feColorMatrix`,`feComponentTransfer`,`feComposite`,`feConvolveMatrix`,`feDiffuseLighting`,`feDisplacementMap`,`feDistantLight`,`feDropShadow`,`feFlood`,`feFuncA`,`feFuncB`,`feFuncG`,`feFuncR`,`feGaussianBlur`,`feImage`,`feMerge`,`feMergeNode`,`feMorphology`,`feOffset`,`fePointLight`,`feSpecularLighting`,`feSpotLight`,`feTile`,`feTurbulence`]),YC=fC([`animate`,`color-profile`,`cursor`,`discard`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`foreignobject`,`hatch`,`hatchpath`,`mesh`,`meshgradient`,`meshpatch`,`meshrow`,`missing-glyph`,`script`,`set`,`solidcolor`,`unknown`,`use`]),XC=fC(`math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts`.split(`.`)),ZC=fC([`maction`,`maligngroup`,`malignmark`,`mlongdiv`,`mscarries`,`mscarry`,`msgroup`,`mstack`,`msline`,`msrow`,`semantics`,`annotation`,`annotation-xml`,`mprescripts`,`none`]),QC=fC([`#text`]),$C=fC(`accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns`.split(`.`)),ew=fC(`accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dominant-baseline.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-orientation.text-rendering.textlength.type.u1.u2.unicode.values.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan`.split(`.`)),tw=fC(`accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns`.split(`.`)),nw=fC([`xlink:href`,`xml:id`,`xlink:title`,`xml:space`,`xmlns:xlink`]),rw=pC(/{{[\w\W]*|^[\w\W]*}}/g),iw=pC(/<%[\w\W]*|^[\w\W]*%>/g),aw=pC(/\${[\w\W]*/g),ow=pC(/^data-[\-\w.\u00B7-\uFFFF]+$/),sw=pC(/^aria-[\-\w]+$/),cw=pC(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),lw=pC(/^(?:\w+script|data):/i),uw=pC(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),dw=pC(/^html$/i),fw=pC(/^[a-z][.\w]*(-[.\w]+)+$/i),pw=pC(/<[/\w!]/g),mw=pC(/<[/\w]/g),hw=pC(/<\/no(script|embed|frames)/i),gw=pC(/\/>/i),_w={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},vw=function(){return typeof window>`u`?null:window},yw=function(e,t){if(typeof e!=`object`||typeof e.createPolicy!=`function`)return null;let n=null,r=`data-tt-policy-suffix`;t&&t.hasAttribute(r)&&(n=t.getAttribute(r));let i=`dompurify`+(n?`#`+n:``);try{return e.createPolicy(i,{createHTML(e){return e},createScriptURL(e){return e}})}catch{return console.warn(`TrustedTypes policy `+i+` could not be created.`),null}},bw=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},xw=function(e,t,n,r){return PC(e,t)&&CC(e[t])?BC(r.base?HC(r.base):{},e[t],r.transform):n};function Sw(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:vw(),t=e=>Sw(e);if(t.version=`3.4.13`,t.removed=[],!e||!e.document||e.document.nodeType!==_w.document||!e.Element)return t.isSupported=!1,t;let n=e.document,r=n,i=r.currentScript;e.DocumentFragment;let a=e.HTMLTemplateElement,o=e.Node,s=e.Element,c=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let l=e.DOMParser,u=e.trustedTypes,d=s.prototype,f=WC(d,`cloneNode`),p=WC(d,`remove`),m=WC(d,`nextSibling`),h=WC(d,`childNodes`),g=WC(d,`parentNode`),_=WC(d,`shadowRoot`),v=WC(d,`attributes`),y=o&&o.prototype?WC(o.prototype,`nodeType`):null,b=o&&o.prototype?WC(o.prototype,`nodeName`):null,x=o&&o.prototype?WC(o.prototype,`ownerDocument`):null;if(typeof a==`function`){let e=n.createElement(`template`);e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let S,C=``,w,T=!1,E=0,D=function(){if(E>0)throw LC(`A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.`)},ee=function(e){D(),E++;try{return S.createHTML(e)}finally{E--}},O=function(e){D(),E++;try{return S.createScriptURL(e)}finally{E--}},te=function(){return T||(w=yw(u,i),T=!0),w},ne=n,re=ne.implementation,ie=ne.createNodeIterator,ae=ne.createDocumentFragment,oe=ne.getElementsByTagName,se=r.importNode,ce=bw();t.isSupported=typeof sC==`function`&&typeof g==`function`&&re&&re.createHTMLDocument!==void 0;let le=rw,ue=iw,de=aw,k=ow,fe=sw,pe=lw,me=uw,he=fw,A=cw,ge=null,_e=BC({},[...KC,...qC,...JC,...XC,...QC]),ve=null,ye=BC({},[...$C,...ew,...tw,...nw]),be=Object.seal(mC(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),xe=null,Se=null,Ce=Object.seal(mC(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),j=!0,we=!0,Te=!1,Ee=!0,De=!1,Oe=!0,ke=!1,Ae=!1,je=null,Me=null,Ne=!1,Pe=!1,Fe=!1,Ie=!1,Le=!0,Re=!1,ze=`user-content-`,Be=!0,Ve=!1,He={},Ue=null,We=BC({},`annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp`.split(`.`)),Ge=null,Ke=BC({},[`audio`,`video`,`img`,`source`,`image`,`track`]),qe=null,Je=BC({},[`alt`,`class`,`for`,`id`,`label`,`name`,`pattern`,`placeholder`,`role`,`summary`,`title`,`value`,`style`,`xmlns`]),Ye=`http://www.w3.org/1998/Math/MathML`,Xe=`http://www.w3.org/2000/svg`,Ze=`http://www.w3.org/1999/xhtml`,Qe=Ze,$e=!1,et=null,tt=BC({},[Ye,Xe,Ze],TC),nt=fC([`mi`,`mo`,`mn`,`ms`,`mtext`]),rt=BC({},nt),it=fC([`annotation-xml`]),at=BC({},it),ot=BC({},[`title`,`style`,`font`,`a`,`script`]),st=null,ct=[`application/xhtml+xml`,`text/html`],lt=null,ut=null,dt=n.createElement(`form`),ft=function(e){return e instanceof RegExp||e instanceof Function},pt=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(ut&&ut===e)return;(!e||typeof e!=`object`)&&(e={}),e=HC(e),st=ct.indexOf(e.PARSER_MEDIA_TYPE)===-1?`text/html`:e.PARSER_MEDIA_TYPE,lt=st===`application/xhtml+xml`?TC:wC,ge=xw(e,`ALLOWED_TAGS`,_e,{transform:lt}),ve=xw(e,`ALLOWED_ATTR`,ye,{transform:lt}),et=xw(e,`ALLOWED_NAMESPACES`,tt,{transform:TC}),qe=xw(e,`ADD_URI_SAFE_ATTR`,Je,{transform:lt,base:Je}),Ge=xw(e,`ADD_DATA_URI_TAGS`,Ke,{transform:lt,base:Ke}),Ue=xw(e,`FORBID_CONTENTS`,We,{transform:lt}),xe=xw(e,`FORBID_TAGS`,HC({}),{transform:lt}),Se=xw(e,`FORBID_ATTR`,HC({}),{transform:lt}),He=PC(e,`USE_PROFILES`)?e.USE_PROFILES&&typeof e.USE_PROFILES==`object`?HC(e.USE_PROFILES):e.USE_PROFILES:!1,j=e.ALLOW_ARIA_ATTR!==!1,we=e.ALLOW_DATA_ATTR!==!1,Te=e.ALLOW_UNKNOWN_PROTOCOLS||!1,Ee=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,De=e.SAFE_FOR_TEMPLATES||!1,Oe=e.SAFE_FOR_XML!==!1,ke=e.WHOLE_DOCUMENT||!1,Pe=e.RETURN_DOM||!1,Fe=e.RETURN_DOM_FRAGMENT||!1,Ie=e.RETURN_TRUSTED_TYPE||!1,Ne=e.FORCE_BODY||!1,Le=e.SANITIZE_DOM!==!1,Re=e.SANITIZE_NAMED_PROPS||!1,Be=e.KEEP_CONTENT!==!1,Ve=e.IN_PLACE||!1,A=GC(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:cw,Qe=typeof e.NAMESPACE==`string`?e.NAMESPACE:Ze,rt=PC(e,`MATHML_TEXT_INTEGRATION_POINTS`)&&e.MATHML_TEXT_INTEGRATION_POINTS&&typeof e.MATHML_TEXT_INTEGRATION_POINTS==`object`?HC(e.MATHML_TEXT_INTEGRATION_POINTS):BC({},nt),at=PC(e,`HTML_INTEGRATION_POINTS`)&&e.HTML_INTEGRATION_POINTS&&typeof e.HTML_INTEGRATION_POINTS==`object`?HC(e.HTML_INTEGRATION_POINTS):BC({},it);let t=PC(e,`CUSTOM_ELEMENT_HANDLING`)&&e.CUSTOM_ELEMENT_HANDLING&&typeof e.CUSTOM_ELEMENT_HANDLING==`object`?HC(e.CUSTOM_ELEMENT_HANDLING):mC(null);if(be=mC(null),PC(t,`tagNameCheck`)&&ft(t.tagNameCheck)&&(be.tagNameCheck=t.tagNameCheck),PC(t,`attributeNameCheck`)&&ft(t.attributeNameCheck)&&(be.attributeNameCheck=t.attributeNameCheck),PC(t,`allowCustomizedBuiltInElements`)&&typeof t.allowCustomizedBuiltInElements==`boolean`&&(be.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),pC(be),De&&(we=!1),Fe&&(Pe=!0),He&&(ge=BC({},QC),ve=mC(null),He.html===!0&&(BC(ge,KC),BC(ve,$C)),He.svg===!0&&(BC(ge,qC),BC(ve,ew),BC(ve,nw)),He.svgFilters===!0&&(BC(ge,JC),BC(ve,ew),BC(ve,nw)),He.mathMl===!0&&(BC(ge,XC),BC(ve,tw),BC(ve,nw))),Ce.tagCheck=null,Ce.attributeCheck=null,PC(e,`ADD_TAGS`)&&(typeof e.ADD_TAGS==`function`?Ce.tagCheck=e.ADD_TAGS:CC(e.ADD_TAGS)&&(ge===_e&&(ge=HC(ge)),BC(ge,e.ADD_TAGS,lt))),PC(e,`ADD_ATTR`)&&(typeof e.ADD_ATTR==`function`?Ce.attributeCheck=e.ADD_ATTR:CC(e.ADD_ATTR)&&(ve===ye&&(ve=HC(ve)),BC(ve,e.ADD_ATTR,lt))),PC(e,`ADD_URI_SAFE_ATTR`)&&CC(e.ADD_URI_SAFE_ATTR)&&BC(qe,e.ADD_URI_SAFE_ATTR,lt),PC(e,`FORBID_CONTENTS`)&&CC(e.FORBID_CONTENTS)&&(Ue===We&&(Ue=HC(Ue)),BC(Ue,e.FORBID_CONTENTS,lt)),PC(e,`ADD_FORBID_CONTENTS`)&&CC(e.ADD_FORBID_CONTENTS)&&(Ue===We&&(Ue=HC(Ue)),BC(Ue,e.ADD_FORBID_CONTENTS,lt)),Be&&(ge[`#text`]=!0),ke&&BC(ge,[`html`,`head`,`body`]),ge.table&&(BC(ge,[`tbody`]),delete xe.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!=`function`)throw LC(`TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.`);if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!=`function`)throw LC(`TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.`);let t=S;S=e.TRUSTED_TYPES_POLICY;try{C=ee(``)}catch(e){throw S=t,e}}else e.TRUSTED_TYPES_POLICY===null?(S=void 0,C=``):(S===void 0&&(S=te()),S&&typeof C==`string`&&(C=ee(``)));fC&&fC(e),ut=e},mt=BC({},[...qC,...JC,...YC]),ht=BC({},[...XC,...ZC]),gt=function(e,t,n){return t.namespaceURI===Ze?e===`svg`:t.namespaceURI===Ye?e===`svg`&&(n===`annotation-xml`||rt[n]):!!mt[e]},_t=function(e,t,n){return t.namespaceURI===Ze?e===`math`:t.namespaceURI===Xe?e===`math`&&at[n]:!!ht[e]},vt=function(e,t,n){return t.namespaceURI===Xe&&!at[n]||t.namespaceURI===Ye&&!rt[n]?!1:!ht[e]&&(ot[e]||!mt[e])},yt=function(e){let t=g(e);(!t||!t.tagName)&&(t={namespaceURI:Qe,tagName:`template`});let n=wC(e.tagName),r=wC(t.tagName);return et[e.namespaceURI]?e.namespaceURI===Xe?gt(n,t,r):e.namespaceURI===Ye?_t(n,t,r):e.namespaceURI===Ze?vt(n,t,r):!!(st===`application/xhtml+xml`&&et[e.namespaceURI]):!1},bt=function(e){xC(t.removed,{element:e});try{g(e).removeChild(e)}catch{if(p(e),!g(e))throw LC(`a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place`)}},xt=function(e){wt(e);let t=h(e);if(t){let e=[];vC(t,t=>{xC(e,t)}),vC(e,e=>{try{p(e)}catch{}})}let n=v(e);if(n)for(let t=n.length-1;t>=0;--t){let r=n[t],i=r&&r.name;if(typeof i==`string`)try{e.removeAttribute(i)}catch{}}},St=function(e,n){try{xC(t.removed,{attribute:n.getAttributeNode(e),from:n})}catch{xC(t.removed,{attribute:null,from:n})}if(n.removeAttribute(e),e===`is`)if(Pe||Fe)try{bt(n)}catch{}else try{n.setAttribute(e,``)}catch{}},Ct=function(e){let t=v(e);if(t)for(let n=t.length-1;n>=0;--n){let r=t[n],i=r&&r.name;if(!(typeof i!=`string`||ve[lt(i)]))try{e.removeAttribute(i)}catch{}}},wt=function(e){let t=[e];for(;t.length>0;){let e=t.pop();(y?y(e):e.nodeType)===_w.element&&Ct(e);let n=h(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},Tt=function(e){if(!Oe)return;let t=[e];for(;t.length>0;){let e=t.pop(),n=y?y(e):e.nodeType;if(n===_w.processingInstruction||n===_w.comment&&IC(mw,e.data)){try{p(e)}catch{}continue}if(n===_w.element){let t=e,n=lt(b?b(e):e.nodeName);try{t.hasAttribute&&t.hasAttribute(`patchsrc`)&&t.removeAttribute(`patchsrc`),t.hasAttribute&&t.hasAttribute(`for`)&&n!==`label`&&n!==`output`&&t.removeAttribute(`for`)}catch{}}let r=h(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}},Et=function(e){let t=null,r=null;if(Ne)e=`<remove></remove>`+e;else{let t=EC(e,/^[\r\n\t ]+/);r=t&&t[0]}st===`application/xhtml+xml`&&Qe===Ze&&(e=`<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>`+e+`</body></html>`);let i=S?ee(e):e;if(Qe===Ze)try{t=new l().parseFromString(i,st)}catch{}if(!t||!t.documentElement){t=re.createDocument(Qe,`template`,null);try{t.documentElement.innerHTML=$e?C:i}catch{}}let a=t.body||t.documentElement;return e&&r&&a.insertBefore(n.createTextNode(r),a.childNodes[0]||null),Qe===Ze?oe.call(t,ke?`html`:`body`)[0]:ke?t.documentElement:a},Dt=function(e){let t=x?x(e):e.ownerDocument;return ie.call(t||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},Ot=function(e){return e=DC(e,le,` `),e=DC(e,ue,` `),e=DC(e,de,` `),e},kt=function(e){var t;e.normalize();let n=x?x(e):e.ownerDocument,r=ie.call(n||e,e,c.SHOW_TEXT|c.SHOW_COMMENT|c.SHOW_CDATA_SECTION|c.SHOW_PROCESSING_INSTRUCTION,null),i=r.nextNode();for(;i;)i.data=Ot(i.data),i=r.nextNode();let a=(t=e.querySelectorAll)==null?void 0:t.call(e,`template`);a&&vC(a,e=>{jt(e.content)&&kt(e.content)})},At=function(e){let t=b?b(e):null;return typeof t!=`string`||lt(t)!==`form`?!1:typeof e.nodeName!=`string`||typeof e.textContent!=`string`||typeof e.removeChild!=`function`||e.attributes!==v(e)||typeof e.removeAttribute!=`function`||typeof e.setAttribute!=`function`||typeof e.namespaceURI!=`string`||typeof e.insertBefore!=`function`||typeof e.hasChildNodes!=`function`||e.nodeType!==y(e)||e.childNodes!==h(e)},jt=function(e){if(!y||typeof e!=`object`||!e)return!1;try{return y(e)===_w.documentFragment}catch{return!1}},Mt=function(e){if(!y||typeof e!=`object`||!e)return!1;try{return typeof y(e)==`number`}catch{return!1}};function Nt(e,n,r){e.length!==0&&vC(e,e=>{e.call(t,n,r,ut)})}let Pt=function(e,t){return!!(Oe&&e.hasChildNodes()&&!Mt(e.firstElementChild)&&IC(pw,e.textContent)&&IC(pw,e.innerHTML)||Oe&&e.namespaceURI===Ze&&t===`style`&&Mt(e.firstElementChild)||e.nodeType===_w.processingInstruction||Oe&&e.nodeType===_w.comment&&IC(mw,e.data))},Ft=function(e,t,n){if(!xe[t]&&Bt(t)&&(be.tagNameCheck instanceof RegExp&&IC(be.tagNameCheck,t)||be.tagNameCheck instanceof Function&&be.tagNameCheck(t)))return!1;if(Be&&!Ue[t]){let t=g(e),r=h(e);if(r&&t){let i=r.length;for(let a=i-1;a>=0;--a){let i=e===n?f(r[a],!0):r[a];t.insertBefore(i,m(e))}}}return bt(e),!0},It=function(e,t,n,r){return e.length===0?t:t===n||t===r?HC(t):t},Lt=function(e,n){if(Nt(ce.beforeSanitizeElements,e,null),e!==n&&g(e)===null)return Ve&&wt(e),!0;if(At(e))return bt(e),!0;let r=lt(b?b(e):e.nodeName);if(ge=It(ce.uponSanitizeElement,ge,_e,je),Nt(ce.uponSanitizeElement,e,{tagName:r,allowedTags:ge}),e!==n&&g(e)===null)return Ve&&wt(e),!0;if(Pt(e,r))return bt(e),!0;if(xe[r]||!(Ce.tagCheck instanceof Function&&Ce.tagCheck(r))&&!ge[r]){let t=Ft(e,r,n);return t===!1&&Nt(ce.afterSanitizeElements,e,null),t}if((y?y(e):e.nodeType)===_w.element&&!yt(e)||(r===`noscript`||r===`noembed`||r===`noframes`)&&IC(hw,e.innerHTML))return bt(e),!0;if(De&&e.nodeType===_w.text){let n=Ot(e.textContent);e.textContent!==n&&(xC(t.removed,{element:e.cloneNode()}),e.textContent=n)}return Nt(ce.afterSanitizeElements,e,null),!1},Rt=function(e,t,r){if(Se[t]||Oe&&t===`patchsrc`||Oe&&t===`for`&&e!==`label`&&e!==`output`||Le&&(t===`id`||t===`name`)&&(r in n||r in dt))return!1;let i=ve[t]||Ce.attributeCheck instanceof Function&&Ce.attributeCheck(t,e);if(!(we&&IC(k,t))&&!(j&&IC(fe,t))){if(!i){if(!(Bt(e)&&(be.tagNameCheck instanceof RegExp&&IC(be.tagNameCheck,e)||be.tagNameCheck instanceof Function&&be.tagNameCheck(e))&&(be.attributeNameCheck instanceof RegExp&&IC(be.attributeNameCheck,t)||be.attributeNameCheck instanceof Function&&be.attributeNameCheck(t,e))||t===`is`&&be.allowCustomizedBuiltInElements&&(be.tagNameCheck instanceof RegExp&&IC(be.tagNameCheck,r)||be.tagNameCheck instanceof Function&&be.tagNameCheck(r))))return!1}else if(!qe[t]&&!IC(A,DC(r,me,``))&&!((t===`src`||t===`xlink:href`||t===`href`)&&e!==`script`&&OC(r,`data:`)===0&&Ge[e])&&!(Te&&!IC(pe,DC(r,me,``)))&&r)return!1}return!0},zt=BC({},[`annotation-xml`,`color-profile`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`missing-glyph`]),Bt=function(e){return!zt[wC(e)]&&IC(he,e)},Vt=function(e,t,n,r){if(S&&typeof u==`object`&&typeof u.getAttributeType==`function`&&!n)switch(u.getAttributeType(e,t)){case`TrustedHTML`:return ee(r);case`TrustedScriptURL`:return O(r)}return r},Ht=function(e,n,r,i){try{r?e.setAttributeNS(r,n,i):e.setAttribute(n,i),At(e)?bt(e):bC(t.removed)}catch{St(n,e)}},Ut=function(e){Nt(ce.beforeSanitizeAttributes,e,null);let t=e.attributes;if(!t||At(e))return;ve=It(ce.uponSanitizeAttribute,ve,ye,Me);let n={attrName:``,attrValue:``,keepAttr:!0,allowedAttributes:ve,forceKeepAttr:void 0},r=t.length,i=lt(e.nodeName);for(;r--;){let a=t[r],o=a.name,s=a.namespaceURI,c=a.value,l=lt(o),u=c,d=o===`value`?u:kC(u);if(n.attrName=l,n.attrValue=d,n.keepAttr=!0,n.forceKeepAttr=void 0,Nt(ce.uponSanitizeAttribute,e,n),d=n.attrValue,Re&&(l===`id`||l===`name`)&&OC(d,ze)!==0&&(St(o,e),d=ze+d),Oe&&IC(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,d)){St(o,e);continue}if(l===`attributename`&&EC(d,`href`)){St(o,e);continue}if(!n.forceKeepAttr){if(!n.keepAttr){St(o,e);continue}if(!Ee&&IC(gw,d)){St(o,e);continue}if(De&&(d=Ot(d)),!Rt(i,l,d)){St(o,e);continue}d=Vt(i,l,s,d),d!==u&&Ht(e,o,s,d)}}Nt(ce.afterSanitizeAttributes,e,null)},Wt=function(e){let t=null,n=Dt(e);for(Nt(ce.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(Nt(ce.uponSanitizeShadowNode,t,null),Lt(t,e),Ut(t),jt(t.content)&&Wt(t.content),(y?y(t):t.nodeType)===_w.element){let e=_(t);jt(e)&&(Gt(e),Wt(e))}Nt(ce.afterSanitizeShadowDOM,e,null)},Gt=function(e){let t=[{node:e,shadow:null}];for(;t.length>0;){let e=t.pop();if(e.shadow){Wt(e.shadow);continue}let n=e.node,r=(y?y(n):n.nodeType)===_w.element,i=h(n);if(i)for(let e=i.length-1;e>=0;--e)t.push({node:i[e],shadow:null});if(r){let e=b?b(n):null;if(typeof e==`string`&&lt(e)===`template`){let e=n.content;jt(e)&&t.push({node:e,shadow:null})}}if(r){let e=_(n);jt(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=null,a=null,o=null,s=null;if($e=!e,$e&&(e=`<!-->`),typeof e!=`string`&&!Mt(e)&&(e=UC(e),typeof e!=`string`))throw LC(`dirty is not a string, aborting`);if(!t.isSupported)return e;Ae?(ge=je,ve=Me):pt(n),(ce.uponSanitizeElement.length>0||ce.uponSanitizeAttribute.length>0)&&(ge=HC(ge)),ce.uponSanitizeAttribute.length>0&&(ve=HC(ve)),t.removed=[];let c=Ve&&typeof e!=`string`&&Mt(e);if(c){Tt(e);let t=b?b(e):e.nodeName;if(typeof t==`string`){let n=lt(t);if(!ge[n]||xe[n])throw xt(e),LC(`root node is forbidden and cannot be sanitized in-place`)}if(At(e))throw xt(e),LC(`root node is clobbered and cannot be sanitized in-place`);try{Gt(e)}catch(t){throw xt(e),t}}else if(Mt(e))i=Et(`<!---->`),a=i.ownerDocument.importNode(e,!0),a.nodeType===_w.element&&a.nodeName===`BODY`||a.nodeName===`HTML`?i=a:i.appendChild(a),Gt(a);else{if(!Pe&&!De&&!ke&&e.indexOf(`<`)===-1)return S&&Ie?ee(e):e;if(i=Et(e),!i)return Pe?null:Ie?C:``}i&&Ne&&bt(i.firstChild);let l=c?e:i;try{let e=Dt(l);for(;o=e.nextNode();)Lt(o,l),Ut(o),jt(o.content)&&Wt(o.content)}catch(n){throw c&&(xt(e),vC(t.removed,e=>{e.element&&wt(e.element)})),n}if(c)return vC(t.removed,e=>{e.element&&wt(e.element)}),De&&kt(e),e;if(Pe){if(De&&kt(i),Fe)for(s=ae.call(i.ownerDocument);i.firstChild;)s.appendChild(i.firstChild);else s=i;return(ve.shadowroot||ve.shadowrootmode)&&(s=se.call(r,s,!0)),s}let u=ke?i.outerHTML:i.innerHTML;return ke&&ge[`!doctype`]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&IC(dw,i.ownerDocument.doctype.name)&&(u=`<!DOCTYPE `+i.ownerDocument.doctype.name+`>
95
+ `+u),De&&(u=Ot(u)),S&&Ie?ee(u):u},t.setConfig=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};pt(e),Ae=!0,je=ge,Me=ve},t.clearConfig=function(){ut=null,Ae=!1,je=null,Me=null,S=w,C=``},t.isValidAttribute=function(e,t,n){ut||pt({});let r=lt(e),i=lt(t);return Rt(r,i,n)},t.addHook=function(e,t){typeof t==`function`&&PC(ce,e)&&xC(ce[e],t)},t.removeHook=function(e,t){if(PC(ce,e)){if(t!==void 0){let n=yC(ce[e],t);return n===-1?void 0:SC(ce[e],n,1)[0]}return bC(ce[e])}},t.removeHooks=function(e){PC(ce,e)&&(ce[e]=[])},t.removeAllHooks=function(){ce=bw()},t}var Cw=Sw(),ww=e=>!e||typeof Cw.sanitize!=`function`?``:Cw.sanitize(e,{USE_PROFILES:{html:!0},FORBID_TAGS:[`style`,`script`,`iframe`,`object`,`embed`,`form`],FORBID_ATTR:[`onerror`,`onload`,`onclick`,`onmouseover`,`style`]}),Tw=(e,t)=>{e.innerHTML=ww(t.value)},Ew={mounted:Tw,updated:Tw},Dw=150,Ow=[`auto`,`top`,`bottom`,`left`,`right`,`auto-start`,`auto-end`,`top-start`,`top-end`,`bottom-start`,`bottom-end`,`left-start`,`left-end`,`right-start`,`right-end`];function kw(e){return e&&Ow.includes(e)?e:`top`}var Aw=L({name:`Tooltip`,directives:{safeHtml:Ew},props:{text:{type:String,default:void 0},placement:{type:String,default:void 0},trigger:{type:String,default:void 0},delay:{type:Number,default:void 0}},setup(e){let t=M(null),n=M(null),r=M(null),i=M(null),a=M(null),o=M(!1),s,c,l,u=()=>new Set((e.trigger??`hover click`).split(/\s+/).filter(Boolean)),d=()=>{s&&clearTimeout(s),c&&clearTimeout(c),l&&clearTimeout(l),s=c=l=void 0},f=()=>{a.value||!n.value||!r.value||!i.value||(a.value=eC(n.value,r.value,{placement:kw(e.placement),strategy:`absolute`,modifiers:[{name:`offset`,options:{offset:[0,8]}},{name:`arrow`,options:{element:i.value}}]}))},p=()=>{var t;!r.value||!e.text||(r.value.style.display=`block`,f(),(t=a.value)==null||t.update(),requestAnimationFrame(()=>{var e;(e=r.value)==null||e.classList.add(`show`)}),o.value=!0)},m=()=>{r.value&&(r.value.classList.remove(`show`),o.value=!1,l=setTimeout(()=>{r.value&&!o.value&&(r.value.style.display=`none`)},Dw))},h=()=>{d(),s=setTimeout(p,e.delay??0)},g=()=>{d(),c=setTimeout(m,e.delay??0)},_=()=>{d(),m()},v=()=>{u().has(`hover`)&&h()},y=()=>{u().has(`hover`)&&g()},b=()=>{u().has(`focus`)&&h()},x=()=>{u().has(`focus`)&&g()},S=()=>/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(typeof navigator<`u`?navigator.userAgent:``);return $f(t,()=>{S()&&_()}),I(()=>e.text,()=>{var e;o.value&&((e=a.value)==null||e.update())}),I(()=>e.placement,()=>{a.value&&a.value.setOptions({placement:kw(e.placement)})}),Mr(()=>{var e;d(),(e=a.value)==null||e.destroy(),a.value=null}),{wrapper:t,triggerEl:n,tooltipEl:r,arrowEl:i,hideNow:_,onMouseEnter:v,onMouseLeave:y,onFocusIn:b,onFocusOut:x}}}),jw={ref:`tooltipEl`,class:`tooltip bs-tooltip-auto fade`,role:`tooltip`,style:{display:`none`,"pointer-events":`none`}},Mw={ref:`arrowEl`,class:`tooltip-arrow`},Nw={class:`tooltip-inner`};function Pw(e,t,n,r,i,a){let o=Hr(`safe-html`);return H(),U(`span`,{ref:`wrapper`,onClick:t[4]||(t[4]=(...t)=>e.hideNow&&e.hideNow(...t))},[G(`span`,{ref:`triggerEl`,class:`d-inline-flex align-items-center`,style:{cursor:`default`},onMouseenter:t[0]||(t[0]=(...t)=>e.onMouseEnter&&e.onMouseEnter(...t)),onMouseleave:t[1]||(t[1]=(...t)=>e.onMouseLeave&&e.onMouseLeave(...t)),onFocusin:t[2]||(t[2]=(...t)=>e.onFocusIn&&e.onFocusIn(...t)),onFocusout:t[3]||(t[3]=(...t)=>e.onFocusOut&&e.onFocusOut(...t))},[B(e.$slots,`default`)],544),G(`div`,jw,[G(`div`,Mw,null,512),F(G(`div`,Nw,null,512),[[o,e.text]])],512)],512)}var Fw=Q(Aw,[[`render`,Pw]]),Iw=L({name:`pis-catalogs-search-table`,components:{Icon:$h,Tooltip:Fw,Clickable:wm,DropdownPopper:Wv,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,emit:c,t:l}=ym(t,e.instanceId,[Ud.Products]),{onCatalogItemMenuAction:u}=bm(a,l,n),d=Y(()=>{var e;return(e=o.value)==null||(e=e.data.catalogs)==null?void 0:e.items}),f=Y(()=>{var e;return((e=a.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-preview`))??!1}),p=Ul,m=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.table)??{}}),h=Y(()=>m.value.columns),g=async e=>{if(s.value&&e)try{var t;await((t=a.value)==null?void 0:t.execute(new ku({catalogId:e}).from(n)))}catch{}},_=Y(()=>{var e;return(e=s.value)==null?void 0:e.catalogs.pagination}),v=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.pageSizes}),y=Y({get:()=>{var e;return((e=_.value)==null?void 0:e.pageSize)??24},set:e=>{var t;return(t=a.value)==null?void 0:t.execute(new zu({pageSize:e}).from(n))}}),b=Y({get:()=>{var e;return(e=s.value)==null?void 0:e.catalogs.sortField},set:e=>{var t;return(t=a.value)==null?void 0:t.execute(new Ku({sortField:e}).from(n))}}),x=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null||(e=e.actions)==null?void 0:e.catalogItemMenu});return{root:t,store:o,sortBy:b,isReady:r,columns:h,pageSize:y,instance:a,routeData:s,sortByItems:p,catalogItems:d,componentName:n,pageSizeItems:v,isWebComponent:i,previewEnabled:f,actionsEnabled:Y(()=>{var e,t;return((e=a.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-search-actions-modals`))&&((t=x.value)==null?void 0:t.visible)}),catalogItemMenu:x,componentOptions:m,t:l,emit:c,details:g,attrValue:Us,attrValues:Ws,isDisabled:(e,t)=>typeof e.disabled==`function`?e.disabled(t):e.disabled,additionalInfo:Gs,catalogItemMenuItems:e=>{var t;return(((t=x.value)==null?void 0:t.items)||[]).filter(t=>typeof t.visible==`function`?t.visible(e):t.visible)},onCatalogItemMenuAction:u,reactiveContext:lg,cellCtx:hg(e=>({col:e.col,instance:a.value,item:e.item,t:l,emit:c,details:g,attrValue:Us,attrValues:Ws})),itemCtx:hg(e=>({instance:a.value,item:e.item,emit:c,t:l}))}}}),Lw={key:0,class:`table-responsive pis-scroll`},Rw={class:`table`},zw={key:0},Bw={key:1,class:`d-flex align-items-center`},Vw={key:2},Hw={key:0,style:{overflow:`hidden`,"text-align":`right`}},Uw={type:`button`,class:`btn btn-link text-dark`},Ww={class:`dropdown-menu show`},Gw={key:0,class:`dropdown-divider`},Kw={key:1,class:`dropdown-item text-muted`},qw=[`onClick`],Jw={key:0},Yw={key:1,class:`my-3 py-5 text muted`};function Xw(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Clickable`),c=R(`Tooltip`),l=R(`Icon`),u=R(`DropdownPopper`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName]),style:{"z-index":`1`}},[e.isReady&&e.componentOptions.visible?(H(),U(V,{key:0},[e.catalogItems&&e.catalogItems.length?(H(),U(`div`,Lw,[G(`table`,Rw,[G(`colgroup`,null,[(H(!0),U(V,null,z(e.columns,(e,t)=>(H(),U(`col`,{key:t,style:k({width:e.width})},null,4))),128)),t[0]||(t[0]=G(`col`,null,null,-1))]),G(`thead`,null,[G(`tr`,null,[(H(!0),U(V,null,z(e.columns,(t,n)=>(H(),U(`th`,{key:n},[t.headerTemplate?(H(),W(o,{key:0,callbacks:t.headerTemplate,ctx:e.reactiveContext({t:e.t,col:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(t.caption),1)],64))]))),128)),e.actionsEnabled?(H(),U(`th`,zw)):J(``,!0),t[1]||(t[1]=G(`th`,null,null,-1))])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.catalogItems,(t,n)=>(H(),U(`tr`,{key:t.id},[(H(!0),U(V,null,z(e.columns,(n,r)=>(H(),U(`td`,{key:r},[n.cellTemplate?(H(),W(o,{key:0,callbacks:n.cellTemplate,ctx:e.cellCtx({item:t,col:n})},null,8,[`callbacks`,`ctx`])):n.dataField===`code`?(H(),U(`span`,Bw,[K(c,{trigger:`hover`,text:e.t(`ItemsInCatalog`,!1,[`${t.productsTotalCount}`])},{default:P(()=>[K(s,{onClick:n=>e.details(t.id)},{default:P(()=>[q(j(t.code),1)]),_:2},1032,[`onClick`])]),_:2},1032,[`text`])])):(H(),U(`span`,Vw,j(t[n.dataField]),1))]))),128)),e.actionsEnabled&&e.catalogItemMenuItems(t).length?(H(),U(`td`,Hw,[K(u,{class:`d-inline-block`,placement:`bottom-start`,interactive:!0,top:n>=e.catalogItems.length-2},{trigger:P(()=>[G(`button`,Uw,[K(l,{name:`menu`})])]),dropdown:P(({close:n})=>[G(`ul`,Ww,[(H(!0),U(V,null,z(e.catalogItemMenuItems(t),(r,i)=>(H(),U(`li`,{key:i},[r.text===`-`?(H(),U(`hr`,Gw)):e.isDisabled(r,t)?(H(),U(`span`,Kw,[r.itemTemplate?(H(),W(o,{key:0,callbacks:r.itemTemplate,ctx:e.itemCtx({item:r})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(r.text),1)],64))])):(H(),U(`a`,{key:2,class:`dropdown-item`,href:``,onClick:X(i=>{e.onCatalogItemMenuAction(r,t),n()},[`prevent`])},[r.itemTemplate?(H(),W(o,{key:0,callbacks:r.itemTemplate,ctx:e.itemCtx({item:r})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(r.text),1)],64))],8,qw))]))),128))])]),_:2},1032,[`top`])])):J(``,!0),G(`td`,null,[t.default?(H(),U(`span`,Jw,[K(l,{name:`star`})])):J(``,!0)])]))),128))])])])):(H(),U(`div`,Yw,j(e.t(`NoResults`)),1))],64)):J(``,!0)],2)}var Zw=Q(Iw,[[`render`,Xw]]),Qw=L({name:`pis-catalogs-search-toolbar`,components:{DropdownPopper:Wv,PaginationAmount:Yv,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,narrowerThan:c,emit:l,t:u}=ym(t,e.instanceId,[Ud.Products]),{onCatalogListMenuAction:d}=bm(a,u,n),f=Ul,p=Y(()=>[{val:``,text:u(`CreatedAll`)},{val:10,text:u(`CreatedWithinDays`,!1,[`10`])},{val:20,text:u(`CreatedWithinDays`,!1,[`20`])},{val:30,text:u(`CreatedWithinDays`,!1,[`30`])}]),m=Y({get:()=>{var e;return(e=s.value)==null?void 0:e.catalogs.sortField},set:e=>{var t;return(t=a.value)==null?void 0:t.execute(new Ku({sortField:e}).from(n))}}),h=Y(()=>{var e;return((e=o.value)==null||(e=e.data.catalogs)==null?void 0:e.totalCount)??0}),g=Y(()=>{var e;return(e=s.value)==null?void 0:e.catalogs.pagination}),_=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.pageSizes}),v=Y({get:()=>{var e;return((e=g.value)==null?void 0:e.pageSize)??24},set:e=>{var t;return(t=a.value)==null?void 0:t.execute(new zu({pageSize:e}).from(n))}}),y=Y({get:()=>{var e;return((e=s.value)==null?void 0:e.catalogs.createdWithinLastDays)??``},set:e=>{var t;return(t=a.value)==null?void 0:t.execute(new qu({days:e}).from(n))}}),b=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null||(e=e.actions)==null?void 0:e.catalogListMenu});return{root:t,store:o,sortBy:m,isReady:r,instance:a,pageSize:v,routeData:s,pagination:g,totalCount:h,createdDate:y,sortByItems:f,createdItems:p,componentName:n,pageSizeItems:_,isWebComponent:i,actionsEnabled:Y(()=>{var e,t;return((e=a.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-search-actions-modals`))&&((t=b.value)==null?void 0:t.visible)}),catalogListMenu:b,catalogListMenuItems:()=>{var e;return(((e=b.value)==null?void 0:e.items)||[]).filter(e=>typeof e.visible==`function`?e.visible():e.visible)},t:u,emit:l,attrValue:Us,attrValues:Ws,isDisabled:e=>typeof e.disabled==`function`?e.disabled():e.disabled,narrowerThan:c,additionalInfo:Gs,onCatalogListMenuAction:d,reactiveContext:lg,itemCtx:hg(e=>({instance:a.value,item:e.item,emit:l,t:u}))}}}),$w={class:`my-3 d-flex flex-row justify-content-between align-items-center flex-wrap`},eT={key:0,class:`d-flex align-items-center my-2`},tT=[`value`],nT=[`value`],rT=[`value`,`textContent`],iT={key:0,class:`d-flex align-items-center justify-content-end my-2`},aT={key:1,type:`button`,class:`btn btn-primary dropdown-toggle`},oT={class:`dropdown-menu show`},sT={key:0,class:`dropdown-divider`},cT={key:1,class:`dropdown-item text-muted`},lT=[`onClick`];function uT(e,t,n,r,i,a){var o;let s=R(`PaginationAmount`),c=R(`MountPoint`),l=R(`DropdownPopper`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName]),style:{"z-index":`1`}},[e.isReady?(H(),U(V,{key:0},[G(`div`,$w,[e.totalCount&&e.pagination?(H(),U(`label`,eT,[K(s,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0)},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`])])):J(``,!0),G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`CreatedWithin`))+`: `,3),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.createdDate=t),class:`form-select ms-2 w-100`},[(H(!0),U(V,null,z(e.createdItems,(e,t)=>(H(),U(`option`,{key:t,value:e.val},j(e.text),9,tT))),128))],512),[[Cs,e.createdDate]])],2),G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`SortBy`))+`: `,3),F(G(`select`,{"onUpdate:modelValue":t[1]||(t[1]=t=>e.sortBy=t),class:`form-select ms-2 w-100`},[(H(!0),U(V,null,z(e.sortByItems,(t,n)=>(H(),U(`option`,{key:n,value:t},j(e.t(`SortBy${t}`)),9,nT))),128))],512),[[Cs,e.sortBy]])],2),G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`PageSize`))+`: `,3),F(G(`select`,{"onUpdate:modelValue":t[2]||(t[2]=t=>e.pageSize=t),class:`form-select ms-2`},[(H(!0),U(V,null,z(e.pageSizeItems,e=>(H(),U(`option`,{key:e,value:e,textContent:j(e)},null,8,rT))),128))],512),[[Cs,e.pageSize]])],2)]),e.actionsEnabled&&(o=e.catalogListMenu)!=null&&o.items?(H(),U(`div`,iT,[K(l,{placement:`bottom-start`,interactive:!0},{trigger:P(()=>[e.catalogListMenu.buttonTemplate?(H(),W(c,{key:0,callbacks:e.catalogListMenu.buttonTemplate,ctx:e.reactiveContext({instance:e.instance,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])):(H(),U(`button`,aT,j(e.t(`Actions`)),1))]),dropdown:P(({close:t})=>[G(`ul`,oT,[(H(!0),U(V,null,z(e.catalogListMenuItems(),(n,r)=>(H(),U(`li`,{key:r},[n.text===`-`?(H(),U(`hr`,sT)):e.isDisabled(n)?(H(),U(`span`,cT,[n.itemTemplate?(H(),W(c,{key:0,callbacks:n.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(n.text),1)],64))])):(H(),U(`a`,{key:2,class:`dropdown-item`,href:``,onClick:X(r=>{e.onCatalogListMenuAction(n),t()},[`prevent`])},[n.itemTemplate?(H(),W(c,{key:0,callbacks:n.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(n.text),1)],64))],8,lT))]))),128))])]),_:1})])):J(``,!0)],64)):J(``,!0)],2)}var dT=Q(Qw,[[`render`,uT]]);function fT(e,t=300){let n,r=!1,i=()=>{n!==void 0&&(clearTimeout(n),n=void 0)};return{update(a,o){if(r=a,!a){i(),e.setShow(!1);return}if(!e.isShown()){if(!o){i(),e.setShow(!0);return}n===void 0&&(n=setTimeout(()=>{n=void 0,r&&!e.isShown()&&e.setShow(!0)},t))}},cancel:i}}function pT(e,t,n=300){let r=M(!1),i=fT({isShown:()=>r.value,setShow:e=>{r.value=e}},n);return I([e,t],([e,t])=>i.update(e,t),{immediate:!0}),je(()=>i.cancel()),r}var mT=L({name:`pis-catalogs-loading-indicator`,components:{Spinner:My},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,routeData:o}=ym(t,e.instanceId);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:a,routeData:o,showOverlay:pT(Y(()=>{var e;return r.value&&!!((e=a.value)!=null&&e.data.isLoadingData)}),Y(()=>{var e,t;return!!((e=a.value)!=null&&(e=e.data.catalogs)!=null&&(e=e.items)!=null&&e.length)||!!((t=a.value)!=null&&(t=t.data.products)!=null&&(t=t.items)!=null&&t.length)}))}}}),hT={ref:`root`,class:`pis-component position-relative`},gT={class:`position-absolute start-50 top-50`,style:{"z-index":`2000`}};function _T(e,t,n,r,i,a){let o=R(`Spinner`);return H(),U(`div`,hT,[e.showOverlay?(H(),U(V,{key:0},[G(`div`,gT,[B(e.$slots,`loader`,{},()=>[K(o)])]),t[0]||(t[0]=G(`div`,{class:`position-absolute top-0 start-0 end-0 bottom-0 bg-body`,style:{"z-index":`1900`,opacity:`0.2`}},null,-1))],64)):J(``,!0),B(e.$slots,`default`)],512)}var vT=Q(mT,[[`render`,_T]]),yT={success:`check-mark-circle`,info:`information-circle`,warning:`warning-circle`,danger:`cross-close-circle`},bT=L({name:`Alert`,components:{Icon:$h},props:{notification:{type:Object,required:!0}},emits:[`closed`],setup(e,{emit:t}){let n=()=>{t(`closed`,!0)},r=Y(()=>yT[e.notification.type]);return{alert,closeAlert:n,icon:r}}}),xT={class:`d-flex flex-grow-1`};function ST(e,t,n,r,i,a){let o=R(`Icon`);return H(),U(`div`,{class:A([[`alert`,`alert-${e.notification.type}`,`alert-dismissible`],`d-flex flex-row align-items-center justify-content-between fade show`]),role:`alert`},[e.icon?(H(),W(o,{key:0,name:e.icon,size:24},null,8,[`name`])):J(``,!0),G(`div`,xT,[B(e.$slots,`default`)]),G(`button`,{type:`button`,class:`d-flex pis-alert-close-button`,"aria-label":`Close`,onClick:t[0]||(t[0]=X((...t)=>e.closeAlert&&e.closeAlert(...t),[`prevent`]))},[K(o,{name:`cross-close`,size:16})])],2)}var CT=L({components:{Alert:Q(bT,[[`render`,ST]])},props:{instance:{type:Object,required:!0}},setup(e){return{notifications:Y(()=>e.instance.store.notifications),onClosed:t=>{let n=e.instance.store.notifications;n&&n.includes(t)&&n.splice(n.indexOf(t),1)}}}}),wT={class:`pis-component`},TT={class:`px-4`};function ET(e,t,n,r,i,a){let o=R(`Alert`),s=Hr(`safe-html`);return H(),U(`div`,wT,[(H(!0),U(V,null,z(e.notifications,(t,n)=>(H(),W(o,{key:n,notification:t,onClosed:n=>e.onClosed(t)},{default:P(()=>[F(G(`span`,TT,null,512),[[s,t.message]])]),_:2},1032,[`notification`,`onClosed`]))),128))])}var DT=Q(CT,[[`render`,ET]]),OT=L({name:`pis-catalogs-common-notifications`,components:{Notifications:DT},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s}=ym(t,e.instanceId);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:o,routeData:s,instance:a}}}),kT={ref:`root`,class:`pis-component`};function AT(e,t,n,r,i,a){let o=R(`Notifications`);return H(),U(`div`,kT,[e.isReady&&e.store?(H(),W(o,{key:0,instance:e.instance},null,8,[`instance`])):J(``,!0)],512)}var jT=Q(OT,[[`render`,AT]]),MT=L({components:{Btn:Iy,Modal:Qy,FormInputClearable:Mb},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=M(!0),i=Y(()=>e.data.alias.alternateProductId||e.data.alias.productId),a=M(``),o=M(``),s=M([]),c=M([]),l=[...e.data.alias.aliases||[]],u=Y(()=>a.value.length>2),d=()=>{o.value=``,s.value=[],c.value=[]},f=e=>{e&&(e.message&&(o.value=e.message),e.warnings&&(s.value=[...e.warnings]),e.errors&&(c.value=[...e.errors]))};return{show:r,aliases:l,isFormValid:u,toBeAddedAlias:a,currentErrors:c,currentMessage:o,currentWarnings:s,onModalShowUpdate:async e=>{try{r.value=e,t(`update:show`,e),e===!1&&await n.execute(new Du().from(`alias-edit-modal`))}catch{}},attrValue:Us,onAddAlias:async e=>{if(d(),i.value)try{let t=await n.execute(new dd({doNotHandleErrors:!0,onSuccessMessage:``,aliases:[{productId:i.value,value:e}]}).from(`alias-edit-modal`));f(t),t&&t.success&&(l.push(...(t.aliases||[]).map(e=>({...e,editable:!0}))),a.value=``)}catch{}},onDeleteAlias:async e=>{d();try{let t=await n.execute(new fd({onSuccessMessage:``,doNotHandleErrors:!0,aliases:[{id:e.id}]}).from(`alias-edit-modal`));if(f(t),t&&t.success){let t=l.indexOf(e);t!==-1&&l.splice(t,1)}}catch{}},onCurrentAliasUpdate:e=>a.value=e}}}),NT={class:`d-flex justify-content-start`},PT={class:`list-unstyled mt-3`},FT={class:`w-75`},IT=[`value`],LT={class:`btn-group d-flex justify-content-between align-items-center`},RT={class:`w-75`},zT={class:`list-unstyled ms-4 mt-3`};function BT(e,t,n,r,i,a){let o=R(`Btn`),s=R(`FormInputClearable`),c=R(`Modal`);return H(),W(c,{show:e.show,title:e.t(`EditProductAliases`),"close-on-outer-click":!1,lg:``,"onUpdate:show":e.onModalShowUpdate},{default:P(()=>[G(`form`,{onSubmit:t[1]||(t[1]=X(()=>{},[`prevent`]))},[G(`div`,NT,[G(`strong`,null,j(e.t(`Product`))+`\xA0`+j(e.attrValue(e.data.alias,`#DisplayName`)),1)]),G(`div`,null,[G(`ul`,PT,[(H(!0),U(V,null,z(e.aliases,(t,n)=>(H(),U(`li`,{key:n,class:`btn-group d-flex justify-content-between align-items-center mb-2`},[G(`div`,FT,[G(`input`,{type:`text`,class:`form-control`,value:t.value,readonly:``},null,8,IT)]),t.editable?(H(),W(o,{key:0,secondary:``,onClick:X(n=>e.onDeleteAlias(t),[`prevent`])},{default:P(()=>[q(j(e.t(`DeleteAlias`)),1)]),_:1},8,[`onClick`])):J(``,!0)]))),128)),G(`li`,LT,[G(`div`,RT,[K(s,{"model-value":e.toBeAddedAlias,"onUpdate:modelValue":e.onCurrentAliasUpdate},null,8,[`model-value`,`onUpdate:modelValue`])]),K(o,{disabled:!e.isFormValid,primary:``,onClick:t[0]||(t[0]=X(t=>e.onAddAlias(e.toBeAddedAlias),[`prevent`]))},{default:P(()=>[q(j(e.t(`AddAlias`)),1)]),_:1},8,[`disabled`])])])]),G(`div`,null,[G(`strong`,null,j(e.currentMessage),1),G(`ul`,zT,[(H(!0),U(V,null,z(e.currentErrors,(e,t)=>(H(),U(`li`,{key:t,class:`d-flex justify-content-start align-items-center text-danger`},[G(`span`,null,j(e.message),1)]))),128)),(H(!0),U(V,null,z(e.currentWarnings,(e,t)=>(H(),U(`li`,{key:t,class:`d-flex justify-content-start align-items-center text-warning`},[G(`span`,null,j(e.message),1)]))),128))])])],32)]),_:1},8,[`show`,`title`,`onUpdate:show`])}var VT=Q(MT,[[`render`,BT]]),HT=L({props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!1,default:void 0}},emits:[`update:show`],setup(e,{emit:t}){return kr(async()=>{let n=Pf.Catalogs.getInstance(e.instanceId);try{await n.execute(new ud({onSuccessMessage:e.t(`AliasesExportReady`)}).from(`aliases-export-modal`))===!0&&await n.execute(new pd({type:`success`,message:e.t(`AliasesExportScheduled`)}).from(`aliases-export-modal`))}catch{}t(`update:show`,!1)}),{}}});function UT(e,t,n,r,i,a){return H(),U(`div`)}var WT=Q(HT,[[`render`,UT]]),GT=e=>new Promise((t,n)=>{if(!window.FileReader)return n(Error(`FileReader not available!`));let r=new FileReader;r.onerror=e=>n(e),r.onload=()=>t(r.result),r.readAsDataURL(e)}),KT=L({components:{Btn:Iy,Modal:Qy},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!1,default:void 0}},emits:[`update:show`],setup(e,{emit:t}){let n=M(!0),r=Pf.Catalogs.getInstance(e.instanceId),i=M(),a=Y(()=>!!i.value),o={uploadedFile:{[mb.required]:{}}},s=e=>{let t=e.target;t&&t.files&&(i.value=t.files[0])},c=()=>t(`update:show`,!1);return{show:n,validators:o,isFormValid:a,uploadedFile:i,close:c,onImport:async()=>{if(i.value){try{let t=await GT(i.value);await r.execute(new ld({file:t,fileName:i.value.name,onSuccessMessage:e.t(`CatalogImportAliasesSuccess`)}).from(`aliases-import-modal`))}catch{}c()}},onFileUpload:s}}}),qT={class:`d-block pt-2`},JT={class:`form-label fw-bolder`},YT={class:`pt-2 has-validation`},XT={class:`form-label fw-bolder`},ZT={class:`mt-3`},QT={class:`d-flex justify-content-end mt-3`};function $T(e,t,n,r,i,a){let o=R(`Btn`),s=R(`Modal`);return H(),W(s,{show:e.show,title:e.t(`ImportAliasList`),"close-on-outer-click":!1,"onUpdate:show":t[4]||(t[4]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[3]||(t[3]=X(()=>{},[`prevent`]))},[G(`label`,qT,[G(`div`,JT,j(e.t(`CatalogCode`)),1)]),G(`div`,YT,[G(`div`,XT,j(e.t(`File`)),1),G(`input`,{type:`file`,class:`form-control`,onChange:t[0]||(t[0]=t=>e.onFileUpload(t))},null,32)]),G(`p`,ZT,j(e.t(`ImportAliasWarning`)),1),G(`p`,null,j(e.t(`ImportAliasInfo`)),1),t[5]||(t[5]=G(`hr`,null,null,-1)),G(`div`,QT,[K(o,{class:`mx-2`,onClick:t[1]||(t[1]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(o,{disabled:!e.isFormValid,primary:``,onClick:t[2]||(t[2]=X(t=>e.onImport(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Import`)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`show`,`title`])}var eE=Q(KT,[[`render`,$T]]),tE={ok:`confirmation-ok`,cancelled:`confirmation-cancelled`},nE=L({name:`Confirmation`,components:{Btn:Iy,Modal:Qy},props:{t:{type:Function,required:!0},item:{type:Object,required:!1,default:void 0},title:{type:String,default:void 0},lg:{type:Boolean,default:!1},xl:{type:Boolean,default:!1}},emits:[`update:show`,tE.ok,tE.cancelled],setup(){return{confirmationEvent:tE}}}),rE={class:`d-flex justify-content-end mt-3`};function iE(e,t,n,r,i,a){let o=R(`Btn`),s=R(`Modal`);return H(),W(s,{show:!!e.item,title:e.title,lg:e.lg,xl:e.xl,"onUpdate:show":t[2]||(t[2]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,null,[B(e.$slots,`default`),G(`div`,rE,[K(o,{primary:``,onClick:t[0]||(t[0]=X(t=>e.$emit(e.confirmationEvent.ok,e.item),[`prevent`]))},{default:P(()=>[q(j(e.t(`Confirm`,!0)),1)]),_:1}),K(o,{class:`mx-2`,onClick:t[1]||(t[1]=X(t=>e.$emit(e.confirmationEvent.cancelled,e.item),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1})])])]),_:3},8,[`show`,`title`,`lg`,`xl`])}var aE=Q(nE,[[`render`,iE]]),oE=L({name:`pis-catalogs-aliases-search-actions-modals`,components:{Confirmation:aE,AliasEditModal:VT,AliasesImportModal:eE,AliasesExportModal:WT},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isReady:i,isWebComponent:a,store:o,t:s}=ym(t,e.instanceId),c=Y(()=>{var e;return(e=r.value)==null?void 0:e.store.data.actions}),l=Y(()=>{var e;return(e=c.value)==null?void 0:e.current}),u=Y(()=>{var e;return(e=c.value)==null?void 0:e.data}),d=async()=>{try{var e;(e=r.value)==null||e.execute(new hd().from(n))}catch{}};return{root:t,store:o,isReady:i,componentName:n,isWebComponent:a,currentActionName:l,currentActionData:u,CatalogAction:Hs,t:s,attrValue:Us,onAliasDelete:async()=>{var e;let t=c.value;if(!(t!=null&&t.current)||t.current!==Hs.aliasDelete)return;let i=(e=t.data)==null?void 0:e.aliases;if(!(!i||!i.length)){try{var a,o;await((a=r.value)==null?void 0:a.execute(new fd({onSuccessMessage:s(`AliasDeleteSuccess`),aliases:i.map(e=>({id:e.id}))}).from(n))),await((o=r.value)==null?void 0:o.execute(new Du().from(n)))}catch{}d()}},onActionCompleted:d}}}),sE={ref:`root`,class:`pis-component position-relative`},cE={class:`mb-4`},lE={class:`list-unstyled`};function uE(e,t,n,r,i,a){let o=R(`AliasEditModal`),s=R(`AliasesImportModal`),c=R(`AliasesExportModal`),l=R(`Confirmation`);return H(),U(`div`,sE,[e.isReady?(H(),U(V,{key:0},[e.currentActionName===e.CatalogAction.aliasEdit?(H(),W(o,{key:0,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):J(``,!0),e.currentActionName===e.CatalogAction.aliasImport?(H(),W(s,{key:1,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):J(``,!0),e.currentActionName===e.CatalogAction.aliasExport?(H(),W(c,{key:2,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.aliasDelete?(H(),W(l,{key:3,title:e.t(`DeleteProductAliases`),item:e.currentActionData.aliases,t:e.t,"onUpdate:show":e.onActionCompleted,onConfirmationCancelled:e.onActionCompleted,onConfirmationOk:e.onAliasDelete},{default:P(()=>[G(`div`,cE,[q(j(e.t(`AliasesConfirmDelete`))+` `,1),G(`ul`,lE,[(H(!0),U(V,null,z(e.currentActionData.aliases,(e,t)=>(H(),U(`li`,{key:t},[G(`strong`,null,j(e.value),1)]))),128))])])]),_:1},8,[`title`,`item`,`t`,`onUpdate:show`,`onConfirmationCancelled`,`onConfirmationOk`])):J(``,!0)],64)):J(``,!0)],512)}var dE=Q(oE,[[`render`,uE]]),fE=L({name:`pis-catalogs-products-search-breadcrumbs`,components:{Arrow:qb,Clickable:wm,Icon:$h},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s}=ym(t,e.instanceId,[Ud.Breadcrumbs]);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:o,breadcrumbs:Y(()=>{var e;return o.value?(e=o.value)==null||(e=e.data.breadcrumbs)==null?void 0:e.items:null}),visible:Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.breadcrumbs)==null?void 0:e.visible}),setClassification:({cid:e})=>{if(a.value&&e)try{if(e==`ROOT`)a.value.execute(new Au({cid:e,clearSearch:!0,treeType:void 0}).from(n));else{var t;a.value.execute(new Au({cid:e,clearSearch:!0,treeType:(t=s.value)==null?void 0:t.products.treeType}).from(n))}}catch{}}}}}),pE={key:0},mE={key:0,class:`list-unstyled`},hE={class:`d-flex align-items-center`};function gE(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`Arrow`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,pE,[e.breadcrumbs&&e.breadcrumbs.length>0?(H(),U(`ul`,mE,[(H(!0),U(V,null,z(e.breadcrumbs,(t,n)=>(H(),U(`li`,{key:n,class:`list-inline-item`},[G(`div`,hE,[n<e.breadcrumbs.length-1?(H(),W(s,{key:0,class:`d-flex align-items-center`,onClick:X(n=>e.setClassification(t),[`prevent`])},{default:P(()=>[n==0?(H(),W(o,{key:0,name:`house-home`,class:`me-1`,size:16})):J(``,!0),q(` `+j(t.name),1)]),_:2},1032,[`onClick`])):(H(),U(V,{key:1},[n==0?(H(),W(o,{key:0,name:`house-home`,class:`me-1`,size:16})):J(``,!0),G(`span`,null,j(t.name),1)],64)),n<e.breadcrumbs.length-1?(H(),W(c,{key:2,class:`ms-2`})):J(``,!0)])]))),128))])):J(``,!0)])):J(``,!0)],2)}var _E=Q(fE,[[`render`,gE]]),vE=L({components:{Icon:$h,Arrow:qb,Clickable:wm},props:{icon:{type:[String,Boolean],default:void 0},header:{type:String,default:void 0},horizontal:Boolean,stickyFooter:Boolean,useMarkup:{type:Boolean,default:!0},collapsed:{type:Boolean,default:!1}},setup(e){let t=M(!e.collapsed);return{isOpen:t,toggle:()=>t.value=!t.value}}}),yE={key:1},bE={class:`position-relative my-2`};function xE(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Arrow`),c=R(`Clickable`);return H(),U(`div`,{class:A([e.useMarkup?`card`:null])},[e.useMarkup&&(e.header||e.icon)?(H(),W(c,{key:0,class:A([`card-header d-flex align-items-center bg-light`,[!e.isOpen&&`border-bottom-0`]]),onClick:e.toggle},{default:P(()=>[e.icon?(H(),W(o,{key:0,name:e.icon,class:`me-2`},null,8,[`name`])):J(``,!0),e.header?(H(),U(`strong`,yE,j(e.header),1)):J(``,!0),K(s,{class:`d-flex align-items-center ms-auto`,size:24,dir:e.isOpen?`up`:`down`},null,8,[`dir`])]),_:1},8,[`class`,`onClick`])):J(``,!0),F(G(`div`,bE,[e.$slots.default?(H(),U(`div`,{key:0,class:A([e.useMarkup&&`card-body`,e.$slots.footer&&`pb-0`])},[B(e.$slots,`default`)],2)):J(``,!0),B(e.$slots,`list`),e.$slots.footer?(H(),U(`div`,{key:1,class:A([e.useMarkup&&`card-body`,e.useMarkup&&e.stickyFooter&&`position-sticky bottom-0 bg-body`])},[B(e.$slots,`footer`)],2)):J(``,!0)],512),[[Mo,e.isOpen]])],2)}var SE=Q(vE,[[`render`,xE]]),CE=L({name:`pis-catalogs-aliases-search-filters`,components:{Card:SE,AliasFilters:Ty},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{isReady:n,isWebComponent:r,componentName:i,store:a,t:o}=ym(t,e.instanceId,[Ud.ProductClassifications]),s=Y(()=>{var e;return((e=a.value)==null||(e=e.options.components)==null||(e=e.aliases)==null||(e=e.search)==null?void 0:e.filters)??{}});return{root:t,isReady:n,isWebComponent:r,componentName:i,componentOptions:s,store:a,visible:Y(()=>s.value.visible),t:o}}});function wE(e,t,n,r,i,a){let o=R(`AliasFilters`),s=R(`Card`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),W(s,{key:0,class:`mb-4`,icon:e.componentOptions.icon&&`folder-open`,header:e.t(`AliasFilters`),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{list:P(()=>[K(o)]),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])):J(``,!0)],2)}var TE=Q(CE,[[`render`,wE]]),EE=L({components:{Icon:$h},props:{icon:{type:String,default:void 0}}}),DE={class:`d-flex btn btn-link btn-sm`};function OE(e,t,n,r,i,a){let o=R(`Icon`);return H(),U(`button`,DE,[e.icon?(H(),W(o,{key:0,name:e.icon,class:`me-2`},null,8,[`name`])):J(``,!0),B(e.$slots,`default`)])}var kE=Q(EE,[[`render`,OE]]),AE=L({}),jE={class:`small text-muted mb-0 pis-message`};function ME(e,t,n,r,i,a){return H(),U(`p`,jE,[B(e.$slots,`default`)])}var NE=Q(AE,[[`render`,ME]]);function PE(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r&&r.push(n)||e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&r.splice(r.indexOf(n)>>>0,1)},emit:function(t,n){(e.get(t)||[]).slice().map(function(e){e(n)}),(e.get(`*`)||[]).slice().map(function(e){e(t,n)})}}}function FE(e,t,n){if(!n)return t;let r=e==null?void 0:e[n];if(r==null)throw Error(`Key is ${r} on item (keyField is '${n}')`);return r}function IE(e,t){return e.map((e,n)=>FE(e,n,t))}function LE(e,t,n){let r=[],i=[];for(let a=0;a<e.length;a++){let o=e[a],s=FE(o,a,t),c=n(o,a,s);r.push(s),i.push(typeof c==`number`&&c>0?c:null)}return{keys:r,sizes:i}}function RE(e,t,n){if(!e||e.keys.length!==t.length||e.sizes.length!==t.length)return!1;for(let r=0;r<t.length;r++)if(e.keys[r]!==FE(t[r],r,n))return!1;return!0}function zE(e,t,n){if(!RE(e,t,n))return{};let r={};for(let t=0;t<e.keys.length;t++){let n=e.sizes[t];typeof n==`number`&&n>0&&(r[e.keys[t]]=n)}return r}function BE(e,t){if(!e.length||t.length<=e.length)return 0;let n=e[0],r=t.indexOf(n);if(r<=0||r+e.length<t.length&&e.length>t.length-r)return 0;for(let n=0;n<e.length;n++)if(t[r+n]!==e[n])return 0;return r}function VE(e,t,n,r,i,a=0){let o=i??`start`;if(o===`nearest`){let i=n+r,o=e+t;return e>=n&&o<=i?null:e<n?e+a:o-r+a}return o===`end`?e+t-r+a:o===`center`?e+(t-r)/2+a:e+a}function HE(e,t,n,r){let i=null,a=null,o=null,s=!1,c=null,l=[],u=n.resizeObserver?()=>{}:n.onVscrollUpdate(g),d=Y(()=>{let t=N(e);if(n.vscrollData.simpleArray){if(t.index==null)throw Error(`index is required when using simple-array mode with dynamic item measurement`);return t.index}if(n.vscrollData.keyField in t.item)return t.item[n.vscrollData.keyField];throw Error(`keyField '${n.vscrollData.keyField}' not found in your item. You should set a valid keyField prop on your Scroller`)}),f=Y(()=>n.vscrollData.sizes[d.value]||0),p=Y(()=>N(e).active&&n.vscrollData.active);function m(){p.value?a!==d.value&&(a=d.value,i=null,o=null,b(d.value)):i=d.value}function h(){N(e).watchData&&!n.resizeObserver?c=I(()=>N(e).item,()=>{_()},{deep:!0}):c&&(c(),c=null)}function g({force:e}){!p.value&&e&&(o=d.value),(i===d.value||e||!f.value)&&m()}function _(){m()}function v(e){n.undefinedMap[e]&&n.undefinedSizeCount.value--,n.undefinedMap[e]=void 0}function y(e,t){if(n.vscrollData.sizes[e]){v(e);return}if(t){n.undefinedMap[e]||n.undefinedSizeCount.value++,n.undefinedMap[e]=!0;return}n.undefinedMap[e]&&(n.undefinedSizeCount.value--,n.undefinedMap[e]=!1)}function b(e){jn(()=>{if(d.value===e){let e=N(t);if(!e)return;let n=e.offsetWidth,r=e.offsetHeight;x(n,r)}a=null})}function x(e,t){let r=~~(n.direction.value===`vertical`?t:e);r&&f.value!==r&&S(r)}function S(t){var i,a;v(d.value),n.vscrollData.sizes[d.value]=t,N(e).emitResize&&((a=(i=N(r))==null?void 0:i.onResize)==null||a.call(i,d.value))}function C(){if(!n.resizeObserver||s)return;let e=N(t);e&&(n.resizeObserver.observe(e),e.$_vs_id=d.value,e.$_vs_onResize=T,s=!0)}function w(){if(!n.resizeObserver||!s)return;let e=N(t);e&&(n.resizeObserver.unobserve(e),e.$_vs_onResize=void 0,s=!1)}function T(e,t,n){d.value===e&&x(t,n)}l.push(I(()=>N(e).watchData,()=>{h()})),n.resizeObserver||l.push(I(()=>N(e).sizeDependencies,()=>{_()},{deep:!0})),l.push(I(d,(e,r)=>{let a=N(t);a&&(a.$_vs_id=e),v(r),y(e,p.value);let o=n.vscrollData.sizes[e];if(!o){i=e,_();return}v(e),s&&(n.vscrollData.sizes[e]=o)})),l.push(I(p,e=>{y(d.value,e),n.resizeObserver?e?C():w():e&&o===d.value&&m()})),h();function E(){p.value&&(m(),C())}function D(){u(),w(),v(d.value);let e=N(t);e&&(e.$_vs_id=void 0,e.$_vs_onResize=void 0),c&&(c(),c=null);for(let e of l)e();l.length=0}return{id:d,size:f,finalActive:p,updateSize:m,mount:E,unmount:D}}var UE={itemsLimit:1e3};function WE(e){return typeof window<`u`&&e===window}var GE=(()=>{if(typeof document>`u`)return`negative`;let e=document.createElement(`div`),t=document.createElement(`div`);e.style.width=`4px`,e.style.height=`1px`,e.style.overflow=`auto`,e.style.direction=`rtl`,t.style.width=`8px`,t.style.height=`1px`,e.appendChild(t),document.body.appendChild(e),e.scrollLeft=-1;let n=e.scrollLeft<0;return document.body.removeChild(e),n?`negative`:`default`})();function KE(e,t,n){return t!==`horizontal`||!n||WE(n)||getComputedStyle(n).direction!==`rtl`?e:GE===`negative`?-e:e}function qE(e,t,n){return KE(e,t,n)}function JE(e,t,n,r){let i=qE(n,t,e),a=!!(r!=null&&r.smooth);if(WE(e)){t===`vertical`?e.scrollTo({top:i,behavior:a?`smooth`:`auto`}):e.scrollTo({left:i,behavior:a?`smooth`:`auto`});return}if(typeof e.scrollTo==`function`){e.scrollTo(t===`vertical`?{top:i,behavior:a?`smooth`:`auto`}:{left:i,behavior:a?`smooth`:`auto`});return}t===`vertical`?e.scrollTop=i:e.scrollLeft=i}function YE(e,t,n){return n?t===`vertical`?window.innerHeight:window.innerWidth:t===`vertical`?e.clientHeight:e.clientWidth}var XE=/auto|scroll/;function ZE(e,t){return e.parentNode===null?t:ZE(e.parentNode,[...t,e])}function QE(e,t){return getComputedStyle(e,null).getPropertyValue(t)}function $E(e){return QE(e,`overflow`)+QE(e,`overflow-y`)+QE(e,`overflow-x`)}function eD(e){return XE.test($E(e))}function tD(e){if(!(e instanceof HTMLElement||e instanceof SVGElement))return;let t=ZE(e.parentNode,[]);for(let e=0;e<t.length;e+=1)if(t[e]instanceof Element&&eD(t[e]))return t[e];return document.scrollingElement||document.documentElement}var nD=!1;function rD(){return nD}if(typeof window<`u`){nD=!1;try{let e=Object.defineProperty({},"passive",{get(){nD=!0}});window.addEventListener(`test`,null,e)}catch{}}var iD=0;function aD(e){let t=e;t._vs_styleStamp++}function oD(e,t,n){let r=e==null?void 0:e[n];if(r==null)throw Error(`Key is ${r} on item (keyField is '${n}')`);return r}function sD(e,t,n,r,i){let a=M([]),o=M(0),s=M(!1),c=0,l=0,u=new Map,d=new Map,f=!1,p=0,m=0,h=!1,g=null,_=null,v=null,y=0,b=null,x=[],S=null,C=null,w=null,T=!1,E=new Set,D=M({}),ee=Y(()=>{let t=N(e);return t.items.length>0&&typeof t.items[0]!=`object`}),O=Y(()=>{let t=N(e);if(t.itemSize===null){let e={[-1]:{accumulator:0}},n=t.items,r=t.sizeField??`size`,i=t.minItemSize,a=D.value,o=1e4,s=0,c;for(let l=0,u=n.length;l<u;l++)c=a[ee.value?l:oD(n[l],l,t.keyField)]||n[l][r]||i,c<o&&(o=c),s+=c,e[l]={accumulator:s,size:c};return y=o,e}return[]}),te=Y(()=>a.value.filter(e=>e.nr.used).sort((e,t)=>e.nr.index-t.nr.index)),ne=Y(()=>{let t=N(e),n=ee.value?null:t.keyField;return LE(t.items,n,(e,n,r)=>t.itemSize==null?D.value[r]||(e==null?void 0:e[t.sizeField??`size`])||void 0:t.itemSize)});function re(t){let n=N(e);return D.value=zE(t,n.items,ee.value?null:n.keyField),Object.keys(D.value).length>0}function ie(e){let t=d.get(e);return t||(t=[],d.set(e,t)),t}function ae(e,t,n,r,i){let a=Wt({item:n,position:0,offset:0,nr:Qt({id:iD++,index:t,used:!0,key:r,type:i}),_vs_styleStamp:0});return e.push(a),a}function oe(e){let t=ie(e);if(t&&t.length){let e=t.pop();return e.nr.used=!0,aD(e),e}}function se(e){let t=e.nr.type;ie(t).push(e),e.nr.used=!1,e.position=-9999,aD(e),u.delete(e.nr.key)}function ce(){u.clear(),d.clear();for(let e=0,t=a.value.length;e<t;e++){let t=a.value[e];t&&se(t)}}function le(e){let t=-1;return t=requestAnimationFrame(()=>{E.delete(t),e()}),E.add(t),t}function ue(){for(let e of E)cancelAnimationFrame(e);E.clear()}function de(){g&&(clearTimeout(g),g=null),_&&(clearTimeout(_),_=null),v&&(clearTimeout(v),v=null),C&&(clearTimeout(C),C=null),w&&(clearTimeout(w),w=null)}function k(){var e;(e=i==null?void 0:i.onResize)==null||e.call(i),s.value&&Oe(!1)}function fe(){S&&!T&&be();let t=N(e);if(!f){if(f=!0,g)return;let e=()=>le(()=>{f=!1;let{continuous:e}=Oe(!1,!0);e||(_&&clearTimeout(_),_=setTimeout(fe,t.updateInterval+100))});e(),t.updateInterval&&(g=setTimeout(()=>{g=null,f&&e()},t.updateInterval))}}function pe(e,t){var n,r;s.value&&(e||t.boundingClientRect.width!==0||t.boundingClientRect.height!==0?((n=i==null?void 0:i.onVisible)==null||n.call(i),le(()=>{Oe(!1)})):(r=i==null?void 0:i.onHidden)==null||r.call(i))}function me(){let e=N(t),n=e?tD(e):void 0;return window.document&&(n===window.document.documentElement||n===window.document.body)?window:n||window}function he(){let t=N(n);return t?N(e).direction===`vertical`?t.scrollHeight:t.scrollWidth:0}function A(){let n=N(t);if(!n)return{start:0,end:0};let r=N(e),i=r.direction===`vertical`,a;if(r.pageMode){let e=n.getBoundingClientRect(),t=i?e.height:e.width,r=-(i?e.top:e.left),o=i?window.innerHeight:window.innerWidth;r<0&&(o+=r,r=0),r+o>t&&(o=t-r),a={start:r,end:r+o}}else a=i?{start:n.scrollTop,end:n.scrollTop+n.clientHeight}:{start:KE(n.scrollLeft,r.direction,n),end:KE(n.scrollLeft,r.direction,n)+n.clientWidth};return a}function ge(){let n=N(t);if(!n)return{start:0,end:0};if(N(e).direction===`vertical`){let e=KE(n.scrollLeft,`horizontal`,n);return{start:e,end:e+n.clientWidth}}return{start:n.scrollTop,end:n.scrollTop+n.clientHeight}}function _e(t){let n=N(e);if(n.itemSize!=null)return n.itemSize;let r=O.value[t];return(r==null?void 0:r.size)||Number(n.minItemSize)||0}function ve(t){var n;let r=N(e),i=r.gridItems||1;return t<=0?0:r.itemSize==null?((n=O.value[t-1])==null?void 0:n.accumulator)||0:Math.floor(t/i)*r.itemSize}function ye(t){let n=N(e),r=n.items.length,i=n.gridItems||1;if(!r)return 0;if(n.itemSize!=null){let e=Math.floor(t/n.itemSize)*i;return Math.min(Math.max(e,0),r-1)}let a=0,o=r-1,s=0;for(;a<=o;){let e=Math.floor((a+o)/2);ve(e)<=t?(s=e,a=e+1):o=e-1}return s}function be(){C&&(clearTimeout(C),C=null),S=null}function xe(){C&&clearTimeout(C),C=setTimeout(()=>{S=null,C=null},150)}function Se(e,t){if(!e.length){be();return}let n=Math.max(A().start-he(),0),r=Math.min(ye(n),e.length-1),i=e[r],a=t?i==null?void 0:i[t]:r;if(a==null){be();return}let o=he()+ve(r);S={key:a,offset:A().start-o}}function Ce(t){if(!S)return!1;let n=N(e),r=IE(t??n.items,ee.value?null:n.keyField).indexOf(S.key);if(r===-1)return be(),!1;let i=he()+ve(r)+S.offset,a=A().start;return Math.abs(i-a)<.5?!1:(T=!0,Ne(i),le(()=>{T=!1}),!0)}function j(){N(e).pageMode?we():Te()}function we(){b=me(),b.addEventListener(`scroll`,fe,rD()?{passive:!0}:!1),b.addEventListener(`resize`,k)}function Te(){b&&(b.removeEventListener(`scroll`,fe),b.removeEventListener(`resize`,k),b=null)}function Ee(e,t,n,r,i,a){let o=Math.ceil(e/t)*n,s=Math.max(0,Math.floor(i.start/n)),c=Math.min(Math.ceil(i.end/n),Math.ceil(e/t)),l=Math.max(0,Math.floor(a.start/r)),u=Math.min(Math.ceil(a.end/r),t),d=[];for(let n=s;n<c;n++){let r=n*t;for(let t=l;t<u;t++){let n=r+t;if(n>=e)break;d.push(n)}}let f=d[0]??0,p=d.at(-1)??-1;return{renderedIndices:d,startIndex:f,endIndex:p+1,visibleStartIndex:f,visibleEndIndex:p,totalSize:o}}function De(){let n=N(e);if(!n.gridItems||n.itemSize==null)return!1;let r=N(t);if(!r)return!1;let i=n.itemSecondarySize||n.itemSize,a=n.direction===`vertical`?r.clientWidth:r.clientHeight;return i*n.gridItems>a}function Oe(t,s=!1){var d,f;let g=N(e),_=g.itemSize,b=g.gridItems||1,x=g.itemSecondarySize||_,S=y,C=g.typeField,w=ee.value?null:g.keyField,T=g.items,E=T.length,D=O.value,te=u,ne=a.value,re=null,ie=null,le,ue,de,k,fe;if(!E)le=ue=k=fe=de=0;else if(h)le=k=0,ue=fe=Math.min(g.prerender,T.length),de=0;else{let e=A(),t=ge();if(s){let n=e.start-p;n<0&&(n=-n);let r=t.start-m;if(r<0&&(r=-r),!(_===null&&n>=S||_!==null&&n>=_)&&!(b>1&&_!=null&&r>=x))return{continuous:!0}}p=e.start,m=t.start;let i=g.buffer;e.start-=i,e.end+=i,t.start-=i,t.end+=i;let a=0,o=N(n);o&&(a=o.scrollHeight,e.start-=a);let c=N(r);if(c){let t=c.scrollHeight;e.end+=t}if(_===null){let t,n=0,r=E-1,i=~~(E/2),o;do o=i,t=D[i].accumulator,t<e.start?n=i:i<E-1&&D[i+1].accumulator>e.start&&(r=i),i=~~((n+r)/2);while(i!==o);for(i<0&&(i=0),le=i,de=D[E-1].accumulator,ue=i;ue<E&&D[ue].accumulator<e.end;ue++);for(ue===-1?ue=T.length-1:(ue++,ue>E&&(ue=E)),k=le;k<E&&a+D[k].accumulator<e.start;k++);for(fe=k;fe<E&&a+D[fe].accumulator<e.end;fe++);}else if(b>1){let n=Ee(E,b,_,x,e,t);re=n.renderedIndices,ie=new Set(re),le=n.startIndex,ue=n.endIndex,k=n.visibleStartIndex,fe=n.visibleEndIndex,de=n.totalSize}else{le=~~(e.start/_*b);let t=le%b;le-=t,ue=Math.ceil(e.end/_*b),k=Math.max(0,Math.floor((e.start-a)/_*b)),fe=Math.floor((e.end-a)/_*b),le<0&&(le=0),ue>E&&(ue=E),k<0&&(k=0),fe>E&&(fe=E),de=Math.ceil(E/b)*_}}ue-le>UE.itemsLimit&&ke(),o.value=de;let pe,me=le<=l&&ue>=c;if(!me||t)ce();else for(let e=0,t=ne.length;e<t;e++){let t=ne[e];if(t&&(pe=t,pe.nr.used)){let e=ie?ie.has(pe.nr.index):pe.nr.index>=le&&pe.nr.index<ue,t=_||D[pe.nr.index]&&D[pe.nr.index].size;(!e||!t)&&se(pe)}}let he,_e,ve=re??Array.from({length:Math.max(0,ue-le)},(e,t)=>le+t);for(let e of ve){if(!(_||D[e]&&D[e].size))continue;he=T[e];let t=w?he[w]:e;if(t==null)throw Error(`Key is ${t} on item (keyField is '${w}')`);if(pe=te.get(t),pe)pe.item!==he&&(pe.item=he),pe.nr.used||console.warn(`Expected existing view's used flag to be true, got ${pe.nr.used}`);else{if(_e=he[C],pe=oe(_e),pe){let n=pe.nr.index!==e||pe.nr.key!==t;pe.item=he,pe.nr.index=e,pe.nr.key=t,pe.nr.type!==_e&&console.warn(`Reused view's type does not match pool's type`),n&&aD(pe)}else pe=ae(ne,e,he,t,_e);te.set(t,pe)}_===null?(pe.position=((d=D[e-1])==null?void 0:d.accumulator)||0,pe.offset=0):(pe.position=Math.floor(e/b)*_,pe.offset=e%b*x)}return c=le,l=ue,g.emitUpdate&&((f=i==null?void 0:i.onUpdate)==null||f.call(i,le,ue,k,fe)),v&&clearTimeout(v),v=setTimeout(je,g.updateInterval+300),{continuous:me}}function ke(){throw w=setTimeout(()=>{w=null,console.warn(`It seems the scroller element isn't scrolling, so it tries to render all the items at once.`,`Scroller:`,N(t)),console.warn(`Make sure the scroller has a fixed height (or width) and 'overflow-y' (or 'overflow-x') set to 'auto' so it can scroll correctly and only render the items visible in the scroll viewport.`)}),Error(`Rendered items limit reached`)}function Ae(){if(De())return!1;let e=a.value.filter(({nr:e})=>e.used);for(let t=1;t<e.length;t++)if(e[t].nr.index!==e[t-1].nr.index+1)return!0;return!1}function je(){a.value.sort((e,t)=>e.nr.index-t.nr.index),Ae()&&(Oe(!1),v&&clearTimeout(v))}function Me(n,r){let i=N(e),a=N(t);if(!a)return;let o=Math.max(0,Math.min(n,i.items.length-1)),s=A().start,c=YE(a,i.direction,i.pageMode),l=VE(ve(o),_e(o),s,c,r==null?void 0:r.align,(r==null?void 0:r.offset)??0);if(l!=null&&(Ne(l,r),i.gridItems&&i.itemSize!=null)){let e=N(t);if(!e)return;let n=i.gridItems,a=i.itemSecondarySize||i.itemSize,s=o%n*a,c=i.direction===`vertical`?`horizontal`:`vertical`,l=VE(s,a,c===`horizontal`?KE(e.scrollLeft,`horizontal`,e):e.scrollTop,c===`horizontal`?e.clientWidth:e.clientHeight,r==null?void 0:r.align,(r==null?void 0:r.offset)??0);l!=null&&JE(e,c,l,r)}}function Ne(n,r){let i=N(e),a=N(t);if(a)if(i.pageMode){let e=tD(a),t=e.getBoundingClientRect(),o=a.getBoundingClientRect(),s=i.direction===`vertical`?`top`:`left`,c=tD(a)===document.documentElement||tD(a)===document.body?i.direction===`vertical`?window.scrollY:window.scrollX:KE(i.direction===`vertical`?e.scrollTop:e.scrollLeft,i.direction,e),l=o[s]-t[s];JE(e.tagName===`HTML`?window:e,i.direction,n+c+l,r)}else JE(a,i.direction,n,r)}let Pe=N(e);return x=IE(Pe.items,Pe.items.length>0&&typeof Pe.items[0]!=`object`?null:Pe.keyField),Pe.cache&&re(Pe.cache),Pe.prerender&&(h=!0,Oe(!1)),Pe.gridItems&&!Pe.itemSize&&console.error(`[vue-recycle-scroller] You must provide an itemSize when using gridItems`),kr(()=>{j(),jn(()=>{h=!1,Oe(!0),s.value=!0})}),Sr(()=>{let e=p;typeof e==`number`&&jn(()=>{Ne(e)})}),Mr(()=>{de(),ue(),Te()}),I(()=>N(e).cache,e=>{re(e),Oe(!0)}),I(()=>N(e).items,(t,n)=>{let r=N(e),i=ee.value?null:r.keyField,a=IE(t,i);r.shift&&BE(n?IE(n,i):x,a)>0?Se(n??[],i):be(),x=a,Ce(t),Oe(!0)}),I(()=>N(e).pageMode,()=>{j(),Oe(!1)}),I(O,()=>{Ce()&&xe(),Oe(!1)},{deep:!0}),I(()=>N(e).gridItems,()=>{Oe(!0)}),I(()=>N(e).itemSecondarySize,()=>{Oe(!0)}),{pool:a,visiblePool:te,totalSize:o,ready:s,sizes:O,simpleArray:ee,scrollToItem:Me,scrollToPosition:Ne,getScroll:A,findItemIndex:ye,getItemOffset:ve,getItemSize:_e,cacheSnapshot:ne,restoreCache:re,updateVisibleItems:Oe,handleScroll:fe,handleResize:k,handleVisibilityChange:pe,sortViews:je}}function cD(e){return e.item}function lD(e){return e._vs_styleStamp??0}var uD=[`position`,`top`,`left`,`transform`,`willChange`,`visibility`,`pointerEvents`];function dD(e){let t={};for(let n of uD)t[n]=e.style[n];return t}function fD(e,t){for(let n of uD)e.style[n]=t[n]??``}function pD(e,t,n,r){if(!(`view`in t)){fD(e,r);return}let i=n===`vertical`,a=e.tagName===`TR`,o=i?`translateY(${t.view.position}px) translateX(${t.view.offset}px)`:`translateX(${t.view.position}px) translateY(${t.view.offset}px)`;e.style.position=`absolute`,e.style.top=i&&a?`${t.view.position}px`:`0px`,e.style.left=!i&&a?`${t.view.position}px`:`0px`,e.style.transform=a?``:o,e.style.willChange=a?`unset`:`transform`,e.style.visibility=t.view.nr.used?`visible`:`hidden`,e.style.pointerEvents=t.view.nr.used?``:`none`}function mD(e){return`view`in e?{item:cD(e.view).item,active:e.view.nr.used,index:e.view.nr.index,watchData:e.watchData??!1,emitResize:e.emitResize??!1,sizeDependencies:e.sizeDependencies??null,onResize:e.onResize}:{watchData:!1,emitResize:!1,sizeDependencies:null,...e}}function hD(e,t,n,r){return n?r??null:(e==null?void 0:e[t])??null}function gD(e){let t=0,n={},r=PE(),i=!1,a,o=!1,s=[],c=null,l=null,u=new Set,d=Ut({active:!0,sizes:{},keyField:N(e).keyField,simpleArray:!1}),f=Y(()=>N(e).direction),p=Y(()=>N(N(e).el)),m=Y(()=>N(N(e).before)),h=Y(()=>N(N(e).after)),g=new Map;function _(e){let t=-1;return t=requestAnimationFrame(()=>{u.delete(t),e()}),u.add(t),t}function v(){for(let e of u)cancelAnimationFrame(e);u.clear()}typeof ResizeObserver<`u`&&(a=new ResizeObserver(e=>{_(()=>{if(Array.isArray(e)){for(let t of e)if(t.target&&t.target.$_vs_onResize){let e,n;if(t.borderBoxSize){let r=t.borderBoxSize[0];e=r.inlineSize,n=r.blockSize}else e=t.contentRect.width,n=t.contentRect.height;t.target.$_vs_onResize(t.target.$_vs_id,e,n)}}})}));let y={vscrollData:d,resizeObserver:a,direction:f,undefinedMap:n,undefinedSizeCount:{get value(){return t},set value(e){t=e}},onVscrollUpdate(e){let t=t=>{e(t)};return r.on(`vscroll:update`,t),()=>r.off(`vscroll:update`,t)}};Wn(`vscrollData`,d),Wn(`vscrollParent`,{get $_undefinedSizes(){return t},set $_undefinedSizes(e){t=e},get $_undefinedMap(){return n},set $_undefinedMap(e){n=e},$_events:r,direction:f}),Wn(`vscrollResizeObserver`,a),Wn(`vscrollMeasurementContext`,y),Wn(`vscrollAnchorRegistry`,{delete(e){g.delete(e)},set(e,t){g.set(e,t)}});let b=Y(()=>{let t=N(e);return t.items.length>0&&typeof t.items[0]!=`object`}),x=Y(()=>{let t=[],{items:r,keyField:i}=N(e),a=b.value,o=d.sizes,s=r.length;for(let e=0;e<s;e++){let s=r[e],c=a?e:s[i],l=o[c];typeof l>`u`&&!n[c]&&(l=0),t.push({item:s,id:c,size:l})}return t}),S=N(e);s=IE(S.items,b.value?null:S.keyField),S.cache&&(d.sizes=zE(S.cache,S.items,b.value?null:S.keyField));let C=Y(()=>{let t=N(e);return{items:x.value,keyField:`id`,direction:t.direction,itemSize:null,gridItems:void 0,itemSecondarySize:void 0,minItemSize:t.minItemSize,sizeField:`size`,typeField:`type`,buffer:t.buffer??200,pageMode:t.pageMode??!1,shift:!1,cache:t.cache,prerender:t.prerender??0,emitUpdate:t.emitUpdate??!1,updateInterval:t.updateInterval??0}});function w(){var t,n;ce(),(n=(t=N(e)).onResize)==null||n.call(t)}function T(){var t,n;r.emit(`vscroll:update`,{force:!1}),(n=(t=N(e)).onVisible)==null||n.call(t)}let E=sD(C,p,m,h,{onResize:w,onVisible:T,onHidden:()=>{var t,n;return(n=(t=N(e)).onHidden)==null?void 0:n.call(t)},onUpdate:(t,n,r,i)=>{var a,o;return(o=(a=N(e)).onUpdate)==null?void 0:o.call(a,t,n,r,i)}}),D=new WeakMap;function ee(){l!=null&&(cancelAnimationFrame(l),u.delete(l),l=null)}function O(){ee(),c=null}function te(){c==null||l!=null||(l=_(()=>{l=null,ae()}))}function ne(){let e=p.value;if(!e)return null;let t=e.getBoundingClientRect(),n=null;for(let[e,r]of g.entries()){if(!r.active||getComputedStyle(e).visibility===`hidden`)continue;let i=e.getBoundingClientRect();if(i.bottom<=t.top||i.top>=t.bottom)continue;let a=Math.max(i.top,t.top)-t.top;(!n||a<n.score)&&(n={key:r.id,offset:i.top-t.top,score:a})}return n}function re(e){let t=p.value;if(!t){O();return}let n=t.scrollTop,r=Math.min(E.findItemIndex(n),e.length-1),i=e[r];if(i==null){O();return}let a=ne();c={logicalKey:i,logicalOffset:n-E.getItemOffset(r),pendingKeys:new Set,stableFrames:0,visualKey:(a==null?void 0:a.key)??null,visualOffset:(a==null?void 0:a.offset)??0}}function ie(e){let t=p.value;return!t||Math.abs(t.scrollTop-e)<.5?!1:(o=!0,t.scrollTop=e,t.dispatchEvent(new Event(`scroll`)),_(()=>{o=!1}),!0)}function ae(){let e=c,t=p.value;if(!e||!t)return;let n=x.value.findIndex(t=>t.id===e.logicalKey);if(n===-1){O();return}let r=!1;if(r=ie(E.getItemOffset(n)+e.logicalOffset)||r,e.visualKey!=null)for(let[n,i]of g.entries()){if(!i.active||i.id!==e.visualKey||getComputedStyle(n).visibility===`hidden`)continue;let a=n.getBoundingClientRect().top-t.getBoundingClientRect().top-e.visualOffset;r=ie(t.scrollTop+a)||r;break}let i=!0;for(let t of e.pendingKeys)if(!(typeof d.sizes[t]==`number`&&d.sizes[t]>0)){i=!1;break}if(!r&&i){if(e.stableFrames++,e.stableFrames>=2){O();return}}else e.stableFrames=0;te()}function oe(t,n,r,i){let a=ke(),o=nn(n),s=nn(r),c=nn({onResize:r.onResize}),l=nn(t),u=a.run(()=>(I(()=>{let t=o.value;if(!(`view`in t))return{active:s.value.active,direction:f.value,id:hD(s.value.item,N(e).keyField,d.simpleArray,s.value.index),legacy:!0};let{view:n}=t;return{active:n.nr.used,direction:f.value,id:cD(n).id,legacy:!1,position:n.position,offset:n.offset,styleStamp:lD(n)}},()=>{let t=l.value;if(t){let n=o.value,r=`view`in n?cD(n.view).id:hD(s.value.item,N(e).keyField,d.simpleArray,s.value.index);r!=null&&g.set(t,{active:s.value.active&&d.active,id:r}),pD(t,o.value,f.value,i)}},{immediate:!0}),HE(s,l,y,c)));u.mount(),D.set(t,{binding:o,scope:a,options:s,callbacks:c,el:l,controller:u,restoreStyles:i})}let se={mounted(e,t){let n=dD(e);oe(e,t.value,mD(t.value),n)},updated(e,t){let n=D.get(e),r=mD(t.value);if(!n){let n=dD(e);oe(e,t.value,r,n);return}n.binding.value=t.value,n.options.value=r,n.callbacks.value={onResize:r.onResize},n.el.value=e,pD(e,t.value,f.value,n.restoreStyles)},unmounted(e){let t=D.get(e);t&&(t.controller.unmount(),t.scope.stop(),fD(e,t.restoreStyles),g.delete(e),D.delete(e))}};function ce(e=!1){(e||b.value)&&(d.sizes={}),r.emit(`vscroll:update`,{force:!0})}function le(e,t){E.scrollToItem(e,t)}function ue(t){let n=N(e);return d.sizes=zE(t,n.items,b.value?null:n.keyField),E.restoreCache(t)}function de(t,n){let r=N(e),i=b.value?n??r.items.indexOf(t):t[r.keyField];return d.sizes[i]||0}function k(){let e=p.value;e&&(i||(i=!0,jn(()=>{e.scrollTop=e.scrollHeight+5e3;let n=()=>{e.scrollTop=e.scrollHeight+5e3,_(()=>{e.scrollTop=e.scrollHeight+5e3,t===0?i=!1:_(n)})};_(n)})))}function fe(){c&&!o&&O()}return I(()=>N(e).items,(t,n)=>{let r=N(e),i=b.value?null:r.keyField,a=IE(t,i);if(r.shift){let e=n?IE(n,i):s,t=BE(e,a);t>0?(re(e),c&&(c.pendingKeys=new Set(a.slice(0,t)),c.stableFrames=0,jn(()=>{c&&ae()}))):O()}else O();s=a,ce()},{flush:`sync`}),I(()=>N(e).cache,e=>{e&&ue(e)}),I(b,e=>{d.simpleArray=e},{immediate:!0}),I(()=>N(e).direction,()=>{O(),ce(!0)}),I(p,(e,t)=>{t==null||t.removeEventListener(`scroll`,fe),e==null||e.addEventListener(`scroll`,fe)},{immediate:!0}),I(x,(t,n)=>{let r=p.value;if(!r)return;if(c){ae();return}let i=r.scrollTop,a=N(e),o=0,s=0,l=Math.min(t.length,n.length);for(let e=0;e<l&&!(o>=i);e++)o+=n[e].size||a.minItemSize,s+=t[e].size||a.minItemSize;let u=s-o;u!==0&&(r.scrollTop+=u)},{flush:`post`}),Sr(()=>{d.active=!0}),Cr(()=>{d.active=!1}),Nr(()=>{var e;ee(),v(),(e=p.value)==null||e.removeEventListener(`scroll`,fe),r.all.clear()}),{vscrollData:d,itemsWithSize:x,resizeObserver:a,measurementContext:y,vDynamicScrollerItem:se,...E,simpleArray:b,forceUpdate:ce,scrollToItem:le,restoreCache:ue,getItemSize:de,scrollToBottom:k,onScrollerResize:w,onScrollerVisible:T}}var _D=new WeakMap;function vD(e){return typeof e==`function`?{callback:e,observer:null,intersection:void 0,visible:null}:{callback:e.callback,observer:null,intersection:e.intersection,visible:null}}function yD(e,t){bD(e);let n=vD(t.value);if(_D.set(e,n),typeof IntersectionObserver>`u`){let t=e.getBoundingClientRect();n.visible=!0,n.callback(!0,{boundingClientRect:t});return}n.observer=new IntersectionObserver(e=>{let t=e[0],r=!!(t!=null&&t.isIntersecting);n.visible!==null&&n.visible===r||(n.visible=r,n.callback(r,t))},n.intersection),n.observer.observe(e)}function bD(e){let t=_D.get(e);t!=null&&t.observer&&(t.observer.disconnect(),t.observer=null)}var xD={mounted(e,t){yD(e,t)},updated(e,t){t.value!==t.oldValue&&yD(e,t)},unmounted(e){bD(e),_D.delete(e)}},SD=L({__name:`ItemView`,props:{view:{},itemTag:{}},setup(e){let t=e;return(e,n)=>(H(),W(Vr(t.itemTag),{class:`vue-recycle-scroller__item-view`},{default:P(()=>[B(e.$slots,`default`,{item:t.view.item,index:t.view.nr.index,active:t.view.nr.used})]),_:3}))}}),CD=((e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n})(L({__name:`ResizeObserver`,emits:[`notify`],setup(e,{emit:t}){let n=t,r=M(),i=null,a=null;function o(){n(`notify`)}return kr(()=>{var e;let t=(e=r.value)==null?void 0:e.parentElement;if(t){if(typeof ResizeObserver<`u`){i=new ResizeObserver(()=>{o()}),i.observe(t);return}a=()=>o(),window.addEventListener(`resize`,a)}}),Mr(()=>{i&&(i.disconnect(),i=null),a&&(window.removeEventListener(`resize`,a),a=null)}),(e,t)=>(H(),U(`div`,{ref_key:`el`,ref:r,class:`vue-recycle-scroller__resize-observer`,"aria-hidden":`true`},null,512))}}),[[`__scopeId`,`data-v-08cc04ab`]]),wD=L({__name:`RecycleScroller`,props:{items:{},keyField:{default:`id`},direction:{default:`vertical`},listTag:{default:`div`},itemTag:{default:`div`},itemSize:{default:null},gridItems:{default:void 0},itemSecondarySize:{default:void 0},minItemSize:{default:null},sizeField:{default:`size`},typeField:{default:`type`},buffer:{default:200},pageMode:{type:Boolean,default:!1},shift:{type:Boolean,default:!1},cache:{default:void 0},prerender:{default:0},emitUpdate:{type:Boolean,default:!1},disableTransform:{type:Boolean,default:!1},updateInterval:{default:0},skipHover:{type:Boolean,default:!1},listClass:{default:``},itemClass:{default:``}},emits:[`resize`,`visible`,`hidden`,`update`,`scrollStart`,`scrollEnd`],setup(e,{expose:t,emit:n}){let r=e,i=n,a=xD,o=M(),s=M(),c=M(),l=M(null),{pool:u,visiblePool:d,totalSize:f,ready:p,scrollToItem:m,scrollToPosition:h,getScroll:g,findItemIndex:_,getItemOffset:v,getItemSize:y,cacheSnapshot:b,restoreCache:x,updateVisibleItems:S,handleScroll:C,handleResize:w,handleVisibilityChange:T}=sD(r,o,s,c,{onResize:()=>i(`resize`),onVisible:()=>i(`visible`),onHidden:()=>i(`hidden`),onUpdate:(e,t,n,a)=>{i(`update`,e,t,n,a),n<=0&&i(`scrollStart`),a>=r.items.length-1&&i(`scrollEnd`)}});function E(e){l.value=e}function D(){l.value=null}let ee=Y(()=>{let e={[r.direction===`vertical`?`minHeight`:`minWidth`]:`${f.value}px`};if(r.gridItems&&r.itemSize!=null){let t=(r.itemSecondarySize||r.itemSize)*r.gridItems;e[r.direction===`vertical`?`minWidth`:`minHeight`]=`${t}px`}return e});return t({el:o,visiblePool:d,scrollToItem:m,scrollToPosition:h,getScroll:g,findItemIndex:_,getItemOffset:v,getItemSize:y,cacheSnapshot:b,restoreCache:x,updateVisibleItems:S}),(e,t)=>F((H(),U(`div`,{ref_key:`el`,ref:o,class:A([`vue-recycle-scroller`,{"grid-mode":r.gridItems,ready:on(p),"page-mode":r.pageMode,[`direction-${r.direction}`]:!0}]),onScrollPassive:t[0]||(t[0]=(...e)=>on(C)&&on(C)(...e))},[e.$slots.before?(H(),U(`div`,{key:0,ref_key:`before`,ref:s,class:`vue-recycle-scroller__slot`},[B(e.$slots,`before`)],512)):J(``,!0),(H(),W(Vr(r.listTag),{style:k(ee.value),class:A([`vue-recycle-scroller__item-wrapper`,r.listClass])},{default:P(()=>[(H(!0),U(V,null,z(on(u),t=>(H(),W(SD,Oa({key:t.nr.id,view:t,"item-tag":r.itemTag,style:on(p)?[r.disableTransform?{[r.direction===`vertical`?`top`:`left`]:`${t.position}px`,willChange:`unset`}:{transform:`translate${r.direction===`vertical`?`Y`:`X`}(${t.position}px) translate${r.direction===`vertical`?`X`:`Y`}(${t.offset}px)`},{width:r.gridItems?`${r.direction===`vertical`&&r.itemSecondarySize||r.itemSize}px`:void 0,height:r.gridItems?`${r.direction===`horizontal`&&r.itemSecondarySize||r.itemSize}px`:void 0,visibility:t.nr.used?`visible`:`hidden`}]:null,class:[`vue-recycle-scroller__item-view`,[r.itemClass,{hover:!r.skipHover&&l.value===t.nr.key}]]},qr(r.skipHover?{}:{mouseenter:()=>{E(t.nr.key)},mouseleave:()=>{D()}})),{default:P(t=>[B(e.$slots,`default`,Oa({ref_for:!0},t))]),_:2},1040,[`view`,`item-tag`,`style`,`class`]))),128)),r.items.length===0?B(e.$slots,`empty`,{key:0}):J(``,!0)]),_:3},8,[`style`,`class`])),e.$slots.after?(H(),U(`div`,{key:1,ref_key:`after`,ref:c,class:`vue-recycle-scroller__slot`},[B(e.$slots,`after`)],512)):J(``,!0),K(CD,{onNotify:on(w)},null,8,[`onNotify`])],34)),[[on(a),on(T)]])}}),TD=L({inheritAttrs:!1,__name:`DynamicScroller`,props:{items:{},keyField:{default:`id`},direction:{default:`vertical`},listTag:{default:`div`},itemTag:{default:`div`},minItemSize:{},shift:{type:Boolean,default:!1},cache:{default:void 0}},emits:[`resize`,`visible`],setup(e,{expose:t,emit:n}){let r=e,i=n,a=M(),o=Y(()=>{var e;let t=(e=a.value)==null?void 0:e.el;return t&&typeof t==`object`&&`value`in t?t.value:t}),{itemsWithSize:s,forceUpdate:c,scrollToItem:l,scrollToPosition:u,findItemIndex:d,getItemOffset:f,getItemSize:p,cacheSnapshot:m,restoreCache:h,scrollToBottom:g,onScrollerResize:_,onScrollerVisible:v}=gD(Y(()=>({items:r.items,keyField:r.keyField,direction:r.direction,minItemSize:r.minItemSize,shift:r.shift,cache:r.cache,el:o.value,onResize:()=>i(`resize`),onVisible:()=>i(`visible`)})));function y(e,t,n){return{item:e.item,index:t,active:n,itemWithSize:e}}return t({scrollToItem:l,scrollToPosition:u,findItemIndex:d,getItemOffset:f,scrollToBottom:g,getItemSize:p,cacheSnapshot:m,restoreCache:h,forceUpdate:c}),(e,t)=>(H(),W(wD,Oa({ref_key:`scroller`,ref:a,items:on(s),"min-item-size":r.minItemSize,direction:r.direction,cache:r.cache,"key-field":`id`,"list-tag":r.listTag,"item-tag":r.itemTag},e.$attrs,{onResize:on(_),onVisible:on(v)}),Gr({default:P(({item:t,index:n,active:r})=>[B(e.$slots,`default`,ge(Ca(y(t,n,r))))]),empty:P(()=>[B(e.$slots,`empty`)]),_:2},[e.$slots.before?{name:`before`,fn:P(()=>[B(e.$slots,`before`)]),key:`0`}:void 0,e.$slots.after?{name:`after`,fn:P(()=>[B(e.$slots,`after`)]),key:`1`}:void 0]),1040,[`items`,`min-item-size`,`direction`,`cache`,`list-tag`,`item-tag`,`onResize`,`onVisible`]))}});function ED(e,t,n){let r=Gn(`vscrollMeasurementContext`),i=Gn(`vscrollAnchorRegistry`,null),a=HE(e,t,r,n);return kr(()=>{a.mount()}),i&&I([a.id,a.finalActive,()=>N(t)],([e,t,n],[r,a,o])=>{o&&o!==n&&i.delete(o),n&&i.set(n,{active:t,id:e})},{immediate:!0}),Mr(()=>{let e=N(t);i&&e&&i.delete(e),a.unmount()}),{id:a.id,size:a.size,finalActive:a.finalActive,updateSize:a.updateSize}}var DD=L({components:{DynamicScroller:TD,DynamicScrollerItem:L({__name:`DynamicScrollerItem`,props:{item:{},watchData:{type:Boolean,default:!1},active:{type:Boolean},index:{default:void 0},sizeDependencies:{default:null},emitResize:{type:Boolean,default:!1},tag:{default:`div`}},emits:[`resize`],setup(e,{emit:t}){let n=e,r=t,i=M();return ED(n,i,{onResize:e=>r(`resize`,e)}),(e,t)=>(H(),W(Vr(n.tag),{ref_key:`el`,ref:i},{default:P(()=>[B(e.$slots,`default`)]),_:3},512))}}),RecycleScroller:wD},props:{items:{type:Array,required:!0},height:{type:String,default:`60vh`},keyField:{type:String,default:`name`},fixedItemSize:{type:Number,default:void 0}}});function OD(e,t,n,r,i,a){let o=R(`RecycleScroller`),s=R(`DynamicScrollerItem`),c=R(`DynamicScroller`);return e.items.length>200&&e.fixedItemSize!==void 0?(H(),W(o,{key:0,class:`pis-scroll`,"key-field":e.keyField,style:k({maxHeight:e.height}),items:e.items,"item-size":e.fixedItemSize,buffer:96,"skip-hover":!0},{default:P(t=>[t?B(e.$slots,`item`,{item:t.item},void 0,void 0,0):J(``,!0)]),_:3},8,[`key-field`,`style`,`items`,`item-size`])):e.items.length>200?(H(),W(c,{key:1,class:`pis-scroll`,"key-field":e.keyField,style:k({maxHeight:e.height}),items:e.items,"min-item-size":50,buffer:96,"skip-hover":!0},{default:P(({item:t,index:n,active:r})=>[K(s,{item:t,active:r,"size-dependencies":[t.name],"data-index":n},{default:P(()=>[B(e.$slots,`item`,{item:t})]),_:2},1032,[`item`,`active`,`size-dependencies`,`data-index`])]),_:3},8,[`key-field`,`style`,`items`])):(H(),U(`div`,{key:2,class:`pis-scroll`,style:k([{"overflow-y":`auto`},{maxHeight:e.height}])},[(H(!0),U(V,null,z(e.items,(t,n)=>B(e.$slots,`item`,{item:t},void 0,void 0,n)),128))],4))}var kD=Q(DD,[[`render`,OD]]),AD=L({components:{Badge:ky,Clickable:wm,ScrollableList:kD},props:{items:{type:Array,required:!0},currentAttributeCode:{type:String,default:void 0},height:{type:String,default:void 0}},emits:[`item-click`],computed:{isReady(){return this.$props.items&&this.$props.items.length}},methods:{clickableClass(e){return this.$props.currentAttributeCode===e.attributeCode&&`active`}}}),jD={class:`d-flex align-items-center justify-content-between`},MD=[`title`];function ND(e,t,n,r,i,a){let o=R(`Badge`),s=R(`Clickable`),c=R(`ScrollableList`),l=Hr(`safe-html`);return e.isReady?(H(),W(c,{key:0,class:`list-group list-group-flush`,"key-field":`attributeCode`,items:e.items,height:e.height,"fixed-item-size":36},{item:P(({item:t})=>[K(s,{class:A([`list-group-item border-0 d-block`,[e.clickableClass(t)]]),onClick:X(n=>e.$emit(`item-click`,t),[`prevent`])},{default:P(()=>[G(`div`,jD,[F(G(`div`,{class:A([`pis-label me-2`,e.items.length>200&&`flex-grow-1 text-truncate`]),style:k({minWidth:e.items.length>200?`0`:void 0}),title:e.items.length>200?t.attributeName:void 0},null,14,MD),[[l,t.attributeNameHtml]]),G(`div`,null,[K(o,{class:`ms-auto`,textContent:j(t.hitCount)},null,8,[`textContent`])])])]),_:2},1032,[`class`,`onClick`])]),_:1},8,[`items`,`height`])):J(``,!0)}var PD=L({components:{Modal:Qy,Badge:ky,Spinner:My,Btn:Iy,LinkSecondary:kE,FormInputClearable:Mb,ScrollableList:kD,Message:NE,FiltersList:Q(AD,[[`render`,ND]]),Arrow:qb},props:{show:Boolean,title:{type:String,required:!0},isMobile:Boolean,t:{type:Function,required:!0},filtersAll:{type:Array,default:void 0},filtersPromoted:{type:Array,default:void 0},filtersAdditional:{type:Array,default:void 0},filtersLoading:Boolean,filtersFetched:Map,filtersModel:{type:Object,default:void 0},filteredResultCount:{type:Number,default:void 0},filteredResultCountLoading:Boolean,fetchFilterValues:{type:Function,required:!0},clearFiltersModelFromEmptyValues:{type:Function,default:void 0},resetFilterOnOpen:{type:Boolean,default:!1},availableFiltersLabelSuffix:{type:String,default:``}},emits:[`update:show`,`value-change`,`apply-filters`,`clear`],setup(e,{emit:t}){let n=M(!1),r=M(null),i=M(!1),a=M(``),o=M(``),s=M(),c=0,l=Y(()=>{var t;return(t=e.filtersAll)==null?void 0:t.find(({attributeCode:e})=>r.value===e)}),u=Y(()=>{if(a.value.length){var t;let n=a.value.toLowerCase();return(t=e.filtersAdditional)==null?void 0:t.filter(({attributeName:e})=>e.toLowerCase().includes(n))}return e.filtersAdditional}),d=Y(()=>{var t;if((t=e.filtersPromoted)!=null&&t.length&&a.value.length){var n;let t=a.value.toLowerCase();return(n=e.filtersPromoted)==null?void 0:n.filter(({attributeName:e})=>e.toLowerCase().includes(t))}return e.filtersPromoted}),f=Y(()=>{var t;if(r.value&&(t=e.filtersFetched)!=null&&t.has(r.value)){var n;return(n=e.filtersFetched)==null?void 0:n.get(r.value)}return null});I(()=>e.show,t=>{if(t===!0&&e.resetFilterOnOpen){var n,i;(n=e.filtersAll)!=null&&n.length&&!((i=e.filtersAll)!=null&&i.some(({attributeCode:e})=>e===r.value))?x():p()}});let p=()=>{if(r.value&&e.show){var t;(t=e.filtersFetched)!=null&&t.has(r.value)||e.fetchFilterValues([r.value])}},m=Y(()=>{if(f.value)if(o.value.length){var e;let t=o.value.toLowerCase();return(e=f.value)==null?void 0:e.filter(({text:e})=>e.toLowerCase().includes(t))}else return f.value;return null}),h=async({attributeCode:t})=>{var i;if(!t)return;let a=++c;if(o.value=``,r.value=t,(i=e.filtersFetched)!=null&&i.has(t)){n.value=!1;return}n.value=!0;try{await e.fetchFilterValues([t])}finally{a===c&&(n.value=!1)}},g=(e,n,r)=>{i.value=!0,t(`value-change`,{attributeCode:n,filterValueName:r,value:ly(e)[0].checked})},_=sp(e=>a.value=e,200),v=()=>a.value=``,y=sp(e=>o.value=e,200),b=()=>o.value=``,x=()=>{let e=++c;n.value=!1,setTimeout(()=>{e===c&&(r.value=null)},50)},S=()=>{c++,n.value=!1,r.value=null,t(`clear`)},C=M(`300px`),w=M(`300px`);return{areFiltersDirty:i,currentFilterData:l,currentFilterValues:f,filterValuesLoading:n,filtersSectionHeight:C,filtersSectionRightHeight:w,applyFilterNameSearch:_,currentFilterAttrCode:r,applyFilterValueSearch:y,filtersPromotedSearched:d,filterValueSearchPhrase:o,filtersAdditionalSearched:u,currentFilterValuesSearched:m,modalFooter:s,clear:S,openFilter:h,onValueChange:g,resetFilterNameSearch:v,criterionValueKey:lu,resetFilterValueSearch:b,resetCurrentFilterAttrCode:x,modalResize:t=>{var n;let r=t.height-110;(n=e.filtersPromoted)!=null&&n.length?C.value=r/2-20+`px`:C.value=r+`px`,w.value=r+`px`},handleModalClose:r=>{r||(c++,n.value=!1,e.clearFiltersModelFromEmptyValues&&e.clearFiltersModelFromEmptyValues()),t(`update:show`,r)}}}}),FD={class:`row gx-3 gy-3`,style:{height:`calc(100vh - 200px)`,"max-height":`800px`}},ID={key:0,class:`h-100 d-flex align-items-center justify-content-center`},LD={key:0,class:`mb-3`},RD={key:1},zD={key:0,class:`text-center py-4`},BD={key:1},VD={key:0},HD={class:`mb-4`},UD={class:`list-group-item border-0`},WD={class:`form-check d-flex align-items-start`},GD=[`checked`,`name`,`onInput`],KD=[`title`,`textContent`],qD={key:1,class:`pis-message`},JD={key:1,class:`pis-message pis-message-error`},YD={key:2,class:`h-100 d-flex align-items-center`},XD={ref:`modalFooter`,class:`w-100 d-flex align-items-center justify-content-center`};function ZD(e,t,n,r,i,a){let o=R(`Spinner`),s=R(`FormInputClearable`),c=R(`FiltersList`),l=R(`Message`),u=R(`Badge`),d=R(`ScrollableList`),f=R(`LinkSecondary`),p=R(`Arrow`),m=R(`Btn`),h=R(`Modal`),g=Hr(`safe-html`);return H(),W(h,{show:e.show,title:e.t(`Filters`,!0),xl:``,"onUpdate:show":e.handleModalClose,onResize:e.modalResize},{footer:P(()=>[G(`div`,XD,[K(f,{icon:`stop-not-allowed`,class:`ext-clear`,onClick:e.clear},{default:P(()=>[q(j(e.t(`ClearFilters`,!0)),1)]),_:1},8,[`onClick`]),e.isMobile&&e.currentFilterAttrCode?(H(),W(m,{key:0,class:`ms-4 ext-reset`,onClick:X(e.resetCurrentFilterAttrCode,[`prevent`])},{default:P(()=>[K(p,{dir:`left`,class:`me-2`}),q(` `+j(e.t(`ApproveFilterValuesSelected`)),1)]),_:1},8,[`onClick`])):J(``,!0),!e.isMobile||!e.currentFilterAttrCode?(H(),W(m,{key:1,icon:`check-mark-circle`,class:`ms-4 ext-apply`,disabled:e.areFiltersDirty!==!0||e.filteredResultCount===0,"is-loading":e.filteredResultCountLoading,onClick:t[0]||(t[0]=X(t=>e.$emit(`apply-filters`),[`prevent`]))},{default:P(()=>[e.filteredResultCount===null?(H(),U(V,{key:0},[q(j(e.t(`ShowResults`,!0)),1)],64)):e.filteredResultCount===0?(H(),U(V,{key:1},[q(j(e.t(`NoFilteringResultsFound`)),1)],64)):(H(),U(V,{key:2},[q(j(e.t(`ShowNResults`,!0,[e.filteredResultCount||0])),1)],64))]),_:1},8,[`disabled`,`is-loading`])):J(``,!0)],512)]),default:P(()=>{var t,n,r,i,a,f,p,m;return[G(`div`,FD,[F(G(`div`,{class:A({"col-6":!e.isMobile,"col-12":e.isMobile})},[e.filtersLoading?(H(),U(`div`,ID,[K(o)])):(H(),U(V,{key:1},[K(s,{placeholder:e.t(`FindFilterAttribute`),class:`mb-4`,"onUpdate:modelValue":e.applyFilterNameSearch,onClear:e.resetFilterNameSearch},null,8,[`placeholder`,`onUpdate:modelValue`,`onClear`]),(t=e.filtersPromoted)!=null&&t.length?(H(),U(`div`,LD,[G(`p`,null,[G(`strong`,null,j(e.t(`FiltersPromoted`)),1)]),(n=e.filtersPromotedSearched)!=null&&n.length?(H(),W(c,{key:0,height:e.filtersSectionHeight,items:e.filtersPromotedSearched,"current-attribute-code":(r=e.currentFilterData)==null?void 0:r.attributeCode,onItemClick:e.openFilter},null,8,[`height`,`items`,`current-attribute-code`,`onItemClick`])):(H(),W(l,{key:1},{default:P(()=>[q(j(e.t(`NoFiltersSearchFound`)),1)]),_:1}))])):J(``,!0),(i=e.filtersAdditional)!=null&&i.length?(H(),U(`div`,RD,[G(`p`,null,[G(`strong`,null,j((a=e.filtersPromoted)!=null&&a.length?e.t(`AdditionalFilters`):e.t(`AvailableFilters`))+j(e.availableFiltersLabelSuffix),1)]),(f=e.filtersAdditionalSearched)!=null&&f.length?(H(),W(c,{key:0,height:e.filtersSectionHeight,items:e.filtersAdditionalSearched,"current-attribute-code":(p=e.currentFilterData)==null?void 0:p.attributeCode,onItemClick:e.openFilter},null,8,[`height`,`items`,`current-attribute-code`,`onItemClick`])):(H(),W(l,{key:1},{default:P(()=>[q(j(e.t(`NoFiltersSearchFound`)),1)]),_:1}))])):J(``,!0)],64))],2),[[Mo,!e.isMobile||!(e.currentFilterAttrCode||e.filterValuesLoading)]]),F(G(`div`,{class:A({"col-6":!e.isMobile,"col-12":e.isMobile})},[e.filterValuesLoading?(H(),U(`div`,zD,[K(o)])):e.currentFilterAttrCode?(H(),U(`div`,BD,[e.currentFilterValues&&e.currentFilterData?(H(),U(`div`,VD,[G(`div`,HD,[K(s,{placeholder:e.t(`FindFilterValue`),class:`mb-4`,"onUpdate:modelValue":e.applyFilterValueSearch,onClear:e.resetFilterValueSearch},null,8,[`placeholder`,`onUpdate:modelValue`,`onClear`])]),G(`p`,null,[F(G(`strong`,null,null,512),[[g,e.currentFilterData.attributeNameHtml]])]),(m=e.currentFilterValuesSearched)!=null&&m.length&&e.filtersModel?(H(),W(d,{key:0,class:`list-group list-group-flush`,items:e.currentFilterValuesSearched,height:e.filtersSectionRightHeight,"key-field":`_key`,"fixed-item-size":36},{item:P(({item:t})=>{var n;return[G(`label`,UD,[G(`div`,WD,[G(`input`,{type:`checkbox`,class:`form-check-input me-2 flex-shrink-0`,checked:(n=e.filtersModel[e.currentFilterData.attributeCode])==null?void 0:n[e.criterionValueKey(t.value)],name:t.text,onInput:n=>{var r;return e.onValueChange(n,((r=e.currentFilterData)==null?void 0:r.attributeCode)||``,e.criterionValueKey(t.value))}},null,40,GD),G(`span`,{class:`form-check-label user-select-none text-truncate`,title:t.text,textContent:j(t.text)},null,8,KD),K(u,{class:`ms-auto`,textContent:j(t.hitCount)},null,8,[`textContent`])])])]}),_:1},8,[`items`,`height`])):(H(),U(`p`,qD,j(e.t(`NoFilterValuesSearchFound`)),1))])):(H(),U(`p`,JD,j(e.t(`NoFilterValues`)),1))])):(H(),U(`div`,YD,[K(l,null,{default:P(()=>[q(j(e.t(`SelectFilter`)),1)]),_:1})]))],2),[[Mo,!e.isMobile||e.currentFilterAttrCode||e.filterValuesLoading]])])]}),_:1},8,[`show`,`title`,`onUpdate:show`,`onResize`])}var QD=Q(PD,[[`render`,ZD]]),$D=L({components:{FiltersNavigatorModalBase:QD},inheritAttrs:!1,props:{show:Boolean,title:{type:String,required:!0},isMobile:Boolean,t:{type:Function,required:!0},filtersAll:{type:Array,default:void 0},filtersPromoted:{type:Array,default:void 0},filtersAdditional:{type:Array,default:void 0},filtersFetched:Map,filtersModel:{type:Object,default:void 0},filteredResultCount:{type:Number,default:void 0},filteredResultCountLoading:Boolean,fetchFilterValues:{type:Function,required:!0},clearFiltersModelFromEmptyValues:{type:Function,default:void 0}}});function eO(e,t,n,r,i,a){let o=R(`FiltersNavigatorModalBase`);return H(),W(o,Oa(e.$attrs,{show:e.show,title:e.title,"is-mobile":e.isMobile,t:e.t,"filters-all":e.filtersAll,"filters-promoted":e.filtersPromoted,"filters-additional":e.filtersAdditional,"filters-fetched":e.filtersFetched,"filters-model":e.filtersModel,"filtered-result-count":e.filteredResultCount,"filtered-result-count-loading":e.filteredResultCountLoading,"fetch-filter-values":e.fetchFilterValues,"clear-filters-model-from-empty-values":e.clearFiltersModelFromEmptyValues,"reset-filter-on-open":``}),null,16,[`show`,`title`,`is-mobile`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-fetched`,`filters-model`,`filtered-result-count`,`filtered-result-count-loading`,`fetch-filter-values`,`clear-filters-model-from-empty-values`])}var tO=Q($D,[[`render`,eO]]),nO=L({name:`pis-catalogs-products-search-filters`,components:{Spinner:My,Badge:ky,LinkSecondary:kE,Btn:Iy,Clickable:wm,Arrow:qb,Card:SE,FiltersNavigator:tO,ScrollableList:kD,Message:NE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=M(!1),{componentName:i,isReady:a,isWebComponent:o,instance:s,store:c,t:l,useProductsFilters:u}=ym(t,e.instanceId,[Ud.Filters]),d=Y(()=>{var e;return((e=c.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.filters)??{}}),{filtersAll:f,filtersPromoted:p,filtersAdditional:m,filtersModel:h,filtersFetched:g,filtersLoading:_,areFiltersApplied:v,filteredResultCount:y,filteredResultCountLoading:b,filtersOpen:x,fetchFilterValues:S,applyModelFilters:C,resetFiltersApplied:w,refreshResultCount:T,refreshFetchedFilterValues:E,syncSelectedFilters:D,expandAllFilters:ee,collapseAllFilters:O}=u(),te=I(()=>s.value,()=>{var e;(e=s.value)==null||e.eventBus.on(`search-changed`,()=>{setTimeout(()=>{g.value.size>0&&(E(),T())},500),D()}),te()}),ne=e=>e.slice(0,d.value.maxFiltersVisible||10)??[],re=Y(()=>p.value.length?p.value:ne(m.value));return{root:t,componentName:i,componentOptions:d,isReady:a,isWebComponent:o,store:c,filtersAll:f,filtersPromoted:p,filtersAdditional:m,filtersToDisplay:re,filtersOpen:x,filtersFetched:g,areFiltersDirty:n,filtersModel:h,areFiltersApplied:v,allFiltersModalShown:r,filteredResultCount:y,filteredResultCountLoading:b,t:l,toggleFilter:async({attributeCode:e})=>{!e||!s.value||(x.value.has(e)?x.value.delete(e):(g.value.has(e)||await S([e]),x.value.add(e)))},clearAndCloseFilters:async()=>{w().then(()=>{x.value.clear()})},isFilterOpen:({attributeCode:e})=>x.value.has(e),isFilterLoading:({attributeCode:e})=>_.value.has(e),showAllFilters:()=>{r.value=!1,setTimeout(()=>{r.value=!0},1)},applyModelFilters:C,fetchFilterValues:S,onModalFilterValueChange:({attributeCode:e,filterValueName:t,value:n})=>{var r;(r=h.value)[e]??(r[e]={}),h.value[e][t]=n,T()},onModalApplyFilters:()=>{C(),r.value=!1},onFilterValueChange:()=>{n.value=!0,T()},resetFiltersApplied:w,expandAll:()=>{ee(re.value)},collapseAll:()=>{O()},criterionValueKey:lu}}}),rO={key:0,class:`d-flex mb-3`},iO={key:1,class:`list-unstyled mb-0`},aO={class:`d-block ms-2 text-body text-break pis-label`},oO={key:0},sO={class:`form-check pe-1`},cO={class:`form-check-label d-flex align-items-start py-1 ms-1`},lO=[`onUpdate:modelValue`,`name`],uO=[`textContent`];function dO(e,t,n,r,i,a){var o;let s=R(`LinkSecondary`),c=R(`Spinner`),l=R(`Arrow`),u=R(`Badge`),d=R(`Clickable`),f=R(`ScrollableList`),p=R(`Message`),m=R(`Btn`),h=R(`Card`),g=R(`FiltersNavigator`),_=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(V,{key:0},[K(h,{class:`mb-4`,"sticky-footer":``,icon:e.componentOptions.icon&&`funnel-filter`,header:e.t(`Filters`,!0),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},Gr({default:P(()=>{var n,r;return[(n=e.filtersToDisplay)!=null&&n.length&&(e.componentOptions.expandAllVisible||e.componentOptions.collapseAllVisible)?(H(),U(`div`,rO,[e.componentOptions.expandAllVisible?(H(),W(s,{key:0,icon:`expand-maximize`,class:`ms-1 me-4 ext-expand-all-filters`,onClick:X(e.expandAll,[`prevent`])},{default:P(()=>[q(j(e.t(`ExpandAllFilters`)),1)]),_:1},8,[`onClick`])):J(``,!0),e.componentOptions.collapseAllVisible?(H(),W(s,{key:1,icon:`shrink-minimise`,class:`ext-collapse-all-filters`,onClick:X(e.collapseAll,[`prevent`])},{default:P(()=>[q(j(e.t(`CollapseAllFilters`)),1)]),_:1},8,[`onClick`])):J(``,!0)])):J(``,!0),(r=e.filtersToDisplay)!=null&&r.length?(H(),U(`ul`,iO,[(H(!0),U(V,null,z(e.filtersToDisplay,n=>{var r;return H(),U(`li`,{key:n.attributeCode,class:`pb-2`},[K(d,{class:`py-1 d-flex align-items-start text-decoration-none lh-sm`,"aria-expanded":e.isFilterOpen(n),onClick:t=>e.toggleFilter(n)},{default:P(()=>[e.isFilterLoading(n)?(H(),W(c,{key:0,sm:``})):(H(),W(l,{key:1,dir:e.isFilterOpen(n)?`up`:`down`},null,8,[`dir`])),F(G(`span`,aO,null,512),[[_,n.attributeNameHtml]]),K(u,{class:`ms-auto`,textContent:j(n.hitCount)},null,8,[`textContent`])]),_:2},1032,[`aria-expanded`,`onClick`]),e.isFilterOpen(n)?(H(),U(`div`,oO,[(r=e.filtersFetched.get(n.attributeCode))!=null&&r.length?(H(),W(f,{key:0,class:`list-unstyled my-1 ms-2`,height:`30vh`,items:e.filtersFetched.get(n.attributeCode)||[]},{item:P(({item:r})=>[G(`div`,sO,[G(`label`,cO,[F(G(`input`,{"onUpdate:modelValue":t=>e.filtersModel[n.attributeCode][e.criterionValueKey(r.value)]=t,type:`checkbox`,class:`form-check-input mt-1 me-2 flex-shrink-0`,name:r.text,onChange:t[0]||(t[0]=(...t)=>e.onFilterValueChange&&e.onFilterValueChange(...t))},null,40,lO),[[bs,e.filtersModel[n.attributeCode][e.criterionValueKey(r.value)]]]),G(`span`,{class:`text-break user-select-none`,textContent:j(r.text)},null,8,uO),K(u,{class:`ms-auto`,textContent:j(r.hitCount)},null,8,[`textContent`])])])]),_:2},1032,[`items`])):(H(),W(p,{key:1},{default:P(()=>[q(j(e.t(`NoFilterValues`)),1)]),_:1}))])):J(``,!0)])}),128))])):(H(),W(p,{key:2},{default:P(()=>[q(j(e.t(`NoFilters`)),1)]),_:1}))]}),_:2},[e.areFiltersApplied||(o=e.filtersAll)!=null&&o.length?{name:`footer`,fn:P(()=>[e.filteredResultCount!==null&&e.areFiltersDirty?(H(),W(m,{key:0,class:`w-100 mb-2 justify-content-between`,disabled:e.areFiltersDirty!==!0||e.filteredResultCount===0,"is-loading":e.filteredResultCountLoading,onClick:X(e.applyModelFilters,[`prevent`])},{default:P(()=>[e.filteredResultCount===null?(H(),U(V,{key:0},[q(j(e.t(`ShowResults`,!0)),1)],64)):e.filteredResultCount===0?(H(),U(V,{key:1},[q(j(e.t(`NoFilteringResultsFound`)),1)],64)):(H(),U(V,{key:2},[q(j(e.t(`ShowNResults`,!0,[`${e.filteredResultCount||`0`}`])),1)],64))]),_:1},8,[`disabled`,`is-loading`,`onClick`])):J(``,!0),e.areFiltersApplied?(H(),W(s,{key:1,icon:`stop-not-allowed`,class:`mt-2`,onClick:X(e.clearAndCloseFilters,[`prevent`])},{default:P(()=>[q(j(e.t(`ClearFilters`,!0)),1)]),_:1},8,[`onClick`])):J(``,!0),K(s,{icon:`pop-out-window`,class:`mt-2`,onClick:X(e.showAllFilters,[`prevent`])},{default:P(()=>[q(j(e.t(`ShowAllFilters`))+` (`+j(e.filtersAll.length)+`) `,1)]),_:1},8,[`onClick`])]),key:`0`}:void 0]),1032,[`icon`,`header`,`use-markup`,`collapsed`]),K(g,{show:e.allFiltersModalShown,title:e.t(`AllFiltersModalTitle`),t:e.t,"filters-all":e.filtersAll,"filters-promoted":e.filtersPromoted,"filters-additional":e.filtersAdditional,"filters-fetched":e.filtersFetched,"filters-model":e.filtersModel,"fetch-filter-values":e.fetchFilterValues,"filtered-result-count":e.filteredResultCount,"filtered-result-count-loading":e.filteredResultCountLoading,onValueChange:e.onModalFilterValueChange,onApplyFilters:e.onModalApplyFilters,onClear:e.resetFiltersApplied},null,8,[`show`,`title`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-fetched`,`filters-model`,`fetch-filter-values`,`filtered-result-count`,`filtered-result-count-loading`,`onValueChange`,`onApplyFilters`,`onClear`])],64)):J(``,!0)],2)}var fO=Q(nO,[[`render`,dO]]),pO=20,mO=L({name:`pis-catalogs-products-search-filters-status`,components:{Badge:ky,LinkSecondary:kE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,t:o,useProductsFilters:s}=ym(t,e.instanceId,[Ud.Filters]),{filtersApplied:c,excludeFilter:l,resetFiltersApplied:u}=s();return{root:t,componentName:n,isReady:r,isWebComponent:i,store:a,filtersApplied:c,componentOptions:Y(()=>{var e;return((e=a.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.filtersStatus)??{}}),t:o,excludeFilter:l,resetAll:()=>{c.value.length&&u()},truncateText:e=>e.length>pO?e.substring(0,pO)+`...`:e}}}),hO={key:0,class:`mt-3`},gO={key:0},_O={class:`d-inline-block me-2`};function vO(e,t,n,r,i,a){let o=R(`Badge`),s=R(`LinkSecondary`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(`div`,hO,[e.filtersApplied.length?(H(),U(`div`,gO,[G(`small`,_O,j(e.t(`AppliedFilters`))+`:`,1),(H(!0),U(V,null,z(e.filtersApplied,(t,n)=>(H(),U(V,null,[(H(!0),U(V,null,z(t.values,(r,i)=>(H(),W(o,{key:`${n}${i}`,class:`me-2 my-1 py-2`,removable:``,title:`${t.attributeName??t.code}: ${r.text}`,"remove-title":e.t(`RemoveBadgeTitle`),onRemove:n=>e.excludeFilter(t,r.value)},{default:P(()=>[q(j(e.truncateText(t.attributeName??t.code))+`: `+j(e.truncateText(r.text)),1)]),_:2},1032,[`title`,`remove-title`,`onRemove`]))),128))],64))),256)),K(s,{icon:`stop-not-allowed`,class:`d-inline-flex align-middle`,onClick:e.resetAll},{default:P(()=>[q(j(e.t(`ClearAll`)),1)]),_:1},8,[`onClick`])])):J(``,!0)])):J(``,!0)],2)}var yO=Q(mO,[[`render`,vO]]),bO=L({components:{Spinner:My,Icon:$h},props:{src:{type:String,default:void 0},active:Boolean,clickable:{type:Boolean,default:!0},hideFrame:Boolean,isLoading:Boolean,maxSize:{type:Number,default:void 0},maxSizeCss:{type:String,default:void 0},padding:{type:Number,default:0},lazyLoading:Boolean}}),xO=[`src`,`loading`];function SO(e,t,n,r,i,a){let o=R(`Spinner`),s=R(`Icon`);return H(),U(`div`,{class:A([`ratio ratio-1x1 flex-shrink-0 pis-image`,[e.src||e.isLoading?`bg-white`:`bg-light`,e.active&&`border-primary`,!e.hideFrame&&`border`]]),style:k({cursor:e.clickable?`pointer`:`default`})},[G(`div`,{class:A([`d-flex align-items-center justify-content-center`,`p-`+e.padding])},[e.isLoading?(H(),W(o,{key:0,sm:``})):e.src?(H(),U(`img`,{key:1,class:`w-100 h-100`,style:k([{"object-fit":`contain`},[e.maxSize?`max-width: ${e.maxSize}px; max-height: ${e.maxSize}px;`:null,e.maxSizeCss?`max-width: ${e.maxSizeCss}; max-height: ${e.maxSizeCss};`:null].filter(Boolean)]),src:e.src,loading:e.lazyLoading?`lazy`:`eager`},null,12,xO)):(H(),W(s,{key:2,name:`photo-picture`,class:`opacity-25`,size:32}))],2)],6)}var CO=Q(bO,[[`render`,SO]]),wO=L({name:`SearchFormView`,components:{Btn:Iy,Dropdown:pb,FormInputClearable:Mb,Badge:ky,Clickable:wm,Spinner:My,Highlighter:sb,Image:CO,MountPoint:cg},props:{setRoot:{type:Function,required:!0},componentName:{type:String,required:!0},isReady:{type:Boolean,default:!1},options:{type:Object,default:()=>({})},adapter:{type:Object,required:!0}},setup(e){let{t,widerThan:n,narrowerThan:r,onAutocompleteItemClick:i}=e.adapter,a=Ut({text:``,type:e.adapter.initialSearchType,isDirty:!1}),o=M({totalCount:0,itemsCount:0,items:[]}),s=M(!1),c=M(!1),l=Y(()=>!!e.options.visible),u=Y(()=>!!e.options.useAutocomplete),d=Y(()=>o.value.items.some(e=>e.type===`category`)),f=Y(()=>e.adapter.placeholder()),p=Y(()=>e.adapter.searchAriaLabel()),m=Y(()=>e.adapter.searchTypeOptions()),h=Y(()=>e.adapter.isSearchTypeDropdownVisible());if(e.adapter.syncTypeFromRouteOnReady){let t=I(()=>e.isReady,n=>{if(n){let n=e.adapter.routeSearchType();n&&(a.type=n),t()}})}let g=async(t,n)=>{s.value=!1;let r=n||o.value.matchesOnlyWithoutFilters,i=t||r;try{let t=await e.adapter.search({searchText:a.text,searchType:a.type,resetCategories:i,resetFilters:r},{autocomplete:o.value});(t==null?void 0:t.searchText)!==void 0&&(a.text=t.searchText),a.isDirty=!1}catch{}},_=e=>{a.text=e,g()},v=e=>{a.text=e},y=()=>{a.isDirty||(a.text=``,o.value.items=[],o.value.totalCount=0,g(!1))},b=()=>{u.value&&a.text!=e.adapter.routeSearchText()&&a.text.length>2&&(s.value=!0,e.adapter.refreshAutocompleteOnFocus&&w(a.text))},x=()=>{s.value=!1},S=(e,t)=>{if(e.attributes){var n=e.attributes[t];if(n&&n.values)return n.values[0].text}},C=e=>{if(e.attributes){var t=e.attributes[`#AllIdentifiers`];if(t&&t.values)return t.values.map(e=>e.text).join(`, `)}},w=sp(async t=>{if(!u.value)return;let n=t!=null&&t.length>2;if(s.value=n,n){var r;c.value=!0;let n=[],s=await((r=e.adapter.autocomplete(t))==null?void 0:r.catch(()=>void 0));if(s){var i,a;let t=(s.items||[]).map(e=>({...e,text:S(e,`#DisplayName`)||``,secondaryText:C(e)||``,description:S(e,`CatalogDescription`)||``,images:e.images,type:`item`,location:`bottom`})),r={totalCount:s.totalCount||0,itemsCount:((i=s.items)==null?void 0:i.length)||0,items:[],autoCategoryNavigationCid:(a=s.autoCategoryNavigationCategory)==null?void 0:a.cid},c=e.adapter.isRootCategory();if(t.length){var l;n.push({attributes:{},productId:``,count:s.totalCount,type:c?`root`:`current`,location:`bottom`,categoryName:(l=s.autoCategoryNavigationCategory)==null?void 0:l.name,sparePart:!1,exactMatch:!1})}s.totalCount!=s.rootTotalCount&&n.push({attributes:{},productId:``,count:s.rootTotalCount,type:`root`,location:`bottom`,sparePart:!1,exactMatch:!1}),s.noFiltersTotalCount>0&&n.push({attributes:{},productId:``,count:s.noFiltersTotalCount,type:`no-filters`,location:`bottom`,sparePart:!1,exactMatch:!1}),s.categories&&s.categories.forEach((t,r)=>{var i,a,o;if(r>(e.options.maxCategoryMatches??2)-1)return;let s=``;t.breadcrumbs&&t.breadcrumbs.length>0&&(s=t.breadcrumbs.slice(0,t.breadcrumbs.length-1).map(e=>e.name).join(` > `)),n.push({attributes:{},productId:((i=t.match)==null?void 0:i.cid)??``,text:(a=t.match)==null?void 0:a.name,secondaryText:s,description:(o=t.keywords)==null?void 0:o.join(`, `),images:t.images,type:`category`,location:`top`,sparePart:!1,exactMatch:!1})}),r.items=n.concat(t),r.matchesOnlyInAllCategories=s.totalCount==0&&s.rootTotalCount>0,r.matchesOnlyWithoutFilters=s.noFiltersTotalCount>0,o.value=r}c.value=!1}},300),T=()=>{var t;a.isDirty=((t=a.text)==null?void 0:t.length)>0&&a.text!=e.adapter.routeSearchText(),w(a.text)},E=e.adapter.inputDebounceMs?sp(T,e.adapter.inputDebounceMs):T;I(()=>e.adapter.routeSearchText(),(e,t)=>{e!==t&&(a.text=e??``)}),I(()=>e.adapter.routeSearchType(),(t,n)=>{t&&t!==n&&e.adapter.acceptsRouteSearchType(t)&&(a.type=t)}),I(()=>a.type,()=>{e.adapter.applyRouteSearchType(a.type)});let D=Y(()=>{if(!a.text)return[];let e=a.text.trim().toLowerCase().split(/[._-\s/]+/);e.push(a.text.trim());let t=a.text.match(/\d+/g),n=a.text;t&&t.forEach(t=>{e.push(t),n=n.replace(t,`$`)});let r=n.trim().toLowerCase().split(`$`);return e.push(...r),e}),ee=e=>{if(e.images&&e.images.length>0)return e.images[0].thumbnailUrl},O=hg(t=>e.adapter.buildAutocompleteItemCtx(t.item));return{t,widerThan:n,narrowerThan:r,itemTopSlotProps:e=>({item:e,highlightTerms:D.value,getThumbnailUrl:ee,closeAutocomplete:x,setSearchText:v}),searchModel:a,searchTypeOptions:m,autocomplete:o,isAutocompleteVisible:s,isAutocompleteLoading:c,placeholder:f,searchAriaLabel:p,isSearchTypeDropdownVisible:h,dropdownMaxHeight:e.adapter.dropdownMaxHeight,showCurrentCategoryNameBadge:!!e.adapter.showCurrentCategoryNameBadge,hideItemsWhileLoading:!!e.adapter.hideItemsWhileLoading,visible:l,hasCategories:d,onSearch:g,onSearchInput:E,onClear:y,searchText:_,setSearchText:v,openAutocomplete:b,closeAutocomplete:x,onAutocompleteItemClick:i,highlightTerms:D,getThumbnailUrl:ee,autocompleteItemCtx:O}}}),TO={key:0,class:`mb-4`},EO={class:`d-flex align-items-center`},DO={key:0,style:{width:`4rem`,"min-width":`4rem`},class:`me-2`},OO={key:2},kO={class:`fw-bold ext-display-name`},AO={key:0,class:`small ext-all-identifiers text-wrap`},jO={key:1,class:`small ext-description text-wrap`},MO={key:0,class:`text-center`},NO={key:1},PO={key:2},FO=[`value`,`textContent`];function IO(e,t,n,r,i,a){let o=R(`Badge`),s=R(`Clickable`),c=R(`Image`),l=R(`MountPoint`),u=R(`Highlighter`),d=R(`Spinner`),f=R(`FormInputClearable`),p=R(`Btn`),m=R(`Dropdown`);return H(),U(`div`,{ref:e.setRoot,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,TO,[K(m,{open:e.isAutocompleteVisible,"onUpdate:open":t[6]||(t[6]=t=>e.isAutocompleteVisible=t),"min-width":`340px`,"max-height":e.dropdownMaxHeight,items:e.hideItemsWhileLoading&&e.isAutocompleteLoading?[]:e.autocomplete.items},Gr({item:P(({item:n})=>[n.type===`no-filters`?(H(),W(s,{key:0,class:`d-flex align-items-center dropdown-item py-2`,onClick:t[0]||(t[0]=t=>e.onSearch(!0,!0))},{default:P(()=>[G(`em`,null,`"`+j(e.searchModel.text)+`"`,1),K(o,{class:`ms-auto`},{default:P(()=>[q(j(e.t(`ShowingNWithoutFilters`,!1,[n&&n.count||0])),1)]),_:2},1024)]),_:2},1024)):J(``,!0),n.type===`root`?(H(),W(s,{key:1,class:`d-flex align-items-center dropdown-item py-2`,onClick:t[1]||(t[1]=t=>e.onSearch(!0))},{default:P(()=>[G(`em`,null,`"`+j(e.searchModel.text)+`"`,1),K(o,{class:`ms-auto`},{default:P(()=>[q(j(e.t(`ShowingNOfAllCategories`,!1,[n&&n.count||0])),1)]),_:2},1024)]),_:2},1024)):n.type===`current`?(H(),W(s,{key:2,class:`d-flex align-items-center dropdown-item py-2`,onClick:t[2]||(t[2]=t=>e.onSearch(!1))},{default:P(()=>[G(`em`,null,`"`+j(e.searchModel.text)+`"`,1),e.showCurrentCategoryNameBadge&&n.categoryName?(H(),W(o,{key:0,class:`ms-auto`},{default:P(()=>[q(j(n&&n.count||0)+` `+j(e.t(`In`))+` "`+j(n.categoryName)+`" `,1)]),_:2},1024)):(H(),W(o,{key:1,class:`ms-auto`},{default:P(()=>[q(j(e.t(`ShowingNOfCurrentCategory`,!1,[n&&n.count||0])),1)]),_:2},1024))]),_:2},1024)):n.type===`item`?(H(),W(s,{key:3,class:`dropdown-item mb-1`,onClick:t=>e.onAutocompleteItemClick(n,e.searchText)},{default:P(()=>[G(`div`,EO,[e.options.showProductImages?(H(),U(`div`,DO,[K(c,{src:e.getThumbnailUrl(n)},null,8,[`src`])])):J(``,!0),e.options.autocompleteItemTemplate?(H(),W(l,{key:1,callbacks:e.options.autocompleteItemTemplate,ctx:e.autocompleteItemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(`div`,OO,[G(`div`,kO,[K(u,{"highlight-class-name":`text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":n.text},null,8,[`search-words`,`text-to-highlight`])]),n.text==n.secondaryText?J(``,!0):(H(),U(`div`,AO,[K(u,{"highlight-class-name":`fw-bold text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":n.secondaryText},null,8,[`search-words`,`text-to-highlight`])])),n.description?(H(),U(`div`,jO,[K(u,{"highlight-class-name":`fw-bold text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":n.description},null,8,[`search-words`,`text-to-highlight`])])):J(``,!0)]))])]),_:2},1032,[`onClick`])):J(``,!0)]),footer:P(()=>[e.isAutocompleteLoading?(H(),U(`div`,MO,[K(d,{sm:``})])):e.autocomplete.totalCount?(H(),U(`small`,NO,j(e.t(`ShowingNOfNMatches`,!1,[`${e.autocomplete.itemsCount||0}`,`${e.autocomplete.totalCount||0}`])),1)):(H(),U(`small`,PO,j(e.autocomplete.matchesOnlyWithoutFilters?e.t(`NoResultsWithAppliedFilters`):e.autocomplete.matchesOnlyInAllCategories?e.t(`NoResultsInCategory`):e.t(`NoResults`)),1))]),activator:P(({on:n})=>[G(`form`,{class:A([e.widerThan(`sm`)&&`input-group flex-nowrap`]),onSubmit:t[5]||(t[5]=X(t=>e.onSearch(!1),[`prevent`]))},[K(f,Oa({modelValue:e.searchModel.text,"onUpdate:modelValue":t[3]||(t[3]=t=>e.searchModel.text=t),"class-inner":e.widerThan(`sm`)?`border-end-0`:`mb-1`,lg:e.widerThan(`sm`),placeholder:e.placeholder},qr(n),{"onUpdate:modelValue":e.onSearchInput,onClear:e.onClear,onFocus:e.openAutocomplete}),null,16,[`modelValue`,`class-inner`,`lg`,`placeholder`,`onUpdate:modelValue`,`onClear`,`onFocus`]),e.isSearchTypeDropdownVisible?F((H(),U(`select`,{key:0,"onUpdate:modelValue":t[4]||(t[4]=t=>e.searchModel.type=t),class:A([`form-select px-2`,[e.narrowerThan(`sm`)&&`mb-1`]]),style:k({"min-width":e.widerThan(`sm`)?`200px`:`100%`,"max-width":e.widerThan(`sm`)?`300px`:`100%`})},[(H(!0),U(V,null,z(e.searchTypeOptions,t=>(H(),U(`option`,{key:t.value,value:t.value,textContent:j(e.t(t.translate))},null,8,FO))),128))],6)),[[Cs,e.searchModel.type]]):J(``,!0),K(p,{"aria-label":e.searchAriaLabel,icon:`lens-search-find`,class:A([e.narrowerThan(`sm`)&&`w-100 d-flex justify-content-center`])},{default:P(()=>[G(`span`,null,j(e.t(`SearchButtonText`)),1)]),_:1},8,[`aria-label`,`class`])],34)]),_:2},[e.hasCategories&&!e.isAutocompleteLoading?{name:`item-top-title`,fn:P(()=>[B(e.$slots,`item-top-title`)]),key:`0`}:void 0,e.hasCategories&&!e.isAutocompleteLoading?{name:`item-title`,fn:P(()=>[B(e.$slots,`item-title`)]),key:`1`}:void 0,e.isAutocompleteLoading?void 0:{name:`item-top`,fn:P(({item:t})=>[B(e.$slots,`item-top`,ge(Ca(e.itemTopSlotProps(t))))]),key:`2`}]),1032,[`open`,`max-height`,`items`])])):J(``,!0)],2)}var LO=Q(wO,[[`render`,IO]]),RO={value:zl.WITH_ALL_WORDS,translate:`SearchTypeAllWords`},zO={value:zl.WITH_AT_LEAST_ONE_WORD,translate:`SearchTypeOneWord`},BO={value:zl.EXACT_PHRASE,translate:`SearchTypeExact`},VO=L({name:`pis-catalogs-products-search-form`,components:{SearchFormView:LO},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=e=>{t.value=e??void 0},{componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,routeData:c,widerThan:l,narrowerThan:u,t:d,emit:f}=ym(t,e.instanceId);return{root:t,setRoot:n,componentName:r,isReady:i,isWebComponent:a,store:s,componentOptions:Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.form}),formAdapter:{t:d,widerThan:l,narrowerThan:u,initialSearchType:zl.WITH_ALL_WORDS,search:async({searchText:e,searchType:t,resetCategories:n,resetFilters:i})=>{var a;await((a=o.value)==null?void 0:a.execute(new yu({searchText:e,searchType:t,resetCategories:n,resetFilters:i}).from(r)))},autocomplete:e=>{var t;return(t=o.value)==null?void 0:t.execute(new Fu({searchText:e}).from(r))},isRootCategory:()=>{var e,t;return!((e=c.value)!=null&&(e=e.products)!=null&&e.cid)||((t=c.value)==null||(t=t.products)==null?void 0:t.cid)===`ROOT`},routeSearchText:()=>{var e;return(e=c.value)==null?void 0:e.products.searchText},routeSearchType:()=>{var e;return(e=c.value)==null?void 0:e.products.searchType},acceptsRouteSearchType:()=>!0,applyRouteSearchType:e=>{c.value&&(c.value.products.searchType=e)},searchTypeOptions:()=>[RO,zO,BO],placeholder:()=>d(`SearchProductsInputPlaceholder`),searchAriaLabel:()=>d(`SearchButtonText`),isSearchTypeDropdownVisible:()=>!0,onAutocompleteItemClick:(e,t)=>t(e.text??``),buildAutocompleteItemCtx:e=>({instance:o.value,item:e,emit:f,t:d})}}}});function HO(e,t,n,r,i,a){let o=R(`SearchFormView`);return H(),W(o,{"set-root":e.setRoot,"component-name":e.componentName,"is-ready":e.isReady,options:e.componentOptions,adapter:e.formAdapter},null,8,[`set-root`,`component-name`,`is-ready`,`options`,`adapter`])}var UO=Q(VO,[[`render`,HO]]),WO=L({components:{Icon:$h},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},qty:{type:Object,required:!0},configurationId:{type:String,required:!0},productId:{type:String,required:!0},catalog:{type:Object,required:!0}},setup(e){let t=Pf.Catalogs.getInstance(e.instanceId),n=M(!1),r=M(!1),i=M();return{loadConfiguredOptions:async()=>{try{var a;if(n.value=!n.value,!r.value&&(a=e.catalog)!=null&&a.id){let n=await t.commandExecutor.execute(new Yu({catalogId:e.catalog.id,configurationId:e.configurationId}).from(`item-configured-option`));n&&(i.value=n),r.value=!0}}catch{}},configurator:i,expanded:n,hasBeenLoaded:r}}}),GO={class:`me-1`},KO={key:0},qO={key:0,class:`table table-sm`},JO={class:`bg-light`},YO={key:1,class:`text-muted`},XO={key:2,class:`text-center`};function ZO(e,t,n,r,i,a){var o;let s=R(`Icon`);return H(),U(V,null,[G(`div`,{class:`my-1`,style:{cursor:`pointer`},onClick:t[0]||(t[0]=X((...t)=>e.loadConfiguredOptions&&e.loadConfiguredOptions(...t),[`prevent`]))},[G(`span`,GO,[K(s,{name:`arrow-right`,size:16,style:k({transform:e.expanded?`rotate(90deg)`:``})},null,8,[`style`])]),G(`a`,null,j(e.productId),1)]),e.expanded?(H(),U(`div`,KO,[e.hasBeenLoaded&&(o=e.configurator)!=null&&(o=o.groups)!=null&&o.length?(H(),U(`table`,qO,[t[4]||(t[4]=G(`colgroup`,null,[G(`col`),G(`col`),G(`col`),G(`col`)],-1)),G(`thead`,null,[G(`tr`,JO,[G(`th`,null,[G(`small`,null,j(e.t(`Product`)),1)]),G(`th`,null,[G(`small`,null,j(e.t(`Description`)),1)]),G(`th`,null,[G(`small`,null,j(e.t(`Quantity`)),1)]),G(`th`,null,[G(`small`,null,j(e.t(`UnitOfMeasure`)),1)])])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.configurator.groups,e=>(H(),U(V,{key:e.name},[G(`tr`,null,[t[1]||(t[1]=G(`td`,null,null,-1)),G(`td`,null,[G(`strong`,null,j(e.name),1)]),t[2]||(t[2]=G(`td`,null,null,-1)),t[3]||(t[3]=G(`td`,null,null,-1))]),(H(!0),U(V,null,z(e.elements,e=>(H(),U(`tr`,{key:e.product},[G(`td`,null,j(e.product),1),G(`td`,null,j(e.description),1),G(`td`,null,j(e.quantity),1),G(`td`,null,j(e.unitOfMeasure),1)]))),128))],64))),128))])])):e.hasBeenLoaded?(H(),U(`span`,YO,j(e.t(`NoOptionsAvailable`)),1)):(H(),U(`div`,XO,[...t[5]||(t[5]=[G(`div`,{class:`spinner-border text-primary`,role:`status`},null,-1)])]))])):J(``,!0)],64)}var QO=L({components:{ItemConfiguredOption:Q(WO,[[`render`,ZO]])},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},qty:{type:Object,required:!0},catalog:{type:Object,required:!0}}}),$O={class:`fw-bold`};function ek(e,t,n,r,i,a){let o=R(`ItemConfiguredOption`);return H(),U(V,null,[G(`div`,$O,j(e.t(`ConfiguredOptions`)),1),(H(!0),U(V,null,z(e.qty.configurationIds,t=>(H(),U(`div`,{key:t.id},[K(o,{"configuration-id":t.id,"product-id":t.productId,"instance-id":e.instanceId,catalog:e.catalog,qty:e.qty,t:e.t},null,8,[`configuration-id`,`product-id`,`instance-id`,`catalog`,`qty`,`t`])]))),128))],64)}var tk=L({name:`ItemCatalogs`,components:{DropdownPopper:Wv,ItemConfiguredOptions:Q(QO,[[`render`,ek]]),Icon:$h,MountPoint:cg},props:{item:{type:Object,required:!0},t:{type:Function,required:!0},allCatalogs:{type:Boolean,default:!1},instanceId:{type:String,default:void 0}},emits:[`navigate`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),{onProductItemMenuAction:r}=bm(M(n),e.t,`item-catalogs`),i=async e=>{if(e)try{t(`navigate`),await n.execute(new ku({catalogId:e}).from(`item-catalogs`))}catch{}},a=Y(()=>{var e;return(e=n.store)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null||(e=e.actions)==null?void 0:e.productItemMenu});return{instance:n,actionsEnabled:Y(()=>{var e;return n.registeredComponents.has(`pis-catalogs-products-search-actions-modals`)&&((e=a.value)==null?void 0:e.visible)}),catalogProductItemMenu:a,emit:t,details:i,isDisabled:(e,t)=>typeof e.disabled==`function`?e.disabled(t):e.disabled,productItemMenuItems:e=>{var t;return(((t=a.value)==null?void 0:t.items)||[]).filter(t=>typeof t.visible==`function`?t.visible(e):t.visible)},onProductItemMenuAction:r,menuItemCtx:hg(r=>({instance:n,item:e.item,emit:t,t:e.t}))}}}),nk={class:`table table-sm`},rk={key:0,style:{width:`30%`}},ik={key:1,style:{width:`40%`}},ak={key:2},ok={class:`bg-light`},sk={key:0},ck={key:1},lk={key:2,class:`text-end`},uk={key:0},dk={class:`fw-bold`},fk=[`onClick`],pk={class:`small text-muted`},mk={key:1},hk={key:2,class:`text-end`},gk={type:`button`,class:`btn btn-link text-dark`},_k={class:`dropdown-menu show`},vk={key:0,class:`dropdown-divider`},yk={key:1,class:`dropdown-item text-muted`},bk=[`onClick`],xk={key:0},Sk=[`colspan`],Ck={class:`pt-2 px-4`};function wk(e,t,n,r,i,a){let o=R(`Icon`),s=R(`MountPoint`),c=R(`DropdownPopper`),l=R(`ItemConfiguredOptions`);return H(),U(`table`,nk,[G(`colgroup`,null,[e.allCatalogs?(H(),U(`col`,rk)):J(``,!0),e.allCatalogs?(H(),U(`col`,ik)):J(``,!0),t[0]||(t[0]=G(`col`,{style:{width:`10%`}},null,-1)),t[1]||(t[1]=G(`col`,{style:{width:`10%`}},null,-1)),e.actionsEnabled?(H(),U(`col`,ak)):J(``,!0)]),G(`thead`,null,[G(`tr`,ok,[e.allCatalogs?(H(),U(`th`,sk,[G(`small`,null,j(e.t(`CatalogCode`)),1)])):J(``,!0),e.allCatalogs?(H(),U(`th`,ck,[G(`small`,null,j(e.t(`Description`)),1)])):J(``,!0),G(`th`,null,[G(`small`,null,j(e.t(`Quantity`)),1)]),G(`th`,null,[G(`small`,null,j(e.t(`UnitOfMeasure`)),1)]),e.actionsEnabled?(H(),U(`th`,lk,[G(`small`,null,j(e.t(`Actions`)),1)])):J(``,!0)])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.item.catalogs,t=>(H(),U(V,{key:t.code+t.owner},[(H(!0),U(V,null,z(t.quantities,n=>{var r;return H(),U(V,{key:n.id},[G(`tr`,{class:A({"no-border-bottom":n.configurationIds&&n.configurationIds.length})},[e.allCatalogs?(H(),U(`td`,uk,[G(`div`,dk,[G(`a`,{href:``,onClick:X(n=>e.details(t.id),[`prevent`])},j(t.code),9,fk)]),G(`div`,pk,j(t.owner.userId),1)])):J(``,!0),e.allCatalogs?(H(),U(`td`,mk,[G(`div`,null,j(t.description),1)])):J(``,!0),G(`td`,null,j(n.value),1),G(`td`,null,j(n.unitOfMeasure),1),e.actionsEnabled&&(r=e.catalogProductItemMenu)!=null&&(r=r.items)!=null&&r.length?(H(),U(`td`,hk,[K(c,{placement:`bottom-start`,interactive:!0,class:`d-inline-block`},{trigger:P(()=>[G(`button`,gk,[K(o,{name:`menu`})])]),dropdown:P(({close:n})=>[G(`ul`,_k,[(H(!0),U(V,null,z(e.productItemMenuItems(e.item),(r,i)=>(H(),U(`li`,{key:i},[r.text===`-`?(H(),U(`hr`,vk)):e.isDisabled(r,e.item)?(H(),U(`span`,yk,[r.itemTemplate?(H(),W(s,{key:0,callbacks:r.itemTemplate,ctx:e.menuItemCtx({item:r})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(r.text),1)],64))])):(H(),U(`a`,{key:2,class:`dropdown-item`,href:``,onClick:X(i=>{e.onProductItemMenuAction(r,e.item,t.id),n()},[`prevent`])},[r.itemTemplate?(H(),W(s,{key:0,callbacks:r.itemTemplate,ctx:e.menuItemCtx({item:r})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(r.text),1)],64))],8,bk))]))),128))])]),_:2},1024)])):J(``,!0)],2),n.configurationIds&&n.configurationIds.length?(H(),U(`tr`,xk,[G(`td`,{colspan:e.allCatalogs?5:3},[G(`div`,Ck,[K(l,{"instance-id":e.instanceId,catalog:t,qty:n,t:e.t},null,8,[`instance-id`,`catalog`,`qty`,`t`])])],8,Sk)])):J(``,!0)],64)}),128))],64))),128))])])}var Tk=Q(tk,[[`render`,wk]]),Ek=L({components:{Modal:Qy,ItemCatalogsDetails:Tk},props:{t:{type:Function,required:!0},item:{type:Object,default:void 0},instanceId:{type:String,default:void 0},show:Boolean,allCatalogs:{type:Boolean,default:!1}},emits:[`hidden`],setup(){return{}}}),Dk={key:0},Ok={key:1,class:`text-center`};function kk(e,t,n,r,i,a){var o,s;let c=R(`ItemCatalogsDetails`),l=R(`Modal`);return H(),W(l,{show:e.show,title:((o=e.item)==null?void 0:o.alternateProductId)||((s=e.item)==null?void 0:s.productId),xl:``},{default:P(()=>[G(`div`,null,[e.item?(H(),U(`div`,Dk,[K(c,{item:e.item,t:e.t,"all-catalogs":e.allCatalogs,"instance-id":e.instanceId,onNavigate:t[0]||(t[0]=t=>e.$emit(`hidden`))},null,8,[`item`,`t`,`all-catalogs`,`instance-id`])])):(H(),U(`div`,Ok,[...t[1]||(t[1]=[G(`div`,{class:`spinner-border text-primary`,role:`status`},null,-1)])]))])]),_:1},8,[`show`,`title`])}var Ak=Q(Ek,[[`render`,kk]]),jk=L({name:`SearchGridView`,components:{Image:CO,Clickable:wm,Icon:$h,MountPoint:cg},props:{setRoot:{type:Function,required:!0},componentName:{type:String,required:!0},isReady:{type:Boolean,default:!1},hideIfInitial:{type:Boolean,default:!1},options:{type:Object,default:()=>({})},items:{type:Array,default:void 0},instance:{type:Object,default:void 0},cardClass:{type:String,required:!0},selectCheckboxStyle:{type:String,required:!0},previewEnabled:{type:Boolean,default:!1},adapter:{type:Object,required:!0}},setup(e){let{t,widerThan:n,details:r,getItemImage:i,isImageDisabled:a,isPreviewDisabled:o,preview:s}=e.adapter;return{t,widerThan:n,details:r,getItemImage:i,isImageDisabled:a,isPreviewDisabled:o,preview:s,attrValues:Ws,showActionTemplate:t=>e.options.actionTemplate&&(e.options.showActionTemplateIfInactive||!(t!=null&&t.inactive)),imageOverlayCtx:hg(t=>e.adapter.buildImageOverlayCtx(t.item)),titleCtx:hg(t=>e.adapter.buildTitleCtx(t.item)),itemCtx:hg(t=>e.adapter.buildItemCtx(t.item)),actionCtx:hg(t=>e.adapter.buildActionCtx(t.item))}}}),Mk={class:`card-img-top position-relative pt-5`},Nk={key:0},Pk={class:`card-body`},Fk={class:`d-flex justify-content-center text-center`},Ik={key:0,class:`card-footer`},Lk={class:`text-center`},Rk=[`checked`,`onClick`];function zk(e,t,n,r,i,a){let o=R(`Image`),s=R(`MountPoint`),c=R(`Icon`),l=R(`Clickable`);return H(),U(`div`,{ref:e.setRoot,class:A([`pis-component`,e.componentName])},[e.isReady&&e.options.visible?(H(),U(V,{key:0},[B(e.$slots,`before-results`),!e.hideIfInitial&&e.items&&e.items.length?(H(),U(`div`,{key:0,class:A([`row`,[e.widerThan(`md`)?`g-4`:`g-3`]])},[(H(!0),U(V,null,z(e.items,t=>{var n,r;return H(),U(`div`,{key:t.productId,class:A([e.widerThan(`xl`)?`col-3`:e.widerThan(`lg`)?`col-4`:e.widerThan(`sm`)?`col-6`:`col-12`])},[G(`div`,{class:A([e.cardClass,{"bg-light":t.exactMatch,"ext-selected":(n=e.instance)==null?void 0:n.selection.isSelected(t)}])},[G(`div`,Mk,[K(o,{src:e.getItemImage(t),"max-size":300,role:`button`,"hide-frame":``,class:`card-img-top`,style:{"max-width":`80% !important`,margin:`auto`},"lazy-loading":e.options.imageLazyLoading,clickable:e.options.navigateOnContentClick&&!e.isImageDisabled(t),onClick:X(n=>e.options.navigateOnContentClick&&!e.isImageDisabled(t)&&e.details(t),[`prevent`])},null,8,[`src`,`lazy-loading`,`clickable`,`onClick`]),e.options.imageOverlayTemplate?(H(),U(`div`,Nk,[K(s,{callbacks:e.options.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)]),G(`div`,Pk,[B(e.$slots,`body-top`,{item:t}),G(`div`,Fk,[B(e.$slots,`title-prefix`,{item:t}),e.options.titleTemplate?(H(),W(s,{key:0,callbacks:e.options.titleTemplate,ctx:e.titleCtx({item:t})},null,8,[`callbacks`,`ctx`])):B(e.$slots,`title-fallback`,{item:t},void 0,void 0,1)]),e.options.showAllIdentifiers?(H(!0),U(V,{key:0},z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`text-center small text-muted fw-bold my-2`},j(e),1))),128)):J(``,!0),e.options.itemTemplate?(H(),W(s,{key:1,callbacks:e.options.itemTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])):B(e.$slots,`item-fallback`,{item:t},void 0,void 0,2),B(e.$slots,`item-extra`,{item:t})]),e.showActionTemplate(t)?(H(),U(`div`,Ik,[G(`div`,Lk,[K(s,{callbacks:e.options.actionTemplate,ctx:e.actionCtx({item:t})},null,8,[`callbacks`,`ctx`])])])):J(``,!0),e.previewEnabled?(H(),U(V,{key:1},[e.isPreviewDisabled(t)?(H(),U(`span`,{key:1,class:`position-absolute top-0 start-0 p-2 d-flex ext-icon-preview text-muted`,style:k({"margin-left":e.options.selectable?`2rem`:`0`})},[K(c,{name:`eye-show`,size:24})],4)):(H(),W(l,{key:0,class:`position-absolute top-0 start-0 p-2 d-flex ext-icon-preview`,style:k({"margin-left":e.options.selectable?`2rem`:`0`}),title:e.t(`Preview`,!0),onClick:n=>!e.isPreviewDisabled(t)&&e.preview(t)},{default:P(()=>[K(c,{name:`eye-show`,size:24})]),_:1},8,[`style`,`title`,`onClick`]))],64)):J(``,!0),e.options.selectable?(H(),U(`div`,{key:2,class:`position-absolute p-2 top-0 start-0 ext-select-checkbox`,style:k(e.selectCheckboxStyle)},[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(r=e.instance)==null?void 0:r.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,Rk)],4)):J(``,!0)],2)],2)}),128))],2)):J(``,!0)],64)):J(``,!0)],2)}var Bk=Q(jk,[[`render`,zk]]),Vk=L({name:`pis-catalogs-products-search-grid`,components:{SearchGridView:Bk,Clickable:wm,Icon:$h,ItemCatalogsDetailsModal:Ak},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=e=>{t.value=e??void 0},r=Vl,{componentName:i,isWebComponent:a,isReady:o,instance:s,store:c,routeData:l,t:u,widerThan:d,emit:f}=ym(t,e.instanceId,[Ud.Products]),p=Y(()=>{var e;return((e=c.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.grid)??{}}),m=async e=>{if(!e.inactive)try{if(l.value&&e){var t;await((t=s.value)==null?void 0:t.execute(new _u(e).from(i)))}}catch{}},h=async e=>{if(e&&!e.inactive)try{var t;await((t=s.value)==null?void 0:t.execute(new _u(e).from(i)))}catch{}},g=Y(()=>{var e;return(e=c.value)==null||(e=e.data.products)==null?void 0:e.items}),_=Y(()=>{var e;return((e=s.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-preview`))??!1}),v=e=>e.baseProduct&&e.baseProduct.inactive||e.inactive,y=async e=>{try{var t;await((t=s.value)==null?void 0:t.execute(new ju({productId:e}).from(i)))}catch{}},b=M(),x=M(!1),S=e=>{b.value=e,x.value=!1,jn(()=>{x.value=!0})},C=e=>{var t;if(e.baseProduct){var n;return(n=(e.baseProduct.images||[])[0])==null?void 0:n.url}return(t=(e.images||[])[0])==null?void 0:t.url};return{root:t,setRoot:n,instance:s,componentName:i,componentOptions:p,isWebComponent:a,isReady:o,store:c,productsItems:g,previewEnabled:_,selectedItem:b,catalogsModalVisible:x,showingAllCatalogs:Y(()=>{var e;return!((e=l.value)!=null&&e.products.catalogId)}),catalogProductType:r,details:m,baseProductDetails:h,toggleItemDetails:S,t:u,attrValue:Us,emit:f,gridAdapter:{t:u,widerThan:d,details:e=>m(e),getItemImage:e=>C(e),isImageDisabled:()=>!1,isPreviewDisabled:e=>v(e),preview:e=>{var t;let n=e;return y(((t=n.baseProduct)==null?void 0:t.productId)||n.alternateProductId||n.productId)},buildImageOverlayCtx:e=>({instance:s.value,item:e,emit:f,t:u}),buildTitleCtx:e=>({instance:s.value,item:e,emit:f,details:m,baseProductDetails:h,attrValue:Us,t:u}),buildItemCtx:e=>({instance:s.value,item:e,emit:f,details:m,baseProductDetails:h,attrValue:Us,attrValues:Ws,t:u}),buildActionCtx:e=>({instance:s.value,item:e,emit:f,details:m,baseProductDetails:h,attrValue:Us,attrValues:Ws,t:u})}}}}),Hk={key:0,style:{position:`absolute`,bottom:`0`,right:`0`,"z-index":`2`}},Uk=[`onClick`],Wk={class:`d-flex flex-column`},Gk={key:0,class:`text-muted`},Kk=[`onClick`],qk={key:2,class:`text-muted small`},Jk={key:0},Yk={key:1},Xk={key:1,class:`fw-bold text-muted`};function Zk(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`SearchGridView`),l=R(`ItemCatalogsDetailsModal`);return H(),U(V,null,[K(c,{"set-root":e.setRoot,"component-name":e.componentName,"is-ready":e.isReady,options:e.componentOptions,items:e.productsItems,instance:e.instance,"card-class":`card h-100 pt-0 pb-4`,"select-checkbox-style":`z-index: 1; width: auto`,"preview-enabled":e.previewEnabled,adapter:e.gridAdapter},{"body-top":P(({item:t})=>[e.componentOptions.detailsVisible?(H(),U(`div`,Hk,[G(`a`,{href:``,class:`btn btn-link text-dark d-flex align-items-center`,onClick:X(n=>e.toggleItemDetails(t),[`prevent`])},[K(o,{name:`plus-add`,class:`py-1`,style:{"font-size":`1.1rem`}})],8,Uk)])):J(``,!0)]),"title-fallback":P(({item:t})=>[G(`div`,Wk,[t.inactive?(H(),U(`strong`,Gk,j(e.attrValue(t,`#DisplayName`)),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(n=>e.details(t),[`prevent`])},[G(`strong`,null,j(e.attrValue(t,`#DisplayName`)),1)],8,Kk)),t.productType===e.catalogProductType.CONFIGURED?(H(),U(`div`,qk,[G(`em`,null,j(e.t(`ConfiguredProducts`)),1)])):J(``,!0)])]),"item-fallback":P(({item:n})=>{var r,i;return[n.customerClassification?(H(),U(`em`,Jk,[q(j(e.t(`CustomerClassification`))+`:\xA0 `+j(n.customerClassification)+` `,1),t[1]||(t[1]=G(`br`,null,null,-1))])):J(``,!0),n.baseProduct?(H(),U(`em`,Yk,[q(j(e.t(`BaseProductId`))+`:\xA0 `,1),(r=n.baseProduct)!=null&&r.inactive?(H(),U(`span`,Xk,j((i=n.baseProduct)==null?void 0:i.productId),1)):(H(),W(s,{key:0,onClick:t=>e.baseProductDetails(n.baseProduct)},{default:P(()=>{var e;return[q(j((e=n.baseProduct)==null?void 0:e.productId),1)]}),_:2},1032,[`onClick`])),t[2]||(t[2]=G(`br`,null,null,-1))])):J(``,!0)]}),_:1},8,[`set-root`,`component-name`,`is-ready`,`options`,`items`,`instance`,`preview-enabled`,`adapter`]),K(l,{"instance-id":e.instanceId,item:e.selectedItem,show:e.catalogsModalVisible,t:e.t,"all-catalogs":e.showingAllCatalogs,onHidden:t[0]||(t[0]=t=>e.catalogsModalVisible=!1)},null,8,[`instance-id`,`item`,`show`,`t`,`all-catalogs`])],64)}var Qk=Q(Vk,[[`render`,Zk]]),$k=L({name:`SearchListView`,components:{Clickable:wm,Icon:$h,Image:CO,MountPoint:cg},props:{setRoot:{type:Function,required:!0},componentName:{type:String,required:!0},isReady:{type:Boolean,default:!1},hideIfInitial:{type:Boolean,default:!1},options:{type:Object,default:()=>({})},items:{type:Array,default:void 0},instance:{type:Object,default:void 0},isDesktop:{type:Boolean,default:!1},selectableAddsImageMargin:{type:Boolean,default:!1},previewEnabled:{type:Boolean,default:!1},adapter:{type:Object,required:!0}},setup(e){let{t,details:n,getItemImage:r,isImageDisabled:i,isPreviewDisabled:a,preview:o,onImageClick:s}=e.adapter;return{t,details:n,getItemImage:r,isImageDisabled:i,isPreviewDisabled:a,preview:o,onImageClick:s,attrValue:Us,attrValues:Ws,showActionTemplate:t=>e.options.actionTemplate&&(e.options.showActionTemplateIfInactive||!(t!=null&&t.inactive)),imageOverlayCtx:hg(t=>e.adapter.buildImageOverlayCtx(t.item)),titleCtx:hg(t=>e.adapter.buildTitleCtx(t.item)),itemCtx:hg(t=>e.adapter.buildItemCtx(t.item)),additionalColumnCtx:hg(t=>e.adapter.buildAdditionalColumnCtx(t.item)),actionCtx:hg(t=>e.adapter.buildActionCtx(t.item))}}}),eA={key:0},tA={class:`row align-items-center`},nA={key:1,class:`position-absolute p-2 top-50 start-0 ext-select-checkbox`,style:{"z-index":`1`,width:`auto`,"margin-top":`-1rem`}},rA=[`checked`,`onClick`],iA={class:`position-relative col d-flex justify-content-center align-items-center card`},aA={key:0},oA={key:3,class:`col-12 g-0`},sA={class:`position-relative col d-flex justify-content-center align-items-center`},cA={key:0},lA={key:0,class:`text-muted`},uA=[`onClick`];function dA(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`Image`),l=R(`MountPoint`);return H(),U(`div`,{ref:e.setRoot,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(V,{key:0},[B(e.$slots,`before-results`),!e.hideIfInitial&&e.items&&e.items.length?(H(),U(`div`,eA,[(H(!0),U(V,null,z(e.items,t=>{var n,r;return H(),U(`div`,{key:t.productId,class:A([`card mb-3 p-3`,{"pt-0":!e.isDesktop,"bg-light":t.exactMatch,"ext-selected":(n=e.instance)==null?void 0:n.selection.isSelected(t)}])},[G(`div`,tA,[e.previewEnabled?(H(),W(s,{key:0,class:`position-absolute p-2 top-0 start-0 d-flex ext-icon-preview`,style:{"z-index":`1`,width:`auto`},title:e.t(`Preview`,!0),disabled:e.isPreviewDisabled(t),onClick:n=>!e.isPreviewDisabled(t)&&e.preview(t)},{default:P(()=>[K(o,{name:`eye-show`,size:24})]),_:1},8,[`title`,`disabled`,`onClick`])):J(``,!0),e.options.selectable?(H(),U(`div`,nA,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(r=e.instance)==null?void 0:r.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,rA)])):J(``,!0),e.isDesktop?(H(),U(`div`,{key:2,class:A([e.previewEnabled||e.selectableAddsImageMargin&&e.options.selectable?`ms-4`:``,`col`]),style:k({"max-width":e.options.imageSize})},[G(`div`,iA,[K(c,{style:k({"max-width":e.options.imageSize}),src:e.getItemImage(t),clickable:e.options.navigateOnContentClick&&!e.isImageDisabled(t),"hide-frame":!0,padding:e.options.imagePadding,"lazy-loading":e.options.imageLazyLoading,onClick:n=>e.onImageClick(t,!1)},null,8,[`style`,`src`,`clickable`,`padding`,`lazy-loading`,`onClick`]),e.options.imageOverlayTemplate?(H(),U(`div`,aA,[K(l,{callbacks:e.options.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])],6)):(H(),U(`div`,oA,[G(`div`,sA,[K(c,{class:`mt-3`,style:{"max-width":`300px`},src:e.getItemImage(t),clickable:e.options.navigateOnContentClick&&!e.isImageDisabled(t),"hide-frame":!0,onClick:n=>e.onImageClick(t,!0)},null,8,[`src`,`clickable`,`onClick`]),e.options.imageOverlayTemplate?(H(),U(`div`,cA,[K(l,{callbacks:e.options.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])])),G(`div`,{class:A([e.isDesktop?`col`:`col-12 mt-3`])},[B(e.$slots,`body-top`,{item:t}),B(e.$slots,`title-prefix`,{item:t}),e.options.titleTemplate?(H(),W(l,{key:0,callbacks:e.options.titleTemplate,ctx:e.titleCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[t.inactive?(H(),U(`strong`,lA,j(e.attrValue(t,`#DisplayName`)),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(n=>e.details(t),[`prevent`])},[G(`strong`,null,j(e.attrValue(t,`#DisplayName`)),1)],8,uA))],64)),e.options.showAllIdentifiers?(H(!0),U(V,{key:2},z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`small text-muted fw-bold`},j(e),1))),128)):J(``,!0),e.options.itemTemplate?(H(),W(l,{key:3,callbacks:e.options.itemTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])):B(e.$slots,`item-fallback`,{item:t},void 0,void 0,4),B(e.$slots,`item-extra`,{item:t})],2),e.options.additionalColumnTemplate?(H(),U(`div`,{key:4,class:A([e.isDesktop?`col-`+e.options.additionalColumnTemplateWidth:`col-12 mt-3`])},[K(l,{callbacks:e.options.additionalColumnTemplate,ctx:e.additionalColumnCtx({item:t})},null,8,[`callbacks`,`ctx`])],2)):J(``,!0),e.showActionTemplate(t)?(H(),U(`div`,{key:5,class:A([e.isDesktop?`col-`+e.options.actionTemplateWidth:`col-12 mt-3`])},[K(l,{callbacks:e.options.actionTemplate,ctx:e.actionCtx({item:t})},null,8,[`callbacks`,`ctx`])],2)):J(``,!0)])],2)}),128))])):J(``,!0)],64)):J(``,!0)],2)}var fA=Q($k,[[`render`,dA]]),pA=L({name:`pis-catalogs-products-search-list`,components:{SearchListView:fA,Icon:$h,Clickable:wm,ItemCatalogsDetailsModal:Ak},props:{instanceId:{type:String,default:void 0}},emits:[`click-content`],setup(e,{emit:t}){let n=M(),r=e=>{n.value=e??void 0},i=Vl,{componentName:a,isReady:o,isWebComponent:s,instance:c,store:l,routeData:u,t:d,widerThan:f,narrowerThan:p,emit:m}=ym(n,e.instanceId,[Ud.Products]),h=Y(()=>{var e;return((e=l.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.list)??{}}),g=Y(()=>f(`md`)),_=async e=>{if(!e.inactive)try{if(u.value&&e){var t;await((t=c.value)==null?void 0:t.execute(new _u(e).from(a)))}}catch{}},v=async e=>{if(e&&!e.inactive)try{var t;await((t=c.value)==null?void 0:t.execute(new _u(e).from(a)))}catch{}},y=Y(()=>{var e;return(e=l.value)==null||(e=e.data.products)==null?void 0:e.items}),b=Y(()=>{var e;return((e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-preview`))??!1}),x=e=>e.baseProduct&&e.baseProduct.inactive||e.inactive,S=async e=>{try{var t;await((t=c.value)==null?void 0:t.execute(new ju({productId:e}).from(a)))}catch{}},C=M(),w=M(!1),T=e=>{C.value=e,w.value=!1,jn(()=>{w.value=!0})},E=e=>{var t;if(e.baseProduct){var n;return(n=(e.baseProduct.images||[])[0])==null?void 0:n.url}return(t=(e.images||[])[0])==null?void 0:t.url};return{root:n,setRoot:r,instance:c,componentName:a,componentOptions:h,isReady:o,isWebComponent:s,isDesktopView:g,store:l,selectedItem:C,productsItems:y,previewEnabled:b,showingAllCatalogs:Y(()=>{var e;return!((e=u.value)!=null&&e.products.catalogId)}),catalogProductType:i,catalogsModalVisible:w,t:d,narrowerThan:p,attrValue:Us,additionalInfo:Gs,details:_,baseProductDetails:v,toggleItemDetails:T,emit:m,listAdapter:{t:d,details:e=>_(e),getItemImage:e=>E(e),isImageDisabled:e=>x(e),isPreviewDisabled:e=>x(e),preview:e=>{var t;let n=e;return S(((t=n.baseProduct)==null?void 0:t.productId)||n.alternateProductId||n.productId)},onImageClick:(e,n)=>{n?t(`click-content`):_(e)},buildImageOverlayCtx:e=>({instance:c.value,item:e,emit:m,t:d}),buildTitleCtx:e=>({instance:c.value,item:e,emit:m,details:_,baseProductDetails:v,attrValue:Us,t:d}),buildItemCtx:e=>({instance:c.value,item:e,emit:m,details:_,baseProductDetails:v,attrValue:Us,t:d}),buildAdditionalColumnCtx:e=>({instance:c.value,item:e,emit:m,details:_,baseProductDetails:v,attrValue:Us,t:d}),buildActionCtx:e=>({instance:c.value,item:e,emit:m,details:_,baseProductDetails:v,attrValue:Us,t:d})}}}}),mA={key:0,style:{position:`absolute`,bottom:`0.4rem`,right:`0.4rem`,"z-index":`2`}},hA=[`onClick`],gA={key:0},_A={key:1},vA={key:1,class:`fw-bold text-muted`};function yA(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`SearchListView`),l=R(`ItemCatalogsDetailsModal`);return H(),U(V,null,[K(c,{"set-root":e.setRoot,"component-name":e.componentName,"is-ready":e.isReady,options:e.componentOptions,items:e.productsItems,instance:e.instance,"is-desktop":e.isDesktopView,"preview-enabled":e.previewEnabled,adapter:e.listAdapter},{"body-top":P(({item:t})=>[e.componentOptions.detailsVisible?(H(),U(`div`,mA,[G(`a`,{href:``,class:`btn btn-link text-dark d-flex align-items-center`,onClick:X(n=>e.toggleItemDetails(t),[`prevent`])},[K(o,{name:`plus-add`,class:`py-1`,style:{"font-size":`1.1rem`}})],8,hA)])):J(``,!0)]),"item-fallback":P(({item:n})=>{var r,i;return[G(`div`,null,[G(`span`,null,j(e.attrValue(n,`#Description`)),1)]),n.customerClassification?(H(),U(`em`,gA,[q(j(e.t(`CustomerClassification`))+`:\xA0 `+j(n.customerClassification)+` `,1),t[1]||(t[1]=G(`br`,null,null,-1))])):J(``,!0),n.baseProduct?(H(),U(`em`,_A,[q(j(e.t(`BaseProductId`))+`:\xA0 `,1),(r=n.baseProduct)!=null&&r.inactive?(H(),U(`span`,vA,j((i=n.baseProduct)==null?void 0:i.productId),1)):(H(),W(s,{key:0,onClick:t=>e.baseProductDetails(n.baseProduct)},{default:P(()=>{var e;return[q(j((e=n.baseProduct)==null?void 0:e.productId),1)]}),_:2},1032,[`onClick`])),t[2]||(t[2]=G(`br`,null,null,-1))])):J(``,!0)]}),_:1},8,[`set-root`,`component-name`,`is-ready`,`options`,`items`,`instance`,`is-desktop`,`preview-enabled`,`adapter`]),K(l,{"instance-id":e.instanceId,item:e.selectedItem,show:e.catalogsModalVisible,t:e.t,"all-catalogs":e.showingAllCatalogs,onHidden:t[0]||(t[0]=t=>e.catalogsModalVisible=!1)},null,8,[`instance-id`,`item`,`show`,`t`,`all-catalogs`])],64)}var bA=Q(pA,[[`render`,yA]]),xA=L({name:`pis-catalogs-products-search-pagination`,components:{Pagination:tx,PaginationAmount:Yv},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isWebComponent:r,isReady:i,instance:a,store:o,routeData:s,t:c,widerThan:l,narrowerThan:u}=ym(t,e.instanceId,[Ud.Products]);return{root:t,componentName:n,isWebComponent:r,isReady:i,store:o,totalCount:Y(()=>{var e;return((e=o.value)==null||(e=e.data.products)==null?void 0:e.totalCount)??0}),pagination:Y(()=>{var e;return(e=s.value)==null?void 0:e.products.pagination}),routeData:s,t:c,widerThan:l,narrowerThan:u,changePage:e=>{a.value&&a.value.execute(new Vu({page:e}).from(n))}}}}),SA={ref:`root`,class:`pis-component`,"aria-label":`Items page navigation`},CA={class:`my-2`};function wA(e,t,n,r,i,a){let o=R(`PaginationAmount`),s=R(`Pagination`);return H(),U(`nav`,SA,[e.isReady?(H(),U(V,{key:0},[e.totalCount&&e.pagination?(H(),U(`div`,{key:0,class:A([`d-flex align-items-center justify-content-between mt-4`,[e.widerThan(`md`)?`flex-row`:`flex-column`]])},[G(`div`,CA,[K(o,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0)},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`])]),K(s,{class:A([`my-2`,e.componentName]),total:Math.ceil(e.totalCount/e.pagination.pageSize),current:e.pagination.page,"narrow-than":e.narrowerThan,onChange:e.changePage},null,8,[`class`,`total`,`current`,`narrow-than`,`onChange`])],2)):J(``,!0)],64)):J(``,!0)],512)}var TA=Q(xA,[[`render`,wA]]),EA=L({name:`pis-catalogs-products-search-part-categories`,components:{LinkSecondary:kE,Card:SE,CategoriesList:Hy,Message:NE,Arrow:qb},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!0),{isReady:r,isWebComponent:i,componentName:a,instance:o,store:s,t:c}=ym(t,e.instanceId,[Ud.ProductClassifications]),l=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.partCategories)??{}}),u=Y(()=>{var e;return((e=s.value)==null||(e=e.data.partClassifications)==null?void 0:e.items)??[]});return{root:t,isReady:r,isWebComponent:i,componentName:a,componentOptions:l,trimList:n,store:s,visible:Y(()=>l.value.visible),categories:u,categoriesTrimmed:Y(()=>{var e;return n.value?(e=u.value)==null?void 0:e.slice(0,l.value.maxCategoriesVisible):u.value}),showMoreBtn:Y(()=>u.value&&u.value.length>(l.value.maxCategoriesVisible??0)),t:c,setCategory:({cid:e})=>{o.value&&e&&o.value.execute(new Au({cid:e,treeType:`Parts`,clearSearch:!1}).from(a))},showAllCategories:()=>{n.value=!n.value}}}}),DA={key:1,class:`card-body`},OA={key:1,class:`card-body`};function kA(e,t,n,r,i,a){let o=R(`CategoriesList`),s=R(`Arrow`),c=R(`LinkSecondary`),l=R(`Message`),u=R(`Card`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),W(u,{key:0,class:`mb-4`,icon:e.componentOptions.icon&&`folder-open`,header:e.t(`PartsAndServices`),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{list:P(()=>{var t,n;return[(t=e.categories)!=null&&t.length?(H(),U(V,{key:0},[(n=e.categories)!=null&&n.length?(H(),W(o,{key:0,categories:e.categoriesTrimmed,onClickItem:e.setCategory},null,8,[`categories`,`onClickItem`])):J(``,!0),e.showMoreBtn?(H(),U(`div`,DA,[K(c,{onClick:X(e.showAllCategories,[`prevent`])},{default:P(()=>[K(s,{class:`me-2`,dir:e.trimList?`down`:`up`},null,8,[`dir`]),q(` `+j(e.trimList?e.t(`ShowAllCategories`):e.t(`HideAllCategories`))+` (`+j(e.categories.length)+`) `,1)]),_:1},8,[`onClick`])])):J(``,!0)],64)):(H(),U(`div`,OA,[K(l,null,{default:P(()=>[q(j(e.t(`NoCategories`)),1)]),_:1})]))]}),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])):J(``,!0)],2)}var AA=Q(EA,[[`render`,kA]]),jA=L({name:`pis-catalogs-products-search-product-categories`,components:{LinkSecondary:kE,Card:SE,CategoriesList:Hy,Message:NE,Arrow:qb},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!0),{isReady:r,isWebComponent:i,componentName:a,instance:o,store:s,t:c}=ym(t,e.instanceId,[Ud.ProductClassifications]),l=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.productCategories)??{}}),u=Y(()=>{var e;return((e=s.value)==null||(e=e.data.productClassifications)==null?void 0:e.items)??[]});return{root:t,isReady:r,isWebComponent:i,componentName:a,componentOptions:l,trimList:n,store:s,visible:Y(()=>l.value.visible),categories:u,categoriesTrimmed:Y(()=>{var e;return n.value?(e=u.value)==null?void 0:e.slice(0,l.value.maxCategoriesVisible):u.value}),showMoreBtn:Y(()=>u.value&&u.value.length>(l.value.maxCategoriesVisible??0)),t:c,setCategory:({cid:e})=>{o.value&&e&&o.value.execute(new Au({cid:e,treeType:`Products`,clearSearch:!1}).from(a))},showAllCategories:()=>{n.value=!n.value}}}}),MA={key:1,class:`card-body`},NA={key:1,class:`card-body`};function PA(e,t,n,r,i,a){let o=R(`CategoriesList`),s=R(`Arrow`),c=R(`LinkSecondary`),l=R(`Message`),u=R(`Card`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),W(u,{key:0,class:`mb-4`,icon:e.componentOptions.icon&&`folder-open`,header:e.t(`Products`),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{list:P(()=>{var t,n;return[(t=e.categories)!=null&&t.length?(H(),U(V,{key:0},[(n=e.categories)!=null&&n.length?(H(),W(o,{key:0,categories:e.categoriesTrimmed,onClickItem:e.setCategory},null,8,[`categories`,`onClickItem`])):J(``,!0),e.showMoreBtn?(H(),U(`div`,MA,[K(c,{onClick:X(e.showAllCategories,[`prevent`])},{default:P(()=>[K(s,{class:`me-2`,dir:e.trimList?`down`:`up`},null,8,[`dir`]),q(` `+j(e.trimList?e.t(`ShowAllCategories`):e.t(`HideAllCategories`))+` (`+j(e.categories.length)+`) `,1)]),_:1},8,[`onClick`])])):J(``,!0)],64)):(H(),U(`div`,NA,[K(l,null,{default:P(()=>[q(j(e.t(`NoCategories`)),1)]),_:1})]))]}),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])):J(``,!0)],2)}var FA=Q(jA,[[`render`,PA]]),IA=L({name:`pis-catalogs-products-search-selection`,components:{MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,widerThan:s,t:c}=ym(t,e.instanceId,[Ud.Products]),l=Y(()=>{var e;return(e=o.value)==null||(e=e.options)==null||(e=e.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.selection});return{root:t,instance:n,componentName:r,isReady:i,visible:Y(()=>{var e;return(e=o.value)==null||(e=e.options)==null||(e=e.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.selection)==null?void 0:e.visible}),isWebComponent:a,store:o,componentOptions:l,widerThan:s,t:c,reactiveContext:lg}}}),LA={key:0,class:`card p-2`},RA={class:`row`},zA={key:0,class:`me-3`},BA={key:1};function VA(e,t,n,r,i,a){var o,s,c,l,u,d;let f=R(`MountPoint`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,LA,[G(`div`,RA,[(o=e.componentOptions)!=null&&o.countVisible?(H(),U(`div`,{key:0,class:A([e.widerThan(`md`)?`col-2`:`col-12`])},[G(`strong`,null,j((s=e.instance)==null?void 0:s.selection.count),1),q(` `+j(e.t(`ItemsSelected`,!0)),1)],2)):J(``,!0),G(`div`,{class:A([[e.widerThan(`md`)?`col-4`:`col-12`],`d-flex flex-row`])},[(c=e.componentOptions)!=null&&c.selectAllVisible?(H(),U(`div`,zA,[G(`a`,{href:``,onClick:t[0]||(t[0]=X(()=>{var t;return(t=e.instance)==null?void 0:t.selection.selectAll()},[`prevent`]))},j(e.t(`SelectAll`,!0)),1)])):J(``,!0),(l=e.componentOptions)!=null&&l.deselectAllVisible&&(u=e.instance)!=null&&u.selection.count?(H(),U(`div`,BA,[G(`a`,{href:``,onClick:t[1]||(t[1]=X(()=>{var t;return(t=e.instance)==null?void 0:t.selection.clear()},[`prevent`]))},j(e.t(`DeselectAll`,!0)),1)])):J(``,!0)],2),(d=e.componentOptions)!=null&&d.actionsTemplate?(H(),U(`div`,{key:1,class:A([e.widerThan(`md`)?`col-6 text-end`:`col-12 `])},[K(f,{callbacks:e.componentOptions.actionsTemplate,ctx:e.reactiveContext({instance:e.instance,t:e.t})},null,8,[`callbacks`,`ctx`])],2)):J(``,!0)])])):J(``,!0)],2)}var HA=Q(IA,[[`render`,VA]]),UA=L({name:`pis-catalogs-products-search-table`,components:{Icon:$h,Clickable:wm,MountPoint:cg,ItemCatalogsDetails:Tk},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=Vl,{componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,routeData:c,emit:l,t:u}=ym(t,e.instanceId,[Ud.Products]),d=Y(()=>{var e;return((e=s.value)==null||(e=e.data.products)==null?void 0:e.items)||[]}),f=Y(()=>{var e;return((e=o.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-preview`))??!1}),p=e=>e.baseProduct&&e.baseProduct.inactive||e.inactive,m=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.table)??{}}),h=Y(()=>m.value.columns),g=async e=>{if(!e.inactive)try{if(c.value&&e){var t;await((t=o.value)==null?void 0:t.execute(new _u(e).from(r)))}}catch{}},_=async e=>{if(e&&!e.inactive)try{var t;await((t=o.value)==null?void 0:t.execute(new _u(e).from(r)))}catch{}};return{root:t,componentName:r,componentOptions:m,instance:o,isReady:i,isWebComponent:a,store:s,routeData:c,productsItems:d,previewEnabled:f,columns:h,showingAllCatalogs:Y(()=>{var e;return!((e=c.value)!=null&&e.products.catalogId)}),catalogProductType:n,CatalogProductTypeEnum:Vl,t:u,emit:l,details:g,previewByProductId:async e=>{try{var t;await((t=o.value)==null?void 0:t.execute(new ju({productId:e}).from(r)))}catch{}},attrValue:Us,additionalInfo:Gs,attrValues:Ws,isPreviewDisabled:p,toggleItemDetails:e=>{e.expanded=!e.expanded},baseProductDetails:_,reactiveContext:lg,cellCtx:hg(e=>({col:e.col,item:e.item,instance:o.value,catalogProductType:n,CatalogProductTypeEnum:Vl,t:u,emit:l,details:g,attrValue:Us,attrValues:Ws,baseProductDetails:_}))}}}),WA={key:0,class:`table-responsive pis-scroll`},GA={class:`table`},KA={key:0,style:{width:`1%`}},qA={key:1,style:{width:`1%`}},JA={key:2,style:{width:`1%`}},YA={key:0},XA={key:1},ZA={key:2},QA={key:0},$A={class:`ext-select-checkbox`},ej=[`checked`,`onClick`],tj={key:1},nj={key:1},rj={key:1,class:`fw-bold text-muted`},ij={class:`text-muted small`},aj={key:0},oj={key:1},sj={key:2},cj={key:1,class:`fw-bold text-muted`},lj={key:2},uj={key:2},dj=[`onClick`],fj={key:0},pj={key:0},mj={key:1},hj=[`colspan`];function gj(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Icon`),c=R(`Clickable`),l=R(`ItemCatalogsDetails`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(V,{key:0},[e.productsItems&&e.productsItems.length?(H(),U(`div`,WA,[G(`table`,GA,[G(`colgroup`,null,[e.componentOptions.selectable?(H(),U(`col`,KA)):J(``,!0),e.previewEnabled?(H(),U(`col`,qA)):J(``,!0),(H(!0),U(V,null,z(e.columns,(e,t)=>(H(),U(`col`,{key:t,style:k({width:e.width})},null,4))),128)),e.componentOptions.detailsVisible?(H(),U(`col`,JA)):J(``,!0)]),G(`thead`,null,[G(`tr`,null,[e.componentOptions.selectable?(H(),U(`th`,YA)):J(``,!0),e.previewEnabled?(H(),U(`th`,XA)):J(``,!0),(H(!0),U(V,null,z(e.columns,(t,n)=>(H(),U(`th`,{key:n},[t.headerTemplate?(H(),W(o,{key:0,callbacks:t.headerTemplate,ctx:e.reactiveContext({t:e.t,col:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(t.caption),1)],64))]))),128)),e.componentOptions.detailsVisible?(H(),U(`th`,ZA)):J(``,!0)])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.productsItems,n=>{var r,i,a,u;return H(),U(V,{key:n.productId},[G(`tr`,{class:A({"bg-light":n.exactMatch,"no-border-bottom":n.expanded,"ext-selected":(r=e.instance)==null?void 0:r.selection.isSelected(n)})},[e.componentOptions.selectable?(H(),U(`td`,QA,[G(`div`,$A,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(i=e.instance)==null?void 0:i.selection.isSelected(n),onClick:t=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(n)}},null,8,ej)])])):J(``,!0),e.previewEnabled?(H(),U(`td`,tj,[K(c,{class:`d-flex ext-icon-preview`,title:e.t(e.isPreviewDisabled(n)?`PreviewNotAvailable`:`Preview`,!0),disabled:e.isPreviewDisabled(n),onClick:X(t=>{var r;return!e.isPreviewDisabled(n)&&e.previewByProductId(((r=n.baseProduct)==null?void 0:r.productId)||n.alternateProductId||n.productId)},[`prevent`])},{default:P(()=>[K(s,{name:`eye-show`,size:24})]),_:1},8,[`title`,`disabled`,`onClick`])])):J(``,!0),(H(!0),U(V,null,z(e.columns,(r,i)=>(H(),U(`td`,{key:i},[r.cellTemplate?(H(),W(o,{key:0,callbacks:r.cellTemplate,ctx:e.cellCtx({item:n,col:r})},null,8,[`callbacks`,`ctx`])):r.dataField===`ProductId`?(H(),U(`div`,nj,[n.inactive?(H(),U(`span`,rj,j(e.attrValue(n,r.dataField)),1)):(H(),W(c,{key:0,onClick:t=>e.details(n)},{default:P(()=>[q(j(e.attrValue(n,r.dataField)),1)]),_:2},1032,[`onClick`])),G(`div`,ij,[n.productType==e.catalogProductType.CONFIGURED?(H(),U(`em`,aj,[q(j(e.t(`ConfiguredProducts`))+` `,1),t[0]||(t[0]=G(`br`,null,null,-1))])):J(``,!0),n.customerClassification?(H(),U(`em`,oj,[q(j(e.t(`CustomerClassification`))+`:\xA0 `+j(n.customerClassification)+` `,1),t[1]||(t[1]=G(`br`,null,null,-1))])):J(``,!0),n.baseProduct?(H(),U(`em`,sj,[q(j(e.t(`BaseProductId`))+`:\xA0 `,1),n.baseProduct.inactive?(H(),U(`span`,cj,j(n.baseProduct.productId),1)):(H(),W(c,{key:0,onClick:t=>e.baseProductDetails(n.baseProduct)},{default:P(()=>[q(j(n.baseProduct.productId),1)]),_:2},1032,[`onClick`])),t[2]||(t[2]=G(`br`,null,null,-1))])):J(``,!0)])])):(H(),U(`div`,lj,j(e.attrValue(n,r.dataField)),1)),r.showAllIdentifiers?(H(!0),U(V,{key:3},z(e.attrValues(n,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`small text-muted fw-bold`},j(e),1))),128)):J(``,!0)]))),128)),e.componentOptions.detailsVisible?(H(),U(`td`,uj,[G(`a`,{href:``,class:`btn btn-link text-dark d-flex align-items-center`,onClick:X(t=>e.toggleItemDetails(n),[`prevent`])},[K(s,{name:n.expanded?`minus-remove`:`plus-add`,class:`py-1`,style:{"font-size":`1.1rem`}},null,8,[`name`])],8,dj)])):J(``,!0)],2),n.expanded?(H(),U(`tr`,fj,[e.componentOptions.selectable?(H(),U(`td`,pj)):J(``,!0),e.previewEnabled?(H(),U(`td`,mj)):J(``,!0),G(`td`,{colspan:(a=e.columns)==null?void 0:a.length},[K(l,{item:n,t:e.t,"all-catalogs":e.showingAllCatalogs,"instance-id":(u=e.instance)==null?void 0:u.id},null,8,[`item`,`t`,`all-catalogs`,`instance-id`])],8,hj),t[3]||(t[3]=G(`td`,null,null,-1))])):J(``,!0)],64)}),128))])])])):J(``,!0)],64)):J(``,!0)],2)}var _j=Q(UA,[[`render`,gj]]),vj=L({name:`pis-catalogs-products-search-toolbar`,components:{PaginationAmount:Yv,Icon:$h,Clickable:wm,Btn:Iy,Dropdown:pb,Arrow:qb,DropdownPopper:Wv,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e,{emit:t}){let n=M(),r=M(!1),i=M(void 0),a={LastImport:Bl.LAST_IMPORT,Product:Bl.PRODUCT,LastModified:Bl.LAST_MODIFIED},{componentName:o,isReady:s,isWebComponent:c,instance:l,store:u,routeData:d,t:f,widerThan:p,narrowerThan:m}=ym(n,e.instanceId),{onProductListMenuAction:h}=bm(l,f,o),g=[{type:`table`,tName:`DisplayModeTable`,icon:`data-table-grid`,relatedComponent:`pis-catalogs-products-search-table-router-view`},{type:`list`,tName:`DisplayModeList`,icon:`list-bullet-options`,relatedComponent:`pis-catalogs-products-search-list-router-view`},{type:`grid`,tName:`DisplayModeGrid`,icon:`grid-matrix`,relatedComponent:`pis-catalogs-products-search-grid-router-view`}],_=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.subViews}),v=Y(()=>{if(!_.value)return g;let e=g.filter(({type:e,relatedComponent:t})=>{var n,r;return((n=_.value)==null?void 0:n.includes(e))&&((r=l.value)==null?void 0:r.registeredComponents.has(t))}),t=[];return _.value.forEach(n=>{var r=e.find(e=>e.type==n);r&&t.push(r)}),t}),y=Y(()=>{var e;return(e=u.value)==null||(e=e.data.products)==null?void 0:e.totalCount}),b=Y(()=>{var e;return(e=d.value)==null?void 0:e.products.pagination}),x=Y({get:()=>{var e;return(e=d.value)==null?void 0:e.products.sortField},set:e=>{var t;return(t=l.value)==null?void 0:t.execute(new Bu({sortField:e}).from(o))}}),S=Y({get:()=>{var e;return((e=b.value)==null?void 0:e.pageSize)??24},set:e=>{var t;return(t=l.value)==null?void 0:t.execute(new Ru({pageSize:e}).from(o))}}),C=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.pageSizes}),w=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.visible}),T=e=>{var t;(t=l.value)==null||t.execute(new Lu({subView:e}).from(o))},E=({type:e})=>{var t;return e===((t=d.value)==null?void 0:t.products.subView)},D=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null||(e=e.actions)==null?void 0:e.productListMenu}),ee=()=>{var e;return(((e=D.value)==null?void 0:e.items)||[]).filter(e=>typeof e.visible==`function`?e.visible():e.visible)},O=e=>typeof e.disabled==`function`?e.disabled():e.disabled,te=Y(()=>{var e,t;return((e=l.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-search-actions-modals`))&&((t=D.value)==null?void 0:t.visible)}),ne=()=>{var e,t;if(!(d!=null&&(e=d.value)!=null&&e.products.catalogId)){i.value=void 0;return}i.value=((t=u.value)==null||(t=t.data.catalogs)==null||(t=t.items)==null?void 0:t.find(e=>{var t;return e.id===(d==null||(t=d.value)==null?void 0:t.products.catalogId)}))||void 0};return I(()=>{var e;return d==null||(e=d.value)==null?void 0:e.products.catalogId},()=>ne()),{root:n,componentName:o,isReady:s,isWebComponent:c,store:u,routeData:d,toolbarVisible:w,subViews:g,visibleSubViews:v,totalCount:y,pagination:b,sortByItems:a,sortBy:x,pageSizeItems:C,pageSize:S,exportMenuOpen:r,productListMenu:D,actionsEnabled:te,instance:l,currentCatalog:i,t:f,emit:t,widerThan:p,isDisabled:O,isSubViewActive:E,narrowerThan:m,changeSubView:T,productListMenuItems:ee,onProductListMenuAction:h,reactiveContext:lg,itemCtx:hg(e=>({instance:l.value,item:e.item,emit:t,t:f}))}}}),yj={class:`d-flex flex-row justify-content-between align-items-center flex-wrap w-100`},bj=[`value`],xj=[`value`,`textContent`],Sj={class:`my-3 d-flex flex-row justify-content-between align-items-center flex-wrap`},Cj={key:0,class:`my-2 mx-2`},wj={key:1,class:`list-unstyled d-flex justify-content-center my-2 mx-2`},Tj={key:0},Ej={key:1,type:`button`,class:`btn btn-primary dropdown-toggle`},Dj={class:`dropdown-menu show`},Oj={key:0,class:`dropdown-divider`},kj={key:1,class:`dropdown-item text-muted`},Aj=[`onClick`];function jj(e,t,n,r,i,a){var o,s;let c=R(`PaginationAmount`),l=R(`Icon`),u=R(`MountPoint`),d=R(`DropdownPopper`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.toolbarVisible?(H(),U(V,{key:0},[G(`div`,yj,[G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`SortBy`))+`:`,3),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.sortBy=t),class:A([`form-select ms-2`,[e.narrowerThan(`xl`)&&`w-100`]])},[(H(!0),U(V,null,z(e.sortByItems,(t,n)=>(H(),U(`option`,{key:n,value:n},j(e.t(`SortBy${t}`)),9,bj))),128))],2),[[Cs,e.sortBy]])],2),G(`label`,{class:A([`d-flex align-items-center my-1`,[e.narrowerThan(`sm`)&&`w-100`]])},[G(`span`,{class:A([`text-nowrap`,[e.narrowerThan(`sm`)&&`w-100`]])},j(e.t(`PageSize`))+`:`,3),F(G(`select`,{"onUpdate:modelValue":t[1]||(t[1]=t=>e.pageSize=t),class:`form-select ms-2`},[(H(!0),U(V,null,z(e.pageSizeItems,e=>(H(),U(`option`,{key:e,value:e,textContent:j(e)},null,8,xj))),128))],512),[[Cs,e.pageSize]])],2)]),G(`div`,Sj,[e.totalCount&&e.pagination?(H(),U(`div`,Cj,[K(c,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0),class:A([e.narrowerThan(`sm`)&&`w-100 text-center`])},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`,`class`])])):J(``,!0),(o=e.visibleSubViews)!=null&&o.length&&e.visibleSubViews.length>1?(H(),U(`ul`,wj,[(H(!0),U(V,null,z(e.visibleSubViews,t=>(H(),U(`li`,{key:t.type},[(H(),W(Vr(e.isSubViewActive(t)?`div`:`Clickable`),{class:A([`d-flex align-items-center py-2 mx-2 text-body text-decoration-none`,[e.isSubViewActive(t)&&`active border-bottom border-primary border-2`]]),role:`tab`,"aria-selected":e.isSubViewActive(t),title:`${e.t(`ChangeDisplayModeTo`)} ${e.t(t.tName)}`,onClick:X(n=>e.changeSubView(t.type),[`prevent`])},{default:P(()=>[K(l,{name:t.icon,class:`mx-1`},null,8,[`name`]),e.widerThan(`sm`)?(H(),U(`span`,Tj,j(e.t(t.tName)),1)):J(``,!0)]),_:2},1032,[`class`,`aria-selected`,`title`,`onClick`]))]))),128))])):J(``,!0),e.actionsEnabled&&(s=e.productListMenu)!=null&&s.items?(H(),U(`div`,{key:2,class:A([`d-flex my-1`,[e.narrowerThan(`sm`)&&`w-100 justify-content-end`]])},[K(d,{placement:`bottom-start`,interactive:!0},{trigger:P(()=>[e.productListMenu.buttonTemplate?(H(),W(u,{key:0,callbacks:e.productListMenu.buttonTemplate,ctx:e.reactiveContext({instance:e.instance,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])):(H(),U(`button`,Ej,j(e.t(`Actions`)),1))]),dropdown:P(({close:t})=>[G(`ul`,Dj,[(H(!0),U(V,null,z(e.productListMenuItems(),(n,r)=>(H(),U(`li`,{key:r},[n.text===`-`?(H(),U(`hr`,Oj)):e.isDisabled(n)?(H(),U(`span`,kj,[n.itemTemplate?(H(),W(u,{key:0,callbacks:n.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(n.text),1)],64))])):(H(),U(`a`,{key:2,class:`dropdown-item`,href:``,onClick:X(r=>{e.onProductListMenuAction(n),t()},[`prevent`])},[n.itemTemplate?(H(),W(u,{key:0,callbacks:n.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(n.text),1)],64))],8,Aj))]))),128))])]),_:1})],2)):J(``,!0)])],64)):J(``,!0)],2)}var Mj=Q(vj,[[`render`,jj]]),Nj=L({name:`pis-catalogs-products-search-grid-router-view`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i,routeData:a}=ym(t,e.instanceId,[Ud.Products]);return{root:t,componentName:n,isReady:r,store:i,routeData:a}}}),Pj={key:0};function Fj(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&e.routeData&&e.routeData.view===`products`&&e.routeData.products.subView==`grid`?(H(),U(`div`,Pj,[B(e.$slots,`default`)])):J(``,!0)],2)}var Ij=Q(Nj,[[`render`,Fj]]),Lj=L({name:`pis-catalogs-products-search-list-router-view`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i,routeData:a}=ym(t,e.instanceId,[Ud.Products]);return{root:t,componentName:n,isReady:r,store:i,routeData:a}}}),Rj={key:0};function zj(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&e.routeData&&e.routeData.view===`products`&&e.routeData.products.subView==`list`?(H(),U(`div`,Rj,[B(e.$slots,`default`)])):J(``,!0)],2)}var Bj=Q(Lj,[[`render`,zj]]),Vj=L({name:`pis-catalogs-products-search-table-router-view`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i,routeData:a}=ym(t,e.instanceId,[Ud.Products]);return{root:t,componentName:n,isReady:r,store:i,routeData:a}}}),Hj={key:0};function Uj(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&e.routeData&&e.routeData.view===`products`&&e.routeData.products.subView==`table`?(H(),U(`div`,Hj,[B(e.$slots,`default`)])):J(``,!0)],2)}var Wj=Q(Vj,[[`render`,Uj]]),Gj=L({components:{FiltersNavigatorModalBase:QD},inheritAttrs:!1,props:{show:Boolean,title:{type:String,required:!0},isMobile:Boolean,t:{type:Function,required:!0},filtersAll:{type:Array,default:void 0},filtersPromoted:{type:Array,default:void 0},filtersAdditional:{type:Array,default:void 0},filtersFetched:Map,filtersModel:{type:Object,default:void 0},filteredResultCount:{type:Number,default:void 0},filteredResultCountLoading:Boolean,fetchFilterValues:{type:Function,required:!0}}});function Kj(e,t,n,r,i,a){let o=R(`FiltersNavigatorModalBase`);return H(),W(o,Oa(e.$attrs,{show:e.show,title:e.title,"is-mobile":e.isMobile,t:e.t,"filters-all":e.filtersAll,"filters-promoted":e.filtersPromoted,"filters-additional":e.filtersAdditional,"filters-fetched":e.filtersFetched,"filters-model":e.filtersModel,"filtered-result-count":e.filteredResultCount,"filtered-result-count-loading":e.filteredResultCountLoading,"fetch-filter-values":e.fetchFilterValues,"available-filters-label-suffix":`:`}),null,16,[`show`,`title`,`is-mobile`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-fetched`,`filters-model`,`filtered-result-count`,`filtered-result-count-loading`,`fetch-filter-values`])}var qj=L({name:`pis-catalogs-products-search-mobile-nav`,components:{Btn:Iy,Modal:Qy,CategoriesList:Hy,FiltersNavigatorModal:Q(Gj,[[`render`,Kj]])},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=M(!1),i=M(!1),{componentName:a,isWebComponent:o,isReady:s,instance:c,store:l,t:u,useProductsFilters:d}=ym(t,e.instanceId,[Ud.Breadcrumbs]),{filtersAll:f,filtersPromoted:p,filtersAdditional:m,filtersModel:h,filtersFetched:g,filteredResultCount:_,fetchFilterValues:v,applyModelFilters:y,refreshResultCount:b,resetFiltersApplied:x}=d(),S=Y(()=>{var e,t;return((e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-search-product-categories`))&&((t=l.value)==null||(t=t.options.components)==null||(t=t.products)==null||(t=t.search)==null||(t=t.productCategories)==null?void 0:t.visible)}),C=Y(()=>{var e,t;return((e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-search-part-categories`))&&((t=l.value)==null||(t=t.options.components)==null||(t=t.products)==null||(t=t.search)==null||(t=t.partCategories)==null?void 0:t.visible)}),w=Y(()=>{var e;return(e=c.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-search-filters`)}),T=Y(()=>{var e;return((e=l.value)==null||(e=e.data.productClassifications)==null?void 0:e.items)??[]}),E=Y(()=>{var e;return((e=l.value)==null||(e=e.data.partClassifications)==null?void 0:e.items)??[]});return{root:t,componentName:a,isWebComponent:o,isReady:s,store:l,columnsNumber:Y(()=>{let e=[S.value,C.value,w.value].filter(Boolean).length;return e>3?3:e}),t:u,instance:c,categoriesModalOpen:n,categories:T,categoriesShown:S,setCategory:async({cid:e})=>{if(c.value&&e){n.value=!1;try{await c.value.execute(new Au({cid:e,clearSearch:!1,treeType:ou.PRODUCTS}).from(a))}catch{}}},partCategoriesModalOpen:r,partCategories:E,partCategoriesShown:C,setPartCategory:async({cid:e})=>{if(c.value&&e){r.value=!1;try{await c.value.execute(new Au({cid:e,clearSearch:!1,treeType:ou.PARTS}).from(a))}catch{}}},filtersModalOpen:i,filtersShown:w,filtersAll:f,filtersPromoted:p,filtersAdditional:m,filtersModel:h,filtersFetched:g,filteredResultCount:_,onModalFilterValueChange:({attributeCode:e,filterValueName:t,value:n})=>{h.value[e][t]=n,b()},fetchFilterValues:v,resetFiltersApplied:x,applyFilters:()=>{i.value=!1,y()}}}}),Jj={class:`mb-4 row g-2`};function Yj(e,t,n,r,i,a){let o=R(`Btn`),s=R(`CategoriesList`),c=R(`Modal`),l=R(`FiltersNavigatorModal`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(V,{key:0},[G(`nav`,Jj,[e.categoriesShown?(H(),U(`div`,{key:0,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`folder-open`,class:`w-100 h-100`,vertical:``,disabled:!e.categories.length,number:e.categories.length,onClick:t[0]||(t[0]=X(t=>e.categoriesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`Products`)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0),e.partCategoriesShown?(H(),U(`div`,{key:1,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`folder-open`,class:`w-100 h-100`,vertical:``,disabled:!e.partCategories.length,number:e.partCategories.length,onClick:t[1]||(t[1]=X(t=>e.partCategoriesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`PartsAndServices`)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0),e.filtersShown?(H(),U(`div`,{key:2,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`funnel-filter`,class:`w-100 h-100`,vertical:``,disabled:!e.filtersAll.length,number:e.filtersAll.length,onClick:t[2]||(t[2]=X(t=>e.filtersModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`Filters`,!0)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0)]),K(c,{show:e.categoriesModalOpen,"onUpdate:show":t[3]||(t[3]=t=>e.categoriesModalOpen=t),title:e.t(`AllOfferings`)},{default:P(()=>[K(s,{categories:e.categories,"configurators-visible":!1,onClickItem:e.setCategory},null,8,[`categories`,`onClickItem`])]),_:1},8,[`show`,`title`]),K(c,{show:e.partCategoriesModalOpen,"onUpdate:show":t[4]||(t[4]=t=>e.partCategoriesModalOpen=t),title:e.t(`PartsAndServices`)},{default:P(()=>[K(s,{categories:e.partCategories,"configurators-visible":!1,onClickItem:e.setPartCategory},null,8,[`categories`,`onClickItem`])]),_:1},8,[`show`,`title`]),e.filtersModalOpen?(H(),W(l,{key:0,show:e.filtersModalOpen,"onUpdate:show":t[5]||(t[5]=t=>e.filtersModalOpen=t),title:e.t(`Filters`,!0),"is-mobile":``,t:e.t,"filters-all":e.filtersAll,"filters-promoted":e.filtersPromoted,"filters-additional":e.filtersAdditional,"filters-model":e.filtersModel,"filters-fetched":e.filtersFetched,"filtered-result-count":e.filteredResultCount,"fetch-filter-values":e.fetchFilterValues,onValueChange:e.onModalFilterValueChange,onApplyFilters:e.applyFilters,onClear:e.resetFiltersApplied},null,8,[`show`,`title`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-model`,`filters-fetched`,`filtered-result-count`,`fetch-filter-values`,`onValueChange`,`onApplyFilters`,`onClear`])):J(``,!0)],64)):J(``,!0)],2)}var Xj=Q(qj,[[`render`,Yj]]),Zj=L({props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},editable:{type:Boolean,default:!0},type:{type:String,default:Wl.PERSONAL}},emits:[`on-type-updated`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=Wl,i=M([]),a=M(e.type);return I(()=>a.value,()=>t(`on-type-updated`,a.value)),kr(async()=>{try{let t=await n.execute(new td().from(`catalog-options`));if(!t)throw Error(e.t(`CatalogOptionsLoadingError`));i.value=t.items||[]}catch(e){await n.execute(new pd({type:`danger`,message:e.message}).from(`catalog-options`))}}),{ownerType:a,catalogType:r,catalogOptions:i}}}),Qj={class:`form-check mt-3`},$j={class:`form-check-label`},eM=[`value`,`disabled`],tM={class:`form-label fw-bolder`};function nM(e,t,n,r,i,a){return H(!0),U(V,null,z(e.catalogOptions,n=>(H(),U(`div`,{key:n.type},[G(`div`,Qj,[G(`label`,$j,[F(G(`input`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.ownerType=t),name:`catalogType`,type:`radio`,class:`form-check-input`,value:n.type,disabled:!e.editable},null,8,eM),[[Ss,e.ownerType]]),G(`div`,tM,j(e.t(`${n.type}Catalog`)),1)])])]))),128)}var rM=Q(Zj,[[`render`,nM]]),iM=L({components:{Popper:Vv},props:{modelValue:{type:null,default:null,required:!1},items:{type:Array,default:void 0}},emits:[`update:modelValue`],setup(e,{emit:t}){let n=M(!1),r=M(),i=M(),a=M(),o=M(),s=M(``),c=Y(()=>e.items==null?[]:e.items.filter(e=>e.type===`fixed`||e.type===`divider`));return{expanded:n,innerValue:r,inputEl:a,toggleEl:i,ddEl:o,filter:s,filteredItems:Y(()=>s.value!=null&&e.items!=null?e.items.filter(e=>e.type===`standard`&&e.text.toLowerCase().indexOf(s.value.toLowerCase())>=0):[]),fixedItems:c,open:()=>{o.value&&i.value&&(o.value.style.width=i.value.clientWidth+2+`px`),setTimeout(()=>{a.value&&a.value.focus()},10)},select:e=>{t(`update:modelValue`,e.value),r.value=e}}}}),aM={class:`position-relative w-100`},oM={ref:`ddEl`,class:`dropdown-menu p-1 dropdown-menu-select position-relative d-block shadow`,style:{"margin-top":`3rem`}},sM=[`onClick`],cM={key:1,class:`dropdown-divider`},lM={class:`p-2`},uM=[`onClick`];function dM(e,t,n,r,i,a){let o=R(`Popper`);return H(),U(`div`,aM,[K(o,{class:`pis-no-transform`,placement:`bottom-start`,"onOpen:popper":e.open},{content:P(({close:n})=>[G(`ul`,oM,[(H(!0),U(V,null,z(e.fixedItems,(t,r)=>(H(),U(`li`,{key:r},[t.type===`fixed`?(H(),U(`a`,{key:0,class:`dropdown-item text-wrap w-100`,href:`#`,onClick:r=>{n(),e.select(t)}},j(t.text),9,sM)):t.type===`divider`?(H(),U(`hr`,cM)):J(``,!0)]))),128)),G(`li`,lM,[F(G(`input`,{ref:`inputEl`,"onUpdate:modelValue":t[0]||(t[0]=t=>e.filter=t),type:`text`,class:`form-control`},null,512),[[ys,e.filter]])]),G(`li`,null,[G(`ul`,null,[(H(!0),U(V,null,z(e.filteredItems,(t,r)=>(H(),U(`li`,{key:r},[G(`a`,{class:`dropdown-item text-wrap w-100`,href:`#`,onClick:r=>{n(),e.select(t)}},j(t.text),9,uM)]))),128))])])],512)]),default:P(()=>{var t;return[G(`button`,{ref:`toggleEl`,type:`button`,class:`btn btn-secondary dropdown-toggle dropdown-toggle-select w-100 text-start form-select`},j((t=e.innerValue)==null?void 0:t.text),513)]}),_:1},8,[`onOpen:popper`])])}var fM=Q(iM,[[`render`,dM]]),pM=L({props:{modelValue:{type:String,default:void 0},placeholder:{type:String,default:void 0},classInner:{type:String,default:void 0},lg:Boolean,cols:{type:Number,default:1},rows:{type:Number,default:1},validators:{type:Object,default:null}},emits:[`update:modelValue`,`update:validation`,`change`,`clear`],setup(e,{emit:t}){let n=M(``),r=M(!1),i=M(!0),a=M({}),o=Y({get:()=>n.value,set:e=>{n.value=e,r.value=!0,t(`update:modelValue`,e)}}),s=e=>{setTimeout(()=>{n.value=e},10)},c=()=>{s(``),t(`clear`),t(`update:modelValue`,``)},l=()=>s(e.modelValue);return I(()=>e.modelValue,()=>l()),I(()=>n.value,n=>{let o={};r.value&&e.validators&&Object.assign(o,xb(n,e.validators)),a.value=o,i.value=!Object.keys(o).length,t(`update:validation`,a.value)}),kr(()=>l()),{isValid:i,innerValue:n,computedValue:o,validationErrors:a,clear:c}}}),mM={class:`position-relative flex-grow-1 has-validation`},hM=[`placeholder`],gM={key:0,class:`position-absolute top-50 end-0 translate-middle-y pe-1`},_M={key:1,class:`invalid-feedback d-block`},vM={key:0},yM={key:1},bM={key:2},xM={key:3};function SM(e,t,n,r,i,a){var o;return H(),U(`div`,mM,[F(G(`textarea`,Oa({"onUpdate:modelValue":t[0]||(t[0]=t=>e.computedValue=t)},e.$attrs,{class:[`form-control`,[e.lg&&`form-control-lg`,e.classInner,e.isValid||`is-invalid`]],placeholder:e.placeholder}),null,16,hM),[[ys,e.computedValue]]),(o=e.innerValue)!=null&&o.length?(H(),U(`div`,gM,[G(`button`,{type:`button`,class:`btn-close`,style:{"background-size":`0.7em`},onClick:t[1]||(t[1]=X((...t)=>e.clear&&e.clear(...t),[`prevent`]))})])):J(``,!0),e.isValid?J(``,!0):(H(),U(`div`,_M,[e.validationErrors.required?(H(),U(`p`,vM,j(`Field is required`))):e.validationErrors.email?(H(),U(`p`,yM,j(`Field must be an email`))):e.validationErrors.csemails?(H(),U(`p`,bM,j(`Field must be a comma separated emails`))):e.validationErrors.minLength?(H(),U(`p`,xM,j(`Field must be at least ${e.validators.minLength.minLength} characters long`),1)):J(``,!0)]))])}var CM=Q(pM,[[`render`,SM]]),wM=L({components:{Btn:Iy,Modal:Qy,FormInputClearable:Mb,FormSelectFilterable:fM,FormTextAreaClearable:CM,CatalogOptions:rM},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=`NEW_CATALOG`,r=Pf.Catalogs.getInstance(e.instanceId),i=M(!1),a=Wl,o=M(null),s=M(``),c=M(``),l=M(Wl.PERSONAL),u=M([]),d=M([]),f=Y(()=>[{value:n,text:e.t(`CreateNewCatalog`),type:`fixed`},{type:`divider`}].concat(u.value.reduce((t,n)=>n.code!==e.data.catalog.code&&n.editable?t.concat([{value:n.code,text:n.code,type:`standard`}]):t,[]))),p=Y(()=>o.value!==null&&(o.value!==n||o.value===n&&!!s.value&&!!l.value&&!!c.value)),m={code:{[mb.required]:{}},description:{[mb.required]:{}}},h=e=>o.value=e,g=e=>s.value=e,_=e=>c.value=e,v=e=>l.value=e,y=()=>t(`update:show`,!1),b=async()=>{if(p.value){try{if(o.value===n){let t={onSuccessMessage:e.t(`CatalogProductCopySuccess`),sourceCatalogId:e.data.catalog.id,code:s.value,type:l.value,description:c.value};await r.execute(new id(t).from(`catalog-copy-modal`))}else{let t={onSuccessMessage:e.t(`CatalogProductCopySuccess`),sourceCatalogId:e.data.catalog.id,targetCatalogId:``},n=u.value.find(e=>e.code===o.value);if(!n)return;t.targetCatalogId=n.id,await r.execute(new rd(t).from(`catalog-copy-modal`))}}catch{}y()}},x=async()=>{try{u.value=await r.execute(new Nd().from(`catalog-copy-modal`))}catch{}};return kr(async()=>{try{x();let t=await r.execute(new td().from(`catalog-copy-modal`));if(!t)throw Error(e.t(`CatalogOptionsLoadingError`));d.value=t.items,i.value=!0}catch(e){await r.execute(new pd({type:`danger`,message:e.message}).from(`catalog-copy-modal`))}}),{newCatalogValue:n,show:i,code:s,type:l,copyTo:o,validators:m,catalogType:a,description:c,isFormValid:p,copyToOptions:f,catalogOptions:d,close:y,onSave:b,onCopyToUpdate:h,onCodeUpdate:g,onTypeUpdated:v,onDescriptionUpdate:_}}}),TM={class:`d-block pt-2`},EM={class:`form-label fw-bolder`},DM={key:0},OM={class:`d-block pt-2`},kM={class:`form-label fw-bolder`},AM={class:`d-block pt-2`},jM={class:`form-label fw-bolder`},MM={class:`d-flex justify-content-end mt-3`};function NM(e,t,n,r,i,a){let o=R(`FormSelectFilterable`),s=R(`FormInputClearable`),c=R(`FormTextAreaClearable`),l=R(`CatalogOptions`),u=R(`Btn`),d=R(`Modal`);return H(),W(d,{show:e.show,title:e.t(`CopyCatalog`),"close-on-outer-click":!1,"onUpdate:show":t[3]||(t[3]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[2]||(t[2]=X(()=>{},[`prevent`]))},[G(`label`,TM,[G(`div`,EM,j(e.t(`CopyCatalogTo`)),1),K(o,{"model-value":e.copyTo,items:e.copyToOptions,"onUpdate:modelValue":e.onCopyToUpdate},null,8,[`model-value`,`items`,`onUpdate:modelValue`])]),e.copyTo==e.newCatalogValue?(H(),U(`div`,DM,[G(`label`,OM,[G(`div`,kM,j(e.t(`CatalogCode`)),1),K(s,{"model-value":e.code,validators:e.validators.code,"onUpdate:modelValue":e.onCodeUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),G(`label`,AM,[G(`div`,jM,j(e.t(`CatalogDescription`)),1),K(c,{"model-value":e.description,rows:3,validators:e.validators.description,"onUpdate:modelValue":e.onDescriptionUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),K(l,{t:e.t,"instance-id":e.instanceId,onOnTypeUpdated:e.onTypeUpdated},null,8,[`t`,`instance-id`,`onOnTypeUpdated`])])):J(``,!0),t[4]||(t[4]=G(`hr`,null,null,-1)),G(`div`,MM,[K(u,{class:`mx-2`,onClick:t[0]||(t[0]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(u,{disabled:!e.isFormValid,primary:``,onClick:t[1]||(t[1]=X(t=>e.onSave(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`show`,`title`])}var PM=Q(wM,[[`render`,NM]]),FM=L({components:{Btn:Iy,Modal:Qy,FormInputClearable:Mb,FormTextAreaClearable:CM,CatalogOptions:rM},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0}},emits:[`update:show`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=M(!1),i=Wl,a=M(``),o=M(``),s=M(i.PERSONAL),c=M([]),l=Y(()=>!!a.value&&!!s.value&&!!o.value),u={code:{[mb.required]:{}},description:{[mb.required]:{}}},d=()=>t(`update:show`,!1);return kr(async()=>{try{let t=await n.execute(new td().from(`catalog-create-new-modal`));if(!t)throw Error(e.t(`CatalogOptionsLoadingError`));c.value=t.items,r.value=!0}catch(e){await n.execute(new pd({type:`danger`,message:e.message}).from(`catalog-create-new-modal`))}}),{show:r,code:a,type:s,validators:u,description:o,isFormValid:l,catalogType:i,catalogOptions:c,close:d,onSave:async()=>{try{await n.execute(new ed({code:a.value,type:s.value,description:o.value,onSuccessMessage:e.t(`CatalogCreateNewSuccess`)}).from(`catalog-create-new-modal`)),await n.execute(new wu().from(`catalog-create-new-modal`))}catch{}d()},onCodeUpdate:e=>a.value=e,onTypeUpdated:e=>s.value=e,onDescriptionUpdate:e=>o.value=e}}}),IM={class:`d-block pt-2`},LM={class:`form-label fw-bolder`},RM={class:`d-block pt-2`},zM={class:`form-label fw-bolder`},BM={class:`d-flex justify-content-end mt-3`};function VM(e,t,n,r,i,a){let o=R(`FormInputClearable`),s=R(`FormTextAreaClearable`),c=R(`CatalogOptions`),l=R(`Btn`),u=R(`Modal`);return H(),W(u,{show:e.show,title:e.t(`NewCatalog`),"close-on-outer-click":!1,"onUpdate:show":t[3]||(t[3]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[2]||(t[2]=X(()=>{},[`prevent`]))},[G(`label`,IM,[G(`div`,LM,j(e.t(`CatalogCode`)),1),K(o,{"model-value":e.code,validators:e.validators.code,"onUpdate:modelValue":e.onCodeUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),G(`label`,RM,[G(`div`,zM,j(e.t(`CatalogDescription`)),1),K(s,{"model-value":e.description,rows:3,validators:e.validators.description,"onUpdate:modelValue":e.onDescriptionUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),K(c,{t:e.t,"instance-id":e.instanceId,onOnTypeUpdated:e.onTypeUpdated},null,8,[`t`,`instance-id`,`onOnTypeUpdated`]),t[4]||(t[4]=G(`hr`,null,null,-1)),G(`div`,BM,[K(l,{class:`mx-2`,onClick:t[0]||(t[0]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(l,{disabled:!e.isFormValid,primary:``,onClick:t[1]||(t[1]=X(t=>e.onSave(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`show`,`title`])}var HM=Q(FM,[[`render`,VM]]),UM=L({components:{Btn:Iy,Modal:Qy,CatalogOptions:rM,FormTextAreaClearable:CM},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=M(!1),r=Wl,i=Pf.Catalogs.getInstance(e.instanceId),a=M(e.data.catalog),o=M(a.value.description),s=M([]),c=Y(()=>!!a.value.code),l={description:{[mb.required]:{}}},u=()=>t(`update:show`,!1);return kr(async()=>{try{let t=await i.execute(new td().from(`catalog-edit-modal`));if(!t)throw Error(e.t(`CatalogOptionsLoadingError`));s.value=t.items,n.value=!0}catch(e){await i.execute(new pd({type:`danger`,message:e.message}).from(`catalog-edit-modal`))}}),{show:n,catalog:a,validators:l,description:o,catalogType:r,isFormValid:c,catalogOptions:s,close:u,onSave:async()=>{if(c.value){try{await i.execute(new nd({catalogId:a.value.id,description:o.value,onSuccessMessage:e.t(`CatalogEditSuccess`)}).from(`catalog-edit-modal`))}catch{}u()}},onMakeDefault:async()=>{if(a.value){try{await i.execute(new od({catalogId:a.value.id,onSuccessMessage:e.t(`CatalogSetAsDefaultSuccess`)}).from(`catalog-edit-modal`))}catch{}u()}},onUnMakeDefault:async()=>{if(a.value){try{await i.execute(new sd({catalogId:a.value.id,onSuccessMessage:e.t(`CatalogUnsetAsDefaultSuccess`)}).from(`catalog-edit-modal`))}catch{}u()}},onDescriptionUpdate:e=>o.value=e}}}),WM={class:`d-block pt-2`},GM={class:`form-label fw-bolder`},KM=[`value`],qM={class:`d-block pt-2`},JM={class:`form-label fw-bolder`},YM={class:`d-flex justify-content-between mt-3`},XM={key:0,class:`d-flex justify-content-start`},ZM={class:`d-flex justify-content-end`};function QM(e,t,n,r,i,a){let o=R(`FormTextAreaClearable`),s=R(`CatalogOptions`),c=R(`Btn`),l=R(`Modal`);return H(),W(l,{show:e.show&&e.catalog,title:e.t(`EditCatalog`),"close-on-outer-click":!1,"onUpdate:show":t[3]||(t[3]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[2]||(t[2]=X(()=>{},[`prevent`]))},[G(`label`,WM,[G(`div`,GM,j(e.t(`CatalogCode`)),1),G(`input`,{type:`text`,class:`form-control`,value:e.catalog.code,disabled:``},null,8,KM)]),G(`label`,qM,[G(`div`,JM,j(e.t(`CatalogDescription`)),1),K(o,{"model-value":e.description,rows:3,validators:e.validators.description,"onUpdate:modelValue":e.onDescriptionUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),K(s,{t:e.t,"instance-id":e.instanceId,type:e.catalog.type,editable:!1},null,8,[`t`,`instance-id`,`type`]),t[4]||(t[4]=G(`hr`,null,null,-1)),G(`div`,YM,[e.catalog.editable?(H(),U(`div`,XM,[e.catalog.default?(H(),W(c,{key:0,onClick:X(e.onUnMakeDefault,[`prevent`])},{default:P(()=>[q(j(e.t(`RemoveFromFavorites`)),1)]),_:1},8,[`onClick`])):(H(),W(c,{key:1,onClick:X(e.onMakeDefault,[`prevent`])},{default:P(()=>[q(j(e.t(`MarkAsFavorite`)),1)]),_:1},8,[`onClick`]))])):J(``,!0),G(`div`,ZM,[K(c,{class:`me-2`,onClick:t[0]||(t[0]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(c,{disabled:!e.isFormValid,primary:``,onClick:t[1]||(t[1]=X(t=>e.onSave(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])])],32)]),_:1},8,[`show`,`title`])}var $M=Q(UM,[[`render`,QM]]),eN=L({components:{Btn:Iy,Badge:ky,Modal:Qy,Spinner:My,FormInputClearable:Mb},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=M(!1),i=M(!1),a=Y(()=>{var e;return(e=n.store.options.components)==null||(e=e.search)==null||(e=e.table)==null?void 0:e.export}),o=M(null),s=M({exportPrices:!1,emails:``}),c={emails:{[mb.required]:i.value&&s.value.exportPrices.valueOf()?{}:void 0,[mb.commaSeparatedEmails]:{}}},l=Y(()=>!i.value||!s.value.exportPrices||!!s.value.emails.valueOf()),u=e=>s.value.emails=e,d=()=>t(`update:show`,!1),f=async()=>{try{let t={catalogId:e.data.catalog.id,catalogCode:e.data.catalog.code,onSuccessMessage:e.t(`CatalogExportReady`)};i.value&&(t.priceSettings={emails:s.value.emails.split(`,`),enabled:s.value.exportPrices}),await n.execute(new $u(t).from(`catalog-export-modal`))===!0&&await n.execute(new pd({type:`success`,message:e.t(`CatalogExportScheduled`)}).from(`catalog-export-modal`))}catch{}d()},p=async()=>{try{var t;let c=await n.execute(new td().from(`catalog-export-modal`));if(!c)throw Error(e.t(`CatalogOptionsLoadingError`));if(s.value.emails=c.email||``,c.pricesAvailable&&(t=a.value)!=null&&t.exportPrices){i.value=!0,r.value=!0;let e=await n.execute(new Ju({}).from(`catalog-export-modal`));e&&e.items&&(o.value=e.items[0]),r.value=!1}else await f()}catch(e){await n.execute(new pd({type:`danger`,message:e.message}).from(`catalog-export-modal`))}};return kr(()=>p()),{models:s,validators:c,isFormValid:l,isLoadingJobs:r,canExportPrices:i,lastScheduledJob:o,close:d,onExport:f,onEmailsUpdate:u}}}),tN={class:`d-block pt-2`},nN={class:`form-label fw-bolder`},rN={key:1,class:`d-block pt-2`},iN={class:`form-check align-items-start`},aN=[`textContent`],oN={key:2,class:`d-block pt-2`},sN={class:`d-block`},cN={class:`form-label fw-bolder`},lN={key:0,class:`d-block pt-2`},uN={class:`form-label fw-bolder`},dN={class:`me-1`},fN={class:`me-1`},pN={class:`d-flex justify-content-end mt-3`};function mN(e,t,n,r,i,a){let o=R(`Spinner`),s=R(`FormInputClearable`),c=R(`Badge`),l=R(`Btn`),u=R(`Modal`);return H(),W(u,{show:e.canExportPrices,title:e.t(`ExportCatalog`),"close-on-outer-click":!1,"onUpdate:show":t[4]||(t[4]=t=>e.$emit(`update:show`))},{default:P(()=>{var n;return[G(`form`,{onSubmit:t[3]||(t[3]=X(()=>{},[`prevent`]))},[G(`label`,tN,[G(`div`,nN,j(e.t(`CatalogCode`)),1),G(`div`,null,j(e.data.catalog.code),1)]),e.isLoadingJobs?(H(),W(o,{key:0})):e.canExportPrices?(H(),U(`label`,rN,[G(`div`,iN,[F(G(`input`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.models.exportPrices=t),name:`exportPrices`,type:`checkbox`,class:`form-check-input me-2`,value:`true`},null,512),[[bs,e.models.exportPrices]]),G(`span`,{class:`form-check-label text-break user-select-none pis-label`,textContent:j(e.t(`ExportPrices`))},null,8,aN),t[5]||(t[5]=G(`br`,null,null,-1)),G(`small`,null,j(e.t(`ExportPricesDescription`)),1)])])):J(``,!0),e.models.exportPrices?(H(),U(`div`,oN,[G(`label`,sN,[G(`span`,cN,j(e.t(`Emails`)),1),K(s,{"model-value":e.models.emails,rows:3,validators:e.validators.emails,"onUpdate:modelValue":e.onEmailsUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`]),t[6]||(t[6]=G(`br`,null,null,-1)),G(`small`,null,j(e.t(`EmailsDescription`)),1)]),e.lastScheduledJob?(H(),U(`label`,lN,[G(`div`,uN,j(e.t(`LastScheduledJob`)),1),G(`span`,dN,j((n=e.lastScheduledJob.catalog)==null?void 0:n.code),1),G(`span`,fN,j(e.lastScheduledJob.type),1),K(c,{class:`ms-auto`,textContent:j(e.lastScheduledJob.status)},null,8,[`textContent`])])):J(``,!0)])):J(``,!0),t[7]||(t[7]=G(`hr`,null,null,-1)),G(`div`,pN,[K(l,{class:`mx-2`,onClick:t[1]||(t[1]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(l,{disabled:!e.isFormValid,primary:``,onClick:t[2]||(t[2]=X(t=>e.onExport(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Export`,!0)),1)]),_:1},8,[`disabled`])])],32)]}),_:1},8,[`show`,`title`])}var hN=Q(eN,[[`render`,mN]]),gN=L({components:{Btn:Iy,Modal:Qy,Spinner:My},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0}},emits:[`update:show`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=M(!0),i=M(!1),a=M([]),o=Xl,s=M(Xl.CATALOG),c=()=>t(`update:show`,!1),l=async t=>{try{await n.execute(new Xu({jobId:t,onSuccessMessage:e.t(`JobDownloadReady`)}).from(`catalog-history-modal`))}catch{}},u=async t=>{try{return await n.execute(new Zu({jobId:t,onSuccessMessage:e.t(`JobCancelled`)}).from(`catalog-history-modal`)),d()}catch{}},d=async()=>{try{let e=await n.execute(new Ju({sortSettings:{field:s.value,direction:s.value===Xl.LAST_MODIFIED?iu.DESCENDING:iu.ASCENDING}}).from(`catalog-history-modal`));e&&e.items&&(a.value=e.items)}catch{}i.value=!0};return I(()=>s.value,()=>d()),kr(()=>{d()}),{show:r,items:a,sortBy:s,isReady:i,sortByItems:o,JobStatusEnum:Zl,close:c,onCancel:u,onDownload:l}}}),_N={key:0},vN={class:`my-3 d-flex flex-row justify-content-center align-items-center flex-wrap`},yN={class:`d-flex align-items-center`},bN={class:`text-nowrap`},xN=[`value`],SN={class:`table-responsive pis-scroll`},CN={class:`table`},wN={key:1,class:`d-flex justify-content-center align-items-center`},TN={key:1,class:`d-flex justify-content-center align-items-center`};function EN(e,t,n,r,i,a){let o=R(`Btn`),s=R(`Spinner`),c=R(`Modal`);return H(),W(c,{show:e.show,title:e.t(`CatalogHistoryModal`),lg:``,"close-on-outer-click":!1,"onUpdate:show":t[2]||(t[2]=t=>e.$emit(`update:show`))},{default:P(()=>[e.isReady?(H(),U(`form`,{key:0,onSubmit:t[1]||(t[1]=X(()=>{},[`prevent`]))},[e.items&&e.items.length?(H(),U(`div`,_N,[G(`div`,vN,[G(`label`,yN,[G(`span`,bN,j(e.t(`SortBy`))+`:`,1),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.sortBy=t),class:`form-select ms-2 w-100`},[(H(!0),U(V,null,z(e.sortByItems,(t,n)=>(H(),U(`option`,{key:n,value:t},j(e.t(`JobHistorySortBy${t}`)),9,xN))),128))],512),[[Cs,e.sortBy]])])]),G(`div`,SN,[G(`table`,CN,[G(`thead`,null,[G(`tr`,null,[G(`th`,null,j(e.t(`CatalogCode`)),1),G(`th`,null,j(e.t(`JobType`)),1),G(`th`,null,j(e.t(`JobStatus`)),1),G(`th`,null,j(e.t(`DateModified`)),1),G(`th`,null,j(e.t(`Actions`)),1)])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.items,(t,n)=>{var r;return H(),U(`tr`,{key:n},[G(`td`,null,j((r=t.catalog)==null?void 0:r.code),1),G(`td`,null,j(e.t(`JobType${t.type}`)),1),G(`td`,null,j(e.t(`JobStatus${t.status}`)),1),G(`td`,null,j(new Date(t.dateModified).toLocaleString([],{dateStyle:`medium`,timeStyle:`medium`})),1),G(`td`,null,[t.status===e.JobStatusEnum.SUCCESS?(H(),W(o,{key:0,primary:``,onClick:X(n=>e.onDownload(t.id),[`prevent`])},{default:P(()=>[q(j(e.t(`Download`,!0)),1)]),_:1},8,[`onClick`])):t.status===e.JobStatusEnum.IN_QUEUE?(H(),W(o,{key:1,primary:``,onClick:X(n=>e.onCancel(t.id),[`prevent`])},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1},8,[`onClick`])):J(``,!0)])])}),128))])])])])):(H(),U(`div`,wN,[G(`span`,null,j(e.t(`JobHistoryListEmpty`)),1)]))],32)):(H(),U(`div`,TN,[K(s)]))]),_:1},8,[`show`,`title`])}var DN=Q(gN,[[`render`,EN]]),ON=L({components:{Btn:Iy,Modal:Qy},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=M(),i=Y(()=>!!r.value),a={uploadedFile:{[mb.required]:{}}},o=e=>{let t=e.target;t&&t.files&&(r.value=t.files[0])},s=()=>t(`update:show`,!1);return{validators:a,isFormValid:i,uploadedFile:r,close:s,onImport:async()=>{if(r.value){try{let t=await GT(r.value);await n.execute(new Qu({catalogId:e.data.catalog.id,file:t,fileName:r.value.name,onSuccessMessage:e.t(`CatalogImportSuccess`)}).from(`catalog-import-modal`))}catch{}s()}},onFileUpload:o}}}),kN={class:`pt-2`},AN={class:`form-label fw-bolder`},jN={class:`pt-2 has-validation`},MN={class:`form-label fw-bolder`},NN={class:`mt-3`},PN={class:`d-flex justify-content-end mt-3`};function FN(e,t,n,r,i,a){let o=R(`Btn`),s=R(`Modal`);return H(),W(s,{show:!0,title:e.t(`ImportCatalog`),"close-on-outer-click":!1,"onUpdate:show":t[4]||(t[4]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[3]||(t[3]=X(()=>{},[`prevent`]))},[G(`label`,kN,[G(`div`,AN,j(e.t(`CompanyNameCode`)),1),G(`div`,null,j(e.data.catalog.code),1)]),G(`div`,jN,[G(`div`,MN,j(e.t(`File`)),1),G(`input`,{type:`file`,class:`form-control`,onChange:t[0]||(t[0]=t=>e.onFileUpload(t))},null,32)]),G(`p`,NN,j(e.t(`ImportWarning`)),1),t[5]||(t[5]=G(`hr`,null,null,-1)),G(`div`,PN,[K(o,{class:`mx-2`,onClick:t[1]||(t[1]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(o,{disabled:!e.isFormValid,primary:``,onClick:t[2]||(t[2]=X(t=>e.onImport(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Import`)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`title`])}var IN=Q(ON,[[`render`,FN]]),LN=L({components:{Modal:Qy},props:{instanceId:{type:String,default:void 0},t:{type:Function,required:!0},errors:{type:Array,required:!0},warnings:{type:Array,required:!0}},emits:[`update:show`],setup(e,{emit:t}){return{close:()=>t(`update:show`,!1)}}});function RN(e,t,n,r,i,a){let o=R(`Modal`);return H(),W(o,{show:!0,title:e.t(`Errors`),"close-on-outer-click":!1,"onUpdate:show":t[0]||(t[0]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`ul`,null,[(H(!0),U(V,null,z(e.errors,e=>(H(),U(`li`,{key:e.id},j(e.message),1))),128)),(H(!0),U(V,null,z(e.warnings,e=>(H(),U(`li`,{key:e.id},j(e.message),1))),128))])]),_:1},8,[`title`])}var zN=L({name:`pis-catalogs-search-actions-modals`,components:{Confirmation:aE,CatalogEditModal:$M,CatalogCopyModal:PM,CatalogImportModal:IN,CatalogExportModal:hN,CatalogHistoryModal:DN,CatalogActionErrors:Q(LN,[[`render`,RN]]),CatalogCreateNewModal:HM},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isReady:i,isWebComponent:a,store:o,t:s}=ym(t,e.instanceId),c=Y(()=>{var e;return(e=r.value)==null?void 0:e.store.data.actions}),l=Y(()=>{var e;return(e=c.value)==null?void 0:e.current}),u=Y(()=>{var e;return(e=c.value)==null?void 0:e.data}),d=async()=>{try{var e;(e=r.value)==null||e.execute(new hd().from(n))}catch{}};return{root:t,store:o,isReady:i,componentName:n,CatalogAction:Hs,isWebComponent:a,currentActionName:l,currentActionData:u,t:s,onCatalogDelete:async()=>{var e;let t=c.value;if(!(t!=null&&t.current)||t.current!==Hs.delete)return;let i=(e=t.data)==null?void 0:e.catalog;if(i){try{var a;await((a=r.value)==null?void 0:a.execute(new ad({catalogId:i.id,onSuccessMessage:s(`CatalogDeleteSuccess`)}).from(n)))}catch{}await d()}},onActionCompleted:d}}}),BN={ref:`root`,class:`pis-component position-relative`},VN={class:`mb-4`};function HN(e,t,n,r,i,a){let o=R(`CatalogEditModal`),s=R(`CatalogCopyModal`),c=R(`CatalogImportModal`),l=R(`CatalogExportModal`),u=R(`CatalogCreateNewModal`),d=R(`CatalogHistoryModal`),f=R(`Confirmation`),p=R(`CatalogActionErrors`);return H(),U(`div`,BN,[e.isReady?(H(),U(V,{key:0},[e.currentActionName===e.CatalogAction.edit?(H(),W(o,{key:0,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.copy?(H(),W(s,{key:1,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.import?(H(),W(c,{key:2,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.export?(H(),W(l,{key:3,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.createNew?(H(),W(u,{key:4,t:e.t,"instance-id":e.instanceId,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.history?(H(),W(d,{key:5,t:e.t,"instance-id":e.instanceId,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.delete?(H(),W(f,{key:6,t:e.t,title:e.t(`DeleteCatalog`),item:e.currentActionData.catalog,"onUpdate:show":e.onActionCompleted,onConfirmationCancelled:e.onActionCompleted,onConfirmationOk:e.onCatalogDelete},{default:P(()=>[G(`div`,VN,[q(j(e.t(`CatalogConfirmDelete`))+`: `,1),G(`strong`,null,j(e.currentActionData.catalog.code),1)])]),_:1},8,[`t`,`title`,`item`,`onUpdate:show`,`onConfirmationCancelled`,`onConfirmationOk`])):e.currentActionName===e.CatalogAction.errors?(H(),W(p,{key:7,t:e.t,"instance-id":e.instanceId,errors:e.currentActionData.errors,warnings:e.currentActionData.warnings},null,8,[`t`,`instance-id`,`errors`,`warnings`])):J(``,!0)],64)):J(``,!0)],512)}var UN=Q(zN,[[`render`,HN]]),WN=L({components:{Btn:Iy,Modal:Qy,FormInputClearable:Mb,FormSelectFilterable:fM,FormTextAreaClearable:CM,CatalogOptions:rM},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=`NEW_CATALOG`,r=Wl,i=M(!1),a=Pf.Catalogs.getInstance(e.instanceId),o=M(null),s=M(``),c=M(``),l=M(Wl.PERSONAL),u=M([]),d=Y(()=>o.value!==null&&(o.value!==n||o.value===n&&!!s.value&&!!l.value&&!!c.value)),f={code:{[mb.required]:{}},description:{[mb.required]:{}}},p=Y(()=>(e.data.product.catalogs??{})[0]||void 0),m=Y(()=>[{value:n,text:e.t(`CreateNewCatalog`),type:`fixed`},{type:`divider`}].concat(u.value.reduce((e,t)=>{var n;return t.code!==((n=p.value)==null?void 0:n.code)&&t.editable?e.concat([{value:t.code,text:t.code,type:`standard`}]):e},[]))),h=()=>t(`update:show`,!1),g=e=>o.value=e,_=e=>s.value=e,v=e=>c.value=e,y=e=>l.value=e,b=async()=>{var t;if(!d.value)return;let r=e.data.catalog,i=(t=e.data.product.catalogs)==null?void 0:t.find(e=>e.code===r.code);if(!i)return;let f=((i==null?void 0:i.quantities)??{})[0];if(f){try{if(o.value===n){let t={onSuccessMessage:e.t(`CatalogProductCopySuccess`),sourceCatalogId:i==null?void 0:i.id,sourceQuantityIds:[f.id],code:s.value,type:l.value,description:c.value};await a.execute(new Gu(t).from(`product-copy-modal`))}else{let t={onSuccessMessage:e.t(`CatalogProductCopySuccess`),sourceCatalogId:i==null?void 0:i.id,sourceQuantityIds:[f.id],targetCatalogId:``},n=u.value.find(e=>e.code===o.value),r=n==null?void 0:n.id;if(!r)return;t.targetCatalogId=r,await a.execute(new Wu(t).from(`product-copy-modal`))}}catch{}h()}},x=async()=>{try{u.value=await a.execute(new Nd().from(`product-copy-modal`))}catch{}};return kr(async()=>{try{x(),i.value=!0}catch(e){await a.execute(new pd({type:`danger`,message:e.message}).from(`product-copy-modal`))}}),{newCatalogValue:n,show:i,copyTo:o,isFormValid:d,validators:f,catalogType:r,copyToOptions:m,code:s,type:l,description:c,close:h,onSave:b,onCopyToUpdate:g,onCodeUpdate:_,onTypeUpdated:y,onDescriptionUpdate:v}}}),GN={class:`d-block pt-2`},KN={class:`form-label fw-bolder`},qN={key:0},JN={class:`d-block pt-2`},YN={class:`form-label fw-bolder`},XN={class:`d-block pt-2`},ZN={class:`form-label fw-bolder`},QN={class:`d-flex justify-content-end mt-3`};function $N(e,t,n,r,i,a){let o=R(`FormSelectFilterable`),s=R(`FormInputClearable`),c=R(`FormTextAreaClearable`),l=R(`CatalogOptions`),u=R(`Btn`),d=R(`Modal`);return H(),W(d,{show:e.show,title:e.t(`CopyProduct`),"close-on-outer-click":!1,"onUpdate:show":t[3]||(t[3]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[2]||(t[2]=X(()=>{},[`prevent`]))},[G(`label`,GN,[G(`div`,KN,j(e.t(`CopyProductTo`)),1),K(o,{"model-value":e.copyTo,items:e.copyToOptions,"onUpdate:modelValue":e.onCopyToUpdate},null,8,[`model-value`,`items`,`onUpdate:modelValue`])]),e.copyTo==e.newCatalogValue?(H(),U(`div`,qN,[G(`label`,JN,[G(`div`,YN,j(e.t(`CatalogCode`)),1),K(s,{"model-value":e.code,validators:e.validators.code,"onUpdate:modelValue":e.onCodeUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),G(`label`,XN,[G(`div`,ZN,j(e.t(`CatalogDescription`)),1),K(c,{"model-value":e.description,rows:3,validators:e.validators.description,"onUpdate:modelValue":e.onDescriptionUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),K(l,{t:e.t,"instance-id":e.instanceId,onOnTypeUpdated:e.onTypeUpdated},null,8,[`t`,`instance-id`,`onOnTypeUpdated`])])):J(``,!0),t[4]||(t[4]=G(`hr`,null,null,-1)),G(`div`,QN,[K(u,{class:`mx-2`,onClick:t[0]||(t[0]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(u,{disabled:!e.isFormValid,primary:``,onClick:t[1]||(t[1]=X(t=>e.onSave(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`show`,`title`])}var eP=Q(WN,[[`render`,$N]]),tP=L({components:{Btn:Iy,Modal:Qy,FormInputClearable:Mb},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=Pf.Catalogs.getInstance(e.instanceId),r=Y(()=>e.data.product.productType===Vl.UNLISTED),i=Ut({uom:``,guid:``,quantityValue:``,productId:``,productDisplayName:``,description:``,customerClassification:void 0,baseProductId:void 0,customFields:[],alternateProductId:``}),a={quantity:{[mb.required]:{},[mb.min]:{min:1},[mb.max]:{max:1e6}}},o=Y(()=>(!r.value||i.description)&&i.quantityValue),s=()=>t(`update:show`,!1);return kr(()=>{var t,n;let r=e.data.product;i.productId=r.productId,i.productDisplayName=Us(r,`#DisplayName`),i.description=Us(r,`#Description`),i.customerClassification=r.customerClassification,i.baseProductId=(t=r.baseProduct)==null?void 0:t.productId,i.customFields=[...r.customFields||[]],i.alternateProductId=r.alternateProductId;let a=e.data.catalog,o=a?(n=r.catalogs)==null?void 0:n.find(e=>e.code===a.code):(r.catalogs??{})[0],s=((o==null?void 0:o.quantities)??{})[0];s&&(i.quantityValue=`${s.value}`,i.guid=s.guid,i.uom=s.unitOfMeasure)}),{formData:i,validators:a,isFormValid:o,isProductDescriptionEditable:r,close:s,onSave:async()=>{try{let t=e.data.catalog.id;if(!t)return;let a={description:i.description,productId:i.productId,quantity:Number.parseInt(i.quantityValue,10),unitOfMeasure:i.uom,customerClassification:i.customerClassification,baseProductId:i.baseProductId,customFields:i.customFields,alternateProductId:i.alternateProductId};r.value&&(a.description=i.description),await n.execute(new Uu({catalogId:t,product:a,onSuccessMessage:e.t(`CatalogProductEditSuccess`)}).from(`product-edit-modal`))}catch{}s()},onQuantityUpdate:e=>i.quantityValue=e,onDescriptionUpdate:e=>i.description=e,onClassificationUpdate:e=>i.customerClassification=e}}}),nP={class:`d-block pt-2`},rP={class:`form-label fw-bolder`},iP=[`value`],aP={class:`d-block pt-2`},oP={class:`form-label fw-bolder`},sP=[`disabled`],cP={class:`row`},lP={class:`col`},uP={class:`form-label fw-bolder`},dP={class:`col`},fP={class:`form-label fw-bolder`},pP=[`value`],mP={class:`d-block pt-2`},hP={class:`form-label fw-bolder`},gP={key:0,class:`d-block pt-2`},_P={class:`form-label fw-bolder`},vP=[`value`],yP={key:1,class:`d-block pt-2`},bP={class:`form-label fw-bolder`},xP={class:`table`},SP={class:`d-flex justify-content-end mt-3`};function CP(e,t,n,r,i,a){let o=R(`FormInputClearable`),s=R(`Btn`),c=R(`Modal`);return H(),W(c,{show:!0,title:e.t(`EditProduct`),"close-on-outer-click":!1,"onUpdate:show":t[4]||(t[4]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[3]||(t[3]=X(()=>{},[`prevent`]))},[G(`label`,nP,[G(`div`,rP,j(e.t(`Product`)),1),G(`input`,{type:`text`,class:`form-control`,value:e.formData.productDisplayName,disabled:``},null,8,iP)]),G(`label`,aP,[G(`div`,oP,j(e.t(`Description`)),1),F(G(`textarea`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.formData.description=t),class:`form-control`,rows:`2`,disabled:!e.isProductDescriptionEditable},null,8,sP),[[ys,e.formData.description]])]),G(`div`,cP,[G(`div`,lP,[G(`label`,null,[G(`div`,uP,j(e.t(`Quantity`)),1),K(o,{"model-value":e.formData.quantityValue,validators:e.validators.quantity,clearable:!1,type:`number`,"onUpdate:modelValue":e.onQuantityUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])])]),G(`div`,dP,[G(`label`,null,[G(`div`,fP,j(e.t(`UnitOfMeasure`)),1),G(`input`,{type:`text`,class:`form-control`,value:e.formData.uom,disabled:``},null,8,pP)])])]),G(`label`,mP,[G(`div`,hP,j(e.t(`CustomerClassification`)),1),K(o,{"model-value":e.formData.customerClassification,type:`text`,"onUpdate:modelValue":e.onClassificationUpdate},null,8,[`model-value`,`onUpdate:modelValue`])]),e.formData.baseProductId?(H(),U(`label`,gP,[G(`div`,_P,j(e.t(`BaseProductId`)),1),G(`input`,{type:`text`,class:`form-control`,value:e.formData.baseProductId,disabled:``},null,8,vP)])):J(``,!0),e.formData.customFields&&e.formData.customFields.length?(H(),U(`div`,yP,[G(`label`,bP,j(e.t(`CustomFields`)),1)])):J(``,!0),G(`table`,xP,[G(`tbody`,null,[(H(!0),U(V,null,z(e.formData.customFields,e=>(H(),U(`tr`,{key:e.key},[G(`td`,null,j(e.key)+`:`,1),G(`td`,null,j(e.value),1)]))),128))])]),t[5]||(t[5]=G(`hr`,null,null,-1)),G(`div`,SP,[K(s,{class:`mx-2`,onClick:t[1]||(t[1]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(s,{disabled:!e.isFormValid,primary:``,onClick:t[2]||(t[2]=X(t=>e.onSave(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`title`])}var wP=L({name:`pis-catalogs-products-search-actions-modals`,components:{ProductEditModal:Q(tP,[[`render`,CP]]),ProductCopyModal:eP,Confirmation:aE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isReady:i,isWebComponent:a,store:o,t:s}=ym(t,e.instanceId),c=Y(()=>{var e;return(e=r.value)==null?void 0:e.store.data.actions}),l=Y(()=>{var e;return(e=c.value)==null?void 0:e.current}),u=Y(()=>{var e;return(e=c.value)==null?void 0:e.data}),d=e=>{var t;return(((t=e.attributes[`#DisplayName`])==null?void 0:t.values)??[{text:e.productId}])[0].text},f=async()=>{try{var e;(e=r.value)==null||e.execute(new hd().from(n))}catch{}};return{root:t,store:o,isReady:i,instance:r,CatalogAction:Hs,componentName:n,isWebComponent:a,currentActionName:l,currentActionData:u,t:s,attrValue:Us,onActionCompleted:f,getProductDisplayName:d,onCatalogProductDelete:async()=>{let e=c.value;if(!(e!=null&&e.current)||e.current!==Hs.productDelete)return;let t=e.data;if(!(!t||!t.product||!t.product.productId||!t.catalog||!t.catalog.id)){try{var i;await((i=r.value)==null?void 0:i.execute(new cd({onSuccessMessage:s(`CatalogProductDeleteSuccess`),products:[{productId:t.product.productId}],catalogId:t.catalog.id}).from(n)))}catch{}f()}}}}}),TP={ref:`root`,class:`pis-component position-relative`},EP={class:`mb-4`},DP={class:`d-block`};function OP(e,t,n,r,i,a){let o=R(`ProductEditModal`),s=R(`ProductCopyModal`),c=R(`Confirmation`);return H(),U(`div`,TP,[e.isReady?(H(),U(V,{key:0},[e.currentActionName===e.CatalogAction.productEdit?(H(),W(o,{key:0,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.productCopy?(H(),W(s,{key:1,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===e.CatalogAction.productDelete?(H(),W(c,{key:2,t:e.t,title:e.t(`DeleteCatalogProduct`),item:e.currentActionData,"onUpdate:show":e.onActionCompleted,onConfirmationCancelled:e.onActionCompleted,onConfirmationOk:e.onCatalogProductDelete},{default:P(()=>[G(`div`,EP,[q(j(e.t(`CatalogProductConfirmDelete`))+` `,1),G(`strong`,DP,j(e.attrValue(e.currentActionData.product,`#DisplayName`)),1)])]),_:1},8,[`t`,`title`,`item`,`onUpdate:show`,`onConfirmationCancelled`,`onConfirmationOk`])):J(``,!0)],64)):J(``,!0)],512)}var kP=Q(wP,[[`render`,OP]]),AP=[`catalog`,`product`,`alias`],jP={catalog:`catalogs`,product:`products`,alias:`aliases`},MP=L({name:`pis-catalogs-common-view-switch`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isReady:i,isWebComponent:a,store:o,t:s,narrowerThan:c}=ym(t,e.instanceId),l=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.viewSwitch)??{}}),u=AP,d=e=>u.includes(e),f=Y(()=>l.value?(l.value.views||[]).filter(d):[]),p=Y(()=>{var e;return(e=r.value)==null?void 0:e.router.routeData.view}),m={catalog:`Catalogs`,product:`Products`,alias:`Aliases`},h={catalog:wu,product:Tu,alias:Eu};return{root:t,store:o,isReady:i,routeMap:jP,routeView:p,allowedViews:f,componentName:n,isWebComponent:a,translationMap:m,t:s,switchToView:async e=>{if(d(e))try{if(h[e]){var t;await((t=r.value)==null?void 0:t.execute(new h[e]))}}catch{}},narrowerThan:c}}}),NP={key:0,class:`mb-3`},PP={class:`nav nav-tabs`},FP=[`onClick`];function IP(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A([`pis-component position-relative`,e.componentName])},[e.isReady?(H(),U(`div`,NP,[G(`ul`,PP,[(H(!0),U(V,null,z(e.allowedViews,t=>(H(),U(`li`,{key:t,class:A([`nav-item`,{"w-100":e.narrowerThan(`sm`)}])},[G(`a`,{class:A([`nav-link`,e.routeView===e.routeMap[t]?`active`:``]),href:`#`,onClick:X(n=>e.switchToView(t),[`prevent`])},j(e.t(e.translationMap[t])),11,FP)],2))),128))])])):J(``,!0)],2)}var LP=Q(MP,[[`render`,IP]]),RP=L({name:`AttributeValueTable`,props:{table:{type:Object,required:!0}}}),zP={class:`table-responsive pis-scroll`},BP={class:`table table-sm mt-2`};function VP(e,t,n,r,i,a){let o=Hr(`safe-html`);return H(),U(`div`,zP,[G(`table`,BP,[G(`thead`,null,[G(`tr`,null,[(H(!0),U(V,null,z(e.table.columns,e=>(H(),U(`th`,{key:e.dataField,class:`text-center`},[F(G(`span`,null,null,512),[[o,e.text]])]))),128))])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.table.rows,(t,n)=>(H(),U(`tr`,{key:n},[(H(!0),U(V,null,z(e.table.columns,e=>{var n,r;return H(),U(`td`,{key:e.dataField,class:`text-center`},[(n=t.values)!=null&&n[e.dataField]?(H(!0),U(V,{key:0},z((r=t.values)==null?void 0:r[e.dataField],(e,t)=>(H(),U(`div`,{key:t,class:`text-nowrap`},j(e.text),1))),128)):J(``,!0)])}),128))]))),128))])])])}var HP=Q(RP,[[`render`,VP]]),UP=L({name:`InteractiveText`,props:{text:{type:String,required:!0},instance:{type:Object,required:!0}},setup(e){let t=async t=>{try{var n;(n=e.instance)==null||n.execute(new bp({productId:t}).from(`interactive-text`))}catch{}};return{renderText:()=>{let n=/{{([^}]+)}}/,r=e.text.split(`
96
+ `),i=[];return r.forEach((e,a)=>{let o=e,s;for(;(s=n.exec(o))!==null;){let e=o.slice(0,s.index);e&&i.push(Qa(`span`,e));let n=s[1];i.push(Qa(`a`,{href:`#`,onClick:e=>{e.preventDefault(),t(n)}},n)),o=o.slice(s.index+s[0].length)}o&&i.push(Qa(`span`,o)),a<r.length-1&&i.push(Qa(`br`))}),Qa(`span`,i)}}}}),WP={style:{"white-space":`pre-wrap`}};function GP(e,t,n,r,i,a){return H(),U(`div`,WP,[(H(),W(Vr(e.renderText)))])}var KP=Q(UP,[[`render`,GP]]),qP=L({name:`PisLink`,props:{link:{type:Object,required:!0},instance:{type:Object,required:!0},clearSearch:{type:Boolean,default:!1},onBeforeClick:{type:Function,required:!1,default:void 0}},setup(e){return{onLinkClick:async()=>{if(e.onBeforeClick)try{e.onBeforeClick()}catch{}let t=e.link;switch(t.type){case Ql.NONE:break;case Ql.CLASSIFICATION:if(t.cid)try{var n;await((n=e.instance)==null?void 0:n.execute(new Op({cid:t.cid,clearSearch:e.clearSearch}).from(`pis-link`)))}catch{}break;case Ql.DETAIL:if(t.productId)try{var r;await((r=e.instance)==null?void 0:r.execute(new bp({productId:t.productId}).from(`pis-link`)))}catch{}break;case Ql.DOCUMENT:if(t.documentId)try{var i;await((i=e.instance)==null?void 0:i.execute(new Cp({documentId:t.documentId}).from(`pis-link`)))}catch{}break;case Ql.SEARCH:if(t.searchText)try{var a;await((a=e.instance)==null?void 0:a.execute(new yp({searchText:t.searchText,searchType:ru.EXACT_PHRASE}).from(`pis-link`)))}catch{}break;case Ql.TECHNICAL_INFORMATION:}}}}});function JP(e,t,n,r,i,a){return H(),U(`a`,{href:`#`,onClick:t[0]||(t[0]=X((...t)=>e.onLinkClick&&e.onLinkClick(...t),[`prevent`]))},[B(e.$slots,`default`)])}var YP=Q(qP,[[`render`,JP]]),XP=L({name:`AttributesTable`,components:{Icon:$h,Arrow:qb,Tooltip:Fw,PisLink:YP,LinkSecondary:kE,InteractiveText:KP,AttributeValueTable:HP},props:{attributes:{type:Object,default:void 0},instance:{type:Object,required:!0},hideDocumentLinks:{type:Boolean,required:!0},t:{type:Function,required:!0}},setup(e){let t=Y(()=>{var t;if(((t=e.instance)==null?void 0:t.instanceType)==`Products`){var n;return((n=e.instance.store)==null||(n=n.options.components)==null||(n=n.common)==null?void 0:n.maxAttributeValuesVisible)||1/0}return 1/0}),n=[`#AllIdentifiers`,`#DisplayName`],r=Ut({}),i={},a=(e,t)=>{i[e]=t},o=e=>r[e];return{records:Y(()=>Object.values(e.attributes||{}).reduce((e,r)=>{if(!n.includes(r.attributeCode)){var i;let n=r.values||[],a=(((i=r.values)==null?void 0:i.length)||0)>t.value;e.push({shouldBeTrimmed:a,attr:r,trimmedValues:o(r.attributeCode)?n:n.slice(0,t.value)})}return e},[])),storeAttrRef:a,isDisabledTrimming:o,toggleValueTrimming:e=>{r[e]?(delete r[e],i[e]&&i[e].scrollIntoView()):r[e]=!0}}}}),ZP={key:0,class:`col`},QP={key:0,class:`fw-bold ps-lg-3`},$P={class:`col-md-4`},eF=[`id`],tF={class:`w-100`},nF={class:`ps-lg-3`},rF=[`title`],iF={key:0,class:`flex-shrink-1 px-2`},aF={key:2,style:{"white-space":`pre-wrap`}},oF={class:`d-print-none ext-attr-val`},sF={key:2,style:{"white-space":`pre-wrap`}},cF={key:0};function lF(e,t,n,r,i,a){let o=R(`AttributeValueTable`),s=R(`Icon`),c=R(`Tooltip`),l=R(`InteractiveText`),u=R(`PisLink`),d=R(`Arrow`),f=R(`LinkSecondary`),p=Hr(`safe-html`);return H(!0),U(V,null,z(e.records,(t,n)=>(H(),U(`div`,{key:n,class:A([`row g-0 py-1 py-lg-2`,{"border-bottom":t.attr.type!=`Table`,"bg-warning":t.attr.highlight}])},[t.attr.type==`Table`&&t.attr.table?(H(),U(`div`,ZP,[t.attr.attributeName?(H(),U(`span`,QP,j(t.attr.attributeName)+`: `,1)):J(``,!0),K(o,{table:t.attr.table},null,8,[`table`])])):(H(),U(V,{key:1},[G(`div`,$P,[G(`div`,{id:t.attr.attributeCode==`TechnicalInformation`?`pis-anchor-attr-TechnicalInformation`:void 0,class:`d-flex`},[G(`div`,tF,[G(`div`,nF,[F(G(`span`,{class:`d-inline-block w-100 text-wrap fw-bold ext-attr-name`,style:{overflow:`hidden`,"text-overflow":`ellipsis`},title:t.attr.tooltip},null,8,rF),[[p,t.attr.attributeName+`:`]])])]),t.attr.internal?(H(),U(`div`,iF,[K(c,{text:e.t(`Internal`,!0)},{default:P(()=>[K(s,{class:`text-warning text-end`,name:`warning-triangle`})]),_:1},8,[`text`])])):J(``,!0)],8,eF)]),G(`div`,{ref_for:!0,ref:n=>e.storeAttrRef(t.attr.attributeCode,n),class:`col-md-8`},[(H(!0),U(V,null,z(t.attr.values,(t,n)=>(H(),U(`div`,{key:n,class:`pis-print-only ext-attr-val`},[t.interactiveText?(H(),W(l,{key:0,instance:e.instance,text:t.interactiveText},null,8,[`instance`,`text`])):t.link&&!e.hideDocumentLinks?(H(),W(u,{key:1,link:t.link,instance:e.instance,"clear-search":!0},{default:P(()=>[q(j(t.link.text),1)]),_:2},1032,[`link`,`instance`])):F((H(),U(`div`,aF,null,512)),[[p,t.text]])]))),128)),G(`div`,oF,[(H(!0),U(V,null,z(t.trimmedValues,(t,n)=>(H(),U(`div`,{key:n},[t.interactiveText?(H(),W(l,{key:0,instance:e.instance,text:t.interactiveText},null,8,[`instance`,`text`])):t.link&&!e.hideDocumentLinks?(H(),W(u,{key:1,link:t.link,instance:e.instance,"clear-search":!0},{default:P(()=>[q(j(t.link.text),1)]),_:2},1032,[`link`,`instance`])):F((H(),U(`div`,sF,null,512)),[[p,t.text]])]))),128)),t.shouldBeTrimmed?(H(),U(`div`,cF,[K(f,{onClick:X(n=>e.toggleValueTrimming(t.attr.attributeCode),[`prevent`])},{default:P(()=>[K(d,{class:`me-2`,dir:e.isDisabledTrimming(t.attr.attributeCode)?`up`:`down`},null,8,[`dir`]),q(` `+j(e.isDisabledTrimming(t.attr.attributeCode)?e.t(`HideMore`):e.t(`ShowMore`)),1)]),_:2},1032,[`onClick`])])):J(``,!0)])],512)],64))],2))),128)}var uF=Q(XP,[[`render`,lF]]),dF=L({components:{Modal:Qy,Image:CO,Arrow:qb,Clickable:wm},props:{images:{type:Array,default:void 0},showPreview:Boolean,hideThumbnails:Boolean,disableModal:Boolean,isLoading:Boolean,alwaysShowThumbnails:Boolean,showOverlayArrows:Boolean,title:{type:String,default:void 0}},setup(e){let t=M(!1),n=M(0),r=Y(()=>{var t;return(t=e.images)!=null&&t.length?e.images[n.value]:null}),i=()=>{var n;!e.disableModal&&!((n=r.value)!=null&&n.noImage)&&(t.value=!0)};return I(()=>e.images,()=>{n.value=0}),{imageModalShown:t,currentIndex:n,currentImage:r,openImageModal:i,nextImage:()=>{if(e.images){let t=n.value;n.value=t<e.images.length-1?t+1:0}},previousImage:()=>{if(e.images){let t=n.value;n.value=t===0?e.images.length-1:t-1}},onItemClick:t=>{n.value=t,e.showPreview||i()}}}}),fF={class:`position-relative`},pF={key:0,class:`col-12 d-flex align-items-center justify-content-center pt-2 position-relative`},mF={class:`d-flex flex-grow-1 justify-content-center`},hF={key:1,class:`position-relative`},gF={key:0,class:`position-relative ext-gallery-modal`},_F={class:`px-2 position-absolute top-50 start-0 text-dark fs-3 ext-arrow-left`},vF=[`src`],yF={class:`px-2 position-absolute top-50 end-0 text-dark fs-3 ext-arrow-right`};function bF(e,t,n,r,i,a){let o=R(`Image`),s=R(`Clickable`),c=R(`Arrow`),l=R(`Modal`);return H(),U(V,null,[e.images&&e.images.length?(H(),U(`div`,{key:0,class:A([`pis-gallery`,[e.showPreview?`row g-2`:`d-flex flex-wrap`]]),style:{"max-width":`700px`}},[G(`div`,fF,[e.showPreview&&e.currentImage?(H(),W(s,{key:0,class:`col-12`,disabled:e.disableModal||e.currentImage.noImage,onClick:e.openImageModal},{default:P(()=>[K(o,{src:e.currentImage.url,"max-size":500,"is-loading":e.isLoading,padding:4},null,8,[`src`,`is-loading`])]),_:1},8,[`disabled`,`onClick`])):J(``,!0),e.showOverlayArrows&&e.images.length>1?(H(),U(V,{key:1},[G(`a`,{href:``,class:`text-dark ext-arrow-left`,style:{"z-index":`2`,"font-size":`1.6rem`,position:`absolute`,top:`calc(50% - 1rem)`,left:`0.4rem`},onClick:t[0]||(t[0]=X((...t)=>e.previousImage&&e.previousImage(...t),[`prevent`]))},[K(c,{dir:`left`})]),G(`a`,{href:``,class:`text-dark ext-arrow-right`,style:{"z-index":`2`,"font-size":`1.6rem`,position:`absolute`,top:`calc(50% - 1rem)`,right:`0.4rem`},onClick:t[1]||(t[1]=X((...t)=>e.nextImage&&e.nextImage(...t),[`prevent`]))},[K(c,{dir:`right`})])],64)):J(``,!0),B(e.$slots,`default`)]),e.images.length>+!e.alwaysShowThumbnails?(H(),U(V,{key:0},[e.hideThumbnails?(H(),U(`div`,pF,[G(`div`,mF,[(H(!0),U(V,null,z(e.images,(t,n)=>(H(),W(s,{key:n,class:`px-2`,onClick:t=>e.onItemClick(n)},{default:P(()=>[G(`div`,{class:A([`ps-3 pt-3 rounded-circle`,[n===e.currentIndex?`bg-primary`:`bg-light`]])},null,2)]),_:2},1032,[`onClick`]))),128))])])):(H(!0),U(V,{key:1},z(e.images,(t,n)=>(H(),W(s,{key:n,class:A([e.showPreview?`col-4`:`me-2 mb-2`]),style:k([!e.showPreview&&`width: 6rem;`]),onClick:t=>e.onItemClick(n)},{default:P(()=>[K(o,{src:t.thumbnailUrl,active:n===e.currentIndex&&e.showPreview,"max-size":100,padding:3},null,8,[`src`,`active`])]),_:2},1032,[`class`,`style`,`onClick`]))),128))],64)):J(``,!0)],2)):(H(),U(`div`,hF,[K(o,{src:void 0,"is-loading":e.isLoading},null,8,[`is-loading`]),B(e.$slots,`default`)])),K(l,{show:e.imageModalShown,"onUpdate:show":t[4]||(t[4]=t=>e.imageModalShown=t),title:e.title,xl:``},{default:P(()=>[e.images&&e.images.length?(H(),U(`div`,gF,[e.images.length>1?(H(),U(`a`,{key:0,href:``,class:`position-absolute top-0 bottom-0 start-0 h-100 pis-hover`,style:{width:`40px`},onClick:t[2]||(t[2]=X((...t)=>e.previousImage&&e.previousImage(...t),[`prevent`]))},[G(`div`,_F,[K(c,{dir:`left`})])])):J(``,!0),e.currentImage?(H(),U(`img`,{key:1,class:`pis-scale-down p-2 p-lg-5`,src:e.currentImage.masterUrl,alt:``},null,8,vF)):J(``,!0),e.images.length>1?(H(),U(`a`,{key:2,href:``,class:`position-absolute top-0 end-0 bottom-0 pis-hover`,style:{width:`40px`},onClick:t[3]||(t[3]=X((...t)=>e.nextImage&&e.nextImage(...t),[`prevent`]))},[G(`div`,yF,[K(c,{dir:`right`})])])):J(``,!0)])):J(``,!0)]),_:1},8,[`show`,`title`])],64)}var xF=Q(dF,[[`render`,bF]]),SF=L({name:`pis-catalogs-products-preview`,components:{MountPoint:cg,Modal:Qy,AttributesTable:uF,ImageGallery:xF,Btn:Iy},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,routeData:s,t:c,emit:l}=ym(t,e.instanceId,[Ud.Products]),u=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.preview)==null?void 0:e.view)??{}}),d=Y({get:()=>{var e;return(e=o.value)==null?void 0:e.data.productPreview},set:e=>{var t;(t=o.value)!=null&&t.data&&`productPreview`in o.value.data&&(o.value.data.productPreview=e)}}),f=Y(()=>{var e;return(e=d.value)==null?void 0:e.item}),p=Y(()=>{var e;return((e=f.value)==null?void 0:e.attributes)||{}}),m=Y(()=>{var e;return((e=f.value)==null?void 0:e.replacements)||[]}),h=Y(()=>f.value?Us(f.value,`#DisplayName`):``),g=Y(()=>f.value?Ws(f.value,`#AllIdentifiers`):[]),_=Y(()=>!0),v=async e=>{if(!(e!=null&&e.inactive)&&(y(),s.value&&e))try{var t;await((t=n.value)==null?void 0:t.execute(new _u(e).from(r)))}catch{}},y=()=>d.value=void 0;return{previewData:d,root:t,componentName:r,componentOptions:u,isReady:i,isWebComponent:a,store:o,routeData:s,instance:n,title:h,attributes:p,replacements:m,identifiers:g,item:f,hideDocumentLinks:_,attrValues:Ws,t:c,emit:l,details:v,attrValue:Us,close:y,reactiveContext:lg}}}),CF={key:0},wF={key:0,class:`mb-4`},TF={class:`row my-4`},EF={class:`col-12 col-md-4 mb-4`},DF={key:0},OF={class:`mt-4`},kF={class:`col-12 col-md-8 order-md-first`};function AF(e,t,n,r,i,a){let o=R(`Btn`),s=R(`MountPoint`),c=R(`ImageGallery`),l=R(`AttributesTable`),u=R(`Modal`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(`div`,CF,[K(u,{show:e.previewData,"onUpdate:show":t[1]||(t[1]=t=>e.previewData=t),title:e.title,xl:``},{"header-actions":P(()=>[K(o,{onClick:t[0]||(t[0]=t=>e.item&&e.details(e.item))},{default:P(()=>[q(j(e.t(`ViewDetails`)),1)]),_:1})]),default:P(()=>{var t;return[e.identifiers.length?(H(),U(`div`,wF,[(H(!0),U(V,null,z(e.identifiers,e=>(H(),U(`div`,{key:e,class:`text-muted`},j(e),1))),128))])):J(``,!0),G(`div`,TF,[G(`div`,EF,[K(c,{"show-preview":``,"hide-thumbnails":``,"disable-modal":``,images:(t=e.item)==null?void 0:t.images,"show-overlay-arrows":!0,title:e.t(`ProductGallery`)},{default:P(()=>[e.componentOptions.imageOverlayTemplate?(H(),U(`div`,DF,[K(s,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.reactiveContext({instance:e.instance,item:e.item,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)]),_:1},8,[`images`,`title`]),G(`div`,OF,[e.componentOptions.actionTemplate?(H(),W(s,{key:0,callbacks:e.componentOptions.actionTemplate,ctx:e.reactiveContext({instance:e.instance,item:e.item,emit:e.emit,details:e.details,attrValue:e.attrValue,attrValues:e.attrValues,close:e.close,t:e.t})},null,8,[`callbacks`,`ctx`])):J(``,!0)])]),G(`div`,kF,[K(l,{instance:e.instance,attributes:e.attributes,"hide-document-links":e.hideDocumentLinks,t:e.t},null,8,[`instance`,`attributes`,`hide-document-links`,`t`])])])]}),_:1},8,[`show`,`title`])])):J(``,!0)],2)}var jF=Q(SF,[[`render`,AF]]),MF=L({name:`pis-catalogs-products-search-no-results`,components:{Btn:Iy},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,t:c}=ym(t,e.instanceId,[Ud.Products]);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:o,noSearchResults:Y(()=>{var e,t;return((e=a.value)==null?void 0:e.getRouteData().products.searchText)&&!((t=o.value)!=null&&(t=t.data.products)!=null&&(t=t.items)!=null&&t.length)}),noProducts:Y(()=>{var e,t,n;return!((e=a.value)!=null&&e.getRouteData().products.searchText)&&!((t=a.value)!=null&&(t=t.getRouteData().products.filters)!=null&&t.rules.length)&&((n=o.value)==null||(n=n.data.products)==null?void 0:n.totalCount)==0}),t:c,clearResults:async()=>{try{var e,t;await((e=a.value)==null?void 0:e.execute(new yu({searchText:``,searchType:((t=s.value)==null?void 0:t.products.searchType)??zl.WITH_ALL_WORDS}).from(n)))}catch{}}}}}),NF={key:0},PF={class:`h5`},FF={key:1,class:`my-3 text-muted`};function IF(e,t,n,r,i,a){let o=R(`Btn`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(V,{key:0},[e.noSearchResults?(H(),U(`div`,NF,[G(`p`,PF,j(e.t(`NoResults`)),1),G(`p`,null,[G(`strong`,null,j(e.t(`Suggestions`))+`:`,1)]),G(`ul`,null,[G(`li`,null,j(e.t(`CheckSpelling`)),1),G(`li`,null,j(e.t(`DifferentKeywords`)),1),G(`li`,null,j(e.t(`ContactSupport`)),1)]),K(o,{onClick:X(e.clearResults,[`prevent`])},{default:P(()=>[q(j(e.t(`Clear`)),1)]),_:1},8,[`onClick`])])):J(``,!0),e.noProducts?(H(),U(`div`,FF,j(e.t(`NoResults`)),1)):J(``,!0)],64)):J(``,!0)],2)}var LF=Q(MF,[[`render`,IF]]),RF=L({name:`pis-catalogs-layout`,components:{LoadingIndicator:vT,CatalogsSearchTable:Zw,CatalogsSearchForm:Wb,ProductsSearchTable:_j,ProductsSearchFilters:fO,ProductsSearchFiltersStatus:yO,ProductsSearchProductCategories:FA,ProductsSearchPartCategories:AA,ProductsBreadcrumbs:_E,ProductsSearchToolbar:Mj,ProductsSearchPagination:TA,CatalogsSearchPagination:ox,ProductsTableView:Wj,ProductsListView:Bj,ProductsGridView:Ij,ProductsSearchList:bA,ProductsSearchGrid:Qk,ProductsSearchForm:UO,CatalogProductSwitch:LP,CatalogActionModals:UN,CatalogProductActionModals:kP,CatalogsSearchToolbar:dT,ProductsPreviewView:jF,ProductsSearchNoResults:LF,CatalogsNotifications:jT,ProductsSearchSelection:HA,CatalogProductsMobileNav:Xj,ProductsSearchAliasFilters:TE,AliasesSearchTable:Rg,AliasActionModals:dE,AliasesSearchToolbar:cy,AliasesMobileNav:nb},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isWebComponent:i,isReady:a,translationsReady:o,store:s,routeData:c,widerThan:l,t:u}=ym(t,e.instanceId),d=Y(()=>{var e;return(e=s.value)==null?void 0:e.options.allowMobileView}),f=e=>e==null?void 0:e.scrollIntoView({behavior:`smooth`}),p=()=>{var e;let n={isHandled:!1};(e=r.value)==null||e.eventBus.emit(`scroll-to-top`,n),n.isHandled||f(t.value)};return I(Y(()=>{var e;return(e=c.value)==null?void 0:e.view}),async(e,t)=>{e&&t&&e!==t&&p()}),{root:t,componentName:n,isWebComponent:i,isReady:a,instance:r,translationsReady:o,store:s,routeData:c,allowMobileView:d,widerThan:l,t:u,scrollTop:p}}}),zF={class:`container-fluid`},BF={key:0},VF={class:`container-fluid`},HF={key:1},UF={class:`container-fluid`},WF={class:`row`},GF={class:`d-sm-none`},KF={key:2},qF={class:`container-fluid`},JF={class:`row`},YF={class:`d-sm-none`};function XF(e,t,n,r,i,a){let o=R(`CatalogsNotifications`),s=R(`CatalogProductSwitch`),c=R(`CatalogsSearchForm`),l=R(`CatalogsSearchToolbar`),u=R(`CatalogsSearchTable`),d=R(`CatalogsSearchPagination`),f=R(`ProductsBreadcrumbs`),p=R(`CatalogProductsMobileNav`),m=R(`ProductsSearchProductCategories`),h=R(`ProductsSearchPartCategories`),g=R(`ProductsSearchFilters`),_=R(`ProductsSearchForm`),v=R(`ProductsSearchFiltersStatus`),y=R(`ProductsSearchToolbar`),b=R(`ProductsSearchSelection`),x=R(`ProductsSearchTable`),S=R(`ProductsTableView`),C=R(`ProductsSearchList`),w=R(`ProductsListView`),T=R(`ProductsSearchGrid`),E=R(`ProductsGridView`),D=R(`ProductsSearchNoResults`),ee=R(`ProductsSearchPagination`),O=R(`ProductsPreviewView`),te=R(`AliasesMobileNav`),ne=R(`ProductsSearchAliasFilters`),re=R(`AliasesSearchToolbar`),ie=R(`AliasesSearchTable`),ae=R(`LoadingIndicator`),oe=R(`CatalogActionModals`),se=R(`CatalogProductActionModals`),ce=R(`AliasActionModals`);return H(),U(`div`,{ref:`root`,class:A([`pis-component position-relative`,e.componentName])},[F(G(`div`,null,[K(o),K(ae,null,{default:P(()=>{var n,r,i;return[G(`div`,zF,[K(s)]),((n=e.routeData)==null?void 0:n.view)===`catalogs`?(H(),U(`div`,BF,[G(`div`,VF,[K(c),K(l),t[0]||(t[0]=G(`hr`,null,null,-1)),K(u),K(d)])])):((r=e.routeData)==null?void 0:r.view)===`products`?(H(),U(`div`,HF,[G(`div`,UF,[K(f),G(`div`,WF,[G(`div`,{class:A([e.widerThan(`xl`)?`col-3`:e.widerThan(`md`)?`col-4`:`col-12`])},[F(G(`div`,GF,[K(p)],512),[[Mo,e.allowMobileView]]),G(`div`,{class:A([e.allowMobileView&&`d-none d-sm-block`])},[K(m),K(h),K(g)],2)],2),G(`div`,{class:A([e.widerThan(`xl`)?`col-9`:e.widerThan(`md`)?`col-8`:`col-12`])},[K(_),K(v),K(y),K(b,{class:`mb-2`}),K(S,null,{default:P(()=>[K(x)]),_:1}),K(w,null,{default:P(()=>[K(C)]),_:1}),K(E,null,{default:P(()=>[K(T)]),_:1}),K(D),K(ee),K(O)],2)])])])):((i=e.routeData)==null?void 0:i.view)===`aliases`?(H(),U(`div`,KF,[G(`div`,qF,[K(f),G(`div`,JF,[G(`div`,{class:A([e.widerThan(`xl`)?`col-3`:e.widerThan(`md`)?`col-4`:`col-12`])},[F(G(`div`,YF,[K(te)],512),[[Mo,e.allowMobileView]]),G(`div`,{class:A([e.allowMobileView&&`d-none d-sm-block`])},[K(ne),K(m),K(h)],2)],2),G(`div`,{class:A([e.widerThan(`xl`)?`col-9`:e.widerThan(`md`)?`col-8`:`col-12`])},[K(_),K(re),K(ie),K(D),K(ee)],2)])])])):J(``,!0)]}),_:1})],512),[[Mo,e.isReady]]),K(oe,{t:e.t,"instance-id":e.instanceId},null,8,[`t`,`instance-id`]),K(se,{t:e.t,"instance-id":e.instanceId},null,8,[`t`,`instance-id`]),K(ce,{t:e.t,"instance-id":e.instanceId},null,8,[`t`,`instance-id`])],2)}var ZF=Q(RF,[[`render`,XF]]),QF={itemsToShow:1,itemsToScroll:1,modelValue:0,transition:300,autoplay:0,snapAlign:`center`,wrapAround:!1,throttle:16,pauseAutoplayOnHover:!1,mouseDrag:!0,touchDrag:!0,dir:`ltr`,breakpoints:void 0,i18n:{ariaNextSlide:`Navigate to next slide`,ariaPreviousSlide:`Navigate to previous slide`,ariaNavigateToSlide:`Navigate to slide {slideNumber}`,ariaGallery:`Gallery`,itemXofY:`Item {currentSlide} of {slidesCount}`,iconArrowUp:`Arrow pointing upwards`,iconArrowDown:`Arrow pointing downwards`,iconArrowRight:`Arrow pointing to the right`,iconArrowLeft:`Arrow pointing to the left`}},$F={itemsToShow:{default:QF.itemsToShow,type:Number},itemsToScroll:{default:QF.itemsToScroll,type:Number},wrapAround:{default:QF.wrapAround,type:Boolean},throttle:{default:QF.throttle,type:Number},snapAlign:{default:QF.snapAlign,validator(e){return[`start`,`end`,`center`,`center-even`,`center-odd`].includes(e)}},transition:{default:QF.transition,type:Number},breakpoints:{default:QF.breakpoints,type:Object},autoplay:{default:QF.autoplay,type:Number},pauseAutoplayOnHover:{default:QF.pauseAutoplayOnHover,type:Boolean},modelValue:{default:void 0,type:Number},mouseDrag:{default:QF.mouseDrag,type:Boolean},touchDrag:{default:QF.touchDrag,type:Boolean},dir:{default:QF.dir,validator(e){return[`rtl`,`ltr`].includes(e)}},i18n:{default:QF.i18n,type:Object},settings:{default(){return{}},type:Object}};function eI({config:e,slidesCount:t}){let{snapAlign:n,wrapAround:r,itemsToShow:i=1}=e;if(r)return Math.max(t-1,0);let a;switch(n){case`start`:a=t-i;break;case`end`:a=t-1;break;case`center`:case`center-odd`:a=t-Math.ceil((i-.5)/2);break;case`center-even`:a=t-Math.ceil(i/2);break;default:a=0}return Math.max(a,0)}function tI({config:e,slidesCount:t}){let{wrapAround:n,snapAlign:r,itemsToShow:i=1}=e,a=0;if(n||i>t)return a;switch(r){case`start`:a=0;break;case`end`:a=i-1;break;case`center`:case`center-odd`:a=Math.floor((i-1)/2);break;case`center-even`:a=Math.floor((i-2)/2);break;default:a=0}return a}function nI({val:e,max:t,min:n}){return t<n?e:Math.min(Math.max(e,n),t)}function rI({config:e,currentSlide:t,slidesCount:n}){let{snapAlign:r,wrapAround:i,itemsToShow:a=1}=e,o=t;switch(r){case`center`:case`center-odd`:o-=(a-1)/2;break;case`center-even`:o-=(a-2)/2;break;case`end`:o-=a-1}return i?o:nI({val:o,max:n-a,min:0})}function iI(e){return e?e.reduce((e,t)=>{var n;return t.type===V?[...e,...iI(t.children)]:((n=t.type)==null?void 0:n.name)===`CarouselSlide`?[...e,t]:e},[]):[]}function aI({val:e,max:t,min:n=0}){return e>t?aI({val:e-(t+1),max:t,min:n}):e<n?aI({val:e+(t+1),max:t,min:n}):e}function oI(e,t){let n;return t?function(...r){let i=this;n||(e.apply(i,r),n=!0,setTimeout(()=>n=!1,t))}:e}function sI(e,t){let n;return function(...r){n&&clearTimeout(n),n=setTimeout(()=>{e(...r),n=null},t)}}function cI(e=``,t={}){return Object.entries(t).reduce((e,[t,n])=>e.replace(`{${t}}`,String(n)),e)}var lI=L({name:`ARIA`,setup(){let e=Gn(`config`,Ut(Object.assign({},QF))),t=Gn(`currentSlide`,M(0)),n=Gn(`slidesCount`,M(0));return()=>Qa(`div`,{class:[`carousel__liveregion`,`carousel__sr-only`],"aria-live":`polite`,"aria-atomic":`true`},cI(e.i18n.itemXofY,{currentSlide:t.value+1,slidesCount:n.value}))}}),uI=L({name:`Carousel`,props:$F,setup(e,{slots:t,emit:n,expose:r}){let i=M(null),a=M([]),o=M(0),s=M(0),c=Ut(Object.assign({},QF)),l=Object.assign({},QF),u,d=M(e.modelValue??0),f=M(0),p=M(0),m=M(0),h=M(0),g,_;Wn(`config`,c),Wn(`slidesCount`,s),Wn(`currentSlide`,d),Wn(`maxSlide`,m),Wn(`minSlide`,h),Wn(`slideWidth`,o);function v(){u=Object.assign({},e.breakpoints),l=Object.assign(Object.assign(Object.assign({},l),e),{i18n:Object.assign(Object.assign({},l.i18n),e.i18n),breakpoints:void 0}),b(l)}function y(){if(!u||!Object.keys(u).length)return;let e=Object.keys(u).map(e=>Number(e)).sort((e,t)=>t-+e),t=Object.assign({},l);e.some(e=>{let n=window.matchMedia(`(min-width: ${e}px)`).matches;return n&&(t=Object.assign(Object.assign({},t),u[e])),n}),b(t)}function b(e){Object.entries(e).forEach(([e,t])=>c[e]=t)}let x=sI(()=>{y(),C(),S()},16);function S(){if(!i.value)return;let e=i.value.getBoundingClientRect();o.value=e.width/c.itemsToShow}function C(){s.value<=0||(p.value=Math.ceil((s.value-1)/2),m.value=eI({config:c,slidesCount:s.value}),h.value=tI({config:c,slidesCount:s.value}),c.wrapAround||(d.value=nI({val:d.value,max:m.value,min:h.value})))}kr(()=>{jn(()=>S()),setTimeout(()=>S(),1e3),y(),oe(),window.addEventListener(`resize`,x,{passive:!0}),n(`init`)}),Nr(()=>{_&&clearTimeout(_),g&&clearInterval(g),window.removeEventListener(`resize`,x,{passive:!0})});let w=!1,T={x:0,y:0},E={x:0,y:0},D=Ut({x:0,y:0}),ee=M(!1),O=M(!1),te=()=>{ee.value=!0},ne=()=>{ee.value=!1};function re(e){[`INPUT`,`TEXTAREA`,`SELECT`].includes(e.target.tagName)||(w=e.type===`touchstart`,w||e.preventDefault(),!(!w&&e.button!==0||ce.value)&&(T.x=w?e.touches[0].clientX:e.clientX,T.y=w?e.touches[0].clientY:e.clientY,document.addEventListener(w?`touchmove`:`mousemove`,ie,!0),document.addEventListener(w?`touchend`:`mouseup`,ae,!0)))}let ie=oI(e=>{O.value=!0,E.x=w?e.touches[0].clientX:e.clientX,E.y=w?e.touches[0].clientY:e.clientY;let t=E.x-T.x,n=E.y-T.y;D.y=n,D.x=t},c.throttle);function ae(){let e=c.dir===`rtl`?-1:1,t=Math.sign(D.x)*.4,n=Math.round(D.x/o.value+t)*e;if(n&&!w){let e=t=>{window.removeEventListener(`click`,e,!0)};window.addEventListener(`click`,e,!0)}le(d.value-n),D.x=0,D.y=0,O.value=!1,document.removeEventListener(w?`touchmove`:`mousemove`,ie,!0),document.removeEventListener(w?`touchend`:`mouseup`,ae,!0)}function oe(){!c.autoplay||c.autoplay<=0||(g=setInterval(()=>{c.pauseAutoplayOnHover&&ee.value||ue()},c.autoplay))}function se(){g&&(clearInterval(g),g=null),oe()}let ce=M(!1);function le(e){let t=c.wrapAround?e:nI({val:e,max:m.value,min:h.value});d.value===t||ce.value||(n(`slide-start`,{slidingToIndex:e,currentSlideIndex:d.value,prevSlideIndex:f.value,slidesCount:s.value}),ce.value=!0,f.value=d.value,d.value=t,_=setTimeout(()=>{if(c.wrapAround){let r=aI({val:t,max:m.value,min:0});r!==d.value&&(d.value=r,n(`loop`,{currentSlideIndex:d.value,slidingToIndex:e}))}n(`update:modelValue`,d.value),n(`slide-end`,{currentSlideIndex:d.value,prevSlideIndex:f.value,slidesCount:s.value}),ce.value=!1,se()},c.transition))}function ue(){le(d.value+c.itemsToScroll)}function de(){le(d.value-c.itemsToScroll)}let k={slideTo:le,next:ue,prev:de};Wn(`nav`,k),Wn(`isSliding`,ce);let fe=Y(()=>rI({config:c,currentSlide:d.value,slidesCount:s.value}));Wn(`slidesToScroll`,fe);let pe=Y(()=>{let e=c.dir===`rtl`?-1:1,t=fe.value*o.value*e;return{transform:`translateX(${D.x-t}px)`,transition:`${ce.value?c.transition:0}ms`,margin:c.wrapAround?`0 -${s.value*o.value}px`:``,width:`100%`}});function me(){v(),y(),C(),S(),se()}Object.keys($F).forEach(t=>{[`modelValue`].includes(t)||I(()=>e[t],me)}),I(()=>e.modelValue,e=>{e!==d.value&&le(Number(e))}),I(s,C),n(`before-init`),v();let he={config:c,slidesCount:s,slideWidth:o,next:ue,prev:de,slideTo:le,currentSlide:d,maxSlide:m,minSlide:h,middleSlide:p};r({updateBreakpointsConfigs:y,updateSlidesData:C,updateSlideWidth:S,initDefaultConfigs:v,restartCarousel:me,slideTo:le,next:ue,prev:de,nav:k,data:he});let A=t.default||t.slides,ge=t.addons,_e=Ut(he);return()=>{let e=iI(A==null?void 0:A(_e)),t=(ge==null?void 0:ge(_e))||[];e.forEach((e,t)=>e.props.index=t);let n=e;if(c.wrapAround){let t=e.map((t,n)=>wa(t,{index:-e.length+n,isClone:!0,key:`clone-before-${n}`})),r=e.map((t,n)=>wa(t,{index:e.length+n,isClone:!0,key:`clone-after-${n}`}));n=[...t,...e,...r]}a.value=e,s.value=Math.max(e.length,1);let r=Qa(`div`,{class:`carousel__viewport`},Qa(`ol`,{class:`carousel__track`,style:pe.value,onMousedownCapture:c.mouseDrag?re:null,onTouchstartPassiveCapture:c.touchDrag?re:null},n));return Qa(`section`,{ref:i,class:{carousel:!0,"is-sliding":ce.value,"is-dragging":O.value,"is-hover":ee.value,"carousel--rtl":c.dir===`rtl`},dir:c.dir,"aria-label":c.i18n.ariaGallery,tabindex:`0`,onMouseenter:te,onMouseleave:ne},[r,t,Qa(lI)])}}}),dI;(function(e){e.arrowUp=`arrowUp`,e.arrowDown=`arrowDown`,e.arrowRight=`arrowRight`,e.arrowLeft=`arrowLeft`})(dI||(dI={}));var fI={arrowUp:`M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6-6 6z`,arrowDown:`M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z`,arrowRight:`M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z`,arrowLeft:`M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z`};function pI(e){return e in dI}var mI=e=>{let t=Gn(`config`,Ut(Object.assign({},QF))),n=String(e.name),r=`icon${n.charAt(0).toUpperCase()+n.slice(1)}`;if(!n||typeof n!=`string`||!pI(n))return;let i=fI[n],a=Qa(`path`,{d:i}),o=t.i18n[r]||e.title||n,s=Qa(`title`,o);return Qa(`svg`,{class:`carousel__icon`,viewBox:`0 0 24 24`,role:`img`,"aria-label":o},[s,a])};mI.props={name:String,title:String};var hI=(e,{slots:t,attrs:n})=>{let{next:r,prev:i}=t||{},a=Gn(`config`,Ut(Object.assign({},QF))),o=Gn(`maxSlide`,M(1)),s=Gn(`minSlide`,M(1)),c=Gn(`currentSlide`,M(1)),l=Gn(`nav`,{}),{dir:u,wrapAround:d,i18n:f}=a,p=u===`rtl`;return[Qa(`button`,{type:`button`,class:[`carousel__prev`,!d&&c.value<=s.value&&`carousel__prev--disabled`,n==null?void 0:n.class],"aria-label":f.ariaPreviousSlide,onClick:l.prev},(i==null?void 0:i())||Qa(mI,{name:p?`arrowRight`:`arrowLeft`})),Qa(`button`,{type:`button`,class:[`carousel__next`,!d&&c.value>=o.value&&`carousel__next--disabled`,n==null?void 0:n.class],"aria-label":f.ariaNextSlide,onClick:l.next},(r==null?void 0:r())||Qa(mI,{name:p?`arrowLeft`:`arrowRight`}))]},gI=()=>{let e=Gn(`config`,Ut(Object.assign({},QF))),t=Gn(`maxSlide`,M(1)),n=Gn(`minSlide`,M(1)),r=Gn(`currentSlide`,M(1)),i=Gn(`nav`,{}),a=e=>aI({val:r.value,max:t.value,min:0})===e,o=[];for(let r=n.value;r<t.value+1;r++){let t=Qa(`button`,{type:`button`,class:{"carousel__pagination-button":!0,"carousel__pagination-button--active":a(r)},"aria-label":cI(e.i18n.ariaNavigateToSlide,{slideNumber:r+1}),onClick:()=>i.slideTo(r)}),n=Qa(`li`,{class:`carousel__pagination-item`,key:r},t);o.push(n)}return Qa(`ol`,{class:`carousel__pagination`},o)},_I=L({name:`CarouselSlide`,props:{index:{type:Number,default:1},isClone:{type:Boolean,default:!1}},setup(e,{slots:t}){let n=Gn(`config`,Ut(Object.assign({},QF))),r=Gn(`currentSlide`,M(0)),i=Gn(`slidesToScroll`,M(0)),a=Gn(`isSliding`,M(!1)),o=Y(()=>e.index===r.value),s=Y(()=>e.index===r.value-1),c=Y(()=>e.index===r.value+1),l=Y(()=>{let t=Math.floor(i.value),r=Math.ceil(i.value+n.itemsToShow-1);return e.index>=t&&e.index<=r});return()=>{var r;return Qa(`li`,{style:{width:`${100/n.itemsToShow}%`},class:{carousel__slide:!0,"carousel__slide--clone":e.isClone,"carousel__slide--visible":l.value,"carousel__slide--active":o.value,"carousel__slide--prev":s.value,"carousel__slide--next":c.value,"carousel__slide--sliding":a.value},"aria-hidden":!l.value},(r=t.default)==null?void 0:r.call(t,{isActive:o.value,isClone:e.isClone,isPrev:s.value,isNext:c.value,isSliding:a.value,isVisible:l.value}))}}}),vI=L({name:`pis-catalogs-products-search-grid-horizontal`,components:{Image:CO,Icon:$h,Carousel:uI,Slide:_I,Pagination:gI,Navigation:hI,MountPoint:cg,Clickable:wm,ItemCatalogsDetailsModal:Ak},props:{instanceId:{type:String,default:void 0}},setup(e){let t=Vl,n=M(),{componentName:r,isWebComponent:i,isReady:a,instance:o,store:s,routeData:c,t:l,widerThan:u,narrowerThan:d,emit:f}=ym(n,e.instanceId,[Ud.Products]),p=M(),m=I(()=>a.value,()=>{o.value&&(m(),o.value.eventBus.on(`route-changed`,()=>{let e=p.value;e&&(jn(()=>{e.slideTo(0)}),setTimeout(()=>{_.value=!0},100))}),v())}),h=()=>{let e=y.value.carousel,t=window.innerWidth;if(e){if(!e.breakpoints)return e.defaults;let n=Object.keys(e.breakpoints);if(n.length){for(let r=n.length-1;r>=0;r--)if(t>parseInt(n[r]))return e.breakpoints[n[r]]}return e.defaults}return{}},g=M(),_=M(!1),v=()=>{g.value=h()};kr(()=>{window.addEventListener(`resize`,v)}),Nr(()=>{window.removeEventListener(`resize`,v)});let y=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.products)==null||(e=e.search)==null?void 0:e.gridHorizontal)??{}}),b=async e=>{if(!e.inactive)try{if(c.value&&e){var t;await((t=o.value)==null?void 0:t.execute(new _u(e).from(r)))}}catch{}},x=async e=>{if(e&&!e.inactive)try{var t;await((t=o.value)==null?void 0:t.execute(new _u(e).from(r)))}catch{}},S=Y(()=>{var e;return((e=s.value)==null||(e=e.data.products)==null?void 0:e.items)??[]}),C=Y(()=>{let e=y.value.carousel;if(!e)return{};let t=e.defaults||{};return t?{...t,mouseDrag:e.mouseDrag,touchDrag:e.touchDrag,wrapAround:e.wrapAround,transition:e.transition}:{}}),w=Y(()=>{var e;return((e=y.value.carousel)==null?void 0:e.breakpoints)||{}}),T=Y(()=>({ariaNextSlide:l(`CarouselAriaNextSlide`),ariaPreviousSlide:l(`CarouselAriaPreviousSlide`),ariaNavigateToSlide:l(`CarouselAriaNavigateToSlide`),ariaGallery:l(`CarouselAriaGallery`),itemXofY:l(`CarouselItemXofY`),iconArrowUp:l(`CarouselIconArrowUp`),iconArrowDown:l(`CarouselIconArrowDown`),iconArrowRight:l(`CarouselIconArrowRight`),iconArrowLeft:l(`CarouselIconArrowLeft`)})),E=M(),D=M(!1);return{root:n,instance:o,loaded:_,componentName:r,componentOptions:y,isWebComponent:i,isReady:a,store:s,productsItems:S,settings:C,breakpoints:w,carousel:p,i18n:T,currentSettings:g,selectedItem:E,baseProductDetails:x,t:l,widerThan:u,narrowerThan:d,attrValue:Us,attrValues:Ws,details:b,emit:f,toggleItemDetails:e=>{E.value=e,D.value=!1,jn(()=>{D.value=!0})},getItemImage:e=>{var t;if(e.baseProduct){var n;return(n=(e.baseProduct.images||[])[0])==null?void 0:n.url}return(t=(e.images||[])[0])==null?void 0:t.url},previewEnabled:Y(()=>{var e;return((e=o.value)==null?void 0:e.registeredComponents.has(`pis-catalogs-products-preview`))??!1}),catalogProductType:t,catalogsModalVisible:D,showingAllCatalogs:Y(()=>{var e;return!((e=c.value)!=null&&e.products.catalogId)}),imageOverlayCtx:hg(e=>({instance:o.value,item:e.item,emit:f,t:l})),titleCtx:hg(e=>({instance:o.value,item:e.item,emit:f,details:b,baseProductDetails:x,attrValue:Us,t:l})),itemCtx:hg(e=>({instance:o.value,item:e.item,emit:f,details:b,baseProductDetails:x,attrValue:Us,attrValues:Ws,t:l}))}}}),yI={class:`card-img-top position-relative pt-5`},bI={key:0},xI={class:`card-body`},SI={key:0,style:{position:`absolute`,bottom:`0`,right:`0`,"z-index":`2`}},CI=[`onClick`],wI={class:`d-flex justify-content-center text-center`},TI={key:1,class:`d-flex flex-column`},EI={key:0,class:`text-muted`},DI=[`onClick`],OI={key:2,class:`text-muted small`},kI={key:0},AI={key:1},jI={key:1,class:`fw-bold text-muted`},MI={key:0,class:`card-footer`},NI={class:`text-center`},PI={key:1,class:`position-absolute p-2 top-0 start-0 ext-select-checkbox`,style:{"z-index":`1`,width:`auto`}},FI=[`checked`,`onClick`];function II(e,t,n,r,i,a){var o;let s=R(`Image`),c=R(`MountPoint`),l=R(`Icon`),u=R(`Clickable`),d=R(`slide`),f=R(`navigation`),p=R(`pagination`),m=R(`carousel`),h=R(`ItemCatalogsDetailsModal`);return H(),U(`div`,{ref:`root`,class:A([`pis-component position-relative`,e.componentName])},[e.isReady&&(o=e.componentOptions)!=null&&o.visible&&e.currentSettings?(H(),W(m,Oa({key:0,ref:`carousel`},e.settings,{breakpoints:e.breakpoints,i18n:e.i18n}),{addons:P(()=>[e.currentSettings.navigationVisible?(H(),W(f,{key:0},{next:P(()=>[K(l,{name:`chevron-right`})]),prev:P(()=>[K(l,{name:`chevron-left`})]),_:1})):J(``,!0),e.currentSettings.paginationVisible?(H(),W(p,{key:1})):J(``,!0)]),default:P(()=>[(H(!0),U(V,null,z(e.productsItems,n=>(H(),W(d,{key:n.productId},{default:P(()=>{var r;return[G(`div`,{class:A([`card h-100 w-100`,[`mx-`+e.currentSettings.margin]])},[G(`div`,yI,[K(s,{src:e.getItemImage(n),"max-size":300,role:`button`,"hide-frame":``,class:`card-img-top`,style:{"max-width":`80% !important`,margin:`auto`},clickable:e.componentOptions.navigateOnContentClick,onClick:X(t=>e.componentOptions.navigateOnContentClick&&e.details(n),[`prevent`])},null,8,[`src`,`clickable`,`onClick`]),e.componentOptions.imageOverlayTemplate?(H(),U(`div`,bI,[K(c,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:n})},null,8,[`callbacks`,`ctx`])])):J(``,!0)]),G(`div`,xI,[e.componentOptions.detailsVisible?(H(),U(`div`,SI,[G(`a`,{href:``,class:`btn btn-link text-dark d-flex align-items-center`,onClick:X(t=>e.toggleItemDetails(n),[`prevent`])},[K(l,{name:`plus-add`,class:`py-1`,style:{"font-size":`1.1rem`}})],8,CI)])):J(``,!0),G(`div`,wI,[e.componentOptions.titleTemplate?(H(),W(c,{key:0,callbacks:e.componentOptions.titleTemplate,ctx:e.titleCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(`div`,TI,[n.inactive?(H(),U(`strong`,EI,j(e.attrValue(n,`#DisplayName`)),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(t=>e.details(n),[`prevent`])},[G(`strong`,null,j(e.attrValue(n,`#DisplayName`)),1)],8,DI)),n.productType===e.catalogProductType.CONFIGURED?(H(),U(`div`,OI,[G(`em`,null,j(e.t(`ConfiguredProducts`)),1)])):J(``,!0)]))]),e.componentOptions.showAllIdentifiers?(H(!0),U(V,{key:1},z(e.attrValues(n,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`text-center small text-muted fw-bold my-2`},j(e),1))),128)):J(``,!0),e.componentOptions.itemTemplate?(H(),W(c,{key:2,callbacks:e.componentOptions.itemTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:3},[n.customerClassification?(H(),U(`em`,kI,[q(j(e.t(`CustomerClassification`))+`:\xA0 `+j(n.customerClassification)+` `,1),t[1]||(t[1]=G(`br`,null,null,-1))])):J(``,!0),n.baseProduct?(H(),U(`em`,AI,[q(j(e.t(`BaseProductId`))+`:\xA0 `,1),n.baseProduct.inactive?(H(),U(`span`,jI,j(n.baseProduct.productId),1)):(H(),W(u,{key:0,onClick:t=>e.baseProductDetails(n.baseProduct)},{default:P(()=>[q(j(n.baseProduct.productId),1)]),_:2},1032,[`onClick`])),t[2]||(t[2]=G(`br`,null,null,-1))])):J(``,!0)],64))]),e.componentOptions.actionTemplate?(H(),U(`div`,MI,[G(`div`,NI,[K(c,{callbacks:e.componentOptions.actionTemplate,ctx:e.itemCtx({item:n})},null,8,[`callbacks`,`ctx`])])])):J(``,!0),e.componentOptions.selectable?(H(),U(`div`,PI,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(r=e.instance)==null?void 0:r.selection.isSelected(n),onClick:t=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(n)}},null,8,FI)])):J(``,!0)],2)]}),_:2},1024))),128))]),_:1},16,[`breakpoints`,`i18n`])):J(``,!0),K(h,{"instance-id":e.instanceId,item:e.selectedItem,show:e.catalogsModalVisible,t:e.t,"all-catalogs":e.showingAllCatalogs,onHidden:t[0]||(t[0]=t=>e.catalogsModalVisible=!1)},null,8,[`instance-id`,`item`,`show`,`t`,`all-catalogs`])],2)}var LI=[jT,LP,Zw,ZF,ox,Wb,dT,_E,FA,AA,fO,yO,UO,jF,Mj,_j,bA,Qk,HA,LF,TA,UN,kP,Xj,TE,Rg,cy,dE,nb,Q(vI,[[`render`,II]])],RI=0,zI=typeof HTMLElement>`u`?class{}:HTMLElement;function BI(e){class t extends zI{constructor(...e){super(...e),Z(this,`instance`,void 0),Z(this,`resolvedId`,void 0)}connectedCallback(){if(this.instance)return;let t=this.getAttribute(`instance-id`);this.resolvedId=t??`${e.idPrefix}${++RI}`,this.instance=e.getInstanceById(this.resolvedId)}disconnectedCallback(){jn(()=>{var e;if(this.isConnected)return;let t=this.instance;this.instance=void 0,this.resolvedId=void 0,t==null||(e=t.destroy)==null||e.call(t)})}getInstance(){return this.instance}getInstanceId(){return this.resolvedId}}return t}var VI=new WeakMap;function HI(e){let t=typeof HTMLElement>`u`?class{}:HTMLElement;class n extends t{constructor(...e){super(...e),Z(this,`instance`,void 0),Z(this,`stopWatch`,void 0),Z(this,`observer`,void 0),Z(this,`overlayShown`,void 0),Z(this,`overlayDelay`,void 0),Z(this,`spinnerWrap`,void 0),Z(this,`backdrop`,void 0),Z(this,`hostPositionTouched`,!1),Z(this,`attempted`,!1)}connectedCallback(){var t;if(this.syncLoaderChildren(),(t=this.observer)==null||t.disconnect(),this.observer=new MutationObserver(()=>this.syncLoaderChildren()),this.observer.observe(this,{childList:!0}),this.instance){this.startEffect();return}this.attempted||(this.attempted=!0,hm(this,e,t=>{this.instance=t,t.registerComponent(e.tag),this.startEffect()}))}disconnectedCallback(){var e;this.stopWatching(),(e=this.observer)==null||e.disconnect(),this.observer=void 0,jn(()=>{this.isConnected||(this.stopWatching(),this.setOverlay(!1),this.instance=void 0,this.attempted=!1)})}startEffect(){this.stopWatching();let t=fT({isShown:()=>this.overlayShown===!0,setShow:e=>this.setOverlay(e)});this.overlayDelay=t,this.stopWatch=Jn(()=>{let n=this.instance;if(!n||!e.isReady(n)){t.update(!1,!1);return}t.update(e.isLoading(n),e.hasContent(n))})}stopWatching(){var e,t;(e=this.stopWatch)==null||e.call(this),this.stopWatch=void 0,(t=this.overlayDelay)==null||t.cancel(),this.overlayDelay=void 0}loaderChildren(){return Array.from(this.children).filter(e=>e.getAttribute(`slot`)===`loader`)}syncLoaderChildren(){let e=this.loaderChildren(),t=this.overlayShown===!0;for(let n of e)t?this.styleLoaderChild(n):this.hideLoaderChild(n);this.syncDefaultSpinner(e.length>0)}styleLoaderChild(t){VI.has(t)||VI.set(t,t.style.cssText);let n=t;n.style.cssText=VI.get(t)??``,n.style.position=`absolute`,n.style.left=`50%`,n.style.top=`50%`,n.style.zIndex=String(e.spinnerZIndex)}hideLoaderChild(e){VI.has(e)||VI.set(e,e.style.cssText);let t=e;t.style.cssText=VI.get(e)??``,t.style.display=`none`}syncDefaultSpinner(e){this.spinnerWrap&&(this.spinnerWrap.style.display=e?`none`:``)}setOverlay(e){if(e!==this.overlayShown)if(this.overlayShown=e,e){if((!this.spinnerWrap||!this.backdrop)&&this.createOverlay(),this.syncLoaderChildren(),!this.hostPositionTouched){var t;let e=(t=this.ownerDocument.defaultView)==null?void 0:t.getComputedStyle(this).position;(!e||e===`static`)&&(VI.set(this,this.style.cssText),this.style.position=`relative`,this.hostPositionTouched=!0)}this.backdrop&&(this.backdrop.style.display=``),this.spinnerWrap&&(this.spinnerWrap.style.display=this.loaderChildren().length?`none`:``)}else this.syncLoaderChildren(),this.backdrop&&(this.backdrop.style.display=`none`),this.spinnerWrap&&(this.spinnerWrap.style.display=`none`),this.hostPositionTouched&&(this.style.cssText=VI.get(this)??``,this.hostPositionTouched=!1)}createOverlay(){let t=this.ownerDocument.createElement(`div`);t.className=`position-absolute top-0 start-0 end-0 bottom-0 bg-body`,t.style.zIndex=String(e.backdropZIndex),t.style.opacity=String(e.backdropOpacity);let n=this.ownerDocument.createElement(`div`);n.className=`position-absolute start-50 top-50`,n.style.zIndex=String(e.spinnerZIndex);let r=this.ownerDocument.createElement(`div`);r.className=`spinner-border text-primary flex-shrink-0`,r.setAttribute(`role`,`status`),n.appendChild(r),this.appendChild(t),this.appendChild(n),this.backdrop=t,this.spinnerWrap=n}}return n}function UI(e){let t=typeof HTMLElement>`u`?class{}:HTMLElement;class n extends t{constructor(...e){super(...e),Z(this,`instance`,void 0),Z(this,`stopWatch`,void 0),Z(this,`isVisible`,void 0),Z(this,`connectedOnce`,!1),Z(this,`attempted`,!1),Z(this,`capturedDisplay`,``)}connectedCallback(){if(this.connectedOnce||(this.connectedOnce=!0,this.capturedDisplay=this.style.display,this.apply(!1)),this.instance){this.startEffect();return}this.attempted||(this.attempted=!0,hm(this,e,t=>{var n;if(this.instance=t,t.registerComponent(e.tag),(n=e.dataTypes)!=null&&n.length){var r;(r=t.registerRequiredDataTypes)==null||r.call(t,e.dataTypes)}this.startEffect()}))}disconnectedCallback(){this.stopWatching(),jn(()=>{this.isConnected||(this.stopWatching(),this.style.display=this.capturedDisplay,this.instance=void 0,this.attempted=!1,this.connectedOnce=!1,this.isVisible=void 0)})}startEffect(){var t;(t=this.stopWatch)==null||t.call(this),this.stopWatch=Jn(()=>{this.apply(this.instance?e.gate(this.instance):!1)})}stopWatching(){var e;(e=this.stopWatch)==null||e.call(this),this.stopWatch=void 0}apply(e){e!==this.isVisible&&(this.isVisible=e,e?this.style.display=this.capturedDisplay:(this.capturedDisplay=this.style.display,this.style.display=`none`))}}return n}function WI(e){if(e.elements.some(e=>e.kind===`view`&&e.subView!==void 0)&&!e.subViewOf)throw Error("defineNativeElements: a view entry carries `subView` but the spec has no `subViewOf` - the sub-view gates could never open.");return e.elements.map(t=>{switch(t.kind){case`instance`:return{name:t.name,ctor:BI({idPrefix:e.idPrefix,getInstanceById:e.getInstanceById})};case`view`:return{name:t.name,ctor:UI({tag:t.name,instanceTag:e.instanceTag,getInstanceById:e.getInstanceById,dataTypes:e.viewDataTypes,gate:n=>e.isReady(n)&&n.router.routeData.view===t.view&&(t.subView===void 0||e.subViewOf(n.router.routeData)===t.subView)})};case`gate`:return{name:t.name,ctor:UI({tag:t.name,instanceTag:e.instanceTag,getInstanceById:e.getInstanceById,gate:t.gate})};case`loader`:return{name:t.name,ctor:HI({tag:t.name,instanceTag:e.instanceTag,getInstanceById:e.getInstanceById,spinnerZIndex:t.spinnerZIndex,backdropZIndex:t.backdropZIndex,backdropOpacity:t.backdropOpacity,isReady:e.isReady,isLoading:e=>!!e.store.data.isLoadingData,hasContent:e.hasContent})}}})}var GI=WI({idPrefix:`pisCatalogsInstance_`,instanceTag:`pis-catalogs-instance`,getInstanceById:e=>Pf.Catalogs.getInstance(e),isReady:e=>!!(e.store.data.isInitialized&&e.store.data.translationsReady),hasContent:e=>{var t,n;return!!((t=e.store.data.catalogs)!=null&&(t=t.items)!=null&&t.length)||!!((n=e.store.data.products)!=null&&(n=n.items)!=null&&n.length)},subViewOf:e=>e.products.subView,viewDataTypes:[Ud.Products],elements:[{kind:`instance`,name:`pis-catalogs-instance`},{kind:`view`,name:`pis-catalogs-search-router-view`,view:`catalogs`},{kind:`view`,name:`pis-catalogs-products-search-router-view`,view:`products`},{kind:`view`,name:`pis-catalogs-aliases-search-router-view`,view:`aliases`},{kind:`view`,name:`pis-catalogs-products-search-table-router-view`,view:`products`,subView:`table`},{kind:`view`,name:`pis-catalogs-products-search-list-router-view`,view:`products`,subView:`list`},{kind:`view`,name:`pis-catalogs-products-search-grid-router-view`,view:`products`,subView:`grid`},{kind:`loader`,name:`pis-catalogs-loading-indicator`,spinnerZIndex:2e3,backdropZIndex:1900,backdropOpacity:.2}]});function KI(){return typeof window<`u`&&typeof document<`u`&&typeof customElements<`u`}var qI={configureApp:e=>{e.directive(`safe-html`,Ew)},shadowRoot:!1};function JI(e,t){if(KI()){for(let{name:e,ctor:n}of t??[])e&&!customElements.get(e)&&customElements.define(e,n);e.forEach(e=>{let t=e.name;if(t&&!customElements.get(t)){let n=ds(e,qI);customElements.define(t,n)}})}}function YI(){If(new Nf),JI(LI,GI),Rf()}var XI=class{constructor(){Z(this,`appSettings`,{appCode:``,langCode:`en`}),Z(this,`styles`,[]),Z(this,`components`,{browser:{common:{toolbar:{applyVisible:!0,cancelVisible:!0,favoritesVisible:!0,productLineTreeVisible:!0,visible:!0,expandFavoritesVisible:!1}},form:{visible:!0,useAutocomplete:!0},tabs:{visible:!0,items:[{id:`favorites`,type:Kl.FAVORITES,itemsExpandable:!1,countsVisible:!0},{id:`offering`,type:Kl.OFFERING,countsVisible:!0},{id:`productLine`,type:Kl.PRODUCT_LINE,countsVisible:!0}]},tree:{visible:!0,scrollHeight:600,mobileScrollHeight:300},selection:{visible:!0,scrollHeight:600,mobileScrollHeight:300},note:{visible:!0},actions:{visible:!0,applyVisible:!0,cancelVisible:!0}}}),Z(this,`allowMobileView`,!0),Z(this,`cacheTranslations`,!0)}},ZI=class{constructor(e){Z(this,`instance`,void 0),Z(this,`select`,e=>{if(!this.data||!(e!=null&&e.length))return;let t=[];e.forEach(e=>{if(e&&e.cid&&!this.isSelected(e)){var n;(n=this.data)==null||n.set(e.cid+`~`+e.tree,e),t.push(e)}}),t.length&&(this.instance.eventBus.emit(`favorites-changed`,{added:t,removed:[],selected:this.selectedItems}),this.trackSelection(t,[]))}),Z(this,`deselect`,e=>{if(!this.data||!(e!=null&&e.length))return;let t=[];e.forEach(e=>{if(e&&e.cid&&this.isSelected(e)){var n;(n=this.data)==null||n.delete(e.cid+`~`+e.tree),t.push(e)}}),t.length&&(this.instance.eventBus.emit(`favorites-changed`,{added:[],removed:t,selected:this.selectedItems}),this.trackSelection([],t))}),Z(this,`toggle`,e=>{this.isSelected(e)?this.deselect([e]):this.select([e])}),Z(this,`clear`,()=>{var e;if(!this.data)return;let t=this.selectedItems;(e=this.data)==null||e.clear(),t.length&&(this.instance.eventBus.emit(`favorites-changed`,{added:[],removed:t,selected:this.selectedItems}),this.trackSelection([],t))}),Z(this,`isSelected`,e=>this.data?this.data.has(e.cid+`~`+e.tree):!1),this.instance=e,e.store.data.favoriteItems||(e.store.data.favoriteItems=new Map)}trackSelection(e,t){Mc(this.instance,{kind:`selection`,action:`favorites-changed`,trigger:`ui`,args:{added:e.length,removed:t.length,selected:this.selectedItems.length}})}get data(){return this.instance.store.data.favoriteItems}get selectedItems(){return this.data?Array.from(this.data.values()):[]}get count(){return this.selectedItems.length}},QI=class{constructor(e){Z(this,`instance`,void 0),Z(this,`select`,e=>{if(!this.data||!(e!=null&&e.length))return;let t=[];e.forEach(e=>{if(e&&e.cid&&!this.isSelected(e)&&e.selectable){var n;(n=this.data)==null||n.set(e.cid+`~`+e.tree,e),t.push(e)}}),t.length&&(this.instance.eventBus.emit(`selection-changed`,{added:t,removed:[],selected:this.selectedItems}),this.trackSelection(t,[]))}),Z(this,`deselect`,e=>{if(!this.data||!(e!=null&&e.length))return;let t=[];e.forEach(e=>{if(e&&e.cid&&this.isSelected(e)){var n;(n=this.data)==null||n.delete(e.cid+`~`+e.tree),t.push(e)}}),t.length&&(this.instance.eventBus.emit(`selection-changed`,{added:[],removed:t,selected:this.selectedItems}),this.trackSelection([],t))}),Z(this,`toggle`,e=>{e.selectable&&(this.isSelected(e)?this.deselect([e]):this.select([e]))}),Z(this,`clear`,()=>{var e;if(!this.data)return;let t=this.selectedItems;(e=this.data)==null||e.clear(),t.length&&(this.instance.eventBus.emit(`selection-changed`,{added:[],removed:t,selected:this.selectedItems}),this.trackSelection([],t))}),Z(this,`isSelected`,e=>this.data?this.data.has(e.cid+`~`+e.tree):!1),this.instance=e,e.store.data.selectedItems||(e.store.data.selectedItems=new Map)}trackSelection(e,t){Mc(this.instance,{kind:`selection`,action:`selection-changed`,trigger:`ui`,args:{added:e.length,removed:t.length,selected:this.selectedItems.length}})}get data(){return this.instance.store.data.selectedItems}get selectedItems(){return this.data?Array.from(this.data.values()):[]}get count(){return this.selectedItems.length}},$I=e=>e.id??e.type,eL=(e,t)=>t?e.find(e=>$I(e)===t):void 0;function tL(e){var t;let n=(t=e.components)==null||(t=t.browser)==null||(t=t.tabs)==null?void 0:t.items;if(Array.isArray(n)&&n.length===0)throw Error(`Invalid classifications tabs: components.browser.tabs.items must contain at least one tab. Omit the option or pass null to use the default tabs.`)}function nL(e){var t,n;let r=(t=e.components)==null?void 0:t.browser;if(!r)return;let i=new XI().components.browser.tabs;r.tabs==null?r.tabs=Ic(i):r.tabs.items??(r.tabs.items=Ic(i.items));let a=r.tabs;if(!((n=a.items)!=null&&n.length))throw Error(`Invalid classifications tabs: components.browser.tabs.items must contain at least one tab. Omit the option or pass null to use the default tabs.`);let o=a.items,s=new Set;a.items=o.map(e=>{if(!e||typeof e!=`object`)throw Error(`Invalid classifications tabs: every items[] entry must be a TabOption object.`);if(`selected`in e)throw Error(`Invalid classifications tabs: TabOption.selected was removed - selection is route-driven. Pass the initial tab through init(options, { tabId }) or setRoute({ tabId }) instead.`);let t=e.id??e.type;if(typeof t!=`string`||t.length===0)throw Error(`Invalid classifications tabs: tab id must be a non-empty string (type "${e.type}").`);if(s.has(t))throw Error(`Invalid classifications tabs: duplicate tab id "${t}". Assign a unique TabOption.id to every tab that shares a type.`);return s.add(t),{...e,id:t}})}var rL=new class{toLegacyEventArgs(e,t){let n={type:e},r=t.selection.selectedItems;if(r!=null&&r.length){let e=[];r.forEach(t=>{let n=t;e.push(this.mapNodesToLegacy(n))}),n.nodes=e}let i=t.favorites.selectedItems;if(i!=null&&i.length){let e=[];i.forEach(t=>{let n=t;e.push(this.mapNodesToLegacy(n))}),n.favorites=e}return t.store.data.invalidFavoriteItems&&(n.invalidFavorites=t.store.data.invalidFavoriteItems),t.store.data.invalidSelectedItems&&(n.invalidNodes=t.store.data.invalidSelectedItems),Ic(n)}mapNodesToLegacy(e){return{cid:e.cid,englishDescription:e.enName,languageSpecificDescription:e.name,treeCode:e.tree==Gl.OFFERING?`OFFERING_TREE`:`PL_TREE`,reference:e.reference?this.mapNodeReferenceToLegacy(e.reference):null}}mapNodeReferenceToLegacy(e){return{classificationCode:e.classificationCode,cid:e.cid,refCid:e.refCid,refPath:e.refPath}}applyLegacyOptions(e,t){let n=[];e.parameters.favoriteView&&n.push({type:Kl.FAVORITES,itemsExpandable:e.parameters.favoriteItemsExpandable,onlyLeafNodesSelectable:e.parameters.onlyLeafNodesSelectable,countsVisible:!0}),n.push({type:Kl.OFFERING,onlyLeafNodesSelectable:e.parameters.onlyLeafNodesSelectable,countsVisible:!0}),e.parameters.productLineHierarchy&&n.push({type:Kl.PRODUCT_LINE,onlyLeafNodesSelectable:e.parameters.onlyLeafNodesSelectable,countsVisible:!0});let r={accessToken:e.accessToken,selectedNodes:this.parseCids(e.parameters.selectedNodes),favoriteNodes:this.parseCids(e.parameters.favoriteNodes),appSettings:{appCode:e.appCode,countryCode:this.getIsoCountryCode(e.countryCode),langCode:this.getIsoLangCode(e.langCode),filters:{applicationUse:{disable:e.parameters.disableAppUseCheck,exceptionCids:e.parameters.disableAppUseCheckException},lifeCyclePhases:e.parameters.lifeCyclePhases,lifeCyclePhaseMode:e.parameters.lifeCyclePhaseMode},productLinePeriod:e.parameters.productLinePeriodCode},components:{browser:{common:{toolbar:{visible:!0,expandFavoritesVisible:e.parameters.expandFavoritesVisible}},tabs:{items:n,visible:!0},tree:{visible:!0,scrollHeight:e.parameters.scrollHeight,mobileScrollHeight:e.parameters.mobileScrollHeight},selection:{visible:!0,scrollHeight:e.parameters.scrollHeight,mobileScrollHeight:e.parameters.mobileScrollHeight}}}};t&&(zc(t,r),r=t);let i={tabId:$I(n[0])};return{options:r,routeData:i}}parseCids(e){let t=[];return e.forEach(e=>{if(typeof e==`string`)if(e.indexOf(`|`)>-1){let n=e.split(`|`);t.push({cid:n[0],type:this.parseTreeType(n[1])})}else t.push({cid:e});else t.push({cid:e.cid,type:this.parseTreeType(e.treeCode)})}),t}parseTreeType(e){if(e===`OFFERING_TREE`)return Gl.OFFERING;if(e===`PL_TREE`)return Gl.PRODUCT_LINE}getIsoCountryCode(e){if(e)return e.includes(`_`)?e.split(`_`)[1]:e}getIsoLangCode(e){if(e)return e.includes(`_`)?e.split(`_`)[0]:e}},iL=class extends wc{},aL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-filter-search`),Z(this,`execute`,async e=>e.router.setRoute({searchText:this.args.searchText}))}},oL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-get-autocomplete`),Z(this,`execute`,async e=>{var t;return await((t=e.httpService)==null?void 0:t.autocomplete(this.args.searchText))})}},sL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-node-expand`),Z(this,`execute`,async e=>{var t;if(this.args.item.leaf)return Promise.resolve(this.args.item);if((t=this.args.item.children)!=null&&t.length)return this.args.item._isExpanded=!0,Promise.resolve(this.args.item);if(e.httpService){this.args.item._isLoading=!0;try{await e.httpService.loadChildren(this.args.item),this.args.item._isExpanded=!0}catch{}finally{this.args.item._isLoading=!1}}return Promise.resolve(this.args.item)})}},cL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-node-collapse`),Z(this,`execute`,async()=>(this.args.item._isExpanded=!1,Promise.resolve(this.args.item)))}},lL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-collapse-all`),Z(this,`setExpandedFalse`,e=>{e==null||e.forEach(e=>{var t;(t=e.children)!=null&&t.length&&(e._isExpanded=!1,this.setExpandedFalse(e.children))})}),Z(this,`execute`,async e=>{var t;let n=((t=e.store.data)==null||(t=t.classifications)==null?void 0:t.items)??[];return this.setExpandedFalse(n),Promise.resolve(this.args)})}},uL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-expand-all`),Z(this,`setExpandedTrue`,e=>{e==null||e.forEach(e=>{var t;(t=e.children)!=null&&t.length&&(e._isExpanded=!0,this.setExpandedTrue(e.children))})}),Z(this,`execute`,async e=>{var t;let n=((t=e.store.data)==null||(t=t.classifications)==null?void 0:t.items)??[];return this.setExpandedTrue(n),Promise.resolve(this.args)})}},dL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-favorites-show`),Z(this,`execute`,async e=>{var t,n;let r=(t=e.store.options.components)==null||(t=t.browser)==null||(t=t.tabs)==null||(t=t.items)==null?void 0:t.find(e=>e.type===`Favorites`);return(n=e.router)==null?void 0:n.setRoute({tabId:r?$I(r):void 0})})}},fL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-show-all`),Z(this,`execute`,async e=>{var t;return(t=e.router)==null?void 0:t.setRoute({tabId:void 0})})}},pL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-set-tab`),Z(this,`execute`,async e=>{var t;return await((t=e.router)==null?void 0:t.setRoute({tabId:this.args.tabId}))})}},mL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-item-select`),Z(this,`execute`,async e=>(e.selection.select([this.args.item]),Promise.resolve(this.args)))}},hL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-item-deselect`),Z(this,`execute`,async e=>(e.selection.deselect([this.args.item]),Promise.resolve(this.args)))}},gL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-favorite-select`),Z(this,`execute`,async e=>(e.favorites.select([this.args.item]),Promise.resolve(this.args)))}},_L=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-favorite-deselect`),Z(this,`execute`,async e=>(e.favorites.deselect([this.args.item]),Promise.resolve(this.args)))}},vL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-selection-clear`),Z(this,`execute`,async e=>(e.selection.clear(),Promise.resolve(this.args)))}},yL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-apply`),Z(this,`execute`,async e=>{let t=rL.toLegacyEventArgs(`Apply`,e);return e.eventBus.emit(`classification-selector-closed`,t),Promise.resolve(this.args)})}},bL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-cancel`),Z(this,`execute`,async e=>{let t=rL.toLegacyEventArgs(`Cancel`,e);return e.eventBus.emit(`classification-selector-closed`,t),Promise.resolve(this.args)})}},xL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-notification-show`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>{let t=0,n=this.args.dismissAfter;e.store.notifications.length&&(e.store.notifications=[],t=1e3),!n&&n!==0&&this.args.type!==`danger`&&(n=6e3,e.store.notifications=[]),n&&n!==0&&setTimeout(()=>{let t=e.store.notifications.indexOf(this.args);t!==-1&&e.store.notifications.splice(t,1)},this.args.dismissAfter),setTimeout(()=>e.store.notifications.push(this.args),t)})}},SL=class extends iL{constructor(...e){super(...e),Z(this,`name`,`classifications-notification-hide`),Z(this,`excludeFromUserActions`,!0),Z(this,`execute`,async e=>{let t=e.store.notifications.indexOf(this.args);t!==-1&&e.store.notifications.splice(t,1)})}},CL=class extends Gc{constructor(e){super(e,wL,`classifications`)}},wL={"classifications-filter-search":aL,"classifications-get-autocomplete":oL,"classifications-node-expand":sL,"classifications-node-collapse":cL,"classifications-collapse-all":lL,"classifications-expand-all":uL,"classifications-favorites-show":dL,"classifications-show-all":fL,"classifications-set-tab":pL,"classifications-item-select":mL,"classifications-item-deselect":hL,"classifications-favorite-select":gL,"classifications-favorite-deselect":_L,"classifications-selection-clear":vL,"classifications-apply":yL,"classifications-cancel":bL,"classifications-notification-show":xL,"classifications-notification-hide":SL},TL={Classifications:`Classifications`,Translations:`Translations`},EL={[TL.Classifications]:(e,t)=>{e.classifications=t},[TL.Translations]:(e,t)=>{Gd.log(`Setting store data not handled`,{type:TL.Translations,data:t})}},DL=class extends Wd{constructor(e){super(e)}dataInterceptor(){var e;return(e=this.instance.store)==null?void 0:e.options.dataInterceptor}dispatchLoadEvent(e){this.setStoreData(e)}setStoreData({type:e,data:t}){if(!this.instance.store)return;let n=EL[e];n(this.instance.store.data,t)}},OL=`pis-classifications-translations`,kL=class extends af{constructor(e,t,n){super(),Z(this,`instance`,void 0),Z(this,`instanceType`,`Classifications`),Z(this,`storeService`,void 0),Z(this,`client`,void 0),Z(this,`setExpanded`,e=>{e==null||e.forEach(e=>{var t;(t=e.children)!=null&&t.length&&(e._isExpanded=!0,this.setExpanded(e.children))})}),this.instance=e,this.client=nf(e,t,n),this.storeService=new DL(e)}getActiveTab(e){var t,n;return eL(((t=this.instance.store.options.components)==null||(t=t.browser)==null||(t=t.tabs)==null?void 0:t.items)??[],e??((n=this.instance.router)==null?void 0:n.routeData.tabId))}async load(e){if(!this.instance.router)return;let t=e||this.instance.router.routeData;return await this.search(t)}async search(e){let{action:t,source:n,trigger:r=`ui`}=Ac(this.instance)??{};this.instance.store.data.isLoadingData=!0;let i=this.getActiveTab(e.tabId),a=Date.now(),o=i=>Mc(this.instance,{kind:`search`,action:`search`,trigger:r,origin:t??`route`,...n?{source:n}:{},args:{searchText:e.searchText??null,tabId:e.tabId??null},outcome:i});try{var s,c,l;let t=await kl.classificationsBrowserSearch({classificationsBrowserSearchQuery:{appSettings:(s=this.instance.store)==null?void 0:s.options.appSettings,search:{treeView:i==null?void 0:i.type,searchText:e.searchText??void 0,selectedCids:((c=this.instance.selection)==null||(c=c.selectedItems)==null?void 0:c.map(e=>e.cid))||[],favoriteCids:((l=this.instance.favorites)==null||(l=l.selectedItems)==null?void 0:l.map(e=>e.cid))||[],favoriteItemsExpandable:i==null?void 0:i.itemsExpandable,onlyLeafNodesSelectable:i==null?void 0:i.onlyLeafNodesSelectable,categoryInclusionCriteria:i==null?void 0:i.categoryInclusionCriteria,categoryExclusionCriteria:i==null?void 0:i.categoryExclusionCriteria}}},{client:this.client});this.instance.eventBus.emit(`search-loaded`,t),o(Nc(void 0,t.items,Date.now()-a)),t&&(this.setExpanded(t.items),this.storeService.setData(TL.Classifications,t)),this.instance.store.data.isLoadingData=!1,this.instance.eventBus.emit(`search-changed`)}catch(e){throw this.instance.store.data.isLoadingData=!1,o({status:`error`,durationMs:Date.now()-a}),e}}async autocomplete(e){let{action:t,source:n,trigger:r=`ui`}=Ac(this.instance)??{},i=this.instance.router.routeData,a=this.getActiveTab(i.tabId),o=Date.now(),s;try{var c,l,u;s=await kl.classificationsBrowserAutocomplete({classificationsBrowserAutocompleteQuery:{appSettings:(c=this.instance.store)==null?void 0:c.options.appSettings,search:{searchText:e,treeView:a==null?void 0:a.type,selectedCids:((l=this.instance.selection)==null||(l=l.selectedItems)==null?void 0:l.map(e=>e.cid))||[],favoriteCids:((u=this.instance.favorites)==null||(u=u.selectedItems)==null?void 0:u.map(e=>e.cid))||[],favoriteItemsExpandable:a==null?void 0:a.itemsExpandable,onlyLeafNodesSelectable:a==null?void 0:a.onlyLeafNodesSelectable,categoryInclusionCriteria:a==null?void 0:a.categoryInclusionCriteria,categoryExclusionCriteria:a==null?void 0:a.categoryExclusionCriteria}}},{client:this.client})}catch(i){throw Mc(this.instance,{kind:`autocomplete`,action:`autocomplete`,trigger:r,...t?{origin:t}:{},...n?{source:n}:{},args:{searchText:e},outcome:{status:`error`,durationMs:Date.now()-o}}),i}return Mc(this.instance,{kind:`autocomplete`,action:`autocomplete`,trigger:r,...t?{origin:t}:{},...n?{source:n}:{},args:{searchText:e},outcome:Nc(s.totalCount,s.matches,Date.now()-o)}),s}async loadChildren(e){var t,n,r;let i=this.instance.router.routeData,a=this.getActiveTab(i.tabId),o=await kl.classificationsBrowserChildren({classificationsBrowserChildrenQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{treeType:e.tree,cid:e.cid,treeView:a==null?void 0:a.type,selectedCids:((n=this.instance.selection)==null||(n=n.selectedItems)==null?void 0:n.map(e=>e.cid))||[],favoriteCids:((r=this.instance.favorites)==null||(r=r.selectedItems)==null?void 0:r.map(e=>e.cid))||[],favoriteItemsExpandable:a==null?void 0:a.itemsExpandable,onlyLeafNodesSelectable:a==null?void 0:a.onlyLeafNodesSelectable,categoryInclusionCriteria:a==null?void 0:a.categoryInclusionCriteria,categoryExclusionCriteria:a==null?void 0:a.categoryExclusionCriteria}}},{client:this.client});return o!=null&&o.items&&(e.children=o.items,this.storeService.setData(TL.Classifications,this.instance.store.data.classifications)),o.items}async validate(e){var t;return await kl.classificationsBrowserValidate({classificationsBrowserValidateQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{nodes:e}}},{client:this.client})}async loadTranslations(){var e;let t=await this.fetchTranslations(OL),n=(e=this.instance.store)==null?void 0:e.options.dataInterceptor,r={type:TL.Translations,data:Ut({items:t}),instance:this.instance};if(n){var i;let e=await n(r);return e.type===`Translations`?(i=e.data)==null?void 0:i.items:t}return t}},AL={tabId:`favorites`},jL=class{constructor(e){Z(this,`instance`,void 0),Z(this,`routeData`,Ut(Ic(AL))),Z(this,`history`,[]),this.instance=e}configuredTabs(){var e;return((e=this.instance.store.options)==null||(e=e.components)==null||(e=e.browser)==null||(e=e.tabs)==null?void 0:e.items)??[]}resolveDefaultRoute(){let e=this.configuredTabs();return e.length?{tabId:$I(e.filter(e=>e.visible!==!1)[0]??e[0])}:Ic(AL)}reconcileTabs(e){let t=this.configuredTabs();if(!t.length){e.tabId=this.resolveDefaultRoute().tabId;return}if(eL(t,e.tabId))return;let n=this.resolveDefaultRoute();e.tabId,e.tabId=n.tabId}async setRoute(e,t=!1){let n=Ic(this.routeData);if(e&&Rc(n,e),this.history.length===0&&(e==null?void 0:e.tabId)==null&&Rc(n,{tabId:null}),this.reconcileTabs(n),uf(n,this.resolveDefaultRoute()),!(this.history.length>0&&Bc(n,Ic(this.routeData))))return this.instance.store.data.isInitialized&&this.instance.httpService?(t||await this.instance.httpService.load(n),this.commitRoute(n),Promise.resolve()):(this.commitRoute(n),Promise.resolve())}async reload(){var e;await((e=this.instance.httpService)==null?void 0:e.load(this.routeData))}commitRoute(e){this.history.push({...e}),Rc(this.routeData,e),this.instance.eventBus.emit(`route-changed`,Ic(this.routeData))}async back(e=1){let t=this.history.length-e-1,n=this.history[t];n&&this.history.splice(t),this.setRoute(n??this.resolveDefaultRoute())}},ML=class{constructor(e,t){Z(this,`id`,void 0),Z(this,`accessor`,void 0),Z(this,`instanceType`,`Classifications`),Z(this,`props`,{}),Z(this,`httpService`,void 0),Z(this,`store`,Ut({notifications:[],data:{isInitialized:!1,actions:{current:null,data:null}},options:{isInitialized:!1}})),Z(this,`router`,new jL(this)),Z(this,`translations`,new yf(this)),Z(this,`commandExecutor`,new CL(this)),Z(this,`logger`,Gd),Z(this,`registeredComponents`,Ut(new Set)),Z(this,`dataTypesRequired`,Ut(new Set)),Z(this,`eventBus`,Vs()),Z(this,`eventBusExt`,_f(this.eventBus)),Z(this,`selection`,new QI(this)),Z(this,`favorites`,new ZI(this)),this.id=e,this.accessor=t}isInitialized(){return this.store.data.isInitialized}async reload(){await this.translations.load(),await this.router.reload()}setRoute(e){this.router.setRoute(e)}async init(e,t){if(this.store.data.isInitialized)throw Error(`Instance "${this.id}" is already initialized`);Af(`classifications`,e),jf(e),tL(e);let n=xf(e==null?void 0:e.baseUrl),r=this.store.options.isInitialized?this.store.options:new XI;hf(r,e),nL(r),this.store.options=r,this.store.options.isInitialized=!0,this.httpService=new kL(this,n,r.accessToken),this.store.data.isInitialized=!0;try{return await this.translations.load(),await this.validateParameters(),this.router.setRoute(t),Promise.resolve()}catch(e){this.store.data.isInitialized=!1;let t=Hc(r.errorInterceptor,{type:`InitError`,message:`PIS initialization error.`,isHandled:!1});return console.error(`[PIS] initialization error`,t,e),Promise.reject(Error(`PIS initialization error`,{cause:e}))}}update(e,t){Af(`classifications`,e),jf(e),tL(e);let n=this.store.options.isInitialized?this.store.options:new XI;hf(n,e),nL(n),this.store.options=n,this.store.options.isInitialized=!0,(t||this.router.history.length>0)&&this.router.setRoute(t??{})}on(e,t){this.eventBusExt.on(e,t)}onReady(e){let t=I(()=>this.store.data,({isInitialized:n})=>{n&&(e(),t())},{deep:!0})}off(e,t){e?this.eventBusExt.off(e,t):this.eventBusExt.all.clear()}registerComponent(e){this.registeredComponents.add(e)}registerRequiredDataTypes(e){e.forEach(e=>this.dataTypesRequired.add(e))}getRegisteredSearchDataTypes(){return[]}destroy(){return this.accessor.destroyInstance(this.id)}execute(e,t){return this.commandExecutor.execute(e,t)}executeCommand(e,...t){return this.commandExecutor.executeCommand(e,...t)}trackUserAction(e){jc(this,e)}getDefaultOptions(){let e=gf(new XI);return nL(e),e}getDefaultRouteData(){return this.router.resolveDefaultRoute()}getOptions(){return this.store.options}getRouteData(){return Ic(this.router.routeData)}applyLegacyOptions(e,t){return rL.applyLegacyOptions(e,t)}async apply(){try{await this.execute(new yL,`api`)}catch{}}async cancel(){try{await this.execute(new bL,`api`)}catch{}}async validateParameters(){if(this.httpService&&(this.store.options.selectedNodes||this.store.options.favoriteNodes)){let n=[...this.store.options.selectedNodes??[],...this.store.options.favoriteNodes??[]];if(n.length){var e,t;let r=await this.httpService.validate(n),i=[],a=[],o=[],s=[];(e=this.store.options.selectedNodes)!=null&&e.length&&this.store.options.selectedNodes.forEach(e=>{if(e.type){var t;let n=(t=r.validNodes)==null?void 0:t.find(t=>t.cid===e.cid&&t.tree===e.type);n?i.push(n):a.push(e)}else{var n,o;let t,l;if((((n=this.store.options.components)==null||(n=n.browser)==null||(n=n.tabs)==null?void 0:n.items)??[]).some(e=>e.type===Kl.OFFERING)){var s;t=(s=r.validNodes)==null?void 0:s.find(t=>t.cid===e.cid&&t.tree===Gl.OFFERING),t&&i.push(t)}if((((o=this.store.options.components)==null||(o=o.browser)==null||(o=o.tabs)==null?void 0:o.items)??[]).some(e=>e.type===Kl.PRODUCT_LINE)){var c;l=(c=r.validNodes)==null?void 0:c.find(t=>t.cid===e.cid&&t.tree===Gl.PRODUCT_LINE),l&&i.push(l)}t===void 0&&l===void 0&&a.push(e)}}),(t=this.store.options.favoriteNodes)!=null&&t.length&&this.store.options.favoriteNodes.forEach(e=>{if(e.type){var t;let n=(t=r.validNodes)==null?void 0:t.find(t=>t.cid===e.cid&&t.tree===e.type);n?o.push(n):s.push(e)}else{var n,i;let t,l;if((((n=this.store.options.components)==null||(n=n.browser)==null||(n=n.tabs)==null?void 0:n.items)??[]).some(e=>e.type===Kl.OFFERING)){var a;t=(a=r.validNodes)==null?void 0:a.find(t=>t.cid===e.cid&&t.tree===Gl.OFFERING),t&&o.push(t)}if((((i=this.store.options.components)==null||(i=i.browser)==null||(i=i.tabs)==null?void 0:i.items)??[]).some(e=>e.type===Kl.PRODUCT_LINE)){var c;l=(c=r.validNodes)==null?void 0:c.find(t=>t.cid===e.cid&&t.tree===Gl.PRODUCT_LINE),l&&o.push(l)}t===void 0&&l===void 0&&s.push(e)}}),i.length&&this.selection.select(i),o.length&&this.favorites.select(o),a.length&&(this.eventBus.emit(`selection-validated`,{invalid:Ic(a),valid:Ic(i)}),this.store.data.invalidSelectedItems=a),s.length&&(this.eventBus.emit(`favorites-validated`,{invalid:Ic(s),valid:Ic(o)}),this.store.data.invalidFavoriteItems=s)}}}},NL=class{constructor(){Z(this,`instances`,Ut(new Map))}destroyInstance(e){try{var t;(t=this.instances.get(e))==null||t.off()}catch{}this.instances.delete(e)}getInstance(e){let t=this.instances.size;if(e!==void 0){if(this.instances.has(e))return this.instances.get(e);{let t=new ML(e,this);return this.instances.set(e,t),t}}if(t===1)return this.instances.values().next().value;if(t>1)throw Error(`[PIS Classifications] Cannot pick default instance if more than one exists`)}setAccessTokenInAllInstances(e){this.instances.forEach(t=>{t.getOptions().accessToken=e})}},PL=_m({getInstance:e=>Pf.Classifications.getInstance(e),instanceTag:`pis-classifications-instance`,debounceResize:!1});function FL(e,t,n){return PL(e,t,n)}var IL=L({name:`pis-classifications-common-notifications`,components:{Notifications:DT},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s}=FL(t,e.instanceId);return{root:t,store:o,isReady:r,instance:a,routeData:s,componentName:n,isWebComponent:i}}}),LL={ref:`root`,class:`pis-component`};function RL(e,t,n,r,i,a){let o=R(`Notifications`);return H(),U(`div`,LL,[e.isReady&&e.store&&e.instance?(H(),W(o,{key:0,instance:e.instance},null,8,[`instance`])):J(``,!0)],512)}var zL=Q(IL,[[`render`,RL]]),BL=L({name:`pis-classifications-browser-actions`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,t:c}=FL(t,e.instanceId,[TL.Classifications]);return{root:t,store:o,isReady:r,instance:a,routeData:s,componentName:n,isWebComponent:i,componentOptions:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null?void 0:e.actions)??{}}),cancel:async()=>{try{var e;await((e=a.value)==null?void 0:e.execute(new bL().from(n)))}catch{}},apply:async()=>{try{var e;await((e=a.value)==null?void 0:e.execute(new yL().from(n)))}catch{}},t:c}}});function VL(e,t,n,r,i,a){return F((H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName]),style:{"z-index":`1`}},[e.isReady?(H(),U(V,{key:0},[G(`button`,{class:`btn btn-outline-primary me-2`,onClick:t[0]||(t[0]=(...t)=>e.cancel&&e.cancel(...t))},j(e.t(`Cancel`)),1),G(`button`,{class:`btn btn-primary`,onClick:t[1]||(t[1]=(...t)=>e.apply&&e.apply(...t))},j(e.t(`Apply`)),1)],64)):J(``,!0)],2)),[[Mo,e.componentOptions.visible]])}var HL=Q(BL,[[`render`,VL]]),UL=L({name:`pis-classifications-browser-note`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,t:c}=FL(t,e.instanceId,[TL.Classifications]);return{root:t,store:o,isReady:r,instance:a,routeData:s,componentName:n,isWebComponent:i,componentOptions:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null?void 0:e.note)??{}}),t:c}}}),WL={key:0,class:`mb-3 card px-3 py-1 bg-light rounded-1`},GL={class:`small`},KL={class:`d-inline pe-1`};function qL(e,t,n,r,i,a){let o=Hr(`safe-html`);return F((H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName]),style:{"z-index":`1`}},[e.isReady?(H(),U(`div`,WL,[G(`span`,GL,[G(`strong`,KL,j(e.t(`NoteTitle`)),1),F(G(`span`,null,null,512),[[o,e.t(`NoteBody`)]])])])):J(``,!0)],2)),[[Mo,e.componentOptions.visible]])}var JL=Q(UL,[[`render`,qL]]),YL={value:Hl.CATALOG_CODE_AND_DESCRIPTION,translate:`SearchByCodeAndDescription`},XL={value:Hl.CREATED_BY,translate:`SearchByCreatedBy`},ZL=L({name:`pis-classifications-browser-search-form`,components:{Btn:Iy,Spinner:My,Dropdown:pb,Clickable:wm,Highlighter:sb,FormInputClearable:Mb},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=Ut({text:``,type:Hl.CATALOG_CODE_AND_DESCRIPTION,isDirty:!1}),r=M({totalCount:0,visibleMatchCount:0,items:[]}),i=M(!1),a=M(!1),{componentName:o,isReady:s,isWebComponent:c,instance:l,store:u,routeData:d,widerThan:f,narrowerThan:p,t:m}=FL(t,e.instanceId),h=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.browser)==null||(e=e.form)==null?void 0:e.visible}),g=Y(()=>{var e;return(e=u.value)==null||(e=e.options.components)==null||(e=e.browser)==null||(e=e.form)==null?void 0:e.useAutocomplete}),_=[YL,XL],v=Y(()=>_),y=async()=>{i.value=!1;try{var e;await((e=l.value)==null?void 0:e.execute(new aL({searchText:n.text}).from(o))),n.isDirty=!1}catch{}},b=e=>{n.text=e,y()},x=()=>{n.isDirty||(n.text=``,r.value.items=[],r.value.totalCount=0,y())},S=()=>{var e;g.value&&n.text!=((e=d.value)==null?void 0:e.searchText)&&n.text.length>2&&(i.value=!0)},C=M([]),w=()=>{i.value=!1},T=sp(async e=>{{let s=[],c=0,u=0,d=(e||``).trim();if(g.value&&d.length>2){a.value=!0,C.value=d.toLowerCase().split(/[._-\s/]+/).concat([d]);try{var t,n;let r=await((t=l.value)==null?void 0:t.execute(new oL({searchText:e}).from(o)));s=((r==null?void 0:r.matches)||[]).map(e=>({text:e,type:`item`})),c=(r==null?void 0:r.totalCount)||0,u=(r==null||(n=r.matches)==null?void 0:n.length)||0}catch{}}r.value={items:s,totalCount:c,visibleMatchCount:u},i.value=r.value.items.length>0,a.value=!1}},600);return I(()=>{var e;return(e=d.value)==null?void 0:e.searchText},(e,t)=>{e!==t&&(n.text=e??``)}),{root:t,componentName:o,isReady:s,isWebComponent:c,store:u,searchModel:n,searchTypeOptions:v,autocomplete:r,isAutocompleteVisible:i,isAutocompleteLoading:a,autocompleteHighlightTerms:C,widerThan:f,narrowerThan:p,t:m,onSearch:y,onSearchInput:()=>{var e,t;n.isDirty=((e=n.text)==null?void 0:e.length)>0&&n.text!=((t=d.value)==null?void 0:t.searchText),T(n.text)},onClear:x,searchText:b,openAutocomplete:S,closeAutocomplete:w,visible:h}}}),QL={key:0},$L={class:`fw-bold ext-display-name`},eR={key:0,class:`text-center`},tR={key:1},nR={key:2},rR={class:`d-none d-sm-inline`};function iR(e,t,n,r,i,a){let o=R(`Highlighter`),s=R(`Clickable`),c=R(`Spinner`),l=R(`FormInputClearable`),u=R(`Btn`),d=R(`Dropdown`);return F((H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,QL,[K(d,{open:e.isAutocompleteVisible,"onUpdate:open":t[2]||(t[2]=t=>e.isAutocompleteVisible=t),"min-width":`340px`,items:e.autocomplete.items},{item:P(({item:t})=>[K(s,{class:`dropdown-item`,onClick:n=>e.searchText(t.text)},{default:P(()=>[G(`div`,$L,[K(o,{"highlight-class-name":`text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.autocompleteHighlightTerms,"auto-escape":!0,"text-to-highlight":t.text},null,8,[`search-words`,`text-to-highlight`])])]),_:2},1032,[`onClick`])]),footer:P(()=>[e.isAutocompleteLoading?(H(),U(`div`,eR,[K(c,{sm:``})])):e.autocomplete.totalCount?(H(),U(`small`,tR,j(e.t(`ShowingNOfNMatches`,!1,[`${e.autocomplete.visibleMatchCount||0}`,`${e.autocomplete.totalCount||0}`])),1)):(H(),U(`small`,nR,j(e.t(`NoResults`)),1))]),activator:P(({on:n})=>[G(`form`,{class:`input-group flex-nowrap`,onSubmit:t[1]||(t[1]=X(t=>e.onSearch(),[`prevent`]))},[K(l,Oa({modelValue:e.searchModel.text,"onUpdate:modelValue":t[0]||(t[0]=t=>e.searchModel.text=t),"class-inner":`border-end-0`,placeholder:e.t(`SearchClassificationsInputPlaceholder`)},qr(n),{"onUpdate:modelValue":e.onSearchInput,onClear:e.onClear,onFocus:e.openAutocomplete}),null,16,[`modelValue`,`placeholder`,`onUpdate:modelValue`,`onClear`,`onFocus`]),K(u,{"aria-label":e.t(`SearchButtonText`),icon:`lens-search-find`},{default:P(()=>[G(`span`,rR,j(e.t(`SearchButtonText`)),1)]),_:1},8,[`aria-label`])],32)]),_:1},8,[`open`,`items`])])):J(``,!0)],2)),[[Mo,e.visible]])}var aR=Q(ZL,[[`render`,iR]]),oR=L({name:`pis-classifications-browser-selection`,components:{Icon:$h,Tooltip:Fw},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,narrowerThan:c,emit:l,t:u}=FL(t,e.instanceId,[TL.Classifications]),d=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null?void 0:e.selection)??{}}),f=Y(()=>{var e;return((e=a.value)==null?void 0:e.selection.selectedItems)||[]}),p=Y(()=>f.value.filter(e=>e.tree==Gl.OFFERING)),m=Y(()=>f.value.filter(e=>e.tree==Gl.PRODUCT_LINE));return{root:t,store:o,isReady:r,instance:a,routeData:s,componentName:n,isWebComponent:i,componentOptions:d,nodes:f,selection:Y(()=>{var e;return(e=a.value)==null?void 0:e.selection}),height:Y(()=>c(`sm`)?d.value.mobileScrollHeight+`px`:d.value.scrollHeight+`px`),t:u,emit:l,attrValue:Us,attrValues:Ws,additionalInfo:Gs,clearAll:()=>{try{var e;(e=a.value)==null||e.execute(new vL().from(n))}catch{}},ProductGroupValidationStatusEnum:tu,offeringNodes:p,plNodes:m}}}),sR={class:`d-flex`},cR={class:`flex-grow-1 fw-bold`},lR={key:0},uR={key:0,class:`fw-bold my-2`},dR={class:`flex-grow-1 d-flex`},fR={key:0},pR=[`onClick`],mR={key:1,class:`fw-bold my-2`},hR={class:`flex-grow-1 d-flex`},gR={key:0},_R=[`onClick`],vR={key:1,class:`p-3 text-muted`};function yR(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Tooltip`);return F((H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName]),style:{"z-index":`1`}},[e.isReady?(H(),U(V,{key:0},[G(`div`,sR,[G(`div`,cR,j(e.t(`SelectedLabel`)),1),e.nodes.length?(H(),U(`a`,{key:0,href:`#`,class:`small`,onClick:t[0]||(t[0]=X((...t)=>e.clearAll&&e.clearAll(...t),[`prevent`]))},j(e.t(`ClearAll`)),1)):J(``,!0)]),G(`div`,{class:`overflow-auto border p-1`,style:k({height:e.height})},[e.nodes&&e.nodes.length?(H(),U(`div`,lR,[e.offeringNodes.length?(H(),U(`div`,uR,j(e.t(`OfferingTree`)),1)):J(``,!0),(H(!0),U(V,null,z(e.offeringNodes,t=>(H(),U(`div`,{key:t.cid,class:`border p-1 mb-1 bg-light d-flex align-items-center rounded-2`},[G(`div`,dR,[G(`div`,null,j(t.name),1),t.productGroup.status===e.ProductGroupValidationStatusEnum.INVALID?(H(),U(`div`,fR,[K(s,{trigger:`hover`,text:e.t(`InvalidProductGroup`),delay:100},{default:P(()=>[K(o,{name:`warning-triangle`,size:16,class:`ms-1 text-warning`})]),_:1},8,[`text`])])):J(``,!0)]),G(`a`,{href:`#`,class:`text-dark pis-hover p-2 d-flex rounded-circle`,onClick:X(n=>{var r;return(r=e.selection)==null?void 0:r.deselect([t])},[`prevent`])},[K(o,{name:`cross-close`,size:16})],8,pR)]))),128)),e.plNodes.length?(H(),U(`div`,mR,j(e.t(`ProductLineTree`)),1)):J(``,!0),(H(!0),U(V,null,z(e.plNodes,t=>(H(),U(`div`,{key:t.cid,class:`border p-1 mb-1 bg-light d-flex align-items-center rounded-2`},[G(`div`,hR,[G(`div`,null,j(t.name),1),t.productGroup.status===e.ProductGroupValidationStatusEnum.INVALID?(H(),U(`div`,gR,[K(s,{trigger:`hover`,text:e.t(`InvalidProductGroup`),delay:100},{default:P(()=>[K(o,{name:`warning-triangle`,size:16,class:`ms-1 text-warning`})]),_:1},8,[`text`])])):J(``,!0)]),G(`a`,{href:`#`,class:`text-dark pis-hover p-2 d-flex rounded-circle`,onClick:X(n=>{var r;return(r=e.selection)==null?void 0:r.deselect([t])},[`prevent`])},[K(o,{name:`cross-close`,size:16})],8,_R)]))),128))])):(H(),U(`div`,vR,j(e.t(`NothingSelected`)),1))],4)],64)):J(``,!0)],2)),[[Mo,e.componentOptions.visible]])}var bR=Q(oR,[[`render`,yR]]),xR=`0px`,SR=L({name:`ClassificationNode`,components:{Icon:$h,Tooltip:Fw,TransitionHeight:L({__name:`TransitionHeight`,props:{duration:{default:100},easingEnter:{default:`ease-in-out`},easingLeave:{default:`ease-in-out`},opacityClosed:{default:0},opacityOpened:{default:1}},setup(e){let t=e;function n(e){return{height:e.style.height,width:e.style.width,position:e.style.position,visibility:e.style.visibility,overflow:e.style.overflow,paddingTop:e.style.paddingTop,paddingBottom:e.style.paddingBottom,borderTopWidth:e.style.borderTopWidth,borderBottomWidth:e.style.borderBottomWidth,marginTop:e.style.marginTop,marginBottom:e.style.marginBottom}}function r(e,t){let{width:n}=getComputedStyle(e);e.style.width=n,e.style.position=`absolute`,e.style.visibility=`hidden`,e.style.height=``;let{height:r}=getComputedStyle(e);return e.style.width=t.width,e.style.position=t.position,e.style.visibility=t.visibility,e.style.height=xR,e.style.overflow=`hidden`,t.height&&t.height!=xR?t.height:r}function i(e,t,n,r,i){let a=e.animate(r,i);e.style.height=t.height,a.onfinish=()=>{e.style.overflow=t.overflow,n()}}function a(e,n){return[{height:xR,opacity:t.opacityClosed,paddingTop:xR,paddingBottom:xR,borderTopWidth:xR,borderBottomWidth:xR,marginTop:xR,marginBottom:xR},{height:e,opacity:t.opacityOpened,paddingTop:n.paddingTop,paddingBottom:n.paddingBottom,borderTopWidth:n.borderTopWidth,borderBottomWidth:n.borderBottomWidth,marginTop:n.marginTop,marginBottom:n.marginBottom}]}function o(e,o){let s=e,c=n(s);i(s,c,o,a(r(s,c),c),{duration:t.duration,easing:t.easingEnter})}function s(e,r){let o=e,s=n(o),{height:c}=getComputedStyle(o);o.style.height=c,o.style.overflow=`hidden`,i(o,s,r,a(c,s).reverse(),{duration:t.duration,easing:t.easingLeave})}return(e,t)=>(H(),W(mo,{css:!1,onEnter:o,onLeave:s},{default:P(()=>[B(e.$slots,`default`)]),_:3}))}})},props:{item:{type:Object,required:!0},t:{type:Function,required:!0},instanceId:{type:String,default:void 0}},setup(e){let t=Y(()=>e.item._isExpanded),n=Y(()=>e.item._isLoading),r=Y(()=>Pf.Classifications.getInstance(e.instanceId)),i=Y(()=>{var e;return(e=r.value)==null?void 0:e.selection}),a=Y(()=>{var e;return(e=r.value)==null?void 0:e.favorites}),o=Y(()=>{var t;return(t=i.value)==null?void 0:t.isSelected(e.item)}),s=Y(()=>{var t;return(t=a.value)==null?void 0:t.isSelected(e.item)}),c=Y(()=>{var e;return(((e=r.value)==null||(e=e.getOptions().components)==null||(e=e.browser)==null||(e=e.tabs)==null?void 0:e.items)||[]).some(e=>e.type===Kl.FAVORITES)}),l=Y(()=>{var t;return((t=e.item.productGroup)==null?void 0:t.status)===tu.INVALID}),u=Y(()=>{var t;return((t=e.item.productGroup)==null?void 0:t.status)===tu.VALID}),d=Y(()=>{var e,t;let n=(e=r.value)==null?void 0:e.getRouteData();return eL(((t=r.value)==null||(t=t.getOptions().components)==null||(t=t.browser)==null||(t=t.tabs)==null?void 0:t.items)??[],n==null?void 0:n.tabId)});return{isExpanded:t,isLoading:n,isSelected:o,isFavorite:s,isInvalidPg:l,isValidPg:u,selection:i,areFavoritesEnabled:c,activeTab:d,isLeaf:Y(()=>{var t,n;return((t=d.value)==null?void 0:t.type)===Kl.FAVORITES&&!((n=d.value)!=null&&n.itemsExpandable)?!e.item.children:e.item.leaf}),toggleNode:async()=>{if(!e.item.leaf)try{if(t.value){var n;await((n=r.value)==null?void 0:n.execute(new cL({item:e.item}).from(`classifications-tree`)))}else{var i;await((i=r.value)==null?void 0:i.execute(new sL({item:e.item}).from(`classifications-tree`)))}}catch{}},toggleSelection:async()=>{try{var t;if((t=i.value)!=null&&t.isSelected(e.item)){var n;await((n=r.value)==null?void 0:n.execute(new hL({item:e.item}).from(`classifications-tree`)))}else{var a;await((a=r.value)==null?void 0:a.execute(new mL({item:e.item}).from(`classifications-tree`)))}}catch{}},toggleFavorite:async()=>{try{var t;if((t=a.value)!=null&&t.isSelected(e.item)){var n;await((n=r.value)==null?void 0:n.execute(new _L({item:e.item}).from(`classifications-tree`)))}else{var i;await((i=r.value)==null?void 0:i.execute(new gL({item:e.item}).from(`classifications-tree`)))}}catch{}}}}}),CR={class:`pis-tree-node`},wR={class:`d-flex align-items-center`},TR={key:0,class:`spinner-border spinner-border-sm mx-2 mt-1 mb-2`,role:`status`},ER={class:`form-check d-flex`},DR=[`id`,`checked`,`disabled`],OR=[`for`],kR={key:0,class:`text-primary pis-hover rounded-2 text-nowrap px-1`},AR={key:1,class:`pis-hover text-nowrap rounded-2 px-1`},jR={key:0},MR={key:1,class:`ms-1`},NR={key:0,class:`pis-tree`};function PR(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Tooltip`),c=R(`ClassificationNode`,!0),l=R(`TransitionHeight`);return H(),U(`li`,CR,[G(`div`,wR,[e.isLeaf?(H(),W(o,{key:0,name:`plus-add`,size:16,class:`me-1 p-2`,style:{opacity:`0`}})):(H(),U(V,{key:1},[e.isLoading?(H(),U(`div`,TR,[...t[5]||(t[5]=[G(`span`,{class:`visually-hidden`},`Loading...`,-1)])])):(H(),U(V,{key:1},[e.isExpanded?(H(),U(`a`,{key:0,href:`#`,class:`text-dark me-1 pis-hover p-2 d-flex rounded-circle`,onClick:t[0]||(t[0]=X((...t)=>e.toggleNode&&e.toggleNode(...t),[`prevent`]))},[K(o,{name:`arrow-right`,size:16,style:{transform:`rotate(90deg)`}})])):(H(),U(`a`,{key:1,href:``,class:`text-dark me-1 pis-hover p-2 d-flex rounded-circle`,onClick:t[1]||(t[1]=X((...t)=>e.toggleNode&&e.toggleNode(...t),[`prevent`]))},[K(o,{name:`arrow-right`,size:16})]))],64))],64)),G(`div`,ER,[G(`input`,{id:`cid_`+e.item.cid,class:`form-check-input me-2`,type:`checkbox`,checked:e.isSelected,disabled:!e.item.selectable,onChange:t[2]||(t[2]=(...t)=>e.toggleSelection&&e.toggleSelection(...t))},null,40,DR),G(`label`,{for:`cid_`+e.item.cid,class:A([`form-check-label user-select-none opacity-100 d-flex align-items-center`,[e.item.match&&`bg-light`]]),onDblclick:t[3]||(t[3]=X((...t)=>e.toggleNode&&e.toggleNode(...t),[`prevent`]))},[e.isValidPg?(H(),U(`div`,kR,[K(s,{trigger:`hover`,delay:200,text:e.item.productGroup.code+` - `+e.item.productGroup.name},{default:P(()=>[q(j(e.item.name),1)]),_:1},8,[`text`])])):(H(),U(`div`,AR,j(e.item.name),1))],42,OR),e.isInvalidPg?(H(),U(`div`,jR,[K(s,{trigger:`hover`,text:e.t(`InvalidProductGroup`),delay:100},{default:P(()=>[K(o,{name:`warning-triangle`,size:16,class:`ms-1 text-warning`})]),_:1},8,[`text`])])):e.areFavoritesEnabled?(H(),U(`div`,MR,[K(s,{trigger:`hover`,text:e.t(`FavoritesTooltip`),delay:100},{default:P(()=>[G(`a`,{href:`#`,class:A([`pis-hover p-1 d-flex rounded-circle`,[e.isFavorite&&`text-warning`,!e.isFavorite&&`text-secondary`]]),onClick:t[4]||(t[4]=X((...t)=>e.toggleFavorite&&e.toggleFavorite(...t),[`prevent`]))},[K(o,{name:`star`,size:16})],2)]),_:1},8,[`text`])])):J(``,!0)])]),K(l,null,{default:P(()=>[e.item.children&&e.isExpanded?(H(),U(`ul`,NR,[(H(!0),U(V,null,z(e.item.children,t=>(H(),W(c,{key:t.cid,item:t,t:e.t,"instance-id":e.instanceId},null,8,[`item`,`t`,`instance-id`]))),128))])):J(``,!0)]),_:1})])}var FR=L({components:{ClassificationNode:Q(SR,[[`render`,PR]])},props:{items:{type:Object,required:!0},t:{type:Function,required:!0},instanceId:{type:String,required:!0}},setup(){return{}}}),IR={class:`pis-tree ps-0`};function LR(e,t,n,r,i,a){let o=R(`ClassificationNode`);return H(),U(`ul`,IR,[(H(!0),U(V,null,z(e.items,t=>(H(),W(o,{key:t.cid,item:t,"instance-id":e.instanceId,t:e.t},null,8,[`item`,`instance-id`,`t`]))),128))])}var RR=L({name:`pis-classifications-browser-tree`,components:{ClassificationRootNode:Q(FR,[[`render`,LR]])},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,narrowerThan:c,emit:l,t:u}=FL(t,e.instanceId,[TL.Classifications]),d=M([]),f=Y(()=>{var e,t;return((e=((t=o.value)==null||(t=t.options.components)==null||(t=t.browser)==null?void 0:t.tabs)??{})==null||(e=e.items)==null?void 0:e.map(e=>e.type))??[]}),p=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null?void 0:e.tree)??{}}),m=Y(()=>{var e,t;return _.value&&f.value.indexOf(Kl.PRODUCT_LINE)<0?((e=o.value)==null||(e=e.data.classifications)==null||(e=e.items)==null?void 0:e.filter(e=>e.tree!=Gl.PRODUCT_LINE))??[]:((t=o.value)==null||(t=t.data.classifications)==null?void 0:t.items)??[]}),h=Y(()=>{var e;return(e=o.value)==null||(e=e.data.classifications)==null?void 0:e.limitExceeded}),g=Y(()=>{var e,t;return eL(((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null||(e=e.tabs)==null?void 0:e.items)??[],(t=s.value)==null?void 0:t.tabId)}),_=Y(()=>{var e;return((e=g.value)==null?void 0:e.type)===Kl.FAVORITES}),v=Y(()=>{var e;return _.value&&((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null||(e=e.common)==null||(e=e.toolbar)==null?void 0:e.expandFavoritesVisible)}),y=async()=>{try{var e;await((e=a.value)==null?void 0:e.execute(new lL().from(n)))}catch{}},b=async()=>{try{var e;await((e=a.value)==null?void 0:e.execute(new uL().from(n)))}catch{}},x=Y(()=>c(`sm`)?p.value.mobileScrollHeight+`px`:p.value.scrollHeight+`px`),S=sp(()=>{try{if(d.value.length){var e;(e=a.value)==null||e.execute(new xL({message:d.value.join(`<br>`),type:`warning`,dismissAfter:0}).from(n)),d.value=[]}}catch{}},500),C=I(()=>{var e;return(e=a.value)==null?void 0:e.store.data.invalidSelectedItems},async()=>{var e;let t=(e=a.value)==null?void 0:e.store.data.invalidSelectedItems;t&&t!=null&&t.length&&(C(),d.value.push(u(`InvalidSelectedItemsWarning`,!1,[t.map(e=>e.cid).join(`, `)])),S())},{immediate:!0}),w=I(()=>{var e;return(e=a.value)==null?void 0:e.store.data.invalidFavoriteItems},async()=>{var e;let t=(e=a.value)==null?void 0:e.store.data.invalidFavoriteItems;t&&t!=null&&t.length&&(w(),d.value.push(u(`InvalidFavoriteItemsWarning`,!1,[t.map(e=>e.cid).join(`, `)])),S())},{immediate:!0});return{root:t,store:o,nodes:m,height:x,isReady:r,instance:a,routeData:s,componentName:n,isWebComponent:i,isLimitExceeded:h,componentOptions:p,isOnFavoritesView:_,isExpandFavoritesVisible:v,t:u,emit:l,collapseAll:y,expandAll:b}}}),zR={class:`d-flex`},BR={class:`flex-grow-1 fw-bold`},VR={key:0,class:`p-3 mb-1 text-muted`},HR={key:1},UR={key:2,class:`p-3 text-muted`};function WR(e,t,n,r,i,a){let o=R(`ClassificationRootNode`);return F((H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName]),style:{"z-index":`1`}},[e.isReady?(H(),U(V,{key:0},[G(`div`,zR,[G(`div`,BR,j(e.t(`SelectLabel`)),1),G(`a`,{href:`#`,class:`small text-end`,onClick:t[0]||(t[0]=X((...t)=>e.collapseAll&&e.collapseAll(...t),[`prevent`]))},j(e.t(`CollapseAllClassifications`)),1),e.isExpandFavoritesVisible?(H(),U(`a`,{key:0,href:`#`,class:`small ms-2 text-end`,onClick:t[1]||(t[1]=X((...t)=>e.expandAll&&e.expandAll(...t),[`prevent`]))},j(e.t(`ExpandAllFavorites`)),1)):J(``,!0)]),G(`div`,{class:`overflow-auto border p-1`,style:k({height:e.height})},[e.isLimitExceeded?(H(),U(`div`,VR,j(e.t(`SearchLimitExceeded`)),1)):J(``,!0),e.nodes.length?(H(),U(`div`,HR,[K(o,{items:e.nodes,"instance-id":e.instance.id,t:e.t},null,8,[`items`,`instance-id`,`t`])])):(H(),U(`div`,UR,j(e.isOnFavoritesView?e.t(`NoFavoritesSelected`):e.t(`NoResults`)),1))],4)],64)):J(``,!0)],2)),[[Mo,e.componentOptions.visible]])}var GR=Q(RR,[[`render`,WR]]),KR=L({name:`pis-classifications-browser-tree-type-tabs`,components:{Icon:$h,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isReady:i,isWebComponent:a,store:o,t:s,narrowerThan:c}=FL(t,e.instanceId),l={Offering:`OfferingTree`,ProductLine:`ProductLineTree`,Favorites:`MyFavorites`,OfferingAndProductLine:`OfferingAndProductLine`},u=e=>{switch(e){case`Offering`:var t;return((t=r.value)==null?void 0:t.selection.selectedItems.filter(e=>e.tree==Gl.OFFERING).length)??0;case`ProductLine`:var n;return((n=r.value)==null?void 0:n.selection.selectedItems.filter(e=>e.tree==Gl.PRODUCT_LINE).length)??0;case`Favorites`:var i;return((i=r.value)==null?void 0:i.favorites.selectedItems.length)??0;default:return 0}},d=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.browser)==null?void 0:e.tabs)??{}}),f=Y(()=>{var e;return(e=r.value)==null?void 0:e.router.routeData}),p=Y(()=>{var e;return(e=f.value)==null?void 0:e.tabId}),m=Y(()=>{var e;return(((e=d.value)==null?void 0:e.items)??[]).filter(e=>e.visible!==!1)}),h=hg(e=>({instance:r.value,tab:e,t:s}));return{root:t,visible:Y(()=>{var e;return(e=d.value)==null?void 0:e.visible}),store:o,isReady:i,activeTabKey:p,visibleTabs:m,componentName:n,isWebComponent:a,translationMap:l,componentOptions:d,t:s,switchToView:async e=>{try{var t;await((t=r.value)==null?void 0:t.execute(new pL({tabId:e.id??e.type}).from(n)))}catch{}},narrowerThan:c,getCount:u,tabContext:h}}}),qR={key:0,class:`mb-3`},JR={class:`nav nav-tabs`},YR=[`onClick`],XR={key:3},ZR={key:4,class:`badge rounded-pill bg-secondary text-body ms-1 small d-none d-sm-inline`};function QR(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Icon`);return F((H(),U(`div`,{ref:`root`,class:A([`pis-component position-relative`,e.componentName])},[e.isReady?(H(),U(`div`,qR,[G(`ul`,JR,[(H(!0),U(V,null,z(e.visibleTabs,t=>(H(),U(`li`,{key:t.id,class:`nav-item`,style:{"max-width":`33%`}},[G(`a`,{class:A([`nav-link mx-1 text-nowrap pis-text-ellipsis`,e.activeTabKey===t.id?`active`:``]),href:`#`,onClick:X(n=>e.switchToView(t),[`prevent`])},[e.narrowerThan(`md`)&&t.iconTemplate?(H(),W(o,{key:0,callbacks:t.iconTemplate,ctx:e.tabContext(t)},null,8,[`callbacks`,`ctx`])):e.narrowerThan(`md`)&&t.type===`Favorites`?(H(),W(s,{key:1,class:`px-2`,name:`star`,size:16})):t.labelTemplate?(H(),W(o,{key:2,callbacks:t.labelTemplate,ctx:e.tabContext(t)},null,8,[`callbacks`,`ctx`])):(H(),U(`span`,XR,j(e.t(e.translationMap[t.type])),1)),t.countsVisible&&e.getCount(t.type)>0?(H(),U(`span`,ZR,j(e.getCount(t.type)),1)):J(``,!0)],10,YR)]))),128))])])):J(``,!0)],2)),[[Mo,e.visible]])}var $R=Q(KR,[[`render`,QR]]),ez=L({name:`pis-classifications-loading-indicator`,components:{Spinner:My},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,routeData:o}=FL(t,e.instanceId);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:a,routeData:o,showOverlay:pT(Y(()=>{var e;return r.value&&!!((e=a.value)!=null&&e.data.isLoadingData)}),Y(()=>{var e;return!!((e=a.value)!=null&&(e=e.data.classifications)!=null&&(e=e.items)!=null&&e.length)}))}}}),tz={ref:`root`,class:`pis-component position-relative`},nz={class:`position-absolute start-50 top-50`,style:{"z-index":`2000`}};function rz(e,t,n,r,i,a){let o=R(`Spinner`);return H(),U(`div`,tz,[e.showOverlay?(H(),U(V,{key:0},[G(`div`,nz,[B(e.$slots,`loader`,{},()=>[K(o)])]),t[0]||(t[0]=G(`div`,{class:`position-absolute top-0 start-0 end-0 bottom-0 bg-body`,style:{"z-index":`1900`,opacity:`0.2`}},null,-1))],64)):J(``,!0),B(e.$slots,`default`)],512)}var iz=L({name:`pis-classifications-layout`,components:{LoadingIndicator:Q(ez,[[`render`,rz]]),ClassificationsSearchForm:aR,ClassificationsTree:GR,ClassificationsSelection:bR,ClassificationNote:JL,ClassificationActions:HL,ClassificationsTreeTabs:$R,ClassificationsNotifications:zL},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isWebComponent:i,isReady:a,translationsReady:o,store:s,routeData:c,widerThan:l,t:u}=FL(t,e.instanceId);return{root:t,componentName:n,isWebComponent:i,isReady:a,instance:r,translationsReady:o,store:s,routeData:c,allowMobileView:Y(()=>{var e;return(e=s.value)==null?void 0:e.options.allowMobileView}),widerThan:l,t:u}}}),az={class:`container-fluid g-0`},oz={class:`row`},sz={class:`col-md-12`},cz={class:`row`},lz={class:`col-md-6 col-sm-12 mb-3`},uz={class:`col-md-6 col-sm-12 text-end mb-3`},dz={class:`row`},fz={class:`col-md-6 mb-3`},pz={class:`col-md-6`};function mz(e,t,n,r,i,a){let o=R(`ClassificationsNotifications`),s=R(`ClassificationNote`),c=R(`ClassificationsTreeTabs`),l=R(`ClassificationsSearchForm`),u=R(`ClassificationActions`),d=R(`ClassificationsTree`),f=R(`ClassificationsSelection`),p=R(`LoadingIndicator`);return H(),U(`div`,{ref:`root`,class:A([`pis-component w-100 h-100`,e.componentName])},[F(G(`div`,null,[K(o),K(p,null,{default:P(()=>[G(`div`,az,[G(`div`,oz,[G(`div`,sz,[K(s,{t:e.t},null,8,[`t`]),K(c)])]),G(`div`,cz,[G(`div`,lz,[K(l)]),G(`div`,uz,[K(u)])]),G(`div`,dz,[G(`div`,fz,[K(d)]),G(`div`,pz,[K(f)])])])]),_:1})],512),[[Mo,e.isReady]])],2)}var hz=[Q(iz,[[`render`,mz]]),GR,aR,bR,$R,JL,HL,zL],gz=WI({idPrefix:`pisClassificationsInstance_`,instanceTag:`pis-classifications-instance`,getInstanceById:e=>Pf.Classifications.getInstance(e),isReady:e=>!!(e.store.data.isInitialized&&e.store.data.translationsReady),hasContent:e=>{var t;return!!((t=e.store.data.classifications)!=null&&(t=t.items)!=null&&t.length)},elements:[{kind:`instance`,name:`pis-classifications-instance`},{kind:`loader`,name:`pis-classifications-loading-indicator`,spinnerZIndex:2e3,backdropZIndex:1900,backdropOpacity:.2}]});function _z(){Lf(new NL),JI(hz,gz),Rf()}var vz={key:1,class:`text-muted`},yz=L({__name:`ProductNameTableCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item),r=Y(()=>Us(n.value,`#DisplayName`));return(t,i)=>n.value.inactive?(H(),U(`span`,vz,j(r.value),1)):(H(),U(`a`,{key:0,href:`#`,onClick:i[0]||(i[0]=X(t=>e.ctx.details(e.ctx.item),[`prevent`]))},j(r.value),1))}}),bz={class:`fw-bold`},xz={class:`text-muted small`},Sz={key:1},Cz={class:`fw-bold`},wz={class:`text-muted small`},Tz=L({__name:`VariantsProductCell`,props:{ctx:{}},setup(e){let t=e,n=Y(()=>t.ctx.item),r=Y(()=>Us(n.value,`#DisplayName`)),i=Y(()=>Us(n.value,`CatalogDescription`));return(t,a)=>n.value.productId?(H(),U(`a`,{key:0,href:`#`,class:`text-decoration-none`,onClick:a[0]||(a[0]=X(t=>e.ctx.details(e.ctx.item),[`prevent`]))},[G(`div`,bz,j(r.value),1),G(`div`,xz,j(i.value),1)])):(H(),U(`div`,Sz,[G(`div`,Cz,j(r.value),1),G(`div`,wz,j(i.value),1)]))}}),Ez={class:`d-flex flex-wrap gap-1`},Dz=L({__name:`VariantsVariantCell`,props:{ctx:{}},setup(e){let t=e,n=(e,t)=>Us(e,t),r=Y(()=>t.ctx.group.variantAttributes??[]);return(t,i)=>(H(),U(`div`,Ez,[(H(!0),U(V,null,z(r.value,(t,r)=>(H(),U(`span`,{key:t.attributeCode??r,class:`badge bg-light text-dark border`},j(t.attributeName??``)+`: `+j(n(e.ctx.item,t.attributeCode)),1))),128))]))}}),Oz=class{constructor(){Z(this,`appSettings`,{appCode:``,langCode:`en`,countryCode:void 0,includeInternalData:!1,treeType:ou.PRODUCTS}),Z(this,`styles`,[]),Z(this,`components`,{common:{hideDocumentLinks:!0,hideReplacements:!1,hideWhereUsed:!1,maxAttributeValuesVisible:10},search:{common:{configurators:{visible:!1}},breadcrumbs:{visible:!0},form:{visible:!0,useAutocomplete:!0,maxCategoryMatches:2},toolbar:{visible:!0,pageSizes:[12,24,48,72],subViews:[`table`,`list`,`grid`],countVisible:!0,subViewsVisible:!0,pageSizesVisible:!0,sortVisible:!0,exportMenu:{visible:!1,items:[]}},pagination:{visible:!0,visiblePages:5},header:{visible:!0},categories:{visible:!0,card:!0,icon:!0,maxCategoriesVisible:12},filters:{visible:!0,card:!0,icon:!0,maxFiltersVisible:10,visibleFromNodeLevel:0},filtersStatus:{visible:!0},narrowByProduct:{visible:!0,card:!0,icon:!0},partTypes:{visible:!0},selection:{visible:!1,deselectAllVisible:!0,selectAllVisible:!0,persist:!1,countVisible:!0},table:{visible:!0,selectable:!1,columns:[{caption:`Name`,dataField:`#DisplayName`,width:`33%`,treeTypes:[ou.PRODUCTS],showAllIdentifiers:!0,headerTemplate:ac(`ProductListProduct`,`common`),cellTemplate:yz},{caption:`Name`,dataField:`#DisplayName`,width:`33%`,treeTypes:[ou.PARTS],showAllIdentifiers:!0,headerTemplate:ac(`ProductListSparePart`,`common`),cellTemplate:yz},{caption:`Description`,treeTypes:[ou.PRODUCTS,ou.PARTS],headerTemplate:ac(`ProductListInformation`,`common`),dataField:`CatalogDescription`,showReplacements:!0,showVariants:!0},{caption:`Quantity`,treeTypes:[ou.PARTS],headerTemplate:ac(`ProductListQuantity`,`common`),dataField:`#Quantity`,masterProductRequired:!0}]},list:{visible:!0,showAllIdentifiers:!0,showReplacements:!0,navigateOnContentClick:!0,imageSize:`10rem`,selectable:!1,imagePadding:0,mobileBreakpoint:680,imageLazyLoading:!0,showVariants:!0},grid:{visible:!0,selectable:!1,showAllIdentifiers:!0,showReplacements:!0,navigateOnContentClick:!0,imageLazyLoading:!0,showVariants:!0},gridHorizontal:{visible:!0,selectable:!1,showAllIdentifiers:!0,showReplacements:!0,navigateOnContentClick:!0,showVariants:!0,carousel:{mouseDrag:!0,touchDrag:!0,transition:300,wrapAround:!1,defaults:{itemsToShow:1,itemsToScroll:1,snapAlign:`center`,margin:5,navigationVisible:!0,paginationVisible:!0},breakpoints:{576:{itemsToShow:2,itemsToScroll:1,snapAlign:`start`,margin:2,navigationVisible:!0,paginationVisible:!1},922:{itemsToShow:4,itemsToScroll:1,snapAlign:`start`,margin:2,navigationVisible:!0,paginationVisible:!1}}}},favoriteCategories:{visible:!1,card:!0,icon:!0,productCids:void 0,partCids:void 0,maxCategoriesVisible:12},favoriteViews:{visible:!1,card:!0,icon:!0,fallbackCode:`ABB`,maxViewsVisible:10,savedViewIds:void 0}},details:{data:{attributeCodes:void 0,bottomNavigationSticky:!0,hideBottomNavigation:!1,showTabCounts:!0,showTabIcons:!0,relationships:{productRelationshipFiltering:!0,pageSize:5,searchMinItems:5,filteringMinItems:5,filteringMaxAttributesVisible:5,actionTemplates:{},displayMode:{All:`table`}},downloads:{visible:!0,count:void 0,loading:!1}},classifications:{visible:!0,treeView:!1},gallery:{visible:!0,hideThumbnailImages:!1,showOverlayArrows:!1},relatedLinks:{visible:!1,showImages:!0},header:{visible:!0,showBackBtn:!0,showPrintToPdfBtn:!0,showPrintViewBtn:!1},variantsDropdown:{visible:!1,showImages:!0},variantsSelector:{visible:!0,unavailableValuesBehavior:`disabled`},variantsTable:{visible:!1,showImages:!0,columns:[{caption:`Product`,width:`25%`,headerTemplate:ac(`ProductListProduct`,`common`),cellTemplate:Tz},{caption:`Variant`,width:`auto`,headerTemplate:ac(`Variant`,`products`),cellTemplate:Dz}]}},compare:{view:{visible:!0,imageSize:`120px`,showAllIdentifiers:!0,showReplacements:!0,categoriesVisible:!0,navigationVisible:!0,printButtonVisible:!1,compactMode:!0,attrColWidth:`240px`,valColWidth:`240px`,imageVisible:!0,imageHideOnScroll:!0}},preview:{view:{visible:!0}}}),Z(this,`allowMobileView`,!0),Z(this,`cacheTranslations`,!0)}},kz=e=>({addToCatalog:async(t,n,r,i)=>e.execute(new om({productId:t,catalogType:n,uom:r,catalogId:i}),`api`)}),Az={search:`/v2/Products/Search`,count:`/v2/Products/Count`,detail:`/v2/Products/Detail`,variantsTable:`/v2/Products/Variants/Table`,translations:`/v2/Translations`},$={Classifications:nu.CLASSIFICATIONS,Products:nu.PRODUCTS,Filters:nu.FILTERS,Breadcrumbs:nu.BREADCRUMBS,Configurators:nu.CONFIGURATORS,MasterProducts:nu.MASTER_PRODUCTS,PartTypes:nu.PART_TYPES,ProductDetails:Yl.PRODUCT_DETAILS,ProductClassifications:Yl.PRODUCT_CLASSIFICATIONS,AttributeGroups:Yl.ATTRIBUTE_GROUPS,ProductRelationships:Yl.PRODUCT_RELATIONSHIPS,RelatedLinks:Yl.RELATED_LINKS,ProductVariantsSelector:Yl.PRODUCT_VARIANTS_SELECTOR,ProductVariantsTable:Yl.PRODUCT_VARIANTS_TABLE,ProductVariantsDropdown:Yl.PRODUCT_VARIANTS_DROPDOWN,ExtendedObjectData:Yl.EXTENDED_OBJECT_DATA,ProductPreview:`ProductPreview`,FavoriteProductCategories:`FavoriteProductCategories`,FavoritePartCategories:`FavoritePartCategories`,FavoriteViews:`FavoriteViews`,Translations:`Translations`,RelatedProducts:`RelatedProducts`,ProductCompare:`ProductCompare`,ProductIdToName:`ProductIdToName`},jz={[$.Products]:(e,t)=>{e.products=t},[$.Classifications]:(e,t)=>{e.classifications=t},[$.Filters]:(e,t)=>{e.filters=t},[$.Breadcrumbs]:(e,t)=>{e.breadcrumbs=t},[$.ProductDetails]:(e,t)=>{t==null?(e.productDetail=void 0,e.itemNotFound=!0):(e.productDetail=t,e.itemNotFound=!1)},[$.ProductClassifications]:(e,t)=>{e.productClassifications=t},[$.AttributeGroups]:(e,t)=>{e.attributeGroups=t},[$.ProductRelationships]:(e,t)=>{e.prm=t},[$.Configurators]:(e,t)=>{e.configurators=t},[$.RelatedLinks]:(e,t)=>{e.relatedLinks=t},[$.ProductPreview]:(e,t)=>{e.productPreview=t},[$.PartTypes]:(e,t)=>{e.partTypes=t},[$.MasterProducts]:(e,t)=>{e.sparePartMasterProducts=t},[$.FavoriteProductCategories]:(e,t)=>{e.favoriteProductCategories=t},[$.FavoritePartCategories]:(e,t)=>{e.favoritePartCategories=t},[$.FavoriteViews]:(e,t)=>{e.favoriteViews=t},[$.RelatedProducts]:(e,t)=>{e.relatedProducts=t},[$.ProductCompare]:(e,t)=>{e.compareResult=t},[$.ProductIdToName]:(e,t)=>{if(e.productIdToDisplayName||(e.productIdToDisplayName={}),t!=null&&t.item){let{requestedProductId:n,item:r}=t,i=Us(r,`#DisplayName`);i&&(e.productIdToDisplayName[r.productId]=i,e.productIdToDisplayName[n]=i)}},[$.ProductVariantsSelector]:(e,t)=>{e.productVariantsSelector=t},[$.ProductVariantsTable]:(e,t)=>{var n;let r=t==null?void 0:t.items,i=(n=e.productVariantsTable)==null?void 0:n.items;if((r==null?void 0:r.length)===1&&i!=null&&i.length){let e=r[0],t=i.findIndex(t=>t.attributeCode===e.attributeCode);if(t>=0){i.splice(t,1,e);return}i.push(e);return}e.productVariantsTable=t},[$.ProductVariantsDropdown]:(e,t)=>{e.productVariantsDropdown=t},[$.Translations]:(e,t)=>{Gd.log(`Setting store data not handled`,{type:$.Translations,data:t})},[$.ExtendedObjectData]:(e,t)=>{Gd.log(`Setting store data not handled`,{type:$.ExtendedObjectData,data:t})}},Mz=class extends Wd{constructor(e){super(e)}dataInterceptor(){var e;return(e=this.instance.store)==null?void 0:e.options.dataInterceptor}dispatchLoadEvent(e){this.setStoreData(e)}setStoreData({type:e,data:t}){if(!this.instance.store)return;let n=jz[e];n(this.instance.store.data,t)}},Nz=`pis-products-translations`,Pz=class extends af{constructor(e,t,n){super(),Z(this,`instance`,void 0),Z(this,`instanceType`,`Products`),Z(this,`storeService`,void 0),Z(this,`client`,void 0),Z(this,`variantTableController`,void 0),Z(this,`autocompleteController`,new AbortController),Z(this,`autocompleteCache`,{}),Z(this,`_lastFilterLoad`,{key:``,count:0}),this.instance=e,this.client=nf(e,t,n),this.storeService=new Mz(e)}searchVariants(){var e;return(e=this.instance.store.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.variants}detailVariants(){var e;return(e=this.instance.store.options.components)==null||(e=e.details)==null||(e=e.data)==null?void 0:e.variants}relationshipSettings(e){var t;let n=(t=this.instance.store.options.components)==null||(t=t.details)==null||(t=t.data)==null?void 0:t.relationships;return{productRelationshipFiltering:n==null?void 0:n.productRelationshipFiltering,attributeCodes:n==null?void 0:n.attributeCodes,...e?{pager:e}:{}}}async load(e){if(this.instance.router)try{let t=e||this.instance.router.routeData;switch(t.view){case`search`:return await this.query(t);case`detail`:return await this.detail(t);case`compare`:return await this.compare(t);default:throw Error(`Unknown view type "${t.view}" to be handled by HttpService`)}}catch(e){this.instance.store.data.isLoadingData=!1,console.error(`Load failed`,e)}}async paginate(e){var t,n;let r=this.searchAttribution();this.instance.store.data.isLoadingData=!0;let i=Date.now(),a;try{var o,s,c,l,u,d,f,p,m,h,g,_,v;a=await Nl.search({searchQuery:{attributeCodes:(o=this.instance.store.options.components)==null||(o=o.search)==null||(o=o.common)==null?void 0:o.attributeCodes,appSettings:(s=this.instance.store)==null?void 0:s.options.appSettings,dataTypes:[nu.PRODUCTS],variants:this.searchVariants(),pager:{page:(e==null||(c=e.search)==null||(c=c.pagination)==null?void 0:c.page)??1,pageSize:(e==null||(l=e.search)==null||(l=l.pagination)==null?void 0:l.pageSize)??12},search:{cid:(u=e.search)==null?void 0:u.cid,partType:((d=e.search)==null?void 0:d.partsType)||$l.ALL,searchType:(f=e.search)==null?void 0:f.searchType,searchText:((p=e.search)==null?void 0:p.searchText)??void 0,filter:(m=e.search)==null?void 0:m.filters,masterProductId:((h=e.search)==null?void 0:h.masterProductId)??void 0},sort:{field:((g=e.search)==null?void 0:g.sortField)??au.PRODUCT,direction:((_=e.search)==null?void 0:_.sortDirection)??iu.ASCENDING},includeProductClassifications:(v=this.instance.store.options.components)==null||(v=v.search)==null||(v=v.common)==null?void 0:v.includeProductClassifications}},{client:this.client})}catch(t){throw this.trackSearch(e,{status:`error`,durationMs:Date.now()-i},r),t}this.trackSearch(e,Nc((t=a.products)==null?void 0:t.totalCount,(n=a.products)==null?void 0:n.items,Date.now()-i),r),this.instance.eventBus.emit(`search-loaded`,a),a.products&&this.storeService.setData($.Products,a.products),this.instance.store.data.isLoadingData=!1}searchAttribution(){let{action:e,source:t,trigger:n=`ui`}=Ac(this.instance)??{};return{origin:e??`route`,trigger:n,...t?{source:t}:{}}}trackSearch(e,t,n){var r,i,a,o,s,c;Mc(this.instance,{kind:`search`,action:`search`,trigger:n.trigger,origin:n.origin,...n.source?{source:n.source}:{},args:{searchText:((r=e.search)==null?void 0:r.searchText)??null,searchType:((i=e.search)==null?void 0:i.searchType)??null,cid:((a=e.search)==null?void 0:a.cid)??null,page:((o=e.search)==null||(o=o.pagination)==null?void 0:o.page)??1,pageSize:((s=e.search)==null||(s=s.pagination)==null?void 0:s.pageSize)??12,appliedFilterCount:((c=e.search)==null||(c=c.filters)==null||(c=c.rules)==null?void 0:c.length)??0},outcome:t})}async query(e){var t,n,r,i,a,o,s,c,l,u;let{pagination:d,searchText:f,searchType:p,cid:m,filters:h,sortField:g,sortDirection:_,partsType:v,masterProductId:y}=e.search??{},b=this.instance.getRegisteredSearchDataTypes();if(!b.length)return Promise.resolve();let x=this.searchAttribution();this.instance.store.data.isLoadingData=!0;let S=Date.now(),C={attributeCodes:(t=this.instance.store.options.components)==null||(t=t.search)==null||(t=t.common)==null?void 0:t.attributeCodes,appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,dataTypes:b,variants:this.searchVariants(),maxProductImages:(r=this.instance.store.options.components)==null||(r=r.search)==null||(r=r.common)==null?void 0:r.maxProductImages,maxClassificationImages:(i=this.instance.store.options.components)==null||(i=i.search)==null||(i=i.common)==null?void 0:i.maxCategoryImages,pager:{page:(d==null?void 0:d.page)??1,pageSize:(d==null?void 0:d.pageSize)??12},search:{cid:m,partType:v||$l.ALL,searchType:p,searchText:f??void 0,filter:h,masterProductId:y??void 0},sort:{field:g??au.PRODUCT,direction:_??iu.ASCENDING},filterSettings:{attributeCodes:(a=this.instance.store.options.components)==null||(a=a.search)==null||(a=a.filters)==null?void 0:a.attributeCodes,maxFilterAttributes:(o=this.instance.store.options.components)==null||(o=o.search)==null||(o=o.filters)==null?void 0:o.maxFiltersVisible},includeProductClassifications:(s=this.instance.store.options.components)==null||(s=s.search)==null||(s=s.common)==null?void 0:s.includeProductClassifications,includeExtendedObjectData:(c=this.instance.store.options.components)==null||(c=c.search)==null||(c=c.common)==null?void 0:c.includeExtendedObjectData},w;if(this.instance.store.options.httpInterceptor)try{w=await this.instance.store.options.httpInterceptor({body:C,url:Az.search,method:`post`})}catch{}let T=w;try{T||(T=await Nl.search({searchQuery:C},{client:this.client}))}catch(t){throw this.trackSearch(e,{status:`error`,durationMs:Date.now()-S},x),t}this.trackSearch(e,Nc((l=T.products)==null?void 0:l.totalCount,(u=T.products)==null?void 0:u.items,Date.now()-S),x),this.instance.eventBus.emit(`search-loaded`,T),T.products&&this.storeService.setData($.Products,T.products),T.classifications&&this.storeService.setData($.Classifications,T.classifications),T.filters&&this.storeService.setData($.Filters,T.filters),T.breadcrumbs&&this.storeService.setData($.Breadcrumbs,T.breadcrumbs),T.configurators&&this.storeService.setData($.Configurators,T.configurators),T.partTypes&&this.storeService.setData($.PartTypes,T.partTypes),T.masterProducts&&this.storeService.setData($.MasterProducts,T.masterProducts),this.instance.store.data.isLoadingData=!1,this.instance.eventBus.emit(`search-changed`)}async detail(e){var t,n,r,i,a,o;let s=(t=e.detail)==null?void 0:t.productId,c=(n=e.search)==null?void 0:n.cid;if(!s)return Promise.resolve();let l=this.instance.getRegisteredDetailsDataTypes();if(!l.length)return Promise.resolve();this.instance.store.data.isLoadingData=!0,this.instance.store.data.productDetail=void 0,(r=this.variantTableController)==null||r.abort(),await this.storeService.setData($.ProductVariantsTable,void 0);let u={appSettings:(i=this.instance.store)==null?void 0:i.options.appSettings,dataTypes:l,search:{productId:s,cid:c},attributeCodes:(a=this.instance.store)==null||(a=a.options.components)==null||(a=a.details)==null||(a=a.data)==null?void 0:a.attributeCodes,maxProductImages:(o=this.instance.store)==null||(o=o.options.components)==null||(o=o.details)==null||(o=o.data)==null?void 0:o.maxProductImages,relationships:this.relationshipSettings(),variants:this.detailVariants()},d;if(this.instance.store.options.httpInterceptor)try{d=await this.instance.store.options.httpInterceptor({body:u,url:Az.detail,method:`post`})}catch{}let f=d;f||(f=await Nl.detail({detailQuery:u},{client:this.client})),this.instance.eventBus.emit(`detail-loaded`,f),f.productDetails?(this.storeService.setData($.ProductDetails,f.productDetails),this.storeService.setData($.ProductIdToName,{item:f.productDetails.item,requestedProductId:s})):this.storeService.setData($.ProductDetails,void 0),f.attributeGroups&&this.storeService.setData($.AttributeGroups,f.attributeGroups),f.productRelationships&&this.storeService.setData($.ProductRelationships,f.productRelationships),f.productClassifications&&this.storeService.setData($.ProductClassifications,f.productClassifications),f.relatedLinks?this.storeService.setData($.RelatedLinks,f.relatedLinks):this.storeService.setData($.RelatedLinks,void 0),f.productVariantsSelector&&this.storeService.setData($.ProductVariantsSelector,f.productVariantsSelector),f.productVariantsTable&&this.storeService.setData($.ProductVariantsTable,f.productVariantsTable),f.productVariantsDropdown&&this.storeService.setData($.ProductVariantsDropdown,f.productVariantsDropdown),this.storeService.setData($.RelatedProducts,f.relatedProducts||void 0),this.instance.store.data.isLoadingData=!1}async loadVariantTableGroup(e){var t,n,r,i,a;let{productId:o}=this.instance.router.routeData.detail??{};if(!o||!e)return;let s=(t=this.instance.store.data.productVariantsTable)==null||(t=t.items)==null?void 0:t.find(t=>t.attributeCode===e);if((s==null?void 0:s.products)!==void 0&&s.variantAttributes!==void 0)return;(n=this.variantTableController)==null||n.abort();let c=new AbortController;this.variantTableController=c;let l={appSettings:this.instance.store.options.appSettings,attributeCode:e,attributeCodes:(r=this.detailVariants())==null?void 0:r.attributeCodes,search:{productId:o}},u;if(this.instance.store.options.httpInterceptor&&(u=await this.instance.store.options.httpInterceptor({body:l,url:Az.variantsTable,method:`post`}),c.signal.aborted||this.variantTableController!==c))return;let d;try{d=u??await Nl.variantsTable({productVariantsTableQuery:l},{client:this.client,signal:c.signal})}catch(e){if(Pc(e))return;throw e}if(c.signal.aborted||this.variantTableController!==c)return;let f=(i=d.items)==null?void 0:i[0];if(((a=d.items)==null?void 0:a.length)!==1||(f==null?void 0:f.attributeCode)!==e)throw Error(`Variants table group "${e}" was not returned.`);await this.storeService.setData($.ProductVariantsTable,d)}async compare(e){var t,n,r,i,a,o,s,c;this.instance.store.data.isLoadingData=!0;let l=await Nl.compare({compareQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{productIds:((n=e.compare)==null?void 0:n.productIds)??[],mergeMethod:((r=e.compare)==null?void 0:r.mergeMethod)??Il.FLAT,cids:((i=e.compare)==null?void 0:i.cids)??[],differencesOnly:(a=e.compare)==null?void 0:a.differencesOnly,strictMode:(o=e.compare)==null?void 0:o.strictMode,specialDocumentHandling:(s=e.compare)==null?void 0:s.specialDocumentHandling},maxProductImages:(c=this.instance.store.options.components)==null||(c=c.compare)==null||(c=c.view)==null?void 0:c.maxProductImages}},{client:this.client});this.instance.eventBus.emit(`compare-loaded`,l),l&&this.storeService.setData($.ProductCompare,l),this.instance.store.data.isLoadingData=!1}async preview(e){var t,n,r,i;this.instance.store.data.isLoadingData=!0;let a=await Nl.preview({previewQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{productId:e,cid:(n=this.instance.getRouteData().search)==null?void 0:n.cid,filter:(r=this.instance.getRouteData().search)==null?void 0:r.filters},maxProductImages:(i=this.instance.store.options.components)==null||(i=i.preview)==null||(i=i.view)==null?void 0:i.maxProductImages}},{client:this.client});this.instance.eventBus.emit(`preview-loaded`,a),a&&this.storeService.setData($.ProductPreview,a),this.instance.store.data.isLoadingData=!1}async filterValues(e){var t;let{searchText:n,searchType:r,cid:i,filters:a,partsType:o}=this.instance.router.routeData.search??{};return await Nl.filterValues({filterValueQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,variants:this.searchVariants(),search:{cid:i,searchText:n,searchType:r,partType:o,filter:a,attributeCodes:e}}},{client:this.client})}async filters(){var e;let{searchText:t,searchType:n,cid:r,filters:i,partsType:a}=this.instance.router.routeData.search??{};return await Nl.filters({filtersQuery:{appSettings:(e=this.instance.store)==null?void 0:e.options.appSettings,variants:this.searchVariants(),search:{cid:r,searchText:t,searchType:n,partType:a,filter:i}}},{client:this.client})}async loadTranslations(){var e;let t=await this.fetchTranslations(Nz,Az.translations),n=(e=this.instance.store)==null?void 0:e.options.dataInterceptor,r={type:$.Translations,data:Ut({items:t}),instance:this.instance};if(n){var i;let e=await n(r);return e.type===`Translations`?(i=e.data)==null?void 0:i.items:t}return t}async loadPrmRelationship(e,t){var n;return await Nl.relationships({prmQuery:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,relationships:this.relationshipSettings(t),search:e}},{client:this.client})}async loadPrmRelationshipAutocomplete(e,t){var n;return await Nl.relationshipAutocomplete({prmAutocompleteQuery:{appSettings:(n=this.instance.store)==null?void 0:n.options.appSettings,relationships:this.relationshipSettings(t),search:e}},{client:this.client})}async loadPrmRelationshipFilterValues(e){var t;return await Nl.relationshipFilterValues({prmFilterValueQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,relationships:this.relationshipSettings(),search:e}},{client:this.client})}async autocomplete(e,t){var n,r;let{action:i,source:a,trigger:o=`ui`}=Ac(this.instance)??{};this.autocompleteController&&this.autocompleteController.abort(),this.autocompleteController=new AbortController;let{cid:s,searchType:c,partsType:l,filters:u}=this.instance.router.routeData.search??{},d=(n=this.instance.store.options.components)==null||(n=n.search)==null?void 0:n.form,f={appSettings:(r=this.instance.store)==null?void 0:r.options.appSettings,variants:this.searchVariants(),pager:{page:1,pageSize:5},search:{cid:t?void 0:s,searchType:t?ru.HIERARCHICAL:c,searchText:e??void 0,filter:u,partType:l},autoCategoryNavigation:d==null?void 0:d.autoCategoryNavigation,fetchProductImages:d==null?void 0:d.showProductImages,fetchCategoryImages:t?!0:d==null?void 0:d.showCategoryImages,categorySearch:t?!0:d==null?void 0:d.categorySearch,categoryKeywordSearch:t?!0:d==null?void 0:d.categoryKeywordSearch},p=JSON.stringify(f);if(this.autocompleteCache[p])return Promise.resolve(this.autocompleteCache[p]);let m=Date.now(),h;try{h=await Nl.autocomplete({autocompleteQuery:f},{client:this.client,signal:this.autocompleteController.signal})}catch(t){throw Pc(t)||Mc(this.instance,{kind:`autocomplete`,action:`autocomplete`,trigger:o,...i?{origin:i}:{},...a?{source:a}:{},args:{searchText:e},outcome:{status:`error`,durationMs:Date.now()-m}}),t}return this.autocompleteCache[p]=h,Mc(this.instance,{kind:`autocomplete`,action:`autocomplete`,trigger:o,...i?{origin:i}:{},...a?{source:a}:{},args:{searchText:e},outcome:Nc(h.totalCount,h.items,Date.now()-m)}),h}async loadFiltersResultCount(e){var t;let{cid:n,searchType:r,searchText:i,partsType:a}=this.instance.router.routeData.search??{},o={appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,variants:this.searchVariants(),search:{cid:n,searchType:r,searchText:i,filter:e,partType:a}},s=JSON.stringify(o);if(this._lastFilterLoad.key==s)return Promise.resolve({totalCount:this._lastFilterLoad.count});let c;if(this.instance.store.options.httpInterceptor)try{c=await this.instance.store.options.httpInterceptor({body:o,url:Az.count,method:`post`})}catch{}try{let e=c??await Nl.count({countQuery:o},{client:this.client});return this._lastFilterLoad.key=s,this._lastFilterLoad.count=e.totalCount,e}catch{return Promise.resolve({totalCount:0})}}async loadFavoriteViews(e){try{var t;let n=await jl.favoriteViewsLoad({favoriteViewsQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,search:{ids:e}}},{client:this.client}),r=n.items?n.items:[];return this.storeService.setData($.FavoriteViews,{items:r}),r}catch(e){return this.instance.logger.log(`Failed to fetch favorite views`,e),[]}}async saveFavoriteView(e,t,n){try{var r,i,a,o,s,c,l,u,d,f,p;let g=await jl.favoriteViewsSave({favoriteViewSaveQuery:{appSettings:(r=this.instance.store)==null?void 0:r.options.appSettings,favoriteView:{id:e,code:t,data:{treeType:ou.PRODUCTS,pager:{page:(n==null||(i=n.search)==null||(i=i.pagination)==null?void 0:i.page)??1,pageSize:(n==null||(a=n.search)==null||(a=a.pagination)==null?void 0:a.pageSize)??12},search:{cid:(o=n.search)==null?void 0:o.cid,partType:(s=n.search)==null?void 0:s.partsType,searchType:(c=n.search)==null?void 0:c.searchType,searchText:((l=n.search)==null?void 0:l.searchText)??void 0,filter:(u=n.search)==null?void 0:u.filters,masterProductId:((d=n.search)==null?void 0:d.masterProductId)??void 0},sort:{field:((f=n.search)==null?void 0:f.sortField)??au.PRODUCT,direction:((p=n.search)==null?void 0:p.sortDirection)??iu.ASCENDING}}}}},{client:this.client});if(g.id){var m;let e=(((m=this.instance.store)==null||(m=m.data.favoriteViews)==null?void 0:m.items)||[]).find(e=>e.id===g.id);if(e)Object.assign(e,g);else{var h;this.storeService.setData($.FavoriteViews,{items:[...((h=this.instance.store)==null||(h=h.data.favoriteViews)==null?void 0:h.items)||[],g]})}return g}}catch(e){this.instance.logger.log(`Failed to fetch favorite views`,e)}}async deleteFavoriteView(e){try{var t;if(await jl.favoriteViewsDelete({favoriteViewDeleteQuery:{appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings,favoriteView:{id:e}}},{client:this.client})){var n;return this.storeService.setData($.FavoriteViews,{items:(((n=this.instance.store)==null||(n=n.data.favoriteViews)==null?void 0:n.items)??[]).filter(t=>t.id!==e)}),e}}catch(e){this.instance.logger.log(`Failed to delete favorite view`,e)}}async generatePDFUrl(e){this.instance.store.data.isLoadingData=!0;try{var t;let n=await Nl.pdfGenerate({pdfQuery:{search:{productId:e},appSettings:(t=this.instance.store)==null?void 0:t.options.appSettings}},{client:this.client});if(n&&n.guid)return this.instance.store.data.isLoadingData=!1,`${this.instance.getOptions().baseUrl}/v2/Products/Pdf/Download?guid=${n.guid}`}catch(e){this.instance.logger.log(`Failed to print product to pdf`,e)}this.instance.store.data.isLoadingData=!1}async getCatalogOptions(){var e,t;return Tl.catalogsOptions({catalogOptionsQuery:{appSettings:{appCode:(e=this.instance.store)==null||(e=e.options.appSettings)==null?void 0:e.appCode,langCode:(t=this.instance.store)==null||(t=t.options.appSettings)==null?void 0:t.langCode}}},{client:this.client})}async getAllCatalogs(){var e,t;return Tl.catalogsSearch({catalogSearchQuery:{appSettings:{appCode:(e=this.instance.store)==null||(e=e.options.appSettings)==null?void 0:e.appCode,langCode:(t=this.instance.store)==null||(t=t.options.appSettings)==null?void 0:t.langCode},pager:{page:1,pageSize:1e3}}},{client:this.client})}async addCatalog(e,t,n){var r,i;return Tl.catalogsAdd({catalogAddAction:{appSettings:{appCode:(r=this.instance.store)==null||(r=r.options.appSettings)==null?void 0:r.appCode,langCode:(i=this.instance.store)==null||(i=i.options.appSettings)==null?void 0:i.langCode},code:e,type:t,description:n}},{client:this.client})}async addProductToCatalog(e,t){var n,r;return Ol.catalogsProductsAdd({catalogProductAddAction:{appSettings:{appCode:(n=this.instance.store)==null||(n=n.options.appSettings)==null?void 0:n.appCode,langCode:(r=this.instance.store)==null||(r=r.options.appSettings)==null?void 0:r.langCode},catalogId:e,products:t}},{client:this.client})}},Fz=class{constructor(e){Z(this,`instance`,void 0),Z(this,`routeData`,Ut(Ic(lp))),Z(this,`history`,[]),this.instance=e}async setRoute(e,t=!1){let n=Ic(this.routeData);if(e){var r;if((r=e.search)!=null&&r.pagination){var i;lf(e.search.pagination,(i=this.routeData)==null||(i=i.search)==null?void 0:i.pagination)}Rc(n,e),uf(n,lp)}if(this.history.length>0&&Bc(n,Ic(this.routeData)))return;let a=!1;if(!t&&this.history.length>1&&n.view==`search`){let e=this.history[this.history.length-1];a=Bc(e,n,e=>e===`subView`)}if(a){this.commitRoute(n);return}let o=!1;if(!t&&this.history.length>1&&n.view==`search`){let e=this.history[this.history.length-1];o=Bc(e,n,e=>e===`page`||e===`pageSize`)}let s=Ic(this.routeData);if(Rc(s,n),this.instance.props.nextRoute=s,this.instance.store.data.isInitialized&&this.instance.httpService){if(t)return this.commitRoute(n);if(o)return await this.instance.httpService.paginate(n),this.commitRoute(n);var c;return await((c=this.instance.httpService)==null?void 0:c.load(n)),this.commitRoute(n)}return this.commitRoute(n)}commitRoute(e){this.instance.props.nextRoute=null,this.history.push({...e}),this.merge(e);let t=Ic(this.routeData);setTimeout(()=>this.instance.eventBus.emit(`route-changed`,t),10)}merge(e){Rc(this.routeData,e)}async reload(){var e,t;(e=this.routeData)!=null&&(e=e.search)!=null&&e.pagination&&(this.routeData.search.pagination.page=1),await((t=this.instance.httpService)==null?void 0:t.load(this.routeData))}async back(e=1){let t=this.history.length-e-1,n=this.history[t];return n&&this.history.splice(t),this.setRoute(n??lp)}},Iz=class{constructor(e,t){Z(this,`id`,void 0),Z(this,`accessor`,void 0),Z(this,`helpers`,void 0),Z(this,`instanceType`,`Products`),Z(this,`props`,{}),Z(this,`httpService`,void 0),Z(this,`store`,Ut({notifications:[],data:{isInitialized:!1,actions:{data:null,current:null}},options:{isInitialized:!1}})),Z(this,`router`,new Fz(this)),Z(this,`translations`,new yf(this)),Z(this,`commandExecutor`,new fm(this)),Z(this,`logger`,Gd),Z(this,`registeredComponents`,Ut(new Set)),Z(this,`dataTypesRequired`,Ut(new Set)),Z(this,`eventBus`,Vs()),Z(this,`eventBusExt`,_f(this.eventBus)),Z(this,`selection`,new vf(this)),this.id=e,this.accessor=t,this.helpers=kz(this)}isInitialized(){return this.store.data.isInitialized}async reload(){await this.translations.load(),await this.router.reload()}setRoute(e){this.router.setRoute(e)}async init(e,t){if(this.store.data.isInitialized)throw Error(`Instance "${this.id}" is already initialized`);Af(`products`,e),jf(e);let n=xf(e==null?void 0:e.baseUrl),r=this.store.options.isInitialized?this.store.options:new Oz;hf(r,e),t&&this.router.merge(t),this.store.options=r,this.store.options.isInitialized=!0,this.httpService=new Pz(this,n,r.accessToken),this.store.data.isInitialized=!0,this.router.setRoute(t);try{return await this.translations.load(),Promise.resolve()}catch(e){this.store.data.isInitialized=!1;let t=Hc(r.errorInterceptor,{type:`InitError`,message:`PIS initialization error.`,isHandled:!1});return console.error(`[PIS] initialization error`,t,e),Promise.reject(Error(`PIS initialization error`,{cause:e}))}}update(e,t){Af(`products`,e),jf(e);let n=this.store.options.isInitialized?this.store.options:new Oz;hf(n,e),this.store.options=n,this.store.options.isInitialized=!0,t&&this.router.setRoute(t)}on(e,t){this.eventBusExt.on(e,t)}onReady(e){let t=I(()=>this.store.data,({isInitialized:n})=>{n&&(e(),t())},{deep:!0})}off(e,t){e?this.eventBusExt.off(e,t):this.eventBusExt.all.clear()}registerComponent(e){this.registeredComponents.add(e)}registerRequiredDataTypes(e){e.forEach(e=>this.dataTypesRequired.add(e))}getRegisteredSearchDataTypes(){if(this.dataTypesRequired&&this.dataTypesRequired.size){var e,t;let n=Object.values(nu),r=Array.from(this.dataTypesRequired).filter(e=>n.includes(e));return(e=this.store.options.components)!=null&&(e=e.search)!=null&&(e=e.common)!=null&&(e=e.configurators)!=null&&e.visible&&r.push(nu.CONFIGURATORS),((t=this.store.options.appSettings)==null?void 0:t.treeType)==ou.PARTS&&r.push(nu.MASTER_PRODUCTS),[...new Set(r)]}return[]}getRegisteredDetailsDataTypes(){if(this.dataTypesRequired&&this.dataTypesRequired.size){var e,t,n,r;let i=Object.values(Yl),a=Array.from(this.dataTypesRequired).filter(e=>i.includes(e));return a.push(Yl.EXTENDED_OBJECT_DATA),(e=this.store.options.components)!=null&&(e=e.details)!=null&&(e=e.variantsSelector)!=null&&e.visible&&a.push(Yl.PRODUCT_VARIANTS_SELECTOR),(t=this.store.options.components)!=null&&(t=t.details)!=null&&(t=t.variantsDropdown)!=null&&t.visible&&a.push(Yl.PRODUCT_VARIANTS_DROPDOWN),(n=this.store.options.components)!=null&&(n=n.details)!=null&&(n=n.variantsTable)!=null&&n.visible&&a.push(Yl.PRODUCT_VARIANTS_TABLE),(r=this.store.options.components)!=null&&(r=r.details)!=null&&(r=r.relatedLinks)!=null&&r.visible&&a.push(Yl.RELATED_LINKS),[...new Set(a)]}return[]}destroy(){return this.accessor.destroyInstance(this.id)}execute(e,t){return this.commandExecutor.execute(e,t)}executeCommand(e,...t){return this.commandExecutor.executeCommand(e,...t)}trackUserAction(e){jc(this,e)}getDefaultOptions(){return gf(new Oz)}getDefaultRouteData(){return Ic(lp)}getOptions(){return this.store.options}getRouteData(){return this.props.nextRoute?this.props.nextRoute:Ic(this.router.routeData)}},Lz=class{constructor(){Z(this,`instances`,Ut(new Map))}destroyInstance(e){try{var t;(t=this.instances.get(e))==null||t.off()}catch{}this.instances.delete(e)}getInstance(e){let t=this.instances.size;if(e!==void 0){if(this.instances.has(e))return this.instances.get(e);{let t=new Iz(e,this);return this.instances.set(e,t),t}}if(t===1)return this.instances.values().next().value;if(t>1)throw Error(`[PIS Products] Cannot pick default instance if more than one exists`)}setAccessTokenInAllInstances(e){this.instances.forEach(t=>{t.getOptions().accessToken=e})}},Rz=L({components:{Btn:Iy,Modal:Qy,FormInputClearable:Mb,FormTextAreaClearable:CM},props:{t:{type:Function,required:!0},instanceId:{type:String,default:void 0},data:{type:Object,required:!0}},emits:[`update:show`],setup(e,{emit:t}){let n=`PIS:Products:AddToCatalogModal:LastCatalogCode`,r=Pf.Products.getInstance(e.instanceId),i=Wl,a=M(!1),o=M(null),s=M(``),c=M(``),l=M(``),u=M(`0`),d=M(``),f=M(!0),p=M(e.data.catalogType),m=M([]),h=M([]),g=M(!0),_=M(e.data.catalogType),v=e=>s.value=e,y=e=>c.value=e,b=e=>l.value=e,x=e=>u.value=e,S=e=>d.value=e,C=e=>p.value=e,w=()=>t(`update:show`,!1),T=async()=>{try{let t;if(o.value!==null){let n=m.value.find(e=>e&&e.code===o.value);if(!n)throw Error(e.t(`CannotFindCatalog`));t=n.id}else t=await r.execute(new um({code:s.value,type:e.data.catalogType,description:c.value,onSuccessMessage:e.t(`CatalogCreateNewSuccess`)}).from(`add-to-catalog-modal`));window.sessionStorage.setItem(n,t),await r.execute(new dm({products:[{productId:e.data.productId,description:l.value,productType:Vl.LISTED,quantity:parseInt(u.value,10),unitOfMeasure:d.value}],id:t,onSuccessMessage:e.t(`ProductAddedToCatalogSuccess`)}).from(`add-to-catalog-modal`))}catch(e){await r.execute(new $p({type:`danger`,message:e.message}).from(`add-to-catalog-modal`))}w()},E=Y(()=>(o.value!==null||!!s.value&&!!c.value&&!!p.value)&&!!u.value&&!!d.value&&!!l.value),D={code:{[mb.required]:{}},description:{[mb.required]:{}},productDescription:{[mb.required]:{}},unitOfMeasure:{[mb.required]:{}},quantity:{[mb.required]:{},[mb.min]:{min:0},[mb.max]:{max:1e6}}},ee=Y(()=>m.value.map(e=>e.code));return kr(async()=>{try{if(!e.data.productId)throw Error(e.t(`ProductIdIsRequired`));if(!e.data.catalogType)throw Error(e.t(`CatalogTypeIsRequired`));if(m.value=await r.execute(new lm().from(`add-to-catalog-modal`)),e.data.catalogType)g.value=!1,h.value=[{type:e.data.catalogType}];else{let e=await r.execute(new cm().from(`add-to-catalog-modal`));h.value=e.items||[]}e.data.uom&&(f.value=!1,d.value=e.data.uom);let t=e.data.catalogId||window.sessionStorage.getItem(n);if(t){let e=ee.value.find(e=>e===t);e&&(o.value=e)}a.value=!0}catch(e){await r.execute(new $p({type:`danger`,message:e.message}).from(`add-to-catalog-modal`))}}),{show:a,code:s,type:p,copyTo:o,instance:r,quantity:u,ownerType:_,validators:D,description:c,isFormValid:E,catalogType:i,unitOfMeasure:d,copyToOptions:ee,catalogOptions:h,productDescription:l,unitOfMeasureEditable:f,catalogOptionsEditable:g,close:w,onSave:T,onUOMUpdate:S,onCodeUpdate:v,onTypeUpdated:C,onQuantityUpdate:x,onDescriptionUpdate:y,onProductDescriptionUpdate:b}}}),zz={class:`d-block pt-2`},Bz={class:`form-label fw-bolder`},Vz={value:null},Hz=[`value`],Uz={class:`d-block pt-2`},Wz={class:`form-label fw-bolder`},Gz={class:`d-block pt-2`},Kz={class:`form-label fw-bolder`},qz={class:`form-check mt-3`},Jz={class:`form-check-label`},Yz=[`value`,`disabled`],Xz={class:`form-label fw-bolder`},Zz={class:`d-block pt-2`},Qz={class:`form-label fw-bolder`},$z={class:`d-block pt-2`},eB={class:`form-label fw-bolder`},tB=[`value`],nB={class:`d-block pt-2`},rB={class:`form-label fw-bolder`},iB={class:`d-flex justify-content-end mt-3`};function aB(e,t,n,r,i,a){let o=R(`FormInputClearable`),s=R(`FormTextAreaClearable`),c=R(`Btn`),l=R(`Modal`);return H(),W(l,{show:e.show,title:e.t(`AddProduct`),"close-on-outer-click":!1,"onUpdate:show":t[5]||(t[5]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`form`,{onSubmit:t[4]||(t[4]=X(()=>{},[`prevent`]))},[G(`label`,zz,[G(`div`,Bz,j(e.t(`AddProductTo`)),1),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.copyTo=t),class:`form-select`},[G(`option`,Vz,j(e.t(`CatalogAddNew`)),1),(H(!0),U(V,null,z(e.copyToOptions,e=>(H(),U(`option`,{key:e,value:e},j(e),9,Hz))),128))],512),[[Cs,e.copyTo]])]),F(G(`div`,null,[G(`label`,Uz,[G(`div`,Wz,j(e.t(`CatalogCode`)),1),K(o,{"model-value":e.code,validators:e.validators.code,"onUpdate:modelValue":e.onCodeUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),G(`label`,Gz,[G(`div`,Kz,j(e.t(`CatalogDescription`)),1),K(s,{"model-value":e.description,rows:3,validators:e.validators.description,"onUpdate:modelValue":e.onDescriptionUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),(H(!0),U(V,null,z(e.catalogOptions,n=>(H(),U(`div`,{key:n.type},[G(`div`,qz,[G(`label`,Jz,[F(G(`input`,{"onUpdate:modelValue":t[1]||(t[1]=t=>e.ownerType=t),name:`catalogType`,type:`radio`,class:`form-check-input`,value:n.type,disabled:!e.catalogOptionsEditable},null,8,Yz),[[Ss,e.ownerType]]),G(`div`,Xz,j(e.t(`${n.type}Catalog`)),1)])])]))),128))],512),[[Mo,e.copyTo===null]]),G(`label`,Zz,[G(`div`,Qz,j(e.t(`Quantity`)),1),K(o,{"model-value":e.quantity,validators:e.validators.quantity,type:`number`,"onUpdate:modelValue":e.onQuantityUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),G(`label`,$z,[G(`div`,eB,j(e.t(`UnitOfMeasure`)),1),e.unitOfMeasureEditable?(H(),W(o,{key:1,"model-value":e.unitOfMeasure,validators:e.validators.unitOfMeasure,"onUpdate:modelValue":e.onUOMUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])):(H(),U(`input`,{key:0,type:`text`,class:`form-control`,value:e.unitOfMeasure,disabled:``},null,8,tB))]),G(`label`,nB,[G(`div`,rB,j(e.t(`ProductDescription`)),1),K(s,{"model-value":e.productDescription,rows:3,validators:e.validators.productDescription,"onUpdate:modelValue":e.onProductDescriptionUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])]),t[6]||(t[6]=G(`hr`,null,null,-1)),G(`div`,iB,[K(c,{class:`mx-2`,onClick:t[2]||(t[2]=X(t=>e.close(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(c,{disabled:!e.isFormValid,primary:``,onClick:t[3]||(t[3]=X(t=>e.onSave(),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])],32)]),_:1},8,[`show`,`title`])}var oB=Q(Rz,[[`render`,aB]]),sB=L({components:{Modal:Qy},props:{instanceId:{type:String,default:void 0},t:{type:Function,required:!0},errors:{type:Array,required:!0},warnings:{type:Array,required:!0}},emits:[`update:show`],setup(e,{emit:t}){return{close:()=>t(`update:show`,!1)}}});function cB(e,t,n,r,i,a){let o=R(`Modal`);return H(),W(o,{show:!0,title:e.t(`Errors`),"close-on-outer-click":!1,"onUpdate:show":t[0]||(t[0]=t=>e.$emit(`update:show`))},{default:P(()=>[G(`ul`,null,[(H(!0),U(V,null,z(e.errors,e=>(H(),U(`li`,{key:e.id},j(e.message),1))),128)),(H(!0),U(V,null,z(e.warnings,e=>(H(),U(`li`,{key:e.id},j(e.message),1))),128))])]),_:1},8,[`title`])}var lB=Q(sB,[[`render`,cB]]),uB=_m({getInstance:e=>Pf.Products.getInstance(e),instanceTag:`pis-products-instance`,isReadyIncludesOptions:!0});function dB(e,t,n){return uB(e,t,n)}var fB=L({name:`pis-products-common-actions-modals`,components:{ProductActionErrors:lB,AddToCatalogModal:oB},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isReady:i,isWebComponent:a,store:o,t:s}=dB(t,e.instanceId),c=Y(()=>{var e;return(e=r.value)==null?void 0:e.store.data.actions});return{root:t,store:o,isReady:i,componentName:n,isWebComponent:a,currentActionName:Y(()=>{var e;return(e=c.value)==null?void 0:e.current}),currentActionData:Y(()=>{var e;return(e=c.value)==null?void 0:e.data}),t:s,onActionCompleted:async()=>{try{var e;(e=r.value)==null||e.execute(new am().from(n))}catch{}}}}}),pB={ref:`root`,class:`pis-component position-relative`};function mB(e,t,n,r,i,a){let o=R(`AddToCatalogModal`),s=R(`ProductActionErrors`);return H(),U(`div`,pB,[e.isReady?(H(),U(V,{key:0},[e.currentActionName===`ProductAddToCatalogAction`?(H(),W(o,{key:0,t:e.t,"instance-id":e.instanceId,data:e.currentActionData,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`data`,`onUpdate:show`])):e.currentActionName===`Errors`?(H(),W(s,{key:1,t:e.t,"instance-id":e.instanceId,errors:e.currentActionData.errors,warnings:e.currentActionData.warnings,"onUpdate:show":e.onActionCompleted},null,8,[`t`,`instance-id`,`errors`,`warnings`,`onUpdate:show`])):J(``,!0)],64)):J(``,!0)],512)}var hB=Q(fB,[[`render`,mB]]),gB=L({components:{Dropdown:pb,Clickable:wm},props:{cat:{type:Object,required:!0},selectedCid:{type:String,required:!1,default:void 0}},emits:[`select`],setup(){return{open:M(!1),getName:e=>{var t;let n=(t=e.breadcrumb)==null?void 0:t.map(e=>e.name);return n==null?void 0:n.join(` > `)}}}}),_B={class:`ms-1`};function vB(e,t,n,r,i,a){let o=R(`Clickable`),s=R(`Dropdown`);return e.cat.nested?(H(),W(s,{key:0,open:e.open,"onUpdate:open":t[1]||(t[1]=t=>e.open=t),items:e.cat.items,class:`d-inline-flex ext-cat-dropdown`},{activator:P(({on:n})=>[(H(),U(`div`,Oa({key:e.cat.cid,class:[`badge rounded-pill me-2 my-1 py-2 d-inline-flex align-items-center dropdown-toggle`,[e.selectedCid&&e.cat.cids.includes(e.selectedCid)?`bg-primary text-white`:`bg-light text-body pis-hover`]],style:{cursor:`pointer`},onClick:t[0]||(t[0]=X(t=>e.open=!e.open,[`prevent`]))},qr(n,!0)),[G(`div`,null,j(e.cat.name),1)],16))]),item:P(({item:t})=>[K(o,{class:A([`dropdown-item badge my-1 py-2 d-inline-flex align-items-center rounded-4 mx-2`,[e.selectedCid&&t.cids.includes(e.selectedCid)?`bg-primary text-white`:`bg-light text-body pis-hover`]]),style:{width:`360px`,"white-space":`break-spaces`,"line-height":`1rem`},onClick:n=>{e.open=!1,e.$emit(`select`,t.cid)}},{default:P(()=>[q(j(e.getName(t))+` (`+j(t.hitCount)+`) `,1)]),_:2},1032,[`class`,`onClick`])]),_:1},8,[`open`,`items`])):(H(),U(`div`,{key:e.cat.cid,class:A([`badge rounded-pill me-2 my-1 py-2 d-inline-flex`,[e.selectedCid&&e.cat.cids.includes(e.selectedCid)?`bg-primary text-white`:`bg-light text-body pis-hover`]]),style:{cursor:`pointer`},onClick:t[2]||(t[2]=X(t=>e.$emit(`select`,e.cat.cid),[`prevent`]))},[G(`div`,null,j(e.cat.name),1),G(`div`,_B,`(`+j(e.cat.hitCount)+`)`,1)],2))}var yB=Q(gB,[[`render`,vB]]),bB=L({components:{Modal:Qy,AttributeValueTable:HP,MountPoint:cg,Image:CO,Icon:$h,Tooltip:Fw},props:{instanceId:{type:String,default:void 0},visible:{type:Boolean,default:!1},items:{type:Object,required:!0},t:{type:Function,required:!0}},setup(e){let t=M(e.visible);I(()=>e.visible,e=>{t.value=e});let n=Y(()=>Pf.Products.getInstance(e.instanceId)),r=Y(()=>{var e;return((e=n.value.store.options.components)==null||(e=e.compare)==null?void 0:e.view)??{}}),i=async e=>{if(!(e!=null&&e.inactive)&&e)try{await n.value.execute(new bp(e).from(`compare-table-data`))}catch{}},a=Y(()=>{var e;return((e=n.value.store.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),o=(e,t)=>{n.value.eventBus.emit(e,t)};return{show:t,componentOptions:r,replacementsVisible:a,AttributeTypeEnum:Ll,instance:n,emit:o,attrValue:Us,attrValues:Ws,additionalInfo:Gs,details:i,imageOverlayCtx:hg(t=>({instance:n.value,item:t.item,emit:o,t:e.t})),titleCtx:hg(t=>({instance:n.value,item:t.item,emit:o,details:i,attrValue:Us,t:e.t})),itemCtx:hg(t=>({instance:n.value,item:t.item,emit:o,details:i,attrValue:Us,t:e.t})),actionCtx:hg(t=>({instance:n.value,item:t.item,emit:o,details:i,attrValue:Us,t:e.t}))}}}),xB={class:`card p-3 mb-4 bg-light`},SB={class:`row align-items-center`},CB={class:`text-center m-auto`},wB={class:`position-relative col d-flex justify-content-center align-items-top`},TB={key:0},EB={class:`col`},DB=[`onClick`],OB={key:5},kB={class:`col text-end`},AB={key:0};function jB(e,t,n,r,i,a){let o=R(`Image`),s=R(`MountPoint`),c=R(`Icon`),l=R(`Tooltip`),u=R(`AttributeValueTable`),d=R(`Modal`);return H(),W(d,{show:e.show,"onUpdate:show":t[0]||(t[0]=t=>e.show=t),title:e.t(`CompareTableData`),xl:``},{default:P(()=>[(H(!0),U(V,null,z(e.items,t=>(H(),U(`div`,{key:t.item.productId,class:`mb-4`},[G(`div`,xB,[G(`div`,SB,[G(`div`,{class:`col`,style:k({"max-width":e.componentOptions.imageSize})},[G(`div`,CB,[G(`div`,wB,[K(o,{style:k({"max-width":e.componentOptions.imageSize}),src:t.imageSrc,"is-loading":!1,clickable:!0,"hide-frame":!0,onClick:n=>e.details(t.item)},null,8,[`style`,`src`,`onClick`]),e.componentOptions.imageOverlayTemplate?(H(),U(`div`,TB,[K(s,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t.item})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])])],4),G(`div`,EB,[t.item.additionalInfo&&t.item.additionalInfo.length?(H(),W(l,{key:0,text:e.additionalInfo(t.item.additionalInfo)},{default:P(()=>[K(c,{class:`text-warning me-1`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0),e.componentOptions.titleTemplate?(H(),W(s,{key:1,callbacks:e.componentOptions.titleTemplate,ctx:e.titleCtx({item:t.item})},null,8,[`callbacks`,`ctx`])):(H(),U(`a`,{key:2,href:`#`,class:`fw-bold`,onClick:X(n=>e.details(t.item),[`prevent`])},j(e.attrValue(t.item,`#DisplayName`)),9,DB)),e.componentOptions.showAllIdentifiers?(H(!0),U(V,{key:3},z(e.attrValues(t.item,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`small text-muted fw-bold`},j(e),1))),128)):J(``,!0),e.componentOptions.itemTemplate?(H(),W(s,{key:4,callbacks:e.componentOptions.itemTemplate,ctx:e.itemCtx({item:t.item})},null,8,[`callbacks`,`ctx`])):(H(),U(`div`,OB,[G(`span`,null,j(e.attrValue(t.item,`CatalogDescription`)),1)]))]),G(`div`,kB,[e.componentOptions.actionTemplate?(H(),U(`div`,AB,[K(s,{callbacks:e.componentOptions.actionTemplate,ctx:e.actionCtx({item:t.item})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])])]),G(`div`,{class:A({small:e.componentOptions.compactMode})},[G(`div`,null,[G(`strong`,null,j(t.attr.attributeName)+`:`,1)]),K(u,{table:t.attr.table},null,8,[`table`])],2)]))),128))]),_:1},8,[`show`,`title`])}var MB=Q(bB,[[`render`,jB]]),NB={},PB=e=>{let t=e.id;if(!NB[t]){let n=Y(()=>[...e.router.history??[]].reverse()),r=Y(()=>n.value.findIndex(({view:e})=>e===`search`));NB[t]={historyReversed:n,lastSearchIndex:r,previousProductName:Y(()=>{if(r.value>1){var t,i;let r=(t=e.router.routeData.detail)==null?void 0:t.productId,o=(i=n.value.find(e=>{var t;return!(e.view!==`detail`||r&&((t=e.detail)==null?void 0:t.productId)===r)}))==null||(i=i.detail)==null?void 0:i.productId;if(o){var a;return(((a=e.store)==null?void 0:a.data.productIdToDisplayName)||{})[o]}}})}}return NB[t]},FB=L({components:{Btn:Iy,Arrow:qb,Tooltip:Fw},props:{instance:{type:Object,required:!0},t:{type:Function,required:!0}},setup(e){let{lastSearchIndex:t,previousProductName:n}=PB(e.instance);return{allowBack:Y(()=>{var t;return((t=e.instance)==null||(t=t.store)==null?void 0:t.data.itemNotFound)!==!0}),lastSearchIndex:t,previousProductName:n,navigateBack:async()=>{try{var t;await((t=e.instance)==null?void 0:t.execute(new Tp().from(`navigation-btns`)))}catch{}},navigateToSearch:async()=>{try{if(t.value>0){var n;await((n=e.instance)==null?void 0:n.execute(new Tp({step:t.value}).from(`navigation-btns`)))}else{var r;await((r=e.instance)==null?void 0:r.execute(new Ep().from(`navigation-btns`)))}}catch{}}}}}),IB={class:`text-nowrap pis-text-ellipsis`},LB={class:`text-nowrap pis-text-ellipsis`};function RB(e,t,n,r,i,a){let o=R(`Arrow`),s=R(`Btn`),c=R(`Tooltip`);return H(),U(V,null,[e.lastSearchIndex>1&&e.previousProductName?(H(),W(c,{key:0,text:e.previousProductName,placement:`bottom`,trigger:`hover focus`},{default:P(()=>[K(s,{class:`pis-mw-10-rem ext-prod-back`,onClick:X(e.navigateBack,[`prevent`])},{default:P(()=>[K(o,{dir:`left`,class:`me-1`}),G(`span`,IB,j(e.previousProductName??e.t(`PreviousProduct`,!0)),1)]),_:1},8,[`onClick`])]),_:1},8,[`text`])):J(``,!0),e.allowBack?(H(),W(s,{key:1,class:`pis-mw-10-rem ext-back`,onClick:X(e.navigateToSearch,[`prevent`])},{default:P(()=>[K(o,{dir:`left`,class:`me-1`}),G(`span`,LB,j(e.t(`BackToSearch`,!0)),1)]),_:1},8,[`onClick`])):J(``,!0)],64)}var zB=Q(FB,[[`render`,RB]]),BB=L({name:`PisReplacements`,components:{PisLink:YP,Icon:$h},props:{replacements:{type:Object,required:!0},instance:{type:Object,required:!0},showIcon:Boolean,isDetailView:Boolean,visible:Boolean},setup(e){let t=async t=>{if(e.isDetailView){let e=document.querySelector(`#pis-anchor-attr-TechnicalInformation`);e&&e.scrollIntoView({behavior:`smooth`})}else try{var n;await((n=e.instance)==null?void 0:n.execute(new bp({productId:t}).from(`pis-replacements`)))}catch{}};return{LinkTypeEnum:Ql,renderLink:e=>{var n;let r=(n=e.link)==null?void 0:n.text;if(!r)return Qa(`span`,e.label??``);let i=/{([^}]+)}/,a=[],o=r,s;for(;(s=i.exec(o))!==null;){let e=o.slice(0,s.index);e&&a.push(e);let n=s[1].split(`|`),r=n[0],i=n[1]??r;a.push(Qa(`a`,{href:`#`,onClick:e=>{e.preventDefault(),t(r)}},i)),o=o.slice(s.index+s[0].length)}return o&&a.push(o),a.length===0?Qa(`span`,e.label??``):Qa(`span`,a)},navigate:t}}}),VB={key:0,class:`pis-replacements`},HB={key:1,class:`fw-bold`},UB={class:`fw-bold`},WB={class:`fw-bold text-nowrap`};function GB(e,t,n,r,i,a){let o=R(`icon`),s=R(`PisLink`);return e.replacements&&e.replacements.length&&e.visible?(H(),U(`div`,VB,[(H(!0),U(V,null,z(e.replacements,(n,r)=>(H(),U(`div`,{key:r,class:A({"d-flex":e.showIcon})},[e.showIcon?(H(),W(o,{key:0,class:`text-muted me-2`,name:`information-circle`,lg:``})):J(``,!0),n.link&&n.link.type===e.LinkTypeEnum.TECHNICAL_INFORMATION?(H(),U(`span`,HB,[(H(),W(Vr(e.renderLink(n))))])):(H(),U(V,{key:2},[G(`span`,UB,j(n.label),1),t[0]||(t[0]=q(`\xA0 `,-1)),n.link?(H(),W(s,{key:0,instance:e.instance,link:n.link,"clear-search":!0},{default:P(()=>[G(`span`,WB,j(n.link.text),1)]),_:2},1032,[`instance`,`link`])):J(``,!0)],64))],2))),128))])):J(``,!0)}var KB=Q(BB,[[`render`,GB]]),qB=L({name:`pis-products-compare`,components:{InteractiveText:KP,PisLink:YP,Icon:$h,Tooltip:Fw,Image:CO,PisReplacements:KB,CompareTableData:MB,NavigationBtns:zB,LinkSecondary:kE,CategoryFilter:yB,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(),r=M(),i=M(!1),a=M([]),o=M(!1),s=M(!1),c=M(!0),l=M(),{instance:u,componentName:d,isReady:f,isWebComponent:p,store:m,routeData:h,t:g,emit:_}=dB(t,e.instanceId),v=()=>{if(n.value&&r.value){var e=n.value.scrollLeft??0;r.value.scrollLeft=e}},y=()=>{if(n.value&&r.value){var e=r.value.scrollLeft??0;n.value.scrollLeft=e}},b=!0,x=()=>{b=!1};rp(l,sp(([{isIntersecting:e}])=>{!b&&C.value.imageVisible&&C.value.imageHideOnScroll&&(c.value=e,b=!0)},300));let S=I(()=>f.value,e=>{if(e==1){var t;i.value=((t=h.value)==null||(t=t.compare)==null?void 0:t.differencesOnly)??!1,setTimeout(()=>{var e,t;(e=n.value)==null||e.addEventListener(`scroll`,v),(t=r.value)==null||t.addEventListener(`scroll`,y),document.addEventListener(`wheel`,x)},500),S()}});I(()=>i.value,e=>{re(e)}),I(()=>{var e;return(e=h.value)==null||(e=e.compare)==null?void 0:e.differencesOnly},e=>{e!==void 0&&e!=i.value&&(i.value=e),e===void 0&&(i.value=!1)}),Mr(()=>{var e,t;(e=n.value)==null||e.removeEventListener(`scroll`,v),(t=r.value)==null||t.removeEventListener(`scroll`,y),document.removeEventListener(`scroll`,x)});let C=Y(()=>{var e;return((e=m.value)==null||(e=e.options.components)==null||(e=e.compare)==null?void 0:e.view)??{}}),w=Y(()=>{var e;return((e=m.value)==null||(e=e.data.compareResult)==null?void 0:e.items)??[]}),T=Y(()=>{var e;if((e=m.value)!=null&&(e=e.data.compareResult)!=null&&e.classifications){var t;let e=[];return(t=m.value)==null||(t=t.data.compareResult)==null||t.classifications.forEach(t=>{if(t.cid==`ROOT`)e.push({cid:t.cid,cids:[t.cid],name:t.name,hitCount:t.hitCount,nested:!1,breadcrumb:t.breadcrumb});else{var n=e.find(e=>e.name==t.name);if(n){var r;n.hitCount+=1,n.cids.push(t.cid),(r=n.items)==null||r.push({cid:t.cid,cids:[t.cid],name:t.name,hitCount:t.hitCount,nested:!1,breadcrumb:t.breadcrumb}),n.nested=!0}else e.push({cid:t.cid,cids:[t.cid],name:t.name,hitCount:t.hitCount,nested:!1,items:[{cid:t.cid,cids:[t.cid],name:t.name,hitCount:t.hitCount,nested:!1,breadcrumb:t.breadcrumb}]})}}),e}return[]}),E=Y(()=>{var e;return((e=m.value)==null||(e=e.data)==null||(e=e.compareResult)==null||(e=e.items)==null?void 0:e.length)==0}),D=Y(()=>w.value.length?w.value[0].attributeGroups??[]:[]),ee=(e,t,n)=>{var r,i=(r=e.attributeGroups)==null?void 0:r.find(e=>e.code==t);return i?[i.attributes[n]]:[]},O=async e=>{if(!(e!=null&&e.inactive)&&h.value&&e)try{var t;await((t=u.value)==null?void 0:t.execute(new bp(e).from(d)))}catch{}},te=Y(()=>{var e;return((e=m.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),ne=async e=>{try{var t;await((t=u.value)==null?void 0:t.execute(new tm({cid:e}).from(d)))}catch{}},re=async e=>{try{var t;await((t=u.value)==null?void 0:t.execute(new tm({diffOnly:e}).from(d)))}catch{}};return{root:t,componentName:d,componentOptions:C,isReady:f,isWebComponent:p,store:m,instance:u,items:w,categories:T,groups:D,replacementsVisible:te,AttributeTypeEnum:Ll,topSection:n,bottomSection:r,selectedCid:Y(()=>{var e;return(e=h.value)!=null&&(e=e.compare)!=null&&(e=e.cids)!=null&&e.length?h.value.compare.cids[0]:`ROOT`}),differencesOnly:i,tableData:a,tableDataVisible:o,showMore:s,noItemsFound:E,hideDocumentLinks:Y(()=>{var e;return((e=m.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideDocumentLinks)==1}),imageVisible:c,visibilityTest:l,filterByCid:ne,t:g,getAttributes:ee,emit:_,attrValue:Us,attrValues:Ws,additionalInfo:Gs,details:O,compareTableData:(e,t)=>{var n=[];w.value.forEach(r=>{if(r.item&&r.attributeGroups){var i;let o=(i=r.attributeGroups)==null?void 0:i.find(t=>t.code==e);if(o){let e=o.attributes[t];if(e&&e.type==Ll.TABLE){var a;let t=(a=(r.item.images||[])[0])==null?void 0:a.thumbnailUrl;n.push({item:r.item,attr:e,imageSrc:t})}}}}),a.value=n,o.value=!1,jn(()=>{o.value=!0})},removeItem:async e=>{try{var t;await((t=u.value)==null?void 0:t.execute(new nm({item:e}).from(d)))}catch{}},print:async()=>{try{var e;await((e=u.value)==null?void 0:e.execute(new rm(t.value).from(d)))}catch{}},reactiveContext:lg,imageOverlayCtx:hg(e=>({instance:u.value,item:e.item,emit:_,t:g})),titleCtx:hg(e=>({instance:u.value,item:e.item,emit:_,details:O,attrValue:Us,t:g})),itemCtx:hg(e=>({instance:u.value,item:e.item,emit:_,details:O,attrValue:Us,t:g})),actionCtx:hg(e=>({instance:u.value,item:e.item,emit:_,details:O,attrValue:Us,t:g}))}}}),JB={key:0,class:`d-flex h-100 flex-column`},YB={class:`d-grid gap-3 d-md-flex justify-content-md-end align-items-center mb-4`},XB={class:`overflow-hidden text-nowrap`},ZB={key:0,class:`my-4 p-2 text-center bg-light`},QB={class:`bg-white`,style:{"z-index":`4`}},$B={key:0,class:`mb-3`},eV={class:`d-inline-block me-2`},tV={class:`sticky-top bg-white`,style:{"z-index":`3`}},nV={ref:`topSection`,class:`table-responsive pb-2`,style:{flex:`none`}},rV={class:`table table-sm mb-0 table-borderless table-first-col-sticky`,style:{height:`100%`}},iV={class:`h-100`},aV={class:`h-100`},oV={class:`bg-white`,style:{"vertical-align":`top`}},sV={key:1,class:`my-2`},cV={class:`form-check form-switch`},lV={class:`form-check-label`,for:`compareDifferencesOnly`},uV={class:`border border-1 border-bottom-0 rounded-top h-100 position-relative`},dV={class:`position-absolute top-0 start-100 translate-middle`},fV=[`onClick`],pV={class:`position-relative col d-flex justify-content-center align-items-top`},mV={key:0},hV={class:`text-center mt-2`},gV=[`onClick`],_V={key:0,class:`h-100`},vV={key:1,class:`h-100`},yV={class:`p-2`},bV={key:2,class:`h-100`},xV={class:`text-center border border-1 border-top-0 rounded-bottom h-100 py-3`},SV={key:0},CV={ref:`visibilityTest`},wV={class:`table table-sm table-first-col-sticky`},TV=[`colspan`],EV={class:`pis-heading mt-2 d-inline-block`,style:{position:`sticky`,left:`0`}},DV={key:0},OV={style:{"vertical-align":`top`}},kV={class:`d-flex`},AV={class:`w-100`},jV={class:`ps-lg-3`},MV=[`title`],NV={key:0,class:`flex-shrink-1 px-2`},PV={key:0,class:`text-center text-muted`},FV={key:1,class:`text-center text-muted`},IV={key:2,class:`text-center`},LV=[`onClick`],RV={key:2,class:`ext-compare-cell-content`,style:{overflow:`hidden`,"text-overflow":`ellipsis`,hyphens:`auto`}};function zV(e,t,n,r,i,a){var o;let s=R(`Icon`),c=R(`LinkSecondary`),l=R(`NavigationBtns`),u=R(`CategoryFilter`),d=R(`MountPoint`),f=R(`Image`),p=R(`Tooltip`),m=R(`PisReplacements`),h=R(`InteractiveText`),g=R(`PisLink`),_=R(`CompareTableData`),v=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,JB,[G(`div`,YB,[e.componentOptions.printButtonVisible?(H(),W(c,{key:0,class:`d-flex align-items-center ext-print-view small`,onClick:e.print},{default:P(()=>[K(s,{name:`printer`,class:`me-1`,size:24}),G(`span`,XB,j(e.t(`ShowPrintView`)),1)]),_:1},8,[`onClick`])):J(``,!0),e.componentOptions.navigationVisible?(H(),W(l,{key:1,instance:e.instance,t:e.t},null,8,[`instance`,`t`])):J(``,!0)]),e.noItemsFound?(H(),U(`div`,ZB,j(e.t(`CompareNoProductsSelected`)),1)):J(``,!0),G(`div`,QB,[e.componentOptions.categoriesVisible&&e.categories.length?(H(),U(`div`,$B,[G(`small`,eV,j(e.t(`Categories`,!0))+`:`,1),(H(!0),U(V,null,z(e.categories,t=>(H(),W(u,{key:t.cid,cat:t,"selected-cid":e.selectedCid,onSelect:e.filterByCid},null,8,[`cat`,`selected-cid`,`onSelect`]))),128))])):J(``,!0)]),G(`div`,tV,[G(`div`,nV,[G(`table`,rV,[G(`colgroup`,null,[G(`col`,{style:k({width:e.componentOptions.attrColWidth,"max-width":e.componentOptions.attrColWidth,"min-width":e.componentOptions.attrColWidth})},null,4),(H(!0),U(V,null,z(e.items,(t,n)=>(H(),U(`col`,{key:n,style:k({width:e.componentOptions.valColWidth,"max-width":e.componentOptions.valColWidth,"min-width":e.componentOptions.valColWidth})},null,4))),128))]),G(`tbody`,iV,[G(`tr`,aV,[G(`td`,oV,[e.componentOptions.headerTemplate&&e.items.length?(H(),W(d,{key:0,callbacks:e.componentOptions.headerTemplate,ctx:e.reactiveContext({instance:e.instance,selectedCid:e.selectedCid,categories:e.categories,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])):J(``,!0),e.items.length?(H(),U(`div`,sV,[G(`div`,cV,[F(G(`input`,{id:`compareDifferencesOnly`,"onUpdate:modelValue":t[0]||(t[0]=t=>e.differencesOnly=t),class:`form-check-input`,type:`checkbox`},null,512),[[bs,e.differencesOnly]]),G(`label`,lV,[G(`strong`,null,j(e.t(`CompareDifferencesOnly`)),1)])])])):J(``,!0)]),(H(!0),U(V,null,z(e.items.map(e=>e.item),(t,n)=>(H(),U(`td`,{key:n,style:{"vertical-align":`top`},class:`h-100 p-3 pt-3 pb-0`},[G(`div`,uV,[G(`div`,dV,[G(`a`,{href:``,class:`text-white bg-dark rounded-circle ext-compare-remove d-flex align-items-center justify-content-center`,style:{width:`1.2rem`,height:`1.2rem`},onClick:X(n=>e.removeItem(t),[`prevent`])},[K(s,{name:`cross-close`,size:16})],8,fV)]),K(mo,{name:`fade`},{default:P(()=>{var n;return[F(G(`div`,{class:`text-center m-auto py-4`,style:k({"max-width":e.componentOptions.imageSize})},[G(`div`,pV,[K(f,{style:k({"max-width":e.componentOptions.imageSize}),src:(n=(t.images||[])[0])==null?void 0:n.url,clickable:!0,"hide-frame":!0,"max-size-css":e.componentOptions.imageSize,onClick:n=>e.details(t)},null,8,[`style`,`src`,`max-size-css`,`onClick`]),e.componentOptions.imageOverlayTemplate?(H(),U(`div`,mV,[K(d,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])],4),[[Mo,e.componentOptions.imageVisible&&e.imageVisible]])]}),_:2},1024),G(`div`,hV,[t.additionalInfo&&t.additionalInfo.length?(H(),W(p,{key:0,text:e.additionalInfo(t.additionalInfo)},{default:P(()=>[K(s,{class:`text-warning me-1`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0),e.componentOptions.titleTemplate?(H(),W(d,{key:1,callbacks:e.componentOptions.titleTemplate,ctx:e.titleCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(`a`,{key:2,href:`#`,class:`fw-bold`,onClick:X(n=>e.details(t),[`prevent`])},j(e.attrValue(t,`#DisplayName`)),9,gV)),e.componentOptions.showAllIdentifiers?(H(!0),U(V,{key:3},z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`text-muted fw-bold`},j(e),1))),128)):J(``,!0),t.replacements&&t.replacements.length&&e.componentOptions.showReplacements?(H(),W(m,{key:4,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0)])])]))),128))]),e.componentOptions.itemTemplate?(H(),U(`tr`,_V,[t[2]||(t[2]=G(`td`,{class:`bg-white`},null,-1)),(H(!0),U(V,null,z(e.items.map(e=>e.item),(t,n)=>(H(),U(`td`,{key:n,style:{"vertical-align":`top`},class:`h-100 px-3 py-0`},[G(`div`,{class:A([`text-center border border-1 border-top-0 h-100`,[e.componentOptions.actionTemplate?`border-bottom-0 pb-0`:`rounded-bottom pb-2`]])},[G(`div`,null,[K(d,{callbacks:e.componentOptions.itemTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])])],2)]))),128))])):(H(),U(`tr`,vV,[t[3]||(t[3]=G(`td`,{class:`bg-white`},null,-1)),(H(!0),U(V,null,z(e.items.map(e=>e.item),(t,n)=>(H(),U(`td`,{key:n,style:{"vertical-align":`top`},class:`h-100 px-3 py-0`},[G(`div`,{class:A([`text-center border border-1 border-top-0 rounded-bottom h-100`,[e.componentOptions.actionTemplate?`border-bottom-0 pb-0`:`rounded-bottom pb-2`]])},[G(`div`,yV,j(e.attrValue(t,`CatalogDescription`)),1)],2)]))),128))])),e.componentOptions.actionTemplate?(H(),U(`tr`,bV,[t[4]||(t[4]=G(`td`,{class:`bg-white`},null,-1)),(H(!0),U(V,null,z(e.items.map(e=>e.item),(t,n)=>(H(),U(`td`,{key:n,style:{"vertical-align":`top`},class:`h-100 p-3 pt-0`},[G(`div`,xV,[t.inactive?J(``,!0):(H(),U(`div`,SV,[K(d,{callbacks:e.componentOptions.actionTemplate,ctx:e.actionCtx({item:t})},null,8,[`callbacks`,`ctx`])]))])]))),128))])):J(``,!0)])])],512)]),G(`div`,CV,null,512),G(`div`,{ref:`bottomSection`,class:A([`table-responsive`,{small:e.componentOptions.compactMode}])},[G(`table`,wV,[G(`colgroup`,null,[G(`col`,{style:k({width:e.componentOptions.attrColWidth,"max-width":e.componentOptions.attrColWidth,"min-width":e.componentOptions.attrColWidth})},null,4),(H(!0),U(V,null,z(e.items,(t,n)=>(H(),U(`col`,{key:n,style:k({width:e.componentOptions.valColWidth,"max-width":e.componentOptions.valColWidth,"min-width":e.componentOptions.valColWidth})},null,4))),128))]),(H(!0),U(V,null,z(e.groups,n=>(H(),U(`tbody`,{key:n.code},[G(`tr`,null,[G(`td`,{colspan:e.items.length+1,class:`disable-sticky ps-0`},[G(`h4`,EV,j(n.description),1),n.code==`AdditionalFields`?(H(),U(`div`,DV,[G(`a`,{href:``,onClick:t[1]||(t[1]=X(t=>e.showMore=!e.showMore,[`prevent`]))},j(e.showMore?e.t(`HideMore`):e.t(`ShowMore`)),1)])):J(``,!0)],8,TV)]),n.code!=`AdditionalFields`||n.code==`AdditionalFields`&&e.showMore?(H(!0),U(V,{key:0},z(n.attributes,r=>(H(),U(`tr`,{key:r.attributeCode},[G(`td`,OV,[G(`div`,kV,[G(`div`,AV,[G(`div`,jV,[F(G(`span`,{class:`d-inline-block w-100 text-wrap fw-bold`,style:{overflow:`hidden`,"text-overflow":`ellipsis`},title:r.tooltip},null,8,MV),[[v,r.attributeName+`:`]])])]),r.internal?(H(),U(`div`,NV,[K(p,{text:e.t(`Internal`,!0)},{default:P(()=>[K(s,{class:`text-warning text-end`,name:`warning-triangle`})]),_:1},8,[`text`])])):J(``,!0)])]),(H(!0),U(V,null,z(e.items,(i,a)=>(H(),U(`td`,{key:a,style:{"vertical-align":`top`,"max-width":`0`},class:`ext-compare-cell`},[(H(!0),U(V,null,z(e.getAttributes(i,n.code,r.attributeCode),(i,a)=>(H(),U(`div`,{key:a,class:`px-2 ext-compare-cell-wrapper`},[i.type==e.AttributeTypeEnum.NOT_APPLICABLE?(H(),U(`div`,PV,[...t[5]||(t[5]=[G(`strong`,null,`N/A`,-1)])])):i.type==e.AttributeTypeEnum.POPULATED?(H(),U(`div`,FV,[...t[6]||(t[6]=[G(`strong`,null,`Y`,-1)])])):i.type==e.AttributeTypeEnum.TABLE?(H(),U(`div`,IV,[G(`a`,{href:``,onClick:X(t=>e.compareTableData(n.code,r.attributeCode),[`prevent`])},j(e.t(`CompareTableData`)),9,LV)])):(H(!0),U(V,{key:3},z(i.values,(t,n)=>(H(),U(`div`,{key:n,class:`text-center`},[t.interactiveText?(H(),W(h,{key:0,instance:e.instance,text:t.interactiveText},null,8,[`instance`,`text`])):t.link&&!e.hideDocumentLinks?(H(),W(g,{key:1,link:t.link,instance:e.instance,"clear-search":!0},{default:P(()=>[q(j(t.link.text),1)]),_:2},1032,[`link`,`instance`])):F((H(),U(`div`,RV,null,512)),[[v,t.text]])]))),128))]))),128))]))),128))]))),128)):J(``,!0)]))),128))])],2)])):J(``,!0),K(_,{"instance-id":(o=e.instance)==null?void 0:o.id,t:e.t,items:e.tableData,visible:e.tableDataVisible},null,8,[`instance-id`,`t`,`items`,`visible`])],2)}var BV=Q(qB,[[`render`,zV]]),VV=L({name:`PrmListSearchForm`,components:{FormInputClearable:Mb,Dropdown:pb,Btn:Iy,Clickable:wm,Spinner:My,Highlighter:sb},props:{instance:{type:Object,required:!0},productId:{type:String,required:!0},relationshipType:{type:String,required:!0},relationshipCode:{type:String,required:!1,default:void 0},filterCriteria:{type:Object,required:!0},t:{type:Function,required:!0},modelValue:{type:String,default:``}},emits:[`update:modelValue`,`search`,`clear`],setup(e,{emit:t}){let n=M(e.modelValue),r=M(!1),i=M(!1),a=M({totalCount:0,itemsCount:0,items:[]}),o=(e,t)=>{if(e.attributes){let n=e.attributes[t];if(n&&n.values)return n.values[0].text}},s=e=>{if(e.attributes){let t=e.attributes[`#AllIdentifiers`];if(t&&t.values)return t.values.map(e=>e.text).join(`, `)}},c=sp(async t=>{let n=t!=null&&t.length>2;if(r.value=n,n){i.value=!0;try{var c;let n=new Bp({search:{productId:e.productId,searchText:t,relationshipType:e.relationshipType,relationshipCode:e.relationshipCode,filter:e.filterCriteria},pager:{page:1,pageSize:5}}),r=await((c=e.instance)==null?void 0:c.execute(n));if(r){var l;let e=(r.items||[]).map(e=>({text:o(e,`#DisplayName`)||e.productId||``,secondaryText:s(e)||``,description:o(e,`CatalogDescription`)||``}));a.value={totalCount:r.totalCount||0,itemsCount:((l=r.items)==null?void 0:l.length)||0,items:e}}else a.value={totalCount:0,itemsCount:0,items:[]}}catch{}i.value=!1}else a.value={totalCount:0,itemsCount:0,items:[]}},300),l=sp(()=>{t(`update:modelValue`,n.value),c(n.value),n.value||t(`search`,``)},300);return{searchText:n,isAutocompleteVisible:r,isAutocompleteLoading:i,autocomplete:a,highlightTerms:Y(()=>{if(!n.value)return[];let e=n.value.trim().toLowerCase().split(/[._-\s/]+/);return e.push(n.value.trim()),e}),onSearchInput:l,onEnter:()=>{r.value=!1,t(`update:modelValue`,n.value),t(`search`,n.value)},onClear:()=>{n.value=``,a.value={totalCount:0,itemsCount:0,items:[]},t(`update:modelValue`,``),t(`clear`)},selectItem:e=>{n.value=e,r.value=!1,t(`update:modelValue`,e),t(`search`,e)},openAutocomplete:()=>{n.value&&n.value.length>2&&(r.value=!0,c(n.value))}}}}),HV={class:`d-flex align-items-center`},UV={class:`fw-bold ext-display-name`},WV={key:0,class:`small ext-all-identifiers text-wrap`},GV={key:1,class:`small ext-description text-wrap`},KV={key:0,class:`text-center`},qV={key:1},JV={key:2};function YV(e,t,n,r,i,a){let o=R(`Highlighter`),s=R(`Clickable`),c=R(`Spinner`),l=R(`FormInputClearable`),u=R(`Btn`),d=R(`Dropdown`);return H(),W(d,{open:e.isAutocompleteVisible,"onUpdate:open":t[2]||(t[2]=t=>e.isAutocompleteVisible=t),"min-width":`300px`,items:e.autocomplete.items},{item:P(({item:t})=>[K(s,{class:`dropdown-item mb-1`,onClick:n=>e.selectItem(t.text)},{default:P(()=>[G(`div`,HV,[G(`div`,null,[G(`div`,UV,[K(o,{"highlight-class-name":`text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":t.text||``},null,8,[`search-words`,`text-to-highlight`])]),t.text!=t.secondaryText&&t.secondaryText?(H(),U(`div`,WV,[K(o,{"highlight-class-name":`fw-bold text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":t.secondaryText},null,8,[`search-words`,`text-to-highlight`])])):J(``,!0),t.description?(H(),U(`div`,GV,[K(o,{"highlight-class-name":`fw-bold text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":e.highlightTerms,"auto-escape":!0,"text-to-highlight":t.description},null,8,[`search-words`,`text-to-highlight`])])):J(``,!0)])])]),_:2},1032,[`onClick`])]),footer:P(()=>[e.isAutocompleteLoading?(H(),U(`div`,KV,[K(c,{sm:``})])):e.autocomplete.totalCount?(H(),U(`small`,qV,j(e.t(`ShowingNOfNMatches`,!1,[`${e.autocomplete.itemsCount}`,`${e.autocomplete.totalCount}`])),1)):e.searchText&&e.searchText.length>2?(H(),U(`small`,JV,j(e.t(`NoResults`)),1)):J(``,!0)]),activator:P(({on:n})=>[G(`form`,{class:`input-group flex-nowrap`,onSubmit:t[1]||(t[1]=X((...t)=>e.onEnter&&e.onEnter(...t),[`prevent`]))},[K(l,Oa({modelValue:e.searchText,"onUpdate:modelValue":t[0]||(t[0]=t=>e.searchText=t),modelModifiers:{trim:!0},"class-inner":`border-end-0`,placeholder:e.t(`SearchProductsInputPlaceholder`)},qr(n),{"onUpdate:modelValue":e.onSearchInput,onKeyup:Ns(e.onEnter,[`enter`]),onClear:e.onClear,onFocus:e.openAutocomplete}),null,16,[`modelValue`,`placeholder`,`onUpdate:modelValue`,`onKeyup`,`onClear`,`onFocus`]),K(u,{"aria-label":e.t(`SearchProductsInputAriaLabel`),icon:`lens-search-find`},{default:P(()=>[G(`span`,null,j(e.t(`SearchButtonText`)),1)]),_:1},8,[`aria-label`])],32)]),_:1},8,[`open`,`items`])}var XV=Q(VV,[[`render`,YV]]),ZV=L({name:`PrmSearchList`,components:{Icon:$h,PisReplacements:KB,Tooltip:Fw,MountPoint:cg,Clickable:wm,Image:CO},props:{products:{type:Array,required:!0},instance:{type:Object,required:!0},t:{type:Function,required:!0},emit:{type:Function,required:!0}},setup(e){let t=M(),n=Y(()=>{var t;return(t=e.instance)==null?void 0:t.store}),r=Y(()=>e.products),i=Y(()=>{var e;return((e=n.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.list)??{}}),a=Y(()=>{var t;return((t=e.instance)==null?void 0:t.registeredComponents.has(`pis-products-preview`))??!1}),o=Y(()=>{var e;return((e=n.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),s=e=>i.value.actionTemplate&&(i.value.showActionTemplateIfInactive||!(e!=null&&e.inactive)),c=async t=>{try{var n;await((n=e.instance)==null?void 0:n.execute(new xp({productId:t.productId}).from(`prm-search-list`)))}catch{}},l=async t=>{if(!(t!=null&&t.inactive)&&t)try{var n;await((n=e.instance)==null?void 0:n.execute(new bp(t).from(`prm-search-list`)))}catch{}};return{root:t,componentOptions:i,productsItems:r,previewEnabled:a,replacementsVisible:o,showActionTemplate:s,attrValue:Us,attrValues:Ws,details:l,preview:c,additionalInfoText:Gs,variantsAvailableInfo:Ks,imageOverlayCtx:hg(t=>({instance:e.instance,item:t.item,emit:e.emit,t:e.t})),itemCtx:hg(t=>({instance:e.instance,item:t.item,emit:e.emit,details:l,attrValue:Us,t:e.t}))}}}),QV={key:0},$V={class:`row align-items-center`},eH={key:1,class:`position-absolute p-2 top-50 start-0 ext-select-checkbox`,style:{"z-index":`1`,width:`auto`,"margin-top":`-1rem`}},tH=[`checked`,`onClick`],nH={class:`position-relative col d-flex justify-content-center align-items-center card`},rH={key:0},iH={class:`col`},aH={key:0,class:`text-muted`},oH=[`onClick`],sH={key:5},cH={key:7,class:`d-flex align-items-center fw-bold mt-1`};function lH(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`Image`),l=R(`MountPoint`),u=R(`Tooltip`),d=R(`PisReplacements`),f=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,`pis-prm-search-list`])},[e.productsItems&&e.productsItems.length?(H(),U(`div`,QV,[(H(!0),U(V,null,z(e.productsItems,t=>{var n,r,i;return H(),U(`div`,{key:t.productId,class:A([`card mb-3 p-3`,{"bg-light":t.exactMatch,"ext-selected":(n=e.instance)==null?void 0:n.selection.isSelected(t)}])},[G(`div`,$V,[e.previewEnabled?(H(),W(s,{key:0,class:`position-absolute p-2 top-0 start-0 d-flex ext-icon-preview`,style:{"z-index":`1`,width:`auto`},title:e.t(`Preview`,!0),disabled:t.inactive,onClick:n=>!t.inactive&&e.preview(t)},{default:P(()=>[K(o,{name:`eye-show`,size:24})]),_:1},8,[`title`,`disabled`,`onClick`])):J(``,!0),e.componentOptions.selectable?(H(),U(`div`,eH,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(r=e.instance)==null?void 0:r.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,tH)])):J(``,!0),G(`div`,{class:A([e.previewEnabled||e.componentOptions.selectable?`ms-4`:``,`col`]),style:k({"max-width":e.componentOptions.imageSize})},[G(`div`,nH,[K(c,{style:k({"max-width":e.componentOptions.imageSize}),src:(i=(t.images||[])[0])==null?void 0:i.url,clickable:e.componentOptions.navigateOnContentClick&&!t.inactive,"hide-frame":!0,padding:e.componentOptions.imagePadding,"lazy-loading":e.componentOptions.imageLazyLoading,onClick:n=>e.details(t)},null,8,[`style`,`src`,`clickable`,`padding`,`lazy-loading`,`onClick`]),e.componentOptions.imageOverlayTemplate?(H(),U(`div`,rH,[K(l,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])],6),G(`div`,iH,[t.additionalInfo&&t.additionalInfo.length?(H(),W(u,{key:0,text:e.additionalInfoText(t.additionalInfo)},{default:P(()=>[K(o,{class:`text-warning me-1`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0),e.componentOptions.titleTemplate?(H(),W(l,{key:1,callbacks:e.componentOptions.titleTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:2},[t.inactive?(H(),U(`strong`,aH,j(e.attrValue(t,`#DisplayName`)),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(n=>e.details(t),[`prevent`])},[G(`strong`,null,j(e.attrValue(t,`#DisplayName`)),1)],8,oH))],64)),e.componentOptions.showAllIdentifiers?(H(!0),U(V,{key:3},z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`small text-muted fw-bold`},j(e),1))),128)):J(``,!0),e.componentOptions.itemTemplate?(H(),W(l,{key:4,callbacks:e.componentOptions.itemTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(`div`,sH,[G(`span`,null,j(e.attrValue(t,`CatalogDescription`)),1)])),t.replacements&&t.replacements.length&&e.componentOptions.showReplacements?(H(),W(d,{key:6,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),e.componentOptions.showVariants&&t.variantsAvailable?(H(),U(`div`,cH,[K(o,{class:`text-muted me-2`,name:`information-circle`}),F(G(`span`,null,null,512),[[f,e.t(`VariantsAvailable`)+`: `+e.variantsAvailableInfo(t.variantAttributes)+`.`]])])):J(``,!0)]),e.componentOptions.additionalColumnTemplate?(H(),U(`div`,{key:2,class:A(`col-`+e.componentOptions.additionalColumnTemplateWidth)},[K(l,{callbacks:e.componentOptions.additionalColumnTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])],2)):J(``,!0),e.showActionTemplate(t)?(H(),U(`div`,{key:3,class:A(`col-`+e.componentOptions.actionTemplateWidth)},[K(l,{callbacks:e.componentOptions.actionTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])],2)):J(``,!0)])],2)}),128))])):J(``,!0)],512)}var uH=Q(ZV,[[`render`,lH]]),dH=L({name:`PrmSearchTable`,components:{Icon:$h,Tooltip:Fw,PisReplacements:KB,Clickable:wm,MountPoint:cg},props:{products:{type:Array,required:!0},relationshipColumns:{type:Array,required:!0},instance:{type:Object,required:!0},t:{type:Function,required:!0},emit:{type:Function,required:!0},relationship:{type:Object,required:!0},actionTemplate:{type:Object,default:void 0}},setup(e){let t=M(),n=Y(()=>e.products),r=Y(()=>{var t;return(t=e.instance)==null?void 0:t.store}),i=Y(()=>{var t;return((t=e.instance)==null?void 0:t.registeredComponents.has(`pis-products-preview`))??!1}),a=Y(()=>{var e;return((e=r.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.table)??{}}),o=Y(()=>{var t,n;let r=(t=a.value.columns)==null?void 0:t.filter(e=>e.treeTypes.indexOf(ou.PRODUCTS)>-1),i=[];if(r!=null&&r.length){var o;i.push({...r[0],headerTemplate:void 0,caption:((o=e.relationshipColumns[0])==null?void 0:o.text)??r[0].caption})}let s=e.relationshipColumns[1];if((s==null?void 0:s.dataField)===`CatalogDescription`&&r&&r.length>1){i.push({...r[1],headerTemplate:void 0,caption:s.text??r[1].caption});let t=e.relationshipColumns.slice(2).map(e=>({caption:e.text,dataField:e.dataField,treeTypes:[ou.PRODUCTS]}));i.push(...t)}else{let t=e.relationshipColumns.slice(1).map(e=>({caption:e.text,dataField:e.dataField,treeTypes:[ou.PRODUCTS]}));i.push(...t)}return(n=e.actionTemplate)!=null&&n.cellTemplate&&i.push({caption:``,width:e.actionTemplate.columnWidth,treeTypes:[ou.PRODUCTS],headerTemplate:e.actionTemplate.headerTemplate,cellTemplate:e.actionTemplate.cellTemplate}),i}),s=Y(()=>{var e;return(e=n.value)==null?void 0:e.some(({additionalInfo:e})=>e==null?void 0:e.length)}),c=Y(()=>{var e;return((e=r.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),l=async t=>{if(t)try{var n;await((n=e.instance)==null?void 0:n.execute(new bp(t).from(`prm-search-table`)))}catch{}};return{root:t,componentOptions:a,productsItems:n,previewEnabled:i,columns:o,shouldDisplayAdditionalInfo:s,replacementsVisible:c,details:l,preview:async t=>{try{var n;await((n=e.instance)==null?void 0:n.execute(new xp({productId:t.productId}).from(`prm-search-table`)))}catch{}},attrValue:Us,attrValues:Ws,additionalInfoText:Gs,variantsAvailableInfo:Ks,reactiveContext:lg,cellCtx:hg(t=>({instance:e.instance,col:t.col,item:t.item,emit:e.emit,details:l,attrValue:Us,attrValues:Ws,t:e.t,relationship:e.relationship,row:t.item}))}}}),fH={key:0,class:`table-responsive pis-scroll`},pH={class:`table`},mH={key:0,style:{width:`1%`}},hH={key:1,style:{width:`1%`}},gH={key:2,style:{width:`1%`}},_H={key:0},vH={key:1},yH={key:2},bH={key:0},xH={class:`ext-select-checkbox`},SH=[`checked`,`onClick`],CH={key:1},wH={key:2},TH={key:1},EH={key:2},DH={key:4,class:`d-flex align-items-center fw-bold mt-1`};function OH(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Icon`),c=R(`Clickable`),l=R(`Tooltip`),u=R(`PisReplacements`),d=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,`pis-prm-search-table`])},[e.productsItems&&e.productsItems.length?(H(),U(`div`,fH,[G(`table`,pH,[G(`colgroup`,null,[e.componentOptions.selectable?(H(),U(`col`,mH)):J(``,!0),e.previewEnabled?(H(),U(`col`,hH)):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`col`,gH)):J(``,!0),(H(!0),U(V,null,z(e.columns,(e,t)=>(H(),U(`col`,{key:t,style:k({width:e.width})},null,4))),128))]),G(`thead`,null,[G(`tr`,null,[e.componentOptions.selectable?(H(),U(`th`,_H)):J(``,!0),e.previewEnabled?(H(),U(`th`,vH)):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`th`,yH)):J(``,!0),(H(!0),U(V,null,z(e.columns,(t,n)=>(H(),U(`th`,{key:n},[t.headerTemplate?(H(),W(o,{key:0,callbacks:t.headerTemplate,ctx:e.reactiveContext({t:e.t,col:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(t.caption),1)],64))]))),128))])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.productsItems,t=>{var n,r;return H(),U(`tr`,{key:t.productId,class:A({"bg-light":t.exactMatch,"ext-selected":(n=e.instance)==null?void 0:n.selection.isSelected(t)})},[e.componentOptions.selectable?(H(),U(`td`,bH,[G(`div`,xH,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(r=e.instance)==null?void 0:r.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,SH)])])):J(``,!0),e.previewEnabled?(H(),U(`td`,CH,[K(c,{class:`d-flex ext-icon-preview`,title:e.t(t.inactive?`PreviewNotAvailable`:`Preview`,!0),disabled:t.inactive,onClick:X(n=>!t.inactive&&e.preview(t),[`prevent`])},{default:P(()=>[K(s,{name:`eye-show`,size:24})]),_:1},8,[`title`,`disabled`,`onClick`])])):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`td`,wH,[t.additionalInfo&&t.additionalInfo.length?(H(),W(l,{key:0,text:e.additionalInfoText(t.additionalInfo)},{default:P(()=>[K(s,{class:`text-warning`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0)])):J(``,!0),(H(!0),U(V,null,z(e.columns,(n,r)=>(H(),U(`td`,{key:r},[n.cellTemplate?(H(),W(o,{key:0,callbacks:n.cellTemplate,ctx:e.cellCtx({item:t,col:n})},null,8,[`callbacks`,`ctx`])):n.dataField==`ProductId`?(H(),U(`span`,TH,[K(c,{onClick:n=>e.details(t)},{default:P(()=>[q(j(e.attrValue(t,n.dataField)),1)]),_:2},1032,[`onClick`])])):(H(),U(`span`,EH,j(e.attrValue(t,n.dataField)),1)),n.showReplacements&&t.replacements&&t.replacements.length?(H(),W(u,{key:3,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),n.showVariants&&t.variantsAvailable?(H(),U(`div`,DH,[K(s,{class:`text-muted me-2`,name:`information-circle`}),F(G(`span`,null,null,512),[[d,e.t(`VariantsAvailable`)+`: `+e.variantsAvailableInfo(t.variantAttributes)+`.`]])])):J(``,!0),n.showAllIdentifiers?(H(!0),U(V,{key:5},z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`small text-muted fw-bold`},j(e),1))),128)):J(``,!0)]))),128))],2)}),128))])])])):J(``,!0)],512)}var kH=L({name:`PrmList`,components:{Arrow:qb,Btn:Iy,Card:SE,Badge:ky,LinkSecondary:kE,Message:NE,ScrollableList:kD,Icon:$h,Pagination:tx,ImageGallery:xF,PrmListSearchForm:XV,FiltersNavigatorModal:tO,Spinner:My,Clickable:wm,PrmSearchTable:Q(dH,[[`render`,OH]]),PrmSearchList:uH},props:{relationship:{type:Object,required:!0},instance:{type:Object,required:!0},productId:{type:String,required:!0},t:{type:Function,required:!0},cid:{type:String,required:!1,default:void 0},emit:{type:Function,required:!0}},setup(e){var t,n;let r=M(!1),i=M(!1),a=Y(()=>e.relationship),o=Y(()=>a.value.columns),s=M(!1),c=M(!1),l=Y(()=>{var t;return(t=e.instance)==null||(t=t.store.options.components)==null||(t=t.details)==null||(t=t.data)==null?void 0:t.relationships}),{filter:u,filtersAll:d,filtersPromoted:f,filtersAdditional:p,filtersModel:m,filtersFetched:h,filtersLoading:g,filtersOpen:_,saveSettings:v,setFilters:y,setFilterValues:b,resetFiltersApplied:x,getFiltersModelAsCriteriaGroup:S}=pp(e.productId,e.relationship),C=M(1),w=M(((t=l.value)==null?void 0:t.pageSize)||0),T=M(((n=a.value.products)==null?void 0:n.totalCount)||0),E=M([]),D=M(!1),ee=M([]),O=M(!1),te=M(!1),ne=Y(()=>{var t;return D.value===!0?E.value:((t=e.relationship.products)==null?void 0:t.items)||[]}),re=Y(()=>Math.ceil(T.value/w.value)),ie=async()=>{te.value=!0;let t=new zp({search:{productId:e.productId,searchText:u.value||void 0,relationshipType:e.relationship.type,relationshipCode:e.relationship.code,filter:S()},pager:{page:C.value,pageSize:w.value}});try{var n;let a=await((n=e.instance)==null?void 0:n.execute(t));if(a&&a.items){var r,i;E.value=((r=a.items[0].products)==null?void 0:r.items)||[],T.value=((i=a.items[0].products)==null?void 0:i.totalCount)||0,y(a.items[0].filters||[])}else E.value=[],T.value=0,y([]);let o={};h.forEach((e,t)=>o[t]=!0),g.forEach(e=>o[e]=!0),Object.keys(o).length>0&&await ae(Object.keys(o)),D.value=!0}catch{}finally{te.value=!1}},ae=async t=>{t.forEach(e=>g.add(e));try{var n;let r=await((n=e.instance)==null?void 0:n.execute(new Hp({attributeCodes:t,productId:e.productId,searchText:u.value||void 0,relationshipType:e.relationship.type,relationshipCode:e.relationship.code,filter:S()}).from(`prm-list`)));b(r.items||[])}catch{}},oe=async e=>{C.value=e,await ie()},se=async()=>{i.value=!1,await ie()},ce=async e=>{u.value=e,C.value=1,await se()},le=async()=>{u.value=``,C.value=1,await ie()},ue=e=>{var t;return e.slice(0,(t=l.value)==null?void 0:t.filteringMaxAttributesVisible)??[]},de=Y(()=>ue(f.value.length?f.value:p.value)),k=async({attributeCode:t})=>{!t||!e.instance||(_.has(t)?_.delete(t):(h.has(t)||await ae([t]),_.add(t)))},fe=({attributeCode:e})=>_.has(e),pe=({attributeCode:e})=>g.has(e),me=()=>{i.value=!1,setTimeout(()=>{i.value=!0},1)},he=async()=>{x(),_&&_.clear(),await ie()},A=({attributeCode:e,filterValueName:t,value:n})=>{m.value[e][t]=n},ge=()=>{r.value=!0};kr(async()=>{if(e.relationship){if(e.relationship.images){O.value=!0;try{var t;let n=await((t=e.instance)==null||(t=t.httpService)==null?void 0:t.loadImagesById(e.relationship.images));n!=null&&n.items&&(ee.value=n.items)}catch{}O.value=!1}e.relationship.filters&&y(e.relationship.filters)}if(S().rules.length||u.value)s.value=!0,c.value=!0,await ie();else{var n,r;s.value=T.value>=(((n=l.value)==null?void 0:n.filteringMinItems)||0)&&[eu.ACCESSORIES,eu.KIT_CONTENTS,eu.SPARE_PART_USED_ON_LIST].includes(e.relationship.type||``),c.value=T.value>=(((r=l.value)==null?void 0:r.searchMinItems)||0)}});let _e=Y(()=>{var t;let n=(t=e.instance)==null||(t=t.store.options.components)==null||(t=t.details)==null||(t=t.data)==null?void 0:t.relationships;if(n!=null&&n.actionTemplates){if(n.actionTemplates[e.relationship.type])return n.actionTemplates[e.relationship.type];if(n.actionTemplates.All)return n.actionTemplates.All}}),ve=Y(()=>{var t;let n=(t=e.instance)==null||(t=t.store)==null||(t=t.options)==null||(t=t.components)==null||(t=t.details)==null||(t=t.data)==null||(t=t.relationships)==null?void 0:t.displayMode;if(n){if(n[e.relationship.type])return n[e.relationship.type];if(n.All)return n.All}return`table`});return{isTableMode:Y(()=>ve.value===`table`),isListMode:Y(()=>ve.value===`list`),prm:a,products:ne,filter:u,page:C,pageCount:re,totalCount:T,productsImages:ee,productsImagesLoading:O,isLoading:te,filtersAll:d,filtersPromoted:f,filtersAdditional:p,filtersToDisplay:de,filtersOpen:_,filtersFetched:h,areFiltersDirty:r,filtersModel:m,isSearchEnabled:c,filteringOptions:l,isFilteringEnabled:s,allFiltersModalShown:i,actionTemplate:_e,columns:o,getFiltersModelAsCriteriaGroup:S,criterionValueKey:lu,onSearch:ce,onSearchClear:le,searchNow:se,toggleFilter:k,saveSettings:v,onPageChange:oe,isFilterOpen:fe,showAllFilters:me,isFilterLoading:pe,onFetchFilterValues:ae,onFilterValueChange:ge,clearAndCloseFilters:he,onModalFilterValueChange:A}}}),AH={key:0},jH={class:`fw-bold`},MH={key:1,class:`mb-4`},NH={key:2},PH={key:0,class:`list-unstyled mb-0`},FH={class:`d-block ms-2 text-body text-break pis-label`},IH={key:0},LH={class:`form-check pe-1`},RH={class:`form-check-label d-flex align-items-start py-1`},zH=[`onUpdate:modelValue`,`name`],BH=[`textContent`],VH={class:`d-flex justify-content-between align-items-center`},HH={class:`text-muted fw-bold`},UH={key:0},WH={class:`fw-bold`},GH={key:1},KH={key:3},qH={key:4},JH={key:5,class:`d-flex flex-row-reverse`};function YH(e,t,n,r,i,a){var o,s,c,l;let u=R(`Icon`),d=R(`ImageGallery`),f=R(`Spinner`),p=R(`Arrow`),m=R(`Badge`),h=R(`Clickable`),g=R(`ScrollableList`),_=R(`Message`),v=R(`Btn`),y=R(`LinkSecondary`),b=R(`Card`),x=R(`FiltersNavigatorModal`),S=R(`PrmListSearchForm`),C=R(`PrmSearchTable`),w=R(`PrmSearchList`),T=R(`Pagination`),E=Hr(`safe-html`);return H(),U(V,null,[e.prm.userFields?(H(),U(`div`,AH,[(H(!0),U(V,null,z(e.prm.userFields,(e,t)=>(H(),U(`div`,{key:t,class:`mb-4`},[G(`div`,jH,[K(u,{name:`information-circle`}),q(` `+j(e.name),1)]),(H(!0),U(V,null,z(e.values,(e,t)=>(H(),U(`div`,{key:t},j(e),1))),128))]))),128))])):J(``,!0),e.productsImages.length?(H(),U(`div`,MH,[K(d,{images:e.productsImages,"always-show-thumbnails":!0,title:e.t(`ProductGallery`)},null,8,[`images`,`title`])])):J(``,!0),e.isFilteringEnabled&&[`inline-collapsed`,`inline-expanded`].includes(((o=e.filteringOptions)==null?void 0:o.filtering)||``)?(H(),U(`div`,NH,[K(b,{class:`mb-4`,"sticky-footer":``,icon:`funnel-filter`,header:e.t(`PrmFilters`,!0),"use-markup":!0,collapsed:((s=e.filteringOptions)==null?void 0:s.filtering)===`inline-collapsed`},Gr({default:P(()=>{var n;return[(n=e.filtersToDisplay)!=null&&n.length?(H(),U(`ul`,PH,[(H(!0),U(V,null,z(e.filtersToDisplay,n=>{var r;return H(),U(`li`,{key:n.attributeCode,class:`pb-2`},[K(h,{class:`py-1 d-flex align-items-start text-decoration-none lh-sm`,"aria-expanded":e.isFilterOpen(n),onClick:t=>e.toggleFilter(n)},{default:P(()=>[e.isFilterLoading(n)?(H(),W(f,{key:0,sm:``})):(H(),W(p,{key:1,dir:e.isFilterOpen(n)?`up`:`down`},null,8,[`dir`])),F(G(`span`,FH,null,512),[[E,n.attributeName]]),K(m,{class:`ms-auto`,textContent:j(n.hitCount)},null,8,[`textContent`])]),_:2},1032,[`aria-expanded`,`onClick`]),e.isFilterOpen(n)?(H(),U(`div`,IH,[(r=e.filtersFetched.get(n.attributeCode))!=null&&r.length?(H(),W(g,{key:0,class:`list-unstyled my-1 ms-2`,height:`30vh`,items:e.filtersFetched.get(n.attributeCode)||[]},{item:P(({item:r})=>[G(`div`,LH,[G(`label`,RH,[F(G(`input`,{"onUpdate:modelValue":t=>e.filtersModel[n.attributeCode][e.criterionValueKey(r.value)]=t,type:`checkbox`,class:`form-check-input mt-1 me-2 flex-shrink-0`,name:r.text,onChange:t[0]||(t[0]=(...t)=>e.onFilterValueChange&&e.onFilterValueChange(...t))},null,40,zH),[[bs,e.filtersModel[n.attributeCode][e.criterionValueKey(r.value)]]]),G(`span`,{class:`text-break user-select-none`,textContent:j(r.text)},null,8,BH),K(m,{class:`ms-auto`,textContent:j(r.hitCount)},null,8,[`textContent`])])])]),_:2},1032,[`items`])):(H(),W(_,{key:1},{default:P(()=>[q(j(e.t(`NoFilterValues`)),1)]),_:1}))])):J(``,!0)])}),128))])):(H(),W(_,{key:1},{default:P(()=>[q(j(e.t(`NoFilters`)),1)]),_:1}))]}),_:2},[(c=e.filtersAll)!=null&&c.length?{name:`footer`,fn:P(()=>[e.areFiltersDirty?(H(),W(v,{key:0,class:`w-100 mb-2 justify-content-between ext-apply`,onClick:X(e.searchNow,[`prevent`])},{default:P(()=>[q(j(e.t(`ShowResults`,!0)),1)]),_:1},8,[`onClick`])):J(``,!0),K(y,{icon:`stop-not-allowed`,class:`mt-2 ext-clear`,onClick:X(e.clearAndCloseFilters,[`prevent`])},{default:P(()=>[q(j(e.t(`ClearFilters`,!0)),1)]),_:1},8,[`onClick`]),K(y,{icon:`pop-out-window`,class:`mt-2 ext-show-all`,onClick:X(e.showAllFilters,[`prevent`])},{default:P(()=>[q(j(e.t(`ShowAllFilters`))+` (`+j(e.filtersAll.length)+`) `,1)]),_:1},8,[`onClick`])]),key:`0`}:void 0]),1032,[`header`,`collapsed`])])):J(``,!0),K(x,{show:e.isFilteringEnabled&&e.allFiltersModalShown,title:e.t(`AllFiltersModalTitle`),t:e.t,"filters-all":e.filtersAll,"filters-promoted":e.filtersPromoted,"filters-additional":e.filtersAdditional,"filters-fetched":e.filtersFetched,"filters-model":e.filtersModel,"fetch-filter-values":e.onFetchFilterValues,"filtered-result-count":void 0,"filtered-result-count-loading":!1,onValueChange:e.onModalFilterValueChange,onApplyFilters:e.searchNow,onClear:e.clearAndCloseFilters},null,8,[`show`,`title`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-fetched`,`filters-model`,`fetch-filter-values`,`onValueChange`,`onApplyFilters`,`onClear`]),G(`div`,VH,[G(`div`,null,[G(`span`,HH,j(e.totalCount)+` `+j(e.t(`Products`,!0)),1)]),e.isFilteringEnabled&&((l=e.filteringOptions)==null?void 0:l.filtering)===`popup`?(H(),U(`div`,UH,[K(y,{icon:`funnel-filter`,onClick:X(e.showAllFilters,[`prevent`])},{default:P(()=>[G(`span`,WH,j(e.t(`PrmFilters`,!0)),1)]),_:1},8,[`onClick`])])):J(``,!0),e.isSearchEnabled?(H(),U(`div`,GH,[K(S,{modelValue:e.filter,"onUpdate:modelValue":t[1]||(t[1]=t=>e.filter=t),instance:e.instance,"product-id":e.productId,"relationship-type":e.relationship.type,"relationship-code":e.relationship.code,"filter-criteria":e.getFiltersModelAsCriteriaGroup(),t:e.t,onSearch:e.onSearch,onClear:e.onSearchClear},null,8,[`modelValue`,`instance`,`product-id`,`relationship-type`,`relationship-code`,`filter-criteria`,`t`,`onSearch`,`onClear`])])):J(``,!0)]),e.isTableMode?(H(),U(`div`,KH,[B(e.$slots,`search-table`,{},()=>[K(C,{products:e.products,"relationship-columns":e.columns,instance:e.instance,t:e.t,emit:e.emit,relationship:e.relationship,"action-template":e.actionTemplate},null,8,[`products`,`relationship-columns`,`instance`,`t`,`emit`,`relationship`,`action-template`])])])):J(``,!0),e.isListMode?(H(),U(`div`,qH,[B(e.$slots,`search-list`,{},()=>[K(w,{products:e.products,instance:e.instance,t:e.t,emit:e.emit},null,8,[`products`,`instance`,`t`,`emit`])])])):J(``,!0),e.pageCount>1?(H(),U(`div`,JH,[K(T,{total:e.pageCount,current:e.page,onChange:e.onPageChange},null,8,[`total`,`current`,`onChange`])])):J(``,!0)],64)}var XH=Q(kH,[[`render`,YH]]),ZH=e=>`pis-anchor-prm-${CSS.escape(e)}`,QH=e=>`#${CSS.escape(e)}`,$H=e=>{let t=Y(()=>{var t;return(t=e.value)==null||(t=t.store.options.components)==null||(t=t.common)==null?void 0:t.hideWhereUsed}),n=Y(()=>{var t,n,r;let i=(t=e.value)==null?void 0:t.store,a={agms:[],prms:[]},o=[...(i==null||(n=i.data.attributeGroups)==null?void 0:n.items)||[]],s=[...(i==null||(r=i.data.prm)==null?void 0:r.items)||[]];for(let e of o){var c;let t={prms:[],attributeGroup:e};if((c=e.relationshipCodes)!=null&&c.length){let n=new Set(e.relationshipCodes);t.prms=s.filter(e=>n.has(e.code)),t.prms.forEach(e=>s.splice(s.indexOf(e),1))}a.agms.push(t)}return a.prms=s,a});return{prmData:n,visibleAgmData:Y(()=>n.value.agms.reduce((e,n)=>n.attributeGroup.visible?e.concat([{attributeGroup:n.attributeGroup,prms:n.prms.filter(e=>!t.value||e.type!==eu.WHERE_USED&&e.type!==eu.SPARE_PART_USED_ON_LIST)}]):e,[])),visiblePrmData:Y(()=>n.value.prms.reduce((e,n)=>!t.value||n.type!==eu.WHERE_USED&&n.type!==eu.SPARE_PART_USED_ON_LIST?e.concat([n]):e,[]))}},eU=L({name:`pis-products-details-attribute-groups`,components:{PrmList:XH,AttributesTable:uF},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s,emit:c}=dB(t,e.instanceId,[$.AttributeGroups,$.ProductRelationships]);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,instance:n,hideDocumentLinks:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideDocumentLinks)==1}),prmDataFiltered:$H(n).visibleAgmData,productId:Y(()=>{var e;return(e=o.value)==null||(e=e.data.productDetail)==null||(e=e.item)==null?void 0:e.productId}),t:s,emit:c,buildPrmAnchorId:ZH}}}),tU={key:0},nU=[`id`],rU={class:`pis-heading ext-attr-group-heading`},iU={class:`ext-attr-group-content`},aU=[`id`],oU={class:``},sU={class:`ext-attr-group-content`};function cU(e,t,n,r,i,a){let o=R(`AttributesTable`),s=R(`PrmList`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,tU,[(H(!0),U(V,null,z(e.prmDataFiltered,(t,n)=>(H(),U(`div`,{key:n,class:`mt-4 ext-attr-group`},[G(`div`,{id:`pis-anchor-agm-${t.attributeGroup.code}`,class:`ext-attr-group-inner`},[G(`h4`,rU,j(t.attributeGroup.description),1),G(`div`,iU,[t.attributeGroup.attributes?(H(),W(o,{key:0,attributes:t.attributeGroup.attributes,instance:e.instance,"hide-document-links":e.hideDocumentLinks,t:e.t},null,8,[`attributes`,`instance`,`hide-document-links`,`t`])):J(``,!0)]),(H(!0),U(V,null,z(t.prms,t=>(H(),U(`div`,{key:t.code,class:`ext-attr-group-list`},[t&&e.productId?(H(),U(`div`,{key:0,id:e.buildPrmAnchorId(t.code),class:`ps-lg-3`},[G(`h5`,oU,j(t.description),1),G(`div`,sU,[K(s,{relationship:t,instance:e.instance,"product-id":e.productId,t:e.t,emit:e.emit},null,8,[`relationship`,`instance`,`product-id`,`t`,`emit`])])],8,aU)):J(``,!0)]))),128))],8,nU)]))),128))])):J(``,!0)],2)}var lU=Q(eU,[[`render`,cU]]),uU=L({name:`pis-products-details-classifications`,components:{Message:NE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s}=dB(t,e.instanceId,[$.ProductClassifications]);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,classifications:Y(()=>{var e;return(e=o.value)==null||(e=e.data.productClassifications)==null?void 0:e.items}),setCategory:async e=>{if(n.value&&e)try{await n.value.execute(new Op({cid:e.cid,clearSearch:!0}).from(r))}catch{}},t:s}}}),dU={key:0},fU={key:0},pU={class:`fw-bold ext-class-group`},mU={class:`ext-class-nodes`},hU={key:0},gU=[`onClick`],_U={key:2,class:`px-1 ext-class-arrow`};function vU(e,t,n,r,i,a){let o=R(`Message`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,dU,[e.classifications?(H(),U(`div`,fU,[G(`ul`,null,[(H(!0),U(V,null,z(e.classifications,(t,n)=>(H(),U(`li`,{key:n},[G(`span`,pU,j(n),1),G(`ul`,null,[(H(!0),U(V,null,z(t,(t,n)=>(H(),U(`li`,{key:n},[G(`div`,mU,[(H(!0),U(V,null,z(t,(n,r)=>(H(),U(`span`,{key:n.cid,class:`ext-class-node`},[n.inactive?(H(),U(`span`,hU,j(n.name),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(t=>e.setCategory(n),[`prevent`])},j(n.name),9,gU)),r+1<t.length?(H(),U(`span`,_U,`›`)):J(``,!0)]))),128))])]))),128))])]))),128))])])):(H(),W(o,{key:1,class:`p-2`},{default:P(()=>[q(j(e.t(`ProductNotClassified`)),1)]),_:1}))])):J(``,!0)],2)}var yU=Q(uU,[[`render`,vU]]),bU=L({name:`pis-products-details-general-information`,components:{AttributesTable:uF},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s}=dB(t,e.instanceId,[Yl.PRODUCT_DETAILS]);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,instance:n,item:Y(()=>{var e;return(e=o.value)==null||(e=e.data.productDetail)==null?void 0:e.item}),hideDocumentLinks:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideDocumentLinks)==1}),t:s}}}),xU={key:0},SU={key:0},CU={class:`pis-heading ext-attr-group-heading`},wU={class:`ext-attr-group-content`};function TU(e,t,n,r,i,a){let o=R(`AttributesTable`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,xU,[e.item?(H(),U(`div`,SU,[G(`h3`,CU,j(e.t(`GeneralInfo`)),1),G(`div`,wU,[e.item.attributes?(H(),W(o,{key:0,attributes:e.item.attributes,instance:e.instance,"hide-document-links":e.hideDocumentLinks,t:e.t},null,8,[`attributes`,`instance`,`hide-document-links`,`t`])):J(``,!0)])])):J(``,!0)])):J(``,!0)],2)}var EU=Q(bU,[[`render`,TU]]),DU=L({name:`pis-products-details-identifiers`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,t:o}=dB(t,e.instanceId,[]);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:a,allIdentifiers:Y(()=>{var e;if((e=a.value)!=null&&(e=e.data.productDetail)!=null&&e.item&&a.value.data.productDetail.item.attributes[`#AllIdentifiers`]){var t;return Ws((t=a.value)==null?void 0:t.data.productDetail.item,`#AllIdentifiers`)}return[]}),t:o}}}),OU={key:0};function kU(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,OU,[(H(!0),U(V,null,z(e.allIdentifiers,e=>(H(),U(`div`,{key:e,class:`text-muted`},j(e),1))),128))])):J(``,!0)],2)}var AU=Q(DU,[[`render`,kU]]),jU=L({name:`pis-products-details-navigation`,components:{Clickable:wm},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,widerThan:s,t:c}=dB(t,e.instanceId,[]),l=$H(n);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,links:Y(()=>{var e,t,r;let i=[];return(e=n.value)!=null&&e.translations.translations?(l.visibleAgmData.value.forEach(e=>i.push({text:e.attributeGroup.description,id:`pis-anchor-agm-${e.attributeGroup.code}`})),l.visiblePrmData.value.forEach(e=>i.push({text:e.description,id:ZH(e.code)})),(t=o.value)!=null&&(t=t.options.components)!=null&&(t=t.details)!=null&&(t=t.variantsTable)!=null&&t.visible&&(((r=o.value)==null||(r=r.data.productVariantsTable)==null||(r=r.items)==null?void 0:r.length)??!1)&&i.push({text:c(`AllVariantProducts`),id:`pis-anchor-variants-table`}),i):i}),t:c,scrollToLink:e=>{let t=document.querySelector(QH(e.id));t&&t.scrollIntoView({behavior:`smooth`})},widerThan:s}}}),MU={key:0},NU={key:0,class:`bg-light p-3`},PU={class:`fw-bold`},FU={class:`row`};function IU(e,t,n,r,i,a){let o=R(`Clickable`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(`div`,MU,[e.links.length>1?(H(),U(`div`,NU,[G(`p`,PU,j(e.t(`GoToSection`))+`:`,1),G(`div`,FU,[(H(!0),U(V,null,z(e.links,t=>(H(),U(`div`,{key:t.id,class:A([e.widerThan(`lg`)?`col-6`:`col-12`])},[K(o,{class:`text-body`,onClick:n=>e.scrollToLink(t)},{default:P(()=>[q(j(t.text),1)]),_:2},1032,[`onClick`])],2))),128))])])):J(``,!0)])):J(``,!0)],2)}var LU=Q(jU,[[`render`,IU]]),RU=L({components:{Card:SE,Image:CO},props:{imageSrc:{type:String,default:void 0},imageLoading:Boolean,inactive:Boolean,contentClickable:Boolean,wide:Boolean,useCardMarkup:{type:Boolean,default:!0},hideImage:Boolean,imageClickable:{type:Boolean,default:!0},imageWidth:{type:String,default:`8rem`},additionalColumnTemplateWidth:{type:Number,default:2},actionTemplateWidth:{type:Number,default:2}},emits:[`click-content`]}),zU={key:0,class:`flex-fill`},BU={class:`position-relative`},VU={class:`col`};function HU(e,t,n,r,i,a){let o=R(`Image`),s=R(`Card`);return H(),W(s,{class:A([e.useCardMarkup?`mb-4`:`mb-5`]),"use-markup":e.useCardMarkup},{default:P(()=>[B(e.$slots,`before`),G(`div`,{class:A([`row align-items-center mt-2`,[e.$slots.before?`ms-3`:``]])},[G(`div`,{class:A([`mb-lg-2`,{col:e.wide,"col-12":!e.wide}]),style:k({"max-width":e.wide?e.imageWidth:`100%`})},[e.hideImage?J(``,!0):(H(),U(`div`,zU,[G(`div`,BU,[K(o,{style:{width:`100%`},class:`flex-fill`,src:e.imageSrc,"is-loading":e.imageLoading,clickable:e.imageClickable,"hide-frame":!0,onClick:t[0]||(t[0]=t=>e.$emit(`click-content`))},null,8,[`src`,`is-loading`,`clickable`]),B(e.$slots,`imageOverlay`)])]))],6),G(`div`,VU,[B(e.$slots,`content`)]),e.$slots.additionalColumn?(H(),U(`div`,{key:0,class:A([`mt-lg-2`,[`col-lg-`+e.additionalColumnTemplateWidth]])},[G(`div`,{class:A([e.wide?`ms-auto`:`mt-3`])},[B(e.$slots,`additionalColumn`)],2)],2)):J(``,!0),!e.inactive&&e.$slots.after?(H(),U(`div`,{key:1,class:A([`mt-lg-2`,[`col-lg-`+e.actionTemplateWidth]])},[G(`div`,{class:A([e.wide?`ms-auto text-end`:`mt-3`])},[B(e.$slots,`after`)],2)],2)):J(``,!0)],2)]),_:3},8,[`class`,`use-markup`])}var UU=L({name:`pis-products-details-related-links`,components:{Message:NE,ProductsListItem:Q(RU,[[`render`,HU]]),Tooltip:Fw,Icon:$h},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,t:o,widerThan:s}=dB(t,e.instanceId),c=Y(()=>{var e;return(e=a.value)==null||(e=e.data.relatedLinks)==null?void 0:e.items});return{root:t,componentName:n,componentOptions:Y(()=>{var e;return((e=a.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.relatedLinks)??{}}),isReady:r,isWebComponent:i,store:a,relatedLinks:c,t:o,widerThan:s}}}),WU={key:0},GU=[`href`];function KU(e,t,n,r,i,a){var o;let s=R(`Icon`),c=R(`Tooltip`),l=R(`ProductsListItem`),u=R(`Message`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.componentOptions.visible&&e.isReady?(H(),U(`div`,WU,[(o=e.relatedLinks)!=null&&o.length?(H(!0),U(V,{key:0},z(e.relatedLinks,(t,n)=>(H(),U(`a`,{key:n,target:`_blank`,href:t.url},[K(l,{"image-src":e.componentOptions.showImages?t.image:``,wide:e.widerThan(`sm`),"hide-image":!e.componentOptions.showImages},{content:P(()=>[t.internal?(H(),W(c,{key:0,text:e.t(`Internal`,!0)},{default:P(()=>[K(s,{class:`text-warning text-end`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0),q(` `+j(t.text),1)]),_:2},1032,[`image-src`,`wide`,`hide-image`])],8,GU))),128)):(H(),W(u,{key:1,class:`p-2`},{default:P(()=>[q(j(e.t(`RelatedLinksNotAvailable`)),1)]),_:1}))])):J(``,!0)],2)}var qU=Q(UU,[[`render`,KU]]),JU=L({name:`pis-products-details-relationships`,components:{PrmList:XH},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s,emit:c}=dB(t,e.instanceId,[$.ProductRelationships]);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,instance:n,prmItems:$H(n).visiblePrmData,productId:Y(()=>{var e;return(e=o.value)==null||(e=e.data.productDetail)==null||(e=e.item)==null?void 0:e.productId}),t:s,emit:c,buildPrmAnchorId:ZH}}}),YU={key:0},XU=[`id`],ZU={class:`pis-heading`};function QU(e,t,n,r,i,a){let o=R(`PrmList`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.productId?(H(),U(`div`,YU,[(H(!0),U(V,null,z(e.prmItems,t=>(H(),U(`div`,{id:e.buildPrmAnchorId(t.code),key:t.code,class:`mt-4`},[G(`h4`,ZU,j(t.description),1),K(o,{relationship:t,instance:e.instance,"product-id":e.productId,t:e.t,emit:e.emit},null,8,[`relationship`,`instance`,`product-id`,`t`,`emit`])],8,XU))),128))])):J(``,!0)],2)}var $U=Q(JU,[[`render`,QU]]),eW=L({name:`pis-products-details-replacements`,components:{PisReplacements:KB},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s}=dB(t,e.instanceId);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,instance:n,item:Y(()=>{var e;return(e=o.value)==null||(e=e.data.productDetail)==null?void 0:e.item}),replacementsVisible:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!==!0}),t:s}}}),tW={key:0};function nW(e,t,n,r,i,a){let o=R(`PisReplacements`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.item?(H(),U(`div`,tW,[e.item.replacements&&e.item.replacements.length?(H(),W(o,{key:0,instance:e.instance,replacements:e.item.replacements,"show-icon":``,"is-detail-view":!0,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0)])):J(``,!0)],2)}var rW=Q(eW,[[`render`,nW]]),iW=L({name:`pis-products-details-variants-dropdown`,components:{Icon:$h,Dropdown:pb,Clickable:wm},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),{componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,t:c,routeData:l}=dB(t,e.instanceId),u=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.variantsDropdown)??{}}),d=Y(()=>{var e,t;return(e=s.value)!=null&&(e=e.data.productVariantsDropdown)!=null&&(e=e.items)!=null&&e.length?(t=s.value)==null?void 0:t.data.productVariantsDropdown.items:[]}),f=Y(()=>{var e;return u.value.visible!==!1&&(((e=d.value)==null?void 0:e.length)??0)>0}),p=Y(()=>{var e;let t=[];return(e=d.value)!=null&&e.length&&d.value.forEach(e=>{var n;t.push({type:`group`,value:e}),(n=e.products)==null||n.forEach(e=>{t.push({type:`product`,value:e})})}),t});return{root:t,componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,t:c,componentOptions:u,variants:d,visible:f,isDropdownOpen:n,selectedProduct:Y(()=>{var e;return((e=s.value)==null||(e=e.data.productDetail)==null?void 0:e.item)||{}}),dropdownItems:p,attrValue:Us,toggleDropdown:()=>{n.value=!n.value},details:async e=>{if(!(e!=null&&e.inactive)&&l.value&&e){n.value=!1;try{var t;await((t=o.value)==null?void 0:t.execute(new bp(e).from(r)))}catch{}}}}}}),aW={key:0},oW={class:`mb-4 ext-attr-group`},sW={class:`row`},cW={class:`col-12`},lW={key:0,class:`px-3 py-2 fw-semibold text-muted bg-light border-bottom small sticky-top`},uW={class:`d-flex align-items-center`},dW={key:0,class:`me-2 flex-shrink-0`,style:{width:`2.5rem`}},fW=[`src`,`alt`],pW={key:1,class:`d-flex align-items-center justify-content-center rounded border bg-light text-muted`,style:{height:`2rem`,"font-size":`1rem`}},mW={class:`flex-grow-1 overflow-hidden`},hW={class:`fw-bold text-truncate`},gW={key:0,class:`small text-muted text-truncate`},_W=[`aria-expanded`],vW={class:`d-flex align-items-center flex-grow-1 w-100`},yW={key:0,class:`me-2 flex-shrink-0`,style:{width:`2rem`}},bW=[`src`,`alt`],xW={key:1,class:`d-flex align-items-center justify-content-center rounded border bg-light text-muted`,style:{height:`1.5rem`,"font-size":`0.875rem`}},SW={class:`flex-grow-1 overflow-hidden`},CW={key:0,class:`text-truncate d-block`},wW={class:`fw-medium d-block text-truncate`},TW={key:0,class:`text-muted small d-block text-truncate`},EW={key:1,class:`text-muted`};function DW(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`Dropdown`),l=Hr(`safe-html`);return H(),U(`div`,{id:`pis-anchor-variants-dropdown`,ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,aW,[G(`h4`,null,j(e.t(`Variants`)),1),G(`div`,oW,[G(`div`,sW,[G(`div`,cW,[K(c,{open:e.isDropdownOpen,"onUpdate:open":t[3]||(t[3]=t=>e.isDropdownOpen=t),width:`100%`,items:e.dropdownItems},{item:P(({item:t})=>{var n;return[t.type===`group`?(H(),U(`div`,lW,[F(G(`span`,null,null,512),[[l,t.value.attributeName+`: `+t.value.attributeValueText]])])):t.type===`product`?(H(),W(s,{key:1,class:A([`dropdown-item py-2`,{active:t.value.productId===((n=e.selectedProduct)==null?void 0:n.productId)}]),onClick:n=>e.details(t.value)},{default:P(()=>{var n;return[G(`div`,uW,[e.componentOptions.showImages===!1?J(``,!0):(H(),U(`div`,dW,[(n=t.value.images)!=null&&n.length?(H(),U(`img`,{key:0,src:t.value.images[0].thumbnailUrl,alt:e.attrValue(t.value,`#DisplayName`),class:`img-fluid rounded border`,style:{"max-height":`2rem`,"object-fit":`contain`},loading:`lazy`},null,8,fW)):(H(),U(`div`,pW,[K(o,{name:`photo-picture`})]))])),G(`div`,mW,[G(`div`,hW,j(e.attrValue(t.value,`#DisplayName`)),1),e.attrValue(t.value,`CatalogDescription`)?(H(),U(`div`,gW,j(e.attrValue(t.value,`CatalogDescription`)),1)):J(``,!0)])])]}),_:2},1032,[`class`,`onClick`])):J(``,!0)]}),activator:P(({on:n})=>{var r;return[G(`div`,Oa({class:`form-select d-flex align-items-center`,tabindex:`0`,role:`combobox`,"aria-expanded":e.isDropdownOpen,"aria-haspopup":`listbox`},qr(n,!0),{onClick:t[0]||(t[0]=(...t)=>e.toggleDropdown&&e.toggleDropdown(...t)),onKeydown:[t[1]||(t[1]=Ns((...t)=>e.toggleDropdown&&e.toggleDropdown(...t),[`enter`])),t[2]||(t[2]=Ns(X((...t)=>e.toggleDropdown&&e.toggleDropdown(...t),[`prevent`]),[`space`]))]}),[G(`div`,vW,[e.componentOptions.showImages!==!1&&e.selectedProduct?(H(),U(`div`,yW,[(r=e.selectedProduct.images)!=null&&r.length?(H(),U(`img`,{key:0,src:e.selectedProduct.images[0].thumbnailUrl,alt:e.selectedProduct&&e.attrValue(e.selectedProduct,`#DisplayName`),class:`img-fluid rounded border`,style:{"max-height":`1.5rem`,"object-fit":`contain`}},null,8,bW)):(H(),U(`div`,xW,[K(o,{name:`photo-picture`,size:16})]))])):J(``,!0),G(`div`,SW,[e.selectedProduct?(H(),U(`span`,CW,[G(`span`,wW,j(e.attrValue(e.selectedProduct,`#DisplayName`)),1),e.attrValue(e.selectedProduct,`CatalogDescription`)?(H(),U(`span`,TW,` (`+j(e.attrValue(e.selectedProduct,`CatalogDescription`))+`) `,1)):J(``,!0)])):(H(),U(`span`,EW,j(e.t(`SelectProduct`)),1))])])],16,_W)]}),_:1},8,[`open`,`items`])])])])])):J(``,!0)],2)}var OW=Q(iW,[[`render`,DW]]),kW=L({name:`pis-products-details-variants-selector`,components:{Icon:$h,Dropdown:pb,Clickable:wm},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,t:s,routeData:c}=dB(t,e.instanceId),l=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.variantsSelector)??{}}),u=Y(()=>{var e,t;return(e=o.value)!=null&&(e=e.data.productVariantsSelector)!=null&&(e=e.items)!=null&&e.length?(t=o.value)==null?void 0:t.data.productVariantsSelector.items:[]}),d=Y(()=>{var e;return l.value.visible!==!1&&(((e=u.value)==null?void 0:e.length)??0)>0}),f=e=>{if(l.value.unavailableValuesBehavior===`hidden`){var t;return((t=e.values)==null?void 0:t.filter(e=>e.match===!0))||[]}return e.values||[]},p=M({});return{root:t,componentName:n,isReady:r,isWebComponent:i,store:o,t:s,componentOptions:l,variants:u,visible:d,isDropdownOpen:p,VariantAttributeDisplayModeEnum:su,getVariantValues:f,details:async e=>{var t;if(!((t=e.product)!=null&&t.inactive)&&!(l.value.unavailableValuesBehavior===`disabled`&&!e.match)&&c.value&&e.product)try{var r;await((r=a.value)==null?void 0:r.execute(new bp(e.product).from(n)))}catch{}},toggleDropdown:e=>{p.value[e]=!p.value[e]},getSelectedValue:e=>{var t;return((t=e.values)==null?void 0:t.find(e=>e.selected))||null},Clickable:wm}}}),AW={key:0},jW={class:`mb-4 ext-attr-group`},MW={class:`mb-3`},NW={class:`d-flex justify-content-between align-items-center mb-3`},PW={class:`fw-bold`},FW={key:0,class:`variant-values`},IW={key:0,class:`d-flex flex-wrap gap-2 mb-3`},LW=[`disabled`,`onClick`],RW={key:1,class:`mb-3`},zW={class:`d-flex align-items-center`},BW={class:`me-2 flex-shrink-0`,style:{width:`2rem`}},VW=[`src`,`alt`],HW={class:`flex-grow-1 min-w-0`},UW={class:`fw-medium text-truncate`},WW=[`aria-expanded`,`onClick`,`onKeydown`],GW={class:`d-flex align-items-center flex-grow-1`},KW={class:`me-2 flex-shrink-0`,style:{width:`1.5rem`}},qW=[`src`,`alt`],JW={class:`flex-grow-1 min-w-0`},YW={class:`text-truncate d-block`},XW={class:`fw-medium`},ZW={key:1,class:`text-muted`},QW={key:2,class:`mb-3`},$W={class:`row g-2`},eG=[`title`,`onClick`,`onKeydown`],tG={class:`variant-image-container d-flex align-items-center justify-content-center position-relative`,style:{width:`100%`,"aspect-ratio":`1`,"min-height":`60px`}},nG=[`src`,`alt`],rG={key:1,class:`variant-image-placeholder text-muted d-flex align-items-center justify-content-center h-100`};function iG(e,t,n,r,i,a){let o=R(`Clickable`),s=R(`Dropdown`),c=R(`Icon`),l=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component mt-4`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,AW,[G(`div`,jW,[G(`h4`,MW,j(e.t(`Variants`)),1),(H(!0),U(V,null,z(e.variants,(t,n)=>(H(),U(`div`,{key:t.attributeCode||n,class:`mb-4`},[G(`div`,NW,[G(`div`,null,[F(G(`span`,PW,null,512),[[l,t.attributeName]])])]),e.getVariantValues(t).length?(H(),U(`div`,FW,[t.displayMode===e.VariantAttributeDisplayModeEnum.PILLS?(H(),U(`div`,IW,[(H(!0),U(V,null,z(e.getVariantValues(t),t=>(H(),U(`button`,{key:t.attributeValueText,type:`button`,class:A([`btn btn-sm`,{active:t.selected,"btn-outline-primary":e.componentOptions.unavailableValuesBehavior!==`disabled`||t.match,"btn-outline-secondary":e.componentOptions.unavailableValuesBehavior===`disabled`&&!t.match}]),disabled:e.componentOptions.unavailableValuesBehavior===`disabled`&&!t.match,onClick:n=>t.product&&e.details(t)},[G(`span`,null,j(t.attributeValueText),1)],10,LW))),128))])):t.displayMode===e.VariantAttributeDisplayModeEnum.DROPDOWN?(H(),U(`div`,RW,[K(s,{open:e.isDropdownOpen[t.attributeCode||``],"onUpdate:open":n=>e.isDropdownOpen[t.attributeCode||``]=n,width:`100%`,items:e.getVariantValues(t).map(e=>({type:`value`,value:e}))},{item:P(({item:n})=>[n.type===`value`?(H(),W(o,{key:0,class:A([`dropdown-item py-2`,{active:n.value.selected,disabled:e.componentOptions.unavailableValuesBehavior===`disabled`&&!n.value.match}]),onClick:r=>{e.toggleDropdown(t.attributeCode||``),e.details(n.value)}},{default:P(()=>{var e;return[G(`div`,zW,[G(`div`,BW,[(e=n.value.product)!=null&&(e=e.images)!=null&&e.length?(H(),U(`img`,{key:0,src:n.value.product.images[0].thumbnailUrl,alt:n.value.name,class:`img-fluid rounded border`,style:{"max-height":`1.5rem`,"object-fit":`contain`},loading:`lazy`},null,8,VW)):J(``,!0)]),G(`div`,HW,[G(`div`,UW,j(n.value.attributeValueText),1)])])]}),_:2},1032,[`class`,`onClick`])):J(``,!0)]),activator:P(({on:n})=>{var r,i;return[G(`div`,Oa({class:`form-select d-flex align-items-center`,tabindex:`0`,role:`combobox`,"aria-expanded":e.isDropdownOpen[t.attributeCode||``]?`true`:`false`,"aria-haspopup":`listbox`,style:{cursor:`pointer`,"background-color":`white`}},qr(n,!0),{onClick:n=>e.toggleDropdown(t.attributeCode||``),onKeydown:[Ns(n=>e.toggleDropdown(t.attributeCode||``),[`enter`]),Ns(X(n=>e.toggleDropdown(t.attributeCode||``),[`prevent`]),[`space`])]}),[G(`div`,GW,[e.getSelectedValue(t)?(H(),U(V,{key:0},[G(`div`,KW,[(r=e.getSelectedValue(t).product)!=null&&(r=r.images)!=null&&r.length?(H(),U(`img`,{key:0,src:(i=e.getSelectedValue(t))==null||(i=i.product)==null||(i=i.images)==null||(i=i[0])==null?void 0:i.thumbnailUrl,alt:e.getSelectedValue(t).attributeValueText,class:`img-fluid rounded border`,style:{"max-height":`1.5rem`,"object-fit":`contain`}},null,8,qW)):J(``,!0)]),G(`div`,JW,[G(`span`,YW,[G(`span`,XW,j(e.getSelectedValue(t).attributeValueText),1)])])],64)):(H(),U(`span`,ZW,j(e.t(`SelectVariant`)),1))])],16,WW)]}),_:2},1032,[`open`,`onUpdate:open`,`items`])])):t.displayMode===e.VariantAttributeDisplayModeEnum.IMAGES?(H(),U(`div`,QW,[G(`div`,$W,[(H(!0),U(V,null,z(e.getVariantValues(t),t=>{var n;return H(),U(`div`,{key:t.attributeValueText,class:`col-xl-2 col-lg-3 col-md-4 col-sm-4 col-4`},[G(`div`,{class:A([`card h-100 text-center position-relative`,{"border-primary":t.selected,"opacity-50":e.componentOptions.unavailableValuesBehavior===`disabled`&&!t.match,"border-1":t.selected}]),title:t.attributeValueText,role:`button`,tabindex:`0`,style:k({cursor:e.componentOptions.unavailableValuesBehavior===`disabled`&&!t.match?`not-allowed`:`pointer`,transition:`all 0.15s ease-in-out`}),onClick:n=>t.product&&e.details(t),onKeydown:[Ns(n=>t.product&&e.details(t),[`enter`]),Ns(X(n=>t.product&&e.details(t),[`prevent`]),[`space`])]},[G(`div`,tG,[G(`div`,null,[(n=t.product)!=null&&(n=n.images)!=null&&n.length?(H(),U(`img`,{key:0,src:t.product.images[0].thumbnailUrl,alt:t.attributeValueText,class:`variant-image img-fluid`,style:{"max-height":`100%`,"max-width":`100%`,"object-fit":`contain`}},null,8,nG)):(H(),U(`div`,rG,[K(c,{name:`photo-picture`,size:24})]))])])],46,eG)])}),128))])])):J(``,!0)])):J(``,!0)]))),128))])])):J(``,!0)],2)}var aG=Q(kW,[[`render`,iG]]),oG=L({name:`pis-products-details-variants-table`,components:{Icon:$h,Clickable:wm,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,t:s,routeData:c}=dB(t,e.instanceId),l=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.variantsTable)??{}}),u=Y(()=>{var e,t;return(e=o.value)!=null&&(e=e.data.productVariantsTable)!=null&&(e=e.items)!=null&&e.length?(t=o.value)==null?void 0:t.data.productVariantsTable.items:[]}),d=Y(()=>{var e;return l.value.visible!==!1&&(((e=u.value)==null?void 0:e.length)??0)>0}),f=M(),p=M(),m=e=>{let t=u.value.find(t=>t.attributeCode===e);return(t==null?void 0:t.products)!==void 0&&t.variantAttributes!==void 0},h=Y(()=>u.value.find(e=>e.attributeCode===f.value));I(u,e=>{var t,n;h.value||(f.value=((t=e.find(e=>e.products!==void 0&&e.variantAttributes!==void 0))==null?void 0:t.attributeCode)??((n=e[0])==null?void 0:n.attributeCode))},{immediate:!0});let g=async e=>{if(e!==f.value&&p.value!==e){if(m(e)){f.value=e;return}p.value=e;try{var t;await((t=a.value)==null?void 0:t.execute(new Lp({attributeCode:e}).from(n))),m(e)&&(f.value=e)}catch{}finally{p.value===e&&(p.value=void 0)}}},_=async e=>{if(!(e!=null&&e.inactive)&&c.value&&e)try{var t;await((t=a.value)==null?void 0:t.execute(new bp(e).from(n)))}catch{}};return{root:t,componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,t:s,componentOptions:l,groups:u,selectedGroup:h,loadingAttributeCode:p,selectGroup:g,visible:d,attrValue:Us,Clickable:wm,details:_,reactiveContext:lg,cellCtx:hg(e=>({col:e.col,group:e.group,item:e.item,instance:a.value,t:s,attrValue:Us,details:_}))}}}),sG={key:0},cG={class:`mb-4 ext-attr-group`},lG={class:`pis-heading ext-attr-group-heading`},uG=[`aria-label`],dG=[`aria-pressed`,`aria-busy`,`disabled`,`onClick`],fG={key:0,class:`mb-4`},pG={class:`table-responsive position-relative d-none d-md-block`,style:{"min-height":`3rem`,"overflow-x":`auto`}},mG={class:`table table-sm table-striped`},hG={key:0,style:{width:`80px`}},gG={class:`table-light`},_G={key:0,class:`text-center border-top-0 ps-4 pe-4`},vG={key:0,class:`text-center align-middle`},yG={key:0,class:`d-flex align-items-center justify-content-center`,style:{height:`40px`}},bG=[`src`],xG={key:1,class:`d-flex align-items-center justify-content-center text-muted`,style:{height:`40px`}},SG={key:1},CG={key:1,class:`fw-bold`},wG={key:2},TG={class:`d-flex flex-wrap gap-1`},EG={class:`mt-1`},DG={class:`badge bg-primary text-white variant-value-badge`,style:{"font-size":`0.7rem`}},OG={key:3},kG={class:`d-md-none`},AG={class:`card-body p-3`},jG={class:`d-flex align-items-start mb-2`},MG={key:0,class:`flex-shrink-0 me-3`},NG={key:0,style:{width:`60px`,height:`60px`}},PG=[`src`],FG={key:1,class:`d-flex align-items-center justify-content-center text-muted rounded border`,style:{width:`60px`,height:`60px`}},IG={class:`flex-grow-1 min-w-0`},LG={class:`mb-2`},RG={key:1,class:`fw-bold text-break`},zG={class:`mb-2`},BG={class:`badge bg-primary text-white variant-value-badge`,style:{"font-size":`0.7rem`}},VG={class:`mb-3`},HG={class:`d-flex flex-wrap gap-1`},UG={key:0},WG={class:`text-muted d-block`},GG={key:1,class:`text-break`};function KG(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Icon`),c=R(`Clickable`),l=Hr(`safe-html`);return H(),U(`div`,{id:`pis-anchor-variants-table`,ref:`root`,class:A([`pis-component mt-4`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,sG,[G(`div`,cG,[G(`h4`,lG,j(e.t(`VariantProducts`)),1),G(`div`,{class:`d-flex flex-wrap gap-2 mb-3`,role:`group`,"aria-label":e.t(`VariantProducts`)},[(H(!0),U(V,null,z(e.groups,t=>{var n,r;return F((H(),U(`button`,{key:t.attributeCode,type:`button`,class:A([`btn btn-sm variant-group-pill`,t.attributeCode===((n=e.selectedGroup)==null?void 0:n.attributeCode)?`btn-primary`:`btn-outline-primary`]),"aria-pressed":t.attributeCode===((r=e.selectedGroup)==null?void 0:r.attributeCode),"aria-busy":e.loadingAttributeCode===t.attributeCode,disabled:e.loadingAttributeCode===t.attributeCode,onClick:n=>e.selectGroup(t.attributeCode)},null,10,dG)),[[l,t.attributeName+`: `+t.attributeValueText]])}),128))],8,uG),e.selectedGroup?(H(),U(`div`,fG,[G(`div`,pG,[G(`table`,mG,[G(`colgroup`,null,[e.componentOptions.showImages===!1?J(``,!0):(H(),U(`col`,hG)),(H(!0),U(V,null,z(e.componentOptions.columns,(e,t)=>(H(),U(`col`,{key:t,style:k({width:e.width})},null,4))),128))]),G(`thead`,gG,[G(`tr`,null,[e.componentOptions.showImages===!1?J(``,!0):(H(),U(`th`,_G,[...t[0]||(t[0]=[G(`span`,{class:`ms-1 me-1`},null,-1)])])),(H(!0),U(V,null,z(e.componentOptions.columns,(t,n)=>(H(),U(`th`,{key:n,class:`border-top-0`},[t.headerTemplate?(H(),W(o,{key:0,callbacks:t.headerTemplate,ctx:e.reactiveContext({t:e.t,col:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(t.caption),1)],64))]))),128))])]),G(`tbody`,null,[(H(!0),U(V,null,z(e.selectedGroup.products??[],t=>{var n;return H(),U(`tr`,{key:`${e.selectedGroup.attributeCode}-${t.productId}`},[e.componentOptions.showImages===!1?J(``,!0):(H(),U(`td`,vG,[(n=t.images)!=null&&n.length?(H(),U(`div`,yG,[G(`img`,{src:t.images[0].thumbnailUrl,class:`img-fluid`,style:{"max-height":`40px`,"object-fit":`contain`}},null,8,bG)])):(H(),U(`div`,xG,[K(s,{name:`photo-picture`,size:24})]))])),(H(!0),U(V,null,z(e.componentOptions.columns,(n,r)=>(H(),U(`td`,{key:r,class:`align-middle`},[n.cellTemplate?(H(),W(o,{key:0,callbacks:n.cellTemplate,ctx:e.cellCtx({item:t,col:n,group:e.selectedGroup})},null,8,[`callbacks`,`ctx`])):n.dataField===`ProductName`?(H(),U(`div`,SG,[t.productId?(H(),W(c,{key:0,class:`text-decoration-none fw-bold`,onClick:n=>e.details(t)},{default:P(()=>[q(j(e.attrValue(t,`#DisplayName`)),1)]),_:2},1032,[`onClick`])):(H(),U(`span`,CG,j(e.attrValue(t,`#DisplayName`)),1))])):n.dataField===`VariantAttributes`?(H(),U(`div`,wG,[G(`div`,TG,[(H(!0),U(V,null,z(e.selectedGroup.variantAttributes??[],(n,r)=>F((H(),U(`span`,{key:r,class:`badge bg-light text-dark border variant-value-badge`})),[[l,n.attributeName+`: `+e.attrValue(t,n.attributeCode)]])),128))]),G(`div`,EG,[F(G(`span`,DG,null,512),[[l,e.selectedGroup.attributeName+`: `+e.attrValue(t,e.selectedGroup.attributeCode)]])])])):(H(),U(`div`,OG,j(e.attrValue(t,n.dataField)),1))]))),128))])}),128))])])]),G(`div`,kG,[(H(!0),U(V,null,z(e.selectedGroup.products??[],t=>{var n;return H(),U(`div`,{key:`mobile-${e.selectedGroup.attributeCode}-${t.productId}`,class:`card mb-3 border`},[G(`div`,AG,[G(`div`,jG,[e.componentOptions.showImages===!1?J(``,!0):(H(),U(`div`,MG,[(n=t.images)!=null&&n.length?(H(),U(`div`,NG,[G(`img`,{src:t.images[0].thumbnailUrl,class:`img-fluid rounded`,style:{width:`100%`,height:`100%`,"object-fit":`contain`,border:`1px solid #dee2e6`}},null,8,PG)])):(H(),U(`div`,FG,[K(s,{name:`photo-picture`})]))])),G(`div`,IG,[G(`div`,LG,[t.productId?(H(),W(c,{key:0,class:`text-decoration-none fw-bold text-break`,onClick:n=>e.details(t)},{default:P(()=>[q(j(e.attrValue(t,`#DisplayName`)),1)]),_:2},1032,[`onClick`])):(H(),U(`span`,RG,j(e.attrValue(t,`#DisplayName`)),1))]),G(`div`,zG,[F(G(`span`,BG,null,512),[[l,e.selectedGroup.attributeName+`: `+e.attrValue(t,e.selectedGroup.attributeCode)]])])])]),G(`div`,VG,[G(`div`,HG,[(H(!0),U(V,null,z(e.selectedGroup.variantAttributes??[],(n,r)=>F((H(),U(`span`,{key:r,class:`badge bg-light text-dark border variant-value-badge`,style:{"font-size":`0.7rem`}})),[[l,n.attributeName+`: `+e.attrValue(t,n.attributeCode)]])),128))])]),(H(!0),U(V,null,z(e.componentOptions.columns,(n,r)=>(H(),U(`div`,{key:r,class:`mb-2`},[n.dataField!==`ProductName`&&n.dataField!==`VariantAttributes`?(H(),U(`div`,UG,[G(`small`,WG,j(n.caption)+`:`,1),n.cellTemplate?(H(),W(o,{key:0,callbacks:n.cellTemplate,ctx:e.cellCtx({item:t,col:n,group:e.selectedGroup})},null,8,[`callbacks`,`ctx`])):(H(),U(`span`,GG,j(e.attrValue(t,n.dataField)||`-`),1))])):J(``,!0)]))),128))])])}),128))])])):J(``,!0)])])):J(``,!0)],2)}var qG=Q(oG,[[`render`,KG],[`__scopeId`,`data-v-3fc29d33`]]),JG=L({name:`pis-products-details-actions`,components:{MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s,emit:c}=dB(t,e.instanceId,[]);return{root:t,componentName:r,isReady:i,isWebComponent:a,store:o,instance:n,item:Y(()=>{var e;return(e=o.value)==null||(e=e.data.productDetail)==null?void 0:e.item}),componentOptions:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.actions)??{}}),emit:c,t:s,reactiveContext:lg}}}),YG={key:0},XG={key:0,class:`mt-2`};function ZG(e,t,n,r,i,a){let o=R(`MountPoint`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.item?(H(),U(`div`,YG,[e.componentOptions.actionTemplate?(H(),U(`div`,XG,[K(o,{callbacks:e.componentOptions.actionTemplate,ctx:e.reactiveContext({instance:e.instance,item:e.item,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)])):J(``,!0)],2)}var QG=Q(JG,[[`render`,ZG]]),$G=L({name:`Tab`,props:{title:{type:String,default:void 0},icon:{type:String,default:void 0},loading:Boolean,count:{type:[String,Number],default:void 0},extclass:{type:String,default:void 0}}});function eK(e,t,n,r,i,a){return B(e.$slots,`default`)}var tK=Q($G,[[`render`,eK]]),nK=L({name:`Tabs`,components:{Clickable:wm,Icon:$h,Spinner:My},props:{modelValue:{type:Number,default:0},desktop:Boolean},emits:[`update:modelValue`],setup(e,{slots:t}){return{tabItems:Y(()=>t&&t.default?t.default().filter(({type:e})=>e.name===`Tab`):[])}}}),rK={key:0},iK={class:`nav nav-tabs mb-3`,role:`tablist`},aK={key:2,class:`badge rounded-pill bg-secondary text-body ms-1 small`},oK=[`id`],sK={key:1},cK={class:`my-4 d-flex align-items-center mb-0 mt-5`};function lK(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Spinner`),c=R(`Clickable`);return e.desktop?(H(),U(`div`,rK,[G(`ul`,iK,[(H(!0),U(V,null,z(e.tabItems,(t,n)=>{var r;return H(),U(`li`,{key:n,class:A([(r=t.props)==null?void 0:r.extclass])},[K(c,{class:A([`nav-link d-flex align-items-center`,{active:n===e.modelValue}]),role:`tab`,"aria-selected":n===e.modelValue?`true`:`false`,"aria-controls":`tabpanel-${n}`,onClick:t=>e.$emit(`update:modelValue`,n)},{default:P(()=>{var e,n,r,i,a;return[(e=t.props)!=null&&e.icon?(H(),W(o,{key:0,name:t.props.icon,class:`me-1`,size:24},null,8,[`name`])):J(``,!0),q(` `+j((n=t.props)==null?void 0:n.title)+` `,1),(r=t.props)!=null&&r.loading?(H(),W(s,{key:1,class:`ms-1`,sm:``})):J(``,!0),!((i=t.props)!=null&&i.loading)&&(a=t.props)!=null&&a.count?(H(),U(`span`,aK,j(t.props.count),1)):J(``,!0)]}),_:2},1032,[`aria-selected`,`aria-controls`,`class`,`onClick`])],2)}),128))]),(H(!0),U(V,null,z(e.tabItems,(t,n)=>(H(),U(`div`,{id:`tabpanel-${n}`,key:n,role:`tabpanel`,style:k({display:n===e.modelValue?`block`:`none`})},[(H(),W(Vr(t)))],12,oK))),128))])):(H(),U(`div`,sK,[(H(!0),U(V,null,z(e.tabItems,(e,n)=>{var r,i,a;return H(),U(`div`,{key:n},[G(`h4`,cK,[(r=e.props)!=null&&r.isLoading?(H(),W(s,{key:0,class:`me-2`,sm:``})):(i=e.props)!=null&&i.icon?(H(),W(o,{key:1,name:e.props.icon,class:`me-2`},null,8,[`name`])):J(``,!0),q(` `+j((a=e.props)==null?void 0:a.title),1)]),t[0]||(t[0]=G(`hr`,{class:`mt-2`,style:{height:`2px`}},null,-1)),(H(),W(Vr(e)))])}),128))]))}var uK=L({name:`pis-products-details-data`,components:{Tabs:Q(nK,[[`render`,lK]]),Tab:tK,NavigationBtns:zB,Arrow:qb,Btn:Iy,ProductDetailsRelatedLinks:qU,ProductDetailsAttributeGroups:lU,ProductDetailsRelationships:$U,ProductDetailsNavigation:LU,ProductDetailsClassifications:yU,Message:NE,ProductDetailsVariantsTable:qG},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(0),{componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,routeData:c,t:l,widerThan:u}=dB(t,e.instanceId,[$.ProductClassifications,$.AttributeGroups,$.ProductRelationships,$.RelatedLinks]),d=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.data}),f=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null||(e=e.classifications)==null?void 0:e.visible}),p=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null||(e=e.relatedLinks)==null?void 0:e.visible}),m=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null||(e=e.data)==null||(e=e.downloads)==null?void 0:e.visible}),h=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null||(e=e.data)==null||(e=e.downloads)==null?void 0:e.loading}),g=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null||(e=e.data)==null||(e=e.downloads)==null?void 0:e.count}),_=Y(()=>{var e;return((e=s.value)==null||(e=e.data.productDetail)==null?void 0:e.item)!=null}),v=Y(()=>{var e,t;if(!((e=d.value)!=null&&e.showTabCounts))return;var n=(t=s.value)==null||(t=t.data.productClassifications)==null?void 0:t.items;if(!n)return 0;let r=0;for(let e in n)n[e].forEach(()=>{r++});return r}),y=Y(()=>{var e,t;if((e=d.value)!=null&&e.showTabCounts){var n=(t=s.value)==null||(t=t.data.relatedLinks)==null?void 0:t.items;return n?n.length:0}});return I(()=>{var e;return(e=c.value)==null?void 0:e.view},(e,t)=>{e===`detail`&&e!==t&&(n.value=0)}),{root:t,itemLoaded:_,currentTabIndex:n,componentName:r,isReady:i,isWebComponent:a,store:s,classifications:f,instance:o,downloads:m,downloadsLoading:h,downloadsCount:g,relatedLinks:p,componentOptions:d,classificationCount:v,relatedLinkCount:y,t:l,widerThan:u,scrollTop:async()=>{try{var e,t;await((e=o.value)==null?void 0:e.execute(new Sp({productId:((t=c.value)==null||(t=t.detail)==null?void 0:t.productId)||``}).from(r)))}catch{}}}}});function dK(e,t,n,r,i,a){var o,s;let c=R(`ProductDetailsNavigation`),l=R(`ProductDetailsAttributeGroups`),u=R(`ProductDetailsRelationships`),d=R(`ProductDetailsVariantsTable`),f=R(`Tab`),p=R(`ProductDetailsClassifications`),m=R(`Message`),h=R(`ProductDetailsRelatedLinks`),g=R(`Tabs`),_=R(`NavigationBtns`),v=R(`Arrow`),y=R(`Btn`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.itemLoaded?(H(),U(V,{key:0},[K(g,{modelValue:e.currentTabIndex,"onUpdate:modelValue":t[0]||(t[0]=t=>e.currentTabIndex=t),class:`mt-4`,desktop:e.widerThan(`md`)},{default:P(()=>{var t,n,r,i;return[K(f,{title:e.t(`DetailsTabTitle`),icon:(t=e.componentOptions)!=null&&t.showTabIcons?`file-document`:void 0,extclass:`ext-tab-details`},{default:P(()=>[K(c),K(l),K(u),K(d)]),_:1},8,[`title`,`icon`]),e.classifications?(H(),W(f,{key:0,title:e.t(`CategoriesTabTitle`),icon:(n=e.componentOptions)!=null&&n.showTabIcons?`folder-open`:void 0,extclass:`ext-tab-categories`,count:e.classificationCount},{default:P(()=>[K(p)]),_:1},8,[`title`,`icon`,`count`])):J(``,!0),e.downloads?(H(),W(f,{key:1,icon:(r=e.componentOptions)!=null&&r.showTabIcons?`download`:void 0,title:e.t(`DownloadsTabTitle`),loading:e.downloadsLoading,count:e.downloadsCount,extclass:`ext-tab-downloads`},{default:P(()=>[B(e.$slots,`detail-downloads`,{},()=>[K(m,{class:`p-2`},{default:P(()=>[q(j(e.t(`DownloadsNotAvailable`)),1)]),_:1})])]),_:3},8,[`icon`,`title`,`loading`,`count`])):J(``,!0),e.relatedLinks?(H(),W(f,{key:2,title:e.t(`LinksTabTitle`),icon:(i=e.componentOptions)!=null&&i.showTabIcons?`link`:void 0,extclass:`ext-tab-related-links`,count:e.relatedLinkCount},{default:P(()=>[K(h)]),_:1},8,[`title`,`icon`,`count`])):J(``,!0)]}),_:3},8,[`modelValue`,`desktop`]),((o=e.componentOptions)==null?void 0:o.hideBottomNavigation)===!0?J(``,!0):(H(),U(`div`,{key:0,class:A([`d-flex d-grid gap-3 justify-content-end align-items-center mt-4 pb-2`,{"position-sticky bottom-0 bg-body":((s=e.componentOptions)==null?void 0:s.bottomNavigationSticky)===!0}]),style:{"z-index":`5`}},[e.widerThan(`sm`)?(H(),W(_,{key:0,instance:e.instance,t:e.t},null,8,[`instance`,`t`])):J(``,!0),K(y,{class:`ext-scroll-top`,onClick:X(e.scrollTop,[`prevent`])},{default:P(()=>[K(v,{dir:`up`,class:`me-2`}),q(` `+j(e.t(`BackToTop`)),1)]),_:1},8,[`onClick`])],2))],64)):J(``,!0)],2)}var fK=Q(uK,[[`render`,dK]]),pK=L({name:`pis-products-details-gallery`,components:{ImageGallery:xF,MountPoint:cg},props:{instanceId:{type:String,default:void 0},showPreview:{type:Boolean,default:!0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,t:s,emit:c}=dB(t,e.instanceId,[$.Breadcrumbs,$.ProductDetails]),l=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.gallery)??{}}),u=Y(()=>{var e;return((e=o.value)==null?void 0:e.data.productDetail)||void 0});return{root:t,componentName:r,componentOptions:l,isReady:i,isWebComponent:a,store:o,visible:Y(()=>{var e;return l.value.visible&&((e=u.value)==null?void 0:e.item)}),instance:n,productDetail:u,t:s,emit:c,reactiveContext:lg}}}),mK={key:0},hK={key:0};function gK(e,t,n,r,i,a){var o;let s=R(`MountPoint`),c=R(`ImageGallery`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,mK,[K(c,{"show-preview":e.showPreview,images:(o=e.productDetail)==null||(o=o.item)==null?void 0:o.images,"hide-thumbnails":e.componentOptions.hideThumbnailImages,"show-overlay-arrows":e.componentOptions.showOverlayArrows,title:e.t(`ProductGallery`)},{default:P(()=>{var t;return[e.componentOptions.imageOverlayTemplate?(H(),U(`div`,hK,[K(s,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.reactiveContext({instance:e.instance,item:(t=e.productDetail)==null?void 0:t.item,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)]}),_:1},8,[`show-preview`,`images`,`hide-thumbnails`,`show-overlay-arrows`,`title`])])):J(``,!0)],2)}var _K=Q(pK,[[`render`,gK]]),vK=L({name:`pis-products-details-header`,components:{Icon:$h,LinkSecondary:kE,NavigationBtns:zB},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,t:s,widerThan:c}=dB(t,e.instanceId,[$.Breadcrumbs,$.ProductDetails]),l=Y(()=>{var e;return(e=o.value)==null||(e=e.data.productDetail)==null?void 0:e.item});return{root:t,title:Y(()=>l.value?Us(l.value,`#DisplayName`):``),store:o,isReady:r,instance:a,componentName:n,isWebComponent:i,componentOptions:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.details)==null?void 0:e.header)??{}}),t:s,widerThan:c,printToPdf:async()=>{if(l.value)try{var e;await((e=a.value)==null?void 0:e.execute(new Zp({productId:l.value.productId}).from(n)))}catch{}},showPrintView:async()=>{if(l.value)try{var e;await((e=a.value)==null?void 0:e.execute(new Qp({productId:l.value.productId}).from(n)))}catch{}}}}}),yK={key:0,class:`d-flex flex-column`},bK={key:0},xK={class:`d-grid gap-3 d-md-flex justify-content-md-end align-items-center`},SK={class:`overflow-hidden text-nowrap`},CK={class:`overflow-hidden text-nowrap`};function wK(e,t,n,r,i,a){let o=R(`Icon`),s=R(`LinkSecondary`),c=R(`NavigationBtns`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(`div`,yK,[e.title?(H(),U(`div`,bK,[G(`h2`,null,j(e.title),1)])):J(``,!0),G(`div`,xK,[e.componentOptions.showPrintViewBtn?(H(),W(s,{key:0,class:`d-flex align-items-center ext-print-view`,onClick:e.showPrintView},{default:P(()=>[K(o,{name:`printer`,class:`me-1`,size:24}),G(`span`,SK,j(e.t(`ShowPrintView`)),1)]),_:1},8,[`onClick`])):J(``,!0),e.componentOptions.showPrintToPdfBtn?(H(),W(s,{key:1,class:`d-flex align-items-center ext-print-pdf`,onClick:t[0]||(t[0]=t=>e.printToPdf())},{default:P(()=>[K(o,{name:`printer`,class:`me-1`,size:24}),G(`span`,CK,j(e.t(`PrintToPdf`)),1)]),_:1})):J(``,!0),e.componentOptions.showBackBtn?(H(),W(c,{key:2,instance:e.instance,t:e.t},null,8,[`instance`,`t`])):J(``,!0)])])):J(``,!0)],2)}var TK=Q(vK,[[`render`,wK]]),EK=L({name:`pis-products-preview`,components:{Modal:Qy,AttributesTable:uF,ImageGallery:xF,PisReplacements:KB,Btn:Iy,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,routeData:s,t:c,emit:l}=dB(t,e.instanceId,[$.Products]),u=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.preview)==null?void 0:e.view)??{}}),d=Y({get:()=>{var e;return(e=o.value)==null?void 0:e.data.productPreview},set:e=>{var t;(t=o.value)!=null&&t.data&&`productPreview`in o.value.data&&(o.value.data.productPreview=e)}}),f=Y(()=>{var e;return(e=d.value)==null?void 0:e.item}),p=Y(()=>{var e;return((e=f.value)==null?void 0:e.attributes)||{}}),m=Y(()=>{var e;return((e=f.value)==null?void 0:e.replacements)||[]}),h=Y(()=>f.value?Us(f.value,`#DisplayName`):``),g=Y(()=>f.value?Ws(f.value,`#AllIdentifiers`):[]),_=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideDocumentLinks)==1}),v=async e=>{if(!(e!=null&&e.inactive)&&(y(),s.value&&e))try{var t;await((t=n.value)==null?void 0:t.execute(new bp(e).from(r)))}catch{}},y=()=>d.value=void 0;return{previewData:d,root:t,componentName:r,componentOptions:u,isReady:i,isWebComponent:a,store:o,routeData:s,instance:n,title:h,attributes:p,replacements:m,identifiers:g,item:f,hideDocumentLinks:_,replacementsVisible:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),attrValues:Ws,t:c,emit:l,details:v,attrValue:Us,close:y,reactiveContext:lg}}}),DK={key:0},OK={key:0,class:`mb-4`},kK={class:`row my-4`},AK={class:`col-12 col-md-4 mb-4`},jK={key:0},MK={class:`mt-4`},NK={class:`col-12 col-md-8 order-md-first`};function PK(e,t,n,r,i,a){let o=R(`Btn`),s=R(`PisReplacements`),c=R(`MountPoint`),l=R(`ImageGallery`),u=R(`AttributesTable`),d=R(`Modal`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(`div`,DK,[K(d,{show:e.previewData,"onUpdate:show":t[1]||(t[1]=t=>e.previewData=t),title:e.title,xl:``},{"header-actions":P(()=>[K(o,{onClick:t[0]||(t[0]=t=>e.item&&e.details(e.item))},{default:P(()=>[q(j(e.t(`ViewDetails`)),1)]),_:1})]),default:P(()=>{var t;return[e.identifiers.length?(H(),U(`div`,OK,[(H(!0),U(V,null,z(e.identifiers,e=>(H(),U(`div`,{key:e,class:`text-muted`},j(e),1))),128))])):J(``,!0),e.replacements&&e.replacements.length?(H(),W(s,{key:1,class:`my-4`,"show-icon":``,instance:e.instance,replacements:e.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),G(`div`,kK,[G(`div`,AK,[K(l,{"show-preview":``,"hide-thumbnails":``,"disable-modal":``,images:(t=e.item)==null?void 0:t.images,"show-overlay-arrows":!0,title:e.t(`ProductGallery`)},{default:P(()=>[e.componentOptions.imageOverlayTemplate?(H(),U(`div`,jK,[K(c,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.reactiveContext({instance:e.instance,item:e.item,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)]),_:1},8,[`images`,`title`]),G(`div`,MK,[e.componentOptions.actionTemplate?(H(),W(c,{key:0,callbacks:e.componentOptions.actionTemplate,ctx:e.reactiveContext({instance:e.instance,item:e.item,emit:e.emit,details:e.details,attrValue:e.attrValue,attrValues:e.attrValues,close:e.close,t:e.t})},null,8,[`callbacks`,`ctx`])):J(``,!0)])]),G(`div`,NK,[K(u,{instance:e.instance,attributes:e.attributes,"hide-document-links":e.hideDocumentLinks,t:e.t},null,8,[`instance`,`attributes`,`hide-document-links`,`t`])])])]}),_:1},8,[`show`,`title`])])):J(``,!0)],2)}var FK=Q(EK,[[`render`,PK]]),IK=L({name:`pis-products-search-breadcrumbs`,components:{Arrow:qb,Clickable:wm,Icon:$h},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o}=dB(t,e.instanceId,[$.Breadcrumbs]);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:o,breadcrumbs:Y(()=>{var e;return o.value?(e=o.value)==null||(e=e.data.breadcrumbs)==null?void 0:e.items:null}),visible:Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.breadcrumbs)==null?void 0:e.visible}),setClassification:async({cid:e})=>{if(a.value&&e)try{await a.value.execute(new Op({cid:e,clearSearch:!0}).from(n))}catch{}}}}}),LK={key:0},RK={key:0,class:`list-unstyled`},zK={class:`d-flex align-items-center`},BK={key:1};function VK(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`),c=R(`Arrow`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,LK,[e.breadcrumbs&&e.breadcrumbs.length>1?(H(),U(`ul`,RK,[(H(!0),U(V,null,z(e.breadcrumbs,(t,n)=>(H(),U(`li`,{key:n,class:`list-inline-item`},[G(`div`,zK,[n<e.breadcrumbs.length-1?(H(),W(s,{key:0,class:`d-flex align-items-center`,onClick:X(n=>e.setClassification(t),[`prevent`])},{default:P(()=>[n==0?(H(),W(o,{key:0,name:`house-home`,class:`me-1`,size:16})):J(``,!0),q(` `+j(t.name),1)]),_:2},1032,[`onClick`])):(H(),U(`span`,BK,j(t.name),1)),n<e.breadcrumbs.length-1?(H(),W(c,{key:2,class:`ms-2`})):J(``,!0)])]))),128))])):J(``,!0)])):J(``,!0)],2)}var HK=Q(IK,[[`render`,VK]]),UK=L({name:`pis-products-loading-indicator`,components:{Spinner:My},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,routeData:o}=dB(t,e.instanceId);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:a,routeData:o,showOverlay:pT(Y(()=>{var e;return r.value&&!!((e=a.value)!=null&&e.data.isLoadingData)}),Y(()=>{var e,t;return!!((e=a.value)!=null&&(e=e.data.products)!=null&&(e=e.items)!=null&&e.length)||!!((t=a.value)!=null&&t.data.productDetail)}))}}}),WK={ref:`root`,class:`pis-component position-relative`},GK={class:`position-absolute start-50 top-50`,style:{"z-index":`5`}};function KK(e,t,n,r,i,a){let o=R(`Spinner`);return H(),U(`div`,WK,[e.showOverlay?(H(),U(V,{key:0},[G(`div`,GK,[B(e.$slots,`loader`,{},()=>[K(o)])]),t[0]||(t[0]=G(`div`,{class:`position-absolute top-0 start-0 end-0 bottom-0 bg-body`,style:{"z-index":`4`,opacity:`0.5`}},null,-1))],64)):J(``,!0),B(e.$slots,`default`)],512)}var qK=Q(UK,[[`render`,KK]]),JK=e=>!e||e===`ROOT`,YK=L({components:{Icon:$h,Clickable:wm},props:{items:{type:Array,default:()=>[]},iterationKey:{type:String,required:!0},namingKey:{type:String,required:!0}},emits:[`click-item`,`remove-item`],methods:{getItemValue(e,t){return e[t]}}}),XK={class:`list-group`},ZK={class:`pis-label text-break`};function QK(e,t,n,r,i,a){let o=R(`Icon`),s=R(`Clickable`);return H(),U(`div`,XK,[(H(!0),U(V,null,z(e.items,t=>(H(),W(s,{key:String(e.getItemValue(t,e.iterationKey)),class:`list-group-item list-group-item-action d-flex align-items-start border-0`,onClick:X(n=>e.$emit(`click-item`,t),[`prevent`])},{default:P(()=>[G(`span`,ZK,j(e.getItemValue(t,e.namingKey)),1),K(s,{class:`ms-auto ext-remove`,onClick:X(n=>e.$emit(`remove-item`,t),[`prevent`])},{default:P(()=>[K(o,{name:`cross-close`,size:16})]),_:1},8,[`onClick`])]),_:2},1032,[`onClick`]))),128))])}var $K=Q(YK,[[`render`,QK]]),eq=L({components:{Removable:$K},props:{categories:{type:Array,default:void 0}},emits:[`click-item`,`remove-item`]});function tq(e,t,n,r,i,a){let o=R(`Removable`);return H(),W(o,{"iteration-key":`cid`,"naming-key":`name`,items:e.categories,onClickItem:t[0]||(t[0]=t=>e.$emit(`click-item`,t)),onRemoveItem:t[1]||(t[1]=t=>e.$emit(`remove-item`,t))},null,8,[`items`])}var nq=L({components:{LinkSecondary:kE,Card:SE,FavoriteCategoriesList:Q(eq,[[`render`,tq]]),Message:NE,Arrow:qb,Icon:$h,Modal:Qy},props:{isMobile:Boolean,instanceId:{type:String,default:void 0},t:{type:Function,required:!0},mobileShow:Boolean},emits:[`update:mobileShow`],setup(e){let t=M(),n=M(!0),r=Pf.Products.getInstance(e.instanceId),i=Y(()=>{var e;return((e=r.store)==null?void 0:e.options.appSettings)??{}}),a=Y(()=>{var e;return((e=r.store)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.favoriteCategories)??{}}),o=Y(()=>i.value.treeType===ou.PRODUCTS?a.value.productCids:a.value.partCids),s=Y(()=>{var e,t;return i.value.treeType===ou.PRODUCTS?((e=r.store)==null||(e=e.data.favoriteProductCategories)==null?void 0:e.items)??[]:((t=r.store)==null||(t=t.data.favoritePartCategories)==null?void 0:t.items)??[]}),c=Y(()=>{var e;return(e=r.store)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.favoriteCategories)==null?void 0:e.visible}),l=Y(()=>{var e;return n.value?(e=s.value)==null?void 0:e.slice(0,a.value.maxCategoriesVisible):s.value}),u=Y(()=>s.value&&s.value.length>(a.value.maxCategoriesVisible??0)),d=async({cid:e})=>{if(r&&e)try{await r.execute(new Op({cid:e,clearSearch:!0}).from(`favorite-categories`))}catch{}},f=async({cid:e})=>{if(r&&e)try{await r.execute(new Xp({cid:e}).from(`favorite-categories`))}catch{}},p=()=>{n.value=!n.value},m=Y(()=>{var e,t,n;return((e=r.router.routeData)==null||(e=e.search)==null?void 0:e.cid)&&!JK((t=r.router.routeData)==null||(t=t.search)==null?void 0:t.cid)&&(o.value&&o.value.indexOf((n=r.router.routeData.search)==null?void 0:n.cid)<0||!o.value)}),h=Y(()=>{var e,t;return o.value&&((e=r.router.routeData)==null||(e=e.search)==null?void 0:e.cid)&&o.value.indexOf((t=r.router.routeData.search)==null?void 0:t.cid)>=0}),g=async()=>{var e;if(r&&(e=r.router.routeData.search)!=null&&e.cid)try{var t;await r.execute(new Yp({cid:(t=r.router.routeData.search)==null?void 0:t.cid}).from(`favorite-categories`)),await v()}catch{}},_=async()=>{var e;if(r&&(e=r.router.routeData)!=null&&(e=e.search)!=null&&e.cid)try{var t;await r.execute(new Xp({cid:(t=r.router.routeData.search)==null?void 0:t.cid}).from(`favorite-categories`))}catch{}},v=async()=>{if(o.value){let n=new Jp({cids:o.value});try{let a=await r.execute(n);if(a){var e,t;a.items&&(a.items=[...a.items].sort((e,t)=>e.name<t.name?-1:+(e.name>t.name))),i.value.treeType===ou.PRODUCTS&&(e=r.store)!=null&&e.data?r.store.data.favoriteProductCategories=a:i.value.treeType===ou.PARTS&&(t=r.store)!=null&&t.data&&(r.store.data.favoritePartCategories=a)}}catch{return}}else{var n,a;i.value.treeType===ou.PRODUCTS&&(n=r.store)!=null&&(n=n.data)!=null&&(n=n.favoriteProductCategories)!=null&&n.items?r.store.data.favoriteProductCategories.items=[]:i.value.treeType===ou.PARTS&&(a=r.store)!=null&&(a=a.data)!=null&&(a=a.favoritePartCategories)!=null&&a.items&&(r.store.data.favoritePartCategories.items=[])}};return v(),{root:t,componentOptions:a,trimList:n,visible:c,categories:s,categoriesTrimmed:l,showMoreBtn:u,setCategory:d,removeCategory:f,showAllCategories:p,addCurrentCategory:g,removeCurrentCategory:_,showAddBtn:m,showRemoveBtn:h}}}),rq={class:`row gx-5 gy-3 h-100`,style:{"min-height":`400px`}},iq={class:A(`col-12`)},aq={key:1,class:`h-100 d-flex align-items-center`},oq={class:`w-100 d-flex align-items-center justify-content-center`},sq={key:1,class:`card-body`},cq={key:1,class:`card-body`},lq={key:2,class:`card-body`},uq={key:3,class:`card-body`};function dq(e,t,n,r,i,a){let o=R(`FavoriteCategoriesList`),s=R(`Message`),c=R(`Icon`),l=R(`LinkSecondary`),u=R(`Modal`),d=R(`Arrow`),f=R(`Card`);return e.isMobile?(H(),W(u,{key:0,show:e.mobileShow,title:e.t(`FavoriteCategoriesModalTitle`),xl:``,"onUpdate:show":t[0]||(t[0]=t=>e.$emit(`update:mobileShow`))},{footer:P(()=>[G(`div`,oq,[e.showAddBtn?(H(),W(l,{key:0,class:`ext-add`,onClick:X(e.addCurrentCategory,[`prevent`])},{default:P(()=>[K(c,{name:`plus-add`,class:`me-2`}),q(` `+j(e.t(`FavoriteCategoriesAddCurrentCategory`)),1)]),_:1},8,[`onClick`])):J(``,!0),e.showRemoveBtn?(H(),W(l,{key:1,class:`ext-remove`,onClick:X(e.removeCurrentCategory,[`prevent`])},{default:P(()=>[K(c,{name:`cross-close`,class:`me-2`}),q(` `+j(e.t(`FavoriteCategoriesRemoveCurrentCategory`)),1)]),_:1},8,[`onClick`])):J(``,!0)])]),default:P(()=>{var t,n;return[G(`div`,rq,[G(`div`,iq,[(t=e.categories)!=null&&t.length?(H(),U(V,{key:0},[(n=e.categories)!=null&&n.length?(H(),W(o,{key:0,categories:e.categories,onClickItem:e.setCategory,onRemoveItem:e.removeCategory},null,8,[`categories`,`onClickItem`,`onRemoveItem`])):J(``,!0)],64)):(H(),U(`div`,aq,[K(s,null,{default:P(()=>[q(j(e.t(`FavoriteCategoriesEmpty`)),1)]),_:1})]))])])]}),_:1},8,[`show`,`title`])):(H(),W(f,{key:1,class:`mb-4`,icon:e.componentOptions.icon&&`star`,header:e.t(`FavoriteCategories`),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{list:P(()=>{var t,n;return[(t=e.categories)!=null&&t.length?(H(),U(V,{key:0},[(n=e.categories)!=null&&n.length?(H(),W(o,{key:0,categories:e.categoriesTrimmed,onClickItem:e.setCategory,onRemoveItem:e.removeCategory},null,8,[`categories`,`onClickItem`,`onRemoveItem`])):J(``,!0),e.showMoreBtn?(H(),U(`div`,sq,[K(l,{onClick:X(e.showAllCategories,[`prevent`])},{default:P(()=>[K(d,{class:`me-2`,dir:e.trimList?`down`:`up`},null,8,[`dir`]),q(` `+j(e.trimList?e.t(`ShowAllCategories`):e.t(`HideAllCategories`))+` (`+j(e.categories.length)+`) `,1)]),_:1},8,[`onClick`])])):J(``,!0)],64)):(H(),U(`div`,cq,[K(s,null,{default:P(()=>[q(j(e.t(`FavoriteCategoriesEmpty`)),1)]),_:1})])),e.showAddBtn?(H(),U(`div`,lq,[K(l,{onClick:X(e.addCurrentCategory,[`prevent`])},{default:P(()=>[K(c,{name:`plus-add`,class:`me-2`}),q(` `+j(e.t(`FavoriteCategoriesAddCurrentCategory`)),1)]),_:1},8,[`onClick`])])):J(``,!0),e.showRemoveBtn?(H(),U(`div`,uq,[K(l,{onClick:X(e.removeCurrentCategory,[`prevent`])},{default:P(()=>[K(c,{name:`cross-close`,class:`me-2`}),q(` `+j(e.t(`FavoriteCategoriesRemoveCurrentCategory`)),1)]),_:1},8,[`onClick`])])):J(``,!0)]}),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`]))}var fq=Q(nq,[[`render`,dq]]),pq=L({components:{Removable:$K},props:{favoriteViews:{type:Array,default:void 0}},emits:[`click-item`,`remove-item`]});function mq(e,t,n,r,i,a){let o=R(`Removable`);return H(),W(o,{"iteration-key":`id`,"naming-key":`code`,items:e.favoriteViews,onClickItem:t[0]||(t[0]=t=>e.$emit(`click-item`,t)),onRemoveItem:t[1]||(t[1]=t=>e.$emit(`remove-item`,t))},null,8,[`items`])}var hq=Q(pq,[[`render`,mq]]),gq=L({components:{Btn:Iy,FormInputClearable:Mb},props:{instanceId:{type:String,default:void 0},fallbackCode:{type:String,default:void 0},favoriteViews:{type:Array,default:void 0},t:{type:Function,required:!0}},emits:[`on-form-submit`,`on-form-cancel`,`on-update`],setup(e,{emit:t}){let n=Pf.Products.getInstance(e.instanceId),r=M(``),i=M(``),a=Y(()=>!!i.value),o=Y(()=>{var e;return(e=n.router.routeData)==null||(e=e.search)==null?void 0:e.cid}),s=Y(()=>!JK(o.value)),c={favoriteCode:{[mb.required]:{}}},l=Y(()=>{if(o.value){var e;let r=(e=n.store)==null||(e=e.data.breadcrumbs)==null?void 0:e.items;if(r){var t;return(t=r[r.length-1])==null?void 0:t.name}}}),u=()=>(s.value?l.value:e.fallbackCode)||e.fallbackCode||``,d=e=>{i.value=e,p()},f=()=>{let t=r.value;if(t){var n;let r=(n=e.favoriteViews)==null?void 0:n.find(e=>e.id===t);if(r)return i.value=r.code,p()}return i.value=u(),p()},p=(e=!1)=>t(e?`on-form-submit`:`on-update`,{id:r.value,code:i.value});return I(()=>r.value,()=>f()),kr(()=>f()),{validators:c,favoriteID:r,isFormValid:a,favoriteCode:i,onUpdate:p,onFavoriteCodeUpdate:d}}}),_q={class:`d-block`},vq={class:`d-block pt-2`},yq={class:`form-label fw-bolder`},bq={value:``,selected:``},xq=[`value`],Sq={class:`form-label fw-bolder`},Cq={class:`d-flex justify-content-end mt-3`};function wq(e,t,n,r,i,a){let o=R(`FormInputClearable`),s=R(`Btn`);return H(),U(`div`,_q,[G(`form`,{onSubmit:t[3]||(t[3]=X(()=>{},[`prevent`]))},[G(`label`,vq,[G(`div`,yq,j(e.t(`FavoriteViewsSaveTo`)),1),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.favoriteID=t),class:`form-select`},[G(`option`,bq,j(e.t(`FavoriteViewsNew`)),1),(H(!0),U(V,null,z(e.favoriteViews,e=>(H(),U(`option`,{key:e.id,value:e.id},j(e.code),9,xq))),128))],512),[[Cs,e.favoriteID]])]),F(G(`label`,{class:A([`pt-2`,{"d-block":!e.favoriteID}])},[G(`div`,Sq,j(e.t(`FavoriteViewsCode`)),1),K(o,{"model-value":e.favoriteCode,validators:e.validators.favoriteCode,"onUpdate:modelValue":e.onFavoriteCodeUpdate},null,8,[`model-value`,`validators`,`onUpdate:modelValue`])],2),[[Mo,!e.favoriteID]]),t[4]||(t[4]=G(`hr`,null,null,-1)),G(`div`,Cq,[K(s,{class:`mx-2`,onClick:t[1]||(t[1]=X(t=>e.$emit(`on-form-cancel`),[`prevent`]))},{default:P(()=>[q(j(e.t(`Cancel`,!0)),1)]),_:1}),K(s,{disabled:!e.isFormValid,primary:``,onClick:t[2]||(t[2]=X(t=>e.onUpdate(!0),[`prevent`]))},{default:P(()=>[q(j(e.t(`Save`,!0)),1)]),_:1},8,[`disabled`])])],32)])}var Tq=L({components:{Card:SE,Modal:Qy,Arrow:qb,Message:NE,Confirmation:aE,LinkSecondary:kE,FavoriteViewsList:hq,FavoriteViewsSaveForm:Q(gq,[[`render`,wq]])},props:{instanceId:{type:String,default:void 0},isMobile:Boolean,mobileShow:Boolean,t:{type:Function,required:!0}},emits:[`update:mobileShow`],setup(e){let t=M(),n=Pf.Products.getInstance(e.instanceId),r=M(!0),i=M(``),a=M(``),o=M(!1),s=M(void 0),c=Y(()=>{var e;return(e=n.store)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.favoriteViews}),l=Y(()=>{var e;return(e=c.value)==null?void 0:e.visible}),u=Y(()=>{var e;return((e=c.value)==null?void 0:e.maxViewsVisible)||0}),d=Y(()=>{var e;return(e=n.router.routeData)==null||(e=e.search)==null?void 0:e.cid}),f=Y(()=>!JK(d.value)),p=Y(()=>{var e;return(e=n.router.routeData)==null||(e=e.search)==null||(e=e.filters)==null?void 0:e.rules.length}),m=Y(()=>{var e;return(e=n.router.routeData)==null||(e=e.search)==null?void 0:e.searchText}),h=Y(()=>{var e;return(e=c.value)==null?void 0:e.fallbackCode}),g=Y(()=>{var e;return((e=n.store)==null||(e=e.data.favoriteViews)==null?void 0:e.items)??[]}),_=Y(()=>g.value.length>u.value),v=Y(()=>!!a.value),y=Y(()=>r.value?(g.value??[]).slice(0,u.value):g.value),b=Y(()=>f.value||p.value||m.value),x=()=>r.value=!r.value,S=e=>{i.value=``,o.value=e},C=e=>s.value=e;return(async()=>{var e;let t=(e=c.value)==null?void 0:e.savedViewIds;if(t&&t.length&&!g.value.length)try{await n.execute(new Wp({ids:t}).from(`favorite-views`))}catch{}})(),{root:t,canSave:b,trimList:r,isVisible:l,favoriteID:i,showMoreBtn:_,isFormValid:v,favoriteCode:a,fallbackCode:h,favoriteViews:g,componentOptions:c,isUpdateModalVisible:o,favoriteViewsTrimmed:y,deleteConfirmationModalItem:s,updateModal:S,onFormUpdate:async({id:e,code:t},r=!1)=>{if(i.value=e,a.value=t,!(!r||!v.value))try{await n.execute(new Gp({id:e,code:t,routeData:n.router.routeData}).from(`favorite-views`)),o.value=!1}catch{}},onFormCancel:()=>o.value=!1,toggleTrimList:x,onFavoriteViewCheck:async e=>{try{await n.execute(new qp({favoriteView:e}).from(`favorite-views`))}catch{}},onFavoriteViewDelete:async e=>{if(e&&e.id)try{await n.execute(new Kp({id:e.id}).from(`favorite-views`))}catch{return}C(void 0)},updateDeleteConfirmationModal:C}}}),Eq={class:`row gx-5 gy-3 h-100`,style:{"min-height":`400px`}},Dq={class:`col-12`},Oq={key:1,class:`h-100 d-flex align-items-center`},kq={key:0,class:`card-body`},Aq={key:0,class:`card-body`},jq={key:1,class:`card-body`},Mq={key:2,class:`card-body`};function Nq(e,t,n,r,i,a){var o,s,c,l;let u=R(`FavoriteViewsList`),d=R(`Message`),f=R(`LinkSecondary`),p=R(`Modal`),m=R(`Arrow`),h=R(`Card`),g=R(`FavoriteViewsSaveForm`),_=R(`Confirmation`);return H(),U(V,null,[e.isMobile?(H(),W(p,{key:0,show:e.mobileShow,title:e.t(`FavoriteViewsModalTitle`),xl:``,"onUpdate:show":t[1]||(t[1]=t=>e.$emit(`update:mobileShow`))},{footer:P(()=>[e.canSave?(H(),U(`div`,kq,[K(f,{icon:`plus-add`,class:`ext-save`,onClick:t[0]||(t[0]=X(t=>e.updateModal(!0),[`prevent`]))},{default:P(()=>[q(j(e.t(`FavoriteViewsSave`)),1)]),_:1})])):J(``,!0)]),default:P(()=>[G(`div`,Eq,[G(`div`,Dq,[e.favoriteViews.length?(H(),W(u,{key:0,"favorite-views":e.favoriteViewsTrimmed,onClickItem:e.onFavoriteViewCheck,onRemoveItem:e.updateDeleteConfirmationModal},null,8,[`favorite-views`,`onClickItem`,`onRemoveItem`])):(H(),U(`div`,Oq,[K(d,null,{default:P(()=>[q(j(e.t(`FavoriteViewsEmpty`)),1)]),_:1})]))])])]),_:1},8,[`show`,`title`])):(H(),W(h,{key:1,class:`mb-4`,icon:((o=e.componentOptions)==null?void 0:o.icon)&&`star`,header:e.t(`FavoriteViews`),"use-markup":(s=e.componentOptions)==null?void 0:s.card,collapsed:(c=e.componentOptions)==null?void 0:c.collapsed},{list:P(()=>[e.favoriteViews.length?(H(),U(V,{key:0},[K(u,{"favorite-views":e.favoriteViewsTrimmed,onClickItem:e.onFavoriteViewCheck,onRemoveItem:e.updateDeleteConfirmationModal},null,8,[`favorite-views`,`onClickItem`,`onRemoveItem`]),e.showMoreBtn?(H(),U(`div`,Aq,[K(f,{onClick:X(e.toggleTrimList,[`prevent`])},{default:P(()=>[K(m,{class:`me-2`,dir:e.trimList?`down`:`up`},null,8,[`dir`]),q(` `+j(e.trimList?e.t(`FavoriteViewsShowMore`):e.t(`FavoriteViewsHideMore`))+` (`+j(e.favoriteViews.length)+`) `,1)]),_:1},8,[`onClick`])])):J(``,!0)],64)):(H(),U(`div`,jq,[K(d,null,{default:P(()=>[q(j(e.t(`FavoriteViewsEmpty`)),1)]),_:1})])),e.canSave?(H(),U(`div`,Mq,[K(f,{icon:`plus-add`,onClick:t[2]||(t[2]=X(t=>e.updateModal(!0),[`prevent`]))},{default:P(()=>[q(j(e.t(`FavoriteViewsSave`)),1)]),_:1})])):J(``,!0)]),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])),K(p,{show:e.isUpdateModalVisible,title:e.t(`FavoriteViewsSaveTitle`),"onUpdate:show":t[5]||(t[5]=t=>e.updateModal(!1))},{default:P(()=>[e.isUpdateModalVisible?(H(),W(g,{key:0,t:e.t,"instance-id":e.instanceId,"favorite-views":e.favoriteViews,"fallback-code":e.fallbackCode,onOnChange:t[3]||(t[3]=({id:t,code:n})=>e.onFormUpdate({id:t,code:n})),onOnFormSubmit:t[4]||(t[4]=({id:t,code:n})=>e.onFormUpdate({id:t,code:n},!0)),onOnFormCancel:e.onFormCancel},null,8,[`t`,`instance-id`,`favorite-views`,`fallback-code`,`onOnFormCancel`])):J(``,!0)]),_:1},8,[`show`,`title`]),K(_,{t:e.t,title:e.t(`FavoriteViewsConfirmDelete`,!1,[((l=e.deleteConfirmationModalItem)==null?void 0:l.code)??``]),item:e.deleteConfirmationModalItem,"onUpdate:show":t[6]||(t[6]=t=>e.updateDeleteConfirmationModal(void 0)),onConfirmationCancelled:t[7]||(t[7]=t=>e.updateDeleteConfirmationModal(void 0)),onConfirmationOk:t[8]||(t[8]=t=>e.onFavoriteViewDelete(e.deleteConfirmationModalItem))},null,8,[`t`,`title`,`item`])],64)}var Pq=Q(Tq,[[`render`,Nq]]),Fq=L({name:`SparePartTypeList`,props:{partTypes:{type:Array,default:void 0},currentPartType:{type:String,default:void 0}},emits:[`click-item`],data:()=>({isChecked:e=>ly(e)[0].checked})}),Iq={class:`list-group list-group-flush`},Lq={class:`form-check mb-0 lh-sm`},Rq=[`checked`,`onInput`],zq={class:`form-check-label user-select-none pis-label`};function Bq(e,t,n,r,i,a){return H(),U(`div`,Iq,[(H(!0),U(V,null,z(e.partTypes,t=>(H(),U(`label`,{key:t.type,class:`list-group-item list-group-item-action`},[G(`div`,Lq,[G(`input`,{type:`radio`,class:`form-check-input me-2 flex-shrink-0`,checked:e.currentPartType==t.type,onInput:n=>e.isChecked(n)&&e.$emit(`click-item`,t)},null,40,Rq),G(`span`,zq,j(t.name),1)])]))),128))])}var Vq=Q(Fq,[[`render`,Bq]]),Hq=L({name:`pis-products-search-mobile-nav`,components:{Btn:Iy,Modal:Qy,CategoriesList:Hy,FiltersNavigatorModal:tO,SparePartTypeList:Vq,Clickable:wm,FormInputClearable:Mb,Badge:ky,LinkSecondary:kE,FavoriteViews:Pq,FavoriteCategories:fq},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=M(!1),i=M(!1),a=M(!1),o=M(``),s=M(!1),c=M(!1),{componentName:l,isWebComponent:u,isReady:d,instance:f,store:p,routeData:m,t:h,useProductsFilters:g}=dB(t,e.instanceId,[$.Breadcrumbs]),{filtersAll:_,filtersPromoted:v,filtersAdditional:y,filtersModel:b,filtersFetched:x,filteredResultCount:S,fetchFilterValues:C,applyModelFilters:w,refreshResultCount:T,resetFiltersApplied:E}=g(),D=Y(()=>{var e;return((e=p.value)==null||(e=e.options.appSettings)==null?void 0:e.treeType)===ou.PARTS}),ee=Y(()=>{var e;return D.value&&((e=f.value)==null?void 0:e.registeredComponents.has(`pis-products-search-narrow-by-product`))}),O=Y(()=>{var e;let t=(e=p.value)==null||(e=e.data.sparePartMasterProducts)==null?void 0:e.items;if(t!=null&&t.length){let e=o.value.toLowerCase();return t.filter(t=>t.description.toLowerCase().includes(e)||t.productId.toLowerCase().includes(e))}return null}),te=Y(()=>{var e;return(e=m.value)==null||(e=e.search)==null?void 0:e.masterProductId}),ne=async({productId:e,description:t})=>{try{var r;await((r=f.value)==null?void 0:r.execute(new Ap({masterProductId:e,masterProductName:t}).from(l))),n.value=!1}catch{}},re=async()=>{try{var e;await((e=f.value)==null?void 0:e.execute(new Ap({masterProductId:void 0,masterProductName:void 0}).from(l))),n.value=!1}catch{}},ie=Y(()=>{var e;return((e=p.value)==null||(e=e.data.partTypes)==null?void 0:e.items)??[]}),ae=Y(()=>{var e;return D.value&&((e=f.value)==null?void 0:e.registeredComponents.has(`pis-products-search-part-types`))}),oe=Y(()=>{var e;return(e=f.value)==null||(e=e.router.routeData)==null||(e=e.search)==null?void 0:e.partsType}),se=async({type:e})=>{if(f.value&&e&&oe.value!=e)try{f.value.execute(new kp({partsType:e}).from(l)),r.value=!1}catch{}},ce=Y(()=>{var e,t,n;return((e=f.value)==null?void 0:e.registeredComponents.has(`pis-products-search-categories`))&&((t=p.value)==null||(t=t.options.components)==null||(t=t.search)==null||(t=t.categories)==null?void 0:t.visible)&&((n=p.value)==null||(n=n.options.appSettings)==null?void 0:n.agmListCode)==null}),le=Y(()=>{var e,t;return((e=f.value)==null?void 0:e.registeredComponents.has(`pis-products-search-favorite-views`))&&((t=p.value)==null||(t=t.options.components)==null||(t=t.search)==null||(t=t.favoriteViews)==null?void 0:t.visible)}),ue=Y(()=>{var e;return(e=f.value)==null?void 0:e.registeredComponents.has(`pis-products-search-filters`)}),de=Y(()=>{var e;return((e=p.value)==null||(e=e.data.favoriteViews)==null?void 0:e.items)??[]}),k=Y(()=>{var e,t;return((e=f.value)==null?void 0:e.registeredComponents.has(`pis-products-search-favorite-categories`))&&((t=p.value)==null||(t=t.options.components)==null||(t=t.search)==null||(t=t.favoriteCategories)==null?void 0:t.visible)}),fe=Y(()=>{var e;return((e=p.value)==null||(e=e.data.classifications)==null?void 0:e.items)??[]}),pe=Y(()=>{var e,t,n;return((e=p.value)==null||(e=e.options.appSettings)==null?void 0:e.treeType)===ou.PRODUCTS?((t=p.value)==null||(t=t.data.favoriteProductCategories)==null?void 0:t.items)??[]:((n=p.value)==null||(n=n.data.favoritePartCategories)==null?void 0:n.items)??[]});return{root:t,componentName:l,isWebComponent:u,isReady:d,store:p,columnsNumber:Y(()=>{let e=[ee.value,ae.value,ce.value,ue.value,k.value].filter(Boolean).length;return e>3?3:e}),t:h,instance:f,narrowByProductShown:ee,narrowByProductModalOpen:n,sparePartMasterProducts:O,sparePartMasterProductsSearch:o,sparePartsMasterProductSelected:te,setMasterProductId:ne,clearMasterProduct:re,partTypes:ie,partTypesModalOpen:r,partTypesShown:ae,partTypeCurrent:oe,setPartType:se,categoriesModalOpen:i,categories:fe,categoriesShown:ce,configuratorOptions:Y(()=>{var e;return(e=p.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.configurators}),setCategory:async({cid:e})=>{if(f.value&&e){i.value=!1;try{await f.value.execute(new Op({cid:e,clearSearch:!1}).from(l))}catch{}}},filtersModalOpen:a,filtersShown:ue,filtersAll:_,filtersPromoted:v,filtersAdditional:y,filtersModel:b,filtersFetched:x,filteredResultCount:S,onModalFilterValueChange:({attributeCode:e,filterValueName:t,value:n})=>{b.value[e][t]=n,T()},fetchFilterValues:C,resetFiltersApplied:E,applyFilters:()=>{a.value=!1,w()},favoriteViews:de,favoriteViewsShown:le,favoriteViewsModalOpen:s,favoriteCategoriesModalOpen:c,favoriteCategoriesShown:k,favoriteCategories:pe}}}),Uq={class:`mb-4 row g-2`},Wq={key:0},Gq=[`value`],Kq={key:0,class:`list-group`},qq={key:1,class:`pis-message`};function Jq(e,t,n,r,i,a){let o=R(`Btn`),s=R(`LinkSecondary`),c=R(`FormInputClearable`),l=R(`Badge`),u=R(`Clickable`),d=R(`Modal`),f=R(`SparePartTypeList`),p=R(`CategoriesList`),m=R(`FiltersNavigatorModal`),h=R(`FavoriteViews`),g=R(`FavoriteCategories`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady?(H(),U(V,{key:0},[G(`nav`,Uq,[e.favoriteViewsShown?(H(),U(`div`,{key:0,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`star`,class:`w-100 h-100`,vertical:``,number:e.favoriteViews.length,onClick:t[0]||(t[0]=X(t=>e.favoriteViewsModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`FavoriteViews`)),1)]),_:1},8,[`number`])],2)):J(``,!0),e.favoriteCategoriesShown?(H(),U(`div`,{key:1,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`star`,class:`w-100 h-100`,vertical:``,number:e.favoriteCategories.length,onClick:t[1]||(t[1]=X(t=>e.favoriteCategoriesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`FavoriteCategories`)),1)]),_:1},8,[`number`])],2)):J(``,!0),e.partTypesShown?(H(),U(`div`,{key:2,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`shrink-minimise`,class:`w-100 h-100`,vertical:``,disabled:!e.sparePartMasterProducts,onClick:t[2]||(t[2]=X(t=>e.narrowByProductModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`NarrowByProduct`,!0)),1)]),_:1},8,[`disabled`])],2)):J(``,!0),e.partTypesShown?(H(),U(`div`,{key:3,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`tool-edit`,class:`w-100 h-100`,vertical:``,onClick:t[3]||(t[3]=X(t=>e.partTypesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`SparePartsType`,!0)),1)]),_:1})],2)):J(``,!0),e.categoriesShown?(H(),U(`div`,{key:4,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`folder-open`,class:`w-100 h-100`,vertical:``,disabled:!e.categories.length,number:e.categories.length,onClick:t[4]||(t[4]=X(t=>e.categoriesModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`Categories`,!0)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0),e.filtersShown?(H(),U(`div`,{key:5,class:A([`col-${12/e.columnsNumber}`])},[K(o,{icon:`funnel-filter`,class:`w-100 h-100`,vertical:``,disabled:!e.filtersAll.length,number:e.filtersAll.length,onClick:t[5]||(t[5]=X(t=>e.filtersModalOpen=!0,[`prevent`]))},{default:P(()=>[q(j(e.t(`Filters`,!0)),1)]),_:1},8,[`disabled`,`number`])],2)):J(``,!0)]),K(d,{show:e.narrowByProductModalOpen,"onUpdate:show":t[7]||(t[7]=t=>e.narrowByProductModalOpen=t),title:e.t(`NarrowByProductModalTitle`)},{default:P(()=>[e.sparePartsMasterProductSelected?(H(),U(`div`,Wq,[G(`input`,{type:`text`,class:`form-control`,disabled:``,value:e.sparePartsMasterProductSelected},null,8,Gq),K(s,{icon:`stop-not-allowed`,class:`mt-3`,onClick:e.clearMasterProduct},{default:P(()=>[q(j(e.t(`NarrowByProductClear`)),1)]),_:1},8,[`onClick`])])):e.sparePartMasterProducts?(H(),U(V,{key:1},[K(c,{modelValue:e.sparePartMasterProductsSearch,"onUpdate:modelValue":t[6]||(t[6]=t=>e.sparePartMasterProductsSearch=t),placeholder:e.t(`FindProduct`),class:`mb-4`},null,8,[`modelValue`,`placeholder`]),e.sparePartMasterProducts.length?(H(),U(`div`,Kq,[(H(!0),U(V,null,z(e.sparePartMasterProducts,(t,n)=>(H(),W(u,{key:n,class:`list-group-item list-group-item-action d-flex align-items-center`,onClick:n=>e.setMasterProductId(t)},{default:P(()=>[q(j(t.description)+` `,1),K(l,{class:`ms-auto`},{default:P(()=>[q(j(t.hitCount),1)]),_:2},1024)]),_:2},1032,[`onClick`]))),128))])):(H(),U(`p`,qq,j(e.t(`NoMasterProductsFound`)),1))],64)):J(``,!0)]),_:1},8,[`show`,`title`]),K(d,{show:e.partTypesModalOpen,"onUpdate:show":t[8]||(t[8]=t=>e.partTypesModalOpen=t),title:e.t(`PartTypesModalTitle`)},{default:P(()=>[K(f,{"part-types":e.partTypes,"current-part-type":e.partTypeCurrent,onClickItem:e.setPartType},null,8,[`part-types`,`current-part-type`,`onClickItem`])]),_:1},8,[`show`,`title`]),K(d,{show:e.categoriesModalOpen,"onUpdate:show":t[9]||(t[9]=t=>e.categoriesModalOpen=t),title:e.t(`CategoriesModalTitle`)},{default:P(()=>[K(p,{categories:e.categories,"configurators-number-title":e.t(`ConfiguratorsNumberTitle`),"configurators-visible":e.configuratorOptions.visible,onClickItem:e.setCategory},null,8,[`categories`,`configurators-number-title`,`configurators-visible`,`onClickItem`])]),_:1},8,[`show`,`title`]),e.filtersModalOpen?(H(),W(m,{key:0,show:e.filtersModalOpen,"onUpdate:show":t[10]||(t[10]=t=>e.filtersModalOpen=t),title:e.t(`Filters`,!0),"is-mobile":``,t:e.t,"filters-all":e.filtersAll,"filters-promoted":e.filtersPromoted,"filters-additional":e.filtersAdditional,"filters-model":e.filtersModel,"filters-fetched":e.filtersFetched,"filtered-result-count":e.filteredResultCount,"fetch-filter-values":e.fetchFilterValues,onValueChange:e.onModalFilterValueChange,onApplyFilters:e.applyFilters,onClear:e.resetFiltersApplied},null,8,[`show`,`title`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-model`,`filters-fetched`,`filtered-result-count`,`fetch-filter-values`,`onValueChange`,`onApplyFilters`,`onClear`])):J(``,!0),e.favoriteViewsModalOpen?(H(),W(h,{key:1,"mobile-show":e.favoriteViewsModalOpen,"onUpdate:mobileShow":t[11]||(t[11]=t=>e.favoriteViewsModalOpen=t),"is-mobile":``,t:e.t},null,8,[`mobile-show`,`t`])):J(``,!0),e.favoriteCategoriesModalOpen?(H(),W(g,{key:2,"mobile-show":e.favoriteCategoriesModalOpen,"onUpdate:mobileShow":t[12]||(t[12]=t=>e.favoriteCategoriesModalOpen=t),"is-mobile":``,t:e.t},null,8,[`mobile-show`,`t`])):J(``,!0)],64)):J(``,!0)],2)}var Yq=Q(Hq,[[`render`,Jq]]),Xq=L({name:`pis-products-common-notifications`,components:{Notifications:DT},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s}=dB(t,e.instanceId);return{root:t,componentName:n,isReady:r,isWebComponent:i,store:o,routeData:s,instance:a}}}),Zq={ref:`root`,class:`pis-component`};function Qq(e,t,n,r,i,a){let o=R(`Notifications`);return H(),U(`div`,Zq,[e.isReady&&e.store?(H(),W(o,{key:0,instance:e.instance},null,8,[`instance`])):J(``,!0)],512)}var $q=Q(Xq,[[`render`,Qq]]),eJ=L({name:`pis-products-search-categories`,components:{LinkSecondary:kE,Card:SE,CategoriesList:Hy,Message:NE,Arrow:qb},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!0),{isReady:r,isWebComponent:i,componentName:a,instance:o,store:s,t:c}=dB(t,e.instanceId,[$.Classifications]),l=Y(()=>{var e;return((e=s.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.categories)??{}}),u=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.configurators}),d=Y(()=>{var e;return((e=s.value)==null||(e=e.data.classifications)==null?void 0:e.items)??[]});return{root:t,isReady:r,isWebComponent:i,componentName:a,componentOptions:l,trimList:n,store:s,visible:Y(()=>{var e;return l.value.visible&&((e=s.value)==null||(e=e.options.appSettings)==null?void 0:e.agmListCode)==null}),categories:d,categoriesTrimmed:Y(()=>{var e;return n.value?(e=d.value)==null?void 0:e.slice(0,l.value.maxCategoriesVisible):d.value}),showMoreBtn:Y(()=>d.value&&d.value.length>(l.value.maxCategoriesVisible??0)),configuratorOptions:u,t:c,setCategory:async({cid:e})=>{if(o.value&&e)try{await o.value.execute(new Op({cid:e,clearSearch:!1}).from(a))}catch{}},showAllCategories:()=>{n.value=!n.value}}}}),tJ={key:1,class:`card-body`},nJ={key:1,class:`card-body`};function rJ(e,t,n,r,i,a){let o=R(`CategoriesList`),s=R(`Arrow`),c=R(`LinkSecondary`),l=R(`Message`),u=R(`Card`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),W(u,{key:0,class:`mb-4`,icon:e.componentOptions.icon&&`folder-open`,header:e.t(`Categories`,!0),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{list:P(()=>{var t,n;return[(t=e.categories)!=null&&t.length?(H(),U(V,{key:0},[(n=e.categories)!=null&&n.length?(H(),W(o,{key:0,categories:e.categoriesTrimmed,"configurators-number-title":e.t(`ConfiguratorsNumberTitle`),"configurators-visible":e.configuratorOptions.visible,onClickItem:e.setCategory},null,8,[`categories`,`configurators-number-title`,`configurators-visible`,`onClickItem`])):J(``,!0),e.showMoreBtn?(H(),U(`div`,tJ,[K(c,{class:`ext-show-all`,onClick:X(e.showAllCategories,[`prevent`])},{default:P(()=>[K(s,{class:`me-2`,dir:e.trimList?`down`:`up`},null,8,[`dir`]),q(` `+j(e.trimList?e.t(`ShowAllCategories`):e.t(`HideAllCategories`))+` (`+j(e.categories.length)+`) `,1)]),_:1},8,[`onClick`])])):J(``,!0)],64)):(H(),U(`div`,nJ,[K(l,null,{default:P(()=>[q(j(e.t(`NoCategories`)),1)]),_:1})]))]}),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])):J(``,!0)],2)}var iJ=Q(eJ,[[`render`,rJ]]),aJ=L({name:`pis-products-search-favorite-categories`,components:{FavoriteCategories:fq},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{isReady:n,isWebComponent:r,componentName:i,store:a,t:o,instance:s}=dB(t,e.instanceId,[]);return{root:t,isReady:n,isWebComponent:r,componentName:i,store:a,instance:s,t:o,visible:Y(()=>{var e;return(e=a.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.favoriteCategories)==null?void 0:e.visible})}}});function oJ(e,t,n,r,i,a){var o;let s=R(`FavoriteCategories`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),W(s,{key:0,t:e.t,"instance-id":(o=e.instance)==null?void 0:o.id},null,8,[`t`,`instance-id`])):J(``,!0)],2)}var sJ=Q(aJ,[[`render`,oJ]]),cJ=L({name:`pis-products-search-favorite-views`,components:{FavoriteViews:Pq},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{isReady:n,isWebComponent:r,componentName:i,store:a,t:o,instance:s}=dB(t,e.instanceId,[$.Breadcrumbs]);return{root:t,instance:s,store:a,visible:Y(()=>{var e;return(e=a.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.favoriteViews)==null?void 0:e.visible}),isReady:n,componentName:i,isWebComponent:r,t:o}}});function lJ(e,t,n,r,i,a){var o;let s=R(`FavoriteViews`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),W(s,{key:0,t:e.t,"instance-id":(o=e.instance)==null?void 0:o.id},null,8,[`t`,`instance-id`])):J(``,!0)],2)}var uJ=Q(cJ,[[`render`,lJ]]),dJ=L({name:`pis-products-search-filters`,components:{Spinner:My,Badge:ky,LinkSecondary:kE,Btn:Iy,Clickable:wm,Arrow:qb,Card:SE,FiltersNavigator:tO,ScrollableList:kD,Message:NE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=M(!1),{componentName:i,isReady:a,isWebComponent:o,instance:s,store:c,t:l,useProductsFilters:u}=dB(t,e.instanceId,[$.Filters]),d=Y(()=>{var e;return((e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.filters)??{}}),{filtersAll:f,filtersPromoted:p,filtersAdditional:m,modalFiltersAll:h,modalFiltersPromoted:g,modalFiltersAdditional:_,filtersTotalCount:v,allFiltersLoading:y,filtersModel:b,filtersFetched:x,filtersLoading:S,areFiltersApplied:C,filteredResultCount:w,filteredResultCountLoading:T,filtersOpen:E,fetchFilterValues:D,fetchAllFilters:ee,invalidateAllFilters:O,applyModelFilters:te,resetFiltersApplied:ne,refreshResultCount:re,refreshFetchedFilterValues:ie,syncSelectedFilters:ae,expandAllFilters:oe,collapseAllFilters:se,clearFiltersModelFromEmptyValues:ce}=u(),le=I(()=>s.value,()=>{var e;(e=s.value)==null||e.eventBus.on(`search-changed`,()=>{O(),setTimeout(()=>{xe.value?oe(de.value):x.value.size>0&&ie()},500),re(),ae()}),le()}),ue=e=>e.slice(0,d.value.maxFiltersVisible||10)??[],de=Y(()=>p.value.length?p.value:ue(m.value)),k=async({attributeCode:e})=>{!e||!s.value||(E.value.has(e)?E.value.delete(e):(x.value.has(e)||await D([e]),E.value.add(e)))},fe=({attributeCode:e})=>E.value.has(e),pe=({attributeCode:e})=>S.value.has(e),me=()=>{r.value=!1,setTimeout(()=>{r.value=!0,ee()},1)},he=async()=>{ne().then(()=>{E.value.clear()})},A=({attributeCode:e,filterValueName:t,value:n})=>{var r;(r=b.value)[e]??(r[e]={}),b.value[e][t]=n,re()},ge=()=>{_e(),r.value=!1},_e=()=>{te(),n.value=!1},ve=()=>{n.value=!0,re()},ye=Y(()=>{var e;return((e=c.value)==null||(e=e.data.breadcrumbs)==null||(e=e.items)==null?void 0:e.length)??0}),be=Y(()=>d.value.visible?!d.value.visibleFromNodeLevel||ye.value>d.value.visibleFromNodeLevel:!1),xe=Y(()=>d.value.visible&&d.value.expandedFromNodeLevel?ye.value>d.value.expandedFromNodeLevel:!1);return{root:t,componentName:i,visible:be,componentOptions:d,isReady:a,isWebComponent:o,store:c,filtersAll:f,filtersPromoted:p,filtersAdditional:m,modalFiltersAll:h,modalFiltersPromoted:g,modalFiltersAdditional:_,filtersTotalCount:v,allFiltersLoading:y,filtersToDisplay:de,filtersOpen:E,filtersFetched:x,areFiltersDirty:n,filtersModel:b,areFiltersApplied:C,allFiltersModalShown:r,filteredResultCount:w,filteredResultCountLoading:T,t:l,toggleFilter:k,clearAndCloseFilters:he,isFilterOpen:fe,isFilterLoading:pe,showAllFilters:me,applyModelFilters:te,fetchFilterValues:D,onModalFilterValueChange:A,onModalApplyFilters:ge,onFilterValueChange:ve,resetFiltersApplied:ne,expandAll:()=>{oe(de.value)},collapseAll:()=>{se()},criterionValueKey:lu,clearFiltersModelFromEmptyValues:ce,onApplyFilters:_e}}}),fJ={key:0,class:`d-flex mb-3`},pJ={key:1,class:`list-unstyled mb-0`},mJ=[`innerHTML`],hJ={key:0},gJ={class:`form-check pe-1`},_J={class:`form-check-label d-flex align-items-start py-1 ms-1`},vJ=[`onUpdate:modelValue`,`name`],yJ=[`innerHTML`];function bJ(e,t,n,r,i,a){let o=R(`LinkSecondary`),s=R(`Spinner`),c=R(`Arrow`),l=R(`Badge`),u=R(`Clickable`),d=R(`ScrollableList`),f=R(`Message`),p=R(`Btn`),m=R(`Card`),h=R(`FiltersNavigator`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(V,{key:0},[K(m,{class:`mb-4`,"sticky-footer":``,icon:e.componentOptions.icon&&`funnel-filter`,header:e.t(`Filters`,!0),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},Gr({default:P(()=>{var n,r;return[(n=e.filtersToDisplay)!=null&&n.length&&(e.componentOptions.expandAllVisible||e.componentOptions.collapseAllVisible)?(H(),U(`div`,fJ,[e.componentOptions.expandAllVisible?(H(),W(o,{key:0,icon:`expand-maximize`,class:`ms-1 me-4 ext-expand-all-filters`,onClick:X(e.expandAll,[`prevent`])},{default:P(()=>[q(j(e.t(`ExpandAllFilters`)),1)]),_:1},8,[`onClick`])):J(``,!0),e.componentOptions.collapseAllVisible?(H(),W(o,{key:1,icon:`shrink-minimise`,class:`ext-collapse-all-filters`,onClick:X(e.collapseAll,[`prevent`])},{default:P(()=>[q(j(e.t(`CollapseAllFilters`)),1)]),_:1},8,[`onClick`])):J(``,!0)])):J(``,!0),(r=e.filtersToDisplay)!=null&&r.length?(H(),U(`ul`,pJ,[(H(!0),U(V,null,z(e.filtersToDisplay,n=>{var r;return H(),U(`li`,{key:n.attributeCode,class:`pb-2`},[K(u,{class:`py-1 d-flex align-items-start text-decoration-none lh-sm`,"aria-expanded":e.isFilterOpen(n),onClick:t=>e.toggleFilter(n)},{default:P(()=>[e.isFilterLoading(n)?(H(),W(s,{key:0,sm:``})):(H(),W(c,{key:1,dir:e.isFilterOpen(n)?`up`:`down`},null,8,[`dir`])),G(`span`,{class:`d-block ms-2 text-body text-break pis-label`,innerHTML:n.attributeNameHtml},null,8,mJ),K(l,{class:`ms-auto`,textContent:j(n.hitCount)},null,8,[`textContent`])]),_:2},1032,[`aria-expanded`,`onClick`]),e.isFilterOpen(n)?(H(),U(`div`,hJ,[(r=e.filtersFetched.get(n.attributeCode))!=null&&r.length?(H(),W(d,{key:0,class:`list-unstyled my-1 ms-2`,height:`30vh`,items:e.filtersFetched.get(n.attributeCode)||[],"key-field":`_key`},{item:P(({item:r})=>[G(`div`,gJ,[G(`label`,_J,[F(G(`input`,{"onUpdate:modelValue":t=>e.filtersModel[n.attributeCode][e.criterionValueKey(r.value)]=t,type:`checkbox`,class:`form-check-input mt-1 me-2 flex-shrink-0`,name:r.text,onChange:t[0]||(t[0]=(...t)=>e.onFilterValueChange&&e.onFilterValueChange(...t))},null,40,vJ),[[bs,e.filtersModel[n.attributeCode][e.criterionValueKey(r.value)]]]),G(`span`,{class:`text-break user-select-none`,innerHTML:r.text},null,8,yJ),K(l,{class:`ms-auto`,textContent:j(r.hitCount)},null,8,[`textContent`])])])]),_:2},1032,[`items`])):(H(),W(f,{key:1},{default:P(()=>[q(j(e.t(`NoFilterValues`)),1)]),_:1}))])):J(``,!0)])}),128))])):(H(),W(f,{key:2},{default:P(()=>[q(j(e.t(`NoFilters`)),1)]),_:1}))]}),_:2},[e.areFiltersApplied||e.filtersTotalCount>0?{name:`footer`,fn:P(()=>[e.filteredResultCount!==null&&e.areFiltersDirty?(H(),W(p,{key:0,class:`w-100 mb-2 justify-content-between ext-apply`,disabled:e.areFiltersDirty!==!0||e.filteredResultCount===0,"is-loading":e.filteredResultCountLoading,onClick:X(e.onApplyFilters,[`prevent`])},{default:P(()=>[e.filteredResultCount===null?(H(),U(V,{key:0},[q(j(e.t(`ShowResults`,!0)),1)],64)):e.filteredResultCount===0?(H(),U(V,{key:1},[q(j(e.t(`NoFilteringResultsFound`)),1)],64)):(H(),U(V,{key:2},[q(j(e.t(`ShowNResults`,!0,[`${e.filteredResultCount||`0`}`])),1)],64))]),_:1},8,[`disabled`,`is-loading`,`onClick`])):J(``,!0),e.areFiltersApplied?(H(),W(o,{key:1,icon:`stop-not-allowed`,class:`mt-2 ext-clear`,onClick:X(e.clearAndCloseFilters,[`prevent`])},{default:P(()=>[q(j(e.t(`ClearFilters`,!0)),1)]),_:1},8,[`onClick`])):J(``,!0),e.filtersTotalCount>0?(H(),W(o,{key:2,icon:`pop-out-window`,class:`mt-2 ext-show-all`,onClick:X(e.showAllFilters,[`prevent`])},{default:P(()=>[q(j(e.t(`ShowAllFilters`))+` (`+j(e.filtersTotalCount)+`) `,1)]),_:1},8,[`onClick`])):J(``,!0)]),key:`0`}:void 0]),1032,[`icon`,`header`,`use-markup`,`collapsed`]),K(h,{show:e.allFiltersModalShown,title:e.t(`AllFiltersModalTitle`),t:e.t,"filters-all":e.modalFiltersAll,"filters-promoted":e.modalFiltersPromoted,"filters-additional":e.modalFiltersAdditional,"filters-loading":e.allFiltersLoading,"filters-fetched":e.filtersFetched,"filters-model":e.filtersModel,"fetch-filter-values":e.fetchFilterValues,"filtered-result-count":e.filteredResultCount,"filtered-result-count-loading":e.filteredResultCountLoading,"clear-filters-model-from-empty-values":e.clearFiltersModelFromEmptyValues,onValueChange:e.onModalFilterValueChange,onApplyFilters:e.onModalApplyFilters,onClear:e.resetFiltersApplied},null,8,[`show`,`title`,`t`,`filters-all`,`filters-promoted`,`filters-additional`,`filters-loading`,`filters-fetched`,`filters-model`,`fetch-filter-values`,`filtered-result-count`,`filtered-result-count-loading`,`clear-filters-model-from-empty-values`,`onValueChange`,`onApplyFilters`,`onClear`])],64)):J(``,!0)],2)}var xJ=Q(dJ,[[`render`,bJ]]),SJ=20,CJ=L({name:`pis-products-search-filters-status`,components:{Badge:ky,LinkSecondary:kE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,instance:o,t:s,useProductsFilters:c}=dB(t,e.instanceId,[$.Filters]),{filtersApplied:l,excludeFilter:u,resetFiltersApplied:d}=c(),f=Y(()=>{var e;return(e=o.value)==null||(e=e.router.routeData)==null||(e=e.search)==null?void 0:e.partsType}),p=Y(()=>f.value===$l.ALL),m=Y(()=>{var e;return((e=a.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.filtersStatus)??{}}),h=async()=>{if(!p.value)try{var e;await((e=o.value)==null?void 0:e.execute(new kp({partsType:$l.ALL}).from(n)))}catch{}};return{root:t,componentName:n,isReady:r,isWebComponent:i,store:a,filtersApplied:l,currentPartType:f,isCurrentPartTypeDefault:p,componentOptions:m,t:s,excludeFilter:u,resetPartsType:h,resetAll:()=>{h(),l.value.length&&d()},truncateText:e=>e.length>SJ?e.substring(0,SJ)+`...`:e}}}),wJ={key:0,class:`mt-3`},TJ={key:0},EJ={class:`d-inline-block me-2`};function DJ(e,t,n,r,i,a){let o=R(`Badge`),s=R(`LinkSecondary`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(`div`,wJ,[e.filtersApplied.length||!e.isCurrentPartTypeDefault?(H(),U(`div`,TJ,[G(`small`,EJ,j(e.t(`AppliedFilters`))+`:`,1),e.isCurrentPartTypeDefault?J(``,!0):(H(),W(o,{key:0,class:`me-2 my-1 py-2`,removable:``,"remove-title":e.t(`RemoveBadgeTitle`),onRemove:e.resetPartsType},{default:P(()=>[q(j(e.t(`SparePartsType`,!0))+`: `+j(e.currentPartType),1)]),_:1},8,[`remove-title`,`onRemove`])),(H(!0),U(V,null,z(e.filtersApplied,(t,n)=>(H(),U(V,null,[(H(!0),U(V,null,z(t.values,(r,i)=>(H(),W(o,{key:`${n}${i}`,class:`me-2 my-1 py-2`,removable:``,title:`${t.attributeName??t.code}: ${r.text}`,"remove-title":e.t(`RemoveBadgeTitle`),onRemove:n=>e.excludeFilter(t,r.value)},{default:P(()=>[q(j(e.truncateText(t.attributeName??t.code))+`: `+j(e.truncateText(r.text)),1)]),_:2},1032,[`title`,`remove-title`,`onRemove`]))),128))],64))),256)),K(s,{icon:`stop-not-allowed`,class:`d-inline-flex align-middle ext-clear`,onClick:e.resetAll},{default:P(()=>[q(j(e.t(`ClearAll`)),1)]),_:1},8,[`onClick`])])):J(``,!0)])):J(``,!0)],2)}var OJ=Q(CJ,[[`render`,DJ]]),kJ={value:ru.WITH_ALL_WORDS,translate:`SearchTypeAllWords`},AJ={value:ru.HIERARCHICAL,translate:`Hierarchical`},jJ={value:ru.WITH_AT_LEAST_ONE_WORD,translate:`SearchTypeOneWord`},MJ={value:ru.EXACT_PHRASE,translate:`SearchTypeExact`},NJ={value:ru.SPARE_PART_MASTER_IDENTIFIER,translate:`SearchTypeMasterId`},PJ=L({name:`pis-products-search-form`,components:{SearchFormView:LO,Clickable:wm,Highlighter:sb,Image:CO},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=e=>{t.value=e??void 0},{componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,routeData:c,widerThan:l,narrowerThan:u,t:d,emit:f}=dB(t,e.instanceId),p=Y(()=>{var e;return(e=s.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.form}),m=Y(()=>{var e;return!!((e=p.value)!=null&&e.autoDetailsNavigation)}),h=Y(()=>{var e;return((e=s.value)==null||(e=e.options.appSettings)==null?void 0:e.treeType)===ou.PARTS}),g=[kJ,jJ,MJ],_=Y(()=>h.value?[NJ,...g]:[AJ,...g]),v=async e=>{if(c.value&&e)try{var t;await((t=o.value)==null?void 0:t.execute(new bp(e).from(r)))}catch{}};return{root:t,setRoot:n,componentName:r,isReady:i,isWebComponent:a,store:s,componentOptions:p,isSparePartsView:h,t:d,setClassification:async(e,t,n)=>{if(o.value&&e){t(),n(``);try{await o.value.execute(new Op({cid:e,clearSearch:!0}).from(r))}catch{}}},formAdapter:{t:d,widerThan:l,narrowerThan:u,initialSearchType:ru.WITH_ALL_WORDS,search:async(e,{autocomplete:t})=>{var n;let i=e.searchText,a=e.resetCategories?void 0:t.autoCategoryNavigationCid;if(!a){var s;let e=t.items.filter(e=>e.type===`item`).length,n=t.items.filter(e=>e.type===`category`).length;if(e==0&&n==1){var l;a=(l=t.items.find(e=>e.type===`category`))==null?void 0:l.productId,i=``}if(!a&&(s=p.value)!=null&&s.autoCategoryNavigation){var u,d,f;a=!((u=c.value)!=null&&(u=u.search)!=null&&u.cid)||((d=c.value)==null||(d=d.search)==null?void 0:d.cid)===`ROOT`?`ROOT`:(f=c.value)==null||(f=f.search)==null?void 0:f.cid}}return await((n=o.value)==null?void 0:n.execute(new yp({searchText:i,searchType:e.searchType,resetCategories:e.resetCategories,resetFilters:e.resetFilters,cid:a}).from(r))),{searchText:i}},autocomplete:e=>{var t;return(t=o.value)==null?void 0:t.execute(new Vp({searchText:e}).from(r))},isRootCategory:()=>{var e,t;return!((e=c.value)!=null&&(e=e.search)!=null&&e.cid)||((t=c.value)==null||(t=t.search)==null?void 0:t.cid)===`ROOT`},routeSearchText:()=>{var e;return(e=c.value)==null||(e=e.search)==null?void 0:e.searchText},routeSearchType:()=>{var e;return(e=c.value)==null||(e=e.search)==null?void 0:e.searchType},acceptsRouteSearchType:e=>!!_.value.find(t=>t.value===e),applyRouteSearchType:e=>{var t;(t=c.value)!=null&&t.search&&(c.value.search.searchType=e)},searchTypeOptions:()=>h.value?[NJ,...g]:g,placeholder:()=>h.value?d(`SearchSparePartsInputPlaceholder`):d(`SearchProductsInputPlaceholder`),searchAriaLabel:()=>h.value?d(`SearchSparePartsInputAriaLabel`):d(`SearchProductsInputAriaLabel`),isSearchTypeDropdownVisible:()=>{var e;return((e=c.value)==null||(e=e.search)==null?void 0:e.searchType)!==ru.HIERARCHICAL},onAutocompleteItemClick:(e,t)=>{m.value&&e.productId?v({productId:e.productId}):t(e.text??``)},buildAutocompleteItemCtx:e=>({instance:o.value,item:e,emit:f,t:d}),inputDebounceMs:300,refreshAutocompleteOnFocus:!0,syncTypeFromRouteOnReady:!0,dropdownMaxHeight:`500px`,showCurrentCategoryNameBadge:!0,hideItemsWhileLoading:!0}}}}),FJ={class:`dropdown-item-text text-muted small mb-1 text-uppercase fw-bold ext-match-category`},IJ={class:`dropdown-item-text text-muted mt-3 mb-1 small text-uppercase fw-bold ext-match-category`},LJ={key:0},RJ={key:1},zJ={key:0,style:{width:`4rem`,"min-width":`4rem`},class:`me-2`},BJ={class:`fw-bold ext-display-name`},VJ={key:0,class:`small ext-all-identifiers text-wrap`},HJ={key:1,class:`small ext-description text-wrap`};function UJ(e,t,n,r,i,a){let o=R(`Image`),s=R(`Highlighter`),c=R(`Clickable`),l=R(`SearchFormView`);return H(),W(l,{"set-root":e.setRoot,"component-name":e.componentName,"is-ready":e.isReady,options:e.componentOptions,adapter:e.formAdapter},{"item-top-title":P(()=>[G(`div`,FJ,[G(`span`,null,j(e.t(`Classifications`)),1)])]),"item-title":P(()=>[G(`div`,IJ,[e.isSparePartsView?(H(),U(`span`,LJ,j(e.t(`SpareParts`,!0)),1)):(H(),U(`span`,RJ,j(e.t(`Products`,!0)),1))])]),"item-top":P(({item:t,highlightTerms:n,getThumbnailUrl:r,closeAutocomplete:i,setSearchText:a})=>[t.type===`category`?(H(),W(c,{key:0,class:`d-flex align-items-center dropdown-item`,onClick:n=>e.setClassification(t.productId,i,a)},{default:P(()=>{var i;return[q(j(t.match)+` `,1),G(`div`,null,[(i=e.componentOptions)!=null&&i.showCategoryImages?(H(),U(`div`,zJ,[K(o,{src:r(t)},null,8,[`src`])])):J(``,!0)]),G(`div`,null,[G(`div`,BJ,[K(s,{"highlight-class-name":`text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":n,"auto-escape":!0,"text-to-highlight":t.text},null,8,[`search-words`,`text-to-highlight`])]),t.description?(H(),U(`div`,VJ,[q(j(e.t(`Keywords`))+`: `,1),K(s,{"highlight-class-name":`fw-bold text-primary p-0 display-inline bg-transparent ext-highlight`,"highlight-tag":`span`,"search-words":n,"auto-escape":!0,"text-to-highlight":t.description},null,8,[`search-words`,`text-to-highlight`])])):J(``,!0),t.secondaryText?(H(),U(`div`,HJ,j(t.secondaryText),1)):J(``,!0)])]}),_:2},1032,[`onClick`])):J(``,!0)]),_:1},8,[`set-root`,`component-name`,`is-ready`,`options`,`adapter`])}var WJ=Q(PJ,[[`render`,UJ]]),GJ=L({name:`ProductsConfiguratorsCard`,components:{Card:SE,MountPoint:cg},props:{configurators:{type:Array,default:void 0},visible:{type:Boolean,default:!1},currentCidName:{type:String,default:void 0},actionTemplate:{type:[Object,Function,String],default:void 0},t:{type:Function,required:!0},showConfigurator:{type:Function,required:!0},emit:{type:Function,required:!0}},setup(){return{reactiveContext:lg}}}),KJ={class:`row g-0`},qJ={class:`col`},JJ={class:`text-muted`},YJ={class:`col`},XJ={class:`fw-bolder`},ZJ={class:`col text-end`};function QJ(e,t,n,r,i,a){let o=R(`MountPoint`),s=R(`Card`);return e.configurators&&e.visible&&e.currentCidName?(H(),W(s,{key:0,class:`mb-4 bg-light`,"use-markup":!0},{default:P(()=>[G(`div`,KJ,[G(`div`,qJ,[G(`div`,JJ,j([e.currentCidName,e.configurators.length>1?e.t(`Configurators`):e.t(`Configurator`)].join(` - `).concat(`:`)),1)])]),(H(!0),U(V,null,z(e.configurators,t=>(H(),U(`div`,{key:t.code,class:`row g-0`},[G(`div`,YJ,[G(`div`,XJ,j(t.productId),1)]),G(`div`,ZJ,[e.actionTemplate?(H(),W(o,{key:0,callbacks:e.actionTemplate,ctx:e.reactiveContext({t:e.t,item:t,showConfigurator:e.showConfigurator,emit:e.emit})},null,8,[`callbacks`,`ctx`])):J(``,!0)])]))),128))]),_:1})):J(``,!0)}var $J=Q(GJ,[[`render`,QJ]]),eY=L({name:`pis-products-search-grid`,components:{SearchGridView:Bk,ProductsConfiguratorsCard:$J,PisReplacements:KB,Tooltip:Fw,Icon:$h},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=e=>{t.value=e??void 0},{componentName:r,isReady:i,instance:a,store:o,routeData:s,t:c,widerThan:l,emit:u}=dB(t,e.instanceId,[$.Products]),d=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.grid)??{}}),f=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.configurators}),p=Y(()=>{var e;if((e=a.value)!=null&&(e=e.router.routeData)!=null&&(e=e.search)!=null&&e.cid){var t;let e=(t=a.value)==null||(t=t.store)==null||(t=t.data.breadcrumbs)==null?void 0:t.items;if(e){var n;return(n=e[e.length-1])==null?void 0:n.name}}}),m=Y(()=>{var e,t;let n=(e=a.value)==null?void 0:e.router.history;return((t=o.value)==null?void 0:t.options.hideInitialSearchResults)&&n&&n.length<=2}),h=async e=>{if(!(e!=null&&e.inactive)&&s.value&&e)try{var t;await((t=a.value)==null?void 0:t.execute(new bp(e).from(r)))}catch{}},g=Y(()=>{var e;return(e=o.value)==null||(e=e.data.products)==null?void 0:e.items}),_=Y(()=>{var e;return((e=a.value)==null?void 0:e.registeredComponents.has(`pis-products-preview`))??!1}),v=async e=>{try{var t;await((t=a.value)==null?void 0:t.execute(new xp({productId:e.productId}).from(r)))}catch{}};return{root:t,setRoot:n,instance:a,componentName:r,componentOptions:d,isReady:i,hideIfInitial:m,productsItems:g,previewEnabled:_,configurators:Y(()=>{var e;return(e=o.value)==null||(e=e.data.configurators)==null?void 0:e.items}),configuratorOptions:f,replacementsVisible:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),currentCIDName:p,showConfigurator:async e=>{try{var t;await((t=a.value)==null?void 0:t.execute(new wp(e).from(r)))}catch{}},t:c,attrValue:Us,additionalInfo:Gs,variantsAvailableInfo:Ks,details:h,emit:u,gridAdapter:{t:c,widerThan:l,details:e=>h(e),getItemImage:e=>{var t;return(t=(e.images||[])[0])==null?void 0:t.url},isImageDisabled:e=>!!e.inactive,isPreviewDisabled:e=>!!e.inactive,preview:e=>v(e),buildImageOverlayCtx:e=>({instance:a.value,item:e,emit:u,t:c}),buildTitleCtx:e=>({instance:a.value,item:e,emit:u,details:h,attrValue:Us,t:c}),buildItemCtx:e=>({instance:a.value,item:e,emit:u,details:h,attrValue:Us,attrValues:Ws,t:c}),buildActionCtx:e=>({instance:a.value,item:e,emit:u,details:h,attrValue:Us,attrValues:Ws,t:c})}}}}),tY={key:0,class:`text-muted`},nY=[`onClick`],rY={class:`d-flex justify-content-center text-center`},iY={key:1,class:`d-flex justify-content-center align-items-center fw-bold mt-1`};function aY(e,t,n,r,i,a){let o=R(`ProductsConfiguratorsCard`),s=R(`Icon`),c=R(`Tooltip`),l=R(`PisReplacements`),u=R(`icon`),d=R(`SearchGridView`),f=Hr(`safe-html`);return H(),W(d,{"set-root":e.setRoot,"component-name":e.componentName,"is-ready":e.isReady,"hide-if-initial":e.hideIfInitial,options:e.componentOptions,items:e.productsItems,instance:e.instance,"card-class":`card h-100 pt-0`,"select-checkbox-style":`z-index: 1; width: auto; margin-top: -0.1rem`,"preview-enabled":e.previewEnabled,adapter:e.gridAdapter},{"before-results":P(()=>[e.hideIfInitial?J(``,!0):(H(),W(o,{key:0,configurators:e.configurators,visible:!!e.configuratorOptions.visible,"current-cid-name":e.currentCIDName,"action-template":e.configuratorOptions.actionTemplate,t:e.t,"show-configurator":e.showConfigurator,emit:e.emit},null,8,[`configurators`,`visible`,`current-cid-name`,`action-template`,`t`,`show-configurator`,`emit`]))]),"title-prefix":P(({item:t})=>{var n;return[t.additionalInfo&&(n=t.additionalInfo)!=null&&n.length?(H(),W(c,{key:0,text:e.additionalInfo(t.additionalInfo)},{default:P(()=>[K(s,{class:`me-2 text-warning`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0)]}),"title-fallback":P(({item:t})=>[t.inactive?(H(),U(`strong`,tY,j(e.attrValue(t,`#DisplayName`)),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(n=>e.details(t),[`prevent`])},[G(`strong`,null,j(e.attrValue(t,`#DisplayName`)),1)],8,nY))]),"item-fallback":P(({item:t})=>[G(`div`,rY,[G(`span`,null,j(e.attrValue(t,`CatalogDescription`)),1)])]),"item-extra":P(({item:t})=>{var n;return[(n=t.replacements)!=null&&n.length&&e.componentOptions.showReplacements?(H(),W(l,{key:0,class:`text-center mt-3`,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),e.componentOptions.showVariants&&t.variantsAvailable?(H(),U(`div`,iY,[K(u,{class:`me-2 text-muted`,name:`information-circle`}),F(G(`span`,null,null,512),[[f,e.t(`VariantsAvailable`)+`: `+e.variantsAvailableInfo(t.variantAttributes)+`.`]])])):J(``,!0)]}),_:1},8,[`set-root`,`component-name`,`is-ready`,`hide-if-initial`,`options`,`items`,`instance`,`preview-enabled`,`adapter`])}var oY=Q(eY,[[`render`,aY]]),sY=L({name:`pis-products-search-header`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,store:a,t:o}=dB(t,e.instanceId,[$.Breadcrumbs]),s=Y(()=>{var e,t;if((e=a.value)!=null&&e.data.searchTitle){var n;return(n=a.value)==null?void 0:n.data.searchTitle}let r=a.value?(t=a.value)==null||(t=t.data.breadcrumbs)==null?void 0:t.items:null;if(r){var i;return(i=r[r.length-1])==null?void 0:i.name}return null}),c=Y(()=>{var e;return((e=a.value)==null?void 0:e.data.searchTitle)!==void 0});return{root:t,componentName:n,isReady:r,headerVisible:Y(()=>{var e;return(e=a.value)==null||(e=e.options)==null||(e=e.components)==null||(e=e.search)==null||(e=e.header)==null?void 0:e.visible}),isWebComponent:i,store:a,title:s,isMasterProductSelected:c,t:o}}}),cY={key:0,class:`mb-4`},lY={key:0};function uY(e,t,n,r,i,a){return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.headerVisible?(H(),U(V,{key:0},[e.title?(H(),U(`h2`,cY,[e.isMasterProductSelected?(H(),U(`span`,lY,j(e.t(`SparePartsOf`)),1)):J(``,!0),q(` `+j(e.title),1)])):J(``,!0)],64)):J(``,!0)],2)}var dY=Q(sY,[[`render`,uY]]),fY=L({name:`pis-products-search-list`,components:{SearchListView:fA,ProductsConfiguratorsCard:$J,PisReplacements:KB,Tooltip:Fw,Icon:$h},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=e=>{t.value=e??void 0},{componentName:r,isReady:i,instance:a,store:o,routeData:s,t:c,widerThanPx:l,emit:u}=dB(t,e.instanceId,[$.Products]),d=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.list)??{}}),f=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.configurators}),p=Y(()=>{var e;if((e=a.value)!=null&&(e=e.router.routeData)!=null&&(e=e.search)!=null&&e.cid){var t;let e=(t=a.value)==null||(t=t.store)==null||(t=t.data.breadcrumbs)==null?void 0:t.items;if(e){var n;return(n=e[e.length-1])==null?void 0:n.name}}}),m=Y(()=>{var e,t;let n=(e=a.value)==null?void 0:e.router.history;return((t=o.value)==null?void 0:t.options.hideInitialSearchResults)&&n&&n.length<=2}),h=Y(()=>l(d.value.mobileBreakpoint)),g=Y(()=>{var e;return(e=o.value)==null||(e=e.data.products)==null?void 0:e.items}),_=Y(()=>{var e;return((e=a.value)==null?void 0:e.registeredComponents.has(`pis-products-preview`))??!1}),v=Y(()=>{var e;return(e=o.value)==null||(e=e.data.configurators)==null?void 0:e.items}),y=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),b=async e=>{if(!(e!=null&&e.inactive)&&s.value&&e)try{var t;await((t=a.value)==null?void 0:t.execute(new bp(e).from(r)))}catch{}},x=async e=>{try{var t;await((t=a.value)==null?void 0:t.execute(new xp({productId:e.productId}).from(r)))}catch{}};return{root:t,setRoot:n,instance:a,componentName:r,componentOptions:d,isReady:i,hideIfInitial:m,isDesktopView:h,productsItems:g,previewEnabled:_,configurators:v,configuratorOptions:f,replacementsVisible:y,currentCIDName:p,showConfigurator:async e=>{try{var t;await((t=a.value)==null?void 0:t.execute(new wp(e).from(r)))}catch{}},t:c,attrValue:Us,additionalInfo:Gs,variantsAvailableInfo:Ks,emit:u,listAdapter:{t:c,details:e=>b(e),getItemImage:e=>{var t;return(t=(e.images||[])[0])==null?void 0:t.url},isImageDisabled:e=>!!e.inactive,isPreviewDisabled:e=>!!e.inactive,preview:e=>x(e),onImageClick:e=>b(e),buildImageOverlayCtx:e=>({instance:a.value,item:e,emit:u,t:c}),buildTitleCtx:e=>({instance:a.value,item:e,emit:u,details:b,attrValue:Us,t:c}),buildItemCtx:e=>({instance:a.value,item:e,emit:u,details:b,attrValue:Us,t:c}),buildAdditionalColumnCtx:e=>({instance:a.value,item:e,emit:u,details:b,attrValue:Us,t:c}),buildActionCtx:e=>({instance:a.value,item:e,emit:u,details:b,attrValue:Us,t:c})}}}}),pY={key:1,class:`d-flex align-items-center fw-bold mt-1`};function mY(e,t,n,r,i,a){let o=R(`ProductsConfiguratorsCard`),s=R(`Icon`),c=R(`Tooltip`),l=R(`PisReplacements`),u=R(`icon`),d=R(`SearchListView`),f=Hr(`safe-html`);return H(),W(d,{"set-root":e.setRoot,"component-name":e.componentName,"is-ready":e.isReady,"hide-if-initial":e.hideIfInitial,options:e.componentOptions,items:e.productsItems,instance:e.instance,"is-desktop":e.isDesktopView,"selectable-adds-image-margin":``,"preview-enabled":e.previewEnabled,adapter:e.listAdapter},{"before-results":P(()=>[e.hideIfInitial?J(``,!0):(H(),W(o,{key:0,configurators:e.configurators,visible:!!e.configuratorOptions.visible,"current-cid-name":e.currentCIDName,"action-template":e.configuratorOptions.actionTemplate,t:e.t,"show-configurator":e.showConfigurator,emit:e.emit},null,8,[`configurators`,`visible`,`current-cid-name`,`action-template`,`t`,`show-configurator`,`emit`]))]),"title-prefix":P(({item:t})=>{var n;return[t.additionalInfo&&(n=t.additionalInfo)!=null&&n.length?(H(),W(c,{key:0,text:e.additionalInfo(t.additionalInfo)},{default:P(()=>[K(s,{class:`text-warning me-1`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0)]}),"item-fallback":P(({item:t})=>[G(`div`,null,[G(`span`,null,j(e.attrValue(t,`CatalogDescription`)),1)])]),"item-extra":P(({item:t})=>{var n;return[(n=t.replacements)!=null&&n.length&&e.componentOptions.showReplacements?(H(),W(l,{key:0,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),e.componentOptions.showVariants&&t.variantsAvailable?(H(),U(`div`,pY,[K(u,{class:`text-muted me-2`,name:`information-circle`}),F(G(`span`,null,null,512),[[f,e.t(`VariantsAvailable`)+`: `+e.variantsAvailableInfo(t.variantAttributes)+`.`]])])):J(``,!0)]}),_:1},8,[`set-root`,`component-name`,`is-ready`,`hide-if-initial`,`options`,`items`,`instance`,`is-desktop`,`preview-enabled`,`adapter`])}var hY=Q(fY,[[`render`,mY]]),gY=L({components:{Dropdown:pb,Clickable:wm,Badge:ky,Message:NE},props:{modelValue:{type:[String,Number],default:void 0},options:{type:Array,default:void 0},placeholder:{type:String,default:void 0},name:{type:String,required:!0},noResultsMessage:{type:String,default:void 0},textField:{type:String,default:`text`},valueField:{type:String,default:`value`}},emits:[`update:modelValue`,`change`],setup(e,{emit:t}){let n=M(!1),r=M(``),i=Y(()=>{var t;if(r.value)return r.value;let n=(t=e.options)==null?void 0:t.find(t=>t[e.valueField]===e.modelValue);return n?n[e.textField]:``}),a=e=>e.toLowerCase().includes(r.value);return{optionsOpen:n,inputText:i,optionsFiltered:Y(()=>{var t;return((t=e.options)==null?void 0:t.filter(t=>{let n=t;return a(n[e.textField])||a(n[e.valueField])}))??[]}),onInput:e=>{r.value=ly(e)[0].value.toLowerCase()},onItemClick:i=>{t(`update:modelValue`,i[e.valueField]),r.value=``,n.value=!1}}}}),_Y=[`value`,`list`,`placeholder`];function vY(e,t,n,r,i,a){let o=R(`Badge`),s=R(`Clickable`),c=R(`Message`),l=R(`Dropdown`);return H(),W(l,{open:e.optionsOpen,"onUpdate:open":t[2]||(t[2]=t=>e.optionsOpen=t),width:`100%`,items:e.optionsFiltered},Gr({item:P(({item:t})=>[K(s,{class:`dropdown-item d-flex`,onClick:n=>e.onItemClick(t)},{default:P(()=>[q(j(t[e.textField])+` `,1),K(o,{class:`ms-auto`},{default:P(()=>[q(j(t.hitCount),1)]),_:2},1024)]),_:2},1032,[`onClick`])]),activator:P(({on:n})=>[G(`input`,Oa(e.$attrs,{class:`form-control`,value:e.inputText,list:e.name,placeholder:e.placeholder},qr(n,!0),{onInput:t[0]||(t[0]=(...t)=>e.onInput&&e.onInput(...t)),onFocus:t[1]||(t[1]=t=>e.optionsOpen=!0)}),null,16,_Y)]),_:2},[e.noResultsMessage&&!e.optionsFiltered.length?{name:`footer`,fn:P(()=>[K(c,null,{default:P(()=>[q(j(e.noResultsMessage),1)]),_:1})]),key:`0`}:void 0]),1032,[`open`,`items`])}var yY=L({name:`pis-products-search-narrow-by-product`,components:{Card:SE,LinkSecondary:kE,FormDatalist:Q(gY,[[`render`,vY]]),Message:NE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{isReady:n,isWebComponent:r,componentName:i,instance:a,store:o,routeData:s,t:c}=dB(t,e.instanceId,[$.MasterProducts]),l=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.narrowByProduct)??{}}),u=Y(()=>{var e;return((e=o.value)==null||(e=e.data.sparePartMasterProducts)==null?void 0:e.items)??[]});return{root:t,isReady:n,isWebComponent:r,componentName:i,componentOptions:l,store:o,isSparePartView:Y(()=>{var e;return((e=o.value)==null||(e=e.options.appSettings)==null?void 0:e.treeType)===`Parts`}),sparePartMasterProducts:u,masterProductSelected:Y(()=>{var e;return(e=s.value)==null||(e=e.search)==null?void 0:e.masterProductId}),t:c,setMasterProductId:async e=>{let t=u.value.find(t=>t.productId==e);if(t)try{var n;await((n=a.value)==null?void 0:n.execute(new Ap({masterProductId:t.productId,masterProductName:t.description}).from(i)))}catch{}},clear:async()=>{try{var e;(e=a.value)==null||e.execute(new Ap({masterProductId:void 0,masterProductName:void 0}).from(i))}catch{}}}}}),bY={key:0},xY={key:0};function SY(e,t,n,r,i,a){let o=R(`FormDatalist`),s=R(`LinkSecondary`),c=R(`Message`),l=R(`Card`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.isSparePartView&&e.componentOptions.visible?(H(),U(`div`,bY,[K(l,{class:`mb-4`,icon:e.componentOptions.icon&&`shrink-minimise`,header:e.t(`NarrowByProduct`,!0),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{default:P(()=>[e.sparePartMasterProducts.length?(H(),U(`div`,xY,[K(o,{name:`narrow-by-product`,"value-field":`productId`,"text-field":`description`,"model-value":e.masterProductSelected,options:e.sparePartMasterProducts,placeholder:e.t(`SelectProduct`),disabled:e.masterProductSelected,"no-results-message":e.t(`NoResults`),"onUpdate:modelValue":e.setMasterProductId},null,8,[`model-value`,`options`,`placeholder`,`disabled`,`no-results-message`,`onUpdate:modelValue`]),e.masterProductSelected?(H(),W(s,{key:0,icon:`stop-not-allowed`,class:`mt-2`,onClick:X(e.clear,[`prevent`])},{default:P(()=>[q(j(e.t(`ClearProduct`)),1)]),_:1},8,[`onClick`])):J(``,!0)])):(H(),W(c,{key:1},{default:P(()=>[q(j(e.t(`TooManyMasterProducts`)),1)]),_:1}))]),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])])):J(``,!0)],2)}var CY=Q(yY,[[`render`,SY]]),wY=L({name:`pis-products-search-no-results`,components:{Btn:Iy,Clickable:wm,Image:CO},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),{componentName:r,isReady:i,isWebComponent:a,instance:o,store:s,routeData:c,t:l}=dB(t,e.instanceId,[$.Products]),u=Ut({totalCount:0,itemsCount:0,items:[]});return kr(async()=>{u.items=[],setTimeout(async()=>{var e;if((e=c.value)!=null&&(e=e.search)!=null&&e.searchText){let e=[];try{var t,i;let n=await((t=o.value)==null?void 0:t.execute(new Vp({searchText:((i=c.value)==null||(i=i.search)==null?void 0:i.searchText)??``,categorySearch:!0}).from(r)));n&&n.categories&&n.categories.forEach((t,n)=>{var r,i,a;if(n>1)return;let o=``;t.breadcrumbs&&t.breadcrumbs.length>0&&(o=t.breadcrumbs.slice(0,t.breadcrumbs.length-1).map(e=>e.name).join(` > `)),e.push({attributes:{},productId:((r=t.match)==null?void 0:r.cid)??``,text:(i=t.match)==null?void 0:i.name,secondaryText:o,description:(a=t.keywords)==null?void 0:a.join(`, `),images:t.images,type:`category`,location:`top`,sparePart:!1,exactMatch:!1})})}catch{}u.items=e,n.value=!0}else n.value=!0},1)}),{root:t,componentName:r,isReady:i,isWebComponent:a,store:s,autocomplete:u,isLoaded:n,t:l,clearResults:async()=>{try{var e,t;await((e=o.value)==null?void 0:e.execute(new yp({searchText:``,searchType:(t=c.value)==null||(t=t.search)==null?void 0:t.searchType}).from(r)))}catch{}},getThumbnailUrl:e=>{if(e.images&&e.images.length>0)return e.images[0].thumbnailUrl},setClassification:async e=>{if(o.value&&e)try{await o.value.execute(new Op({cid:e,clearSearch:!0}).from(r))}catch{}}}}}),TY={class:`h5`},EY={key:0,class:`mt-4`},DY={style:{width:`4rem`,"min-width":`4rem`},class:`me-2`},OY={class:`fw-bold ext-display-name`},kY=[`onClick`],AY={key:0,class:`small ext-all-identifiers text-wrap`},jY={key:1,class:`small ext-description text-wrap`},MY={class:`mt-4`};function NY(e,t,n,r,i,a){let o=R(`Image`),s=R(`Clickable`),c=R(`Btn`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.isLoaded?(H(),U(V,{key:0},[G(`div`,null,[G(`p`,TY,j(e.autocomplete.items.length?e.t(`NoProductResults`):e.t(`NoResults`)),1),G(`p`,null,[G(`strong`,null,j(e.t(`Suggestions`))+`:`,1)]),G(`ul`,null,[G(`li`,null,j(e.t(`CheckSpelling`)),1),G(`li`,null,j(e.t(`DifferentKeywords`)),1),G(`li`,null,j(e.t(`ContactSupport`)),1)])]),e.autocomplete.items.length?(H(),U(`div`,EY,[G(`strong`,null,j(e.t(`CategorySuggestions`)),1),(H(!0),U(V,null,z(e.autocomplete.items,(t,n)=>(H(),U(`div`,{key:n,class:`mt-3`},[t.type===`category`?(H(),W(s,{key:0,class:`d-flex align-items-center dropdown-item`,onClick:n=>e.setClassification(t.productId)},{default:P(()=>[G(`div`,null,[G(`div`,DY,[K(o,{src:e.getThumbnailUrl(t)},null,8,[`src`])])]),G(`div`,null,[G(`div`,OY,[G(`a`,{href:`#`,onClick:X(n=>e.setClassification(t.productId),[`prevent`])},j(t.text),9,kY)]),t.description?(H(),U(`div`,AY,j(e.t(`Keywords`))+`:`+j(t.description),1)):J(``,!0),t.secondaryText?(H(),U(`div`,jY,j(t.secondaryText),1)):J(``,!0)])]),_:2},1032,[`onClick`])):J(``,!0)]))),128))])):J(``,!0),G(`div`,MY,[K(c,{onClick:X(e.clearResults,[`prevent`])},{default:P(()=>[q(j(e.t(`Clear`)),1)]),_:1},8,[`onClick`])])],64)):J(``,!0)],2)}var PY=Q(wY,[[`render`,NY]]),FY=L({name:`pis-products-search-pagination`,components:{Pagination:tx,PaginationAmount:Yv,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isWebComponent:r,isReady:i,instance:a,store:o,routeData:s,t:c,widerThan:l,narrowerThan:u,emit:d}=dB(t,e.instanceId,[$.Products]),f=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.pagination)??{}}),p=Y(()=>{var e,t;let n=(e=a.value)==null?void 0:e.router.history;return((t=o.value)==null?void 0:t.options.hideInitialSearchResults)&&n&&n.length<=2}),m=Y(()=>{var e;return((e=o.value)==null||(e=e.data.products)==null?void 0:e.totalCount)??0}),h=Y(()=>{var e;return(e=s.value)==null||(e=e.search)==null?void 0:e.pagination}),g=async e=>{if(a.value)try{await a.value.execute(new jp({page:e}).from(n))}catch{}},_=Y(()=>{var e;return Math.ceil(m.value/(((e=s.value)==null||(e=e.search)==null||(e=e.pagination)==null?void 0:e.pageSize)??1))}),v=Y(()=>{var e;return(e=h.value)==null?void 0:e.page});return{root:t,visible:Y(()=>f.value.visible),componentName:n,isWebComponent:r,isReady:i,store:o,hideIfInitial:p,totalCount:m,pagination:h,routeData:s,componentOptions:f,instance:a,totalPages:_,page:v,t:c,widerThan:l,narrowerThan:u,changePage:g,emit:d,reactiveContext:lg}}}),IY={ref:`root`,class:`pis-component`,"aria-label":`Items page navigation`},LY={key:0,class:`my-2`};function RY(e,t,n,r,i,a){var o;let s=R(`PaginationAmount`),c=R(`MountPoint`),l=R(`Pagination`);return H(),U(`nav`,IY,[e.isReady&&e.visible?(H(),U(V,{key:0},[!e.hideIfInitial&&e.totalCount&&e.pagination?(H(),U(`div`,{key:0,class:A([`d-flex align-items-center justify-content-between mt-4`,[e.widerThan(`md`)?`flex-row`:`flex-column`]])},[e.componentOptions.hideCounts===!0?J(``,!0):(H(),U(`div`,LY,[K(s,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0)},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`])])),e.componentOptions.paginationTemplate?(H(),W(c,{key:1,callbacks:e.componentOptions.paginationTemplate,ctx:e.reactiveContext({instance:e.instance,page:e.page,pageSize:e.pagination.pageSize,totalPages:e.totalPages,totalCount:e.totalCount,changePage:e.changePage,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])):J(``,!0),K(l,{class:A([`my-2`,e.componentName]),total:Math.ceil(e.totalCount/(((o=e.pagination)==null?void 0:o.pageSize)??1)),current:e.pagination.page,"trim-to":e.componentOptions.visiblePages,"narrow-than":e.narrowerThan,onChange:e.changePage},null,8,[`class`,`total`,`current`,`trim-to`,`narrow-than`,`onChange`])],2)):J(``,!0)],64)):J(``,!0)],512)}var zY=Q(FY,[[`render`,RY]]),BY=L({name:`pis-products-search-part-types`,components:{Card:SE,SparePartTypeList:Vq,Message:NE},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{isReady:n,isWebComponent:r,componentName:i,instance:a,store:o,t:s}=dB(t,e.instanceId,[$.PartTypes]),c=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.partTypes)??{}}),l=Y(()=>{var e;return((e=o.value)==null||(e=e.data.partTypes)==null?void 0:e.items)??[]}),u=Y(()=>{var e;return(e=a.value)==null||(e=e.router.routeData)==null||(e=e.search)==null?void 0:e.partsType});return{root:t,isReady:n,isWebComponent:r,componentName:i,componentOptions:c,store:o,visible:Y(()=>{var e;return((e=o.value)==null||(e=e.options.appSettings)==null?void 0:e.treeType)===`Parts`&&c.value.visible}),partTypes:l,currentPartType:u,t:s,setPartType:async e=>{if(a.value&&e&&e.type&&u.value!=e.type)try{await a.value.execute(new kp({partsType:e.type}).from(i))}catch{}}}}}),VY={key:0},HY={key:1,class:`card-body`};function UY(e,t,n,r,i,a){let o=R(`SparePartTypeList`),s=R(`Message`),c=R(`Card`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,VY,[K(c,{class:`mb-4`,icon:e.componentOptions.icon&&`tool-edit`,header:e.t(`SparePartsType`,!0),"use-markup":e.componentOptions.card,collapsed:e.componentOptions.collapsed},{list:P(()=>{var t;return[(t=e.partTypes)!=null&&t.length?(H(),W(o,{key:0,"part-types":e.partTypes,"current-part-type":e.currentPartType,onClickItem:e.setPartType},null,8,[`part-types`,`current-part-type`,`onClickItem`])):(H(),U(`div`,HY,[K(s,null,{default:P(()=>[q(j(e.t(`NoSparePartTypes`)),1)]),_:1})]))]}),_:1},8,[`icon`,`header`,`use-markup`,`collapsed`])])):J(``,!0)],2)}var WY=Q(BY,[[`render`,UY]]),GY=L({name:`pis-products-search-selection`,components:{MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{instance:n,componentName:r,isReady:i,isWebComponent:a,store:o,widerThan:s,t:c}=dB(t,e.instanceId,[$.Products]),l=Y(()=>{var e;return(e=o.value)==null||(e=e.options)==null||(e=e.components)==null||(e=e.search)==null?void 0:e.selection});return{root:t,instance:n,componentName:r,isReady:i,visible:Y(()=>{var e;return(e=o.value)==null||(e=e.options)==null||(e=e.components)==null||(e=e.search)==null||(e=e.selection)==null?void 0:e.visible}),isWebComponent:a,store:o,componentOptions:l,widerThan:s,t:c,reactiveContext:lg}}}),KY={key:0,class:`card p-2`},qY={class:`row`},JY={key:0,class:`me-3`},YY={key:1};function XY(e,t,n,r,i,a){var o,s,c,l,u,d;let f=R(`MountPoint`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.visible?(H(),U(`div`,KY,[G(`div`,qY,[(o=e.componentOptions)!=null&&o.countVisible?(H(),U(`div`,{key:0,class:A([e.widerThan(`md`)?`col-2`:`col-12`])},[G(`strong`,null,j((s=e.instance)==null?void 0:s.selection.count),1),q(` `+j(e.t(`ItemsSelected`,!0)),1)],2)):J(``,!0),G(`div`,{class:A([[e.widerThan(`md`)?`col-4`:`col-12`],`d-flex flex-row`])},[(c=e.componentOptions)!=null&&c.selectAllVisible?(H(),U(`div`,JY,[G(`a`,{href:``,onClick:t[0]||(t[0]=X(()=>{var t;return(t=e.instance)==null?void 0:t.selection.selectAll()},[`prevent`]))},j(e.t(`SelectAll`,!0)),1)])):J(``,!0),(l=e.componentOptions)!=null&&l.deselectAllVisible&&(u=e.instance)!=null&&u.selection.count?(H(),U(`div`,YY,[G(`a`,{href:``,onClick:t[1]||(t[1]=X(()=>{var t;return(t=e.instance)==null?void 0:t.selection.clear()},[`prevent`]))},j(e.t(`DeselectAll`,!0)),1)])):J(``,!0)],2),(d=e.componentOptions)!=null&&d.actionsTemplate?(H(),U(`div`,{key:1,class:A([e.widerThan(`md`)?`col-6 text-end`:`col-12 `])},[K(f,{callbacks:e.componentOptions.actionsTemplate,ctx:e.reactiveContext({instance:e.instance,t:e.t})},null,8,[`callbacks`,`ctx`])],2)):J(``,!0)])])):J(``,!0)],2)}var ZY=Q(GY,[[`render`,XY]]),QY=L({name:`pis-products-search-table`,components:{Icon:$h,Tooltip:Fw,PisReplacements:KB,Clickable:wm,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,isWebComponent:i,instance:a,store:o,routeData:s,emit:c,t:l}=dB(t,e.instanceId,[$.Products]),u=Y(()=>{var e;return(e=o.value)==null||(e=e.data.products)==null?void 0:e.items}),d=Y(()=>{var e;return((e=a.value)==null?void 0:e.registeredComponents.has(`pis-products-preview`))??!1}),f=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.table)??{}}),p=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.configurators}),m=Y(()=>{var e;if((e=a.value)!=null&&(e=e.router.routeData)!=null&&(e=e.search)!=null&&e.cid){var t;let e=(t=a.value)==null||(t=t.store)==null||(t=t.data.breadcrumbs)==null?void 0:t.items;if(e){var n;return(n=e[e.length-1])==null?void 0:n.name}}}),h=Y(()=>{var e,t;let n=(e=a.value)==null?void 0:e.router.history;return((t=o.value)==null?void 0:t.options.hideInitialSearchResults)&&n&&n.length<=2}),g=Y(()=>{var e,t;let n=(e=s.value)==null||(e=e.search)==null?void 0:e.masterProductId;if(((t=o.value)==null||(t=t.options.appSettings)==null?void 0:t.treeType)==ou.PRODUCTS){var r;return(r=f.value.columns)==null?void 0:r.filter(e=>e.treeTypes.indexOf(ou.PRODUCTS)>-1&&(e.masterProductRequired&&n||!e.masterProductRequired))}var i;return(i=f.value.columns)==null?void 0:i.filter(e=>e.treeTypes.indexOf(ou.PARTS)>-1&&(e.masterProductRequired&&n||!e.masterProductRequired))}),_=Y(()=>{var e;return(e=o.value)==null||(e=e.data.configurators)==null?void 0:e.items}),v=Y(()=>{var e;return(e=u.value)==null?void 0:e.some(({additionalInfo:e})=>e==null?void 0:e.length)}),y=async e=>{if(s.value&&e)try{var t;await((t=a.value)==null?void 0:t.execute(new bp(e).from(n)))}catch{}};return{root:t,componentName:n,componentOptions:f,instance:a,isReady:r,isWebComponent:i,store:o,routeData:s,productsItems:u,previewEnabled:d,hideIfInitial:h,columns:g,configuratorOptions:p,configurators:_,shouldDisplayAdditionalInfo:v,replacementsVisible:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),currentCIDName:m,t:l,emit:c,details:y,preview:async e=>{try{var t;await((t=a.value)==null?void 0:t.execute(new xp({productId:e.productId}).from(n)))}catch{}},attrValue:Us,additionalInfo:Gs,variantsAvailableInfo:Ks,showConfigurator:async e=>{try{var t;await((t=a.value)==null?void 0:t.execute(new wp(e).from(n)))}catch{}},attrValues:Ws,reactiveContext:lg,cellCtx:hg(e=>({instance:a.value,col:e.col,item:e.item,emit:c,details:y,attrValue:Us,attrValues:Ws,t:l}))}}}),$Y={key:0,class:`table-responsive pis-scroll`},eX={class:`table`},tX={key:0,style:{width:`1%`}},nX={key:1,style:{width:`1%`}},rX={key:2,style:{width:`1%`}},iX={key:0},aX={key:1},oX={key:2},sX={class:`bg-light`},cX={key:0},lX={key:1},uX={key:2},dX=[`colspan`],fX={class:`row g-0`},pX={class:`col`},mX={class:`text-muted`},hX={key:0},gX={key:1},_X={key:2},vX=[`colspan`],yX={class:`row g-0`},bX={class:`col`},xX={class:`fw-bolder`},SX={class:`col text-end`},CX={key:0},wX={class:`ext-select-checkbox`},TX=[`checked`,`onClick`],EX={key:1},DX={key:2},OX={key:1},kX={key:2},AX={key:4,class:`d-flex align-items-center fw-bold mt-1`},jX={key:5,class:`mt-2`};function MX(e,t,n,r,i,a){var o;let s=R(`MountPoint`),c=R(`Icon`),l=R(`Clickable`),u=R(`Tooltip`),d=R(`PisReplacements`),f=R(`icon`),p=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.componentOptions.visible?(H(),U(V,{key:0},[!e.hideIfInitial&&e.productsItems&&e.productsItems.length?(H(),U(`div`,$Y,[G(`table`,eX,[G(`colgroup`,null,[e.componentOptions.selectable?(H(),U(`col`,tX)):J(``,!0),e.previewEnabled?(H(),U(`col`,nX)):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`col`,rX)):J(``,!0),(H(!0),U(V,null,z(e.columns,(e,t)=>(H(),U(`col`,{key:t,style:k({width:e.width})},null,4))),128))]),G(`thead`,null,[G(`tr`,null,[e.componentOptions.selectable?(H(),U(`th`,iX)):J(``,!0),e.previewEnabled?(H(),U(`th`,aX)):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`th`,oX)):J(``,!0),(H(!0),U(V,null,z(e.columns,(t,n)=>(H(),U(`th`,{key:n},[t.headerTemplate?(H(),W(s,{key:0,callbacks:t.headerTemplate,ctx:e.reactiveContext({t:e.t,col:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:1},[q(j(t.caption),1)],64))]))),128))])]),G(`tbody`,null,[e.configurators&&e.configuratorOptions.visible&&e.currentCIDName?(H(),U(V,{key:0},[G(`tr`,sX,[e.componentOptions.selectable?(H(),U(`td`,cX)):J(``,!0),e.previewEnabled?(H(),U(`td`,lX)):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`td`,uX)):J(``,!0),G(`td`,{colspan:(o=e.columns)==null?void 0:o.length},[G(`div`,fX,[G(`div`,pX,[G(`div`,mX,j([e.currentCIDName,e.configurators.length>1?e.t(`Configurators`):e.t(`Configurator`)].join(` - `).concat(`:`)),1)])])],8,dX)]),(H(!0),U(V,null,z(e.configurators,t=>{var n;return H(),U(`tr`,{key:t.code,class:`bg-light`},[e.componentOptions.selectable?(H(),U(`td`,hX)):J(``,!0),e.previewEnabled?(H(),U(`td`,gX)):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`td`,_X)):J(``,!0),G(`td`,{colspan:(n=e.columns)==null?void 0:n.length},[G(`div`,yX,[G(`div`,bX,[G(`div`,xX,j(t.productId),1)]),G(`div`,SX,[e.configuratorOptions.actionTemplate?(H(),W(s,{key:0,callbacks:e.configuratorOptions.actionTemplate,ctx:e.reactiveContext({t:e.t,item:t,showConfigurator:e.showConfigurator,emit:e.emit})},null,8,[`callbacks`,`ctx`])):J(``,!0)])])],8,vX)])}),128))],64)):J(``,!0),(H(!0),U(V,null,z(e.productsItems,t=>{var n,r;return H(),U(`tr`,{key:t.productId,class:A({"bg-light":t.exactMatch,"ext-selected":(n=e.instance)==null?void 0:n.selection.isSelected(t)})},[e.componentOptions.selectable?(H(),U(`td`,CX,[G(`div`,wX,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(r=e.instance)==null?void 0:r.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,TX)])])):J(``,!0),e.previewEnabled?(H(),U(`td`,EX,[K(l,{class:`d-flex ext-icon-preview`,title:e.t(t.inactive?`PreviewNotAvailable`:`Preview`,!0),disabled:t.inactive,onClick:X(n=>!t.inactive&&e.preview(t),[`prevent`])},{default:P(()=>[K(c,{name:`eye-show`,size:24})]),_:1},8,[`title`,`disabled`,`onClick`])])):J(``,!0),e.shouldDisplayAdditionalInfo?(H(),U(`td`,DX,[t.additionalInfo&&t.additionalInfo.length?(H(),W(u,{key:0,text:e.additionalInfo(t.additionalInfo)},{default:P(()=>[K(c,{class:`text-warning`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0)])):J(``,!0),(H(!0),U(V,null,z(e.columns,(n,r)=>(H(),U(`td`,{key:r},[n.cellTemplate?(H(),W(s,{key:0,callbacks:n.cellTemplate,ctx:e.cellCtx({item:t,col:n})},null,8,[`callbacks`,`ctx`])):n.dataField==`ProductId`?(H(),U(`span`,OX,[K(l,{onClick:n=>e.details(t)},{default:P(()=>[q(j(e.attrValue(t,n.dataField)),1)]),_:2},1032,[`onClick`])])):(H(),U(`span`,kX,j(e.attrValue(t,n.dataField)),1)),n.showReplacements&&t.replacements&&t.replacements.length?(H(),W(d,{key:3,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),n.showVariants&&t.variantsAvailable?(H(),U(`div`,AX,[K(f,{class:`text-muted me-2`,name:`information-circle`}),F(G(`span`,null,null,512),[[p,e.t(`VariantsAvailable`)+`: `+e.variantsAvailableInfo(t.variantAttributes)+`.`]])])):J(``,!0),n.showAllIdentifiers?(H(),U(`div`,jX,[(H(!0),U(V,null,z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`badge text-bg-light d-inline-block`},j(e),1))),128))])):J(``,!0)]))),128))],2)}),128))])])])):J(``,!0)],64)):J(``,!0)],2)}var NX=Q(QY,[[`render`,MX]]),PX=L({name:`pis-products-search-toolbar`,components:{PaginationAmount:Yv,Icon:$h,Clickable:wm,Btn:Iy,Dropdown:pb,Arrow:qb,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),n=M(!1),r=au,{componentName:i,isReady:a,isWebComponent:o,instance:s,store:c,routeData:l,t:u,widerThan:d,narrowerThan:f,emit:p}=dB(t,e.instanceId),m=Y(()=>{var e,t;let n=(e=s.value)==null?void 0:e.router.history;return((t=c.value)==null?void 0:t.options.hideInitialSearchResults)&&n&&n.length<=2}),h=[{type:`table`,tName:`DisplayModeTable`,icon:`data-table-grid`,relatedComponent:`pis-products-search-table-router-view`},{type:`list`,tName:`DisplayModeList`,icon:`list-bullet-options`,relatedComponent:`pis-products-search-list-router-view`},{type:`grid`,tName:`DisplayModeGrid`,icon:`grid-matrix`,relatedComponent:`pis-products-search-grid-router-view`}],g=Y(()=>{var e;return(e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.toolbar}),_=Y(()=>{var e;return(e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.subViews}),v=Y(()=>{if(!_.value)return h;let e=h.filter(({type:e,relatedComponent:t})=>{var n,r;return((n=_.value)==null?void 0:n.includes(e))&&((r=s.value)==null?void 0:r.registeredComponents.has(t))}),t=[];return _.value.forEach(n=>{var r=e.find(e=>e.type==n);r&&t.push(r)}),t}),y=Y(()=>{var e;return(e=c.value)==null||(e=e.data.products)==null?void 0:e.totalCount}),b=Y(()=>{var e;return(e=l.value)==null||(e=e.search)==null?void 0:e.pagination}),x=Y({get:()=>{var e;return(e=l.value)==null||(e=e.search)==null?void 0:e.sortField},set:async e=>{try{var t;await((t=s.value)==null?void 0:t.execute(new Np({sortField:e}).from(i)))}catch{}}}),S=Y({get:()=>{var e;return((e=b.value)==null?void 0:e.pageSize)??24},set:async e=>{try{var t;await((t=s.value)==null?void 0:t.execute(new Mp({pageSize:e}).from(i)))}catch{}}}),C=Y(()=>{var e;return(e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.pageSizes});return{root:t,componentName:i,isReady:a,isWebComponent:o,store:c,routeData:l,toolbarVisible:Y(()=>{var e,t;return((e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.visible)&&((t=c.value.data.products)==null||(t=t.items)==null?void 0:t.length)}),hideIfInitial:m,subViews:h,visibleSubViews:v,totalCount:y,pagination:b,sortByItems:r,sortBy:x,pageSizeItems:C,pageSize:S,exportMenuOpen:n,exportMenu:Y(()=>{var e;return(e=c.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.toolbar)==null?void 0:e.exportMenu}),componentOptions:g,instance:s,executeExportMenuItemCommand:async e=>{try{var t;await((t=s.value)==null?void 0:t.execute(new Up(e).from(i)))}catch{}},t:u,widerThan:d,narrowerThan:f,changeSubView:async e=>{try{var t;await((t=s.value)==null?void 0:t.execute(new Dp({subView:e}).from(i)))}catch{}},isSubViewActive:({type:e})=>{var t;return e===((t=l.value)==null||(t=t.search)==null?void 0:t.subView)},emit:p,reactiveContext:lg}}}),FX={key:0,class:`order-2 my-2 mx-2`},IX={key:1,class:`order-3 list-unstyled d-flex justify-content-center my-2 mx-2`},LX={key:0},RX={key:0,class:`d-flex align-items-center`},zX={class:`text-nowrap`},BX=[`value`],VX={key:1,class:`d-flex align-items-center ms-2`},HX={class:`text-nowrap`},UX=[`value`,`textContent`],WX={key:3,class:`order-5 mx-2 my-2`},GX={key:4,class:`order-3 mx-2 my-2`};function KX(e,t,n,r,i,a){var o,s,c,l,u;let d=R(`PaginationAmount`),f=R(`Icon`),p=R(`Arrow`),m=R(`Btn`),h=R(`Clickable`),g=R(`Dropdown`),_=R(`MountPoint`);return H(),U(`div`,{ref:`root`,class:A([`pis-component`,e.componentName])},[e.isReady&&e.toolbarVisible?(H(),U(V,{key:0},[e.hideIfInitial?J(``,!0):(H(),U(`div`,{key:0,class:A([`mt-3 mb-4 mx-n2 d-flex flex-row justify-content-between align-items-center`,[e.narrowerThan(`xl`)&&`flex-wrap`]])},[(o=e.componentOptions)!=null&&o.countVisible&&e.totalCount&&e.pagination?(H(),U(`div`,FX,[K(d,{"total-count":e.totalCount,page:e.pagination.page,"page-size":e.pagination.pageSize,"showing-text":e.t(`PaginationShowing`,!0),"of-text":e.t(`PaginationOf`,!0)},null,8,[`total-count`,`page`,`page-size`,`showing-text`,`of-text`])])):J(``,!0),(s=e.componentOptions)!=null&&s.subViewsVisible&&(c=e.visibleSubViews)!=null&&c.length&&e.visibleSubViews.length>1?(H(),U(`ul`,IX,[(H(!0),U(V,null,z(e.visibleSubViews,t=>(H(),U(`li`,{key:t.type},[(H(),W(Vr(e.isSubViewActive(t)?`div`:`Clickable`),{class:A([`d-flex align-items-center py-2 mx-2 text-body text-decoration-none`,[e.isSubViewActive(t)&&`active border-bottom border-primary border-2`,`ext-`+t.type]]),role:`tab`,"aria-selected":e.isSubViewActive(t),title:`${e.t(`ChangeDisplayModeTo`)} ${e.t(t.tName)}`,onClick:X(n=>e.changeSubView(t.type),[`prevent`])},{default:P(()=>[K(f,{name:t.icon,class:`mx-1`},null,8,[`name`]),e.widerThan(`sm`)?(H(),U(`span`,LX,j(e.t(t.tName)),1)):J(``,!0)]),_:2},1032,[`class`,`aria-selected`,`title`,`onClick`]))]))),128))])):J(``,!0),(l=e.componentOptions)!=null&&l.sortVisible||(u=e.componentOptions)!=null&&u.pageSizesVisible?(H(),U(`div`,{key:2,class:A([`d-flex justify-content-between my-2 mx-2`,[e.narrowerThan(`xl`)?`w-100 order-1`:`order-5`]])},[e.componentOptions.sortVisible?(H(),U(`label`,RX,[G(`span`,zX,j(e.t(`SortBy`))+`:`,1),F(G(`select`,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.sortBy=t),class:A([`form-select ms-2 ext-sort`,[e.narrowerThan(`xl`)&&`w-100`]])},[(H(!0),U(V,null,z(e.sortByItems,(t,n)=>(H(),U(`option`,{key:n,value:t},j(e.t(`SortBy${t}`)),9,BX))),128))],2),[[Cs,e.sortBy]])])):J(``,!0),e.componentOptions.pageSizesVisible?(H(),U(`label`,VX,[G(`span`,HX,j(e.t(`PageSize`))+`:`,1),F(G(`select`,{"onUpdate:modelValue":t[1]||(t[1]=t=>e.pageSize=t),class:`form-select ms-2 ext-page-size`},[(H(!0),U(V,null,z(e.pageSizeItems,e=>(H(),U(`option`,{key:e,value:e,textContent:j(e)},null,8,UX))),128))],512),[[Cs,e.pageSize]])])):J(``,!0)],2)):J(``,!0),e.exportMenu&&e.exportMenu.visible&&e.exportMenu.items.length>0?(H(),U(`div`,WX,[K(g,{open:e.exportMenuOpen,"onUpdate:open":t[3]||(t[3]=t=>e.exportMenuOpen=t),items:e.exportMenu.items,class:`ext-export-dropdown`},{activator:P(({on:n})=>[K(m,Oa(qr(n),{onClick:t[2]||(t[2]=t=>e.exportMenuOpen=!e.exportMenuOpen)}),{default:P(()=>[q(j(e.t(`Export`))+` `,1),K(p,{dir:`down`,class:`ms-1`})]),_:1},16)]),item:P(({item:t})=>[K(h,{class:A([`dropdown-item`,[`ext-export-`+t.code]]),disabled:t.disabled,onClick:n=>!t.disabled&&e.executeExportMenuItemCommand(t)},{default:P(()=>[q(j(t.text),1)]),_:2},1032,[`class`,`disabled`,`onClick`])]),_:1},8,[`open`,`items`])])):J(``,!0),e.componentOptions&&e.componentOptions.customActionsTemplate?(H(),U(`div`,GX,[K(_,{callbacks:e.componentOptions.customActionsTemplate,ctx:e.reactiveContext({instance:e.instance,emit:e.emit,t:e.t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)],2))],64)):J(``,!0)],2)}var qX=Q(PX,[[`render`,KX]]),JX=L({name:`pis-products-search-grid-router-view`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i,routeData:a}=dB(t,e.instanceId,[$.Products]);return{root:t,componentName:n,isReady:r,store:i,routeData:a}}}),YX={key:0};function XX(e,t,n,r,i,a){var o;return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&e.routeData&&e.routeData.view===`search`&&((o=e.routeData.search)==null?void 0:o.subView)==`grid`?(H(),U(`div`,YX,[B(e.$slots,`default`)])):J(``,!0)],2)}var ZX=Q(JX,[[`render`,XX]]),QX=L({name:`pis-products-search-list-router-view`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i,routeData:a}=dB(t,e.instanceId,[$.Products]);return{root:t,componentName:n,isReady:r,store:i,routeData:a}}}),$X={key:0};function eZ(e,t,n,r,i,a){var o;return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&e.routeData&&e.routeData.view===`search`&&((o=e.routeData.search)==null?void 0:o.subView)==`list`?(H(),U(`div`,$X,[B(e.$slots,`default`)])):J(``,!0)],2)}var tZ=Q(QX,[[`render`,eZ]]),nZ=L({name:`pis-products-search-no-results-gate`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i}=dB(t,e.instanceId);return{root:t,componentName:n,store:i,isReady:r,productsItems:Y(()=>{var e;return(e=i.value)==null||(e=e.data.products)==null?void 0:e.items})}}}),rZ={key:0};function iZ(e,t,n,r,i,a){var o;return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&!((o=e.store)!=null&&o.data.isLoadingData)&&(!e.productsItems||!e.productsItems.length)?(H(),U(`div`,rZ,[B(e.$slots,`default`)])):J(``,!0)],2)}var aZ=Q(nZ,[[`render`,iZ]]),oZ=L({name:`pis-products-search-table-router-view`,props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isReady:r,store:i,routeData:a}=dB(t,e.instanceId,[$.Products]);return{root:t,componentName:n,isReady:r,store:i,routeData:a}}}),sZ={key:0};function cZ(e,t,n,r,i,a){var o;return H(),U(`div`,{ref:`root`,class:A(e.componentName)},[e.isReady&&e.routeData&&e.routeData.view===`search`&&((o=e.routeData.search)==null?void 0:o.subView)==`table`?(H(),U(`div`,sZ,[B(e.$slots,`default`)])):J(``,!0)],2)}var lZ=L({name:`pis-products-layout`,components:{Message:NE,LoadingIndicator:qK,ProductsMobileNav:Yq,ProductsSearchCategories:iJ,ProductsSearchFilters:xJ,ProductsSearchFiltersStatus:OJ,ProductsSearchForm:WJ,ProductsSearchGrid:oY,ProductsSearchHeader:dY,ProductsSearchList:hY,ProductsSearchNoResults:PY,ProductsSearchNoResultsView:aZ,ProductsSearchPagination:zY,ProductsSearchTable:NX,ProductsSearchToolbar:qX,ProductsSearchPartTypes:WY,ProductsSearchFavoriteViews:uJ,ProductsSearchFavoriteCategories:sJ,ProductsSearchSelection:ZY,ProductsDetailsHeader:TK,ProductsDetailsGallery:_K,ProductDetailsGeneralInformation:EU,ProductDetailsReplacements:rW,ProductDetailsIdentifiers:AU,ProductDetailsClassifications:yU,ProductDetailsAttributeGroups:lU,ProductDetailsRelationships:$U,ProductsPreview:FK,ProductsTableView:Q(oZ,[[`render`,cZ]]),ProductsListView:tZ,ProductsGridView:ZX,ProductsSearchNarrowByProduct:CY,ProductsDetailsData:fK,ProductsDetailsActions:QG,ProductsBreadcrumbs:HK,ProductsNotifications:$q,ProductCompare:BV,ProductActionModals:hB,ProductDetailsVariantsSelector:aG,ProductDetailsVariantsTable:qG,ProductDetailsVariantsDropdown:OW},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,instance:r,isWebComponent:i,isReady:a,translationsReady:o,store:s,routeData:c,widerThan:l,t:u}=dB(t,e.instanceId),d=Y(()=>{var e;return(e=s.value)==null?void 0:e.options.allowMobileView}),f=Y(()=>{var e;return((e=s.value)==null?void 0:e.data.productDetail)||void 0}),p=Y(()=>{var e,t,n;return((e=s.value)==null||(e=e.options.components)==null||(e=e.details)==null||(e=e.gallery)==null?void 0:e.visible)&&((t=f.value)==null?void 0:t.item)||((n=s.value)==null||(n=n.options.components)==null||(n=n.details)==null||(n=n.actions)==null?void 0:n.actionTemplate)});I(a,()=>{var e;(e=r.value)==null||e.eventBus.on(`internal:scroll-to-top`,()=>{h()})});let m=e=>e==null?void 0:e.scrollIntoView({behavior:`smooth`}),h=()=>{var e;let n={isHandled:!1};(e=r.value)==null||e.eventBus.emit(`scroll-to-top`,n),n.isHandled||m(t.value)},g=Y(()=>{var e;return(e=c.value)==null?void 0:e.view}),_=Y(()=>{var e;return((e=s.value)==null||(e=e.data.productDetail)==null?void 0:e.item)!=null}),v=Y(()=>{var e;return((e=s.value)==null?void 0:e.data.itemNotFound)===!0});return I(g,async(e,t)=>{e&&t&&e!==t&&h()}),{root:t,componentName:n,isWebComponent:i,isReady:a,instance:r,translationsReady:o,store:s,routeData:c,allowMobileView:d,detailsGalleryVisible:p,itemLoaded:_,itemNotFound:v,widerThan:l,t:u,scrollTop:h}}}),uZ={class:`container-fluid`},dZ={class:`row`},fZ={class:`d-sm-none`},pZ={class:`container-fluid d-print-none`},mZ={key:0},hZ={key:1},gZ={class:`row`},_Z={key:0},vZ={key:2},yZ={class:`container-fluid pis-print-only`},bZ={class:`row`},xZ={class:`container-fluid`};function SZ(e,t,n,r,i,a){let o=R(`ProductsNotifications`),s=R(`ProductsBreadcrumbs`),c=R(`ProductsSearchHeader`),l=R(`ProductsMobileNav`),u=R(`ProductsSearchFavoriteViews`),d=R(`ProductsSearchFavoriteCategories`),f=R(`ProductsSearchNarrowByProduct`),p=R(`ProductsSearchPartTypes`),m=R(`ProductsSearchCategories`),h=R(`ProductsSearchFilters`),g=R(`ProductsSearchForm`),_=R(`ProductsSearchFiltersStatus`),v=R(`ProductsSearchToolbar`),y=R(`ProductsSearchSelection`),b=R(`ProductsSearchTable`),x=R(`ProductsTableView`),S=R(`ProductsSearchList`),C=R(`ProductsListView`),w=R(`ProductsSearchGrid`),T=R(`ProductsGridView`),E=R(`ProductsSearchPagination`),D=R(`ProductsSearchNoResults`),ee=R(`ProductsSearchNoResultsView`),O=R(`ProductsDetailsHeader`),te=R(`ProductDetailsIdentifiers`),ne=R(`ProductDetailsReplacements`),re=R(`ProductDetailsGeneralInformation`),ie=R(`Message`),ae=R(`ProductsDetailsData`),oe=R(`ProductsDetailsGallery`),se=R(`ProductsDetailsActions`),ce=R(`ProductDetailsVariantsSelector`),le=R(`ProductDetailsVariantsDropdown`),ue=R(`ProductDetailsClassifications`),de=R(`ProductDetailsAttributeGroups`),k=R(`ProductDetailsRelationships`),fe=R(`ProductDetailsVariantsTable`),pe=R(`ProductCompare`),me=R(`ProductsPreview`),he=R(`LoadingIndicator`),ge=R(`ProductActionModals`);return H(),U(`div`,{ref:`root`,class:A([`pis-component position-relative`,e.componentName])},[F(G(`div`,null,[K(o),K(he,null,{default:P(()=>{var t,n,r;return[F(G(`div`,null,[G(`div`,uZ,[K(s),K(c),G(`div`,dZ,[G(`div`,{class:A([e.widerThan(`xl`)?`col-3`:e.widerThan(`md`)?`col-4`:`col-12`])},[F(G(`div`,fZ,[K(l)],512),[[Mo,e.allowMobileView]]),G(`div`,{class:A([e.allowMobileView&&`d-none d-sm-block`])},[K(u),K(d),K(f),K(p),K(m),K(h)],2)],2),G(`div`,{class:A([e.widerThan(`xl`)?`col-9`:e.widerThan(`md`)?`col-8`:`col-12`])},[K(g),K(_),K(v),K(y,{class:`mb-2`}),K(x,null,{default:P(()=>[B(e.$slots,`search-table`,{},()=>[K(b)])]),_:3}),K(C,null,{default:P(()=>[B(e.$slots,`search-list`,{},()=>[K(S)])]),_:3}),K(T,null,{default:P(()=>[B(e.$slots,`search-grid`,{},()=>[K(w)])]),_:3}),K(E),K(ee,null,{default:P(()=>[B(e.$slots,`search-no-results`,{},()=>[K(D)])]),_:3})],2)])])],512),[[Mo,((t=e.routeData)==null?void 0:t.view)===`search`]]),F(G(`div`,null,[G(`div`,pZ,[e.itemNotFound?(H(),U(`h4`,mZ,j(e.t(`ProductNotFound`,!0)),1)):(H(),U(`div`,hZ,[F(G(`div`,null,[B(e.$slots,`detail-before-breadcrumbs`)],512),[[Mo,e.itemLoaded]]),F(G(`div`,null,[B(e.$slots,`detail-after-breadcrumbs`)],512),[[Mo,e.itemLoaded]]),K(O),G(`div`,gZ,[G(`div`,{class:A([e.widerThan(`md`)?`col-8`:`col-12`])},[K(te,{class:`mt-3`}),K(ne,{class:`mt-3`}),F(G(`div`,null,[B(e.$slots,`detail-before-general`)],512),[[Mo,e.itemLoaded]]),K(re),F(G(`div`,null,[B(e.$slots,`detail-after-general`)],512),[[Mo,e.itemLoaded]]),K(ae,null,{"detail-downloads":P(()=>[B(e.$slots,`detail-downloads`,{},()=>[K(ie,{class:`p-2`},{default:P(()=>[q(j(e.t(`DownloadsNotAvailable`)),1)]),_:1})])]),_:3})],2),G(`div`,{class:A([e.widerThan(`md`)?`col-4`:`col-12 order-first`])},[e.detailsGalleryVisible?F((H(),U(`div`,_Z,[B(e.$slots,`detail-before-gallery`)],512)),[[Mo,e.itemLoaded]]):J(``,!0),e.detailsGalleryVisible?(H(),U(V,{key:1},[K(oe,{class:`mt-5`}),K(se)],64)):J(``,!0),K(ce),K(le),e.detailsGalleryVisible?F((H(),U(`div`,vZ,[B(e.$slots,`detail-after-gallery`)],512)),[[Mo,e.itemLoaded]]):J(``,!0)],2)])]))]),G(`div`,yZ,[G(`div`,bZ,[K(te,{class:`mt-3`}),K(ne,{class:`mt-3`}),K(re,{class:`mt-3`}),K(ue,{class:`mt-3`}),K(de,{class:`mt-3`}),K(k,{class:`mt-3`}),K(fe,{class:`mt-3`})])])],512),[[Mo,((n=e.routeData)==null?void 0:n.view)===`detail`]]),F(G(`div`,null,[G(`div`,xZ,[K(pe)])],512),[[Mo,((r=e.routeData)==null?void 0:r.view)===`compare`]]),K(me)]}),_:3}),K(ge)],512),[[Mo,e.isReady]])],2)}var CZ=Q(lZ,[[`render`,SZ]]),wZ=L({name:`pis-products-search-grid-horizontal`,components:{Image:CO,PisReplacements:KB,Tooltip:Fw,Icon:$h,Carousel:uI,Slide:_I,Pagination:gI,Navigation:hI,MountPoint:cg},props:{instanceId:{type:String,default:void 0}},setup(e){let t=M(),{componentName:n,isWebComponent:r,isReady:i,instance:a,store:o,routeData:s,t:c,widerThan:l,narrowerThan:u,emit:d}=dB(t,e.instanceId,[$.Products]),f=M(),p=I(()=>i.value,()=>{a.value&&(p(),a.value.eventBus.on(`route-changed`,()=>{let e=f.value;e&&(jn(()=>{e.slideTo(0)}),setTimeout(()=>{g.value=!0},100))}),_())}),m=()=>{let e=v.value.carousel,t=window.innerWidth;if(e){if(!e.breakpoints)return e.defaults;let n=Object.keys(e.breakpoints);if(n.length){for(let r=n.length-1;r>=0;r--)if(t>parseInt(n[r]))return e.breakpoints[n[r]]}return e.defaults}return{}},h=M(),g=M(!1),_=()=>{h.value=m()};kr(()=>{window.addEventListener(`resize`,_)}),Nr(()=>{window.removeEventListener(`resize`,_)});let v=Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null?void 0:e.gridHorizontal)??{}}),y=Y(()=>{var e;return(e=o.value)==null||(e=e.options.components)==null||(e=e.search)==null||(e=e.common)==null?void 0:e.configurators}),b=async e=>{if(!(e!=null&&e.inactive)&&s.value&&e)try{var t;await((t=a.value)==null?void 0:t.execute(new bp(e).from(n)))}catch{}};return{root:t,instance:a,loaded:g,componentName:n,componentOptions:v,isWebComponent:r,isReady:i,store:o,productsItems:Y(()=>{var e;return((e=o.value)==null||(e=e.data.products)==null?void 0:e.items)??[]}),configurators:Y(()=>{var e;return(e=o.value)==null||(e=e.data.configurators)==null?void 0:e.items}),configuratorOptions:y,replacementsVisible:Y(()=>{var e;return((e=o.value)==null||(e=e.options.components)==null||(e=e.common)==null?void 0:e.hideReplacements)!=1}),settings:Y(()=>{let e=v.value.carousel.defaults||{};return e?{...e,mouseDrag:v.value.carousel.mouseDrag,touchDrag:v.value.carousel.touchDrag,wrapAround:v.value.carousel.wrapAround,transition:v.value.carousel.transition}:{}}),breakpoints:Y(()=>v.value.carousel.breakpoints||{}),carousel:f,i18n:Y(()=>({ariaNextSlide:c(`CarouselAriaNextSlide`),ariaPreviousSlide:c(`CarouselAriaPreviousSlide`),ariaNavigateToSlide:c(`CarouselAriaNavigateToSlide`),ariaGallery:c(`CarouselAriaGallery`),itemXofY:c(`CarouselItemXofY`),iconArrowUp:c(`CarouselIconArrowUp`),iconArrowDown:c(`CarouselIconArrowDown`),iconArrowRight:c(`CarouselIconArrowRight`),iconArrowLeft:c(`CarouselIconArrowLeft`)})),currentSettings:h,t:c,widerThan:l,narrowerThan:u,attrValue:Us,attrValues:Ws,details:b,additionalInfo:Gs,variantsAvailableInfo:Ks,emit:d,imageOverlayCtx:hg(e=>({instance:a.value,item:e.item,emit:d,t:c})),titleCtx:hg(e=>({instance:a.value,item:e.item,emit:d,details:b,attrValue:Us,t:c})),itemCtx:hg(e=>({instance:a.value,item:e.item,emit:d,details:b,attrValue:Us,attrValues:Ws,t:c})),actionCtx:hg(e=>({instance:a.value,item:e.item,emit:d,details:b,attrValue:Us,attrValues:Ws,t:c}))}}}),TZ={class:`card-img-top position-relative pt-5`},EZ={key:0},DZ={class:`card-body`},OZ={class:`d-flex justify-content-center text-center`},kZ={key:0,class:`text-muted`},AZ=[`onClick`],jZ={key:2,class:`d-flex justify-content-center text-center`},MZ={key:4,class:`d-flex justify-content-center align-items-center fw-bold mt-1`},NZ={key:0,class:`card-footer`},PZ={class:`text-center`},FZ={key:1,class:`position-absolute p-2 top-0 start-0 ext-select-checkbox`,style:{"z-index":`1`,width:`auto`,"margin-top":`-0.1rem`}},IZ=[`checked`,`onClick`];function LZ(e,t,n,r,i,a){var o;let s=R(`Image`),c=R(`MountPoint`),l=R(`Icon`),u=R(`Tooltip`),d=R(`PisReplacements`),f=R(`icon`),p=R(`slide`),m=R(`navigation`),h=R(`pagination`),g=R(`carousel`),_=Hr(`safe-html`);return H(),U(`div`,{ref:`root`,class:A([`pis-component position-relative`,e.componentName])},[e.isReady&&(o=e.componentOptions)!=null&&o.visible&&e.currentSettings?(H(),W(g,Oa({key:0,ref:`carousel`},e.settings,{breakpoints:e.breakpoints,i18n:e.i18n}),{addons:P(()=>[e.currentSettings.navigationVisible?(H(),W(m,{key:0},{next:P(()=>[K(l,{name:`chevron-right`})]),prev:P(()=>[K(l,{name:`chevron-left`})]),_:1})):J(``,!0),e.currentSettings.paginationVisible?(H(),W(h,{key:1})):J(``,!0)]),default:P(()=>[(H(!0),U(V,null,z(e.productsItems,t=>(H(),W(p,{key:t.productId},{default:P(()=>{var n,r,i;return[G(`div`,{class:A([`card h-100 w-100`,[`mx-`+e.currentSettings.margin]])},[G(`div`,TZ,[K(s,{src:(n=(t.images||[])[0])==null?void 0:n.url,"max-size":300,role:`button`,"hide-frame":``,class:`card-img-top`,style:{"max-width":`80% !important`,margin:`auto`},clickable:e.componentOptions.navigateOnContentClick&&!t.inactive,onClick:X(n=>e.componentOptions.navigateOnContentClick&&!t.inactive&&e.details(t),[`prevent`])},null,8,[`src`,`clickable`,`onClick`]),e.componentOptions.imageOverlayTemplate?(H(),U(`div`,EZ,[K(c,{callbacks:e.componentOptions.imageOverlayTemplate,ctx:e.imageOverlayCtx({item:t})},null,8,[`callbacks`,`ctx`])])):J(``,!0)]),G(`div`,DZ,[G(`div`,OZ,[t.additionalInfo&&t.additionalInfo.length?(H(),W(u,{key:0,text:e.additionalInfo(t.additionalInfo)},{default:P(()=>[K(l,{class:`me-2 text-warning`,name:`warning-triangle`})]),_:1},8,[`text`])):J(``,!0),e.componentOptions.titleTemplate?(H(),W(c,{key:1,callbacks:e.componentOptions.titleTemplate,ctx:e.titleCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(V,{key:2},[t.inactive?(H(),U(`strong`,kZ,j(e.attrValue(t,`#DisplayName`)),1)):(H(),U(`a`,{key:1,href:`#`,onClick:X(n=>e.details(t),[`prevent`])},[G(`strong`,null,j(e.attrValue(t,`#DisplayName`)),1)],8,AZ))],64))]),e.componentOptions.showAllIdentifiers?(H(!0),U(V,{key:0},z(e.attrValues(t,`#AllIdentifiers`),(e,t)=>(H(),U(`div`,{key:t,class:`text-center small text-muted fw-bold my-2`},j(e),1))),128)):J(``,!0),e.componentOptions.itemTemplate?(H(),W(c,{key:1,callbacks:e.componentOptions.itemTemplate,ctx:e.itemCtx({item:t})},null,8,[`callbacks`,`ctx`])):(H(),U(`div`,jZ,[G(`span`,null,j(e.attrValue(t,`CatalogDescription`)),1)])),(r=t.replacements)!=null&&r.length&&e.componentOptions.showReplacements?(H(),W(d,{key:3,class:`text-center mt-3`,instance:e.instance,replacements:t.replacements,visible:e.replacementsVisible},null,8,[`instance`,`replacements`,`visible`])):J(``,!0),e.componentOptions.showVariants&&t.variantsAvailable?(H(),U(`div`,MZ,[K(f,{class:`me-2 text-muted`,name:`information-circle`}),F(G(`span`,null,null,512),[[_,e.t(`VariantsAvailable`)+`: `+e.variantsAvailableInfo(t.variantAttributes)+`.`]])])):J(``,!0)]),e.componentOptions.actionTemplate?(H(),U(`div`,NZ,[G(`div`,PZ,[K(c,{callbacks:e.componentOptions.actionTemplate,ctx:e.actionCtx({item:t})},null,8,[`callbacks`,`ctx`])])])):J(``,!0),e.componentOptions.selectable?(H(),U(`div`,FZ,[G(`input`,{type:`checkbox`,class:`form-check-input`,checked:(i=e.instance)==null?void 0:i.selection.isSelected(t),onClick:n=>{var r;return(r=e.instance)==null?void 0:r.selection.toggle(t)}},null,8,IZ)])):J(``,!0)],2)]}),_:2},1024))),128))]),_:1},16,[`breakpoints`,`i18n`])):J(``,!0)],2)}var RZ=[HK,CZ,Yq,$q,hB,FK,iJ,xJ,OJ,WJ,oY,dY,hY,PY,zY,NX,qX,CY,WY,uJ,sJ,ZY,Q(wZ,[[`render`,LZ]]),fK,_K,TK,EU,AU,rW,QG,LU,qU,lU,$U,yU,aG,OW,qG,BV],zZ=e=>Pf.Products.getInstance(e),BZ=e=>!!(e.store.data.isInitialized&&e.store.data.translationsReady&&e.store.options.isInitialized),VZ=WI({idPrefix:`pisProductsInstance_`,instanceTag:`pis-products-instance`,getInstanceById:zZ,isReady:BZ,hasContent:e=>{var t;return!!((t=e.store.data.products)!=null&&(t=t.items)!=null&&t.length)||!!e.store.data.productDetail},subViewOf:e=>{var t;return(t=e.search)==null?void 0:t.subView},viewDataTypes:[$.Products],elements:[{kind:`instance`,name:`pis-products-instance`},{kind:`view`,name:`pis-products-search-router-view`,view:`search`},{kind:`view`,name:`pis-products-details-router-view`,view:`detail`},{kind:`view`,name:`pis-products-compare-router-view`,view:`compare`},{kind:`view`,name:`pis-products-search-table-router-view`,view:`search`,subView:`table`},{kind:`view`,name:`pis-products-search-list-router-view`,view:`search`,subView:`list`},{kind:`view`,name:`pis-products-search-grid-router-view`,view:`search`,subView:`grid`},{kind:`gate`,name:`pis-products-search-no-results-gate`,gate:e=>{var t;if(!BZ(e)||e.store.data.isLoadingData)return!1;let n=(t=e.store.data.products)==null?void 0:t.items;return!n||!n.length}},{kind:`loader`,name:`pis-products-loading-indicator`,spinnerZIndex:5,backdropZIndex:4,backdropOpacity:.5}]});function HZ(){Ff(new Lz),JI(RZ,VZ),Rf()}HZ(),YI(),_z()})();
97
+ //# sourceMappingURL=pis-csp.js.map