@krainovsd/js-helpers 0.15.3 → 0.16.1

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 (65) hide show
  1. package/lib/cjs/index.cjs +662 -583
  2. package/lib/cjs/index.cjs.map +1 -1
  3. package/lib/esm/{lib/api/middlewares/console-post-middleware.js → api/after/logger-after-handler.js} +4 -4
  4. package/lib/esm/api/after/logger-after-handler.js.map +1 -0
  5. package/lib/esm/api/api.constants.js +23 -0
  6. package/lib/esm/api/api.constants.js.map +1 -0
  7. package/lib/esm/api/api.js +343 -0
  8. package/lib/esm/api/api.js.map +1 -0
  9. package/lib/esm/{lib/api/middlewares/console-middleware.js → api/before/logger-before-handler.js} +4 -4
  10. package/lib/esm/api/before/logger-before-handler.js.map +1 -0
  11. package/lib/esm/api/before/oauth-before-handler.js +56 -0
  12. package/lib/esm/api/before/oauth-before-handler.js.map +1 -0
  13. package/lib/esm/{lib/api/oauth/token.js → api/oauth.js} +30 -10
  14. package/lib/esm/api/oauth.js.map +1 -0
  15. package/lib/esm/constants/errors.js +16 -0
  16. package/lib/esm/constants/errors.js.map +1 -0
  17. package/lib/esm/constants/index.js +27 -0
  18. package/lib/esm/constants/index.js.map +1 -0
  19. package/lib/esm/index.js +9 -8
  20. package/lib/esm/index.js.map +1 -1
  21. package/lib/esm/lib/colors/get-color-format.js +1 -2
  22. package/lib/esm/lib/colors/get-color-format.js.map +1 -1
  23. package/lib/esm/lib/colors/take-opacity-colors.js +1 -2
  24. package/lib/esm/lib/colors/take-opacity-colors.js.map +1 -1
  25. package/lib/esm/lib/colors/transform-to-color.js +1 -2
  26. package/lib/esm/lib/colors/transform-to-color.js.map +1 -1
  27. package/lib/esm/lib/date/get-date-by-rules.js +1 -2
  28. package/lib/esm/lib/date/get-date-by-rules.js.map +1 -1
  29. package/lib/esm/lib/date/is-yesterday.js +0 -1
  30. package/lib/esm/lib/date/is-yesterday.js.map +1 -1
  31. package/lib/esm/lib/lodash/clone-deep.js +2 -11
  32. package/lib/esm/lib/lodash/clone-deep.js.map +1 -1
  33. package/lib/esm/lib/lodash/debounce.js +1 -2
  34. package/lib/esm/lib/lodash/debounce.js.map +1 -1
  35. package/lib/esm/lib/lodash/throttle.js +1 -1
  36. package/lib/esm/lib/lodash/throttle.js.map +1 -1
  37. package/lib/esm/lib/utils/build-query-string.js.map +1 -1
  38. package/lib/esm/lib/utils/{create-url-with-params.js → create-url-with-queries.js} +3 -3
  39. package/lib/esm/lib/utils/create-url-with-queries.js.map +1 -0
  40. package/lib/esm/lib/utils/field-view-format.js +1 -2
  41. package/lib/esm/lib/utils/field-view-format.js.map +1 -1
  42. package/lib/index.d.ts +229 -175
  43. package/package.json +4 -2
  44. package/lib/esm/constants/api.js +0 -10
  45. package/lib/esm/constants/api.js.map +0 -1
  46. package/lib/esm/constants/colors.js +0 -9
  47. package/lib/esm/constants/colors.js.map +0 -1
  48. package/lib/esm/constants/date.js +0 -11
  49. package/lib/esm/constants/date.js.map +0 -1
  50. package/lib/esm/constants/fields.js +0 -11
  51. package/lib/esm/constants/fields.js.map +0 -1
  52. package/lib/esm/lib/api/constants.js +0 -4
  53. package/lib/esm/lib/api/constants.js.map +0 -1
  54. package/lib/esm/lib/api/core.js +0 -191
  55. package/lib/esm/lib/api/core.js.map +0 -1
  56. package/lib/esm/lib/api/middlewares/console-middleware.js.map +0 -1
  57. package/lib/esm/lib/api/middlewares/console-post-middleware.js.map +0 -1
  58. package/lib/esm/lib/api/middlewares/index.js +0 -65
  59. package/lib/esm/lib/api/middlewares/index.js.map +0 -1
  60. package/lib/esm/lib/api/middlewares/oauth-middleware.js +0 -75
  61. package/lib/esm/lib/api/middlewares/oauth-middleware.js.map +0 -1
  62. package/lib/esm/lib/api/oauth/token.js.map +0 -1
  63. package/lib/esm/lib/api/oauth/user.js +0 -35
  64. package/lib/esm/lib/api/oauth/user.js.map +0 -1
  65. package/lib/esm/lib/utils/create-url-with-params.js.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.js","sources":["../../../src/constants/errors.ts"],"sourcesContent":["import type { RequestHeader } from \"../api\";\n\ntype ResponseErrorOptions = {\n message: string;\n status: number;\n code?: number;\n description?: unknown;\n headers?: RequestHeader;\n};\n\nexport class ResponseError extends Error {\n status: number;\n code?: number;\n description?: unknown;\n headers?: RequestHeader;\n\n constructor({ message, status, description, code, headers }: ResponseErrorOptions) {\n super(message);\n this.status = status;\n this.description = description;\n this.code = code;\n this.headers = headers;\n }\n}\n"],"names":[],"mappings":"AAUM,MAAO,aAAc,SAAQ,KAAK,CAAA;AACtC,IAAA,MAAM;AACN,IAAA,IAAI;AACJ,IAAA,WAAW;AACX,IAAA,OAAO;IAEP,WAAY,CAAA,EAAE,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,IAAI,EAAE,OAAO,EAAwB,EAAA;QAC/E,KAAK,CAAC,OAAO,CAAC;AACd,QAAA,IAAI,CAAC,MAAM,GAAG,MAAM;AACpB,QAAA,IAAI,CAAC,WAAW,GAAG,WAAW;AAC9B,QAAA,IAAI,CAAC,IAAI,GAAG,IAAI;AAChB,QAAA,IAAI,CAAC,OAAO,GAAG,OAAO;;AAEzB;;;;"}
@@ -0,0 +1,27 @@
1
+ export { IS_BROWSER, IS_BUN, IS_DENO, IS_JEST, IS_NODE, IS_WEB_WORKER } from './environment.js';
2
+
3
+ const COLOR_FORMATS = {
4
+ Hex: "HEX",
5
+ Rgb: "RGB",
6
+ Rgba: "RGBA",
7
+ Hsl: "HSL",
8
+ };
9
+ const DATE_TYPES = {
10
+ Days: "days",
11
+ Months: "months",
12
+ Years: "years",
13
+ Seconds: "seconds",
14
+ Minutes: "minutes",
15
+ Hours: "hours",
16
+ };
17
+ const FIELD_TYPES = {
18
+ Date: "date",
19
+ Time: "time",
20
+ DateTime: "dateTime",
21
+ String: "string",
22
+ Number: "number",
23
+ Array: "array",
24
+ };
25
+
26
+ export { COLOR_FORMATS, DATE_TYPES, FIELD_TYPES };
27
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../../src/constants/index.ts"],"sourcesContent":["export * from \"./errors\";\nexport * from \"./environment\";\n\nexport const COLOR_FORMATS = {\n Hex: \"HEX\",\n Rgb: \"RGB\",\n Rgba: \"RGBA\",\n Hsl: \"HSL\",\n} as const;\n\nexport const DATE_TYPES = {\n Days: \"days\",\n Months: \"months\",\n Years: \"years\",\n Seconds: \"seconds\",\n Minutes: \"minutes\",\n Hours: \"hours\",\n} as const;\n\nexport const FIELD_TYPES = {\n Date: \"date\",\n Time: \"time\",\n DateTime: \"dateTime\",\n String: \"string\",\n Number: \"number\",\n Array: \"array\",\n} as const;\n"],"names":[],"mappings":";;AAGa,MAAA,aAAa,GAAG;AAC3B,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,GAAG,EAAE,KAAK;AACV,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,GAAG,EAAE,KAAK;;AAGC,MAAA,UAAU,GAAG;AACxB,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,MAAM,EAAE,QAAQ;AAChB,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;;AAGH,MAAA,WAAW,GAAG;AACzB,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,QAAQ,EAAE,UAAU;AACpB,IAAA,MAAM,EAAE,QAAQ;AAChB,IAAA,MAAM,EAAE,QAAQ;AAChB,IAAA,KAAK,EAAE,OAAO;;;;;"}
package/lib/esm/index.js CHANGED
@@ -1,6 +1,3 @@
1
- export { ResponseError, createRequestClientInstance } from './lib/api/core.js';
2
- export { getOauthToken, getOauthTokenFromOtherWindow } from './lib/api/oauth/token.js';
3
- export { getAuthUser, updateAuthUser } from './lib/api/oauth/user.js';
4
1
  export { downloadFile } from './lib/browser/download-file.js';
5
2
  export { downloadJson } from './lib/browser/download-json.js';
6
3
  export { readFile } from './lib/browser/read-file.js';
@@ -32,7 +29,7 @@ export { jsonParse } from './lib/utils/json-parse.js';
32
29
  export { randomString } from './lib/utils/random-string.js';
33
30
  export { wait } from './lib/utils/wait.js';
34
31
  export { transformToNumber } from './lib/utils/transform-to-number.js';
35
- export { createURLWithParams } from './lib/utils/create-url-with-params.js';
32
+ export { createURLWithQueries } from './lib/utils/create-url-with-queries.js';
36
33
  export { trimUrl } from './lib/utils/trim-url.js';
37
34
  export { arrayToMapByKey } from './lib/utils/array-to-map-by-key.js';
38
35
  export { buildQueryString } from './lib/utils/build-query-string.js';
@@ -70,9 +67,13 @@ export { differenceWith } from './lib/lodash/difference-with.js';
70
67
  export { isEqual } from './lib/lodash/is-equal.js';
71
68
  export { throttle } from './lib/lodash/throttle.js';
72
69
  export { type } from './lib/lodash/type.js';
73
- export { DATE_TYPES } from './constants/date.js';
74
- export { API_MIDDLEWARES, POST_API_MIDDLEWARES } from './constants/api.js';
70
+ export { COLOR_FORMATS, DATE_TYPES, FIELD_TYPES } from './constants/index.js';
71
+ export { createFetchClient } from './api/api.js';
72
+ export { getOauthToken, getOauthTokenFromOtherWindow, refetchAfterOauth } from './api/oauth.js';
73
+ export { loggerAfterHandler } from './api/after/logger-after-handler.js';
74
+ export { loggerBeforeHandler } from './api/before/logger-before-handler.js';
75
+ export { oauthBeforeHandler } from './api/before/oauth-before-handler.js';
76
+ export { OAUTH_STATE, REQUEST_ERROR, RESPONSE_DATA_SYMBOL } from './api/api.constants.js';
77
+ export { ResponseError } from './constants/errors.js';
75
78
  export { IS_BROWSER, IS_BUN, IS_DENO, IS_JEST, IS_NODE, IS_WEB_WORKER } from './constants/environment.js';
76
- export { COLOR_FORMATS } from './constants/colors.js';
77
- export { FIELD_TYPES } from './constants/fields.js';
78
79
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,5 +1,4 @@
1
- import '../../constants/environment.js';
2
- import { COLOR_FORMATS } from '../../constants/colors.js';
1
+ import { COLOR_FORMATS } from '../../constants/index.js';
3
2
 
4
3
  function getColorFormat(color) {
5
4
  if (color.startsWith("#")) {
@@ -1 +1 @@
1
- {"version":3,"file":"get-color-format.js","sources":["../../../../src/lib/colors/get-color-format.ts"],"sourcesContent":["import { COLOR_FORMATS } from \"../../constants\";\n\nexport function getColorFormat(color: string) {\n if (color.startsWith(\"#\")) {\n return COLOR_FORMATS.Hex;\n }\n if (color.startsWith(\"rgba\")) {\n return COLOR_FORMATS.Rgba;\n }\n if (color.startsWith(\"rgb\")) {\n return COLOR_FORMATS.Rgb;\n }\n if (color.startsWith(\"hsl\")) {\n return COLOR_FORMATS.Hsl;\n }\n}\n"],"names":[],"mappings":";;;AAEM,SAAU,cAAc,CAAC,KAAa,EAAA;AAC1C,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE;QACzB,OAAO,aAAa,CAAC,GAAG;;AAE1B,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE;QAC5B,OAAO,aAAa,CAAC,IAAI;;AAE3B,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE;QAC3B,OAAO,aAAa,CAAC,GAAG;;AAE1B,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE;QAC3B,OAAO,aAAa,CAAC,GAAG;;AAE5B;;;;"}
1
+ {"version":3,"file":"get-color-format.js","sources":["../../../../src/lib/colors/get-color-format.ts"],"sourcesContent":["import { COLOR_FORMATS } from \"../../constants\";\n\nexport function getColorFormat(color: string) {\n if (color.startsWith(\"#\")) {\n return COLOR_FORMATS.Hex;\n }\n if (color.startsWith(\"rgba\")) {\n return COLOR_FORMATS.Rgba;\n }\n if (color.startsWith(\"rgb\")) {\n return COLOR_FORMATS.Rgb;\n }\n if (color.startsWith(\"hsl\")) {\n return COLOR_FORMATS.Hsl;\n }\n}\n"],"names":[],"mappings":";;AAEM,SAAU,cAAc,CAAC,KAAa,EAAA;AAC1C,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE;QACzB,OAAO,aAAa,CAAC,GAAG;;AAE1B,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE;QAC5B,OAAO,aAAa,CAAC,IAAI;;AAE3B,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE;QAC3B,OAAO,aAAa,CAAC,GAAG;;AAE1B,IAAA,IAAI,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE;QAC3B,OAAO,aAAa,CAAC,GAAG;;AAE5B;;;;"}
@@ -1,5 +1,4 @@
1
- import '../../constants/environment.js';
2
- import { COLOR_FORMATS } from '../../constants/colors.js';
1
+ import { COLOR_FORMATS } from '../../constants/index.js';
3
2
  import { getColorFormat } from './get-color-format.js';
4
3
  import { transformHEXtoRGB } from './transform-hex-to-rgb.js';
5
4
  import { transformRGBtoRGBA } from './transform-rgb-to-rgba.js';
@@ -1 +1 @@
1
- {"version":3,"file":"take-opacity-colors.js","sources":["../../../../src/lib/colors/take-opacity-colors.ts"],"sourcesContent":["import { COLOR_FORMATS } from \"../../constants\";\nimport { getColorFormat } from \"./get-color-format\";\nimport { transformHEXtoRGB } from \"./transform-hex-to-rgb\";\nimport { transformRGBtoRGBA } from \"./transform-rgb-to-rgba\";\nimport { transformRGBAtoRGB } from \"./transform-rgba-to-rgb\";\n\nexport function takeOpacityColors(color: string | undefined, opacities: number[]) {\n let rgbColor = color;\n\n if (!rgbColor) return [];\n\n if (getColorFormat(rgbColor) === COLOR_FORMATS.Hex) {\n rgbColor = transformHEXtoRGB(rgbColor);\n } else if (getColorFormat(rgbColor) === COLOR_FORMATS.Rgba) {\n rgbColor = transformRGBAtoRGB(rgbColor);\n }\n\n if (getColorFormat(rgbColor) !== COLOR_FORMATS.Rgb) return [];\n\n return [...opacities.map((opacity) => transformRGBtoRGBA(rgbColor, opacity))];\n}\n"],"names":[],"mappings":";;;;;;;AAMgB,SAAA,iBAAiB,CAAC,KAAyB,EAAE,SAAmB,EAAA;IAC9E,IAAI,QAAQ,GAAG,KAAK;AAEpB,IAAA,IAAI,CAAC,QAAQ;AAAE,QAAA,OAAO,EAAE;IAExB,IAAI,cAAc,CAAC,QAAQ,CAAC,KAAK,aAAa,CAAC,GAAG,EAAE;AAClD,QAAA,QAAQ,GAAG,iBAAiB,CAAC,QAAQ,CAAC;;SACjC,IAAI,cAAc,CAAC,QAAQ,CAAC,KAAK,aAAa,CAAC,IAAI,EAAE;AAC1D,QAAA,QAAQ,GAAG,kBAAkB,CAAC,QAAQ,CAAC;;AAGzC,IAAA,IAAI,cAAc,CAAC,QAAQ,CAAC,KAAK,aAAa,CAAC,GAAG;AAAE,QAAA,OAAO,EAAE;AAE7D,IAAA,OAAO,CAAC,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC,OAAO,KAAK,kBAAkB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,CAAC;AAC/E;;;;"}
1
+ {"version":3,"file":"take-opacity-colors.js","sources":["../../../../src/lib/colors/take-opacity-colors.ts"],"sourcesContent":["import { COLOR_FORMATS } from \"../../constants\";\nimport { getColorFormat } from \"./get-color-format\";\nimport { transformHEXtoRGB } from \"./transform-hex-to-rgb\";\nimport { transformRGBtoRGBA } from \"./transform-rgb-to-rgba\";\nimport { transformRGBAtoRGB } from \"./transform-rgba-to-rgb\";\n\nexport function takeOpacityColors(color: string | undefined, opacities: number[]) {\n let rgbColor = color;\n\n if (!rgbColor) return [];\n\n if (getColorFormat(rgbColor) === COLOR_FORMATS.Hex) {\n rgbColor = transformHEXtoRGB(rgbColor);\n } else if (getColorFormat(rgbColor) === COLOR_FORMATS.Rgba) {\n rgbColor = transformRGBAtoRGB(rgbColor);\n }\n\n if (getColorFormat(rgbColor) !== COLOR_FORMATS.Rgb) return [];\n\n return [...opacities.map((opacity) => transformRGBtoRGBA(rgbColor, opacity))];\n}\n"],"names":[],"mappings":";;;;;;AAMgB,SAAA,iBAAiB,CAAC,KAAyB,EAAE,SAAmB,EAAA;IAC9E,IAAI,QAAQ,GAAG,KAAK;AAEpB,IAAA,IAAI,CAAC,QAAQ;AAAE,QAAA,OAAO,EAAE;IAExB,IAAI,cAAc,CAAC,QAAQ,CAAC,KAAK,aAAa,CAAC,GAAG,EAAE;AAClD,QAAA,QAAQ,GAAG,iBAAiB,CAAC,QAAQ,CAAC;;SACjC,IAAI,cAAc,CAAC,QAAQ,CAAC,KAAK,aAAa,CAAC,IAAI,EAAE;AAC1D,QAAA,QAAQ,GAAG,kBAAkB,CAAC,QAAQ,CAAC;;AAGzC,IAAA,IAAI,cAAc,CAAC,QAAQ,CAAC,KAAK,aAAa,CAAC,GAAG;AAAE,QAAA,OAAO,EAAE;AAE7D,IAAA,OAAO,CAAC,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC,OAAO,KAAK,kBAAkB,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,CAAC;AAC/E;;;;"}
@@ -1,5 +1,4 @@
1
- import '../../constants/environment.js';
2
- import { COLOR_FORMATS } from '../../constants/colors.js';
1
+ import { COLOR_FORMATS } from '../../constants/index.js';
3
2
  import { isString } from '../typings/is-string.js';
4
3
  import { getColorFormat } from './get-color-format.js';
5
4
 
@@ -1 +1 @@
1
- {"version":3,"file":"transform-to-color.js","sources":["../../../../src/lib/colors/transform-to-color.ts"],"sourcesContent":["import { COLOR_FORMATS } from \"../../constants\";\nimport type { ColorFormat } from \"../../types\";\nimport { isString } from \"../typings\";\nimport { getColorFormat } from \"./get-color-format\";\n\nexport function transformToColor(\n currentColor: unknown,\n defaultColor: string = \"black\",\n defaultFormat: ColorFormat = COLOR_FORMATS.Hex,\n) {\n if (!isString(currentColor)) return defaultColor;\n\n let correctColor = currentColor;\n\n if (!getColorFormat(correctColor)) {\n switch (defaultFormat) {\n case COLOR_FORMATS.Hex: {\n correctColor = `#${correctColor}`;\n break;\n }\n case COLOR_FORMATS.Rgb: {\n correctColor = `rgb(${correctColor})`;\n break;\n }\n case COLOR_FORMATS.Rgba: {\n correctColor = `rgba(${correctColor})`;\n break;\n }\n case COLOR_FORMATS.Hsl: {\n correctColor = `hsl(${correctColor})`;\n break;\n }\n default: {\n correctColor = `#${correctColor}`;\n break;\n }\n }\n }\n\n return correctColor;\n}\n"],"names":[],"mappings":";;;;;AAKM,SAAU,gBAAgB,CAC9B,YAAqB,EACrB,YAAuB,GAAA,OAAO,EAC9B,aAAA,GAA6B,aAAa,CAAC,GAAG,EAAA;AAE9C,IAAA,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC;AAAE,QAAA,OAAO,YAAY;IAEhD,IAAI,YAAY,GAAG,YAAY;AAE/B,IAAA,IAAI,CAAC,cAAc,CAAC,YAAY,CAAC,EAAE;QACjC,QAAQ,aAAa;AACnB,YAAA,KAAK,aAAa,CAAC,GAAG,EAAE;AACtB,gBAAA,YAAY,GAAG,CAAA,CAAA,EAAI,YAAY,CAAA,CAAE;gBACjC;;AAEF,YAAA,KAAK,aAAa,CAAC,GAAG,EAAE;AACtB,gBAAA,YAAY,GAAG,CAAA,IAAA,EAAO,YAAY,CAAA,CAAA,CAAG;gBACrC;;AAEF,YAAA,KAAK,aAAa,CAAC,IAAI,EAAE;AACvB,gBAAA,YAAY,GAAG,CAAA,KAAA,EAAQ,YAAY,CAAA,CAAA,CAAG;gBACtC;;AAEF,YAAA,KAAK,aAAa,CAAC,GAAG,EAAE;AACtB,gBAAA,YAAY,GAAG,CAAA,IAAA,EAAO,YAAY,CAAA,CAAA,CAAG;gBACrC;;YAEF,SAAS;AACP,gBAAA,YAAY,GAAG,CAAA,CAAA,EAAI,YAAY,CAAA,CAAE;gBACjC;;;;AAKN,IAAA,OAAO,YAAY;AACrB;;;;"}
1
+ {"version":3,"file":"transform-to-color.js","sources":["../../../../src/lib/colors/transform-to-color.ts"],"sourcesContent":["import { COLOR_FORMATS } from \"../../constants\";\nimport type { ColorFormat } from \"../../types\";\nimport { isString } from \"../typings\";\nimport { getColorFormat } from \"./get-color-format\";\n\nexport function transformToColor(\n currentColor: unknown,\n defaultColor: string = \"black\",\n defaultFormat: ColorFormat = COLOR_FORMATS.Hex,\n) {\n if (!isString(currentColor)) return defaultColor;\n\n let correctColor = currentColor;\n\n if (!getColorFormat(correctColor)) {\n switch (defaultFormat) {\n case COLOR_FORMATS.Hex: {\n correctColor = `#${correctColor}`;\n break;\n }\n case COLOR_FORMATS.Rgb: {\n correctColor = `rgb(${correctColor})`;\n break;\n }\n case COLOR_FORMATS.Rgba: {\n correctColor = `rgba(${correctColor})`;\n break;\n }\n case COLOR_FORMATS.Hsl: {\n correctColor = `hsl(${correctColor})`;\n break;\n }\n default: {\n correctColor = `#${correctColor}`;\n break;\n }\n }\n }\n\n return correctColor;\n}\n"],"names":[],"mappings":";;;;AAKM,SAAU,gBAAgB,CAC9B,YAAqB,EACrB,YAAuB,GAAA,OAAO,EAC9B,aAAA,GAA6B,aAAa,CAAC,GAAG,EAAA;AAE9C,IAAA,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC;AAAE,QAAA,OAAO,YAAY;IAEhD,IAAI,YAAY,GAAG,YAAY;AAE/B,IAAA,IAAI,CAAC,cAAc,CAAC,YAAY,CAAC,EAAE;QACjC,QAAQ,aAAa;AACnB,YAAA,KAAK,aAAa,CAAC,GAAG,EAAE;AACtB,gBAAA,YAAY,GAAG,CAAA,CAAA,EAAI,YAAY,CAAA,CAAE;gBACjC;;AAEF,YAAA,KAAK,aAAa,CAAC,GAAG,EAAE;AACtB,gBAAA,YAAY,GAAG,CAAA,IAAA,EAAO,YAAY,CAAA,CAAA,CAAG;gBACrC;;AAEF,YAAA,KAAK,aAAa,CAAC,IAAI,EAAE;AACvB,gBAAA,YAAY,GAAG,CAAA,KAAA,EAAQ,YAAY,CAAA,CAAA,CAAG;gBACtC;;AAEF,YAAA,KAAK,aAAa,CAAC,GAAG,EAAE;AACtB,gBAAA,YAAY,GAAG,CAAA,IAAA,EAAO,YAAY,CAAA,CAAA,CAAG;gBACrC;;YAEF,SAAS;AACP,gBAAA,YAAY,GAAG,CAAA,CAAA,EAAI,YAAY,CAAA,CAAE;gBACjC;;;;AAKN,IAAA,OAAO,YAAY;AACrB;;;;"}
@@ -1,5 +1,4 @@
1
- import { DATE_TYPES } from '../../constants/date.js';
2
- import '../../constants/environment.js';
1
+ import { DATE_TYPES } from '../../constants/index.js';
3
2
 
4
3
  function getDateByRules(rules, date = new Date()) {
5
4
  let result = new Date(date);
@@ -1 +1 @@
1
- {"version":3,"file":"get-date-by-rules.js","sources":["../../../../src/lib/date/get-date-by-rules.ts"],"sourcesContent":["import { DATE_TYPES } from \"../../constants\";\nimport { type DateGetterRule, type DateType } from \"../../types\";\n\nexport function getDateByRules(rules: DateGetterRule[], date: Date = new Date()) {\n let result = new Date(date);\n for (const rule of rules) {\n result = getDate(rule.increment, rule.type, result);\n }\n\n return result;\n}\n\nfunction getDate(increment: number, type: DateType, date: Date = new Date()) {\n const result = new Date(date);\n switch (type) {\n case DATE_TYPES.Days: {\n result.setDate(result.getDate() + increment);\n\n return result;\n }\n case DATE_TYPES.Months: {\n result.setMonth(result.getMonth() + increment);\n\n return result;\n }\n case DATE_TYPES.Years: {\n result.setFullYear(result.getFullYear() + increment);\n\n return result;\n }\n case DATE_TYPES.Seconds: {\n result.setSeconds(result.getSeconds() + increment);\n\n return result;\n }\n case DATE_TYPES.Minutes: {\n result.setMinutes(result.getMinutes() + increment);\n\n return result;\n }\n case DATE_TYPES.Hours: {\n result.setHours(result.getHours() + increment);\n\n return result;\n }\n default:\n return result;\n }\n}\n"],"names":[],"mappings":";;;AAGM,SAAU,cAAc,CAAC,KAAuB,EAAE,IAAa,GAAA,IAAI,IAAI,EAAE,EAAA;AAC7E,IAAA,IAAI,MAAM,GAAG,IAAI,IAAI,CAAC,IAAI,CAAC;AAC3B,IAAA,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE;AACxB,QAAA,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC;;AAGrD,IAAA,OAAO,MAAM;AACf;AAEA,SAAS,OAAO,CAAC,SAAiB,EAAE,IAAc,EAAE,IAAA,GAAa,IAAI,IAAI,EAAE,EAAA;AACzE,IAAA,MAAM,MAAM,GAAG,IAAI,IAAI,CAAC,IAAI,CAAC;IAC7B,QAAQ,IAAI;AACV,QAAA,KAAK,UAAU,CAAC,IAAI,EAAE;YACpB,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,OAAO,EAAE,GAAG,SAAS,CAAC;AAE5C,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,MAAM,EAAE;YACtB,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,EAAE,GAAG,SAAS,CAAC;AAE9C,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,KAAK,EAAE;YACrB,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,WAAW,EAAE,GAAG,SAAS,CAAC;AAEpD,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,OAAO,EAAE;YACvB,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,EAAE,GAAG,SAAS,CAAC;AAElD,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,OAAO,EAAE;YACvB,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,EAAE,GAAG,SAAS,CAAC;AAElD,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,KAAK,EAAE;YACrB,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,EAAE,GAAG,SAAS,CAAC;AAE9C,YAAA,OAAO,MAAM;;AAEf,QAAA;AACE,YAAA,OAAO,MAAM;;AAEnB;;;;"}
1
+ {"version":3,"file":"get-date-by-rules.js","sources":["../../../../src/lib/date/get-date-by-rules.ts"],"sourcesContent":["import { DATE_TYPES } from \"../../constants\";\nimport { type DateGetterRule, type DateType } from \"../../types\";\n\nexport function getDateByRules(rules: DateGetterRule[], date: Date = new Date()) {\n let result = new Date(date);\n for (const rule of rules) {\n result = getDate(rule.increment, rule.type, result);\n }\n\n return result;\n}\n\nfunction getDate(increment: number, type: DateType, date: Date = new Date()) {\n const result = new Date(date);\n switch (type) {\n case DATE_TYPES.Days: {\n result.setDate(result.getDate() + increment);\n\n return result;\n }\n case DATE_TYPES.Months: {\n result.setMonth(result.getMonth() + increment);\n\n return result;\n }\n case DATE_TYPES.Years: {\n result.setFullYear(result.getFullYear() + increment);\n\n return result;\n }\n case DATE_TYPES.Seconds: {\n result.setSeconds(result.getSeconds() + increment);\n\n return result;\n }\n case DATE_TYPES.Minutes: {\n result.setMinutes(result.getMinutes() + increment);\n\n return result;\n }\n case DATE_TYPES.Hours: {\n result.setHours(result.getHours() + increment);\n\n return result;\n }\n default:\n return result;\n }\n}\n"],"names":[],"mappings":";;AAGM,SAAU,cAAc,CAAC,KAAuB,EAAE,IAAa,GAAA,IAAI,IAAI,EAAE,EAAA;AAC7E,IAAA,IAAI,MAAM,GAAG,IAAI,IAAI,CAAC,IAAI,CAAC;AAC3B,IAAA,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE;AACxB,QAAA,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,EAAE,MAAM,CAAC;;AAGrD,IAAA,OAAO,MAAM;AACf;AAEA,SAAS,OAAO,CAAC,SAAiB,EAAE,IAAc,EAAE,IAAA,GAAa,IAAI,IAAI,EAAE,EAAA;AACzE,IAAA,MAAM,MAAM,GAAG,IAAI,IAAI,CAAC,IAAI,CAAC;IAC7B,QAAQ,IAAI;AACV,QAAA,KAAK,UAAU,CAAC,IAAI,EAAE;YACpB,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,OAAO,EAAE,GAAG,SAAS,CAAC;AAE5C,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,MAAM,EAAE;YACtB,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,EAAE,GAAG,SAAS,CAAC;AAE9C,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,KAAK,EAAE;YACrB,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC,WAAW,EAAE,GAAG,SAAS,CAAC;AAEpD,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,OAAO,EAAE;YACvB,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,EAAE,GAAG,SAAS,CAAC;AAElD,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,OAAO,EAAE;YACvB,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,UAAU,EAAE,GAAG,SAAS,CAAC;AAElD,YAAA,OAAO,MAAM;;AAEf,QAAA,KAAK,UAAU,CAAC,KAAK,EAAE;YACrB,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,EAAE,GAAG,SAAS,CAAC;AAE9C,YAAA,OAAO,MAAM;;AAEf,QAAA;AACE,YAAA,OAAO,MAAM;;AAEnB;;;;"}
@@ -1,6 +1,5 @@
1
1
  import dayjs from 'dayjs';
2
2
  import yesterdayPlugin from 'dayjs/plugin/isYesterday';
3
- import '../../constants/environment.js';
4
3
 
5
4
  dayjs.extend(yesterdayPlugin);
6
5
  function isYesterday(date) {
@@ -1 +1 @@
1
- {"version":3,"file":"is-yesterday.js","sources":["../../../../src/lib/date/is-yesterday.ts"],"sourcesContent":["import dayjs from \"dayjs\";\nimport yesterdayPlugin from \"dayjs/plugin/isYesterday\";\nimport { type Maybe } from \"../../types\";\n\ndayjs.extend(yesterdayPlugin);\n\nexport function isYesterday(date: Maybe<string | Date | number>) {\n try {\n return dayjs(date).isYesterday();\n } catch {\n return false;\n }\n}\n"],"names":[],"mappings":";;;;AAIA,KAAK,CAAC,MAAM,CAAC,eAAe,CAAC;AAEvB,SAAU,WAAW,CAAC,IAAmC,EAAA;AAC7D,IAAA,IAAI;AACF,QAAA,OAAO,KAAK,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE;;AAChC,IAAA,MAAM;AACN,QAAA,OAAO,KAAK;;AAEhB;;;;"}
1
+ {"version":3,"file":"is-yesterday.js","sources":["../../../../src/lib/date/is-yesterday.ts"],"sourcesContent":["import dayjs from \"dayjs\";\nimport yesterdayPlugin from \"dayjs/plugin/isYesterday\";\nimport { type Maybe } from \"../../types\";\n\ndayjs.extend(yesterdayPlugin);\n\nexport function isYesterday(date: Maybe<string | Date | number>) {\n try {\n return dayjs(date).isYesterday();\n } catch {\n return false;\n }\n}\n"],"names":[],"mappings":";;;AAIA,KAAK,CAAC,MAAM,CAAC,eAAe,CAAC;AAEvB,SAAU,WAAW,CAAC,IAAmC,EAAA;AAC7D,IAAA,IAAI;AACF,QAAA,OAAO,KAAK,CAAC,IAAI,CAAC,CAAC,WAAW,EAAE;;AAChC,IAAA,MAAM;AACN,QAAA,OAAO,KAAK;;AAEhB;;;;"}
@@ -1,23 +1,14 @@
1
1
  import { isPrimitive } from '../typings/is-primitive.js';
2
2
  import { type } from './type.js';
3
3
 
4
- /* eslint-disable @typescript-eslint/no-non-null-assertion */
5
- function cloneDeep(value, map) {
6
- map ??= new Map();
7
- // this avoids the slower switch with a quick if decision removing some milliseconds in each run.
4
+ function cloneDeep(value) {
8
5
  if (isPrimitive(value)) {
9
6
  return value;
10
7
  }
11
8
  function copy(copiedValue) {
12
- // Check for circular and same references on the object graph and return its corresponding clone.
13
- const cachedCopy = map.get(value);
14
- if (cachedCopy) {
15
- return cachedCopy;
16
- }
17
- map.set(value, copiedValue);
18
9
  for (const key in value) {
19
10
  if (Object.hasOwn(value, key)) {
20
- copiedValue[key] = cloneDeep(value[key], map);
11
+ copiedValue[key] = cloneDeep(value[key]);
21
12
  }
22
13
  }
23
14
  return copiedValue;
@@ -1 +1 @@
1
- {"version":3,"file":"clone-deep.js","sources":["../../../../src/lib/lodash/clone-deep.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-non-null-assertion */\nimport { isPrimitive } from \"../typings\";\nimport { type } from \"./type\";\n\nexport function cloneDeep(value: unknown, map?: Map<unknown, unknown>) {\n map ??= new Map();\n\n // this avoids the slower switch with a quick if decision removing some milliseconds in each run.\n if (isPrimitive(value)) {\n return value;\n }\n\n function copy(copiedValue: object) {\n // Check for circular and same references on the object graph and return its corresponding clone.\n const cachedCopy = map!.get(value);\n\n if (cachedCopy) {\n return cachedCopy;\n }\n\n map!.set(value, copiedValue);\n\n for (const key in value as object) {\n if (Object.hasOwn(value as object, key)) {\n (copiedValue as Record<string, unknown>)[key] = cloneDeep(\n (value as Record<string, unknown>)[key],\n map,\n );\n }\n }\n\n return copiedValue;\n }\n\n switch (type(value)) {\n case \"Object\":\n return copy(Object.create(Object.getPrototypeOf(value) as object) as object);\n case \"Array\":\n return copy(Array((value as unknown[]).length));\n case \"Date\":\n return new Date((value as Date).valueOf());\n case \"RegExp\":\n return cloneRegExp(value as RegExp);\n case \"Int8Array\":\n case \"Uint8Array\":\n case \"Uint8ClampedArray\":\n case \"Int16Array\":\n case \"Uint16Array\":\n case \"Int32Array\":\n case \"Uint32Array\":\n case \"Float32Array\":\n case \"Float64Array\":\n case \"BigInt64Array\":\n case \"BigUint64Array\":\n return (value as Int8Array).slice();\n default:\n return value;\n }\n}\n\nfunction cloneRegExp(pattern: RegExp) {\n return new RegExp(\n pattern.source,\n pattern.flags\n ? pattern.flags\n : (pattern.global ? \"g\" : \"\") +\n (pattern.ignoreCase ? \"i\" : \"\") +\n (pattern.multiline ? \"m\" : \"\") +\n (pattern.sticky ? \"y\" : \"\") +\n (pattern.unicode ? \"u\" : \"\") +\n (pattern.dotAll ? \"s\" : \"\"),\n );\n}\n"],"names":[],"mappings":";;;AAAA;AAIgB,SAAA,SAAS,CAAC,KAAc,EAAE,GAA2B,EAAA;AACnE,IAAA,GAAG,KAAK,IAAI,GAAG,EAAE;;AAGjB,IAAA,IAAI,WAAW,CAAC,KAAK,CAAC,EAAE;AACtB,QAAA,OAAO,KAAK;;IAGd,SAAS,IAAI,CAAC,WAAmB,EAAA;;QAE/B,MAAM,UAAU,GAAG,GAAI,CAAC,GAAG,CAAC,KAAK,CAAC;QAElC,IAAI,UAAU,EAAE;AACd,YAAA,OAAO,UAAU;;AAGnB,QAAA,GAAI,CAAC,GAAG,CAAC,KAAK,EAAE,WAAW,CAAC;AAE5B,QAAA,KAAK,MAAM,GAAG,IAAI,KAAe,EAAE;YACjC,IAAI,MAAM,CAAC,MAAM,CAAC,KAAe,EAAE,GAAG,CAAC,EAAE;AACtC,gBAAA,WAAuC,CAAC,GAAG,CAAC,GAAG,SAAS,CACtD,KAAiC,CAAC,GAAG,CAAC,EACvC,GAAG,CACJ;;;AAIL,QAAA,OAAO,WAAW;;AAGpB,IAAA,QAAQ,IAAI,CAAC,KAAK,CAAC;AACjB,QAAA,KAAK,QAAQ;AACX,YAAA,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,cAAc,CAAC,KAAK,CAAW,CAAW,CAAC;AAC9E,QAAA,KAAK,OAAO;YACV,OAAO,IAAI,CAAC,KAAK,CAAE,KAAmB,CAAC,MAAM,CAAC,CAAC;AACjD,QAAA,KAAK,MAAM;YACT,OAAO,IAAI,IAAI,CAAE,KAAc,CAAC,OAAO,EAAE,CAAC;AAC5C,QAAA,KAAK,QAAQ;AACX,YAAA,OAAO,WAAW,CAAC,KAAe,CAAC;AACrC,QAAA,KAAK,WAAW;AAChB,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,mBAAmB;AACxB,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,aAAa;AAClB,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,aAAa;AAClB,QAAA,KAAK,cAAc;AACnB,QAAA,KAAK,cAAc;AACnB,QAAA,KAAK,eAAe;AACpB,QAAA,KAAK,gBAAgB;AACnB,YAAA,OAAQ,KAAmB,CAAC,KAAK,EAAE;AACrC,QAAA;AACE,YAAA,OAAO,KAAK;;AAElB;AAEA,SAAS,WAAW,CAAC,OAAe,EAAA;IAClC,OAAO,IAAI,MAAM,CACf,OAAO,CAAC,MAAM,EACd,OAAO,CAAC;UACJ,OAAO,CAAC;AACV,UAAE,CAAC,OAAO,CAAC,MAAM,GAAG,GAAG,GAAG,EAAE;aACzB,OAAO,CAAC,UAAU,GAAG,GAAG,GAAG,EAAE,CAAC;aAC9B,OAAO,CAAC,SAAS,GAAG,GAAG,GAAG,EAAE,CAAC;aAC7B,OAAO,CAAC,MAAM,GAAG,GAAG,GAAG,EAAE,CAAC;aAC1B,OAAO,CAAC,OAAO,GAAG,GAAG,GAAG,EAAE,CAAC;AAC5B,aAAC,OAAO,CAAC,MAAM,GAAG,GAAG,GAAG,EAAE,CAAC,CAChC;AACH;;;;"}
1
+ {"version":3,"file":"clone-deep.js","sources":["../../../../src/lib/lodash/clone-deep.ts"],"sourcesContent":["import { isPrimitive } from \"../typings\";\nimport { type } from \"./type\";\n\nexport function cloneDeep<T>(value: T): T {\n if (isPrimitive(value)) {\n return value;\n }\n\n function copy(copiedValue: object) {\n for (const key in value as object) {\n if (Object.hasOwn(value as object, key)) {\n (copiedValue as Record<string, unknown>)[key] = cloneDeep(\n (value as Record<string, unknown>)[key],\n );\n }\n }\n\n return copiedValue;\n }\n\n switch (type(value)) {\n case \"Object\":\n return copy(Object.create(Object.getPrototypeOf(value) as object) as object) as T;\n case \"Array\":\n return copy(Array((value as unknown[]).length)) as T;\n case \"Date\":\n return new Date((value as Date).valueOf()) as T;\n case \"RegExp\":\n return cloneRegExp(value as RegExp) as T;\n case \"Int8Array\":\n case \"Uint8Array\":\n case \"Uint8ClampedArray\":\n case \"Int16Array\":\n case \"Uint16Array\":\n case \"Int32Array\":\n case \"Uint32Array\":\n case \"Float32Array\":\n case \"Float64Array\":\n case \"BigInt64Array\":\n case \"BigUint64Array\":\n return (value as Int8Array).slice() as T;\n default:\n return value;\n }\n}\n\nfunction cloneRegExp(pattern: RegExp) {\n return new RegExp(\n pattern.source,\n pattern.flags\n ? pattern.flags\n : (pattern.global ? \"g\" : \"\") +\n (pattern.ignoreCase ? \"i\" : \"\") +\n (pattern.multiline ? \"m\" : \"\") +\n (pattern.sticky ? \"y\" : \"\") +\n (pattern.unicode ? \"u\" : \"\") +\n (pattern.dotAll ? \"s\" : \"\"),\n );\n}\n"],"names":[],"mappings":";;;AAGM,SAAU,SAAS,CAAI,KAAQ,EAAA;AACnC,IAAA,IAAI,WAAW,CAAC,KAAK,CAAC,EAAE;AACtB,QAAA,OAAO,KAAK;;IAGd,SAAS,IAAI,CAAC,WAAmB,EAAA;AAC/B,QAAA,KAAK,MAAM,GAAG,IAAI,KAAe,EAAE;YACjC,IAAI,MAAM,CAAC,MAAM,CAAC,KAAe,EAAE,GAAG,CAAC,EAAE;gBACtC,WAAuC,CAAC,GAAG,CAAC,GAAG,SAAS,CACtD,KAAiC,CAAC,GAAG,CAAC,CACxC;;;AAIL,QAAA,OAAO,WAAW;;AAGpB,IAAA,QAAQ,IAAI,CAAC,KAAK,CAAC;AACjB,QAAA,KAAK,QAAQ;AACX,YAAA,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,cAAc,CAAC,KAAK,CAAW,CAAW,CAAM;AACnF,QAAA,KAAK,OAAO;YACV,OAAO,IAAI,CAAC,KAAK,CAAE,KAAmB,CAAC,MAAM,CAAC,CAAM;AACtD,QAAA,KAAK,MAAM;YACT,OAAO,IAAI,IAAI,CAAE,KAAc,CAAC,OAAO,EAAE,CAAM;AACjD,QAAA,KAAK,QAAQ;AACX,YAAA,OAAO,WAAW,CAAC,KAAe,CAAM;AAC1C,QAAA,KAAK,WAAW;AAChB,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,mBAAmB;AACxB,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,aAAa;AAClB,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,aAAa;AAClB,QAAA,KAAK,cAAc;AACnB,QAAA,KAAK,cAAc;AACnB,QAAA,KAAK,eAAe;AACpB,QAAA,KAAK,gBAAgB;AACnB,YAAA,OAAQ,KAAmB,CAAC,KAAK,EAAO;AAC1C,QAAA;AACE,YAAA,OAAO,KAAK;;AAElB;AAEA,SAAS,WAAW,CAAC,OAAe,EAAA;IAClC,OAAO,IAAI,MAAM,CACf,OAAO,CAAC,MAAM,EACd,OAAO,CAAC;UACJ,OAAO,CAAC;AACV,UAAE,CAAC,OAAO,CAAC,MAAM,GAAG,GAAG,GAAG,EAAE;aACzB,OAAO,CAAC,UAAU,GAAG,GAAG,GAAG,EAAE,CAAC;aAC9B,OAAO,CAAC,SAAS,GAAG,GAAG,GAAG,EAAE,CAAC;aAC7B,OAAO,CAAC,MAAM,GAAG,GAAG,GAAG,EAAE,CAAC;aAC1B,OAAO,CAAC,OAAO,GAAG,GAAG,GAAG,EAAE,CAAC;AAC5B,aAAC,OAAO,CAAC,MAAM,GAAG,GAAG,GAAG,EAAE,CAAC,CAChC;AACH;;;;"}
@@ -1,5 +1,4 @@
1
- /* eslint-disable @typescript-eslint/no-explicit-any */
2
- function debounce({ delay }, func) {
1
+ function debounce(func, { delay }) {
3
2
  let timer;
4
3
  let active = true;
5
4
  const debounced = (...args) => {
@@ -1 +1 @@
1
- {"version":3,"file":"debounce.js","sources":["../../../../src/lib/lodash/debounce.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nexport function debounce<TArgs extends any[]>(\n { delay }: { delay: number },\n func: (...args: TArgs) => any,\n) {\n let timer: NodeJS.Timeout | undefined;\n let active = true;\n\n const debounced = (...args: TArgs) => {\n if (active) {\n clearTimeout(timer);\n timer = setTimeout(() => {\n if (active) {\n func(...args);\n }\n timer = undefined;\n }, delay);\n } else {\n func(...args);\n }\n };\n debounced.isPending = () => {\n return timer !== undefined;\n };\n debounced.cancel = () => {\n active = false;\n };\n debounced.flush = (...args: TArgs) => {\n func(...args);\n };\n\n return debounced;\n}\n"],"names":[],"mappings":"AAAA;SACgB,QAAQ,CACtB,EAAE,KAAK,EAAqB,EAC5B,IAA6B,EAAA;AAE7B,IAAA,IAAI,KAAiC;IACrC,IAAI,MAAM,GAAG,IAAI;AAEjB,IAAA,MAAM,SAAS,GAAG,CAAC,GAAG,IAAW,KAAI;QACnC,IAAI,MAAM,EAAE;YACV,YAAY,CAAC,KAAK,CAAC;AACnB,YAAA,KAAK,GAAG,UAAU,CAAC,MAAK;gBACtB,IAAI,MAAM,EAAE;AACV,oBAAA,IAAI,CAAC,GAAG,IAAI,CAAC;;gBAEf,KAAK,GAAG,SAAS;aAClB,EAAE,KAAK,CAAC;;aACJ;AACL,YAAA,IAAI,CAAC,GAAG,IAAI,CAAC;;AAEjB,KAAC;AACD,IAAA,SAAS,CAAC,SAAS,GAAG,MAAK;QACzB,OAAO,KAAK,KAAK,SAAS;AAC5B,KAAC;AACD,IAAA,SAAS,CAAC,MAAM,GAAG,MAAK;QACtB,MAAM,GAAG,KAAK;AAChB,KAAC;AACD,IAAA,SAAS,CAAC,KAAK,GAAG,CAAC,GAAG,IAAW,KAAI;AACnC,QAAA,IAAI,CAAC,GAAG,IAAI,CAAC;AACf,KAAC;AAED,IAAA,OAAO,SAAS;AAClB;;;;"}
1
+ {"version":3,"file":"debounce.js","sources":["../../../../src/lib/lodash/debounce.ts"],"sourcesContent":["export function debounce<TArgs extends unknown[]>(\n func: (...args: TArgs) => unknown,\n { delay }: { delay: number },\n) {\n let timer: NodeJS.Timeout | undefined;\n let active = true;\n\n const debounced = (...args: TArgs) => {\n if (active) {\n clearTimeout(timer);\n timer = setTimeout(() => {\n if (active) {\n func(...args);\n }\n timer = undefined;\n }, delay);\n } else {\n func(...args);\n }\n };\n debounced.isPending = () => {\n return timer !== undefined;\n };\n debounced.cancel = () => {\n active = false;\n };\n debounced.flush = (...args: TArgs) => {\n func(...args);\n };\n\n return debounced;\n}\n"],"names":[],"mappings":"SAAgB,QAAQ,CACtB,IAAiC,EACjC,EAAE,KAAK,EAAqB,EAAA;AAE5B,IAAA,IAAI,KAAiC;IACrC,IAAI,MAAM,GAAG,IAAI;AAEjB,IAAA,MAAM,SAAS,GAAG,CAAC,GAAG,IAAW,KAAI;QACnC,IAAI,MAAM,EAAE;YACV,YAAY,CAAC,KAAK,CAAC;AACnB,YAAA,KAAK,GAAG,UAAU,CAAC,MAAK;gBACtB,IAAI,MAAM,EAAE;AACV,oBAAA,IAAI,CAAC,GAAG,IAAI,CAAC;;gBAEf,KAAK,GAAG,SAAS;aAClB,EAAE,KAAK,CAAC;;aACJ;AACL,YAAA,IAAI,CAAC,GAAG,IAAI,CAAC;;AAEjB,KAAC;AACD,IAAA,SAAS,CAAC,SAAS,GAAG,MAAK;QACzB,OAAO,KAAK,KAAK,SAAS;AAC5B,KAAC;AACD,IAAA,SAAS,CAAC,MAAM,GAAG,MAAK;QACtB,MAAM,GAAG,KAAK;AAChB,KAAC;AACD,IAAA,SAAS,CAAC,KAAK,GAAG,CAAC,GAAG,IAAW,KAAI;AACnC,QAAA,IAAI,CAAC,GAAG,IAAI,CAAC;AACf,KAAC;AAED,IAAA,OAAO,SAAS;AAClB;;;;"}
@@ -1,5 +1,5 @@
1
1
  /* eslint-disable @typescript-eslint/no-explicit-any */
2
- function throttle({ interval }, func) {
2
+ function throttle(func, { interval }) {
3
3
  let ready = true;
4
4
  let timer;
5
5
  const throttled = (...args) => {
@@ -1 +1 @@
1
- {"version":3,"file":"throttle.js","sources":["../../../../src/lib/lodash/throttle.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nexport function throttle<TArgs extends any[]>(\n { interval }: { interval: number },\n func: (...args: TArgs) => any,\n) {\n let ready = true;\n let timer: NodeJS.Timeout | undefined;\n\n const throttled = (...args: TArgs) => {\n if (!ready) return;\n func(...args);\n ready = false;\n timer = setTimeout(() => {\n ready = true;\n timer = undefined;\n }, interval);\n };\n\n throttled.isThrottled = () => {\n return timer !== undefined;\n };\n\n return throttled;\n}\n"],"names":[],"mappings":"AAAA;SACgB,QAAQ,CACtB,EAAE,QAAQ,EAAwB,EAClC,IAA6B,EAAA;IAE7B,IAAI,KAAK,GAAG,IAAI;AAChB,IAAA,IAAI,KAAiC;AAErC,IAAA,MAAM,SAAS,GAAG,CAAC,GAAG,IAAW,KAAI;AACnC,QAAA,IAAI,CAAC,KAAK;YAAE;AACZ,QAAA,IAAI,CAAC,GAAG,IAAI,CAAC;QACb,KAAK,GAAG,KAAK;AACb,QAAA,KAAK,GAAG,UAAU,CAAC,MAAK;YACtB,KAAK,GAAG,IAAI;YACZ,KAAK,GAAG,SAAS;SAClB,EAAE,QAAQ,CAAC;AACd,KAAC;AAED,IAAA,SAAS,CAAC,WAAW,GAAG,MAAK;QAC3B,OAAO,KAAK,KAAK,SAAS;AAC5B,KAAC;AAED,IAAA,OAAO,SAAS;AAClB;;;;"}
1
+ {"version":3,"file":"throttle.js","sources":["../../../../src/lib/lodash/throttle.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nexport function throttle<TArgs extends any[]>(\n func: (...args: TArgs) => any,\n { interval }: { interval: number },\n) {\n let ready = true;\n let timer: NodeJS.Timeout | undefined;\n\n const throttled = (...args: TArgs) => {\n if (!ready) return;\n func(...args);\n ready = false;\n timer = setTimeout(() => {\n ready = true;\n timer = undefined;\n }, interval);\n };\n\n throttled.isThrottled = () => {\n return timer !== undefined;\n };\n\n return throttled;\n}\n"],"names":[],"mappings":"AAAA;SACgB,QAAQ,CACtB,IAA6B,EAC7B,EAAE,QAAQ,EAAwB,EAAA;IAElC,IAAI,KAAK,GAAG,IAAI;AAChB,IAAA,IAAI,KAAiC;AAErC,IAAA,MAAM,SAAS,GAAG,CAAC,GAAG,IAAW,KAAI;AACnC,QAAA,IAAI,CAAC,KAAK;YAAE;AACZ,QAAA,IAAI,CAAC,GAAG,IAAI,CAAC;QACb,KAAK,GAAG,KAAK;AACb,QAAA,KAAK,GAAG,UAAU,CAAC,MAAK;YACtB,KAAK,GAAG,IAAI;YACZ,KAAK,GAAG,SAAS;SAClB,EAAE,QAAQ,CAAC;AACd,KAAC;AAED,IAAA,SAAS,CAAC,WAAW,GAAG,MAAK;QAC3B,OAAO,KAAK,KAAK,SAAS;AAC5B,KAAC;AAED,IAAA,OAAO,SAAS;AAClB;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"build-query-string.js","sources":["../../../../src/lib/utils/build-query-string.ts"],"sourcesContent":["import type { ParamsType } from \"../../types\";\nimport { isArray, isObject } from \"../typings\";\n\nexport function buildQueryString(params: ParamsType): string {\n const queryString: string[] = [];\n\n for (const [key, value] of Object.entries(params)) {\n if (isObject(value) || value == undefined) continue;\n\n if (isArray(value)) {\n for (const item of value) {\n if (item != undefined && !isObject(item))\n queryString.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(item))}`);\n }\n } else {\n queryString.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);\n }\n }\n\n return queryString.join(\"&\");\n}\n"],"names":[],"mappings":";;;AAGM,SAAU,gBAAgB,CAAC,MAAkB,EAAA;IACjD,MAAM,WAAW,GAAa,EAAE;AAEhC,IAAA,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE;AACjD,QAAA,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,KAAK,IAAI,SAAS;YAAE;AAE3C,QAAA,IAAI,OAAO,CAAC,KAAK,CAAC,EAAE;AAClB,YAAA,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE;gBACxB,IAAI,IAAI,IAAI,SAAS,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC;AACtC,oBAAA,WAAW,CAAC,IAAI,CAAC,GAAG,kBAAkB,CAAC,GAAG,CAAC,CAAA,CAAA,EAAI,kBAAkB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAA,CAAE,CAAC;;;aAEjF;AACL,YAAA,WAAW,CAAC,IAAI,CAAC,GAAG,kBAAkB,CAAC,GAAG,CAAC,CAAA,CAAA,EAAI,kBAAkB,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAA,CAAE,CAAC;;;AAIvF,IAAA,OAAO,WAAW,CAAC,IAAI,CAAC,GAAG,CAAC;AAC9B;;;;"}
1
+ {"version":3,"file":"build-query-string.js","sources":["../../../../src/lib/utils/build-query-string.ts"],"sourcesContent":["import type { RequestQuery } from \"../../api\";\nimport { isArray, isObject } from \"../typings\";\n\nexport function buildQueryString(params: RequestQuery): string {\n const queryString: string[] = [];\n\n for (const [key, value] of Object.entries(params)) {\n if (isObject(value) || value == undefined) continue;\n\n if (isArray(value)) {\n for (const item of value) {\n if (item != undefined && !isObject(item))\n queryString.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(item))}`);\n }\n } else {\n queryString.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);\n }\n }\n\n return queryString.join(\"&\");\n}\n"],"names":[],"mappings":";;;AAGM,SAAU,gBAAgB,CAAC,MAAoB,EAAA;IACnD,MAAM,WAAW,GAAa,EAAE;AAEhC,IAAA,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE;AACjD,QAAA,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,KAAK,IAAI,SAAS;YAAE;AAE3C,QAAA,IAAI,OAAO,CAAC,KAAK,CAAC,EAAE;AAClB,YAAA,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE;gBACxB,IAAI,IAAI,IAAI,SAAS,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC;AACtC,oBAAA,WAAW,CAAC,IAAI,CAAC,GAAG,kBAAkB,CAAC,GAAG,CAAC,CAAA,CAAA,EAAI,kBAAkB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAA,CAAE,CAAC;;;aAEjF;AACL,YAAA,WAAW,CAAC,IAAI,CAAC,GAAG,kBAAkB,CAAC,GAAG,CAAC,CAAA,CAAA,EAAI,kBAAkB,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAA,CAAE,CAAC;;;AAIvF,IAAA,OAAO,WAAW,CAAC,IAAI,CAAC,GAAG,CAAC;AAC9B;;;;"}
@@ -1,6 +1,6 @@
1
1
  import { buildQueryString } from './build-query-string.js';
2
2
 
3
- function createURLWithParams(options) {
3
+ function createURLWithQueries(options) {
4
4
  const url = options.baseURL;
5
5
  if (!options.params) {
6
6
  return url;
@@ -9,5 +9,5 @@ function createURLWithParams(options) {
9
9
  return `${url}?${queryString}`;
10
10
  }
11
11
 
12
- export { createURLWithParams };
13
- //# sourceMappingURL=create-url-with-params.js.map
12
+ export { createURLWithQueries };
13
+ //# sourceMappingURL=create-url-with-queries.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create-url-with-queries.js","sources":["../../../../src/lib/utils/create-url-with-queries.ts"],"sourcesContent":["import type { RequestQuery } from \"../../api\";\nimport { buildQueryString } from \"./build-query-string\";\n\ntype CreateURLOptionsInterface = {\n baseURL: string;\n params?: RequestQuery;\n};\n\nexport function createURLWithQueries(options: CreateURLOptionsInterface): string {\n const url = options.baseURL;\n\n if (!options.params) {\n return url;\n }\n\n const queryString = buildQueryString(options.params);\n\n return `${url}?${queryString}`;\n}\n"],"names":[],"mappings":";;AAQM,SAAU,oBAAoB,CAAC,OAAkC,EAAA;AACrE,IAAA,MAAM,GAAG,GAAG,OAAO,CAAC,OAAO;AAE3B,IAAA,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE;AACnB,QAAA,OAAO,GAAG;;IAGZ,MAAM,WAAW,GAAG,gBAAgB,CAAC,OAAO,CAAC,MAAM,CAAC;AAEpD,IAAA,OAAO,CAAG,EAAA,GAAG,CAAI,CAAA,EAAA,WAAW,EAAE;AAChC;;;;"}
@@ -1,5 +1,4 @@
1
- import '../../constants/environment.js';
2
- import { FIELD_TYPES } from '../../constants/fields.js';
1
+ import { FIELD_TYPES } from '../../constants/index.js';
3
2
  import 'dayjs';
4
3
  import '../date/is-today.js';
5
4
  import '../date/is-tomorrow.js';
@@ -1 +1 @@
1
- {"version":3,"file":"field-view-format.js","sources":["../../../../src/lib/utils/field-view-format.ts"],"sourcesContent":["import { FIELD_TYPES } from \"../../constants\";\nimport type { FieldType } from \"../../types\";\nimport { dateFormat } from \"../date\";\nimport { isArray, isBoolean, isDate, isNumber, isString } from \"../typings\";\nimport { transformToNumber } from \"./transform-to-number\";\n\nexport function fieldViewFormat(field: unknown, type: FieldType = \"string\") {\n switch (type) {\n case FIELD_TYPES.Array: {\n return isArray(field) ? field.join(\", \") : \"\";\n }\n case FIELD_TYPES.Date: {\n return isString(field) || isNumber(field) || isDate(field)\n ? dateFormat(field, \"DD.MM.YYYY\")\n : \"\";\n }\n case FIELD_TYPES.DateTime: {\n return isString(field) || isNumber(field) || isDate(field)\n ? dateFormat(field, \"DD.MM.YYYY HH:mm\")\n : \"\";\n }\n case FIELD_TYPES.Number: {\n return isString(field) || isNumber(field) || isBoolean(field)\n ? String(transformToNumber(field))\n : \"\";\n }\n case FIELD_TYPES.String: {\n return isString(field) || isNumber(field) || isBoolean(field) ? String(field) : \"\";\n }\n case FIELD_TYPES.Time: {\n return isString(field) || isNumber(field) || isDate(field) ? dateFormat(field, \"HH:mm\") : \"\";\n }\n default: {\n return isString(field) || isNumber(field) || isBoolean(field) ? String(field) : \"\";\n }\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;SAMgB,eAAe,CAAC,KAAc,EAAE,OAAkB,QAAQ,EAAA;IACxE,QAAQ,IAAI;AACV,QAAA,KAAK,WAAW,CAAC,KAAK,EAAE;AACtB,YAAA,OAAO,OAAO,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE;;AAE/C,QAAA,KAAK,WAAW,CAAC,IAAI,EAAE;AACrB,YAAA,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK;AACvD,kBAAE,UAAU,CAAC,KAAK,EAAE,YAAY;kBAC9B,EAAE;;AAER,QAAA,KAAK,WAAW,CAAC,QAAQ,EAAE;AACzB,YAAA,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK;AACvD,kBAAE,UAAU,CAAC,KAAK,EAAE,kBAAkB;kBACpC,EAAE;;AAER,QAAA,KAAK,WAAW,CAAC,MAAM,EAAE;AACvB,YAAA,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK;AAC1D,kBAAE,MAAM,CAAC,iBAAiB,CAAC,KAAK,CAAC;kBAC/B,EAAE;;AAER,QAAA,KAAK,WAAW,CAAC,MAAM,EAAE;YACvB,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE;;AAEpF,QAAA,KAAK,WAAW,CAAC,IAAI,EAAE;YACrB,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK,CAAC,GAAG,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,GAAG,EAAE;;QAE9F,SAAS;YACP,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE;;;AAGxF;;;;"}
1
+ {"version":3,"file":"field-view-format.js","sources":["../../../../src/lib/utils/field-view-format.ts"],"sourcesContent":["import { FIELD_TYPES } from \"../../constants\";\nimport type { FieldType } from \"../../types\";\nimport { dateFormat } from \"../date\";\nimport { isArray, isBoolean, isDate, isNumber, isString } from \"../typings\";\nimport { transformToNumber } from \"./transform-to-number\";\n\nexport function fieldViewFormat(field: unknown, type: FieldType = \"string\") {\n switch (type) {\n case FIELD_TYPES.Array: {\n return isArray(field) ? field.join(\", \") : \"\";\n }\n case FIELD_TYPES.Date: {\n return isString(field) || isNumber(field) || isDate(field)\n ? dateFormat(field, \"DD.MM.YYYY\")\n : \"\";\n }\n case FIELD_TYPES.DateTime: {\n return isString(field) || isNumber(field) || isDate(field)\n ? dateFormat(field, \"DD.MM.YYYY HH:mm\")\n : \"\";\n }\n case FIELD_TYPES.Number: {\n return isString(field) || isNumber(field) || isBoolean(field)\n ? String(transformToNumber(field))\n : \"\";\n }\n case FIELD_TYPES.String: {\n return isString(field) || isNumber(field) || isBoolean(field) ? String(field) : \"\";\n }\n case FIELD_TYPES.Time: {\n return isString(field) || isNumber(field) || isDate(field) ? dateFormat(field, \"HH:mm\") : \"\";\n }\n default: {\n return isString(field) || isNumber(field) || isBoolean(field) ? String(field) : \"\";\n }\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;SAMgB,eAAe,CAAC,KAAc,EAAE,OAAkB,QAAQ,EAAA;IACxE,QAAQ,IAAI;AACV,QAAA,KAAK,WAAW,CAAC,KAAK,EAAE;AACtB,YAAA,OAAO,OAAO,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE;;AAE/C,QAAA,KAAK,WAAW,CAAC,IAAI,EAAE;AACrB,YAAA,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK;AACvD,kBAAE,UAAU,CAAC,KAAK,EAAE,YAAY;kBAC9B,EAAE;;AAER,QAAA,KAAK,WAAW,CAAC,QAAQ,EAAE;AACzB,YAAA,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK;AACvD,kBAAE,UAAU,CAAC,KAAK,EAAE,kBAAkB;kBACpC,EAAE;;AAER,QAAA,KAAK,WAAW,CAAC,MAAM,EAAE;AACvB,YAAA,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK;AAC1D,kBAAE,MAAM,CAAC,iBAAiB,CAAC,KAAK,CAAC;kBAC/B,EAAE;;AAER,QAAA,KAAK,WAAW,CAAC,MAAM,EAAE;YACvB,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE;;AAEpF,QAAA,KAAK,WAAW,CAAC,IAAI,EAAE;YACrB,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,KAAK,CAAC,GAAG,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,GAAG,EAAE;;QAE9F,SAAS;YACP,OAAO,QAAQ,CAAC,KAAK,CAAC,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,SAAS,CAAC,KAAK,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE;;;AAGxF;;;;"}