@tailor-cms/ce-accordion-edit 0.0.15 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/AccordionItem.vue.d.ts +30 -0
- package/dist/components/Edit.vue.d.ts +14 -0
- package/dist/index.cjs +1197 -1616
- package/dist/{style.css → index.css} +7 -7
- package/dist/index.d.ts +5 -0
- package/dist/index.js +1198 -1617
- package/package.json +19 -15
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import { defineComponent, inject, ref, computed, resolveComponent, resolveDirective,
|
|
1
|
+
import "./index.css";
|
|
2
|
+
import { defineComponent, inject, ref, computed, resolveComponent, resolveDirective, createBlock, openBlock, withCtx, createVNode, mergeProps, withModifiers, createElementBlock, createCommentVNode, withKeys, toDisplayString, Fragment, withDirectives, createTextVNode, reactive, onMounted, onBeforeUnmount, createElementVNode, unref, renderList } from "vue";
|
|
3
3
|
const byteToHex = [];
|
|
4
4
|
for (let i = 0; i < 256; ++i) {
|
|
5
5
|
byteToHex.push((i + 256).toString(16).slice(1));
|
|
@@ -21,37 +21,33 @@ function rng() {
|
|
|
21
21
|
const randomUUID = typeof crypto !== "undefined" && crypto.randomUUID && crypto.randomUUID.bind(crypto);
|
|
22
22
|
const native = { randomUUID };
|
|
23
23
|
function v4(options, buf, offset) {
|
|
24
|
-
|
|
25
|
-
if (native.randomUUID && !buf && !options) {
|
|
24
|
+
if (native.randomUUID && true && !options) {
|
|
26
25
|
return native.randomUUID();
|
|
27
26
|
}
|
|
28
27
|
options = options || {};
|
|
29
|
-
const rnds = options.random ??
|
|
28
|
+
const rnds = options.random ?? options.rng?.() ?? rng();
|
|
30
29
|
if (rnds.length < 16) {
|
|
31
30
|
throw new Error("Random bytes length must be >= 16");
|
|
32
31
|
}
|
|
33
32
|
rnds[6] = rnds[6] & 15 | 64;
|
|
34
33
|
rnds[8] = rnds[8] & 63 | 128;
|
|
35
|
-
if (buf) {
|
|
36
|
-
offset = offset || 0;
|
|
37
|
-
if (offset < 0 || offset + 16 > buf.length) {
|
|
38
|
-
throw new RangeError(`UUID byte range ${offset}:${offset + 15} is out of buffer bounds`);
|
|
39
|
-
}
|
|
40
|
-
for (let i = 0; i < 16; ++i) {
|
|
41
|
-
buf[offset + i] = rnds[i];
|
|
42
|
-
}
|
|
43
|
-
return buf;
|
|
44
|
-
}
|
|
45
34
|
return unsafeStringify(rnds);
|
|
46
35
|
}
|
|
47
|
-
var
|
|
36
|
+
var id1 = v4();
|
|
37
|
+
var id2 = v4();
|
|
48
38
|
var type = "ACCORDION";
|
|
49
39
|
var name = "Accordion";
|
|
50
40
|
var initState = () => ({
|
|
51
41
|
embeds: {},
|
|
52
42
|
items: {
|
|
53
|
-
[
|
|
54
|
-
id,
|
|
43
|
+
[id1]: {
|
|
44
|
+
id: id1,
|
|
45
|
+
header: "Accordion Item Title",
|
|
46
|
+
body: {},
|
|
47
|
+
position: 1
|
|
48
|
+
},
|
|
49
|
+
[id2]: {
|
|
50
|
+
id: id2,
|
|
55
51
|
header: "Accordion Item Title",
|
|
56
52
|
body: {},
|
|
57
53
|
position: 1
|
|
@@ -65,6 +61,73 @@ var ui = {
|
|
|
65
61
|
// (e.g. 50/50 layout)
|
|
66
62
|
forceFullWidth: true
|
|
67
63
|
};
|
|
64
|
+
var ai = {
|
|
65
|
+
Schema: {
|
|
66
|
+
type: "json_schema",
|
|
67
|
+
name: "ce_accordion",
|
|
68
|
+
schema: {
|
|
69
|
+
type: "object",
|
|
70
|
+
properties: {
|
|
71
|
+
items: {
|
|
72
|
+
type: "array",
|
|
73
|
+
minItems: 2,
|
|
74
|
+
items: {
|
|
75
|
+
type: "object",
|
|
76
|
+
properties: {
|
|
77
|
+
header: { type: "string" },
|
|
78
|
+
content: { type: "string" }
|
|
79
|
+
},
|
|
80
|
+
required: ["header", "content"],
|
|
81
|
+
additionalProperties: false
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
required: ["items"],
|
|
86
|
+
additionalProperties: false
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
getPrompt: () => `
|
|
90
|
+
Generate a accordion content element as an object with the following
|
|
91
|
+
properties:
|
|
92
|
+
{
|
|
93
|
+
"items": [
|
|
94
|
+
{
|
|
95
|
+
"header": "",
|
|
96
|
+
"content": ""
|
|
97
|
+
}
|
|
98
|
+
]
|
|
99
|
+
}
|
|
100
|
+
where:
|
|
101
|
+
- 'items' is an array of accordion item objects where:
|
|
102
|
+
- 'header' is the title of the accordion item.
|
|
103
|
+
- 'content' is the text to be displayed in the accordion item.
|
|
104
|
+
The content should be relevant to the topic of the accordion and
|
|
105
|
+
have a few paragraphs about the topic.
|
|
106
|
+
`,
|
|
107
|
+
processResponse: (val) => {
|
|
108
|
+
return val.items.reduce(
|
|
109
|
+
(acc, { header, content }, index2) => {
|
|
110
|
+
const embedId = v4();
|
|
111
|
+
const itemId = v4();
|
|
112
|
+
acc.embeds[embedId] = {
|
|
113
|
+
id: embedId,
|
|
114
|
+
data: { content },
|
|
115
|
+
embedded: true,
|
|
116
|
+
position: 1,
|
|
117
|
+
type: "TIPTAP_HTML"
|
|
118
|
+
};
|
|
119
|
+
acc.items[itemId] = {
|
|
120
|
+
id: itemId,
|
|
121
|
+
body: { [embedId]: true },
|
|
122
|
+
header,
|
|
123
|
+
position: index2 + 1
|
|
124
|
+
};
|
|
125
|
+
return acc;
|
|
126
|
+
},
|
|
127
|
+
{ items: {}, embeds: {} }
|
|
128
|
+
);
|
|
129
|
+
}
|
|
130
|
+
};
|
|
68
131
|
var manifest$1 = {
|
|
69
132
|
type,
|
|
70
133
|
version: "1.0",
|
|
@@ -72,125 +135,20 @@ var manifest$1 = {
|
|
|
72
135
|
isComposite: true,
|
|
73
136
|
ssr: false,
|
|
74
137
|
initState,
|
|
75
|
-
ui
|
|
138
|
+
ui,
|
|
139
|
+
ai
|
|
76
140
|
};
|
|
77
|
-
var
|
|
78
|
-
var
|
|
79
|
-
function getDefaultExportFromCjs(x) {
|
|
80
|
-
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
81
|
-
}
|
|
82
|
-
function listCacheClear$1() {
|
|
83
|
-
this.__data__ = [];
|
|
84
|
-
this.size = 0;
|
|
85
|
-
}
|
|
86
|
-
var _listCacheClear = listCacheClear$1;
|
|
87
|
-
function eq$4(value, other) {
|
|
88
|
-
return value === other || value !== value && other !== other;
|
|
89
|
-
}
|
|
90
|
-
var eq_1 = eq$4;
|
|
91
|
-
var eq$3 = eq_1;
|
|
92
|
-
function assocIndexOf$4(array, key) {
|
|
93
|
-
var length = array.length;
|
|
94
|
-
while (length--) {
|
|
95
|
-
if (eq$3(array[length][0], key)) {
|
|
96
|
-
return length;
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
return -1;
|
|
100
|
-
}
|
|
101
|
-
var _assocIndexOf = assocIndexOf$4;
|
|
102
|
-
var assocIndexOf$3 = _assocIndexOf;
|
|
103
|
-
var arrayProto$1 = Array.prototype;
|
|
104
|
-
var splice$1 = arrayProto$1.splice;
|
|
105
|
-
function listCacheDelete$1(key) {
|
|
106
|
-
var data = this.__data__, index2 = assocIndexOf$3(data, key);
|
|
107
|
-
if (index2 < 0) {
|
|
108
|
-
return false;
|
|
109
|
-
}
|
|
110
|
-
var lastIndex = data.length - 1;
|
|
111
|
-
if (index2 == lastIndex) {
|
|
112
|
-
data.pop();
|
|
113
|
-
} else {
|
|
114
|
-
splice$1.call(data, index2, 1);
|
|
115
|
-
}
|
|
116
|
-
--this.size;
|
|
117
|
-
return true;
|
|
118
|
-
}
|
|
119
|
-
var _listCacheDelete = listCacheDelete$1;
|
|
120
|
-
var assocIndexOf$2 = _assocIndexOf;
|
|
121
|
-
function listCacheGet$1(key) {
|
|
122
|
-
var data = this.__data__, index2 = assocIndexOf$2(data, key);
|
|
123
|
-
return index2 < 0 ? void 0 : data[index2][1];
|
|
124
|
-
}
|
|
125
|
-
var _listCacheGet = listCacheGet$1;
|
|
126
|
-
var assocIndexOf$1 = _assocIndexOf;
|
|
127
|
-
function listCacheHas$1(key) {
|
|
128
|
-
return assocIndexOf$1(this.__data__, key) > -1;
|
|
129
|
-
}
|
|
130
|
-
var _listCacheHas = listCacheHas$1;
|
|
131
|
-
var assocIndexOf = _assocIndexOf;
|
|
132
|
-
function listCacheSet$1(key, value) {
|
|
133
|
-
var data = this.__data__, index2 = assocIndexOf(data, key);
|
|
134
|
-
if (index2 < 0) {
|
|
135
|
-
++this.size;
|
|
136
|
-
data.push([key, value]);
|
|
137
|
-
} else {
|
|
138
|
-
data[index2][1] = value;
|
|
139
|
-
}
|
|
140
|
-
return this;
|
|
141
|
-
}
|
|
142
|
-
var _listCacheSet = listCacheSet$1;
|
|
143
|
-
var listCacheClear = _listCacheClear, listCacheDelete = _listCacheDelete, listCacheGet = _listCacheGet, listCacheHas = _listCacheHas, listCacheSet = _listCacheSet;
|
|
144
|
-
function ListCache$4(entries) {
|
|
145
|
-
var index2 = -1, length = entries == null ? 0 : entries.length;
|
|
146
|
-
this.clear();
|
|
147
|
-
while (++index2 < length) {
|
|
148
|
-
var entry = entries[index2];
|
|
149
|
-
this.set(entry[0], entry[1]);
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
ListCache$4.prototype.clear = listCacheClear;
|
|
153
|
-
ListCache$4.prototype["delete"] = listCacheDelete;
|
|
154
|
-
ListCache$4.prototype.get = listCacheGet;
|
|
155
|
-
ListCache$4.prototype.has = listCacheHas;
|
|
156
|
-
ListCache$4.prototype.set = listCacheSet;
|
|
157
|
-
var _ListCache = ListCache$4;
|
|
158
|
-
var ListCache$3 = _ListCache;
|
|
159
|
-
function stackClear$1() {
|
|
160
|
-
this.__data__ = new ListCache$3();
|
|
161
|
-
this.size = 0;
|
|
162
|
-
}
|
|
163
|
-
var _stackClear = stackClear$1;
|
|
164
|
-
function stackDelete$1(key) {
|
|
165
|
-
var data = this.__data__, result = data["delete"](key);
|
|
166
|
-
this.size = data.size;
|
|
167
|
-
return result;
|
|
168
|
-
}
|
|
169
|
-
var _stackDelete = stackDelete$1;
|
|
170
|
-
function stackGet$1(key) {
|
|
171
|
-
return this.__data__.get(key);
|
|
172
|
-
}
|
|
173
|
-
var _stackGet = stackGet$1;
|
|
174
|
-
function stackHas$1(key) {
|
|
175
|
-
return this.__data__.has(key);
|
|
176
|
-
}
|
|
177
|
-
var _stackHas = stackHas$1;
|
|
178
|
-
var freeGlobal$1 = typeof commonjsGlobal == "object" && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
|
|
179
|
-
var _freeGlobal = freeGlobal$1;
|
|
180
|
-
var freeGlobal = _freeGlobal;
|
|
141
|
+
var index_default = manifest$1;
|
|
142
|
+
var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
|
|
181
143
|
var freeSelf = typeof self == "object" && self && self.Object === Object && self;
|
|
182
|
-
var root
|
|
183
|
-
var
|
|
184
|
-
var
|
|
185
|
-
var
|
|
186
|
-
var
|
|
187
|
-
var
|
|
188
|
-
|
|
189
|
-
var hasOwnProperty$
|
|
190
|
-
var nativeObjectToString$1 = objectProto$f.toString;
|
|
191
|
-
var symToStringTag$1 = Symbol$6 ? Symbol$6.toStringTag : void 0;
|
|
192
|
-
function getRawTag$1(value) {
|
|
193
|
-
var isOwn = hasOwnProperty$c.call(value, symToStringTag$1), tag = value[symToStringTag$1];
|
|
144
|
+
var root = freeGlobal || freeSelf || Function("return this")();
|
|
145
|
+
var Symbol$1 = root.Symbol;
|
|
146
|
+
var objectProto$e = Object.prototype;
|
|
147
|
+
var hasOwnProperty$b = objectProto$e.hasOwnProperty;
|
|
148
|
+
var nativeObjectToString$1 = objectProto$e.toString;
|
|
149
|
+
var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : void 0;
|
|
150
|
+
function getRawTag(value) {
|
|
151
|
+
var isOwn = hasOwnProperty$b.call(value, symToStringTag$1), tag = value[symToStringTag$1];
|
|
194
152
|
try {
|
|
195
153
|
value[symToStringTag$1] = void 0;
|
|
196
154
|
var unmasked = true;
|
|
@@ -206,53 +164,74 @@ function getRawTag$1(value) {
|
|
|
206
164
|
}
|
|
207
165
|
return result;
|
|
208
166
|
}
|
|
209
|
-
var
|
|
210
|
-
var
|
|
211
|
-
|
|
212
|
-
function objectToString$1(value) {
|
|
167
|
+
var objectProto$d = Object.prototype;
|
|
168
|
+
var nativeObjectToString = objectProto$d.toString;
|
|
169
|
+
function objectToString(value) {
|
|
213
170
|
return nativeObjectToString.call(value);
|
|
214
171
|
}
|
|
215
|
-
var _objectToString = objectToString$1;
|
|
216
|
-
var Symbol$5 = _Symbol, getRawTag = _getRawTag, objectToString = _objectToString;
|
|
217
172
|
var nullTag = "[object Null]", undefinedTag = "[object Undefined]";
|
|
218
|
-
var symToStringTag = Symbol$
|
|
219
|
-
function baseGetTag
|
|
173
|
+
var symToStringTag = Symbol$1 ? Symbol$1.toStringTag : void 0;
|
|
174
|
+
function baseGetTag(value) {
|
|
220
175
|
if (value == null) {
|
|
221
176
|
return value === void 0 ? undefinedTag : nullTag;
|
|
222
177
|
}
|
|
223
178
|
return symToStringTag && symToStringTag in Object(value) ? getRawTag(value) : objectToString(value);
|
|
224
179
|
}
|
|
225
|
-
|
|
226
|
-
|
|
180
|
+
function isObjectLike(value) {
|
|
181
|
+
return value != null && typeof value == "object";
|
|
182
|
+
}
|
|
183
|
+
var symbolTag$3 = "[object Symbol]";
|
|
184
|
+
function isSymbol(value) {
|
|
185
|
+
return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag$3;
|
|
186
|
+
}
|
|
187
|
+
function arrayMap(array, iteratee) {
|
|
188
|
+
var index2 = -1, length = array == null ? 0 : array.length, result = Array(length);
|
|
189
|
+
while (++index2 < length) {
|
|
190
|
+
result[index2] = iteratee(array[index2], index2, array);
|
|
191
|
+
}
|
|
192
|
+
return result;
|
|
193
|
+
}
|
|
194
|
+
var isArray = Array.isArray;
|
|
195
|
+
var symbolProto$2 = Symbol$1 ? Symbol$1.prototype : void 0, symbolToString = symbolProto$2 ? symbolProto$2.toString : void 0;
|
|
196
|
+
function baseToString(value) {
|
|
197
|
+
if (typeof value == "string") {
|
|
198
|
+
return value;
|
|
199
|
+
}
|
|
200
|
+
if (isArray(value)) {
|
|
201
|
+
return arrayMap(value, baseToString) + "";
|
|
202
|
+
}
|
|
203
|
+
if (isSymbol(value)) {
|
|
204
|
+
return symbolToString ? symbolToString.call(value) : "";
|
|
205
|
+
}
|
|
206
|
+
var result = value + "";
|
|
207
|
+
return result == "0" && 1 / value == -Infinity ? "-0" : result;
|
|
208
|
+
}
|
|
209
|
+
function isObject(value) {
|
|
227
210
|
var type2 = typeof value;
|
|
228
211
|
return value != null && (type2 == "object" || type2 == "function");
|
|
229
212
|
}
|
|
230
|
-
|
|
231
|
-
|
|
213
|
+
function identity(value) {
|
|
214
|
+
return value;
|
|
215
|
+
}
|
|
232
216
|
var asyncTag = "[object AsyncFunction]", funcTag$2 = "[object Function]", genTag$1 = "[object GeneratorFunction]", proxyTag = "[object Proxy]";
|
|
233
|
-
function isFunction
|
|
234
|
-
if (!isObject
|
|
217
|
+
function isFunction(value) {
|
|
218
|
+
if (!isObject(value)) {
|
|
235
219
|
return false;
|
|
236
220
|
}
|
|
237
|
-
var tag = baseGetTag
|
|
221
|
+
var tag = baseGetTag(value);
|
|
238
222
|
return tag == funcTag$2 || tag == genTag$1 || tag == asyncTag || tag == proxyTag;
|
|
239
223
|
}
|
|
240
|
-
var
|
|
241
|
-
var root$6 = _root;
|
|
242
|
-
var coreJsData$1 = root$6["__core-js_shared__"];
|
|
243
|
-
var _coreJsData = coreJsData$1;
|
|
244
|
-
var coreJsData = _coreJsData;
|
|
224
|
+
var coreJsData = root["__core-js_shared__"];
|
|
245
225
|
var maskSrcKey = function() {
|
|
246
226
|
var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
|
|
247
227
|
return uid ? "Symbol(src)_1." + uid : "";
|
|
248
228
|
}();
|
|
249
|
-
function isMasked
|
|
229
|
+
function isMasked(func) {
|
|
250
230
|
return !!maskSrcKey && maskSrcKey in func;
|
|
251
231
|
}
|
|
252
|
-
var _isMasked = isMasked$1;
|
|
253
232
|
var funcProto$1 = Function.prototype;
|
|
254
233
|
var funcToString$1 = funcProto$1.toString;
|
|
255
|
-
function toSource
|
|
234
|
+
function toSource(func) {
|
|
256
235
|
if (func != null) {
|
|
257
236
|
try {
|
|
258
237
|
return funcToString$1.call(func);
|
|
@@ -265,211 +244,149 @@ function toSource$2(func) {
|
|
|
265
244
|
}
|
|
266
245
|
return "";
|
|
267
246
|
}
|
|
268
|
-
var _toSource = toSource$2;
|
|
269
|
-
var isFunction$1 = isFunction_1, isMasked = _isMasked, isObject$6 = isObject_1, toSource$1 = _toSource;
|
|
270
247
|
var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
|
|
271
248
|
var reIsHostCtor = /^\[object .+?Constructor\]$/;
|
|
272
|
-
var funcProto = Function.prototype, objectProto$
|
|
249
|
+
var funcProto = Function.prototype, objectProto$c = Object.prototype;
|
|
273
250
|
var funcToString = funcProto.toString;
|
|
274
|
-
var hasOwnProperty$
|
|
251
|
+
var hasOwnProperty$a = objectProto$c.hasOwnProperty;
|
|
275
252
|
var reIsNative = RegExp(
|
|
276
|
-
"^" + funcToString.call(hasOwnProperty$
|
|
253
|
+
"^" + funcToString.call(hasOwnProperty$a).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
|
277
254
|
);
|
|
278
|
-
function baseIsNative
|
|
279
|
-
if (!isObject
|
|
255
|
+
function baseIsNative(value) {
|
|
256
|
+
if (!isObject(value) || isMasked(value)) {
|
|
280
257
|
return false;
|
|
281
258
|
}
|
|
282
|
-
var pattern = isFunction
|
|
283
|
-
return pattern.test(toSource
|
|
259
|
+
var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
|
|
260
|
+
return pattern.test(toSource(value));
|
|
284
261
|
}
|
|
285
|
-
|
|
286
|
-
function getValue$1(object, key) {
|
|
262
|
+
function getValue(object, key) {
|
|
287
263
|
return object == null ? void 0 : object[key];
|
|
288
264
|
}
|
|
289
|
-
|
|
290
|
-
var baseIsNative = _baseIsNative, getValue = _getValue;
|
|
291
|
-
function getNative$7(object, key) {
|
|
265
|
+
function getNative(object, key) {
|
|
292
266
|
var value = getValue(object, key);
|
|
293
267
|
return baseIsNative(value) ? value : void 0;
|
|
294
268
|
}
|
|
295
|
-
var
|
|
296
|
-
var
|
|
297
|
-
var
|
|
298
|
-
|
|
299
|
-
var getNative$5 = _getNative;
|
|
300
|
-
var nativeCreate$4 = getNative$5(Object, "create");
|
|
301
|
-
var _nativeCreate = nativeCreate$4;
|
|
302
|
-
var nativeCreate$3 = _nativeCreate;
|
|
303
|
-
function hashClear$1() {
|
|
304
|
-
this.__data__ = nativeCreate$3 ? nativeCreate$3(null) : {};
|
|
305
|
-
this.size = 0;
|
|
306
|
-
}
|
|
307
|
-
var _hashClear = hashClear$1;
|
|
308
|
-
function hashDelete$1(key) {
|
|
309
|
-
var result = this.has(key) && delete this.__data__[key];
|
|
310
|
-
this.size -= result ? 1 : 0;
|
|
311
|
-
return result;
|
|
312
|
-
}
|
|
313
|
-
var _hashDelete = hashDelete$1;
|
|
314
|
-
var nativeCreate$2 = _nativeCreate;
|
|
315
|
-
var HASH_UNDEFINED$2 = "__lodash_hash_undefined__";
|
|
316
|
-
var objectProto$c = Object.prototype;
|
|
317
|
-
var hasOwnProperty$a = objectProto$c.hasOwnProperty;
|
|
318
|
-
function hashGet$1(key) {
|
|
319
|
-
var data = this.__data__;
|
|
320
|
-
if (nativeCreate$2) {
|
|
321
|
-
var result = data[key];
|
|
322
|
-
return result === HASH_UNDEFINED$2 ? void 0 : result;
|
|
269
|
+
var WeakMap = getNative(root, "WeakMap");
|
|
270
|
+
var objectCreate = Object.create;
|
|
271
|
+
var baseCreate = /* @__PURE__ */ function() {
|
|
272
|
+
function object() {
|
|
323
273
|
}
|
|
324
|
-
return
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
function
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
274
|
+
return function(proto) {
|
|
275
|
+
if (!isObject(proto)) {
|
|
276
|
+
return {};
|
|
277
|
+
}
|
|
278
|
+
if (objectCreate) {
|
|
279
|
+
return objectCreate(proto);
|
|
280
|
+
}
|
|
281
|
+
object.prototype = proto;
|
|
282
|
+
var result = new object();
|
|
283
|
+
object.prototype = void 0;
|
|
284
|
+
return result;
|
|
285
|
+
};
|
|
286
|
+
}();
|
|
287
|
+
function apply(func, thisArg, args) {
|
|
288
|
+
switch (args.length) {
|
|
289
|
+
case 0:
|
|
290
|
+
return func.call(thisArg);
|
|
291
|
+
case 1:
|
|
292
|
+
return func.call(thisArg, args[0]);
|
|
293
|
+
case 2:
|
|
294
|
+
return func.call(thisArg, args[0], args[1]);
|
|
295
|
+
case 3:
|
|
296
|
+
return func.call(thisArg, args[0], args[1], args[2]);
|
|
297
|
+
}
|
|
298
|
+
return func.apply(thisArg, args);
|
|
342
299
|
}
|
|
343
|
-
|
|
344
|
-
var
|
|
345
|
-
|
|
346
|
-
var index2 = -1, length = entries == null ? 0 : entries.length;
|
|
347
|
-
this.clear();
|
|
300
|
+
function copyArray(source, array) {
|
|
301
|
+
var index2 = -1, length = source.length;
|
|
302
|
+
array || (array = Array(length));
|
|
348
303
|
while (++index2 < length) {
|
|
349
|
-
|
|
350
|
-
this.set(entry[0], entry[1]);
|
|
304
|
+
array[index2] = source[index2];
|
|
351
305
|
}
|
|
306
|
+
return array;
|
|
352
307
|
}
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
var
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
308
|
+
var HOT_COUNT = 800, HOT_SPAN = 16;
|
|
309
|
+
var nativeNow = Date.now;
|
|
310
|
+
function shortOut(func) {
|
|
311
|
+
var count = 0, lastCalled = 0;
|
|
312
|
+
return function() {
|
|
313
|
+
var stamp = nativeNow(), remaining = HOT_SPAN - (stamp - lastCalled);
|
|
314
|
+
lastCalled = stamp;
|
|
315
|
+
if (remaining > 0) {
|
|
316
|
+
if (++count >= HOT_COUNT) {
|
|
317
|
+
return arguments[0];
|
|
318
|
+
}
|
|
319
|
+
} else {
|
|
320
|
+
count = 0;
|
|
321
|
+
}
|
|
322
|
+
return func.apply(void 0, arguments);
|
|
366
323
|
};
|
|
367
324
|
}
|
|
368
|
-
|
|
369
|
-
function
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
}
|
|
373
|
-
var _isKeyable = isKeyable$1;
|
|
374
|
-
var isKeyable = _isKeyable;
|
|
375
|
-
function getMapData$4(map, key) {
|
|
376
|
-
var data = map.__data__;
|
|
377
|
-
return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
|
|
378
|
-
}
|
|
379
|
-
var _getMapData = getMapData$4;
|
|
380
|
-
var getMapData$3 = _getMapData;
|
|
381
|
-
function mapCacheDelete$1(key) {
|
|
382
|
-
var result = getMapData$3(this, key)["delete"](key);
|
|
383
|
-
this.size -= result ? 1 : 0;
|
|
384
|
-
return result;
|
|
385
|
-
}
|
|
386
|
-
var _mapCacheDelete = mapCacheDelete$1;
|
|
387
|
-
var getMapData$2 = _getMapData;
|
|
388
|
-
function mapCacheGet$1(key) {
|
|
389
|
-
return getMapData$2(this, key).get(key);
|
|
390
|
-
}
|
|
391
|
-
var _mapCacheGet = mapCacheGet$1;
|
|
392
|
-
var getMapData$1 = _getMapData;
|
|
393
|
-
function mapCacheHas$1(key) {
|
|
394
|
-
return getMapData$1(this, key).has(key);
|
|
395
|
-
}
|
|
396
|
-
var _mapCacheHas = mapCacheHas$1;
|
|
397
|
-
var getMapData = _getMapData;
|
|
398
|
-
function mapCacheSet$1(key, value) {
|
|
399
|
-
var data = getMapData(this, key), size = data.size;
|
|
400
|
-
data.set(key, value);
|
|
401
|
-
this.size += data.size == size ? 0 : 1;
|
|
402
|
-
return this;
|
|
325
|
+
function constant(value) {
|
|
326
|
+
return function() {
|
|
327
|
+
return value;
|
|
328
|
+
};
|
|
403
329
|
}
|
|
404
|
-
var
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
330
|
+
var defineProperty = function() {
|
|
331
|
+
try {
|
|
332
|
+
var func = getNative(Object, "defineProperty");
|
|
333
|
+
func({}, "", {});
|
|
334
|
+
return func;
|
|
335
|
+
} catch (e) {
|
|
336
|
+
}
|
|
337
|
+
}();
|
|
338
|
+
var baseSetToString = !defineProperty ? identity : function(func, string) {
|
|
339
|
+
return defineProperty(func, "toString", {
|
|
340
|
+
"configurable": true,
|
|
341
|
+
"enumerable": false,
|
|
342
|
+
"value": constant(string),
|
|
343
|
+
"writable": true
|
|
344
|
+
});
|
|
345
|
+
};
|
|
346
|
+
var setToString = shortOut(baseSetToString);
|
|
347
|
+
function arrayEach(array, iteratee) {
|
|
348
|
+
var index2 = -1, length = array == null ? 0 : array.length;
|
|
409
349
|
while (++index2 < length) {
|
|
410
|
-
|
|
411
|
-
|
|
350
|
+
if (iteratee(array[index2], index2, array) === false) {
|
|
351
|
+
break;
|
|
352
|
+
}
|
|
412
353
|
}
|
|
354
|
+
return array;
|
|
413
355
|
}
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
var _MapCache = MapCache$3;
|
|
420
|
-
var ListCache$1 = _ListCache, Map$1 = _Map, MapCache$2 = _MapCache;
|
|
421
|
-
var LARGE_ARRAY_SIZE = 200;
|
|
422
|
-
function stackSet$1(key, value) {
|
|
423
|
-
var data = this.__data__;
|
|
424
|
-
if (data instanceof ListCache$1) {
|
|
425
|
-
var pairs = data.__data__;
|
|
426
|
-
if (!Map$1 || pairs.length < LARGE_ARRAY_SIZE - 1) {
|
|
427
|
-
pairs.push([key, value]);
|
|
428
|
-
this.size = ++data.size;
|
|
429
|
-
return this;
|
|
356
|
+
function baseFindIndex(array, predicate, fromIndex, fromRight) {
|
|
357
|
+
var length = array.length, index2 = fromIndex + -1;
|
|
358
|
+
while (++index2 < length) {
|
|
359
|
+
if (predicate(array[index2], index2, array)) {
|
|
360
|
+
return index2;
|
|
430
361
|
}
|
|
431
|
-
data = this.__data__ = new MapCache$2(pairs);
|
|
432
362
|
}
|
|
433
|
-
|
|
434
|
-
this.size = data.size;
|
|
435
|
-
return this;
|
|
363
|
+
return -1;
|
|
436
364
|
}
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
function Stack$3(entries) {
|
|
440
|
-
var data = this.__data__ = new ListCache(entries);
|
|
441
|
-
this.size = data.size;
|
|
365
|
+
function baseIsNaN(value) {
|
|
366
|
+
return value !== value;
|
|
442
367
|
}
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
Stack$3.prototype.get = stackGet;
|
|
446
|
-
Stack$3.prototype.has = stackHas;
|
|
447
|
-
Stack$3.prototype.set = stackSet;
|
|
448
|
-
var _Stack = Stack$3;
|
|
449
|
-
function arrayEach$2(array, iteratee) {
|
|
450
|
-
var index2 = -1, length = array == null ? 0 : array.length;
|
|
368
|
+
function strictIndexOf(array, value, fromIndex) {
|
|
369
|
+
var index2 = fromIndex - 1, length = array.length;
|
|
451
370
|
while (++index2 < length) {
|
|
452
|
-
if (
|
|
453
|
-
|
|
371
|
+
if (array[index2] === value) {
|
|
372
|
+
return index2;
|
|
454
373
|
}
|
|
455
374
|
}
|
|
456
|
-
return
|
|
375
|
+
return -1;
|
|
457
376
|
}
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
}
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
if (key == "__proto__" && defineProperty$1) {
|
|
472
|
-
defineProperty$1(object, key, {
|
|
377
|
+
function baseIndexOf(array, value, fromIndex) {
|
|
378
|
+
return value === value ? strictIndexOf(array, value, fromIndex) : baseFindIndex(array, baseIsNaN, fromIndex);
|
|
379
|
+
}
|
|
380
|
+
var MAX_SAFE_INTEGER$1 = 9007199254740991;
|
|
381
|
+
var reIsUint = /^(?:0|[1-9]\d*)$/;
|
|
382
|
+
function isIndex(value, length) {
|
|
383
|
+
var type2 = typeof value;
|
|
384
|
+
length = length == null ? MAX_SAFE_INTEGER$1 : length;
|
|
385
|
+
return !!length && (type2 == "number" || type2 != "symbol" && reIsUint.test(value)) && (value > -1 && value % 1 == 0 && value < length);
|
|
386
|
+
}
|
|
387
|
+
function baseAssignValue(object, key, value) {
|
|
388
|
+
if (key == "__proto__" && defineProperty) {
|
|
389
|
+
defineProperty(object, key, {
|
|
473
390
|
"configurable": true,
|
|
474
391
|
"enumerable": true,
|
|
475
392
|
"value": value,
|
|
@@ -479,611 +396,320 @@ function baseAssignValue$2(object, key, value) {
|
|
|
479
396
|
object[key] = value;
|
|
480
397
|
}
|
|
481
398
|
}
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
var
|
|
486
|
-
|
|
399
|
+
function eq(value, other) {
|
|
400
|
+
return value === other || value !== value && other !== other;
|
|
401
|
+
}
|
|
402
|
+
var objectProto$b = Object.prototype;
|
|
403
|
+
var hasOwnProperty$9 = objectProto$b.hasOwnProperty;
|
|
404
|
+
function assignValue(object, key, value) {
|
|
487
405
|
var objValue = object[key];
|
|
488
|
-
if (!(hasOwnProperty$
|
|
489
|
-
baseAssignValue
|
|
406
|
+
if (!(hasOwnProperty$9.call(object, key) && eq(objValue, value)) || value === void 0 && !(key in object)) {
|
|
407
|
+
baseAssignValue(object, key, value);
|
|
490
408
|
}
|
|
491
409
|
}
|
|
492
|
-
var
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
return
|
|
410
|
+
var nativeMax = Math.max;
|
|
411
|
+
function overRest(func, start, transform) {
|
|
412
|
+
start = nativeMax(start === void 0 ? func.length - 1 : start, 0);
|
|
413
|
+
return function() {
|
|
414
|
+
var args = arguments, index2 = -1, length = nativeMax(args.length - start, 0), array = Array(length);
|
|
415
|
+
while (++index2 < length) {
|
|
416
|
+
array[index2] = args[start + index2];
|
|
417
|
+
}
|
|
418
|
+
index2 = -1;
|
|
419
|
+
var otherArgs = Array(start + 1);
|
|
420
|
+
while (++index2 < start) {
|
|
421
|
+
otherArgs[index2] = args[index2];
|
|
422
|
+
}
|
|
423
|
+
otherArgs[start] = transform(array);
|
|
424
|
+
return apply(func, this, otherArgs);
|
|
425
|
+
};
|
|
426
|
+
}
|
|
427
|
+
function baseRest(func, start) {
|
|
428
|
+
return setToString(overRest(func, start, identity), func + "");
|
|
511
429
|
}
|
|
512
|
-
var
|
|
513
|
-
function
|
|
430
|
+
var MAX_SAFE_INTEGER = 9007199254740991;
|
|
431
|
+
function isLength(value) {
|
|
432
|
+
return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
|
|
433
|
+
}
|
|
434
|
+
function isArrayLike(value) {
|
|
435
|
+
return value != null && isLength(value.length) && !isFunction(value);
|
|
436
|
+
}
|
|
437
|
+
function isIterateeCall(value, index2, object) {
|
|
438
|
+
if (!isObject(object)) {
|
|
439
|
+
return false;
|
|
440
|
+
}
|
|
441
|
+
var type2 = typeof index2;
|
|
442
|
+
if (type2 == "number" ? isArrayLike(object) && isIndex(index2, object.length) : type2 == "string" && index2 in object) {
|
|
443
|
+
return eq(object[index2], value);
|
|
444
|
+
}
|
|
445
|
+
return false;
|
|
446
|
+
}
|
|
447
|
+
var objectProto$a = Object.prototype;
|
|
448
|
+
function isPrototype(value) {
|
|
449
|
+
var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto$a;
|
|
450
|
+
return value === proto;
|
|
451
|
+
}
|
|
452
|
+
function baseTimes(n, iteratee) {
|
|
514
453
|
var index2 = -1, result = Array(n);
|
|
515
454
|
while (++index2 < n) {
|
|
516
455
|
result[index2] = iteratee(index2);
|
|
517
456
|
}
|
|
518
457
|
return result;
|
|
519
458
|
}
|
|
520
|
-
var _baseTimes = baseTimes$1;
|
|
521
|
-
function isObjectLike$8(value) {
|
|
522
|
-
return value != null && typeof value == "object";
|
|
523
|
-
}
|
|
524
|
-
var isObjectLike_1 = isObjectLike$8;
|
|
525
|
-
var baseGetTag$4 = _baseGetTag, isObjectLike$7 = isObjectLike_1;
|
|
526
459
|
var argsTag$3 = "[object Arguments]";
|
|
527
|
-
function baseIsArguments
|
|
528
|
-
return isObjectLike
|
|
460
|
+
function baseIsArguments(value) {
|
|
461
|
+
return isObjectLike(value) && baseGetTag(value) == argsTag$3;
|
|
529
462
|
}
|
|
530
|
-
var _baseIsArguments = baseIsArguments$1;
|
|
531
|
-
var baseIsArguments = _baseIsArguments, isObjectLike$6 = isObjectLike_1;
|
|
532
463
|
var objectProto$9 = Object.prototype;
|
|
533
|
-
var hasOwnProperty$
|
|
464
|
+
var hasOwnProperty$8 = objectProto$9.hasOwnProperty;
|
|
534
465
|
var propertyIsEnumerable$1 = objectProto$9.propertyIsEnumerable;
|
|
535
|
-
var isArguments
|
|
466
|
+
var isArguments = baseIsArguments(/* @__PURE__ */ function() {
|
|
536
467
|
return arguments;
|
|
537
468
|
}()) ? baseIsArguments : function(value) {
|
|
538
|
-
return isObjectLike
|
|
469
|
+
return isObjectLike(value) && hasOwnProperty$8.call(value, "callee") && !propertyIsEnumerable$1.call(value, "callee");
|
|
539
470
|
};
|
|
540
|
-
var isArguments_1 = isArguments$4;
|
|
541
|
-
var isArray$e = Array.isArray;
|
|
542
|
-
var isArray_1 = isArray$e;
|
|
543
|
-
var isBuffer$4 = { exports: {} };
|
|
544
471
|
function stubFalse() {
|
|
545
472
|
return false;
|
|
546
473
|
}
|
|
547
|
-
var
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
554
|
-
var Buffer = moduleExports ? root2.Buffer : void 0;
|
|
555
|
-
var nativeIsBuffer = Buffer ? Buffer.isBuffer : void 0;
|
|
556
|
-
var isBuffer2 = nativeIsBuffer || stubFalse2;
|
|
557
|
-
module.exports = isBuffer2;
|
|
558
|
-
})(isBuffer$4, isBuffer$4.exports);
|
|
559
|
-
var isBufferExports = isBuffer$4.exports;
|
|
560
|
-
var MAX_SAFE_INTEGER$1 = 9007199254740991;
|
|
561
|
-
var reIsUint = /^(?:0|[1-9]\d*)$/;
|
|
562
|
-
function isIndex$4(value, length) {
|
|
563
|
-
var type2 = typeof value;
|
|
564
|
-
length = length == null ? MAX_SAFE_INTEGER$1 : length;
|
|
565
|
-
return !!length && (type2 == "number" || type2 != "symbol" && reIsUint.test(value)) && (value > -1 && value % 1 == 0 && value < length);
|
|
566
|
-
}
|
|
567
|
-
var _isIndex = isIndex$4;
|
|
568
|
-
var MAX_SAFE_INTEGER = 9007199254740991;
|
|
569
|
-
function isLength$3(value) {
|
|
570
|
-
return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
|
|
571
|
-
}
|
|
572
|
-
var isLength_1 = isLength$3;
|
|
573
|
-
var baseGetTag$3 = _baseGetTag, isLength$2 = isLength_1, isObjectLike$5 = isObjectLike_1;
|
|
474
|
+
var freeExports$2 = typeof exports == "object" && exports && !exports.nodeType && exports;
|
|
475
|
+
var freeModule$2 = freeExports$2 && typeof module == "object" && module && !module.nodeType && module;
|
|
476
|
+
var moduleExports$2 = freeModule$2 && freeModule$2.exports === freeExports$2;
|
|
477
|
+
var Buffer$1 = moduleExports$2 ? root.Buffer : void 0;
|
|
478
|
+
var nativeIsBuffer = Buffer$1 ? Buffer$1.isBuffer : void 0;
|
|
479
|
+
var isBuffer = nativeIsBuffer || stubFalse;
|
|
574
480
|
var argsTag$2 = "[object Arguments]", arrayTag$2 = "[object Array]", boolTag$3 = "[object Boolean]", dateTag$3 = "[object Date]", errorTag$2 = "[object Error]", funcTag$1 = "[object Function]", mapTag$6 = "[object Map]", numberTag$4 = "[object Number]", objectTag$3 = "[object Object]", regexpTag$3 = "[object RegExp]", setTag$6 = "[object Set]", stringTag$3 = "[object String]", weakMapTag$2 = "[object WeakMap]";
|
|
575
481
|
var arrayBufferTag$3 = "[object ArrayBuffer]", dataViewTag$4 = "[object DataView]", float32Tag$2 = "[object Float32Array]", float64Tag$2 = "[object Float64Array]", int8Tag$2 = "[object Int8Array]", int16Tag$2 = "[object Int16Array]", int32Tag$2 = "[object Int32Array]", uint8Tag$2 = "[object Uint8Array]", uint8ClampedTag$2 = "[object Uint8ClampedArray]", uint16Tag$2 = "[object Uint16Array]", uint32Tag$2 = "[object Uint32Array]";
|
|
576
482
|
var typedArrayTags = {};
|
|
577
483
|
typedArrayTags[float32Tag$2] = typedArrayTags[float64Tag$2] = typedArrayTags[int8Tag$2] = typedArrayTags[int16Tag$2] = typedArrayTags[int32Tag$2] = typedArrayTags[uint8Tag$2] = typedArrayTags[uint8ClampedTag$2] = typedArrayTags[uint16Tag$2] = typedArrayTags[uint32Tag$2] = true;
|
|
578
484
|
typedArrayTags[argsTag$2] = typedArrayTags[arrayTag$2] = typedArrayTags[arrayBufferTag$3] = typedArrayTags[boolTag$3] = typedArrayTags[dataViewTag$4] = typedArrayTags[dateTag$3] = typedArrayTags[errorTag$2] = typedArrayTags[funcTag$1] = typedArrayTags[mapTag$6] = typedArrayTags[numberTag$4] = typedArrayTags[objectTag$3] = typedArrayTags[regexpTag$3] = typedArrayTags[setTag$6] = typedArrayTags[stringTag$3] = typedArrayTags[weakMapTag$2] = false;
|
|
579
|
-
function baseIsTypedArray
|
|
580
|
-
return isObjectLike
|
|
485
|
+
function baseIsTypedArray(value) {
|
|
486
|
+
return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
|
|
581
487
|
}
|
|
582
|
-
|
|
583
|
-
function baseUnary$5(func) {
|
|
488
|
+
function baseUnary(func) {
|
|
584
489
|
return function(value) {
|
|
585
490
|
return func(value);
|
|
586
491
|
};
|
|
587
492
|
}
|
|
588
|
-
var
|
|
589
|
-
var
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
var nodeUtil2 = function() {
|
|
598
|
-
try {
|
|
599
|
-
var types = freeModule && freeModule.require && freeModule.require("util").types;
|
|
600
|
-
if (types) {
|
|
601
|
-
return types;
|
|
602
|
-
}
|
|
603
|
-
return freeProcess && freeProcess.binding && freeProcess.binding("util");
|
|
604
|
-
} catch (e) {
|
|
493
|
+
var freeExports$1 = typeof exports == "object" && exports && !exports.nodeType && exports;
|
|
494
|
+
var freeModule$1 = freeExports$1 && typeof module == "object" && module && !module.nodeType && module;
|
|
495
|
+
var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
|
|
496
|
+
var freeProcess = moduleExports$1 && freeGlobal.process;
|
|
497
|
+
var nodeUtil = function() {
|
|
498
|
+
try {
|
|
499
|
+
var types = freeModule$1 && freeModule$1.require && freeModule$1.require("util").types;
|
|
500
|
+
if (types) {
|
|
501
|
+
return types;
|
|
605
502
|
}
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
}
|
|
609
|
-
|
|
610
|
-
var
|
|
611
|
-
var
|
|
612
|
-
var isTypedArray$3 = nodeIsTypedArray ? baseUnary$4(nodeIsTypedArray) : baseIsTypedArray;
|
|
613
|
-
var isTypedArray_1 = isTypedArray$3;
|
|
614
|
-
var baseTimes = _baseTimes, isArguments$3 = isArguments_1, isArray$d = isArray_1, isBuffer$3 = isBufferExports, isIndex$3 = _isIndex, isTypedArray$2 = isTypedArray_1;
|
|
503
|
+
return freeProcess && freeProcess.binding && freeProcess.binding("util");
|
|
504
|
+
} catch (e) {
|
|
505
|
+
}
|
|
506
|
+
}();
|
|
507
|
+
var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
|
|
508
|
+
var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
|
|
615
509
|
var objectProto$8 = Object.prototype;
|
|
616
|
-
var hasOwnProperty$
|
|
617
|
-
function arrayLikeKeys
|
|
618
|
-
var isArr = isArray
|
|
510
|
+
var hasOwnProperty$7 = objectProto$8.hasOwnProperty;
|
|
511
|
+
function arrayLikeKeys(value, inherited) {
|
|
512
|
+
var isArr = isArray(value), isArg = !isArr && isArguments(value), isBuff = !isArr && !isArg && isBuffer(value), isType = !isArr && !isArg && !isBuff && isTypedArray(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes(value.length, String) : [], length = result.length;
|
|
619
513
|
for (var key in value) {
|
|
620
|
-
if (
|
|
514
|
+
if (hasOwnProperty$7.call(value, key) && !(skipIndexes && // Safari 9 has enumerable `arguments.length` in strict mode.
|
|
621
515
|
(key == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
|
|
622
516
|
isBuff && (key == "offset" || key == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
|
|
623
517
|
isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || // Skip index properties.
|
|
624
|
-
isIndex
|
|
518
|
+
isIndex(key, length)))) {
|
|
625
519
|
result.push(key);
|
|
626
520
|
}
|
|
627
521
|
}
|
|
628
522
|
return result;
|
|
629
523
|
}
|
|
630
|
-
|
|
631
|
-
var objectProto$7 = Object.prototype;
|
|
632
|
-
function isPrototype$4(value) {
|
|
633
|
-
var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto$7;
|
|
634
|
-
return value === proto;
|
|
635
|
-
}
|
|
636
|
-
var _isPrototype = isPrototype$4;
|
|
637
|
-
function overArg$2(func, transform) {
|
|
524
|
+
function overArg(func, transform) {
|
|
638
525
|
return function(arg) {
|
|
639
526
|
return func(transform(arg));
|
|
640
527
|
};
|
|
641
528
|
}
|
|
642
|
-
var
|
|
643
|
-
var
|
|
644
|
-
var
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
var objectProto$6 = Object.prototype;
|
|
648
|
-
var hasOwnProperty$5 = objectProto$6.hasOwnProperty;
|
|
649
|
-
function baseKeys$2(object) {
|
|
650
|
-
if (!isPrototype$3(object)) {
|
|
529
|
+
var nativeKeys = overArg(Object.keys, Object);
|
|
530
|
+
var objectProto$7 = Object.prototype;
|
|
531
|
+
var hasOwnProperty$6 = objectProto$7.hasOwnProperty;
|
|
532
|
+
function baseKeys(object) {
|
|
533
|
+
if (!isPrototype(object)) {
|
|
651
534
|
return nativeKeys(object);
|
|
652
535
|
}
|
|
653
536
|
var result = [];
|
|
654
537
|
for (var key in Object(object)) {
|
|
655
|
-
if (hasOwnProperty$
|
|
538
|
+
if (hasOwnProperty$6.call(object, key) && key != "constructor") {
|
|
656
539
|
result.push(key);
|
|
657
540
|
}
|
|
658
541
|
}
|
|
659
542
|
return result;
|
|
660
543
|
}
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
function isArrayLike$6(value) {
|
|
664
|
-
return value != null && isLength$1(value.length) && !isFunction(value);
|
|
544
|
+
function keys(object) {
|
|
545
|
+
return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
|
|
665
546
|
}
|
|
666
|
-
var
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
547
|
+
var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/;
|
|
548
|
+
function isKey(value, object) {
|
|
549
|
+
if (isArray(value)) {
|
|
550
|
+
return false;
|
|
551
|
+
}
|
|
552
|
+
var type2 = typeof value;
|
|
553
|
+
if (type2 == "number" || type2 == "symbol" || type2 == "boolean" || value == null || isSymbol(value)) {
|
|
554
|
+
return true;
|
|
555
|
+
}
|
|
556
|
+
return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object(object);
|
|
670
557
|
}
|
|
671
|
-
var
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
558
|
+
var nativeCreate = getNative(Object, "create");
|
|
559
|
+
function hashClear() {
|
|
560
|
+
this.__data__ = nativeCreate ? nativeCreate(null) : {};
|
|
561
|
+
this.size = 0;
|
|
675
562
|
}
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
if (object != null) {
|
|
680
|
-
for (var key in Object(object)) {
|
|
681
|
-
result.push(key);
|
|
682
|
-
}
|
|
683
|
-
}
|
|
563
|
+
function hashDelete(key) {
|
|
564
|
+
var result = this.has(key) && delete this.__data__[key];
|
|
565
|
+
this.size -= result ? 1 : 0;
|
|
684
566
|
return result;
|
|
685
567
|
}
|
|
686
|
-
var
|
|
687
|
-
var
|
|
568
|
+
var HASH_UNDEFINED$2 = "__lodash_hash_undefined__";
|
|
569
|
+
var objectProto$6 = Object.prototype;
|
|
570
|
+
var hasOwnProperty$5 = objectProto$6.hasOwnProperty;
|
|
571
|
+
function hashGet(key) {
|
|
572
|
+
var data = this.__data__;
|
|
573
|
+
if (nativeCreate) {
|
|
574
|
+
var result = data[key];
|
|
575
|
+
return result === HASH_UNDEFINED$2 ? void 0 : result;
|
|
576
|
+
}
|
|
577
|
+
return hasOwnProperty$5.call(data, key) ? data[key] : void 0;
|
|
578
|
+
}
|
|
688
579
|
var objectProto$5 = Object.prototype;
|
|
689
580
|
var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
|
|
690
|
-
function
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
}
|
|
694
|
-
var isProto = isPrototype$2(object), result = [];
|
|
695
|
-
for (var key in object) {
|
|
696
|
-
if (!(key == "constructor" && (isProto || !hasOwnProperty$4.call(object, key)))) {
|
|
697
|
-
result.push(key);
|
|
698
|
-
}
|
|
699
|
-
}
|
|
700
|
-
return result;
|
|
581
|
+
function hashHas(key) {
|
|
582
|
+
var data = this.__data__;
|
|
583
|
+
return nativeCreate ? data[key] !== void 0 : hasOwnProperty$4.call(data, key);
|
|
701
584
|
}
|
|
702
|
-
var
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
var copyObject$2 = _copyObject, keysIn$2 = keysIn_1;
|
|
709
|
-
function baseAssignIn$1(object, source) {
|
|
710
|
-
return object && copyObject$2(source, keysIn$2(source), object);
|
|
711
|
-
}
|
|
712
|
-
var _baseAssignIn = baseAssignIn$1;
|
|
713
|
-
var _cloneBuffer = { exports: {} };
|
|
714
|
-
_cloneBuffer.exports;
|
|
715
|
-
(function(module, exports) {
|
|
716
|
-
var root2 = _root;
|
|
717
|
-
var freeExports = exports && !exports.nodeType && exports;
|
|
718
|
-
var freeModule = freeExports && true && module && !module.nodeType && module;
|
|
719
|
-
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
720
|
-
var Buffer = moduleExports ? root2.Buffer : void 0, allocUnsafe = Buffer ? Buffer.allocUnsafe : void 0;
|
|
721
|
-
function cloneBuffer2(buffer, isDeep) {
|
|
722
|
-
if (isDeep) {
|
|
723
|
-
return buffer.slice();
|
|
724
|
-
}
|
|
725
|
-
var length = buffer.length, result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);
|
|
726
|
-
buffer.copy(result);
|
|
727
|
-
return result;
|
|
728
|
-
}
|
|
729
|
-
module.exports = cloneBuffer2;
|
|
730
|
-
})(_cloneBuffer, _cloneBuffer.exports);
|
|
731
|
-
var _cloneBufferExports = _cloneBuffer.exports;
|
|
732
|
-
function copyArray$2(source, array) {
|
|
733
|
-
var index2 = -1, length = source.length;
|
|
734
|
-
array || (array = Array(length));
|
|
735
|
-
while (++index2 < length) {
|
|
736
|
-
array[index2] = source[index2];
|
|
737
|
-
}
|
|
738
|
-
return array;
|
|
585
|
+
var HASH_UNDEFINED$1 = "__lodash_hash_undefined__";
|
|
586
|
+
function hashSet(key, value) {
|
|
587
|
+
var data = this.__data__;
|
|
588
|
+
this.size += this.has(key) ? 0 : 1;
|
|
589
|
+
data[key] = nativeCreate && value === void 0 ? HASH_UNDEFINED$1 : value;
|
|
590
|
+
return this;
|
|
739
591
|
}
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
592
|
+
function Hash(entries) {
|
|
593
|
+
var index2 = -1, length = entries == null ? 0 : entries.length;
|
|
594
|
+
this.clear();
|
|
743
595
|
while (++index2 < length) {
|
|
744
|
-
var
|
|
745
|
-
|
|
746
|
-
result[resIndex++] = value;
|
|
747
|
-
}
|
|
748
|
-
}
|
|
749
|
-
return result;
|
|
750
|
-
}
|
|
751
|
-
var _arrayFilter = arrayFilter$1;
|
|
752
|
-
function stubArray$2() {
|
|
753
|
-
return [];
|
|
754
|
-
}
|
|
755
|
-
var stubArray_1 = stubArray$2;
|
|
756
|
-
var arrayFilter = _arrayFilter, stubArray$1 = stubArray_1;
|
|
757
|
-
var objectProto$4 = Object.prototype;
|
|
758
|
-
var propertyIsEnumerable = objectProto$4.propertyIsEnumerable;
|
|
759
|
-
var nativeGetSymbols$1 = Object.getOwnPropertySymbols;
|
|
760
|
-
var getSymbols$3 = !nativeGetSymbols$1 ? stubArray$1 : function(object) {
|
|
761
|
-
if (object == null) {
|
|
762
|
-
return [];
|
|
596
|
+
var entry = entries[index2];
|
|
597
|
+
this.set(entry[0], entry[1]);
|
|
763
598
|
}
|
|
764
|
-
object = Object(object);
|
|
765
|
-
return arrayFilter(nativeGetSymbols$1(object), function(symbol) {
|
|
766
|
-
return propertyIsEnumerable.call(object, symbol);
|
|
767
|
-
});
|
|
768
|
-
};
|
|
769
|
-
var _getSymbols = getSymbols$3;
|
|
770
|
-
var copyObject$1 = _copyObject, getSymbols$2 = _getSymbols;
|
|
771
|
-
function copySymbols$1(source, object) {
|
|
772
|
-
return copyObject$1(source, getSymbols$2(source), object);
|
|
773
599
|
}
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
600
|
+
Hash.prototype.clear = hashClear;
|
|
601
|
+
Hash.prototype["delete"] = hashDelete;
|
|
602
|
+
Hash.prototype.get = hashGet;
|
|
603
|
+
Hash.prototype.has = hashHas;
|
|
604
|
+
Hash.prototype.set = hashSet;
|
|
605
|
+
function listCacheClear() {
|
|
606
|
+
this.__data__ = [];
|
|
607
|
+
this.size = 0;
|
|
781
608
|
}
|
|
782
|
-
|
|
783
|
-
var
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
var nativeGetSymbols = Object.getOwnPropertySymbols;
|
|
788
|
-
var getSymbolsIn$2 = !nativeGetSymbols ? stubArray : function(object) {
|
|
789
|
-
var result = [];
|
|
790
|
-
while (object) {
|
|
791
|
-
arrayPush$2(result, getSymbols$1(object));
|
|
792
|
-
object = getPrototype$1(object);
|
|
793
|
-
}
|
|
794
|
-
return result;
|
|
795
|
-
};
|
|
796
|
-
var _getSymbolsIn = getSymbolsIn$2;
|
|
797
|
-
var copyObject = _copyObject, getSymbolsIn$1 = _getSymbolsIn;
|
|
798
|
-
function copySymbolsIn$1(source, object) {
|
|
799
|
-
return copyObject(source, getSymbolsIn$1(source), object);
|
|
800
|
-
}
|
|
801
|
-
var _copySymbolsIn = copySymbolsIn$1;
|
|
802
|
-
var arrayPush$1 = _arrayPush, isArray$c = isArray_1;
|
|
803
|
-
function baseGetAllKeys$2(object, keysFunc, symbolsFunc) {
|
|
804
|
-
var result = keysFunc(object);
|
|
805
|
-
return isArray$c(object) ? result : arrayPush$1(result, symbolsFunc(object));
|
|
806
|
-
}
|
|
807
|
-
var _baseGetAllKeys = baseGetAllKeys$2;
|
|
808
|
-
var baseGetAllKeys$1 = _baseGetAllKeys, getSymbols = _getSymbols, keys$3 = keys_1;
|
|
809
|
-
function getAllKeys$2(object) {
|
|
810
|
-
return baseGetAllKeys$1(object, keys$3, getSymbols);
|
|
811
|
-
}
|
|
812
|
-
var _getAllKeys = getAllKeys$2;
|
|
813
|
-
var baseGetAllKeys = _baseGetAllKeys, getSymbolsIn = _getSymbolsIn, keysIn$1 = keysIn_1;
|
|
814
|
-
function getAllKeysIn$1(object) {
|
|
815
|
-
return baseGetAllKeys(object, keysIn$1, getSymbolsIn);
|
|
816
|
-
}
|
|
817
|
-
var _getAllKeysIn = getAllKeysIn$1;
|
|
818
|
-
var getNative$3 = _getNative, root$4 = _root;
|
|
819
|
-
var DataView$1 = getNative$3(root$4, "DataView");
|
|
820
|
-
var _DataView = DataView$1;
|
|
821
|
-
var getNative$2 = _getNative, root$3 = _root;
|
|
822
|
-
var Promise$2 = getNative$2(root$3, "Promise");
|
|
823
|
-
var _Promise = Promise$2;
|
|
824
|
-
var getNative$1 = _getNative, root$2 = _root;
|
|
825
|
-
var Set$1 = getNative$1(root$2, "Set");
|
|
826
|
-
var _Set = Set$1;
|
|
827
|
-
var getNative = _getNative, root$1 = _root;
|
|
828
|
-
var WeakMap$1 = getNative(root$1, "WeakMap");
|
|
829
|
-
var _WeakMap = WeakMap$1;
|
|
830
|
-
var DataView = _DataView, Map = _Map, Promise$1 = _Promise, Set = _Set, WeakMap = _WeakMap, baseGetTag$2 = _baseGetTag, toSource = _toSource;
|
|
831
|
-
var mapTag$5 = "[object Map]", objectTag$2 = "[object Object]", promiseTag = "[object Promise]", setTag$5 = "[object Set]", weakMapTag$1 = "[object WeakMap]";
|
|
832
|
-
var dataViewTag$3 = "[object DataView]";
|
|
833
|
-
var dataViewCtorString = toSource(DataView), mapCtorString = toSource(Map), promiseCtorString = toSource(Promise$1), setCtorString = toSource(Set), weakMapCtorString = toSource(WeakMap);
|
|
834
|
-
var getTag$5 = baseGetTag$2;
|
|
835
|
-
if (DataView && getTag$5(new DataView(new ArrayBuffer(1))) != dataViewTag$3 || Map && getTag$5(new Map()) != mapTag$5 || Promise$1 && getTag$5(Promise$1.resolve()) != promiseTag || Set && getTag$5(new Set()) != setTag$5 || WeakMap && getTag$5(new WeakMap()) != weakMapTag$1) {
|
|
836
|
-
getTag$5 = function(value) {
|
|
837
|
-
var result = baseGetTag$2(value), Ctor = result == objectTag$2 ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
|
|
838
|
-
if (ctorString) {
|
|
839
|
-
switch (ctorString) {
|
|
840
|
-
case dataViewCtorString:
|
|
841
|
-
return dataViewTag$3;
|
|
842
|
-
case mapCtorString:
|
|
843
|
-
return mapTag$5;
|
|
844
|
-
case promiseCtorString:
|
|
845
|
-
return promiseTag;
|
|
846
|
-
case setCtorString:
|
|
847
|
-
return setTag$5;
|
|
848
|
-
case weakMapCtorString:
|
|
849
|
-
return weakMapTag$1;
|
|
850
|
-
}
|
|
609
|
+
function assocIndexOf(array, key) {
|
|
610
|
+
var length = array.length;
|
|
611
|
+
while (length--) {
|
|
612
|
+
if (eq(array[length][0], key)) {
|
|
613
|
+
return length;
|
|
851
614
|
}
|
|
852
|
-
return result;
|
|
853
|
-
};
|
|
854
|
-
}
|
|
855
|
-
var _getTag = getTag$5;
|
|
856
|
-
var objectProto$3 = Object.prototype;
|
|
857
|
-
var hasOwnProperty$3 = objectProto$3.hasOwnProperty;
|
|
858
|
-
function initCloneArray$1(array) {
|
|
859
|
-
var length = array.length, result = new array.constructor(length);
|
|
860
|
-
if (length && typeof array[0] == "string" && hasOwnProperty$3.call(array, "index")) {
|
|
861
|
-
result.index = array.index;
|
|
862
|
-
result.input = array.input;
|
|
863
615
|
}
|
|
864
|
-
return
|
|
865
|
-
}
|
|
866
|
-
var _initCloneArray = initCloneArray$1;
|
|
867
|
-
var root = _root;
|
|
868
|
-
var Uint8Array$3 = root.Uint8Array;
|
|
869
|
-
var _Uint8Array = Uint8Array$3;
|
|
870
|
-
var Uint8Array$2 = _Uint8Array;
|
|
871
|
-
function cloneArrayBuffer$3(arrayBuffer) {
|
|
872
|
-
var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
|
|
873
|
-
new Uint8Array$2(result).set(new Uint8Array$2(arrayBuffer));
|
|
874
|
-
return result;
|
|
875
|
-
}
|
|
876
|
-
var _cloneArrayBuffer = cloneArrayBuffer$3;
|
|
877
|
-
var cloneArrayBuffer$2 = _cloneArrayBuffer;
|
|
878
|
-
function cloneDataView$1(dataView, isDeep) {
|
|
879
|
-
var buffer = isDeep ? cloneArrayBuffer$2(dataView.buffer) : dataView.buffer;
|
|
880
|
-
return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);
|
|
881
|
-
}
|
|
882
|
-
var _cloneDataView = cloneDataView$1;
|
|
883
|
-
var reFlags = /\w*$/;
|
|
884
|
-
function cloneRegExp$1(regexp) {
|
|
885
|
-
var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));
|
|
886
|
-
result.lastIndex = regexp.lastIndex;
|
|
887
|
-
return result;
|
|
888
|
-
}
|
|
889
|
-
var _cloneRegExp = cloneRegExp$1;
|
|
890
|
-
var Symbol$4 = _Symbol;
|
|
891
|
-
var symbolProto$2 = Symbol$4 ? Symbol$4.prototype : void 0, symbolValueOf$1 = symbolProto$2 ? symbolProto$2.valueOf : void 0;
|
|
892
|
-
function cloneSymbol$1(symbol) {
|
|
893
|
-
return symbolValueOf$1 ? Object(symbolValueOf$1.call(symbol)) : {};
|
|
894
|
-
}
|
|
895
|
-
var _cloneSymbol = cloneSymbol$1;
|
|
896
|
-
var cloneArrayBuffer$1 = _cloneArrayBuffer;
|
|
897
|
-
function cloneTypedArray$1(typedArray, isDeep) {
|
|
898
|
-
var buffer = isDeep ? cloneArrayBuffer$1(typedArray.buffer) : typedArray.buffer;
|
|
899
|
-
return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
|
|
616
|
+
return -1;
|
|
900
617
|
}
|
|
901
|
-
var
|
|
902
|
-
var
|
|
903
|
-
|
|
904
|
-
var
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
switch (tag) {
|
|
908
|
-
case arrayBufferTag$2:
|
|
909
|
-
return cloneArrayBuffer(object);
|
|
910
|
-
case boolTag$2:
|
|
911
|
-
case dateTag$2:
|
|
912
|
-
return new Ctor(+object);
|
|
913
|
-
case dataViewTag$2:
|
|
914
|
-
return cloneDataView(object, isDeep);
|
|
915
|
-
case float32Tag$1:
|
|
916
|
-
case float64Tag$1:
|
|
917
|
-
case int8Tag$1:
|
|
918
|
-
case int16Tag$1:
|
|
919
|
-
case int32Tag$1:
|
|
920
|
-
case uint8Tag$1:
|
|
921
|
-
case uint8ClampedTag$1:
|
|
922
|
-
case uint16Tag$1:
|
|
923
|
-
case uint32Tag$1:
|
|
924
|
-
return cloneTypedArray(object, isDeep);
|
|
925
|
-
case mapTag$4:
|
|
926
|
-
return new Ctor();
|
|
927
|
-
case numberTag$3:
|
|
928
|
-
case stringTag$2:
|
|
929
|
-
return new Ctor(object);
|
|
930
|
-
case regexpTag$2:
|
|
931
|
-
return cloneRegExp(object);
|
|
932
|
-
case setTag$4:
|
|
933
|
-
return new Ctor();
|
|
934
|
-
case symbolTag$3:
|
|
935
|
-
return cloneSymbol(object);
|
|
618
|
+
var arrayProto$1 = Array.prototype;
|
|
619
|
+
var splice$1 = arrayProto$1.splice;
|
|
620
|
+
function listCacheDelete(key) {
|
|
621
|
+
var data = this.__data__, index2 = assocIndexOf(data, key);
|
|
622
|
+
if (index2 < 0) {
|
|
623
|
+
return false;
|
|
936
624
|
}
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
function object() {
|
|
625
|
+
var lastIndex = data.length - 1;
|
|
626
|
+
if (index2 == lastIndex) {
|
|
627
|
+
data.pop();
|
|
628
|
+
} else {
|
|
629
|
+
splice$1.call(data, index2, 1);
|
|
943
630
|
}
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
return {};
|
|
947
|
-
}
|
|
948
|
-
if (objectCreate) {
|
|
949
|
-
return objectCreate(proto);
|
|
950
|
-
}
|
|
951
|
-
object.prototype = proto;
|
|
952
|
-
var result = new object();
|
|
953
|
-
object.prototype = void 0;
|
|
954
|
-
return result;
|
|
955
|
-
};
|
|
956
|
-
}();
|
|
957
|
-
var _baseCreate = baseCreate$1;
|
|
958
|
-
var baseCreate = _baseCreate, getPrototype = _getPrototype, isPrototype$1 = _isPrototype;
|
|
959
|
-
function initCloneObject$1(object) {
|
|
960
|
-
return typeof object.constructor == "function" && !isPrototype$1(object) ? baseCreate(getPrototype(object)) : {};
|
|
631
|
+
--this.size;
|
|
632
|
+
return true;
|
|
961
633
|
}
|
|
962
|
-
|
|
963
|
-
var
|
|
964
|
-
|
|
965
|
-
function baseIsMap$1(value) {
|
|
966
|
-
return isObjectLike$4(value) && getTag$4(value) == mapTag$3;
|
|
967
|
-
}
|
|
968
|
-
var _baseIsMap = baseIsMap$1;
|
|
969
|
-
var baseIsMap = _baseIsMap, baseUnary$3 = _baseUnary, nodeUtil$1 = _nodeUtilExports;
|
|
970
|
-
var nodeIsMap = nodeUtil$1 && nodeUtil$1.isMap;
|
|
971
|
-
var isMap$1 = nodeIsMap ? baseUnary$3(nodeIsMap) : baseIsMap;
|
|
972
|
-
var isMap_1 = isMap$1;
|
|
973
|
-
var getTag$3 = _getTag, isObjectLike$3 = isObjectLike_1;
|
|
974
|
-
var setTag$3 = "[object Set]";
|
|
975
|
-
function baseIsSet$1(value) {
|
|
976
|
-
return isObjectLike$3(value) && getTag$3(value) == setTag$3;
|
|
634
|
+
function listCacheGet(key) {
|
|
635
|
+
var data = this.__data__, index2 = assocIndexOf(data, key);
|
|
636
|
+
return index2 < 0 ? void 0 : data[index2][1];
|
|
977
637
|
}
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
var
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
var arrayBufferTag$1 = "[object ArrayBuffer]", dataViewTag$1 = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
|
|
987
|
-
var cloneableTags = {};
|
|
988
|
-
cloneableTags[argsTag$1] = cloneableTags[arrayTag$1] = cloneableTags[arrayBufferTag$1] = cloneableTags[dataViewTag$1] = cloneableTags[boolTag$1] = cloneableTags[dateTag$1] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag$2] = cloneableTags[numberTag$2] = cloneableTags[objectTag$1] = cloneableTags[regexpTag$1] = cloneableTags[setTag$2] = cloneableTags[stringTag$1] = cloneableTags[symbolTag$2] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
|
|
989
|
-
cloneableTags[errorTag$1] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = false;
|
|
990
|
-
function baseClone$1(value, bitmask, customizer, key, object, stack) {
|
|
991
|
-
var result, isDeep = bitmask & CLONE_DEEP_FLAG$1, isFlat = bitmask & CLONE_FLAT_FLAG, isFull = bitmask & CLONE_SYMBOLS_FLAG$1;
|
|
992
|
-
if (customizer) {
|
|
993
|
-
result = object ? customizer(value, key, object, stack) : customizer(value);
|
|
994
|
-
}
|
|
995
|
-
if (result !== void 0) {
|
|
996
|
-
return result;
|
|
997
|
-
}
|
|
998
|
-
if (!isObject$3(value)) {
|
|
999
|
-
return value;
|
|
1000
|
-
}
|
|
1001
|
-
var isArr = isArray$b(value);
|
|
1002
|
-
if (isArr) {
|
|
1003
|
-
result = initCloneArray(value);
|
|
1004
|
-
if (!isDeep) {
|
|
1005
|
-
return copyArray$1(value, result);
|
|
1006
|
-
}
|
|
638
|
+
function listCacheHas(key) {
|
|
639
|
+
return assocIndexOf(this.__data__, key) > -1;
|
|
640
|
+
}
|
|
641
|
+
function listCacheSet(key, value) {
|
|
642
|
+
var data = this.__data__, index2 = assocIndexOf(data, key);
|
|
643
|
+
if (index2 < 0) {
|
|
644
|
+
++this.size;
|
|
645
|
+
data.push([key, value]);
|
|
1007
646
|
} else {
|
|
1008
|
-
|
|
1009
|
-
if (isBuffer$2(value)) {
|
|
1010
|
-
return cloneBuffer(value, isDeep);
|
|
1011
|
-
}
|
|
1012
|
-
if (tag == objectTag$1 || tag == argsTag$1 || isFunc && !object) {
|
|
1013
|
-
result = isFlat || isFunc ? {} : initCloneObject(value);
|
|
1014
|
-
if (!isDeep) {
|
|
1015
|
-
return isFlat ? copySymbolsIn(value, baseAssignIn(result, value)) : copySymbols(value, baseAssign(result, value));
|
|
1016
|
-
}
|
|
1017
|
-
} else {
|
|
1018
|
-
if (!cloneableTags[tag]) {
|
|
1019
|
-
return object ? value : {};
|
|
1020
|
-
}
|
|
1021
|
-
result = initCloneByTag(value, tag, isDeep);
|
|
1022
|
-
}
|
|
1023
|
-
}
|
|
1024
|
-
stack || (stack = new Stack$2());
|
|
1025
|
-
var stacked = stack.get(value);
|
|
1026
|
-
if (stacked) {
|
|
1027
|
-
return stacked;
|
|
647
|
+
data[index2][1] = value;
|
|
1028
648
|
}
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
});
|
|
649
|
+
return this;
|
|
650
|
+
}
|
|
651
|
+
function ListCache(entries) {
|
|
652
|
+
var index2 = -1, length = entries == null ? 0 : entries.length;
|
|
653
|
+
this.clear();
|
|
654
|
+
while (++index2 < length) {
|
|
655
|
+
var entry = entries[index2];
|
|
656
|
+
this.set(entry[0], entry[1]);
|
|
1038
657
|
}
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
658
|
+
}
|
|
659
|
+
ListCache.prototype.clear = listCacheClear;
|
|
660
|
+
ListCache.prototype["delete"] = listCacheDelete;
|
|
661
|
+
ListCache.prototype.get = listCacheGet;
|
|
662
|
+
ListCache.prototype.has = listCacheHas;
|
|
663
|
+
ListCache.prototype.set = listCacheSet;
|
|
664
|
+
var Map = getNative(root, "Map");
|
|
665
|
+
function mapCacheClear() {
|
|
666
|
+
this.size = 0;
|
|
667
|
+
this.__data__ = {
|
|
668
|
+
"hash": new Hash(),
|
|
669
|
+
"map": new (Map || ListCache)(),
|
|
670
|
+
"string": new Hash()
|
|
671
|
+
};
|
|
672
|
+
}
|
|
673
|
+
function isKeyable(value) {
|
|
674
|
+
var type2 = typeof value;
|
|
675
|
+
return type2 == "string" || type2 == "number" || type2 == "symbol" || type2 == "boolean" ? value !== "__proto__" : value === null;
|
|
676
|
+
}
|
|
677
|
+
function getMapData(map, key) {
|
|
678
|
+
var data = map.__data__;
|
|
679
|
+
return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
|
|
680
|
+
}
|
|
681
|
+
function mapCacheDelete(key) {
|
|
682
|
+
var result = getMapData(this, key)["delete"](key);
|
|
683
|
+
this.size -= result ? 1 : 0;
|
|
1048
684
|
return result;
|
|
1049
685
|
}
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
var CLONE_DEEP_FLAG = 1, CLONE_SYMBOLS_FLAG = 4;
|
|
1053
|
-
function cloneDeep(value) {
|
|
1054
|
-
return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);
|
|
686
|
+
function mapCacheGet(key) {
|
|
687
|
+
return getMapData(this, key).get(key);
|
|
1055
688
|
}
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
var baseGetTag$1 = _baseGetTag, isObjectLike$2 = isObjectLike_1;
|
|
1059
|
-
var numberTag$1 = "[object Number]";
|
|
1060
|
-
function isNumber(value) {
|
|
1061
|
-
return typeof value == "number" || isObjectLike$2(value) && baseGetTag$1(value) == numberTag$1;
|
|
689
|
+
function mapCacheHas(key) {
|
|
690
|
+
return getMapData(this, key).has(key);
|
|
1062
691
|
}
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
return typeof value == "symbol" || isObjectLike$1(value) && baseGetTag(value) == symbolTag$1;
|
|
692
|
+
function mapCacheSet(key, value) {
|
|
693
|
+
var data = getMapData(this, key), size = data.size;
|
|
694
|
+
data.set(key, value);
|
|
695
|
+
this.size += data.size == size ? 0 : 1;
|
|
696
|
+
return this;
|
|
1069
697
|
}
|
|
1070
|
-
|
|
1071
|
-
var
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
}
|
|
1077
|
-
var type2 = typeof value;
|
|
1078
|
-
if (type2 == "number" || type2 == "symbol" || type2 == "boolean" || value == null || isSymbol$3(value)) {
|
|
1079
|
-
return true;
|
|
698
|
+
function MapCache(entries) {
|
|
699
|
+
var index2 = -1, length = entries == null ? 0 : entries.length;
|
|
700
|
+
this.clear();
|
|
701
|
+
while (++index2 < length) {
|
|
702
|
+
var entry = entries[index2];
|
|
703
|
+
this.set(entry[0], entry[1]);
|
|
1080
704
|
}
|
|
1081
|
-
return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object(object);
|
|
1082
705
|
}
|
|
1083
|
-
|
|
1084
|
-
|
|
706
|
+
MapCache.prototype.clear = mapCacheClear;
|
|
707
|
+
MapCache.prototype["delete"] = mapCacheDelete;
|
|
708
|
+
MapCache.prototype.get = mapCacheGet;
|
|
709
|
+
MapCache.prototype.has = mapCacheHas;
|
|
710
|
+
MapCache.prototype.set = mapCacheSet;
|
|
1085
711
|
var FUNC_ERROR_TEXT = "Expected a function";
|
|
1086
|
-
function memoize
|
|
712
|
+
function memoize(func, resolver) {
|
|
1087
713
|
if (typeof func != "function" || resolver != null && typeof resolver != "function") {
|
|
1088
714
|
throw new TypeError(FUNC_ERROR_TEXT);
|
|
1089
715
|
}
|
|
@@ -1096,14 +722,12 @@ function memoize$1(func, resolver) {
|
|
|
1096
722
|
memoized.cache = cache.set(key, result) || cache;
|
|
1097
723
|
return result;
|
|
1098
724
|
};
|
|
1099
|
-
memoized.cache = new (memoize
|
|
725
|
+
memoized.cache = new (memoize.Cache || MapCache)();
|
|
1100
726
|
return memoized;
|
|
1101
727
|
}
|
|
1102
|
-
memoize
|
|
1103
|
-
var memoize_1 = memoize$1;
|
|
1104
|
-
var memoize = memoize_1;
|
|
728
|
+
memoize.Cache = MapCache;
|
|
1105
729
|
var MAX_MEMOIZE_SIZE = 500;
|
|
1106
|
-
function memoizeCapped
|
|
730
|
+
function memoizeCapped(func) {
|
|
1107
731
|
var result = memoize(func, function(key) {
|
|
1108
732
|
if (cache.size === MAX_MEMOIZE_SIZE) {
|
|
1109
733
|
cache.clear();
|
|
@@ -1113,11 +737,9 @@ function memoizeCapped$1(func) {
|
|
|
1113
737
|
var cache = result.cache;
|
|
1114
738
|
return result;
|
|
1115
739
|
}
|
|
1116
|
-
var _memoizeCapped = memoizeCapped$1;
|
|
1117
|
-
var memoizeCapped = _memoizeCapped;
|
|
1118
740
|
var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
|
|
1119
741
|
var reEscapeChar = /\\(\\)?/g;
|
|
1120
|
-
var stringToPath
|
|
742
|
+
var stringToPath = memoizeCapped(function(string) {
|
|
1121
743
|
var result = [];
|
|
1122
744
|
if (string.charCodeAt(0) === 46) {
|
|
1123
745
|
result.push("");
|
|
@@ -1127,405 +749,350 @@ var stringToPath$1 = memoizeCapped(function(string) {
|
|
|
1127
749
|
});
|
|
1128
750
|
return result;
|
|
1129
751
|
});
|
|
1130
|
-
|
|
1131
|
-
function arrayMap$3(array, iteratee) {
|
|
1132
|
-
var index2 = -1, length = array == null ? 0 : array.length, result = Array(length);
|
|
1133
|
-
while (++index2 < length) {
|
|
1134
|
-
result[index2] = iteratee(array[index2], index2, array);
|
|
1135
|
-
}
|
|
1136
|
-
return result;
|
|
1137
|
-
}
|
|
1138
|
-
var _arrayMap = arrayMap$3;
|
|
1139
|
-
var Symbol$3 = _Symbol, arrayMap$2 = _arrayMap, isArray$9 = isArray_1, isSymbol$2 = isSymbol_1;
|
|
1140
|
-
var INFINITY$1 = 1 / 0;
|
|
1141
|
-
var symbolProto$1 = Symbol$3 ? Symbol$3.prototype : void 0, symbolToString = symbolProto$1 ? symbolProto$1.toString : void 0;
|
|
1142
|
-
function baseToString$1(value) {
|
|
1143
|
-
if (typeof value == "string") {
|
|
1144
|
-
return value;
|
|
1145
|
-
}
|
|
1146
|
-
if (isArray$9(value)) {
|
|
1147
|
-
return arrayMap$2(value, baseToString$1) + "";
|
|
1148
|
-
}
|
|
1149
|
-
if (isSymbol$2(value)) {
|
|
1150
|
-
return symbolToString ? symbolToString.call(value) : "";
|
|
1151
|
-
}
|
|
1152
|
-
var result = value + "";
|
|
1153
|
-
return result == "0" && 1 / value == -INFINITY$1 ? "-0" : result;
|
|
1154
|
-
}
|
|
1155
|
-
var _baseToString = baseToString$1;
|
|
1156
|
-
var baseToString = _baseToString;
|
|
1157
|
-
function toString$2(value) {
|
|
752
|
+
function toString(value) {
|
|
1158
753
|
return value == null ? "" : baseToString(value);
|
|
1159
754
|
}
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
function castPath$4(value, object) {
|
|
1163
|
-
if (isArray$8(value)) {
|
|
755
|
+
function castPath(value, object) {
|
|
756
|
+
if (isArray(value)) {
|
|
1164
757
|
return value;
|
|
1165
758
|
}
|
|
1166
|
-
return isKey
|
|
759
|
+
return isKey(value, object) ? [value] : stringToPath(toString(value));
|
|
1167
760
|
}
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
var INFINITY = 1 / 0;
|
|
1171
|
-
function toKey$5(value) {
|
|
1172
|
-
if (typeof value == "string" || isSymbol$1(value)) {
|
|
761
|
+
function toKey(value) {
|
|
762
|
+
if (typeof value == "string" || isSymbol(value)) {
|
|
1173
763
|
return value;
|
|
1174
764
|
}
|
|
1175
765
|
var result = value + "";
|
|
1176
|
-
return result == "0" && 1 / value == -
|
|
766
|
+
return result == "0" && 1 / value == -Infinity ? "-0" : result;
|
|
1177
767
|
}
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
function baseGet$4(object, path) {
|
|
1181
|
-
path = castPath$3(path, object);
|
|
768
|
+
function baseGet(object, path) {
|
|
769
|
+
path = castPath(path, object);
|
|
1182
770
|
var index2 = 0, length = path.length;
|
|
1183
771
|
while (object != null && index2 < length) {
|
|
1184
|
-
object = object[toKey
|
|
772
|
+
object = object[toKey(path[index2++])];
|
|
1185
773
|
}
|
|
1186
774
|
return index2 && index2 == length ? object : void 0;
|
|
1187
775
|
}
|
|
1188
|
-
|
|
1189
|
-
var
|
|
1190
|
-
|
|
1191
|
-
if (!isObject$2(object)) {
|
|
1192
|
-
return object;
|
|
1193
|
-
}
|
|
1194
|
-
path = castPath$2(path, object);
|
|
1195
|
-
var index2 = -1, length = path.length, lastIndex = length - 1, nested = object;
|
|
1196
|
-
while (nested != null && ++index2 < length) {
|
|
1197
|
-
var key = toKey$3(path[index2]), newValue = value;
|
|
1198
|
-
if (key === "__proto__" || key === "constructor" || key === "prototype") {
|
|
1199
|
-
return object;
|
|
1200
|
-
}
|
|
1201
|
-
if (index2 != lastIndex) {
|
|
1202
|
-
var objValue = nested[key];
|
|
1203
|
-
newValue = customizer ? customizer(objValue, key, nested) : void 0;
|
|
1204
|
-
if (newValue === void 0) {
|
|
1205
|
-
newValue = isObject$2(objValue) ? objValue : isIndex$2(path[index2 + 1]) ? [] : {};
|
|
1206
|
-
}
|
|
1207
|
-
}
|
|
1208
|
-
assignValue(nested, key, newValue);
|
|
1209
|
-
nested = nested[key];
|
|
1210
|
-
}
|
|
1211
|
-
return object;
|
|
1212
|
-
}
|
|
1213
|
-
var _baseSet = baseSet$1;
|
|
1214
|
-
var baseGet$3 = _baseGet, baseSet = _baseSet, castPath$1 = _castPath;
|
|
1215
|
-
function basePickBy$1(object, paths, predicate) {
|
|
1216
|
-
var index2 = -1, length = paths.length, result = {};
|
|
1217
|
-
while (++index2 < length) {
|
|
1218
|
-
var path = paths[index2], value = baseGet$3(object, path);
|
|
1219
|
-
if (predicate(value, path)) {
|
|
1220
|
-
baseSet(result, castPath$1(path, object), value);
|
|
1221
|
-
}
|
|
1222
|
-
}
|
|
1223
|
-
return result;
|
|
1224
|
-
}
|
|
1225
|
-
var _basePickBy = basePickBy$1;
|
|
1226
|
-
function baseHasIn$1(object, key) {
|
|
1227
|
-
return object != null && key in Object(object);
|
|
776
|
+
function get(object, path, defaultValue) {
|
|
777
|
+
var result = object == null ? void 0 : baseGet(object, path);
|
|
778
|
+
return result === void 0 ? defaultValue : result;
|
|
1228
779
|
}
|
|
1229
|
-
|
|
1230
|
-
var
|
|
1231
|
-
function hasPath$1(object, path, hasFunc) {
|
|
1232
|
-
path = castPath(path, object);
|
|
1233
|
-
var index2 = -1, length = path.length, result = false;
|
|
780
|
+
function arrayPush(array, values) {
|
|
781
|
+
var index2 = -1, length = values.length, offset = array.length;
|
|
1234
782
|
while (++index2 < length) {
|
|
1235
|
-
|
|
1236
|
-
if (!(result = object != null && hasFunc(object, key))) {
|
|
1237
|
-
break;
|
|
1238
|
-
}
|
|
1239
|
-
object = object[key];
|
|
1240
|
-
}
|
|
1241
|
-
if (result || ++index2 != length) {
|
|
1242
|
-
return result;
|
|
783
|
+
array[offset + index2] = values[index2];
|
|
1243
784
|
}
|
|
1244
|
-
|
|
1245
|
-
return !!length && isLength(length) && isIndex$1(key, length) && (isArray$7(object) || isArguments$2(object));
|
|
1246
|
-
}
|
|
1247
|
-
var _hasPath = hasPath$1;
|
|
1248
|
-
var baseHasIn = _baseHasIn, hasPath = _hasPath;
|
|
1249
|
-
function hasIn$2(object, path) {
|
|
1250
|
-
return object != null && hasPath(object, path, baseHasIn);
|
|
1251
|
-
}
|
|
1252
|
-
var hasIn_1 = hasIn$2;
|
|
1253
|
-
var basePickBy = _basePickBy, hasIn$1 = hasIn_1;
|
|
1254
|
-
function basePick$1(object, paths) {
|
|
1255
|
-
return basePickBy(object, paths, function(value, path) {
|
|
1256
|
-
return hasIn$1(object, path);
|
|
1257
|
-
});
|
|
785
|
+
return array;
|
|
1258
786
|
}
|
|
1259
|
-
var
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
function isFlattenable$1(value) {
|
|
1263
|
-
return isArray$6(value) || isArguments$1(value) || !!(spreadableSymbol && value && value[spreadableSymbol]);
|
|
787
|
+
var spreadableSymbol = Symbol$1 ? Symbol$1.isConcatSpreadable : void 0;
|
|
788
|
+
function isFlattenable(value) {
|
|
789
|
+
return isArray(value) || isArguments(value) || !!(spreadableSymbol && value && value[spreadableSymbol]);
|
|
1264
790
|
}
|
|
1265
|
-
|
|
1266
|
-
var arrayPush = _arrayPush, isFlattenable = _isFlattenable;
|
|
1267
|
-
function baseFlatten$2(array, depth, predicate, isStrict, result) {
|
|
791
|
+
function baseFlatten(array, depth, predicate, isStrict, result) {
|
|
1268
792
|
var index2 = -1, length = array.length;
|
|
1269
793
|
predicate || (predicate = isFlattenable);
|
|
1270
794
|
result || (result = []);
|
|
1271
795
|
while (++index2 < length) {
|
|
1272
796
|
var value = array[index2];
|
|
1273
|
-
if (
|
|
1274
|
-
|
|
1275
|
-
baseFlatten$2(value, depth - 1, predicate, isStrict, result);
|
|
1276
|
-
} else {
|
|
797
|
+
if (predicate(value)) {
|
|
798
|
+
{
|
|
1277
799
|
arrayPush(result, value);
|
|
1278
800
|
}
|
|
1279
|
-
} else
|
|
801
|
+
} else {
|
|
1280
802
|
result[result.length] = value;
|
|
1281
803
|
}
|
|
1282
804
|
}
|
|
1283
805
|
return result;
|
|
1284
806
|
}
|
|
1285
|
-
|
|
1286
|
-
var baseFlatten$1 = _baseFlatten;
|
|
1287
|
-
function flatten$1(array) {
|
|
807
|
+
function flatten(array) {
|
|
1288
808
|
var length = array == null ? 0 : array.length;
|
|
1289
|
-
return length ? baseFlatten
|
|
809
|
+
return length ? baseFlatten(array) : [];
|
|
1290
810
|
}
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
return func.call(thisArg, args[0], args[1]);
|
|
1300
|
-
case 3:
|
|
1301
|
-
return func.call(thisArg, args[0], args[1], args[2]);
|
|
811
|
+
function flatRest(func) {
|
|
812
|
+
return setToString(overRest(func, void 0, flatten), func + "");
|
|
813
|
+
}
|
|
814
|
+
var getPrototype = overArg(Object.getPrototypeOf, Object);
|
|
815
|
+
function arrayReduce(array, iteratee, accumulator, initAccum) {
|
|
816
|
+
var index2 = -1, length = array == null ? 0 : array.length;
|
|
817
|
+
if (initAccum && length) {
|
|
818
|
+
accumulator = array[++index2];
|
|
1302
819
|
}
|
|
1303
|
-
|
|
820
|
+
while (++index2 < length) {
|
|
821
|
+
accumulator = iteratee(accumulator, array[index2], index2, array);
|
|
822
|
+
}
|
|
823
|
+
return accumulator;
|
|
1304
824
|
}
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
825
|
+
function stackClear() {
|
|
826
|
+
this.__data__ = new ListCache();
|
|
827
|
+
this.size = 0;
|
|
828
|
+
}
|
|
829
|
+
function stackDelete(key) {
|
|
830
|
+
var data = this.__data__, result = data["delete"](key);
|
|
831
|
+
this.size = data.size;
|
|
832
|
+
return result;
|
|
833
|
+
}
|
|
834
|
+
function stackGet(key) {
|
|
835
|
+
return this.__data__.get(key);
|
|
836
|
+
}
|
|
837
|
+
function stackHas(key) {
|
|
838
|
+
return this.__data__.has(key);
|
|
839
|
+
}
|
|
840
|
+
var LARGE_ARRAY_SIZE = 200;
|
|
841
|
+
function stackSet(key, value) {
|
|
842
|
+
var data = this.__data__;
|
|
843
|
+
if (data instanceof ListCache) {
|
|
844
|
+
var pairs = data.__data__;
|
|
845
|
+
if (!Map || pairs.length < LARGE_ARRAY_SIZE - 1) {
|
|
846
|
+
pairs.push([key, value]);
|
|
847
|
+
this.size = ++data.size;
|
|
848
|
+
return this;
|
|
1319
849
|
}
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
850
|
+
data = this.__data__ = new MapCache(pairs);
|
|
851
|
+
}
|
|
852
|
+
data.set(key, value);
|
|
853
|
+
this.size = data.size;
|
|
854
|
+
return this;
|
|
1323
855
|
}
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
return value;
|
|
1328
|
-
};
|
|
856
|
+
function Stack(entries) {
|
|
857
|
+
var data = this.__data__ = new ListCache(entries);
|
|
858
|
+
this.size = data.size;
|
|
1329
859
|
}
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
860
|
+
Stack.prototype.clear = stackClear;
|
|
861
|
+
Stack.prototype["delete"] = stackDelete;
|
|
862
|
+
Stack.prototype.get = stackGet;
|
|
863
|
+
Stack.prototype.has = stackHas;
|
|
864
|
+
Stack.prototype.set = stackSet;
|
|
865
|
+
var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
|
|
866
|
+
var freeModule = freeExports && typeof module == "object" && module && !module.nodeType && module;
|
|
867
|
+
var moduleExports = freeModule && freeModule.exports === freeExports;
|
|
868
|
+
var Buffer = moduleExports ? root.Buffer : void 0;
|
|
869
|
+
Buffer ? Buffer.allocUnsafe : void 0;
|
|
870
|
+
function cloneBuffer(buffer, isDeep) {
|
|
871
|
+
{
|
|
872
|
+
return buffer.slice();
|
|
873
|
+
}
|
|
874
|
+
}
|
|
875
|
+
function arrayFilter(array, predicate) {
|
|
876
|
+
var index2 = -1, length = array == null ? 0 : array.length, resIndex = 0, result = [];
|
|
877
|
+
while (++index2 < length) {
|
|
878
|
+
var value = array[index2];
|
|
879
|
+
if (predicate(value, index2, array)) {
|
|
880
|
+
result[resIndex++] = value;
|
|
881
|
+
}
|
|
882
|
+
}
|
|
883
|
+
return result;
|
|
1333
884
|
}
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
885
|
+
function stubArray() {
|
|
886
|
+
return [];
|
|
887
|
+
}
|
|
888
|
+
var objectProto$4 = Object.prototype;
|
|
889
|
+
var propertyIsEnumerable = objectProto$4.propertyIsEnumerable;
|
|
890
|
+
var nativeGetSymbols = Object.getOwnPropertySymbols;
|
|
891
|
+
var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
|
|
892
|
+
if (object == null) {
|
|
893
|
+
return [];
|
|
894
|
+
}
|
|
895
|
+
object = Object(object);
|
|
896
|
+
return arrayFilter(nativeGetSymbols(object), function(symbol) {
|
|
897
|
+
return propertyIsEnumerable.call(object, symbol);
|
|
1342
898
|
});
|
|
1343
899
|
};
|
|
1344
|
-
|
|
1345
|
-
var
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
return
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
900
|
+
function baseGetAllKeys(object, keysFunc, symbolsFunc) {
|
|
901
|
+
var result = keysFunc(object);
|
|
902
|
+
return isArray(object) ? result : arrayPush(result, symbolsFunc(object));
|
|
903
|
+
}
|
|
904
|
+
function getAllKeys(object) {
|
|
905
|
+
return baseGetAllKeys(object, keys, getSymbols);
|
|
906
|
+
}
|
|
907
|
+
var DataView = getNative(root, "DataView");
|
|
908
|
+
var Promise$1 = getNative(root, "Promise");
|
|
909
|
+
var Set = getNative(root, "Set");
|
|
910
|
+
var mapTag$5 = "[object Map]", objectTag$2 = "[object Object]", promiseTag = "[object Promise]", setTag$5 = "[object Set]", weakMapTag$1 = "[object WeakMap]";
|
|
911
|
+
var dataViewTag$3 = "[object DataView]";
|
|
912
|
+
var dataViewCtorString = toSource(DataView), mapCtorString = toSource(Map), promiseCtorString = toSource(Promise$1), setCtorString = toSource(Set), weakMapCtorString = toSource(WeakMap);
|
|
913
|
+
var getTag = baseGetTag;
|
|
914
|
+
if (DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag$3 || Map && getTag(new Map()) != mapTag$5 || Promise$1 && getTag(Promise$1.resolve()) != promiseTag || Set && getTag(new Set()) != setTag$5 || WeakMap && getTag(new WeakMap()) != weakMapTag$1) {
|
|
915
|
+
getTag = function(value) {
|
|
916
|
+
var result = baseGetTag(value), Ctor = result == objectTag$2 ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
|
|
917
|
+
if (ctorString) {
|
|
918
|
+
switch (ctorString) {
|
|
919
|
+
case dataViewCtorString:
|
|
920
|
+
return dataViewTag$3;
|
|
921
|
+
case mapCtorString:
|
|
922
|
+
return mapTag$5;
|
|
923
|
+
case promiseCtorString:
|
|
924
|
+
return promiseTag;
|
|
925
|
+
case setCtorString:
|
|
926
|
+
return setTag$5;
|
|
927
|
+
case weakMapCtorString:
|
|
928
|
+
return weakMapTag$1;
|
|
1355
929
|
}
|
|
1356
|
-
} else {
|
|
1357
|
-
count = 0;
|
|
1358
930
|
}
|
|
1359
|
-
return
|
|
931
|
+
return result;
|
|
1360
932
|
};
|
|
1361
933
|
}
|
|
1362
|
-
var
|
|
1363
|
-
var
|
|
1364
|
-
|
|
1365
|
-
var
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
934
|
+
var objectProto$3 = Object.prototype;
|
|
935
|
+
var hasOwnProperty$3 = objectProto$3.hasOwnProperty;
|
|
936
|
+
function initCloneArray(array) {
|
|
937
|
+
var length = array.length, result = new array.constructor(length);
|
|
938
|
+
if (length && typeof array[0] == "string" && hasOwnProperty$3.call(array, "index")) {
|
|
939
|
+
result.index = array.index;
|
|
940
|
+
result.input = array.input;
|
|
941
|
+
}
|
|
942
|
+
return result;
|
|
943
|
+
}
|
|
944
|
+
var Uint8Array$1 = root.Uint8Array;
|
|
945
|
+
function cloneArrayBuffer(arrayBuffer) {
|
|
946
|
+
var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
|
|
947
|
+
new Uint8Array$1(result).set(new Uint8Array$1(arrayBuffer));
|
|
948
|
+
return result;
|
|
1369
949
|
}
|
|
1370
|
-
|
|
1371
|
-
var
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
950
|
+
function cloneDataView(dataView, isDeep) {
|
|
951
|
+
var buffer = cloneArrayBuffer(dataView.buffer);
|
|
952
|
+
return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);
|
|
953
|
+
}
|
|
954
|
+
var reFlags = /\w*$/;
|
|
955
|
+
function cloneRegExp(regexp) {
|
|
956
|
+
var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));
|
|
957
|
+
result.lastIndex = regexp.lastIndex;
|
|
958
|
+
return result;
|
|
959
|
+
}
|
|
960
|
+
var symbolProto$1 = Symbol$1 ? Symbol$1.prototype : void 0, symbolValueOf$1 = symbolProto$1 ? symbolProto$1.valueOf : void 0;
|
|
961
|
+
function cloneSymbol(symbol) {
|
|
962
|
+
return symbolValueOf$1 ? Object(symbolValueOf$1.call(symbol)) : {};
|
|
963
|
+
}
|
|
964
|
+
function cloneTypedArray(typedArray, isDeep) {
|
|
965
|
+
var buffer = cloneArrayBuffer(typedArray.buffer);
|
|
966
|
+
return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
|
|
967
|
+
}
|
|
968
|
+
var boolTag$2 = "[object Boolean]", dateTag$2 = "[object Date]", mapTag$4 = "[object Map]", numberTag$3 = "[object Number]", regexpTag$2 = "[object RegExp]", setTag$4 = "[object Set]", stringTag$2 = "[object String]", symbolTag$2 = "[object Symbol]";
|
|
969
|
+
var arrayBufferTag$2 = "[object ArrayBuffer]", dataViewTag$2 = "[object DataView]", float32Tag$1 = "[object Float32Array]", float64Tag$1 = "[object Float64Array]", int8Tag$1 = "[object Int8Array]", int16Tag$1 = "[object Int16Array]", int32Tag$1 = "[object Int32Array]", uint8Tag$1 = "[object Uint8Array]", uint8ClampedTag$1 = "[object Uint8ClampedArray]", uint16Tag$1 = "[object Uint16Array]", uint32Tag$1 = "[object Uint32Array]";
|
|
970
|
+
function initCloneByTag(object, tag, isDeep) {
|
|
971
|
+
var Ctor = object.constructor;
|
|
972
|
+
switch (tag) {
|
|
973
|
+
case arrayBufferTag$2:
|
|
974
|
+
return cloneArrayBuffer(object);
|
|
975
|
+
case boolTag$2:
|
|
976
|
+
case dateTag$2:
|
|
977
|
+
return new Ctor(+object);
|
|
978
|
+
case dataViewTag$2:
|
|
979
|
+
return cloneDataView(object);
|
|
980
|
+
case float32Tag$1:
|
|
981
|
+
case float64Tag$1:
|
|
982
|
+
case int8Tag$1:
|
|
983
|
+
case int16Tag$1:
|
|
984
|
+
case int32Tag$1:
|
|
985
|
+
case uint8Tag$1:
|
|
986
|
+
case uint8ClampedTag$1:
|
|
987
|
+
case uint16Tag$1:
|
|
988
|
+
case uint32Tag$1:
|
|
989
|
+
return cloneTypedArray(object);
|
|
990
|
+
case mapTag$4:
|
|
991
|
+
return new Ctor();
|
|
992
|
+
case numberTag$3:
|
|
993
|
+
case stringTag$2:
|
|
994
|
+
return new Ctor(object);
|
|
995
|
+
case regexpTag$2:
|
|
996
|
+
return cloneRegExp(object);
|
|
997
|
+
case setTag$4:
|
|
998
|
+
return new Ctor();
|
|
999
|
+
case symbolTag$2:
|
|
1000
|
+
return cloneSymbol(object);
|
|
1388
1001
|
}
|
|
1389
|
-
return -1;
|
|
1390
|
-
}
|
|
1391
|
-
var _baseFindIndex = baseFindIndex$1;
|
|
1392
|
-
function baseIsNaN$1(value) {
|
|
1393
|
-
return value !== value;
|
|
1394
1002
|
}
|
|
1395
|
-
|
|
1396
|
-
function
|
|
1397
|
-
var index2 = fromIndex - 1, length = array.length;
|
|
1398
|
-
while (++index2 < length) {
|
|
1399
|
-
if (array[index2] === value) {
|
|
1400
|
-
return index2;
|
|
1401
|
-
}
|
|
1402
|
-
}
|
|
1403
|
-
return -1;
|
|
1003
|
+
function initCloneObject(object) {
|
|
1004
|
+
return typeof object.constructor == "function" && !isPrototype(object) ? baseCreate(getPrototype(object)) : {};
|
|
1404
1005
|
}
|
|
1405
|
-
var
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
return value === value ? strictIndexOf(array, value, fromIndex) : baseFindIndex(array, baseIsNaN, fromIndex);
|
|
1006
|
+
var mapTag$3 = "[object Map]";
|
|
1007
|
+
function baseIsMap(value) {
|
|
1008
|
+
return isObjectLike(value) && getTag(value) == mapTag$3;
|
|
1409
1009
|
}
|
|
1410
|
-
var
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
return index2;
|
|
1416
|
-
}
|
|
1417
|
-
}
|
|
1418
|
-
return -1;
|
|
1010
|
+
var nodeIsMap = nodeUtil && nodeUtil.isMap;
|
|
1011
|
+
var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;
|
|
1012
|
+
var setTag$3 = "[object Set]";
|
|
1013
|
+
function baseIsSet(value) {
|
|
1014
|
+
return isObjectLike(value) && getTag(value) == setTag$3;
|
|
1419
1015
|
}
|
|
1420
|
-
var
|
|
1421
|
-
var
|
|
1422
|
-
var
|
|
1423
|
-
var
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1016
|
+
var nodeIsSet = nodeUtil && nodeUtil.isSet;
|
|
1017
|
+
var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
|
|
1018
|
+
var argsTag$1 = "[object Arguments]", arrayTag$1 = "[object Array]", boolTag$1 = "[object Boolean]", dateTag$1 = "[object Date]", errorTag$1 = "[object Error]", funcTag = "[object Function]", genTag = "[object GeneratorFunction]", mapTag$2 = "[object Map]", numberTag$2 = "[object Number]", objectTag$1 = "[object Object]", regexpTag$1 = "[object RegExp]", setTag$2 = "[object Set]", stringTag$1 = "[object String]", symbolTag$1 = "[object Symbol]", weakMapTag = "[object WeakMap]";
|
|
1019
|
+
var arrayBufferTag$1 = "[object ArrayBuffer]", dataViewTag$1 = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
|
|
1020
|
+
var cloneableTags = {};
|
|
1021
|
+
cloneableTags[argsTag$1] = cloneableTags[arrayTag$1] = cloneableTags[arrayBufferTag$1] = cloneableTags[dataViewTag$1] = cloneableTags[boolTag$1] = cloneableTags[dateTag$1] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag$2] = cloneableTags[numberTag$2] = cloneableTags[objectTag$1] = cloneableTags[regexpTag$1] = cloneableTags[setTag$2] = cloneableTags[stringTag$1] = cloneableTags[symbolTag$1] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
|
|
1022
|
+
cloneableTags[errorTag$1] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = false;
|
|
1023
|
+
function baseClone(value, bitmask, customizer, key, object, stack) {
|
|
1024
|
+
var result;
|
|
1025
|
+
if (result !== void 0) {
|
|
1026
|
+
return result;
|
|
1428
1027
|
}
|
|
1429
|
-
if (
|
|
1430
|
-
|
|
1028
|
+
if (!isObject(value)) {
|
|
1029
|
+
return value;
|
|
1431
1030
|
}
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1031
|
+
var isArr = isArray(value);
|
|
1032
|
+
if (isArr) {
|
|
1033
|
+
result = initCloneArray(value);
|
|
1034
|
+
} else {
|
|
1035
|
+
var tag = getTag(value), isFunc = tag == funcTag || tag == genTag;
|
|
1036
|
+
if (isBuffer(value)) {
|
|
1037
|
+
return cloneBuffer(value);
|
|
1038
|
+
}
|
|
1039
|
+
if (tag == objectTag$1 || tag == argsTag$1 || isFunc && !object) {
|
|
1040
|
+
result = isFunc ? {} : initCloneObject(value);
|
|
1041
|
+
} else {
|
|
1042
|
+
if (!cloneableTags[tag]) {
|
|
1043
|
+
return object ? value : {};
|
|
1437
1044
|
}
|
|
1438
|
-
|
|
1045
|
+
result = initCloneByTag(value, tag);
|
|
1439
1046
|
}
|
|
1440
1047
|
}
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
function pullAll$1(array, values) {
|
|
1446
|
-
return array && array.length && values && values.length ? basePullAll(array, values) : array;
|
|
1447
|
-
}
|
|
1448
|
-
var pullAll_1 = pullAll$1;
|
|
1449
|
-
var baseRest$1 = _baseRest, pullAll = pullAll_1;
|
|
1450
|
-
var pull = baseRest$1(pullAll);
|
|
1451
|
-
var pull_1 = pull;
|
|
1452
|
-
const pull$1 = /* @__PURE__ */ getDefaultExportFromCjs(pull_1);
|
|
1453
|
-
function arrayReduce$1(array, iteratee, accumulator, initAccum) {
|
|
1454
|
-
var index2 = -1, length = array == null ? 0 : array.length;
|
|
1455
|
-
if (initAccum && length) {
|
|
1456
|
-
accumulator = array[++index2];
|
|
1048
|
+
stack || (stack = new Stack());
|
|
1049
|
+
var stacked = stack.get(value);
|
|
1050
|
+
if (stacked) {
|
|
1051
|
+
return stacked;
|
|
1457
1052
|
}
|
|
1458
|
-
|
|
1459
|
-
|
|
1053
|
+
stack.set(value, result);
|
|
1054
|
+
if (isSet(value)) {
|
|
1055
|
+
value.forEach(function(subValue) {
|
|
1056
|
+
result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));
|
|
1057
|
+
});
|
|
1058
|
+
} else if (isMap(value)) {
|
|
1059
|
+
value.forEach(function(subValue, key2) {
|
|
1060
|
+
result.set(key2, baseClone(subValue, bitmask, customizer, key2, value, stack));
|
|
1061
|
+
});
|
|
1460
1062
|
}
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
while (length--) {
|
|
1468
|
-
var key = props[fromRight ? length : ++index2];
|
|
1469
|
-
if (iteratee(iterable[key], key, iterable) === false) {
|
|
1470
|
-
break;
|
|
1471
|
-
}
|
|
1063
|
+
var keysFunc = getAllKeys;
|
|
1064
|
+
var props = isArr ? void 0 : keysFunc(value);
|
|
1065
|
+
arrayEach(props || value, function(subValue, key2) {
|
|
1066
|
+
if (props) {
|
|
1067
|
+
key2 = subValue;
|
|
1068
|
+
subValue = value[key2];
|
|
1472
1069
|
}
|
|
1473
|
-
|
|
1474
|
-
};
|
|
1070
|
+
assignValue(result, key2, baseClone(subValue, bitmask, customizer, key2, value, stack));
|
|
1071
|
+
});
|
|
1072
|
+
return result;
|
|
1475
1073
|
}
|
|
1476
|
-
var
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
var _baseFor = baseFor$1;
|
|
1480
|
-
var baseFor = _baseFor, keys$1 = keys_1;
|
|
1481
|
-
function baseForOwn$1(object, iteratee) {
|
|
1482
|
-
return object && baseFor(object, iteratee, keys$1);
|
|
1483
|
-
}
|
|
1484
|
-
var _baseForOwn = baseForOwn$1;
|
|
1485
|
-
var isArrayLike$3 = isArrayLike_1;
|
|
1486
|
-
function createBaseEach$1(eachFunc, fromRight) {
|
|
1487
|
-
return function(collection, iteratee) {
|
|
1488
|
-
if (collection == null) {
|
|
1489
|
-
return collection;
|
|
1490
|
-
}
|
|
1491
|
-
if (!isArrayLike$3(collection)) {
|
|
1492
|
-
return eachFunc(collection, iteratee);
|
|
1493
|
-
}
|
|
1494
|
-
var length = collection.length, index2 = fromRight ? length : -1, iterable = Object(collection);
|
|
1495
|
-
while (fromRight ? index2-- : ++index2 < length) {
|
|
1496
|
-
if (iteratee(iterable[index2], index2, iterable) === false) {
|
|
1497
|
-
break;
|
|
1498
|
-
}
|
|
1499
|
-
}
|
|
1500
|
-
return collection;
|
|
1501
|
-
};
|
|
1074
|
+
var CLONE_DEEP_FLAG = 1, CLONE_SYMBOLS_FLAG = 4;
|
|
1075
|
+
function cloneDeep(value) {
|
|
1076
|
+
return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);
|
|
1502
1077
|
}
|
|
1503
|
-
var _createBaseEach = createBaseEach$1;
|
|
1504
|
-
var baseForOwn = _baseForOwn, createBaseEach = _createBaseEach;
|
|
1505
|
-
var baseEach$3 = createBaseEach(baseForOwn);
|
|
1506
|
-
var _baseEach = baseEach$3;
|
|
1507
1078
|
var HASH_UNDEFINED = "__lodash_hash_undefined__";
|
|
1508
|
-
function setCacheAdd
|
|
1079
|
+
function setCacheAdd(value) {
|
|
1509
1080
|
this.__data__.set(value, HASH_UNDEFINED);
|
|
1510
1081
|
return this;
|
|
1511
1082
|
}
|
|
1512
|
-
|
|
1513
|
-
function setCacheHas$1(value) {
|
|
1083
|
+
function setCacheHas(value) {
|
|
1514
1084
|
return this.__data__.has(value);
|
|
1515
1085
|
}
|
|
1516
|
-
|
|
1517
|
-
var MapCache = _MapCache, setCacheAdd = _setCacheAdd, setCacheHas = _setCacheHas;
|
|
1518
|
-
function SetCache$1(values) {
|
|
1086
|
+
function SetCache(values) {
|
|
1519
1087
|
var index2 = -1, length = values == null ? 0 : values.length;
|
|
1520
1088
|
this.__data__ = new MapCache();
|
|
1521
1089
|
while (++index2 < length) {
|
|
1522
1090
|
this.add(values[index2]);
|
|
1523
1091
|
}
|
|
1524
1092
|
}
|
|
1525
|
-
SetCache
|
|
1526
|
-
SetCache
|
|
1527
|
-
|
|
1528
|
-
function arraySome$1(array, predicate) {
|
|
1093
|
+
SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
|
|
1094
|
+
SetCache.prototype.has = setCacheHas;
|
|
1095
|
+
function arraySome(array, predicate) {
|
|
1529
1096
|
var index2 = -1, length = array == null ? 0 : array.length;
|
|
1530
1097
|
while (++index2 < length) {
|
|
1531
1098
|
if (predicate(array[index2], index2, array)) {
|
|
@@ -1534,14 +1101,11 @@ function arraySome$1(array, predicate) {
|
|
|
1534
1101
|
}
|
|
1535
1102
|
return false;
|
|
1536
1103
|
}
|
|
1537
|
-
|
|
1538
|
-
function cacheHas$1(cache, key) {
|
|
1104
|
+
function cacheHas(cache, key) {
|
|
1539
1105
|
return cache.has(key);
|
|
1540
1106
|
}
|
|
1541
|
-
var _cacheHas = cacheHas$1;
|
|
1542
|
-
var SetCache = _SetCache, arraySome = _arraySome, cacheHas = _cacheHas;
|
|
1543
1107
|
var COMPARE_PARTIAL_FLAG$5 = 1, COMPARE_UNORDERED_FLAG$3 = 2;
|
|
1544
|
-
function equalArrays
|
|
1108
|
+
function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {
|
|
1545
1109
|
var isPartial = bitmask & COMPARE_PARTIAL_FLAG$5, arrLength = array.length, othLength = other.length;
|
|
1546
1110
|
if (arrLength != othLength && !(isPartial && othLength > arrLength)) {
|
|
1547
1111
|
return false;
|
|
@@ -1584,29 +1148,25 @@ function equalArrays$2(array, other, bitmask, customizer, equalFunc, stack) {
|
|
|
1584
1148
|
stack["delete"](other);
|
|
1585
1149
|
return result;
|
|
1586
1150
|
}
|
|
1587
|
-
|
|
1588
|
-
function mapToArray$1(map) {
|
|
1151
|
+
function mapToArray(map) {
|
|
1589
1152
|
var index2 = -1, result = Array(map.size);
|
|
1590
1153
|
map.forEach(function(value, key) {
|
|
1591
1154
|
result[++index2] = [key, value];
|
|
1592
1155
|
});
|
|
1593
1156
|
return result;
|
|
1594
1157
|
}
|
|
1595
|
-
|
|
1596
|
-
function setToArray$1(set) {
|
|
1158
|
+
function setToArray(set) {
|
|
1597
1159
|
var index2 = -1, result = Array(set.size);
|
|
1598
1160
|
set.forEach(function(value) {
|
|
1599
1161
|
result[++index2] = value;
|
|
1600
1162
|
});
|
|
1601
1163
|
return result;
|
|
1602
1164
|
}
|
|
1603
|
-
var _setToArray = setToArray$1;
|
|
1604
|
-
var Symbol$1 = _Symbol, Uint8Array$1 = _Uint8Array, eq$1 = eq_1, equalArrays$1 = _equalArrays, mapToArray = _mapToArray, setToArray = _setToArray;
|
|
1605
1165
|
var COMPARE_PARTIAL_FLAG$4 = 1, COMPARE_UNORDERED_FLAG$2 = 2;
|
|
1606
|
-
var boolTag = "[object Boolean]", dateTag = "[object Date]", errorTag = "[object Error]", mapTag$1 = "[object Map]", numberTag = "[object Number]", regexpTag = "[object RegExp]", setTag$1 = "[object Set]", stringTag = "[object String]", symbolTag = "[object Symbol]";
|
|
1166
|
+
var boolTag = "[object Boolean]", dateTag = "[object Date]", errorTag = "[object Error]", mapTag$1 = "[object Map]", numberTag$1 = "[object Number]", regexpTag = "[object RegExp]", setTag$1 = "[object Set]", stringTag = "[object String]", symbolTag = "[object Symbol]";
|
|
1607
1167
|
var arrayBufferTag = "[object ArrayBuffer]", dataViewTag = "[object DataView]";
|
|
1608
1168
|
var symbolProto = Symbol$1 ? Symbol$1.prototype : void 0, symbolValueOf = symbolProto ? symbolProto.valueOf : void 0;
|
|
1609
|
-
function equalByTag
|
|
1169
|
+
function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {
|
|
1610
1170
|
switch (tag) {
|
|
1611
1171
|
case dataViewTag:
|
|
1612
1172
|
if (object.byteLength != other.byteLength || object.byteOffset != other.byteOffset) {
|
|
@@ -1621,8 +1181,8 @@ function equalByTag$1(object, other, tag, bitmask, customizer, equalFunc, stack)
|
|
|
1621
1181
|
return true;
|
|
1622
1182
|
case boolTag:
|
|
1623
1183
|
case dateTag:
|
|
1624
|
-
case numberTag:
|
|
1625
|
-
return eq
|
|
1184
|
+
case numberTag$1:
|
|
1185
|
+
return eq(+object, +other);
|
|
1626
1186
|
case errorTag:
|
|
1627
1187
|
return object.name == other.name && object.message == other.message;
|
|
1628
1188
|
case regexpTag:
|
|
@@ -1642,7 +1202,7 @@ function equalByTag$1(object, other, tag, bitmask, customizer, equalFunc, stack)
|
|
|
1642
1202
|
}
|
|
1643
1203
|
bitmask |= COMPARE_UNORDERED_FLAG$2;
|
|
1644
1204
|
stack.set(object, other);
|
|
1645
|
-
var result = equalArrays
|
|
1205
|
+
var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);
|
|
1646
1206
|
stack["delete"](object);
|
|
1647
1207
|
return result;
|
|
1648
1208
|
case symbolTag:
|
|
@@ -1652,12 +1212,10 @@ function equalByTag$1(object, other, tag, bitmask, customizer, equalFunc, stack)
|
|
|
1652
1212
|
}
|
|
1653
1213
|
return false;
|
|
1654
1214
|
}
|
|
1655
|
-
var _equalByTag = equalByTag$1;
|
|
1656
|
-
var getAllKeys = _getAllKeys;
|
|
1657
1215
|
var COMPARE_PARTIAL_FLAG$3 = 1;
|
|
1658
1216
|
var objectProto$2 = Object.prototype;
|
|
1659
1217
|
var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
|
|
1660
|
-
function equalObjects
|
|
1218
|
+
function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {
|
|
1661
1219
|
var isPartial = bitmask & COMPARE_PARTIAL_FLAG$3, objProps = getAllKeys(object), objLength = objProps.length, othProps = getAllKeys(other), othLength = othProps.length;
|
|
1662
1220
|
if (objLength != othLength && !isPartial) {
|
|
1663
1221
|
return false;
|
|
@@ -1700,189 +1258,392 @@ function equalObjects$1(object, other, bitmask, customizer, equalFunc, stack) {
|
|
|
1700
1258
|
stack["delete"](other);
|
|
1701
1259
|
return result;
|
|
1702
1260
|
}
|
|
1703
|
-
var _equalObjects = equalObjects$1;
|
|
1704
|
-
var Stack$1 = _Stack, equalArrays = _equalArrays, equalByTag = _equalByTag, equalObjects = _equalObjects, getTag$1 = _getTag, isArray$5 = isArray_1, isBuffer$1 = isBufferExports, isTypedArray$1 = isTypedArray_1;
|
|
1705
1261
|
var COMPARE_PARTIAL_FLAG$2 = 1;
|
|
1706
1262
|
var argsTag = "[object Arguments]", arrayTag = "[object Array]", objectTag = "[object Object]";
|
|
1707
1263
|
var objectProto$1 = Object.prototype;
|
|
1708
1264
|
var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
|
|
1709
|
-
function baseIsEqualDeep
|
|
1710
|
-
var objIsArr = isArray
|
|
1265
|
+
function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {
|
|
1266
|
+
var objIsArr = isArray(object), othIsArr = isArray(other), objTag = objIsArr ? arrayTag : getTag(object), othTag = othIsArr ? arrayTag : getTag(other);
|
|
1711
1267
|
objTag = objTag == argsTag ? objectTag : objTag;
|
|
1712
1268
|
othTag = othTag == argsTag ? objectTag : othTag;
|
|
1713
1269
|
var objIsObj = objTag == objectTag, othIsObj = othTag == objectTag, isSameTag = objTag == othTag;
|
|
1714
|
-
if (isSameTag && isBuffer
|
|
1715
|
-
if (!isBuffer
|
|
1270
|
+
if (isSameTag && isBuffer(object)) {
|
|
1271
|
+
if (!isBuffer(other)) {
|
|
1716
1272
|
return false;
|
|
1717
1273
|
}
|
|
1718
1274
|
objIsArr = true;
|
|
1719
1275
|
objIsObj = false;
|
|
1720
1276
|
}
|
|
1721
1277
|
if (isSameTag && !objIsObj) {
|
|
1722
|
-
stack || (stack = new Stack
|
|
1723
|
-
return objIsArr || isTypedArray
|
|
1278
|
+
stack || (stack = new Stack());
|
|
1279
|
+
return objIsArr || isTypedArray(object) ? equalArrays(object, other, bitmask, customizer, equalFunc, stack) : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);
|
|
1724
1280
|
}
|
|
1725
1281
|
if (!(bitmask & COMPARE_PARTIAL_FLAG$2)) {
|
|
1726
1282
|
var objIsWrapped = objIsObj && hasOwnProperty$1.call(object, "__wrapped__"), othIsWrapped = othIsObj && hasOwnProperty$1.call(other, "__wrapped__");
|
|
1727
1283
|
if (objIsWrapped || othIsWrapped) {
|
|
1728
1284
|
var objUnwrapped = objIsWrapped ? object.value() : object, othUnwrapped = othIsWrapped ? other.value() : other;
|
|
1729
|
-
stack || (stack = new Stack
|
|
1285
|
+
stack || (stack = new Stack());
|
|
1730
1286
|
return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);
|
|
1731
1287
|
}
|
|
1732
1288
|
}
|
|
1733
1289
|
if (!isSameTag) {
|
|
1734
1290
|
return false;
|
|
1735
1291
|
}
|
|
1736
|
-
stack || (stack = new Stack
|
|
1292
|
+
stack || (stack = new Stack());
|
|
1737
1293
|
return equalObjects(object, other, bitmask, customizer, equalFunc, stack);
|
|
1738
1294
|
}
|
|
1739
|
-
|
|
1740
|
-
var baseIsEqualDeep = _baseIsEqualDeep, isObjectLike = isObjectLike_1;
|
|
1741
|
-
function baseIsEqual$2(value, other, bitmask, customizer, stack) {
|
|
1295
|
+
function baseIsEqual(value, other, bitmask, customizer, stack) {
|
|
1742
1296
|
if (value === other) {
|
|
1743
1297
|
return true;
|
|
1744
1298
|
}
|
|
1745
1299
|
if (value == null || other == null || !isObjectLike(value) && !isObjectLike(other)) {
|
|
1746
1300
|
return value !== value && other !== other;
|
|
1747
1301
|
}
|
|
1748
|
-
return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual
|
|
1302
|
+
return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);
|
|
1749
1303
|
}
|
|
1750
|
-
var _baseIsEqual = baseIsEqual$2;
|
|
1751
|
-
var Stack = _Stack, baseIsEqual$1 = _baseIsEqual;
|
|
1752
1304
|
var COMPARE_PARTIAL_FLAG$1 = 1, COMPARE_UNORDERED_FLAG$1 = 2;
|
|
1753
|
-
function baseIsMatch
|
|
1754
|
-
var index2 = matchData.length, length = index2
|
|
1305
|
+
function baseIsMatch(object, source, matchData, customizer) {
|
|
1306
|
+
var index2 = matchData.length, length = index2;
|
|
1755
1307
|
if (object == null) {
|
|
1756
1308
|
return !length;
|
|
1757
1309
|
}
|
|
1758
1310
|
object = Object(object);
|
|
1759
1311
|
while (index2--) {
|
|
1760
1312
|
var data = matchData[index2];
|
|
1761
|
-
if (
|
|
1313
|
+
if (data[2] ? data[1] !== object[data[0]] : !(data[0] in object)) {
|
|
1762
1314
|
return false;
|
|
1763
1315
|
}
|
|
1764
1316
|
}
|
|
1765
1317
|
while (++index2 < length) {
|
|
1766
1318
|
data = matchData[index2];
|
|
1767
1319
|
var key = data[0], objValue = object[key], srcValue = data[1];
|
|
1768
|
-
if (
|
|
1320
|
+
if (data[2]) {
|
|
1769
1321
|
if (objValue === void 0 && !(key in object)) {
|
|
1770
1322
|
return false;
|
|
1771
1323
|
}
|
|
1772
1324
|
} else {
|
|
1773
1325
|
var stack = new Stack();
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
}
|
|
1777
|
-
if (!(result === void 0 ? baseIsEqual$1(srcValue, objValue, COMPARE_PARTIAL_FLAG$1 | COMPARE_UNORDERED_FLAG$1, customizer, stack) : result)) {
|
|
1326
|
+
var result;
|
|
1327
|
+
if (!(result === void 0 ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG$1 | COMPARE_UNORDERED_FLAG$1, customizer, stack) : result)) {
|
|
1778
1328
|
return false;
|
|
1779
1329
|
}
|
|
1780
1330
|
}
|
|
1781
1331
|
}
|
|
1782
|
-
return true;
|
|
1783
|
-
}
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1332
|
+
return true;
|
|
1333
|
+
}
|
|
1334
|
+
function isStrictComparable(value) {
|
|
1335
|
+
return value === value && !isObject(value);
|
|
1336
|
+
}
|
|
1337
|
+
function getMatchData(object) {
|
|
1338
|
+
var result = keys(object), length = result.length;
|
|
1339
|
+
while (length--) {
|
|
1340
|
+
var key = result[length], value = object[key];
|
|
1341
|
+
result[length] = [key, value, isStrictComparable(value)];
|
|
1342
|
+
}
|
|
1343
|
+
return result;
|
|
1344
|
+
}
|
|
1345
|
+
function matchesStrictComparable(key, srcValue) {
|
|
1346
|
+
return function(object) {
|
|
1347
|
+
if (object == null) {
|
|
1348
|
+
return false;
|
|
1349
|
+
}
|
|
1350
|
+
return object[key] === srcValue && (srcValue !== void 0 || key in Object(object));
|
|
1351
|
+
};
|
|
1352
|
+
}
|
|
1353
|
+
function baseMatches(source) {
|
|
1354
|
+
var matchData = getMatchData(source);
|
|
1355
|
+
if (matchData.length == 1 && matchData[0][2]) {
|
|
1356
|
+
return matchesStrictComparable(matchData[0][0], matchData[0][1]);
|
|
1357
|
+
}
|
|
1358
|
+
return function(object) {
|
|
1359
|
+
return object === source || baseIsMatch(object, source, matchData);
|
|
1360
|
+
};
|
|
1361
|
+
}
|
|
1362
|
+
function baseHasIn(object, key) {
|
|
1363
|
+
return object != null && key in Object(object);
|
|
1364
|
+
}
|
|
1365
|
+
function hasPath(object, path, hasFunc) {
|
|
1366
|
+
path = castPath(path, object);
|
|
1367
|
+
var index2 = -1, length = path.length, result = false;
|
|
1368
|
+
while (++index2 < length) {
|
|
1369
|
+
var key = toKey(path[index2]);
|
|
1370
|
+
if (!(result = object != null && hasFunc(object, key))) {
|
|
1371
|
+
break;
|
|
1372
|
+
}
|
|
1373
|
+
object = object[key];
|
|
1374
|
+
}
|
|
1375
|
+
if (result || ++index2 != length) {
|
|
1376
|
+
return result;
|
|
1377
|
+
}
|
|
1378
|
+
length = object == null ? 0 : object.length;
|
|
1379
|
+
return !!length && isLength(length) && isIndex(key, length) && (isArray(object) || isArguments(object));
|
|
1380
|
+
}
|
|
1381
|
+
function hasIn(object, path) {
|
|
1382
|
+
return object != null && hasPath(object, path, baseHasIn);
|
|
1383
|
+
}
|
|
1384
|
+
var COMPARE_PARTIAL_FLAG = 1, COMPARE_UNORDERED_FLAG = 2;
|
|
1385
|
+
function baseMatchesProperty(path, srcValue) {
|
|
1386
|
+
if (isKey(path) && isStrictComparable(srcValue)) {
|
|
1387
|
+
return matchesStrictComparable(toKey(path), srcValue);
|
|
1388
|
+
}
|
|
1389
|
+
return function(object) {
|
|
1390
|
+
var objValue = get(object, path);
|
|
1391
|
+
return objValue === void 0 && objValue === srcValue ? hasIn(object, path) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
|
|
1392
|
+
};
|
|
1393
|
+
}
|
|
1394
|
+
function baseProperty(key) {
|
|
1395
|
+
return function(object) {
|
|
1396
|
+
return object == null ? void 0 : object[key];
|
|
1397
|
+
};
|
|
1398
|
+
}
|
|
1399
|
+
function basePropertyDeep(path) {
|
|
1400
|
+
return function(object) {
|
|
1401
|
+
return baseGet(object, path);
|
|
1402
|
+
};
|
|
1403
|
+
}
|
|
1404
|
+
function property(path) {
|
|
1405
|
+
return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);
|
|
1406
|
+
}
|
|
1407
|
+
function baseIteratee(value) {
|
|
1408
|
+
if (typeof value == "function") {
|
|
1409
|
+
return value;
|
|
1410
|
+
}
|
|
1411
|
+
if (value == null) {
|
|
1412
|
+
return identity;
|
|
1413
|
+
}
|
|
1414
|
+
if (typeof value == "object") {
|
|
1415
|
+
return isArray(value) ? baseMatchesProperty(value[0], value[1]) : baseMatches(value);
|
|
1416
|
+
}
|
|
1417
|
+
return property(value);
|
|
1418
|
+
}
|
|
1419
|
+
function createBaseFor(fromRight) {
|
|
1420
|
+
return function(object, iteratee, keysFunc) {
|
|
1421
|
+
var index2 = -1, iterable = Object(object), props = keysFunc(object), length = props.length;
|
|
1422
|
+
while (length--) {
|
|
1423
|
+
var key = props[++index2];
|
|
1424
|
+
if (iteratee(iterable[key], key, iterable) === false) {
|
|
1425
|
+
break;
|
|
1426
|
+
}
|
|
1427
|
+
}
|
|
1428
|
+
return object;
|
|
1429
|
+
};
|
|
1430
|
+
}
|
|
1431
|
+
var baseFor = createBaseFor();
|
|
1432
|
+
function baseForOwn(object, iteratee) {
|
|
1433
|
+
return object && baseFor(object, iteratee, keys);
|
|
1434
|
+
}
|
|
1435
|
+
function createBaseEach(eachFunc, fromRight) {
|
|
1436
|
+
return function(collection, iteratee) {
|
|
1437
|
+
if (collection == null) {
|
|
1438
|
+
return collection;
|
|
1439
|
+
}
|
|
1440
|
+
if (!isArrayLike(collection)) {
|
|
1441
|
+
return eachFunc(collection, iteratee);
|
|
1442
|
+
}
|
|
1443
|
+
var length = collection.length, index2 = -1, iterable = Object(collection);
|
|
1444
|
+
while (++index2 < length) {
|
|
1445
|
+
if (iteratee(iterable[index2], index2, iterable) === false) {
|
|
1446
|
+
break;
|
|
1447
|
+
}
|
|
1448
|
+
}
|
|
1449
|
+
return collection;
|
|
1450
|
+
};
|
|
1451
|
+
}
|
|
1452
|
+
var baseEach = createBaseEach(baseForOwn);
|
|
1453
|
+
function castFunction(value) {
|
|
1454
|
+
return typeof value == "function" ? value : identity;
|
|
1455
|
+
}
|
|
1456
|
+
function forEach(collection, iteratee) {
|
|
1457
|
+
var func = isArray(collection) ? arrayEach : baseEach;
|
|
1458
|
+
return func(collection, castFunction(iteratee));
|
|
1459
|
+
}
|
|
1460
|
+
function baseMap(collection, iteratee) {
|
|
1461
|
+
var index2 = -1, result = isArrayLike(collection) ? Array(collection.length) : [];
|
|
1462
|
+
baseEach(collection, function(value, key, collection2) {
|
|
1463
|
+
result[++index2] = iteratee(value, key, collection2);
|
|
1464
|
+
});
|
|
1465
|
+
return result;
|
|
1466
|
+
}
|
|
1467
|
+
var mapTag = "[object Map]", setTag = "[object Set]";
|
|
1468
|
+
var objectProto = Object.prototype;
|
|
1469
|
+
var hasOwnProperty = objectProto.hasOwnProperty;
|
|
1470
|
+
function isEmpty(value) {
|
|
1471
|
+
if (value == null) {
|
|
1472
|
+
return true;
|
|
1473
|
+
}
|
|
1474
|
+
if (isArrayLike(value) && (isArray(value) || typeof value == "string" || typeof value.splice == "function" || isBuffer(value) || isTypedArray(value) || isArguments(value))) {
|
|
1475
|
+
return !value.length;
|
|
1476
|
+
}
|
|
1477
|
+
var tag = getTag(value);
|
|
1478
|
+
if (tag == mapTag || tag == setTag) {
|
|
1479
|
+
return !value.size;
|
|
1480
|
+
}
|
|
1481
|
+
if (isPrototype(value)) {
|
|
1482
|
+
return !baseKeys(value).length;
|
|
1483
|
+
}
|
|
1484
|
+
for (var key in value) {
|
|
1485
|
+
if (hasOwnProperty.call(value, key)) {
|
|
1486
|
+
return false;
|
|
1487
|
+
}
|
|
1488
|
+
}
|
|
1489
|
+
return true;
|
|
1490
|
+
}
|
|
1491
|
+
var numberTag = "[object Number]";
|
|
1492
|
+
function isNumber(value) {
|
|
1493
|
+
return typeof value == "number" || isObjectLike(value) && baseGetTag(value) == numberTag;
|
|
1494
|
+
}
|
|
1495
|
+
function baseSet(object, path, value, customizer) {
|
|
1496
|
+
if (!isObject(object)) {
|
|
1497
|
+
return object;
|
|
1498
|
+
}
|
|
1499
|
+
path = castPath(path, object);
|
|
1500
|
+
var index2 = -1, length = path.length, lastIndex = length - 1, nested = object;
|
|
1501
|
+
while (nested != null && ++index2 < length) {
|
|
1502
|
+
var key = toKey(path[index2]), newValue = value;
|
|
1503
|
+
if (key === "__proto__" || key === "constructor" || key === "prototype") {
|
|
1504
|
+
return object;
|
|
1505
|
+
}
|
|
1506
|
+
if (index2 != lastIndex) {
|
|
1507
|
+
var objValue = nested[key];
|
|
1508
|
+
newValue = void 0;
|
|
1509
|
+
if (newValue === void 0) {
|
|
1510
|
+
newValue = isObject(objValue) ? objValue : isIndex(path[index2 + 1]) ? [] : {};
|
|
1511
|
+
}
|
|
1512
|
+
}
|
|
1513
|
+
assignValue(nested, key, newValue);
|
|
1514
|
+
nested = nested[key];
|
|
1515
|
+
}
|
|
1516
|
+
return object;
|
|
1517
|
+
}
|
|
1518
|
+
function basePickBy(object, paths, predicate) {
|
|
1519
|
+
var index2 = -1, length = paths.length, result = {};
|
|
1520
|
+
while (++index2 < length) {
|
|
1521
|
+
var path = paths[index2], value = baseGet(object, path);
|
|
1522
|
+
if (predicate(value, path)) {
|
|
1523
|
+
baseSet(result, castPath(path, object), value);
|
|
1524
|
+
}
|
|
1525
|
+
}
|
|
1526
|
+
return result;
|
|
1788
1527
|
}
|
|
1789
|
-
|
|
1790
|
-
var
|
|
1791
|
-
|
|
1792
|
-
var result = keys(object), length = result.length;
|
|
1528
|
+
function baseSortBy(array, comparer) {
|
|
1529
|
+
var length = array.length;
|
|
1530
|
+
array.sort(comparer);
|
|
1793
1531
|
while (length--) {
|
|
1794
|
-
|
|
1795
|
-
result[length] = [key, value, isStrictComparable$1(value)];
|
|
1532
|
+
array[length] = array[length].value;
|
|
1796
1533
|
}
|
|
1797
|
-
return
|
|
1534
|
+
return array;
|
|
1798
1535
|
}
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1536
|
+
function compareAscending(value, other) {
|
|
1537
|
+
if (value !== other) {
|
|
1538
|
+
var valIsDefined = value !== void 0, valIsNull = value === null, valIsReflexive = value === value, valIsSymbol = isSymbol(value);
|
|
1539
|
+
var othIsDefined = other !== void 0, othIsNull = other === null, othIsReflexive = other === other, othIsSymbol = isSymbol(other);
|
|
1540
|
+
if (!othIsNull && !othIsSymbol && !valIsSymbol && value > other || valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol || valIsNull && othIsDefined && othIsReflexive || !valIsDefined && othIsReflexive || !valIsReflexive) {
|
|
1541
|
+
return 1;
|
|
1542
|
+
}
|
|
1543
|
+
if (!valIsNull && !valIsSymbol && !othIsSymbol && value < other || othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol || othIsNull && valIsDefined && valIsReflexive || !othIsDefined && valIsReflexive || !othIsReflexive) {
|
|
1544
|
+
return -1;
|
|
1804
1545
|
}
|
|
1805
|
-
return object[key] === srcValue && (srcValue !== void 0 || key in Object(object));
|
|
1806
|
-
};
|
|
1807
|
-
}
|
|
1808
|
-
var _matchesStrictComparable = matchesStrictComparable$2;
|
|
1809
|
-
var baseIsMatch = _baseIsMatch, getMatchData = _getMatchData, matchesStrictComparable$1 = _matchesStrictComparable;
|
|
1810
|
-
function baseMatches$1(source) {
|
|
1811
|
-
var matchData = getMatchData(source);
|
|
1812
|
-
if (matchData.length == 1 && matchData[0][2]) {
|
|
1813
|
-
return matchesStrictComparable$1(matchData[0][0], matchData[0][1]);
|
|
1814
1546
|
}
|
|
1815
|
-
return
|
|
1816
|
-
return object === source || baseIsMatch(object, source, matchData);
|
|
1817
|
-
};
|
|
1818
|
-
}
|
|
1819
|
-
var _baseMatches = baseMatches$1;
|
|
1820
|
-
var baseGet$2 = _baseGet;
|
|
1821
|
-
function get$1(object, path, defaultValue) {
|
|
1822
|
-
var result = object == null ? void 0 : baseGet$2(object, path);
|
|
1823
|
-
return result === void 0 ? defaultValue : result;
|
|
1547
|
+
return 0;
|
|
1824
1548
|
}
|
|
1825
|
-
|
|
1826
|
-
var
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1549
|
+
function compareMultiple(object, other, orders) {
|
|
1550
|
+
var index2 = -1, objCriteria = object.criteria, othCriteria = other.criteria, length = objCriteria.length, ordersLength = orders.length;
|
|
1551
|
+
while (++index2 < length) {
|
|
1552
|
+
var result = compareAscending(objCriteria[index2], othCriteria[index2]);
|
|
1553
|
+
if (result) {
|
|
1554
|
+
if (index2 >= ordersLength) {
|
|
1555
|
+
return result;
|
|
1556
|
+
}
|
|
1557
|
+
var order = orders[index2];
|
|
1558
|
+
return result * (order == "desc" ? -1 : 1);
|
|
1559
|
+
}
|
|
1831
1560
|
}
|
|
1832
|
-
return
|
|
1833
|
-
var objValue = get(object, path);
|
|
1834
|
-
return objValue === void 0 && objValue === srcValue ? hasIn(object, path) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
|
|
1835
|
-
};
|
|
1836
|
-
}
|
|
1837
|
-
var _baseMatchesProperty = baseMatchesProperty$1;
|
|
1838
|
-
function baseProperty$1(key) {
|
|
1839
|
-
return function(object) {
|
|
1840
|
-
return object == null ? void 0 : object[key];
|
|
1841
|
-
};
|
|
1561
|
+
return object.index - other.index;
|
|
1842
1562
|
}
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1563
|
+
function baseOrderBy(collection, iteratees, orders) {
|
|
1564
|
+
if (iteratees.length) {
|
|
1565
|
+
iteratees = arrayMap(iteratees, function(iteratee) {
|
|
1566
|
+
if (isArray(iteratee)) {
|
|
1567
|
+
return function(value) {
|
|
1568
|
+
return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee);
|
|
1569
|
+
};
|
|
1570
|
+
}
|
|
1571
|
+
return iteratee;
|
|
1572
|
+
});
|
|
1573
|
+
} else {
|
|
1574
|
+
iteratees = [identity];
|
|
1575
|
+
}
|
|
1576
|
+
var index2 = -1;
|
|
1577
|
+
iteratees = arrayMap(iteratees, baseUnary(baseIteratee));
|
|
1578
|
+
var result = baseMap(collection, function(value, key, collection2) {
|
|
1579
|
+
var criteria = arrayMap(iteratees, function(iteratee) {
|
|
1580
|
+
return iteratee(value);
|
|
1581
|
+
});
|
|
1582
|
+
return { "criteria": criteria, "index": ++index2, "value": value };
|
|
1583
|
+
});
|
|
1584
|
+
return baseSortBy(result, function(object, other) {
|
|
1585
|
+
return compareMultiple(object, other, orders);
|
|
1586
|
+
});
|
|
1849
1587
|
}
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1588
|
+
function basePick(object, paths) {
|
|
1589
|
+
return basePickBy(object, paths, function(value, path) {
|
|
1590
|
+
return hasIn(object, path);
|
|
1591
|
+
});
|
|
1854
1592
|
}
|
|
1855
|
-
var
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1593
|
+
var pick = flatRest(function(object, paths) {
|
|
1594
|
+
return object == null ? {} : basePick(object, paths);
|
|
1595
|
+
});
|
|
1596
|
+
var arrayProto = Array.prototype;
|
|
1597
|
+
var splice = arrayProto.splice;
|
|
1598
|
+
function basePullAll(array, values, iteratee, comparator) {
|
|
1599
|
+
var indexOf = baseIndexOf, index2 = -1, length = values.length, seen = array;
|
|
1600
|
+
if (array === values) {
|
|
1601
|
+
values = copyArray(values);
|
|
1863
1602
|
}
|
|
1864
|
-
|
|
1865
|
-
|
|
1603
|
+
while (++index2 < length) {
|
|
1604
|
+
var fromIndex = 0, value = values[index2], computed2 = value;
|
|
1605
|
+
while ((fromIndex = indexOf(seen, computed2, fromIndex)) > -1) {
|
|
1606
|
+
if (seen !== array) {
|
|
1607
|
+
splice.call(seen, fromIndex, 1);
|
|
1608
|
+
}
|
|
1609
|
+
splice.call(array, fromIndex, 1);
|
|
1610
|
+
}
|
|
1866
1611
|
}
|
|
1867
|
-
return
|
|
1612
|
+
return array;
|
|
1613
|
+
}
|
|
1614
|
+
function pullAll(array, values) {
|
|
1615
|
+
return array && array.length && values && values.length ? basePullAll(array, values) : array;
|
|
1868
1616
|
}
|
|
1869
|
-
var
|
|
1870
|
-
function baseReduce
|
|
1617
|
+
var pull = baseRest(pullAll);
|
|
1618
|
+
function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) {
|
|
1871
1619
|
eachFunc(collection, function(value, index2, collection2) {
|
|
1872
1620
|
accumulator = initAccum ? (initAccum = false, value) : iteratee(accumulator, value, index2, collection2);
|
|
1873
1621
|
});
|
|
1874
1622
|
return accumulator;
|
|
1875
1623
|
}
|
|
1876
|
-
var _baseReduce = baseReduce$1;
|
|
1877
|
-
var arrayReduce = _arrayReduce, baseEach$2 = _baseEach, baseIteratee$1 = _baseIteratee, baseReduce = _baseReduce, isArray$3 = isArray_1;
|
|
1878
1624
|
function reduce(collection, iteratee, accumulator) {
|
|
1879
|
-
var func = isArray
|
|
1880
|
-
return func(collection, baseIteratee
|
|
1625
|
+
var func = isArray(collection) ? arrayReduce : baseReduce, initAccum = arguments.length < 3;
|
|
1626
|
+
return func(collection, baseIteratee(iteratee), accumulator, initAccum, baseEach);
|
|
1627
|
+
}
|
|
1628
|
+
var sortBy = baseRest(function(collection, iteratees) {
|
|
1629
|
+
if (collection == null) {
|
|
1630
|
+
return [];
|
|
1631
|
+
}
|
|
1632
|
+
var length = iteratees.length;
|
|
1633
|
+
if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {
|
|
1634
|
+
iteratees = [];
|
|
1635
|
+
} else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {
|
|
1636
|
+
iteratees = [iteratees[0]];
|
|
1637
|
+
}
|
|
1638
|
+
return baseOrderBy(collection, baseFlatten(iteratees), []);
|
|
1639
|
+
});
|
|
1640
|
+
var idCounter = 0;
|
|
1641
|
+
function uniqueId(prefix) {
|
|
1642
|
+
var id = ++idCounter;
|
|
1643
|
+
return toString(prefix) + id;
|
|
1881
1644
|
}
|
|
1882
|
-
var reduce_1 = reduce;
|
|
1883
|
-
const reduce$1 = /* @__PURE__ */ getDefaultExportFromCjs(reduce_1);
|
|
1884
1645
|
/**!
|
|
1885
|
-
* Sortable 1.15.
|
|
1646
|
+
* Sortable 1.15.6
|
|
1886
1647
|
* @author RubaXa <trash@rubaxa.org>
|
|
1887
1648
|
* @author owenm <owen23355@gmail.com>
|
|
1888
1649
|
* @license MIT
|
|
@@ -1958,38 +1719,33 @@ function _extends() {
|
|
|
1958
1719
|
return _extends.apply(this, arguments);
|
|
1959
1720
|
}
|
|
1960
1721
|
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
1961
|
-
if (source == null)
|
|
1962
|
-
return {};
|
|
1722
|
+
if (source == null) return {};
|
|
1963
1723
|
var target = {};
|
|
1964
1724
|
var sourceKeys = Object.keys(source);
|
|
1965
1725
|
var key, i;
|
|
1966
1726
|
for (i = 0; i < sourceKeys.length; i++) {
|
|
1967
1727
|
key = sourceKeys[i];
|
|
1968
|
-
if (excluded.indexOf(key) >= 0)
|
|
1969
|
-
continue;
|
|
1728
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
1970
1729
|
target[key] = source[key];
|
|
1971
1730
|
}
|
|
1972
1731
|
return target;
|
|
1973
1732
|
}
|
|
1974
1733
|
function _objectWithoutProperties(source, excluded) {
|
|
1975
|
-
if (source == null)
|
|
1976
|
-
return {};
|
|
1734
|
+
if (source == null) return {};
|
|
1977
1735
|
var target = _objectWithoutPropertiesLoose(source, excluded);
|
|
1978
1736
|
var key, i;
|
|
1979
1737
|
if (Object.getOwnPropertySymbols) {
|
|
1980
1738
|
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
|
1981
1739
|
for (i = 0; i < sourceSymbolKeys.length; i++) {
|
|
1982
1740
|
key = sourceSymbolKeys[i];
|
|
1983
|
-
if (excluded.indexOf(key) >= 0)
|
|
1984
|
-
|
|
1985
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key))
|
|
1986
|
-
continue;
|
|
1741
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
1742
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
1987
1743
|
target[key] = source[key];
|
|
1988
1744
|
}
|
|
1989
1745
|
}
|
|
1990
1746
|
return target;
|
|
1991
1747
|
}
|
|
1992
|
-
var version = "1.15.
|
|
1748
|
+
var version = "1.15.6";
|
|
1993
1749
|
function userAgent(pattern) {
|
|
1994
1750
|
if (typeof window !== "undefined" && window.navigator) {
|
|
1995
1751
|
return !!/* @__PURE__ */ navigator.userAgent.match(pattern);
|
|
@@ -2012,8 +1768,7 @@ function off(el, event, fn) {
|
|
|
2012
1768
|
el.removeEventListener(event, fn, !IE11OrLess && captureMode);
|
|
2013
1769
|
}
|
|
2014
1770
|
function matches(el, selector) {
|
|
2015
|
-
if (!selector)
|
|
2016
|
-
return;
|
|
1771
|
+
if (!selector) return;
|
|
2017
1772
|
selector[0] === ">" && (selector = selector.substring(1));
|
|
2018
1773
|
if (el) {
|
|
2019
1774
|
try {
|
|
@@ -2040,8 +1795,7 @@ function closest(el, selector, ctx, includeCTX) {
|
|
|
2040
1795
|
if (selector != null && (selector[0] === ">" ? el.parentNode === ctx && matches(el, selector) : matches(el, selector)) || includeCTX && el === ctx) {
|
|
2041
1796
|
return el;
|
|
2042
1797
|
}
|
|
2043
|
-
if (el === ctx)
|
|
2044
|
-
break;
|
|
1798
|
+
if (el === ctx) break;
|
|
2045
1799
|
} while (el = getParentOrHost(el));
|
|
2046
1800
|
}
|
|
2047
1801
|
return null;
|
|
@@ -2111,8 +1865,7 @@ function getWindowScrollingElement() {
|
|
|
2111
1865
|
}
|
|
2112
1866
|
}
|
|
2113
1867
|
function getRect(el, relativeToContainingBlock, relativeToNonStaticParent, undoScale, container) {
|
|
2114
|
-
if (!el.getBoundingClientRect && el !== window)
|
|
2115
|
-
return;
|
|
1868
|
+
if (!el.getBoundingClientRect && el !== window) return;
|
|
2116
1869
|
var elRect, top, left, bottom, right, height, width;
|
|
2117
1870
|
if (el !== window && el.parentNode && el !== getWindowScrollingElement()) {
|
|
2118
1871
|
elRect = el.getBoundingClientRect();
|
|
@@ -2169,15 +1922,11 @@ function isScrolledPast(el, elSide, parentSide) {
|
|
|
2169
1922
|
var parent = getParentAutoScrollElement(el, true), elSideVal = getRect(el)[elSide];
|
|
2170
1923
|
while (parent) {
|
|
2171
1924
|
var parentSideVal = getRect(parent)[parentSide], visible = void 0;
|
|
2172
|
-
|
|
1925
|
+
{
|
|
2173
1926
|
visible = elSideVal >= parentSideVal;
|
|
2174
|
-
} else {
|
|
2175
|
-
visible = elSideVal <= parentSideVal;
|
|
2176
1927
|
}
|
|
2177
|
-
if (!visible)
|
|
2178
|
-
|
|
2179
|
-
if (parent === getWindowScrollingElement())
|
|
2180
|
-
break;
|
|
1928
|
+
if (!visible) return parent;
|
|
1929
|
+
if (parent === getWindowScrollingElement()) break;
|
|
2181
1930
|
parent = getParentAutoScrollElement(parent, false);
|
|
2182
1931
|
}
|
|
2183
1932
|
return false;
|
|
@@ -2227,28 +1976,23 @@ function getRelativeScrollOffset(el) {
|
|
|
2227
1976
|
}
|
|
2228
1977
|
function indexOfObject(arr, obj) {
|
|
2229
1978
|
for (var i in arr) {
|
|
2230
|
-
if (!arr.hasOwnProperty(i))
|
|
2231
|
-
continue;
|
|
1979
|
+
if (!arr.hasOwnProperty(i)) continue;
|
|
2232
1980
|
for (var key in obj) {
|
|
2233
|
-
if (obj.hasOwnProperty(key) && obj[key] === arr[i][key])
|
|
2234
|
-
return Number(i);
|
|
1981
|
+
if (obj.hasOwnProperty(key) && obj[key] === arr[i][key]) return Number(i);
|
|
2235
1982
|
}
|
|
2236
1983
|
}
|
|
2237
1984
|
return -1;
|
|
2238
1985
|
}
|
|
2239
1986
|
function getParentAutoScrollElement(el, includeSelf) {
|
|
2240
|
-
if (!el || !el.getBoundingClientRect)
|
|
2241
|
-
return getWindowScrollingElement();
|
|
1987
|
+
if (!el || !el.getBoundingClientRect) return getWindowScrollingElement();
|
|
2242
1988
|
var elem = el;
|
|
2243
1989
|
var gotSelf = false;
|
|
2244
1990
|
do {
|
|
2245
1991
|
if (elem.clientWidth < elem.scrollWidth || elem.clientHeight < elem.scrollHeight) {
|
|
2246
1992
|
var elemCSS = css(elem);
|
|
2247
1993
|
if (elem.clientWidth < elem.scrollWidth && (elemCSS.overflowX == "auto" || elemCSS.overflowX == "scroll") || elem.clientHeight < elem.scrollHeight && (elemCSS.overflowY == "auto" || elemCSS.overflowY == "scroll")) {
|
|
2248
|
-
if (!elem.getBoundingClientRect || elem === document.body)
|
|
2249
|
-
|
|
2250
|
-
if (gotSelf || includeSelf)
|
|
2251
|
-
return elem;
|
|
1994
|
+
if (!elem.getBoundingClientRect || elem === document.body) return getWindowScrollingElement();
|
|
1995
|
+
if (gotSelf || includeSelf) return elem;
|
|
2252
1996
|
gotSelf = true;
|
|
2253
1997
|
}
|
|
2254
1998
|
}
|
|
@@ -2307,8 +2051,7 @@ function getChildContainingRectFromElement(container, options, ghostEl2) {
|
|
|
2307
2051
|
var rect = {};
|
|
2308
2052
|
Array.from(container.children).forEach(function(child) {
|
|
2309
2053
|
var _rect$left, _rect$top, _rect$right, _rect$bottom;
|
|
2310
|
-
if (!closest(child, options.draggable, container, false) || child.animated || child === ghostEl2)
|
|
2311
|
-
return;
|
|
2054
|
+
if (!closest(child, options.draggable, container, false) || child.animated || child === ghostEl2) return;
|
|
2312
2055
|
var childRect = getRect(child);
|
|
2313
2056
|
rect.left = Math.min((_rect$left = rect.left) !== null && _rect$left !== void 0 ? _rect$left : Infinity, childRect.left);
|
|
2314
2057
|
rect.top = Math.min((_rect$top = rect.top) !== null && _rect$top !== void 0 ? _rect$top : Infinity, childRect.top);
|
|
@@ -2327,12 +2070,10 @@ function AnimationStateManager() {
|
|
|
2327
2070
|
return {
|
|
2328
2071
|
captureAnimationState: function captureAnimationState() {
|
|
2329
2072
|
animationStates = [];
|
|
2330
|
-
if (!this.options.animation)
|
|
2331
|
-
return;
|
|
2073
|
+
if (!this.options.animation) return;
|
|
2332
2074
|
var children = [].slice.call(this.el.children);
|
|
2333
2075
|
children.forEach(function(child) {
|
|
2334
|
-
if (css(child, "display") === "none" || child === Sortable.ghost)
|
|
2335
|
-
return;
|
|
2076
|
+
if (css(child, "display") === "none" || child === Sortable.ghost) return;
|
|
2336
2077
|
animationStates.push({
|
|
2337
2078
|
target: child,
|
|
2338
2079
|
rect: getRect(child)
|
|
@@ -2360,8 +2101,7 @@ function AnimationStateManager() {
|
|
|
2360
2101
|
var _this = this;
|
|
2361
2102
|
if (!this.options.animation) {
|
|
2362
2103
|
clearTimeout(animationCallbackId);
|
|
2363
|
-
if (typeof callback === "function")
|
|
2364
|
-
callback();
|
|
2104
|
+
if (typeof callback === "function") callback();
|
|
2365
2105
|
return;
|
|
2366
2106
|
}
|
|
2367
2107
|
var animating = false, animationTime = 0;
|
|
@@ -2402,12 +2142,10 @@ function AnimationStateManager() {
|
|
|
2402
2142
|
});
|
|
2403
2143
|
clearTimeout(animationCallbackId);
|
|
2404
2144
|
if (!animating) {
|
|
2405
|
-
if (typeof callback === "function")
|
|
2406
|
-
callback();
|
|
2145
|
+
if (typeof callback === "function") callback();
|
|
2407
2146
|
} else {
|
|
2408
2147
|
animationCallbackId = setTimeout(function() {
|
|
2409
|
-
if (typeof callback === "function")
|
|
2410
|
-
callback();
|
|
2148
|
+
if (typeof callback === "function") callback();
|
|
2411
2149
|
}, animationTime);
|
|
2412
2150
|
}
|
|
2413
2151
|
animationStates = [];
|
|
@@ -2467,8 +2205,7 @@ var PluginManager = {
|
|
|
2467
2205
|
};
|
|
2468
2206
|
var eventNameGlobal = eventName + "Global";
|
|
2469
2207
|
plugins.forEach(function(plugin) {
|
|
2470
|
-
if (!sortable[plugin.pluginName])
|
|
2471
|
-
return;
|
|
2208
|
+
if (!sortable[plugin.pluginName]) return;
|
|
2472
2209
|
if (sortable[plugin.pluginName][eventNameGlobal]) {
|
|
2473
2210
|
sortable[plugin.pluginName][eventNameGlobal](_objectSpread2({
|
|
2474
2211
|
sortable
|
|
@@ -2484,8 +2221,7 @@ var PluginManager = {
|
|
|
2484
2221
|
initializePlugins: function initializePlugins(sortable, el, defaults2, options) {
|
|
2485
2222
|
plugins.forEach(function(plugin) {
|
|
2486
2223
|
var pluginName = plugin.pluginName;
|
|
2487
|
-
if (!sortable.options[pluginName] && !plugin.initializeByDefault)
|
|
2488
|
-
return;
|
|
2224
|
+
if (!sortable.options[pluginName] && !plugin.initializeByDefault) return;
|
|
2489
2225
|
var initialized = new plugin(sortable, el, sortable.options);
|
|
2490
2226
|
initialized.sortable = sortable;
|
|
2491
2227
|
initialized.options = sortable.options;
|
|
@@ -2493,8 +2229,7 @@ var PluginManager = {
|
|
|
2493
2229
|
_extends(defaults2, initialized.defaults);
|
|
2494
2230
|
});
|
|
2495
2231
|
for (var option2 in sortable.options) {
|
|
2496
|
-
if (!sortable.options.hasOwnProperty(option2))
|
|
2497
|
-
continue;
|
|
2232
|
+
if (!sortable.options.hasOwnProperty(option2)) continue;
|
|
2498
2233
|
var modified = this.modifyOption(sortable, option2, sortable.options[option2]);
|
|
2499
2234
|
if (typeof modified !== "undefined") {
|
|
2500
2235
|
sortable.options[option2] = modified;
|
|
@@ -2504,8 +2239,7 @@ var PluginManager = {
|
|
|
2504
2239
|
getEventProperties: function getEventProperties(name2, sortable) {
|
|
2505
2240
|
var eventProperties = {};
|
|
2506
2241
|
plugins.forEach(function(plugin) {
|
|
2507
|
-
if (typeof plugin.eventProperties !== "function")
|
|
2508
|
-
return;
|
|
2242
|
+
if (typeof plugin.eventProperties !== "function") return;
|
|
2509
2243
|
_extends(eventProperties, plugin.eventProperties.call(sortable[plugin.pluginName], name2));
|
|
2510
2244
|
});
|
|
2511
2245
|
return eventProperties;
|
|
@@ -2513,8 +2247,7 @@ var PluginManager = {
|
|
|
2513
2247
|
modifyOption: function modifyOption(sortable, name2, value) {
|
|
2514
2248
|
var modifiedValue;
|
|
2515
2249
|
plugins.forEach(function(plugin) {
|
|
2516
|
-
if (!sortable[plugin.pluginName])
|
|
2517
|
-
return;
|
|
2250
|
+
if (!sortable[plugin.pluginName]) return;
|
|
2518
2251
|
if (plugin.optionListeners && typeof plugin.optionListeners[name2] === "function") {
|
|
2519
2252
|
modifiedValue = plugin.optionListeners[name2].call(sortable[plugin.pluginName], value);
|
|
2520
2253
|
}
|
|
@@ -2525,8 +2258,7 @@ var PluginManager = {
|
|
|
2525
2258
|
function dispatchEvent(_ref) {
|
|
2526
2259
|
var sortable = _ref.sortable, rootEl2 = _ref.rootEl, name2 = _ref.name, targetEl = _ref.targetEl, cloneEl2 = _ref.cloneEl, toEl = _ref.toEl, fromEl = _ref.fromEl, oldIndex2 = _ref.oldIndex, newIndex2 = _ref.newIndex, oldDraggableIndex2 = _ref.oldDraggableIndex, newDraggableIndex2 = _ref.newDraggableIndex, originalEvent = _ref.originalEvent, putSortable2 = _ref.putSortable, extraEventProperties = _ref.extraEventProperties;
|
|
2527
2260
|
sortable = sortable || rootEl2 && rootEl2[expando];
|
|
2528
|
-
if (!sortable)
|
|
2529
|
-
return;
|
|
2261
|
+
if (!sortable) return;
|
|
2530
2262
|
var evt, options = sortable.options, onName = "on" + name2.charAt(0).toUpperCase() + name2.substr(1);
|
|
2531
2263
|
if (window.CustomEvent && !IE11OrLess && !Edge) {
|
|
2532
2264
|
evt = new CustomEvent(name2, {
|
|
@@ -2609,8 +2341,7 @@ function _dispatchEvent(info) {
|
|
|
2609
2341
|
}
|
|
2610
2342
|
var dragEl, parentEl, ghostEl, rootEl, nextEl, lastDownEl, cloneEl, cloneHidden, oldIndex, newIndex, oldDraggableIndex, newDraggableIndex, activeGroup, putSortable, awaitingDragStarted = false, ignoreNextClick = false, sortables = [], tapEvt, touchEvt, lastDx, lastDy, tapDistanceLeft, tapDistanceTop, moved, lastTarget, lastDirection, pastFirstInvertThresh = false, isCircumstantialInvert = false, targetMoveDistance, ghostRelativeParent, ghostRelativeParentInitialScroll = [], _silent = false, savedInputChecked = [];
|
|
2611
2343
|
var documentExists = typeof document !== "undefined", PositionGhostAbsolutely = IOS, CSSFloatProperty = Edge || IE11OrLess ? "cssFloat" : "float", supportDraggable = documentExists && !ChromeForAndroid && !IOS && "draggable" in document.createElement("div"), supportCssPointerEvents = function() {
|
|
2612
|
-
if (!documentExists)
|
|
2613
|
-
return;
|
|
2344
|
+
if (!documentExists) return;
|
|
2614
2345
|
if (IE11OrLess) {
|
|
2615
2346
|
return false;
|
|
2616
2347
|
}
|
|
@@ -2637,8 +2368,7 @@ var documentExists = typeof document !== "undefined", PositionGhostAbsolutely =
|
|
|
2637
2368
|
var ret;
|
|
2638
2369
|
sortables.some(function(sortable) {
|
|
2639
2370
|
var threshold = sortable[expando].options.emptyInsertThreshold;
|
|
2640
|
-
if (!threshold || lastChild(sortable))
|
|
2641
|
-
return;
|
|
2371
|
+
if (!threshold || lastChild(sortable)) return;
|
|
2642
2372
|
var rect = getRect(sortable), insideHorizontally = x >= rect.left - threshold && x <= rect.right + threshold, insideVertically = y >= rect.top - threshold && y <= rect.bottom + threshold;
|
|
2643
2373
|
if (insideHorizontally && insideVertically) {
|
|
2644
2374
|
return ret = sortable;
|
|
@@ -2767,7 +2497,8 @@ function Sortable(el, options) {
|
|
|
2767
2497
|
x: 0,
|
|
2768
2498
|
y: 0
|
|
2769
2499
|
},
|
|
2770
|
-
|
|
2500
|
+
// Disabled on Safari: #1571; Enabled on Safari IOS: #2244
|
|
2501
|
+
supportPointer: Sortable.supportPointer !== false && "PointerEvent" in window && (!Safari || IOS),
|
|
2771
2502
|
emptyInsertThreshold: 5
|
|
2772
2503
|
};
|
|
2773
2504
|
PluginManager.initializePlugins(this, el, defaults2);
|
|
@@ -2810,8 +2541,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
2810
2541
|
return typeof this.options.direction === "function" ? this.options.direction.call(this, evt, target, dragEl) : this.options.direction;
|
|
2811
2542
|
},
|
|
2812
2543
|
_onTapStart: function _onTapStart(evt) {
|
|
2813
|
-
if (!evt.cancelable)
|
|
2814
|
-
return;
|
|
2544
|
+
if (!evt.cancelable) return;
|
|
2815
2545
|
var _this = this, el = this.el, options = this.options, preventOnFilter = options.preventOnFilter, type2 = evt.type, touch = evt.touches && evt.touches[0] || evt.pointerType && evt.pointerType === "touch" && evt, target = (touch || evt).target, originalTarget = evt.target.shadowRoot && (evt.path && evt.path[0] || evt.composedPath && evt.composedPath()[0]) || target, filter = options.filter;
|
|
2816
2546
|
_saveInputCheckedState(el);
|
|
2817
2547
|
if (dragEl) {
|
|
@@ -2848,7 +2578,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
2848
2578
|
pluginEvent2("filter", _this, {
|
|
2849
2579
|
evt
|
|
2850
2580
|
});
|
|
2851
|
-
preventOnFilter && evt.
|
|
2581
|
+
preventOnFilter && evt.preventDefault();
|
|
2852
2582
|
return;
|
|
2853
2583
|
}
|
|
2854
2584
|
} else if (filter) {
|
|
@@ -2870,7 +2600,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
2870
2600
|
}
|
|
2871
2601
|
});
|
|
2872
2602
|
if (filter) {
|
|
2873
|
-
preventOnFilter && evt.
|
|
2603
|
+
preventOnFilter && evt.preventDefault();
|
|
2874
2604
|
return;
|
|
2875
2605
|
}
|
|
2876
2606
|
}
|
|
@@ -2926,9 +2656,14 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
2926
2656
|
on(ownerDocument, "dragover", nearestEmptyInsertDetectEvent);
|
|
2927
2657
|
on(ownerDocument, "mousemove", nearestEmptyInsertDetectEvent);
|
|
2928
2658
|
on(ownerDocument, "touchmove", nearestEmptyInsertDetectEvent);
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2659
|
+
if (options.supportPointer) {
|
|
2660
|
+
on(ownerDocument, "pointerup", _this._onDrop);
|
|
2661
|
+
!this.nativeDraggable && on(ownerDocument, "pointercancel", _this._onDrop);
|
|
2662
|
+
} else {
|
|
2663
|
+
on(ownerDocument, "mouseup", _this._onDrop);
|
|
2664
|
+
on(ownerDocument, "touchend", _this._onDrop);
|
|
2665
|
+
on(ownerDocument, "touchcancel", _this._onDrop);
|
|
2666
|
+
}
|
|
2932
2667
|
if (FireFox && this.nativeDraggable) {
|
|
2933
2668
|
this.options.touchStartThreshold = 4;
|
|
2934
2669
|
dragEl.draggable = true;
|
|
@@ -2941,9 +2676,14 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
2941
2676
|
this._onDrop();
|
|
2942
2677
|
return;
|
|
2943
2678
|
}
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2679
|
+
if (options.supportPointer) {
|
|
2680
|
+
on(ownerDocument, "pointerup", _this._disableDelayedDrag);
|
|
2681
|
+
on(ownerDocument, "pointercancel", _this._disableDelayedDrag);
|
|
2682
|
+
} else {
|
|
2683
|
+
on(ownerDocument, "mouseup", _this._disableDelayedDrag);
|
|
2684
|
+
on(ownerDocument, "touchend", _this._disableDelayedDrag);
|
|
2685
|
+
on(ownerDocument, "touchcancel", _this._disableDelayedDrag);
|
|
2686
|
+
}
|
|
2947
2687
|
on(ownerDocument, "mousemove", _this._delayedDragTouchMoveHandler);
|
|
2948
2688
|
on(ownerDocument, "touchmove", _this._delayedDragTouchMoveHandler);
|
|
2949
2689
|
options.supportPointer && on(ownerDocument, "pointermove", _this._delayedDragTouchMoveHandler);
|
|
@@ -2969,6 +2709,8 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
2969
2709
|
off(ownerDocument, "mouseup", this._disableDelayedDrag);
|
|
2970
2710
|
off(ownerDocument, "touchend", this._disableDelayedDrag);
|
|
2971
2711
|
off(ownerDocument, "touchcancel", this._disableDelayedDrag);
|
|
2712
|
+
off(ownerDocument, "pointerup", this._disableDelayedDrag);
|
|
2713
|
+
off(ownerDocument, "pointercancel", this._disableDelayedDrag);
|
|
2972
2714
|
off(ownerDocument, "mousemove", this._delayedDragTouchMoveHandler);
|
|
2973
2715
|
off(ownerDocument, "touchmove", this._delayedDragTouchMoveHandler);
|
|
2974
2716
|
off(ownerDocument, "pointermove", this._delayedDragTouchMoveHandler);
|
|
@@ -3030,8 +2772,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3030
2772
|
var parent = target;
|
|
3031
2773
|
while (target && target.shadowRoot) {
|
|
3032
2774
|
target = target.shadowRoot.elementFromPoint(touchEvt.clientX, touchEvt.clientY);
|
|
3033
|
-
if (target === parent)
|
|
3034
|
-
break;
|
|
2775
|
+
if (target === parent) break;
|
|
3035
2776
|
parent = target;
|
|
3036
2777
|
}
|
|
3037
2778
|
dragEl.parentNode[expando]._isOutsideThisEl(target);
|
|
@@ -3099,8 +2840,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3099
2840
|
ghostRelativeParent = ghostRelativeParent.parentNode;
|
|
3100
2841
|
}
|
|
3101
2842
|
if (ghostRelativeParent !== document.body && ghostRelativeParent !== document.documentElement) {
|
|
3102
|
-
if (ghostRelativeParent === document)
|
|
3103
|
-
ghostRelativeParent = getWindowScrollingElement();
|
|
2843
|
+
if (ghostRelativeParent === document) ghostRelativeParent = getWindowScrollingElement();
|
|
3104
2844
|
rect.top += ghostRelativeParent.scrollTop;
|
|
3105
2845
|
rect.left += ghostRelativeParent.scrollLeft;
|
|
3106
2846
|
} else {
|
|
@@ -3152,8 +2892,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3152
2892
|
}
|
|
3153
2893
|
_this.cloneId = _nextTick(function() {
|
|
3154
2894
|
pluginEvent2("clone", _this);
|
|
3155
|
-
if (Sortable.eventCanceled)
|
|
3156
|
-
return;
|
|
2895
|
+
if (Sortable.eventCanceled) return;
|
|
3157
2896
|
if (!_this.options.removeCloneOnHide) {
|
|
3158
2897
|
rootEl.insertBefore(cloneEl, dragEl);
|
|
3159
2898
|
}
|
|
@@ -3182,6 +2921,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3182
2921
|
_this._dragStartId = _nextTick(_this._dragStarted.bind(_this, fallback, evt));
|
|
3183
2922
|
on(document, "selectstart", _this);
|
|
3184
2923
|
moved = true;
|
|
2924
|
+
window.getSelection().removeAllRanges();
|
|
3185
2925
|
if (Safari) {
|
|
3186
2926
|
css(document.body, "user-select", "none");
|
|
3187
2927
|
}
|
|
@@ -3189,8 +2929,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3189
2929
|
// Returns true - if no further action is needed (either inserted or another condition)
|
|
3190
2930
|
_onDragOver: function _onDragOver(evt) {
|
|
3191
2931
|
var el = this.el, target = evt.target, dragRect, targetRect, revert, options = this.options, group = options.group, activeSortable = Sortable.active, isOwner = activeGroup === group, canSort = options.sort, fromSortable = putSortable || activeSortable, vertical, _this = this, completedFired = false;
|
|
3192
|
-
if (_silent)
|
|
3193
|
-
return;
|
|
2932
|
+
if (_silent) return;
|
|
3194
2933
|
function dragOverEvent(name2, extra) {
|
|
3195
2934
|
pluginEvent2(name2, _this, _objectSpread2({
|
|
3196
2935
|
evt,
|
|
@@ -3274,8 +3013,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3274
3013
|
}
|
|
3275
3014
|
target = closest(target, options.draggable, el, true);
|
|
3276
3015
|
dragOverEvent("dragOver");
|
|
3277
|
-
if (Sortable.eventCanceled)
|
|
3278
|
-
return completedFired;
|
|
3016
|
+
if (Sortable.eventCanceled) return completedFired;
|
|
3279
3017
|
if (dragEl.contains(evt.target) || target.animated && target.animatingX && target.animatingY || _this._ignoreWhileAnimating === target) {
|
|
3280
3018
|
return completed(false);
|
|
3281
3019
|
}
|
|
@@ -3284,8 +3022,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3284
3022
|
vertical = this._getDirection(evt, target) === "vertical";
|
|
3285
3023
|
dragRect = getRect(dragEl);
|
|
3286
3024
|
dragOverEvent("dragOverValid");
|
|
3287
|
-
if (Sortable.eventCanceled)
|
|
3288
|
-
return completedFired;
|
|
3025
|
+
if (Sortable.eventCanceled) return completedFired;
|
|
3289
3026
|
if (revert) {
|
|
3290
3027
|
parentEl = rootEl;
|
|
3291
3028
|
capture();
|
|
@@ -3404,6 +3141,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3404
3141
|
off(ownerDocument, "mouseup", this._onDrop);
|
|
3405
3142
|
off(ownerDocument, "touchend", this._onDrop);
|
|
3406
3143
|
off(ownerDocument, "pointerup", this._onDrop);
|
|
3144
|
+
off(ownerDocument, "pointercancel", this._onDrop);
|
|
3407
3145
|
off(ownerDocument, "touchcancel", this._onDrop);
|
|
3408
3146
|
off(document, "selectstart", this);
|
|
3409
3147
|
},
|
|
@@ -3576,17 +3314,17 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3576
3314
|
*/
|
|
3577
3315
|
sort: function sort(order, useAnimation) {
|
|
3578
3316
|
var items = {}, rootEl2 = this.el;
|
|
3579
|
-
this.toArray().forEach(function(
|
|
3317
|
+
this.toArray().forEach(function(id, i) {
|
|
3580
3318
|
var el = rootEl2.children[i];
|
|
3581
3319
|
if (closest(el, this.options.draggable, rootEl2, false)) {
|
|
3582
|
-
items[
|
|
3320
|
+
items[id] = el;
|
|
3583
3321
|
}
|
|
3584
3322
|
}, this);
|
|
3585
3323
|
useAnimation && this.captureAnimationState();
|
|
3586
|
-
order.forEach(function(
|
|
3587
|
-
if (items[
|
|
3588
|
-
rootEl2.removeChild(items[
|
|
3589
|
-
rootEl2.appendChild(items[
|
|
3324
|
+
order.forEach(function(id) {
|
|
3325
|
+
if (items[id]) {
|
|
3326
|
+
rootEl2.removeChild(items[id]);
|
|
3327
|
+
rootEl2.appendChild(items[id]);
|
|
3590
3328
|
}
|
|
3591
3329
|
});
|
|
3592
3330
|
useAnimation && this.animateAll();
|
|
@@ -3654,8 +3392,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3654
3392
|
_hideClone: function _hideClone() {
|
|
3655
3393
|
if (!cloneHidden) {
|
|
3656
3394
|
pluginEvent2("hideClone", this);
|
|
3657
|
-
if (Sortable.eventCanceled)
|
|
3658
|
-
return;
|
|
3395
|
+
if (Sortable.eventCanceled) return;
|
|
3659
3396
|
css(cloneEl, "display", "none");
|
|
3660
3397
|
if (this.options.removeCloneOnHide && cloneEl.parentNode) {
|
|
3661
3398
|
cloneEl.parentNode.removeChild(cloneEl);
|
|
@@ -3670,8 +3407,7 @@ Sortable.prototype = /** @lends Sortable.prototype */
|
|
|
3670
3407
|
}
|
|
3671
3408
|
if (cloneHidden) {
|
|
3672
3409
|
pluginEvent2("showClone", this);
|
|
3673
|
-
if (Sortable.eventCanceled)
|
|
3674
|
-
return;
|
|
3410
|
+
if (Sortable.eventCanceled) return;
|
|
3675
3411
|
if (dragEl.parentNode == rootEl && !this.options.group.revertClone) {
|
|
3676
3412
|
rootEl.insertBefore(cloneEl, dragEl);
|
|
3677
3413
|
} else if (nextEl) {
|
|
@@ -3790,8 +3526,8 @@ function _saveInputCheckedState(root2) {
|
|
|
3790
3526
|
function _nextTick(fn) {
|
|
3791
3527
|
return setTimeout(fn, 0);
|
|
3792
3528
|
}
|
|
3793
|
-
function _cancelNextTick(
|
|
3794
|
-
return clearTimeout(
|
|
3529
|
+
function _cancelNextTick(id) {
|
|
3530
|
+
return clearTimeout(id);
|
|
3795
3531
|
}
|
|
3796
3532
|
if (documentExists) {
|
|
3797
3533
|
on(document, "touchmove", function(evt) {
|
|
@@ -3827,14 +3563,12 @@ Sortable.mount = function() {
|
|
|
3827
3563
|
for (var _len = arguments.length, plugins2 = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
3828
3564
|
plugins2[_key] = arguments[_key];
|
|
3829
3565
|
}
|
|
3830
|
-
if (plugins2[0].constructor === Array)
|
|
3831
|
-
plugins2 = plugins2[0];
|
|
3566
|
+
if (plugins2[0].constructor === Array) plugins2 = plugins2[0];
|
|
3832
3567
|
plugins2.forEach(function(plugin) {
|
|
3833
3568
|
if (!plugin.prototype || !plugin.prototype.constructor) {
|
|
3834
3569
|
throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(plugin));
|
|
3835
3570
|
}
|
|
3836
|
-
if (plugin.utils)
|
|
3837
|
-
Sortable.utils = _objectSpread2(_objectSpread2({}, Sortable.utils), plugin.utils);
|
|
3571
|
+
if (plugin.utils) Sortable.utils = _objectSpread2(_objectSpread2({}, Sortable.utils), plugin.utils);
|
|
3838
3572
|
PluginManager.mount(plugin);
|
|
3839
3573
|
});
|
|
3840
3574
|
};
|
|
@@ -3942,8 +3676,7 @@ function clearPointerElemChangedInterval() {
|
|
|
3942
3676
|
clearInterval(pointerElemChangedInterval);
|
|
3943
3677
|
}
|
|
3944
3678
|
var autoScroll = throttle(function(evt, options, rootEl2, isFallback) {
|
|
3945
|
-
if (!options.scroll)
|
|
3946
|
-
return;
|
|
3679
|
+
if (!options.scroll) return;
|
|
3947
3680
|
var x = (evt.touches ? evt.touches[0] : evt).clientX, y = (evt.touches ? evt.touches[0] : evt).clientY, sens = options.scrollSensitivity, speed = options.scrollSpeed, winScroller = getWindowScrollingElement();
|
|
3948
3681
|
var scrollThisInstance = false, scrollCustomFn;
|
|
3949
3682
|
if (scrollRootEl !== rootEl2) {
|
|
@@ -4005,8 +3738,7 @@ var autoScroll = throttle(function(evt, options, rootEl2, isFallback) {
|
|
|
4005
3738
|
}, 30);
|
|
4006
3739
|
var drop = function drop2(_ref) {
|
|
4007
3740
|
var originalEvent = _ref.originalEvent, putSortable2 = _ref.putSortable, dragEl2 = _ref.dragEl, activeSortable = _ref.activeSortable, dispatchSortableEvent = _ref.dispatchSortableEvent, hideGhostForTarget = _ref.hideGhostForTarget, unhideGhostForTarget = _ref.unhideGhostForTarget;
|
|
4008
|
-
if (!originalEvent)
|
|
4009
|
-
return;
|
|
3741
|
+
if (!originalEvent) return;
|
|
4010
3742
|
var toSortable = putSortable2 || activeSortable;
|
|
4011
3743
|
hideGhostForTarget();
|
|
4012
3744
|
var touch = originalEvent.changedTouches && originalEvent.changedTouches.length ? originalEvent.changedTouches[0] : originalEvent;
|
|
@@ -4067,156 +3799,6 @@ _extends(Remove, {
|
|
|
4067
3799
|
});
|
|
4068
3800
|
Sortable.mount(new AutoScrollPlugin());
|
|
4069
3801
|
Sortable.mount(Remove, Revert);
|
|
4070
|
-
var baseEach$1 = _baseEach, isArrayLike$2 = isArrayLike_1;
|
|
4071
|
-
function baseMap$1(collection, iteratee) {
|
|
4072
|
-
var index2 = -1, result = isArrayLike$2(collection) ? Array(collection.length) : [];
|
|
4073
|
-
baseEach$1(collection, function(value, key, collection2) {
|
|
4074
|
-
result[++index2] = iteratee(value, key, collection2);
|
|
4075
|
-
});
|
|
4076
|
-
return result;
|
|
4077
|
-
}
|
|
4078
|
-
var _baseMap = baseMap$1;
|
|
4079
|
-
function baseSortBy$1(array, comparer) {
|
|
4080
|
-
var length = array.length;
|
|
4081
|
-
array.sort(comparer);
|
|
4082
|
-
while (length--) {
|
|
4083
|
-
array[length] = array[length].value;
|
|
4084
|
-
}
|
|
4085
|
-
return array;
|
|
4086
|
-
}
|
|
4087
|
-
var _baseSortBy = baseSortBy$1;
|
|
4088
|
-
var isSymbol = isSymbol_1;
|
|
4089
|
-
function compareAscending$1(value, other) {
|
|
4090
|
-
if (value !== other) {
|
|
4091
|
-
var valIsDefined = value !== void 0, valIsNull = value === null, valIsReflexive = value === value, valIsSymbol = isSymbol(value);
|
|
4092
|
-
var othIsDefined = other !== void 0, othIsNull = other === null, othIsReflexive = other === other, othIsSymbol = isSymbol(other);
|
|
4093
|
-
if (!othIsNull && !othIsSymbol && !valIsSymbol && value > other || valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol || valIsNull && othIsDefined && othIsReflexive || !valIsDefined && othIsReflexive || !valIsReflexive) {
|
|
4094
|
-
return 1;
|
|
4095
|
-
}
|
|
4096
|
-
if (!valIsNull && !valIsSymbol && !othIsSymbol && value < other || othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol || othIsNull && valIsDefined && valIsReflexive || !othIsDefined && valIsReflexive || !othIsReflexive) {
|
|
4097
|
-
return -1;
|
|
4098
|
-
}
|
|
4099
|
-
}
|
|
4100
|
-
return 0;
|
|
4101
|
-
}
|
|
4102
|
-
var _compareAscending = compareAscending$1;
|
|
4103
|
-
var compareAscending = _compareAscending;
|
|
4104
|
-
function compareMultiple$1(object, other, orders) {
|
|
4105
|
-
var index2 = -1, objCriteria = object.criteria, othCriteria = other.criteria, length = objCriteria.length, ordersLength = orders.length;
|
|
4106
|
-
while (++index2 < length) {
|
|
4107
|
-
var result = compareAscending(objCriteria[index2], othCriteria[index2]);
|
|
4108
|
-
if (result) {
|
|
4109
|
-
if (index2 >= ordersLength) {
|
|
4110
|
-
return result;
|
|
4111
|
-
}
|
|
4112
|
-
var order = orders[index2];
|
|
4113
|
-
return result * (order == "desc" ? -1 : 1);
|
|
4114
|
-
}
|
|
4115
|
-
}
|
|
4116
|
-
return object.index - other.index;
|
|
4117
|
-
}
|
|
4118
|
-
var _compareMultiple = compareMultiple$1;
|
|
4119
|
-
var arrayMap = _arrayMap, baseGet = _baseGet, baseIteratee = _baseIteratee, baseMap = _baseMap, baseSortBy = _baseSortBy, baseUnary = _baseUnary, compareMultiple = _compareMultiple, identity$1 = identity_1, isArray$2 = isArray_1;
|
|
4120
|
-
function baseOrderBy$1(collection, iteratees, orders) {
|
|
4121
|
-
if (iteratees.length) {
|
|
4122
|
-
iteratees = arrayMap(iteratees, function(iteratee) {
|
|
4123
|
-
if (isArray$2(iteratee)) {
|
|
4124
|
-
return function(value) {
|
|
4125
|
-
return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee);
|
|
4126
|
-
};
|
|
4127
|
-
}
|
|
4128
|
-
return iteratee;
|
|
4129
|
-
});
|
|
4130
|
-
} else {
|
|
4131
|
-
iteratees = [identity$1];
|
|
4132
|
-
}
|
|
4133
|
-
var index2 = -1;
|
|
4134
|
-
iteratees = arrayMap(iteratees, baseUnary(baseIteratee));
|
|
4135
|
-
var result = baseMap(collection, function(value, key, collection2) {
|
|
4136
|
-
var criteria = arrayMap(iteratees, function(iteratee) {
|
|
4137
|
-
return iteratee(value);
|
|
4138
|
-
});
|
|
4139
|
-
return { "criteria": criteria, "index": ++index2, "value": value };
|
|
4140
|
-
});
|
|
4141
|
-
return baseSortBy(result, function(object, other) {
|
|
4142
|
-
return compareMultiple(object, other, orders);
|
|
4143
|
-
});
|
|
4144
|
-
}
|
|
4145
|
-
var _baseOrderBy = baseOrderBy$1;
|
|
4146
|
-
var eq = eq_1, isArrayLike$1 = isArrayLike_1, isIndex = _isIndex, isObject = isObject_1;
|
|
4147
|
-
function isIterateeCall$1(value, index2, object) {
|
|
4148
|
-
if (!isObject(object)) {
|
|
4149
|
-
return false;
|
|
4150
|
-
}
|
|
4151
|
-
var type2 = typeof index2;
|
|
4152
|
-
if (type2 == "number" ? isArrayLike$1(object) && isIndex(index2, object.length) : type2 == "string" && index2 in object) {
|
|
4153
|
-
return eq(object[index2], value);
|
|
4154
|
-
}
|
|
4155
|
-
return false;
|
|
4156
|
-
}
|
|
4157
|
-
var _isIterateeCall = isIterateeCall$1;
|
|
4158
|
-
var baseFlatten = _baseFlatten, baseOrderBy = _baseOrderBy, baseRest = _baseRest, isIterateeCall = _isIterateeCall;
|
|
4159
|
-
var sortBy = baseRest(function(collection, iteratees) {
|
|
4160
|
-
if (collection == null) {
|
|
4161
|
-
return [];
|
|
4162
|
-
}
|
|
4163
|
-
var length = iteratees.length;
|
|
4164
|
-
if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {
|
|
4165
|
-
iteratees = [];
|
|
4166
|
-
} else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {
|
|
4167
|
-
iteratees = [iteratees[0]];
|
|
4168
|
-
}
|
|
4169
|
-
return baseOrderBy(collection, baseFlatten(iteratees, 1), []);
|
|
4170
|
-
});
|
|
4171
|
-
var sortBy_1 = sortBy;
|
|
4172
|
-
const sortBy$1 = /* @__PURE__ */ getDefaultExportFromCjs(sortBy_1);
|
|
4173
|
-
var toString = toString_1;
|
|
4174
|
-
var idCounter = 0;
|
|
4175
|
-
function uniqueId(prefix) {
|
|
4176
|
-
var id2 = ++idCounter;
|
|
4177
|
-
return toString(prefix) + id2;
|
|
4178
|
-
}
|
|
4179
|
-
var uniqueId_1 = uniqueId;
|
|
4180
|
-
const uniqueId$1 = /* @__PURE__ */ getDefaultExportFromCjs(uniqueId_1);
|
|
4181
|
-
var identity = identity_1;
|
|
4182
|
-
function castFunction$1(value) {
|
|
4183
|
-
return typeof value == "function" ? value : identity;
|
|
4184
|
-
}
|
|
4185
|
-
var _castFunction = castFunction$1;
|
|
4186
|
-
var arrayEach = _arrayEach, baseEach = _baseEach, castFunction = _castFunction, isArray$1 = isArray_1;
|
|
4187
|
-
function forEach(collection, iteratee) {
|
|
4188
|
-
var func = isArray$1(collection) ? arrayEach : baseEach;
|
|
4189
|
-
return func(collection, castFunction(iteratee));
|
|
4190
|
-
}
|
|
4191
|
-
var forEach_1 = forEach;
|
|
4192
|
-
const forEach$1 = /* @__PURE__ */ getDefaultExportFromCjs(forEach_1);
|
|
4193
|
-
var baseKeys = _baseKeys, getTag = _getTag, isArguments = isArguments_1, isArray = isArray_1, isArrayLike = isArrayLike_1, isBuffer = isBufferExports, isPrototype = _isPrototype, isTypedArray = isTypedArray_1;
|
|
4194
|
-
var mapTag = "[object Map]", setTag = "[object Set]";
|
|
4195
|
-
var objectProto = Object.prototype;
|
|
4196
|
-
var hasOwnProperty = objectProto.hasOwnProperty;
|
|
4197
|
-
function isEmpty(value) {
|
|
4198
|
-
if (value == null) {
|
|
4199
|
-
return true;
|
|
4200
|
-
}
|
|
4201
|
-
if (isArrayLike(value) && (isArray(value) || typeof value == "string" || typeof value.splice == "function" || isBuffer(value) || isTypedArray(value) || isArguments(value))) {
|
|
4202
|
-
return !value.length;
|
|
4203
|
-
}
|
|
4204
|
-
var tag = getTag(value);
|
|
4205
|
-
if (tag == mapTag || tag == setTag) {
|
|
4206
|
-
return !value.size;
|
|
4207
|
-
}
|
|
4208
|
-
if (isPrototype(value)) {
|
|
4209
|
-
return !baseKeys(value).length;
|
|
4210
|
-
}
|
|
4211
|
-
for (var key in value) {
|
|
4212
|
-
if (hasOwnProperty.call(value, key)) {
|
|
4213
|
-
return false;
|
|
4214
|
-
}
|
|
4215
|
-
}
|
|
4216
|
-
return true;
|
|
4217
|
-
}
|
|
4218
|
-
var isEmpty_1 = isEmpty;
|
|
4219
|
-
const isEmpty$1 = /* @__PURE__ */ getDefaultExportFromCjs(isEmpty_1);
|
|
4220
3802
|
const _hoisted_1$1 = {
|
|
4221
3803
|
key: 2,
|
|
4222
3804
|
class: "accordion-title ml-4"
|
|
@@ -4233,33 +3815,33 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4233
3815
|
embedElementConfig: {},
|
|
4234
3816
|
embeds: { default: () => ({}) },
|
|
4235
3817
|
isFocused: { type: Boolean, default: false },
|
|
4236
|
-
|
|
3818
|
+
isReadonly: { type: Boolean, default: false },
|
|
4237
3819
|
isExpanded: { type: Boolean, default: false }
|
|
4238
3820
|
},
|
|
4239
3821
|
emits: ["save", "delete"],
|
|
4240
|
-
setup(__props, { emit }) {
|
|
3822
|
+
setup(__props, { emit: __emit }) {
|
|
4241
3823
|
const props = __props;
|
|
3824
|
+
const emit = __emit;
|
|
4242
3825
|
const eventBus = inject("$eventBus");
|
|
4243
3826
|
const isEditing = ref(!props.item.header);
|
|
4244
3827
|
const form = ref();
|
|
4245
3828
|
const header = ref(props.item.header);
|
|
4246
|
-
const hasElements = computed(() => !isEmpty
|
|
3829
|
+
const hasElements = computed(() => !isEmpty(props.embeds));
|
|
4247
3830
|
const cancel = () => {
|
|
4248
3831
|
header.value = props.item.header;
|
|
4249
3832
|
isEditing.value = false;
|
|
4250
3833
|
};
|
|
4251
3834
|
const saveHeader = async () => {
|
|
4252
|
-
|
|
4253
|
-
const { valid } = await
|
|
4254
|
-
if (!valid)
|
|
4255
|
-
return;
|
|
3835
|
+
if (!form.value) return;
|
|
3836
|
+
const { valid } = await form.value.validate();
|
|
3837
|
+
if (!valid) return;
|
|
4256
3838
|
isEditing.value = false;
|
|
4257
3839
|
const item = { ...props.item, header: header.value };
|
|
4258
3840
|
emit("save", { item, embeds: props.embeds });
|
|
4259
3841
|
};
|
|
4260
3842
|
const saveEmbed = (embeds) => {
|
|
4261
|
-
const item = cloneDeep
|
|
4262
|
-
forEach
|
|
3843
|
+
const item = cloneDeep(props.item);
|
|
3844
|
+
forEach(embeds, (it) => item.body[it.id] = true);
|
|
4263
3845
|
emit("save", { item, embeds });
|
|
4264
3846
|
};
|
|
4265
3847
|
const deleteItem = () => {
|
|
@@ -4270,8 +3852,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4270
3852
|
});
|
|
4271
3853
|
};
|
|
4272
3854
|
const deleteEmbed = (embed) => {
|
|
4273
|
-
const embeds = cloneDeep
|
|
4274
|
-
const item = cloneDeep
|
|
3855
|
+
const embeds = cloneDeep(props.embeds);
|
|
3856
|
+
const item = cloneDeep(props.item);
|
|
4275
3857
|
delete embeds[embed.id];
|
|
4276
3858
|
delete item.body[embed.id];
|
|
4277
3859
|
emit("save", { item, embeds });
|
|
@@ -4310,7 +3892,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4310
3892
|
onSubmit: withModifiers(saveHeader, ["prevent"])
|
|
4311
3893
|
}, {
|
|
4312
3894
|
default: withCtx(() => [
|
|
4313
|
-
!_ctx.
|
|
3895
|
+
!_ctx.isReadonly ? (openBlock(), createElementBlock("span", {
|
|
4314
3896
|
key: 0,
|
|
4315
3897
|
class: "accordion-drag-handle",
|
|
4316
3898
|
onDrag: _cache[0] || (_cache[0] = withModifiers(() => {
|
|
@@ -4335,7 +3917,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4335
3917
|
}, ["prevent"]), ["space"]))
|
|
4336
3918
|
}, null, 8, ["modelValue", "rules"])) : (openBlock(), createElementBlock("div", _hoisted_1$1, toDisplayString(_ctx.item.header), 1)),
|
|
4337
3919
|
createVNode(_component_VSpacer),
|
|
4338
|
-
!_ctx.
|
|
3920
|
+
!_ctx.isReadonly ? (openBlock(), createElementBlock("div", _hoisted_2$1, [
|
|
4339
3921
|
isEditing.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
4340
3922
|
createVNode(_component_VBtn, {
|
|
4341
3923
|
disabled: header.value === props.item.header,
|
|
@@ -4352,7 +3934,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4352
3934
|
text: "Cancel",
|
|
4353
3935
|
variant: "text",
|
|
4354
3936
|
onClick: withModifiers(cancel, ["stop"])
|
|
4355
|
-
}, null, 8, ["disabled"
|
|
3937
|
+
}, null, 8, ["disabled"])
|
|
4356
3938
|
], 64)) : (openBlock(), createBlock(_component_VFadeTransition, {
|
|
4357
3939
|
key: 1,
|
|
4358
3940
|
group: ""
|
|
@@ -4391,7 +3973,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4391
3973
|
})
|
|
4392
3974
|
]),
|
|
4393
3975
|
_: 1
|
|
4394
|
-
}
|
|
3976
|
+
})), [
|
|
4395
3977
|
[_directive_tooltip, { text: "Delete item", openDelay: 300 }, "bottom"]
|
|
4396
3978
|
]) : createCommentVNode("", true)
|
|
4397
3979
|
], 64)) : createCommentVNode("", true)
|
|
@@ -4401,7 +3983,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4401
3983
|
])) : createCommentVNode("", true)
|
|
4402
3984
|
]),
|
|
4403
3985
|
_: 2
|
|
4404
|
-
},
|
|
3986
|
+
}, 1536)
|
|
4405
3987
|
]),
|
|
4406
3988
|
_: 2
|
|
4407
3989
|
}, 1040)
|
|
@@ -4412,13 +3994,14 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4412
3994
|
default: withCtx(() => [
|
|
4413
3995
|
!hasElements.value ? (openBlock(), createBlock(_component_VAlert, {
|
|
4414
3996
|
key: 0,
|
|
4415
|
-
|
|
4416
|
-
|
|
3997
|
+
class: "mx-6 mt-4 mb-2",
|
|
3998
|
+
color: "primary-darken-1",
|
|
3999
|
+
icon: "mdi-information-outline",
|
|
4417
4000
|
variant: "tonal",
|
|
4418
4001
|
prominent: ""
|
|
4419
4002
|
}, {
|
|
4420
4003
|
default: withCtx(() => [
|
|
4421
|
-
_ctx.
|
|
4004
|
+
_ctx.isReadonly ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
4422
4005
|
createTextVNode(" No content elements added to this item. ")
|
|
4423
4006
|
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
4424
4007
|
createTextVNode(" Click the button below to add content element. ")
|
|
@@ -4429,7 +4012,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4429
4012
|
createVNode(_component_TailorEmbeddedContainer, {
|
|
4430
4013
|
"allowed-element-config": _ctx.embedElementConfig,
|
|
4431
4014
|
container: { embeds: _ctx.embeds },
|
|
4432
|
-
"is-disabled": _ctx.
|
|
4015
|
+
"is-disabled": _ctx.isReadonly,
|
|
4433
4016
|
onDelete: deleteEmbed,
|
|
4434
4017
|
onSave: _cache[6] || (_cache[6] = ($event) => saveEmbed($event.embeds))
|
|
4435
4018
|
}, null, 8, ["allowed-element-config", "container", "is-disabled"])
|
|
@@ -4442,7 +4025,6 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
4442
4025
|
};
|
|
4443
4026
|
}
|
|
4444
4027
|
});
|
|
4445
|
-
const AccordionItem_vue_vue_type_style_index_0_scoped_890bcc09_lang = "";
|
|
4446
4028
|
const _export_sfc = (sfc, props) => {
|
|
4447
4029
|
const target = sfc.__vccOpts || sfc;
|
|
4448
4030
|
for (const [key, val] of props) {
|
|
@@ -4450,7 +4032,7 @@ const _export_sfc = (sfc, props) => {
|
|
|
4450
4032
|
}
|
|
4451
4033
|
return target;
|
|
4452
4034
|
};
|
|
4453
|
-
const AccordionItem = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-
|
|
4035
|
+
const AccordionItem = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-dbced97c"]]);
|
|
4454
4036
|
const _hoisted_1 = { class: "text-subtitle-2" };
|
|
4455
4037
|
const _hoisted_2 = { class: "pa-6 text-center" };
|
|
4456
4038
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
@@ -4458,23 +4040,25 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4458
4040
|
props: {
|
|
4459
4041
|
element: {},
|
|
4460
4042
|
embedElementConfig: {},
|
|
4043
|
+
isDragged: { type: Boolean },
|
|
4461
4044
|
isFocused: { type: Boolean },
|
|
4462
|
-
|
|
4045
|
+
isReadonly: { type: Boolean }
|
|
4463
4046
|
},
|
|
4464
4047
|
emits: ["save"],
|
|
4465
|
-
setup(__props, { emit }) {
|
|
4048
|
+
setup(__props, { emit: __emit }) {
|
|
4466
4049
|
const props = __props;
|
|
4050
|
+
const emit = __emit;
|
|
4467
4051
|
const expanded = ref([]);
|
|
4468
|
-
const elementData = reactive(cloneDeep
|
|
4052
|
+
const elementData = reactive(cloneDeep(props.element.data));
|
|
4469
4053
|
const panels = ref();
|
|
4470
4054
|
const sortable = ref();
|
|
4471
|
-
const accordionItems = computed(() => sortBy
|
|
4055
|
+
const accordionItems = computed(() => sortBy(elementData.items, "position"));
|
|
4472
4056
|
const accordionItemCount = computed(() => accordionItems.value.length);
|
|
4473
4057
|
const embedsByItem = computed(
|
|
4474
|
-
() => reduce
|
|
4058
|
+
() => reduce(
|
|
4475
4059
|
elementData.items,
|
|
4476
4060
|
(acc, item) => {
|
|
4477
|
-
acc[item.id] = pick
|
|
4061
|
+
acc[item.id] = pick(elementData.embeds, Object.keys(item.body));
|
|
4478
4062
|
return acc;
|
|
4479
4063
|
},
|
|
4480
4064
|
{}
|
|
@@ -4485,28 +4069,26 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4485
4069
|
Object.assign(elementData.embeds, embeds);
|
|
4486
4070
|
emit("save", elementData);
|
|
4487
4071
|
};
|
|
4488
|
-
const deleteItem = (
|
|
4489
|
-
const { body } = elementData.items[
|
|
4072
|
+
const deleteItem = (id) => {
|
|
4073
|
+
const { body } = elementData.items[id];
|
|
4490
4074
|
Object.keys(body).forEach((id22) => delete elementData.embeds[id22]);
|
|
4491
|
-
delete elementData.items[
|
|
4492
|
-
if (expanded.value.includes(
|
|
4493
|
-
pull$1(expanded.value, id2);
|
|
4075
|
+
delete elementData.items[id];
|
|
4076
|
+
if (expanded.value.includes(id)) pull(expanded.value, id);
|
|
4494
4077
|
emit("save", elementData);
|
|
4495
4078
|
};
|
|
4496
4079
|
const addAccordionItem = () => {
|
|
4497
|
-
const
|
|
4498
|
-
elementData.items[
|
|
4499
|
-
id
|
|
4080
|
+
const id = v4();
|
|
4081
|
+
elementData.items[id] = {
|
|
4082
|
+
id,
|
|
4500
4083
|
header: `Accordion Item Title`,
|
|
4501
4084
|
body: {},
|
|
4502
4085
|
position: accordionItemCount.value + 1
|
|
4503
4086
|
};
|
|
4504
|
-
expanded.value.push(
|
|
4087
|
+
expanded.value.push(id);
|
|
4505
4088
|
emit("save", elementData);
|
|
4506
4089
|
};
|
|
4507
4090
|
const calculateNewPosition = (oldIndex2, newIndex2) => {
|
|
4508
|
-
if (!newIndex2)
|
|
4509
|
-
return accordionItems.value[newIndex2].position / 2;
|
|
4091
|
+
if (!newIndex2) return accordionItems.value[newIndex2].position / 2;
|
|
4510
4092
|
if (newIndex2 + 1 === accordionItemCount.value) {
|
|
4511
4093
|
return accordionItems.value[newIndex2].position + 1;
|
|
4512
4094
|
}
|
|
@@ -4518,11 +4100,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4518
4100
|
onMounted(() => {
|
|
4519
4101
|
sortable.value = Sortable.create(panels.value.$el, {
|
|
4520
4102
|
animation: 150,
|
|
4521
|
-
group: `dragDrop-${uniqueId
|
|
4103
|
+
group: `dragDrop-${uniqueId()}`,
|
|
4522
4104
|
handle: ".accordion-drag-handle",
|
|
4523
4105
|
onEnd: ({ oldIndex: oldIndex2, newIndex: newIndex2 }) => {
|
|
4524
|
-
if (!isNumber
|
|
4525
|
-
return;
|
|
4106
|
+
if (!isNumber(newIndex2) || !isNumber(oldIndex2)) return;
|
|
4526
4107
|
const position = calculateNewPosition(oldIndex2, newIndex2);
|
|
4527
4108
|
const currentItem = accordionItems.value[oldIndex2];
|
|
4528
4109
|
Object.assign(elementData.items[currentItem.id], { position });
|
|
@@ -4552,12 +4133,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4552
4133
|
}, {
|
|
4553
4134
|
default: withCtx(() => [
|
|
4554
4135
|
createVNode(_component_VIcon, {
|
|
4555
|
-
icon: unref(
|
|
4136
|
+
icon: unref(index_default).ui.icon,
|
|
4556
4137
|
color: "secondary-lighten-2",
|
|
4557
4138
|
size: "18",
|
|
4558
4139
|
start: ""
|
|
4559
4140
|
}, null, 8, ["icon"]),
|
|
4560
|
-
createElementVNode("span", _hoisted_1, toDisplayString(unref(
|
|
4141
|
+
createElementVNode("span", _hoisted_1, toDisplayString(unref(index_default).name), 1)
|
|
4561
4142
|
]),
|
|
4562
4143
|
_: 1
|
|
4563
4144
|
}),
|
|
@@ -4583,7 +4164,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4583
4164
|
"allow-deletion": accordionItemCount.value > 1,
|
|
4584
4165
|
"embed-element-config": _ctx.embedElementConfig,
|
|
4585
4166
|
embeds: embedsByItem.value[item.id],
|
|
4586
|
-
"is-disabled": _ctx.
|
|
4167
|
+
"is-disabled": _ctx.isReadonly,
|
|
4587
4168
|
"is-expanded": expanded.value.includes(item.id),
|
|
4588
4169
|
"is-focused": _ctx.isFocused,
|
|
4589
4170
|
item,
|
|
@@ -4598,7 +4179,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4598
4179
|
]),
|
|
4599
4180
|
_: 1
|
|
4600
4181
|
}, 8, ["modelValue"]),
|
|
4601
|
-
!_ctx.
|
|
4182
|
+
!_ctx.isReadonly ? (openBlock(), createBlock(_component_VBtn, {
|
|
4602
4183
|
key: 0,
|
|
4603
4184
|
class: "mt-6",
|
|
4604
4185
|
color: "primary-darken-4",
|
|
@@ -4606,10 +4187,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4606
4187
|
variant: "text",
|
|
4607
4188
|
onClick: addAccordionItem
|
|
4608
4189
|
}, {
|
|
4609
|
-
default: withCtx(() => [
|
|
4190
|
+
default: withCtx(() => _cache[2] || (_cache[2] = [
|
|
4610
4191
|
createTextVNode(" Add Accordion Item ")
|
|
4611
|
-
]),
|
|
4612
|
-
_: 1
|
|
4192
|
+
])),
|
|
4193
|
+
_: 1,
|
|
4194
|
+
__: [2]
|
|
4613
4195
|
})) : createCommentVNode("", true)
|
|
4614
4196
|
])
|
|
4615
4197
|
]),
|
|
@@ -4618,10 +4200,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
4618
4200
|
};
|
|
4619
4201
|
}
|
|
4620
4202
|
});
|
|
4621
|
-
const
|
|
4622
|
-
const Edit = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-6cfc3c31"]]);
|
|
4203
|
+
const Edit = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-7a90551b"]]);
|
|
4623
4204
|
const manifest = {
|
|
4624
|
-
...
|
|
4205
|
+
...index_default,
|
|
4625
4206
|
Edit
|
|
4626
4207
|
};
|
|
4627
4208
|
export {
|