@frollo/frollo-web-ui 1.2.3 → 1.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/cjs/index.js +1451 -719
  2. package/esm/{add-to-unscopables-44076600.js → add-to-unscopables-a5032b1d.js} +4 -4
  3. package/esm/{array-iteration-10670eca.js → array-iteration-4f83e223.js} +4 -4
  4. package/esm/{classof-b2d09c70.js → classof-088c9833.js} +2 -2
  5. package/esm/create-property-da6d232b.js +26 -0
  6. package/esm/es.array.find-54b8f84b.js +52 -0
  7. package/esm/{es.array.includes-b402df81.js → es.array.includes-9a6e4066.js} +4 -4
  8. package/esm/{es.function.name-383fcdbc.js → es.function.name-2fa3a718.js} +1 -1
  9. package/esm/{es.number.constructor-6def8fd9.js → es.number.constructor-b7faae1f.js} +5 -3
  10. package/esm/{function-name-0d296891.js → function-name-c49146fc.js} +1 -1
  11. package/esm/fw-animations.js +5 -5
  12. package/esm/{fw-button-fb8e3fe2.js → fw-button-d5d2cf19.js} +1 -1
  13. package/esm/fw-button.js +6 -6
  14. package/esm/fw-checkbox.js +2 -2
  15. package/esm/fw-dropdown.js +9 -54
  16. package/esm/fw-image.js +848 -0
  17. package/esm/fw-input.js +6 -6
  18. package/esm/fw-loading-bar-da7d53fb.js +22 -0
  19. package/esm/fw-loading.js +96 -0
  20. package/esm/fw-modal.js +7 -7
  21. package/esm/fw-navigation-menu.js +6 -6
  22. package/esm/fw-progress-bar.js +5 -5
  23. package/esm/fw-table.js +466 -8
  24. package/esm/fw-tabs.js +8 -8
  25. package/esm/fw-tag.js +5 -5
  26. package/esm/{index-26d82b11.js → index-7d8c95be.js} +2 -2
  27. package/esm/{index-ed9adbea.js → index-b3aa1664.js} +94 -80
  28. package/esm/index.js +36 -199
  29. package/esm/{is-forced-2369382d.js → is-forced-fd46b5f2.js} +2 -2
  30. package/esm/{object-keys-f9d76c12.js → object-keys-3c73c404.js} +2 -2
  31. package/esm/{to-string-2588bbbe.js → to-string-c2bd1f4d.js} +2 -2
  32. package/frollo-web-ui.esm.js +1635 -829
  33. package/icons/index.ts +3 -1
  34. package/icons/user.svg +3 -0
  35. package/index.d.ts +149 -17
  36. package/package.json +1 -1
  37. package/types/components/fw-image/fw-image.vue.d.ts +84 -0
  38. package/types/components/fw-image/index.d.ts +2 -0
  39. package/types/components/fw-image/index.types.d.ts +8 -0
  40. package/types/components/fw-loading/fw-loading-bar.vue.d.ts +2 -0
  41. package/types/components/fw-loading/fw-loading-card.vue.d.ts +2 -0
  42. package/types/components/fw-loading/fw-loading-table.vue.d.ts +25 -0
  43. package/types/components/fw-loading/index.d.ts +4 -0
  44. package/types/components/fw-table/fw-table.vue.d.ts +11 -1
  45. package/types/components/fw-table/index.types.d.ts +1 -0
  46. package/types/components/index.d.ts +2 -0
  47. package/types/components/index.types.d.ts +1 -0
  48. package/types/directives/index.d.ts +2 -0
  49. package/types/directives/lazy-loader.d.ts +3 -0
  50. package/types/icons/index.d.ts +2 -1
  51. package/esm/index-2ee67707.js +0 -454
@@ -0,0 +1,848 @@
1
+ import './es.array.includes-9a6e4066.js';
2
+ import { o as objectSetPrototypeOf } from './es.number.constructor-b7faae1f.js';
3
+ import { defineComponent, computed, ref, resolveComponent, resolveDirective, withDirectives, openBlock, createElementBlock, normalizeClass, withKeys, createElementVNode, createVNode, renderSlot } from 'vue';
4
+ import './es.array.find-54b8f84b.js';
5
+ import { a as documentCreateElement$1, g as global$4, b as functionCall, c as anObject$3, e as getMethod$2, w as wellKnownSymbol$6, h as aCallable$1, t as tryToString$1, i as toObject$2, f as functionUncurryThis, r as requireObjectCoercible$1, j as fails$2, k as hasOwnProperty_1, l as isCallable$4, m as isPure, o as objectDefineProperty, n as functionName, p as functionBindNative, q as engineUserAgent } from './function-name-c49146fc.js';
6
+ import { _ as _export } from './object-keys-3c73c404.js';
7
+ import { a as arrayIteration, f as functionBindContext, i as isConstructor$1 } from './array-iteration-4f83e223.js';
8
+ import { c as createNonEnumerableProperty$2, l as lengthOfArrayLike$1, a as toIntegerOrInfinity$1, s as sharedKey$1, d as defineBuiltIn$2, b as createPropertyDescriptor$1, i as internalState } from './is-forced-fd46b5f2.js';
9
+ import { a as arrayMethodIsStrict$1, c as createProperty$1 } from './create-property-da6d232b.js';
10
+ import { c as classof$1 } from './classof-088c9833.js';
11
+ import { t as toString$2 } from './to-string-c2bd1f4d.js';
12
+ import { o as objectCreate } from './add-to-unscopables-a5032b1d.js';
13
+ import { s as script$1 } from './fw-loading-bar-da7d53fb.js';
14
+ import { r as render$1 } from './index-b3aa1664.js';
15
+ import { s as styleInject } from './style-inject.es-1f59c1d0.js';
16
+ import './check-94a5917a.js';
17
+
18
+ var es_array_forEach = {};
19
+
20
+ 'use strict';
21
+ var $forEach = arrayIteration.forEach;
22
+ var arrayMethodIsStrict = arrayMethodIsStrict$1;
23
+
24
+ var STRICT_METHOD = arrayMethodIsStrict('forEach');
25
+
26
+ // `Array.prototype.forEach` method implementation
27
+ // https://tc39.es/ecma262/#sec-array.prototype.foreach
28
+ var arrayForEach = !STRICT_METHOD ? function forEach(callbackfn /* , thisArg */) {
29
+ return $forEach(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
30
+ // eslint-disable-next-line es-x/no-array-prototype-foreach -- safe
31
+ } : [].forEach;
32
+
33
+ 'use strict';
34
+ var $$4 = _export;
35
+ var forEach$1 = arrayForEach;
36
+
37
+ // `Array.prototype.forEach` method
38
+ // https://tc39.es/ecma262/#sec-array.prototype.foreach
39
+ // eslint-disable-next-line es-x/no-array-prototype-foreach -- safe
40
+ $$4({ target: 'Array', proto: true, forced: [].forEach != forEach$1 }, {
41
+ forEach: forEach$1
42
+ });
43
+
44
+ var web_domCollections_forEach = {};
45
+
46
+ // iterable DOM collections
47
+ // flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
48
+ var domIterables = {
49
+ CSSRuleList: 0,
50
+ CSSStyleDeclaration: 0,
51
+ CSSValueList: 0,
52
+ ClientRectList: 0,
53
+ DOMRectList: 0,
54
+ DOMStringList: 0,
55
+ DOMTokenList: 1,
56
+ DataTransferItemList: 0,
57
+ FileList: 0,
58
+ HTMLAllCollection: 0,
59
+ HTMLCollection: 0,
60
+ HTMLFormElement: 0,
61
+ HTMLSelectElement: 0,
62
+ MediaList: 0,
63
+ MimeTypeArray: 0,
64
+ NamedNodeMap: 0,
65
+ NodeList: 1,
66
+ PaintRequestList: 0,
67
+ Plugin: 0,
68
+ PluginArray: 0,
69
+ SVGLengthList: 0,
70
+ SVGNumberList: 0,
71
+ SVGPathSegList: 0,
72
+ SVGPointList: 0,
73
+ SVGStringList: 0,
74
+ SVGTransformList: 0,
75
+ SourceBufferList: 0,
76
+ StyleSheetList: 0,
77
+ TextTrackCueList: 0,
78
+ TextTrackList: 0,
79
+ TouchList: 0
80
+ };
81
+
82
+ // in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`
83
+ var documentCreateElement = documentCreateElement$1;
84
+
85
+ var classList = documentCreateElement('span').classList;
86
+ var DOMTokenListPrototype$1 = classList && classList.constructor && classList.constructor.prototype;
87
+
88
+ var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
89
+
90
+ var global$3 = global$4;
91
+ var DOMIterables = domIterables;
92
+ var DOMTokenListPrototype = domTokenListPrototype;
93
+ var forEach = arrayForEach;
94
+ var createNonEnumerableProperty$1 = createNonEnumerableProperty$2;
95
+
96
+ var handlePrototype = function (CollectionPrototype) {
97
+ // some Chrome versions have non-configurable methods on DOMTokenList
98
+ if (CollectionPrototype && CollectionPrototype.forEach !== forEach) try {
99
+ createNonEnumerableProperty$1(CollectionPrototype, 'forEach', forEach);
100
+ } catch (error) {
101
+ CollectionPrototype.forEach = forEach;
102
+ }
103
+ };
104
+
105
+ for (var COLLECTION_NAME in DOMIterables) {
106
+ if (DOMIterables[COLLECTION_NAME]) {
107
+ handlePrototype(global$3[COLLECTION_NAME] && global$3[COLLECTION_NAME].prototype);
108
+ }
109
+ }
110
+
111
+ handlePrototype(DOMTokenListPrototype);
112
+
113
+ var es_array_from = {};
114
+
115
+ var call$4 = functionCall;
116
+ var anObject$2 = anObject$3;
117
+ var getMethod$1 = getMethod$2;
118
+
119
+ var iteratorClose$1 = function (iterator, kind, value) {
120
+ var innerResult, innerError;
121
+ anObject$2(iterator);
122
+ try {
123
+ innerResult = getMethod$1(iterator, 'return');
124
+ if (!innerResult) {
125
+ if (kind === 'throw') throw value;
126
+ return value;
127
+ }
128
+ innerResult = call$4(innerResult, iterator);
129
+ } catch (error) {
130
+ innerError = true;
131
+ innerResult = error;
132
+ }
133
+ if (kind === 'throw') throw value;
134
+ if (innerError) throw innerResult;
135
+ anObject$2(innerResult);
136
+ return value;
137
+ };
138
+
139
+ var anObject$1 = anObject$3;
140
+ var iteratorClose = iteratorClose$1;
141
+
142
+ // call something on iterator step with safe closing on error
143
+ var callWithSafeIterationClosing$1 = function (iterator, fn, value, ENTRIES) {
144
+ try {
145
+ return ENTRIES ? fn(anObject$1(value)[0], value[1]) : fn(value);
146
+ } catch (error) {
147
+ iteratorClose(iterator, 'throw', error);
148
+ }
149
+ };
150
+
151
+ var iterators = {};
152
+
153
+ var wellKnownSymbol$5 = wellKnownSymbol$6;
154
+ var Iterators$3 = iterators;
155
+
156
+ var ITERATOR$4 = wellKnownSymbol$5('iterator');
157
+ var ArrayPrototype = Array.prototype;
158
+
159
+ // check on default Array iterator
160
+ var isArrayIteratorMethod$1 = function (it) {
161
+ return it !== undefined && (Iterators$3.Array === it || ArrayPrototype[ITERATOR$4] === it);
162
+ };
163
+
164
+ var classof = classof$1;
165
+ var getMethod = getMethod$2;
166
+ var Iterators$2 = iterators;
167
+ var wellKnownSymbol$4 = wellKnownSymbol$6;
168
+
169
+ var ITERATOR$3 = wellKnownSymbol$4('iterator');
170
+
171
+ var getIteratorMethod$2 = function (it) {
172
+ if (it != undefined) return getMethod(it, ITERATOR$3)
173
+ || getMethod(it, '@@iterator')
174
+ || Iterators$2[classof(it)];
175
+ };
176
+
177
+ var call$3 = functionCall;
178
+ var aCallable = aCallable$1;
179
+ var anObject = anObject$3;
180
+ var tryToString = tryToString$1;
181
+ var getIteratorMethod$1 = getIteratorMethod$2;
182
+
183
+ var $TypeError$1 = TypeError;
184
+
185
+ var getIterator$1 = function (argument, usingIterator) {
186
+ var iteratorMethod = arguments.length < 2 ? getIteratorMethod$1(argument) : usingIterator;
187
+ if (aCallable(iteratorMethod)) return anObject(call$3(iteratorMethod, argument));
188
+ throw $TypeError$1(tryToString(argument) + ' is not iterable');
189
+ };
190
+
191
+ 'use strict';
192
+ var bind = functionBindContext;
193
+ var call$2 = functionCall;
194
+ var toObject$1 = toObject$2;
195
+ var callWithSafeIterationClosing = callWithSafeIterationClosing$1;
196
+ var isArrayIteratorMethod = isArrayIteratorMethod$1;
197
+ var isConstructor = isConstructor$1;
198
+ var lengthOfArrayLike = lengthOfArrayLike$1;
199
+ var createProperty = createProperty$1;
200
+ var getIterator = getIterator$1;
201
+ var getIteratorMethod = getIteratorMethod$2;
202
+
203
+ var $Array = Array;
204
+
205
+ // `Array.from` method implementation
206
+ // https://tc39.es/ecma262/#sec-array.from
207
+ var arrayFrom = function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {
208
+ var O = toObject$1(arrayLike);
209
+ var IS_CONSTRUCTOR = isConstructor(this);
210
+ var argumentsLength = arguments.length;
211
+ var mapfn = argumentsLength > 1 ? arguments[1] : undefined;
212
+ var mapping = mapfn !== undefined;
213
+ if (mapping) mapfn = bind(mapfn, argumentsLength > 2 ? arguments[2] : undefined);
214
+ var iteratorMethod = getIteratorMethod(O);
215
+ var index = 0;
216
+ var length, result, step, iterator, next, value;
217
+ // if the target is not iterable or it's an array with the default iterator - use a simple case
218
+ if (iteratorMethod && !(this === $Array && isArrayIteratorMethod(iteratorMethod))) {
219
+ iterator = getIterator(O, iteratorMethod);
220
+ next = iterator.next;
221
+ result = IS_CONSTRUCTOR ? new this() : [];
222
+ for (;!(step = call$2(next, iterator)).done; index++) {
223
+ value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value;
224
+ createProperty(result, index, value);
225
+ }
226
+ } else {
227
+ length = lengthOfArrayLike(O);
228
+ result = IS_CONSTRUCTOR ? new this(length) : $Array(length);
229
+ for (;length > index; index++) {
230
+ value = mapping ? mapfn(O[index], index) : O[index];
231
+ createProperty(result, index, value);
232
+ }
233
+ }
234
+ result.length = index;
235
+ return result;
236
+ };
237
+
238
+ var wellKnownSymbol$3 = wellKnownSymbol$6;
239
+
240
+ var ITERATOR$2 = wellKnownSymbol$3('iterator');
241
+ var SAFE_CLOSING = false;
242
+
243
+ try {
244
+ var called = 0;
245
+ var iteratorWithReturn = {
246
+ next: function () {
247
+ return { done: !!called++ };
248
+ },
249
+ 'return': function () {
250
+ SAFE_CLOSING = true;
251
+ }
252
+ };
253
+ iteratorWithReturn[ITERATOR$2] = function () {
254
+ return this;
255
+ };
256
+ // eslint-disable-next-line es-x/no-array-from, no-throw-literal -- required for testing
257
+ Array.from(iteratorWithReturn, function () { throw 2; });
258
+ } catch (error) { /* empty */ }
259
+
260
+ var checkCorrectnessOfIteration$1 = function (exec, SKIP_CLOSING) {
261
+ if (!SKIP_CLOSING && !SAFE_CLOSING) return false;
262
+ var ITERATION_SUPPORT = false;
263
+ try {
264
+ var object = {};
265
+ object[ITERATOR$2] = function () {
266
+ return {
267
+ next: function () {
268
+ return { done: ITERATION_SUPPORT = true };
269
+ }
270
+ };
271
+ };
272
+ exec(object);
273
+ } catch (error) { /* empty */ }
274
+ return ITERATION_SUPPORT;
275
+ };
276
+
277
+ var $$3 = _export;
278
+ var from = arrayFrom;
279
+ var checkCorrectnessOfIteration = checkCorrectnessOfIteration$1;
280
+
281
+ var INCORRECT_ITERATION = !checkCorrectnessOfIteration(function (iterable) {
282
+ // eslint-disable-next-line es-x/no-array-from -- required for testing
283
+ Array.from(iterable);
284
+ });
285
+
286
+ // `Array.from` method
287
+ // https://tc39.es/ecma262/#sec-array.from
288
+ $$3({ target: 'Array', stat: true, forced: INCORRECT_ITERATION }, {
289
+ from: from
290
+ });
291
+
292
+ var es_string_iterator = {};
293
+
294
+ var uncurryThis$1 = functionUncurryThis;
295
+ var toIntegerOrInfinity = toIntegerOrInfinity$1;
296
+ var toString$1 = toString$2;
297
+ var requireObjectCoercible = requireObjectCoercible$1;
298
+
299
+ var charAt$1 = uncurryThis$1(''.charAt);
300
+ var charCodeAt = uncurryThis$1(''.charCodeAt);
301
+ var stringSlice = uncurryThis$1(''.slice);
302
+
303
+ var createMethod = function (CONVERT_TO_STRING) {
304
+ return function ($this, pos) {
305
+ var S = toString$1(requireObjectCoercible($this));
306
+ var position = toIntegerOrInfinity(pos);
307
+ var size = S.length;
308
+ var first, second;
309
+ if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;
310
+ first = charCodeAt(S, position);
311
+ return first < 0xD800 || first > 0xDBFF || position + 1 === size
312
+ || (second = charCodeAt(S, position + 1)) < 0xDC00 || second > 0xDFFF
313
+ ? CONVERT_TO_STRING
314
+ ? charAt$1(S, position)
315
+ : first
316
+ : CONVERT_TO_STRING
317
+ ? stringSlice(S, position, position + 2)
318
+ : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;
319
+ };
320
+ };
321
+
322
+ var stringMultibyte = {
323
+ // `String.prototype.codePointAt` method
324
+ // https://tc39.es/ecma262/#sec-string.prototype.codepointat
325
+ codeAt: createMethod(false),
326
+ // `String.prototype.at` method
327
+ // https://github.com/mathiasbynens/String.prototype.at
328
+ charAt: createMethod(true)
329
+ };
330
+
331
+ var fails$1 = fails$2;
332
+
333
+ var correctPrototypeGetter = !fails$1(function () {
334
+ function F() { /* empty */ }
335
+ F.prototype.constructor = null;
336
+ // eslint-disable-next-line es-x/no-object-getprototypeof -- required for testing
337
+ return Object.getPrototypeOf(new F()) !== F.prototype;
338
+ });
339
+
340
+ var hasOwn$1 = hasOwnProperty_1;
341
+ var isCallable$3 = isCallable$4;
342
+ var toObject = toObject$2;
343
+ var sharedKey = sharedKey$1;
344
+ var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
345
+
346
+ var IE_PROTO = sharedKey('IE_PROTO');
347
+ var $Object = Object;
348
+ var ObjectPrototype = $Object.prototype;
349
+
350
+ // `Object.getPrototypeOf` method
351
+ // https://tc39.es/ecma262/#sec-object.getprototypeof
352
+ // eslint-disable-next-line es-x/no-object-getprototypeof -- safe
353
+ var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {
354
+ var object = toObject(O);
355
+ if (hasOwn$1(object, IE_PROTO)) return object[IE_PROTO];
356
+ var constructor = object.constructor;
357
+ if (isCallable$3(constructor) && object instanceof constructor) {
358
+ return constructor.prototype;
359
+ } return object instanceof $Object ? ObjectPrototype : null;
360
+ };
361
+
362
+ 'use strict';
363
+ var fails = fails$2;
364
+ var isCallable$2 = isCallable$4;
365
+ var create$1 = objectCreate;
366
+ var getPrototypeOf$1 = objectGetPrototypeOf;
367
+ var defineBuiltIn$1 = defineBuiltIn$2;
368
+ var wellKnownSymbol$2 = wellKnownSymbol$6;
369
+ var IS_PURE$1 = isPure;
370
+
371
+ var ITERATOR$1 = wellKnownSymbol$2('iterator');
372
+ var BUGGY_SAFARI_ITERATORS$1 = false;
373
+
374
+ // `%IteratorPrototype%` object
375
+ // https://tc39.es/ecma262/#sec-%iteratorprototype%-object
376
+ var IteratorPrototype$2, PrototypeOfArrayIteratorPrototype, arrayIterator;
377
+
378
+ /* eslint-disable es-x/no-array-prototype-keys -- safe */
379
+ if ([].keys) {
380
+ arrayIterator = [].keys();
381
+ // Safari 8 has buggy iterators w/o `next`
382
+ if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS$1 = true;
383
+ else {
384
+ PrototypeOfArrayIteratorPrototype = getPrototypeOf$1(getPrototypeOf$1(arrayIterator));
385
+ if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$2 = PrototypeOfArrayIteratorPrototype;
386
+ }
387
+ }
388
+
389
+ var NEW_ITERATOR_PROTOTYPE = IteratorPrototype$2 == undefined || fails(function () {
390
+ var test = {};
391
+ // FF44- legacy iterators case
392
+ return IteratorPrototype$2[ITERATOR$1].call(test) !== test;
393
+ });
394
+
395
+ if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$2 = {};
396
+ else if (IS_PURE$1) IteratorPrototype$2 = create$1(IteratorPrototype$2);
397
+
398
+ // `%IteratorPrototype%[@@iterator]()` method
399
+ // https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
400
+ if (!isCallable$2(IteratorPrototype$2[ITERATOR$1])) {
401
+ defineBuiltIn$1(IteratorPrototype$2, ITERATOR$1, function () {
402
+ return this;
403
+ });
404
+ }
405
+
406
+ var iteratorsCore = {
407
+ IteratorPrototype: IteratorPrototype$2,
408
+ BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS$1
409
+ };
410
+
411
+ var defineProperty = objectDefineProperty.f;
412
+ var hasOwn = hasOwnProperty_1;
413
+ var wellKnownSymbol$1 = wellKnownSymbol$6;
414
+
415
+ var TO_STRING_TAG = wellKnownSymbol$1('toStringTag');
416
+
417
+ var setToStringTag$2 = function (target, TAG, STATIC) {
418
+ if (target && !STATIC) target = target.prototype;
419
+ if (target && !hasOwn(target, TO_STRING_TAG)) {
420
+ defineProperty(target, TO_STRING_TAG, { configurable: true, value: TAG });
421
+ }
422
+ };
423
+
424
+ 'use strict';
425
+ var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
426
+ var create = objectCreate;
427
+ var createPropertyDescriptor = createPropertyDescriptor$1;
428
+ var setToStringTag$1 = setToStringTag$2;
429
+ var Iterators$1 = iterators;
430
+
431
+ var returnThis$1 = function () { return this; };
432
+
433
+ var createIteratorConstructor$1 = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {
434
+ var TO_STRING_TAG = NAME + ' Iterator';
435
+ IteratorConstructor.prototype = create(IteratorPrototype$1, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });
436
+ setToStringTag$1(IteratorConstructor, TO_STRING_TAG, false, true);
437
+ Iterators$1[TO_STRING_TAG] = returnThis$1;
438
+ return IteratorConstructor;
439
+ };
440
+
441
+ 'use strict';
442
+ var $$2 = _export;
443
+ var call$1 = functionCall;
444
+ var IS_PURE = isPure;
445
+ var FunctionName = functionName;
446
+ var isCallable$1 = isCallable$4;
447
+ var createIteratorConstructor = createIteratorConstructor$1;
448
+ var getPrototypeOf = objectGetPrototypeOf;
449
+ var setPrototypeOf = objectSetPrototypeOf;
450
+ var setToStringTag = setToStringTag$2;
451
+ var createNonEnumerableProperty = createNonEnumerableProperty$2;
452
+ var defineBuiltIn = defineBuiltIn$2;
453
+ var wellKnownSymbol = wellKnownSymbol$6;
454
+ var Iterators = iterators;
455
+ var IteratorsCore = iteratorsCore;
456
+
457
+ var PROPER_FUNCTION_NAME = FunctionName.PROPER;
458
+ var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
459
+ var IteratorPrototype = IteratorsCore.IteratorPrototype;
460
+ var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;
461
+ var ITERATOR = wellKnownSymbol('iterator');
462
+ var KEYS = 'keys';
463
+ var VALUES = 'values';
464
+ var ENTRIES = 'entries';
465
+
466
+ var returnThis = function () { return this; };
467
+
468
+ var defineIterator$1 = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {
469
+ createIteratorConstructor(IteratorConstructor, NAME, next);
470
+
471
+ var getIterationMethod = function (KIND) {
472
+ if (KIND === DEFAULT && defaultIterator) return defaultIterator;
473
+ if (!BUGGY_SAFARI_ITERATORS && KIND in IterablePrototype) return IterablePrototype[KIND];
474
+ switch (KIND) {
475
+ case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };
476
+ case VALUES: return function values() { return new IteratorConstructor(this, KIND); };
477
+ case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };
478
+ } return function () { return new IteratorConstructor(this); };
479
+ };
480
+
481
+ var TO_STRING_TAG = NAME + ' Iterator';
482
+ var INCORRECT_VALUES_NAME = false;
483
+ var IterablePrototype = Iterable.prototype;
484
+ var nativeIterator = IterablePrototype[ITERATOR]
485
+ || IterablePrototype['@@iterator']
486
+ || DEFAULT && IterablePrototype[DEFAULT];
487
+ var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);
488
+ var anyNativeIterator = NAME == 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;
489
+ var CurrentIteratorPrototype, methods, KEY;
490
+
491
+ // fix native
492
+ if (anyNativeIterator) {
493
+ CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));
494
+ if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {
495
+ if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {
496
+ if (setPrototypeOf) {
497
+ setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);
498
+ } else if (!isCallable$1(CurrentIteratorPrototype[ITERATOR])) {
499
+ defineBuiltIn(CurrentIteratorPrototype, ITERATOR, returnThis);
500
+ }
501
+ }
502
+ // Set @@toStringTag to native iterators
503
+ setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);
504
+ if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;
505
+ }
506
+ }
507
+
508
+ // fix Array.prototype.{ values, @@iterator }.name in V8 / FF
509
+ if (PROPER_FUNCTION_NAME && DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) {
510
+ if (!IS_PURE && CONFIGURABLE_FUNCTION_NAME) {
511
+ createNonEnumerableProperty(IterablePrototype, 'name', VALUES);
512
+ } else {
513
+ INCORRECT_VALUES_NAME = true;
514
+ defaultIterator = function values() { return call$1(nativeIterator, this); };
515
+ }
516
+ }
517
+
518
+ // export additional methods
519
+ if (DEFAULT) {
520
+ methods = {
521
+ values: getIterationMethod(VALUES),
522
+ keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),
523
+ entries: getIterationMethod(ENTRIES)
524
+ };
525
+ if (FORCED) for (KEY in methods) {
526
+ if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
527
+ defineBuiltIn(IterablePrototype, KEY, methods[KEY]);
528
+ }
529
+ } else $$2({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
530
+ }
531
+
532
+ // define iterator
533
+ if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {
534
+ defineBuiltIn(IterablePrototype, ITERATOR, defaultIterator, { name: DEFAULT });
535
+ }
536
+ Iterators[NAME] = defaultIterator;
537
+
538
+ return methods;
539
+ };
540
+
541
+ 'use strict';
542
+ var charAt = stringMultibyte.charAt;
543
+ var toString = toString$2;
544
+ var InternalStateModule = internalState;
545
+ var defineIterator = defineIterator$1;
546
+
547
+ var STRING_ITERATOR = 'String Iterator';
548
+ var setInternalState = InternalStateModule.set;
549
+ var getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);
550
+
551
+ // `String.prototype[@@iterator]` method
552
+ // https://tc39.es/ecma262/#sec-string.prototype-@@iterator
553
+ defineIterator(String, 'String', function (iterated) {
554
+ setInternalState(this, {
555
+ type: STRING_ITERATOR,
556
+ string: toString(iterated),
557
+ index: 0
558
+ });
559
+ // `%StringIteratorPrototype%.next` method
560
+ // https://tc39.es/ecma262/#sec-%stringiteratorprototype%.next
561
+ }, function next() {
562
+ var state = getInternalState(this);
563
+ var string = state.string;
564
+ var index = state.index;
565
+ var point;
566
+ if (index >= string.length) return { value: undefined, done: true };
567
+ point = charAt(string, index);
568
+ state.index += point.length;
569
+ return { value: point, done: false };
570
+ });
571
+
572
+ var web_timers = {};
573
+
574
+ var web_setInterval = {};
575
+
576
+ var NATIVE_BIND = functionBindNative;
577
+
578
+ var FunctionPrototype = Function.prototype;
579
+ var apply$1 = FunctionPrototype.apply;
580
+ var call = FunctionPrototype.call;
581
+
582
+ // eslint-disable-next-line es-x/no-reflect -- safe
583
+ var functionApply = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call.bind(apply$1) : function () {
584
+ return call.apply(apply$1, arguments);
585
+ });
586
+
587
+ var uncurryThis = functionUncurryThis;
588
+
589
+ var arraySlice$1 = uncurryThis([].slice);
590
+
591
+ var $TypeError = TypeError;
592
+
593
+ var validateArgumentsLength$1 = function (passed, required) {
594
+ if (passed < required) throw $TypeError('Not enough arguments');
595
+ return passed;
596
+ };
597
+
598
+ var global$2 = global$4;
599
+ var apply = functionApply;
600
+ var isCallable = isCallable$4;
601
+ var userAgent = engineUserAgent;
602
+ var arraySlice = arraySlice$1;
603
+ var validateArgumentsLength = validateArgumentsLength$1;
604
+
605
+ var MSIE = /MSIE .\./.test(userAgent); // <- dirty ie9- check
606
+ var Function$1 = global$2.Function;
607
+
608
+ var wrap = function (scheduler) {
609
+ return MSIE ? function (handler, timeout /* , ...arguments */) {
610
+ var boundArgs = validateArgumentsLength(arguments.length, 1) > 2;
611
+ var fn = isCallable(handler) ? handler : Function$1(handler);
612
+ var args = boundArgs ? arraySlice(arguments, 2) : undefined;
613
+ return scheduler(boundArgs ? function () {
614
+ apply(fn, this, args);
615
+ } : fn, timeout);
616
+ } : scheduler;
617
+ };
618
+
619
+ // ie9- setTimeout & setInterval additional parameters fix
620
+ // https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#timers
621
+ var schedulersFix = {
622
+ // `setTimeout` method
623
+ // https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-settimeout
624
+ setTimeout: wrap(global$2.setTimeout),
625
+ // `setInterval` method
626
+ // https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-setinterval
627
+ setInterval: wrap(global$2.setInterval)
628
+ };
629
+
630
+ var $$1 = _export;
631
+ var global$1 = global$4;
632
+ var setInterval = schedulersFix.setInterval;
633
+
634
+ // ie9- setInterval additional parameters fix
635
+ // https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-setinterval
636
+ $$1({ global: true, bind: true, forced: global$1.setInterval !== setInterval }, {
637
+ setInterval: setInterval
638
+ });
639
+
640
+ var web_setTimeout = {};
641
+
642
+ var $ = _export;
643
+ var global = global$4;
644
+ var setTimeout$1 = schedulersFix.setTimeout;
645
+
646
+ // ie9- setTimeout additional parameters fix
647
+ // https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#dom-settimeout
648
+ $({ global: true, bind: true, forced: global.setTimeout !== setTimeout$1 }, {
649
+ setTimeout: setTimeout$1
650
+ });
651
+
652
+ var lazyLoadDirective = {
653
+ mounted: function mounted(el) {
654
+ var loadImage = function loadImage() {
655
+ var imageElement = Array.from(el.children).find(function (element) {
656
+ return element.nodeName === 'IMG';
657
+ });
658
+
659
+ if (imageElement) {
660
+ var type = el.getAttribute('type');
661
+ var url = imageElement.dataset.url;
662
+ imageElement.addEventListener('load', function () {
663
+ setTimeout(function () {
664
+ return el.classList.add('fw-image--loaded');
665
+ }, 100);
666
+ setTimeout(function () {
667
+ var _el$querySelector;
668
+
669
+ return (_el$querySelector = el.querySelector('.fw-image--loading')) === null || _el$querySelector === void 0 ? void 0 : _el$querySelector.remove();
670
+ }, 600);
671
+ });
672
+
673
+ if (url) {
674
+ imageElement.src = url;
675
+ }
676
+
677
+ if (type === 'background') {
678
+ el.style.backgroundImage = "url('".concat(url, "')");
679
+ imageElement.remove();
680
+ }
681
+
682
+ imageElement.addEventListener('error', function () {
683
+ setTimeout(function () {
684
+ return el.classList.add('fw-image--loaded-error');
685
+ }, 100);
686
+ setTimeout(function () {
687
+ var _el$querySelector2;
688
+
689
+ return (_el$querySelector2 = el.querySelector('.fw-image--loading')) === null || _el$querySelector2 === void 0 ? void 0 : _el$querySelector2.remove();
690
+ }, 600);
691
+ });
692
+ }
693
+ };
694
+
695
+ var handleIntersect = function handleIntersect(entries, observer) {
696
+ entries.forEach(function (entry) {
697
+ if (entry.isIntersecting) {
698
+ loadImage();
699
+ observer.unobserve(el);
700
+ }
701
+ });
702
+ };
703
+
704
+ var createObserver = function createObserver() {
705
+ var options = {
706
+ root: null,
707
+ threshold: Number(el.getAttribute('threshold')) || 0
708
+ };
709
+ var observer = new IntersectionObserver(handleIntersect, options);
710
+ observer.observe(el);
711
+ };
712
+
713
+ if (window.IntersectionObserver) {
714
+ createObserver();
715
+ } else {
716
+ loadImage();
717
+ }
718
+ }
719
+ };
720
+
721
+ var script = defineComponent({
722
+ name: 'FwImage',
723
+ directives: {
724
+ lazyload: lazyLoadDirective
725
+ },
726
+ components: {
727
+ FwLoadingBar: script$1,
728
+ FileExclamationSvg: render$1
729
+ },
730
+ props: {
731
+ /**
732
+ * The src attribute of the image
733
+ */
734
+ src: String,
735
+
736
+ /**
737
+ * The alt attribute of the image
738
+ */
739
+ alt: String,
740
+
741
+ /**
742
+ * The type of component. Accepts 'background' and defaults to the native html5 element.
743
+ */
744
+ type: {
745
+ type: String,
746
+ "default": 'native',
747
+ validator: function validator(value) {
748
+ return ['native', 'background'].includes(value);
749
+ }
750
+ },
751
+
752
+ /**
753
+ * Whether the loading bar and error state are rounded.
754
+ */
755
+ rounded: {
756
+ type: Boolean,
757
+ "default": false
758
+ },
759
+
760
+ /**
761
+ * The class for the native image element
762
+ */
763
+ imageClass: {
764
+ type: String
765
+ },
766
+
767
+ /**
768
+ * Controls the threshold before the component triggers the src url.
769
+ */
770
+ threshold: {
771
+ type: Number,
772
+ "default": 0
773
+ }
774
+ },
775
+ setup: function setup(props) {
776
+ var isBackground = computed(function () {
777
+ return props.type === 'background';
778
+ });
779
+ var fwImageRef = ref(null);
780
+ return {
781
+ fwImageRef: fwImageRef,
782
+ isBackground: isBackground
783
+ };
784
+ }
785
+ });
786
+
787
+ var _hoisted_1 = ["type", "threshold"];
788
+ var _hoisted_2 = ["data-url", "alt"];
789
+ var _hoisted_3 = {
790
+ "class": "fw-image--error-wrapper flex flex-col items-center justify-center"
791
+ };
792
+ function render(_ctx, _cache, $props, $setup, $data, $options) {
793
+ var _component_FwLoadingBar = resolveComponent("FwLoadingBar");
794
+
795
+ var _component_FileExclamationSvg = resolveComponent("FileExclamationSvg");
796
+
797
+ var _directive_lazyload = resolveDirective("lazyload");
798
+
799
+ return withDirectives((openBlock(), createElementBlock("div", {
800
+ ref: "fwImageRef",
801
+ type: _ctx.type,
802
+ threshold: _ctx.threshold,
803
+ "class": normalizeClass(["fw-image", {
804
+ 'fw-image--background': _ctx.isBackground,
805
+ 'rounded-full': _ctx.rounded
806
+ }]),
807
+ onClick: _cache[0] || (_cache[0] = function ($event) {
808
+ return _ctx.$emit('click', $event);
809
+ }),
810
+ onKeyup: _cache[1] || (_cache[1] = withKeys(function ($event) {
811
+ return _ctx.$emit('click', $event);
812
+ }, ["enter"])),
813
+ onMouseover: _cache[2] || (_cache[2] = function ($event) {
814
+ return _ctx.$emit('mouseover');
815
+ }),
816
+ onMouseout: _cache[3] || (_cache[3] = function ($event) {
817
+ return _ctx.$emit('mouseout');
818
+ }),
819
+ onFocusin: _cache[4] || (_cache[4] = function ($event) {
820
+ return _ctx.$emit('mouseover');
821
+ }),
822
+ onFocusout: _cache[5] || (_cache[5] = function ($event) {
823
+ return _ctx.$emit('mouseout');
824
+ })
825
+ }, [createElementVNode("img", {
826
+ "data-url": _ctx.src,
827
+ alt: _ctx.alt,
828
+ "class": normalizeClass(_ctx.imageClass)
829
+ }, null, 10, _hoisted_2), createVNode(_component_FwLoadingBar, {
830
+ "class": normalizeClass(["fw-image--loading w-full h-full", {
831
+ 'rounded-full': _ctx.rounded
832
+ }])
833
+ }, null, 8, ["class"]), createElementVNode("div", {
834
+ "class": normalizeClass(["fw-image--error bg-grey-20", {
835
+ 'rounded-full': _ctx.rounded
836
+ }])
837
+ }, [createElementVNode("div", _hoisted_3, [createVNode(_component_FileExclamationSvg, {
838
+ "class": "w-full h-full scale-[0.3] opacity-80 text-alert max-w-[150px]"
839
+ })])], 2), renderSlot(_ctx.$slots, "default")], 42, _hoisted_1)), [[_directive_lazyload]]);
840
+ }
841
+
842
+ var css_248z = ".fw-image{position:relative}.fw-image img{-webkit-transition:all .5s ease-in-out;-o-transition:all .5s ease-in-out;transition:all .5s ease-in-out}.fw-image img,.fw-image--error{opacity:0;visibility:hidden;width:100%}.fw-image--error{height:100%;left:0;position:relative;position:absolute;top:0;-webkit-transition:all .5s ease-in;-o-transition:all .5s ease-in;transition:all .5s ease-in}.fw-image--error-wrapper{font-size:inherit;left:50%;position:absolute;text-align:center;top:50%;-webkit-transform:translate(-50%,-50%);-ms-transform:translate(-50%,-50%);transform:translate(-50%,-50%);width:100%}.fw-image--loading{height:100%;left:0;position:absolute!important;top:0;-webkit-transition:all .5s ease-in-out;-o-transition:all .5s ease-in-out;transition:all .5s ease-in-out;width:100%}.fw-image--loaded img,.fw-image--loading{opacity:1;visibility:visible}.fw-image--loaded .fw-image--loading{opacity:0;visibility:hidden;width:100%}.fw-image--loaded-error img{display:none}.fw-image--loaded-error .fw-image--error{opacity:1;visibility:visible}.fw-image--background{background-position:50%;background-repeat:no-repeat;background-size:cover}";
843
+ var stylesheet = ".fw-image{position:relative}.fw-image img{-webkit-transition:all .5s ease-in-out;-o-transition:all .5s ease-in-out;transition:all .5s ease-in-out}.fw-image img,.fw-image--error{opacity:0;visibility:hidden;width:100%}.fw-image--error{height:100%;left:0;position:relative;position:absolute;top:0;-webkit-transition:all .5s ease-in;-o-transition:all .5s ease-in;transition:all .5s ease-in}.fw-image--error-wrapper{font-size:inherit;left:50%;position:absolute;text-align:center;top:50%;-webkit-transform:translate(-50%,-50%);-ms-transform:translate(-50%,-50%);transform:translate(-50%,-50%);width:100%}.fw-image--loading{height:100%;left:0;position:absolute!important;top:0;-webkit-transition:all .5s ease-in-out;-o-transition:all .5s ease-in-out;transition:all .5s ease-in-out;width:100%}.fw-image--loaded img,.fw-image--loading{opacity:1;visibility:visible}.fw-image--loaded .fw-image--loading{opacity:0;visibility:hidden;width:100%}.fw-image--loaded-error img{display:none}.fw-image--loaded-error .fw-image--error{opacity:1;visibility:visible}.fw-image--background{background-position:50%;background-repeat:no-repeat;background-size:cover}";
844
+ styleInject(css_248z);
845
+
846
+ script.render = render;
847
+
848
+ export { script as FwImage };