@rzl-zone/utils-js 3.5.3 → 3.5.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (114) hide show
  1. package/dist/assertions/index.cjs +11 -11
  2. package/dist/assertions/index.d.ts +1 -1
  3. package/dist/assertions/index.js +5 -5
  4. package/dist/{chunk-RZW35UN5.cjs → chunk-2CQI36UD.cjs} +6 -6
  5. package/dist/{chunk-CDCERIZ2.js → chunk-2RZGZEE2.js} +3 -3
  6. package/dist/{chunk-PET42Z7W.js → chunk-2VO2CBTU.js} +2 -2
  7. package/dist/{chunk-CMW2TBOQ.js → chunk-3KTD3QDI.js} +2 -7
  8. package/dist/{chunk-XEDXFSGI.js → chunk-4ACKNPL5.js} +2 -2
  9. package/dist/{chunk-SIM77PU4.js → chunk-4ZOXSUXB.js} +3 -3
  10. package/dist/{chunk-IVL7CKVH.cjs → chunk-5NN4ZDE2.cjs} +6 -6
  11. package/dist/{chunk-FJZGG54N.cjs → chunk-66WLOZOD.cjs} +50 -50
  12. package/dist/{chunk-SBFNXGTJ.js → chunk-6DSPJA5U.js} +9 -9
  13. package/dist/{chunk-D3ENH7H6.cjs → chunk-6RFNZ2ZZ.cjs} +14 -14
  14. package/dist/{chunk-CKTLUNWX.js → chunk-6WMB5AJR.js} +2 -2
  15. package/dist/{chunk-JBQMXC5I.cjs → chunk-7QQV66RX.cjs} +10 -10
  16. package/dist/{chunk-6JFZL7YE.cjs → chunk-7WBMA2VE.cjs} +4 -4
  17. package/dist/{chunk-3IBQ5MOM.js → chunk-7ZNEUWYP.js} +2 -2
  18. package/dist/{chunk-JEQEF5WD.js → chunk-A3YI6Y2P.js} +3 -3
  19. package/dist/{chunk-DEZZUYE2.js → chunk-ABA2ZSBQ.js} +3 -3
  20. package/dist/{chunk-NRF6LWBC.cjs → chunk-AKKM6MOX.cjs} +15 -15
  21. package/dist/{chunk-ZETAZZLD.cjs → chunk-ATLFMKAF.cjs} +7 -7
  22. package/dist/{chunk-V45XJKHW.cjs → chunk-B4SDEBN7.cjs} +3 -3
  23. package/dist/{chunk-2IOOEY45.cjs → chunk-B6UIKBHR.cjs} +4 -4
  24. package/dist/chunk-BAV5T2E3.cjs +1 -1
  25. package/dist/{chunk-E74U6CYP.cjs → chunk-BYUT376O.cjs} +3 -3
  26. package/dist/{chunk-OYTYSY7G.js → chunk-D53CE4BT.js} +7 -7
  27. package/dist/{chunk-IRFL4MAX.js → chunk-DPLL67OT.js} +2 -2
  28. package/dist/chunk-DVMHRLKP.cjs +1 -1
  29. package/dist/{chunk-5KJFVIQT.cjs → chunk-EK7FSI7F.cjs} +3 -3
  30. package/dist/{chunk-PZQ6I4JJ.cjs → chunk-F3WBQKRI.cjs} +1 -8
  31. package/dist/{chunk-SBKGWRS5.js → chunk-FI76UZRF.js} +2 -2
  32. package/dist/{chunk-IZPBKKPO.js → chunk-GAJBF6DR.js} +2 -2
  33. package/dist/{chunk-DWF2R5GD.cjs → chunk-H5NWBTHW.cjs} +61 -61
  34. package/dist/{chunk-W2WNBUDE.js → chunk-JY4HLZ4W.js} +2 -2
  35. package/dist/{chunk-5757UBXJ.cjs → chunk-K3SONK25.cjs} +24 -24
  36. package/dist/{chunk-HYRQMTRH.cjs → chunk-K63WO3XA.cjs} +4 -4
  37. package/dist/chunk-KHO2SBNA.cjs +1 -1
  38. package/dist/{chunk-RIPKY4RU.js → chunk-KPCDDYTZ.js} +2 -2
  39. package/dist/{chunk-F6IPNNSJ.cjs → chunk-KTQLDIIT.cjs} +161 -161
  40. package/dist/chunk-L5RDAVVH.js +1 -1
  41. package/dist/{chunk-GGEADHZO.js → chunk-LBNOZIZ6.js} +5 -5
  42. package/dist/{chunk-3VA554KW.js → chunk-LEX4TQW2.js} +2 -2
  43. package/dist/{chunk-KVAL5PAG.cjs → chunk-LIU4S3JA.cjs} +4 -4
  44. package/dist/{chunk-2WA36TC5.cjs → chunk-ME7Q2M5I.cjs} +22 -22
  45. package/dist/{chunk-E55EQK2U.cjs → chunk-NREACG6M.cjs} +3 -3
  46. package/dist/{chunk-T2T7K3KR.js → chunk-OFBFGFVH.js} +2 -2
  47. package/dist/chunk-ONZFBJVW.js +1 -1
  48. package/dist/{chunk-XABCB3Y7.cjs → chunk-OS5OT5JA.cjs} +126 -126
  49. package/dist/{chunk-GQR4R5WY.js → chunk-PZQC3FZY.js} +4 -4
  50. package/dist/{chunk-FWHNWL2P.cjs → chunk-QAPYHLHC.cjs} +3 -3
  51. package/dist/chunk-QNKGP5DY.js +1 -1
  52. package/dist/{chunk-YKPSRP5G.js → chunk-QUITZ3GP.js} +8 -8
  53. package/dist/{chunk-7ODAAXX5.cjs → chunk-RIEYB2AW.cjs} +71 -71
  54. package/dist/{chunk-LS6U7FAY.cjs → chunk-RMJC3B5P.cjs} +26 -26
  55. package/dist/{chunk-JMJQCN74.js → chunk-SN6YRDLG.js} +9 -9
  56. package/dist/{chunk-NBZWMBO6.js → chunk-SZJ7OI4S.js} +3 -3
  57. package/dist/{chunk-FWCKOJZM.js → chunk-TDPYR5JY.js} +10 -10
  58. package/dist/{chunk-OI5XKNZO.js → chunk-TDYGYHSH.js} +4 -4
  59. package/dist/{chunk-CAH33WOQ.cjs → chunk-TFDXRT6D.cjs} +3 -3
  60. package/dist/chunk-UDA26MCU.cjs +1 -1
  61. package/dist/{chunk-HQWOFR56.cjs → chunk-UKAUXY2U.cjs} +12 -12
  62. package/dist/{chunk-H66AC7GK.cjs → chunk-URDI3IMY.cjs} +19 -19
  63. package/dist/{chunk-6JFCSH7J.js → chunk-VCVND6CH.js} +2 -2
  64. package/dist/chunk-VJDDGRIK.cjs +1 -1
  65. package/dist/{chunk-QBKAEVYG.js → chunk-VNADVWSJ.js} +3 -3
  66. package/dist/chunk-WVSPXFTY.js +1 -1
  67. package/dist/{chunk-2CQX5CBG.js → chunk-XFTUHS4Y.js} +4 -4
  68. package/dist/{chunk-T7PU2V7X.cjs → chunk-YC7AK3KX.cjs} +31 -31
  69. package/dist/{chunk-EL6A35UR.cjs → chunk-YGB2BQPB.cjs} +8 -8
  70. package/dist/chunk-YWHHVDT4.js +1 -1
  71. package/dist/{chunk-5IGC6PBH.js → chunk-ZN53RM3R.js} +2 -2
  72. package/dist/conversions/index.cjs +34 -34
  73. package/dist/conversions/index.d.ts +1 -1
  74. package/dist/conversions/index.js +15 -15
  75. package/dist/events/index.cjs +8 -8
  76. package/dist/events/index.d.ts +1 -1
  77. package/dist/events/index.js +4 -4
  78. package/dist/formatters/index.cjs +19 -19
  79. package/dist/formatters/index.d.ts +1 -1
  80. package/dist/formatters/index.js +9 -9
  81. package/dist/generators/index.cjs +8 -8
  82. package/dist/generators/index.d.ts +1 -1
  83. package/dist/generators/index.js +4 -4
  84. package/dist/index.d.ts +1 -14
  85. package/dist/isPlainObject-FWmcJF6k.d.ts +1 -1
  86. package/dist/next/index.cjs +35 -35
  87. package/dist/next/index.d.ts +1 -1
  88. package/dist/next/index.js +7 -7
  89. package/dist/next/server/index.cjs +4 -4
  90. package/dist/next/server/index.d.ts +1 -1
  91. package/dist/next/server/index.js +2 -2
  92. package/dist/operations/index.cjs +11 -11
  93. package/dist/operations/index.d.ts +1 -1
  94. package/dist/operations/index.js +8 -8
  95. package/dist/parsers/index.cjs +4 -4
  96. package/dist/parsers/index.d.ts +1 -1
  97. package/dist/parsers/index.js +3 -3
  98. package/dist/predicates/index.cjs +74 -82
  99. package/dist/predicates/index.d.ts +2 -23
  100. package/dist/predicates/index.js +12 -12
  101. package/dist/promises/index.cjs +6 -6
  102. package/dist/promises/index.d.ts +1 -1
  103. package/dist/promises/index.js +4 -4
  104. package/dist/rzl-utils.global.js +2 -17
  105. package/dist/strings/index.cjs +23 -23
  106. package/dist/strings/index.d.ts +1 -1
  107. package/dist/strings/index.js +7 -7
  108. package/dist/tailwind/index.cjs +11 -11
  109. package/dist/tailwind/index.d.ts +1 -1
  110. package/dist/tailwind/index.js +4 -4
  111. package/dist/urls/index.cjs +19 -19
  112. package/dist/urls/index.d.ts +1 -1
  113. package/dist/urls/index.js +13 -13
  114. package/package.json +1 -1
@@ -2,21 +2,21 @@
2
2
  * ====================================================
3
3
  * Rzl Utils-JS.
4
4
  * ----------------------------------------------------
5
- * Version: 3.5.3.
5
+ * Version: 3.5.4.
6
6
  * Author: Rizalvin Dwiky.
7
7
  * Repository: https://github.com/rzl-zone/utils-js.
8
8
  * ====================================================
9
9
  */
10
10
  'use strict';
11
11
 
12
- var chunk2IOOEY45_cjs = require('./chunk-2IOOEY45.cjs');
13
- var chunk5KJFVIQT_cjs = require('./chunk-5KJFVIQT.cjs');
14
- var chunkV45XJKHW_cjs = require('./chunk-V45XJKHW.cjs');
12
+ var chunkB6UIKBHR_cjs = require('./chunk-B6UIKBHR.cjs');
13
+ var chunkEK7FSI7F_cjs = require('./chunk-EK7FSI7F.cjs');
14
+ var chunkB4SDEBN7_cjs = require('./chunk-B4SDEBN7.cjs');
15
15
  var chunkDVMHRLKP_cjs = require('./chunk-DVMHRLKP.cjs');
16
- var chunkE55EQK2U_cjs = require('./chunk-E55EQK2U.cjs');
17
- var chunkHYRQMTRH_cjs = require('./chunk-HYRQMTRH.cjs');
18
- var chunkT7PU2V7X_cjs = require('./chunk-T7PU2V7X.cjs');
19
- var chunkPZQ6I4JJ_cjs = require('./chunk-PZQ6I4JJ.cjs');
16
+ var chunkNREACG6M_cjs = require('./chunk-NREACG6M.cjs');
17
+ var chunkK63WO3XA_cjs = require('./chunk-K63WO3XA.cjs');
18
+ var chunkYC7AK3KX_cjs = require('./chunk-YC7AK3KX.cjs');
19
+ var chunkF3WBQKRI_cjs = require('./chunk-F3WBQKRI.cjs');
20
20
  var max = require('libphonenumber-js/max');
21
21
  var locale = require('date-fns/locale');
22
22
  var dateFns = require('date-fns');
@@ -28,69 +28,69 @@ var formatIndianNumber = (numStr, separator) => {
28
28
  return rest.replace(/\B(?=(\d{2})+(?!\d))/g, separator) + separator + lastThree;
29
29
  };
30
30
  var formatCurrency = (value, options = {}) => {
31
- if (!chunkPZQ6I4JJ_cjs.isString(value) && !chunkV45XJKHW_cjs.isFinite(value)) {
31
+ if (!chunkF3WBQKRI_cjs.isString(value) && !chunkB4SDEBN7_cjs.isFinite(value)) {
32
32
  throw new TypeError(
33
- `First parameter (\`value\`) must be of type \`string\` or \`primitive-number\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
33
+ `First parameter (\`value\`) must be of type \`string\` or \`primitive-number\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
34
34
  value
35
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(value)}\`.`
35
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(value)}\`.`
36
36
  );
37
37
  }
38
- chunkPZQ6I4JJ_cjs.assertIsPlainObject(options, {
38
+ chunkF3WBQKRI_cjs.assertIsPlainObject(options, {
39
39
  message: ({ currentType, validType }) => `Second parameter (\`options\`) must be of type \`${validType}\`, but received: \`${currentType}\`.`
40
40
  });
41
- const decimal = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "decimal") ? options.decimal : false;
42
- const totalDecimal = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "totalDecimal") ? options.totalDecimal : 2;
43
- const endDecimal = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "endDecimal") ? options.endDecimal : true;
44
- const indianFormat = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "indianFormat") ? options.indianFormat : false;
45
- const suffixCurrency = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "suffixCurrency") ? options.suffixCurrency : "";
46
- const suffixDecimal = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "suffixDecimal") ? options.suffixDecimal : "";
47
- const roundedDecimal = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "roundedDecimal") ? options.roundedDecimal : "round";
48
- const negativeFormat = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "negativeFormat") ? options.negativeFormat : "dash";
49
- let separatorDecimals = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "separatorDecimals") ? options.separatorDecimals : ",";
50
- let separator = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "separator") ? options.separator : ".";
51
- if (!chunkPZQ6I4JJ_cjs.isString(separator) || !chunkPZQ6I4JJ_cjs.isString(separatorDecimals) || !chunkPZQ6I4JJ_cjs.isString(suffixCurrency) || !chunkPZQ6I4JJ_cjs.isString(suffixDecimal)) {
41
+ const decimal = chunkF3WBQKRI_cjs.hasOwnProp(options, "decimal") ? options.decimal : false;
42
+ const totalDecimal = chunkF3WBQKRI_cjs.hasOwnProp(options, "totalDecimal") ? options.totalDecimal : 2;
43
+ const endDecimal = chunkF3WBQKRI_cjs.hasOwnProp(options, "endDecimal") ? options.endDecimal : true;
44
+ const indianFormat = chunkF3WBQKRI_cjs.hasOwnProp(options, "indianFormat") ? options.indianFormat : false;
45
+ const suffixCurrency = chunkF3WBQKRI_cjs.hasOwnProp(options, "suffixCurrency") ? options.suffixCurrency : "";
46
+ const suffixDecimal = chunkF3WBQKRI_cjs.hasOwnProp(options, "suffixDecimal") ? options.suffixDecimal : "";
47
+ const roundedDecimal = chunkF3WBQKRI_cjs.hasOwnProp(options, "roundedDecimal") ? options.roundedDecimal : "round";
48
+ const negativeFormat = chunkF3WBQKRI_cjs.hasOwnProp(options, "negativeFormat") ? options.negativeFormat : "dash";
49
+ let separatorDecimals = chunkF3WBQKRI_cjs.hasOwnProp(options, "separatorDecimals") ? options.separatorDecimals : ",";
50
+ let separator = chunkF3WBQKRI_cjs.hasOwnProp(options, "separator") ? options.separator : ".";
51
+ if (!chunkF3WBQKRI_cjs.isString(separator) || !chunkF3WBQKRI_cjs.isString(separatorDecimals) || !chunkF3WBQKRI_cjs.isString(suffixCurrency) || !chunkF3WBQKRI_cjs.isString(suffixDecimal)) {
52
52
  throw new TypeError(
53
- `Parameter \`separator\`, \`separatorDecimals\`, \`suffixCurrency\` and \`suffixDecimal\` property of the \`options\` (second parameter) must be of type \`string\`, but received: ['separator': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
53
+ `Parameter \`separator\`, \`separatorDecimals\`, \`suffixCurrency\` and \`suffixDecimal\` property of the \`options\` (second parameter) must be of type \`string\`, but received: ['separator': \`${chunkF3WBQKRI_cjs.getPreciseType(
54
54
  separator
55
- )}\`, 'separatorDecimals': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
55
+ )}\`, 'separatorDecimals': \`${chunkF3WBQKRI_cjs.getPreciseType(
56
56
  separatorDecimals
57
- )}\`, 'suffixCurrency': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
57
+ )}\`, 'suffixCurrency': \`${chunkF3WBQKRI_cjs.getPreciseType(
58
58
  suffixCurrency
59
- )}\`, 'suffixDecimal': \`${chunkPZQ6I4JJ_cjs.getPreciseType(suffixDecimal)}\`].`
59
+ )}\`, 'suffixDecimal': \`${chunkF3WBQKRI_cjs.getPreciseType(suffixDecimal)}\`].`
60
60
  );
61
61
  }
62
- if (!chunkPZQ6I4JJ_cjs.isBoolean(decimal) || !chunkPZQ6I4JJ_cjs.isBoolean(endDecimal) || !chunkPZQ6I4JJ_cjs.isBoolean(indianFormat)) {
62
+ if (!chunkF3WBQKRI_cjs.isBoolean(decimal) || !chunkF3WBQKRI_cjs.isBoolean(endDecimal) || !chunkF3WBQKRI_cjs.isBoolean(indianFormat)) {
63
63
  throw new TypeError(
64
- `Parameter \`decimal\`, \`endDecimal\` and \`indianFormat\` property of the \`options\` (second parameter) must be of type \`boolean\`, but received: ['decimal': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
64
+ `Parameter \`decimal\`, \`endDecimal\` and \`indianFormat\` property of the \`options\` (second parameter) must be of type \`boolean\`, but received: ['decimal': \`${chunkF3WBQKRI_cjs.getPreciseType(
65
65
  decimal
66
- )}\`, 'endDecimal': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
66
+ )}\`, 'endDecimal': \`${chunkF3WBQKRI_cjs.getPreciseType(
67
67
  endDecimal
68
- )}\`, 'indianFormat': \`${chunkPZQ6I4JJ_cjs.getPreciseType(indianFormat)}\`].`
68
+ )}\`, 'indianFormat': \`${chunkF3WBQKRI_cjs.getPreciseType(indianFormat)}\`].`
69
69
  );
70
70
  }
71
71
  if (!chunkDVMHRLKP_cjs.isInteger(totalDecimal)) {
72
72
  throw new TypeError(
73
- `Parameter \`totalDecimal\` property of the \`options\` (second parameter) must be of type \`integer-number\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
73
+ `Parameter \`totalDecimal\` property of the \`options\` (second parameter) must be of type \`integer-number\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
74
74
  totalDecimal
75
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(length)}\`.`
75
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(length)}\`.`
76
76
  );
77
77
  }
78
78
  if (!(roundedDecimal === false || roundedDecimal === "round" || roundedDecimal === "ceil" || roundedDecimal === "floor")) {
79
79
  throw new TypeError(
80
- `Parameter \`roundedDecimal\` property of the \`options\` (second parameter) must be of type \`false\` or \`string\` must be one of "round" | "ceil" | "floor", but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
80
+ `Parameter \`roundedDecimal\` property of the \`options\` (second parameter) must be of type \`false\` or \`string\` must be one of "round" | "ceil" | "floor", but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
81
81
  roundedDecimal
82
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(roundedDecimal)}\`.`
82
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(roundedDecimal)}\`.`
83
83
  );
84
84
  }
85
- if (!(negativeFormat === "abs" || negativeFormat === "brackets" || negativeFormat === "dash" || chunkPZQ6I4JJ_cjs.isPlainObject(negativeFormat))) {
85
+ if (!(negativeFormat === "abs" || negativeFormat === "brackets" || negativeFormat === "dash" || chunkF3WBQKRI_cjs.isPlainObject(negativeFormat))) {
86
86
  throw new TypeError(
87
- `Parameter \`negativeFormat\` property of the \`options\` (second parameter) must be of type \`string\` must be one of "abs" | "brackets" | "dash" or \`plain-object\` type, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
87
+ `Parameter \`negativeFormat\` property of the \`options\` (second parameter) must be of type \`string\` must be one of "abs" | "brackets" | "dash" or \`plain-object\` type, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
88
88
  negativeFormat
89
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(negativeFormat)}\`.`
89
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(negativeFormat)}\`.`
90
90
  );
91
91
  }
92
- const rawNum = chunkPZQ6I4JJ_cjs.isString(value) ? chunk5KJFVIQT_cjs.parseCurrencyString(value) : value;
93
- if (chunkPZQ6I4JJ_cjs.isNaN(rawNum)) {
92
+ const rawNum = chunkF3WBQKRI_cjs.isString(value) ? chunkEK7FSI7F_cjs.parseCurrencyString(value) : value;
93
+ if (chunkF3WBQKRI_cjs.isNaN(rawNum)) {
94
94
  throw new TypeError(
95
95
  `First parameter (\`value\`) could not be parsed into a valid \`number\`.`
96
96
  );
@@ -129,7 +129,7 @@ var formatCurrency = (value, options = {}) => {
129
129
  } else {
130
130
  formattedInteger = (suffixCurrency.trim().length ? suffixCurrency : "") + integerPart.replace(/\B(?=(\d{3})+(?!\d))/g, separator);
131
131
  }
132
- if (decimal && !chunkPZQ6I4JJ_cjs.isUndefined(decimalPartRaw) && totalDecimal > 0) {
132
+ if (decimal && !chunkF3WBQKRI_cjs.isUndefined(decimalPartRaw) && totalDecimal > 0) {
133
133
  let formattedDecimal = separatorDecimals + decimalPartRaw;
134
134
  if (endDecimal) formattedDecimal += suffixDecimal;
135
135
  formattedInteger += formattedDecimal;
@@ -139,32 +139,32 @@ var formatCurrency = (value, options = {}) => {
139
139
  formattedInteger = "-" + formattedInteger;
140
140
  } else if (negativeFormat === "brackets") {
141
141
  formattedInteger = "(" + formattedInteger + ")";
142
- } else if (negativeFormat === "abs") ; else if (chunkPZQ6I4JJ_cjs.isPlainObject(negativeFormat)) {
143
- if (chunkPZQ6I4JJ_cjs.hasOwnProp(negativeFormat, "custom")) {
142
+ } else if (negativeFormat === "abs") ; else if (chunkF3WBQKRI_cjs.isPlainObject(negativeFormat)) {
143
+ if (chunkF3WBQKRI_cjs.hasOwnProp(negativeFormat, "custom")) {
144
144
  const formatCustomNegative = negativeFormat.custom;
145
- if (!chunkPZQ6I4JJ_cjs.isFunction(formatCustomNegative)) {
145
+ if (!chunkF3WBQKRI_cjs.isFunction(formatCustomNegative)) {
146
146
  throw new TypeError(
147
- `Parameter \`negativeFormat.custom\` property of the \`options\` (second parameter) must be of type function: \`(formatted: string) => string\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
147
+ `Parameter \`negativeFormat.custom\` property of the \`options\` (second parameter) must be of type function: \`(formatted: string) => string\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
148
148
  formatCustomNegative
149
149
  )}\`.`
150
150
  );
151
151
  }
152
152
  const result = formatCustomNegative(formattedInteger);
153
- chunkHYRQMTRH_cjs.assertIsString(result, {
153
+ chunkK63WO3XA_cjs.assertIsString(result, {
154
154
  message: ({ currentType, validType }) => `Parameter \`negativeFormat.custom\` property of the \`options\` (second parameter) expected return a \`${validType}\` type value, but received: \`${currentType}\`.`
155
155
  });
156
156
  formattedInteger = result;
157
157
  } else {
158
158
  const formatStyleNegative = negativeFormat.style || "dash";
159
- const formatSpaceNegative = !chunkPZQ6I4JJ_cjs.isUndefined(negativeFormat.space) ? negativeFormat.space : false;
160
- chunkPZQ6I4JJ_cjs.assertIsBoolean(formatSpaceNegative, {
159
+ const formatSpaceNegative = !chunkF3WBQKRI_cjs.isUndefined(negativeFormat.space) ? negativeFormat.space : false;
160
+ chunkF3WBQKRI_cjs.assertIsBoolean(formatSpaceNegative, {
161
161
  message: ({ currentType, validType }) => `Parameter \`negativeFormat.space\` property of the \`options\` (second parameter) must be of type \`${validType} or undefined\`, but received: \`${currentType}\`.`
162
162
  });
163
163
  if (!(formatStyleNegative === "abs" || formatStyleNegative === "brackets" || formatStyleNegative === "dash")) {
164
164
  throw new TypeError(
165
- `Parameter \`negativeFormat.style\` property of the \`options\` (second parameter) must be of type \`string\` must be of type "abs" | "brackets" | "dash", but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
165
+ `Parameter \`negativeFormat.style\` property of the \`options\` (second parameter) must be of type \`string\` must be of type "abs" | "brackets" | "dash", but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
166
166
  formatStyleNegative
167
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(formatStyleNegative)}\`.`
167
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(formatStyleNegative)}\`.`
168
168
  );
169
169
  }
170
170
  switch (formatStyleNegative) {
@@ -182,21 +182,21 @@ var formatCurrency = (value, options = {}) => {
182
182
  };
183
183
 
184
184
  var formatNumber = (value, separator = ",") => {
185
- if (!chunkPZQ6I4JJ_cjs.isString(value) && !chunkV45XJKHW_cjs.isFinite(value)) {
185
+ if (!chunkF3WBQKRI_cjs.isString(value) && !chunkB4SDEBN7_cjs.isFinite(value)) {
186
186
  throw new TypeError(
187
- `First parameter (\`value\`) must be of type \`string\` or \`primitive number\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
187
+ `First parameter (\`value\`) must be of type \`string\` or \`primitive number\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
188
188
  value
189
189
  )}\`.`
190
190
  );
191
191
  }
192
- if (!chunkPZQ6I4JJ_cjs.isString(separator)) {
192
+ if (!chunkF3WBQKRI_cjs.isString(separator)) {
193
193
  throw new TypeError(
194
- `Second parameter (\`separator\`) must be of type \`string\` or empty as \`undefined\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
194
+ `Second parameter (\`separator\`) must be of type \`string\` or empty as \`undefined\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
195
195
  separator
196
196
  )}\`.`
197
197
  );
198
198
  }
199
- separator = chunkPZQ6I4JJ_cjs.isString(separator) ? separator : ",";
199
+ separator = chunkF3WBQKRI_cjs.isString(separator) ? separator : ",";
200
200
  const decimalSeparator = separator === "." ? "," : separator === "," ? "." : ".";
201
201
  const stringValue = value.toString().trim();
202
202
  const lastDot = stringValue.lastIndexOf(".");
@@ -235,42 +235,42 @@ var isValidParseAsYouType = (parsedAsYouType) => {
235
235
  };
236
236
 
237
237
  function formatPhoneNumber(value, options = {}) {
238
- if (chunkPZQ6I4JJ_cjs.isNil(value)) return "";
239
- if (!chunkPZQ6I4JJ_cjs.isString(value) && !chunkPZQ6I4JJ_cjs.isNumber(value)) {
238
+ if (chunkF3WBQKRI_cjs.isNil(value)) return "";
239
+ if (!chunkF3WBQKRI_cjs.isString(value) && !chunkF3WBQKRI_cjs.isNumber(value)) {
240
240
  throw new TypeError(
241
- `First parameter (\`value\`) must be of type \`string\`, \`number\`, \`null\` or \`undefined\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
241
+ `First parameter (\`value\`) must be of type \`string\`, \`number\`, \`null\` or \`undefined\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
242
242
  value
243
243
  )}\`.`
244
244
  );
245
245
  }
246
- chunkPZQ6I4JJ_cjs.assertIsPlainObject(options, {
246
+ chunkF3WBQKRI_cjs.assertIsPlainObject(options, {
247
247
  message: ({ currentType, validType }) => `Second parameter (\`options\`) must be of type \`${validType}\`, but received: \`${currentType}\`.`
248
248
  });
249
- const takeNumberOnly = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "takeNumberOnly") ? options.takeNumberOnly : false;
250
- const checkValidOnly = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "checkValidOnly") ? options.checkValidOnly : false;
251
- const defaultCountry = chunkPZQ6I4JJ_cjs.hasOwnProp(
249
+ const takeNumberOnly = chunkF3WBQKRI_cjs.hasOwnProp(options, "takeNumberOnly") ? options.takeNumberOnly : false;
250
+ const checkValidOnly = chunkF3WBQKRI_cjs.hasOwnProp(options, "checkValidOnly") ? options.checkValidOnly : false;
251
+ const defaultCountry = chunkF3WBQKRI_cjs.hasOwnProp(
252
252
  options,
253
253
  "defaultCountry"
254
254
  ) ? options.defaultCountry : void 0;
255
- const separator = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "separator") ? options.separator : " ";
256
- const prependPlusCountryCode = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "prependPlusCountryCode") ? options.prependPlusCountryCode : true;
257
- const outputFormat = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "outputFormat") ? options.outputFormat : "INTERNATIONAL";
258
- const openingNumberCountry = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "openingNumberCountry") ? options.openingNumberCountry : "";
259
- const closingNumberCountry = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "closingNumberCountry") ? options.closingNumberCountry : "";
260
- if (!chunkPZQ6I4JJ_cjs.isBoolean(takeNumberOnly) || !chunkPZQ6I4JJ_cjs.isBoolean(checkValidOnly) || !chunkPZQ6I4JJ_cjs.isBoolean(prependPlusCountryCode)) {
255
+ const separator = chunkF3WBQKRI_cjs.hasOwnProp(options, "separator") ? options.separator : " ";
256
+ const prependPlusCountryCode = chunkF3WBQKRI_cjs.hasOwnProp(options, "prependPlusCountryCode") ? options.prependPlusCountryCode : true;
257
+ const outputFormat = chunkF3WBQKRI_cjs.hasOwnProp(options, "outputFormat") ? options.outputFormat : "INTERNATIONAL";
258
+ const openingNumberCountry = chunkF3WBQKRI_cjs.hasOwnProp(options, "openingNumberCountry") ? options.openingNumberCountry : "";
259
+ const closingNumberCountry = chunkF3WBQKRI_cjs.hasOwnProp(options, "closingNumberCountry") ? options.closingNumberCountry : "";
260
+ if (!chunkF3WBQKRI_cjs.isBoolean(takeNumberOnly) || !chunkF3WBQKRI_cjs.isBoolean(checkValidOnly) || !chunkF3WBQKRI_cjs.isBoolean(prependPlusCountryCode)) {
261
261
  throw new TypeError(
262
- `Parameter \`takeNumberOnly\`, \`checkValidOnly\` and \`prependPlusCountryCode\` property of the \`options\` (second parameter) must be of type \`boolean\` or unset as \`undefined\` value, but received: ['takeNumberOnly': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
262
+ `Parameter \`takeNumberOnly\`, \`checkValidOnly\` and \`prependPlusCountryCode\` property of the \`options\` (second parameter) must be of type \`boolean\` or unset as \`undefined\` value, but received: ['takeNumberOnly': \`${chunkF3WBQKRI_cjs.getPreciseType(
263
263
  takeNumberOnly
264
- )}\`, 'checkValidOnly': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
264
+ )}\`, 'checkValidOnly': \`${chunkF3WBQKRI_cjs.getPreciseType(
265
265
  checkValidOnly
266
- )}\`, 'prependPlusCountryCode': \`${chunkPZQ6I4JJ_cjs.getPreciseType(prependPlusCountryCode)}\`].`
266
+ )}\`, 'prependPlusCountryCode': \`${chunkF3WBQKRI_cjs.getPreciseType(prependPlusCountryCode)}\`].`
267
267
  );
268
268
  }
269
- if (!chunkPZQ6I4JJ_cjs.isUndefined(defaultCountry) && !max.isSupportedCountry(defaultCountry)) {
269
+ if (!chunkF3WBQKRI_cjs.isUndefined(defaultCountry) && !max.isSupportedCountry(defaultCountry)) {
270
270
  throw new TypeError(
271
- `Parameter \`defaultCountry\` property of the \`options\` (second parameter) must be of type \`string\` as \`CountryCode\` (ISO-3166-1 alpha-2) or unset as \`undefined\` value, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
271
+ `Parameter \`defaultCountry\` property of the \`options\` (second parameter) must be of type \`string\` as \`CountryCode\` (ISO-3166-1 alpha-2) or unset as \`undefined\` value, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
272
272
  defaultCountry
273
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(defaultCountry, {
273
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(defaultCountry, {
274
274
  keepUndefined: true
275
275
  })}\`.
276
276
 
@@ -279,21 +279,21 @@ See: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_e
279
279
  }
280
280
  if (!["INTERNATIONAL", "NATIONAL", "RFC3966", "E.164"].includes(outputFormat)) {
281
281
  throw new TypeError(
282
- `Parameter \`outputFormat\` property of the \`options\` (second parameter) must be of type \`string\` as \`OutputFormat\` ("NATIONAL" | "INTERNATIONAL" | "E.164" | "RFC3966") or unset as \`undefined\` (default value to: \`INTERNATIONAL\`) value, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
282
+ `Parameter \`outputFormat\` property of the \`options\` (second parameter) must be of type \`string\` as \`OutputFormat\` ("NATIONAL" | "INTERNATIONAL" | "E.164" | "RFC3966") or unset as \`undefined\` (default value to: \`INTERNATIONAL\`) value, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
283
283
  outputFormat
284
- )}\`, with value: ${chunkT7PU2V7X_cjs.safeStableStringify(outputFormat, { keepUndefined: true })}.`
284
+ )}\`, with value: ${chunkYC7AK3KX_cjs.safeStableStringify(outputFormat, { keepUndefined: true })}.`
285
285
  );
286
286
  }
287
- if (!chunkPZQ6I4JJ_cjs.isString(separator) || !chunkPZQ6I4JJ_cjs.isString(openingNumberCountry) || !chunkPZQ6I4JJ_cjs.isString(closingNumberCountry)) {
287
+ if (!chunkF3WBQKRI_cjs.isString(separator) || !chunkF3WBQKRI_cjs.isString(openingNumberCountry) || !chunkF3WBQKRI_cjs.isString(closingNumberCountry)) {
288
288
  throw new TypeError(
289
- `Parameter \`separator\`, \`plusNumberCountry\`, \`openingNumberCountry\` and \`closingNumberCountry\` property of the \`options\` (second parameter) must be of type \`string\` or unset as \`undefined\` value, but received: ['separator': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
289
+ `Parameter \`separator\`, \`plusNumberCountry\`, \`openingNumberCountry\` and \`closingNumberCountry\` property of the \`options\` (second parameter) must be of type \`string\` or unset as \`undefined\` value, but received: ['separator': \`${chunkF3WBQKRI_cjs.getPreciseType(
290
290
  separator
291
- )}\`,'openingNumberCountry': \`${chunkPZQ6I4JJ_cjs.getPreciseType(
291
+ )}\`,'openingNumberCountry': \`${chunkF3WBQKRI_cjs.getPreciseType(
292
292
  openingNumberCountry
293
- )}\`, 'closingNumberCountry': \`${chunkPZQ6I4JJ_cjs.getPreciseType(closingNumberCountry)}\`].`
293
+ )}\`, 'closingNumberCountry': \`${chunkF3WBQKRI_cjs.getPreciseType(closingNumberCountry)}\`].`
294
294
  );
295
295
  }
296
- if (!chunkPZQ6I4JJ_cjs.isString(value)) value = String(value);
296
+ if (!chunkF3WBQKRI_cjs.isString(value)) value = String(value);
297
297
  const parsedPhoneNumber = parsingAsYouType(value, defaultCountry);
298
298
  const validPhoneNumber = isValidParseAsYouType(parsedPhoneNumber);
299
299
  if (checkValidOnly) return validPhoneNumber;
@@ -307,7 +307,7 @@ See: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_e
307
307
  const [cc, ...rest] = intlNumb.split(" ");
308
308
  const countryCode = prependPlusCountryCode ? cc : cc.replace(/^\++/, "");
309
309
  const restWithSeparator = rest.join(separator);
310
- if (chunkPZQ6I4JJ_cjs.isNonEmptyString(openingNumberCountry) && chunkPZQ6I4JJ_cjs.isNonEmptyString(closingNumberCountry)) {
310
+ if (chunkF3WBQKRI_cjs.isNonEmptyString(openingNumberCountry) && chunkF3WBQKRI_cjs.isNonEmptyString(closingNumberCountry)) {
311
311
  return `${openingNumberCountry}${countryCode}${closingNumberCountry} ${restWithSeparator}`;
312
312
  }
313
313
  return `${countryCode} ${restWithSeparator}`;
@@ -337,7 +337,7 @@ var _censor = (str, minCensor, maxPercentage, hashSeed) => {
337
337
  const indexes = /* @__PURE__ */ new Set();
338
338
  let i = 0;
339
339
  while (indexes.size < totalCensor) {
340
- const idx = !chunkPZQ6I4JJ_cjs.isUndefined(hashSeed) ? (hashSeed + str.length + i * 31) % str.length : Math.floor(Math.random() * str.length);
340
+ const idx = !chunkF3WBQKRI_cjs.isUndefined(hashSeed) ? (hashSeed + str.length + i * 31) % str.length : Math.floor(Math.random() * str.length);
341
341
  indexes.add(idx);
342
342
  i++;
343
343
  }
@@ -348,16 +348,16 @@ var _censor = (str, minCensor, maxPercentage, hashSeed) => {
348
348
  };
349
349
 
350
350
  var censorEmail = (email, options = {}) => {
351
- if (!chunkPZQ6I4JJ_cjs.isNonEmptyString(email)) return "";
352
- chunkPZQ6I4JJ_cjs.assertIsPlainObject(options, {
351
+ if (!chunkF3WBQKRI_cjs.isNonEmptyString(email)) return "";
352
+ chunkF3WBQKRI_cjs.assertIsPlainObject(options, {
353
353
  message: ({ currentType, validType }) => `Second parameter (\`options\`) must be of type \`${validType}\`, but received: \`${currentType}\`.`
354
354
  });
355
- const mode = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "mode") ? options.mode : "fixed";
355
+ const mode = chunkF3WBQKRI_cjs.hasOwnProp(options, "mode") ? options.mode : "fixed";
356
356
  if (mode !== "random" && mode !== "fixed") {
357
357
  throw new TypeError(
358
- `Parameter \`mode\` property of the \`options\` (second parameter) must be one of "fixed" or "random", but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
358
+ `Parameter \`mode\` property of the \`options\` (second parameter) must be one of "fixed" or "random", but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
359
359
  mode
360
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(mode)}\`.`
360
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(mode)}\`.`
361
361
  );
362
362
  }
363
363
  const emailRegex = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
@@ -377,29 +377,29 @@ var censorEmail = (email, options = {}) => {
377
377
  };
378
378
 
379
379
  function chunkString(subject, limiter, options = {}) {
380
- if (chunkPZQ6I4JJ_cjs.isNil(subject) || limiter <= 0) return subject;
381
- chunkHYRQMTRH_cjs.assertIsString(subject, {
380
+ if (chunkF3WBQKRI_cjs.isNil(subject) || limiter <= 0) return subject;
381
+ chunkK63WO3XA_cjs.assertIsString(subject, {
382
382
  message: ({ currentType, validType }) => `First parameter (\`subject\`) must be of type \`${validType}\`, but received: \`${currentType}\`.`
383
383
  });
384
384
  if (!chunkDVMHRLKP_cjs.isInteger(limiter)) {
385
385
  throw new TypeError(
386
- `Second parameter (\`limiter\`) must be of type \`integer-number\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
386
+ `Second parameter (\`limiter\`) must be of type \`integer-number\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
387
387
  limiter
388
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(limiter)}\`.`
388
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(limiter)}\`.`
389
389
  );
390
390
  }
391
- chunkPZQ6I4JJ_cjs.assertIsPlainObject(options, {
391
+ chunkF3WBQKRI_cjs.assertIsPlainObject(options, {
392
392
  message: ({ currentType, validType }) => `Third parameter (\`options\`) must be of type \`${validType}\`, but received: \`${currentType}\`.`
393
393
  });
394
- const separator = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "separator") ? options.separator : " ";
395
- const reCountAfterSpace = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "reCountAfterSpace") ? options.reCountAfterSpace : false;
396
- chunkHYRQMTRH_cjs.assertIsString(separator, {
394
+ const separator = chunkF3WBQKRI_cjs.hasOwnProp(options, "separator") ? options.separator : " ";
395
+ const reCountAfterSpace = chunkF3WBQKRI_cjs.hasOwnProp(options, "reCountAfterSpace") ? options.reCountAfterSpace : false;
396
+ chunkK63WO3XA_cjs.assertIsString(separator, {
397
397
  message: ({ currentType, validType }) => `Parameter \`separator\` property of the \`options\` (third parameter) must be of type \`${validType}\`, but received: \`${currentType}\`.`
398
398
  });
399
- chunkPZQ6I4JJ_cjs.assertIsBoolean(reCountAfterSpace, {
399
+ chunkF3WBQKRI_cjs.assertIsBoolean(reCountAfterSpace, {
400
400
  message: ({ currentType, validType }) => `Parameter \`reCountAfterSpace\` property of the \`options\` (third parameter) must be of type \`${validType}\`, but received: \`${currentType}\`.`
401
401
  });
402
- subject = chunk2IOOEY45_cjs.normalizeSpaces(subject);
402
+ subject = chunkB6UIKBHR_cjs.normalizeSpaces(subject);
403
403
  if (!reCountAfterSpace) {
404
404
  let result = "";
405
405
  let currentCount = 0;
@@ -442,28 +442,28 @@ function chunkString(subject, limiter, options = {}) {
442
442
  }
443
443
 
444
444
  var truncateString = (text, options = {}) => {
445
- if (!chunkPZQ6I4JJ_cjs.isNonEmptyString(text)) return "";
446
- chunkPZQ6I4JJ_cjs.assertIsPlainObject(options, {
445
+ if (!chunkF3WBQKRI_cjs.isNonEmptyString(text)) return "";
446
+ chunkF3WBQKRI_cjs.assertIsPlainObject(options, {
447
447
  message: ({ currentType, validType }) => `Seconds parameter (\`options\`) must be of type \`${validType}\`, but received: \`${currentType}\`.`
448
448
  });
449
- const trim = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "trim") ? options.trim : true;
450
- const length2 = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "length") ? options.length : 10;
451
- let ending = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "ending") ? options.ending : "...";
449
+ const trim = chunkF3WBQKRI_cjs.hasOwnProp(options, "trim") ? options.trim : true;
450
+ const length2 = chunkF3WBQKRI_cjs.hasOwnProp(options, "length") ? options.length : 10;
451
+ let ending = chunkF3WBQKRI_cjs.hasOwnProp(options, "ending") ? options.ending : "...";
452
452
  if (!chunkDVMHRLKP_cjs.isInteger(length2)) {
453
453
  throw new TypeError(
454
- `Parameter \`length\` property of the \`options\` (second parameter) must be of type \`integer-number\`, but received: \`${chunkPZQ6I4JJ_cjs.getPreciseType(
454
+ `Parameter \`length\` property of the \`options\` (second parameter) must be of type \`integer-number\`, but received: \`${chunkF3WBQKRI_cjs.getPreciseType(
455
455
  length2
456
- )}\`, with value: \`${chunkT7PU2V7X_cjs.safeStableStringify(length2)}\`.`
456
+ )}\`, with value: \`${chunkYC7AK3KX_cjs.safeStableStringify(length2)}\`.`
457
457
  );
458
458
  }
459
459
  if (length2 < 1) return "";
460
- chunkHYRQMTRH_cjs.assertIsString(ending, {
460
+ chunkK63WO3XA_cjs.assertIsString(ending, {
461
461
  message: ({ currentType, validType }) => `Parameter \`ending\` property of the \`options\` (second parameter) must be of type \`${validType}\`, but received: \`${currentType}\`.`
462
462
  });
463
- chunkPZQ6I4JJ_cjs.assertIsBoolean(trim, {
463
+ chunkF3WBQKRI_cjs.assertIsBoolean(trim, {
464
464
  message: ({ currentType, validType }) => `Parameter \`trim\` property of the \`options\` (second parameter) must be of type \`${validType}\`, but received: \`${currentType}\`.`
465
465
  });
466
- if (chunkE55EQK2U_cjs.isEmptyString(ending)) {
466
+ if (chunkNREACG6M_cjs.isEmptyString(ending)) {
467
467
  ending = "...";
468
468
  } else {
469
469
  ending = ending.trim();
@@ -476,24 +476,24 @@ var truncateString = (text, options = {}) => {
476
476
  return cleanSliced + ending;
477
477
  };
478
478
  var formatDateFns = (date, options = {}) => {
479
- if (chunkPZQ6I4JJ_cjs.isNil(date) || !(chunkT7PU2V7X_cjs.isDate(date) || chunkPZQ6I4JJ_cjs.isNonEmptyString(date))) return null;
480
- if (!chunkPZQ6I4JJ_cjs.isPlainObject(options)) {
479
+ if (chunkF3WBQKRI_cjs.isNil(date) || !(chunkYC7AK3KX_cjs.isDate(date) || chunkF3WBQKRI_cjs.isNonEmptyString(date))) return null;
480
+ if (!chunkF3WBQKRI_cjs.isPlainObject(options)) {
481
481
  options = {};
482
482
  }
483
483
  const { inputFormat, locale: locale$1 = "en", inputLocale = "en", ...restOptions } = options;
484
- const format = chunkPZQ6I4JJ_cjs.hasOwnProp(options, "format") && chunkPZQ6I4JJ_cjs.isNonEmptyString(options.format) ? options.format : "dd MMM yyyy - HH:mm:ss";
484
+ const format = chunkF3WBQKRI_cjs.hasOwnProp(options, "format") && chunkF3WBQKRI_cjs.isNonEmptyString(options.format) ? options.format : "dd MMM yyyy - HH:mm:ss";
485
485
  let parsedDate;
486
486
  try {
487
- if (chunkPZQ6I4JJ_cjs.isNonEmptyString(date) && inputFormat && inputLocale) {
488
- const valueOfInputLocale = chunkPZQ6I4JJ_cjs.isNonEmptyString(inputLocale) ? inputLocale === "id" ? locale.id : locale.enUS : inputLocale;
487
+ if (chunkF3WBQKRI_cjs.isNonEmptyString(date) && inputFormat && inputLocale) {
488
+ const valueOfInputLocale = chunkF3WBQKRI_cjs.isNonEmptyString(inputLocale) ? inputLocale === "id" ? locale.id : locale.enUS : inputLocale;
489
489
  parsedDate = dateFns.parse(date, inputFormat, /* @__PURE__ */ new Date(), {
490
490
  locale: valueOfInputLocale
491
491
  });
492
492
  } else {
493
493
  parsedDate = new Date(date);
494
494
  }
495
- if (chunkPZQ6I4JJ_cjs.isNaN(parsedDate.getTime())) return null;
496
- const valueOfLocale = chunkPZQ6I4JJ_cjs.isNonEmptyString(locale$1) ? locale$1 === "id" ? locale.id : locale.enUS : locale$1;
495
+ if (chunkF3WBQKRI_cjs.isNaN(parsedDate.getTime())) return null;
496
+ const valueOfLocale = chunkF3WBQKRI_cjs.isNonEmptyString(locale$1) ? locale$1 === "id" ? locale.id : locale.enUS : locale$1;
497
497
  return dateFns.format(parsedDate, format, {
498
498
  ...restOptions,
499
499
  locale: valueOfLocale
@@ -504,16 +504,16 @@ var formatDateFns = (date, options = {}) => {
504
504
  };
505
505
 
506
506
  var formatDateIntl = (date, options) => {
507
- if (chunkPZQ6I4JJ_cjs.isNil(date) || !(chunkT7PU2V7X_cjs.isDate(date) || chunkPZQ6I4JJ_cjs.isNonEmptyString(date))) return null;
507
+ if (chunkF3WBQKRI_cjs.isNil(date) || !(chunkYC7AK3KX_cjs.isDate(date) || chunkF3WBQKRI_cjs.isNonEmptyString(date))) return null;
508
508
  const parsedDate = new Date(date);
509
- if (chunkPZQ6I4JJ_cjs.isNaN(parsedDate.getTime())) return null;
510
- if (!chunkPZQ6I4JJ_cjs.isPlainObject(options)) {
509
+ if (chunkF3WBQKRI_cjs.isNaN(parsedDate.getTime())) return null;
510
+ if (!chunkF3WBQKRI_cjs.isPlainObject(options)) {
511
511
  options = {};
512
512
  }
513
513
  const { locale = "en-US", ...restProps } = options;
514
514
  try {
515
515
  return new Intl.DateTimeFormat(
516
- chunkPZQ6I4JJ_cjs.isNonEmptyString(locale) ? locale.trim() : "en-US",
516
+ chunkF3WBQKRI_cjs.isNonEmptyString(locale) ? locale.trim() : "en-US",
517
517
  restProps
518
518
  ).format(parsedDate);
519
519
  } catch {
@@ -522,16 +522,16 @@ var formatDateIntl = (date, options) => {
522
522
  };
523
523
 
524
524
  var formatDateTime = (date, format) => {
525
- if (chunkPZQ6I4JJ_cjs.isNil(format)) {
525
+ if (chunkF3WBQKRI_cjs.isNil(format)) {
526
526
  format = "YYYY-MM-DD hh:mm:ss";
527
527
  }
528
- if (!chunkPZQ6I4JJ_cjs.isString(format)) return null;
529
- if (chunkPZQ6I4JJ_cjs.isNil(date) || !(chunkT7PU2V7X_cjs.isDate(date) || chunkPZQ6I4JJ_cjs.isNonEmptyString(date))) {
528
+ if (!chunkF3WBQKRI_cjs.isString(format)) return null;
529
+ if (chunkF3WBQKRI_cjs.isNil(date) || !(chunkYC7AK3KX_cjs.isDate(date) || chunkF3WBQKRI_cjs.isNonEmptyString(date))) {
530
530
  return null;
531
531
  }
532
532
  try {
533
533
  const parsedDate = new Date(date);
534
- if (chunkPZQ6I4JJ_cjs.isNaN(parsedDate.getTime())) return null;
534
+ if (chunkF3WBQKRI_cjs.isNaN(parsedDate.getTime())) return null;
535
535
  const pad2 = (n) => n.toString().padStart(2, "0");
536
536
  const map = {
537
537
  YYYY: parsedDate.getFullYear().toString(),
@@ -553,13 +553,13 @@ var formatDateTime = (date, format) => {
553
553
 
554
554
  var getGMTOffset = (date) => {
555
555
  try {
556
- if (chunkPZQ6I4JJ_cjs.isNil(date) || chunkPZQ6I4JJ_cjs.isString(date) && chunkE55EQK2U_cjs.isEmptyString(date)) {
556
+ if (chunkF3WBQKRI_cjs.isNil(date) || chunkF3WBQKRI_cjs.isString(date) && chunkNREACG6M_cjs.isEmptyString(date)) {
557
557
  date = /* @__PURE__ */ new Date();
558
- } else if (!(chunkT7PU2V7X_cjs.isDate(date) || chunkPZQ6I4JJ_cjs.isNonEmptyString(date))) {
558
+ } else if (!(chunkYC7AK3KX_cjs.isDate(date) || chunkF3WBQKRI_cjs.isNonEmptyString(date))) {
559
559
  return "0";
560
560
  }
561
561
  const parsedDate = new Date(date);
562
- if (chunkPZQ6I4JJ_cjs.isNaN(parsedDate.getTime())) return "0";
562
+ if (chunkF3WBQKRI_cjs.isNaN(parsedDate.getTime())) return "0";
563
563
  const padZero = (num) => num.toString().padStart(2, "0");
564
564
  let offset = parsedDate.getTimezoneOffset();
565
565
  const sign = offset < 0 ? "+" : "-";
@@ -2,14 +2,14 @@
2
2
  * ====================================================
3
3
  * Rzl Utils-JS.
4
4
  * ----------------------------------------------------
5
- * Version: 3.5.3.
5
+ * Version: 3.5.4.
6
6
  * Author: Rizalvin Dwiky.
7
7
  * Repository: https://github.com/rzl-zone/utils-js.
8
8
  * ====================================================
9
9
  */
10
- import { isEmptyString } from './chunk-W2WNBUDE.js';
11
- import { isEmptyArray, isEmptyObject } from './chunk-6JFCSH7J.js';
12
- import { assertIsPlainObject, hasOwnProp, assertIsBoolean, isNil, isNaN, isString, isArray, isObject } from './chunk-CMW2TBOQ.js';
10
+ import { isEmptyString } from './chunk-JY4HLZ4W.js';
11
+ import { isEmptyArray, isEmptyObject } from './chunk-VCVND6CH.js';
12
+ import { assertIsPlainObject, hasOwnProp, assertIsBoolean, isNil, isNaN, isString, isArray, isObject } from './chunk-3KTD3QDI.js';
13
13
 
14
14
  var isEmptyValue = (value, options = {}) => {
15
15
  assertIsPlainObject(options, {
@@ -2,14 +2,14 @@
2
2
  * ====================================================
3
3
  * Rzl Utils-JS.
4
4
  * ----------------------------------------------------
5
- * Version: 3.5.3.
5
+ * Version: 3.5.4.
6
6
  * Author: Rizalvin Dwiky.
7
7
  * Repository: https://github.com/rzl-zone/utils-js.
8
8
  * ====================================================
9
9
  */
10
10
  'use strict';
11
11
 
12
- var chunkPZQ6I4JJ_cjs = require('./chunk-PZQ6I4JJ.cjs');
12
+ var chunkF3WBQKRI_cjs = require('./chunk-F3WBQKRI.cjs');
13
13
 
14
14
  var KNOWN_EXTENSIONS = /* @__PURE__ */ new Set([
15
15
  // 📄 Text & Document
@@ -393,7 +393,7 @@ var DOUBLE_EXTENSIONS = /* @__PURE__ */ new Set([
393
393
  "tar.xz"
394
394
  ]);
395
395
  var extractFileName = (url) => {
396
- if (!chunkPZQ6I4JJ_cjs.isNonEmptyString(url)) return void 0;
396
+ if (!chunkF3WBQKRI_cjs.isNonEmptyString(url)) return void 0;
397
397
  let fileName = url.split("/").pop();
398
398
  if (fileName === "") return "";
399
399
  if (!fileName) return void 0;
@@ -2,7 +2,7 @@
2
2
  * ====================================================
3
3
  * Rzl Utils-JS.
4
4
  * ----------------------------------------------------
5
- * Version: 3.5.3.
5
+ * Version: 3.5.4.
6
6
  * Author: Rizalvin Dwiky.
7
7
  * Repository: https://github.com/rzl-zone/utils-js.
8
8
  * ====================================================
@@ -2,19 +2,19 @@
2
2
  * ====================================================
3
3
  * Rzl Utils-JS.
4
4
  * ----------------------------------------------------
5
- * Version: 3.5.3.
5
+ * Version: 3.5.4.
6
6
  * Author: Rizalvin Dwiky.
7
7
  * Repository: https://github.com/rzl-zone/utils-js.
8
8
  * ====================================================
9
9
  */
10
- import { normalizeSpaces } from './chunk-T2T7K3KR.js';
11
- import { parseCurrencyString } from './chunk-IRFL4MAX.js';
12
- import { isFinite } from './chunk-3IBQ5MOM.js';
10
+ import { normalizeSpaces } from './chunk-OFBFGFVH.js';
11
+ import { parseCurrencyString } from './chunk-DPLL67OT.js';
12
+ import { isFinite } from './chunk-7ZNEUWYP.js';
13
13
  import { isInteger } from './chunk-WVSPXFTY.js';
14
- import { isEmptyString } from './chunk-W2WNBUDE.js';
15
- import { assertIsString } from './chunk-SBKGWRS5.js';
16
- import { safeStableStringify, isDate } from './chunk-PET42Z7W.js';
17
- import { isString, getPreciseType, assertIsPlainObject, hasOwnProp, isBoolean, isPlainObject, isNaN, isUndefined, isFunction, assertIsBoolean, isNil, isNumber, isNonEmptyString } from './chunk-CMW2TBOQ.js';
14
+ import { isEmptyString } from './chunk-JY4HLZ4W.js';
15
+ import { assertIsString } from './chunk-FI76UZRF.js';
16
+ import { safeStableStringify, isDate } from './chunk-2VO2CBTU.js';
17
+ import { isString, getPreciseType, assertIsPlainObject, hasOwnProp, isBoolean, isPlainObject, isNaN, isUndefined, isFunction, assertIsBoolean, isNil, isNumber, isNonEmptyString } from './chunk-3KTD3QDI.js';
18
18
  import { isSupportedCountry, AsYouType } from 'libphonenumber-js/max';
19
19
  import { id, enUS } from 'date-fns/locale';
20
20
  import { parse, format } from 'date-fns';