@dereekb/model 10.0.5 → 10.0.6
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/index.cjs.d.ts +1 -0
- package/index.cjs.default.js +1 -0
- package/index.cjs.js +2781 -0
- package/index.cjs.mjs +2 -0
- package/index.esm.js +3992 -0
- package/package.json +13 -3
- package/src/lib/data/address/address.d.ts +1 -1
- package/src/lib/data/website/link.d.ts +1 -1
- package/src/lib/data/website/link.file.d.ts +2 -2
- package/src/lib/data/website/link.website.d.ts +2 -2
- package/src/lib/service/loader/model.loader.d.ts +1 -1
- package/src/lib/service/permission/permission.d.ts +2 -2
- package/src/lib/service/permission/permission.service.d.ts +4 -4
- package/src/lib/service/permission/role.d.ts +1 -1
- package/src/lib/transform/transform.d.ts +3 -3
- package/src/lib/transform/transform.function.d.ts +3 -3
- package/src/lib/transform/transform.result.d.ts +2 -2
- package/src/lib/transform/type.annotation.d.ts +1 -1
- package/src/lib/transform/type.d.ts +2 -2
- package/src/lib/validator/date.d.ts +2 -2
- package/src/lib/validator/phone.d.ts +2 -2
- package/src/lib/validator/url.d.ts +2 -2
- package/CHANGELOG.md +0 -1382
- package/src/index.js +0 -5
- package/src/index.js.map +0 -1
- package/src/lib/data/address/address.js +0 -73
- package/src/lib/data/address/address.js.map +0 -1
- package/src/lib/data/address/index.js +0 -5
- package/src/lib/data/address/index.js.map +0 -1
- package/src/lib/data/index.js +0 -6
- package/src/lib/data/index.js.map +0 -1
- package/src/lib/data/website/index.js +0 -7
- package/src/lib/data/website/index.js.map +0 -1
- package/src/lib/data/website/link.file.js +0 -104
- package/src/lib/data/website/link.file.js.map +0 -1
- package/src/lib/data/website/link.js +0 -48
- package/src/lib/data/website/link.js.map +0 -1
- package/src/lib/data/website/link.website.js +0 -228
- package/src/lib/data/website/link.website.js.map +0 -1
- package/src/lib/index.js +0 -8
- package/src/lib/index.js.map +0 -1
- package/src/lib/service/context.d.ts +0 -0
- package/src/lib/service/context.js +0 -2
- package/src/lib/service/context.js.map +0 -1
- package/src/lib/service/index.js +0 -6
- package/src/lib/service/index.js.map +0 -1
- package/src/lib/service/loader/index.js +0 -5
- package/src/lib/service/loader/index.js.map +0 -1
- package/src/lib/service/loader/model.loader.js +0 -3
- package/src/lib/service/loader/model.loader.js.map +0 -1
- package/src/lib/service/permission/index.js +0 -7
- package/src/lib/service/permission/index.js.map +0 -1
- package/src/lib/service/permission/permission.js +0 -21
- package/src/lib/service/permission/permission.js.map +0 -1
- package/src/lib/service/permission/permission.service.js +0 -50
- package/src/lib/service/permission/permission.service.js.map +0 -1
- package/src/lib/service/permission/role.js +0 -119
- package/src/lib/service/permission/role.js.map +0 -1
- package/src/lib/transform/index.js +0 -9
- package/src/lib/transform/index.js.map +0 -1
- package/src/lib/transform/transform.function.js +0 -28
- package/src/lib/transform/transform.function.js.map +0 -1
- package/src/lib/transform/transform.js +0 -70
- package/src/lib/transform/transform.js.map +0 -1
- package/src/lib/transform/transform.result.js +0 -17
- package/src/lib/transform/transform.result.js.map +0 -1
- package/src/lib/transform/type.annotation.js +0 -17
- package/src/lib/transform/type.annotation.js.map +0 -1
- package/src/lib/transform/type.js +0 -44
- package/src/lib/transform/type.js.map +0 -1
- package/src/lib/validator/date.js +0 -26
- package/src/lib/validator/date.js.map +0 -1
- package/src/lib/validator/index.js +0 -7
- package/src/lib/validator/index.js.map +0 -1
- package/src/lib/validator/phone.js +0 -72
- package/src/lib/validator/phone.js.map +0 -1
- package/src/lib/validator/url.js +0 -46
- package/src/lib/validator/url.js.map +0 -1
package/index.cjs.js
ADDED
|
@@ -0,0 +1,2781 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var util = require('@dereekb/util');
|
|
6
|
+
var classTransformer = require('class-transformer');
|
|
7
|
+
var classValidator = require('class-validator');
|
|
8
|
+
|
|
9
|
+
/******************************************************************************
|
|
10
|
+
Copyright (c) Microsoft Corporation.
|
|
11
|
+
|
|
12
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
13
|
+
purpose with or without fee is hereby granted.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
16
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
17
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
18
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
19
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
20
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
21
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
22
|
+
***************************************************************************** */
|
|
23
|
+
|
|
24
|
+
function __decorate(decorators, target, key, desc) {
|
|
25
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
26
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
27
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
28
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
function __metadata(metadataKey, metadataValue) {
|
|
32
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function __awaiter(thisArg, _arguments, P, generator) {
|
|
36
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
37
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
38
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
39
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
40
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
41
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
46
|
+
var e = new Error(message);
|
|
47
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
const ADDRESS_LINE_MAX_LENGTH = 50;
|
|
51
|
+
const ADDRESS_CITY_MAX_LENGTH = 80;
|
|
52
|
+
const ADDRESS_STATE_MAX_LENGTH = 30;
|
|
53
|
+
const ADDRESS_STATE_CODE_MAX_LENGTH = 2;
|
|
54
|
+
const ADDRESS_ZIP_MAX_LENGTH = 11;
|
|
55
|
+
const ADDRESS_COUNTRY_MAX_LENGTH = 80;
|
|
56
|
+
class AbstractUnitedStatesAddressWithoutStateParams {}
|
|
57
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.MaxLength(ADDRESS_LINE_MAX_LENGTH), __metadata("design:type", String)], AbstractUnitedStatesAddressWithoutStateParams.prototype, "line1", void 0);
|
|
58
|
+
__decorate([classTransformer.Expose(), classValidator.IsOptional(), classValidator.IsString(), classValidator.MaxLength(ADDRESS_LINE_MAX_LENGTH), __metadata("design:type", String)], AbstractUnitedStatesAddressWithoutStateParams.prototype, "line2", void 0);
|
|
59
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.MaxLength(ADDRESS_CITY_MAX_LENGTH), __metadata("design:type", String)], AbstractUnitedStatesAddressWithoutStateParams.prototype, "city", void 0);
|
|
60
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.Matches(util.ZIP_CODE_STRING_REGEX), classValidator.MaxLength(ADDRESS_ZIP_MAX_LENGTH), __metadata("design:type", String)], AbstractUnitedStatesAddressWithoutStateParams.prototype, "zip", void 0);
|
|
61
|
+
/**
|
|
62
|
+
* UnitedStatesAddress that enforces a StateCode for the state value.
|
|
63
|
+
*/
|
|
64
|
+
class UnitedStatesAddressWithStateCodeParams extends AbstractUnitedStatesAddressWithoutStateParams {}
|
|
65
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.Matches(util.US_STATE_CODE_STRING_REGEX), classValidator.MinLength(ADDRESS_STATE_CODE_MAX_LENGTH), classValidator.MaxLength(ADDRESS_STATE_CODE_MAX_LENGTH), __metadata("design:type", String)], UnitedStatesAddressWithStateCodeParams.prototype, "state", void 0);
|
|
66
|
+
/**
|
|
67
|
+
* UnitedStatesAddress that enforces a State for the state value.
|
|
68
|
+
*/
|
|
69
|
+
class UnitedStatesAddressWithStateStringParams extends AbstractUnitedStatesAddressWithoutStateParams {}
|
|
70
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.MaxLength(ADDRESS_STATE_MAX_LENGTH), __metadata("design:type", String)], UnitedStatesAddressWithStateStringParams.prototype, "state", void 0);
|
|
71
|
+
|
|
72
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
73
|
+
|
|
74
|
+
var check = function (it) {
|
|
75
|
+
return it && it.Math === Math && it;
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
79
|
+
var global$f =
|
|
80
|
+
// eslint-disable-next-line es/no-global-this -- safe
|
|
81
|
+
check(typeof globalThis == 'object' && globalThis) ||
|
|
82
|
+
check(typeof window == 'object' && window) ||
|
|
83
|
+
// eslint-disable-next-line no-restricted-globals -- safe
|
|
84
|
+
check(typeof self == 'object' && self) ||
|
|
85
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
86
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
87
|
+
// eslint-disable-next-line no-new-func -- fallback
|
|
88
|
+
(function () { return this; })() || Function('return this')();
|
|
89
|
+
|
|
90
|
+
var objectGetOwnPropertyDescriptor = {};
|
|
91
|
+
|
|
92
|
+
var fails$e = function (exec) {
|
|
93
|
+
try {
|
|
94
|
+
return !!exec();
|
|
95
|
+
} catch (error) {
|
|
96
|
+
return true;
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
var fails$d = fails$e;
|
|
101
|
+
|
|
102
|
+
// Detect IE8's incomplete defineProperty implementation
|
|
103
|
+
var descriptors = !fails$d(function () {
|
|
104
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
105
|
+
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
var fails$c = fails$e;
|
|
109
|
+
|
|
110
|
+
var functionBindNative = !fails$c(function () {
|
|
111
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
112
|
+
var test = (function () { /* empty */ }).bind();
|
|
113
|
+
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
114
|
+
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
115
|
+
});
|
|
116
|
+
|
|
117
|
+
var NATIVE_BIND$1 = functionBindNative;
|
|
118
|
+
|
|
119
|
+
var call$7 = Function.prototype.call;
|
|
120
|
+
|
|
121
|
+
var functionCall = NATIVE_BIND$1 ? call$7.bind(call$7) : function () {
|
|
122
|
+
return call$7.apply(call$7, arguments);
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
var objectPropertyIsEnumerable = {};
|
|
126
|
+
|
|
127
|
+
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
128
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
129
|
+
var getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
130
|
+
|
|
131
|
+
// Nashorn ~ JDK8 bug
|
|
132
|
+
var NASHORN_BUG = getOwnPropertyDescriptor$1 && !$propertyIsEnumerable.call({ 1: 2 }, 1);
|
|
133
|
+
|
|
134
|
+
// `Object.prototype.propertyIsEnumerable` method implementation
|
|
135
|
+
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
|
|
136
|
+
objectPropertyIsEnumerable.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
137
|
+
var descriptor = getOwnPropertyDescriptor$1(this, V);
|
|
138
|
+
return !!descriptor && descriptor.enumerable;
|
|
139
|
+
} : $propertyIsEnumerable;
|
|
140
|
+
|
|
141
|
+
var createPropertyDescriptor$3 = function (bitmap, value) {
|
|
142
|
+
return {
|
|
143
|
+
enumerable: !(bitmap & 1),
|
|
144
|
+
configurable: !(bitmap & 2),
|
|
145
|
+
writable: !(bitmap & 4),
|
|
146
|
+
value: value
|
|
147
|
+
};
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
var NATIVE_BIND = functionBindNative;
|
|
151
|
+
|
|
152
|
+
var FunctionPrototype$1 = Function.prototype;
|
|
153
|
+
var call$6 = FunctionPrototype$1.call;
|
|
154
|
+
var uncurryThisWithBind = NATIVE_BIND && FunctionPrototype$1.bind.bind(call$6, call$6);
|
|
155
|
+
|
|
156
|
+
var functionUncurryThis = NATIVE_BIND ? uncurryThisWithBind : function (fn) {
|
|
157
|
+
return function () {
|
|
158
|
+
return call$6.apply(fn, arguments);
|
|
159
|
+
};
|
|
160
|
+
};
|
|
161
|
+
|
|
162
|
+
var uncurryThis$b = functionUncurryThis;
|
|
163
|
+
|
|
164
|
+
var toString$3 = uncurryThis$b({}.toString);
|
|
165
|
+
var stringSlice$2 = uncurryThis$b(''.slice);
|
|
166
|
+
|
|
167
|
+
var classofRaw$1 = function (it) {
|
|
168
|
+
return stringSlice$2(toString$3(it), 8, -1);
|
|
169
|
+
};
|
|
170
|
+
|
|
171
|
+
var uncurryThis$a = functionUncurryThis;
|
|
172
|
+
var fails$b = fails$e;
|
|
173
|
+
var classof$2 = classofRaw$1;
|
|
174
|
+
|
|
175
|
+
var $Object$4 = Object;
|
|
176
|
+
var split = uncurryThis$a(''.split);
|
|
177
|
+
|
|
178
|
+
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
179
|
+
var indexedObject = fails$b(function () {
|
|
180
|
+
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
181
|
+
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
182
|
+
return !$Object$4('z').propertyIsEnumerable(0);
|
|
183
|
+
}) ? function (it) {
|
|
184
|
+
return classof$2(it) === 'String' ? split(it, '') : $Object$4(it);
|
|
185
|
+
} : $Object$4;
|
|
186
|
+
|
|
187
|
+
// we can't use just `it == null` since of `document.all` special case
|
|
188
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
189
|
+
var isNullOrUndefined$2 = function (it) {
|
|
190
|
+
return it === null || it === undefined;
|
|
191
|
+
};
|
|
192
|
+
|
|
193
|
+
var isNullOrUndefined$1 = isNullOrUndefined$2;
|
|
194
|
+
|
|
195
|
+
var $TypeError$6 = TypeError;
|
|
196
|
+
|
|
197
|
+
// `RequireObjectCoercible` abstract operation
|
|
198
|
+
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
199
|
+
var requireObjectCoercible$2 = function (it) {
|
|
200
|
+
if (isNullOrUndefined$1(it)) throw new $TypeError$6("Can't call method on " + it);
|
|
201
|
+
return it;
|
|
202
|
+
};
|
|
203
|
+
|
|
204
|
+
// toObject with fallback for non-array-like ES3 strings
|
|
205
|
+
var IndexedObject$1 = indexedObject;
|
|
206
|
+
var requireObjectCoercible$1 = requireObjectCoercible$2;
|
|
207
|
+
|
|
208
|
+
var toIndexedObject$5 = function (it) {
|
|
209
|
+
return IndexedObject$1(requireObjectCoercible$1(it));
|
|
210
|
+
};
|
|
211
|
+
|
|
212
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
213
|
+
var documentAll = typeof document == 'object' && document.all;
|
|
214
|
+
|
|
215
|
+
// `IsCallable` abstract operation
|
|
216
|
+
// https://tc39.es/ecma262/#sec-iscallable
|
|
217
|
+
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
218
|
+
var isCallable$e = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
|
|
219
|
+
return typeof argument == 'function' || argument === documentAll;
|
|
220
|
+
} : function (argument) {
|
|
221
|
+
return typeof argument == 'function';
|
|
222
|
+
};
|
|
223
|
+
|
|
224
|
+
var isCallable$d = isCallable$e;
|
|
225
|
+
|
|
226
|
+
var isObject$7 = function (it) {
|
|
227
|
+
return typeof it == 'object' ? it !== null : isCallable$d(it);
|
|
228
|
+
};
|
|
229
|
+
|
|
230
|
+
var global$e = global$f;
|
|
231
|
+
var isCallable$c = isCallable$e;
|
|
232
|
+
|
|
233
|
+
var aFunction = function (argument) {
|
|
234
|
+
return isCallable$c(argument) ? argument : undefined;
|
|
235
|
+
};
|
|
236
|
+
|
|
237
|
+
var getBuiltIn$3 = function (namespace, method) {
|
|
238
|
+
return arguments.length < 2 ? aFunction(global$e[namespace]) : global$e[namespace] && global$e[namespace][method];
|
|
239
|
+
};
|
|
240
|
+
|
|
241
|
+
var uncurryThis$9 = functionUncurryThis;
|
|
242
|
+
|
|
243
|
+
var objectIsPrototypeOf = uncurryThis$9({}.isPrototypeOf);
|
|
244
|
+
|
|
245
|
+
var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
|
|
246
|
+
|
|
247
|
+
var global$d = global$f;
|
|
248
|
+
var userAgent = engineUserAgent;
|
|
249
|
+
|
|
250
|
+
var process = global$d.process;
|
|
251
|
+
var Deno = global$d.Deno;
|
|
252
|
+
var versions = process && process.versions || Deno && Deno.version;
|
|
253
|
+
var v8 = versions && versions.v8;
|
|
254
|
+
var match, version;
|
|
255
|
+
|
|
256
|
+
if (v8) {
|
|
257
|
+
match = v8.split('.');
|
|
258
|
+
// in old Chrome, versions of V8 isn't V8 = Chrome / 10
|
|
259
|
+
// but their correct versions are not interesting for us
|
|
260
|
+
version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
|
|
264
|
+
// so check `userAgent` even if `.v8` exists, but 0
|
|
265
|
+
if (!version && userAgent) {
|
|
266
|
+
match = userAgent.match(/Edge\/(\d+)/);
|
|
267
|
+
if (!match || match[1] >= 74) {
|
|
268
|
+
match = userAgent.match(/Chrome\/(\d+)/);
|
|
269
|
+
if (match) version = +match[1];
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
var engineV8Version = version;
|
|
274
|
+
|
|
275
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
276
|
+
var V8_VERSION = engineV8Version;
|
|
277
|
+
var fails$a = fails$e;
|
|
278
|
+
var global$c = global$f;
|
|
279
|
+
|
|
280
|
+
var $String$5 = global$c.String;
|
|
281
|
+
|
|
282
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
283
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$a(function () {
|
|
284
|
+
var symbol = Symbol('symbol detection');
|
|
285
|
+
// Chrome 38 Symbol has incorrect toString conversion
|
|
286
|
+
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
287
|
+
// nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
|
|
288
|
+
// of course, fail.
|
|
289
|
+
return !$String$5(symbol) || !(Object(symbol) instanceof Symbol) ||
|
|
290
|
+
// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
|
|
291
|
+
!Symbol.sham && V8_VERSION && V8_VERSION < 41;
|
|
292
|
+
});
|
|
293
|
+
|
|
294
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
295
|
+
var NATIVE_SYMBOL$1 = symbolConstructorDetection;
|
|
296
|
+
|
|
297
|
+
var useSymbolAsUid = NATIVE_SYMBOL$1
|
|
298
|
+
&& !Symbol.sham
|
|
299
|
+
&& typeof Symbol.iterator == 'symbol';
|
|
300
|
+
|
|
301
|
+
var getBuiltIn$2 = getBuiltIn$3;
|
|
302
|
+
var isCallable$b = isCallable$e;
|
|
303
|
+
var isPrototypeOf = objectIsPrototypeOf;
|
|
304
|
+
var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
|
|
305
|
+
|
|
306
|
+
var $Object$3 = Object;
|
|
307
|
+
|
|
308
|
+
var isSymbol$2 = USE_SYMBOL_AS_UID$1 ? function (it) {
|
|
309
|
+
return typeof it == 'symbol';
|
|
310
|
+
} : function (it) {
|
|
311
|
+
var $Symbol = getBuiltIn$2('Symbol');
|
|
312
|
+
return isCallable$b($Symbol) && isPrototypeOf($Symbol.prototype, $Object$3(it));
|
|
313
|
+
};
|
|
314
|
+
|
|
315
|
+
var $String$4 = String;
|
|
316
|
+
|
|
317
|
+
var tryToString$1 = function (argument) {
|
|
318
|
+
try {
|
|
319
|
+
return $String$4(argument);
|
|
320
|
+
} catch (error) {
|
|
321
|
+
return 'Object';
|
|
322
|
+
}
|
|
323
|
+
};
|
|
324
|
+
|
|
325
|
+
var isCallable$a = isCallable$e;
|
|
326
|
+
var tryToString = tryToString$1;
|
|
327
|
+
|
|
328
|
+
var $TypeError$5 = TypeError;
|
|
329
|
+
|
|
330
|
+
// `Assert: IsCallable(argument) is true`
|
|
331
|
+
var aCallable$2 = function (argument) {
|
|
332
|
+
if (isCallable$a(argument)) return argument;
|
|
333
|
+
throw new $TypeError$5(tryToString(argument) + ' is not a function');
|
|
334
|
+
};
|
|
335
|
+
|
|
336
|
+
var aCallable$1 = aCallable$2;
|
|
337
|
+
var isNullOrUndefined = isNullOrUndefined$2;
|
|
338
|
+
|
|
339
|
+
// `GetMethod` abstract operation
|
|
340
|
+
// https://tc39.es/ecma262/#sec-getmethod
|
|
341
|
+
var getMethod$1 = function (V, P) {
|
|
342
|
+
var func = V[P];
|
|
343
|
+
return isNullOrUndefined(func) ? undefined : aCallable$1(func);
|
|
344
|
+
};
|
|
345
|
+
|
|
346
|
+
var call$5 = functionCall;
|
|
347
|
+
var isCallable$9 = isCallable$e;
|
|
348
|
+
var isObject$6 = isObject$7;
|
|
349
|
+
|
|
350
|
+
var $TypeError$4 = TypeError;
|
|
351
|
+
|
|
352
|
+
// `OrdinaryToPrimitive` abstract operation
|
|
353
|
+
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
354
|
+
var ordinaryToPrimitive$1 = function (input, pref) {
|
|
355
|
+
var fn, val;
|
|
356
|
+
if (pref === 'string' && isCallable$9(fn = input.toString) && !isObject$6(val = call$5(fn, input))) return val;
|
|
357
|
+
if (isCallable$9(fn = input.valueOf) && !isObject$6(val = call$5(fn, input))) return val;
|
|
358
|
+
if (pref !== 'string' && isCallable$9(fn = input.toString) && !isObject$6(val = call$5(fn, input))) return val;
|
|
359
|
+
throw new $TypeError$4("Can't convert object to primitive value");
|
|
360
|
+
};
|
|
361
|
+
|
|
362
|
+
var shared$4 = {exports: {}};
|
|
363
|
+
|
|
364
|
+
var global$b = global$f;
|
|
365
|
+
|
|
366
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
367
|
+
var defineProperty$5 = Object.defineProperty;
|
|
368
|
+
|
|
369
|
+
var defineGlobalProperty$3 = function (key, value) {
|
|
370
|
+
try {
|
|
371
|
+
defineProperty$5(global$b, key, { value: value, configurable: true, writable: true });
|
|
372
|
+
} catch (error) {
|
|
373
|
+
global$b[key] = value;
|
|
374
|
+
} return value;
|
|
375
|
+
};
|
|
376
|
+
|
|
377
|
+
var global$a = global$f;
|
|
378
|
+
var defineGlobalProperty$2 = defineGlobalProperty$3;
|
|
379
|
+
|
|
380
|
+
var SHARED = '__core-js_shared__';
|
|
381
|
+
var store$3 = global$a[SHARED] || defineGlobalProperty$2(SHARED, {});
|
|
382
|
+
|
|
383
|
+
var sharedStore = store$3;
|
|
384
|
+
|
|
385
|
+
var store$2 = sharedStore;
|
|
386
|
+
|
|
387
|
+
(shared$4.exports = function (key, value) {
|
|
388
|
+
return store$2[key] || (store$2[key] = value !== undefined ? value : {});
|
|
389
|
+
})('versions', []).push({
|
|
390
|
+
version: '3.35.0',
|
|
391
|
+
mode: 'global',
|
|
392
|
+
copyright: '© 2014-2023 Denis Pushkarev (zloirock.ru)',
|
|
393
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.35.0/LICENSE',
|
|
394
|
+
source: 'https://github.com/zloirock/core-js'
|
|
395
|
+
});
|
|
396
|
+
|
|
397
|
+
var requireObjectCoercible = requireObjectCoercible$2;
|
|
398
|
+
|
|
399
|
+
var $Object$2 = Object;
|
|
400
|
+
|
|
401
|
+
// `ToObject` abstract operation
|
|
402
|
+
// https://tc39.es/ecma262/#sec-toobject
|
|
403
|
+
var toObject$3 = function (argument) {
|
|
404
|
+
return $Object$2(requireObjectCoercible(argument));
|
|
405
|
+
};
|
|
406
|
+
|
|
407
|
+
var uncurryThis$8 = functionUncurryThis;
|
|
408
|
+
var toObject$2 = toObject$3;
|
|
409
|
+
|
|
410
|
+
var hasOwnProperty = uncurryThis$8({}.hasOwnProperty);
|
|
411
|
+
|
|
412
|
+
// `HasOwnProperty` abstract operation
|
|
413
|
+
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
414
|
+
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
415
|
+
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
416
|
+
return hasOwnProperty(toObject$2(it), key);
|
|
417
|
+
};
|
|
418
|
+
|
|
419
|
+
var uncurryThis$7 = functionUncurryThis;
|
|
420
|
+
|
|
421
|
+
var id = 0;
|
|
422
|
+
var postfix = Math.random();
|
|
423
|
+
var toString$2 = uncurryThis$7(1.0.toString);
|
|
424
|
+
|
|
425
|
+
var uid$2 = function (key) {
|
|
426
|
+
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$2(++id + postfix, 36);
|
|
427
|
+
};
|
|
428
|
+
|
|
429
|
+
var global$9 = global$f;
|
|
430
|
+
var shared$3 = shared$4.exports;
|
|
431
|
+
var hasOwn$8 = hasOwnProperty_1;
|
|
432
|
+
var uid$1 = uid$2;
|
|
433
|
+
var NATIVE_SYMBOL = symbolConstructorDetection;
|
|
434
|
+
var USE_SYMBOL_AS_UID = useSymbolAsUid;
|
|
435
|
+
|
|
436
|
+
var Symbol$1 = global$9.Symbol;
|
|
437
|
+
var WellKnownSymbolsStore = shared$3('wks');
|
|
438
|
+
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
|
|
439
|
+
|
|
440
|
+
var wellKnownSymbol$8 = function (name) {
|
|
441
|
+
if (!hasOwn$8(WellKnownSymbolsStore, name)) {
|
|
442
|
+
WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn$8(Symbol$1, name)
|
|
443
|
+
? Symbol$1[name]
|
|
444
|
+
: createWellKnownSymbol('Symbol.' + name);
|
|
445
|
+
} return WellKnownSymbolsStore[name];
|
|
446
|
+
};
|
|
447
|
+
|
|
448
|
+
var call$4 = functionCall;
|
|
449
|
+
var isObject$5 = isObject$7;
|
|
450
|
+
var isSymbol$1 = isSymbol$2;
|
|
451
|
+
var getMethod = getMethod$1;
|
|
452
|
+
var ordinaryToPrimitive = ordinaryToPrimitive$1;
|
|
453
|
+
var wellKnownSymbol$7 = wellKnownSymbol$8;
|
|
454
|
+
|
|
455
|
+
var $TypeError$3 = TypeError;
|
|
456
|
+
var TO_PRIMITIVE = wellKnownSymbol$7('toPrimitive');
|
|
457
|
+
|
|
458
|
+
// `ToPrimitive` abstract operation
|
|
459
|
+
// https://tc39.es/ecma262/#sec-toprimitive
|
|
460
|
+
var toPrimitive$1 = function (input, pref) {
|
|
461
|
+
if (!isObject$5(input) || isSymbol$1(input)) return input;
|
|
462
|
+
var exoticToPrim = getMethod(input, TO_PRIMITIVE);
|
|
463
|
+
var result;
|
|
464
|
+
if (exoticToPrim) {
|
|
465
|
+
if (pref === undefined) pref = 'default';
|
|
466
|
+
result = call$4(exoticToPrim, input, pref);
|
|
467
|
+
if (!isObject$5(result) || isSymbol$1(result)) return result;
|
|
468
|
+
throw new $TypeError$3("Can't convert object to primitive value");
|
|
469
|
+
}
|
|
470
|
+
if (pref === undefined) pref = 'number';
|
|
471
|
+
return ordinaryToPrimitive(input, pref);
|
|
472
|
+
};
|
|
473
|
+
|
|
474
|
+
var toPrimitive = toPrimitive$1;
|
|
475
|
+
var isSymbol = isSymbol$2;
|
|
476
|
+
|
|
477
|
+
// `ToPropertyKey` abstract operation
|
|
478
|
+
// https://tc39.es/ecma262/#sec-topropertykey
|
|
479
|
+
var toPropertyKey$2 = function (argument) {
|
|
480
|
+
var key = toPrimitive(argument, 'string');
|
|
481
|
+
return isSymbol(key) ? key : key + '';
|
|
482
|
+
};
|
|
483
|
+
|
|
484
|
+
var global$8 = global$f;
|
|
485
|
+
var isObject$4 = isObject$7;
|
|
486
|
+
|
|
487
|
+
var document$1 = global$8.document;
|
|
488
|
+
// typeof document.createElement is 'object' in old IE
|
|
489
|
+
var EXISTS$1 = isObject$4(document$1) && isObject$4(document$1.createElement);
|
|
490
|
+
|
|
491
|
+
var documentCreateElement$2 = function (it) {
|
|
492
|
+
return EXISTS$1 ? document$1.createElement(it) : {};
|
|
493
|
+
};
|
|
494
|
+
|
|
495
|
+
var DESCRIPTORS$9 = descriptors;
|
|
496
|
+
var fails$9 = fails$e;
|
|
497
|
+
var createElement = documentCreateElement$2;
|
|
498
|
+
|
|
499
|
+
// Thanks to IE8 for its funny defineProperty
|
|
500
|
+
var ie8DomDefine = !DESCRIPTORS$9 && !fails$9(function () {
|
|
501
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
502
|
+
return Object.defineProperty(createElement('div'), 'a', {
|
|
503
|
+
get: function () { return 7; }
|
|
504
|
+
}).a !== 7;
|
|
505
|
+
});
|
|
506
|
+
|
|
507
|
+
var DESCRIPTORS$8 = descriptors;
|
|
508
|
+
var call$3 = functionCall;
|
|
509
|
+
var propertyIsEnumerableModule$1 = objectPropertyIsEnumerable;
|
|
510
|
+
var createPropertyDescriptor$2 = createPropertyDescriptor$3;
|
|
511
|
+
var toIndexedObject$4 = toIndexedObject$5;
|
|
512
|
+
var toPropertyKey$1 = toPropertyKey$2;
|
|
513
|
+
var hasOwn$7 = hasOwnProperty_1;
|
|
514
|
+
var IE8_DOM_DEFINE$1 = ie8DomDefine;
|
|
515
|
+
|
|
516
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
517
|
+
var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
518
|
+
|
|
519
|
+
// `Object.getOwnPropertyDescriptor` method
|
|
520
|
+
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
|
|
521
|
+
objectGetOwnPropertyDescriptor.f = DESCRIPTORS$8 ? $getOwnPropertyDescriptor$1 : function getOwnPropertyDescriptor(O, P) {
|
|
522
|
+
O = toIndexedObject$4(O);
|
|
523
|
+
P = toPropertyKey$1(P);
|
|
524
|
+
if (IE8_DOM_DEFINE$1) try {
|
|
525
|
+
return $getOwnPropertyDescriptor$1(O, P);
|
|
526
|
+
} catch (error) { /* empty */ }
|
|
527
|
+
if (hasOwn$7(O, P)) return createPropertyDescriptor$2(!call$3(propertyIsEnumerableModule$1.f, O, P), O[P]);
|
|
528
|
+
};
|
|
529
|
+
|
|
530
|
+
var objectDefineProperty = {};
|
|
531
|
+
|
|
532
|
+
var DESCRIPTORS$7 = descriptors;
|
|
533
|
+
var fails$8 = fails$e;
|
|
534
|
+
|
|
535
|
+
// V8 ~ Chrome 36-
|
|
536
|
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
537
|
+
var v8PrototypeDefineBug = DESCRIPTORS$7 && fails$8(function () {
|
|
538
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
539
|
+
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
540
|
+
value: 42,
|
|
541
|
+
writable: false
|
|
542
|
+
}).prototype !== 42;
|
|
543
|
+
});
|
|
544
|
+
|
|
545
|
+
var isObject$3 = isObject$7;
|
|
546
|
+
|
|
547
|
+
var $String$3 = String;
|
|
548
|
+
var $TypeError$2 = TypeError;
|
|
549
|
+
|
|
550
|
+
// `Assert: Type(argument) is Object`
|
|
551
|
+
var anObject$6 = function (argument) {
|
|
552
|
+
if (isObject$3(argument)) return argument;
|
|
553
|
+
throw new $TypeError$2($String$3(argument) + ' is not an object');
|
|
554
|
+
};
|
|
555
|
+
|
|
556
|
+
var DESCRIPTORS$6 = descriptors;
|
|
557
|
+
var IE8_DOM_DEFINE = ie8DomDefine;
|
|
558
|
+
var V8_PROTOTYPE_DEFINE_BUG$1 = v8PrototypeDefineBug;
|
|
559
|
+
var anObject$5 = anObject$6;
|
|
560
|
+
var toPropertyKey = toPropertyKey$2;
|
|
561
|
+
|
|
562
|
+
var $TypeError$1 = TypeError;
|
|
563
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
564
|
+
var $defineProperty = Object.defineProperty;
|
|
565
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
566
|
+
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
567
|
+
var ENUMERABLE = 'enumerable';
|
|
568
|
+
var CONFIGURABLE$1 = 'configurable';
|
|
569
|
+
var WRITABLE = 'writable';
|
|
570
|
+
|
|
571
|
+
// `Object.defineProperty` method
|
|
572
|
+
// https://tc39.es/ecma262/#sec-object.defineproperty
|
|
573
|
+
objectDefineProperty.f = DESCRIPTORS$6 ? V8_PROTOTYPE_DEFINE_BUG$1 ? function defineProperty(O, P, Attributes) {
|
|
574
|
+
anObject$5(O);
|
|
575
|
+
P = toPropertyKey(P);
|
|
576
|
+
anObject$5(Attributes);
|
|
577
|
+
if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
|
|
578
|
+
var current = $getOwnPropertyDescriptor(O, P);
|
|
579
|
+
if (current && current[WRITABLE]) {
|
|
580
|
+
O[P] = Attributes.value;
|
|
581
|
+
Attributes = {
|
|
582
|
+
configurable: CONFIGURABLE$1 in Attributes ? Attributes[CONFIGURABLE$1] : current[CONFIGURABLE$1],
|
|
583
|
+
enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],
|
|
584
|
+
writable: false
|
|
585
|
+
};
|
|
586
|
+
}
|
|
587
|
+
} return $defineProperty(O, P, Attributes);
|
|
588
|
+
} : $defineProperty : function defineProperty(O, P, Attributes) {
|
|
589
|
+
anObject$5(O);
|
|
590
|
+
P = toPropertyKey(P);
|
|
591
|
+
anObject$5(Attributes);
|
|
592
|
+
if (IE8_DOM_DEFINE) try {
|
|
593
|
+
return $defineProperty(O, P, Attributes);
|
|
594
|
+
} catch (error) { /* empty */ }
|
|
595
|
+
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$1('Accessors not supported');
|
|
596
|
+
if ('value' in Attributes) O[P] = Attributes.value;
|
|
597
|
+
return O;
|
|
598
|
+
};
|
|
599
|
+
|
|
600
|
+
var DESCRIPTORS$5 = descriptors;
|
|
601
|
+
var definePropertyModule$3 = objectDefineProperty;
|
|
602
|
+
var createPropertyDescriptor$1 = createPropertyDescriptor$3;
|
|
603
|
+
|
|
604
|
+
var createNonEnumerableProperty$4 = DESCRIPTORS$5 ? function (object, key, value) {
|
|
605
|
+
return definePropertyModule$3.f(object, key, createPropertyDescriptor$1(1, value));
|
|
606
|
+
} : function (object, key, value) {
|
|
607
|
+
object[key] = value;
|
|
608
|
+
return object;
|
|
609
|
+
};
|
|
610
|
+
|
|
611
|
+
var makeBuiltIn$2 = {exports: {}};
|
|
612
|
+
|
|
613
|
+
var DESCRIPTORS$4 = descriptors;
|
|
614
|
+
var hasOwn$6 = hasOwnProperty_1;
|
|
615
|
+
|
|
616
|
+
var FunctionPrototype = Function.prototype;
|
|
617
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
618
|
+
var getDescriptor = DESCRIPTORS$4 && Object.getOwnPropertyDescriptor;
|
|
619
|
+
|
|
620
|
+
var EXISTS = hasOwn$6(FunctionPrototype, 'name');
|
|
621
|
+
// additional protection from minified / mangled / dropped function names
|
|
622
|
+
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
623
|
+
var CONFIGURABLE = EXISTS && (!DESCRIPTORS$4 || (DESCRIPTORS$4 && getDescriptor(FunctionPrototype, 'name').configurable));
|
|
624
|
+
|
|
625
|
+
var functionName = {
|
|
626
|
+
EXISTS: EXISTS,
|
|
627
|
+
PROPER: PROPER,
|
|
628
|
+
CONFIGURABLE: CONFIGURABLE
|
|
629
|
+
};
|
|
630
|
+
|
|
631
|
+
var uncurryThis$6 = functionUncurryThis;
|
|
632
|
+
var isCallable$8 = isCallable$e;
|
|
633
|
+
var store$1 = sharedStore;
|
|
634
|
+
|
|
635
|
+
var functionToString = uncurryThis$6(Function.toString);
|
|
636
|
+
|
|
637
|
+
// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
|
|
638
|
+
if (!isCallable$8(store$1.inspectSource)) {
|
|
639
|
+
store$1.inspectSource = function (it) {
|
|
640
|
+
return functionToString(it);
|
|
641
|
+
};
|
|
642
|
+
}
|
|
643
|
+
|
|
644
|
+
var inspectSource$1 = store$1.inspectSource;
|
|
645
|
+
|
|
646
|
+
var global$7 = global$f;
|
|
647
|
+
var isCallable$7 = isCallable$e;
|
|
648
|
+
|
|
649
|
+
var WeakMap$1 = global$7.WeakMap;
|
|
650
|
+
|
|
651
|
+
var weakMapBasicDetection = isCallable$7(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
652
|
+
|
|
653
|
+
var shared$2 = shared$4.exports;
|
|
654
|
+
var uid = uid$2;
|
|
655
|
+
|
|
656
|
+
var keys = shared$2('keys');
|
|
657
|
+
|
|
658
|
+
var sharedKey$3 = function (key) {
|
|
659
|
+
return keys[key] || (keys[key] = uid(key));
|
|
660
|
+
};
|
|
661
|
+
|
|
662
|
+
var hiddenKeys$4 = {};
|
|
663
|
+
|
|
664
|
+
var NATIVE_WEAK_MAP = weakMapBasicDetection;
|
|
665
|
+
var global$6 = global$f;
|
|
666
|
+
var isObject$2 = isObject$7;
|
|
667
|
+
var createNonEnumerableProperty$3 = createNonEnumerableProperty$4;
|
|
668
|
+
var hasOwn$5 = hasOwnProperty_1;
|
|
669
|
+
var shared$1 = sharedStore;
|
|
670
|
+
var sharedKey$2 = sharedKey$3;
|
|
671
|
+
var hiddenKeys$3 = hiddenKeys$4;
|
|
672
|
+
|
|
673
|
+
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
674
|
+
var TypeError$1 = global$6.TypeError;
|
|
675
|
+
var WeakMap = global$6.WeakMap;
|
|
676
|
+
var set, get, has;
|
|
677
|
+
|
|
678
|
+
var enforce = function (it) {
|
|
679
|
+
return has(it) ? get(it) : set(it, {});
|
|
680
|
+
};
|
|
681
|
+
|
|
682
|
+
var getterFor = function (TYPE) {
|
|
683
|
+
return function (it) {
|
|
684
|
+
var state;
|
|
685
|
+
if (!isObject$2(it) || (state = get(it)).type !== TYPE) {
|
|
686
|
+
throw new TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
687
|
+
} return state;
|
|
688
|
+
};
|
|
689
|
+
};
|
|
690
|
+
|
|
691
|
+
if (NATIVE_WEAK_MAP || shared$1.state) {
|
|
692
|
+
var store = shared$1.state || (shared$1.state = new WeakMap());
|
|
693
|
+
/* eslint-disable no-self-assign -- prototype methods protection */
|
|
694
|
+
store.get = store.get;
|
|
695
|
+
store.has = store.has;
|
|
696
|
+
store.set = store.set;
|
|
697
|
+
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
698
|
+
set = function (it, metadata) {
|
|
699
|
+
if (store.has(it)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
700
|
+
metadata.facade = it;
|
|
701
|
+
store.set(it, metadata);
|
|
702
|
+
return metadata;
|
|
703
|
+
};
|
|
704
|
+
get = function (it) {
|
|
705
|
+
return store.get(it) || {};
|
|
706
|
+
};
|
|
707
|
+
has = function (it) {
|
|
708
|
+
return store.has(it);
|
|
709
|
+
};
|
|
710
|
+
} else {
|
|
711
|
+
var STATE = sharedKey$2('state');
|
|
712
|
+
hiddenKeys$3[STATE] = true;
|
|
713
|
+
set = function (it, metadata) {
|
|
714
|
+
if (hasOwn$5(it, STATE)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
715
|
+
metadata.facade = it;
|
|
716
|
+
createNonEnumerableProperty$3(it, STATE, metadata);
|
|
717
|
+
return metadata;
|
|
718
|
+
};
|
|
719
|
+
get = function (it) {
|
|
720
|
+
return hasOwn$5(it, STATE) ? it[STATE] : {};
|
|
721
|
+
};
|
|
722
|
+
has = function (it) {
|
|
723
|
+
return hasOwn$5(it, STATE);
|
|
724
|
+
};
|
|
725
|
+
}
|
|
726
|
+
|
|
727
|
+
var internalState = {
|
|
728
|
+
set: set,
|
|
729
|
+
get: get,
|
|
730
|
+
has: has,
|
|
731
|
+
enforce: enforce,
|
|
732
|
+
getterFor: getterFor
|
|
733
|
+
};
|
|
734
|
+
|
|
735
|
+
var uncurryThis$5 = functionUncurryThis;
|
|
736
|
+
var fails$7 = fails$e;
|
|
737
|
+
var isCallable$6 = isCallable$e;
|
|
738
|
+
var hasOwn$4 = hasOwnProperty_1;
|
|
739
|
+
var DESCRIPTORS$3 = descriptors;
|
|
740
|
+
var CONFIGURABLE_FUNCTION_NAME$1 = functionName.CONFIGURABLE;
|
|
741
|
+
var inspectSource = inspectSource$1;
|
|
742
|
+
var InternalStateModule$1 = internalState;
|
|
743
|
+
|
|
744
|
+
var enforceInternalState = InternalStateModule$1.enforce;
|
|
745
|
+
var getInternalState$2 = InternalStateModule$1.get;
|
|
746
|
+
var $String$2 = String;
|
|
747
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
748
|
+
var defineProperty$4 = Object.defineProperty;
|
|
749
|
+
var stringSlice$1 = uncurryThis$5(''.slice);
|
|
750
|
+
var replace$1 = uncurryThis$5(''.replace);
|
|
751
|
+
var join = uncurryThis$5([].join);
|
|
752
|
+
|
|
753
|
+
var CONFIGURABLE_LENGTH = DESCRIPTORS$3 && !fails$7(function () {
|
|
754
|
+
return defineProperty$4(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
755
|
+
});
|
|
756
|
+
|
|
757
|
+
var TEMPLATE = String(String).split('String');
|
|
758
|
+
|
|
759
|
+
var makeBuiltIn$1 = makeBuiltIn$2.exports = function (value, name, options) {
|
|
760
|
+
if (stringSlice$1($String$2(name), 0, 7) === 'Symbol(') {
|
|
761
|
+
name = '[' + replace$1($String$2(name), /^Symbol\(([^)]*)\)/, '$1') + ']';
|
|
762
|
+
}
|
|
763
|
+
if (options && options.getter) name = 'get ' + name;
|
|
764
|
+
if (options && options.setter) name = 'set ' + name;
|
|
765
|
+
if (!hasOwn$4(value, 'name') || (CONFIGURABLE_FUNCTION_NAME$1 && value.name !== name)) {
|
|
766
|
+
if (DESCRIPTORS$3) defineProperty$4(value, 'name', { value: name, configurable: true });
|
|
767
|
+
else value.name = name;
|
|
768
|
+
}
|
|
769
|
+
if (CONFIGURABLE_LENGTH && options && hasOwn$4(options, 'arity') && value.length !== options.arity) {
|
|
770
|
+
defineProperty$4(value, 'length', { value: options.arity });
|
|
771
|
+
}
|
|
772
|
+
try {
|
|
773
|
+
if (options && hasOwn$4(options, 'constructor') && options.constructor) {
|
|
774
|
+
if (DESCRIPTORS$3) defineProperty$4(value, 'prototype', { writable: false });
|
|
775
|
+
// in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
776
|
+
} else if (value.prototype) value.prototype = undefined;
|
|
777
|
+
} catch (error) { /* empty */ }
|
|
778
|
+
var state = enforceInternalState(value);
|
|
779
|
+
if (!hasOwn$4(state, 'source')) {
|
|
780
|
+
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
781
|
+
} return value;
|
|
782
|
+
};
|
|
783
|
+
|
|
784
|
+
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
|
785
|
+
// eslint-disable-next-line no-extend-native -- required
|
|
786
|
+
Function.prototype.toString = makeBuiltIn$1(function toString() {
|
|
787
|
+
return isCallable$6(this) && getInternalState$2(this).source || inspectSource(this);
|
|
788
|
+
}, 'toString');
|
|
789
|
+
|
|
790
|
+
var isCallable$5 = isCallable$e;
|
|
791
|
+
var definePropertyModule$2 = objectDefineProperty;
|
|
792
|
+
var makeBuiltIn = makeBuiltIn$2.exports;
|
|
793
|
+
var defineGlobalProperty$1 = defineGlobalProperty$3;
|
|
794
|
+
|
|
795
|
+
var defineBuiltIn$3 = function (O, key, value, options) {
|
|
796
|
+
if (!options) options = {};
|
|
797
|
+
var simple = options.enumerable;
|
|
798
|
+
var name = options.name !== undefined ? options.name : key;
|
|
799
|
+
if (isCallable$5(value)) makeBuiltIn(value, name, options);
|
|
800
|
+
if (options.global) {
|
|
801
|
+
if (simple) O[key] = value;
|
|
802
|
+
else defineGlobalProperty$1(key, value);
|
|
803
|
+
} else {
|
|
804
|
+
try {
|
|
805
|
+
if (!options.unsafe) delete O[key];
|
|
806
|
+
else if (O[key]) simple = true;
|
|
807
|
+
} catch (error) { /* empty */ }
|
|
808
|
+
if (simple) O[key] = value;
|
|
809
|
+
else definePropertyModule$2.f(O, key, {
|
|
810
|
+
value: value,
|
|
811
|
+
enumerable: false,
|
|
812
|
+
configurable: !options.nonConfigurable,
|
|
813
|
+
writable: !options.nonWritable
|
|
814
|
+
});
|
|
815
|
+
} return O;
|
|
816
|
+
};
|
|
817
|
+
|
|
818
|
+
var objectGetOwnPropertyNames = {};
|
|
819
|
+
|
|
820
|
+
var ceil = Math.ceil;
|
|
821
|
+
var floor = Math.floor;
|
|
822
|
+
|
|
823
|
+
// `Math.trunc` method
|
|
824
|
+
// https://tc39.es/ecma262/#sec-math.trunc
|
|
825
|
+
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
826
|
+
var mathTrunc = Math.trunc || function trunc(x) {
|
|
827
|
+
var n = +x;
|
|
828
|
+
return (n > 0 ? floor : ceil)(n);
|
|
829
|
+
};
|
|
830
|
+
|
|
831
|
+
var trunc = mathTrunc;
|
|
832
|
+
|
|
833
|
+
// `ToIntegerOrInfinity` abstract operation
|
|
834
|
+
// https://tc39.es/ecma262/#sec-tointegerorinfinity
|
|
835
|
+
var toIntegerOrInfinity$2 = function (argument) {
|
|
836
|
+
var number = +argument;
|
|
837
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
838
|
+
return number !== number || number === 0 ? 0 : trunc(number);
|
|
839
|
+
};
|
|
840
|
+
|
|
841
|
+
var toIntegerOrInfinity$1 = toIntegerOrInfinity$2;
|
|
842
|
+
|
|
843
|
+
var max = Math.max;
|
|
844
|
+
var min$1 = Math.min;
|
|
845
|
+
|
|
846
|
+
// Helper for a popular repeating case of the spec:
|
|
847
|
+
// Let integer be ? ToInteger(index).
|
|
848
|
+
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
|
849
|
+
var toAbsoluteIndex$1 = function (index, length) {
|
|
850
|
+
var integer = toIntegerOrInfinity$1(index);
|
|
851
|
+
return integer < 0 ? max(integer + length, 0) : min$1(integer, length);
|
|
852
|
+
};
|
|
853
|
+
|
|
854
|
+
var toIntegerOrInfinity = toIntegerOrInfinity$2;
|
|
855
|
+
|
|
856
|
+
var min = Math.min;
|
|
857
|
+
|
|
858
|
+
// `ToLength` abstract operation
|
|
859
|
+
// https://tc39.es/ecma262/#sec-tolength
|
|
860
|
+
var toLength$1 = function (argument) {
|
|
861
|
+
return argument > 0 ? min(toIntegerOrInfinity(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
|
|
862
|
+
};
|
|
863
|
+
|
|
864
|
+
var toLength = toLength$1;
|
|
865
|
+
|
|
866
|
+
// `LengthOfArrayLike` abstract operation
|
|
867
|
+
// https://tc39.es/ecma262/#sec-lengthofarraylike
|
|
868
|
+
var lengthOfArrayLike$1 = function (obj) {
|
|
869
|
+
return toLength(obj.length);
|
|
870
|
+
};
|
|
871
|
+
|
|
872
|
+
var toIndexedObject$3 = toIndexedObject$5;
|
|
873
|
+
var toAbsoluteIndex = toAbsoluteIndex$1;
|
|
874
|
+
var lengthOfArrayLike = lengthOfArrayLike$1;
|
|
875
|
+
|
|
876
|
+
// `Array.prototype.{ indexOf, includes }` methods implementation
|
|
877
|
+
var createMethod = function (IS_INCLUDES) {
|
|
878
|
+
return function ($this, el, fromIndex) {
|
|
879
|
+
var O = toIndexedObject$3($this);
|
|
880
|
+
var length = lengthOfArrayLike(O);
|
|
881
|
+
var index = toAbsoluteIndex(fromIndex, length);
|
|
882
|
+
var value;
|
|
883
|
+
// Array#includes uses SameValueZero equality algorithm
|
|
884
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
885
|
+
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
886
|
+
value = O[index++];
|
|
887
|
+
// eslint-disable-next-line no-self-compare -- NaN check
|
|
888
|
+
if (value !== value) return true;
|
|
889
|
+
// Array#indexOf ignores holes, Array#includes - not
|
|
890
|
+
} else for (;length > index; index++) {
|
|
891
|
+
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
892
|
+
} return !IS_INCLUDES && -1;
|
|
893
|
+
};
|
|
894
|
+
};
|
|
895
|
+
|
|
896
|
+
var arrayIncludes = {
|
|
897
|
+
// `Array.prototype.includes` method
|
|
898
|
+
// https://tc39.es/ecma262/#sec-array.prototype.includes
|
|
899
|
+
includes: createMethod(true),
|
|
900
|
+
// `Array.prototype.indexOf` method
|
|
901
|
+
// https://tc39.es/ecma262/#sec-array.prototype.indexof
|
|
902
|
+
indexOf: createMethod(false)
|
|
903
|
+
};
|
|
904
|
+
|
|
905
|
+
var uncurryThis$4 = functionUncurryThis;
|
|
906
|
+
var hasOwn$3 = hasOwnProperty_1;
|
|
907
|
+
var toIndexedObject$2 = toIndexedObject$5;
|
|
908
|
+
var indexOf$1 = arrayIncludes.indexOf;
|
|
909
|
+
var hiddenKeys$2 = hiddenKeys$4;
|
|
910
|
+
|
|
911
|
+
var push = uncurryThis$4([].push);
|
|
912
|
+
|
|
913
|
+
var objectKeysInternal = function (object, names) {
|
|
914
|
+
var O = toIndexedObject$2(object);
|
|
915
|
+
var i = 0;
|
|
916
|
+
var result = [];
|
|
917
|
+
var key;
|
|
918
|
+
for (key in O) !hasOwn$3(hiddenKeys$2, key) && hasOwn$3(O, key) && push(result, key);
|
|
919
|
+
// Don't enum bug & hidden keys
|
|
920
|
+
while (names.length > i) if (hasOwn$3(O, key = names[i++])) {
|
|
921
|
+
~indexOf$1(result, key) || push(result, key);
|
|
922
|
+
}
|
|
923
|
+
return result;
|
|
924
|
+
};
|
|
925
|
+
|
|
926
|
+
// IE8- don't enum bug keys
|
|
927
|
+
var enumBugKeys$3 = [
|
|
928
|
+
'constructor',
|
|
929
|
+
'hasOwnProperty',
|
|
930
|
+
'isPrototypeOf',
|
|
931
|
+
'propertyIsEnumerable',
|
|
932
|
+
'toLocaleString',
|
|
933
|
+
'toString',
|
|
934
|
+
'valueOf'
|
|
935
|
+
];
|
|
936
|
+
|
|
937
|
+
var internalObjectKeys$1 = objectKeysInternal;
|
|
938
|
+
var enumBugKeys$2 = enumBugKeys$3;
|
|
939
|
+
|
|
940
|
+
var hiddenKeys$1 = enumBugKeys$2.concat('length', 'prototype');
|
|
941
|
+
|
|
942
|
+
// `Object.getOwnPropertyNames` method
|
|
943
|
+
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
944
|
+
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
945
|
+
objectGetOwnPropertyNames.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
946
|
+
return internalObjectKeys$1(O, hiddenKeys$1);
|
|
947
|
+
};
|
|
948
|
+
|
|
949
|
+
var objectGetOwnPropertySymbols = {};
|
|
950
|
+
|
|
951
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
952
|
+
objectGetOwnPropertySymbols.f = Object.getOwnPropertySymbols;
|
|
953
|
+
|
|
954
|
+
var getBuiltIn$1 = getBuiltIn$3;
|
|
955
|
+
var uncurryThis$3 = functionUncurryThis;
|
|
956
|
+
var getOwnPropertyNamesModule = objectGetOwnPropertyNames;
|
|
957
|
+
var getOwnPropertySymbolsModule$1 = objectGetOwnPropertySymbols;
|
|
958
|
+
var anObject$4 = anObject$6;
|
|
959
|
+
|
|
960
|
+
var concat$1 = uncurryThis$3([].concat);
|
|
961
|
+
|
|
962
|
+
// all object keys, includes non-enumerable and symbols
|
|
963
|
+
var ownKeys$1 = getBuiltIn$1('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
964
|
+
var keys = getOwnPropertyNamesModule.f(anObject$4(it));
|
|
965
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule$1.f;
|
|
966
|
+
return getOwnPropertySymbols ? concat$1(keys, getOwnPropertySymbols(it)) : keys;
|
|
967
|
+
};
|
|
968
|
+
|
|
969
|
+
var hasOwn$2 = hasOwnProperty_1;
|
|
970
|
+
var ownKeys = ownKeys$1;
|
|
971
|
+
var getOwnPropertyDescriptorModule = objectGetOwnPropertyDescriptor;
|
|
972
|
+
var definePropertyModule$1 = objectDefineProperty;
|
|
973
|
+
|
|
974
|
+
var copyConstructorProperties$1 = function (target, source, exceptions) {
|
|
975
|
+
var keys = ownKeys(source);
|
|
976
|
+
var defineProperty = definePropertyModule$1.f;
|
|
977
|
+
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
|
978
|
+
for (var i = 0; i < keys.length; i++) {
|
|
979
|
+
var key = keys[i];
|
|
980
|
+
if (!hasOwn$2(target, key) && !(exceptions && hasOwn$2(exceptions, key))) {
|
|
981
|
+
defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
|
982
|
+
}
|
|
983
|
+
}
|
|
984
|
+
};
|
|
985
|
+
|
|
986
|
+
var fails$6 = fails$e;
|
|
987
|
+
var isCallable$4 = isCallable$e;
|
|
988
|
+
|
|
989
|
+
var replacement = /#|\.prototype\./;
|
|
990
|
+
|
|
991
|
+
var isForced$1 = function (feature, detection) {
|
|
992
|
+
var value = data[normalize(feature)];
|
|
993
|
+
return value === POLYFILL ? true
|
|
994
|
+
: value === NATIVE ? false
|
|
995
|
+
: isCallable$4(detection) ? fails$6(detection)
|
|
996
|
+
: !!detection;
|
|
997
|
+
};
|
|
998
|
+
|
|
999
|
+
var normalize = isForced$1.normalize = function (string) {
|
|
1000
|
+
return String(string).replace(replacement, '.').toLowerCase();
|
|
1001
|
+
};
|
|
1002
|
+
|
|
1003
|
+
var data = isForced$1.data = {};
|
|
1004
|
+
var NATIVE = isForced$1.NATIVE = 'N';
|
|
1005
|
+
var POLYFILL = isForced$1.POLYFILL = 'P';
|
|
1006
|
+
|
|
1007
|
+
var isForced_1 = isForced$1;
|
|
1008
|
+
|
|
1009
|
+
var global$5 = global$f;
|
|
1010
|
+
var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
|
|
1011
|
+
var createNonEnumerableProperty$2 = createNonEnumerableProperty$4;
|
|
1012
|
+
var defineBuiltIn$2 = defineBuiltIn$3;
|
|
1013
|
+
var defineGlobalProperty = defineGlobalProperty$3;
|
|
1014
|
+
var copyConstructorProperties = copyConstructorProperties$1;
|
|
1015
|
+
var isForced = isForced_1;
|
|
1016
|
+
|
|
1017
|
+
/*
|
|
1018
|
+
options.target - name of the target object
|
|
1019
|
+
options.global - target is the global object
|
|
1020
|
+
options.stat - export as static methods of target
|
|
1021
|
+
options.proto - export as prototype methods of target
|
|
1022
|
+
options.real - real prototype method for the `pure` version
|
|
1023
|
+
options.forced - export even if the native feature is available
|
|
1024
|
+
options.bind - bind methods to the target, required for the `pure` version
|
|
1025
|
+
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
|
1026
|
+
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
|
1027
|
+
options.sham - add a flag to not completely full polyfills
|
|
1028
|
+
options.enumerable - export as enumerable property
|
|
1029
|
+
options.dontCallGetSet - prevent calling a getter on target
|
|
1030
|
+
options.name - the .name of the function if it does not match the key
|
|
1031
|
+
*/
|
|
1032
|
+
var _export = function (options, source) {
|
|
1033
|
+
var TARGET = options.target;
|
|
1034
|
+
var GLOBAL = options.global;
|
|
1035
|
+
var STATIC = options.stat;
|
|
1036
|
+
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
1037
|
+
if (GLOBAL) {
|
|
1038
|
+
target = global$5;
|
|
1039
|
+
} else if (STATIC) {
|
|
1040
|
+
target = global$5[TARGET] || defineGlobalProperty(TARGET, {});
|
|
1041
|
+
} else {
|
|
1042
|
+
target = (global$5[TARGET] || {}).prototype;
|
|
1043
|
+
}
|
|
1044
|
+
if (target) for (key in source) {
|
|
1045
|
+
sourceProperty = source[key];
|
|
1046
|
+
if (options.dontCallGetSet) {
|
|
1047
|
+
descriptor = getOwnPropertyDescriptor(target, key);
|
|
1048
|
+
targetProperty = descriptor && descriptor.value;
|
|
1049
|
+
} else targetProperty = target[key];
|
|
1050
|
+
FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
1051
|
+
// contained in target
|
|
1052
|
+
if (!FORCED && targetProperty !== undefined) {
|
|
1053
|
+
if (typeof sourceProperty == typeof targetProperty) continue;
|
|
1054
|
+
copyConstructorProperties(sourceProperty, targetProperty);
|
|
1055
|
+
}
|
|
1056
|
+
// add a flag to not completely full polyfills
|
|
1057
|
+
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
1058
|
+
createNonEnumerableProperty$2(sourceProperty, 'sham', true);
|
|
1059
|
+
}
|
|
1060
|
+
defineBuiltIn$2(target, key, sourceProperty, options);
|
|
1061
|
+
}
|
|
1062
|
+
};
|
|
1063
|
+
|
|
1064
|
+
var wellKnownSymbol$6 = wellKnownSymbol$8;
|
|
1065
|
+
|
|
1066
|
+
var TO_STRING_TAG$2 = wellKnownSymbol$6('toStringTag');
|
|
1067
|
+
var test = {};
|
|
1068
|
+
|
|
1069
|
+
test[TO_STRING_TAG$2] = 'z';
|
|
1070
|
+
|
|
1071
|
+
var toStringTagSupport = String(test) === '[object z]';
|
|
1072
|
+
|
|
1073
|
+
var TO_STRING_TAG_SUPPORT = toStringTagSupport;
|
|
1074
|
+
var isCallable$3 = isCallable$e;
|
|
1075
|
+
var classofRaw = classofRaw$1;
|
|
1076
|
+
var wellKnownSymbol$5 = wellKnownSymbol$8;
|
|
1077
|
+
|
|
1078
|
+
var TO_STRING_TAG$1 = wellKnownSymbol$5('toStringTag');
|
|
1079
|
+
var $Object$1 = Object;
|
|
1080
|
+
|
|
1081
|
+
// ES3 wrong here
|
|
1082
|
+
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
|
|
1083
|
+
|
|
1084
|
+
// fallback for IE11 Script Access Denied error
|
|
1085
|
+
var tryGet = function (it, key) {
|
|
1086
|
+
try {
|
|
1087
|
+
return it[key];
|
|
1088
|
+
} catch (error) { /* empty */ }
|
|
1089
|
+
};
|
|
1090
|
+
|
|
1091
|
+
// getting tag from ES6+ `Object.prototype.toString`
|
|
1092
|
+
var classof$1 = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
|
|
1093
|
+
var O, tag, result;
|
|
1094
|
+
return it === undefined ? 'Undefined' : it === null ? 'Null'
|
|
1095
|
+
// @@toStringTag case
|
|
1096
|
+
: typeof (tag = tryGet(O = $Object$1(it), TO_STRING_TAG$1)) == 'string' ? tag
|
|
1097
|
+
// builtinTag case
|
|
1098
|
+
: CORRECT_ARGUMENTS ? classofRaw(O)
|
|
1099
|
+
// ES3 arguments fallback
|
|
1100
|
+
: (result = classofRaw(O)) === 'Object' && isCallable$3(O.callee) ? 'Arguments' : result;
|
|
1101
|
+
};
|
|
1102
|
+
|
|
1103
|
+
var classof = classof$1;
|
|
1104
|
+
|
|
1105
|
+
var $String$1 = String;
|
|
1106
|
+
|
|
1107
|
+
var toString$1 = function (argument) {
|
|
1108
|
+
if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
|
|
1109
|
+
return $String$1(argument);
|
|
1110
|
+
};
|
|
1111
|
+
|
|
1112
|
+
var anObject$3 = anObject$6;
|
|
1113
|
+
|
|
1114
|
+
// `RegExp.prototype.flags` getter implementation
|
|
1115
|
+
// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
|
|
1116
|
+
var regexpFlags$1 = function () {
|
|
1117
|
+
var that = anObject$3(this);
|
|
1118
|
+
var result = '';
|
|
1119
|
+
if (that.hasIndices) result += 'd';
|
|
1120
|
+
if (that.global) result += 'g';
|
|
1121
|
+
if (that.ignoreCase) result += 'i';
|
|
1122
|
+
if (that.multiline) result += 'm';
|
|
1123
|
+
if (that.dotAll) result += 's';
|
|
1124
|
+
if (that.unicode) result += 'u';
|
|
1125
|
+
if (that.unicodeSets) result += 'v';
|
|
1126
|
+
if (that.sticky) result += 'y';
|
|
1127
|
+
return result;
|
|
1128
|
+
};
|
|
1129
|
+
|
|
1130
|
+
var fails$5 = fails$e;
|
|
1131
|
+
var global$4 = global$f;
|
|
1132
|
+
|
|
1133
|
+
// babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
|
|
1134
|
+
var $RegExp$2 = global$4.RegExp;
|
|
1135
|
+
|
|
1136
|
+
var UNSUPPORTED_Y$1 = fails$5(function () {
|
|
1137
|
+
var re = $RegExp$2('a', 'y');
|
|
1138
|
+
re.lastIndex = 2;
|
|
1139
|
+
return re.exec('abcd') !== null;
|
|
1140
|
+
});
|
|
1141
|
+
|
|
1142
|
+
// UC Browser bug
|
|
1143
|
+
// https://github.com/zloirock/core-js/issues/1008
|
|
1144
|
+
var MISSED_STICKY = UNSUPPORTED_Y$1 || fails$5(function () {
|
|
1145
|
+
return !$RegExp$2('a', 'y').sticky;
|
|
1146
|
+
});
|
|
1147
|
+
|
|
1148
|
+
var BROKEN_CARET = UNSUPPORTED_Y$1 || fails$5(function () {
|
|
1149
|
+
// https://bugzilla.mozilla.org/show_bug.cgi?id=773687
|
|
1150
|
+
var re = $RegExp$2('^r', 'gy');
|
|
1151
|
+
re.lastIndex = 2;
|
|
1152
|
+
return re.exec('str') !== null;
|
|
1153
|
+
});
|
|
1154
|
+
|
|
1155
|
+
var regexpStickyHelpers = {
|
|
1156
|
+
BROKEN_CARET: BROKEN_CARET,
|
|
1157
|
+
MISSED_STICKY: MISSED_STICKY,
|
|
1158
|
+
UNSUPPORTED_Y: UNSUPPORTED_Y$1
|
|
1159
|
+
};
|
|
1160
|
+
|
|
1161
|
+
var objectDefineProperties = {};
|
|
1162
|
+
|
|
1163
|
+
var internalObjectKeys = objectKeysInternal;
|
|
1164
|
+
var enumBugKeys$1 = enumBugKeys$3;
|
|
1165
|
+
|
|
1166
|
+
// `Object.keys` method
|
|
1167
|
+
// https://tc39.es/ecma262/#sec-object.keys
|
|
1168
|
+
// eslint-disable-next-line es/no-object-keys -- safe
|
|
1169
|
+
var objectKeys$2 = Object.keys || function keys(O) {
|
|
1170
|
+
return internalObjectKeys(O, enumBugKeys$1);
|
|
1171
|
+
};
|
|
1172
|
+
|
|
1173
|
+
var DESCRIPTORS$2 = descriptors;
|
|
1174
|
+
var V8_PROTOTYPE_DEFINE_BUG = v8PrototypeDefineBug;
|
|
1175
|
+
var definePropertyModule = objectDefineProperty;
|
|
1176
|
+
var anObject$2 = anObject$6;
|
|
1177
|
+
var toIndexedObject$1 = toIndexedObject$5;
|
|
1178
|
+
var objectKeys$1 = objectKeys$2;
|
|
1179
|
+
|
|
1180
|
+
// `Object.defineProperties` method
|
|
1181
|
+
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
1182
|
+
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
1183
|
+
objectDefineProperties.f = DESCRIPTORS$2 && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
1184
|
+
anObject$2(O);
|
|
1185
|
+
var props = toIndexedObject$1(Properties);
|
|
1186
|
+
var keys = objectKeys$1(Properties);
|
|
1187
|
+
var length = keys.length;
|
|
1188
|
+
var index = 0;
|
|
1189
|
+
var key;
|
|
1190
|
+
while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
|
|
1191
|
+
return O;
|
|
1192
|
+
};
|
|
1193
|
+
|
|
1194
|
+
var getBuiltIn = getBuiltIn$3;
|
|
1195
|
+
|
|
1196
|
+
var html$1 = getBuiltIn('document', 'documentElement');
|
|
1197
|
+
|
|
1198
|
+
/* global ActiveXObject -- old IE, WSH */
|
|
1199
|
+
var anObject$1 = anObject$6;
|
|
1200
|
+
var definePropertiesModule = objectDefineProperties;
|
|
1201
|
+
var enumBugKeys = enumBugKeys$3;
|
|
1202
|
+
var hiddenKeys = hiddenKeys$4;
|
|
1203
|
+
var html = html$1;
|
|
1204
|
+
var documentCreateElement$1 = documentCreateElement$2;
|
|
1205
|
+
var sharedKey$1 = sharedKey$3;
|
|
1206
|
+
|
|
1207
|
+
var GT = '>';
|
|
1208
|
+
var LT = '<';
|
|
1209
|
+
var PROTOTYPE = 'prototype';
|
|
1210
|
+
var SCRIPT = 'script';
|
|
1211
|
+
var IE_PROTO$1 = sharedKey$1('IE_PROTO');
|
|
1212
|
+
|
|
1213
|
+
var EmptyConstructor = function () { /* empty */ };
|
|
1214
|
+
|
|
1215
|
+
var scriptTag = function (content) {
|
|
1216
|
+
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
1217
|
+
};
|
|
1218
|
+
|
|
1219
|
+
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
1220
|
+
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
1221
|
+
activeXDocument.write(scriptTag(''));
|
|
1222
|
+
activeXDocument.close();
|
|
1223
|
+
var temp = activeXDocument.parentWindow.Object;
|
|
1224
|
+
activeXDocument = null; // avoid memory leak
|
|
1225
|
+
return temp;
|
|
1226
|
+
};
|
|
1227
|
+
|
|
1228
|
+
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
1229
|
+
var NullProtoObjectViaIFrame = function () {
|
|
1230
|
+
// Thrash, waste and sodomy: IE GC bug
|
|
1231
|
+
var iframe = documentCreateElement$1('iframe');
|
|
1232
|
+
var JS = 'java' + SCRIPT + ':';
|
|
1233
|
+
var iframeDocument;
|
|
1234
|
+
iframe.style.display = 'none';
|
|
1235
|
+
html.appendChild(iframe);
|
|
1236
|
+
// https://github.com/zloirock/core-js/issues/475
|
|
1237
|
+
iframe.src = String(JS);
|
|
1238
|
+
iframeDocument = iframe.contentWindow.document;
|
|
1239
|
+
iframeDocument.open();
|
|
1240
|
+
iframeDocument.write(scriptTag('document.F=Object'));
|
|
1241
|
+
iframeDocument.close();
|
|
1242
|
+
return iframeDocument.F;
|
|
1243
|
+
};
|
|
1244
|
+
|
|
1245
|
+
// Check for document.domain and active x support
|
|
1246
|
+
// No need to use active x approach when document.domain is not set
|
|
1247
|
+
// see https://github.com/es-shims/es5-shim/issues/150
|
|
1248
|
+
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
1249
|
+
// avoid IE GC bug
|
|
1250
|
+
var activeXDocument;
|
|
1251
|
+
var NullProtoObject = function () {
|
|
1252
|
+
try {
|
|
1253
|
+
activeXDocument = new ActiveXObject('htmlfile');
|
|
1254
|
+
} catch (error) { /* ignore */ }
|
|
1255
|
+
NullProtoObject = typeof document != 'undefined'
|
|
1256
|
+
? document.domain && activeXDocument
|
|
1257
|
+
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
1258
|
+
: NullProtoObjectViaIFrame()
|
|
1259
|
+
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
1260
|
+
var length = enumBugKeys.length;
|
|
1261
|
+
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
|
1262
|
+
return NullProtoObject();
|
|
1263
|
+
};
|
|
1264
|
+
|
|
1265
|
+
hiddenKeys[IE_PROTO$1] = true;
|
|
1266
|
+
|
|
1267
|
+
// `Object.create` method
|
|
1268
|
+
// https://tc39.es/ecma262/#sec-object.create
|
|
1269
|
+
// eslint-disable-next-line es/no-object-create -- safe
|
|
1270
|
+
var objectCreate = Object.create || function create(O, Properties) {
|
|
1271
|
+
var result;
|
|
1272
|
+
if (O !== null) {
|
|
1273
|
+
EmptyConstructor[PROTOTYPE] = anObject$1(O);
|
|
1274
|
+
result = new EmptyConstructor();
|
|
1275
|
+
EmptyConstructor[PROTOTYPE] = null;
|
|
1276
|
+
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
1277
|
+
result[IE_PROTO$1] = O;
|
|
1278
|
+
} else result = NullProtoObject();
|
|
1279
|
+
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
1280
|
+
};
|
|
1281
|
+
|
|
1282
|
+
var fails$4 = fails$e;
|
|
1283
|
+
var global$3 = global$f;
|
|
1284
|
+
|
|
1285
|
+
// babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError
|
|
1286
|
+
var $RegExp$1 = global$3.RegExp;
|
|
1287
|
+
|
|
1288
|
+
var regexpUnsupportedDotAll = fails$4(function () {
|
|
1289
|
+
var re = $RegExp$1('.', 's');
|
|
1290
|
+
return !(re.dotAll && re.test('\n') && re.flags === 's');
|
|
1291
|
+
});
|
|
1292
|
+
|
|
1293
|
+
var fails$3 = fails$e;
|
|
1294
|
+
var global$2 = global$f;
|
|
1295
|
+
|
|
1296
|
+
// babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError
|
|
1297
|
+
var $RegExp = global$2.RegExp;
|
|
1298
|
+
|
|
1299
|
+
var regexpUnsupportedNcg = fails$3(function () {
|
|
1300
|
+
var re = $RegExp('(?<a>b)', 'g');
|
|
1301
|
+
return re.exec('b').groups.a !== 'b' ||
|
|
1302
|
+
'b'.replace(re, '$<a>c') !== 'bc';
|
|
1303
|
+
});
|
|
1304
|
+
|
|
1305
|
+
/* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */
|
|
1306
|
+
/* eslint-disable regexp/no-useless-quantifier -- testing */
|
|
1307
|
+
var call$2 = functionCall;
|
|
1308
|
+
var uncurryThis$2 = functionUncurryThis;
|
|
1309
|
+
var toString = toString$1;
|
|
1310
|
+
var regexpFlags = regexpFlags$1;
|
|
1311
|
+
var stickyHelpers = regexpStickyHelpers;
|
|
1312
|
+
var shared = shared$4.exports;
|
|
1313
|
+
var create$2 = objectCreate;
|
|
1314
|
+
var getInternalState$1 = internalState.get;
|
|
1315
|
+
var UNSUPPORTED_DOT_ALL = regexpUnsupportedDotAll;
|
|
1316
|
+
var UNSUPPORTED_NCG = regexpUnsupportedNcg;
|
|
1317
|
+
|
|
1318
|
+
var nativeReplace = shared('native-string-replace', String.prototype.replace);
|
|
1319
|
+
var nativeExec = RegExp.prototype.exec;
|
|
1320
|
+
var patchedExec = nativeExec;
|
|
1321
|
+
var charAt = uncurryThis$2(''.charAt);
|
|
1322
|
+
var indexOf = uncurryThis$2(''.indexOf);
|
|
1323
|
+
var replace = uncurryThis$2(''.replace);
|
|
1324
|
+
var stringSlice = uncurryThis$2(''.slice);
|
|
1325
|
+
|
|
1326
|
+
var UPDATES_LAST_INDEX_WRONG = (function () {
|
|
1327
|
+
var re1 = /a/;
|
|
1328
|
+
var re2 = /b*/g;
|
|
1329
|
+
call$2(nativeExec, re1, 'a');
|
|
1330
|
+
call$2(nativeExec, re2, 'a');
|
|
1331
|
+
return re1.lastIndex !== 0 || re2.lastIndex !== 0;
|
|
1332
|
+
})();
|
|
1333
|
+
|
|
1334
|
+
var UNSUPPORTED_Y = stickyHelpers.BROKEN_CARET;
|
|
1335
|
+
|
|
1336
|
+
// nonparticipating capturing group, copied from es5-shim's String#split patch.
|
|
1337
|
+
var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;
|
|
1338
|
+
|
|
1339
|
+
var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;
|
|
1340
|
+
|
|
1341
|
+
if (PATCH) {
|
|
1342
|
+
patchedExec = function exec(string) {
|
|
1343
|
+
var re = this;
|
|
1344
|
+
var state = getInternalState$1(re);
|
|
1345
|
+
var str = toString(string);
|
|
1346
|
+
var raw = state.raw;
|
|
1347
|
+
var result, reCopy, lastIndex, match, i, object, group;
|
|
1348
|
+
|
|
1349
|
+
if (raw) {
|
|
1350
|
+
raw.lastIndex = re.lastIndex;
|
|
1351
|
+
result = call$2(patchedExec, raw, str);
|
|
1352
|
+
re.lastIndex = raw.lastIndex;
|
|
1353
|
+
return result;
|
|
1354
|
+
}
|
|
1355
|
+
|
|
1356
|
+
var groups = state.groups;
|
|
1357
|
+
var sticky = UNSUPPORTED_Y && re.sticky;
|
|
1358
|
+
var flags = call$2(regexpFlags, re);
|
|
1359
|
+
var source = re.source;
|
|
1360
|
+
var charsAdded = 0;
|
|
1361
|
+
var strCopy = str;
|
|
1362
|
+
|
|
1363
|
+
if (sticky) {
|
|
1364
|
+
flags = replace(flags, 'y', '');
|
|
1365
|
+
if (indexOf(flags, 'g') === -1) {
|
|
1366
|
+
flags += 'g';
|
|
1367
|
+
}
|
|
1368
|
+
|
|
1369
|
+
strCopy = stringSlice(str, re.lastIndex);
|
|
1370
|
+
// Support anchored sticky behavior.
|
|
1371
|
+
if (re.lastIndex > 0 && (!re.multiline || re.multiline && charAt(str, re.lastIndex - 1) !== '\n')) {
|
|
1372
|
+
source = '(?: ' + source + ')';
|
|
1373
|
+
strCopy = ' ' + strCopy;
|
|
1374
|
+
charsAdded++;
|
|
1375
|
+
}
|
|
1376
|
+
// ^(? + rx + ) is needed, in combination with some str slicing, to
|
|
1377
|
+
// simulate the 'y' flag.
|
|
1378
|
+
reCopy = new RegExp('^(?:' + source + ')', flags);
|
|
1379
|
+
}
|
|
1380
|
+
|
|
1381
|
+
if (NPCG_INCLUDED) {
|
|
1382
|
+
reCopy = new RegExp('^' + source + '$(?!\\s)', flags);
|
|
1383
|
+
}
|
|
1384
|
+
if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;
|
|
1385
|
+
|
|
1386
|
+
match = call$2(nativeExec, sticky ? reCopy : re, strCopy);
|
|
1387
|
+
|
|
1388
|
+
if (sticky) {
|
|
1389
|
+
if (match) {
|
|
1390
|
+
match.input = stringSlice(match.input, charsAdded);
|
|
1391
|
+
match[0] = stringSlice(match[0], charsAdded);
|
|
1392
|
+
match.index = re.lastIndex;
|
|
1393
|
+
re.lastIndex += match[0].length;
|
|
1394
|
+
} else re.lastIndex = 0;
|
|
1395
|
+
} else if (UPDATES_LAST_INDEX_WRONG && match) {
|
|
1396
|
+
re.lastIndex = re.global ? match.index + match[0].length : lastIndex;
|
|
1397
|
+
}
|
|
1398
|
+
if (NPCG_INCLUDED && match && match.length > 1) {
|
|
1399
|
+
// Fix browsers whose `exec` methods don't consistently return `undefined`
|
|
1400
|
+
// for NPCG, like IE8. NOTE: This doesn't work for /(.?)?/
|
|
1401
|
+
call$2(nativeReplace, match[0], reCopy, function () {
|
|
1402
|
+
for (i = 1; i < arguments.length - 2; i++) {
|
|
1403
|
+
if (arguments[i] === undefined) match[i] = undefined;
|
|
1404
|
+
}
|
|
1405
|
+
});
|
|
1406
|
+
}
|
|
1407
|
+
|
|
1408
|
+
if (match && groups) {
|
|
1409
|
+
match.groups = object = create$2(null);
|
|
1410
|
+
for (i = 0; i < groups.length; i++) {
|
|
1411
|
+
group = groups[i];
|
|
1412
|
+
object[group[0]] = match[group[1]];
|
|
1413
|
+
}
|
|
1414
|
+
}
|
|
1415
|
+
|
|
1416
|
+
return match;
|
|
1417
|
+
};
|
|
1418
|
+
}
|
|
1419
|
+
|
|
1420
|
+
var regexpExec = patchedExec;
|
|
1421
|
+
|
|
1422
|
+
var $$2 = _export;
|
|
1423
|
+
var exec = regexpExec;
|
|
1424
|
+
|
|
1425
|
+
// `RegExp.prototype.exec` method
|
|
1426
|
+
// https://tc39.es/ecma262/#sec-regexp.prototype.exec
|
|
1427
|
+
$$2({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {
|
|
1428
|
+
exec: exec
|
|
1429
|
+
});
|
|
1430
|
+
|
|
1431
|
+
const UNKNOWN_WEBSITE_LINK_TYPE = 'u';
|
|
1432
|
+
/**
|
|
1433
|
+
* Max length of WebsiteLink's data type.
|
|
1434
|
+
*/
|
|
1435
|
+
const WEBSITE_LINK_TYPE_MAX_LENGTH = 32;
|
|
1436
|
+
/**
|
|
1437
|
+
* Alpha-numeric type between 1 and 32 characters only allowed.
|
|
1438
|
+
*/
|
|
1439
|
+
const WEBSITE_LINK_TYPE_REGEX = /^[a-zA-Z0-9]{1,32}$/;
|
|
1440
|
+
function isValidWebsiteLinkType(input) {
|
|
1441
|
+
return WEBSITE_LINK_TYPE_REGEX.test(input);
|
|
1442
|
+
}
|
|
1443
|
+
/**
|
|
1444
|
+
* Default max length of WebsiteLink's data string.
|
|
1445
|
+
*/
|
|
1446
|
+
const WEBSITE_LINK_ENCODED_DATA_MAX_LENGTH = 1000;
|
|
1447
|
+
class WebsiteLink {
|
|
1448
|
+
constructor(template) {
|
|
1449
|
+
if (template != null) {
|
|
1450
|
+
this.t = template.t;
|
|
1451
|
+
this.d = template.d;
|
|
1452
|
+
}
|
|
1453
|
+
}
|
|
1454
|
+
}
|
|
1455
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.Matches(WEBSITE_LINK_TYPE_REGEX), classValidator.MaxLength(WEBSITE_LINK_TYPE_MAX_LENGTH), __metadata("design:type", String)], WebsiteLink.prototype, "t", void 0);
|
|
1456
|
+
__decorate([classTransformer.Expose(), classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.MaxLength(WEBSITE_LINK_ENCODED_DATA_MAX_LENGTH), __metadata("design:type", String)], WebsiteLink.prototype, "d", void 0);
|
|
1457
|
+
|
|
1458
|
+
var wellKnownSymbol$4 = wellKnownSymbol$8;
|
|
1459
|
+
var create$1 = objectCreate;
|
|
1460
|
+
var defineProperty$3 = objectDefineProperty.f;
|
|
1461
|
+
|
|
1462
|
+
var UNSCOPABLES = wellKnownSymbol$4('unscopables');
|
|
1463
|
+
var ArrayPrototype = Array.prototype;
|
|
1464
|
+
|
|
1465
|
+
// Array.prototype[@@unscopables]
|
|
1466
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
1467
|
+
if (ArrayPrototype[UNSCOPABLES] === undefined) {
|
|
1468
|
+
defineProperty$3(ArrayPrototype, UNSCOPABLES, {
|
|
1469
|
+
configurable: true,
|
|
1470
|
+
value: create$1(null)
|
|
1471
|
+
});
|
|
1472
|
+
}
|
|
1473
|
+
|
|
1474
|
+
// add a key to Array.prototype[@@unscopables]
|
|
1475
|
+
var addToUnscopables$1 = function (key) {
|
|
1476
|
+
ArrayPrototype[UNSCOPABLES][key] = true;
|
|
1477
|
+
};
|
|
1478
|
+
|
|
1479
|
+
var iterators = {};
|
|
1480
|
+
|
|
1481
|
+
var fails$2 = fails$e;
|
|
1482
|
+
|
|
1483
|
+
var correctPrototypeGetter = !fails$2(function () {
|
|
1484
|
+
function F() { /* empty */ }
|
|
1485
|
+
F.prototype.constructor = null;
|
|
1486
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
1487
|
+
return Object.getPrototypeOf(new F()) !== F.prototype;
|
|
1488
|
+
});
|
|
1489
|
+
|
|
1490
|
+
var hasOwn$1 = hasOwnProperty_1;
|
|
1491
|
+
var isCallable$2 = isCallable$e;
|
|
1492
|
+
var toObject$1 = toObject$3;
|
|
1493
|
+
var sharedKey = sharedKey$3;
|
|
1494
|
+
var CORRECT_PROTOTYPE_GETTER = correctPrototypeGetter;
|
|
1495
|
+
|
|
1496
|
+
var IE_PROTO = sharedKey('IE_PROTO');
|
|
1497
|
+
var $Object = Object;
|
|
1498
|
+
var ObjectPrototype = $Object.prototype;
|
|
1499
|
+
|
|
1500
|
+
// `Object.getPrototypeOf` method
|
|
1501
|
+
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
1502
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
1503
|
+
var objectGetPrototypeOf = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {
|
|
1504
|
+
var object = toObject$1(O);
|
|
1505
|
+
if (hasOwn$1(object, IE_PROTO)) return object[IE_PROTO];
|
|
1506
|
+
var constructor = object.constructor;
|
|
1507
|
+
if (isCallable$2(constructor) && object instanceof constructor) {
|
|
1508
|
+
return constructor.prototype;
|
|
1509
|
+
} return object instanceof $Object ? ObjectPrototype : null;
|
|
1510
|
+
};
|
|
1511
|
+
|
|
1512
|
+
var fails$1 = fails$e;
|
|
1513
|
+
var isCallable$1 = isCallable$e;
|
|
1514
|
+
var isObject$1 = isObject$7;
|
|
1515
|
+
var getPrototypeOf$1 = objectGetPrototypeOf;
|
|
1516
|
+
var defineBuiltIn$1 = defineBuiltIn$3;
|
|
1517
|
+
var wellKnownSymbol$3 = wellKnownSymbol$8;
|
|
1518
|
+
|
|
1519
|
+
var ITERATOR$2 = wellKnownSymbol$3('iterator');
|
|
1520
|
+
var BUGGY_SAFARI_ITERATORS$1 = false;
|
|
1521
|
+
|
|
1522
|
+
// `%IteratorPrototype%` object
|
|
1523
|
+
// https://tc39.es/ecma262/#sec-%iteratorprototype%-object
|
|
1524
|
+
var IteratorPrototype$2, PrototypeOfArrayIteratorPrototype, arrayIterator;
|
|
1525
|
+
|
|
1526
|
+
/* eslint-disable es/no-array-prototype-keys -- safe */
|
|
1527
|
+
if ([].keys) {
|
|
1528
|
+
arrayIterator = [].keys();
|
|
1529
|
+
// Safari 8 has buggy iterators w/o `next`
|
|
1530
|
+
if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS$1 = true;
|
|
1531
|
+
else {
|
|
1532
|
+
PrototypeOfArrayIteratorPrototype = getPrototypeOf$1(getPrototypeOf$1(arrayIterator));
|
|
1533
|
+
if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype$2 = PrototypeOfArrayIteratorPrototype;
|
|
1534
|
+
}
|
|
1535
|
+
}
|
|
1536
|
+
|
|
1537
|
+
var NEW_ITERATOR_PROTOTYPE = !isObject$1(IteratorPrototype$2) || fails$1(function () {
|
|
1538
|
+
var test = {};
|
|
1539
|
+
// FF44- legacy iterators case
|
|
1540
|
+
return IteratorPrototype$2[ITERATOR$2].call(test) !== test;
|
|
1541
|
+
});
|
|
1542
|
+
|
|
1543
|
+
if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype$2 = {};
|
|
1544
|
+
|
|
1545
|
+
// `%IteratorPrototype%[@@iterator]()` method
|
|
1546
|
+
// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
|
|
1547
|
+
if (!isCallable$1(IteratorPrototype$2[ITERATOR$2])) {
|
|
1548
|
+
defineBuiltIn$1(IteratorPrototype$2, ITERATOR$2, function () {
|
|
1549
|
+
return this;
|
|
1550
|
+
});
|
|
1551
|
+
}
|
|
1552
|
+
|
|
1553
|
+
var iteratorsCore = {
|
|
1554
|
+
IteratorPrototype: IteratorPrototype$2,
|
|
1555
|
+
BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS$1
|
|
1556
|
+
};
|
|
1557
|
+
|
|
1558
|
+
var defineProperty$2 = objectDefineProperty.f;
|
|
1559
|
+
var hasOwn = hasOwnProperty_1;
|
|
1560
|
+
var wellKnownSymbol$2 = wellKnownSymbol$8;
|
|
1561
|
+
|
|
1562
|
+
var TO_STRING_TAG = wellKnownSymbol$2('toStringTag');
|
|
1563
|
+
|
|
1564
|
+
var setToStringTag$3 = function (target, TAG, STATIC) {
|
|
1565
|
+
if (target && !STATIC) target = target.prototype;
|
|
1566
|
+
if (target && !hasOwn(target, TO_STRING_TAG)) {
|
|
1567
|
+
defineProperty$2(target, TO_STRING_TAG, { configurable: true, value: TAG });
|
|
1568
|
+
}
|
|
1569
|
+
};
|
|
1570
|
+
|
|
1571
|
+
var IteratorPrototype$1 = iteratorsCore.IteratorPrototype;
|
|
1572
|
+
var create = objectCreate;
|
|
1573
|
+
var createPropertyDescriptor = createPropertyDescriptor$3;
|
|
1574
|
+
var setToStringTag$2 = setToStringTag$3;
|
|
1575
|
+
var Iterators$2 = iterators;
|
|
1576
|
+
|
|
1577
|
+
var returnThis$1 = function () { return this; };
|
|
1578
|
+
|
|
1579
|
+
var iteratorCreateConstructor = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {
|
|
1580
|
+
var TO_STRING_TAG = NAME + ' Iterator';
|
|
1581
|
+
IteratorConstructor.prototype = create(IteratorPrototype$1, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });
|
|
1582
|
+
setToStringTag$2(IteratorConstructor, TO_STRING_TAG, false);
|
|
1583
|
+
Iterators$2[TO_STRING_TAG] = returnThis$1;
|
|
1584
|
+
return IteratorConstructor;
|
|
1585
|
+
};
|
|
1586
|
+
|
|
1587
|
+
var uncurryThis$1 = functionUncurryThis;
|
|
1588
|
+
var aCallable = aCallable$2;
|
|
1589
|
+
|
|
1590
|
+
var functionUncurryThisAccessor = function (object, key, method) {
|
|
1591
|
+
try {
|
|
1592
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
1593
|
+
return uncurryThis$1(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));
|
|
1594
|
+
} catch (error) { /* empty */ }
|
|
1595
|
+
};
|
|
1596
|
+
|
|
1597
|
+
var isObject = isObject$7;
|
|
1598
|
+
|
|
1599
|
+
var isPossiblePrototype$1 = function (argument) {
|
|
1600
|
+
return isObject(argument) || argument === null;
|
|
1601
|
+
};
|
|
1602
|
+
|
|
1603
|
+
var isPossiblePrototype = isPossiblePrototype$1;
|
|
1604
|
+
|
|
1605
|
+
var $String = String;
|
|
1606
|
+
var $TypeError = TypeError;
|
|
1607
|
+
|
|
1608
|
+
var aPossiblePrototype$1 = function (argument) {
|
|
1609
|
+
if (isPossiblePrototype(argument)) return argument;
|
|
1610
|
+
throw new $TypeError("Can't set " + $String(argument) + ' as a prototype');
|
|
1611
|
+
};
|
|
1612
|
+
|
|
1613
|
+
/* eslint-disable no-proto -- safe */
|
|
1614
|
+
var uncurryThisAccessor = functionUncurryThisAccessor;
|
|
1615
|
+
var anObject = anObject$6;
|
|
1616
|
+
var aPossiblePrototype = aPossiblePrototype$1;
|
|
1617
|
+
|
|
1618
|
+
// `Object.setPrototypeOf` method
|
|
1619
|
+
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
1620
|
+
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
1621
|
+
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
1622
|
+
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
1623
|
+
var CORRECT_SETTER = false;
|
|
1624
|
+
var test = {};
|
|
1625
|
+
var setter;
|
|
1626
|
+
try {
|
|
1627
|
+
setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');
|
|
1628
|
+
setter(test, []);
|
|
1629
|
+
CORRECT_SETTER = test instanceof Array;
|
|
1630
|
+
} catch (error) { /* empty */ }
|
|
1631
|
+
return function setPrototypeOf(O, proto) {
|
|
1632
|
+
anObject(O);
|
|
1633
|
+
aPossiblePrototype(proto);
|
|
1634
|
+
if (CORRECT_SETTER) setter(O, proto);
|
|
1635
|
+
else O.__proto__ = proto;
|
|
1636
|
+
return O;
|
|
1637
|
+
};
|
|
1638
|
+
}() : undefined);
|
|
1639
|
+
|
|
1640
|
+
var $$1 = _export;
|
|
1641
|
+
var call$1 = functionCall;
|
|
1642
|
+
var FunctionName = functionName;
|
|
1643
|
+
var isCallable = isCallable$e;
|
|
1644
|
+
var createIteratorConstructor = iteratorCreateConstructor;
|
|
1645
|
+
var getPrototypeOf = objectGetPrototypeOf;
|
|
1646
|
+
var setPrototypeOf = objectSetPrototypeOf;
|
|
1647
|
+
var setToStringTag$1 = setToStringTag$3;
|
|
1648
|
+
var createNonEnumerableProperty$1 = createNonEnumerableProperty$4;
|
|
1649
|
+
var defineBuiltIn = defineBuiltIn$3;
|
|
1650
|
+
var wellKnownSymbol$1 = wellKnownSymbol$8;
|
|
1651
|
+
var Iterators$1 = iterators;
|
|
1652
|
+
var IteratorsCore = iteratorsCore;
|
|
1653
|
+
|
|
1654
|
+
var PROPER_FUNCTION_NAME = FunctionName.PROPER;
|
|
1655
|
+
var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
|
|
1656
|
+
var IteratorPrototype = IteratorsCore.IteratorPrototype;
|
|
1657
|
+
var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;
|
|
1658
|
+
var ITERATOR$1 = wellKnownSymbol$1('iterator');
|
|
1659
|
+
var KEYS = 'keys';
|
|
1660
|
+
var VALUES = 'values';
|
|
1661
|
+
var ENTRIES = 'entries';
|
|
1662
|
+
|
|
1663
|
+
var returnThis = function () { return this; };
|
|
1664
|
+
|
|
1665
|
+
var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {
|
|
1666
|
+
createIteratorConstructor(IteratorConstructor, NAME, next);
|
|
1667
|
+
|
|
1668
|
+
var getIterationMethod = function (KIND) {
|
|
1669
|
+
if (KIND === DEFAULT && defaultIterator) return defaultIterator;
|
|
1670
|
+
if (!BUGGY_SAFARI_ITERATORS && KIND && KIND in IterablePrototype) return IterablePrototype[KIND];
|
|
1671
|
+
|
|
1672
|
+
switch (KIND) {
|
|
1673
|
+
case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };
|
|
1674
|
+
case VALUES: return function values() { return new IteratorConstructor(this, KIND); };
|
|
1675
|
+
case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };
|
|
1676
|
+
}
|
|
1677
|
+
|
|
1678
|
+
return function () { return new IteratorConstructor(this); };
|
|
1679
|
+
};
|
|
1680
|
+
|
|
1681
|
+
var TO_STRING_TAG = NAME + ' Iterator';
|
|
1682
|
+
var INCORRECT_VALUES_NAME = false;
|
|
1683
|
+
var IterablePrototype = Iterable.prototype;
|
|
1684
|
+
var nativeIterator = IterablePrototype[ITERATOR$1]
|
|
1685
|
+
|| IterablePrototype['@@iterator']
|
|
1686
|
+
|| DEFAULT && IterablePrototype[DEFAULT];
|
|
1687
|
+
var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);
|
|
1688
|
+
var anyNativeIterator = NAME === 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;
|
|
1689
|
+
var CurrentIteratorPrototype, methods, KEY;
|
|
1690
|
+
|
|
1691
|
+
// fix native
|
|
1692
|
+
if (anyNativeIterator) {
|
|
1693
|
+
CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));
|
|
1694
|
+
if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {
|
|
1695
|
+
if (getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {
|
|
1696
|
+
if (setPrototypeOf) {
|
|
1697
|
+
setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);
|
|
1698
|
+
} else if (!isCallable(CurrentIteratorPrototype[ITERATOR$1])) {
|
|
1699
|
+
defineBuiltIn(CurrentIteratorPrototype, ITERATOR$1, returnThis);
|
|
1700
|
+
}
|
|
1701
|
+
}
|
|
1702
|
+
// Set @@toStringTag to native iterators
|
|
1703
|
+
setToStringTag$1(CurrentIteratorPrototype, TO_STRING_TAG, true);
|
|
1704
|
+
}
|
|
1705
|
+
}
|
|
1706
|
+
|
|
1707
|
+
// fix Array.prototype.{ values, @@iterator }.name in V8 / FF
|
|
1708
|
+
if (PROPER_FUNCTION_NAME && DEFAULT === VALUES && nativeIterator && nativeIterator.name !== VALUES) {
|
|
1709
|
+
if (CONFIGURABLE_FUNCTION_NAME) {
|
|
1710
|
+
createNonEnumerableProperty$1(IterablePrototype, 'name', VALUES);
|
|
1711
|
+
} else {
|
|
1712
|
+
INCORRECT_VALUES_NAME = true;
|
|
1713
|
+
defaultIterator = function values() { return call$1(nativeIterator, this); };
|
|
1714
|
+
}
|
|
1715
|
+
}
|
|
1716
|
+
|
|
1717
|
+
// export additional methods
|
|
1718
|
+
if (DEFAULT) {
|
|
1719
|
+
methods = {
|
|
1720
|
+
values: getIterationMethod(VALUES),
|
|
1721
|
+
keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),
|
|
1722
|
+
entries: getIterationMethod(ENTRIES)
|
|
1723
|
+
};
|
|
1724
|
+
if (FORCED) for (KEY in methods) {
|
|
1725
|
+
if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
|
|
1726
|
+
defineBuiltIn(IterablePrototype, KEY, methods[KEY]);
|
|
1727
|
+
}
|
|
1728
|
+
} else $$1({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
|
|
1729
|
+
}
|
|
1730
|
+
|
|
1731
|
+
// define iterator
|
|
1732
|
+
if (IterablePrototype[ITERATOR$1] !== defaultIterator) {
|
|
1733
|
+
defineBuiltIn(IterablePrototype, ITERATOR$1, defaultIterator, { name: DEFAULT });
|
|
1734
|
+
}
|
|
1735
|
+
Iterators$1[NAME] = defaultIterator;
|
|
1736
|
+
|
|
1737
|
+
return methods;
|
|
1738
|
+
};
|
|
1739
|
+
|
|
1740
|
+
// `CreateIterResultObject` abstract operation
|
|
1741
|
+
// https://tc39.es/ecma262/#sec-createiterresultobject
|
|
1742
|
+
var createIterResultObject$1 = function (value, done) {
|
|
1743
|
+
return { value: value, done: done };
|
|
1744
|
+
};
|
|
1745
|
+
|
|
1746
|
+
var toIndexedObject = toIndexedObject$5;
|
|
1747
|
+
var addToUnscopables = addToUnscopables$1;
|
|
1748
|
+
var Iterators = iterators;
|
|
1749
|
+
var InternalStateModule = internalState;
|
|
1750
|
+
var defineProperty$1 = objectDefineProperty.f;
|
|
1751
|
+
var defineIterator = iteratorDefine;
|
|
1752
|
+
var createIterResultObject = createIterResultObject$1;
|
|
1753
|
+
var DESCRIPTORS$1 = descriptors;
|
|
1754
|
+
|
|
1755
|
+
var ARRAY_ITERATOR = 'Array Iterator';
|
|
1756
|
+
var setInternalState = InternalStateModule.set;
|
|
1757
|
+
var getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);
|
|
1758
|
+
|
|
1759
|
+
// `Array.prototype.entries` method
|
|
1760
|
+
// https://tc39.es/ecma262/#sec-array.prototype.entries
|
|
1761
|
+
// `Array.prototype.keys` method
|
|
1762
|
+
// https://tc39.es/ecma262/#sec-array.prototype.keys
|
|
1763
|
+
// `Array.prototype.values` method
|
|
1764
|
+
// https://tc39.es/ecma262/#sec-array.prototype.values
|
|
1765
|
+
// `Array.prototype[@@iterator]` method
|
|
1766
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@iterator
|
|
1767
|
+
// `CreateArrayIterator` internal method
|
|
1768
|
+
// https://tc39.es/ecma262/#sec-createarrayiterator
|
|
1769
|
+
var es_array_iterator = defineIterator(Array, 'Array', function (iterated, kind) {
|
|
1770
|
+
setInternalState(this, {
|
|
1771
|
+
type: ARRAY_ITERATOR,
|
|
1772
|
+
target: toIndexedObject(iterated), // target
|
|
1773
|
+
index: 0, // next index
|
|
1774
|
+
kind: kind // kind
|
|
1775
|
+
});
|
|
1776
|
+
// `%ArrayIteratorPrototype%.next` method
|
|
1777
|
+
// https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next
|
|
1778
|
+
}, function () {
|
|
1779
|
+
var state = getInternalState(this);
|
|
1780
|
+
var target = state.target;
|
|
1781
|
+
var index = state.index++;
|
|
1782
|
+
if (!target || index >= target.length) {
|
|
1783
|
+
state.target = undefined;
|
|
1784
|
+
return createIterResultObject(undefined, true);
|
|
1785
|
+
}
|
|
1786
|
+
switch (state.kind) {
|
|
1787
|
+
case 'keys': return createIterResultObject(index, false);
|
|
1788
|
+
case 'values': return createIterResultObject(target[index], false);
|
|
1789
|
+
} return createIterResultObject([index, target[index]], false);
|
|
1790
|
+
}, 'values');
|
|
1791
|
+
|
|
1792
|
+
// argumentsList[@@iterator] is %ArrayProto_values%
|
|
1793
|
+
// https://tc39.es/ecma262/#sec-createunmappedargumentsobject
|
|
1794
|
+
// https://tc39.es/ecma262/#sec-createmappedargumentsobject
|
|
1795
|
+
var values = Iterators.Arguments = Iterators.Array;
|
|
1796
|
+
|
|
1797
|
+
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
1798
|
+
addToUnscopables('keys');
|
|
1799
|
+
addToUnscopables('values');
|
|
1800
|
+
addToUnscopables('entries');
|
|
1801
|
+
|
|
1802
|
+
// V8 ~ Chrome 45- bug
|
|
1803
|
+
if (DESCRIPTORS$1 && values.name !== 'values') try {
|
|
1804
|
+
defineProperty$1(values, 'name', { value: 'values' });
|
|
1805
|
+
} catch (error) { /* empty */ }
|
|
1806
|
+
|
|
1807
|
+
// iterable DOM collections
|
|
1808
|
+
// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
|
|
1809
|
+
var domIterables = {
|
|
1810
|
+
CSSRuleList: 0,
|
|
1811
|
+
CSSStyleDeclaration: 0,
|
|
1812
|
+
CSSValueList: 0,
|
|
1813
|
+
ClientRectList: 0,
|
|
1814
|
+
DOMRectList: 0,
|
|
1815
|
+
DOMStringList: 0,
|
|
1816
|
+
DOMTokenList: 1,
|
|
1817
|
+
DataTransferItemList: 0,
|
|
1818
|
+
FileList: 0,
|
|
1819
|
+
HTMLAllCollection: 0,
|
|
1820
|
+
HTMLCollection: 0,
|
|
1821
|
+
HTMLFormElement: 0,
|
|
1822
|
+
HTMLSelectElement: 0,
|
|
1823
|
+
MediaList: 0,
|
|
1824
|
+
MimeTypeArray: 0,
|
|
1825
|
+
NamedNodeMap: 0,
|
|
1826
|
+
NodeList: 1,
|
|
1827
|
+
PaintRequestList: 0,
|
|
1828
|
+
Plugin: 0,
|
|
1829
|
+
PluginArray: 0,
|
|
1830
|
+
SVGLengthList: 0,
|
|
1831
|
+
SVGNumberList: 0,
|
|
1832
|
+
SVGPathSegList: 0,
|
|
1833
|
+
SVGPointList: 0,
|
|
1834
|
+
SVGStringList: 0,
|
|
1835
|
+
SVGTransformList: 0,
|
|
1836
|
+
SourceBufferList: 0,
|
|
1837
|
+
StyleSheetList: 0,
|
|
1838
|
+
TextTrackCueList: 0,
|
|
1839
|
+
TextTrackList: 0,
|
|
1840
|
+
TouchList: 0
|
|
1841
|
+
};
|
|
1842
|
+
|
|
1843
|
+
// in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`
|
|
1844
|
+
var documentCreateElement = documentCreateElement$2;
|
|
1845
|
+
|
|
1846
|
+
var classList = documentCreateElement('span').classList;
|
|
1847
|
+
var DOMTokenListPrototype$1 = classList && classList.constructor && classList.constructor.prototype;
|
|
1848
|
+
|
|
1849
|
+
var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
|
|
1850
|
+
|
|
1851
|
+
var global$1 = global$f;
|
|
1852
|
+
var DOMIterables = domIterables;
|
|
1853
|
+
var DOMTokenListPrototype = domTokenListPrototype;
|
|
1854
|
+
var ArrayIteratorMethods = es_array_iterator;
|
|
1855
|
+
var createNonEnumerableProperty = createNonEnumerableProperty$4;
|
|
1856
|
+
var setToStringTag = setToStringTag$3;
|
|
1857
|
+
var wellKnownSymbol = wellKnownSymbol$8;
|
|
1858
|
+
|
|
1859
|
+
var ITERATOR = wellKnownSymbol('iterator');
|
|
1860
|
+
var ArrayValues = ArrayIteratorMethods.values;
|
|
1861
|
+
|
|
1862
|
+
var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
|
|
1863
|
+
if (CollectionPrototype) {
|
|
1864
|
+
// some Chrome versions have non-configurable methods on DOMTokenList
|
|
1865
|
+
if (CollectionPrototype[ITERATOR] !== ArrayValues) try {
|
|
1866
|
+
createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);
|
|
1867
|
+
} catch (error) {
|
|
1868
|
+
CollectionPrototype[ITERATOR] = ArrayValues;
|
|
1869
|
+
}
|
|
1870
|
+
setToStringTag(CollectionPrototype, COLLECTION_NAME, true);
|
|
1871
|
+
if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {
|
|
1872
|
+
// some Chrome versions have non-configurable methods on DOMTokenList
|
|
1873
|
+
if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {
|
|
1874
|
+
createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);
|
|
1875
|
+
} catch (error) {
|
|
1876
|
+
CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];
|
|
1877
|
+
}
|
|
1878
|
+
}
|
|
1879
|
+
}
|
|
1880
|
+
};
|
|
1881
|
+
|
|
1882
|
+
for (var COLLECTION_NAME in DOMIterables) {
|
|
1883
|
+
handlePrototype(global$1[COLLECTION_NAME] && global$1[COLLECTION_NAME].prototype, COLLECTION_NAME);
|
|
1884
|
+
}
|
|
1885
|
+
|
|
1886
|
+
handlePrototype(DOMTokenListPrototype, 'DOMTokenList');
|
|
1887
|
+
|
|
1888
|
+
/**
|
|
1889
|
+
* Max length of WebsiteLink's data type.
|
|
1890
|
+
*/
|
|
1891
|
+
const WEBSITE_FILE_LINK_TYPE_MAX_LENGTH = WEBSITE_LINK_TYPE_MAX_LENGTH;
|
|
1892
|
+
/**
|
|
1893
|
+
* Has the same regex as WebsiteLinkType
|
|
1894
|
+
*/
|
|
1895
|
+
const WEBSITE_FILE_LINK_TYPE_REGEX = WEBSITE_LINK_TYPE_REGEX;
|
|
1896
|
+
/**
|
|
1897
|
+
* Max length of WebsiteLink's data type.
|
|
1898
|
+
*/
|
|
1899
|
+
const WEBSITE_FILE_LINK_MIME_TYPE_MAX_LENGTH = 128;
|
|
1900
|
+
/**
|
|
1901
|
+
* Default max length of WebsiteLink's data string.
|
|
1902
|
+
*/
|
|
1903
|
+
const WEBSITE_FILE_LINK_MIME_TYPE_REGEX = /^\w+\/[-+.\w]+$/;
|
|
1904
|
+
/**
|
|
1905
|
+
* Max length of WebsiteLink's data type.
|
|
1906
|
+
*/
|
|
1907
|
+
const WEBSITE_FILE_LINK_NAME_MAX_LENGTH = 128;
|
|
1908
|
+
/**
|
|
1909
|
+
* Max length of WebsiteLink's data type.
|
|
1910
|
+
*/
|
|
1911
|
+
const WEBSITE_FILE_LINK_DATA_MAX_LENGTH = WEBSITE_LINK_ENCODED_DATA_MAX_LENGTH - 3 - WEBSITE_FILE_LINK_TYPE_MAX_LENGTH - WEBSITE_FILE_LINK_MIME_TYPE_MAX_LENGTH - WEBSITE_FILE_LINK_NAME_MAX_LENGTH;
|
|
1912
|
+
const WEBSITE_FILE_LINK_DATA_REGEX = /^[^|]+$/;
|
|
1913
|
+
class WebsiteFileLink {
|
|
1914
|
+
constructor(template) {
|
|
1915
|
+
if (template != null) {
|
|
1916
|
+
this.type = template.type;
|
|
1917
|
+
this.mime = template.mime;
|
|
1918
|
+
this.name = template.name;
|
|
1919
|
+
this.data = template.data;
|
|
1920
|
+
}
|
|
1921
|
+
}
|
|
1922
|
+
}
|
|
1923
|
+
__decorate([classTransformer.Expose(), classValidator.IsOptional(), classValidator.IsString(), classValidator.Matches(WEBSITE_FILE_LINK_TYPE_REGEX), classValidator.MaxLength(WEBSITE_LINK_TYPE_MAX_LENGTH), __metadata("design:type", String)], WebsiteFileLink.prototype, "type", void 0);
|
|
1924
|
+
__decorate([classTransformer.Expose(), classValidator.IsOptional(), classValidator.IsString(), classValidator.Matches(WEBSITE_FILE_LINK_MIME_TYPE_REGEX), classValidator.MaxLength(WEBSITE_FILE_LINK_MIME_TYPE_MAX_LENGTH), __metadata("design:type", String)], WebsiteFileLink.prototype, "mime", void 0);
|
|
1925
|
+
__decorate([classTransformer.Expose(), classValidator.IsOptional(), classValidator.IsString(), classValidator.MaxLength(WEBSITE_FILE_LINK_NAME_MAX_LENGTH), __metadata("design:type", String)], WebsiteFileLink.prototype, "name", void 0);
|
|
1926
|
+
__decorate([classValidator.IsString(), classValidator.IsNotEmpty(), classValidator.Matches(WEBSITE_FILE_LINK_DATA_REGEX), classValidator.MaxLength(WEBSITE_FILE_LINK_DATA_MAX_LENGTH), __metadata("design:type", String)], WebsiteFileLink.prototype, "data", void 0);
|
|
1927
|
+
const WEBSITE_FILE_LINK_WEBSITE_LINK_TYPE = 'f';
|
|
1928
|
+
function websiteFileLinkToWebsiteLink(input) {
|
|
1929
|
+
return {
|
|
1930
|
+
t: WEBSITE_FILE_LINK_WEBSITE_LINK_TYPE,
|
|
1931
|
+
d: encodeWebsiteFileLinkToWebsiteLinkEncodedData(input)
|
|
1932
|
+
};
|
|
1933
|
+
}
|
|
1934
|
+
function websiteLinkToWebsiteLinkFile(input) {
|
|
1935
|
+
const encodedData = input.d;
|
|
1936
|
+
return decodeWebsiteLinkEncodedDataToWebsiteFileLink(encodedData);
|
|
1937
|
+
}
|
|
1938
|
+
const WEBSITE_FILE_LINK_ENCODE_SEPARATOR = '|';
|
|
1939
|
+
function encodeWebsiteFileLinkToWebsiteLinkEncodedData(input) {
|
|
1940
|
+
const encoded = [input.type, input.mime, input.data, input.name].map(x => x || '').join(WEBSITE_FILE_LINK_ENCODE_SEPARATOR);
|
|
1941
|
+
return encoded;
|
|
1942
|
+
}
|
|
1943
|
+
function decodeWebsiteLinkEncodedDataToWebsiteFileLink(input) {
|
|
1944
|
+
const [type, mime, data, name] = util.splitJoinRemainder(input, WEBSITE_FILE_LINK_ENCODE_SEPARATOR, 4);
|
|
1945
|
+
return util.filterFalsyAndEmptyValues({
|
|
1946
|
+
type,
|
|
1947
|
+
mime,
|
|
1948
|
+
name,
|
|
1949
|
+
data
|
|
1950
|
+
});
|
|
1951
|
+
}
|
|
1952
|
+
|
|
1953
|
+
/**
|
|
1954
|
+
* Used for isolating a username from a website that has the username as the base url.
|
|
1955
|
+
*
|
|
1956
|
+
* Example:
|
|
1957
|
+
* - https://facebook.com/facebook
|
|
1958
|
+
*/
|
|
1959
|
+
const WEBSITE_LINK_ISOLATE_BASE_URL_PROFILE_ID = util.isolateWebsitePathFunction({
|
|
1960
|
+
isolatePathComponents: 0,
|
|
1961
|
+
removeTrailingSlash: true,
|
|
1962
|
+
removeQueryParameters: true
|
|
1963
|
+
});
|
|
1964
|
+
function usernameFromUsernameOrWebsiteWithBaseUrlUsername(input, prefix) {
|
|
1965
|
+
const username = util.toRelativeSlashPathStartType(WEBSITE_LINK_ISOLATE_BASE_URL_PROFILE_ID(usernameOrWebsiteUrlToWebsiteUrl(input)));
|
|
1966
|
+
if (prefix) {
|
|
1967
|
+
return util.addPrefix(prefix, username);
|
|
1968
|
+
} else {
|
|
1969
|
+
return username;
|
|
1970
|
+
}
|
|
1971
|
+
}
|
|
1972
|
+
function usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername(input, isolateFn) {
|
|
1973
|
+
return util.toRelativeSlashPathStartType(isolateFn(usernameOrWebsiteUrlToWebsiteUrl(input)));
|
|
1974
|
+
}
|
|
1975
|
+
function usernameOrWebsiteUrlToWebsiteUrl(input) {
|
|
1976
|
+
return util.hasWebsiteDomain(input) ? input : util.toAbsoluteSlashPathStartType(util.removeHttpFromUrl(input));
|
|
1977
|
+
}
|
|
1978
|
+
// MARK: Website
|
|
1979
|
+
const WEBSITE_URL_WEBSITE_LINK_TYPE = 'w';
|
|
1980
|
+
function websiteUrlToWebsiteLink(input) {
|
|
1981
|
+
return {
|
|
1982
|
+
t: WEBSITE_URL_WEBSITE_LINK_TYPE,
|
|
1983
|
+
d: util.removeHttpFromUrl(input) // website urls are stored as-is without http/https
|
|
1984
|
+
};
|
|
1985
|
+
}
|
|
1986
|
+
// MARK: Email
|
|
1987
|
+
const EMAIL_URL_WEBSITE_LINK_TYPE = 'e';
|
|
1988
|
+
function emailAddressToWebsiteLink(input) {
|
|
1989
|
+
return {
|
|
1990
|
+
t: EMAIL_URL_WEBSITE_LINK_TYPE,
|
|
1991
|
+
d: input
|
|
1992
|
+
};
|
|
1993
|
+
}
|
|
1994
|
+
// MARK: Phone
|
|
1995
|
+
const PHONE_URL_WEBSITE_LINK_TYPE = 'p';
|
|
1996
|
+
function phoneNumberToWebsiteLink(input) {
|
|
1997
|
+
return {
|
|
1998
|
+
t: PHONE_URL_WEBSITE_LINK_TYPE,
|
|
1999
|
+
d: input
|
|
2000
|
+
};
|
|
2001
|
+
}
|
|
2002
|
+
// MARK: Facebook
|
|
2003
|
+
const FACEBOOK_BASE_URL = `https://www.facebook.com`;
|
|
2004
|
+
const FACEBOOK_WEBSITE_LINK_TYPE = 'fb';
|
|
2005
|
+
function facebookProfileUrlToWebsiteLink(input) {
|
|
2006
|
+
return {
|
|
2007
|
+
t: FACEBOOK_WEBSITE_LINK_TYPE,
|
|
2008
|
+
d: usernameFromUsernameOrWebsiteWithBaseUrlUsername(input)
|
|
2009
|
+
};
|
|
2010
|
+
}
|
|
2011
|
+
function facebookProfileUrl(profileId) {
|
|
2012
|
+
return `${FACEBOOK_BASE_URL}/${profileId}`;
|
|
2013
|
+
}
|
|
2014
|
+
// MARK: Instagram
|
|
2015
|
+
const INSTAGRAM_BASE_URL = `https://www.instagram.com`;
|
|
2016
|
+
const INSTAGRAM_WEBSITE_LINK_TYPE = 'ig';
|
|
2017
|
+
function instagramProfileUrlToWebsiteLink(input) {
|
|
2018
|
+
return {
|
|
2019
|
+
t: INSTAGRAM_WEBSITE_LINK_TYPE,
|
|
2020
|
+
d: usernameFromUsernameOrWebsiteWithBaseUrlUsername(input)
|
|
2021
|
+
};
|
|
2022
|
+
}
|
|
2023
|
+
function instagramProfileUrl(profileId) {
|
|
2024
|
+
return `${INSTAGRAM_BASE_URL}/${profileId}`;
|
|
2025
|
+
}
|
|
2026
|
+
// MARK: Twitter
|
|
2027
|
+
const TWITTER_BASE_URL = `https://www.twitter.com`;
|
|
2028
|
+
const TWITTER_WEBSITE_LINK_TYPE = 'tw';
|
|
2029
|
+
function twitterProfileUrlToWebsiteLink(input) {
|
|
2030
|
+
return {
|
|
2031
|
+
t: TWITTER_WEBSITE_LINK_TYPE,
|
|
2032
|
+
d: usernameFromUsernameOrWebsiteWithBaseUrlUsername(input)
|
|
2033
|
+
};
|
|
2034
|
+
}
|
|
2035
|
+
function twitterProfileUrl(profileId) {
|
|
2036
|
+
return `${TWITTER_BASE_URL}/${profileId}`;
|
|
2037
|
+
}
|
|
2038
|
+
// MARK: Tiktok
|
|
2039
|
+
const TIKTOK_BASE_URL = `https://tiktok.com`;
|
|
2040
|
+
const TIKTOK_USERNAME_PREFIX = '@';
|
|
2041
|
+
const TIKTOK_WEBSITE_LINK_TYPE = 'tt';
|
|
2042
|
+
function tiktokProfileUrlToWebsiteLink(input) {
|
|
2043
|
+
return {
|
|
2044
|
+
t: TIKTOK_WEBSITE_LINK_TYPE,
|
|
2045
|
+
d: usernameFromUsernameOrWebsiteWithBaseUrlUsername(input, TIKTOK_USERNAME_PREFIX)
|
|
2046
|
+
};
|
|
2047
|
+
}
|
|
2048
|
+
function tiktokProfileUrl(profileId) {
|
|
2049
|
+
return `${TIKTOK_BASE_URL}/@${profileId}`;
|
|
2050
|
+
}
|
|
2051
|
+
// MARK: Snapchat
|
|
2052
|
+
const SNAPCHAT_BASE_URL = `https://snapchat.com`;
|
|
2053
|
+
const SNAPCHAT_WEBSITE_LINK_TYPE = 'sc';
|
|
2054
|
+
const SNAPCHAT_WEBSITE_LINK_ISOLATE_PROFILE_ID = util.isolateWebsitePathFunction({
|
|
2055
|
+
ignoredBasePath: 'add',
|
|
2056
|
+
isolatePathComponents: 0,
|
|
2057
|
+
removeTrailingSlash: true,
|
|
2058
|
+
removeQueryParameters: true
|
|
2059
|
+
});
|
|
2060
|
+
function snapchatProfileUrlToWebsiteLink(input) {
|
|
2061
|
+
return {
|
|
2062
|
+
t: SNAPCHAT_WEBSITE_LINK_TYPE,
|
|
2063
|
+
d: usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername(input, SNAPCHAT_WEBSITE_LINK_ISOLATE_PROFILE_ID)
|
|
2064
|
+
};
|
|
2065
|
+
}
|
|
2066
|
+
function snapchatProfileUrl(profileId) {
|
|
2067
|
+
return `${SNAPCHAT_BASE_URL}/add/${profileId}`;
|
|
2068
|
+
}
|
|
2069
|
+
// MARK: YouTube
|
|
2070
|
+
const YOUTUBE_BASE_URL = `https://youtube.com`;
|
|
2071
|
+
const YOUTUBE_WEBSITE_LINK_TYPE = 'yt';
|
|
2072
|
+
const YOUTUBE_WEBSITE_LINK_ISOLATE_PROFILE_ID = util.isolateWebsitePathFunction({
|
|
2073
|
+
ignoredBasePath: 'c',
|
|
2074
|
+
isolatePathComponents: 0,
|
|
2075
|
+
removeTrailingSlash: true,
|
|
2076
|
+
removeQueryParameters: true
|
|
2077
|
+
});
|
|
2078
|
+
function youtubeProfileUrlToWebsiteLink(input) {
|
|
2079
|
+
return {
|
|
2080
|
+
t: YOUTUBE_WEBSITE_LINK_TYPE,
|
|
2081
|
+
d: usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername(input, YOUTUBE_WEBSITE_LINK_ISOLATE_PROFILE_ID)
|
|
2082
|
+
};
|
|
2083
|
+
}
|
|
2084
|
+
function youtubeProfileUrl(profileId) {
|
|
2085
|
+
return `${YOUTUBE_BASE_URL}/c/${profileId}`;
|
|
2086
|
+
}
|
|
2087
|
+
// MARK: PayPal
|
|
2088
|
+
const PAYPAL_BASE_URL = `https://paypal.me`;
|
|
2089
|
+
const PAYPAL_WEBSITE_LINK_TYPE = 'pp';
|
|
2090
|
+
function paypalProfileUrlToWebsiteLink(input) {
|
|
2091
|
+
return {
|
|
2092
|
+
t: PAYPAL_WEBSITE_LINK_TYPE,
|
|
2093
|
+
d: usernameFromUsernameOrWebsiteWithBaseUrlUsername(input)
|
|
2094
|
+
};
|
|
2095
|
+
}
|
|
2096
|
+
function paypalProfileUrl(profileId) {
|
|
2097
|
+
return `${PAYPAL_BASE_URL}/${profileId}`;
|
|
2098
|
+
}
|
|
2099
|
+
// MARK: Cashapp
|
|
2100
|
+
const CASHAPP_BASE_URL = `https://cash.app`;
|
|
2101
|
+
const CASHAPP_USERNAME_PREFIX = '$';
|
|
2102
|
+
const CASHAPP_WEBSITE_LINK_TYPE = 'ca';
|
|
2103
|
+
function cashappProfileUrlToWebsiteLink(input) {
|
|
2104
|
+
return {
|
|
2105
|
+
t: CASHAPP_WEBSITE_LINK_TYPE,
|
|
2106
|
+
d: usernameFromUsernameOrWebsiteWithBaseUrlUsername(input, CASHAPP_USERNAME_PREFIX)
|
|
2107
|
+
};
|
|
2108
|
+
}
|
|
2109
|
+
function cashappProfileUrl(profileId) {
|
|
2110
|
+
return `${CASHAPP_BASE_URL}/$${profileId}`;
|
|
2111
|
+
}
|
|
2112
|
+
// MARK: Venmo
|
|
2113
|
+
const VENMO_BASE_URL = `https://account.venmo.com`;
|
|
2114
|
+
const VENMO_WEBSITE_LINK_TYPE = 'vn';
|
|
2115
|
+
const VENMO_WEBSITE_LINK_ISOLATE_PROFILE_ID = util.isolateWebsitePathFunction({
|
|
2116
|
+
ignoredBasePath: 'u',
|
|
2117
|
+
isolatePathComponents: 0,
|
|
2118
|
+
removeTrailingSlash: true,
|
|
2119
|
+
removeQueryParameters: true
|
|
2120
|
+
});
|
|
2121
|
+
function venmoProfileUrlToWebsiteLink(input) {
|
|
2122
|
+
return {
|
|
2123
|
+
t: VENMO_WEBSITE_LINK_TYPE,
|
|
2124
|
+
d: usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername(input, VENMO_WEBSITE_LINK_ISOLATE_PROFILE_ID)
|
|
2125
|
+
};
|
|
2126
|
+
}
|
|
2127
|
+
function venmoProfileUrl(profileId) {
|
|
2128
|
+
return `${VENMO_BASE_URL}/u/${profileId}`;
|
|
2129
|
+
}
|
|
2130
|
+
// MARK: Spotify
|
|
2131
|
+
const SPOTIFY_BASE_URL = `https://open.spotify.com/`;
|
|
2132
|
+
const SPOTIFY_WEBSITE_LINK_TYPE = 'sp';
|
|
2133
|
+
const SPOTIFY_WEBSITE_LINK_ISOLATE_PROFILE_ID = util.isolateWebsitePathFunction({
|
|
2134
|
+
ignoredBasePath: 'user',
|
|
2135
|
+
isolatePathComponents: 0,
|
|
2136
|
+
removeTrailingSlash: true,
|
|
2137
|
+
removeQueryParameters: true
|
|
2138
|
+
});
|
|
2139
|
+
function spotifyProfileUrlToWebsiteLink(input) {
|
|
2140
|
+
return {
|
|
2141
|
+
t: SPOTIFY_WEBSITE_LINK_TYPE,
|
|
2142
|
+
d: usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername(input, SPOTIFY_WEBSITE_LINK_ISOLATE_PROFILE_ID)
|
|
2143
|
+
};
|
|
2144
|
+
}
|
|
2145
|
+
function spotifyProfileUrl(profileId) {
|
|
2146
|
+
return `${SPOTIFY_BASE_URL}/user/${profileId}`;
|
|
2147
|
+
}
|
|
2148
|
+
|
|
2149
|
+
const GRANTED_SYS_ADMIN_ROLE_KEY = 'sysadmin';
|
|
2150
|
+
const GRANTED_OWNER_ROLE_KEY = 'owner';
|
|
2151
|
+
const GRANTED_ADMIN_ROLE_KEY = 'admin';
|
|
2152
|
+
/**
|
|
2153
|
+
* Returns true if the input role is a GrantedAdminRole or a GrantedOwnerRole.
|
|
2154
|
+
*
|
|
2155
|
+
* @param role
|
|
2156
|
+
* @returns
|
|
2157
|
+
*/
|
|
2158
|
+
function isGrantedAdminLevelRole(role) {
|
|
2159
|
+
return role === GRANTED_ADMIN_ROLE_KEY || role === GRANTED_OWNER_ROLE_KEY;
|
|
2160
|
+
}
|
|
2161
|
+
const GRANTED_READ_ROLE_KEY = 'read';
|
|
2162
|
+
const GRANTED_UPDATE_ROLE_KEY = 'update';
|
|
2163
|
+
const GRANTED_DELETE_ROLE_KEY = 'delete';
|
|
2164
|
+
const FULL_ACCESS_ROLE_KEY = '__FULL__';
|
|
2165
|
+
const NO_ACCESS_ROLE_KEY = '__EMPTY__';
|
|
2166
|
+
function noAccessRoleMap() {
|
|
2167
|
+
return {
|
|
2168
|
+
[NO_ACCESS_ROLE_KEY]: true
|
|
2169
|
+
};
|
|
2170
|
+
}
|
|
2171
|
+
function isNoAccessRoleMap(input) {
|
|
2172
|
+
return input[NO_ACCESS_ROLE_KEY] === true;
|
|
2173
|
+
}
|
|
2174
|
+
function fullAccessRoleMap() {
|
|
2175
|
+
return {
|
|
2176
|
+
[FULL_ACCESS_ROLE_KEY]: true
|
|
2177
|
+
};
|
|
2178
|
+
}
|
|
2179
|
+
function isFullAccessRoleMap(input) {
|
|
2180
|
+
return input[FULL_ACCESS_ROLE_KEY] === true;
|
|
2181
|
+
}
|
|
2182
|
+
/**
|
|
2183
|
+
* Creates a GrantedRoleMapReader.
|
|
2184
|
+
*
|
|
2185
|
+
* @param map
|
|
2186
|
+
* @returns
|
|
2187
|
+
*/
|
|
2188
|
+
function grantedRoleMapReader(map) {
|
|
2189
|
+
return new GrantedRoleMapReaderInstance(map);
|
|
2190
|
+
}
|
|
2191
|
+
class GrantedRoleMapReaderInstance {
|
|
2192
|
+
constructor(_map) {
|
|
2193
|
+
this._map = _map;
|
|
2194
|
+
}
|
|
2195
|
+
hasNoAccess() {
|
|
2196
|
+
return this._map[NO_ACCESS_ROLE_KEY];
|
|
2197
|
+
}
|
|
2198
|
+
truthMap(input) {
|
|
2199
|
+
const result = {};
|
|
2200
|
+
util.forEachKeyValue(input, {
|
|
2201
|
+
forEach: ([role, value]) => {
|
|
2202
|
+
if (this.hasRole(role)) {
|
|
2203
|
+
result[role] = value;
|
|
2204
|
+
}
|
|
2205
|
+
}
|
|
2206
|
+
});
|
|
2207
|
+
return result;
|
|
2208
|
+
}
|
|
2209
|
+
hasRole(role) {
|
|
2210
|
+
return this.hasRoles('any', role);
|
|
2211
|
+
}
|
|
2212
|
+
hasRoles(setIncludes, inputRoles) {
|
|
2213
|
+
if (this._map[FULL_ACCESS_ROLE_KEY]) {
|
|
2214
|
+
return true;
|
|
2215
|
+
} else {
|
|
2216
|
+
return this.containsRoles(setIncludes, inputRoles);
|
|
2217
|
+
}
|
|
2218
|
+
}
|
|
2219
|
+
containsRoles(setIncludes, inputRoles) {
|
|
2220
|
+
const roles = util.iterableToArray(inputRoles);
|
|
2221
|
+
if (setIncludes === 'any') {
|
|
2222
|
+
return this.containsAnyRole(roles);
|
|
2223
|
+
} else {
|
|
2224
|
+
return this.containsEachRole(roles);
|
|
2225
|
+
}
|
|
2226
|
+
}
|
|
2227
|
+
containsAnyRole(roles) {
|
|
2228
|
+
for (const role of roles) {
|
|
2229
|
+
if (this._map[role]) {
|
|
2230
|
+
return true;
|
|
2231
|
+
}
|
|
2232
|
+
}
|
|
2233
|
+
return false;
|
|
2234
|
+
}
|
|
2235
|
+
containsEachRole(roles) {
|
|
2236
|
+
for (const role of roles) {
|
|
2237
|
+
if (!this._map[role]) {
|
|
2238
|
+
return false;
|
|
2239
|
+
}
|
|
2240
|
+
}
|
|
2241
|
+
return true;
|
|
2242
|
+
}
|
|
2243
|
+
}
|
|
2244
|
+
/**
|
|
2245
|
+
* Converts the input array of roles to a GrantedRoleKeysMap.
|
|
2246
|
+
*
|
|
2247
|
+
* @param roles
|
|
2248
|
+
* @returns
|
|
2249
|
+
*/
|
|
2250
|
+
function grantedRoleKeysMapFromArray(roles, value = true) {
|
|
2251
|
+
return util.arrayToObject(roles, x => x, () => value);
|
|
2252
|
+
}
|
|
2253
|
+
|
|
2254
|
+
function noAccessContextGrantedModelRoles(context, data) {
|
|
2255
|
+
return contextGrantedModelRoles(context, data, noAccessRoleMap());
|
|
2256
|
+
}
|
|
2257
|
+
function fullAccessGrantedModelRoles(context, data) {
|
|
2258
|
+
return contextGrantedModelRoles(context, data, fullAccessRoleMap());
|
|
2259
|
+
}
|
|
2260
|
+
function contextGrantedModelRoles(context, data, roles) {
|
|
2261
|
+
return {
|
|
2262
|
+
data,
|
|
2263
|
+
context,
|
|
2264
|
+
roleMap: roles
|
|
2265
|
+
};
|
|
2266
|
+
}
|
|
2267
|
+
|
|
2268
|
+
/**
|
|
2269
|
+
* Abstract ModelPermissionService implementation.
|
|
2270
|
+
*/
|
|
2271
|
+
class AbstractModelPermissionService {
|
|
2272
|
+
constructor(modelLoader) {
|
|
2273
|
+
this.modelLoader = modelLoader;
|
|
2274
|
+
}
|
|
2275
|
+
roleMapForKeyContext(key, context) {
|
|
2276
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2277
|
+
const model = yield this.modelLoader.loadModelForKey(key, context);
|
|
2278
|
+
let result;
|
|
2279
|
+
if (model != null) {
|
|
2280
|
+
result = yield this.roleMapForModelContext(model, context);
|
|
2281
|
+
} else {
|
|
2282
|
+
result = noAccessContextGrantedModelRoles(context);
|
|
2283
|
+
}
|
|
2284
|
+
return result;
|
|
2285
|
+
});
|
|
2286
|
+
}
|
|
2287
|
+
roleMapForModelContext(model, context) {
|
|
2288
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2289
|
+
const output = yield this.outputForModel(model, context);
|
|
2290
|
+
let result;
|
|
2291
|
+
if (output != null && this.isUsableOutputForRoles(output, context)) {
|
|
2292
|
+
result = yield this.getRoleMapForOutput(output, context, model);
|
|
2293
|
+
} else {
|
|
2294
|
+
result = noAccessContextGrantedModelRoles(context, output);
|
|
2295
|
+
}
|
|
2296
|
+
return result;
|
|
2297
|
+
});
|
|
2298
|
+
}
|
|
2299
|
+
getRoleMapForOutput(output, context, model) {
|
|
2300
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2301
|
+
const roleMap = yield this.roleMapForModel(output, context, model);
|
|
2302
|
+
return contextGrantedModelRoles(context, output, roleMap);
|
|
2303
|
+
});
|
|
2304
|
+
}
|
|
2305
|
+
isUsableOutputForRoles(output, context) {
|
|
2306
|
+
return true; // can override in parent functions to further filter roles.
|
|
2307
|
+
}
|
|
2308
|
+
}
|
|
2309
|
+
|
|
2310
|
+
// MARK: String
|
|
2311
|
+
function transformStringToBoolean(defaultValue) {
|
|
2312
|
+
return params => {
|
|
2313
|
+
if (params.value) {
|
|
2314
|
+
switch (params.value.toLowerCase()) {
|
|
2315
|
+
case 't':
|
|
2316
|
+
case 'true':
|
|
2317
|
+
return true;
|
|
2318
|
+
case 'f':
|
|
2319
|
+
case 'false':
|
|
2320
|
+
return false;
|
|
2321
|
+
default:
|
|
2322
|
+
return defaultValue;
|
|
2323
|
+
}
|
|
2324
|
+
} else {
|
|
2325
|
+
return defaultValue;
|
|
2326
|
+
}
|
|
2327
|
+
};
|
|
2328
|
+
}
|
|
2329
|
+
// MARK: Comma Separated Values
|
|
2330
|
+
function transformCommaSeparatedValueToArray(mapFn) {
|
|
2331
|
+
return params => {
|
|
2332
|
+
let result;
|
|
2333
|
+
if (params.value) {
|
|
2334
|
+
if (Array.isArray(params.value)) {
|
|
2335
|
+
result = params.value;
|
|
2336
|
+
} else {
|
|
2337
|
+
result = util.splitCommaSeparatedString(params.value, mapFn);
|
|
2338
|
+
}
|
|
2339
|
+
}
|
|
2340
|
+
return result;
|
|
2341
|
+
};
|
|
2342
|
+
}
|
|
2343
|
+
const transformCommaSeparatedNumberValueToArray = transformCommaSeparatedValueToArray(x => Number(x));
|
|
2344
|
+
const transformCommaSeparatedStringValueToArray = transformCommaSeparatedValueToArray(x => x);
|
|
2345
|
+
|
|
2346
|
+
// MARK: Transform Annotations
|
|
2347
|
+
function TransformCommaSeparatedValueToArray(mapFn) {
|
|
2348
|
+
return classTransformer.Transform(transformCommaSeparatedValueToArray(mapFn));
|
|
2349
|
+
}
|
|
2350
|
+
const TransformCommaSeparatedStringValueToArray = () => classTransformer.Transform(transformCommaSeparatedStringValueToArray);
|
|
2351
|
+
const TransformCommaSeparatedNumberValueToArray = () => classTransformer.Transform(transformCommaSeparatedNumberValueToArray);
|
|
2352
|
+
const TransformStringValueToBoolean = () => classTransformer.Transform(transformStringToBoolean());
|
|
2353
|
+
|
|
2354
|
+
var DESCRIPTORS = descriptors;
|
|
2355
|
+
var uncurryThis = functionUncurryThis;
|
|
2356
|
+
var call = functionCall;
|
|
2357
|
+
var fails = fails$e;
|
|
2358
|
+
var objectKeys = objectKeys$2;
|
|
2359
|
+
var getOwnPropertySymbolsModule = objectGetOwnPropertySymbols;
|
|
2360
|
+
var propertyIsEnumerableModule = objectPropertyIsEnumerable;
|
|
2361
|
+
var toObject = toObject$3;
|
|
2362
|
+
var IndexedObject = indexedObject;
|
|
2363
|
+
|
|
2364
|
+
// eslint-disable-next-line es/no-object-assign -- safe
|
|
2365
|
+
var $assign = Object.assign;
|
|
2366
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
2367
|
+
var defineProperty = Object.defineProperty;
|
|
2368
|
+
var concat = uncurryThis([].concat);
|
|
2369
|
+
|
|
2370
|
+
// `Object.assign` method
|
|
2371
|
+
// https://tc39.es/ecma262/#sec-object.assign
|
|
2372
|
+
var objectAssign = !$assign || fails(function () {
|
|
2373
|
+
// should have correct order of operations (Edge bug)
|
|
2374
|
+
if (DESCRIPTORS && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {
|
|
2375
|
+
enumerable: true,
|
|
2376
|
+
get: function () {
|
|
2377
|
+
defineProperty(this, 'b', {
|
|
2378
|
+
value: 3,
|
|
2379
|
+
enumerable: false
|
|
2380
|
+
});
|
|
2381
|
+
}
|
|
2382
|
+
}), { b: 2 })).b !== 1) return true;
|
|
2383
|
+
// should work with symbols and should have deterministic property order (V8 bug)
|
|
2384
|
+
var A = {};
|
|
2385
|
+
var B = {};
|
|
2386
|
+
// eslint-disable-next-line es/no-symbol -- safe
|
|
2387
|
+
var symbol = Symbol('assign detection');
|
|
2388
|
+
var alphabet = 'abcdefghijklmnopqrst';
|
|
2389
|
+
A[symbol] = 7;
|
|
2390
|
+
alphabet.split('').forEach(function (chr) { B[chr] = chr; });
|
|
2391
|
+
return $assign({}, A)[symbol] !== 7 || objectKeys($assign({}, B)).join('') !== alphabet;
|
|
2392
|
+
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
|
|
2393
|
+
var T = toObject(target);
|
|
2394
|
+
var argumentsLength = arguments.length;
|
|
2395
|
+
var index = 1;
|
|
2396
|
+
var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
|
|
2397
|
+
var propertyIsEnumerable = propertyIsEnumerableModule.f;
|
|
2398
|
+
while (argumentsLength > index) {
|
|
2399
|
+
var S = IndexedObject(arguments[index++]);
|
|
2400
|
+
var keys = getOwnPropertySymbols ? concat(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);
|
|
2401
|
+
var length = keys.length;
|
|
2402
|
+
var j = 0;
|
|
2403
|
+
var key;
|
|
2404
|
+
while (length > j) {
|
|
2405
|
+
key = keys[j++];
|
|
2406
|
+
if (!DESCRIPTORS || call(propertyIsEnumerable, S, key)) T[key] = S[key];
|
|
2407
|
+
}
|
|
2408
|
+
} return T;
|
|
2409
|
+
} : $assign;
|
|
2410
|
+
|
|
2411
|
+
var $ = _export;
|
|
2412
|
+
var assign = objectAssign;
|
|
2413
|
+
|
|
2414
|
+
// `Object.assign` method
|
|
2415
|
+
// https://tc39.es/ecma262/#sec-object.assign
|
|
2416
|
+
// eslint-disable-next-line es/no-object-assign -- required for testing
|
|
2417
|
+
$({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
|
|
2418
|
+
assign: assign
|
|
2419
|
+
});
|
|
2420
|
+
|
|
2421
|
+
function transformAndValidateObject(config) {
|
|
2422
|
+
const transformToResult = transformAndValidateObjectResult(config.classType, config.fn, config.optionsForContext);
|
|
2423
|
+
const {
|
|
2424
|
+
handleValidationError
|
|
2425
|
+
} = config;
|
|
2426
|
+
return (input, context) => transformToResult(input, context).then(x => __awaiter(this, void 0, void 0, function* () {
|
|
2427
|
+
const object = x.object;
|
|
2428
|
+
let result;
|
|
2429
|
+
if (x.success) {
|
|
2430
|
+
result = x.result;
|
|
2431
|
+
} else {
|
|
2432
|
+
result = yield handleValidationError(x.validationErrors);
|
|
2433
|
+
}
|
|
2434
|
+
return {
|
|
2435
|
+
object,
|
|
2436
|
+
result
|
|
2437
|
+
};
|
|
2438
|
+
}));
|
|
2439
|
+
}
|
|
2440
|
+
/**
|
|
2441
|
+
* Creates a new TransformAndValidateObjectFactory.
|
|
2442
|
+
*
|
|
2443
|
+
* @param defaults
|
|
2444
|
+
* @returns
|
|
2445
|
+
*/
|
|
2446
|
+
function transformAndValidateObjectFactory(defaults) {
|
|
2447
|
+
const {
|
|
2448
|
+
handleValidationError: defaultHandleValidationError,
|
|
2449
|
+
optionsForContext
|
|
2450
|
+
} = defaults;
|
|
2451
|
+
return (classType, fn, handleValidationError) => {
|
|
2452
|
+
const config = {
|
|
2453
|
+
classType,
|
|
2454
|
+
fn,
|
|
2455
|
+
handleValidationError: handleValidationError !== null && handleValidationError !== void 0 ? handleValidationError : defaultHandleValidationError,
|
|
2456
|
+
optionsForContext
|
|
2457
|
+
};
|
|
2458
|
+
return transformAndValidateObject(config);
|
|
2459
|
+
};
|
|
2460
|
+
}
|
|
2461
|
+
/**
|
|
2462
|
+
* Factory function that wraps the input class type and handler function to first transform the input object to a the given class, and then validate it.
|
|
2463
|
+
*
|
|
2464
|
+
* @param classType
|
|
2465
|
+
* @param fn
|
|
2466
|
+
* @returns
|
|
2467
|
+
*/
|
|
2468
|
+
function transformAndValidateObjectResult(classType, fn, inputOptionsForContext) {
|
|
2469
|
+
const optionsForContext = inputOptionsForContext !== null && inputOptionsForContext !== void 0 ? inputOptionsForContext : () => ({});
|
|
2470
|
+
return (input, context) => __awaiter(this, void 0, void 0, function* () {
|
|
2471
|
+
const {
|
|
2472
|
+
transform: transformOptions,
|
|
2473
|
+
validate: validateOptions
|
|
2474
|
+
} = optionsForContext(context);
|
|
2475
|
+
const object = classTransformer.plainToInstance(classType, input, Object.assign(Object.assign({}, transformOptions), {
|
|
2476
|
+
// Note: Each variable on the target class must be marked with the @Expose() annotation.
|
|
2477
|
+
excludeExtraneousValues: true
|
|
2478
|
+
}));
|
|
2479
|
+
const validationErrors = yield classValidator.validate(object, validateOptions);
|
|
2480
|
+
if (validationErrors.length) {
|
|
2481
|
+
return {
|
|
2482
|
+
object,
|
|
2483
|
+
validationErrors,
|
|
2484
|
+
success: false
|
|
2485
|
+
};
|
|
2486
|
+
} else {
|
|
2487
|
+
const result = yield fn(object);
|
|
2488
|
+
return {
|
|
2489
|
+
object,
|
|
2490
|
+
result,
|
|
2491
|
+
success: true
|
|
2492
|
+
};
|
|
2493
|
+
}
|
|
2494
|
+
});
|
|
2495
|
+
}
|
|
2496
|
+
|
|
2497
|
+
function transformAndValidateFunctionResultFactory(defaults) {
|
|
2498
|
+
return toTransformAndValidateFunctionResultFactory(transformAndValidateObjectFactory(defaults));
|
|
2499
|
+
}
|
|
2500
|
+
function toTransformAndValidateFunctionResultFactory(transformAndValidateObjectFactory) {
|
|
2501
|
+
return (classType, fn, handleValidationError) => {
|
|
2502
|
+
const transformAndValidateObjectFn = transformAndValidateObjectFactory(classType, fn, handleValidationError);
|
|
2503
|
+
return (input, context) => {
|
|
2504
|
+
return toTransformAndValidateFunctionResult(transformAndValidateObjectFn(input, context));
|
|
2505
|
+
};
|
|
2506
|
+
};
|
|
2507
|
+
}
|
|
2508
|
+
function toTransformAndValidateFunctionResult(objectOutput) {
|
|
2509
|
+
return util.mapPromiseOrValue(objectOutput, x => {
|
|
2510
|
+
const {
|
|
2511
|
+
object,
|
|
2512
|
+
result
|
|
2513
|
+
} = x;
|
|
2514
|
+
const fnResult = result;
|
|
2515
|
+
fnResult.params = object;
|
|
2516
|
+
return fnResult;
|
|
2517
|
+
});
|
|
2518
|
+
}
|
|
2519
|
+
|
|
2520
|
+
function transformAndValidateResultFactory(defaults) {
|
|
2521
|
+
const factory = transformAndValidateObjectFactory(defaults);
|
|
2522
|
+
return (classType, fn, handleValidationError) => {
|
|
2523
|
+
const transformAndValidateObjectFn = factory(classType, fn, handleValidationError);
|
|
2524
|
+
return (input, context) => __awaiter(this, void 0, void 0, function* () {
|
|
2525
|
+
const {
|
|
2526
|
+
result
|
|
2527
|
+
} = yield transformAndValidateObjectFn(input, context);
|
|
2528
|
+
return result;
|
|
2529
|
+
});
|
|
2530
|
+
};
|
|
2531
|
+
}
|
|
2532
|
+
|
|
2533
|
+
/**
|
|
2534
|
+
* isISO8601DayString validator
|
|
2535
|
+
*/
|
|
2536
|
+
function IsISO8601DayString(validationOptions) {
|
|
2537
|
+
return function (object, propertyName) {
|
|
2538
|
+
classValidator.registerDecorator({
|
|
2539
|
+
name: 'isISO8601DayString',
|
|
2540
|
+
target: object.constructor,
|
|
2541
|
+
propertyName: propertyName,
|
|
2542
|
+
options: validationOptions,
|
|
2543
|
+
validator: {
|
|
2544
|
+
validate: util.isISO8601DayString,
|
|
2545
|
+
defaultMessage(args) {
|
|
2546
|
+
return `"${args.value}" is not a ISO8601DayString.`;
|
|
2547
|
+
}
|
|
2548
|
+
}
|
|
2549
|
+
});
|
|
2550
|
+
};
|
|
2551
|
+
}
|
|
2552
|
+
|
|
2553
|
+
/**
|
|
2554
|
+
* isE164PhoneNumber validator that does not allowed extensions.
|
|
2555
|
+
*/
|
|
2556
|
+
function IsE164PhoneNumber(validationOptions) {
|
|
2557
|
+
return function (object, propertyName) {
|
|
2558
|
+
classValidator.registerDecorator({
|
|
2559
|
+
name: 'isE164PhoneNumber',
|
|
2560
|
+
target: object.constructor,
|
|
2561
|
+
propertyName: propertyName,
|
|
2562
|
+
options: validationOptions,
|
|
2563
|
+
validator: {
|
|
2564
|
+
validate: x => util.isE164PhoneNumber(x, false),
|
|
2565
|
+
defaultMessage(args) {
|
|
2566
|
+
return `"${args.value}" is not a E164PhoneNumber with no extension.`;
|
|
2567
|
+
}
|
|
2568
|
+
}
|
|
2569
|
+
});
|
|
2570
|
+
};
|
|
2571
|
+
}
|
|
2572
|
+
/**
|
|
2573
|
+
* isE164PhoneNumber validator that allows extensions.
|
|
2574
|
+
*
|
|
2575
|
+
* @param validationOptions
|
|
2576
|
+
* @returns
|
|
2577
|
+
*/
|
|
2578
|
+
function IsE164PhoneNumberWithOptionalExtension(validationOptions) {
|
|
2579
|
+
return function (object, propertyName) {
|
|
2580
|
+
classValidator.registerDecorator({
|
|
2581
|
+
name: 'isE164PhoneNumber',
|
|
2582
|
+
target: object.constructor,
|
|
2583
|
+
propertyName: propertyName,
|
|
2584
|
+
options: validationOptions,
|
|
2585
|
+
validator: {
|
|
2586
|
+
validate: x => util.isE164PhoneNumber(x, true),
|
|
2587
|
+
defaultMessage(args) {
|
|
2588
|
+
return `"${args.value}" is not an E164PhoneNumber or has an invalid extension.`;
|
|
2589
|
+
}
|
|
2590
|
+
}
|
|
2591
|
+
});
|
|
2592
|
+
};
|
|
2593
|
+
}
|
|
2594
|
+
/**
|
|
2595
|
+
* isE164PhoneNumberWithExtension validator
|
|
2596
|
+
*
|
|
2597
|
+
* @param validationOptions
|
|
2598
|
+
* @returns
|
|
2599
|
+
*/
|
|
2600
|
+
function IsE164PhoneNumberWithExtension(validationOptions) {
|
|
2601
|
+
return function (object, propertyName) {
|
|
2602
|
+
classValidator.registerDecorator({
|
|
2603
|
+
name: 'isE164PhoneNumberWithExtension',
|
|
2604
|
+
target: object.constructor,
|
|
2605
|
+
propertyName: propertyName,
|
|
2606
|
+
options: validationOptions,
|
|
2607
|
+
validator: {
|
|
2608
|
+
validate: util.isE164PhoneNumberWithExtension,
|
|
2609
|
+
defaultMessage(args) {
|
|
2610
|
+
return `"${args.value}" is not a E164PhoneNumberWithExtension.`;
|
|
2611
|
+
}
|
|
2612
|
+
}
|
|
2613
|
+
});
|
|
2614
|
+
};
|
|
2615
|
+
}
|
|
2616
|
+
|
|
2617
|
+
/**
|
|
2618
|
+
* isWebsiteUrl validator
|
|
2619
|
+
*/
|
|
2620
|
+
function IsWebsiteUrl(validationOptions) {
|
|
2621
|
+
return function (object, propertyName) {
|
|
2622
|
+
classValidator.registerDecorator({
|
|
2623
|
+
name: 'isWebsiteUrl',
|
|
2624
|
+
target: object.constructor,
|
|
2625
|
+
propertyName: propertyName,
|
|
2626
|
+
options: validationOptions,
|
|
2627
|
+
validator: {
|
|
2628
|
+
validate: util.isWebsiteUrl,
|
|
2629
|
+
defaultMessage(args) {
|
|
2630
|
+
return `"${args.value}" is not a valid website url`;
|
|
2631
|
+
}
|
|
2632
|
+
}
|
|
2633
|
+
});
|
|
2634
|
+
};
|
|
2635
|
+
}
|
|
2636
|
+
/**
|
|
2637
|
+
* isWebsiteUrlWithPrefix validator
|
|
2638
|
+
*/
|
|
2639
|
+
function IsWebsiteUrlWithPrefix(validationOptions) {
|
|
2640
|
+
return function (object, propertyName) {
|
|
2641
|
+
classValidator.registerDecorator({
|
|
2642
|
+
name: 'isWebsiteUrlWithPrefix',
|
|
2643
|
+
target: object.constructor,
|
|
2644
|
+
propertyName: propertyName,
|
|
2645
|
+
options: validationOptions,
|
|
2646
|
+
validator: {
|
|
2647
|
+
validate: util.isWebsiteUrlWithPrefix,
|
|
2648
|
+
defaultMessage(args) {
|
|
2649
|
+
return `"${args.value}" is not a valid website url with a http/https prefix.`;
|
|
2650
|
+
}
|
|
2651
|
+
}
|
|
2652
|
+
});
|
|
2653
|
+
};
|
|
2654
|
+
}
|
|
2655
|
+
|
|
2656
|
+
exports.ADDRESS_CITY_MAX_LENGTH = ADDRESS_CITY_MAX_LENGTH;
|
|
2657
|
+
exports.ADDRESS_COUNTRY_MAX_LENGTH = ADDRESS_COUNTRY_MAX_LENGTH;
|
|
2658
|
+
exports.ADDRESS_LINE_MAX_LENGTH = ADDRESS_LINE_MAX_LENGTH;
|
|
2659
|
+
exports.ADDRESS_STATE_CODE_MAX_LENGTH = ADDRESS_STATE_CODE_MAX_LENGTH;
|
|
2660
|
+
exports.ADDRESS_STATE_MAX_LENGTH = ADDRESS_STATE_MAX_LENGTH;
|
|
2661
|
+
exports.ADDRESS_ZIP_MAX_LENGTH = ADDRESS_ZIP_MAX_LENGTH;
|
|
2662
|
+
exports.AbstractModelPermissionService = AbstractModelPermissionService;
|
|
2663
|
+
exports.AbstractUnitedStatesAddressWithoutStateParams = AbstractUnitedStatesAddressWithoutStateParams;
|
|
2664
|
+
exports.CASHAPP_BASE_URL = CASHAPP_BASE_URL;
|
|
2665
|
+
exports.CASHAPP_USERNAME_PREFIX = CASHAPP_USERNAME_PREFIX;
|
|
2666
|
+
exports.CASHAPP_WEBSITE_LINK_TYPE = CASHAPP_WEBSITE_LINK_TYPE;
|
|
2667
|
+
exports.EMAIL_URL_WEBSITE_LINK_TYPE = EMAIL_URL_WEBSITE_LINK_TYPE;
|
|
2668
|
+
exports.FACEBOOK_BASE_URL = FACEBOOK_BASE_URL;
|
|
2669
|
+
exports.FACEBOOK_WEBSITE_LINK_TYPE = FACEBOOK_WEBSITE_LINK_TYPE;
|
|
2670
|
+
exports.FULL_ACCESS_ROLE_KEY = FULL_ACCESS_ROLE_KEY;
|
|
2671
|
+
exports.GRANTED_ADMIN_ROLE_KEY = GRANTED_ADMIN_ROLE_KEY;
|
|
2672
|
+
exports.GRANTED_DELETE_ROLE_KEY = GRANTED_DELETE_ROLE_KEY;
|
|
2673
|
+
exports.GRANTED_OWNER_ROLE_KEY = GRANTED_OWNER_ROLE_KEY;
|
|
2674
|
+
exports.GRANTED_READ_ROLE_KEY = GRANTED_READ_ROLE_KEY;
|
|
2675
|
+
exports.GRANTED_SYS_ADMIN_ROLE_KEY = GRANTED_SYS_ADMIN_ROLE_KEY;
|
|
2676
|
+
exports.GRANTED_UPDATE_ROLE_KEY = GRANTED_UPDATE_ROLE_KEY;
|
|
2677
|
+
exports.GrantedRoleMapReaderInstance = GrantedRoleMapReaderInstance;
|
|
2678
|
+
exports.INSTAGRAM_BASE_URL = INSTAGRAM_BASE_URL;
|
|
2679
|
+
exports.INSTAGRAM_WEBSITE_LINK_TYPE = INSTAGRAM_WEBSITE_LINK_TYPE;
|
|
2680
|
+
exports.IsE164PhoneNumber = IsE164PhoneNumber;
|
|
2681
|
+
exports.IsE164PhoneNumberWithExtension = IsE164PhoneNumberWithExtension;
|
|
2682
|
+
exports.IsE164PhoneNumberWithOptionalExtension = IsE164PhoneNumberWithOptionalExtension;
|
|
2683
|
+
exports.IsISO8601DayString = IsISO8601DayString;
|
|
2684
|
+
exports.IsWebsiteUrl = IsWebsiteUrl;
|
|
2685
|
+
exports.IsWebsiteUrlWithPrefix = IsWebsiteUrlWithPrefix;
|
|
2686
|
+
exports.NO_ACCESS_ROLE_KEY = NO_ACCESS_ROLE_KEY;
|
|
2687
|
+
exports.PAYPAL_BASE_URL = PAYPAL_BASE_URL;
|
|
2688
|
+
exports.PAYPAL_WEBSITE_LINK_TYPE = PAYPAL_WEBSITE_LINK_TYPE;
|
|
2689
|
+
exports.PHONE_URL_WEBSITE_LINK_TYPE = PHONE_URL_WEBSITE_LINK_TYPE;
|
|
2690
|
+
exports.SNAPCHAT_BASE_URL = SNAPCHAT_BASE_URL;
|
|
2691
|
+
exports.SNAPCHAT_WEBSITE_LINK_ISOLATE_PROFILE_ID = SNAPCHAT_WEBSITE_LINK_ISOLATE_PROFILE_ID;
|
|
2692
|
+
exports.SNAPCHAT_WEBSITE_LINK_TYPE = SNAPCHAT_WEBSITE_LINK_TYPE;
|
|
2693
|
+
exports.SPOTIFY_BASE_URL = SPOTIFY_BASE_URL;
|
|
2694
|
+
exports.SPOTIFY_WEBSITE_LINK_ISOLATE_PROFILE_ID = SPOTIFY_WEBSITE_LINK_ISOLATE_PROFILE_ID;
|
|
2695
|
+
exports.SPOTIFY_WEBSITE_LINK_TYPE = SPOTIFY_WEBSITE_LINK_TYPE;
|
|
2696
|
+
exports.TIKTOK_BASE_URL = TIKTOK_BASE_URL;
|
|
2697
|
+
exports.TIKTOK_USERNAME_PREFIX = TIKTOK_USERNAME_PREFIX;
|
|
2698
|
+
exports.TIKTOK_WEBSITE_LINK_TYPE = TIKTOK_WEBSITE_LINK_TYPE;
|
|
2699
|
+
exports.TWITTER_BASE_URL = TWITTER_BASE_URL;
|
|
2700
|
+
exports.TWITTER_WEBSITE_LINK_TYPE = TWITTER_WEBSITE_LINK_TYPE;
|
|
2701
|
+
exports.TransformCommaSeparatedNumberValueToArray = TransformCommaSeparatedNumberValueToArray;
|
|
2702
|
+
exports.TransformCommaSeparatedStringValueToArray = TransformCommaSeparatedStringValueToArray;
|
|
2703
|
+
exports.TransformCommaSeparatedValueToArray = TransformCommaSeparatedValueToArray;
|
|
2704
|
+
exports.TransformStringValueToBoolean = TransformStringValueToBoolean;
|
|
2705
|
+
exports.UNKNOWN_WEBSITE_LINK_TYPE = UNKNOWN_WEBSITE_LINK_TYPE;
|
|
2706
|
+
exports.UnitedStatesAddressWithStateCodeParams = UnitedStatesAddressWithStateCodeParams;
|
|
2707
|
+
exports.UnitedStatesAddressWithStateStringParams = UnitedStatesAddressWithStateStringParams;
|
|
2708
|
+
exports.VENMO_BASE_URL = VENMO_BASE_URL;
|
|
2709
|
+
exports.VENMO_WEBSITE_LINK_ISOLATE_PROFILE_ID = VENMO_WEBSITE_LINK_ISOLATE_PROFILE_ID;
|
|
2710
|
+
exports.VENMO_WEBSITE_LINK_TYPE = VENMO_WEBSITE_LINK_TYPE;
|
|
2711
|
+
exports.WEBSITE_FILE_LINK_DATA_MAX_LENGTH = WEBSITE_FILE_LINK_DATA_MAX_LENGTH;
|
|
2712
|
+
exports.WEBSITE_FILE_LINK_DATA_REGEX = WEBSITE_FILE_LINK_DATA_REGEX;
|
|
2713
|
+
exports.WEBSITE_FILE_LINK_ENCODE_SEPARATOR = WEBSITE_FILE_LINK_ENCODE_SEPARATOR;
|
|
2714
|
+
exports.WEBSITE_FILE_LINK_MIME_TYPE_MAX_LENGTH = WEBSITE_FILE_LINK_MIME_TYPE_MAX_LENGTH;
|
|
2715
|
+
exports.WEBSITE_FILE_LINK_MIME_TYPE_REGEX = WEBSITE_FILE_LINK_MIME_TYPE_REGEX;
|
|
2716
|
+
exports.WEBSITE_FILE_LINK_NAME_MAX_LENGTH = WEBSITE_FILE_LINK_NAME_MAX_LENGTH;
|
|
2717
|
+
exports.WEBSITE_FILE_LINK_TYPE_MAX_LENGTH = WEBSITE_FILE_LINK_TYPE_MAX_LENGTH;
|
|
2718
|
+
exports.WEBSITE_FILE_LINK_TYPE_REGEX = WEBSITE_FILE_LINK_TYPE_REGEX;
|
|
2719
|
+
exports.WEBSITE_FILE_LINK_WEBSITE_LINK_TYPE = WEBSITE_FILE_LINK_WEBSITE_LINK_TYPE;
|
|
2720
|
+
exports.WEBSITE_LINK_ENCODED_DATA_MAX_LENGTH = WEBSITE_LINK_ENCODED_DATA_MAX_LENGTH;
|
|
2721
|
+
exports.WEBSITE_LINK_ISOLATE_BASE_URL_PROFILE_ID = WEBSITE_LINK_ISOLATE_BASE_URL_PROFILE_ID;
|
|
2722
|
+
exports.WEBSITE_LINK_TYPE_MAX_LENGTH = WEBSITE_LINK_TYPE_MAX_LENGTH;
|
|
2723
|
+
exports.WEBSITE_LINK_TYPE_REGEX = WEBSITE_LINK_TYPE_REGEX;
|
|
2724
|
+
exports.WEBSITE_URL_WEBSITE_LINK_TYPE = WEBSITE_URL_WEBSITE_LINK_TYPE;
|
|
2725
|
+
exports.WebsiteFileLink = WebsiteFileLink;
|
|
2726
|
+
exports.WebsiteLink = WebsiteLink;
|
|
2727
|
+
exports.YOUTUBE_BASE_URL = YOUTUBE_BASE_URL;
|
|
2728
|
+
exports.YOUTUBE_WEBSITE_LINK_ISOLATE_PROFILE_ID = YOUTUBE_WEBSITE_LINK_ISOLATE_PROFILE_ID;
|
|
2729
|
+
exports.YOUTUBE_WEBSITE_LINK_TYPE = YOUTUBE_WEBSITE_LINK_TYPE;
|
|
2730
|
+
exports.cashappProfileUrl = cashappProfileUrl;
|
|
2731
|
+
exports.cashappProfileUrlToWebsiteLink = cashappProfileUrlToWebsiteLink;
|
|
2732
|
+
exports.contextGrantedModelRoles = contextGrantedModelRoles;
|
|
2733
|
+
exports.decodeWebsiteLinkEncodedDataToWebsiteFileLink = decodeWebsiteLinkEncodedDataToWebsiteFileLink;
|
|
2734
|
+
exports.emailAddressToWebsiteLink = emailAddressToWebsiteLink;
|
|
2735
|
+
exports.encodeWebsiteFileLinkToWebsiteLinkEncodedData = encodeWebsiteFileLinkToWebsiteLinkEncodedData;
|
|
2736
|
+
exports.facebookProfileUrl = facebookProfileUrl;
|
|
2737
|
+
exports.facebookProfileUrlToWebsiteLink = facebookProfileUrlToWebsiteLink;
|
|
2738
|
+
exports.fullAccessGrantedModelRoles = fullAccessGrantedModelRoles;
|
|
2739
|
+
exports.fullAccessRoleMap = fullAccessRoleMap;
|
|
2740
|
+
exports.grantedRoleKeysMapFromArray = grantedRoleKeysMapFromArray;
|
|
2741
|
+
exports.grantedRoleMapReader = grantedRoleMapReader;
|
|
2742
|
+
exports.instagramProfileUrl = instagramProfileUrl;
|
|
2743
|
+
exports.instagramProfileUrlToWebsiteLink = instagramProfileUrlToWebsiteLink;
|
|
2744
|
+
exports.isFullAccessRoleMap = isFullAccessRoleMap;
|
|
2745
|
+
exports.isGrantedAdminLevelRole = isGrantedAdminLevelRole;
|
|
2746
|
+
exports.isNoAccessRoleMap = isNoAccessRoleMap;
|
|
2747
|
+
exports.isValidWebsiteLinkType = isValidWebsiteLinkType;
|
|
2748
|
+
exports.noAccessContextGrantedModelRoles = noAccessContextGrantedModelRoles;
|
|
2749
|
+
exports.noAccessRoleMap = noAccessRoleMap;
|
|
2750
|
+
exports.paypalProfileUrl = paypalProfileUrl;
|
|
2751
|
+
exports.paypalProfileUrlToWebsiteLink = paypalProfileUrlToWebsiteLink;
|
|
2752
|
+
exports.phoneNumberToWebsiteLink = phoneNumberToWebsiteLink;
|
|
2753
|
+
exports.snapchatProfileUrl = snapchatProfileUrl;
|
|
2754
|
+
exports.snapchatProfileUrlToWebsiteLink = snapchatProfileUrlToWebsiteLink;
|
|
2755
|
+
exports.spotifyProfileUrl = spotifyProfileUrl;
|
|
2756
|
+
exports.spotifyProfileUrlToWebsiteLink = spotifyProfileUrlToWebsiteLink;
|
|
2757
|
+
exports.tiktokProfileUrl = tiktokProfileUrl;
|
|
2758
|
+
exports.tiktokProfileUrlToWebsiteLink = tiktokProfileUrlToWebsiteLink;
|
|
2759
|
+
exports.toTransformAndValidateFunctionResult = toTransformAndValidateFunctionResult;
|
|
2760
|
+
exports.toTransformAndValidateFunctionResultFactory = toTransformAndValidateFunctionResultFactory;
|
|
2761
|
+
exports.transformAndValidateFunctionResultFactory = transformAndValidateFunctionResultFactory;
|
|
2762
|
+
exports.transformAndValidateObject = transformAndValidateObject;
|
|
2763
|
+
exports.transformAndValidateObjectFactory = transformAndValidateObjectFactory;
|
|
2764
|
+
exports.transformAndValidateObjectResult = transformAndValidateObjectResult;
|
|
2765
|
+
exports.transformAndValidateResultFactory = transformAndValidateResultFactory;
|
|
2766
|
+
exports.transformCommaSeparatedNumberValueToArray = transformCommaSeparatedNumberValueToArray;
|
|
2767
|
+
exports.transformCommaSeparatedStringValueToArray = transformCommaSeparatedStringValueToArray;
|
|
2768
|
+
exports.transformCommaSeparatedValueToArray = transformCommaSeparatedValueToArray;
|
|
2769
|
+
exports.transformStringToBoolean = transformStringToBoolean;
|
|
2770
|
+
exports.twitterProfileUrl = twitterProfileUrl;
|
|
2771
|
+
exports.twitterProfileUrlToWebsiteLink = twitterProfileUrlToWebsiteLink;
|
|
2772
|
+
exports.usernameFromUsernameOrWebsiteWithBaseUrlUsername = usernameFromUsernameOrWebsiteWithBaseUrlUsername;
|
|
2773
|
+
exports.usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername = usernameFromUsernameOrWebsiteWithOneOffBaseUrlUsername;
|
|
2774
|
+
exports.usernameOrWebsiteUrlToWebsiteUrl = usernameOrWebsiteUrlToWebsiteUrl;
|
|
2775
|
+
exports.venmoProfileUrl = venmoProfileUrl;
|
|
2776
|
+
exports.venmoProfileUrlToWebsiteLink = venmoProfileUrlToWebsiteLink;
|
|
2777
|
+
exports.websiteFileLinkToWebsiteLink = websiteFileLinkToWebsiteLink;
|
|
2778
|
+
exports.websiteLinkToWebsiteLinkFile = websiteLinkToWebsiteLinkFile;
|
|
2779
|
+
exports.websiteUrlToWebsiteLink = websiteUrlToWebsiteLink;
|
|
2780
|
+
exports.youtubeProfileUrl = youtubeProfileUrl;
|
|
2781
|
+
exports.youtubeProfileUrlToWebsiteLink = youtubeProfileUrlToWebsiteLink;
|