inferred-types 0.54.9 → 0.55.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/modules/constants/dist/index.cjs +118 -1
- package/modules/constants/dist/index.cjs.map +1 -1
- package/modules/constants/dist/index.d.ts +29 -1
- package/modules/constants/dist/index.js +113 -1
- package/modules/constants/dist/index.js.map +1 -1
- package/modules/inferred-types/dist/index.cjs +293 -16
- package/modules/inferred-types/dist/index.cjs.map +1 -1
- package/modules/inferred-types/dist/index.d.ts +21440 -20778
- package/modules/inferred-types/dist/index.js +277 -16
- package/modules/inferred-types/dist/index.js.map +1 -1
- package/modules/runtime/dist/index.cjs +187 -15
- package/modules/runtime/dist/index.cjs.map +1 -1
- package/modules/runtime/dist/index.d.ts +5420 -5137
- package/modules/runtime/dist/index.js +176 -15
- package/modules/runtime/dist/index.js.map +1 -1
- package/modules/types/dist/index.d.ts +9684 -9333
- package/package.json +3 -4
|
@@ -508,6 +508,73 @@ var HASH_TABLE_CHAR = {
|
|
|
508
508
|
...HASH_TABLE_SPECIAL
|
|
509
509
|
};
|
|
510
510
|
var HASH_TABLE_OTHER = "999";
|
|
511
|
+
var MIME_TYPES = [
|
|
512
|
+
// Application MIME Types
|
|
513
|
+
"application/json",
|
|
514
|
+
"application/xml",
|
|
515
|
+
"application/javascript",
|
|
516
|
+
"application/pdf",
|
|
517
|
+
"application/ld+json",
|
|
518
|
+
"application/octet-stream",
|
|
519
|
+
"application/x-www-form-urlencoded",
|
|
520
|
+
"application/vnd.api+json",
|
|
521
|
+
"application/msword",
|
|
522
|
+
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
|
|
523
|
+
"application/vnd.ms-excel",
|
|
524
|
+
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
|
525
|
+
"application/vnd.ms-powerpoint",
|
|
526
|
+
"application/vnd.openxmlformats-officedocument.presentationml.presentation",
|
|
527
|
+
// Text MIME Types
|
|
528
|
+
"text/plain",
|
|
529
|
+
"text/html",
|
|
530
|
+
"text/css",
|
|
531
|
+
"text/csv",
|
|
532
|
+
"text/javascript",
|
|
533
|
+
"text/markdown",
|
|
534
|
+
// Image MIME Types
|
|
535
|
+
"image/jpeg",
|
|
536
|
+
"image/png",
|
|
537
|
+
"image/gif",
|
|
538
|
+
"image/bmp",
|
|
539
|
+
"image/webp",
|
|
540
|
+
"image/svg+xml",
|
|
541
|
+
"image/tiff",
|
|
542
|
+
// Audio MIME Types
|
|
543
|
+
"audio/mpeg",
|
|
544
|
+
"audio/ogg",
|
|
545
|
+
"audio/wav",
|
|
546
|
+
"audio/webm",
|
|
547
|
+
"audio/flac",
|
|
548
|
+
// Video MIME Types
|
|
549
|
+
"video/mp4",
|
|
550
|
+
"video/mpeg",
|
|
551
|
+
"video/ogg",
|
|
552
|
+
"video/webm",
|
|
553
|
+
"video/quicktime",
|
|
554
|
+
// Multipart MIME Types
|
|
555
|
+
"multipart/form-data",
|
|
556
|
+
"multipart/mixed",
|
|
557
|
+
"multipart/alternative",
|
|
558
|
+
"multipart/related",
|
|
559
|
+
// Font MIME Types
|
|
560
|
+
"font/woff",
|
|
561
|
+
"font/woff2",
|
|
562
|
+
"font/ttf",
|
|
563
|
+
"font/otf",
|
|
564
|
+
// Other Common MIME Types
|
|
565
|
+
"application/rss+xml",
|
|
566
|
+
"application/atom+xml",
|
|
567
|
+
"application/x-pkcs12",
|
|
568
|
+
"application/x-shockwave-flash",
|
|
569
|
+
"application/x-www-form-urlencoded",
|
|
570
|
+
"application/x-font-ttf",
|
|
571
|
+
"application/x-font-opentype",
|
|
572
|
+
"application/x-font-woff",
|
|
573
|
+
"application/x-font-woff2",
|
|
574
|
+
"application/vnd.rar",
|
|
575
|
+
"application/zip",
|
|
576
|
+
"application/x-7z-compressed"
|
|
577
|
+
];
|
|
511
578
|
var IMAGE_FORMAT_LOOKUP = [
|
|
512
579
|
{ ext: "jpg", webFormat: true, other_ext: ["jpeg"] },
|
|
513
580
|
{ ext: "png", webFormat: true, other_ext: [] },
|
|
@@ -848,13 +915,51 @@ var IPv6 = {
|
|
|
848
915
|
var IPv4 = {
|
|
849
916
|
Loopback: "127.0.0.1"
|
|
850
917
|
};
|
|
918
|
+
var NETWORK_PROTOCOL_INSECURE = [
|
|
919
|
+
"http",
|
|
920
|
+
"ftp",
|
|
921
|
+
"ws",
|
|
922
|
+
"dns",
|
|
923
|
+
"telnet",
|
|
924
|
+
"imap",
|
|
925
|
+
"pop3",
|
|
926
|
+
"smtp"
|
|
927
|
+
];
|
|
928
|
+
var NETWORK_PROTOCOL_SECURE = [
|
|
929
|
+
"https",
|
|
930
|
+
"sftp",
|
|
931
|
+
"wss",
|
|
932
|
+
"sdns",
|
|
933
|
+
"ssh"
|
|
934
|
+
];
|
|
935
|
+
var NETWORK_PROTOCOL = [
|
|
936
|
+
...NETWORK_PROTOCOL_INSECURE,
|
|
937
|
+
...NETWORK_PROTOCOL_SECURE
|
|
938
|
+
];
|
|
851
939
|
var NETWORK_PROTOCOL_LOOKUP = {
|
|
852
940
|
http: ["http", "https"],
|
|
853
941
|
ftp: ["ftp", "sftp"],
|
|
854
942
|
file: ["", "file"],
|
|
855
943
|
ws: ["ws", "wss"],
|
|
856
944
|
ssh: ["", "ssh"],
|
|
857
|
-
scp: ["", "scp"]
|
|
945
|
+
scp: ["", "scp"],
|
|
946
|
+
telnet: ["telnet", ""],
|
|
947
|
+
dns: ["dns", "sdns"]
|
|
948
|
+
};
|
|
949
|
+
var PROTOCOL_DEFAULT_PORTS = {
|
|
950
|
+
http: 80,
|
|
951
|
+
https: 443,
|
|
952
|
+
ws: 80,
|
|
953
|
+
wss: 443,
|
|
954
|
+
ssh: 22,
|
|
955
|
+
telnet: 23,
|
|
956
|
+
dns: 53,
|
|
957
|
+
sdns: 853,
|
|
958
|
+
smtp: 25,
|
|
959
|
+
imap: 142,
|
|
960
|
+
pop3: 110,
|
|
961
|
+
ftp: 21,
|
|
962
|
+
sftp: 22
|
|
858
963
|
};
|
|
859
964
|
var TOP_LEVEL_DOMAINS = [
|
|
860
965
|
"com",
|
|
@@ -3156,13 +3261,51 @@ var AREA_METRICS_LOOKUP2 = [
|
|
|
3156
3261
|
{ abbrev: "acre", name: "acre" },
|
|
3157
3262
|
{ abbrev: "ha", name: "hectare" }
|
|
3158
3263
|
];
|
|
3264
|
+
var NETWORK_PROTOCOL_INSECURE2 = [
|
|
3265
|
+
"http",
|
|
3266
|
+
"ftp",
|
|
3267
|
+
"ws",
|
|
3268
|
+
"dns",
|
|
3269
|
+
"telnet",
|
|
3270
|
+
"imap",
|
|
3271
|
+
"pop3",
|
|
3272
|
+
"smtp"
|
|
3273
|
+
];
|
|
3274
|
+
var NETWORK_PROTOCOL_SECURE2 = [
|
|
3275
|
+
"https",
|
|
3276
|
+
"sftp",
|
|
3277
|
+
"wss",
|
|
3278
|
+
"sdns",
|
|
3279
|
+
"ssh"
|
|
3280
|
+
];
|
|
3281
|
+
var NETWORK_PROTOCOL2 = [
|
|
3282
|
+
...NETWORK_PROTOCOL_INSECURE2,
|
|
3283
|
+
...NETWORK_PROTOCOL_SECURE2
|
|
3284
|
+
];
|
|
3159
3285
|
var NETWORK_PROTOCOL_LOOKUP2 = {
|
|
3160
3286
|
http: ["http", "https"],
|
|
3161
3287
|
ftp: ["ftp", "sftp"],
|
|
3162
3288
|
file: ["", "file"],
|
|
3163
3289
|
ws: ["ws", "wss"],
|
|
3164
3290
|
ssh: ["", "ssh"],
|
|
3165
|
-
scp: ["", "scp"]
|
|
3291
|
+
scp: ["", "scp"],
|
|
3292
|
+
telnet: ["telnet", ""],
|
|
3293
|
+
dns: ["dns", "sdns"]
|
|
3294
|
+
};
|
|
3295
|
+
var PROTOCOL_DEFAULT_PORTS2 = {
|
|
3296
|
+
http: 80,
|
|
3297
|
+
https: 443,
|
|
3298
|
+
ws: 80,
|
|
3299
|
+
wss: 443,
|
|
3300
|
+
ssh: 22,
|
|
3301
|
+
telnet: 23,
|
|
3302
|
+
dns: 53,
|
|
3303
|
+
sdns: 853,
|
|
3304
|
+
smtp: 25,
|
|
3305
|
+
imap: 142,
|
|
3306
|
+
pop3: 110,
|
|
3307
|
+
ftp: 21,
|
|
3308
|
+
sftp: 22
|
|
3166
3309
|
};
|
|
3167
3310
|
var Never2 = createConstant2("never");
|
|
3168
3311
|
var US_NEWS2 = [
|
|
@@ -4823,7 +4966,7 @@ var filter = "NOT READY";
|
|
|
4823
4966
|
function find(list2, deref = null) {
|
|
4824
4967
|
return (comparator) => {
|
|
4825
4968
|
return list2.find((i) => {
|
|
4826
|
-
const val = deref ?
|
|
4969
|
+
const val = deref ? isObject(i) || isArray(i) ? deref in i ? i[deref] : void 0 : i : i;
|
|
4827
4970
|
return val === comparator;
|
|
4828
4971
|
});
|
|
4829
4972
|
};
|
|
@@ -5497,6 +5640,9 @@ var isRatio = (val) => /\d{1,4}\s*\/\s*\d{1,4}/.test(val);
|
|
|
5497
5640
|
function isCssAspectRatio(val) {
|
|
5498
5641
|
return isString(val) && val.split(/\s+/).every((i) => tokens.includes(i) || isRatio(i));
|
|
5499
5642
|
}
|
|
5643
|
+
function isCsv(val) {
|
|
5644
|
+
return isString(val) && val.includes(",") && !val.startsWith(",");
|
|
5645
|
+
}
|
|
5500
5646
|
function isDefined(value) {
|
|
5501
5647
|
return typeof value !== "undefined";
|
|
5502
5648
|
}
|
|
@@ -5513,6 +5659,9 @@ function isEmail(val) {
|
|
|
5513
5659
|
const firstChar = val[0].toLowerCase();
|
|
5514
5660
|
return isString(val) && (LOWER_ALPHA_CHARS2.includes(firstChar) && parts.length === 2 && domain.length >= 1 && tld.length >= 2);
|
|
5515
5661
|
}
|
|
5662
|
+
function isEmpty(val) {
|
|
5663
|
+
return isUndefined(val) || isNull(val) || isString(val) && val.length === 0 || isObject(val) && Object.keys(val).length === 0 || isArray(val) && val.length === 0;
|
|
5664
|
+
}
|
|
5516
5665
|
function isErrorCondition(value, kind = null) {
|
|
5517
5666
|
return isObject(value) && "__kind" in value && value.__kind === "ErrorCondition" && "kind" in value ? kind !== null ? value.kind === kind : true : false;
|
|
5518
5667
|
}
|
|
@@ -5550,7 +5699,7 @@ function isPhoneNumber(val) {
|
|
|
5550
5699
|
const svelte = String(val).trim();
|
|
5551
5700
|
const chars = svelte.split("");
|
|
5552
5701
|
const numeric = retainChars(svelte, ...NUMERIC_CHAR2);
|
|
5553
|
-
const
|
|
5702
|
+
const valid2 = ["+", "(", ...NUMERIC_CHAR2];
|
|
5554
5703
|
const nothing = stripChars(svelte, ...[
|
|
5555
5704
|
...NUMERIC_CHAR2,
|
|
5556
5705
|
...WHITESPACE_CHARS2,
|
|
@@ -5560,7 +5709,7 @@ function isPhoneNumber(val) {
|
|
|
5560
5709
|
".",
|
|
5561
5710
|
"-"
|
|
5562
5711
|
]);
|
|
5563
|
-
return chars.every((i) =>
|
|
5712
|
+
return chars.every((i) => valid2.includes(i)) && svelte.startsWith(`+`) ? numeric.length >= 8 : svelte.startsWith(`00`) ? numeric.length >= 10 : numeric.length >= 7 && nothing === "";
|
|
5564
5713
|
}
|
|
5565
5714
|
function isReadonlyArray(value) {
|
|
5566
5715
|
return Array.isArray(value) === true;
|
|
@@ -5623,6 +5772,19 @@ function isUrl(val, ...protocols) {
|
|
|
5623
5772
|
const p = protocols.length === 0 ? ["http", "https"] : protocols;
|
|
5624
5773
|
return isString(val) && p.some((i) => val.startsWith(`${i}://`));
|
|
5625
5774
|
}
|
|
5775
|
+
var VALID = [
|
|
5776
|
+
...ALPHA_CHARS2,
|
|
5777
|
+
...NUMERIC_CHAR2,
|
|
5778
|
+
"_",
|
|
5779
|
+
"."
|
|
5780
|
+
];
|
|
5781
|
+
var alpha = null;
|
|
5782
|
+
function valid(chars) {
|
|
5783
|
+
return chars.every((i) => VALID.includes(i));
|
|
5784
|
+
}
|
|
5785
|
+
function isVariable(val) {
|
|
5786
|
+
return isString(val) && startsWith(alpha)(val) && valid(asChars(val));
|
|
5787
|
+
}
|
|
5626
5788
|
function separate(s) {
|
|
5627
5789
|
return stripWhile(s.toLowerCase(), ...NUMERIC_CHAR2).trim();
|
|
5628
5790
|
}
|
|
@@ -5761,6 +5923,18 @@ function hasUrlQueryParameter(val, prop) {
|
|
|
5761
5923
|
function isNumericArray(val) {
|
|
5762
5924
|
return Array.isArray(val) && val.every((i) => isNumber(i));
|
|
5763
5925
|
}
|
|
5926
|
+
function hasProtocol(val, ...protocols) {
|
|
5927
|
+
return isString(val) && protocols.length === 0 ? NETWORK_PROTOCOL2.some((i) => val.startsWith(i)) : protocols.some((i) => val.startsWith(i));
|
|
5928
|
+
}
|
|
5929
|
+
function isProtocol(val, ...protocols) {
|
|
5930
|
+
return isString(val) && protocols.length === 0 ? NETWORK_PROTOCOL2.includes(val) : protocols.includes(val);
|
|
5931
|
+
}
|
|
5932
|
+
function hasProtocolPrefix(val, ...protocols) {
|
|
5933
|
+
return isString(val) && protocols.length === 0 ? NETWORK_PROTOCOL2.map((i) => `${i}://`).some((i) => val.startsWith(i)) : protocols.map((i) => `${i}://`).some((i) => val.startsWith(i));
|
|
5934
|
+
}
|
|
5935
|
+
function isProtocolPrefix(val, ...protocols) {
|
|
5936
|
+
return isString(val) && protocols.length === 0 ? NETWORK_PROTOCOL2.map((i) => `${i}://`).includes(val) : protocols.map((i) => `${i}://`).includes(val);
|
|
5937
|
+
}
|
|
5764
5938
|
function isTypeToken(val, kind) {
|
|
5765
5939
|
if (isString(val) && val.startsWith("<<") && val.endsWith(">>")) {
|
|
5766
5940
|
const stripped = stripSurround("<<", ">>")(val);
|
|
@@ -5992,24 +6166,24 @@ function isNewsUrl(val) {
|
|
|
5992
6166
|
return isAustralianNewsUrl(val) || isBelgiumNewsUrl(val) || isCanadianNewsUrl(val) || isDanishNewsUrl(val) || isDutchNewsUrl(val) || isFrenchNewsUrl(val) || isGermanNewsUrl(val) || isIndianNewsUrl(val) || isItalianNewsUrl(val) || isJapaneseNewsUrl(val) || isMexicanNewsUrl(val) || isNorwegianNewsUrl(val) || isSouthKoreanNewsUrl(val) || isSpanishNewsUrl(val) || isSwissNewsUrl(val) || isTurkishNewsUrl(val) || isUkNewsUrl(val) || isUsNewsUrl(val);
|
|
5993
6167
|
}
|
|
5994
6168
|
function isBitbucketUrl(val) {
|
|
5995
|
-
const
|
|
5996
|
-
return isString(val) &&
|
|
6169
|
+
const valid2 = REPO_SOURCE_LOOKUP2.bitbucket;
|
|
6170
|
+
return isString(val) && valid2.some(
|
|
5997
6171
|
(i) => val === i || val.startsWith(`${i}/`) || val.startsWith(`${i}?`)
|
|
5998
6172
|
);
|
|
5999
6173
|
}
|
|
6000
6174
|
function isCodeCommitUrl(val) {
|
|
6001
|
-
const
|
|
6002
|
-
return isString(val) &&
|
|
6175
|
+
const valid2 = REPO_SOURCE_LOOKUP2.codecommit;
|
|
6176
|
+
return isString(val) && valid2.some(
|
|
6003
6177
|
(i) => val === i || val.startsWith(`${i}/`) || val.startsWith(`${i}?`)
|
|
6004
6178
|
);
|
|
6005
6179
|
}
|
|
6006
6180
|
function isGithubUrl(val) {
|
|
6007
|
-
const
|
|
6181
|
+
const valid2 = [
|
|
6008
6182
|
"https://github.com",
|
|
6009
6183
|
"https://www.github.com",
|
|
6010
6184
|
"https://github.io"
|
|
6011
6185
|
];
|
|
6012
|
-
return isString(val) &&
|
|
6186
|
+
return isString(val) && valid2.some(
|
|
6013
6187
|
(i) => val === i || val.startsWith(`${i}/`) || val.startsWith(`${i}?`)
|
|
6014
6188
|
);
|
|
6015
6189
|
}
|
|
@@ -6553,16 +6727,77 @@ function getUrlQueryParams(url, specific = void 0) {
|
|
|
6553
6727
|
}
|
|
6554
6728
|
return qp === "" ? qp : `?${qp}`;
|
|
6555
6729
|
}
|
|
6556
|
-
function
|
|
6557
|
-
const
|
|
6558
|
-
|
|
6559
|
-
|
|
6560
|
-
|
|
6730
|
+
function getUrlDefaultPort(url) {
|
|
6731
|
+
const proto = getUrlProtocol(url);
|
|
6732
|
+
return proto in PROTOCOL_DEFAULT_PORTS2 ? PROTOCOL_DEFAULT_PORTS2[proto] : null;
|
|
6733
|
+
}
|
|
6734
|
+
function getUrlPort(url, resolve = false) {
|
|
6735
|
+
const re = /.*:(\d{2,3})/;
|
|
6736
|
+
const match = url.match(re);
|
|
6737
|
+
return re.test(url) && match && isNumberLike(Array.from(match)[1]) ? Number(Array.from(match)[1]) : resolve ? getUrlDefaultPort(url) : hasProtocol(url) ? `default` : null;
|
|
6561
6738
|
}
|
|
6562
6739
|
function getUrlSource(url) {
|
|
6563
6740
|
const candidate = stripAfter(stripAfter(stripAfter(removeUrlProtocol(url), "/"), "?"), ":");
|
|
6564
6741
|
return isIpAddress(candidate) || isDomainName(candidate) ? candidate : Never2;
|
|
6565
6742
|
}
|
|
6743
|
+
function getUrlBase(url) {
|
|
6744
|
+
const path = getUrlPath(url);
|
|
6745
|
+
const remaining = stripAfter(url, path);
|
|
6746
|
+
return remaining;
|
|
6747
|
+
}
|
|
6748
|
+
function getUrlDynamics(url) {
|
|
6749
|
+
const path = getUrlPath(url);
|
|
6750
|
+
const qp = getUrlQueryParams(url);
|
|
6751
|
+
const pathParts = path.startsWith("<") ? path.split("<").map((i) => ensureLeading(i, "<")) : path.split("<").map((i) => ensureLeading(i, "<")).slice(1);
|
|
6752
|
+
const segmentTypes = [
|
|
6753
|
+
"string",
|
|
6754
|
+
"number",
|
|
6755
|
+
"boolean",
|
|
6756
|
+
"Opt<string>",
|
|
6757
|
+
"Opt<number>",
|
|
6758
|
+
"Opt<boolean>"
|
|
6759
|
+
];
|
|
6760
|
+
const pathVars = {};
|
|
6761
|
+
const findPathTyped = infer(`<{{infer name}} as {{infer type}}>`);
|
|
6762
|
+
const findPathUnion = infer(`<{{infer name}} as string({{infer union}})>`);
|
|
6763
|
+
const findPathNamed = infer(`<{{infer name}}>`);
|
|
6764
|
+
for (const part of pathParts) {
|
|
6765
|
+
const union4 = findPathUnion(part);
|
|
6766
|
+
const typed = findPathTyped(part);
|
|
6767
|
+
const named = findPathNamed(part);
|
|
6768
|
+
if (union4) {
|
|
6769
|
+
if (isVariable(union4.name) && isCsv(union4.union)) {
|
|
6770
|
+
pathVars[union4.name] = `string(${union4.union})`;
|
|
6771
|
+
}
|
|
6772
|
+
} else if (typed && segmentTypes.includes(typed.type) && isVariable(typed.name)) {
|
|
6773
|
+
pathVars[typed.name] = typed.type;
|
|
6774
|
+
} else if (named && isVariable(named.name)) {
|
|
6775
|
+
pathVars[named.name] = "string";
|
|
6776
|
+
}
|
|
6777
|
+
}
|
|
6778
|
+
const qpVars = {};
|
|
6779
|
+
const qpParts = stripLeading(qp, "?").split("&");
|
|
6780
|
+
for (const p of qpParts) {
|
|
6781
|
+
const union4 = infer(`{{infer var}}=<string({{infer params}})>`)(p);
|
|
6782
|
+
const dynamic = infer(`{{infer var}}=<{{infer val}}>`)(p);
|
|
6783
|
+
const fixed = infer(`{{infer var}}={{infer val}}`)(p);
|
|
6784
|
+
if (union4 && isVariable(union4.var) && isCsv(union4.params)) {
|
|
6785
|
+
qpVars[union4.var] = `string(${union4.params})`;
|
|
6786
|
+
} else if (dynamic && isVariable(dynamic.var) && segmentTypes.includes(dynamic.val)) {
|
|
6787
|
+
qpVars[dynamic.var] = dynamic.val;
|
|
6788
|
+
} else if (fixed && isVariable(fixed.var)) {
|
|
6789
|
+
qpVars[fixed.var] = fixed.val;
|
|
6790
|
+
}
|
|
6791
|
+
}
|
|
6792
|
+
return {
|
|
6793
|
+
pathVars,
|
|
6794
|
+
qpVars,
|
|
6795
|
+
allVars: hasOverlappingKeys(pathVars, qpVars) ? null : {
|
|
6796
|
+
...pathVars,
|
|
6797
|
+
...qpVars
|
|
6798
|
+
}
|
|
6799
|
+
};
|
|
6800
|
+
}
|
|
6566
6801
|
function urlMeta(url) {
|
|
6567
6802
|
return {
|
|
6568
6803
|
url,
|
|
@@ -6570,6 +6805,7 @@ function urlMeta(url) {
|
|
|
6570
6805
|
protocol: getUrlProtocol(url),
|
|
6571
6806
|
path: getUrlPath(url),
|
|
6572
6807
|
queryParameters: getUrlQueryParams(url),
|
|
6808
|
+
params: getUrlDynamics,
|
|
6573
6809
|
port: getUrlPort(url),
|
|
6574
6810
|
source: getUrlSource(url),
|
|
6575
6811
|
isIpAddress: isIpAddress(getUrlSource(url)),
|
|
@@ -6970,6 +7206,15 @@ function simpleType(token) {
|
|
|
6970
7206
|
const value = isSimpleScalarToken(token) ? simpleScalarType(token) : isSimpleContainerToken(token) ? simpleContainerToken(token) : Never2;
|
|
6971
7207
|
return value;
|
|
6972
7208
|
}
|
|
7209
|
+
function hasOverlappingKeys(a, b) {
|
|
7210
|
+
const keys = Object.keys(a);
|
|
7211
|
+
for (const k of keys) {
|
|
7212
|
+
if (k in b) {
|
|
7213
|
+
return true;
|
|
7214
|
+
}
|
|
7215
|
+
}
|
|
7216
|
+
return false;
|
|
7217
|
+
}
|
|
6973
7218
|
function uniqueKeys(left, right) {
|
|
6974
7219
|
const isNumeric = !!(isArray(left) && isArray(right));
|
|
6975
7220
|
if (isArray(left) && !isArray(right) || isArray(right) && !isArray(left)) {
|
|
@@ -7257,11 +7502,15 @@ export {
|
|
|
7257
7502
|
MARKED,
|
|
7258
7503
|
MASS_METRICS_LOOKUP,
|
|
7259
7504
|
MEXICAN_NEWS,
|
|
7505
|
+
MIME_TYPES,
|
|
7260
7506
|
MONTH_ABBR,
|
|
7261
7507
|
MONTH_NAME,
|
|
7262
7508
|
MapCardinality,
|
|
7263
7509
|
NARROW_CONTAINER_TYPE_KINDS,
|
|
7510
|
+
NETWORK_PROTOCOL,
|
|
7511
|
+
NETWORK_PROTOCOL_INSECURE,
|
|
7264
7512
|
NETWORK_PROTOCOL_LOOKUP,
|
|
7513
|
+
NETWORK_PROTOCOL_SECURE,
|
|
7265
7514
|
NIKE_DNS,
|
|
7266
7515
|
NON_ZERO_NUMERIC_CHAR,
|
|
7267
7516
|
NORWEGIAN_NEWS,
|
|
@@ -7278,6 +7527,7 @@ export {
|
|
|
7278
7527
|
PLURAL_EXCEPTIONS_OLD,
|
|
7279
7528
|
POWER_METRICS_LOOKUP,
|
|
7280
7529
|
PRESSURE_METRICS_LOOKUP,
|
|
7530
|
+
PROTOCOL_DEFAULT_PORTS,
|
|
7281
7531
|
PROXMOX_CT_STATE,
|
|
7282
7532
|
REPO_PAGE_TYPES,
|
|
7283
7533
|
REPO_SOURCES,
|
|
@@ -7441,6 +7691,9 @@ export {
|
|
|
7441
7691
|
getTokenKind,
|
|
7442
7692
|
getTomorrow,
|
|
7443
7693
|
getTypeSubtype,
|
|
7694
|
+
getUrlBase,
|
|
7695
|
+
getUrlDefaultPort,
|
|
7696
|
+
getUrlDynamics,
|
|
7444
7697
|
getUrlPath,
|
|
7445
7698
|
getUrlPort,
|
|
7446
7699
|
getUrlProtocol,
|
|
@@ -7453,6 +7706,9 @@ export {
|
|
|
7453
7706
|
hasDefaultValue,
|
|
7454
7707
|
hasIndexOf,
|
|
7455
7708
|
hasKeys,
|
|
7709
|
+
hasOverlappingKeys,
|
|
7710
|
+
hasProtocol,
|
|
7711
|
+
hasProtocolPrefix,
|
|
7456
7712
|
hasUrlPort,
|
|
7457
7713
|
hasUrlQueryParameter,
|
|
7458
7714
|
hasWhiteSpace,
|
|
@@ -7518,6 +7774,7 @@ export {
|
|
|
7518
7774
|
isCountryCode3,
|
|
7519
7775
|
isCountryName,
|
|
7520
7776
|
isCssAspectRatio,
|
|
7777
|
+
isCsv,
|
|
7521
7778
|
isCurrentMetric,
|
|
7522
7779
|
isCurrentUom,
|
|
7523
7780
|
isCvsUrl,
|
|
@@ -7533,6 +7790,7 @@ export {
|
|
|
7533
7790
|
isDutchNewsUrl,
|
|
7534
7791
|
isEbayUrl,
|
|
7535
7792
|
isEmail,
|
|
7793
|
+
isEmpty,
|
|
7536
7794
|
isEnergyMetric,
|
|
7537
7795
|
isEnergyUom,
|
|
7538
7796
|
isEqual,
|
|
@@ -7621,6 +7879,8 @@ export {
|
|
|
7621
7879
|
isPowerUom,
|
|
7622
7880
|
isPressureMetric,
|
|
7623
7881
|
isPressureUom,
|
|
7882
|
+
isProtocol,
|
|
7883
|
+
isProtocolPrefix,
|
|
7624
7884
|
isReadonlyArray,
|
|
7625
7885
|
isRecordToken,
|
|
7626
7886
|
isRef,
|
|
@@ -7699,6 +7959,7 @@ export {
|
|
|
7699
7959
|
isUsNewsUrl,
|
|
7700
7960
|
isUsStateAbbreviation,
|
|
7701
7961
|
isUsStateName,
|
|
7962
|
+
isVariable,
|
|
7702
7963
|
isVoltageMetric,
|
|
7703
7964
|
isVoltageUom,
|
|
7704
7965
|
isVolumeMetric,
|