nxt-dropzone-wrapper 15.0.0 → 16.0.0-alpha.1

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.
@@ -1,49 +1,62 @@
1
+ import * as i0 from '@angular/core';
2
+ import { InjectionToken, EventEmitter, PLATFORM_ID, Directive, Inject, Optional, Input, Output, HostBinding, forwardRef, Component, ViewEncapsulation, ViewChild, NgModule } from '@angular/core';
1
3
  import * as i1 from '@angular/common';
2
4
  import { isPlatformBrowser, CommonModule } from '@angular/common';
3
- import * as i0 from '@angular/core';
4
- import { InjectionToken, EventEmitter, PLATFORM_ID, Directive, Inject, Optional, Input, Output, Component, ViewEncapsulation, ViewChild, NgModule } from '@angular/core';
5
5
  import Dropzone from 'dropzone';
6
6
 
7
7
  const NXT_DROPZONE_CONFIG = new InjectionToken('NXT_DROPZONE_CONFIG');
8
+ /** @internal */
8
9
  const DropzoneEvents = [
9
- 'error',
10
- 'success',
11
- 'sending',
12
- 'canceled',
13
- 'complete',
14
- 'processing',
10
+ 'init',
15
11
  'drop',
16
12
  'dragStart',
17
13
  'dragEnd',
18
14
  'dragEnter',
19
15
  'dragOver',
20
16
  'dragLeave',
21
- 'thumbnail',
17
+ 'paste',
18
+ 'reset',
22
19
  'addedFile',
23
20
  'addedFiles',
24
21
  'removedFile',
25
- 'uploadProgress',
26
- 'maxFilesReached',
27
- 'maxFilesExceeded',
22
+ 'thumbnail',
23
+ 'error',
28
24
  'errorMultiple',
29
- 'successMultiple',
25
+ 'processing',
26
+ 'processingMultiple',
27
+ 'uploadProgress',
28
+ 'totalUploadProgress',
29
+ 'sending',
30
30
  'sendingMultiple',
31
+ 'success',
32
+ 'successMultiple',
33
+ 'canceled',
31
34
  'canceledMultiple',
35
+ 'complete',
32
36
  'completeMultiple',
33
- 'processingMultiple',
34
- 'reset',
35
- 'queueComplete',
36
- 'totalUploadProgress'
37
+ 'maxFilesExceeded',
38
+ 'maxFilesReached',
39
+ 'queueComplete'
37
40
  ];
38
- class DropzoneConfig {
41
+ /** @internal */
42
+ const internalChanges = new Set([
43
+ 'autoReset',
44
+ 'errorReset',
45
+ 'cancelReset'
46
+ ]);
47
+ /** @internal */
48
+ class _DropzoneConfig {
39
49
  constructor(config = {}) {
40
50
  this.assign(config);
41
51
  }
42
52
  assign(config = {}, target) {
43
53
  target = target || this;
44
54
  for (const key in config) {
45
- if (config[key] != null && !(Array.isArray(config[key])) &&
46
- typeof config[key] === 'object' && !(config[key] instanceof HTMLElement)) {
55
+ if (config[key] != null
56
+ && config[key] != undefined
57
+ && !Array.isArray(config[key])
58
+ && typeof config[key] === 'object'
59
+ && !(config[key] instanceof HTMLElement)) {
47
60
  target[key] = {};
48
61
  this.assign(config[key], target[key]);
49
62
  }
@@ -52,61 +65,127 @@ class DropzoneConfig {
52
65
  }
53
66
  }
54
67
  }
55
- }
68
+ }
69
+ /** @internal */
70
+ const NXT_DROPZONE_LISTENERS = new InjectionToken('NXT_DROPZONE_LISTENERS');
56
71
 
57
72
  /* eslint-disable @angular-eslint/no-output-rename */
58
73
  class DropzoneDirective {
59
- constructor(zone, renderer, elementRef, differs, platformId, defaults) {
74
+ /** Disables / detaches Dropzone from the element */
75
+ set disabled(val) {
76
+ val = !!val;
77
+ if (val != this._disabled && this.instance) {
78
+ if (val)
79
+ this.zone.runOutsideAngular(() => {
80
+ this.instance.disable();
81
+ });
82
+ else
83
+ this.zone.runOutsideAngular(() => {
84
+ this.instance.enable();
85
+ });
86
+ }
87
+ this._disabled = val;
88
+ }
89
+ get disabled() {
90
+ return this._disabled;
91
+ }
92
+ get dropzone() {
93
+ return this.instance;
94
+ }
95
+ /** @internal */
96
+ get isSingle() {
97
+ return this._params.maxFiles === 1;
98
+ }
99
+ /** @internal */
100
+ get isMultiple() {
101
+ return this._params.maxFiles !== 1;
102
+ }
103
+ constructor(zone, elementRef, differs, platformId, defaults, component) {
104
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35;
60
105
  this.zone = zone;
61
- this.renderer = renderer;
62
106
  this.elementRef = elementRef;
63
107
  this.differs = differs;
64
108
  this.platformId = platformId;
65
109
  this.defaults = defaults;
66
- this.configDiff = null;
67
- this.disabled = false;
68
- this.DZ_INIT = new EventEmitter();
69
- this.DZ_ERROR = new EventEmitter();
70
- this.DZ_SUCCESS = new EventEmitter();
71
- this.DZ_SENDING = new EventEmitter();
72
- this.DZ_CANCELED = new EventEmitter();
73
- this.DZ_COMPLETE = new EventEmitter();
74
- this.DZ_PROCESSING = new EventEmitter();
75
- this.DZ_DROP = new EventEmitter();
76
- this.DZ_DRAGSTART = new EventEmitter();
77
- this.DZ_DRAGEND = new EventEmitter();
78
- this.DZ_DRAGENTER = new EventEmitter();
79
- this.DZ_DRAGOVER = new EventEmitter();
80
- this.DZ_DRAGLEAVE = new EventEmitter();
81
- this.DZ_THUMBNAIL = new EventEmitter();
82
- this.DZ_ADDEDFILE = new EventEmitter();
83
- this.DZ_ADDEDFILES = new EventEmitter();
84
- this.DZ_REMOVEDFILE = new EventEmitter();
85
- this.DZ_UPLOADPROGRESS = new EventEmitter();
86
- this.DZ_MAXFILESREACHED = new EventEmitter();
87
- this.DZ_MAXFILESEXCEEDED = new EventEmitter();
88
- this.DZ_ERRORMULTIPLE = new EventEmitter();
89
- this.DZ_SUCCESSMULTIPLE = new EventEmitter();
90
- this.DZ_SENDINGMULTIPLE = new EventEmitter();
91
- this.DZ_CANCELEDMULTIPLE = new EventEmitter();
92
- this.DZ_COMPLETEMULTIPLE = new EventEmitter();
93
- this.DZ_PROCESSINGMULTIPLE = new EventEmitter();
94
- this.DZ_RESET = new EventEmitter();
95
- this.DZ_QUEUECOMPLETE = new EventEmitter();
96
- this.DZ_TOTALUPLOADPROGRESS = new EventEmitter();
97
- const dz = Dropzone;
98
- dz.autoDiscover = false;
110
+ this.component = component;
111
+ this._disabled = false;
112
+ this._params = new _DropzoneConfig(this.defaults);
113
+ this.configDiff = this.differs.find(this.config || {}).create();
114
+ this.paramDiff = this.differs.find(this._params).create();
115
+ this.DZ_INIT = (_b = (_a = this.component) === null || _a === void 0 ? void 0 : _a.DZ_INIT) !== null && _b !== void 0 ? _b : new EventEmitter();
116
+ this.DZ_DROP = (_d = (_c = this.component) === null || _c === void 0 ? void 0 : _c.DZ_DROP) !== null && _d !== void 0 ? _d : new EventEmitter();
117
+ this.DZ_DRAGSTART = (_f = (_e = this.component) === null || _e === void 0 ? void 0 : _e.DZ_DRAGSTART) !== null && _f !== void 0 ? _f : new EventEmitter();
118
+ this.DZ_DRAGEND = (_h = (_g = this.component) === null || _g === void 0 ? void 0 : _g.DZ_DRAGEND) !== null && _h !== void 0 ? _h : new EventEmitter();
119
+ this.DZ_DRAGENTER = (_k = (_j = this.component) === null || _j === void 0 ? void 0 : _j.DZ_DRAGENTER) !== null && _k !== void 0 ? _k : new EventEmitter();
120
+ this.DZ_DRAGOVER = (_m = (_l = this.component) === null || _l === void 0 ? void 0 : _l.DZ_DRAGOVER) !== null && _m !== void 0 ? _m : new EventEmitter();
121
+ this.DZ_DRAGLEAVE = (_p = (_o = this.component) === null || _o === void 0 ? void 0 : _o.DZ_DRAGLEAVE) !== null && _p !== void 0 ? _p : new EventEmitter();
122
+ this.DZ_PASTE = (_r = (_q = this.component) === null || _q === void 0 ? void 0 : _q.DZ_PASTE) !== null && _r !== void 0 ? _r : new EventEmitter();
123
+ this.DZ_RESET = (_t = (_s = this.component) === null || _s === void 0 ? void 0 : _s.DZ_RESET) !== null && _t !== void 0 ? _t : new EventEmitter();
124
+ this.DZ_ADDEDFILE = (_v = (_u = this.component) === null || _u === void 0 ? void 0 : _u.DZ_ADDEDFILE) !== null && _v !== void 0 ? _v : new EventEmitter();
125
+ this.DZ_ADDEDFILES = (_x = (_w = this.component) === null || _w === void 0 ? void 0 : _w.DZ_ADDEDFILES) !== null && _x !== void 0 ? _x : new EventEmitter();
126
+ this.DZ_REMOVEDFILE = (_z = (_y = this.component) === null || _y === void 0 ? void 0 : _y.DZ_REMOVEDFILE) !== null && _z !== void 0 ? _z : new EventEmitter();
127
+ this.DZ_THUMBNAIL = (_1 = (_0 = this.component) === null || _0 === void 0 ? void 0 : _0.DZ_THUMBNAIL) !== null && _1 !== void 0 ? _1 : new EventEmitter();
128
+ this.DZ_ERROR = (_3 = (_2 = this.component) === null || _2 === void 0 ? void 0 : _2.DZ_ERROR) !== null && _3 !== void 0 ? _3 : new EventEmitter();
129
+ this.DZ_ERRORMULTIPLE = (_5 = (_4 = this.component) === null || _4 === void 0 ? void 0 : _4.DZ_ERRORMULTIPLE) !== null && _5 !== void 0 ? _5 : new EventEmitter();
130
+ this.DZ_PROCESSING = (_7 = (_6 = this.component) === null || _6 === void 0 ? void 0 : _6.DZ_PROCESSING) !== null && _7 !== void 0 ? _7 : new EventEmitter();
131
+ this.DZ_PROCESSINGMULTIPLE = (_9 = (_8 = this.component) === null || _8 === void 0 ? void 0 : _8.DZ_PROCESSINGMULTIPLE) !== null && _9 !== void 0 ? _9 : new EventEmitter();
132
+ this.DZ_UPLOADPROGRESS = (_11 = (_10 = this.component) === null || _10 === void 0 ? void 0 : _10.DZ_UPLOADPROGRESS) !== null && _11 !== void 0 ? _11 : new EventEmitter();
133
+ this.DZ_TOTALUPLOADPROGRESS = (_13 = (_12 = this.component) === null || _12 === void 0 ? void 0 : _12.DZ_TOTALUPLOADPROGRESS) !== null && _13 !== void 0 ? _13 : new EventEmitter();
134
+ this.DZ_SENDING = (_15 = (_14 = this.component) === null || _14 === void 0 ? void 0 : _14.DZ_SENDING) !== null && _15 !== void 0 ? _15 : new EventEmitter();
135
+ this.DZ_SENDINGMULTIPLE = (_17 = (_16 = this.component) === null || _16 === void 0 ? void 0 : _16.DZ_SENDINGMULTIPLE) !== null && _17 !== void 0 ? _17 : new EventEmitter();
136
+ this.DZ_SUCCESS = (_19 = (_18 = this.component) === null || _18 === void 0 ? void 0 : _18.DZ_SUCCESS) !== null && _19 !== void 0 ? _19 : new EventEmitter();
137
+ this.DZ_SUCCESSMULTIPLE = (_21 = (_20 = this.component) === null || _20 === void 0 ? void 0 : _20.DZ_SUCCESSMULTIPLE) !== null && _21 !== void 0 ? _21 : new EventEmitter();
138
+ this.DZ_CANCELED = (_23 = (_22 = this.component) === null || _22 === void 0 ? void 0 : _22.DZ_CANCELED) !== null && _23 !== void 0 ? _23 : new EventEmitter();
139
+ this.DZ_CANCELEDMULTIPLE = (_25 = (_24 = this.component) === null || _24 === void 0 ? void 0 : _24.DZ_CANCELEDMULTIPLE) !== null && _25 !== void 0 ? _25 : new EventEmitter();
140
+ this.DZ_COMPLETE = (_27 = (_26 = this.component) === null || _26 === void 0 ? void 0 : _26.DZ_COMPLETE) !== null && _27 !== void 0 ? _27 : new EventEmitter();
141
+ this.DZ_COMPLETEMULTIPLE = (_29 = (_28 = this.component) === null || _28 === void 0 ? void 0 : _28.DZ_COMPLETEMULTIPLE) !== null && _29 !== void 0 ? _29 : new EventEmitter();
142
+ this.DZ_MAXFILESEXCEEDED = (_31 = (_30 = this.component) === null || _30 === void 0 ? void 0 : _30.DZ_MAXFILESEXCEEDED) !== null && _31 !== void 0 ? _31 : new EventEmitter();
143
+ this.DZ_MAXFILESREACHED = (_33 = (_32 = this.component) === null || _32 === void 0 ? void 0 : _32.DZ_MAXFILESREACHED) !== null && _33 !== void 0 ? _33 : new EventEmitter();
144
+ this.DZ_QUEUECOMPLETE = (_35 = (_34 = this.component) === null || _34 === void 0 ? void 0 : _34.DZ_QUEUECOMPLETE) !== null && _35 !== void 0 ? _35 : new EventEmitter();
99
145
  }
146
+ /** @internal */
100
147
  ngOnInit() {
148
+ this.initInstance();
149
+ }
150
+ /** @internal */
151
+ ngOnDestroy() {
152
+ this.destroyInstance();
153
+ }
154
+ /** @internal */
155
+ ngDoCheck() {
156
+ const changes = this.configDiff.diff(this.config || {});
157
+ if (changes) {
158
+ const newParams = new _DropzoneConfig(this.defaults);
159
+ newParams.assign(this.config);
160
+ const d = this.paramDiff.diff(newParams);
161
+ if (d) {
162
+ this._params = newParams;
163
+ let hasChanges = false;
164
+ d.forEachItem(r => {
165
+ if (!internalChanges.has(r.key) && r.currentValue !== r.previousValue)
166
+ hasChanges = true;
167
+ });
168
+ if (hasChanges && this.instance) {
169
+ this.destroyInstance();
170
+ this.initInstance();
171
+ }
172
+ }
173
+ }
174
+ }
175
+ /** @internal */
176
+ reset(cancel) {
177
+ if (this.instance) {
178
+ this.zone.runOutsideAngular(() => {
179
+ this.instance.removeAllFiles(cancel);
180
+ });
181
+ }
182
+ }
183
+ initInstance() {
101
184
  if (!isPlatformBrowser(this.platformId)) {
102
185
  return;
103
186
  }
104
- const params = new DropzoneConfig(this.defaults);
105
- params.assign(this.config); // Custom configuration
106
- this.renderer.addClass(this.elementRef.nativeElement, (params.maxFiles === 1) ? 'dz-single' : 'dz-multiple');
107
- this.renderer.removeClass(this.elementRef.nativeElement, (params.maxFiles === 1) ? 'dz-multiple' : 'dz-single');
108
187
  this.zone.runOutsideAngular(() => {
109
- this.instance = new Dropzone(this.elementRef.nativeElement, params);
188
+ this.instance = new Dropzone(this.elementRef.nativeElement, this._params);
110
189
  });
111
190
  if (this.disabled) {
112
191
  this.instance.disable();
@@ -118,18 +197,21 @@ class DropzoneDirective {
118
197
  }
119
198
  // Add auto reset handling for events
120
199
  this.instance.on('success', () => {
121
- if (params.autoReset != null) {
122
- setTimeout(() => this.reset(), params.autoReset);
200
+ var _a;
201
+ if (((_a = this._params.autoReset) !== null && _a !== void 0 ? _a : -1) >= 0) {
202
+ setTimeout(() => this.reset(), this._params.autoReset);
123
203
  }
124
204
  });
125
205
  this.instance.on('error', () => {
126
- if (params.errorReset != null) {
127
- setTimeout(() => this.reset(), params.errorReset);
206
+ var _a;
207
+ if (((_a = this._params.errorReset) !== null && _a !== void 0 ? _a : -1) >= 0) {
208
+ setTimeout(() => this.reset(), this._params.errorReset);
128
209
  }
129
210
  });
130
211
  this.instance.on('canceled', () => {
131
- if (params.cancelReset != null) {
132
- setTimeout(() => this.reset(), params.cancelReset);
212
+ var _a;
213
+ if (((_a = this._params.cancelReset) !== null && _a !== void 0 ? _a : -1) >= 0) {
214
+ setTimeout(() => this.reset(), this._params.cancelReset);
133
215
  }
134
216
  });
135
217
  // Add native Dropzone event handling
@@ -145,65 +227,26 @@ class DropzoneDirective {
145
227
  }
146
228
  });
147
229
  });
148
- if (!this.configDiff) {
149
- this.configDiff = this.differs.find(this.config || {}).create();
150
- this.configDiff.diff(this.config || {});
151
- }
152
230
  }
153
- ngOnDestroy() {
231
+ destroyInstance() {
154
232
  if (this.instance) {
155
233
  this.zone.runOutsideAngular(() => {
156
234
  this.instance.destroy();
157
235
  });
158
- this.instance = null;
159
- }
160
- }
161
- ngDoCheck() {
162
- if (!this.disabled && this.configDiff) {
163
- const changes = this.configDiff.diff(this.config || {});
164
- if (changes && this.instance) {
165
- this.ngOnDestroy();
166
- this.ngOnInit();
167
- }
168
- }
169
- }
170
- ngOnChanges(changes) {
171
- if (this.instance && changes['disabled']) {
172
- if (changes['disabled'].currentValue !== changes['disabled'].previousValue) {
173
- if (changes['disabled'].currentValue === false) {
174
- this.zone.runOutsideAngular(() => {
175
- this.instance.enable();
176
- });
177
- }
178
- else if (changes['disabled'].currentValue === true) {
179
- this.zone.runOutsideAngular(() => {
180
- this.instance.disable();
181
- });
182
- }
183
- }
184
- }
185
- }
186
- dropzone() {
187
- return this.instance;
188
- }
189
- reset(cancel) {
190
- if (this.instance) {
191
- this.zone.runOutsideAngular(() => {
192
- this.instance.removeAllFiles(cancel);
193
- });
236
+ this.instance = undefined;
194
237
  }
195
238
  }
196
239
  }
197
- DropzoneDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneDirective, deps: [{ token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.KeyValueDiffers }, { token: PLATFORM_ID }, { token: NXT_DROPZONE_CONFIG, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
198
- DropzoneDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.1", type: DropzoneDirective, selector: "[nxtDropzone]", inputs: { disabled: "disabled", config: ["nxtDropzone", "config"] }, outputs: { DZ_INIT: "init", DZ_ERROR: "error", DZ_SUCCESS: "success", DZ_SENDING: "sending", DZ_CANCELED: "canceled", DZ_COMPLETE: "complete", DZ_PROCESSING: "processing", DZ_DROP: "drop", DZ_DRAGSTART: "dragStart", DZ_DRAGEND: "dragEnd", DZ_DRAGENTER: "dragEnter", DZ_DRAGOVER: "dragOver", DZ_DRAGLEAVE: "dragLeave", DZ_THUMBNAIL: "thumbnail", DZ_ADDEDFILE: "addedFile", DZ_ADDEDFILES: "addedFiles", DZ_REMOVEDFILE: "removedFile", DZ_UPLOADPROGRESS: "uploadProgress", DZ_MAXFILESREACHED: "maxFilesReached", DZ_MAXFILESEXCEEDED: "maxFilesExceeded", DZ_ERRORMULTIPLE: "errorMultiple", DZ_SUCCESSMULTIPLE: "successMultiple", DZ_SENDINGMULTIPLE: "sendingMultiple", DZ_CANCELEDMULTIPLE: "canceledMultiple", DZ_COMPLETEMULTIPLE: "completeMultiple", DZ_PROCESSINGMULTIPLE: "processingMultiple", DZ_RESET: "reset", DZ_QUEUECOMPLETE: "queueComplete", DZ_TOTALUPLOADPROGRESS: "totalUploadProgress" }, exportAs: ["nxtDropzone"], usesOnChanges: true, ngImport: i0 });
199
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneDirective, decorators: [{
240
+ DropzoneDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneDirective, deps: [{ token: i0.NgZone }, { token: i0.ElementRef }, { token: i0.KeyValueDiffers }, { token: PLATFORM_ID }, { token: NXT_DROPZONE_CONFIG, optional: true }, { token: NXT_DROPZONE_LISTENERS, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
241
+ DropzoneDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.3", type: DropzoneDirective, selector: "[nxtDropzone]", inputs: { disabled: "disabled", config: ["nxtDropzone", "config"] }, outputs: { DZ_INIT: "init", DZ_DROP: "drop", DZ_DRAGSTART: "dragStart", DZ_DRAGEND: "dragEnd", DZ_DRAGENTER: "dragEnter", DZ_DRAGOVER: "dragOver", DZ_DRAGLEAVE: "dragLeave", DZ_PASTE: "paste", DZ_RESET: "reset", DZ_ADDEDFILE: "addedFile", DZ_ADDEDFILES: "addedFiles", DZ_REMOVEDFILE: "removedFile", DZ_THUMBNAIL: "thumbnail", DZ_ERROR: "error", DZ_ERRORMULTIPLE: "errorMultiple", DZ_PROCESSING: "processing", DZ_PROCESSINGMULTIPLE: "processingMultiple", DZ_UPLOADPROGRESS: "uploadProgress", DZ_TOTALUPLOADPROGRESS: "totalUploadProgress", DZ_SENDING: "sending", DZ_SENDINGMULTIPLE: "sendingMultiple", DZ_SUCCESS: "success", DZ_SUCCESSMULTIPLE: "successMultiple", DZ_CANCELED: "canceled", DZ_CANCELEDMULTIPLE: "canceledMultiple", DZ_COMPLETE: "complete", DZ_COMPLETEMULTIPLE: "completeMultiple", DZ_MAXFILESEXCEEDED: "maxFilesExceeded", DZ_MAXFILESREACHED: "maxFilesReached", DZ_QUEUECOMPLETE: "queueComplete" }, host: { properties: { "class.dz-single": "this.isSingle", "class.dz-multiple": "this.isMultiple" } }, exportAs: ["nxtDropzone"], ngImport: i0 });
242
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneDirective, decorators: [{
200
243
  type: Directive,
201
244
  args: [{
202
245
  selector: '[nxtDropzone]',
203
246
  exportAs: 'nxtDropzone'
204
247
  }]
205
248
  }], ctorParameters: function () {
206
- return [{ type: i0.NgZone }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: i0.KeyValueDiffers }, { type: Object, decorators: [{
249
+ return [{ type: i0.NgZone }, { type: i0.ElementRef }, { type: i0.KeyValueDiffers }, { type: Object, decorators: [{
207
250
  type: Inject,
208
251
  args: [PLATFORM_ID]
209
252
  }] }, { type: undefined, decorators: [{
@@ -211,6 +254,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
211
254
  }, {
212
255
  type: Inject,
213
256
  args: [NXT_DROPZONE_CONFIG]
257
+ }] }, { type: undefined, decorators: [{
258
+ type: Optional
259
+ }, {
260
+ type: Inject,
261
+ args: [NXT_DROPZONE_LISTENERS]
214
262
  }] }];
215
263
  }, propDecorators: { disabled: [{
216
264
  type: Input
@@ -220,24 +268,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
220
268
  }], DZ_INIT: [{
221
269
  type: Output,
222
270
  args: ['init']
223
- }], DZ_ERROR: [{
224
- type: Output,
225
- args: ['error']
226
- }], DZ_SUCCESS: [{
227
- type: Output,
228
- args: ['success']
229
- }], DZ_SENDING: [{
230
- type: Output,
231
- args: ['sending']
232
- }], DZ_CANCELED: [{
233
- type: Output,
234
- args: ['canceled']
235
- }], DZ_COMPLETE: [{
236
- type: Output,
237
- args: ['complete']
238
- }], DZ_PROCESSING: [{
239
- type: Output,
240
- args: ['processing']
241
271
  }], DZ_DROP: [{
242
272
  type: Output,
243
273
  args: ['drop']
@@ -256,9 +286,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
256
286
  }], DZ_DRAGLEAVE: [{
257
287
  type: Output,
258
288
  args: ['dragLeave']
259
- }], DZ_THUMBNAIL: [{
289
+ }], DZ_PASTE: [{
260
290
  type: Output,
261
- args: ['thumbnail']
291
+ args: ['paste']
292
+ }], DZ_RESET: [{
293
+ type: Output,
294
+ args: ['reset']
262
295
  }], DZ_ADDEDFILE: [{
263
296
  type: Output,
264
297
  args: ['addedFile']
@@ -268,114 +301,130 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
268
301
  }], DZ_REMOVEDFILE: [{
269
302
  type: Output,
270
303
  args: ['removedFile']
304
+ }], DZ_THUMBNAIL: [{
305
+ type: Output,
306
+ args: ['thumbnail']
307
+ }], DZ_ERROR: [{
308
+ type: Output,
309
+ args: ['error']
310
+ }], DZ_ERRORMULTIPLE: [{
311
+ type: Output,
312
+ args: ['errorMultiple']
313
+ }], DZ_PROCESSING: [{
314
+ type: Output,
315
+ args: ['processing']
316
+ }], DZ_PROCESSINGMULTIPLE: [{
317
+ type: Output,
318
+ args: ['processingMultiple']
271
319
  }], DZ_UPLOADPROGRESS: [{
272
320
  type: Output,
273
321
  args: ['uploadProgress']
274
- }], DZ_MAXFILESREACHED: [{
322
+ }], DZ_TOTALUPLOADPROGRESS: [{
275
323
  type: Output,
276
- args: ['maxFilesReached']
277
- }], DZ_MAXFILESEXCEEDED: [{
324
+ args: ['totalUploadProgress']
325
+ }], DZ_SENDING: [{
278
326
  type: Output,
279
- args: ['maxFilesExceeded']
280
- }], DZ_ERRORMULTIPLE: [{
327
+ args: ['sending']
328
+ }], DZ_SENDINGMULTIPLE: [{
281
329
  type: Output,
282
- args: ['errorMultiple']
330
+ args: ['sendingMultiple']
331
+ }], DZ_SUCCESS: [{
332
+ type: Output,
333
+ args: ['success']
283
334
  }], DZ_SUCCESSMULTIPLE: [{
284
335
  type: Output,
285
336
  args: ['successMultiple']
286
- }], DZ_SENDINGMULTIPLE: [{
337
+ }], DZ_CANCELED: [{
287
338
  type: Output,
288
- args: ['sendingMultiple']
339
+ args: ['canceled']
289
340
  }], DZ_CANCELEDMULTIPLE: [{
290
341
  type: Output,
291
342
  args: ['canceledMultiple']
343
+ }], DZ_COMPLETE: [{
344
+ type: Output,
345
+ args: ['complete']
292
346
  }], DZ_COMPLETEMULTIPLE: [{
293
347
  type: Output,
294
348
  args: ['completeMultiple']
295
- }], DZ_PROCESSINGMULTIPLE: [{
349
+ }], DZ_MAXFILESEXCEEDED: [{
296
350
  type: Output,
297
- args: ['processingMultiple']
298
- }], DZ_RESET: [{
351
+ args: ['maxFilesExceeded']
352
+ }], DZ_MAXFILESREACHED: [{
299
353
  type: Output,
300
- args: ['reset']
354
+ args: ['maxFilesReached']
301
355
  }], DZ_QUEUECOMPLETE: [{
302
356
  type: Output,
303
357
  args: ['queueComplete']
304
- }], DZ_TOTALUPLOADPROGRESS: [{
305
- type: Output,
306
- args: ['totalUploadProgress']
358
+ }], isSingle: [{
359
+ type: HostBinding,
360
+ args: ['class.dz-single']
361
+ }], isMultiple: [{
362
+ type: HostBinding,
363
+ args: ['class.dz-multiple']
307
364
  }] } });
308
365
 
309
366
  /* eslint-disable @angular-eslint/no-output-rename */
310
367
  class DropzoneComponent {
311
- constructor(
312
- // eslint-disable-next-line @typescript-eslint/ban-types
313
- platformId) {
314
- this.platformId = platformId;
368
+ constructor() {
369
+ /** Disables / detaches Dropzone from the element */
315
370
  this.disabled = false;
371
+ /** Message to show for the user on the upload area */
316
372
  this.message = 'Click or drag files to upload';
373
+ /** Placeholder image to be shown as the upload area */
317
374
  this.placeholder = '';
375
+ /** Use 'dropzone' class (use provided default styles) */
318
376
  this.useDropzoneClass = true;
319
377
  this.DZ_INIT = new EventEmitter();
320
- this.DZ_ERROR = new EventEmitter();
321
- this.DZ_SUCCESS = new EventEmitter();
322
- this.DZ_SENDING = new EventEmitter();
323
- this.DZ_CANCELED = new EventEmitter();
324
- this.DZ_COMPLETE = new EventEmitter();
325
- this.DZ_PROCESSING = new EventEmitter();
326
378
  this.DZ_DROP = new EventEmitter();
327
379
  this.DZ_DRAGSTART = new EventEmitter();
328
380
  this.DZ_DRAGEND = new EventEmitter();
329
381
  this.DZ_DRAGENTER = new EventEmitter();
330
382
  this.DZ_DRAGOVER = new EventEmitter();
331
383
  this.DZ_DRAGLEAVE = new EventEmitter();
332
- this.DZ_THUMBNAIL = new EventEmitter();
384
+ this.DZ_PASTE = new EventEmitter();
385
+ this.DZ_RESET = new EventEmitter();
333
386
  this.DZ_ADDEDFILE = new EventEmitter();
334
387
  this.DZ_ADDEDFILES = new EventEmitter();
335
388
  this.DZ_REMOVEDFILE = new EventEmitter();
336
- this.DZ_UPLOADPROGRESS = new EventEmitter();
337
- this.DZ_MAXFILESREACHED = new EventEmitter();
338
- this.DZ_MAXFILESEXCEEDED = new EventEmitter();
389
+ this.DZ_THUMBNAIL = new EventEmitter();
390
+ this.DZ_ERROR = new EventEmitter();
339
391
  this.DZ_ERRORMULTIPLE = new EventEmitter();
340
- this.DZ_SUCCESSMULTIPLE = new EventEmitter();
392
+ this.DZ_PROCESSING = new EventEmitter();
393
+ this.DZ_PROCESSINGMULTIPLE = new EventEmitter();
394
+ this.DZ_UPLOADPROGRESS = new EventEmitter();
395
+ this.DZ_TOTALUPLOADPROGRESS = new EventEmitter();
396
+ this.DZ_SENDING = new EventEmitter();
341
397
  this.DZ_SENDINGMULTIPLE = new EventEmitter();
398
+ // eslint-disable-next-line @typescript-eslint/ban-types
399
+ this.DZ_SUCCESS = new EventEmitter();
400
+ this.DZ_SUCCESSMULTIPLE = new EventEmitter();
401
+ this.DZ_CANCELED = new EventEmitter();
342
402
  this.DZ_CANCELEDMULTIPLE = new EventEmitter();
403
+ this.DZ_COMPLETE = new EventEmitter();
343
404
  this.DZ_COMPLETEMULTIPLE = new EventEmitter();
344
- this.DZ_PROCESSINGMULTIPLE = new EventEmitter();
345
- this.DZ_RESET = new EventEmitter();
405
+ this.DZ_MAXFILESEXCEEDED = new EventEmitter();
406
+ this.DZ_MAXFILESREACHED = new EventEmitter();
346
407
  this.DZ_QUEUECOMPLETE = new EventEmitter();
347
- this.DZ_TOTALUPLOADPROGRESS = new EventEmitter();
348
- }
349
- ngOnInit() {
350
- if (!isPlatformBrowser(this.platformId)) {
351
- return;
352
- }
353
- setTimeout(() => {
354
- DropzoneEvents.forEach((eventName) => {
355
- if (this.directiveRef) {
356
- const output = `DZ_${eventName.toUpperCase()}`;
357
- const directiveOutput = output;
358
- const componentOutput = output;
359
- this.directiveRef[directiveOutput] = this[componentOutput];
360
- }
361
- });
362
- }, 0);
363
408
  }
409
+ /** @internal */
410
+ ngOnInit() { }
411
+ /** @internal */
364
412
  getPlaceholder() {
365
413
  return 'url(' + encodeURI(this.placeholder) + ')';
366
414
  }
367
415
  }
368
- DropzoneComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneComponent, deps: [{ token: PLATFORM_ID }], target: i0.ɵɵFactoryTarget.Component });
369
- DropzoneComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.1", type: DropzoneComponent, selector: "nxt-dropzone", inputs: { disabled: "disabled", config: "config", message: "message", placeholder: "placeholder", useDropzoneClass: "useDropzoneClass" }, outputs: { DZ_INIT: "init", DZ_ERROR: "error", DZ_SUCCESS: "success", DZ_SENDING: "sending", DZ_CANCELED: "canceled", DZ_COMPLETE: "complete", DZ_PROCESSING: "processing", DZ_DROP: "drop", DZ_DRAGSTART: "dragStart", DZ_DRAGEND: "dragEnd", DZ_DRAGENTER: "dragEnter", DZ_DRAGOVER: "dragOver", DZ_DRAGLEAVE: "dragLeave", DZ_THUMBNAIL: "thumbnail", DZ_ADDEDFILE: "addedFile", DZ_ADDEDFILES: "addedFiles", DZ_REMOVEDFILE: "removedFile", DZ_UPLOADPROGRESS: "uploadProgress", DZ_MAXFILESREACHED: "maxFilesReached", DZ_MAXFILESEXCEEDED: "maxFilesExceeded", DZ_ERRORMULTIPLE: "errorMultiple", DZ_SUCCESSMULTIPLE: "successMultiple", DZ_SENDINGMULTIPLE: "sendingMultiple", DZ_CANCELEDMULTIPLE: "canceledMultiple", DZ_COMPLETEMULTIPLE: "completeMultiple", DZ_PROCESSINGMULTIPLE: "processingMultiple", DZ_RESET: "reset", DZ_QUEUECOMPLETE: "queueComplete", DZ_TOTALUPLOADPROGRESS: "totalUploadProgress" }, viewQueries: [{ propertyName: "directiveRef", first: true, predicate: DropzoneDirective, descendants: true, static: true }], exportAs: ["nxtDropzone"], ngImport: i0, template: "<div class=\"dz-wrapper\"\n [class.dropzone]=\"useDropzoneClass\"\n [nxtDropzone]=\"config\"\n [disabled]=\"disabled\"\n (init)=\"DZ_INIT.emit($event)\">\n <div class=\"dz-message\"\n [class.disabled]=\"disabled\"\n [class.dz-placeholder]=\"placeholder\">\n <div class=\"dz-text\"\n [innerHTML]=\"config?.dictDefaultMessage || message\"></div>\n\n <div *ngIf=\"placeholder\"\n class=\"dz-image\"\n [style.background-image]=\"getPlaceholder()\"></div>\n </div>\n\n <ng-content></ng-content>\n</div>\n", styles: ["nxt-dropzone{display:block;width:100%;height:auto}nxt-dropzone>.dropzone.dz-wrapper{position:relative;overflow:auto;width:100%;min-height:0;max-height:100%;padding:0;border:none;color:#666;background:transparent}nxt-dropzone>.dropzone.dz-wrapper .dz-message{position:relative;display:inline-block;overflow:auto;width:calc(100% - 16px);min-width:calc(100% - 16px);min-height:40px;max-width:calc(100% - 16px);max-height:100%;margin:8px;border:2px dashed #aaa;background-color:#eee}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-text{position:absolute;top:50%;width:100%;padding:8px 16px;text-align:center;transform:translateY(-50%)}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-image{width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50% 50%}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled{cursor:not-allowed}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled .dz-text{opacity:.5}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder{border-color:#aaa0}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder .dz-text{position:absolute;z-index:1;top:0;right:10%;left:10%;opacity:0;font-weight:700;background-color:#ffffff80;transform:translateY(-50%);transition:filter .25s ease-in-out,opacity .25s ease-in-out,border-color .25s ease-in-out}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled){border-color:#aaa}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-text{opacity:1}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-image{filter:blur(8px)}nxt-dropzone>.dropzone.dz-wrapper .dz-preview{margin:8px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-details{padding:24px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress{width:80%;margin-left:-40%;border:1px solid #aaa;border-radius:4px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress .dz-upload{background-color:#666}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span{display:block;overflow:hidden;width:100%;max-width:100%;text-overflow:ellipsis}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span:hover{overflow:visible;white-space:normal;word-wrap:break-word}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-message{width:100%;height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview{width:calc(100% - 16px);height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image{width:100%;height:100%;border-radius:0}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image img{display:block;width:100%;height:auto;margin:0}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-error-message{top:50%;left:50%;transform:translate(-50%) translateY(100%)}nxt-dropzone>.dropzone.dz-wrapper.dz-single.dz-started .dz-message{display:none}nxt-dropzone>.dropzone.dz-wrapper.dz-multiple.dz-started .dz-message{display:inline-block}nxt-dropzone[fxflex]{display:flex;flex-direction:inherit;min-width:0;min-height:0}nxt-dropzone[fxflex]>.dropzone.dz-wrapper{flex:1 1 auto;min-width:0;min-height:0}nxt-dropzone[fxlayout]{align-items:inherit;align-content:inherit;justify-content:inherit}nxt-dropzone[fxlayout]>.dropzone.dz-wrapper.dz-single{display:flex;flex-direction:column;align-items:center;align-content:center;justify-content:center}nxt-dropzone[fxlayout]>.dropzone.dz-wrapper.dz-multiple{display:flex;flex-flow:row wrap;align-items:flex-start;align-content:flex-start;justify-content:space-between}\n", "@keyframes passing-through{0%{opacity:0;transform:translateY(40px)}30%,70%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-40px)}}@keyframes slide-in{0%{opacity:0;transform:translateY(40px)}30%{opacity:1;transform:translateY(0)}}@keyframes pulse{0%{transform:scale(1)}10%{transform:scale(1.1)}20%{transform:scale(1)}}.dropzone,.dropzone *{box-sizing:border-box}.dropzone{min-height:150px;border:1px solid rgba(0,0,0,.8);border-radius:5px;padding:20px}.dropzone.dz-clickable{cursor:pointer}.dropzone.dz-clickable *{cursor:default}.dropzone.dz-clickable .dz-message,.dropzone.dz-clickable .dz-message *{cursor:pointer}.dropzone.dz-started .dz-message{display:none}.dropzone.dz-drag-hover{border-style:solid}.dropzone.dz-drag-hover .dz-message{opacity:.5}.dropzone .dz-message{text-align:center;margin:3em 0}.dropzone .dz-message .dz-button{background:none;color:inherit;border:none;padding:0;font:inherit;cursor:pointer;outline:inherit}.dropzone .dz-preview{position:relative;display:inline-block;vertical-align:top;margin:16px;min-height:100px}.dropzone .dz-preview:hover{z-index:1000}.dropzone .dz-preview.dz-file-preview .dz-image{border-radius:20px;background:#999;background:linear-gradient(to bottom,#eee,#ddd)}.dropzone .dz-preview.dz-file-preview .dz-details{opacity:1}.dropzone .dz-preview.dz-image-preview{background:#fff}.dropzone .dz-preview.dz-image-preview .dz-details{transition:opacity .2s linear}.dropzone .dz-preview .dz-remove{font-size:14px;text-align:center;display:block;cursor:pointer;border:none}.dropzone .dz-preview .dz-remove:hover{text-decoration:underline}.dropzone .dz-preview:hover .dz-details{opacity:1}.dropzone .dz-preview .dz-details{z-index:20;position:absolute;top:0;left:0;opacity:0;font-size:13px;min-width:100%;max-width:100%;padding:2em 1em;text-align:center;color:#000000e6;line-height:150%}.dropzone .dz-preview .dz-details .dz-size{margin-bottom:1em;font-size:16px}.dropzone .dz-preview .dz-details .dz-filename{white-space:nowrap}.dropzone .dz-preview .dz-details .dz-filename:hover span{border:1px solid rgba(200,200,200,.8);background-color:#fffc}.dropzone .dz-preview .dz-details .dz-filename:not(:hover){overflow:hidden;text-overflow:ellipsis}.dropzone .dz-preview .dz-details .dz-filename:not(:hover) span{border:1px solid transparent}.dropzone .dz-preview .dz-details .dz-filename span,.dropzone .dz-preview .dz-details .dz-size span{background-color:#fff6;padding:0 .4em;border-radius:3px}.dropzone .dz-preview:hover .dz-image img{transform:scale(1.05);filter:blur(8px)}.dropzone .dz-preview .dz-image{border-radius:20px;overflow:hidden;width:120px;height:120px;position:relative;display:block;z-index:10}.dropzone .dz-preview .dz-image img{display:block}.dropzone .dz-preview.dz-success .dz-success-mark{animation:passing-through 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview.dz-error .dz-error-mark{opacity:1;animation:slide-in 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview .dz-success-mark,.dropzone .dz-preview .dz-error-mark{pointer-events:none;opacity:0;z-index:500;position:absolute;display:block;top:50%;left:50%;margin-left:-27px;margin-top:-27px;background:rgba(0,0,0,.8);border-radius:50%}.dropzone .dz-preview .dz-success-mark svg,.dropzone .dz-preview .dz-error-mark svg{display:block;width:54px;height:54px;fill:#fff}.dropzone .dz-preview.dz-processing .dz-progress{opacity:1;transition:all .2s linear}.dropzone .dz-preview.dz-complete .dz-progress{opacity:0;transition:opacity .4s ease-in}.dropzone .dz-preview:not(.dz-processing) .dz-progress{animation:pulse 6s ease infinite}.dropzone .dz-preview .dz-progress{opacity:1;z-index:1000;pointer-events:none;position:absolute;height:20px;top:50%;margin-top:-10px;left:15%;right:15%;border:3px solid rgba(0,0,0,.8);background:rgba(0,0,0,.8);border-radius:10px;overflow:hidden}.dropzone .dz-preview .dz-progress .dz-upload{background:#fff;display:block;position:relative;height:100%;width:0;transition:width .3s ease-in-out;border-radius:17px}.dropzone .dz-preview.dz-error .dz-error-message{display:block}.dropzone .dz-preview.dz-error:hover .dz-error-message{opacity:1;pointer-events:auto}.dropzone .dz-preview .dz-error-message{pointer-events:none;z-index:1000;position:absolute;display:block;display:none;opacity:0;transition:opacity .3s ease;border-radius:8px;font-size:13px;top:130px;left:-10px;width:140px;background:#b10606;padding:.5em 1em;color:#fff}.dropzone .dz-preview .dz-error-message:after{content:\"\";position:absolute;top:-6px;left:64px;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #b10606}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: DropzoneDirective, selector: "[nxtDropzone]", inputs: ["disabled", "nxtDropzone"], outputs: ["init", "error", "success", "sending", "canceled", "complete", "processing", "drop", "dragStart", "dragEnd", "dragEnter", "dragOver", "dragLeave", "thumbnail", "addedFile", "addedFiles", "removedFile", "uploadProgress", "maxFilesReached", "maxFilesExceeded", "errorMultiple", "successMultiple", "sendingMultiple", "canceledMultiple", "completeMultiple", "processingMultiple", "reset", "queueComplete", "totalUploadProgress"], exportAs: ["nxtDropzone"] }], encapsulation: i0.ViewEncapsulation.None });
370
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneComponent, decorators: [{
416
+ DropzoneComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
417
+ DropzoneComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.3", type: DropzoneComponent, selector: "nxt-dropzone", inputs: { disabled: "disabled", config: "config", message: "message", placeholder: "placeholder", useDropzoneClass: "useDropzoneClass" }, outputs: { DZ_INIT: "init", DZ_DROP: "drop", DZ_DRAGSTART: "dragStart", DZ_DRAGEND: "dragEnd", DZ_DRAGENTER: "dragEnter", DZ_DRAGOVER: "dragOver", DZ_DRAGLEAVE: "dragLeave", DZ_PASTE: "paste", DZ_RESET: "reset", DZ_ADDEDFILE: "addedFile", DZ_ADDEDFILES: "addedFiles", DZ_REMOVEDFILE: "removedFile", DZ_THUMBNAIL: "thumbnail", DZ_ERROR: "error", DZ_ERRORMULTIPLE: "errorMultiple", DZ_PROCESSING: "processing", DZ_PROCESSINGMULTIPLE: "processingMultiple", DZ_UPLOADPROGRESS: "uploadProgress", DZ_TOTALUPLOADPROGRESS: "totalUploadProgress", DZ_SENDING: "sending", DZ_SENDINGMULTIPLE: "sendingMultiple", DZ_SUCCESS: "success", DZ_SUCCESSMULTIPLE: "successMultiple", DZ_CANCELED: "canceled", DZ_CANCELEDMULTIPLE: "canceledMultiple", DZ_COMPLETE: "complete", DZ_COMPLETEMULTIPLE: "completeMultiple", DZ_MAXFILESEXCEEDED: "maxFilesExceeded", DZ_MAXFILESREACHED: "maxFilesReached", DZ_QUEUECOMPLETE: "queueComplete" }, providers: [{
418
+ provide: NXT_DROPZONE_LISTENERS,
419
+ useValue: forwardRef(() => DropzoneComponent)
420
+ }], viewQueries: [{ propertyName: "directiveRef", first: true, predicate: DropzoneDirective, descendants: true }], ngImport: i0, template: "<div class=\"dz-wrapper\"\n [class.dropzone]=\"useDropzoneClass\"\n [nxtDropzone]=\"config\"\n [disabled]=\"disabled\">\n <div class=\"dz-message\"\n [class.disabled]=\"disabled\"\n [class.dz-placeholder]=\"placeholder\">\n <div class=\"dz-text\"\n [innerHTML]=\"config?.dictDefaultMessage || message\"></div>\n\n <div *ngIf=\"placeholder\"\n class=\"dz-image\"\n [style.background-image]=\"getPlaceholder()\"></div>\n </div>\n\n <ng-content></ng-content>\n</div>\n", styles: ["nxt-dropzone{display:flex;width:100%;height:auto}nxt-dropzone>.dropzone.dz-wrapper{overflow:auto;width:100%;min-height:0;max-height:100%;padding:0;border:none;color:#666;background:transparent;border-radius:0;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:16px}nxt-dropzone>.dropzone.dz-wrapper .dz-message{overflow:auto;min-height:60px;max-height:100%;border:2px dashed #aaa;background-color:#eee;display:flex;align-items:center;justify-content:center;margin:0;border-radius:5px;grid-column:span 2;grid-row:span 2}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-text{padding:8px 16px;text-align:center}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-image{width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50% 50%}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled{cursor:not-allowed}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled .dz-text{opacity:.5}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder{position:relative;border-color:#aaa0;transition:border-color .25s ease-in-out}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder .dz-text{position:absolute;z-index:1;opacity:0;font-weight:700;background-color:#ffffff80;transition:filter .25s ease-in-out,opacity .25s ease-in-out}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled){border-color:#aaa}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-text{opacity:1}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-image{filter:blur(8px)}nxt-dropzone>.dropzone.dz-wrapper .dz-preview{margin:0}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-details{padding:24px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress{width:80%;border:1px solid #aaa;border-radius:5px;overflow:hidden}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress .dz-upload{background-color:#666}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span{display:block;overflow:hidden;width:100%;max-width:100%;text-overflow:ellipsis}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span:hover{overflow:visible;white-space:normal;word-wrap:break-word}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-image{border-radius:5px;overflow:hidden;min-width:120px;min-height:120px;width:auto;height:auto}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-message{width:100%;height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview{width:100%;height:100%;grid-column:span 2;grid-row:span 2}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image{width:100%;height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image img{display:block;width:100%;height:auto;margin:0}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-error-message{top:50%;left:50%;transform:translate(-50%) translateY(100%)}nxt-dropzone>.dropzone.dz-wrapper.dz-single.dz-started .dz-message{display:none}nxt-dropzone>.dropzone.dz-wrapper.dz-multiple.dz-started .dz-message{display:flex}\n", "@keyframes passing-through{0%{opacity:0;transform:translateY(40px)}30%,70%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-40px)}}@keyframes slide-in{0%{opacity:0;transform:translateY(40px)}30%{opacity:1;transform:translateY(0)}}@keyframes pulse{0%{transform:scale(1)}10%{transform:scale(1.1)}20%{transform:scale(1)}}.dropzone,.dropzone *{box-sizing:border-box}.dropzone{min-height:150px;border:1px solid rgba(0,0,0,.8);border-radius:5px;padding:20px}.dropzone.dz-clickable{cursor:pointer}.dropzone.dz-clickable *{cursor:default}.dropzone.dz-clickable .dz-message,.dropzone.dz-clickable .dz-message *{cursor:pointer}.dropzone.dz-started .dz-message{display:none}.dropzone.dz-drag-hover{border-style:solid}.dropzone.dz-drag-hover .dz-message{opacity:.5}.dropzone .dz-message{text-align:center;margin:3em 0}.dropzone .dz-message .dz-button{background:none;color:inherit;border:none;padding:0;font:inherit;cursor:pointer;outline:inherit}.dropzone .dz-preview{position:relative;display:inline-block;vertical-align:top;margin:16px;min-height:100px}.dropzone .dz-preview:hover{z-index:1000}.dropzone .dz-preview.dz-file-preview .dz-image{border-radius:20px;background:#999;background:linear-gradient(to bottom,#eee,#ddd)}.dropzone .dz-preview.dz-file-preview .dz-details{opacity:1}.dropzone .dz-preview.dz-image-preview{background:#fff}.dropzone .dz-preview.dz-image-preview .dz-details{transition:opacity .2s linear}.dropzone .dz-preview .dz-remove{font-size:14px;text-align:center;display:block;cursor:pointer;border:none}.dropzone .dz-preview .dz-remove:hover{text-decoration:underline}.dropzone .dz-preview:hover .dz-details{opacity:1}.dropzone .dz-preview .dz-details{z-index:20;position:absolute;top:0;left:0;opacity:0;font-size:13px;min-width:100%;max-width:100%;padding:2em 1em;text-align:center;color:#000000e6;line-height:150%}.dropzone .dz-preview .dz-details .dz-size{margin-bottom:1em;font-size:16px}.dropzone .dz-preview .dz-details .dz-filename{white-space:nowrap}.dropzone .dz-preview .dz-details .dz-filename:hover span{border:1px solid rgba(200,200,200,.8);background-color:#fffc}.dropzone .dz-preview .dz-details .dz-filename:not(:hover){overflow:hidden;text-overflow:ellipsis}.dropzone .dz-preview .dz-details .dz-filename:not(:hover) span{border:1px solid transparent}.dropzone .dz-preview .dz-details .dz-filename span,.dropzone .dz-preview .dz-details .dz-size span{background-color:#fff6;padding:0 .4em;border-radius:3px}.dropzone .dz-preview:hover .dz-image img{transform:scale(1.05);filter:blur(8px)}.dropzone .dz-preview .dz-image{border-radius:20px;overflow:hidden;width:120px;height:120px;position:relative;display:block;z-index:10}.dropzone .dz-preview .dz-image img{display:block}.dropzone .dz-preview.dz-success .dz-success-mark{animation:passing-through 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview.dz-error .dz-error-mark{opacity:1;animation:slide-in 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview .dz-success-mark,.dropzone .dz-preview .dz-error-mark{pointer-events:none;opacity:0;z-index:500;position:absolute;display:block;top:50%;left:50%;margin-left:-27px;margin-top:-27px;background:rgba(0,0,0,.8);border-radius:50%}.dropzone .dz-preview .dz-success-mark svg,.dropzone .dz-preview .dz-error-mark svg{display:block;width:54px;height:54px;fill:#fff}.dropzone .dz-preview.dz-processing .dz-progress{opacity:1;transition:all .2s linear}.dropzone .dz-preview.dz-complete .dz-progress{opacity:0;transition:opacity .4s ease-in}.dropzone .dz-preview:not(.dz-processing) .dz-progress{animation:pulse 6s ease infinite}.dropzone .dz-preview .dz-progress{opacity:1;z-index:1000;pointer-events:none;position:absolute;height:20px;top:50%;margin-top:-10px;left:15%;right:15%;border:3px solid rgba(0,0,0,.8);background:rgba(0,0,0,.8);border-radius:10px;overflow:hidden}.dropzone .dz-preview .dz-progress .dz-upload{background:#fff;display:block;position:relative;height:100%;width:0;transition:width .3s ease-in-out;border-radius:17px}.dropzone .dz-preview.dz-error .dz-error-message{display:block}.dropzone .dz-preview.dz-error:hover .dz-error-message{opacity:1;pointer-events:auto}.dropzone .dz-preview .dz-error-message{pointer-events:none;z-index:1000;position:absolute;display:block;display:none;opacity:0;transition:opacity .3s ease;border-radius:8px;font-size:13px;top:130px;left:-10px;width:140px;background:#b10606;padding:.5em 1em;color:#fff}.dropzone .dz-preview .dz-error-message:after{content:\"\";position:absolute;top:-6px;left:64px;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #b10606}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: DropzoneDirective, selector: "[nxtDropzone]", inputs: ["disabled", "nxtDropzone"], outputs: ["init", "drop", "dragStart", "dragEnd", "dragEnter", "dragOver", "dragLeave", "paste", "reset", "addedFile", "addedFiles", "removedFile", "thumbnail", "error", "errorMultiple", "processing", "processingMultiple", "uploadProgress", "totalUploadProgress", "sending", "sendingMultiple", "success", "successMultiple", "canceled", "canceledMultiple", "complete", "completeMultiple", "maxFilesExceeded", "maxFilesReached", "queueComplete"], exportAs: ["nxtDropzone"] }], encapsulation: i0.ViewEncapsulation.None });
421
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneComponent, decorators: [{
371
422
  type: Component,
372
- args: [{ selector: 'nxt-dropzone', exportAs: 'nxtDropzone', encapsulation: ViewEncapsulation.None, template: "<div class=\"dz-wrapper\"\n [class.dropzone]=\"useDropzoneClass\"\n [nxtDropzone]=\"config\"\n [disabled]=\"disabled\"\n (init)=\"DZ_INIT.emit($event)\">\n <div class=\"dz-message\"\n [class.disabled]=\"disabled\"\n [class.dz-placeholder]=\"placeholder\">\n <div class=\"dz-text\"\n [innerHTML]=\"config?.dictDefaultMessage || message\"></div>\n\n <div *ngIf=\"placeholder\"\n class=\"dz-image\"\n [style.background-image]=\"getPlaceholder()\"></div>\n </div>\n\n <ng-content></ng-content>\n</div>\n", styles: ["nxt-dropzone{display:block;width:100%;height:auto}nxt-dropzone>.dropzone.dz-wrapper{position:relative;overflow:auto;width:100%;min-height:0;max-height:100%;padding:0;border:none;color:#666;background:transparent}nxt-dropzone>.dropzone.dz-wrapper .dz-message{position:relative;display:inline-block;overflow:auto;width:calc(100% - 16px);min-width:calc(100% - 16px);min-height:40px;max-width:calc(100% - 16px);max-height:100%;margin:8px;border:2px dashed #aaa;background-color:#eee}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-text{position:absolute;top:50%;width:100%;padding:8px 16px;text-align:center;transform:translateY(-50%)}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-image{width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50% 50%}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled{cursor:not-allowed}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled .dz-text{opacity:.5}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder{border-color:#aaa0}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder .dz-text{position:absolute;z-index:1;top:0;right:10%;left:10%;opacity:0;font-weight:700;background-color:#ffffff80;transform:translateY(-50%);transition:filter .25s ease-in-out,opacity .25s ease-in-out,border-color .25s ease-in-out}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled){border-color:#aaa}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-text{opacity:1}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-image{filter:blur(8px)}nxt-dropzone>.dropzone.dz-wrapper .dz-preview{margin:8px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-details{padding:24px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress{width:80%;margin-left:-40%;border:1px solid #aaa;border-radius:4px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress .dz-upload{background-color:#666}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span{display:block;overflow:hidden;width:100%;max-width:100%;text-overflow:ellipsis}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span:hover{overflow:visible;white-space:normal;word-wrap:break-word}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-message{width:100%;height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview{width:calc(100% - 16px);height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image{width:100%;height:100%;border-radius:0}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image img{display:block;width:100%;height:auto;margin:0}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-error-message{top:50%;left:50%;transform:translate(-50%) translateY(100%)}nxt-dropzone>.dropzone.dz-wrapper.dz-single.dz-started .dz-message{display:none}nxt-dropzone>.dropzone.dz-wrapper.dz-multiple.dz-started .dz-message{display:inline-block}nxt-dropzone[fxflex]{display:flex;flex-direction:inherit;min-width:0;min-height:0}nxt-dropzone[fxflex]>.dropzone.dz-wrapper{flex:1 1 auto;min-width:0;min-height:0}nxt-dropzone[fxlayout]{align-items:inherit;align-content:inherit;justify-content:inherit}nxt-dropzone[fxlayout]>.dropzone.dz-wrapper.dz-single{display:flex;flex-direction:column;align-items:center;align-content:center;justify-content:center}nxt-dropzone[fxlayout]>.dropzone.dz-wrapper.dz-multiple{display:flex;flex-flow:row wrap;align-items:flex-start;align-content:flex-start;justify-content:space-between}\n", "@keyframes passing-through{0%{opacity:0;transform:translateY(40px)}30%,70%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-40px)}}@keyframes slide-in{0%{opacity:0;transform:translateY(40px)}30%{opacity:1;transform:translateY(0)}}@keyframes pulse{0%{transform:scale(1)}10%{transform:scale(1.1)}20%{transform:scale(1)}}.dropzone,.dropzone *{box-sizing:border-box}.dropzone{min-height:150px;border:1px solid rgba(0,0,0,.8);border-radius:5px;padding:20px}.dropzone.dz-clickable{cursor:pointer}.dropzone.dz-clickable *{cursor:default}.dropzone.dz-clickable .dz-message,.dropzone.dz-clickable .dz-message *{cursor:pointer}.dropzone.dz-started .dz-message{display:none}.dropzone.dz-drag-hover{border-style:solid}.dropzone.dz-drag-hover .dz-message{opacity:.5}.dropzone .dz-message{text-align:center;margin:3em 0}.dropzone .dz-message .dz-button{background:none;color:inherit;border:none;padding:0;font:inherit;cursor:pointer;outline:inherit}.dropzone .dz-preview{position:relative;display:inline-block;vertical-align:top;margin:16px;min-height:100px}.dropzone .dz-preview:hover{z-index:1000}.dropzone .dz-preview.dz-file-preview .dz-image{border-radius:20px;background:#999;background:linear-gradient(to bottom,#eee,#ddd)}.dropzone .dz-preview.dz-file-preview .dz-details{opacity:1}.dropzone .dz-preview.dz-image-preview{background:#fff}.dropzone .dz-preview.dz-image-preview .dz-details{transition:opacity .2s linear}.dropzone .dz-preview .dz-remove{font-size:14px;text-align:center;display:block;cursor:pointer;border:none}.dropzone .dz-preview .dz-remove:hover{text-decoration:underline}.dropzone .dz-preview:hover .dz-details{opacity:1}.dropzone .dz-preview .dz-details{z-index:20;position:absolute;top:0;left:0;opacity:0;font-size:13px;min-width:100%;max-width:100%;padding:2em 1em;text-align:center;color:#000000e6;line-height:150%}.dropzone .dz-preview .dz-details .dz-size{margin-bottom:1em;font-size:16px}.dropzone .dz-preview .dz-details .dz-filename{white-space:nowrap}.dropzone .dz-preview .dz-details .dz-filename:hover span{border:1px solid rgba(200,200,200,.8);background-color:#fffc}.dropzone .dz-preview .dz-details .dz-filename:not(:hover){overflow:hidden;text-overflow:ellipsis}.dropzone .dz-preview .dz-details .dz-filename:not(:hover) span{border:1px solid transparent}.dropzone .dz-preview .dz-details .dz-filename span,.dropzone .dz-preview .dz-details .dz-size span{background-color:#fff6;padding:0 .4em;border-radius:3px}.dropzone .dz-preview:hover .dz-image img{transform:scale(1.05);filter:blur(8px)}.dropzone .dz-preview .dz-image{border-radius:20px;overflow:hidden;width:120px;height:120px;position:relative;display:block;z-index:10}.dropzone .dz-preview .dz-image img{display:block}.dropzone .dz-preview.dz-success .dz-success-mark{animation:passing-through 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview.dz-error .dz-error-mark{opacity:1;animation:slide-in 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview .dz-success-mark,.dropzone .dz-preview .dz-error-mark{pointer-events:none;opacity:0;z-index:500;position:absolute;display:block;top:50%;left:50%;margin-left:-27px;margin-top:-27px;background:rgba(0,0,0,.8);border-radius:50%}.dropzone .dz-preview .dz-success-mark svg,.dropzone .dz-preview .dz-error-mark svg{display:block;width:54px;height:54px;fill:#fff}.dropzone .dz-preview.dz-processing .dz-progress{opacity:1;transition:all .2s linear}.dropzone .dz-preview.dz-complete .dz-progress{opacity:0;transition:opacity .4s ease-in}.dropzone .dz-preview:not(.dz-processing) .dz-progress{animation:pulse 6s ease infinite}.dropzone .dz-preview .dz-progress{opacity:1;z-index:1000;pointer-events:none;position:absolute;height:20px;top:50%;margin-top:-10px;left:15%;right:15%;border:3px solid rgba(0,0,0,.8);background:rgba(0,0,0,.8);border-radius:10px;overflow:hidden}.dropzone .dz-preview .dz-progress .dz-upload{background:#fff;display:block;position:relative;height:100%;width:0;transition:width .3s ease-in-out;border-radius:17px}.dropzone .dz-preview.dz-error .dz-error-message{display:block}.dropzone .dz-preview.dz-error:hover .dz-error-message{opacity:1;pointer-events:auto}.dropzone .dz-preview .dz-error-message{pointer-events:none;z-index:1000;position:absolute;display:block;display:none;opacity:0;transition:opacity .3s ease;border-radius:8px;font-size:13px;top:130px;left:-10px;width:140px;background:#b10606;padding:.5em 1em;color:#fff}.dropzone .dz-preview .dz-error-message:after{content:\"\";position:absolute;top:-6px;left:64px;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #b10606}\n"] }]
373
- }], ctorParameters: function () {
374
- return [{ type: Object, decorators: [{
375
- type: Inject,
376
- args: [PLATFORM_ID]
377
- }] }];
378
- }, propDecorators: { disabled: [{
423
+ args: [{ selector: 'nxt-dropzone', encapsulation: ViewEncapsulation.None, providers: [{
424
+ provide: NXT_DROPZONE_LISTENERS,
425
+ useValue: forwardRef(() => DropzoneComponent)
426
+ }], template: "<div class=\"dz-wrapper\"\n [class.dropzone]=\"useDropzoneClass\"\n [nxtDropzone]=\"config\"\n [disabled]=\"disabled\">\n <div class=\"dz-message\"\n [class.disabled]=\"disabled\"\n [class.dz-placeholder]=\"placeholder\">\n <div class=\"dz-text\"\n [innerHTML]=\"config?.dictDefaultMessage || message\"></div>\n\n <div *ngIf=\"placeholder\"\n class=\"dz-image\"\n [style.background-image]=\"getPlaceholder()\"></div>\n </div>\n\n <ng-content></ng-content>\n</div>\n", styles: ["nxt-dropzone{display:flex;width:100%;height:auto}nxt-dropzone>.dropzone.dz-wrapper{overflow:auto;width:100%;min-height:0;max-height:100%;padding:0;border:none;color:#666;background:transparent;border-radius:0;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:16px}nxt-dropzone>.dropzone.dz-wrapper .dz-message{overflow:auto;min-height:60px;max-height:100%;border:2px dashed #aaa;background-color:#eee;display:flex;align-items:center;justify-content:center;margin:0;border-radius:5px;grid-column:span 2;grid-row:span 2}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-text{padding:8px 16px;text-align:center}nxt-dropzone>.dropzone.dz-wrapper .dz-message .dz-image{width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50% 50%}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled{cursor:not-allowed}nxt-dropzone>.dropzone.dz-wrapper .dz-message.disabled .dz-text{opacity:.5}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder{position:relative;border-color:#aaa0;transition:border-color .25s ease-in-out}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder .dz-text{position:absolute;z-index:1;opacity:0;font-weight:700;background-color:#ffffff80;transition:filter .25s ease-in-out,opacity .25s ease-in-out}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled){border-color:#aaa}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-text{opacity:1}nxt-dropzone>.dropzone.dz-wrapper .dz-message.dz-placeholder:hover:not(.disabled) .dz-image{filter:blur(8px)}nxt-dropzone>.dropzone.dz-wrapper .dz-preview{margin:0}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-details{padding:24px}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress{width:80%;border:1px solid #aaa;border-radius:5px;overflow:hidden}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-progress .dz-upload{background-color:#666}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span{display:block;overflow:hidden;width:100%;max-width:100%;text-overflow:ellipsis}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-filename span:hover{overflow:visible;white-space:normal;word-wrap:break-word}nxt-dropzone>.dropzone.dz-wrapper .dz-preview .dz-image{border-radius:5px;overflow:hidden;min-width:120px;min-height:120px;width:auto;height:auto}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-message{width:100%;height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview{width:100%;height:100%;grid-column:span 2;grid-row:span 2}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image{width:100%;height:100%}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-preview .dz-image img{display:block;width:100%;height:auto;margin:0}nxt-dropzone>.dropzone.dz-wrapper.dz-single .dz-error-message{top:50%;left:50%;transform:translate(-50%) translateY(100%)}nxt-dropzone>.dropzone.dz-wrapper.dz-single.dz-started .dz-message{display:none}nxt-dropzone>.dropzone.dz-wrapper.dz-multiple.dz-started .dz-message{display:flex}\n", "@keyframes passing-through{0%{opacity:0;transform:translateY(40px)}30%,70%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-40px)}}@keyframes slide-in{0%{opacity:0;transform:translateY(40px)}30%{opacity:1;transform:translateY(0)}}@keyframes pulse{0%{transform:scale(1)}10%{transform:scale(1.1)}20%{transform:scale(1)}}.dropzone,.dropzone *{box-sizing:border-box}.dropzone{min-height:150px;border:1px solid rgba(0,0,0,.8);border-radius:5px;padding:20px}.dropzone.dz-clickable{cursor:pointer}.dropzone.dz-clickable *{cursor:default}.dropzone.dz-clickable .dz-message,.dropzone.dz-clickable .dz-message *{cursor:pointer}.dropzone.dz-started .dz-message{display:none}.dropzone.dz-drag-hover{border-style:solid}.dropzone.dz-drag-hover .dz-message{opacity:.5}.dropzone .dz-message{text-align:center;margin:3em 0}.dropzone .dz-message .dz-button{background:none;color:inherit;border:none;padding:0;font:inherit;cursor:pointer;outline:inherit}.dropzone .dz-preview{position:relative;display:inline-block;vertical-align:top;margin:16px;min-height:100px}.dropzone .dz-preview:hover{z-index:1000}.dropzone .dz-preview.dz-file-preview .dz-image{border-radius:20px;background:#999;background:linear-gradient(to bottom,#eee,#ddd)}.dropzone .dz-preview.dz-file-preview .dz-details{opacity:1}.dropzone .dz-preview.dz-image-preview{background:#fff}.dropzone .dz-preview.dz-image-preview .dz-details{transition:opacity .2s linear}.dropzone .dz-preview .dz-remove{font-size:14px;text-align:center;display:block;cursor:pointer;border:none}.dropzone .dz-preview .dz-remove:hover{text-decoration:underline}.dropzone .dz-preview:hover .dz-details{opacity:1}.dropzone .dz-preview .dz-details{z-index:20;position:absolute;top:0;left:0;opacity:0;font-size:13px;min-width:100%;max-width:100%;padding:2em 1em;text-align:center;color:#000000e6;line-height:150%}.dropzone .dz-preview .dz-details .dz-size{margin-bottom:1em;font-size:16px}.dropzone .dz-preview .dz-details .dz-filename{white-space:nowrap}.dropzone .dz-preview .dz-details .dz-filename:hover span{border:1px solid rgba(200,200,200,.8);background-color:#fffc}.dropzone .dz-preview .dz-details .dz-filename:not(:hover){overflow:hidden;text-overflow:ellipsis}.dropzone .dz-preview .dz-details .dz-filename:not(:hover) span{border:1px solid transparent}.dropzone .dz-preview .dz-details .dz-filename span,.dropzone .dz-preview .dz-details .dz-size span{background-color:#fff6;padding:0 .4em;border-radius:3px}.dropzone .dz-preview:hover .dz-image img{transform:scale(1.05);filter:blur(8px)}.dropzone .dz-preview .dz-image{border-radius:20px;overflow:hidden;width:120px;height:120px;position:relative;display:block;z-index:10}.dropzone .dz-preview .dz-image img{display:block}.dropzone .dz-preview.dz-success .dz-success-mark{animation:passing-through 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview.dz-error .dz-error-mark{opacity:1;animation:slide-in 3s cubic-bezier(.77,0,.175,1)}.dropzone .dz-preview .dz-success-mark,.dropzone .dz-preview .dz-error-mark{pointer-events:none;opacity:0;z-index:500;position:absolute;display:block;top:50%;left:50%;margin-left:-27px;margin-top:-27px;background:rgba(0,0,0,.8);border-radius:50%}.dropzone .dz-preview .dz-success-mark svg,.dropzone .dz-preview .dz-error-mark svg{display:block;width:54px;height:54px;fill:#fff}.dropzone .dz-preview.dz-processing .dz-progress{opacity:1;transition:all .2s linear}.dropzone .dz-preview.dz-complete .dz-progress{opacity:0;transition:opacity .4s ease-in}.dropzone .dz-preview:not(.dz-processing) .dz-progress{animation:pulse 6s ease infinite}.dropzone .dz-preview .dz-progress{opacity:1;z-index:1000;pointer-events:none;position:absolute;height:20px;top:50%;margin-top:-10px;left:15%;right:15%;border:3px solid rgba(0,0,0,.8);background:rgba(0,0,0,.8);border-radius:10px;overflow:hidden}.dropzone .dz-preview .dz-progress .dz-upload{background:#fff;display:block;position:relative;height:100%;width:0;transition:width .3s ease-in-out;border-radius:17px}.dropzone .dz-preview.dz-error .dz-error-message{display:block}.dropzone .dz-preview.dz-error:hover .dz-error-message{opacity:1;pointer-events:auto}.dropzone .dz-preview .dz-error-message{pointer-events:none;z-index:1000;position:absolute;display:block;display:none;opacity:0;transition:opacity .3s ease;border-radius:8px;font-size:13px;top:130px;left:-10px;width:140px;background:#b10606;padding:.5em 1em;color:#fff}.dropzone .dz-preview .dz-error-message:after{content:\"\";position:absolute;top:-6px;left:64px;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:6px solid #b10606}\n"] }]
427
+ }], ctorParameters: function () { return []; }, propDecorators: { disabled: [{
379
428
  type: Input
380
429
  }], config: [{
381
430
  type: Input
@@ -388,24 +437,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
388
437
  }], DZ_INIT: [{
389
438
  type: Output,
390
439
  args: ['init']
391
- }], DZ_ERROR: [{
392
- type: Output,
393
- args: ['error']
394
- }], DZ_SUCCESS: [{
395
- type: Output,
396
- args: ['success']
397
- }], DZ_SENDING: [{
398
- type: Output,
399
- args: ['sending']
400
- }], DZ_CANCELED: [{
401
- type: Output,
402
- args: ['canceled']
403
- }], DZ_COMPLETE: [{
404
- type: Output,
405
- args: ['complete']
406
- }], DZ_PROCESSING: [{
407
- type: Output,
408
- args: ['processing']
409
440
  }], DZ_DROP: [{
410
441
  type: Output,
411
442
  args: ['drop']
@@ -424,9 +455,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
424
455
  }], DZ_DRAGLEAVE: [{
425
456
  type: Output,
426
457
  args: ['dragLeave']
427
- }], DZ_THUMBNAIL: [{
458
+ }], DZ_PASTE: [{
428
459
  type: Output,
429
- args: ['thumbnail']
460
+ args: ['paste']
461
+ }], DZ_RESET: [{
462
+ type: Output,
463
+ args: ['reset']
430
464
  }], DZ_ADDEDFILE: [{
431
465
  type: Output,
432
466
  args: ['addedFile']
@@ -436,55 +470,73 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
436
470
  }], DZ_REMOVEDFILE: [{
437
471
  type: Output,
438
472
  args: ['removedFile']
473
+ }], DZ_THUMBNAIL: [{
474
+ type: Output,
475
+ args: ['thumbnail']
476
+ }], DZ_ERROR: [{
477
+ type: Output,
478
+ args: ['error']
479
+ }], DZ_ERRORMULTIPLE: [{
480
+ type: Output,
481
+ args: ['errorMultiple']
482
+ }], DZ_PROCESSING: [{
483
+ type: Output,
484
+ args: ['processing']
485
+ }], DZ_PROCESSINGMULTIPLE: [{
486
+ type: Output,
487
+ args: ['processingMultiple']
439
488
  }], DZ_UPLOADPROGRESS: [{
440
489
  type: Output,
441
490
  args: ['uploadProgress']
442
- }], DZ_MAXFILESREACHED: [{
491
+ }], DZ_TOTALUPLOADPROGRESS: [{
443
492
  type: Output,
444
- args: ['maxFilesReached']
445
- }], DZ_MAXFILESEXCEEDED: [{
493
+ args: ['totalUploadProgress']
494
+ }], DZ_SENDING: [{
446
495
  type: Output,
447
- args: ['maxFilesExceeded']
448
- }], DZ_ERRORMULTIPLE: [{
496
+ args: ['sending']
497
+ }], DZ_SENDINGMULTIPLE: [{
449
498
  type: Output,
450
- args: ['errorMultiple']
499
+ args: ['sendingMultiple']
500
+ }], DZ_SUCCESS: [{
501
+ type: Output,
502
+ args: ['success']
451
503
  }], DZ_SUCCESSMULTIPLE: [{
452
504
  type: Output,
453
505
  args: ['successMultiple']
454
- }], DZ_SENDINGMULTIPLE: [{
506
+ }], DZ_CANCELED: [{
455
507
  type: Output,
456
- args: ['sendingMultiple']
508
+ args: ['canceled']
457
509
  }], DZ_CANCELEDMULTIPLE: [{
458
510
  type: Output,
459
511
  args: ['canceledMultiple']
512
+ }], DZ_COMPLETE: [{
513
+ type: Output,
514
+ args: ['complete']
460
515
  }], DZ_COMPLETEMULTIPLE: [{
461
516
  type: Output,
462
517
  args: ['completeMultiple']
463
- }], DZ_PROCESSINGMULTIPLE: [{
518
+ }], DZ_MAXFILESEXCEEDED: [{
464
519
  type: Output,
465
- args: ['processingMultiple']
466
- }], DZ_RESET: [{
520
+ args: ['maxFilesExceeded']
521
+ }], DZ_MAXFILESREACHED: [{
467
522
  type: Output,
468
- args: ['reset']
523
+ args: ['maxFilesReached']
469
524
  }], DZ_QUEUECOMPLETE: [{
470
525
  type: Output,
471
526
  args: ['queueComplete']
472
- }], DZ_TOTALUPLOADPROGRESS: [{
473
- type: Output,
474
- args: ['totalUploadProgress']
475
527
  }], directiveRef: [{
476
528
  type: ViewChild,
477
- args: [DropzoneDirective, { static: true }]
529
+ args: [DropzoneDirective]
478
530
  }] } });
479
531
 
480
532
  class DropzoneModule {
481
533
  }
482
- DropzoneModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
483
- DropzoneModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.1", ngImport: i0, type: DropzoneModule, declarations: [DropzoneComponent,
534
+ DropzoneModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
535
+ DropzoneModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.3", ngImport: i0, type: DropzoneModule, declarations: [DropzoneComponent,
484
536
  DropzoneDirective], imports: [CommonModule], exports: [DropzoneComponent,
485
537
  DropzoneDirective] });
486
- DropzoneModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneModule, imports: [CommonModule] });
487
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImport: i0, type: DropzoneModule, decorators: [{
538
+ DropzoneModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneModule, imports: [CommonModule] });
539
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.3", ngImport: i0, type: DropzoneModule, decorators: [{
488
540
  type: NgModule,
489
541
  args: [{
490
542
  declarations: [
@@ -505,5 +557,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.1", ngImpor
505
557
  * Generated bundle index. Do not edit.
506
558
  */
507
559
 
508
- export { DropzoneComponent, DropzoneConfig, DropzoneDirective, DropzoneModule, NXT_DROPZONE_CONFIG };
560
+ export { DropzoneComponent, DropzoneDirective, DropzoneModule, NXT_DROPZONE_CONFIG };
509
561
  //# sourceMappingURL=nxt-dropzone-wrapper.mjs.map