dom-render 1.0.96 → 1.0.97

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. package/DomRender.d.ts +1 -1
  2. package/DomRender.js +3 -3
  3. package/DomRenderProxy.js +12 -14
  4. package/README.MD +41 -0
  5. package/components/ComponentSet.d.ts +1 -1
  6. package/configs/Config.d.ts +1 -1
  7. package/configs/TargetAttr.d.ts +1 -1
  8. package/configs/TargetElement.d.ts +1 -1
  9. package/css/parse/index.d.ts +1 -0
  10. package/css/parse/index.js +512 -0
  11. package/css/stringify/compiler.d.ts +32 -0
  12. package/css/stringify/compiler.js +40 -0
  13. package/css/stringify/compress.d.ts +75 -0
  14. package/css/stringify/compress.js +156 -0
  15. package/css/stringify/identity.d.ts +85 -0
  16. package/css/stringify/identity.js +194 -0
  17. package/css/stringify/index.d.ts +14 -0
  18. package/css/stringify/index.js +44 -0
  19. package/dist/bundle.js +1075 -328
  20. package/events/EventManager.js +27 -27
  21. package/iterators/Range.d.ts +1 -0
  22. package/iterators/Range.js +15 -0
  23. package/messenger/Messenger.d.ts +4 -4
  24. package/operators/Dr.js +2 -2
  25. package/operators/DrAppender.js +5 -3
  26. package/operators/DrFor.js +5 -3
  27. package/operators/DrForOf.js +5 -3
  28. package/operators/DrForm.js +12 -12
  29. package/operators/DrIf.js +5 -3
  30. package/operators/DrInnerHTML.js +2 -2
  31. package/operators/DrInnerText.js +2 -2
  32. package/operators/DrPre.js +4 -2
  33. package/operators/DrRepeat.js +5 -3
  34. package/operators/DrTargetAttr.js +4 -2
  35. package/operators/DrTargetElement.js +5 -3
  36. package/operators/DrThis.js +2 -2
  37. package/operators/DrThisProperty.js +6 -4
  38. package/operators/OperatorExecuter.d.ts +5 -5
  39. package/operators/OperatorExecuter.js +2 -2
  40. package/operators/OperatorExecuterAttrRequire.js +1 -1
  41. package/package.json +3 -3
  42. package/rawsets/AttrInitCallBack.d.ts +1 -1
  43. package/rawsets/Attrs.d.ts +1 -1
  44. package/rawsets/CreatorMetaData.d.ts +1 -1
  45. package/rawsets/ElementInitCallBack.d.ts +1 -1
  46. package/rawsets/RawSet.d.ts +6 -2
  47. package/rawsets/RawSet.js +93 -54
  48. package/rawsets/Render.d.ts +1 -1
  49. package/routers/Router.d.ts +1 -1
  50. package/routers/Router.js +1 -1
  51. package/utils/dom/DomUtils.d.ts +1 -1
  52. package/utils/node/NodeUtils.d.ts +1 -1
  53. package/utils/script/ScriptUtils.js +2 -2
  54. package/utils/storage/StorageUtils.d.ts +7 -0
  55. package/utils/storage/StorageUtils.js +39 -0
  56. package/utils/string/StringUtils.d.ts +1 -0
  57. package/utils/string/StringUtils.js +17 -0
  58. package/validators/EmptyValidator.js +2 -2
  59. package/validators/NotEmptyValidator.js +2 -2
  60. package/validators/ValidMultipleValidator.d.ts +1 -1
  61. package/validators/Validator.d.ts +2 -2
  62. package/validators/ValidatorArray.d.ts +1 -1
@@ -24,9 +24,9 @@ var EmptyValidator = /** @class */ (function (_super) {
24
24
  return _super.call(this, value, target, event, autoValid) || this;
25
25
  }
26
26
  EmptyValidator.prototype.valid = function () {
27
- var _a;
27
+ var _a, _b;
28
28
  var value = this.value;
29
- return value === undefined || value === null || ((_a = value === null || value === void 0 ? void 0 : value.length) !== null && _a !== void 0 ? _a : 0) <= 0;
29
+ return value === undefined || value === null || ((_b = (_a = value) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0) <= 0;
30
30
  };
31
31
  return EmptyValidator;
32
32
  }(Validator_1.Validator));
@@ -24,10 +24,10 @@ var NotEmptyValidator = /** @class */ (function (_super) {
24
24
  return _super.call(this, value, target, event, autoValid) || this;
25
25
  }
26
26
  NotEmptyValidator.prototype.valid = function () {
27
- var _a;
27
+ var _a, _b;
28
28
  var value = this.value;
29
29
  // console.log('NotEmptyValidator', value, value !== undefined && value !== null && ((value as any)?.length ?? 0) > 0)
30
- return value !== undefined && value !== null && ((_a = value === null || value === void 0 ? void 0 : value.length) !== null && _a !== void 0 ? _a : 0) > 0;
30
+ return value !== undefined && value !== null && ((_b = (_a = value) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0) > 0;
31
31
  };
32
32
  return NotEmptyValidator;
33
33
  }(Validator_1.Validator));
@@ -1,6 +1,6 @@
1
1
  import { Validator } from './Validator';
2
2
  import { MultipleValidator } from './MultipleValidator';
3
- export type ValidMulltiple<T = any, E = Element> = (validators: Validator<T, E>[], value?: T, target?: E, event?: Event) => boolean;
3
+ export declare type ValidMulltiple<T = any, E = Element> = (validators: Validator<T, E>[], value?: T, target?: E, event?: Event) => boolean;
4
4
  export declare class ValidMultipleValidator<T = any, E = Element> extends MultipleValidator<T, E> {
5
5
  validMultipleCallback: ValidMulltiple<T, E>;
6
6
  validators: Validator<T, E>[];
@@ -1,5 +1,5 @@
1
- export type Valid<T = any, E = Element> = (value?: T, target?: E, event?: Event) => boolean;
2
- export type ValidAction<T = any, E = Element> = (valid: boolean, value?: T, target?: E, event?: Event) => void;
1
+ export declare type Valid<T = any, E = Element> = (value?: T, target?: E, event?: Event) => boolean;
2
+ export declare type ValidAction<T = any, E = Element> = (valid: boolean, value?: T, target?: E, event?: Event) => void;
3
3
  export declare abstract class Validator<T = any, E = Element> {
4
4
  protected _value?: T | undefined;
5
5
  private _target?;
@@ -1,5 +1,5 @@
1
1
  import { Validator } from './Validator';
2
- export type MakeValidator<T = any, E = Element> = (value: T, target: E, event?: Event) => Validator<T, E>;
2
+ export declare type MakeValidator<T = any, E = Element> = (value: T, target: E, event?: Event) => Validator<T, E>;
3
3
  export declare abstract class ValidatorArray<T = any, E = Element> extends Validator<Validator<T, E>[], E> {
4
4
  private _makeValidatorFactory;
5
5
  constructor(value?: Validator<T, E>[], target?: E, event?: Event, autoValid?: boolean);