@enablerr-ui/report 0.2.33 → 0.2.35

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.
package/dist/index.min.js CHANGED
@@ -1 +1 @@
1
- System.register(["@enablerr-ui/layout","@enablerr-ui/form"],(function(t){"use strict";var e,n,o;return{setters:[function(t){e=t.getAttractions},function(t){n=t.attachment_notification,o=t.Request}],execute:function(){t("version","0.2.33");function r(){}function l(t){return t()}function s(){return Object.create(null)}function i(t){t.forEach(l)}function c(t){return"function"==typeof t}function d(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function u(t,e){t.appendChild(e)}function a(t,e,n){t.insertBefore(e,n||null)}function f(t){t.parentNode.removeChild(t)}function p(t){return document.createElement(t)}function m(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function h(t){return document.createTextNode(t)}function $(){return h(" ")}function g(){return h("")}function v(t,e,n,o){return t.addEventListener(e,n,o),()=>t.removeEventListener(e,n,o)}function b(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function y(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function k(t,e,n,o){t.style.setProperty(e,n,o?"important":"")}let j;function w(t){j=t}function x(){if(!j)throw new Error("Function called outside component initialization");return j}const z=[],q=[],_=[],E=[],O=Promise.resolve();let P=!1;function B(t){_.push(t)}let D=!1;const C=new Set;function M(){if(!D){D=!0;do{for(let t=0;t<z.length;t+=1){const e=z[t];w(e),S(e.$$)}for(w(null),z.length=0;q.length;)q.pop()();for(let t=0;t<_.length;t+=1){const e=_[t];C.has(e)||(C.add(e),e())}_.length=0}while(z.length);for(;E.length;)E.pop()();P=!1,D=!1,C.clear()}}function S(t){if(null!==t.fragment){t.update(),i(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(B)}}const I=new Set;let N;function A(){N={r:0,c:[],p:N}}function G(){N.r||i(N.c),N=N.p}function T(t,e){t&&t.i&&(I.delete(t),t.i(e))}function W(t,e,n,o){if(t&&t.o){if(I.has(t))return;I.add(t),N&&N.c.push((()=>{I.delete(t),o&&(n&&t.d(1),o())})),t.o(e)}}function F(t,e){const n=e.token={};function o(t,o,r,l){if(e.token!==n)return;e.resolved=l;let s=e.ctx;void 0!==r&&(s=s.slice(),s[r]=l);const i=t&&(e.current=t)(s);let c=!1;e.block&&(e.blocks?e.blocks.forEach(((t,n)=>{n!==o&&t&&(A(),W(t,1,1,(()=>{e.blocks[n]===t&&(e.blocks[n]=null)})),G())})):e.block.d(1),i.c(),T(i,1),i.m(e.mount(),e.anchor),c=!0),e.block=i,e.blocks&&(e.blocks[o]=i),c&&M()}if((r=t)&&"object"==typeof r&&"function"==typeof r.then){const n=x();if(t.then((t=>{w(n),o(e.then,1,e.value,t),w(null)}),(t=>{if(w(n),o(e.catch,2,e.error,t),w(null),!e.hasCatch)throw t})),e.current!==e.pending)return o(e.pending,0),!0}else{if(e.current!==e.then)return o(e.then,1,e.value,t),!0;e.resolved=t}var r}const H="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:global;function R(t){t&&t.c()}function L(t,e,n,o){const{fragment:r,on_mount:s,on_destroy:d,after_update:u}=t.$$;r&&r.m(e,n),o||B((()=>{const e=s.map(l).filter(c);d?d.push(...e):i(e),t.$$.on_mount=[]})),u.forEach(B)}function U(t,e){const n=t.$$;null!==n.fragment&&(i(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function K(t,e){-1===t.$$.dirty[0]&&(z.push(t),P||(P=!0,O.then(M)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}function V(t,e,n,o,l,c,d=[-1]){const u=j;w(t);const a=t.$$={fragment:null,ctx:null,props:c,update:r,not_equal:l,bound:s(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(u?u.$$.context:e.context||[]),callbacks:s(),dirty:d,skip_bound:!1};let p=!1;if(a.ctx=n?n(t,e.props||{},((e,n,...o)=>{const r=o.length?o[0]:n;return a.ctx&&l(a.ctx[e],a.ctx[e]=r)&&(!a.skip_bound&&a.bound[e]&&a.bound[e](r),p&&K(t,e)),n})):[],a.update(),p=!0,i(a.before_update),a.fragment=!!o&&o(a.ctx),e.target){if(e.hydrate){const t=function(t){return Array.from(t.childNodes)}(e.target);a.fragment&&a.fragment.l(t),t.forEach(f)}else a.fragment&&a.fragment.c();e.intro&&T(t.$$.fragment),L(t,e.target,e.anchor,e.customElement),M()}w(u)}class J{$destroy(){U(this,1),this.$destroy=r}$on(t,e){const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){var e;this.$$set&&(e=t,0!==Object.keys(e).length)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}function Q(t){let e,n,o,l,s;return{c(){e=m("svg"),n=m("path"),o=m("polyline"),l=m("line"),b(n,"d","M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"),b(o,"points","7 10 12 15 17 10"),b(l,"x1","12"),b(l,"y1","15"),b(l,"x2","12"),b(l,"y2","3"),b(e,"xmlns","http://www.w3.org/2000/svg"),b(e,"width",t[0]),b(e,"height",t[0]),b(e,"fill","none"),b(e,"viewBox","0 0 24 24"),b(e,"stroke","currentColor"),b(e,"stroke-width",t[1]),b(e,"stroke-linecap","round"),b(e,"stroke-linejoin","round"),b(e,"class",s="feather feather-download "+t[2])},m(t,r){a(t,e,r),u(e,n),u(e,o),u(e,l)},p(t,[n]){1&n&&b(e,"width",t[0]),1&n&&b(e,"height",t[0]),2&n&&b(e,"stroke-width",t[1]),4&n&&s!==(s="feather feather-download "+t[2])&&b(e,"class",s)},i:r,o:r,d(t){t&&f(e)}}}function X(t,e,n){let{size:o="100%"}=e,{strokeWidth:r=2}=e,{class:l=""}=e;return"100%"!==o&&(o="x"===o.slice(-1)?o.slice(0,o.length-1)+"em":parseInt(o)+"px"),t.$$set=t=>{"size"in t&&n(0,o=t.size),"strokeWidth"in t&&n(1,r=t.strokeWidth),"class"in t&&n(2,l=t.class)},[o,r,l]}class Y extends J{constructor(t){super(),V(this,t,X,Q,d,{size:0,strokeWidth:1,class:2})}}function Z(t){let e,n,o,l;return{c(){e=m("svg"),n=m("polyline"),o=m("path"),b(n,"points","3 6 5 6 21 6"),b(o,"d","M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"),b(e,"xmlns","http://www.w3.org/2000/svg"),b(e,"width",t[0]),b(e,"height",t[0]),b(e,"fill","none"),b(e,"viewBox","0 0 24 24"),b(e,"stroke","currentColor"),b(e,"stroke-width",t[1]),b(e,"stroke-linecap","round"),b(e,"stroke-linejoin","round"),b(e,"class",l="feather feather-trash "+t[2])},m(t,r){a(t,e,r),u(e,n),u(e,o)},p(t,[n]){1&n&&b(e,"width",t[0]),1&n&&b(e,"height",t[0]),2&n&&b(e,"stroke-width",t[1]),4&n&&l!==(l="feather feather-trash "+t[2])&&b(e,"class",l)},i:r,o:r,d(t){t&&f(e)}}}function tt(t,e,n){let{size:o="100%"}=e,{strokeWidth:r=2}=e,{class:l=""}=e;return"100%"!==o&&(o="x"===o.slice(-1)?o.slice(0,o.length-1)+"em":parseInt(o)+"px"),t.$$set=t=>{"size"in t&&n(0,o=t.size),"strokeWidth"in t&&n(1,r=t.strokeWidth),"class"in t&&n(2,l=t.class)},[o,r,l]}class et extends J{constructor(t){super(),V(this,t,tt,Z,d,{size:0,strokeWidth:1,class:2})}}const{document:nt}=H;function ot(t,e,n){const o=t.slice();return o[22]=e[n],o[24]=n,o}function rt(t){let e;return{c(){e=p("div"),e.textContent="Dokument ersetzen"},m(t,n){a(t,e,n)},d(t){t&&f(e)}}}function lt(t){let e;return{c(){e=p("div"),e.textContent="Dokument wählen"},m(t,n){a(t,e,n)},d(t){t&&f(e)}}}function st(t){let e;function n(t,e){return t[0]?rt:lt}let o=n(t),r=o(t);return{c(){r.c(),e=g()},m(t,n){r.m(t,n),a(t,e,n)},p(t,l){o!==(o=n(t))&&(r.d(1),r=o(t),r&&(r.c(),r.m(e.parentNode,e)))},d(t){r.d(t),t&&f(e)}}}function it(t){let e,n,o,r,l,s,i,c,d,m,g,k,j,w,x,z;function _(e){t[16](e)}let O={placeholder:t[6],type:"text",id:"fileTitle",required:!0};return void 0!==t[3]&&(O.value=t[3]),m=new t[8]({props:O}),q.push((()=>function(t,e,n){const o=t.$$.props[e];void 0!==o&&(t.$$.bound[o]=n,n(t.$$.ctx[o]))}(m,"value",_))),j=new t[7]({props:{filled:!0,style:"color: whitesmoke;",type:"submit",$$slots:{default:[ct]},$$scope:{ctx:t}}}),{c(){e=p("div"),n=p("form"),o=p("div"),r=p("div"),l=h(t[4]),s=$(),i=p("div"),c=h(t[5]),d=$(),R(m.$$.fragment),k=$(),R(j.$$.fragment),b(r,"class","word-break svelte-1ldjqdz"),b(o,"class","container-file svelte-1ldjqdz"),b(n,"id","submitForm"),b(e,"class","form-step svelte-1ldjqdz")},m(f,p){var h;a(f,e,p),u(e,n),u(n,o),u(o,r),u(r,l),u(o,s),u(o,i),u(i,c),u(o,d),L(m,o,null),u(o,k),L(j,o,null),w=!0,x||(z=v(n,"submit",(h=t[9],function(t){return t.preventDefault(),h.call(this,t)})),x=!0)},p(t,e){(!w||16&e)&&y(l,t[4]),(!w||32&e)&&y(c,t[5]);const n={};var o;64&e&&(n.placeholder=t[6]),!g&&8&e&&(g=!0,n.value=t[3],o=()=>g=!1,E.push(o)),m.$set(n);const r={};33554432&e&&(r.$$scope={dirty:e,ctx:t}),j.$set(r)},i(t){w||(T(m.$$.fragment,t),T(j.$$.fragment,t),w=!0)},o(t){W(m.$$.fragment,t),W(j.$$.fragment,t),w=!1},d(t){t&&f(e),U(m),U(j),x=!1,z()}}}function ct(t){let e;return{c(){e=h("Dokument hochladen")},m(t,n){a(t,e,n)},d(t){t&&f(e)}}}function dt(t){return{c:r,m:r,p:r,i:r,o:r,d:r}}function ut(t){let e,n,o,r,l,s,i,c;const d=[ft,at],m=[];function h(t,e){return 0===t[21].length?0:1}return s=h(t),i=m[s]=d[s](t),{c(){e=p("div"),n=p("table"),o=p("thead"),o.innerHTML='<tr class="svelte-1ldjqdz"><th class="svelte-1ldjqdz">#</th> \n <th class="svelte-1ldjqdz">Datei</th> \n <th class="text_right svelte-1ldjqdz">Grösse</th> \n <th id="headAction" class="svelte-1ldjqdz">Aktionen</th></tr>',r=$(),l=p("tbody"),i.c(),b(o,"class","tablehead"),b(n,"class","tableFixHead"),b(e,"class","task_list svelte-1ldjqdz")},m(t,i){a(t,e,i),u(e,n),u(n,o),u(n,r),u(n,l),m[s].m(l,null),c=!0},p(t,e){let n=s;s=h(t),s===n?m[s].p(t,e):(A(),W(m[n],1,1,(()=>{m[n]=null})),G(),i=m[s],i?i.p(t,e):(i=m[s]=d[s](t),i.c()),T(i,1),i.m(l,null))},i(t){c||(T(i),c=!0)},o(t){W(i),c=!1},d(t){t&&f(e),m[s].d()}}}function at(t){let e,n,o=t[21],r=[];for(let e=0;e<o.length;e+=1)r[e]=ht(ot(t,o,e));const l=t=>W(r[t],1,1,(()=>{r[t]=null}));return{c(){for(let t=0;t<r.length;t+=1)r[t].c();e=g()},m(t,o){for(let e=0;e<r.length;e+=1)r[e].m(t,o);a(t,e,o),n=!0},p(t,n){if(2050&n){let s;for(o=t[21],s=0;s<o.length;s+=1){const l=ot(t,o,s);r[s]?(r[s].p(l,n),T(r[s],1)):(r[s]=ht(l),r[s].c(),T(r[s],1),r[s].m(e.parentNode,e))}for(A(),s=o.length;s<r.length;s+=1)l(s);G()}},i(t){if(!n){for(let t=0;t<o.length;t+=1)T(r[t]);n=!0}},o(t){r=r.filter(Boolean);for(let t=0;t<r.length;t+=1)W(r[t]);n=!1},d(t){!function(t,e){for(let n=0;n<t.length;n+=1)t[n]&&t[n].d(e)}(r,t),t&&f(e)}}}function ft(t){let e;return{c(){e=p("tr"),e.innerHTML='<td colspan="4" style="text-align: center;" class="svelte-1ldjqdz">Keine Dokumente gefunden</td>',b(e,"class","svelte-1ldjqdz")},m(t,n){a(t,e,n)},p:r,i:r,o:r,d(t){t&&f(e)}}}function pt(t){let e,n,o,r;return n=new Y({props:{size:"18"}}),{c(){e=p("a"),R(n.$$.fragment),b(e,"href",o="/api/userreport/"+t[22]._id),k(e,"color","whitesmoke")},m(t,o){a(t,e,o),L(n,e,null),r=!0},p(t,n){(!r||2&n&&o!==(o="/api/userreport/"+t[22]._id))&&b(e,"href",o)},i(t){r||(T(n.$$.fragment,t),r=!0)},o(t){W(n.$$.fragment,t),r=!1},d(t){t&&f(e),U(n)}}}function mt(t){let e,n;return e=new et({props:{size:"18"}}),{c(){R(e.$$.fragment)},m(t,o){L(e,t,o),n=!0},p:r,i(t){n||(T(e.$$.fragment,t),n=!0)},o(t){W(e.$$.fragment,t),n=!1},d(t){U(e,t)}}}function ht(t){let e,n,o,r,l,s,i,c,d,m,g,v,j,w,x,z,q=t[24]+1+"",_=t[22].title+"",E=vt(t[22].sizeInByte)+"";return v=new t[7]({props:{small:!0,filled:!0,style:"display: inline;",$$slots:{default:[pt]},$$scope:{ctx:t}}}),w=new t[7]({props:{small:!0,class:"deleteicon",style:"color: whitesmoke; display: inline;",$$slots:{default:[mt]},$$scope:{ctx:t}}}),w.$on("click",(function(){return t[17](t[22])})),{c(){e=p("tr"),n=p("td"),o=h(q),r=$(),l=p("td"),s=h(_),i=$(),c=p("td"),d=h(E),m=$(),g=p("td"),R(v.$$.fragment),j=$(),R(w.$$.fragment),x=$(),b(n,"class","svelte-1ldjqdz"),k(l,"max-width","30em"),b(l,"class","svelte-1ldjqdz"),b(c,"class","text_right svelte-1ldjqdz"),b(g,"class","svelte-1ldjqdz"),b(e,"class","svelte-1ldjqdz")},m(t,f){a(t,e,f),u(e,n),u(n,o),u(e,r),u(e,l),u(l,s),u(e,i),u(e,c),u(c,d),u(e,m),u(e,g),L(v,g,null),u(g,j),L(w,g,null),u(e,x),z=!0},p(e,n){t=e,(!z||2&n)&&_!==(_=t[22].title+"")&&y(s,_),(!z||2&n)&&E!==(E=vt(t[22].sizeInByte)+"")&&y(d,E);const o={};33554434&n&&(o.$$scope={dirty:n,ctx:t}),v.$set(o);const r={};33554432&n&&(r.$$scope={dirty:n,ctx:t}),w.$set(r)},i(t){z||(T(v.$$.fragment,t),T(w.$$.fragment,t),z=!0)},o(t){W(v.$$.fragment,t),W(w.$$.fragment,t),z=!1},d(t){t&&f(e),U(v),U(w)}}}function $t(t){return{c:r,m:r,p:r,i:r,o:r,d:r}}function gt(t){let e,n,o,r,l,s,i,c,d,m,h,y,j;r=new t[7]({props:{class:"btn-document btn-document-primary",filled:!0,$$slots:{default:[st]},$$scope:{ctx:t}}}),r.$on("click",t[13]);let w=t[0]&&it(t),x={ctx:t,current:null,token:null,hasCatch:!1,pending:$t,then:ut,catch:dt,value:21,blocks:[,,,]};return F(m=t[1],x),{c(){e=p("div"),n=p("form"),o=p("div"),R(r.$$.fragment),l=$(),s=p("input"),i=$(),w&&w.c(),c=$(),d=g(),x.block.c(),b(s,"type","file"),b(s,"accept",".pdf"),b(s,"id","fileInput"),s.required=!0,k(s,"display","none"),b(o,"class","document-choose svelte-1ldjqdz"),b(n,"id","uploadForm"),b(e,"class","form-step svelte-1ldjqdz")},m(f,p){a(f,e,p),u(e,n),u(n,o),L(r,o,null),u(o,l),u(o,s),t[15](s),a(f,i,p),w&&w.m(f,p),a(f,c,p),a(f,d,p),x.block.m(f,x.anchor=p),x.mount=()=>d.parentNode,x.anchor=d,h=!0,y||(j=v(s,"change",t[14]),y=!0)},p(e,[n]){t=e;const o={};33554433&n&&(o.$$scope={dirty:n,ctx:t}),r.$set(o),t[0]?w?(w.p(t,n),1&n&&T(w,1)):(w=it(t),w.c(),T(w,1),w.m(c.parentNode,c)):w&&(A(),W(w,1,1,(()=>{w=null})),G()),x.ctx=t,2&n&&m!==(m=t[1])&&F(m,x)||function(t,e,n){const o=e.slice(),{resolved:r}=t;t.current===t.then&&(o[t.value]=r),t.current===t.catch&&(o[t.error]=r),t.block.p(o,n)}(x,t,n)},i(t){h||(T(r.$$.fragment,t),T(w),T(x.block),h=!0)},o(t){W(r.$$.fragment,t),W(w);for(let t=0;t<3;t+=1){W(x.blocks[t])}h=!1},d(n){n&&f(e),U(r),t[15](null),n&&f(i),w&&w.d(n),n&&f(c),n&&f(d),x.block.d(n),x.token=null,x=null,y=!1,j()}}}function vt(t){if(t>=1073741824)t=Math.round(t/1073741824*100)/100+" GB";else if(t>=1048576){t=Math.round(t/1048576*100)/100+" MB"}else if(t>=1024){t=Math.round(t/1024*100)/100+" KB"}else t>1?t+=" bytes":1==t?t+=" byte":t="0 bytes";return t}function bt(t,r,l){let s,i,c;const{Button:d,Divider:u,TextField:a}=e;let f,p,m,h,{task:$}=r,g=[];const v=async()=>{const t=await $;f=t.task.id;return await o.getUserReports(f)};g=v();const b=()=>{let t=p.files[0];l(3,h=t?t.name.split(".").slice(0,-1).join("."):""),l(0,m=t)};function y(t){o.deleteUserReport(t).then((()=>{}))}n.subscribe((t=>{t&&t.taskId===f&&l(1,g=v())}));return t.$$set=t=>{"task"in t&&l(12,$=t.task)},t.$$.update=()=>{1&t.$$.dirty&&l(4,s=m?m.name:""),1&t.$$.dirty&&l(5,i=m?vt(m.size):""),1&t.$$.dirty&&l(6,c=m?m.name.split(".").slice(0,-1).join("."):"")},[m,g,p,h,s,i,c,d,a,function(){if(!m||!c)return;const t=new FormData;t.append("title",h),t.append("file",m),o.uploadUserReport(f,t).then((()=>{document.getElementById("submitForm").reset(),l(0,m=null)}))},b,y,$,()=>{p.click()},()=>b(),function(t){q[t?"unshift":"push"]((()=>{p=t,l(2,p)}))},function(t){h=t,l(3,h)},t=>y(t._id)]}class yt extends J{constructor(t){var e;super(),nt.getElementById("svelte-1ldjqdz-style")||((e=p("style")).id="svelte-1ldjqdz-style",e.textContent=".form-step.svelte-1ldjqdz .document-choose.svelte-1ldjqdz{margin:1em}.form-step.svelte-1ldjqdz .btn-document{width:300px;text-align:center}.form-step.svelte-1ldjqdz .btn-document div{margin-inline:auto}.form-step.svelte-1ldjqdz .btn-document-primary{color:#fff}.form-step.svelte-1ldjqdz .btn-document-secondary{background-color:#91BDD9}.form-step.svelte-1ldjqdz .container-file.svelte-1ldjqdz{display:grid;gap:1em;grid-template-columns:218px 100px 2fr 1fr;align-items:center}.form-step.svelte-1ldjqdz .word-break.svelte-1ldjqdz{word-break:break-all}.task_list.svelte-1ldjqdz.svelte-1ldjqdz{flex:auto;overflow-y:scroll;overflow-x:hidden;width:99%;height:30em;border:1px solid #ccc;border-radius:0.5em;margin-top:2em}.task_list.svelte-1ldjqdz th.svelte-1ldjqdz{padding:0.8em}.task_list.svelte-1ldjqdz td.svelte-1ldjqdz{padding:0.8em}.task_list.svelte-1ldjqdz .deleteicon{background-color:#CB6C60 !important}.task_list.svelte-1ldjqdz tr.svelte-1ldjqdz:nth-child(2n){background-color:#f8f8fe}.task_list.svelte-1ldjqdz td.svelte-1ldjqdz{vertical-align:middle}#headAction.svelte-1ldjqdz.svelte-1ldjqdz{width:13em}td.text_right.svelte-1ldjqdz.svelte-1ldjqdz,th.text_right.svelte-1ldjqdz.svelte-1ldjqdz{padding-right:1em}",u(nt.head,e)),V(this,t,bt,gt,d,{task:12})}}function kt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var jt,wt,xt=(jt=function(t,e){function n(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}function o(t){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?n(Object(o),!0).forEach((function(e){r(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):n(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function l(t){return l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},l(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){if("object"!==l(t))throw new Error("single-spa-svelte requires a configuration object");var e=o(o({},s),t);if(!e.component)throw new Error("single-spa-svelte must be passed opts.component");var n={};return{bootstrap:i.bind(null,e,n),mount:c.bind(null,e,n),unmount:d.bind(null,e,n),update:u.bind(null,e,n)}};var s={component:null,domElementGetter:null,props:{}};function i(t){return Promise.resolve()}function c(t,e,n){var r=Object.keys(s),l=Object.keys(t).reduce((function(e,n){return r.includes(n)||(e[n]=t[n]),e}),{});return Promise.resolve().then((function(){var r=function(t,e){return(e=e&&e.customProps?e.customProps:e).domElement?function(){return e.domElement}:e.domElementGetter?function(){return e.domElementGetter(e)}:t.domElementGetter?function(){return t.domElementGetter(e)}:function(t){var e=t.appName||t.name;if(!e)throw Error("single-spa-svelte was not given an application name as a prop, so it can't make a unique dom element container for the svelte application");var n="single-spa-application:".concat(e);return function(){var t=document.getElementById(n);return t||((t=document.createElement("div")).id=n,document.body.appendChild(t)),t}}(e)}(t,n),s=r();e.instance=new t.component(o(o({},l),{},{target:s,props:Object.assign({},n,t.props)}))}))}function d(t,e){return Promise.resolve().then((function(){e.instance.$destroy?e.instance.$destroy():e.instance.destroy()}))}function u(t,e,n){return Promise.resolve().then((function(){e.instance.$set?e.instance.$set(n):e.instance.set(n)}))}},jt(wt={exports:{}},wt.exports),wt.exports);const zt=kt(xt)({component:yt,domElementGetter:()=>document.getElementById("detail-app")}),{bootstrap:qt,mount:_t,unmount:Et}=zt;t({bootstrap:qt,mount:_t,unmount:Et});t("Report",yt)}}}));
1
+ System.register(["@enablerr-ui/layout","@enablerr-ui/form"],(function(t){"use strict";var e,n,o,r,s;return{setters:[function(t){e=t.getAttractions},function(t){n=t.attachment_notification,o=t.Request,r=t.currentRoles,s=t.settings}],execute:function(){t("version","0.2.35");function c(){}function l(t){return t()}function i(){return Object.create(null)}function u(t){t.forEach(l)}function a(t){return"function"==typeof t}function d(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function p(t,e,n){t.$$.on_destroy.push(function(t,...e){if(null==t)return c;const n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}(e,n))}function f(t,e){t.appendChild(e)}function m(t,e,n){t.insertBefore(e,n||null)}function h(t){t.parentNode.removeChild(t)}function $(t){return document.createElement(t)}function g(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function v(t){return document.createTextNode(t)}function b(){return v(" ")}function w(){return v("")}function y(t,e,n,o){return t.addEventListener(e,n,o),()=>t.removeEventListener(e,n,o)}function k(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function x(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function _(t,e,n,o){t.style.setProperty(e,n,o?"important":"")}let E;function j(t){E=t}function O(){if(!E)throw new Error("Function called outside component initialization");return E}const P=[],z=[],B=[],D=[],S=Promise.resolve();let M=!1;function C(t){B.push(t)}let I=!1;const N=new Set;function A(){if(!I){I=!0;do{for(let t=0;t<P.length;t+=1){const e=P[t];j(e),G(e.$$)}for(j(null),P.length=0;z.length;)z.pop()();for(let t=0;t<B.length;t+=1){const e=B[t];N.has(e)||(N.add(e),e())}B.length=0}while(P.length);for(;D.length;)D.pop()();M=!1,I=!1,N.clear()}}function G(t){if(null!==t.fragment){t.update(),u(t.before_update);const e=t.dirty;t.dirty=[-1],t.fragment&&t.fragment.p(t.ctx,e),t.after_update.forEach(C)}}const T=new Set;let W;function F(){W={r:0,c:[],p:W}}function q(){W.r||u(W.c),W=W.p}function R(t,e){t&&t.i&&(T.delete(t),t.i(e))}function H(t,e,n,o){if(t&&t.o){if(T.has(t))return;T.add(t),W&&W.c.push((()=>{T.delete(t),o&&(n&&t.d(1),o())})),t.o(e)}}function L(t,e){const n=e.token={};function o(t,o,r,s){if(e.token!==n)return;e.resolved=s;let c=e.ctx;void 0!==r&&(c=c.slice(),c[r]=s);const l=t&&(e.current=t)(c);let i=!1;e.block&&(e.blocks?e.blocks.forEach(((t,n)=>{n!==o&&t&&(F(),H(t,1,1,(()=>{e.blocks[n]===t&&(e.blocks[n]=null)})),q())})):e.block.d(1),l.c(),R(l,1),l.m(e.mount(),e.anchor),i=!0),e.block=l,e.blocks&&(e.blocks[o]=l),i&&A()}if((r=t)&&"object"==typeof r&&"function"==typeof r.then){const n=O();if(t.then((t=>{j(n),o(e.then,1,e.value,t),j(null)}),(t=>{if(j(n),o(e.catch,2,e.error,t),j(null),!e.hasCatch)throw t})),e.current!==e.pending)return o(e.pending,0),!0}else{if(e.current!==e.then)return o(e.then,1,e.value,t),!0;e.resolved=t}var r}const U="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:global;function K(t){t&&t.c()}function V(t,e,n,o){const{fragment:r,on_mount:s,on_destroy:c,after_update:i}=t.$$;r&&r.m(e,n),o||C((()=>{const e=s.map(l).filter(a);c?c.push(...e):u(e),t.$$.on_mount=[]})),i.forEach(C)}function J(t,e){const n=t.$$;null!==n.fragment&&(u(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function Q(t,e){-1===t.$$.dirty[0]&&(P.push(t),M||(M=!0,S.then(A)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<<e%31}function X(t,e,n,o,r,s,l=[-1]){const a=E;j(t);const d=t.$$={fragment:null,ctx:null,props:s,update:c,not_equal:r,bound:i(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(a?a.$$.context:e.context||[]),callbacks:i(),dirty:l,skip_bound:!1};let p=!1;if(d.ctx=n?n(t,e.props||{},((e,n,...o)=>{const s=o.length?o[0]:n;return d.ctx&&r(d.ctx[e],d.ctx[e]=s)&&(!d.skip_bound&&d.bound[e]&&d.bound[e](s),p&&Q(t,e)),n})):[],d.update(),p=!0,u(d.before_update),d.fragment=!!o&&o(d.ctx),e.target){if(e.hydrate){const t=function(t){return Array.from(t.childNodes)}(e.target);d.fragment&&d.fragment.l(t),t.forEach(h)}else d.fragment&&d.fragment.c();e.intro&&R(t.$$.fragment),V(t,e.target,e.anchor,e.customElement),A()}j(a)}class Y{$destroy(){J(this,1),this.$destroy=c}$on(t,e){const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){var e;this.$$set&&(e=t,0!==Object.keys(e).length)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}function Z(t){let e,n,o,r,s;return{c(){e=g("svg"),n=g("path"),o=g("polyline"),r=g("line"),k(n,"d","M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"),k(o,"points","7 10 12 15 17 10"),k(r,"x1","12"),k(r,"y1","15"),k(r,"x2","12"),k(r,"y2","3"),k(e,"xmlns","http://www.w3.org/2000/svg"),k(e,"width",t[0]),k(e,"height",t[0]),k(e,"fill","none"),k(e,"viewBox","0 0 24 24"),k(e,"stroke","currentColor"),k(e,"stroke-width",t[1]),k(e,"stroke-linecap","round"),k(e,"stroke-linejoin","round"),k(e,"class",s="feather feather-download "+t[2])},m(t,s){m(t,e,s),f(e,n),f(e,o),f(e,r)},p(t,[n]){1&n&&k(e,"width",t[0]),1&n&&k(e,"height",t[0]),2&n&&k(e,"stroke-width",t[1]),4&n&&s!==(s="feather feather-download "+t[2])&&k(e,"class",s)},i:c,o:c,d(t){t&&h(e)}}}function tt(t,e,n){let{size:o="100%"}=e,{strokeWidth:r=2}=e,{class:s=""}=e;return"100%"!==o&&(o="x"===o.slice(-1)?o.slice(0,o.length-1)+"em":parseInt(o)+"px"),t.$$set=t=>{"size"in t&&n(0,o=t.size),"strokeWidth"in t&&n(1,r=t.strokeWidth),"class"in t&&n(2,s=t.class)},[o,r,s]}class et extends Y{constructor(t){super(),X(this,t,tt,Z,d,{size:0,strokeWidth:1,class:2})}}function nt(t){let e,n,o,r;return{c(){e=g("svg"),n=g("polyline"),o=g("path"),k(n,"points","3 6 5 6 21 6"),k(o,"d","M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"),k(e,"xmlns","http://www.w3.org/2000/svg"),k(e,"width",t[0]),k(e,"height",t[0]),k(e,"fill","none"),k(e,"viewBox","0 0 24 24"),k(e,"stroke","currentColor"),k(e,"stroke-width",t[1]),k(e,"stroke-linecap","round"),k(e,"stroke-linejoin","round"),k(e,"class",r="feather feather-trash "+t[2])},m(t,r){m(t,e,r),f(e,n),f(e,o)},p(t,[n]){1&n&&k(e,"width",t[0]),1&n&&k(e,"height",t[0]),2&n&&k(e,"stroke-width",t[1]),4&n&&r!==(r="feather feather-trash "+t[2])&&k(e,"class",r)},i:c,o:c,d(t){t&&h(e)}}}function ot(t,e,n){let{size:o="100%"}=e,{strokeWidth:r=2}=e,{class:s=""}=e;return"100%"!==o&&(o="x"===o.slice(-1)?o.slice(0,o.length-1)+"em":parseInt(o)+"px"),t.$$set=t=>{"size"in t&&n(0,o=t.size),"strokeWidth"in t&&n(1,r=t.strokeWidth),"class"in t&&n(2,s=t.class)},[o,r,s]}class rt extends Y{constructor(t){super(),X(this,t,ot,nt,d,{size:0,strokeWidth:1,class:2})}}const{document:st}=U;function ct(t,e,n){const o=t.slice();return o[27]=e[n],o[29]=n,o}function lt(t){let e;return{c(){e=$("div"),e.textContent="Dokument ersetzen"},m(t,n){m(t,e,n)},d(t){t&&h(e)}}}function it(t){let e;return{c(){e=$("div"),e.textContent="Dokument wählen"},m(t,n){m(t,e,n)},d(t){t&&h(e)}}}function ut(t){let e;function n(t,e){return t[0]?lt:it}let o=n(t),r=o(t);return{c(){r.c(),e=w()},m(t,n){r.m(t,n),m(t,e,n)},p(t,s){o!==(o=n(t))&&(r.d(1),r=o(t),r&&(r.c(),r.m(e.parentNode,e)))},d(t){r.d(t),t&&h(e)}}}function at(t){let e,n,o,r,s,c,l,i,u,a,d,p,g,w,_,E;function j(e){t[21](e)}let O={placeholder:t[7],type:"text",id:"fileTitle",required:!0};return void 0!==t[3]&&(O.value=t[3]),a=new t[9]({props:O}),z.push((()=>function(t,e,n){const o=t.$$.props[e];void 0!==o&&(t.$$.bound[o]=n,n(t.$$.ctx[o]))}(a,"value",j))),g=new t[8]({props:{disabled:t[4],filled:!0,style:"color: whitesmoke;",type:"submit",$$slots:{default:[dt]},$$scope:{ctx:t}}}),{c(){e=$("div"),n=$("form"),o=$("div"),r=$("div"),s=v(t[5]),c=b(),l=$("div"),i=v(t[6]),u=b(),K(a.$$.fragment),p=b(),K(g.$$.fragment),k(r,"class","word-break svelte-o8wpc2"),k(o,"class","container-file svelte-o8wpc2"),k(n,"id","submitForm"),k(e,"class","form-step svelte-o8wpc2")},m(d,h){var $;m(d,e,h),f(e,n),f(n,o),f(o,r),f(r,s),f(o,c),f(o,l),f(l,i),f(o,u),V(a,o,null),f(o,p),V(g,o,null),w=!0,_||(E=y(n,"submit",($=t[10],function(t){return t.preventDefault(),$.call(this,t)})),_=!0)},p(t,e){(!w||32&e)&&x(s,t[5]),(!w||64&e)&&x(i,t[6]);const n={};var o;128&e&&(n.placeholder=t[7]),!d&&8&e&&(d=!0,n.value=t[3],o=()=>d=!1,D.push(o)),a.$set(n);const r={};16&e&&(r.disabled=t[4]),1073741824&e&&(r.$$scope={dirty:e,ctx:t}),g.$set(r)},i(t){w||(R(a.$$.fragment,t),R(g.$$.fragment,t),w=!0)},o(t){H(a.$$.fragment,t),H(g.$$.fragment,t),w=!1},d(t){t&&h(e),J(a),J(g),_=!1,E()}}}function dt(t){let e;return{c(){e=v("Dokument hochladen")},m(t,n){m(t,e,n)},d(t){t&&h(e)}}}function pt(t){return{c:c,m:c,p:c,i:c,o:c,d:c}}function ft(t){let e,n,o,r,s,c,l,i;const u=[ht,mt],a=[];function d(t,e){return 0===t[26].length?0:1}return c=d(t),l=a[c]=u[c](t),{c(){e=$("div"),n=$("table"),o=$("thead"),o.innerHTML='<tr class="svelte-o8wpc2"><th class="svelte-o8wpc2">#</th> \n <th class="svelte-o8wpc2">Datei</th> \n <th class="text_right svelte-o8wpc2">Grösse</th> \n <th id="headAction" class="svelte-o8wpc2">Aktionen</th></tr>',r=b(),s=$("tbody"),l.c(),k(o,"class","tablehead"),k(n,"class","tableFixHead"),k(e,"class","task_list svelte-o8wpc2")},m(t,l){m(t,e,l),f(e,n),f(n,o),f(n,r),f(n,s),a[c].m(s,null),i=!0},p(t,e){let n=c;c=d(t),c===n?a[c].p(t,e):(F(),H(a[n],1,1,(()=>{a[n]=null})),q(),l=a[c],l?l.p(t,e):(l=a[c]=u[c](t),l.c()),R(l,1),l.m(s,null))},i(t){i||(R(l),i=!0)},o(t){H(l),i=!1},d(t){t&&h(e),a[c].d()}}}function mt(t){let e,n,o=t[26],r=[];for(let e=0;e<o.length;e+=1)r[e]=vt(ct(t,o,e));const s=t=>H(r[t],1,1,(()=>{r[t]=null}));return{c(){for(let t=0;t<r.length;t+=1)r[t].c();e=w()},m(t,o){for(let e=0;e<r.length;e+=1)r[e].m(t,o);m(t,e,o),n=!0},p(t,n){if(4114&n){let c;for(o=t[26],c=0;c<o.length;c+=1){const s=ct(t,o,c);r[c]?(r[c].p(s,n),R(r[c],1)):(r[c]=vt(s),r[c].c(),R(r[c],1),r[c].m(e.parentNode,e))}for(F(),c=o.length;c<r.length;c+=1)s(c);q()}},i(t){if(!n){for(let t=0;t<o.length;t+=1)R(r[t]);n=!0}},o(t){r=r.filter(Boolean);for(let t=0;t<r.length;t+=1)H(r[t]);n=!1},d(t){!function(t,e){for(let n=0;n<t.length;n+=1)t[n]&&t[n].d(e)}(r,t),t&&h(e)}}}function ht(t){let e;return{c(){e=$("tr"),e.innerHTML='<td colspan="4" style="text-align: center;" class="svelte-o8wpc2">Keine Dokumente gefunden</td>',k(e,"class","svelte-o8wpc2")},m(t,n){m(t,e,n)},p:c,i:c,o:c,d(t){t&&h(e)}}}function $t(t){let e,n,o,r;return n=new et({props:{size:"18"}}),{c(){e=$("a"),K(n.$$.fragment),k(e,"href",o="/api/userreport/"+t[27]._id),_(e,"color","whitesmoke")},m(t,o){m(t,e,o),V(n,e,null),r=!0},p(t,n){(!r||2&n&&o!==(o="/api/userreport/"+t[27]._id))&&k(e,"href",o)},i(t){r||(R(n.$$.fragment,t),r=!0)},o(t){H(n.$$.fragment,t),r=!1},d(t){t&&h(e),J(n)}}}function gt(t){let e,n;return e=new rt({props:{size:"18"}}),{c(){K(e.$$.fragment)},m(t,o){V(e,t,o),n=!0},p:c,i(t){n||(R(e.$$.fragment,t),n=!0)},o(t){H(e.$$.fragment,t),n=!1},d(t){J(e,t)}}}function vt(t){let e,n,o,r,s,c,l,i,u,a,d,p,g,w,y,E,j=t[29]+1+"",O=t[27].title+"",P=yt(t[27].sizeInByte)+"";return p=new t[8]({props:{small:!0,filled:!0,style:"display: inline;",$$slots:{default:[$t]},$$scope:{ctx:t}}}),w=new t[8]({props:{disabled:t[4],small:!0,filled:!0,danger:!0,style:"color: whitesmoke; display: inline;",$$slots:{default:[gt]},$$scope:{ctx:t}}}),w.$on("click",(function(){return t[22](t[27])})),{c(){e=$("tr"),n=$("td"),o=v(j),r=b(),s=$("td"),c=v(O),l=b(),i=$("td"),u=v(P),a=b(),d=$("td"),K(p.$$.fragment),g=b(),K(w.$$.fragment),y=b(),k(n,"class","svelte-o8wpc2"),_(s,"max-width","30em"),k(s,"class","svelte-o8wpc2"),k(i,"class","text_right svelte-o8wpc2"),k(d,"class","svelte-o8wpc2"),k(e,"class","svelte-o8wpc2")},m(t,h){m(t,e,h),f(e,n),f(n,o),f(e,r),f(e,s),f(s,c),f(e,l),f(e,i),f(i,u),f(e,a),f(e,d),V(p,d,null),f(d,g),V(w,d,null),f(e,y),E=!0},p(e,n){t=e,(!E||2&n)&&O!==(O=t[27].title+"")&&x(c,O),(!E||2&n)&&P!==(P=yt(t[27].sizeInByte)+"")&&x(u,P);const o={};1073741826&n&&(o.$$scope={dirty:n,ctx:t}),p.$set(o);const r={};16&n&&(r.disabled=t[4]),1073741824&n&&(r.$$scope={dirty:n,ctx:t}),w.$set(r)},i(t){E||(R(p.$$.fragment,t),R(w.$$.fragment,t),E=!0)},o(t){H(p.$$.fragment,t),H(w.$$.fragment,t),E=!1},d(t){t&&h(e),J(p),J(w)}}}function bt(t){return{c:c,m:c,p:c,i:c,o:c,d:c}}function wt(t){let e,n,o,r,s,c,l,i,u,a,d,p,g;r=new t[8]({props:{class:"btn-document btn-document-primary",filled:!0,disabled:t[4],$$slots:{default:[ut]},$$scope:{ctx:t}}}),r.$on("click",t[18]);let v=t[0]&&at(t),x={ctx:t,current:null,token:null,hasCatch:!1,pending:bt,then:ft,catch:pt,value:26,blocks:[,,,]};return L(a=t[1],x),{c(){e=$("div"),n=$("form"),o=$("div"),K(r.$$.fragment),s=b(),c=$("input"),l=b(),v&&v.c(),i=b(),u=w(),x.block.c(),k(c,"type","file"),k(c,"accept",".pdf"),k(c,"id","fileInput"),c.required=!0,_(c,"display","none"),k(o,"class","document-choose svelte-o8wpc2"),k(n,"id","uploadForm"),k(e,"class","form-step svelte-o8wpc2")},m(a,h){m(a,e,h),f(e,n),f(n,o),V(r,o,null),f(o,s),f(o,c),t[20](c),m(a,l,h),v&&v.m(a,h),m(a,i,h),m(a,u,h),x.block.m(a,x.anchor=h),x.mount=()=>u.parentNode,x.anchor=u,d=!0,p||(g=y(c,"change",t[19]),p=!0)},p(e,[n]){t=e;const o={};16&n&&(o.disabled=t[4]),1073741825&n&&(o.$$scope={dirty:n,ctx:t}),r.$set(o),t[0]?v?(v.p(t,n),1&n&&R(v,1)):(v=at(t),v.c(),R(v,1),v.m(i.parentNode,i)):v&&(F(),H(v,1,1,(()=>{v=null})),q()),x.ctx=t,2&n&&a!==(a=t[1])&&L(a,x)||function(t,e,n){const o=e.slice(),{resolved:r}=t;t.current===t.then&&(o[t.value]=r),t.current===t.catch&&(o[t.error]=r),t.block.p(o,n)}(x,t,n)},i(t){d||(R(r.$$.fragment,t),R(v),R(x.block),d=!0)},o(t){H(r.$$.fragment,t),H(v);for(let t=0;t<3;t+=1){H(x.blocks[t])}d=!1},d(n){n&&h(e),J(r),t[20](null),n&&h(l),v&&v.d(n),n&&h(i),n&&h(u),x.block.d(n),x.token=null,x=null,p=!1,g()}}}function yt(t){if(t>=1073741824)t=Math.round(t/1073741824*100)/100+" GB";else if(t>=1048576){t=Math.round(t/1048576*100)/100+" MB"}else if(t>=1024){t=Math.round(t/1024*100)/100+" KB"}else t>1?t+=" bytes":1==t?t+=" byte":t="0 bytes";return t}function kt(t,c,l){let i,u,a,d,f,m;p(t,r,(t=>l(16,f=t))),p(t,s,(t=>l(17,m=t)));const{Button:h,Divider:$,TextField:g}=e;let v,b,w,y,k,{task:x}=c,_=[],E=x.task?.readonly;const j=async()=>{const t=await x;l(14,b=await o.getSchema(t.event)),v=t.task.id;return await o.getUserReports(v)};_=j();const O=()=>{let t=w.files[0];l(3,k=t?t.name.split(".").slice(0,-1).join("."):""),l(0,y=t)};function P(t){o.deleteUserReport(t).then((()=>{}))}n.subscribe((t=>{t&&t.taskId===v&&l(1,_=j())}));return t.$$set=t=>{"task"in t&&l(13,x=t.task)},t.$$.update=()=>{if(253952&t.$$.dirty&&b&&x.task&&f&&m.role?.length&&b.authorization?.length){const t=b.authorization.some((t=>f?.find((e=>e===t.role&&"edit"===t.activity))));l(15,E||=!t)}32768&t.$$.dirty&&l(4,i=E),1&t.$$.dirty&&l(5,u=y?y.name:""),1&t.$$.dirty&&l(6,a=y?yt(y.size):""),1&t.$$.dirty&&l(7,d=y?y.name.split(".").slice(0,-1).join("."):"")},[y,_,w,k,i,u,a,d,h,g,function(){if(!y||!d)return;const t=new FormData;t.append("title",k),t.append("file",y),o.uploadUserReport(v,t).then((()=>{document.getElementById("submitForm").reset(),l(0,y=null)}))},O,P,x,b,E,f,m,()=>{w.click()},()=>O(),function(t){z[t?"unshift":"push"]((()=>{w=t,l(2,w)}))},function(t){k=t,l(3,k)},t=>P(t._id)]}class xt extends Y{constructor(t){var e;super(),st.getElementById("svelte-o8wpc2-style")||((e=$("style")).id="svelte-o8wpc2-style",e.textContent=".form-step.svelte-o8wpc2 .document-choose.svelte-o8wpc2{margin:1em}.form-step.svelte-o8wpc2 .btn-document{width:300px;text-align:center}.form-step.svelte-o8wpc2 .btn-document div{margin-inline:auto}.form-step.svelte-o8wpc2 .btn-document-primary{color:#fff}.form-step.svelte-o8wpc2 .btn-document-secondary{background-color:#91BDD9}.form-step.svelte-o8wpc2 .container-file.svelte-o8wpc2{display:grid;gap:1em;grid-template-columns:218px 100px 2fr 1fr;align-items:center}.form-step.svelte-o8wpc2 .word-break.svelte-o8wpc2{word-break:break-all}.task_list.svelte-o8wpc2.svelte-o8wpc2{flex:auto;overflow-y:scroll;overflow-x:hidden;width:99%;height:30em;border:1px solid #ccc;border-radius:0.5em;margin-top:2em}.task_list.svelte-o8wpc2 th.svelte-o8wpc2{padding:0.8em}.task_list.svelte-o8wpc2 td.svelte-o8wpc2{padding:0.8em}.task_list.svelte-o8wpc2 tr.svelte-o8wpc2:nth-child(2n){background-color:#f8f8fe}.task_list.svelte-o8wpc2 td.svelte-o8wpc2{vertical-align:middle}#headAction.svelte-o8wpc2.svelte-o8wpc2{width:13em}td.text_right.svelte-o8wpc2.svelte-o8wpc2,th.text_right.svelte-o8wpc2.svelte-o8wpc2{padding-right:1em}",f(st.head,e)),X(this,t,kt,wt,d,{task:13})}}function _t(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Et,jt,Ot=(Et=function(t,e){function n(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}function o(t){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?n(Object(o),!0).forEach((function(e){r(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):n(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function s(t){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){if("object"!==s(t))throw new Error("single-spa-svelte requires a configuration object");var e=o(o({},c),t);if(!e.component)throw new Error("single-spa-svelte must be passed opts.component");var n={};return{bootstrap:l.bind(null,e,n),mount:i.bind(null,e,n),unmount:u.bind(null,e,n),update:a.bind(null,e,n)}};var c={component:null,domElementGetter:null,props:{}};function l(t){return Promise.resolve()}function i(t,e,n){var r=Object.keys(c),s=Object.keys(t).reduce((function(e,n){return r.includes(n)||(e[n]=t[n]),e}),{});return Promise.resolve().then((function(){var r=function(t,e){return(e=e&&e.customProps?e.customProps:e).domElement?function(){return e.domElement}:e.domElementGetter?function(){return e.domElementGetter(e)}:t.domElementGetter?function(){return t.domElementGetter(e)}:function(t){var e=t.appName||t.name;if(!e)throw Error("single-spa-svelte was not given an application name as a prop, so it can't make a unique dom element container for the svelte application");var n="single-spa-application:".concat(e);return function(){var t=document.getElementById(n);return t||((t=document.createElement("div")).id=n,document.body.appendChild(t)),t}}(e)}(t,n),c=r();e.instance=new t.component(o(o({},s),{},{target:c,props:Object.assign({},n,t.props)}))}))}function u(t,e){return Promise.resolve().then((function(){e.instance.$destroy?e.instance.$destroy():e.instance.destroy()}))}function a(t,e,n){return Promise.resolve().then((function(){e.instance.$set?e.instance.$set(n):e.instance.set(n)}))}},Et(jt={exports:{}},jt.exports),jt.exports);const Pt=_t(Ot)({component:xt,domElementGetter:()=>document.getElementById("detail-app")}),{bootstrap:zt,mount:Bt,unmount:Dt}=Pt;t({bootstrap:zt,mount:Bt,unmount:Dt});t("Report",xt)}}}));
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@enablerr-ui/report",
3
3
  "description": "enablerr - the Next Enterprise Solution",
4
- "version": "0.2.33",
4
+ "version": "0.2.35",
5
5
  "os": [
6
6
  "darwin",
7
7
  "linux"