@nuralyui/file-upload 0.0.10 → 0.0.12
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/bundle.js +26 -75
- package/package.json +1 -1
package/bundle.js
CHANGED
|
@@ -1,53 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2019 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
5
|
-
*/
|
|
6
|
-
const t=window,i=t.ShadowRoot&&(void 0===t.ShadyCSS||t.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s=Symbol(),e=new WeakMap;class o{constructor(t,i,e){if(this._$cssResult$=!0,e!==s)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=i}get styleSheet(){let t=this.o;const s=this.t;if(i&&void 0===t){const i=void 0!==s&&1===s.length;i&&(t=e.get(s)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),i&&e.set(s,t))}return t}toString(){return this.cssText}}const n=i?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let i="";for(const s of t.cssRules)i+=s.cssText;return(t=>new o("string"==typeof t?t:t+"",void 0,s))(i)})(t):t
|
|
7
|
-
/**
|
|
8
|
-
* @license
|
|
9
|
-
* Copyright 2017 Google LLC
|
|
10
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
11
|
-
*/;var r;const l=window,h=l.trustedTypes,d=h?h.emptyScript:"",a=l.reactiveElementPolyfillSupport,c={toAttribute(t,i){switch(i){case Boolean:t=t?d:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,i){let s=t;switch(i){case Boolean:s=null!==t;break;case Number:s=null===t?null:Number(t);break;case Object:case Array:try{s=JSON.parse(t)}catch(t){s=null}}return s}},u=(t,i)=>i!==t&&(i==i||t==t),v={attribute:!0,type:String,converter:c,reflect:!1,hasChanged:u},p="finalized";class f extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(t){var i;this.finalize(),(null!==(i=this.h)&&void 0!==i?i:this.h=[]).push(t)}static get observedAttributes(){this.finalize();const t=[];return this.elementProperties.forEach(((i,s)=>{const e=this._$Ep(s,i);void 0!==e&&(this._$Ev.set(e,s),t.push(e))})),t}static createProperty(t,i=v){if(i.state&&(i.attribute=!1),this.finalize(),this.elementProperties.set(t,i),!i.noAccessor&&!this.prototype.hasOwnProperty(t)){const s="symbol"==typeof t?Symbol():"__"+t,e=this.getPropertyDescriptor(t,s,i);void 0!==e&&Object.defineProperty(this.prototype,t,e)}}static getPropertyDescriptor(t,i,s){return{get(){return this[i]},set(e){const o=this[t];this[i]=e,this.requestUpdate(t,o,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)||v}static finalize(){if(this.hasOwnProperty(p))return!1;this[p]=!0;const t=Object.getPrototypeOf(this);if(t.finalize(),void 0!==t.h&&(this.h=[...t.h]),this.elementProperties=new Map(t.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){const t=this.properties,i=[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)];for(const s of i)this.createProperty(s,t[s])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(t){const i=[];if(Array.isArray(t)){const s=new Set(t.flat(1/0).reverse());for(const t of s)i.unshift(n(t))}else void 0!==t&&i.push(n(t));return i}static _$Ep(t,i){const s=i.attribute;return!1===s?void 0:"string"==typeof s?s:"string"==typeof t?t.toLowerCase():void 0}_$Eu(){var t;this._$E_=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(t=this.constructor.h)||void 0===t||t.forEach((t=>t(this)))}addController(t){var i,s;(null!==(i=this._$ES)&&void 0!==i?i:this._$ES=[]).push(t),void 0!==this.renderRoot&&this.isConnected&&(null===(s=t.hostConnected)||void 0===s||s.call(t))}removeController(t){var i;null===(i=this._$ES)||void 0===i||i.splice(this._$ES.indexOf(t)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach(((t,i)=>{this.hasOwnProperty(i)&&(this._$Ei.set(i,this[i]),delete this[i])}))}createRenderRoot(){var s;const e=null!==(s=this.shadowRoot)&&void 0!==s?s:this.attachShadow(this.constructor.shadowRootOptions);return((s,e)=>{i?s.adoptedStyleSheets=e.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet)):e.forEach((i=>{const e=document.createElement("style"),o=t.litNonce;void 0!==o&&e.setAttribute("nonce",o),e.textContent=i.cssText,s.appendChild(e)}))})(e,this.constructor.elementStyles),e}connectedCallback(){var t;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var i;return null===(i=t.hostConnected)||void 0===i?void 0:i.call(t)}))}enableUpdating(t){}disconnectedCallback(){var t;null===(t=this._$ES)||void 0===t||t.forEach((t=>{var i;return null===(i=t.hostDisconnected)||void 0===i?void 0:i.call(t)}))}attributeChangedCallback(t,i,s){this._$AK(t,s)}_$EO(t,i,s=v){var e;const o=this.constructor._$Ep(t,s);if(void 0!==o&&!0===s.reflect){const n=(void 0!==(null===(e=s.converter)||void 0===e?void 0:e.toAttribute)?s.converter:c).toAttribute(i,s.type);this._$El=t,null==n?this.removeAttribute(o):this.setAttribute(o,n),this._$El=null}}_$AK(t,i){var s;const e=this.constructor,o=e._$Ev.get(t);if(void 0!==o&&this._$El!==o){const t=e.getPropertyOptions(o),n="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==(null===(s=t.converter)||void 0===s?void 0:s.fromAttribute)?t.converter:c;this._$El=o,this[o]=n.fromAttribute(i,t.type),this._$El=null}}requestUpdate(t,i,s){let e=!0;void 0!==t&&(((s=s||this.constructor.getPropertyOptions(t)).hasChanged||u)(this[t],i)?(this._$AL.has(t)||this._$AL.set(t,i),!0===s.reflect&&this._$El!==t&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(t,s))):e=!1),!this.isUpdatePending&&e&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var t;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach(((t,i)=>this[i]=t)),this._$Ei=void 0);let i=!1;const s=this._$AL;try{i=this.shouldUpdate(s),i?(this.willUpdate(s),null===(t=this._$ES)||void 0===t||t.forEach((t=>{var i;return null===(i=t.hostUpdate)||void 0===i?void 0:i.call(t)})),this.update(s)):this._$Ek()}catch(t){throw i=!1,this._$Ek(),t}i&&this._$AE(s)}willUpdate(t){}_$AE(t){var i;null===(i=this._$ES)||void 0===i||i.forEach((t=>{var i;return null===(i=t.hostUpdated)||void 0===i?void 0:i.call(t)})),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(t){return!0}update(t){void 0!==this._$EC&&(this._$EC.forEach(((t,i)=>this._$EO(i,this[i],t))),this._$EC=void 0),this._$Ek()}updated(t){}firstUpdated(t){}}
|
|
12
|
-
/**
|
|
13
|
-
* @license
|
|
14
|
-
* Copyright 2017 Google LLC
|
|
15
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
16
|
-
*/
|
|
17
|
-
var g;f[p]=!0,f.elementProperties=new Map,f.elementStyles=[],f.shadowRootOptions={mode:"open"},null==a||a({ReactiveElement:f}),(null!==(r=l.reactiveElementVersions)&&void 0!==r?r:l.reactiveElementVersions=[]).push("1.6.3");const w=window,m=w.trustedTypes,b=m?m.createPolicy("lit-html",{createHTML:t=>t}):void 0,y="$lit$",x=`lit$${(Math.random()+"").slice(9)}$`,$="?"+x,k=`<${$}>`,S=document,_=()=>S.createComment(""),A=t=>null===t||"object"!=typeof t&&"function"!=typeof t,C=Array.isArray,z="[ \t\n\f\r]",E=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,M=/-->/g,j=/>/g,U=RegExp(`>|${z}(?:([^\\s"'>=/]+)(${z}*=${z}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),B=/'/g,T=/"/g,P=/^(?:script|style|textarea|title)$/i,N=Symbol.for("lit-noChange"),R=Symbol.for("lit-nothing"),I=new WeakMap,O=S.createTreeWalker(S,129,null,!1);function F(t,i){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==b?b.createHTML(i):i}class L{constructor({strings:t,_$litType$:i},s){let e;this.parts=[];let o=0,n=0;const r=t.length-1,l=this.parts,[h,d]=((t,i)=>{const s=t.length-1,e=[];let o,n=2===i?"<svg>":"",r=E;for(let i=0;i<s;i++){const s=t[i];let l,h,d=-1,a=0;for(;a<s.length&&(r.lastIndex=a,h=r.exec(s),null!==h);)a=r.lastIndex,r===E?"!--"===h[1]?r=M:void 0!==h[1]?r=j:void 0!==h[2]?(P.test(h[2])&&(o=RegExp("</"+h[2],"g")),r=U):void 0!==h[3]&&(r=U):r===U?">"===h[0]?(r=null!=o?o:E,d=-1):void 0===h[1]?d=-2:(d=r.lastIndex-h[2].length,l=h[1],r=void 0===h[3]?U:'"'===h[3]?T:B):r===T||r===B?r=U:r===M||r===j?r=E:(r=U,o=void 0);const c=r===U&&t[i+1].startsWith("/>")?" ":"";n+=r===E?s+k:d>=0?(e.push(l),s.slice(0,d)+y+s.slice(d)+x+c):s+x+(-2===d?(e.push(void 0),i):c)}return[F(t,n+(t[s]||"<?>")+(2===i?"</svg>":"")),e]})(t,i);if(this.el=L.createElement(h,s),O.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(e=O.nextNode())&&l.length<r;){if(1===e.nodeType){if(e.hasAttributes()){const t=[];for(const i of e.getAttributeNames())if(i.endsWith(y)||i.startsWith(x)){const s=d[n++];if(t.push(i),void 0!==s){const t=e.getAttribute(s.toLowerCase()+y).split(x),i=/([.?@])?(.*)/.exec(s);l.push({type:1,index:o,name:i[2],strings:t,ctor:"."===i[1]?W:"?"===i[1]?V:"@"===i[1]?q:K})}else l.push({type:6,index:o})}for(const i of t)e.removeAttribute(i)}if(P.test(e.tagName)){const t=e.textContent.split(x),i=t.length-1;if(i>0){e.textContent=m?m.emptyScript:"";for(let s=0;s<i;s++)e.append(t[s],_()),O.nextNode(),l.push({type:2,index:++o});e.append(t[i],_())}}}else if(8===e.nodeType)if(e.data===$)l.push({type:2,index:o});else{let t=-1;for(;-1!==(t=e.data.indexOf(x,t+1));)l.push({type:7,index:o}),t+=x.length-1}o++}}static createElement(t,i){const s=S.createElement("template");return s.innerHTML=t,s}}function D(t,i,s=t,e){var o,n,r,l;if(i===N)return i;let h=void 0!==e?null===(o=s._$Co)||void 0===o?void 0:o[e]:s._$Cl;const d=A(i)?void 0:i._$litDirective$;return(null==h?void 0:h.constructor)!==d&&(null===(n=null==h?void 0:h._$AO)||void 0===n||n.call(h,!1),void 0===d?h=void 0:(h=new d(t),h._$AT(t,s,e)),void 0!==e?(null!==(r=(l=s)._$Co)&&void 0!==r?r:l._$Co=[])[e]=h:s._$Cl=h),void 0!==h&&(i=D(t,h._$AS(t,i.values),h,e)),i}class H{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var i;const{el:{content:s},parts:e}=this._$AD,o=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:S).importNode(s,!0);O.currentNode=o;let n=O.nextNode(),r=0,l=0,h=e[0];for(;void 0!==h;){if(r===h.index){let i;2===h.type?i=new Z(n,n.nextSibling,this,t):1===h.type?i=new h.ctor(n,h.name,h.strings,this,t):6===h.type&&(i=new G(n,this,t)),this._$AV.push(i),h=e[++l]}r!==(null==h?void 0:h.index)&&(n=O.nextNode(),r++)}return O.currentNode=S,o}v(t){let i=0;for(const s of this._$AV)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++}}class Z{constructor(t,i,s,e){var o;this.type=2,this._$AH=R,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cp=null===(o=null==e?void 0:e.isConnected)||void 0===o||o}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cp}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===(null==t?void 0:t.nodeType)&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=D(this,t,i),A(t)?t===R||null==t||""===t?(this._$AH!==R&&this._$AR(),this._$AH=R):t!==this._$AH&&t!==N&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>C(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==R&&A(this._$AH)?this._$AA.nextSibling.data=t:this.$(S.createTextNode(t)),this._$AH=t}g(t){var i;const{values:s,_$litType$:e}=t,o="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=L.createElement(F(e.h,e.h[0]),this.options)),e);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===o)this._$AH.v(s);else{const t=new H(o,this),i=t.u(this.options);t.v(s),this.$(i),this._$AH=t}}_$AC(t){let i=I.get(t.strings);return void 0===i&&I.set(t.strings,i=new L(t)),i}T(t){C(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const o of t)e===i.length?i.push(s=new Z(this.k(_()),this.k(_()),this,this.options)):s=i[e],s._$AI(o),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e)}_$AR(t=this._$AA.nextSibling,i){var s;for(null===(s=this._$AP)||void 0===s||s.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$Cp=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class K{constructor(t,i,s,e,o){this.type=1,this._$AH=R,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=o,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=R}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,s,e){const o=this.strings;let n=!1;if(void 0===o)t=D(this,t,i,0),n=!A(t)||t!==this._$AH&&t!==N,n&&(this._$AH=t);else{const e=t;let r,l;for(t=o[0],r=0;r<o.length-1;r++)l=D(this,e[s+r],i,r),l===N&&(l=this._$AH[r]),n||(n=!A(l)||l!==this._$AH[r]),l===R?t=R:t!==R&&(t+=(null!=l?l:"")+o[r+1]),this._$AH[r]=l}n&&!e&&this.j(t)}j(t){t===R?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class W extends K{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===R?void 0:t}}const J=m?m.emptyScript:"";class V extends K{constructor(){super(...arguments),this.type=4}j(t){t&&t!==R?this.element.setAttribute(this.name,J):this.element.removeAttribute(this.name)}}class q extends K{constructor(t,i,s,e,o){super(t,i,s,e,o),this.type=5}_$AI(t,i=this){var s;if((t=null!==(s=D(this,t,i,0))&&void 0!==s?s:R)===N)return;const e=this._$AH,o=t===R&&e!==R||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,n=t!==R&&(e===R||o);o&&this.element.removeEventListener(this.name,this,e),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,s;"function"==typeof this._$AH?this._$AH.call(null!==(s=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==s?s:this.element,t):this._$AH.handleEvent(t)}}class G{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){D(this,t)}}const Q=w.litHtmlPolyfillSupport;
|
|
18
|
-
/**
|
|
19
|
-
* @license
|
|
20
|
-
* Copyright 2017 Google LLC
|
|
21
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
22
|
-
*/
|
|
23
|
-
var X;null==Q||Q(L,Z),(null!==(g=w.litHtmlVersions)&&void 0!==g?g:w.litHtmlVersions=[]).push("2.8.0");const Y=window,tt=Y.trustedTypes,it=tt?tt.createPolicy("lit-html",{createHTML:t=>t}):void 0,st="$lit$",et=`lit$${(Math.random()+"").slice(9)}$`,ot="?"+et,nt=`<${ot}>`,rt=document,lt=()=>rt.createComment(""),ht=t=>null===t||"object"!=typeof t&&"function"!=typeof t,dt=Array.isArray,at="[ \t\n\f\r]",ct=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,ut=/-->/g,vt=/>/g,pt=RegExp(`>|${at}(?:([^\\s"'>=/]+)(${at}*=${at}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),ft=/'/g,gt=/"/g,wt=/^(?:script|style|textarea|title)$/i,mt=(t=>(i,...s)=>({_$litType$:t,strings:i,values:s}))(1),bt=Symbol.for("lit-noChange"),yt=Symbol.for("lit-nothing"),xt=new WeakMap,$t=rt.createTreeWalker(rt,129,null,!1);function kt(t,i){if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==it?it.createHTML(i):i}const St=(t,i)=>{const s=t.length-1,e=[];let o,n=2===i?"<svg>":"",r=ct;for(let i=0;i<s;i++){const s=t[i];let l,h,d=-1,a=0;for(;a<s.length&&(r.lastIndex=a,h=r.exec(s),null!==h);)a=r.lastIndex,r===ct?"!--"===h[1]?r=ut:void 0!==h[1]?r=vt:void 0!==h[2]?(wt.test(h[2])&&(o=RegExp("</"+h[2],"g")),r=pt):void 0!==h[3]&&(r=pt):r===pt?">"===h[0]?(r=null!=o?o:ct,d=-1):void 0===h[1]?d=-2:(d=r.lastIndex-h[2].length,l=h[1],r=void 0===h[3]?pt:'"'===h[3]?gt:ft):r===gt||r===ft?r=pt:r===ut||r===vt?r=ct:(r=pt,o=void 0);const c=r===pt&&t[i+1].startsWith("/>")?" ":"";n+=r===ct?s+nt:d>=0?(e.push(l),s.slice(0,d)+st+s.slice(d)+et+c):s+et+(-2===d?(e.push(void 0),i):c)}return[kt(t,n+(t[s]||"<?>")+(2===i?"</svg>":"")),e]};class _t{constructor({strings:t,_$litType$:i},s){let e;this.parts=[];let o=0,n=0;const r=t.length-1,l=this.parts,[h,d]=St(t,i);if(this.el=_t.createElement(h,s),$t.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(e=$t.nextNode())&&l.length<r;){if(1===e.nodeType){if(e.hasAttributes()){const t=[];for(const i of e.getAttributeNames())if(i.endsWith(st)||i.startsWith(et)){const s=d[n++];if(t.push(i),void 0!==s){const t=e.getAttribute(s.toLowerCase()+st).split(et),i=/([.?@])?(.*)/.exec(s);l.push({type:1,index:o,name:i[2],strings:t,ctor:"."===i[1]?Mt:"?"===i[1]?Ut:"@"===i[1]?Bt:Et})}else l.push({type:6,index:o})}for(const i of t)e.removeAttribute(i)}if(wt.test(e.tagName)){const t=e.textContent.split(et),i=t.length-1;if(i>0){e.textContent=tt?tt.emptyScript:"";for(let s=0;s<i;s++)e.append(t[s],lt()),$t.nextNode(),l.push({type:2,index:++o});e.append(t[i],lt())}}}else if(8===e.nodeType)if(e.data===ot)l.push({type:2,index:o});else{let t=-1;for(;-1!==(t=e.data.indexOf(et,t+1));)l.push({type:7,index:o}),t+=et.length-1}o++}}static createElement(t,i){const s=rt.createElement("template");return s.innerHTML=t,s}}function At(t,i,s=t,e){var o,n,r,l;if(i===bt)return i;let h=void 0!==e?null===(o=s._$Co)||void 0===o?void 0:o[e]:s._$Cl;const d=ht(i)?void 0:i._$litDirective$;return(null==h?void 0:h.constructor)!==d&&(null===(n=null==h?void 0:h._$AO)||void 0===n||n.call(h,!1),void 0===d?h=void 0:(h=new d(t),h._$AT(t,s,e)),void 0!==e?(null!==(r=(l=s)._$Co)&&void 0!==r?r:l._$Co=[])[e]=h:s._$Cl=h),void 0!==h&&(i=At(t,h._$AS(t,i.values),h,e)),i}class Ct{constructor(t,i){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var i;const{el:{content:s},parts:e}=this._$AD,o=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:rt).importNode(s,!0);$t.currentNode=o;let n=$t.nextNode(),r=0,l=0,h=e[0];for(;void 0!==h;){if(r===h.index){let i;2===h.type?i=new zt(n,n.nextSibling,this,t):1===h.type?i=new h.ctor(n,h.name,h.strings,this,t):6===h.type&&(i=new Tt(n,this,t)),this._$AV.push(i),h=e[++l]}r!==(null==h?void 0:h.index)&&(n=$t.nextNode(),r++)}return $t.currentNode=rt,o}v(t){let i=0;for(const s of this._$AV)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,i),i+=s.strings.length-2):s._$AI(t[i])),i++}}class zt{constructor(t,i,s,e){var o;this.type=2,this._$AH=yt,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=s,this.options=e,this._$Cp=null===(o=null==e?void 0:e.isConnected)||void 0===o||o}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cp}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===(null==t?void 0:t.nodeType)&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=At(this,t,i),ht(t)?t===yt||null==t||""===t?(this._$AH!==yt&&this._$AR(),this._$AH=yt):t!==this._$AH&&t!==bt&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>dt(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==yt&&ht(this._$AH)?this._$AA.nextSibling.data=t:this.$(rt.createTextNode(t)),this._$AH=t}g(t){var i;const{values:s,_$litType$:e}=t,o="number"==typeof e?this._$AC(t):(void 0===e.el&&(e.el=_t.createElement(kt(e.h,e.h[0]),this.options)),e);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===o)this._$AH.v(s);else{const t=new Ct(o,this),i=t.u(this.options);t.v(s),this.$(i),this._$AH=t}}_$AC(t){let i=xt.get(t.strings);return void 0===i&&xt.set(t.strings,i=new _t(t)),i}T(t){dt(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let s,e=0;for(const o of t)e===i.length?i.push(s=new zt(this.k(lt()),this.k(lt()),this,this.options)):s=i[e],s._$AI(o),e++;e<i.length&&(this._$AR(s&&s._$AB.nextSibling,e),i.length=e)}_$AR(t=this._$AA.nextSibling,i){var s;for(null===(s=this._$AP)||void 0===s||s.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$Cp=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class Et{constructor(t,i,s,e,o){this.type=1,this._$AH=yt,this._$AN=void 0,this.element=t,this.name=i,this._$AM=e,this.options=o,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=yt}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,s,e){const o=this.strings;let n=!1;if(void 0===o)t=At(this,t,i,0),n=!ht(t)||t!==this._$AH&&t!==bt,n&&(this._$AH=t);else{const e=t;let r,l;for(t=o[0],r=0;r<o.length-1;r++)l=At(this,e[s+r],i,r),l===bt&&(l=this._$AH[r]),n||(n=!ht(l)||l!==this._$AH[r]),l===yt?t=yt:t!==yt&&(t+=(null!=l?l:"")+o[r+1]),this._$AH[r]=l}n&&!e&&this.j(t)}j(t){t===yt?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class Mt extends Et{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===yt?void 0:t}}const jt=tt?tt.emptyScript:"";class Ut extends Et{constructor(){super(...arguments),this.type=4}j(t){t&&t!==yt?this.element.setAttribute(this.name,jt):this.element.removeAttribute(this.name)}}class Bt extends Et{constructor(t,i,s,e,o){super(t,i,s,e,o),this.type=5}_$AI(t,i=this){var s;if((t=null!==(s=At(this,t,i,0))&&void 0!==s?s:yt)===bt)return;const e=this._$AH,o=t===yt&&e!==yt||t.capture!==e.capture||t.once!==e.once||t.passive!==e.passive,n=t!==yt&&(e===yt||o);o&&this.element.removeEventListener(this.name,this,e),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,s;"function"==typeof this._$AH?this._$AH.call(null!==(s=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==s?s:this.element,t):this._$AH.handleEvent(t)}}class Tt{constructor(t,i,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){At(this,t)}}const Pt=Y.litHtmlPolyfillSupport;null==Pt||Pt(_t,zt),(null!==(X=Y.litHtmlVersions)&&void 0!==X?X:Y.litHtmlVersions=[]).push("2.8.0");
|
|
24
|
-
/**
|
|
25
|
-
* @license
|
|
26
|
-
* Copyright 2017 Google LLC
|
|
27
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
28
|
-
*/
|
|
29
|
-
var Nt,Rt;class It extends f{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var t,i;const s=super.createRenderRoot();return null!==(t=(i=this.renderOptions).renderBefore)&&void 0!==t||(i.renderBefore=s.firstChild),s}update(t){const i=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,i,s)=>{var e,o;const n=null!==(e=null==s?void 0:s.renderBefore)&&void 0!==e?e:i;let r=n._$litPart$;if(void 0===r){const t=null!==(o=null==s?void 0:s.renderBefore)&&void 0!==o?o:null;n._$litPart$=r=new zt(i.insertBefore(lt(),t),t,void 0,null!=s?s:{})}return r._$AI(t),r})(i,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),null===(t=this._$Do)||void 0===t||t.setConnected(!1)}render(){return bt}}It.finalized=!0,It._$litElement$=!0,null===(Nt=globalThis.litElementHydrateSupport)||void 0===Nt||Nt.call(globalThis,{LitElement:It});const Ot=globalThis.litElementPolyfillSupport;null==Ot||Ot({LitElement:It}),(null!==(Rt=globalThis.litElementVersions)&&void 0!==Rt?Rt:globalThis.litElementVersions=[]).push("3.3.3");
|
|
30
|
-
/**
|
|
31
|
-
* @license
|
|
32
|
-
* Copyright 2017 Google LLC
|
|
33
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
34
|
-
*/
|
|
35
|
-
const Ft=(t,i)=>"method"===i.kind&&i.descriptor&&!("value"in i.descriptor)?{...i,finisher(s){s.createProperty(i.key,t)}}:{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:i.key,initializer(){"function"==typeof i.initializer&&(this[i.key]=i.initializer.call(this))},finisher(s){s.createProperty(i.key,t)}},Lt=(t,i,s)=>{i.constructor.createProperty(s,t)};
|
|
36
|
-
/**
|
|
37
|
-
* @license
|
|
38
|
-
* Copyright 2017 Google LLC
|
|
39
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
40
|
-
*/function Dt(t){return(i,s)=>void 0!==s?Lt(t,i,s):Ft(t,i)
|
|
41
|
-
/**
|
|
42
|
-
* @license
|
|
43
|
-
* Copyright 2017 Google LLC
|
|
44
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
45
|
-
*/}function Ht(t){return Dt({...t,state:!0})}
|
|
46
|
-
/**
|
|
47
|
-
* @license
|
|
48
|
-
* Copyright 2021 Google LLC
|
|
49
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
50
|
-
*/var Zt;null===(Zt=window.HTMLSlotElement)||void 0===Zt||Zt.prototype.assignedElements;const Kt=((t,...i)=>{const e=1===t.length?t[0]:i.reduce(((i,s,e)=>i+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+t[e+1]),t[0]);return new o(e,t,s)})`
|
|
1
|
+
import{css as i,LitElement as e,html as t}from"lit";import{property as o,state as s,customElement as r}from"lit/decorators.js";const n=i`
|
|
51
2
|
:host {
|
|
52
3
|
display: block;
|
|
53
4
|
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
|
|
@@ -329,8 +280,8 @@ const Ft=(t,i)=>"method"===i.kind&&i.descriptor&&!("value"in i.descriptor)?{...i
|
|
|
329
280
|
font-size: 16px;
|
|
330
281
|
}
|
|
331
282
|
}
|
|
332
|
-
`,
|
|
333
|
-
<div class="upload" @drop=${this._onDrop} @dragover=${
|
|
283
|
+
`,l={isImageFile:i=>i.type.startsWith("image/"),formatFileSize(i){if(0===i)return"0 B";const e=Math.floor(Math.log(i)/Math.log(1024));return parseFloat((i/Math.pow(1024,e)).toFixed(2))+" "+["B","KB","MB","GB","TB"][e]},createFilePreview:i=>new Promise((e=>{const t=new FileReader;t.onload=i=>{var t;e(null===(t=i.target)||void 0===t?void 0:t.result)},t.readAsDataURL(i)}))};var a=function(i,e,t,o){for(var s,r=arguments.length,n=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,t):o,l=i.length-1;l>=0;l--)(s=i[l])&&(n=(r<3?s(n):r>3?s(e,t,n):s(e,t))||n);return r>3&&n&&Object.defineProperty(e,t,n),n},d=function(i,e,t,o){return new(t||(t=Promise))((function(s,r){function n(i){try{a(o.next(i))}catch(i){r(i)}}function l(i){try{a(o.throw(i))}catch(i){r(i)}}function a(i){var e;i.done?s(i.value):(e=i.value,e instanceof t?e:new t((function(i){i(e)}))).then(n,l)}a((o=o.apply(i,e||[])).next())}))};let h=class extends e{constructor(){super(...arguments),this.accept="",this.multiple=!1,this.drag=!0,this.tip="",this.limit=0,this.preview=!0,this.generatePreviewOnUpload=!1,this.fileList=[],this.isDragOver=!1,this.showDragArea=!1,this.inputElement=null,this.dragCounter=0,this.previewImage=null,this._onDocumentDragEnter=i=>{i.preventDefault(),this.dragCounter++,1===this.dragCounter&&(this.showDragArea=!0)},this._onDocumentDragLeave=i=>{i.preventDefault(),this.dragCounter--,0===this.dragCounter&&(this.showDragArea=!1,this.isDragOver=!1)},this._onDocumentDrop=i=>{i.target===this||this.contains(i.target)||(i.preventDefault(),this.dragCounter=0,this.showDragArea=!1,this.isDragOver=!1)},this._onDocumentDragOver=i=>{i.preventDefault();const e=i.composedPath().includes(this);this.isDragOver=!!e},this._onDrop=i=>{var e;i.preventDefault(),i.stopPropagation(),this.dragCounter=0,this.isDragOver=!1,this.showDragArea=!1,(null===(e=i.dataTransfer)||void 0===e?void 0:e.files)&&(this.dispatchEvent(new CustomEvent("files-changed",{detail:i.dataTransfer.files,bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("file-drop",{detail:{files:i.dataTransfer.files},bubbles:!0,composed:!0})),this._handleFiles(i.dataTransfer.files))},this._onClick=()=>{var i;null===(i=this.inputElement)||void 0===i||i.click()},this._onChange=i=>{const e=i.target;e.files&&(this.dispatchEvent(new CustomEvent("files-changed",{detail:e.files,bubbles:!0,composed:!0})),this._handleFiles(e.files),e.value="")}}connectedCallback(){super.connectedCallback(),this.drag&&(document.addEventListener("dragenter",this._onDocumentDragEnter),document.addEventListener("dragleave",this._onDocumentDragLeave),document.addEventListener("drop",this._onDocumentDrop),document.addEventListener("dragover",this._onDocumentDragOver))}disconnectedCallback(){super.disconnectedCallback(),this.drag&&(document.removeEventListener("dragenter",this._onDocumentDragEnter),document.removeEventListener("dragleave",this._onDocumentDragLeave),document.removeEventListener("drop",this._onDocumentDrop),document.removeEventListener("dragover",this._onDocumentDragOver))}firstUpdated(i){var e;super.firstUpdated(i),this.inputElement=(null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector('input[type="file"]'))||null}_handleFiles(i){return d(this,void 0,void 0,(function*(){if(this.multiple&&this.limit>0&&this.fileList.length+i.length>this.limit)return void this._dispatchEvent("exceed",{files:i});if(!this.multiple&&i.length>0){const e=i[i.length-1];this.previewImage&&this.fileList.some((i=>i.url===this.previewImage))&&(this.previewImage=null);const t=[...this.fileList];for(const i of t)this._dispatchEvent("remove",{file:i});this.fileList=[];const o=l.isImageFile(e),s={name:e.name,size:l.formatFileSize(e.size),raw:e,status:"ready",percentage:0,uid:Date.now()+Math.random().toString(36).substring(2),isImage:o};return this.preview&&this.generatePreviewOnUpload&&o&&(s.url=yield l.createFilePreview(e)),this.fileList=[s],this.requestUpdate(),void this._dispatchEvent("select",{files:[s],fileList:this.fileList})}const e=[];for(const t of Array.from(i)){const i=l.isImageFile(t),o={name:t.name,size:l.formatFileSize(t.size),raw:t,status:"ready",percentage:0,uid:Date.now()+Math.random().toString(36).substring(2),isImage:i};this.preview&&this.generatePreviewOnUpload&&i&&(o.url=yield l.createFilePreview(t)),this.fileList=[...this.fileList,o],e.push(o)}this.requestUpdate(),this._dispatchEvent("select",{files:e,fileList:this.fileList})}))}updateFileStatus(i,e,t){const o=this.fileList.find((e=>e.uid===i));o&&(o.status=e,void 0!==t&&(o.percentage=t),this._updateFile(o))}_updateFile(i){this.fileList=this.fileList.map((e=>e.uid===i.uid?i:e)),this.requestUpdate()}_removeFile(i){const e=this.fileList.find((e=>e.uid===i));this.fileList=this.fileList.filter((e=>e.uid!==i)),e&&this._dispatchEvent("remove",{file:e}),this.requestUpdate()}_dispatchEvent(i,e){this.dispatchEvent(new CustomEvent(`file-${i}`,{detail:e,bubbles:!0,composed:!0}))}_showPreview(i){this.previewImage=i}_closePreview(){this.previewImage=null}render(){return t`
|
|
284
|
+
<div class="upload" @drop=${this._onDrop} @dragover=${i=>i.preventDefault()}>
|
|
334
285
|
<input
|
|
335
286
|
type="file"
|
|
336
287
|
class="hidden"
|
|
@@ -339,7 +290,7 @@ const Ft=(t,i)=>"method"===i.kind&&i.descriptor&&!("value"in i.descriptor)?{...i
|
|
|
339
290
|
@change=${this._onChange}
|
|
340
291
|
/>
|
|
341
292
|
|
|
342
|
-
${this.showDragArea?
|
|
293
|
+
${this.showDragArea?t`
|
|
343
294
|
<div
|
|
344
295
|
class="upload-dragger ${this.isDragOver?"is-dragover":""}"
|
|
345
296
|
@click=${this._onClick}
|
|
@@ -352,82 +303,82 @@ const Ft=(t,i)=>"method"===i.kind&&i.descriptor&&!("value"in i.descriptor)?{...i
|
|
|
352
303
|
</svg>
|
|
353
304
|
</div>
|
|
354
305
|
<div class="upload-text">Drop file here or click to upload</div>
|
|
355
|
-
${this.tip?
|
|
306
|
+
${this.tip?t`<div class="upload-tip">${this.tip}</div>`:""}
|
|
356
307
|
</div>
|
|
357
|
-
`:
|
|
308
|
+
`:t`
|
|
358
309
|
<nr-button @click=${this._onClick}>Upload File</nr-button>
|
|
359
|
-
${this.tip?
|
|
310
|
+
${this.tip?t`<div class="upload-tip">${this.tip}</div>`:""}
|
|
360
311
|
`}
|
|
361
312
|
|
|
362
313
|
<div class="file-list">
|
|
363
|
-
${this.fileList.map((t
|
|
314
|
+
${this.fileList.map((i=>t`
|
|
364
315
|
<div class="file-item">
|
|
365
|
-
${
|
|
316
|
+
${i.isImage?t`
|
|
366
317
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
367
318
|
<rect x="3" y="3" width="18" height="18" rx="2" ry="2"></rect>
|
|
368
319
|
<circle cx="8.5" cy="8.5" r="1.5"></circle>
|
|
369
320
|
<polyline points="21 15 16 10 5 21"></polyline>
|
|
370
321
|
</svg>
|
|
371
|
-
`:
|
|
322
|
+
`:t`
|
|
372
323
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
373
324
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path>
|
|
374
325
|
<polyline points="14 2 14 8 20 8"></polyline>
|
|
375
326
|
</svg>
|
|
376
327
|
`}
|
|
377
|
-
<div class="file-name">${
|
|
378
|
-
<div class="file-size">${
|
|
328
|
+
<div class="file-name">${i.name}</div>
|
|
329
|
+
<div class="file-size">${i.size}</div>
|
|
379
330
|
<div class="file-status">
|
|
380
|
-
${"success"===
|
|
331
|
+
${"success"===i.status?t`
|
|
381
332
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#67c23a" stroke-width="2">
|
|
382
333
|
<polyline points="20 6 9 17 4 12"></polyline>
|
|
383
334
|
</svg>
|
|
384
|
-
`:"error"===
|
|
335
|
+
`:"error"===i.status?t`
|
|
385
336
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#f56c6c" stroke-width="2">
|
|
386
337
|
<line x1="18" y1="6" x2="6" y2="18"></line>
|
|
387
338
|
<line x1="6" y1="6" x2="18" y2="18"></line>
|
|
388
339
|
</svg>
|
|
389
|
-
`:"uploading"===
|
|
340
|
+
`:"uploading"===i.status?t`${i.percentage}%`:""}
|
|
390
341
|
</div>
|
|
391
342
|
<div class="file-actions">
|
|
392
|
-
${
|
|
393
|
-
<button class="preview-icon" @click=${()=>this._showPreview(
|
|
343
|
+
${i.isImage&&i.url?t`
|
|
344
|
+
<button class="preview-icon" @click=${()=>this._showPreview(i.url)}>
|
|
394
345
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
395
346
|
<path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"></path>
|
|
396
347
|
<circle cx="12" cy="12" r="3"></circle>
|
|
397
348
|
</svg>
|
|
398
349
|
</button>
|
|
399
350
|
`:""}
|
|
400
|
-
<button @click=${()=>this._removeFile(
|
|
351
|
+
<button @click=${()=>this._removeFile(i.uid)}>
|
|
401
352
|
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
402
353
|
<line x1="18" y1="6" x2="6" y2="18"></line>
|
|
403
354
|
<line x1="6" y1="6" x2="18" y2="18"></line>
|
|
404
355
|
</svg>
|
|
405
356
|
</button>
|
|
406
357
|
</div>
|
|
407
|
-
${"uploading"===
|
|
358
|
+
${"uploading"===i.status?t`
|
|
408
359
|
<div class="progress-bar">
|
|
409
|
-
<div class="progress-inner" style="width: ${
|
|
360
|
+
<div class="progress-inner" style="width: ${i.percentage}%"></div>
|
|
410
361
|
</div>
|
|
411
362
|
`:""}
|
|
412
363
|
</div>
|
|
413
|
-
${this.preview&&
|
|
364
|
+
${this.preview&&i.isImage&&i.url?t`
|
|
414
365
|
<div class="file-preview">
|
|
415
366
|
<img
|
|
416
367
|
class="image-preview"
|
|
417
|
-
src="${
|
|
418
|
-
alt="${
|
|
419
|
-
@click=${()=>this._showPreview(
|
|
368
|
+
src="${i.url}"
|
|
369
|
+
alt="${i.name}"
|
|
370
|
+
@click=${()=>this._showPreview(i.url)}
|
|
420
371
|
/>
|
|
421
372
|
</div>
|
|
422
373
|
`:""}
|
|
423
374
|
`))}
|
|
424
375
|
</div>
|
|
425
376
|
|
|
426
|
-
${this.previewImage?
|
|
377
|
+
${this.previewImage?t`
|
|
427
378
|
<div class="preview-modal" @click=${this._closePreview}>
|
|
428
379
|
<button class="preview-close">×</button>
|
|
429
380
|
<img src="${this.previewImage}" alt="Preview" />
|
|
430
381
|
</div>
|
|
431
382
|
`:""}
|
|
432
383
|
</div>
|
|
433
|
-
`}};
|
|
384
|
+
`}};h.styles=n,a([o({type:String})],h.prototype,"accept",void 0),a([o({type:Boolean})],h.prototype,"multiple",void 0),a([o({type:Boolean})],h.prototype,"drag",void 0),a([o({type:String})],h.prototype,"tip",void 0),a([o({type:Number})],h.prototype,"limit",void 0),a([o({type:Boolean})],h.prototype,"preview",void 0),a([o({type:Boolean})],h.prototype,"generatePreviewOnUpload",void 0),a([s()],h.prototype,"fileList",void 0),a([s()],h.prototype,"isDragOver",void 0),a([s()],h.prototype,"showDragArea",void 0),a([s()],h.prototype,"inputElement",void 0),a([s()],h.prototype,"dragCounter",void 0),a([s()],h.prototype,"previewImage",void 0),h=a([r("nr-file-upload")],h);export{h as FileUpload};
|