@kato-lee/utilities 1.0.1 → 2.0.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 (43) hide show
  1. package/fesm2022/kato-lee-utilities-models.mjs +69 -0
  2. package/fesm2022/kato-lee-utilities-models.mjs.map +1 -0
  3. package/fesm2022/kato-lee-utilities-pipes.mjs +149 -0
  4. package/fesm2022/kato-lee-utilities-pipes.mjs.map +1 -0
  5. package/fesm2022/kato-lee-utilities-services.mjs +276 -0
  6. package/fesm2022/kato-lee-utilities-services.mjs.map +1 -0
  7. package/fesm2022/kato-lee-utilities-types.mjs +65 -0
  8. package/fesm2022/kato-lee-utilities-types.mjs.map +1 -0
  9. package/fesm2022/kato-lee-utilities-validators.mjs +20 -0
  10. package/fesm2022/kato-lee-utilities-validators.mjs.map +1 -0
  11. package/fesm2022/kato-lee-utilities.mjs +1 -18
  12. package/fesm2022/kato-lee-utilities.mjs.map +1 -1
  13. package/index.d.ts +94 -5
  14. package/js/_clone-deep.js +826 -826
  15. package/js/_order-by.js +1287 -1287
  16. package/js/index.js +2 -2
  17. package/models/index.d.ts +32 -0
  18. package/models/package.json +3 -0
  19. package/package.json +25 -3
  20. package/pipes/index.d.ts +51 -0
  21. package/pipes/package.json +3 -0
  22. package/services/index.d.ts +56 -0
  23. package/services/package.json +3 -0
  24. package/types/index.d.ts +36 -0
  25. package/types/package.json +3 -0
  26. package/validators/index.d.ts +16 -0
  27. package/validators/package.json +3 -0
  28. package/_either.d.ts +0 -12
  29. package/_group-by-key.d.ts +0 -6
  30. package/_lodash.d.ts +0 -71
  31. package/_path.d.ts +0 -1
  32. package/_types.d.ts +0 -14
  33. package/esm2022/_either.mjs +0 -49
  34. package/esm2022/_group-by-key.mjs +0 -19
  35. package/esm2022/_lodash.mjs +0 -91
  36. package/esm2022/_path.mjs +0 -17
  37. package/esm2022/_types.mjs +0 -17
  38. package/esm2022/index.mjs +0 -9
  39. package/esm2022/js/_clone-deep.mjs +0 -619
  40. package/esm2022/js/_order-by.mjs +0 -948
  41. package/esm2022/kato-lee-utilities.mjs +0 -5
  42. package/js/_clone-deep.d.ts +0 -2
  43. package/js/_order-by.d.ts +0 -2
@@ -0,0 +1,20 @@
1
+ import { Validators } from '@angular/forms';
2
+
3
+ const PATTERN_EMAIL = '^[^@]+@[^@]+.[a-zA-Z]{2,}$';
4
+ const PATTERN_NUMERIC = /^[0-9.]+$/;
5
+ const PATTERN_OUT_SPACES = /^[^\s]+$/;
6
+ const required = Validators.required;
7
+ const max = (max) => Validators.max(max);
8
+ const min = (min) => Validators.min(min);
9
+ const maxLength = (maxLength) => Validators.maxLength(maxLength);
10
+ const minLength = (minLength) => Validators.minLength(minLength);
11
+ const withOutSpaces = Validators.pattern(PATTERN_OUT_SPACES);
12
+ const onlyNumber = Validators.pattern(PATTERN_NUMERIC);
13
+ const email = Validators.pattern(PATTERN_EMAIL);
14
+
15
+ /**
16
+ * Generated bundle index. Do not edit.
17
+ */
18
+
19
+ export { PATTERN_EMAIL, PATTERN_NUMERIC, PATTERN_OUT_SPACES, email, max, maxLength, min, minLength, onlyNumber, required, withOutSpaces };
20
+ //# sourceMappingURL=kato-lee-utilities-validators.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"kato-lee-utilities-validators.mjs","sources":["../../../libraries/utilities/validators/index.ts","../../../libraries/utilities/validators/kato-lee-utilities-validators.ts"],"sourcesContent":["import { Validators } from '@angular/forms';\r\n\r\nexport const PATTERN_EMAIL = '^[^@]+@[^@]+.[a-zA-Z]{2,}$';\r\nexport const PATTERN_NUMERIC = /^[0-9.]+$/;\r\nexport const PATTERN_OUT_SPACES = /^[^\\s]+$/;\r\n\r\nexport const required = Validators.required;\r\n\r\nexport const max = (max: number) => Validators.max(max);\r\nexport const min = (min: number) => Validators.min(min);\r\n\r\nexport const maxLength = (maxLength: number) => Validators.maxLength(maxLength);\r\nexport const minLength = (minLength: number) => Validators.minLength(minLength);\r\n\r\nexport const withOutSpaces = Validators.pattern(PATTERN_OUT_SPACES);\r\nexport const onlyNumber = Validators.pattern(PATTERN_NUMERIC);\r\nexport const email = Validators.pattern(PATTERN_EMAIL);\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAEO,MAAM,aAAa,GAAG;AACtB,MAAM,eAAe,GAAG;AACxB,MAAM,kBAAkB,GAAG;AAE3B,MAAM,QAAQ,GAAG,UAAU,CAAC;AAE5B,MAAM,GAAG,GAAG,CAAC,GAAW,KAAK,UAAU,CAAC,GAAG,CAAC,GAAG;AAC/C,MAAM,GAAG,GAAG,CAAC,GAAW,KAAK,UAAU,CAAC,GAAG,CAAC,GAAG;AAE/C,MAAM,SAAS,GAAG,CAAC,SAAiB,KAAK,UAAU,CAAC,SAAS,CAAC,SAAS;AACvE,MAAM,SAAS,GAAG,CAAC,SAAiB,KAAK,UAAU,CAAC,SAAS,CAAC,SAAS;AAEvE,MAAM,aAAa,GAAG,UAAU,CAAC,OAAO,CAAC,kBAAkB;AAC3D,MAAM,UAAU,GAAG,UAAU,CAAC,OAAO,CAAC,eAAe;AACrD,MAAM,KAAK,GAAG,UAAU,CAAC,OAAO,CAAC,aAAa;;AChBrD;;AAEG;;;;"}
@@ -1737,23 +1737,6 @@ const extname = (path) => {
1737
1737
  return win32SplitPath(path)[3];
1738
1738
  };
1739
1739
 
1740
- class CtmType {
1741
- constructor(code, forHumans, abbreviation) {
1742
- this.code = code;
1743
- this.forHumans = forHumans;
1744
- this.abbreviation = abbreviation;
1745
- }
1746
- getCode() {
1747
- return this.code;
1748
- }
1749
- getForHumans() {
1750
- return this.forHumans;
1751
- }
1752
- getAbbreviation() {
1753
- return this.abbreviation;
1754
- }
1755
- }
1756
-
1757
1740
  /*
1758
1741
  * Public API Surface of @kato-lee/utilities
1759
1742
  */
@@ -1762,5 +1745,5 @@ class CtmType {
1762
1745
  * Generated bundle index. Do not edit.
1763
1746
  */
1764
1747
 
1765
- export { CtmType, Either, clone, cloneDeep, extname, groupByKey, orderBy, uniq };
1748
+ export { Either, clone, cloneDeep, extname, groupByKey, orderBy, uniq };
1766
1749
  //# sourceMappingURL=kato-lee-utilities.mjs.map