@frollo/frollo-web-ui 0.0.22 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/index.js +635 -421
- package/esm/{add-to-unscopables-c6a09beb.js → add-to-unscopables-81c17489.js} +139 -99
- package/esm/{es.array.includes-1b7043c3.js → es.array.includes-debcb50f.js} +9 -3
- package/esm/{es.function.name-f416c9da.js → es.function.name-e746680f.js} +1 -1
- package/esm/{function-name-982253be.js → function-name-f0c1223e.js} +52 -61
- package/esm/{fw-button-0826e6fc.js → fw-button-ab906734.js} +12 -4
- package/esm/fw-button.js +4 -4
- package/esm/fw-card.js +6 -3
- package/esm/fw-checkbox.js +13 -8
- package/esm/fw-form.js +1 -1
- package/esm/fw-input.js +21 -11
- package/esm/fw-modal.js +7 -475
- package/esm/fw-navigation-menu.js +80 -24
- package/esm/fw-tabs.js +4 -3
- package/esm/{index-9de6159f.js → index-5ee56f7d.js} +24 -75
- package/esm/index-963039a3.js +475 -0
- package/esm/index.js +128 -40
- package/esm/to-string-139f1ee8.js +52 -0
- package/esm/{vee-validate.esm-028c6424.js → vee-validate.esm-b64acab1.js} +62 -9
- package/frollo-web-ui.esm.js +669 -421
- package/index.d.ts +28 -11
- package/package.json +20 -17
- package/tailwind.config.js +8 -8
- package/types/components/fw-button/fw-button.vue.d.ts +1 -0
- package/types/components/fw-card/fw-card.vue.d.ts +1 -0
- package/types/components/fw-checkbox/fw-checkbox.vue.d.ts +5 -4
- package/types/components/fw-checkbox/index.types.d.ts +1 -1
- package/types/components/fw-input/fw-input.vue.d.ts +17 -4
- package/types/components/fw-input/index.types.d.ts +1 -1
- package/types/components/fw-navigation-menu/fw-navigation-menu.vue.d.ts +3 -0
- package/types/index.esm.d.ts +1 -1
- package/types/services/modal.d.ts +1 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { b as functionUncurryThis,
|
|
2
|
-
import { b as classofRaw
|
|
1
|
+
import { b as functionUncurryThis, h as aCallable$1, c as functionBindNative, f as fails$2, i as isCallable$3, j as getBuiltIn$1, k as isObject$2, w as wellKnownSymbol$1, t as toObject$1, l as anObject$1, r as requireObjectCoercible$1, a as descriptors, g as global$1, m as hasOwnProperty_1, o as objectIsPrototypeOf, n as isSymbol$1, p as toPrimitive$1, q as objectDefineProperty } from './function-name-f0c1223e.js';
|
|
2
|
+
import { b as classofRaw, i as inspectSource$1, e as indexedObject, l as lengthOfArrayLike$1, f as isForced_1, d as defineBuiltIn$1, g as objectGetOwnPropertyNames, h as objectGetOwnPropertyDescriptor, _ as _export, j as addToUnscopables$1 } from './add-to-unscopables-81c17489.js';
|
|
3
|
+
import { c as classof$2, a as toString$1 } from './to-string-139f1ee8.js';
|
|
3
4
|
import { defineComponent, computed, ref, provide, openBlock, createElementBlock, Fragment, renderList, createElementVNode, normalizeClass, toDisplayString, createCommentVNode, renderSlot, getCurrentInstance, inject, watchEffect } from 'vue';
|
|
4
5
|
|
|
5
6
|
var uncurryThis$6 = functionUncurryThis;
|
|
@@ -16,59 +17,19 @@ var functionBindContext = function (fn, that) {
|
|
|
16
17
|
};
|
|
17
18
|
};
|
|
18
19
|
|
|
19
|
-
var classof$
|
|
20
|
+
var classof$1 = classofRaw;
|
|
20
21
|
|
|
21
22
|
// `IsArray` abstract operation
|
|
22
23
|
// https://tc39.es/ecma262/#sec-isarray
|
|
23
|
-
// eslint-disable-next-line es/no-array-isarray -- safe
|
|
24
|
+
// eslint-disable-next-line es-x/no-array-isarray -- safe
|
|
24
25
|
var isArray$1 = Array.isArray || function isArray(argument) {
|
|
25
|
-
return classof$
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
var wellKnownSymbol$2 = wellKnownSymbol$3;
|
|
29
|
-
|
|
30
|
-
var TO_STRING_TAG$1 = wellKnownSymbol$2('toStringTag');
|
|
31
|
-
var test = {};
|
|
32
|
-
|
|
33
|
-
test[TO_STRING_TAG$1] = 'z';
|
|
34
|
-
|
|
35
|
-
var toStringTagSupport = String(test) === '[object z]';
|
|
36
|
-
|
|
37
|
-
var global$4 = global$5;
|
|
38
|
-
var TO_STRING_TAG_SUPPORT = toStringTagSupport;
|
|
39
|
-
var isCallable$3 = isCallable$4;
|
|
40
|
-
var classofRaw = classofRaw$1;
|
|
41
|
-
var wellKnownSymbol$1 = wellKnownSymbol$3;
|
|
42
|
-
|
|
43
|
-
var TO_STRING_TAG = wellKnownSymbol$1('toStringTag');
|
|
44
|
-
var Object$1 = global$4.Object;
|
|
45
|
-
|
|
46
|
-
// ES3 wrong here
|
|
47
|
-
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';
|
|
48
|
-
|
|
49
|
-
// fallback for IE11 Script Access Denied error
|
|
50
|
-
var tryGet = function (it, key) {
|
|
51
|
-
try {
|
|
52
|
-
return it[key];
|
|
53
|
-
} catch (error) { /* empty */ }
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
// getting tag from ES6+ `Object.prototype.toString`
|
|
57
|
-
var classof$2 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
|
|
58
|
-
var O, tag, result;
|
|
59
|
-
return it === undefined ? 'Undefined' : it === null ? 'Null'
|
|
60
|
-
// @@toStringTag case
|
|
61
|
-
: typeof (tag = tryGet(O = Object$1(it), TO_STRING_TAG)) == 'string' ? tag
|
|
62
|
-
// builtinTag case
|
|
63
|
-
: CORRECT_ARGUMENTS ? classofRaw(O)
|
|
64
|
-
// ES3 arguments fallback
|
|
65
|
-
: (result = classofRaw(O)) == 'Object' && isCallable$3(O.callee) ? 'Arguments' : result;
|
|
26
|
+
return classof$1(argument) == 'Array';
|
|
66
27
|
};
|
|
67
28
|
|
|
68
29
|
var uncurryThis$5 = functionUncurryThis;
|
|
69
30
|
var fails$1 = fails$2;
|
|
70
|
-
var isCallable$2 = isCallable$
|
|
71
|
-
var classof
|
|
31
|
+
var isCallable$2 = isCallable$3;
|
|
32
|
+
var classof = classof$2;
|
|
72
33
|
var getBuiltIn = getBuiltIn$1;
|
|
73
34
|
var inspectSource = inspectSource$1;
|
|
74
35
|
|
|
@@ -91,7 +52,7 @@ var isConstructorModern = function isConstructor(argument) {
|
|
|
91
52
|
|
|
92
53
|
var isConstructorLegacy = function isConstructor(argument) {
|
|
93
54
|
if (!isCallable$2(argument)) return false;
|
|
94
|
-
switch (classof
|
|
55
|
+
switch (classof(argument)) {
|
|
95
56
|
case 'AsyncFunction':
|
|
96
57
|
case 'GeneratorFunction':
|
|
97
58
|
case 'AsyncGeneratorFunction': return false;
|
|
@@ -118,14 +79,13 @@ var isConstructor$1 = !construct || fails$1(function () {
|
|
|
118
79
|
|| called;
|
|
119
80
|
}) ? isConstructorLegacy : isConstructorModern;
|
|
120
81
|
|
|
121
|
-
var global$3 = global$5;
|
|
122
82
|
var isArray = isArray$1;
|
|
123
83
|
var isConstructor = isConstructor$1;
|
|
124
84
|
var isObject$1 = isObject$2;
|
|
125
|
-
var wellKnownSymbol = wellKnownSymbol$
|
|
85
|
+
var wellKnownSymbol = wellKnownSymbol$1;
|
|
126
86
|
|
|
127
87
|
var SPECIES = wellKnownSymbol('species');
|
|
128
|
-
var Array
|
|
88
|
+
var $Array = Array;
|
|
129
89
|
|
|
130
90
|
// a part of `ArraySpeciesCreate` abstract operation
|
|
131
91
|
// https://tc39.es/ecma262/#sec-arrayspeciescreate
|
|
@@ -134,12 +94,12 @@ var arraySpeciesConstructor$1 = function (originalArray) {
|
|
|
134
94
|
if (isArray(originalArray)) {
|
|
135
95
|
C = originalArray.constructor;
|
|
136
96
|
// cross-realm fallback
|
|
137
|
-
if (isConstructor(C) && (C === Array
|
|
97
|
+
if (isConstructor(C) && (C === $Array || isArray(C.prototype))) C = undefined;
|
|
138
98
|
else if (isObject$1(C)) {
|
|
139
99
|
C = C[SPECIES];
|
|
140
100
|
if (C === null) C = undefined;
|
|
141
101
|
}
|
|
142
|
-
} return C === undefined ? Array
|
|
102
|
+
} return C === undefined ? $Array : C;
|
|
143
103
|
};
|
|
144
104
|
|
|
145
105
|
var arraySpeciesConstructor = arraySpeciesConstructor$1;
|
|
@@ -226,15 +186,14 @@ var arrayIteration = {
|
|
|
226
186
|
|
|
227
187
|
var es_number_constructor = {};
|
|
228
188
|
|
|
229
|
-
var
|
|
230
|
-
var isCallable$1 = isCallable$4;
|
|
189
|
+
var isCallable$1 = isCallable$3;
|
|
231
190
|
|
|
232
|
-
var String
|
|
233
|
-
var TypeError
|
|
191
|
+
var $String = String;
|
|
192
|
+
var $TypeError = TypeError;
|
|
234
193
|
|
|
235
194
|
var aPossiblePrototype$1 = function (argument) {
|
|
236
195
|
if (typeof argument == 'object' || isCallable$1(argument)) return argument;
|
|
237
|
-
throw TypeError
|
|
196
|
+
throw $TypeError("Can't set " + $String(argument) + ' as a prototype');
|
|
238
197
|
};
|
|
239
198
|
|
|
240
199
|
/* eslint-disable no-proto -- safe */
|
|
@@ -246,13 +205,13 @@ var aPossiblePrototype = aPossiblePrototype$1;
|
|
|
246
205
|
// `Object.setPrototypeOf` method
|
|
247
206
|
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
248
207
|
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
249
|
-
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
208
|
+
// eslint-disable-next-line es-x/no-object-setprototypeof -- safe
|
|
250
209
|
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
251
210
|
var CORRECT_SETTER = false;
|
|
252
211
|
var test = {};
|
|
253
212
|
var setter;
|
|
254
213
|
try {
|
|
255
|
-
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
214
|
+
// eslint-disable-next-line es-x/no-object-getownpropertydescriptor -- safe
|
|
256
215
|
setter = uncurryThis$3(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
|
|
257
216
|
setter(test, []);
|
|
258
217
|
CORRECT_SETTER = test instanceof Array;
|
|
@@ -266,7 +225,7 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
|
|
|
266
225
|
};
|
|
267
226
|
}() : undefined);
|
|
268
227
|
|
|
269
|
-
var isCallable = isCallable$
|
|
228
|
+
var isCallable = isCallable$3;
|
|
270
229
|
var isObject = isObject$2;
|
|
271
230
|
var setPrototypeOf = objectSetPrototypeOf;
|
|
272
231
|
|
|
@@ -291,16 +250,6 @@ var uncurryThis$2 = functionUncurryThis;
|
|
|
291
250
|
// https://tc39.es/ecma262/#sec-thisnumbervalue
|
|
292
251
|
var thisNumberValue$1 = uncurryThis$2(1.0.valueOf);
|
|
293
252
|
|
|
294
|
-
var global$1 = global$5;
|
|
295
|
-
var classof = classof$2;
|
|
296
|
-
|
|
297
|
-
var String$1 = global$1.String;
|
|
298
|
-
|
|
299
|
-
var toString$1 = function (argument) {
|
|
300
|
-
if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');
|
|
301
|
-
return String$1(argument);
|
|
302
|
-
};
|
|
303
|
-
|
|
304
253
|
// a string of all valid unicode whitespaces
|
|
305
254
|
var whitespaces$1 = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
|
|
306
255
|
'\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';
|
|
@@ -339,10 +288,10 @@ var stringTrim = {
|
|
|
339
288
|
|
|
340
289
|
'use strict';
|
|
341
290
|
var DESCRIPTORS = descriptors;
|
|
342
|
-
var global = global$
|
|
291
|
+
var global = global$1;
|
|
343
292
|
var uncurryThis = functionUncurryThis;
|
|
344
293
|
var isForced = isForced_1;
|
|
345
|
-
var
|
|
294
|
+
var defineBuiltIn = defineBuiltIn$1;
|
|
346
295
|
var hasOwn = hasOwnProperty_1;
|
|
347
296
|
var inheritIfRequired = inheritIfRequired$1;
|
|
348
297
|
var isPrototypeOf = objectIsPrototypeOf;
|
|
@@ -423,7 +372,7 @@ if (isForced(NUMBER, !NativeNumber(' 0o1') || !NativeNumber('0b1') || NativeNumb
|
|
|
423
372
|
}
|
|
424
373
|
NumberWrapper.prototype = NumberPrototype;
|
|
425
374
|
NumberPrototype.constructor = NumberWrapper;
|
|
426
|
-
|
|
375
|
+
defineBuiltIn(global, NUMBER, NumberWrapper, { constructor: true });
|
|
427
376
|
}
|
|
428
377
|
|
|
429
378
|
var script$1 = defineComponent({
|
|
@@ -562,4 +511,4 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
562
511
|
|
|
563
512
|
script.render = render;
|
|
564
513
|
|
|
565
|
-
export { arrayIteration as a, script as b,
|
|
514
|
+
export { arrayIteration as a, script as b, script$1 as s };
|
|
@@ -0,0 +1,475 @@
|
|
|
1
|
+
import './es.array.includes-debcb50f.js';
|
|
2
|
+
import { defineComponent, pushScopeId, popScopeId, resolveComponent, openBlock, createBlock, Transition, withCtx, createElementVNode, createElementBlock, renderSlot, createCommentVNode, createTextVNode, toDisplayString } from 'vue';
|
|
3
|
+
import { s as script$1 } from './fw-button-ab906734.js';
|
|
4
|
+
import { s as styleInject } from './style-inject.es-1f59c1d0.js';
|
|
5
|
+
|
|
6
|
+
/** Detect free variable `global` from Node.js. */
|
|
7
|
+
var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;
|
|
8
|
+
|
|
9
|
+
/** Detect free variable `self`. */
|
|
10
|
+
var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
|
|
11
|
+
|
|
12
|
+
/** Used as a reference to the global object. */
|
|
13
|
+
var root = freeGlobal || freeSelf || Function('return this')();
|
|
14
|
+
|
|
15
|
+
/** Built-in value references. */
|
|
16
|
+
var Symbol = root.Symbol;
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* A specialized version of `_.map` for arrays without support for iteratee
|
|
20
|
+
* shorthands.
|
|
21
|
+
*
|
|
22
|
+
* @private
|
|
23
|
+
* @param {Array} [array] The array to iterate over.
|
|
24
|
+
* @param {Function} iteratee The function invoked per iteration.
|
|
25
|
+
* @returns {Array} Returns the new mapped array.
|
|
26
|
+
*/
|
|
27
|
+
function arrayMap(array, iteratee) {
|
|
28
|
+
var index = -1,
|
|
29
|
+
length = array == null ? 0 : array.length,
|
|
30
|
+
result = Array(length);
|
|
31
|
+
|
|
32
|
+
while (++index < length) {
|
|
33
|
+
result[index] = iteratee(array[index], index, array);
|
|
34
|
+
}
|
|
35
|
+
return result;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Checks if `value` is classified as an `Array` object.
|
|
40
|
+
*
|
|
41
|
+
* @static
|
|
42
|
+
* @memberOf _
|
|
43
|
+
* @since 0.1.0
|
|
44
|
+
* @category Lang
|
|
45
|
+
* @param {*} value The value to check.
|
|
46
|
+
* @returns {boolean} Returns `true` if `value` is an array, else `false`.
|
|
47
|
+
* @example
|
|
48
|
+
*
|
|
49
|
+
* _.isArray([1, 2, 3]);
|
|
50
|
+
* // => true
|
|
51
|
+
*
|
|
52
|
+
* _.isArray(document.body.children);
|
|
53
|
+
* // => false
|
|
54
|
+
*
|
|
55
|
+
* _.isArray('abc');
|
|
56
|
+
* // => false
|
|
57
|
+
*
|
|
58
|
+
* _.isArray(_.noop);
|
|
59
|
+
* // => false
|
|
60
|
+
*/
|
|
61
|
+
var isArray = Array.isArray;
|
|
62
|
+
|
|
63
|
+
/** Used for built-in method references. */
|
|
64
|
+
var objectProto$1 = Object.prototype;
|
|
65
|
+
|
|
66
|
+
/** Used to check objects for own properties. */
|
|
67
|
+
var hasOwnProperty = objectProto$1.hasOwnProperty;
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Used to resolve the
|
|
71
|
+
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
72
|
+
* of values.
|
|
73
|
+
*/
|
|
74
|
+
var nativeObjectToString$1 = objectProto$1.toString;
|
|
75
|
+
|
|
76
|
+
/** Built-in value references. */
|
|
77
|
+
var symToStringTag$1 = Symbol ? Symbol.toStringTag : undefined;
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
|
|
81
|
+
*
|
|
82
|
+
* @private
|
|
83
|
+
* @param {*} value The value to query.
|
|
84
|
+
* @returns {string} Returns the raw `toStringTag`.
|
|
85
|
+
*/
|
|
86
|
+
function getRawTag(value) {
|
|
87
|
+
var isOwn = hasOwnProperty.call(value, symToStringTag$1),
|
|
88
|
+
tag = value[symToStringTag$1];
|
|
89
|
+
|
|
90
|
+
try {
|
|
91
|
+
value[symToStringTag$1] = undefined;
|
|
92
|
+
var unmasked = true;
|
|
93
|
+
} catch (e) {}
|
|
94
|
+
|
|
95
|
+
var result = nativeObjectToString$1.call(value);
|
|
96
|
+
if (unmasked) {
|
|
97
|
+
if (isOwn) {
|
|
98
|
+
value[symToStringTag$1] = tag;
|
|
99
|
+
} else {
|
|
100
|
+
delete value[symToStringTag$1];
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
return result;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
/** Used for built-in method references. */
|
|
107
|
+
var objectProto = Object.prototype;
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Used to resolve the
|
|
111
|
+
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
112
|
+
* of values.
|
|
113
|
+
*/
|
|
114
|
+
var nativeObjectToString = objectProto.toString;
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* Converts `value` to a string using `Object.prototype.toString`.
|
|
118
|
+
*
|
|
119
|
+
* @private
|
|
120
|
+
* @param {*} value The value to convert.
|
|
121
|
+
* @returns {string} Returns the converted string.
|
|
122
|
+
*/
|
|
123
|
+
function objectToString(value) {
|
|
124
|
+
return nativeObjectToString.call(value);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/** `Object#toString` result references. */
|
|
128
|
+
var nullTag = '[object Null]',
|
|
129
|
+
undefinedTag = '[object Undefined]';
|
|
130
|
+
|
|
131
|
+
/** Built-in value references. */
|
|
132
|
+
var symToStringTag = Symbol ? Symbol.toStringTag : undefined;
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* The base implementation of `getTag` without fallbacks for buggy environments.
|
|
136
|
+
*
|
|
137
|
+
* @private
|
|
138
|
+
* @param {*} value The value to query.
|
|
139
|
+
* @returns {string} Returns the `toStringTag`.
|
|
140
|
+
*/
|
|
141
|
+
function baseGetTag(value) {
|
|
142
|
+
if (value == null) {
|
|
143
|
+
return value === undefined ? undefinedTag : nullTag;
|
|
144
|
+
}
|
|
145
|
+
return (symToStringTag && symToStringTag in Object(value))
|
|
146
|
+
? getRawTag(value)
|
|
147
|
+
: objectToString(value);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* Checks if `value` is object-like. A value is object-like if it's not `null`
|
|
152
|
+
* and has a `typeof` result of "object".
|
|
153
|
+
*
|
|
154
|
+
* @static
|
|
155
|
+
* @memberOf _
|
|
156
|
+
* @since 4.0.0
|
|
157
|
+
* @category Lang
|
|
158
|
+
* @param {*} value The value to check.
|
|
159
|
+
* @returns {boolean} Returns `true` if `value` is object-like, else `false`.
|
|
160
|
+
* @example
|
|
161
|
+
*
|
|
162
|
+
* _.isObjectLike({});
|
|
163
|
+
* // => true
|
|
164
|
+
*
|
|
165
|
+
* _.isObjectLike([1, 2, 3]);
|
|
166
|
+
* // => true
|
|
167
|
+
*
|
|
168
|
+
* _.isObjectLike(_.noop);
|
|
169
|
+
* // => false
|
|
170
|
+
*
|
|
171
|
+
* _.isObjectLike(null);
|
|
172
|
+
* // => false
|
|
173
|
+
*/
|
|
174
|
+
function isObjectLike(value) {
|
|
175
|
+
return value != null && typeof value == 'object';
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
/** `Object#toString` result references. */
|
|
179
|
+
var symbolTag = '[object Symbol]';
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* Checks if `value` is classified as a `Symbol` primitive or object.
|
|
183
|
+
*
|
|
184
|
+
* @static
|
|
185
|
+
* @memberOf _
|
|
186
|
+
* @since 4.0.0
|
|
187
|
+
* @category Lang
|
|
188
|
+
* @param {*} value The value to check.
|
|
189
|
+
* @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
|
|
190
|
+
* @example
|
|
191
|
+
*
|
|
192
|
+
* _.isSymbol(Symbol.iterator);
|
|
193
|
+
* // => true
|
|
194
|
+
*
|
|
195
|
+
* _.isSymbol('abc');
|
|
196
|
+
* // => false
|
|
197
|
+
*/
|
|
198
|
+
function isSymbol(value) {
|
|
199
|
+
return typeof value == 'symbol' ||
|
|
200
|
+
(isObjectLike(value) && baseGetTag(value) == symbolTag);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
/** Used as references for various `Number` constants. */
|
|
204
|
+
var INFINITY = 1 / 0;
|
|
205
|
+
|
|
206
|
+
/** Used to convert symbols to primitives and strings. */
|
|
207
|
+
var symbolProto = Symbol ? Symbol.prototype : undefined,
|
|
208
|
+
symbolToString = symbolProto ? symbolProto.toString : undefined;
|
|
209
|
+
|
|
210
|
+
/**
|
|
211
|
+
* The base implementation of `_.toString` which doesn't convert nullish
|
|
212
|
+
* values to empty strings.
|
|
213
|
+
*
|
|
214
|
+
* @private
|
|
215
|
+
* @param {*} value The value to process.
|
|
216
|
+
* @returns {string} Returns the string.
|
|
217
|
+
*/
|
|
218
|
+
function baseToString(value) {
|
|
219
|
+
// Exit early for strings to avoid a performance hit in some environments.
|
|
220
|
+
if (typeof value == 'string') {
|
|
221
|
+
return value;
|
|
222
|
+
}
|
|
223
|
+
if (isArray(value)) {
|
|
224
|
+
// Recursively convert values (susceptible to call stack limits).
|
|
225
|
+
return arrayMap(value, baseToString) + '';
|
|
226
|
+
}
|
|
227
|
+
if (isSymbol(value)) {
|
|
228
|
+
return symbolToString ? symbolToString.call(value) : '';
|
|
229
|
+
}
|
|
230
|
+
var result = (value + '');
|
|
231
|
+
return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
/**
|
|
235
|
+
* Converts `value` to a string. An empty string is returned for `null`
|
|
236
|
+
* and `undefined` values. The sign of `-0` is preserved.
|
|
237
|
+
*
|
|
238
|
+
* @static
|
|
239
|
+
* @memberOf _
|
|
240
|
+
* @since 4.0.0
|
|
241
|
+
* @category Lang
|
|
242
|
+
* @param {*} value The value to convert.
|
|
243
|
+
* @returns {string} Returns the converted string.
|
|
244
|
+
* @example
|
|
245
|
+
*
|
|
246
|
+
* _.toString(null);
|
|
247
|
+
* // => ''
|
|
248
|
+
*
|
|
249
|
+
* _.toString(-0);
|
|
250
|
+
* // => '-0'
|
|
251
|
+
*
|
|
252
|
+
* _.toString([1, 2, 3]);
|
|
253
|
+
* // => '1,2,3'
|
|
254
|
+
*/
|
|
255
|
+
function toString(value) {
|
|
256
|
+
return value == null ? '' : baseToString(value);
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
/** Used to generate unique IDs. */
|
|
260
|
+
var idCounter = 0;
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* Generates a unique ID. If `prefix` is given, the ID is appended to it.
|
|
264
|
+
*
|
|
265
|
+
* @static
|
|
266
|
+
* @since 0.1.0
|
|
267
|
+
* @memberOf _
|
|
268
|
+
* @category Util
|
|
269
|
+
* @param {string} [prefix=''] The value to prefix the ID with.
|
|
270
|
+
* @returns {string} Returns the unique ID.
|
|
271
|
+
* @example
|
|
272
|
+
*
|
|
273
|
+
* _.uniqueId('contact_');
|
|
274
|
+
* // => 'contact_104'
|
|
275
|
+
*
|
|
276
|
+
* _.uniqueId();
|
|
277
|
+
* // => '105'
|
|
278
|
+
*/
|
|
279
|
+
function uniqueId(prefix) {
|
|
280
|
+
var id = ++idCounter;
|
|
281
|
+
return toString(prefix) + id;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
var script = defineComponent({
|
|
285
|
+
name: 'FwModal',
|
|
286
|
+
components: {
|
|
287
|
+
FwButton: script$1
|
|
288
|
+
},
|
|
289
|
+
emits: ['cancel', 'confirm'],
|
|
290
|
+
props: {
|
|
291
|
+
/**
|
|
292
|
+
* The header title of the modal
|
|
293
|
+
*/
|
|
294
|
+
header: {
|
|
295
|
+
type: String
|
|
296
|
+
},
|
|
297
|
+
|
|
298
|
+
/**
|
|
299
|
+
* The body description of the modal
|
|
300
|
+
*/
|
|
301
|
+
body: {
|
|
302
|
+
type: String
|
|
303
|
+
},
|
|
304
|
+
|
|
305
|
+
/**
|
|
306
|
+
* The aria role of the modal container. Defaults to `dialog`
|
|
307
|
+
*/
|
|
308
|
+
role: {
|
|
309
|
+
type: String,
|
|
310
|
+
"default": 'dialog'
|
|
311
|
+
},
|
|
312
|
+
|
|
313
|
+
/**
|
|
314
|
+
* Whether to show the cancel button
|
|
315
|
+
*/
|
|
316
|
+
showCancel: {
|
|
317
|
+
type: Boolean,
|
|
318
|
+
"default": false
|
|
319
|
+
},
|
|
320
|
+
|
|
321
|
+
/**
|
|
322
|
+
* Whether to show the confirm button
|
|
323
|
+
*/
|
|
324
|
+
showConfirm: {
|
|
325
|
+
type: Boolean,
|
|
326
|
+
"default": true
|
|
327
|
+
},
|
|
328
|
+
|
|
329
|
+
/**
|
|
330
|
+
* Custom text for the cancel button
|
|
331
|
+
*/
|
|
332
|
+
cancelButtonText: {
|
|
333
|
+
type: String,
|
|
334
|
+
"default": 'Cancel'
|
|
335
|
+
},
|
|
336
|
+
|
|
337
|
+
/**
|
|
338
|
+
* Button variant for the cancel button
|
|
339
|
+
*/
|
|
340
|
+
cancelButtonType: {
|
|
341
|
+
type: String,
|
|
342
|
+
"default": 'secondary',
|
|
343
|
+
validator: function validator(value) {
|
|
344
|
+
return ['primary', 'secondary', 'tertiary', 'error', 'success', 'link', 'text'].includes(value);
|
|
345
|
+
}
|
|
346
|
+
},
|
|
347
|
+
|
|
348
|
+
/**
|
|
349
|
+
* Custom text for the confirm button
|
|
350
|
+
*/
|
|
351
|
+
confirmButtonText: {
|
|
352
|
+
type: String,
|
|
353
|
+
"default": 'Confirm'
|
|
354
|
+
},
|
|
355
|
+
|
|
356
|
+
/**
|
|
357
|
+
* Button variant for the confirm button
|
|
358
|
+
*/
|
|
359
|
+
confirmButtonType: {
|
|
360
|
+
type: String,
|
|
361
|
+
"default": 'primary',
|
|
362
|
+
validator: function validator(value) {
|
|
363
|
+
return ['primary', 'secondary', 'tertiary', 'error', 'success', 'link', 'text'].includes(value);
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
},
|
|
367
|
+
setup: function setup() {
|
|
368
|
+
var uuid = uniqueId();
|
|
369
|
+
return {
|
|
370
|
+
uuid: uuid
|
|
371
|
+
};
|
|
372
|
+
}
|
|
373
|
+
});
|
|
374
|
+
|
|
375
|
+
var _withScopeId = function _withScopeId(n) {
|
|
376
|
+
return pushScopeId("data-v-003a6fba"), n = n(), popScopeId(), n;
|
|
377
|
+
};
|
|
378
|
+
|
|
379
|
+
var _hoisted_1 = {
|
|
380
|
+
"class": "fw-modal"
|
|
381
|
+
};
|
|
382
|
+
var _hoisted_2 = {
|
|
383
|
+
"class": "fw-modal--mask fixed z-[9999] top-0 left-0 w-full h-full bg-black bg-opacity-50"
|
|
384
|
+
};
|
|
385
|
+
var _hoisted_3 = {
|
|
386
|
+
"class": "fw-modal--wrapper text-center overflow-auto flex justify-center items-center h-full"
|
|
387
|
+
};
|
|
388
|
+
var _hoisted_4 = ["role", "aria-labelledby", "aria-describedby"];
|
|
389
|
+
var _hoisted_5 = {
|
|
390
|
+
key: 0,
|
|
391
|
+
"class": "fw-modal--header text-center"
|
|
392
|
+
};
|
|
393
|
+
var _hoisted_6 = {
|
|
394
|
+
key: 0,
|
|
395
|
+
id: "modal-logo",
|
|
396
|
+
"class": "flex justify-center"
|
|
397
|
+
};
|
|
398
|
+
var _hoisted_7 = ["id"];
|
|
399
|
+
var _hoisted_8 = ["id", "innerHTML"];
|
|
400
|
+
var _hoisted_9 = ["id"];
|
|
401
|
+
var _hoisted_10 = ["innerHTML", "id"];
|
|
402
|
+
var _hoisted_11 = {
|
|
403
|
+
key: 3,
|
|
404
|
+
"class": "modal-footer flex space-x-4 pt-4 justify-center"
|
|
405
|
+
};
|
|
406
|
+
function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
407
|
+
var _component_FwButton = resolveComponent("FwButton");
|
|
408
|
+
|
|
409
|
+
return openBlock(), createBlock(Transition, {
|
|
410
|
+
name: "modalFadeIn",
|
|
411
|
+
appear: ""
|
|
412
|
+
}, {
|
|
413
|
+
"default": withCtx(function () {
|
|
414
|
+
return [createElementVNode("div", _hoisted_1, [createElementVNode("div", _hoisted_2, [createElementVNode("div", _hoisted_3, [createElementVNode("div", {
|
|
415
|
+
role: _ctx.role,
|
|
416
|
+
"aria-modal": "true",
|
|
417
|
+
"class": "fw-modal--container p-12 m-8 inline-block w-full max-w-[540px] bg-white rounded-2xl shadow",
|
|
418
|
+
"aria-labelledby": _ctx.$slots.header || _ctx.header ? "modal_".concat(_ctx.uuid, "_header") : undefined,
|
|
419
|
+
"aria-describedby": _ctx.$slots.body ? "modal_".concat(_ctx.uuid, "_body") : undefined
|
|
420
|
+
}, [_ctx.$slots.icon || _ctx.$slots.header || _ctx.header ? (openBlock(), createElementBlock("div", _hoisted_5, [_ctx.$slots.icon ? (openBlock(), createElementBlock("div", _hoisted_6, [renderSlot(_ctx.$slots, "icon")])) : createCommentVNode("", true), _ctx.$slots.header ? (openBlock(), createElementBlock("h2", {
|
|
421
|
+
key: 1,
|
|
422
|
+
id: "modal_".concat(_ctx.uuid, "_header")
|
|
423
|
+
}, [renderSlot(_ctx.$slots, "header")], 8, _hoisted_7)) : _ctx.header ? (openBlock(), createElementBlock("h2", {
|
|
424
|
+
key: 2,
|
|
425
|
+
id: "modal_".concat(_ctx.uuid, "_header"),
|
|
426
|
+
innerHTML: _ctx.header
|
|
427
|
+
}, null, 8, _hoisted_8)) : createCommentVNode("", true)])) : createCommentVNode("", true), _ctx.$slots.body ? (openBlock(), createElementBlock("div", {
|
|
428
|
+
key: 1,
|
|
429
|
+
"class": "modal-body mt-4",
|
|
430
|
+
id: "modal_".concat(_ctx.uuid, "_body")
|
|
431
|
+
}, [renderSlot(_ctx.$slots, "body")], 8, _hoisted_9)) : _ctx.body ? (openBlock(), createElementBlock("div", {
|
|
432
|
+
key: 2,
|
|
433
|
+
innerHTML: _ctx.body,
|
|
434
|
+
"class": "modal-body mt-4",
|
|
435
|
+
id: "modal_".concat(_ctx.uuid, "_body")
|
|
436
|
+
}, null, 8, _hoisted_10)) : createCommentVNode("", true), _ctx.showConfirm || _ctx.showCancel ? (openBlock(), createElementBlock("div", _hoisted_11, [_ctx.showCancel ? (openBlock(), createBlock(_component_FwButton, {
|
|
437
|
+
key: 0,
|
|
438
|
+
"class": "basis-1/2",
|
|
439
|
+
variant: _ctx.cancelButtonType,
|
|
440
|
+
"aria-label": _ctx.cancelButtonText,
|
|
441
|
+
onClick: _cache[0] || (_cache[0] = function ($event) {
|
|
442
|
+
return _ctx.$emit('cancel');
|
|
443
|
+
})
|
|
444
|
+
}, {
|
|
445
|
+
"default": withCtx(function () {
|
|
446
|
+
return [createTextVNode(toDisplayString(_ctx.cancelButtonText), 1)];
|
|
447
|
+
}),
|
|
448
|
+
_: 1
|
|
449
|
+
}, 8, ["variant", "aria-label"])) : createCommentVNode("", true), _ctx.showConfirm ? (openBlock(), createBlock(_component_FwButton, {
|
|
450
|
+
key: 1,
|
|
451
|
+
"class": "basis-1/2",
|
|
452
|
+
variant: _ctx.confirmButtonType,
|
|
453
|
+
"aria-label": _ctx.confirmButtonText,
|
|
454
|
+
onClick: _cache[1] || (_cache[1] = function ($event) {
|
|
455
|
+
return _ctx.$emit('confirm');
|
|
456
|
+
})
|
|
457
|
+
}, {
|
|
458
|
+
"default": withCtx(function () {
|
|
459
|
+
return [createTextVNode(toDisplayString(_ctx.confirmButtonText), 1)];
|
|
460
|
+
}),
|
|
461
|
+
_: 1
|
|
462
|
+
}, 8, ["variant", "aria-label"])) : createCommentVNode("", true)])) : createCommentVNode("", true)], 8, _hoisted_4)])])])];
|
|
463
|
+
}),
|
|
464
|
+
_: 3
|
|
465
|
+
});
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
var css_248z = ".modalFadeIn-enter-active[data-v-003a6fba]{-webkit-animation:modalFadeIn-003a6fba .4s;animation:modalFadeIn-003a6fba .4s;-webkit-transition:opacity .4s ease-in;-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}.modalFadeIn-leave-active[data-v-003a6fba]{animation:modalFadeIn-003a6fba .4s reverse;-webkit-transition:opacity .4s ease-out;-o-transition:opacity .4s ease-out;transition:opacity .4s ease-out}@-webkit-keyframes modalFadeIn-003a6fba{0%{opacity:0}to{opacity:1}}@keyframes modalFadeIn-003a6fba{0%{opacity:0}to{opacity:1}}";
|
|
469
|
+
var stylesheet = ".modalFadeIn-enter-active[data-v-003a6fba]{-webkit-animation:modalFadeIn-003a6fba .4s;animation:modalFadeIn-003a6fba .4s;-webkit-transition:opacity .4s ease-in;-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}.modalFadeIn-leave-active[data-v-003a6fba]{animation:modalFadeIn-003a6fba .4s reverse;-webkit-transition:opacity .4s ease-out;-o-transition:opacity .4s ease-out;transition:opacity .4s ease-out}@-webkit-keyframes modalFadeIn-003a6fba{0%{opacity:0}to{opacity:1}}@keyframes modalFadeIn-003a6fba{0%{opacity:0}to{opacity:1}}";
|
|
470
|
+
styleInject(css_248z);
|
|
471
|
+
|
|
472
|
+
script.render = render;
|
|
473
|
+
script.__scopeId = "data-v-003a6fba";
|
|
474
|
+
|
|
475
|
+
export { script as s, uniqueId as u };
|