@luftborn/custom-elements 2.1.2 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. package/demo/index.html +22 -0
  2. package/demo/index.js +352 -66
  3. package/demo/index.min.js +351 -65
  4. package/demo/index.min.js.map +1 -1
  5. package/dist/elements/Elements.d.ts +3 -1
  6. package/dist/elements/Elements.js +5 -1
  7. package/dist/elements/Elements.js.map +1 -1
  8. package/dist/elements/InternationaPhoneNumber/InternationaPhoneNumberElement.d.ts +1 -0
  9. package/dist/elements/InternationaPhoneNumber/InternationaPhoneNumberElement.js +8 -5
  10. package/dist/elements/InternationaPhoneNumber/InternationaPhoneNumberElement.js.map +1 -1
  11. package/dist/elements/SECompanyRegistrationElement/SECompanyRegistrationElement.d.ts +14 -0
  12. package/dist/elements/SECompanyRegistrationElement/SECompanyRegistrationElement.js +83 -0
  13. package/dist/elements/SECompanyRegistrationElement/SECompanyRegistrationElement.js.map +1 -0
  14. package/dist/elements/SEPersonalNumberElement/SEPersonalNumberElement.d.ts +14 -0
  15. package/dist/elements/SEPersonalNumberElement/SEPersonalNumberElement.js +83 -0
  16. package/dist/elements/SEPersonalNumberElement/SEPersonalNumberElement.js.map +1 -0
  17. package/dist/framework/Validation/Validators/SECompanyRegistration.d.ts +9 -0
  18. package/dist/framework/Validation/Validators/SECompanyRegistration.js +38 -0
  19. package/dist/framework/Validation/Validators/SECompanyRegistration.js.map +1 -0
  20. package/dist/framework/Validation/Validators/SEPersonalNumber.d.ts +6 -0
  21. package/dist/framework/Validation/Validators/SEPersonalNumber.js +71 -0
  22. package/dist/framework/Validation/Validators/SEPersonalNumber.js.map +1 -0
  23. package/package.json +1 -1
  24. package/src/elements/Elements.ts +5 -1
  25. package/src/elements/InternationaPhoneNumber/InternationaPhoneNumberElement.ts +7 -5
  26. package/src/elements/SECompanyRegistrationElement/SECompanyRegistrationElement.ts +73 -0
  27. package/src/elements/SEPersonalNumberElement/SEPersonalNumberElement.ts +73 -0
  28. package/src/framework/Validation/Validators/SECompanyRegistration.ts +40 -0
  29. package/src/framework/Validation/Validators/SEPersonalNumber.ts +80 -0
package/demo/index.min.js CHANGED
@@ -11,7 +11,7 @@ document.onreadystatechange = function () {
11
11
  }
12
12
  };
13
13
 
14
- },{"./../src/index":68}],2:[function(require,module,exports){
14
+ },{"./../src/index":72}],2:[function(require,module,exports){
15
15
  /**
16
16
  @license @nocompile
17
17
  Copyright (c) 2018 The Polymer Project Authors. All rights reserved.
@@ -2364,7 +2364,7 @@ var CustomForm = /** @class */ (function () {
2364
2364
  }());
2365
2365
  exports.CustomForm = CustomForm;
2366
2366
 
2367
- },{"./elements/FileField/FileFieldElement":20,"./framework/Utilities/ArrayUtil":54,"./framework/Utilities/MakeRequest":57}],10:[function(require,module,exports){
2367
+ },{"./elements/FileField/FileFieldElement":20,"./framework/Utilities/ArrayUtil":56,"./framework/Utilities/MakeRequest":59}],10:[function(require,module,exports){
2368
2368
  "use strict";
2369
2369
  var __extends = (this && this.__extends) || (function () {
2370
2370
  var extendStatics = function (d, b) {
@@ -2572,7 +2572,7 @@ var AddressElement = /** @class */ (function (_super) {
2572
2572
  }(CustomInputElement_1.CustomInputElement));
2573
2573
  exports.AddressElement = AddressElement;
2574
2574
 
2575
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Language/Translator":52,"../../framework/Polyfills/getAttributeNamesPolyfill":53,"../../framework/Utilities/debouncer":60,"../../framework/custom-element.decorator":67}],11:[function(require,module,exports){
2575
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Language/Translator":54,"../../framework/Polyfills/getAttributeNamesPolyfill":55,"../../framework/Utilities/debouncer":62,"../../framework/custom-element.decorator":71}],11:[function(require,module,exports){
2576
2576
  "use strict";
2577
2577
  var __extends = (this && this.__extends) || (function () {
2578
2578
  var extendStatics = function (d, b) {
@@ -2701,7 +2701,7 @@ var BankFieldElement = /** @class */ (function (_super) {
2701
2701
  }(CustomInputElement_1.CustomInputElement));
2702
2702
  exports.BankFieldElement = BankFieldElement;
2703
2703
 
2704
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Language/Translator":52,"../../framework/Validation/Validators/BankAccount":61,"../../framework/Validation/Validators/BankAccountRegistrationNumber":62,"../../framework/custom-element.decorator":67}],12:[function(require,module,exports){
2704
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Language/Translator":54,"../../framework/Validation/Validators/BankAccount":63,"../../framework/Validation/Validators/BankAccountRegistrationNumber":64,"../../framework/custom-element.decorator":71}],12:[function(require,module,exports){
2705
2705
  "use strict";
2706
2706
  var __extends = (this && this.__extends) || (function () {
2707
2707
  var extendStatics = function (d, b) {
@@ -2785,7 +2785,7 @@ var CPRElement = /** @class */ (function (_super) {
2785
2785
  }(CustomInputElement_1.CustomInputElement));
2786
2786
  exports.CPRElement = CPRElement;
2787
2787
 
2788
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Validation/Validators/CPR":65,"../../framework/custom-element.decorator":67}],13:[function(require,module,exports){
2788
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Validation/Validators/CPR":67,"../../framework/custom-element.decorator":71}],13:[function(require,module,exports){
2789
2789
  "use strict";
2790
2790
  var __extends = (this && this.__extends) || (function () {
2791
2791
  var extendStatics = function (d, b) {
@@ -2869,7 +2869,7 @@ var CVRElement = /** @class */ (function (_super) {
2869
2869
  }(CustomInputElement_1.CustomInputElement));
2870
2870
  exports.CVRElement = CVRElement;
2871
2871
 
2872
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Validation/Validators/CVR":66,"../../framework/custom-element.decorator":67}],14:[function(require,module,exports){
2872
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Validation/Validators/CVR":68,"../../framework/custom-element.decorator":71}],14:[function(require,module,exports){
2873
2873
  "use strict";
2874
2874
  var __extends = (this && this.__extends) || (function () {
2875
2875
  var extendStatics = function (d, b) {
@@ -2967,7 +2967,7 @@ var CheckBoxElement = /** @class */ (function (_super) {
2967
2967
  }(CustomInputElement_1.CustomInputElement));
2968
2968
  exports.CheckBoxElement = CheckBoxElement;
2969
2969
 
2970
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Utilities/StringUtil":58,"../../framework/custom-element.decorator":67}],15:[function(require,module,exports){
2970
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Utilities/StringUtil":60,"../../framework/custom-element.decorator":71}],15:[function(require,module,exports){
2971
2971
  "use strict";
2972
2972
  var __extends = (this && this.__extends) || (function () {
2973
2973
  var extendStatics = function (d, b) {
@@ -3051,7 +3051,7 @@ var CustomRegularExpressionElement = /** @class */ (function (_super) {
3051
3051
  }(CustomInputElement_1.CustomInputElement));
3052
3052
  exports.CustomRegularExpressionElement = CustomRegularExpressionElement;
3053
3053
 
3054
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/custom-element.decorator":67}],16:[function(require,module,exports){
3054
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/custom-element.decorator":71}],16:[function(require,module,exports){
3055
3055
  "use strict";
3056
3056
  var __extends = (this && this.__extends) || (function () {
3057
3057
  var extendStatics = function (d, b) {
@@ -3138,7 +3138,7 @@ var DateFieldElement = /** @class */ (function (_super) {
3138
3138
  }(CustomInputElement_1.CustomInputElement));
3139
3139
  exports.DateFieldElement = DateFieldElement;
3140
3140
 
3141
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/custom-element.decorator":67}],17:[function(require,module,exports){
3141
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/custom-element.decorator":71}],17:[function(require,module,exports){
3142
3142
  "use strict";
3143
3143
  var __extends = (this && this.__extends) || (function () {
3144
3144
  var extendStatics = function (d, b) {
@@ -3233,10 +3233,10 @@ var DropDownListElement = /** @class */ (function (_super) {
3233
3233
  }(CustomInputElement_1.CustomInputElement));
3234
3234
  exports.DropDownListElement = DropDownListElement;
3235
3235
 
3236
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Utilities/StringUtil":58,"../../framework/custom-element.decorator":67}],18:[function(require,module,exports){
3236
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Utilities/StringUtil":60,"../../framework/custom-element.decorator":71}],18:[function(require,module,exports){
3237
3237
  "use strict";
3238
3238
  Object.defineProperty(exports, "__esModule", { value: true });
3239
- exports.TypeAheadElement = exports.BankFieldElement = exports.IdentificationElement = exports.CVRElement = exports.CPRElement = exports.IntPhoneFieldElement = exports.DateFieldElement = exports.CustomRegularExpressionElement = exports.NumericFieldElement = exports.FileFieldElement = exports.DropDownListElement = exports.TextAreaElement = exports.RadioButtonGroupElement = exports.CheckBoxElement = exports.EmailFieldElement = exports.TextFieldElement = exports.AddressElement = void 0;
3239
+ exports.SECompanyRegistrationElement = exports.SEPersonalNumberElement = exports.TypeAheadElement = exports.BankFieldElement = exports.IdentificationElement = exports.CVRElement = exports.CPRElement = exports.IntPhoneFieldElement = exports.DateFieldElement = exports.CustomRegularExpressionElement = exports.NumericFieldElement = exports.FileFieldElement = exports.DropDownListElement = exports.TextAreaElement = exports.RadioButtonGroupElement = exports.CheckBoxElement = exports.EmailFieldElement = exports.TextFieldElement = exports.AddressElement = void 0;
3240
3240
  var AddressElement_1 = require("./Address/AddressElement");
3241
3241
  Object.defineProperty(exports, "AddressElement", { enumerable: true, get: function () { return AddressElement_1.AddressElement; } });
3242
3242
  var TextFieldElement_1 = require("./TextField/TextFieldElement");
@@ -3271,8 +3271,12 @@ var BankFieldElement_1 = require("./BankField/BankFieldElement");
3271
3271
  Object.defineProperty(exports, "BankFieldElement", { enumerable: true, get: function () { return BankFieldElement_1.BankFieldElement; } });
3272
3272
  var TypeAheadElement_1 = require("./TypeAhead/TypeAheadElement");
3273
3273
  Object.defineProperty(exports, "TypeAheadElement", { enumerable: true, get: function () { return TypeAheadElement_1.TypeAheadElement; } });
3274
+ var SEPersonalNumberElement_1 = require("./SEPersonalNumberElement/SEPersonalNumberElement");
3275
+ Object.defineProperty(exports, "SEPersonalNumberElement", { enumerable: true, get: function () { return SEPersonalNumberElement_1.SEPersonalNumberElement; } });
3276
+ var SECompanyRegistrationElement_1 = require("./SECompanyRegistrationElement/SECompanyRegistrationElement");
3277
+ Object.defineProperty(exports, "SECompanyRegistrationElement", { enumerable: true, get: function () { return SECompanyRegistrationElement_1.SECompanyRegistrationElement; } });
3274
3278
 
3275
- },{"./Address/AddressElement":10,"./BankField/BankFieldElement":11,"./CPRElement/CPRElement":12,"./CVRElement/CVRElement":13,"./CheckBoxElement/CheckBoxElement":14,"./CustomRegularExpression/CustomRegularExpressionElement":15,"./DateField/DateFieldElement":16,"./DropDownList/DropDownListElement":17,"./EmailField/EmailFieldElement":19,"./FileField/FileFieldElement":20,"./IdentificationElement/IdentificationElement":21,"./InternationaPhoneNumber/InternationaPhoneNumberElement":24,"./NumericField/NumericFieldElement":25,"./RadioButtonGroup/RadioButtonGroupElement":26,"./TextAreaElement/TextAreaElement":27,"./TextField/TextFieldElement":28,"./TypeAhead/TypeAheadElement":29}],19:[function(require,module,exports){
3279
+ },{"./Address/AddressElement":10,"./BankField/BankFieldElement":11,"./CPRElement/CPRElement":12,"./CVRElement/CVRElement":13,"./CheckBoxElement/CheckBoxElement":14,"./CustomRegularExpression/CustomRegularExpressionElement":15,"./DateField/DateFieldElement":16,"./DropDownList/DropDownListElement":17,"./EmailField/EmailFieldElement":19,"./FileField/FileFieldElement":20,"./IdentificationElement/IdentificationElement":21,"./InternationaPhoneNumber/InternationaPhoneNumberElement":24,"./NumericField/NumericFieldElement":25,"./RadioButtonGroup/RadioButtonGroupElement":26,"./SECompanyRegistrationElement/SECompanyRegistrationElement":27,"./SEPersonalNumberElement/SEPersonalNumberElement":28,"./TextAreaElement/TextAreaElement":29,"./TextField/TextFieldElement":30,"./TypeAhead/TypeAheadElement":31}],19:[function(require,module,exports){
3276
3280
  "use strict";
3277
3281
  var __extends = (this && this.__extends) || (function () {
3278
3282
  var extendStatics = function (d, b) {
@@ -3357,7 +3361,7 @@ var EmailFieldElement = /** @class */ (function (_super) {
3357
3361
  }(CustomInputElement_1.CustomInputElement));
3358
3362
  exports.EmailFieldElement = EmailFieldElement;
3359
3363
 
3360
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/custom-element.decorator":67}],20:[function(require,module,exports){
3364
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/custom-element.decorator":71}],20:[function(require,module,exports){
3361
3365
  "use strict";
3362
3366
  var __extends = (this && this.__extends) || (function () {
3363
3367
  var extendStatics = function (d, b) {
@@ -3462,7 +3466,7 @@ var FileFieldElement = /** @class */ (function (_super) {
3462
3466
  }(CustomInputElement_1.CustomInputElement));
3463
3467
  exports.FileFieldElement = FileFieldElement;
3464
3468
 
3465
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Polyfills/getAttributeNamesPolyfill":53,"../../framework/custom-element.decorator":67}],21:[function(require,module,exports){
3469
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Polyfills/getAttributeNamesPolyfill":55,"../../framework/custom-element.decorator":71}],21:[function(require,module,exports){
3466
3470
  "use strict";
3467
3471
  var __extends = (this && this.__extends) || (function () {
3468
3472
  var extendStatics = function (d, b) {
@@ -3558,7 +3562,7 @@ var IdentificationElement = /** @class */ (function (_super) {
3558
3562
  }(CustomInputElement_1.CustomInputElement));
3559
3563
  exports.IdentificationElement = IdentificationElement;
3560
3564
 
3561
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Validation/Validators/BankIdNorway":63,"../../framework/Validation/Validators/BankIdSweden":64,"../../framework/Validation/Validators/CPR":65,"../../framework/Validation/Validators/CVR":66,"../../framework/custom-element.decorator":67}],22:[function(require,module,exports){
3565
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Validation/Validators/BankIdNorway":65,"../../framework/Validation/Validators/BankIdSweden":66,"../../framework/Validation/Validators/CPR":67,"../../framework/Validation/Validators/CVR":68,"../../framework/custom-element.decorator":71}],22:[function(require,module,exports){
3562
3566
  "use strict";
3563
3567
  Object.defineProperty(exports, "__esModule", { value: true });
3564
3568
  function GetFlagsUrl() {
@@ -3609,7 +3613,9 @@ var Flags2x_1 = require("./Flags2x");
3609
3613
  var IntPhoneFieldElement = /** @class */ (function (_super) {
3610
3614
  __extends(IntPhoneFieldElement, _super);
3611
3615
  function IntPhoneFieldElement() {
3612
- return _super.call(this) || this;
3616
+ var _this = _super.call(this) || this;
3617
+ _this.UTILS_URL = 'https://cdnjs.cloudflare.com/ajax/libs/intl-tel-input/15.0.1/js/utils.js';
3618
+ return _this;
3613
3619
  }
3614
3620
  Object.defineProperty(IntPhoneFieldElement.prototype, "value", {
3615
3621
  get: function () {
@@ -3656,6 +3662,7 @@ var IntPhoneFieldElement = /** @class */ (function (_super) {
3656
3662
  };
3657
3663
  var isIplookUpDisabled = ((_a = this.getAttribute('data-disable-iplookup')) === null || _a === void 0 ? void 0 : _a.toLowerCase()) === "true";
3658
3664
  var defaultCountry = isIplookUpDisabled ? 'dk' : 'auto';
3665
+ var utilsUrl = this.getAttribute('data-utils-url');
3659
3666
  var country = (_b = this.getAttribute('data-country')) === null || _b === void 0 ? void 0 : _b.toLowerCase();
3660
3667
  this.intlTelInput = intlTelInput(this.phone, {
3661
3668
  geoIpLookup: isIplookUpDisabled ? null : geoIpLookup,
@@ -3663,7 +3670,7 @@ var IntPhoneFieldElement = /** @class */ (function (_super) {
3663
3670
  initialCountry: country !== null && country !== void 0 ? country : defaultCountry,
3664
3671
  preferredCountries: ["dk", "se", "gb"],
3665
3672
  nationalMode: true,
3666
- utilsScript: 'https://cdnjs.cloudflare.com/ajax/libs/intl-tel-input/15.0.1/js/utils.js',
3673
+ utilsScript: utilsUrl !== null && utilsUrl !== void 0 ? utilsUrl : this.UTILS_URL,
3667
3674
  });
3668
3675
  this.intlTelInput.promise.then(function (e) {
3669
3676
  setTimeout(function () {
@@ -3672,9 +3679,9 @@ var IntPhoneFieldElement = /** @class */ (function (_super) {
3672
3679
  });
3673
3680
  var isLocalFlagEnabled = ((_c = this.getAttribute('data-local-flag')) === null || _c === void 0 ? void 0 : _c.toLowerCase()) === "true";
3674
3681
  if (isLocalFlagEnabled) {
3675
- var flagWrapper = this.shadowRoot.querySelector(".iti__flag");
3676
- if (flagWrapper) {
3677
- flagWrapper.style.backgroundImage = "url(" + (0, Flags_1.default)() + ")";
3682
+ var flagWrappers = this.shadowRoot.querySelectorAll(".iti__flag");
3683
+ if (flagWrappers.length > 0) {
3684
+ flagWrappers.forEach(function (f) { return f.style.backgroundImage = "url(" + (0, Flags_1.default)() + ")"; });
3678
3685
  }
3679
3686
  }
3680
3687
  };
@@ -3699,7 +3706,7 @@ var IntPhoneFieldElement = /** @class */ (function (_super) {
3699
3706
  }(CustomInputElement_1.CustomInputElement));
3700
3707
  exports.IntPhoneFieldElement = IntPhoneFieldElement;
3701
3708
 
3702
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Utilities/MakeRequest":57,"../../framework/custom-element.decorator":67,"./Flags":22,"./Flags2x":23,"intl-tel-input":6}],25:[function(require,module,exports){
3709
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Utilities/MakeRequest":59,"../../framework/custom-element.decorator":71,"./Flags":22,"./Flags2x":23,"intl-tel-input":6}],25:[function(require,module,exports){
3703
3710
  "use strict";
3704
3711
  var __extends = (this && this.__extends) || (function () {
3705
3712
  var extendStatics = function (d, b) {
@@ -3792,7 +3799,7 @@ var NumericFieldElement = /** @class */ (function (_super) {
3792
3799
  }(CustomInputElement_1.CustomInputElement));
3793
3800
  exports.NumericFieldElement = NumericFieldElement;
3794
3801
 
3795
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/custom-element.decorator":67}],26:[function(require,module,exports){
3802
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/custom-element.decorator":71}],26:[function(require,module,exports){
3796
3803
  "use strict";
3797
3804
  var __extends = (this && this.__extends) || (function () {
3798
3805
  var extendStatics = function (d, b) {
@@ -3893,7 +3900,175 @@ var RadioButtonGroupElement = /** @class */ (function (_super) {
3893
3900
  }(CustomInputElement_1.CustomInputElement));
3894
3901
  exports.RadioButtonGroupElement = RadioButtonGroupElement;
3895
3902
 
3896
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Utilities/StringUtil":58,"../../framework/custom-element.decorator":67}],27:[function(require,module,exports){
3903
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Utilities/StringUtil":60,"../../framework/custom-element.decorator":71}],27:[function(require,module,exports){
3904
+ "use strict";
3905
+ var __extends = (this && this.__extends) || (function () {
3906
+ var extendStatics = function (d, b) {
3907
+ extendStatics = Object.setPrototypeOf ||
3908
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
3909
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
3910
+ return extendStatics(d, b);
3911
+ };
3912
+ return function (d, b) {
3913
+ if (typeof b !== "function" && b !== null)
3914
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
3915
+ extendStatics(d, b);
3916
+ function __() { this.constructor = d; }
3917
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
3918
+ };
3919
+ })();
3920
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3921
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3922
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
3923
+ 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;
3924
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
3925
+ };
3926
+ Object.defineProperty(exports, "__esModule", { value: true });
3927
+ exports.SECompanyRegistrationElement = void 0;
3928
+ var custom_element_decorator_1 = require("../../framework/custom-element.decorator");
3929
+ var CustomInputElement_1 = require("../../framework/CustomInputElement");
3930
+ var CustomEvents_1 = require("../../framework/CustomEvents");
3931
+ var SECompanyRegistration_1 = require("../../framework/Validation/Validators/SECompanyRegistration");
3932
+ var SECompanyRegistrationElement = /** @class */ (function (_super) {
3933
+ __extends(SECompanyRegistrationElement, _super);
3934
+ function SECompanyRegistrationElement() {
3935
+ var _this = _super.call(this) || this;
3936
+ _this.validator = new SECompanyRegistration_1.default();
3937
+ return _this;
3938
+ }
3939
+ Object.defineProperty(SECompanyRegistrationElement.prototype, "value", {
3940
+ get: function () {
3941
+ return "" + this.text.value;
3942
+ },
3943
+ set: function (value) {
3944
+ this.text.value = value;
3945
+ },
3946
+ enumerable: false,
3947
+ configurable: true
3948
+ });
3949
+ Object.defineProperty(SECompanyRegistrationElement.prototype, "valid", {
3950
+ get: function () {
3951
+ return this.validator.isSatisfiedBy(this.value, !this.required);
3952
+ },
3953
+ enumerable: false,
3954
+ configurable: true
3955
+ });
3956
+ SECompanyRegistrationElement.prototype.connectedCallback = function () {
3957
+ _super.prototype.connectedCallback.call(this);
3958
+ };
3959
+ SECompanyRegistrationElement.prototype.initChildInputs = function () {
3960
+ this.text = _super.prototype.getChildInput.call(this, '#se-company-registration-field');
3961
+ this.text.addEventListener('change', this.change.bind(this));
3962
+ if (this.required) {
3963
+ this.text.setAttribute('required', '');
3964
+ }
3965
+ };
3966
+ // events
3967
+ SECompanyRegistrationElement.prototype.change = function ($event) {
3968
+ this.touched = true;
3969
+ this.onChange.emit(new CustomEvents_1.CustomElementEventArgs(this.value, 'change'));
3970
+ };
3971
+ SECompanyRegistrationElement.prototype.validate = function () {
3972
+ this.valid;
3973
+ this.onValidate.emit(new CustomEvents_1.CustomElementEventArgs(this.value, 'validate'));
3974
+ };
3975
+ SECompanyRegistrationElement = __decorate([
3976
+ (0, custom_element_decorator_1.default)({
3977
+ selector: 'se-company-registration-element',
3978
+ template: "\n <div class=\"wrapper\">\n <input type=\"text\" id='se-company-registration-field' placeholder='SSSSSSSSSS'/>\n </div>",
3979
+ style: "\n :host{\n width:100%;\n }\n .wrapper{\n display:flex;\n }\n input{\n box-sizing: border-box;\n width: 100% !important;\n border: none;\n background-color: #f1f4ff;\n margin: 2px;\n resize: none;\n }",
3980
+ useShadow: true,
3981
+ })
3982
+ ], SECompanyRegistrationElement);
3983
+ return SECompanyRegistrationElement;
3984
+ }(CustomInputElement_1.CustomInputElement));
3985
+ exports.SECompanyRegistrationElement = SECompanyRegistrationElement;
3986
+
3987
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Validation/Validators/SECompanyRegistration":69,"../../framework/custom-element.decorator":71}],28:[function(require,module,exports){
3988
+ "use strict";
3989
+ var __extends = (this && this.__extends) || (function () {
3990
+ var extendStatics = function (d, b) {
3991
+ extendStatics = Object.setPrototypeOf ||
3992
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
3993
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
3994
+ return extendStatics(d, b);
3995
+ };
3996
+ return function (d, b) {
3997
+ if (typeof b !== "function" && b !== null)
3998
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
3999
+ extendStatics(d, b);
4000
+ function __() { this.constructor = d; }
4001
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
4002
+ };
4003
+ })();
4004
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
4005
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4006
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4007
+ 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;
4008
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
4009
+ };
4010
+ Object.defineProperty(exports, "__esModule", { value: true });
4011
+ exports.SEPersonalNumberElement = void 0;
4012
+ var custom_element_decorator_1 = require("../../framework/custom-element.decorator");
4013
+ var CustomInputElement_1 = require("../../framework/CustomInputElement");
4014
+ var CustomEvents_1 = require("../../framework/CustomEvents");
4015
+ var SEPersonalNumber_1 = require("../../framework/Validation/Validators/SEPersonalNumber");
4016
+ var SEPersonalNumberElement = /** @class */ (function (_super) {
4017
+ __extends(SEPersonalNumberElement, _super);
4018
+ function SEPersonalNumberElement() {
4019
+ var _this = _super.call(this) || this;
4020
+ _this.validator = new SEPersonalNumber_1.default();
4021
+ return _this;
4022
+ }
4023
+ Object.defineProperty(SEPersonalNumberElement.prototype, "value", {
4024
+ get: function () {
4025
+ return "" + this.text.value;
4026
+ },
4027
+ set: function (value) {
4028
+ this.text.value = value;
4029
+ },
4030
+ enumerable: false,
4031
+ configurable: true
4032
+ });
4033
+ Object.defineProperty(SEPersonalNumberElement.prototype, "valid", {
4034
+ get: function () {
4035
+ return this.validator.isSatisfiedBy(this.value, !this.required);
4036
+ },
4037
+ enumerable: false,
4038
+ configurable: true
4039
+ });
4040
+ SEPersonalNumberElement.prototype.connectedCallback = function () {
4041
+ _super.prototype.connectedCallback.call(this);
4042
+ };
4043
+ SEPersonalNumberElement.prototype.initChildInputs = function () {
4044
+ this.text = _super.prototype.getChildInput.call(this, '#se-personal-number-field');
4045
+ this.text.addEventListener('change', this.change.bind(this));
4046
+ if (this.required) {
4047
+ this.text.setAttribute('required', '');
4048
+ }
4049
+ };
4050
+ // events
4051
+ SEPersonalNumberElement.prototype.change = function ($event) {
4052
+ this.touched = true;
4053
+ this.onChange.emit(new CustomEvents_1.CustomElementEventArgs(this.value, 'change'));
4054
+ };
4055
+ SEPersonalNumberElement.prototype.validate = function () {
4056
+ this.valid;
4057
+ this.onValidate.emit(new CustomEvents_1.CustomElementEventArgs(this.value, 'validate'));
4058
+ };
4059
+ SEPersonalNumberElement = __decorate([
4060
+ (0, custom_element_decorator_1.default)({
4061
+ selector: 'se-personal-number-element',
4062
+ template: "\n <div class=\"wrapper\">\n <input type=\"text\" id='se-personal-number-field' placeholder='(YY)YYMMDD-SSSS'/>\n </div>",
4063
+ style: "\n :host{\n width:100%;\n }\n .wrapper{\n display:flex;\n }\n input{\n box-sizing: border-box;\n width: 100% !important;\n border: none;\n background-color: #f1f4ff;\n margin: 2px;\n resize: none;\n }",
4064
+ useShadow: true,
4065
+ })
4066
+ ], SEPersonalNumberElement);
4067
+ return SEPersonalNumberElement;
4068
+ }(CustomInputElement_1.CustomInputElement));
4069
+ exports.SEPersonalNumberElement = SEPersonalNumberElement;
4070
+
4071
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Validation/Validators/SEPersonalNumber":70,"../../framework/custom-element.decorator":71}],29:[function(require,module,exports){
3897
4072
  "use strict";
3898
4073
  var __extends = (this && this.__extends) || (function () {
3899
4074
  var extendStatics = function (d, b) {
@@ -3974,7 +4149,7 @@ var TextAreaElement = /** @class */ (function (_super) {
3974
4149
  }(CustomInputElement_1.CustomInputElement));
3975
4150
  exports.TextAreaElement = TextAreaElement;
3976
4151
 
3977
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/custom-element.decorator":67}],28:[function(require,module,exports){
4152
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/custom-element.decorator":71}],30:[function(require,module,exports){
3978
4153
  "use strict";
3979
4154
  var __extends = (this && this.__extends) || (function () {
3980
4155
  var extendStatics = function (d, b) {
@@ -4055,7 +4230,7 @@ var TextFieldElement = /** @class */ (function (_super) {
4055
4230
  }(CustomInputElement_1.CustomInputElement));
4056
4231
  exports.TextFieldElement = TextFieldElement;
4057
4232
 
4058
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/custom-element.decorator":67}],29:[function(require,module,exports){
4233
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/custom-element.decorator":71}],31:[function(require,module,exports){
4059
4234
  "use strict";
4060
4235
  var __extends = (this && this.__extends) || (function () {
4061
4236
  var extendStatics = function (d, b) {
@@ -4266,7 +4441,7 @@ var TypeAheadElement = /** @class */ (function (_super) {
4266
4441
  }(CustomInputElement_1.CustomInputElement));
4267
4442
  exports.TypeAheadElement = TypeAheadElement;
4268
4443
 
4269
- },{"../../framework/CustomEvents":30,"../../framework/CustomInputElement":31,"../../framework/Utilities/DomUtility":56,"../../framework/custom-element.decorator":67}],30:[function(require,module,exports){
4444
+ },{"../../framework/CustomEvents":32,"../../framework/CustomInputElement":33,"../../framework/Utilities/DomUtility":58,"../../framework/custom-element.decorator":71}],32:[function(require,module,exports){
4270
4445
  "use strict";
4271
4446
  Object.defineProperty(exports, "__esModule", { value: true });
4272
4447
  exports.CustomElementEvent = exports.CustomElementEventArgs = void 0;
@@ -4315,7 +4490,7 @@ var CustomElementEvent = /** @class */ (function () {
4315
4490
  }());
4316
4491
  exports.CustomElementEvent = CustomElementEvent;
4317
4492
 
4318
- },{}],31:[function(require,module,exports){
4493
+ },{}],33:[function(require,module,exports){
4319
4494
  "use strict";
4320
4495
  var __extends = (this && this.__extends) || (function () {
4321
4496
  var extendStatics = function (d, b) {
@@ -4575,7 +4750,7 @@ var CustomInputElement = /** @class */ (function (_super) {
4575
4750
  }(HTMLElement));
4576
4751
  exports.CustomInputElement = CustomInputElement;
4577
4752
 
4578
- },{"./CustomEvents":30,"./Utilities/ArrayUtil":54,"./Utilities/DomUtil":55}],32:[function(require,module,exports){
4753
+ },{"./CustomEvents":32,"./Utilities/ArrayUtil":56,"./Utilities/DomUtil":57}],34:[function(require,module,exports){
4579
4754
  "use strict";
4580
4755
  Object.defineProperty(exports, "__esModule", { value: true });
4581
4756
  var BaseDictionary = /** @class */ (function () {
@@ -4597,7 +4772,7 @@ var BaseDictionary = /** @class */ (function () {
4597
4772
  }());
4598
4773
  exports.default = BaseDictionary;
4599
4774
 
4600
- },{}],33:[function(require,module,exports){
4775
+ },{}],35:[function(require,module,exports){
4601
4776
  "use strict";
4602
4777
  var __extends = (this && this.__extends) || (function () {
4603
4778
  var extendStatics = function (d, b) {
@@ -4638,7 +4813,7 @@ var CzechDictionary = /** @class */ (function (_super) {
4638
4813
  }(BaseDictionary_1.default));
4639
4814
  exports.default = CzechDictionary;
4640
4815
 
4641
- },{"./Base/BaseDictionary":32}],34:[function(require,module,exports){
4816
+ },{"./Base/BaseDictionary":34}],36:[function(require,module,exports){
4642
4817
  "use strict";
4643
4818
  var __extends = (this && this.__extends) || (function () {
4644
4819
  var extendStatics = function (d, b) {
@@ -4679,7 +4854,7 @@ var DanishDictionary = /** @class */ (function (_super) {
4679
4854
  }(BaseDictionary_1.default));
4680
4855
  exports.default = DanishDictionary;
4681
4856
 
4682
- },{"./Base/BaseDictionary":32}],35:[function(require,module,exports){
4857
+ },{"./Base/BaseDictionary":34}],37:[function(require,module,exports){
4683
4858
  "use strict";
4684
4859
  var __extends = (this && this.__extends) || (function () {
4685
4860
  var extendStatics = function (d, b) {
@@ -4720,7 +4895,7 @@ var DutchDictionary = /** @class */ (function (_super) {
4720
4895
  }(BaseDictionary_1.default));
4721
4896
  exports.default = DutchDictionary;
4722
4897
 
4723
- },{"./Base/BaseDictionary":32}],36:[function(require,module,exports){
4898
+ },{"./Base/BaseDictionary":34}],38:[function(require,module,exports){
4724
4899
  "use strict";
4725
4900
  var __extends = (this && this.__extends) || (function () {
4726
4901
  var extendStatics = function (d, b) {
@@ -4761,7 +4936,7 @@ var EnglishDictionary = /** @class */ (function (_super) {
4761
4936
  }(BaseDictionary_1.default));
4762
4937
  exports.default = EnglishDictionary;
4763
4938
 
4764
- },{"./Base/BaseDictionary":32}],37:[function(require,module,exports){
4939
+ },{"./Base/BaseDictionary":34}],39:[function(require,module,exports){
4765
4940
  "use strict";
4766
4941
  var __extends = (this && this.__extends) || (function () {
4767
4942
  var extendStatics = function (d, b) {
@@ -4802,7 +4977,7 @@ var EstonianDictionary = /** @class */ (function (_super) {
4802
4977
  }(BaseDictionary_1.default));
4803
4978
  exports.default = EstonianDictionary;
4804
4979
 
4805
- },{"./Base/BaseDictionary":32}],38:[function(require,module,exports){
4980
+ },{"./Base/BaseDictionary":34}],40:[function(require,module,exports){
4806
4981
  "use strict";
4807
4982
  var __extends = (this && this.__extends) || (function () {
4808
4983
  var extendStatics = function (d, b) {
@@ -4843,7 +5018,7 @@ var FinnishDictionary = /** @class */ (function (_super) {
4843
5018
  }(BaseDictionary_1.default));
4844
5019
  exports.default = FinnishDictionary;
4845
5020
 
4846
- },{"./Base/BaseDictionary":32}],39:[function(require,module,exports){
5021
+ },{"./Base/BaseDictionary":34}],41:[function(require,module,exports){
4847
5022
  "use strict";
4848
5023
  var __extends = (this && this.__extends) || (function () {
4849
5024
  var extendStatics = function (d, b) {
@@ -4884,7 +5059,7 @@ var FrenchDictionary = /** @class */ (function (_super) {
4884
5059
  }(BaseDictionary_1.default));
4885
5060
  exports.default = FrenchDictionary;
4886
5061
 
4887
- },{"./Base/BaseDictionary":32}],40:[function(require,module,exports){
5062
+ },{"./Base/BaseDictionary":34}],42:[function(require,module,exports){
4888
5063
  "use strict";
4889
5064
  var __extends = (this && this.__extends) || (function () {
4890
5065
  var extendStatics = function (d, b) {
@@ -4925,7 +5100,7 @@ var GermanDictionary = /** @class */ (function (_super) {
4925
5100
  }(BaseDictionary_1.default));
4926
5101
  exports.default = GermanDictionary;
4927
5102
 
4928
- },{"./Base/BaseDictionary":32}],41:[function(require,module,exports){
5103
+ },{"./Base/BaseDictionary":34}],43:[function(require,module,exports){
4929
5104
  "use strict";
4930
5105
  var __extends = (this && this.__extends) || (function () {
4931
5106
  var extendStatics = function (d, b) {
@@ -4966,7 +5141,7 @@ var GreekDictionary = /** @class */ (function (_super) {
4966
5141
  }(BaseDictionary_1.default));
4967
5142
  exports.default = GreekDictionary;
4968
5143
 
4969
- },{"./Base/BaseDictionary":32}],42:[function(require,module,exports){
5144
+ },{"./Base/BaseDictionary":34}],44:[function(require,module,exports){
4970
5145
  "use strict";
4971
5146
  var __extends = (this && this.__extends) || (function () {
4972
5147
  var extendStatics = function (d, b) {
@@ -5007,7 +5182,7 @@ var HungarianDictionary = /** @class */ (function (_super) {
5007
5182
  }(BaseDictionary_1.default));
5008
5183
  exports.default = HungarianDictionary;
5009
5184
 
5010
- },{"./Base/BaseDictionary":32}],43:[function(require,module,exports){
5185
+ },{"./Base/BaseDictionary":34}],45:[function(require,module,exports){
5011
5186
  "use strict";
5012
5187
  var __extends = (this && this.__extends) || (function () {
5013
5188
  var extendStatics = function (d, b) {
@@ -5048,7 +5223,7 @@ var IcelandicDictionary = /** @class */ (function (_super) {
5048
5223
  }(BaseDictionary_1.default));
5049
5224
  exports.default = IcelandicDictionary;
5050
5225
 
5051
- },{"./Base/BaseDictionary":32}],44:[function(require,module,exports){
5226
+ },{"./Base/BaseDictionary":34}],46:[function(require,module,exports){
5052
5227
  "use strict";
5053
5228
  var __extends = (this && this.__extends) || (function () {
5054
5229
  var extendStatics = function (d, b) {
@@ -5089,7 +5264,7 @@ var ItalianDictionary = /** @class */ (function (_super) {
5089
5264
  }(BaseDictionary_1.default));
5090
5265
  exports.default = ItalianDictionary;
5091
5266
 
5092
- },{"./Base/BaseDictionary":32}],45:[function(require,module,exports){
5267
+ },{"./Base/BaseDictionary":34}],47:[function(require,module,exports){
5093
5268
  "use strict";
5094
5269
  var __extends = (this && this.__extends) || (function () {
5095
5270
  var extendStatics = function (d, b) {
@@ -5130,7 +5305,7 @@ var LatvianDictionary = /** @class */ (function (_super) {
5130
5305
  }(BaseDictionary_1.default));
5131
5306
  exports.default = LatvianDictionary;
5132
5307
 
5133
- },{"./Base/BaseDictionary":32}],46:[function(require,module,exports){
5308
+ },{"./Base/BaseDictionary":34}],48:[function(require,module,exports){
5134
5309
  "use strict";
5135
5310
  var __extends = (this && this.__extends) || (function () {
5136
5311
  var extendStatics = function (d, b) {
@@ -5171,7 +5346,7 @@ var LituanianDictionary = /** @class */ (function (_super) {
5171
5346
  }(BaseDictionary_1.default));
5172
5347
  exports.default = LituanianDictionary;
5173
5348
 
5174
- },{"./Base/BaseDictionary":32}],47:[function(require,module,exports){
5349
+ },{"./Base/BaseDictionary":34}],49:[function(require,module,exports){
5175
5350
  "use strict";
5176
5351
  var __extends = (this && this.__extends) || (function () {
5177
5352
  var extendStatics = function (d, b) {
@@ -5212,7 +5387,7 @@ var NorwegianDictionary = /** @class */ (function (_super) {
5212
5387
  }(BaseDictionary_1.default));
5213
5388
  exports.default = NorwegianDictionary;
5214
5389
 
5215
- },{"./Base/BaseDictionary":32}],48:[function(require,module,exports){
5390
+ },{"./Base/BaseDictionary":34}],50:[function(require,module,exports){
5216
5391
  "use strict";
5217
5392
  var __extends = (this && this.__extends) || (function () {
5218
5393
  var extendStatics = function (d, b) {
@@ -5253,7 +5428,7 @@ var PolishDictionary = /** @class */ (function (_super) {
5253
5428
  }(BaseDictionary_1.default));
5254
5429
  exports.default = PolishDictionary;
5255
5430
 
5256
- },{"./Base/BaseDictionary":32}],49:[function(require,module,exports){
5431
+ },{"./Base/BaseDictionary":34}],51:[function(require,module,exports){
5257
5432
  "use strict";
5258
5433
  var __extends = (this && this.__extends) || (function () {
5259
5434
  var extendStatics = function (d, b) {
@@ -5294,7 +5469,7 @@ var PortugueseDictionary = /** @class */ (function (_super) {
5294
5469
  }(BaseDictionary_1.default));
5295
5470
  exports.default = PortugueseDictionary;
5296
5471
 
5297
- },{"./Base/BaseDictionary":32}],50:[function(require,module,exports){
5472
+ },{"./Base/BaseDictionary":34}],52:[function(require,module,exports){
5298
5473
  "use strict";
5299
5474
  var __extends = (this && this.__extends) || (function () {
5300
5475
  var extendStatics = function (d, b) {
@@ -5335,7 +5510,7 @@ var SpanishDictionary = /** @class */ (function (_super) {
5335
5510
  }(BaseDictionary_1.default));
5336
5511
  exports.default = SpanishDictionary;
5337
5512
 
5338
- },{"./Base/BaseDictionary":32}],51:[function(require,module,exports){
5513
+ },{"./Base/BaseDictionary":34}],53:[function(require,module,exports){
5339
5514
  "use strict";
5340
5515
  var __extends = (this && this.__extends) || (function () {
5341
5516
  var extendStatics = function (d, b) {
@@ -5376,7 +5551,7 @@ var SwedishDictionary = /** @class */ (function (_super) {
5376
5551
  }(BaseDictionary_1.default));
5377
5552
  exports.default = SwedishDictionary;
5378
5553
 
5379
- },{"./Base/BaseDictionary":32}],52:[function(require,module,exports){
5554
+ },{"./Base/BaseDictionary":34}],54:[function(require,module,exports){
5380
5555
  "use strict";
5381
5556
  Object.defineProperty(exports, "__esModule", { value: true });
5382
5557
  var DanishDictionary_1 = require("./Languages/DanishDictionary");
@@ -5493,7 +5668,7 @@ var Translator = /** @class */ (function () {
5493
5668
  }());
5494
5669
  exports.default = Translator;
5495
5670
 
5496
- },{"./Languages/CzechDictionary":33,"./Languages/DanishDictionary":34,"./Languages/DutchDictionary":35,"./Languages/EnglishDictionary":36,"./Languages/EstonianDictionary":37,"./Languages/FinnishDictionary":38,"./Languages/FrenchDictionary":39,"./Languages/GermanDictionary":40,"./Languages/GreekDictionary":41,"./Languages/HungarianDictionary":42,"./Languages/IcelandicDictionary":43,"./Languages/ItalianDictionary":44,"./Languages/LatvianDictionary":45,"./Languages/LituanianDictionary":46,"./Languages/NorwegianDictionary":47,"./Languages/PolishDictionary":48,"./Languages/PortugueseDictionary":49,"./Languages/SpanishDictionary":50,"./Languages/SwedishDictionary":51}],53:[function(require,module,exports){
5671
+ },{"./Languages/CzechDictionary":35,"./Languages/DanishDictionary":36,"./Languages/DutchDictionary":37,"./Languages/EnglishDictionary":38,"./Languages/EstonianDictionary":39,"./Languages/FinnishDictionary":40,"./Languages/FrenchDictionary":41,"./Languages/GermanDictionary":42,"./Languages/GreekDictionary":43,"./Languages/HungarianDictionary":44,"./Languages/IcelandicDictionary":45,"./Languages/ItalianDictionary":46,"./Languages/LatvianDictionary":47,"./Languages/LituanianDictionary":48,"./Languages/NorwegianDictionary":49,"./Languages/PolishDictionary":50,"./Languages/PortugueseDictionary":51,"./Languages/SpanishDictionary":52,"./Languages/SwedishDictionary":53}],55:[function(require,module,exports){
5497
5672
  "use strict";
5498
5673
  Object.defineProperty(exports, "__esModule", { value: true });
5499
5674
  function getAttributeNamesPolyfill() {
@@ -5512,7 +5687,7 @@ function getAttributeNamesPolyfill() {
5512
5687
  exports.default = getAttributeNamesPolyfill;
5513
5688
  ;
5514
5689
 
5515
- },{}],54:[function(require,module,exports){
5690
+ },{}],56:[function(require,module,exports){
5516
5691
  "use strict";
5517
5692
  Object.defineProperty(exports, "__esModule", { value: true });
5518
5693
  var ArrayUtil = /** @class */ (function () {
@@ -5550,7 +5725,7 @@ var ArrayUtil = /** @class */ (function () {
5550
5725
  }());
5551
5726
  exports.default = ArrayUtil;
5552
5727
 
5553
- },{}],55:[function(require,module,exports){
5728
+ },{}],57:[function(require,module,exports){
5554
5729
  "use strict";
5555
5730
  Object.defineProperty(exports, "__esModule", { value: true });
5556
5731
  var ViewportUtil_1 = require("./ViewportUtil");
@@ -5653,7 +5828,7 @@ var DomUtil = /** @class */ (function () {
5653
5828
  }());
5654
5829
  exports.default = DomUtil;
5655
5830
 
5656
- },{"./ViewportUtil":59}],56:[function(require,module,exports){
5831
+ },{"./ViewportUtil":61}],58:[function(require,module,exports){
5657
5832
  "use strict";
5658
5833
  Object.defineProperty(exports, "__esModule", { value: true });
5659
5834
  var DomUtility = /** @class */ (function () {
@@ -5667,7 +5842,7 @@ var DomUtility = /** @class */ (function () {
5667
5842
  }());
5668
5843
  exports.default = DomUtility;
5669
5844
 
5670
- },{}],57:[function(require,module,exports){
5845
+ },{}],59:[function(require,module,exports){
5671
5846
  "use strict";
5672
5847
  Object.defineProperty(exports, "__esModule", { value: true });
5673
5848
  var MakeRequest = /** @class */ (function () {
@@ -5717,7 +5892,7 @@ var MakeRequest = /** @class */ (function () {
5717
5892
  }());
5718
5893
  exports.default = MakeRequest;
5719
5894
 
5720
- },{}],58:[function(require,module,exports){
5895
+ },{}],60:[function(require,module,exports){
5721
5896
  "use strict";
5722
5897
  Object.defineProperty(exports, "__esModule", { value: true });
5723
5898
  exports.StringUtil = void 0;
@@ -5735,7 +5910,7 @@ var StringUtil = /** @class */ (function () {
5735
5910
  }());
5736
5911
  exports.StringUtil = StringUtil;
5737
5912
 
5738
- },{}],59:[function(require,module,exports){
5913
+ },{}],61:[function(require,module,exports){
5739
5914
  "use strict";
5740
5915
  Object.defineProperty(exports, "__esModule", { value: true });
5741
5916
  exports.ViewportUtil = void 0;
@@ -5779,7 +5954,7 @@ var ViewportUtil = /** @class */ (function () {
5779
5954
  }());
5780
5955
  exports.ViewportUtil = ViewportUtil;
5781
5956
 
5782
- },{}],60:[function(require,module,exports){
5957
+ },{}],62:[function(require,module,exports){
5783
5958
  "use strict";
5784
5959
  Object.defineProperty(exports, "__esModule", { value: true });
5785
5960
  var debouncer = function (func, wait, immediate) {
@@ -5832,7 +6007,7 @@ var debouncer = function (func, wait, immediate) {
5832
6007
  };
5833
6008
  exports.default = debouncer;
5834
6009
 
5835
- },{}],61:[function(require,module,exports){
6010
+ },{}],63:[function(require,module,exports){
5836
6011
  "use strict";
5837
6012
  Object.defineProperty(exports, "__esModule", { value: true });
5838
6013
  var BankAccountValidator = /** @class */ (function () {
@@ -5846,7 +6021,7 @@ var BankAccountValidator = /** @class */ (function () {
5846
6021
  }());
5847
6022
  exports.default = BankAccountValidator;
5848
6023
 
5849
- },{}],62:[function(require,module,exports){
6024
+ },{}],64:[function(require,module,exports){
5850
6025
  "use strict";
5851
6026
  Object.defineProperty(exports, "__esModule", { value: true });
5852
6027
  var BankAccountRegistrationNumberValidator = /** @class */ (function () {
@@ -5860,7 +6035,7 @@ var BankAccountRegistrationNumberValidator = /** @class */ (function () {
5860
6035
  }());
5861
6036
  exports.default = BankAccountRegistrationNumberValidator;
5862
6037
 
5863
- },{}],63:[function(require,module,exports){
6038
+ },{}],65:[function(require,module,exports){
5864
6039
  "use strict";
5865
6040
  Object.defineProperty(exports, "__esModule", { value: true });
5866
6041
  var BankIdNorwayValidator = /** @class */ (function () {
@@ -5883,7 +6058,7 @@ var BankIdNorwayValidator = /** @class */ (function () {
5883
6058
  }());
5884
6059
  exports.default = BankIdNorwayValidator;
5885
6060
 
5886
- },{}],64:[function(require,module,exports){
6061
+ },{}],66:[function(require,module,exports){
5887
6062
  "use strict";
5888
6063
  Object.defineProperty(exports, "__esModule", { value: true });
5889
6064
  var BankIdSwedenValidator = /** @class */ (function () {
@@ -5906,7 +6081,7 @@ var BankIdSwedenValidator = /** @class */ (function () {
5906
6081
  }());
5907
6082
  exports.default = BankIdSwedenValidator;
5908
6083
 
5909
- },{}],65:[function(require,module,exports){
6084
+ },{}],67:[function(require,module,exports){
5910
6085
  "use strict";
5911
6086
  Object.defineProperty(exports, "__esModule", { value: true });
5912
6087
  var CprValidator = /** @class */ (function () {
@@ -5983,7 +6158,7 @@ var CprValidator = /** @class */ (function () {
5983
6158
  }());
5984
6159
  exports.default = CprValidator;
5985
6160
 
5986
- },{}],66:[function(require,module,exports){
6161
+ },{}],68:[function(require,module,exports){
5987
6162
  "use strict";
5988
6163
  Object.defineProperty(exports, "__esModule", { value: true });
5989
6164
  var CvrValidator = /** @class */ (function () {
@@ -6015,7 +6190,118 @@ var CvrValidator = /** @class */ (function () {
6015
6190
  }());
6016
6191
  exports.default = CvrValidator;
6017
6192
 
6018
- },{}],67:[function(require,module,exports){
6193
+ },{}],69:[function(require,module,exports){
6194
+ "use strict";
6195
+ Object.defineProperty(exports, "__esModule", { value: true });
6196
+ var SECompanyRegistrationValidator = /** @class */ (function () {
6197
+ function SECompanyRegistrationValidator() {
6198
+ this.ORG_NR_SE_LUHN_WEIGHTS = [2, 1, 2, 1, 2, 1, 2, 1, 2, 1];
6199
+ this.sum = function (a, b) { return a + b; };
6200
+ }
6201
+ SECompanyRegistrationValidator.prototype.weighted = function (coefficients) {
6202
+ return function (value, index) { return value * coefficients[index]; };
6203
+ };
6204
+ SECompanyRegistrationValidator.prototype.isSatisfiedBy = function (input, allowEmpty) {
6205
+ if (allowEmpty && !input) {
6206
+ return true;
6207
+ }
6208
+ return this.orgNrSe(input);
6209
+ };
6210
+ SECompanyRegistrationValidator.prototype.orgNrSe = function (value) {
6211
+ return this.checkLuhnModulus10(value, this.ORG_NR_SE_LUHN_WEIGHTS);
6212
+ };
6213
+ SECompanyRegistrationValidator.prototype.checkLuhnModulus10 = function (testValue, luhnWeights) {
6214
+ var length = luhnWeights.length;
6215
+ var testValue$ = testValue.replace("-", "");
6216
+ if (testValue$.length !== length) {
6217
+ return false;
6218
+ }
6219
+ if (Number.isNaN(parseInt(testValue$, 10))) {
6220
+ return false;
6221
+ }
6222
+ var digits = testValue$.split("").map(Number);
6223
+ var luhnF = function (n) { return (n < length ? n : n - (length - 1)); };
6224
+ var luhnSum = luhnWeights.map(this.weighted(digits)).map(luhnF).reduce(this.sum);
6225
+ var controlSum = length - (+luhnSum % length);
6226
+ return controlSum % 10 === 0;
6227
+ };
6228
+ return SECompanyRegistrationValidator;
6229
+ }());
6230
+ exports.default = SECompanyRegistrationValidator;
6231
+
6232
+ },{}],70:[function(require,module,exports){
6233
+ "use strict";
6234
+ Object.defineProperty(exports, "__esModule", { value: true });
6235
+ var SEPersonalNumberValidator = /** @class */ (function () {
6236
+ function SEPersonalNumberValidator() {
6237
+ this.regex = new RegExp('^(\d{2}){0,1}(\d{2})(\d{2})(\d{2})([\+\-]?)((?!000)\d{3})(\d)$');
6238
+ }
6239
+ SEPersonalNumberValidator.prototype.isSatisfiedBy = function (input, allowEmpty) {
6240
+ if (allowEmpty === void 0) { allowEmpty = true; }
6241
+ if (allowEmpty && !input) {
6242
+ return true;
6243
+ }
6244
+ var matches = this.regex.exec(input);
6245
+ if (!matches || matches.length < 7) {
6246
+ return false;
6247
+ }
6248
+ var groups = matches;
6249
+ var decade = groups[2];
6250
+ var century;
6251
+ if (groups[1]) {
6252
+ century = groups[1];
6253
+ }
6254
+ else {
6255
+ var born = new Date().getFullYear() - parseInt(decade, 10);
6256
+ if (groups[5] && groups[5] === '+') {
6257
+ born -= 100;
6258
+ }
6259
+ century = born.toString().substring(0, 2);
6260
+ }
6261
+ // Create date time object.
6262
+ var day = parseInt(groups[4], 10);
6263
+ var isCoordinationNumber = day > 60;
6264
+ day = isCoordinationNumber ? day - 60 : day;
6265
+ var realDay = day;
6266
+ var year = decade;
6267
+ var fullYear = century + decade;
6268
+ var month = groups[3];
6269
+ var numbers = groups[6] + groups[7];
6270
+ var controlNumber = groups[7];
6271
+ // Try parse date-time to make sure it's actually a real date.
6272
+ if (!Date.parse(fullYear + "-" + month + "-" + realDay)) {
6273
+ return false;
6274
+ }
6275
+ if (this.luhn("" + year + month + day + groups[6]) !== parseInt(controlNumber, 10)) {
6276
+ return false;
6277
+ }
6278
+ return true;
6279
+ };
6280
+ SEPersonalNumberValidator.prototype.luhn = function (value) {
6281
+ // Luhm algorithm doubles every other number in the value.
6282
+ // To get the correct checksum digit we aught to append a 0 on the sequence.
6283
+ // If the result becomes a two digit number, subtract 9 from the value.
6284
+ // If the total sum is not a 0, the last checksum value should be subtracted from 10.
6285
+ // The resulting value is the check value that we use as control number.
6286
+ // The value passed is a string, so we aught to get the actual integer value from each char (i.e., subtract '0' which is 48).
6287
+ var t = value.split('').map(function (d) { return parseInt(d, 10); });
6288
+ var sum = 0;
6289
+ var temp;
6290
+ for (var i = 0; i < t.length; i++) {
6291
+ temp = t[i];
6292
+ temp *= 2 - (i % 2);
6293
+ if (temp > 9) {
6294
+ temp -= 9;
6295
+ }
6296
+ sum += temp;
6297
+ }
6298
+ return Math.ceil(sum / 10.0) * 10 - sum;
6299
+ };
6300
+ return SEPersonalNumberValidator;
6301
+ }());
6302
+ exports.default = SEPersonalNumberValidator;
6303
+
6304
+ },{}],71:[function(require,module,exports){
6019
6305
  "use strict";
6020
6306
  Object.defineProperty(exports, "__esModule", { value: true });
6021
6307
  var elementConfig = /** @class */ (function () {
@@ -6068,7 +6354,7 @@ var CustomElement = function (config) {
6068
6354
  };
6069
6355
  exports.default = CustomElement;
6070
6356
 
6071
- },{}],68:[function(require,module,exports){
6357
+ },{}],72:[function(require,module,exports){
6072
6358
  "use strict";
6073
6359
  Object.defineProperty(exports, "__esModule", { value: true });
6074
6360
  exports.CustomInputElement = exports.elements = exports.CustomForm = void 0;
@@ -6084,6 +6370,6 @@ Object.defineProperty(exports, "CustomInputElement", { enumerable: true, get: fu
6084
6370
  var elements = require("./elements/Elements");
6085
6371
  exports.elements = elements;
6086
6372
 
6087
- },{"./custom-form":9,"./elements/Elements":18,"./framework/CustomInputElement":31,"@webcomponents/webcomponentsjs/custom-elements-es5-adapter.js":2,"@webcomponents/webcomponentsjs/webcomponents-bundle":3,"@webcomponents/webcomponentsjs/webcomponents-loader.js":4}]},{},[1])
6373
+ },{"./custom-form":9,"./elements/Elements":18,"./framework/CustomInputElement":33,"@webcomponents/webcomponentsjs/custom-elements-es5-adapter.js":2,"@webcomponents/webcomponentsjs/webcomponents-bundle":3,"@webcomponents/webcomponentsjs/webcomponents-loader.js":4}]},{},[1])
6088
6374
 
6089
6375
  //# sourceMappingURL=index.min.js.map