@sme.up/ketchup 6.2.0 → 6.3.0

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 (160) hide show
  1. package/dist/cjs/{f-button-5b69d882.js → f-button-94cb5f35.js} +2 -2
  2. package/dist/cjs/{f-cell-3a740c48.js → f-cell-76830a0d.js} +12 -14
  3. package/dist/cjs/{f-checkbox-57443ca3.js → f-checkbox-cd977193.js} +1 -1
  4. package/dist/cjs/{f-chip-02e83f82.js → f-chip-68d45fd3.js} +3 -3
  5. package/dist/cjs/{f-image-2a61ece2.js → f-image-0e71df7e.js} +2 -2
  6. package/dist/cjs/{f-paginator-utils-09126bdd.js → f-paginator-utils-46689c0a.js} +80 -403
  7. package/dist/cjs/{f-text-field-9ee20a67.js → f-text-field-b4229cef.js} +11 -3
  8. package/dist/cjs/{index-06b131ea.js → index-31125378.js} +9 -4
  9. package/dist/cjs/ketchup.cjs.js +3 -3
  10. package/dist/cjs/kup-accordion.cjs.entry.js +5 -6
  11. package/dist/cjs/kup-autocomplete_25.cjs.entry.js +116 -111
  12. package/dist/cjs/kup-box.cjs.entry.js +15 -17
  13. package/dist/cjs/kup-calendar.cjs.entry.js +9 -11
  14. package/dist/cjs/kup-cell.cjs.entry.js +9 -11
  15. package/dist/cjs/kup-dash-list.cjs.entry.js +5 -7
  16. package/dist/cjs/kup-dash_2.cjs.entry.js +4 -5
  17. package/dist/cjs/kup-dashboard.cjs.entry.js +76 -17
  18. package/dist/cjs/kup-drawer.cjs.entry.js +4 -5
  19. package/dist/cjs/kup-echart.cjs.entry.js +17 -19
  20. package/dist/cjs/kup-family-tree.cjs.entry.js +140 -64
  21. package/dist/cjs/kup-form.cjs.entry.js +10 -12
  22. package/dist/cjs/kup-iframe.cjs.entry.js +4 -5
  23. package/dist/cjs/kup-image-list.cjs.entry.js +10 -12
  24. package/dist/cjs/kup-lazy.cjs.entry.js +4 -5
  25. package/dist/cjs/kup-magic-box.cjs.entry.js +5 -6
  26. package/dist/cjs/{kup-manager-02acbb37.js → kup-manager-7c514a30.js} +1400 -369
  27. package/dist/cjs/kup-nav-bar.cjs.entry.js +4 -5
  28. package/dist/cjs/kup-numeric-picker.cjs.entry.js +3 -3
  29. package/dist/cjs/kup-photo-frame.cjs.entry.js +4 -5
  30. package/dist/cjs/kup-probe.cjs.entry.js +2 -2
  31. package/dist/cjs/kup-qlik.cjs.entry.js +2 -2
  32. package/dist/cjs/kup-snackbar.cjs.entry.js +6 -7
  33. package/dist/cjs/loader.cjs.js +3 -3
  34. package/dist/collection/assets/dashboard.js +48 -0
  35. package/dist/collection/assets/family-tree.js +236 -19
  36. package/dist/collection/assets/index.js +4 -0
  37. package/dist/collection/assets/kupinteract.js +68 -0
  38. package/dist/collection/collection-manifest.json +5 -5
  39. package/dist/collection/components/kup-dashboard/kup-dashboard.css +7 -0
  40. package/dist/collection/components/kup-dashboard/kup-dashboard.js +67 -7
  41. package/dist/collection/components/kup-data-table/kup-data-table-helper.js +42 -30
  42. package/dist/collection/components/kup-echart/kup-echart.js +9 -9
  43. package/dist/collection/components/kup-family-tree/kup-family-tree-declarations.js +3 -1
  44. package/dist/collection/components/kup-family-tree/kup-family-tree.css +79 -9
  45. package/dist/collection/components/kup-family-tree/kup-family-tree.js +253 -65
  46. package/dist/collection/components/kup-text-field/kup-text-field-declarations.js +1 -0
  47. package/dist/collection/components/kup-text-field/kup-text-field.js +27 -0
  48. package/dist/collection/f-components/f-text-field/f-text-field.js +9 -1
  49. package/dist/collection/managers/kup-data/kup-data-cell-helper.js +48 -15
  50. package/dist/collection/managers/kup-data/kup-data.js +5 -5
  51. package/dist/collection/managers/kup-interact/kup-interact.js +3 -5
  52. package/dist/collection/managers/kup-scroll-on-hover/kup-scroll-on-hover-declarations.js +2 -0
  53. package/dist/collection/managers/kup-scroll-on-hover/kup-scroll-on-hover.js +131 -45
  54. package/dist/collection/utils/filters/filters-rows.js +4 -23
  55. package/dist/collection/utils/filters/filters-tree-items.js +2 -1
  56. package/dist/esm/{f-button-fd44ef70.js → f-button-cd948e50.js} +2 -2
  57. package/dist/esm/{f-cell-7b159a22.js → f-cell-474dd282.js} +6 -8
  58. package/dist/esm/{f-checkbox-c51c4a75.js → f-checkbox-e06cf07b.js} +1 -1
  59. package/dist/esm/{f-chip-c2e4c522.js → f-chip-d6f2eb94.js} +3 -3
  60. package/dist/esm/{f-image-2ab4b9aa.js → f-image-914a03ef.js} +2 -2
  61. package/dist/esm/{f-paginator-utils-ef537d82.js → f-paginator-utils-a4a52732.js} +44 -366
  62. package/dist/esm/{f-text-field-41c575eb.js → f-text-field-76341fe3.js} +11 -3
  63. package/dist/esm/{index-ad6ab214.js → index-e41330a5.js} +9 -4
  64. package/dist/esm/ketchup.js +3 -3
  65. package/dist/esm/kup-accordion.entry.js +3 -4
  66. package/dist/esm/kup-autocomplete_25.entry.js +17 -12
  67. package/dist/esm/kup-box.entry.js +9 -11
  68. package/dist/esm/kup-calendar.entry.js +5 -7
  69. package/dist/esm/kup-cell.entry.js +7 -9
  70. package/dist/esm/kup-dash-list.entry.js +2 -4
  71. package/dist/esm/kup-dash_2.entry.js +2 -3
  72. package/dist/esm/kup-dashboard.entry.js +74 -15
  73. package/dist/esm/kup-drawer.entry.js +2 -3
  74. package/dist/esm/kup-echart.entry.js +11 -13
  75. package/dist/esm/kup-family-tree.entry.js +138 -62
  76. package/dist/esm/kup-form.entry.js +7 -9
  77. package/dist/esm/kup-iframe.entry.js +2 -3
  78. package/dist/esm/kup-image-list.entry.js +8 -10
  79. package/dist/esm/kup-lazy.entry.js +2 -3
  80. package/dist/esm/kup-magic-box.entry.js +3 -4
  81. package/dist/esm/{kup-manager-22a475e6.js → kup-manager-86f440c7.js} +1379 -370
  82. package/dist/esm/kup-nav-bar.entry.js +2 -3
  83. package/dist/esm/kup-numeric-picker.entry.js +3 -3
  84. package/dist/esm/kup-photo-frame.entry.js +2 -3
  85. package/dist/esm/kup-probe.entry.js +2 -2
  86. package/dist/esm/kup-qlik.entry.js +2 -2
  87. package/dist/esm/kup-snackbar.entry.js +4 -5
  88. package/dist/esm/loader.js +3 -3
  89. package/dist/ketchup/ketchup.esm.js +1 -1
  90. package/dist/ketchup/p-00e1133d.entry.js +9 -0
  91. package/dist/ketchup/p-066f344a.entry.js +1 -0
  92. package/dist/ketchup/p-0c6e0647.entry.js +1 -0
  93. package/dist/ketchup/p-151f7c17.entry.js +27 -0
  94. package/dist/ketchup/p-1e9c03b0.entry.js +1 -0
  95. package/dist/ketchup/{p-fc2b1229.js → p-21ea11cb.js} +3 -3
  96. package/dist/ketchup/{p-1959f835.entry.js → p-2f4e6c50.entry.js} +1 -1
  97. package/dist/ketchup/p-3586f59c.js +1 -0
  98. package/dist/ketchup/p-359fd90d.entry.js +1 -0
  99. package/dist/ketchup/{p-38d7584e.js → p-389fd0bf.js} +1 -1
  100. package/dist/ketchup/{p-cd5cfa7c.js → p-5552f156.js} +1 -1
  101. package/dist/ketchup/{p-264b1b19.entry.js → p-77aff9c1.entry.js} +1 -1
  102. package/dist/ketchup/{p-e9366aaf.entry.js → p-7cfdf53c.entry.js} +4 -4
  103. package/dist/ketchup/p-853a5178.entry.js +1 -0
  104. package/dist/ketchup/{p-edae3076.js → p-8673bd4e.js} +1 -1
  105. package/dist/ketchup/p-8b55b786.entry.js +1 -0
  106. package/dist/ketchup/p-95f5834b.entry.js +1 -0
  107. package/dist/ketchup/p-a2c595c4.js +1 -0
  108. package/dist/ketchup/p-ae91f27e.entry.js +1 -0
  109. package/dist/ketchup/{p-928c5c36.js → p-af664379.js} +1 -1
  110. package/dist/ketchup/p-b0b3989b.js +2 -0
  111. package/dist/ketchup/p-b3b65a61.entry.js +1 -0
  112. package/dist/ketchup/p-bc306a53.entry.js +1 -0
  113. package/dist/ketchup/{p-42080355.entry.js → p-c3783b77.entry.js} +1 -1
  114. package/dist/ketchup/{p-dc62a30f.js → p-cd4fc3fb.js} +1 -1
  115. package/dist/ketchup/p-cee76b14.entry.js +1 -0
  116. package/dist/ketchup/p-cfaea29b.entry.js +1 -0
  117. package/dist/ketchup/p-d2f51e7b.entry.js +1 -0
  118. package/dist/ketchup/p-df8e6a4d.entry.js +1 -0
  119. package/dist/ketchup/p-e60a1170.entry.js +1 -0
  120. package/dist/ketchup/p-e9a1ba04.entry.js +1 -0
  121. package/dist/types/components/kup-dashboard/kup-dashboard.d.ts +6 -1
  122. package/dist/types/components/kup-family-tree/kup-family-tree-declarations.d.ts +7 -3
  123. package/dist/types/components/kup-family-tree/kup-family-tree.d.ts +26 -5
  124. package/dist/types/components/kup-text-field/kup-text-field-declarations.d.ts +1 -0
  125. package/dist/types/components/kup-text-field/kup-text-field.d.ts +5 -0
  126. package/dist/types/components.d.ts +49 -7
  127. package/dist/types/f-components/f-text-field/f-text-field-declarations.d.ts +1 -0
  128. package/dist/types/managers/kup-data/kup-data-cell-helper.d.ts +13 -6
  129. package/dist/types/managers/kup-data/kup-data.d.ts +2 -1
  130. package/dist/types/managers/kup-scroll-on-hover/kup-scroll-on-hover-declarations.d.ts +9 -1
  131. package/dist/types/managers/kup-scroll-on-hover/kup-scroll-on-hover.d.ts +7 -5
  132. package/dist/types/utils/filters/filters-rows.d.ts +0 -2
  133. package/package.json +2 -2
  134. package/dist/cjs/cell-utils-fe64a28c.js +0 -168
  135. package/dist/cjs/utils-4b208b48.js +0 -447
  136. package/dist/esm/cell-utils-cb5d4149.js +0 -160
  137. package/dist/esm/utils-2c1f4122.js +0 -428
  138. package/dist/ketchup/p-06c6cc68.js +0 -1
  139. package/dist/ketchup/p-0dacd4bc.entry.js +0 -1
  140. package/dist/ketchup/p-1c44dc62.entry.js +0 -1
  141. package/dist/ketchup/p-4bc9f98b.entry.js +0 -1
  142. package/dist/ketchup/p-578583db.entry.js +0 -1
  143. package/dist/ketchup/p-5866d507.entry.js +0 -1
  144. package/dist/ketchup/p-61059e9d.entry.js +0 -9
  145. package/dist/ketchup/p-664be494.entry.js +0 -1
  146. package/dist/ketchup/p-67cd575d.entry.js +0 -1
  147. package/dist/ketchup/p-682a367a.js +0 -1
  148. package/dist/ketchup/p-6ccf7eb2.entry.js +0 -1
  149. package/dist/ketchup/p-7230ab97.entry.js +0 -1
  150. package/dist/ketchup/p-752b4cef.entry.js +0 -1
  151. package/dist/ketchup/p-7de3e7ac.entry.js +0 -1
  152. package/dist/ketchup/p-9b36497d.entry.js +0 -1
  153. package/dist/ketchup/p-b982d137.entry.js +0 -1
  154. package/dist/ketchup/p-c0219e5e.js +0 -1
  155. package/dist/ketchup/p-c55fd0a7.entry.js +0 -1
  156. package/dist/ketchup/p-d154b3a0.entry.js +0 -1
  157. package/dist/ketchup/p-d2affb6f.entry.js +0 -27
  158. package/dist/ketchup/p-d3b542b3.js +0 -2
  159. package/dist/ketchup/p-d6c12c6c.js +0 -1
  160. package/dist/ketchup/p-da0eab60.entry.js +0 -1
@@ -1,2 +0,0 @@
1
- let e,t,n=!1,l=!1;const s="undefined"!=typeof window?window:{},o=s.document||{head:{}},i={t:0,l:"",jmp:e=>e(),raf:e=>requestAnimationFrame(e),ael:(e,t,n,l)=>e.addEventListener(t,n,l),rel:(e,t,n,l)=>e.removeEventListener(t,n,l),ce:(e,t)=>new CustomEvent(e,t)},c=e=>Promise.resolve(e),r=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replace}catch(e){}return!1})(),a=(e,t,n)=>{n&&n.map((([n,l,s])=>{const o=f(e,n),c=u(t,s),r=p(n);i.ael(o,l,c,r),(t.o=t.o||[]).push((()=>i.rel(o,l,c,r)))}))},u=(e,t)=>n=>{try{256&e.t?e.i[t](n):(e.u=e.u||[]).push([t,n])}catch(e){le(e)}},f=(e,t)=>4&t?o:e,p=e=>0!=(2&e),d="http://www.w3.org/1999/xlink",h=new WeakMap,m=e=>"sc-"+e.p,y={},$=e=>"object"==(e=typeof e)||"function"===e,w=(e,t,...n)=>{let l=null,s=null,o=!1,i=!1;const c=[],r=t=>{for(let n=0;n<t.length;n++)l=t[n],Array.isArray(l)?r(l):null!=l&&"boolean"!=typeof l&&((o="function"!=typeof e&&!$(l))&&(l+=""),o&&i?c[c.length-1].h+=l:c.push(o?b(null,l):l),i=o)};if(r(n),t){t.key&&(s=t.key);{const e=t.className||t.class;e&&(t.class="object"!=typeof e?e:Object.keys(e).filter((t=>e[t])).join(" "))}}if("function"==typeof e)return e(null===t?{}:t,c,v);const a=b(e,null);return a.m=t,c.length>0&&(a.$=c),a.g=s,a},b=(e,t)=>({t:0,v:e,h:t,j:null,$:null,m:null,g:null}),g={},v={forEach:(e,t)=>e.map(j).forEach(t),map:(e,t)=>e.map(j).map(t).map(k)},j=e=>({vattrs:e.m,vchildren:e.$,vkey:e.g,vname:e.k,vtag:e.v,vtext:e.h}),k=e=>{if("function"==typeof e.vtag){const t=Object.assign({},e.vattrs);return e.vkey&&(t.key=e.vkey),e.vname&&(t.name=e.vname),w(e.vtag,t,...e.vchildren||[])}const t=b(e.vtag,e.vtext);return t.m=e.vattrs,t.$=e.vchildren,t.g=e.vkey,t.k=e.vname,t},S=(e,t,n,l,o,c)=>{if(n!==l){let r=ne(e,t),a=t.toLowerCase();if("class"===t){const t=e.classList,s=M(n),o=M(l);t.remove(...s.filter((e=>e&&!o.includes(e)))),t.add(...o.filter((e=>e&&!s.includes(e))))}else if("style"===t){for(const t in n)l&&null!=l[t]||(t.includes("-")?e.style.removeProperty(t):e.style[t]="");for(const t in l)n&&l[t]===n[t]||(t.includes("-")?e.style.setProperty(t,l[t]):e.style[t]=l[t])}else if("key"===t);else if("ref"===t)l&&l(e);else if(r||"o"!==t[0]||"n"!==t[1]){const s=$(l);if((r||s&&null!==l)&&!o)try{if(e.tagName.includes("-"))e[t]=l;else{const s=null==l?"":l;"list"===t?r=!1:null!=n&&e[t]==s||(e[t]=s)}}catch(e){}let i=!1;a!==(a=a.replace(/^xlink\:?/,""))&&(t=a,i=!0),null==l||!1===l?!1===l&&""!==e.getAttribute(t)||(i?e.removeAttributeNS(d,t):e.removeAttribute(t)):(!r||4&c||o)&&!s&&(l=!0===l?"":l,i?e.setAttributeNS(d,t,l):e.setAttribute(t,l))}else t="-"===t[2]?t.slice(3):ne(s,a)?a.slice(2):a[2]+t.slice(3),n&&i.rel(e,t,n,!1),l&&i.ael(e,t,l,!1)}},O=/\s/,M=e=>e?e.split(O):[],x=(e,t,n,l)=>{const s=11===t.j.nodeType&&t.j.host?t.j.host:t.j,o=e&&e.m||y,i=t.m||y;for(l in o)l in i||S(s,l,o[l],void 0,n,t.t);for(l in i)S(s,l,o[l],i[l],n,t.t)},C=(t,l,s)=>{const i=l.$[s];let c,r,a=0;if(null!==i.h)c=i.j=o.createTextNode(i.h);else{if(n||(n="svg"===i.v),c=i.j=o.createElementNS(n?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",i.v),n&&"foreignObject"===i.v&&(n=!1),x(null,i,n),null!=e&&c["s-si"]!==e&&c.classList.add(c["s-si"]=e),i.$)for(a=0;a<i.$.length;++a)r=C(t,i,a),r&&c.appendChild(r);"svg"===i.v?n=!1:"foreignObject"===c.tagName&&(n=!0)}return c},L=(e,n,l,s,o,i)=>{let c,r=e;for(r.shadowRoot&&r.tagName===t&&(r=r.shadowRoot);o<=i;++o)s[o]&&(c=C(null,l,o),c&&(s[o].j=c,r.insertBefore(c,n)))},P=(e,t,n,l,s)=>{for(;t<=n;++t)(l=e[t])&&(s=l.j,W(l),s.remove())},R=(e,t)=>e.v===t.v&&e.g===t.g,U=(e,t)=>{const l=t.j=e.j,s=e.$,o=t.$,i=t.v,c=t.h;null===c?(n="svg"===i||"foreignObject"!==i&&n,"slot"===i||x(e,t,n),null!==s&&null!==o?((e,t,n,l)=>{let s,o,i=0,c=0,r=0,a=0,u=t.length-1,f=t[0],p=t[u],d=l.length-1,h=l[0],m=l[d];for(;i<=u&&c<=d;)if(null==f)f=t[++i];else if(null==p)p=t[--u];else if(null==h)h=l[++c];else if(null==m)m=l[--d];else if(R(f,h))U(f,h),f=t[++i],h=l[++c];else if(R(p,m))U(p,m),p=t[--u],m=l[--d];else if(R(f,m))U(f,m),e.insertBefore(f.j,p.j.nextSibling),f=t[++i],m=l[--d];else if(R(p,h))U(p,h),e.insertBefore(p.j,f.j),p=t[--u],h=l[++c];else{for(r=-1,a=i;a<=u;++a)if(t[a]&&null!==t[a].g&&t[a].g===h.g){r=a;break}r>=0?(o=t[r],o.v!==h.v?s=C(t&&t[c],n,r):(U(o,h),t[r]=void 0,s=o.j),h=l[++c]):(s=C(t&&t[c],n,c),h=l[++c]),s&&f.j.parentNode.insertBefore(s,f.j)}i>u?L(e,null==l[d+1]?null:l[d+1].j,n,l,c,d):c>d&&P(t,i,u)})(l,s,t,o):null!==o?(null!==e.h&&(l.textContent=""),L(l,null,t,o,0,o.length-1)):null!==s&&P(s,0,s.length-1),n&&"svg"===i&&(n=!1)):e.h!==c&&(l.data=c)},W=e=>{e.m&&e.m.ref&&e.m.ref(null),e.$&&e.$.map(W)},E=e=>Z(e).S,D=(e,t,n)=>{const l=E(e);return{emit:e=>N(l,t,{bubbles:!!(4&n),composed:!!(2&n),cancelable:!!(1&n),detail:e})}},N=(e,t,n)=>{const l=i.ce(t,n);return e.dispatchEvent(l),l},T=(e,t)=>{t&&!e.O&&t["s-p"]&&t["s-p"].push(new Promise((t=>e.O=t)))},A=(e,t)=>{if(e.t|=16,!(4&e.t))return T(e,e.M),de((()=>F(e,t)));e.t|=512},F=(e,t)=>{const n=e.i;let l;return t?(e.t|=256,e.u&&(e.u.map((([e,t])=>B(n,e,t))),e.u=null),l=B(n,"componentWillLoad")):l=B(n,"componentWillUpdate"),l=G(l,(()=>B(n,"componentWillRender"))),G(l,(()=>H(e,n,t)))},H=async(e,t,n)=>{const l=e.S,s=l["s-rc"];n&&(e=>{const t=e.C,n=e.S,l=t.t,s=((e,t)=>{let n=m(t);const l=ie.get(n);if(e=11===e.nodeType?e:o,l)if("string"==typeof l){let t,s=h.get(e=e.head||e);s||h.set(e,s=new Set),s.has(n)||(t=o.createElement("style"),t.innerHTML=l,e.insertBefore(t,e.querySelector("link")),s&&s.add(n))}else e.adoptedStyleSheets.includes(l)||(e.adoptedStyleSheets=[...e.adoptedStyleSheets,l]);return n})(n.shadowRoot?n.shadowRoot:n.getRootNode(),t);10&l&&(n["s-sc"]=s,n.classList.add(s+"-h"))})(e);q(e,t),s&&(s.map((e=>e())),l["s-rc"]=void 0);{const t=l["s-p"],n=()=>V(e);0===t.length?n():(Promise.all(t).then(n),e.t|=4,t.length=0)}},q=(n,l)=>{try{l=l.render(),n.t&=-17,n.t|=2,((n,l)=>{const s=n.S,o=n.C,i=n.L||b(null,null),c=(e=>e&&e.v===g)(l)?l:w(null,null,l);t=s.tagName,o.P&&(c.m=c.m||{},o.P.map((([e,t])=>c.m[t]=s[e]))),c.v=null,c.t|=4,n.L=c,c.j=i.j=s.shadowRoot||s,e=s["s-sc"],U(i,c)})(n,l)}catch(e){le(e,n.S)}return null},V=e=>{const t=e.S,n=e.i,l=e.M;B(n,"componentDidRender"),64&e.t?B(n,"componentDidUpdate"):(e.t|=64,I(t),B(n,"componentDidLoad"),e.R(t),l||z()),e.U(t),e.O&&(e.O(),e.O=void 0),512&e.t&&pe((()=>A(e,!1))),e.t&=-517},_=e=>{{const t=Z(e),n=t.S.isConnected;return n&&2==(18&t.t)&&A(t,!1),n}},z=()=>{I(o.documentElement),pe((()=>N(s,"appload",{detail:{namespace:"ketchup"}})))},B=(e,t,n)=>{if(e&&e[t])try{return e[t](n)}catch(e){le(e)}},G=(e,t)=>e&&e.then?e.then(t):t(),I=e=>e.classList.add("hydrated"),J=(e,t,n)=>{if(t.W){e.watchers&&(t.D=e.watchers);const l=Object.entries(t.W),s=e.prototype;if(l.map((([e,[l]])=>{31&l||2&n&&32&l?Object.defineProperty(s,e,{get(){return((e,t)=>Z(this).N.get(t))(0,e)},set(n){((e,t,n,l)=>{const s=Z(e),o=s.S,i=s.N.get(t),c=s.t,r=s.i;if(n=((e,t)=>null==e||$(e)?e:4&t?"false"!==e&&(""===e||!!e):2&t?parseFloat(e):1&t?e+"":e)(n,l.W[t][0]),(!(8&c)||void 0===i)&&n!==i&&(!Number.isNaN(i)||!Number.isNaN(n))&&(s.N.set(t,n),r)){if(l.D&&128&c){const e=l.D[t];e&&e.map((e=>{try{r[e](n,i,t)}catch(e){le(e,o)}}))}2==(18&c)&&A(s,!1)}})(this,e,n,t)},configurable:!0,enumerable:!0}):1&n&&64&l&&Object.defineProperty(s,e,{value(...t){const n=Z(this);return n.T.then((()=>n.i[e](...t)))}})})),1&n){const n=new Map;s.attributeChangedCallback=function(e,t,l){i.jmp((()=>{const t=n.get(e);if(this.hasOwnProperty(t))l=this[t],delete this[t];else if(s.hasOwnProperty(t)&&"number"==typeof this[t]&&this[t]==l)return;this[t]=(null!==l||"boolean"!=typeof this[t])&&l}))},e.observedAttributes=l.filter((([e,t])=>15&t[0])).map((([e,l])=>{const s=l[1]||e;return n.set(s,e),512&l[0]&&t.P.push([e,s]),s}))}}return e},K=(e,t={})=>{const n=[],l=t.exclude||[],c=s.customElements,u=o.head,f=u.querySelector("meta[charset]"),p=o.createElement("style"),d=[];let h,y=!0;Object.assign(i,t),i.l=new URL(t.resourcesUrl||"./",o.baseURI).href,e.map((e=>{e[1].map((t=>{const s={t:t[0],p:t[1],W:t[2],A:t[3]};s.W=t[2],s.A=t[3],s.P=[],s.D={};const o=s.p,u=class extends HTMLElement{constructor(e){super(e),te(e=this,s),1&s.t&&e.attachShadow({mode:"open"})}connectedCallback(){h&&(clearTimeout(h),h=null),y?d.push(this):i.jmp((()=>(e=>{if(0==(1&i.t)){const t=Z(e),n=t.C,l=()=>{};if(1&t.t)a(e,t,n.A);else{t.t|=1;{let n=e;for(;n=n.parentNode||n.host;)if(n["s-p"]){T(t,t.M=n);break}}n.W&&Object.entries(n.W).map((([t,[n]])=>{if(31&n&&e.hasOwnProperty(t)){const n=e[t];delete e[t],e[t]=n}})),(async(e,t,n,l,s)=>{if(0==(32&t.t)){{if(t.t|=32,(s=oe(n)).then){const e=()=>{};s=await s,e()}s.isProxied||(n.D=s.watchers,J(s,n,2),s.isProxied=!0);const e=()=>{};t.t|=8;try{new s(t)}catch(e){le(e)}t.t&=-9,t.t|=128,e()}if(s.style){let e=s.style;const t=m(n);if(!ie.has(t)){const l=()=>{};((e,t,n)=>{let l=ie.get(e);r&&n?(l=l||new CSSStyleSheet,l.replace(t)):l=t,ie.set(e,l)})(t,e,!!(1&n.t)),l()}}}const o=t.M,i=()=>A(t,!0);o&&o["s-rc"]?o["s-rc"].push(i):i()})(0,t,n)}l()}})(this)))}disconnectedCallback(){i.jmp((()=>(()=>{if(0==(1&i.t)){const e=Z(this),t=e.i;e.o&&(e.o.map((e=>e())),e.o=void 0),B(t,"disconnectedCallback")}})()))}componentOnReady(){return Z(this).F}};s.H=e[0],l.includes(o)||c.get(o)||(n.push(o),c.define(o,J(u,s,1)))}))})),p.innerHTML=n+"{visibility:hidden}.hydrated{visibility:inherit}",p.setAttribute("data-styles",""),u.insertBefore(p,f?f.nextSibling:u.firstChild),y=!1,d.length?d.map((e=>e.connectedCallback())):i.jmp((()=>h=setTimeout(z,30)))},Q=e=>{const t=new URL(e,i.l);return t.origin!==s.location.origin?t.href:t.pathname},X=e=>i.l=e,Y=new WeakMap,Z=e=>Y.get(e),ee=(e,t)=>Y.set(t.i=e,t),te=(e,t)=>{const n={t:0,S:e,C:t,N:new Map};return n.T=new Promise((e=>n.U=e)),n.F=new Promise((e=>n.R=e)),e["s-p"]=[],e["s-rc"]=[],a(e,n,t.A),Y.set(e,n)},ne=(e,t)=>t in e,le=(e,t)=>(0,console.error)(e,t),se=new Map,oe=e=>{const t=e.p.replace(/-/g,"_"),n=e.H,l=se.get(n);return l?l[t]:import(`./${n}.entry.js`).then((e=>(se.set(n,e),e[t])),le)
2
- /*!__STENCIL_STATIC_IMPORT_SWITCH__*/},ie=new Map,ce=[],re=[],ae=(e,t)=>n=>{e.push(n),l||(l=!0,t&&4&i.t?pe(fe):i.raf(fe))},ue=e=>{for(let t=0;t<e.length;t++)try{e[t](performance.now())}catch(e){le(e)}e.length=0},fe=()=>{ue(ce),ue(re),(l=ce.length>0)&&i.raf(fe)},pe=e=>c().then(e),de=ae(re,!0);export{g as H,Q as a,K as b,D as c,_ as f,E as g,w as h,c as p,ee as r,X as s}
@@ -1 +0,0 @@
1
- import{u as n,d as l,e as u,h as t}from"./p-682a367a.js";import{d as r}from"./p-fc2b1229.js";const e=document.documentElement;function f(n,l){if(null!=l&&null!=l.displayedValue)return l.displayedValue;let u=s(l.value,n,l);return null!=l&&(l.displayedValue=u),u}function i(n,l){return null==n?"":(null!=n.displayedValue&&""!=n.displayedValue.trim()||(n.displayedValue=s(n.value,l,null)),n.displayedValue)}function o(n){return e.ketchup.math.numberify(n.obj?n.obj.k:n.value)}function s(n,l,u){let t=null!=l?l.obj:null;return null!=u&&(t=u.obj?u.obj:t),a(n,t,null!=l?l.decimals:null)}function a(t,f,i){return null==t||""==t.trim()?t:e.ketchup.objects.isNumber(f)?n(t,i||-1,f?f.p:""):e.ketchup.objects.isDate(f)&&e.ketchup.dates.isValid(t,r.ISO_DATE)?e.ketchup.dates.format(t):e.ketchup.objects.isTime(f)?l(t,e.ketchup.objects.isTimeWithSeconds(f),f.t+f.p):e.ketchup.objects.isTimestamp(f)?u(t):t}function c(n,l){if(null==n)return null;for(let u of n)if(u.name===l)return u;return null}function m(n,l,u){return p(n.obj,n.value,l.obj,l.value,u)}function p(n,l,u,f,i){const o="A"===i?1:-1;if(null==n||null==u)return o*d(l,f);if(n.t!==u.t||n.p!==u.p){let l=d(n.t,u.t);return 0===l&&(l=d(n.p,u.p)),l*o}let s=l,a=f;if(s==a)return 0;if(""==s)return-1*o;if(""==a)return 1*o;let c=s,m=a;if(e.ketchup.objects.isNumber(n))c=t(s),m=t(a);else if(e.ketchup.objects.isDate(n))c=e.ketchup.dates.toDate(e.ketchup.dates.format(s,r.ISO_DATE)),m=e.ketchup.dates.toDate(e.ketchup.dates.format(a,r.ISO_DATE));else if(e.ketchup.objects.isTime(n)){let l=e.ketchup.objects.isTimeWithSeconds(n);c=e.ketchup.dates.toDate(e.ketchup.dates.format(s,l?r.ISO_TIME:r.ISO_TIME_WITHOUT_SECONDS)),m=e.ketchup.dates.toDate(e.ketchup.dates.format(a,l?r.ISO_TIME:r.ISO_TIME_WITHOUT_SECONDS))}else e.ketchup.objects.isTimestamp(n)&&(c=e.ketchup.dates.toDate(e.ketchup.dates.format(s,r.ISO_DATE_TIME)),m=e.ketchup.dates.toDate(e.ketchup.dates.format(a,r.ISO_DATE_TIME)));return c>m?1*o:c<m?-1*o:0}function d(n,l){let u=null==n?0:n.length,t=null==l?0:l.length;const r=Math.min(u,t);let e=0;for(;e<r;){const u=n[e],t=l[e];if(u!==t)return u.charCodeAt(0)-t.charCodeAt(0);e++}return u-t}export{i as a,a as b,f as c,p as d,m as e,o as f,c as g}
@@ -1 +0,0 @@
1
- import{r as t,f as i,h as s,H as e,g as o}from"./p-d3b542b3.js";import{k as a,h as c,c as n,a7 as r,z as h,a8 as l,D as u,b as p}from"./p-fc2b1229.js";import{F as d}from"./p-6c77a36c.js";import{F as b}from"./p-38d7584e.js";import{g as m,s as k}from"./p-682a367a.js";import{c as g}from"./p-97e8ea42.js";var f,x;!function(t){t.customStyle="Custom style of the component.",t.data="Sets the data that will be used to display different components."}(f||(f={})),function(t){t.BOX="Box",t.BUTTON_LIST="Button List",t.CHART="Chart",t.CHIP="Chip",t.ECHART="Echart",t.DATATABLE="Datatable",t.JSON="JSON",t.TREE="Tree"}(x||(x={}));const y=class{constructor(i){t(this,i),this.display=x.DATATABLE,this.customStyle="",this.data=null,this.dragHandler=null,this.kupManager=a(),this.textArea=null,this.wrapperRef=null}async getProps(t){return m(this,f,t)}async refresh(){i(this)}async setProps(t){k(this,f,t)}comboboxProps(){const t=[];for(const i in x)Object.prototype.hasOwnProperty.call(x,i)&&t.push({id:x[i],selected:!1,value:x[i]});return{data:{"kup-list":{data:t,id:"kup-debug-theme-changer-list"},"kup-text-field":{emitSubmitEventOnEnter:!1,inputType:"text",label:this.kupManager.language.translate(c.VIEW_AS)}},id:"comp-switcher",initialValue:this.display,isSelect:!0,"onKup-combobox-itemclick":t=>{this.display=t.detail.value}}}setContent(){const t=!!(this.data&&this.data.columns&&this.data.columns.length>0),i=[],e={};if(this.display===x.JSON)e.initialValue=this.data?JSON.stringify(this.data,null,2):"",e.textArea=!0,i.push(s("kup-text-field",Object.assign({class:"kup-full-width kup-full-height"},e,{ref:t=>this.textArea=t,"onkup-textfield-input":t=>{try{this.data=JSON.parse(t.detail.value)}catch(t){this.data={columns:[{name:"ERROR",title:"Error"}],rows:[{cells:{ERROR:{value:"Invalid JSON:"+t}}}]}}}})));else if(t)switch(this.display){case x.BOX:e.data=this.data,i.push(s("kup-box",Object.assign({},e)));break;case x.BUTTON_LIST:e.data=this.data,i.push(s("kup-button-list",Object.assign({},e)));break;case x.CHIP:e.data=this.data,i.push(s("kup-chip",Object.assign({},e)));break;case x.CHART:case x.ECHART:e.data=this.data,e.series=[],e.axis=null;for(let t=0;t<this.data.columns.length;t++){const i=this.data.columns[t];i.obj&&this.kupManager.objects.isNumber(i.obj)||null!==e.axis?e.series.push(this.display===x.CHART?{code:i.name,decode:i.title}:i.name):e.axis=i.name}0===e.series.length&&this.kupManager.debug.logMessage(this,"Not enough numerical columns to display a chart!",n.WARNING),e.axis||this.kupManager.debug.logMessage(this,"No axis for the chart!",n.WARNING),i.push(s(this.display===x.CHART?"kup-chart":"kup-echart",Object.assign({},e)));break;case x.DATATABLE:e.data=this.data,e.autoFillMissingCells=!0,i.push(s("kup-data-table",Object.assign({},e)));break;case x.TREE:e.data=this.data,i.push(s("kup-tree",Object.assign({class:"kup-full-width"},e)));break;default:return void this.kupManager.debug.logMessage(this,"Display mode not supported ("+this.display+")!",n.ERROR)}else i.push(s("div",{class:"empty"},s(b,{sizeY:"100px",resource:"move_to_inbox"}),s("div",{class:"empty-text"},this.kupManager.language.translate(c.DROP_YOUR_DATA))));return i}updateData(t){{const i=Object.assign({},this.data),s=t.detail.sourceElement&&t.detail.sourceElement.column?t.detail.sourceElement.column:null,e=t.detail.sourceElement&&t.detail.sourceElement.row?t.detail.sourceElement.row:null;if(s&&s.name?i.columns?this.data.columns.find((t=>t.name===s.name))||i.columns.push(s):i.columns=[s]:this.kupManager.debug.logMessage(this,"Invalid column received.",n.WARNING),e&&(i.rows?i.rows.push(e):i.rows=[e]),this.data=i,this.data&&this.textArea)try{this.textArea.setValue(JSON.stringify(this.data,null,2))}catch(t){this.textArea.setValue("Invalid JSON:"+t)}}}componentWillLoad(){this.kupManager.debug.logLoad(this,!1),this.kupManager.language.register(this),this.kupManager.theme.register(this)}componentDidLoad(){this.rootElement.addEventListener(r,(t=>this.updateData(t))),this.dragHandler=this.rootElement.shadowRoot.querySelector("#drag-handle"),this.kupManager.interact.dialogify(this.rootElement,this.dragHandler),this.kupManager.interact.dropzone(this.wrapperRef,{accept:`[${h}],[${l}]`},{dispatcher:this.rootElement,type:u.MAGICBOX}),this.kupManager.debug.logLoad(this,!0)}componentWillRender(){this.kupManager.debug.logRender(this,!1)}componentDidRender(){this.kupManager.debug.logRender(this,!0)}render(){return s(e,null,s("style",null,this.kupManager.theme.setKupStyle(this.rootElement)),s("div",{id:g},s("div",{class:"magic-box-wrapper"},s("div",{class:"actions",id:"drag-handle"},s("kup-combobox",Object.assign({},this.comboboxProps())),s("kup-button",{styling:d.FLAT,icon:"delete",label:"Reset","onkup-button-click":()=>{this.data=null}}),s("kup-button",{id:"close-dialog",customStyle:`:host{${p.PRIMARY}: var(${p.TITLE});}`,icon:"clear","onkup-button-click":()=>{this.kupManager.hideMagicBox()}})),s("div",{class:"content",ref:t=>this.wrapperRef=t},this.setContent()))))}disconnectedCallback(){this.kupManager.interact.unregister([this.rootElement,this.wrapperRef]),this.kupManager.language.unregister(this),this.kupManager.theme.unregister(this)}get rootElement(){return o(this)}};y.style=":host{background-color:var(--kup-background-color);color:var(--kup-text-color);display:block;height:300px;min-width:700px;width:700px}#kup-component,.magic-box-wrapper{height:100%;width:100%}.magic-box-wrapper{border:3px dashed var(--kup-border-color);box-sizing:border-box;display:flex;flex-direction:column}.actions{align-items:center;background-color:var(--kup-title-background-color);display:inline-flex;height:52px;justify-content:center;left:0;position:absolute;top:0;width:100%;z-index:1}.actions kup-button{margin:0.5em}.actions #comp-switcher{margin:auto 0}.actions #close-dialog{position:absolute;margin:0;top:0;right:0;background-color:var(--kup-title-background-color)}.content{box-sizing:border-box;height:100%;margin-top:52px;overflow:auto;transition:background-color 125ms ease}.empty{flex-direction:column;display:flex;text-align:center;justify-content:center;height:100%;width:100%;opacity:0.5;transition:opacity 0.25s ease-out}.empty .f-image{margin:0}.json{font-family:var(--kup-font-family-monospace);margin:0}[kup-drag-over]{background-color:rgba(var(--kup-success-color-rgb), 0.25)}";export{y as kup_magic_box}