fds-vue-core 8.11.2 → 8.11.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Blocks/FdsBlockExpander/FdsBlockExpander.vue.d.ts +1 -1
- package/dist/components/Blocks/FdsBlockInfo/FdsBlockInfo.vue.d.ts +2 -2
- package/dist/components/Blocks/FdsBlockLink/FdsBlockLink.vue.d.ts +2 -2
- package/dist/components/Buttons/FdsButtonMinor/FdsButtonMinor.vue.d.ts +2 -2
- package/dist/components/Buttons/FdsButtonPrimary/FdsButtonPrimary.vue.d.ts +2 -2
- package/dist/components/Buttons/FdsButtonSecondary/FdsButtonSecondary.vue.d.ts +2 -2
- package/dist/components/Buttons/FdsButtonTertiary/FdsButtonTertiary.vue.d.ts +2 -2
- package/dist/components/FdsDrawer/FdsDrawer.vue.d.ts +1 -1
- package/dist/components/FdsIcon/FdsIcon.vue.d.ts +1 -1
- package/dist/components/FdsModal/FdsModal.vue.d.ts +1 -1
- package/dist/components/FdsPopover/FdsPopover.vue.d.ts +1 -1
- package/dist/components/FdsSearchSelect/FdsSearchSelect.vue.d.ts +2 -2
- package/dist/components/FdsSearchSelectPro/FdsSearchSelectPro.vue.d.ts +3 -3
- package/dist/components/FdsSticker/FdsSticker.vue.d.ts +1 -1
- package/dist/components/Form/FdsCheckbox/FdsCheckbox.vue.d.ts +2 -2
- package/dist/components/Form/FdsInput/FdsInput.vue.d.ts +4 -4
- package/dist/components/Form/FdsRadio/FdsRadio.vue.d.ts +2 -2
- package/dist/components/Form/FdsSelect/FdsSelect.vue.d.ts +1 -1
- package/dist/components/Form/FdsSsn/FdsSsn.vue.d.ts +1 -1
- package/dist/components/Form/FdsTextarea/FdsTextarea.vue.d.ts +1 -1
- package/dist/components/Table/FdsTableHead/FdsTableHead.vue.d.ts +1 -1
- package/dist/components/Tabs/FdsTabsItem/FdsTabsItem.vue.d.ts +1 -1
- package/dist/components/Typography/FdsH1/FdsH1.vue.d.ts +1 -1
- package/dist/components/Typography/FdsH2/FdsH2.vue.d.ts +1 -1
- package/dist/components/Typography/FdsH3/FdsH3.vue.d.ts +1 -1
- package/dist/fds-vue-core.cjs.js +74 -96
- package/dist/fds-vue-core.cjs.js.map +1 -1
- package/dist/fds-vue-core.es.js +74 -96
- package/dist/fds-vue-core.es.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +17 -16
- package/dist/assets/assets/fonts/IBMPlexSans-Bold.woff +0 -0
- package/dist/assets/assets/fonts/IBMPlexSans-Bold.woff2 +0 -0
- package/dist/assets/assets/fonts/IBMPlexSans-Light.woff +0 -0
- package/dist/assets/assets/fonts/IBMPlexSans-Light.woff2 +0 -0
- package/dist/assets/assets/fonts/IBMPlexSans-Regular.woff +0 -0
- package/dist/assets/assets/fonts/IBMPlexSans-Regular.woff2 +0 -0
- package/dist/assets/assets/fonts/Raleway-ExtraBold.woff +0 -0
- package/dist/assets/assets/fonts/Raleway-ExtraBold.woff2 +0 -0
package/dist/fds-vue-core.cjs.js
CHANGED
|
@@ -15098,22 +15098,6 @@ var FdsTruncatedText_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
15098
15098
|
};
|
|
15099
15099
|
}
|
|
15100
15100
|
});
|
|
15101
|
-
//#endregion
|
|
15102
|
-
//#region node_modules/.pnpm/date-fns@4.4.0/node_modules/date-fns/constants.js
|
|
15103
|
-
/**
|
|
15104
|
-
* @constant
|
|
15105
|
-
* @name daysInYear
|
|
15106
|
-
* @summary Days in 1 year.
|
|
15107
|
-
*
|
|
15108
|
-
* @description
|
|
15109
|
-
* How many days in a year.
|
|
15110
|
-
*
|
|
15111
|
-
* One years equals 365.2425 days according to the formula:
|
|
15112
|
-
*
|
|
15113
|
-
* > Leap year occurs every 4 years, except for years that are divisible by 100 and not divisible by 400.
|
|
15114
|
-
* > 1 mean year = (365+1/4-1/100+1/400) days = 365.2425 days
|
|
15115
|
-
*/
|
|
15116
|
-
var daysInYear = 365.2425;
|
|
15117
15101
|
-(Math.pow(10, 8) * 24 * 60 * 60 * 1e3);
|
|
15118
15102
|
/**
|
|
15119
15103
|
* @constant
|
|
@@ -15129,14 +15113,6 @@ var millisecondsInWeek = 6048e5;
|
|
|
15129
15113
|
var millisecondsInDay = 864e5;
|
|
15130
15114
|
/**
|
|
15131
15115
|
* @constant
|
|
15132
|
-
* @name secondsInDay
|
|
15133
|
-
* @summary Seconds in 1 day.
|
|
15134
|
-
*/
|
|
15135
|
-
var secondsInDay = 86400;
|
|
15136
|
-
secondsInDay * 7;
|
|
15137
|
-
secondsInDay * daysInYear / 12 * 3;
|
|
15138
|
-
/**
|
|
15139
|
-
* @constant
|
|
15140
15116
|
* @name constructFromSymbol
|
|
15141
15117
|
* @summary Symbol enabling Date extensions to inherit properties from the reference date.
|
|
15142
15118
|
*
|
|
@@ -18314,12 +18290,12 @@ var FdsWizard_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
18314
18290
|
}
|
|
18315
18291
|
});
|
|
18316
18292
|
//#endregion
|
|
18317
|
-
//#region node_modules/.pnpm/qrcode.vue@3.
|
|
18293
|
+
//#region node_modules/.pnpm/qrcode.vue@3.11.0_vue@3.5.44_typescript@5.9.3_/node_modules/qrcode.vue/dist/qrcode.vue.esm.js
|
|
18318
18294
|
/*!
|
|
18319
|
-
* qrcode.vue v3.
|
|
18295
|
+
* qrcode.vue v3.11.0
|
|
18320
18296
|
* A Vue.js component to generate QRCode. Both support Vue 2 and Vue 3
|
|
18321
18297
|
* © 2017-PRESENT @scopewu(https://github.com/scopewu)
|
|
18322
|
-
* MIT
|
|
18298
|
+
* @license MIT.
|
|
18323
18299
|
*/
|
|
18324
18300
|
/******************************************************************************
|
|
18325
18301
|
Copyright (c) Microsoft Corporation.
|
|
@@ -19969,7 +19945,7 @@ var FdsBankIdStatusAlert_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
19969
19945
|
}
|
|
19970
19946
|
});
|
|
19971
19947
|
//#endregion
|
|
19972
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
19948
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/metadata.mobile.json.js
|
|
19973
19949
|
var metadata_mobile_json_default = {
|
|
19974
19950
|
"version": 4,
|
|
19975
19951
|
"country_calling_codes": {
|
|
@@ -23651,7 +23627,7 @@ var metadata_mobile_json_default = {
|
|
|
23651
23627
|
0,
|
|
23652
23628
|
0,
|
|
23653
23629
|
0,
|
|
23654
|
-
[0, ["9(?:(?:0[0-5]|[13]\\d|2[0-3])\\d\\d|9(?:[0-46]\\d\\d|5(?:10|5\\d)|8(?:[12]\\d|3[0-2]|88)|9(?:[
|
|
23630
|
+
[0, ["9(?:(?:0[0-5]|[13]\\d|2[0-3])\\d\\d|9(?:[0-46]\\d\\d|5(?:10|5\\d)|8(?:[12]\\d|3[0-2]|88)|9(?:[0-359]\\d|69|77|8[7-9])))\\d{5}", [10]]]
|
|
23655
23631
|
],
|
|
23656
23632
|
"IS": [
|
|
23657
23633
|
"354",
|
|
@@ -25317,7 +25293,7 @@ var metadata_mobile_json_default = {
|
|
|
25317
25293
|
0,
|
|
25318
25294
|
0,
|
|
25319
25295
|
0,
|
|
25320
|
-
[0, ["(?:702[0-24-9]|819[01])\\d{6}|(?:7(?:0[13-9]|[12]\\d)|8(?:0[1-9]|1[0-8])|9(?:0[1-9]|1[
|
|
25296
|
+
[0, ["(?:702[0-24-9]|819[01])\\d{6}|(?:7(?:0[13-9]|[12]\\d)|8(?:0[1-9]|1[0-8])|9(?:0[1-9]|1[0-6]))\\d{7}", [10]]]
|
|
25321
25297
|
],
|
|
25322
25298
|
"NI": [
|
|
25323
25299
|
"505",
|
|
@@ -27533,7 +27509,7 @@ var metadata_mobile_json_default = {
|
|
|
27533
27509
|
0,
|
|
27534
27510
|
0,
|
|
27535
27511
|
0,
|
|
27536
|
-
[0, ["
|
|
27512
|
+
[0, ["983[2-57-9]\\d{6}|(?:2(?:0[1-35-9]|1[02-9]|2[03-57-9]|3[1459]|4[08]|5[1-46]|6[0279]|7[02469]|8[13])|3(?:0[1-57-9]|1[02-9]|2[013-79]|3[0-24679]|4[167]|5[0-3]|6[01349]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[02589]|8[04])|5(?:0[1-57-9]|1[0235-8]|20|3[0149]|4[01]|5[179]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|3[016]|4[0156]|5[01679]|6[0-279]|78|8[0-269])|7(?:0[1-46-8]|1[2-9]|2[04-8]|3[0-2478]|4[0378]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[0168]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-3589]|8[04-69]))[2-9]\\d{6}"]]
|
|
27537
27513
|
],
|
|
27538
27514
|
"UY": [
|
|
27539
27515
|
"598",
|
|
@@ -28386,7 +28362,7 @@ var metadata_mobile_json_default = {
|
|
|
28386
28362
|
}
|
|
28387
28363
|
};
|
|
28388
28364
|
//#endregion
|
|
28389
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28365
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/mobile/es6/exports/withMetadataArgument.js
|
|
28390
28366
|
function withMetadataArgument(func, _arguments, resultPrototype) {
|
|
28391
28367
|
var args = Array.prototype.slice.call(_arguments);
|
|
28392
28368
|
args.push(metadata_mobile_json_default);
|
|
@@ -28395,7 +28371,7 @@ function withMetadataArgument(func, _arguments, resultPrototype) {
|
|
|
28395
28371
|
return result;
|
|
28396
28372
|
}
|
|
28397
28373
|
//#endregion
|
|
28398
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28374
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/tools/semver-compare.js
|
|
28399
28375
|
function semver_compare_default(a, b) {
|
|
28400
28376
|
a = a.split("-");
|
|
28401
28377
|
b = b.split("-");
|
|
@@ -28413,19 +28389,19 @@ function semver_compare_default(a, b) {
|
|
|
28413
28389
|
return !a[1] && b[1] ? 1 : a[1] && !b[1] ? -1 : 0;
|
|
28414
28390
|
}
|
|
28415
28391
|
//#endregion
|
|
28416
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28392
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/isObject.js
|
|
28417
28393
|
var objectConstructor = {}.constructor;
|
|
28418
28394
|
function isObject(object) {
|
|
28419
28395
|
return object !== void 0 && object !== null && object.constructor === objectConstructor;
|
|
28420
28396
|
}
|
|
28421
28397
|
//#endregion
|
|
28422
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28398
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/isCallingCode.js
|
|
28423
28399
|
var CALLING_CODE_REG_EXP = /^\d+$/;
|
|
28424
28400
|
function isCallingCode(string) {
|
|
28425
28401
|
return CALLING_CODE_REG_EXP.test(string);
|
|
28426
28402
|
}
|
|
28427
28403
|
//#endregion
|
|
28428
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28404
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/metadata.js
|
|
28429
28405
|
var V3 = "1.2.0";
|
|
28430
28406
|
var V4 = "1.7.35";
|
|
28431
28407
|
var DEFAULT_EXT_PREFIX = " ext. ";
|
|
@@ -28756,7 +28732,7 @@ function setVersion(metadata) {
|
|
|
28756
28732
|
else this.v4 = true;
|
|
28757
28733
|
}
|
|
28758
28734
|
//#endregion
|
|
28759
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28735
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/mergeArrays.js
|
|
28760
28736
|
/**
|
|
28761
28737
|
* Merges two arrays.
|
|
28762
28738
|
* @param {*} a
|
|
@@ -28769,7 +28745,7 @@ function mergeArrays(a, b) {
|
|
|
28769
28745
|
return merged.sort((a, b) => a - b);
|
|
28770
28746
|
}
|
|
28771
28747
|
//#endregion
|
|
28772
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28748
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/checkNumberLength.js
|
|
28773
28749
|
/**
|
|
28774
28750
|
* Checks phone number length against the phone numbering plan selected in metadata.
|
|
28775
28751
|
* Optionally, it could be restrained by a specific country.
|
|
@@ -28812,7 +28788,7 @@ function checkNumberLengthForType(nationalNumber, type, country, metadata) {
|
|
|
28812
28788
|
return possible_lengths.indexOf(actual_length, 1) >= 0 ? "IS_POSSIBLE" : "INVALID_LENGTH";
|
|
28813
28789
|
}
|
|
28814
28790
|
//#endregion
|
|
28815
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28791
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/isPossible.js
|
|
28816
28792
|
/**
|
|
28817
28793
|
* Checks if a phone number is "possible" (basically just checks its length).
|
|
28818
28794
|
*
|
|
@@ -28860,7 +28836,7 @@ function isPossibleNumber(nationalNumber, metadata) {
|
|
|
28860
28836
|
}
|
|
28861
28837
|
}
|
|
28862
28838
|
//#endregion
|
|
28863
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28839
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/matchesEntirely.js
|
|
28864
28840
|
/**
|
|
28865
28841
|
* Checks whether the entire input sequence can be matched
|
|
28866
28842
|
* against the regular expression.
|
|
@@ -28871,7 +28847,7 @@ function matchesEntirely(text, regularExpressionText) {
|
|
|
28871
28847
|
return new RegExp("^(?:" + regularExpressionText + ")$").test(text);
|
|
28872
28848
|
}
|
|
28873
28849
|
//#endregion
|
|
28874
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28850
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/getNumberType.js
|
|
28875
28851
|
var NON_FIXED_LINE_PHONE_TYPES = [
|
|
28876
28852
|
"MOBILE",
|
|
28877
28853
|
"PREMIUM_RATE",
|
|
@@ -28906,7 +28882,7 @@ function isNumberTypeEqualTo(nationalNumber, type, metadata) {
|
|
|
28906
28882
|
return matchesEntirely(nationalNumber, typeDefinition.pattern());
|
|
28907
28883
|
}
|
|
28908
28884
|
//#endregion
|
|
28909
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28885
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/isValid.js
|
|
28910
28886
|
/**
|
|
28911
28887
|
* Checks if a given phone number is valid.
|
|
28912
28888
|
*
|
|
@@ -28949,13 +28925,13 @@ function isValidNumber(input, options, metadataJson) {
|
|
|
28949
28925
|
return matchesEntirely(options.v2 ? input.nationalNumber : input.phone, metadata.nationalNumberPattern());
|
|
28950
28926
|
}
|
|
28951
28927
|
//#endregion
|
|
28952
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28928
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/isCountryCode.js
|
|
28953
28929
|
var COUNTRY_CODE_REG_EXP = /^[A-Z]{2}$/;
|
|
28954
28930
|
function isCountryCode(string) {
|
|
28955
28931
|
return COUNTRY_CODE_REG_EXP.test(string);
|
|
28956
28932
|
}
|
|
28957
28933
|
//#endregion
|
|
28958
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28934
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/getCountryAndCallingCodeFromOneOfThem.js
|
|
28959
28935
|
function getCountryAndCallingCodeFromOneOfThem(countryOrCallingCode, metadataJson) {
|
|
28960
28936
|
let country;
|
|
28961
28937
|
let callingCode;
|
|
@@ -28971,7 +28947,7 @@ function getCountryAndCallingCodeFromOneOfThem(countryOrCallingCode, metadataJso
|
|
|
28971
28947
|
};
|
|
28972
28948
|
}
|
|
28973
28949
|
//#endregion
|
|
28974
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28950
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/getPossibleCountriesForNumber.js
|
|
28975
28951
|
/**
|
|
28976
28952
|
* Returns a list of countries that the phone number could potentially belong to.
|
|
28977
28953
|
* @param {string} callingCode — Calling code.
|
|
@@ -28992,12 +28968,12 @@ function couldNationalNumberBelongToCountry(nationalNumber, country, metadataJso
|
|
|
28992
28968
|
return metadata.numberingPlan.possibleLengths().indexOf(nationalNumber.length) >= 0;
|
|
28993
28969
|
}
|
|
28994
28970
|
//#endregion
|
|
28995
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28971
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/constants.js
|
|
28996
28972
|
var VALID_DIGITS = "0-90-9٠-٩۰-۹";
|
|
28997
28973
|
var VALID_PUNCTUATION = `-‐-―−ー-//.. ()()[]\\[\\]~⁓∼~`;
|
|
28998
28974
|
var PLUS_CHARS = "++";
|
|
28999
28975
|
//#endregion
|
|
29000
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28976
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/stripIddPrefix.js
|
|
29001
28977
|
var CAPTURING_DIGIT_PATTERN = new RegExp("([" + VALID_DIGITS + "])");
|
|
29002
28978
|
function stripIddPrefix(number, country, callingCode, metadataJson) {
|
|
29003
28979
|
if (!country) return;
|
|
@@ -29013,7 +28989,7 @@ function stripIddPrefix(number, country, callingCode, metadataJson) {
|
|
|
29013
28989
|
return number;
|
|
29014
28990
|
}
|
|
29015
28991
|
//#endregion
|
|
29016
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
28992
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js
|
|
29017
28993
|
/**
|
|
29018
28994
|
* Strips any national prefix (such as 0, 1) present in a
|
|
29019
28995
|
* (possibly incomplete) number provided.
|
|
@@ -29059,7 +29035,7 @@ function extractNationalNumberFromPossiblyIncompleteNumber(number, metadata) {
|
|
|
29059
29035
|
return { nationalNumber: number };
|
|
29060
29036
|
}
|
|
29061
29037
|
//#endregion
|
|
29062
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29038
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/getCountryByNationalNumber.js
|
|
29063
29039
|
/**
|
|
29064
29040
|
* Returns the exact country that a given national (significant) number belongs to
|
|
29065
29041
|
* in case of ambiguity, i.e. when multiple countries share the same "country calling code".
|
|
@@ -29081,7 +29057,7 @@ function getCountryByNationalNumber(nationalNumber, countries, metadataJson) {
|
|
|
29081
29057
|
}
|
|
29082
29058
|
}
|
|
29083
29059
|
//#endregion
|
|
29084
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29060
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/getCountryByCallingCode.js
|
|
29085
29061
|
/**
|
|
29086
29062
|
* Returns the exact country that a given national (significant) number belongs to
|
|
29087
29063
|
* in case of ambiguity, i.e. when multiple countries share the same "country calling code".
|
|
@@ -29097,7 +29073,7 @@ function getCountryByCallingCode(callingCode, { nationalNumber, metadata }) {
|
|
|
29097
29073
|
return getCountryByNationalNumber(nationalNumber, possibleCountries, metadata.metadata);
|
|
29098
29074
|
}
|
|
29099
29075
|
//#endregion
|
|
29100
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29076
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extractNationalNumber.js
|
|
29101
29077
|
/**
|
|
29102
29078
|
* Strips national prefix and carrier code from a complete phone number.
|
|
29103
29079
|
* The difference from the non-"FromCompleteNumber" function is that
|
|
@@ -29144,7 +29120,7 @@ function isPossibleIncompleteNationalNumber(nationalNumber, country, metadata) {
|
|
|
29144
29120
|
}
|
|
29145
29121
|
}
|
|
29146
29122
|
//#endregion
|
|
29147
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29123
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js
|
|
29148
29124
|
/**
|
|
29149
29125
|
* Sometimes some people incorrectly input international phone numbers
|
|
29150
29126
|
* without the leading `+`. This function corrects such input.
|
|
@@ -29172,7 +29148,7 @@ function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number,
|
|
|
29172
29148
|
return { number };
|
|
29173
29149
|
}
|
|
29174
29150
|
//#endregion
|
|
29175
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29151
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extractCountryCallingCode.js
|
|
29176
29152
|
/**
|
|
29177
29153
|
* Attempts to extract a calling code from a phone number.
|
|
29178
29154
|
* * If the phone number is found to be "international":
|
|
@@ -29235,12 +29211,12 @@ function extractCountryCallingCode(number, country, defaultCountry, defaultCalli
|
|
|
29235
29211
|
return {};
|
|
29236
29212
|
}
|
|
29237
29213
|
//#endregion
|
|
29238
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29214
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/applyInternationalSeparatorStyle.js
|
|
29239
29215
|
function applyInternationalSeparatorStyle(formattedNumber) {
|
|
29240
29216
|
return formattedNumber.replace(new RegExp(`[${VALID_PUNCTUATION}]+`, "g"), " ").trim();
|
|
29241
29217
|
}
|
|
29242
29218
|
//#endregion
|
|
29243
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29219
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/formatNationalNumberUsingFormat.js
|
|
29244
29220
|
var FIRST_GROUP_PATTERN = /(\$\d)/;
|
|
29245
29221
|
function formatNationalNumberUsingFormat(number, format, { useInternationalFormat, withNationalPrefix, carrierCode, metadata }) {
|
|
29246
29222
|
const formattedNumber = number.replace(new RegExp(format.pattern()), useInternationalFormat ? format.internationalFormat() : withNationalPrefix && format.nationalPrefixFormattingRule() ? format.format().replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule()) : format.format());
|
|
@@ -29248,7 +29224,7 @@ function formatNationalNumberUsingFormat(number, format, { useInternationalForma
|
|
|
29248
29224
|
return formattedNumber;
|
|
29249
29225
|
}
|
|
29250
29226
|
//#endregion
|
|
29251
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29227
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/getIddPrefix.js
|
|
29252
29228
|
/**
|
|
29253
29229
|
* Pattern that makes it easy to distinguish whether a region has a single
|
|
29254
29230
|
* international dialing prefix or not. If a region has a single international
|
|
@@ -29266,7 +29242,7 @@ function getIddPrefix(country, callingCode, metadata) {
|
|
|
29266
29242
|
if (SINGLE_IDD_PREFIX_REG_EXP.test(countryMetadata.IDDPrefix())) return countryMetadata.IDDPrefix();
|
|
29267
29243
|
}
|
|
29268
29244
|
//#endregion
|
|
29269
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29245
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extension/createExtensionPattern.js
|
|
29270
29246
|
var RFC3966_EXTN_PREFIX = ";ext=";
|
|
29271
29247
|
/**
|
|
29272
29248
|
* Helper method for constructing regular expressions for parsing. Creates
|
|
@@ -29321,7 +29297,7 @@ function createExtensionPattern(purpose) {
|
|
|
29321
29297
|
return rfcExtn + "|" + explicitExtn + "|" + ambiguousExtn + "|" + americanStyleExtnWithSuffix + "|" + autoDiallingExtn + "|" + onlyCommasExtn;
|
|
29322
29298
|
}
|
|
29323
29299
|
//#endregion
|
|
29324
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29300
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/isViablePhoneNumber.js
|
|
29325
29301
|
var MIN_LENGTH_PHONE_NUMBER_PATTERN = "[" + VALID_DIGITS + "]{2}";
|
|
29326
29302
|
var VALID_PHONE_NUMBER = "[" + PLUS_CHARS + "]{0,1}(?:[" + VALID_PUNCTUATION + "]*[" + VALID_DIGITS + "]){3,}[" + VALID_PUNCTUATION + VALID_DIGITS + "]*";
|
|
29327
29303
|
var VALID_PHONE_NUMBER_START_REG_EXP = new RegExp("^[" + PLUS_CHARS + "]{0,1}(?:[" + VALID_PUNCTUATION + "]*[" + VALID_DIGITS + "]){1,2}$", "i");
|
|
@@ -29334,7 +29310,7 @@ function isViablePhoneNumberStart(number) {
|
|
|
29334
29310
|
return VALID_PHONE_NUMBER_START_REG_EXP.test(number);
|
|
29335
29311
|
}
|
|
29336
29312
|
//#endregion
|
|
29337
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29313
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/RFC3966.js
|
|
29338
29314
|
/**
|
|
29339
29315
|
* @param {object} - `{ ?number, ?extension }`.
|
|
29340
29316
|
* @return {string} Phone URI (RFC 3966).
|
|
@@ -29345,7 +29321,7 @@ function formatRFC3966({ number, ext }) {
|
|
|
29345
29321
|
return `tel:${number}${ext ? ";ext=" + ext : ""}`;
|
|
29346
29322
|
}
|
|
29347
29323
|
//#endregion
|
|
29348
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29324
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/format.js
|
|
29349
29325
|
var DEFAULT_OPTIONS = { formatExtension: (formattedNumber, extension, metadata) => `${formattedNumber}${metadata.ext()}${extension}` };
|
|
29350
29326
|
/**
|
|
29351
29327
|
* Formats a phone number.
|
|
@@ -29444,7 +29420,7 @@ function pickFirstMatchingElement(elements, testFunction) {
|
|
|
29444
29420
|
}
|
|
29445
29421
|
}
|
|
29446
29422
|
//#endregion
|
|
29447
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29423
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/PhoneNumber.js
|
|
29448
29424
|
function _extends$3() {
|
|
29449
29425
|
return _extends$3 = Object.assign ? Object.assign.bind() : function(n) {
|
|
29450
29426
|
for (var e = 1; e < arguments.length; e++) {
|
|
@@ -29521,7 +29497,7 @@ var PhoneNumber$1 = class {
|
|
|
29521
29497
|
};
|
|
29522
29498
|
var E164_NUMBER_REGEXP = /^\+\d+$/;
|
|
29523
29499
|
//#endregion
|
|
29524
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29500
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/ParseError.js
|
|
29525
29501
|
var ParseError = class ParseError extends Error {
|
|
29526
29502
|
constructor(code) {
|
|
29527
29503
|
super(code);
|
|
@@ -29530,7 +29506,7 @@ var ParseError = class ParseError extends Error {
|
|
|
29530
29506
|
}
|
|
29531
29507
|
};
|
|
29532
29508
|
//#endregion
|
|
29533
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29509
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extension/extractExtension.js
|
|
29534
29510
|
var EXTN_PATTERN = new RegExp("(?:" + createExtensionPattern() + ")$", "i");
|
|
29535
29511
|
function extractExtension(number) {
|
|
29536
29512
|
const start = number.search(EXTN_PATTERN);
|
|
@@ -29547,7 +29523,7 @@ function extractExtension(number) {
|
|
|
29547
29523
|
}
|
|
29548
29524
|
}
|
|
29549
29525
|
//#endregion
|
|
29550
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29526
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/parseDigits.js
|
|
29551
29527
|
var DIGITS = {
|
|
29552
29528
|
"0": "0",
|
|
29553
29529
|
"1": "1",
|
|
@@ -29594,7 +29570,7 @@ function parseDigit(character) {
|
|
|
29594
29570
|
return DIGITS[character];
|
|
29595
29571
|
}
|
|
29596
29572
|
//#endregion
|
|
29597
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29573
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/parseIncompletePhoneNumber.js
|
|
29598
29574
|
/**
|
|
29599
29575
|
* Parses phone number characters from a string.
|
|
29600
29576
|
* Drops all punctuation leaving only digits and the leading `+` sign (if any).
|
|
@@ -29637,7 +29613,7 @@ function parsePhoneNumberCharacter(character, prevParsedCharacters, eventListene
|
|
|
29637
29613
|
return parseDigit(character);
|
|
29638
29614
|
}
|
|
29639
29615
|
//#endregion
|
|
29640
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29616
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extractPhoneContext.js
|
|
29641
29617
|
var RFC3966_PHONE_DIGIT_ = "([" + VALID_DIGITS + "]|[\\-\\.\\(\\)]?)";
|
|
29642
29618
|
var RFC3966_GLOBAL_NUMBER_DIGITS_ = "^\\+" + RFC3966_PHONE_DIGIT_ + "*[" + VALID_DIGITS + "]" + RFC3966_PHONE_DIGIT_ + "*$";
|
|
29643
29619
|
/**
|
|
@@ -29685,7 +29661,7 @@ function isPhoneContextValid(phoneContext) {
|
|
|
29685
29661
|
return RFC3966_GLOBAL_NUMBER_DIGITS_PATTERN_.test(phoneContext) || RFC3966_DOMAINNAME_PATTERN_.test(phoneContext);
|
|
29686
29662
|
}
|
|
29687
29663
|
//#endregion
|
|
29688
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29664
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js
|
|
29689
29665
|
/**
|
|
29690
29666
|
* @param {string} numberToParse
|
|
29691
29667
|
* @param {string} nationalNumber
|
|
@@ -29712,7 +29688,7 @@ function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse,
|
|
|
29712
29688
|
if (phoneNumberString !== "") return phoneNumberString;
|
|
29713
29689
|
}
|
|
29714
29690
|
//#endregion
|
|
29715
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29691
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/parse.js
|
|
29716
29692
|
var MAX_INPUT_STRING_LENGTH = 250;
|
|
29717
29693
|
var PHONE_NUMBER_START_PATTERN = new RegExp("[" + PLUS_CHARS + VALID_DIGITS + "]");
|
|
29718
29694
|
var AFTER_PHONE_NUMBER_END_PATTERN = new RegExp("[^" + VALID_DIGITS + "#]+$");
|
|
@@ -29728,7 +29704,7 @@ var AFTER_PHONE_NUMBER_END_PATTERN = new RegExp("[^" + VALID_DIGITS + "#]+$");
|
|
|
29728
29704
|
* @param {object} metadataJson
|
|
29729
29705
|
* @return {object|PhoneNumber?} If `options.v2: true` flag is passed, it returns a `PhoneNumber?` instance. Otherwise, returns an object of shape `{ phone: '...', country: '...' }` (or just `{}` if no phone number was parsed).
|
|
29730
29706
|
*/
|
|
29731
|
-
function parse(text, options, metadataJson) {
|
|
29707
|
+
function parse$1(text, options, metadataJson) {
|
|
29732
29708
|
options = options || {};
|
|
29733
29709
|
const metadata = new Metadata(metadataJson);
|
|
29734
29710
|
if (options.defaultCountry && !metadata.hasCountry(options.defaultCountry)) {
|
|
@@ -29873,7 +29849,7 @@ function parsePhoneNumber$3(formattedPhoneNumber, defaultCountry, defaultCalling
|
|
|
29873
29849
|
};
|
|
29874
29850
|
}
|
|
29875
29851
|
//#endregion
|
|
29876
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29852
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/parsePhoneNumberWithError_.js
|
|
29877
29853
|
function _extends$2() {
|
|
29878
29854
|
return _extends$2 = Object.assign ? Object.assign.bind() : function(n) {
|
|
29879
29855
|
for (var e = 1; e < arguments.length; e++) {
|
|
@@ -29884,10 +29860,10 @@ function _extends$2() {
|
|
|
29884
29860
|
}, _extends$2.apply(null, arguments);
|
|
29885
29861
|
}
|
|
29886
29862
|
function parsePhoneNumberWithError(text, options, metadata) {
|
|
29887
|
-
return parse(text, _extends$2({}, options, { v2: true }), metadata);
|
|
29863
|
+
return parse$1(text, _extends$2({}, options, { v2: true }), metadata);
|
|
29888
29864
|
}
|
|
29889
29865
|
//#endregion
|
|
29890
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29866
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/normalizeArguments.js
|
|
29891
29867
|
function _extends$1() {
|
|
29892
29868
|
return _extends$1 = Object.assign ? Object.assign.bind() : function(n) {
|
|
29893
29869
|
for (var e = 1; e < arguments.length; e++) {
|
|
@@ -29926,7 +29902,7 @@ function normalizeArguments(args) {
|
|
|
29926
29902
|
};
|
|
29927
29903
|
}
|
|
29928
29904
|
//#endregion
|
|
29929
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29905
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/parsePhoneNumber_.js
|
|
29930
29906
|
function _extends() {
|
|
29931
29907
|
return _extends = Object.assign ? Object.assign.bind() : function(n) {
|
|
29932
29908
|
for (var e = 1; e < arguments.length; e++) {
|
|
@@ -29946,45 +29922,45 @@ function parsePhoneNumber$2(text, options, metadata) {
|
|
|
29946
29922
|
}
|
|
29947
29923
|
}
|
|
29948
29924
|
//#endregion
|
|
29949
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29925
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/parsePhoneNumber.js
|
|
29950
29926
|
function parsePhoneNumber$1() {
|
|
29951
29927
|
const { text, options, metadata } = normalizeArguments(arguments);
|
|
29952
29928
|
return parsePhoneNumber$2(text, options, metadata);
|
|
29953
29929
|
}
|
|
29954
29930
|
//#endregion
|
|
29955
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29931
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/getCountries.js
|
|
29956
29932
|
function getCountries$1(metadata) {
|
|
29957
29933
|
return new Metadata(metadata).getCountries();
|
|
29958
29934
|
}
|
|
29959
29935
|
//#endregion
|
|
29960
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29936
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/es6-modern/getExampleNumber.js
|
|
29961
29937
|
function getExampleNumber$1(country, examples, metadata) {
|
|
29962
29938
|
if (examples[country]) return new PhoneNumber$1(country, examples[country], metadata);
|
|
29963
29939
|
}
|
|
29964
29940
|
//#endregion
|
|
29965
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29941
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/mobile/es6/exports/PhoneNumber.js
|
|
29966
29942
|
var PhoneNumber = class extends PhoneNumber$1 {
|
|
29967
29943
|
constructor(number) {
|
|
29968
29944
|
super(number, metadata_mobile_json_default);
|
|
29969
29945
|
}
|
|
29970
29946
|
};
|
|
29971
29947
|
//#endregion
|
|
29972
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29948
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/mobile/es6/exports/parsePhoneNumber.js
|
|
29973
29949
|
function parsePhoneNumber() {
|
|
29974
29950
|
return withMetadataArgument(parsePhoneNumber$1, arguments, PhoneNumber.prototype);
|
|
29975
29951
|
}
|
|
29976
29952
|
//#endregion
|
|
29977
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29953
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/mobile/es6/exports/getCountries.js
|
|
29978
29954
|
function getCountries() {
|
|
29979
29955
|
return withMetadataArgument(getCountries$1, arguments);
|
|
29980
29956
|
}
|
|
29981
29957
|
//#endregion
|
|
29982
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29958
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/mobile/es6/exports/getCountryCallingCode.js
|
|
29983
29959
|
function getCountryCallingCode() {
|
|
29984
29960
|
return withMetadataArgument(getCountryCallingCode$1, arguments);
|
|
29985
29961
|
}
|
|
29986
29962
|
//#endregion
|
|
29987
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
29963
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/mobile/es6/exports/getExampleNumber.js
|
|
29988
29964
|
function getExampleNumber() {
|
|
29989
29965
|
return withMetadataArgument(getExampleNumber$1, arguments);
|
|
29990
29966
|
}
|
|
@@ -30448,7 +30424,7 @@ var FdsPhonenumberCountryPicker_default = /* @__PURE__ */ (0, vue.defineComponen
|
|
|
30448
30424
|
}
|
|
30449
30425
|
});
|
|
30450
30426
|
//#endregion
|
|
30451
|
-
//#region node_modules/.pnpm/libphonenumber-js@1.13.
|
|
30427
|
+
//#region node_modules/.pnpm/libphonenumber-js@1.13.15/node_modules/libphonenumber-js/examples.mobile.json.js
|
|
30452
30428
|
var examples_mobile_json_default = {
|
|
30453
30429
|
"AC": "40123",
|
|
30454
30430
|
"AD": "312345",
|
|
@@ -31059,7 +31035,7 @@ var FdsPhonenumber_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
31059
31035
|
}
|
|
31060
31036
|
});
|
|
31061
31037
|
//#endregion
|
|
31062
|
-
//#region node_modules/.pnpm/personnummer@3.
|
|
31038
|
+
//#region node_modules/.pnpm/personnummer@3.3.1/node_modules/personnummer/dist/esm/index.mjs
|
|
31063
31039
|
var PersonnummerError = class extends Error {
|
|
31064
31040
|
constructor() {
|
|
31065
31041
|
super("Invalid swedish personal identity number");
|
|
@@ -31085,14 +31061,14 @@ var luhn = (str) => {
|
|
|
31085
31061
|
if (v > 9) v -= 9;
|
|
31086
31062
|
sum += v;
|
|
31087
31063
|
}
|
|
31088
|
-
return Math.ceil(sum / 10) * 10 - sum;
|
|
31064
|
+
return Math.ceil(sum / 10) * 10 - sum || 0;
|
|
31089
31065
|
};
|
|
31090
31066
|
var testDate = (year, month, day) => {
|
|
31091
31067
|
month -= 1;
|
|
31092
31068
|
const date = new Date(year, month, day);
|
|
31093
31069
|
return !(date.getFullYear() !== year || date.getMonth() !== month || date.getDate() !== day);
|
|
31094
31070
|
};
|
|
31095
|
-
var Personnummer = class {
|
|
31071
|
+
var Personnummer = class _Personnummer {
|
|
31096
31072
|
/**
|
|
31097
31073
|
* Personnummer constructor.
|
|
31098
31074
|
*
|
|
@@ -31227,7 +31203,7 @@ var Personnummer = class {
|
|
|
31227
31203
|
* @return {Personnummer}
|
|
31228
31204
|
*/
|
|
31229
31205
|
static parse(pin, options) {
|
|
31230
|
-
return new
|
|
31206
|
+
return new _Personnummer(pin, options);
|
|
31231
31207
|
}
|
|
31232
31208
|
/**
|
|
31233
31209
|
* Validate a Swedish personal identity number.
|
|
@@ -31239,9 +31215,9 @@ var Personnummer = class {
|
|
|
31239
31215
|
*/
|
|
31240
31216
|
static valid(pin, options) {
|
|
31241
31217
|
try {
|
|
31242
|
-
|
|
31218
|
+
_Personnummer.parse(pin, options);
|
|
31243
31219
|
return true;
|
|
31244
|
-
} catch (
|
|
31220
|
+
} catch (_err) {
|
|
31245
31221
|
return false;
|
|
31246
31222
|
}
|
|
31247
31223
|
}
|
|
@@ -31264,7 +31240,7 @@ var Personnummer = class {
|
|
|
31264
31240
|
const check = match[7];
|
|
31265
31241
|
if (typeof century === "undefined" || !century.length) {
|
|
31266
31242
|
const d = /* @__PURE__ */ new Date();
|
|
31267
|
-
let baseYear
|
|
31243
|
+
let baseYear;
|
|
31268
31244
|
if (sep === "+") {
|
|
31269
31245
|
this._sep = "+";
|
|
31270
31246
|
baseYear = d.getFullYear() - 100;
|
|
@@ -31285,8 +31261,8 @@ var Personnummer = class {
|
|
|
31285
31261
|
this._num = num;
|
|
31286
31262
|
this._check = check;
|
|
31287
31263
|
if (!this.valid()) throw new PersonnummerError();
|
|
31288
|
-
if (!
|
|
31289
|
-
if (!
|
|
31264
|
+
if (!options?.allowCoordinationNumber && this.isCoordinationNumber()) throw new PersonnummerError();
|
|
31265
|
+
if (!options?.allowInterimNumber && this.isInterimNumber()) throw new PersonnummerError();
|
|
31290
31266
|
}
|
|
31291
31267
|
/**
|
|
31292
31268
|
* Validate a Swedish personal identity number.
|
|
@@ -31294,9 +31270,9 @@ var Personnummer = class {
|
|
|
31294
31270
|
* @return {boolean}
|
|
31295
31271
|
*/
|
|
31296
31272
|
valid() {
|
|
31297
|
-
const
|
|
31298
|
-
if (
|
|
31299
|
-
return
|
|
31273
|
+
const valid2 = luhn(this.year + this.month + this.day + this.num.replace(/[TRSUWXJKLMN]/, "1")) === +this.check && !!this.check;
|
|
31274
|
+
if (valid2 && testDate(parseInt(this.century + this.year), +this.month, +this.day)) return valid2;
|
|
31275
|
+
return valid2 && testDate(parseInt(this.century + this.year), +this.month, +this.day - 60);
|
|
31300
31276
|
}
|
|
31301
31277
|
/**
|
|
31302
31278
|
* Format a Swedish personal identity number as one of the official formats,
|
|
@@ -31365,7 +31341,9 @@ var Personnummer = class {
|
|
|
31365
31341
|
return parseInt(this.num.substr(-1)) % 2 === 1;
|
|
31366
31342
|
}
|
|
31367
31343
|
};
|
|
31368
|
-
|
|
31344
|
+
Personnummer.valid;
|
|
31345
|
+
Personnummer.parse;
|
|
31346
|
+
var index_default = Personnummer;
|
|
31369
31347
|
//#endregion
|
|
31370
31348
|
//#region src/helpers/validateSsn.ts
|
|
31371
31349
|
var INVALID_RESULT = {
|
|
@@ -31413,7 +31391,7 @@ function validateSsnNumber(value, options) {
|
|
|
31413
31391
|
const digits = convertPidTo12Digits(trimmed);
|
|
31414
31392
|
if (digits.length !== 12) return INVALID_RESULT;
|
|
31415
31393
|
const resolvedOptions = resolveSsnValidationOptions(options);
|
|
31416
|
-
const isValid =
|
|
31394
|
+
const isValid = index_default.valid(digits, resolvedOptions);
|
|
31417
31395
|
return {
|
|
31418
31396
|
isValid,
|
|
31419
31397
|
digits: isValid ? digits : null
|