dom-render 1.0.78 → 1.0.79

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/README.MD CHANGED
@@ -624,6 +624,13 @@ const data = DomRender.run(new Data(), document.querySelector('#app')!, config);
624
624
  using component
625
625
  ```html
626
626
  <my-element dr-on-component-init="$component.say();"></my-element>
627
+
628
+ <home value="${this.name}$" wow="${this.color}$">
629
+ ${#component#.homeName}$
630
+ <home value="${#component#.homeName}$" wow="${#component#.homeColor}$" dr-component-name="sub_component" dr-component-inner-html-name="innerHTML">
631
+ ${#sub_component#.homeName}$
632
+ </home>
633
+ </home>
627
634
  ```
628
635
  - attribute
629
636
  - dr-on-component-init: component created init call script
@@ -631,6 +638,10 @@ using component
631
638
  - $element: element instance
632
639
  - $attribute: element attribute object
633
640
  - $innerHTML: element innerHTML string
641
+ - #component#: component instance
642
+ - #innerHTML#: element innerHTML
643
+ - dr-component-name: renaming component variable name (default: component)
644
+ - dr-inner-html-name: renaming innerHTML variable name (default: innerHTML)
634
645
  ---
635
646
 
636
647
  # License
package/RawSet.js CHANGED
@@ -596,7 +596,7 @@ var RawSet = /** @class */ (function () {
596
596
  styles: styles,
597
597
  template: template,
598
598
  callBack: function (element, obj, rawSet, attrs) {
599
- var _a, _b, _c, _d;
599
+ var _a, _b, _c, _d, _e, _f;
600
600
  // console.log('callback------->', element)
601
601
  if (!obj.__domrender_components) {
602
602
  obj.__domrender_components = {};
@@ -666,15 +666,17 @@ var RawSet = /** @class */ (function () {
666
666
  (_d = instance === null || instance === void 0 ? void 0 : instance.onCreateRender) === null || _d === void 0 ? void 0 : _d.call.apply(_d, __spreadArray([instance], createParam, false));
667
667
  var applayTemplate = element.innerHTML;
668
668
  var innerHTMLThisRandom;
669
+ var componentName = (_e = element.getAttribute("".concat(EventManager_1.EventManager.attrPrefix, "component-name"))) !== null && _e !== void 0 ? _e : 'component';
670
+ var innerHTMLName = (_f = element.getAttribute("".concat(EventManager_1.EventManager.attrPrefix, "component-inner-html-name"))) !== null && _f !== void 0 ? _f : 'innerHTML';
669
671
  if (applayTemplate) {
670
672
  // if (rawSet.point.thisVariableName) {
671
673
  // 넘어온 innerHTML에 this가 있으면 해당안되게 우선 치환.
672
674
  innerHTMLThisRandom = RandomUtils_1.RandomUtils.uuid();
673
675
  applayTemplate = applayTemplate.replace(/this\./g, innerHTMLThisRandom);
674
676
  // }
675
- applayTemplate = applayTemplate.replace(/#component#/g, 'this');
677
+ applayTemplate = applayTemplate.replace(RegExp("#".concat(componentName, "#"), 'g'), 'this');
676
678
  }
677
- applayTemplate = template.replace(/#innerHTML#/g, applayTemplate);
679
+ applayTemplate = template.replace(RegExp("#".concat(innerHTMLName, "#"), 'g'), applayTemplate);
678
680
  // dr-on-component-init
679
681
  var oninit = element.getAttribute("".concat(EventManager_1.EventManager.attrPrefix, "on-component-init")); // dr-on-component-init
680
682
  if (oninit) {
package/dist/bundle.js CHANGED
@@ -2346,7 +2346,7 @@ var RawSet = /** @class */ (function () {
2346
2346
  styles: styles,
2347
2347
  template: template,
2348
2348
  callBack: function (element, obj, rawSet, attrs) {
2349
- var _a, _b, _c, _d;
2349
+ var _a, _b, _c, _d, _e, _f;
2350
2350
  // console.log('callback------->', element)
2351
2351
  if (!obj.__domrender_components) {
2352
2352
  obj.__domrender_components = {};
@@ -2416,15 +2416,17 @@ var RawSet = /** @class */ (function () {
2416
2416
  (_d = instance === null || instance === void 0 ? void 0 : instance.onCreateRender) === null || _d === void 0 ? void 0 : _d.call.apply(_d, __spreadArray([instance], createParam, false));
2417
2417
  var applayTemplate = element.innerHTML;
2418
2418
  var innerHTMLThisRandom;
2419
+ var componentName = (_e = element.getAttribute("".concat(EventManager.attrPrefix, "component-name"))) !== null && _e !== void 0 ? _e : 'component';
2420
+ var innerHTMLName = (_f = element.getAttribute("".concat(EventManager.attrPrefix, "component-inner-html-name"))) !== null && _f !== void 0 ? _f : 'innerHTML';
2419
2421
  if (applayTemplate) {
2420
2422
  // if (rawSet.point.thisVariableName) {
2421
2423
  // 넘어온 innerHTML에 this가 있으면 해당안되게 우선 치환.
2422
2424
  innerHTMLThisRandom = RandomUtils.uuid();
2423
2425
  applayTemplate = applayTemplate.replace(/this\./g, innerHTMLThisRandom);
2424
2426
  // }
2425
- applayTemplate = applayTemplate.replace(/#component#/g, 'this');
2427
+ applayTemplate = applayTemplate.replace(RegExp("#".concat(componentName, "#"), 'g'), 'this');
2426
2428
  }
2427
- applayTemplate = template.replace(/#innerHTML#/g, applayTemplate);
2429
+ applayTemplate = template.replace(RegExp("#".concat(innerHTMLName, "#"), 'g'), applayTemplate);
2428
2430
  // dr-on-component-init
2429
2431
  var oninit = element.getAttribute("".concat(EventManager.attrPrefix, "on-component-init")); // dr-on-component-init
2430
2432
  if (oninit) {
@@ -3400,21 +3402,6 @@ var DomRender = /** @class */ (function () {
3400
3402
  return DomRender;
3401
3403
  }());
3402
3404
 
3403
- var RenderManager = /** @class */ (function () {
3404
- function RenderManager() {
3405
- }
3406
- RenderManager.render = function (obj, target) {
3407
- if (target === void 0) { target = Object.keys(obj); }
3408
- var domRenderProxy = obj._DomRender_proxy;
3409
- if (domRenderProxy) {
3410
- target.forEach(function (it) {
3411
- domRenderProxy.root([it], obj[it]);
3412
- });
3413
- }
3414
- };
3415
- return RenderManager;
3416
- }());
3417
-
3418
3405
  var Appender = /** @class */ (function () {
3419
3406
  // [keys: string]: any;
3420
3407
  function Appender() {
@@ -3444,6 +3431,21 @@ var Appender = /** @class */ (function () {
3444
3431
  return Appender;
3445
3432
  }());
3446
3433
 
3434
+ var RenderManager = /** @class */ (function () {
3435
+ function RenderManager() {
3436
+ }
3437
+ RenderManager.render = function (obj, target) {
3438
+ if (target === void 0) { target = Object.keys(obj); }
3439
+ var domRenderProxy = obj._DomRender_proxy;
3440
+ if (domRenderProxy) {
3441
+ target.forEach(function (it) {
3442
+ domRenderProxy.root([it], obj[it]);
3443
+ });
3444
+ }
3445
+ };
3446
+ return RenderManager;
3447
+ }());
3448
+
3447
3449
  var AllCheckedValidatorArray = /** @class */ (function (_super) {
3448
3450
  __extends(AllCheckedValidatorArray, _super);
3449
3451
  function AllCheckedValidatorArray(value, target, event, autoValid) {
@@ -3470,19 +3472,6 @@ var AllUnCheckedValidatorArray = /** @class */ (function (_super) {
3470
3472
  return AllUnCheckedValidatorArray;
3471
3473
  }(ValidatorArray));
3472
3474
 
3473
- var CheckedValidator = /** @class */ (function (_super) {
3474
- __extends(CheckedValidator, _super);
3475
- function CheckedValidator(value, target, event, autoValid) {
3476
- if (autoValid === void 0) { autoValid = true; }
3477
- return _super.call(this, value, target, event, autoValid) || this;
3478
- }
3479
- CheckedValidator.prototype.valid = function () {
3480
- var _a, _b;
3481
- return (_b = (_a = this.getTarget()) === null || _a === void 0 ? void 0 : _a.checked) !== null && _b !== void 0 ? _b : false;
3482
- };
3483
- return CheckedValidator;
3484
- }(Validator));
3485
-
3486
3475
  var CountEqualsCheckedValidatorArray = /** @class */ (function (_super) {
3487
3476
  __extends(CountEqualsCheckedValidatorArray, _super);
3488
3477
  function CountEqualsCheckedValidatorArray(count, value, target, event, autoValid) {
@@ -3528,20 +3517,18 @@ var CountGreaterThanCheckedValidatorArray = /** @class */ (function (_super) {
3528
3517
  return CountGreaterThanCheckedValidatorArray;
3529
3518
  }(ValidatorArray));
3530
3519
 
3531
- var CountGreaterThanEqualsCheckedValidatorArray = /** @class */ (function (_super) {
3532
- __extends(CountGreaterThanEqualsCheckedValidatorArray, _super);
3533
- function CountGreaterThanEqualsCheckedValidatorArray(count, value, target, event, autoValid) {
3520
+ var CheckedValidator = /** @class */ (function (_super) {
3521
+ __extends(CheckedValidator, _super);
3522
+ function CheckedValidator(value, target, event, autoValid) {
3534
3523
  if (autoValid === void 0) { autoValid = true; }
3535
- var _this = _super.call(this, value, target, event, autoValid) || this;
3536
- _this.count = count;
3537
- return _this;
3524
+ return _super.call(this, value, target, event, autoValid) || this;
3538
3525
  }
3539
- CountGreaterThanEqualsCheckedValidatorArray.prototype.valid = function () {
3540
- var _a;
3541
- return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return it.checked; }).length >= this.count;
3526
+ CheckedValidator.prototype.valid = function () {
3527
+ var _a, _b;
3528
+ return (_b = (_a = this.getTarget()) === null || _a === void 0 ? void 0 : _a.checked) !== null && _b !== void 0 ? _b : false;
3542
3529
  };
3543
- return CountGreaterThanEqualsCheckedValidatorArray;
3544
- }(ValidatorArray));
3530
+ return CheckedValidator;
3531
+ }(Validator));
3545
3532
 
3546
3533
  var CountGreaterThanEqualsUnCheckedValidatorArray = /** @class */ (function (_super) {
3547
3534
  __extends(CountGreaterThanEqualsUnCheckedValidatorArray, _super);
@@ -3558,19 +3545,19 @@ var CountGreaterThanEqualsUnCheckedValidatorArray = /** @class */ (function (_su
3558
3545
  return CountGreaterThanEqualsUnCheckedValidatorArray;
3559
3546
  }(ValidatorArray));
3560
3547
 
3561
- var CountGreaterThanUnCheckedValidatorArray = /** @class */ (function (_super) {
3562
- __extends(CountGreaterThanUnCheckedValidatorArray, _super);
3563
- function CountGreaterThanUnCheckedValidatorArray(count, value, target, event, autoValid) {
3548
+ var CountGreaterThanEqualsCheckedValidatorArray = /** @class */ (function (_super) {
3549
+ __extends(CountGreaterThanEqualsCheckedValidatorArray, _super);
3550
+ function CountGreaterThanEqualsCheckedValidatorArray(count, value, target, event, autoValid) {
3564
3551
  if (autoValid === void 0) { autoValid = true; }
3565
3552
  var _this = _super.call(this, value, target, event, autoValid) || this;
3566
3553
  _this.count = count;
3567
3554
  return _this;
3568
3555
  }
3569
- CountGreaterThanUnCheckedValidatorArray.prototype.valid = function () {
3556
+ CountGreaterThanEqualsCheckedValidatorArray.prototype.valid = function () {
3570
3557
  var _a;
3571
- return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return !it.checked; }).length > this.count;
3558
+ return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return it.checked; }).length >= this.count;
3572
3559
  };
3573
- return CountGreaterThanUnCheckedValidatorArray;
3560
+ return CountGreaterThanEqualsCheckedValidatorArray;
3574
3561
  }(ValidatorArray));
3575
3562
 
3576
3563
  var CountLessThanEqualsCheckedValidatorArray = /** @class */ (function (_super) {
@@ -3588,6 +3575,36 @@ var CountLessThanEqualsCheckedValidatorArray = /** @class */ (function (_super)
3588
3575
  return CountLessThanEqualsCheckedValidatorArray;
3589
3576
  }(ValidatorArray));
3590
3577
 
3578
+ var CountLessThanEqualsUnCheckedValidatorArray = /** @class */ (function (_super) {
3579
+ __extends(CountLessThanEqualsUnCheckedValidatorArray, _super);
3580
+ function CountLessThanEqualsUnCheckedValidatorArray(count, value, target, event, autoValid) {
3581
+ if (autoValid === void 0) { autoValid = true; }
3582
+ var _this = _super.call(this, value, target, event, autoValid) || this;
3583
+ _this.count = count;
3584
+ return _this;
3585
+ }
3586
+ CountLessThanEqualsUnCheckedValidatorArray.prototype.valid = function () {
3587
+ var _a;
3588
+ return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return !it.checked; }).length <= this.count;
3589
+ };
3590
+ return CountLessThanEqualsUnCheckedValidatorArray;
3591
+ }(ValidatorArray));
3592
+
3593
+ var CountGreaterThanUnCheckedValidatorArray = /** @class */ (function (_super) {
3594
+ __extends(CountGreaterThanUnCheckedValidatorArray, _super);
3595
+ function CountGreaterThanUnCheckedValidatorArray(count, value, target, event, autoValid) {
3596
+ if (autoValid === void 0) { autoValid = true; }
3597
+ var _this = _super.call(this, value, target, event, autoValid) || this;
3598
+ _this.count = count;
3599
+ return _this;
3600
+ }
3601
+ CountGreaterThanUnCheckedValidatorArray.prototype.valid = function () {
3602
+ var _a;
3603
+ return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return !it.checked; }).length > this.count;
3604
+ };
3605
+ return CountGreaterThanUnCheckedValidatorArray;
3606
+ }(ValidatorArray));
3607
+
3591
3608
  var CountLessThanUnCheckedValidatorArray = /** @class */ (function (_super) {
3592
3609
  __extends(CountLessThanUnCheckedValidatorArray, _super);
3593
3610
  function CountLessThanUnCheckedValidatorArray(count, value, target, event, autoValid) {
@@ -3618,26 +3635,19 @@ var CountLessThanCheckedValidatorArray = /** @class */ (function (_super) {
3618
3635
  return CountLessThanCheckedValidatorArray;
3619
3636
  }(ValidatorArray));
3620
3637
 
3621
- var ExcludeCheckedValidatorArray = /** @class */ (function (_super) {
3622
- __extends(ExcludeCheckedValidatorArray, _super);
3623
- function ExcludeCheckedValidatorArray(include, allRequired, value, target, event, autoValid) {
3624
- if (allRequired === void 0) { allRequired = false; }
3638
+ var CountUnCheckedValidatorArray = /** @class */ (function (_super) {
3639
+ __extends(CountUnCheckedValidatorArray, _super);
3640
+ function CountUnCheckedValidatorArray(count, value, target, event, autoValid) {
3625
3641
  if (autoValid === void 0) { autoValid = true; }
3626
3642
  var _this = _super.call(this, value, target, event, autoValid) || this;
3627
- _this.include = include;
3628
- _this.allRequired = allRequired;
3643
+ _this.count = count;
3629
3644
  return _this;
3630
3645
  }
3631
- ExcludeCheckedValidatorArray.prototype.valid = function () {
3632
- var _this = this;
3646
+ CountUnCheckedValidatorArray.prototype.valid = function () {
3633
3647
  var _a;
3634
- var valus = (_a = this.value) !== null && _a !== void 0 ? _a : [];
3635
- var unCheckedValue = valus.filter(function (it) { return !it.checked; }).map(function (it) { return it.value; });
3636
- return unCheckedValue.length > 0 &&
3637
- (!(unCheckedValue.filter(function (it) { return !_this.include.includes(it); }).length > 0)) &&
3638
- (this.allRequired ? unCheckedValue.filter(function (it) { return _this.include.includes(it); }).length === this.include.length : true);
3648
+ return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return !it.checked; }).length >= this.count;
3639
3649
  };
3640
- return ExcludeCheckedValidatorArray;
3650
+ return CountUnCheckedValidatorArray;
3641
3651
  }(ValidatorArray));
3642
3652
 
3643
3653
  var EmptyValidator = /** @class */ (function (_super) {
@@ -3654,53 +3664,6 @@ var EmptyValidator = /** @class */ (function (_super) {
3654
3664
  return EmptyValidator;
3655
3665
  }(Validator));
3656
3666
 
3657
- var MultipleValidator = /** @class */ (function (_super) {
3658
- __extends(MultipleValidator, _super);
3659
- function MultipleValidator(validators, value, target, event, autoValid) {
3660
- if (autoValid === void 0) { autoValid = true; }
3661
- var _this = _super.call(this, value, target, event, autoValid) || this;
3662
- _this.validators = validators.map(function (it) {
3663
- it.setAutoValid(false);
3664
- it.setAutoValidAction(false);
3665
- return it;
3666
- });
3667
- _this.validators.forEach(function (it) {
3668
- it.set(_this.value, _this.getTarget(), _this.getEvent());
3669
- });
3670
- return _this;
3671
- }
3672
- MultipleValidator.prototype.changeValue = function (value) {
3673
- var _this = this;
3674
- this.validators.forEach(function (it) { return it.set(_this.value, _this.getTarget(), _this.getEvent()); });
3675
- };
3676
- MultipleValidator.prototype.validAction = function () {
3677
- return !(this.validators.filter(function (it) { return !it.validAction(); }).length > 0);
3678
- };
3679
- MultipleValidator.prototype.valid = function () {
3680
- // console.log('mm', this.validators)
3681
- return !(this.validators.filter(function (it) { return !it.valid(); }).length > 0);
3682
- };
3683
- return MultipleValidator;
3684
- }(Validator));
3685
-
3686
- var FormValidator = /** @class */ (function (_super) {
3687
- __extends(FormValidator, _super);
3688
- function FormValidator(target, event, autoValid) {
3689
- if (autoValid === void 0) { autoValid = true; }
3690
- return _super.call(this, undefined, target, event, autoValid) || this;
3691
- }
3692
- FormValidator.prototype.validAction = function () {
3693
- return _super.prototype.childValidAction.call(this);
3694
- };
3695
- FormValidator.prototype.valid = function () {
3696
- return this.childValid();
3697
- };
3698
- FormValidator.prototype.reset = function () {
3699
- this.targetReset();
3700
- };
3701
- return FormValidator;
3702
- }(Validator));
3703
-
3704
3667
  var IncludeCheckedValidatorArray = /** @class */ (function (_super) {
3705
3668
  __extends(IncludeCheckedValidatorArray, _super);
3706
3669
  function IncludeCheckedValidatorArray(include, allRequired, value, target, event, autoValid) {
@@ -3723,19 +3686,26 @@ var IncludeCheckedValidatorArray = /** @class */ (function (_super) {
3723
3686
  return IncludeCheckedValidatorArray;
3724
3687
  }(ValidatorArray));
3725
3688
 
3726
- var CountLessThanEqualsUnCheckedValidatorArray = /** @class */ (function (_super) {
3727
- __extends(CountLessThanEqualsUnCheckedValidatorArray, _super);
3728
- function CountLessThanEqualsUnCheckedValidatorArray(count, value, target, event, autoValid) {
3689
+ var ExcludeCheckedValidatorArray = /** @class */ (function (_super) {
3690
+ __extends(ExcludeCheckedValidatorArray, _super);
3691
+ function ExcludeCheckedValidatorArray(include, allRequired, value, target, event, autoValid) {
3692
+ if (allRequired === void 0) { allRequired = false; }
3729
3693
  if (autoValid === void 0) { autoValid = true; }
3730
3694
  var _this = _super.call(this, value, target, event, autoValid) || this;
3731
- _this.count = count;
3695
+ _this.include = include;
3696
+ _this.allRequired = allRequired;
3732
3697
  return _this;
3733
3698
  }
3734
- CountLessThanEqualsUnCheckedValidatorArray.prototype.valid = function () {
3699
+ ExcludeCheckedValidatorArray.prototype.valid = function () {
3700
+ var _this = this;
3735
3701
  var _a;
3736
- return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return !it.checked; }).length <= this.count;
3702
+ var valus = (_a = this.value) !== null && _a !== void 0 ? _a : [];
3703
+ var unCheckedValue = valus.filter(function (it) { return !it.checked; }).map(function (it) { return it.value; });
3704
+ return unCheckedValue.length > 0 &&
3705
+ (!(unCheckedValue.filter(function (it) { return !_this.include.includes(it); }).length > 0)) &&
3706
+ (this.allRequired ? unCheckedValue.filter(function (it) { return _this.include.includes(it); }).length === this.include.length : true);
3737
3707
  };
3738
- return CountLessThanEqualsUnCheckedValidatorArray;
3708
+ return ExcludeCheckedValidatorArray;
3739
3709
  }(ValidatorArray));
3740
3710
 
3741
3711
  var NotEmptyValidator = /** @class */ (function (_super) {
@@ -3753,20 +3723,52 @@ var NotEmptyValidator = /** @class */ (function (_super) {
3753
3723
  return NotEmptyValidator;
3754
3724
  }(Validator));
3755
3725
 
3756
- var CountUnCheckedValidatorArray = /** @class */ (function (_super) {
3757
- __extends(CountUnCheckedValidatorArray, _super);
3758
- function CountUnCheckedValidatorArray(count, value, target, event, autoValid) {
3726
+ var FormValidator = /** @class */ (function (_super) {
3727
+ __extends(FormValidator, _super);
3728
+ function FormValidator(target, event, autoValid) {
3729
+ if (autoValid === void 0) { autoValid = true; }
3730
+ return _super.call(this, undefined, target, event, autoValid) || this;
3731
+ }
3732
+ FormValidator.prototype.validAction = function () {
3733
+ return _super.prototype.childValidAction.call(this);
3734
+ };
3735
+ FormValidator.prototype.valid = function () {
3736
+ return this.childValid();
3737
+ };
3738
+ FormValidator.prototype.reset = function () {
3739
+ this.targetReset();
3740
+ };
3741
+ return FormValidator;
3742
+ }(Validator));
3743
+
3744
+ var MultipleValidator = /** @class */ (function (_super) {
3745
+ __extends(MultipleValidator, _super);
3746
+ function MultipleValidator(validators, value, target, event, autoValid) {
3759
3747
  if (autoValid === void 0) { autoValid = true; }
3760
3748
  var _this = _super.call(this, value, target, event, autoValid) || this;
3761
- _this.count = count;
3749
+ _this.validators = validators.map(function (it) {
3750
+ it.setAutoValid(false);
3751
+ it.setAutoValidAction(false);
3752
+ return it;
3753
+ });
3754
+ _this.validators.forEach(function (it) {
3755
+ it.set(_this.value, _this.getTarget(), _this.getEvent());
3756
+ });
3762
3757
  return _this;
3763
3758
  }
3764
- CountUnCheckedValidatorArray.prototype.valid = function () {
3765
- var _a;
3766
- return ((_a = this.value) !== null && _a !== void 0 ? _a : []).filter(function (it) { return !it.checked; }).length >= this.count;
3759
+ MultipleValidator.prototype.changeValue = function (value) {
3760
+ var _this = this;
3761
+ this.validators.forEach(function (it) { return it.set(_this.value, _this.getTarget(), _this.getEvent()); });
3767
3762
  };
3768
- return CountUnCheckedValidatorArray;
3769
- }(ValidatorArray));
3763
+ MultipleValidator.prototype.validAction = function () {
3764
+ return !(this.validators.filter(function (it) { return !it.validAction(); }).length > 0);
3765
+ };
3766
+ MultipleValidator.prototype.valid = function () {
3767
+ // console.log('mm', this.validators)
3768
+ return !(this.validators.filter(function (it) { return !it.valid(); }).length > 0);
3769
+ };
3770
+ return MultipleValidator;
3771
+ }(Validator));
3770
3772
 
3771
3773
  var NotRegExpTestValidator = /** @class */ (function (_super) {
3772
3774
  __extends(NotRegExpTestValidator, _super);
@@ -3813,6 +3815,19 @@ var RegExpTestValidator = /** @class */ (function (_super) {
3813
3815
  return RegExpTestValidator;
3814
3816
  }(Validator));
3815
3817
 
3818
+ var UnCheckedValidator = /** @class */ (function (_super) {
3819
+ __extends(UnCheckedValidator, _super);
3820
+ function UnCheckedValidator(value, target, event, autoValid) {
3821
+ if (autoValid === void 0) { autoValid = true; }
3822
+ return _super.call(this, value, target, event, autoValid) || this;
3823
+ }
3824
+ UnCheckedValidator.prototype.valid = function () {
3825
+ var _a, _b;
3826
+ return !((_b = (_a = this.getTarget()) === null || _a === void 0 ? void 0 : _a.checked) !== null && _b !== void 0 ? _b : false);
3827
+ };
3828
+ return UnCheckedValidator;
3829
+ }(Validator));
3830
+
3816
3831
  var ValidMultipleValidator = /** @class */ (function (_super) {
3817
3832
  __extends(ValidMultipleValidator, _super);
3818
3833
  function ValidMultipleValidator(validMultipleCallback, validators, value, target, event, autoValid) {
@@ -3828,6 +3843,18 @@ var ValidMultipleValidator = /** @class */ (function (_super) {
3828
3843
  return ValidMultipleValidator;
3829
3844
  }(MultipleValidator));
3830
3845
 
3846
+ var PassValidator = /** @class */ (function (_super) {
3847
+ __extends(PassValidator, _super);
3848
+ function PassValidator(value, target, event, autoValid) {
3849
+ if (autoValid === void 0) { autoValid = true; }
3850
+ return _super.call(this, value, target, event, autoValid) || this;
3851
+ }
3852
+ PassValidator.prototype.valid = function () {
3853
+ return true;
3854
+ };
3855
+ return PassValidator;
3856
+ }(Validator));
3857
+
3831
3858
  var RequiredValidator = /** @class */ (function (_super) {
3832
3859
  __extends(RequiredValidator, _super);
3833
3860
  function RequiredValidator(value, target, event, autoValid) {
@@ -3842,19 +3869,6 @@ var RequiredValidator = /** @class */ (function (_super) {
3842
3869
  return RequiredValidator;
3843
3870
  }(Validator));
3844
3871
 
3845
- var UnCheckedValidator = /** @class */ (function (_super) {
3846
- __extends(UnCheckedValidator, _super);
3847
- function UnCheckedValidator(value, target, event, autoValid) {
3848
- if (autoValid === void 0) { autoValid = true; }
3849
- return _super.call(this, value, target, event, autoValid) || this;
3850
- }
3851
- UnCheckedValidator.prototype.valid = function () {
3852
- var _a, _b;
3853
- return !((_b = (_a = this.getTarget()) === null || _a === void 0 ? void 0 : _a.checked) !== null && _b !== void 0 ? _b : false);
3854
- };
3855
- return UnCheckedValidator;
3856
- }(Validator));
3857
-
3858
3872
  var ValidValidatorArray = /** @class */ (function (_super) {
3859
3873
  __extends(ValidValidatorArray, _super);
3860
3874
  function ValidValidatorArray(validCallBack, value, target, event, autoValid) {
@@ -3869,16 +3883,18 @@ var ValidValidatorArray = /** @class */ (function (_super) {
3869
3883
  return ValidValidatorArray;
3870
3884
  }(ValidatorArray));
3871
3885
 
3872
- var PassValidator = /** @class */ (function (_super) {
3873
- __extends(PassValidator, _super);
3874
- function PassValidator(value, target, event, autoValid) {
3886
+ var ValidValidator = /** @class */ (function (_super) {
3887
+ __extends(ValidValidator, _super);
3888
+ function ValidValidator(validCallBack, value, target, event, autoValid) {
3875
3889
  if (autoValid === void 0) { autoValid = true; }
3876
- return _super.call(this, value, target, event, autoValid) || this;
3890
+ var _this = _super.call(this, value, target, event, autoValid) || this;
3891
+ _this.validCallBack = validCallBack;
3892
+ return _this;
3877
3893
  }
3878
- PassValidator.prototype.valid = function () {
3879
- return true;
3894
+ ValidValidator.prototype.valid = function (value, target, event) {
3895
+ return this.validCallBack(value, target, event);
3880
3896
  };
3881
- return PassValidator;
3897
+ return ValidValidator;
3882
3898
  }(Validator));
3883
3899
 
3884
3900
  var ValueEqualsValidator = /** @class */ (function (_super) {
@@ -3909,20 +3925,6 @@ var ValueNotEqualsValidator = /** @class */ (function (_super) {
3909
3925
  return ValueNotEqualsValidator;
3910
3926
  }(Validator));
3911
3927
 
3912
- var ValidValidator = /** @class */ (function (_super) {
3913
- __extends(ValidValidator, _super);
3914
- function ValidValidator(validCallBack, value, target, event, autoValid) {
3915
- if (autoValid === void 0) { autoValid = true; }
3916
- var _this = _super.call(this, value, target, event, autoValid) || this;
3917
- _this.validCallBack = validCallBack;
3918
- return _this;
3919
- }
3920
- ValidValidator.prototype.valid = function (value, target, event) {
3921
- return this.validCallBack(value, target, event);
3922
- };
3923
- return ValidValidator;
3924
- }(Validator));
3925
-
3926
3928
  var NodeUtils = /** @class */ (function () {
3927
3929
  function NodeUtils() {
3928
3930
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dom-render",
3
- "version": "1.0.78",
3
+ "version": "1.0.79",
4
4
  "main": "DomRender.js",
5
5
  "license": "MIT",
6
6
  "description": "dom-render",