@persei/perseed-api 5.0.17 → 5.0.18

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 (88) hide show
  1. package/dist/ecosystem-container-widget.cjs +33 -0
  2. package/dist/ecosystem-container-widget.cjs.map +1 -0
  3. package/dist/ecosystem-container-widget.d.ts +1 -0
  4. package/dist/ecosystem-container-widget.mjs +33 -0
  5. package/dist/ecosystem-container-widget.mjs.map +1 -0
  6. package/dist/global-dates.cjs +6 -0
  7. package/dist/global-dates.cjs.map +1 -0
  8. package/dist/global-dates.d.ts +1 -0
  9. package/dist/global-dates.mjs +6 -0
  10. package/dist/global-dates.mjs.map +1 -0
  11. package/dist/global-locale.cjs +28 -0
  12. package/dist/global-locale.cjs.map +1 -0
  13. package/dist/global-locale.d.ts +1 -0
  14. package/dist/global-locale.mjs +28 -0
  15. package/dist/global-locale.mjs.map +1 -0
  16. package/dist/lib-CDM5aEJG.cjs +27 -0
  17. package/dist/lib-CDM5aEJG.cjs.map +1 -0
  18. package/dist/lib-XRCJ_UAQ.js +28 -0
  19. package/dist/lib-XRCJ_UAQ.js.map +1 -0
  20. package/dist/src/app.d.ts.map +1 -1
  21. package/dist/src/config/config.d.ts +1 -0
  22. package/dist/src/config/config.d.ts.map +1 -1
  23. package/dist/src/schemas/container_widget/create_widget_payload.schema.json +7 -20
  24. package/dist/src/schemas/container_widget/update_widget_payload.schema.json +7 -20
  25. package/dist/src/schemas/container_widget/widgetTypes/PatientListProps.d.ts +2 -6
  26. package/dist/src/schemas/container_widget/widgetTypes/PatientListProps.d.ts.map +1 -1
  27. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.helper.d.ts +46 -0
  28. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.helper.d.ts.map +1 -0
  29. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.helper.test.d.ts +2 -0
  30. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.helper.test.d.ts.map +1 -0
  31. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.schema.d.ts +22 -0
  32. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.schema.d.ts.map +1 -0
  33. package/dist/src/v2/modules/ecosystem/container-widget/container-widget.service.test.d.ts.map +1 -0
  34. package/dist/src/v2/modules/ecosystem/container-widget/index.d.ts +3 -0
  35. package/dist/src/v2/modules/ecosystem/container-widget/index.d.ts.map +1 -0
  36. package/dist/src/v2/modules/ecosystem/container-widget/lib.d.ts +3 -0
  37. package/dist/src/v2/modules/ecosystem/container-widget/lib.d.ts.map +1 -0
  38. package/dist/src/v2/modules/global/dates/dates.helper.d.ts +17 -0
  39. package/dist/src/v2/modules/global/dates/dates.helper.d.ts.map +1 -0
  40. package/dist/src/v2/modules/global/dates/dates.helper.test.d.ts +2 -0
  41. package/dist/src/v2/modules/global/dates/dates.helper.test.d.ts.map +1 -0
  42. package/dist/src/v2/modules/global/dates/dates.schema.d.ts +7 -0
  43. package/dist/src/v2/modules/global/dates/dates.schema.d.ts.map +1 -0
  44. package/dist/src/v2/modules/global/dates/index.d.ts +2 -0
  45. package/dist/src/v2/modules/global/dates/index.d.ts.map +1 -1
  46. package/dist/src/v2/modules/global/dates/lib.d.ts +3 -0
  47. package/dist/src/v2/modules/global/dates/lib.d.ts.map +1 -0
  48. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.controller.d.ts.map +1 -0
  49. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.controller.test.d.ts.map +1 -0
  50. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.middleware.d.ts.map +1 -0
  51. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.schema.d.ts.map +1 -0
  52. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.schema.test.d.ts.map +1 -0
  53. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.service.d.ts.map +1 -0
  54. package/dist/src/v2/modules/global/e2e-operation/e2e-operation.service.test.d.ts.map +1 -0
  55. package/dist/src/v2/modules/global/e2e-operation/index.d.ts.map +1 -0
  56. package/dist/src/v2/modules/global/locale/index.d.ts +3 -0
  57. package/dist/src/v2/modules/global/locale/index.d.ts.map +1 -0
  58. package/dist/src/v2/modules/global/locale/lib.d.ts +3 -0
  59. package/dist/src/v2/modules/global/locale/lib.d.ts.map +1 -0
  60. package/dist/src/v2/modules/global/locale/locale.helper.d.ts +17 -0
  61. package/dist/src/v2/modules/global/locale/locale.helper.d.ts.map +1 -0
  62. package/dist/src/v2/modules/global/locale/locale.helper.test.d.ts +2 -0
  63. package/dist/src/v2/modules/global/locale/locale.helper.test.d.ts.map +1 -0
  64. package/dist/src/v2/modules/global/locale/locale.schema.d.ts +15 -0
  65. package/dist/src/v2/modules/global/locale/locale.schema.d.ts.map +1 -0
  66. package/dist/src/v2/modules/project/health-data/health-data.service.d.ts +20 -3
  67. package/dist/src/v2/modules/project/health-data/health-data.service.d.ts.map +1 -1
  68. package/dist/v1/perseed-api.cjs.map +1 -1
  69. package/dist/v1/perseed-api.mjs.map +1 -1
  70. package/package.json +2 -1
  71. package/dist/src/v2/modules/container_widget/container-widget.service.test.d.ts.map +0 -1
  72. package/dist/src/v2/modules/e2e-operation/e2e-operation.controller.d.ts.map +0 -1
  73. package/dist/src/v2/modules/e2e-operation/e2e-operation.controller.test.d.ts.map +0 -1
  74. package/dist/src/v2/modules/e2e-operation/e2e-operation.middleware.d.ts.map +0 -1
  75. package/dist/src/v2/modules/e2e-operation/e2e-operation.schema.d.ts.map +0 -1
  76. package/dist/src/v2/modules/e2e-operation/e2e-operation.schema.test.d.ts.map +0 -1
  77. package/dist/src/v2/modules/e2e-operation/e2e-operation.service.d.ts.map +0 -1
  78. package/dist/src/v2/modules/e2e-operation/e2e-operation.service.test.d.ts.map +0 -1
  79. package/dist/src/v2/modules/e2e-operation/index.d.ts.map +0 -1
  80. /package/dist/src/v2/modules/{container_widget → ecosystem/container-widget}/container-widget.service.test.d.ts +0 -0
  81. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.controller.d.ts +0 -0
  82. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.controller.test.d.ts +0 -0
  83. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.middleware.d.ts +0 -0
  84. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.schema.d.ts +0 -0
  85. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.schema.test.d.ts +0 -0
  86. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.service.d.ts +0 -0
  87. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/e2e-operation.service.test.d.ts +0 -0
  88. /package/dist/src/v2/modules/{e2e-operation → global/e2e-operation}/index.d.ts +0 -0
@@ -0,0 +1,33 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const globalDates = require("./lib-CDM5aEJG.cjs");
4
+ const globalLocale = require("./global-locale.cjs");
5
+ function resolveTrendWindow(nowMs, config, weekStart = globalLocale.getWeekStart(), utc = false) {
6
+ const { fromValue, unit } = config;
7
+ const toValue = config.toValue ?? 0;
8
+ return {
9
+ start: globalDates.getPeriodStart(globalDates.subtractPeriods(nowMs, fromValue, unit, utc), unit, weekStart, utc),
10
+ end: toValue === 0 ? nowMs : globalDates.getPeriodStart(globalDates.subtractPeriods(nowMs, toValue - 1, unit, utc), unit, weekStart, utc)
11
+ };
12
+ }
13
+ function resolveRelativePeriod(nowMs, { value, unit, excludeCurrentPeriod = false }, weekStart = globalLocale.getWeekStart(), utc = false) {
14
+ return resolveTrendWindow(
15
+ nowMs,
16
+ { fromValue: excludeCurrentPeriod ? value : value - 1, toValue: excludeCurrentPeriod ? 1 : 0, unit },
17
+ weekStart,
18
+ utc
19
+ );
20
+ }
21
+ function resolveRelativeDateRange(nowMs, config, format, weekStart = globalLocale.getWeekStart(), utc = false) {
22
+ const { start, end } = resolveRelativePeriod(nowMs, config, weekStart, utc);
23
+ const startDate = globalDates.toCalendar(start, utc);
24
+ if (format === "discrete") {
25
+ return { start_date: startDate.toISOString(), end_date: globalDates.toCalendar(end, utc).toISOString() };
26
+ }
27
+ const endDate = config.excludeCurrentPeriod ? globalDates.toCalendar(end, utc).subtract(1, "day") : globalDates.toCalendar(end, utc);
28
+ return { start_date: startDate.format("YYYY-MM-DD"), end_date: endDate.format("YYYY-MM-DD") };
29
+ }
30
+ exports.resolveRelativeDateRange = resolveRelativeDateRange;
31
+ exports.resolveRelativePeriod = resolveRelativePeriod;
32
+ exports.resolveTrendWindow = resolveTrendWindow;
33
+ //# sourceMappingURL=ecosystem-container-widget.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ecosystem-container-widget.cjs","sources":["../../src/v2/modules/ecosystem/container-widget/container-widget.helper.ts"],"sourcesContent":["import { getPeriodStart, subtractPeriods, toCalendar } from '../../global/dates/dates.helper'\nimport { getWeekStart } from '../../global/locale/locale.helper'\nimport { type RelativePeriodConfig, type TrendWindow, type TrendWindowConfig } from './container-widget.schema'\n\n/**\n * Trend-widget time windows: the `value`/`from`/`to` → concrete-window resolution shared by the trend\n * widget (front, viewer-local) and the health-data time-range filter (backend, UTC). Built on the\n * generic calendar primitives of `global/dates` (which take the week start as a plain number) and the\n * locale week-start resolver of `global/locale`, so the trend-specific rules live here in one place.\n *\n * The `utc` flag is forwarded to the primitives: `false` (default) uses the ambient local calendar\n * (the front, viewer's timezone); `true` uses UTC (the backend). Both callers produce the exact same\n * window for the same inputs and timezone.\n */\n\n/**\n * Resolves a `from`/`to` range into a concrete, calendar-aligned window. `fromValue` and `toValue`\n * are inclusive bucket offsets (\"N units ago\"), so the window covers the buckets from `toValue`-ago\n * up to `fromValue`-ago and spans `fromValue − toValue + 1` buckets:\n *\n * - `start` (inclusive) = `getPeriodStart(now − fromValue·unit)` — start of the oldest bucket.\n * - `end` (exclusive) = `now` when `toValue = 0` (the current, in-progress bucket is included,\n * up to now); otherwise `getPeriodStart(now − (toValue − 1)·unit)` — the start of the bucket\n * just after the newest included one, which drops the current bucket.\n *\n * Example (unit = week, weekStart = 1 Monday, now = Tue 2026-07-07):\n * from 2, to 0 → [Mon 22 Jun, now) (3 weeks including the current one)\n * from 3, to 1 → [Mon 15 Jun, Mon 06 Jul) (3 complete weeks, current one excluded)\n */\nexport function resolveTrendWindow(\n nowMs: number,\n config: TrendWindowConfig,\n weekStart: number = getWeekStart(),\n utc = false,\n): TrendWindow {\n const { fromValue, unit } = config\n const toValue = config.toValue ?? 0\n return {\n start: getPeriodStart(subtractPeriods(nowMs, fromValue, unit, utc), unit, weekStart, utc),\n end: toValue === 0 ? nowMs : getPeriodStart(subtractPeriods(nowMs, toValue - 1, unit, utc), unit, weekStart, utc),\n }\n}\n\n/**\n * Resolves a count-based relative period into a concrete window — the single source of truth for the\n * `value` → from/to mapping shared by every consumer (backend health-data filter, front trend widget),\n * so the \"current period counts as one of the N\" rule is defined exactly once:\n * - including it → `from = value - 1`, `to = 0` (buckets `value-1`…0 ago, ending now);\n * - excluding it → `from = value`, `to = 1` (`value` complete buckets before the current one).\n */\nexport function resolveRelativePeriod(\n nowMs: number,\n { value, unit, excludeCurrentPeriod = false }: RelativePeriodConfig,\n weekStart: number = getWeekStart(),\n utc = false,\n): TrendWindow {\n return resolveTrendWindow(\n nowMs,\n { fromValue: excludeCurrentPeriod ? value : value - 1, toValue: excludeCurrentPeriod ? 1 : 0, unit },\n weekStart,\n utc,\n )\n}\n\n/**\n * Resolves a count-based relative period into a formatted date range, keeping the whole calculation\n * (from/to mapping + the day-level rule + formatting) in one shared place:\n * - `daily`: date-only `YYYY-MM-DD`; when excluding the current period the inclusive end becomes the\n * last completed calendar day (the day before the current period's start).\n * - `discrete`: ISO-8601, with the exclusive upper bound used verbatim.\n */\nexport function resolveRelativeDateRange(\n nowMs: number,\n config: RelativePeriodConfig,\n format: 'daily' | 'discrete',\n weekStart: number = getWeekStart(),\n utc = false,\n): { start_date: string; end_date: string } {\n const { start, end } = resolveRelativePeriod(nowMs, config, weekStart, utc)\n const startDate = toCalendar(start, utc)\n if (format === 'discrete') {\n return { start_date: startDate.toISOString(), end_date: toCalendar(end, utc).toISOString() }\n }\n const endDate = config.excludeCurrentPeriod ? toCalendar(end, utc).subtract(1, 'day') : toCalendar(end, utc)\n return { start_date: startDate.format('YYYY-MM-DD'), end_date: endDate.format('YYYY-MM-DD') }\n}\n"],"names":["getWeekStart","getPeriodStart","subtractPeriods","toCalendar"],"mappings":";;;;AA6BO,SAAS,mBACd,OACA,QACA,YAAoBA,aAAAA,aAAA,GACpB,MAAM,OACO;AACb,QAAM,EAAE,WAAW,KAAA,IAAS;AAC5B,QAAM,UAAU,OAAO,WAAW;AAClC,SAAO;AAAA,IACL,OAAOC,YAAAA,eAAeC,4BAAgB,OAAO,WAAW,MAAM,GAAG,GAAG,MAAM,WAAW,GAAG;AAAA,IACxF,KAAK,YAAY,IAAI,QAAQD,YAAAA,eAAeC,YAAAA,gBAAgB,OAAO,UAAU,GAAG,MAAM,GAAG,GAAG,MAAM,WAAW,GAAG;AAAA,EAAA;AAEpH;AASO,SAAS,sBACd,OACA,EAAE,OAAO,MAAM,uBAAuB,MAAA,GACtC,YAAoBF,aAAAA,gBACpB,MAAM,OACO;AACb,SAAO;AAAA,IACL;AAAA,IACA,EAAE,WAAW,uBAAuB,QAAQ,QAAQ,GAAG,SAAS,uBAAuB,IAAI,GAAG,KAAA;AAAA,IAC9F;AAAA,IACA;AAAA,EAAA;AAEJ;AASO,SAAS,yBACd,OACA,QACA,QACA,YAAoBA,0BAAA,GACpB,MAAM,OACoC;AAC1C,QAAM,EAAE,OAAO,QAAQ,sBAAsB,OAAO,QAAQ,WAAW,GAAG;AAC1E,QAAM,YAAYG,YAAAA,WAAW,OAAO,GAAG;AACvC,MAAI,WAAW,YAAY;AACzB,WAAO,EAAE,YAAY,UAAU,eAAe,UAAUA,YAAAA,WAAW,KAAK,GAAG,EAAE,cAAY;AAAA,EAC3F;AACA,QAAM,UAAU,OAAO,uBAAuBA,YAAAA,WAAW,KAAK,GAAG,EAAE,SAAS,GAAG,KAAK,IAAIA,YAAAA,WAAW,KAAK,GAAG;AAC3G,SAAO,EAAE,YAAY,UAAU,OAAO,YAAY,GAAG,UAAU,QAAQ,OAAO,YAAY,EAAA;AAC5F;;;;"}
@@ -0,0 +1 @@
1
+ export * from './src/v2/modules/ecosystem/container-widget/lib'
@@ -0,0 +1,33 @@
1
+ import { t as toCalendar, g as getPeriodStart, s as subtractPeriods } from "./lib-XRCJ_UAQ.js";
2
+ import { getWeekStart } from "./global-locale.mjs";
3
+ function resolveTrendWindow(nowMs, config, weekStart = getWeekStart(), utc = false) {
4
+ const { fromValue, unit } = config;
5
+ const toValue = config.toValue ?? 0;
6
+ return {
7
+ start: getPeriodStart(subtractPeriods(nowMs, fromValue, unit, utc), unit, weekStart, utc),
8
+ end: toValue === 0 ? nowMs : getPeriodStart(subtractPeriods(nowMs, toValue - 1, unit, utc), unit, weekStart, utc)
9
+ };
10
+ }
11
+ function resolveRelativePeriod(nowMs, { value, unit, excludeCurrentPeriod = false }, weekStart = getWeekStart(), utc = false) {
12
+ return resolveTrendWindow(
13
+ nowMs,
14
+ { fromValue: excludeCurrentPeriod ? value : value - 1, toValue: excludeCurrentPeriod ? 1 : 0, unit },
15
+ weekStart,
16
+ utc
17
+ );
18
+ }
19
+ function resolveRelativeDateRange(nowMs, config, format, weekStart = getWeekStart(), utc = false) {
20
+ const { start, end } = resolveRelativePeriod(nowMs, config, weekStart, utc);
21
+ const startDate = toCalendar(start, utc);
22
+ if (format === "discrete") {
23
+ return { start_date: startDate.toISOString(), end_date: toCalendar(end, utc).toISOString() };
24
+ }
25
+ const endDate = config.excludeCurrentPeriod ? toCalendar(end, utc).subtract(1, "day") : toCalendar(end, utc);
26
+ return { start_date: startDate.format("YYYY-MM-DD"), end_date: endDate.format("YYYY-MM-DD") };
27
+ }
28
+ export {
29
+ resolveRelativeDateRange,
30
+ resolveRelativePeriod,
31
+ resolveTrendWindow
32
+ };
33
+ //# sourceMappingURL=ecosystem-container-widget.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ecosystem-container-widget.mjs","sources":["../../src/v2/modules/ecosystem/container-widget/container-widget.helper.ts"],"sourcesContent":["import { getPeriodStart, subtractPeriods, toCalendar } from '../../global/dates/dates.helper'\nimport { getWeekStart } from '../../global/locale/locale.helper'\nimport { type RelativePeriodConfig, type TrendWindow, type TrendWindowConfig } from './container-widget.schema'\n\n/**\n * Trend-widget time windows: the `value`/`from`/`to` → concrete-window resolution shared by the trend\n * widget (front, viewer-local) and the health-data time-range filter (backend, UTC). Built on the\n * generic calendar primitives of `global/dates` (which take the week start as a plain number) and the\n * locale week-start resolver of `global/locale`, so the trend-specific rules live here in one place.\n *\n * The `utc` flag is forwarded to the primitives: `false` (default) uses the ambient local calendar\n * (the front, viewer's timezone); `true` uses UTC (the backend). Both callers produce the exact same\n * window for the same inputs and timezone.\n */\n\n/**\n * Resolves a `from`/`to` range into a concrete, calendar-aligned window. `fromValue` and `toValue`\n * are inclusive bucket offsets (\"N units ago\"), so the window covers the buckets from `toValue`-ago\n * up to `fromValue`-ago and spans `fromValue − toValue + 1` buckets:\n *\n * - `start` (inclusive) = `getPeriodStart(now − fromValue·unit)` — start of the oldest bucket.\n * - `end` (exclusive) = `now` when `toValue = 0` (the current, in-progress bucket is included,\n * up to now); otherwise `getPeriodStart(now − (toValue − 1)·unit)` — the start of the bucket\n * just after the newest included one, which drops the current bucket.\n *\n * Example (unit = week, weekStart = 1 Monday, now = Tue 2026-07-07):\n * from 2, to 0 → [Mon 22 Jun, now) (3 weeks including the current one)\n * from 3, to 1 → [Mon 15 Jun, Mon 06 Jul) (3 complete weeks, current one excluded)\n */\nexport function resolveTrendWindow(\n nowMs: number,\n config: TrendWindowConfig,\n weekStart: number = getWeekStart(),\n utc = false,\n): TrendWindow {\n const { fromValue, unit } = config\n const toValue = config.toValue ?? 0\n return {\n start: getPeriodStart(subtractPeriods(nowMs, fromValue, unit, utc), unit, weekStart, utc),\n end: toValue === 0 ? nowMs : getPeriodStart(subtractPeriods(nowMs, toValue - 1, unit, utc), unit, weekStart, utc),\n }\n}\n\n/**\n * Resolves a count-based relative period into a concrete window — the single source of truth for the\n * `value` → from/to mapping shared by every consumer (backend health-data filter, front trend widget),\n * so the \"current period counts as one of the N\" rule is defined exactly once:\n * - including it → `from = value - 1`, `to = 0` (buckets `value-1`…0 ago, ending now);\n * - excluding it → `from = value`, `to = 1` (`value` complete buckets before the current one).\n */\nexport function resolveRelativePeriod(\n nowMs: number,\n { value, unit, excludeCurrentPeriod = false }: RelativePeriodConfig,\n weekStart: number = getWeekStart(),\n utc = false,\n): TrendWindow {\n return resolveTrendWindow(\n nowMs,\n { fromValue: excludeCurrentPeriod ? value : value - 1, toValue: excludeCurrentPeriod ? 1 : 0, unit },\n weekStart,\n utc,\n )\n}\n\n/**\n * Resolves a count-based relative period into a formatted date range, keeping the whole calculation\n * (from/to mapping + the day-level rule + formatting) in one shared place:\n * - `daily`: date-only `YYYY-MM-DD`; when excluding the current period the inclusive end becomes the\n * last completed calendar day (the day before the current period's start).\n * - `discrete`: ISO-8601, with the exclusive upper bound used verbatim.\n */\nexport function resolveRelativeDateRange(\n nowMs: number,\n config: RelativePeriodConfig,\n format: 'daily' | 'discrete',\n weekStart: number = getWeekStart(),\n utc = false,\n): { start_date: string; end_date: string } {\n const { start, end } = resolveRelativePeriod(nowMs, config, weekStart, utc)\n const startDate = toCalendar(start, utc)\n if (format === 'discrete') {\n return { start_date: startDate.toISOString(), end_date: toCalendar(end, utc).toISOString() }\n }\n const endDate = config.excludeCurrentPeriod ? toCalendar(end, utc).subtract(1, 'day') : toCalendar(end, utc)\n return { start_date: startDate.format('YYYY-MM-DD'), end_date: endDate.format('YYYY-MM-DD') }\n}\n"],"names":[],"mappings":";;AA6BO,SAAS,mBACd,OACA,QACA,YAAoB,aAAA,GACpB,MAAM,OACO;AACb,QAAM,EAAE,WAAW,KAAA,IAAS;AAC5B,QAAM,UAAU,OAAO,WAAW;AAClC,SAAO;AAAA,IACL,OAAO,eAAe,gBAAgB,OAAO,WAAW,MAAM,GAAG,GAAG,MAAM,WAAW,GAAG;AAAA,IACxF,KAAK,YAAY,IAAI,QAAQ,eAAe,gBAAgB,OAAO,UAAU,GAAG,MAAM,GAAG,GAAG,MAAM,WAAW,GAAG;AAAA,EAAA;AAEpH;AASO,SAAS,sBACd,OACA,EAAE,OAAO,MAAM,uBAAuB,MAAA,GACtC,YAAoB,gBACpB,MAAM,OACO;AACb,SAAO;AAAA,IACL;AAAA,IACA,EAAE,WAAW,uBAAuB,QAAQ,QAAQ,GAAG,SAAS,uBAAuB,IAAI,GAAG,KAAA;AAAA,IAC9F;AAAA,IACA;AAAA,EAAA;AAEJ;AASO,SAAS,yBACd,OACA,QACA,QACA,YAAoB,aAAA,GACpB,MAAM,OACoC;AAC1C,QAAM,EAAE,OAAO,QAAQ,sBAAsB,OAAO,QAAQ,WAAW,GAAG;AAC1E,QAAM,YAAY,WAAW,OAAO,GAAG;AACvC,MAAI,WAAW,YAAY;AACzB,WAAO,EAAE,YAAY,UAAU,eAAe,UAAU,WAAW,KAAK,GAAG,EAAE,cAAY;AAAA,EAC3F;AACA,QAAM,UAAU,OAAO,uBAAuB,WAAW,KAAK,GAAG,EAAE,SAAS,GAAG,KAAK,IAAI,WAAW,KAAK,GAAG;AAC3G,SAAO,EAAE,YAAY,UAAU,OAAO,YAAY,GAAG,UAAU,QAAQ,OAAO,YAAY,EAAA;AAC5F;"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const globalDates = require("./lib-CDM5aEJG.cjs");
4
+ exports.getPeriodStart = globalDates.getPeriodStart;
5
+ exports.subtractPeriods = globalDates.subtractPeriods;
6
+ //# sourceMappingURL=global-dates.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global-dates.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
@@ -0,0 +1 @@
1
+ export * from './src/v2/modules/global/dates/lib'
@@ -0,0 +1,6 @@
1
+ import { g, s } from "./lib-XRCJ_UAQ.js";
2
+ export {
3
+ g as getPeriodStart,
4
+ s as subtractPeriods
5
+ };
6
+ //# sourceMappingURL=global-dates.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global-dates.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const DEFAULT_LOCALE = "es-ES";
4
+ const FALLBACK_WEEK_START = 1;
5
+ function toLocale(raw) {
6
+ const tag = raw?.trim().replace(/_/g, "-");
7
+ if (!tag) return DEFAULT_LOCALE;
8
+ try {
9
+ const loc = new Intl.Locale(tag);
10
+ const region = loc.region ?? loc.maximize().region;
11
+ if (region) return `${loc.language}-${region}`;
12
+ } catch {
13
+ }
14
+ return DEFAULT_LOCALE;
15
+ }
16
+ function getWeekStart(locale = DEFAULT_LOCALE) {
17
+ try {
18
+ const loc = new Intl.Locale(locale);
19
+ const info = loc.weekInfo ?? loc.getWeekInfo?.();
20
+ if (info && typeof info.firstDay === "number") return info.firstDay;
21
+ } catch {
22
+ }
23
+ return FALLBACK_WEEK_START;
24
+ }
25
+ exports.DEFAULT_LOCALE = DEFAULT_LOCALE;
26
+ exports.getWeekStart = getWeekStart;
27
+ exports.toLocale = toLocale;
28
+ //# sourceMappingURL=global-locale.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global-locale.cjs","sources":["../../src/v2/modules/global/locale/locale.schema.ts","../../src/v2/modules/global/locale/locale.helper.ts"],"sourcesContent":["/**\n * Locale contracts owned by this module. Pure types/constants only — the normalization and week-info\n * logic that consumes them lives in `locale.helper.ts`.\n */\n\n// Canonical locale: BCP-47 `language-REGION`, region ALWAYS present (e.g. `es-ES`, `en-US`).\n// Every consumer works on this fixed shape — normalize raw input once with `toLocale`, never re-parse.\nexport type Locale = `${Lowercase<string>}-${Uppercase<string>}`\n\n// Platform default, unified with the default timezone (Europe/Madrid → Spain → week starts Monday).\nexport const DEFAULT_LOCALE: Locale = 'es-ES'\n\n// `weekInfo` (getter) / `getWeekInfo()` are not yet in the TS `Intl.Locale` lib types.\nexport type LocaleWithWeekInfo = Intl.Locale & {\n weekInfo?: { firstDay: number }\n getWeekInfo?: () => { firstDay: number }\n}\n","import { DEFAULT_LOCALE, type Locale, type LocaleWithWeekInfo } from './locale.schema'\n\n/**\n * Locale normalization and calendar week-info derived from the user's locale. Kept separate from\n * `global/dates`: this module answers cultural questions about a locale (canonical shape, which\n * weekday starts the week), while `dates` does calendar arithmetic and takes the week start as an\n * already-resolved number. That split keeps `dates` locale-agnostic and free of any v2-module import.\n */\n\n// ISO Monday: the week start of DEFAULT_LOCALE. Only used if the runtime lacks Intl week info.\nconst FALLBACK_WEEK_START = 1\n\n/**\n * Normalizes any raw locale into the canonical {@link Locale}. Converts `_`→`-`, and when the tag\n * carries no region, resolves the language's OWN default region via `Intl.Locale.maximize()` (CLDR\n * likely-subtags): `en` → `en-US`, `es` → `es-ES`, `de` → `de-DE`. An explicit region is preserved\n * (`en-GB` stays `en-GB`). Empty/blank/unparseable input falls back to {@link DEFAULT_LOCALE}. Call\n * this ONCE at each boundary; downstream functions take an already-normalized `Locale`.\n */\nexport function toLocale(raw?: string | null): Locale {\n const tag = raw?.trim().replace(/_/g, '-')\n if (!tag) return DEFAULT_LOCALE\n try {\n const loc = new Intl.Locale(tag)\n const region = loc.region ?? loc.maximize().region\n if (region) return `${loc.language}-${region}` as Locale\n } catch {\n // Unparseable tag — fall back to the platform default.\n }\n return DEFAULT_LOCALE\n}\n\n/**\n * Returns the ISO weekday number (1 = Monday … 7 = Sunday) that starts the week for `locale`. Takes\n * an already-canonical {@link Locale} (normalize raw input with {@link toLocale} first), so no format\n * parsing happens here. Falls back to {@link DEFAULT_LOCALE}'s week start only on runtimes without\n * Intl week info.\n */\nexport function getWeekStart(locale: Locale = DEFAULT_LOCALE): number {\n try {\n const loc = new Intl.Locale(locale) as LocaleWithWeekInfo\n const info = loc.weekInfo ?? loc.getWeekInfo?.()\n if (info && typeof info.firstDay === 'number') return info.firstDay\n } catch {\n // Runtime without Intl week info, or a locale Intl rejects — use the default week start.\n }\n return FALLBACK_WEEK_START\n}\n"],"names":[],"mappings":";;AAUO,MAAM,iBAAyB;ACAtC,MAAM,sBAAsB;AASrB,SAAS,SAAS,KAA6B;AACpD,QAAM,MAAM,KAAK,KAAA,EAAO,QAAQ,MAAM,GAAG;AACzC,MAAI,CAAC,IAAK,QAAO;AACjB,MAAI;AACF,UAAM,MAAM,IAAI,KAAK,OAAO,GAAG;AAC/B,UAAM,SAAS,IAAI,UAAU,IAAI,WAAW;AAC5C,QAAI,OAAQ,QAAO,GAAG,IAAI,QAAQ,IAAI,MAAM;AAAA,EAC9C,QAAQ;AAAA,EAER;AACA,SAAO;AACT;AAQO,SAAS,aAAa,SAAiB,gBAAwB;AACpE,MAAI;AACF,UAAM,MAAM,IAAI,KAAK,OAAO,MAAM;AAClC,UAAM,OAAO,IAAI,YAAY,IAAI,cAAA;AACjC,QAAI,QAAQ,OAAO,KAAK,aAAa,iBAAiB,KAAK;AAAA,EAC7D,QAAQ;AAAA,EAER;AACA,SAAO;AACT;;;;"}
@@ -0,0 +1 @@
1
+ export * from './src/v2/modules/global/locale/lib'
@@ -0,0 +1,28 @@
1
+ const DEFAULT_LOCALE = "es-ES";
2
+ const FALLBACK_WEEK_START = 1;
3
+ function toLocale(raw) {
4
+ const tag = raw?.trim().replace(/_/g, "-");
5
+ if (!tag) return DEFAULT_LOCALE;
6
+ try {
7
+ const loc = new Intl.Locale(tag);
8
+ const region = loc.region ?? loc.maximize().region;
9
+ if (region) return `${loc.language}-${region}`;
10
+ } catch {
11
+ }
12
+ return DEFAULT_LOCALE;
13
+ }
14
+ function getWeekStart(locale = DEFAULT_LOCALE) {
15
+ try {
16
+ const loc = new Intl.Locale(locale);
17
+ const info = loc.weekInfo ?? loc.getWeekInfo?.();
18
+ if (info && typeof info.firstDay === "number") return info.firstDay;
19
+ } catch {
20
+ }
21
+ return FALLBACK_WEEK_START;
22
+ }
23
+ export {
24
+ DEFAULT_LOCALE,
25
+ getWeekStart,
26
+ toLocale
27
+ };
28
+ //# sourceMappingURL=global-locale.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global-locale.mjs","sources":["../../src/v2/modules/global/locale/locale.schema.ts","../../src/v2/modules/global/locale/locale.helper.ts"],"sourcesContent":["/**\n * Locale contracts owned by this module. Pure types/constants only — the normalization and week-info\n * logic that consumes them lives in `locale.helper.ts`.\n */\n\n// Canonical locale: BCP-47 `language-REGION`, region ALWAYS present (e.g. `es-ES`, `en-US`).\n// Every consumer works on this fixed shape — normalize raw input once with `toLocale`, never re-parse.\nexport type Locale = `${Lowercase<string>}-${Uppercase<string>}`\n\n// Platform default, unified with the default timezone (Europe/Madrid → Spain → week starts Monday).\nexport const DEFAULT_LOCALE: Locale = 'es-ES'\n\n// `weekInfo` (getter) / `getWeekInfo()` are not yet in the TS `Intl.Locale` lib types.\nexport type LocaleWithWeekInfo = Intl.Locale & {\n weekInfo?: { firstDay: number }\n getWeekInfo?: () => { firstDay: number }\n}\n","import { DEFAULT_LOCALE, type Locale, type LocaleWithWeekInfo } from './locale.schema'\n\n/**\n * Locale normalization and calendar week-info derived from the user's locale. Kept separate from\n * `global/dates`: this module answers cultural questions about a locale (canonical shape, which\n * weekday starts the week), while `dates` does calendar arithmetic and takes the week start as an\n * already-resolved number. That split keeps `dates` locale-agnostic and free of any v2-module import.\n */\n\n// ISO Monday: the week start of DEFAULT_LOCALE. Only used if the runtime lacks Intl week info.\nconst FALLBACK_WEEK_START = 1\n\n/**\n * Normalizes any raw locale into the canonical {@link Locale}. Converts `_`→`-`, and when the tag\n * carries no region, resolves the language's OWN default region via `Intl.Locale.maximize()` (CLDR\n * likely-subtags): `en` → `en-US`, `es` → `es-ES`, `de` → `de-DE`. An explicit region is preserved\n * (`en-GB` stays `en-GB`). Empty/blank/unparseable input falls back to {@link DEFAULT_LOCALE}. Call\n * this ONCE at each boundary; downstream functions take an already-normalized `Locale`.\n */\nexport function toLocale(raw?: string | null): Locale {\n const tag = raw?.trim().replace(/_/g, '-')\n if (!tag) return DEFAULT_LOCALE\n try {\n const loc = new Intl.Locale(tag)\n const region = loc.region ?? loc.maximize().region\n if (region) return `${loc.language}-${region}` as Locale\n } catch {\n // Unparseable tag — fall back to the platform default.\n }\n return DEFAULT_LOCALE\n}\n\n/**\n * Returns the ISO weekday number (1 = Monday … 7 = Sunday) that starts the week for `locale`. Takes\n * an already-canonical {@link Locale} (normalize raw input with {@link toLocale} first), so no format\n * parsing happens here. Falls back to {@link DEFAULT_LOCALE}'s week start only on runtimes without\n * Intl week info.\n */\nexport function getWeekStart(locale: Locale = DEFAULT_LOCALE): number {\n try {\n const loc = new Intl.Locale(locale) as LocaleWithWeekInfo\n const info = loc.weekInfo ?? loc.getWeekInfo?.()\n if (info && typeof info.firstDay === 'number') return info.firstDay\n } catch {\n // Runtime without Intl week info, or a locale Intl rejects — use the default week start.\n }\n return FALLBACK_WEEK_START\n}\n"],"names":[],"mappings":"AAUO,MAAM,iBAAyB;ACAtC,MAAM,sBAAsB;AASrB,SAAS,SAAS,KAA6B;AACpD,QAAM,MAAM,KAAK,KAAA,EAAO,QAAQ,MAAM,GAAG;AACzC,MAAI,CAAC,IAAK,QAAO;AACjB,MAAI;AACF,UAAM,MAAM,IAAI,KAAK,OAAO,GAAG;AAC/B,UAAM,SAAS,IAAI,UAAU,IAAI,WAAW;AAC5C,QAAI,OAAQ,QAAO,GAAG,IAAI,QAAQ,IAAI,MAAM;AAAA,EAC9C,QAAQ;AAAA,EAER;AACA,SAAO;AACT;AAQO,SAAS,aAAa,SAAiB,gBAAwB;AACpE,MAAI;AACF,UAAM,MAAM,IAAI,KAAK,OAAO,MAAM;AAClC,UAAM,OAAO,IAAI,YAAY,IAAI,cAAA;AACjC,QAAI,QAAQ,OAAO,KAAK,aAAa,iBAAiB,KAAK;AAAA,EAC7D,QAAQ;AAAA,EAER;AACA,SAAO;AACT;"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ const dayjs = require("dayjs");
3
+ const utcPlugin = require("dayjs/plugin/utc");
4
+ dayjs.extend(utcPlugin);
5
+ const DEFAULT_WEEK_START = 1;
6
+ function toCalendar(ms, utc) {
7
+ return utc ? dayjs.utc(ms) : dayjs(ms);
8
+ }
9
+ function isoWeekday(d) {
10
+ const day = d.day();
11
+ return day === 0 ? 7 : day;
12
+ }
13
+ function getPeriodStart(ms, unit, weekStart = DEFAULT_WEEK_START, utc = false) {
14
+ const d = toCalendar(ms, utc);
15
+ if (unit === "week") {
16
+ const diff = (isoWeekday(d) - weekStart + 7) % 7;
17
+ return d.subtract(diff, "day").startOf("day").valueOf();
18
+ }
19
+ return d.startOf(unit).valueOf();
20
+ }
21
+ function subtractPeriods(ms, value, unit, utc = false) {
22
+ return toCalendar(ms, utc).subtract(value, unit).valueOf();
23
+ }
24
+ exports.getPeriodStart = getPeriodStart;
25
+ exports.subtractPeriods = subtractPeriods;
26
+ exports.toCalendar = toCalendar;
27
+ //# sourceMappingURL=lib-CDM5aEJG.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lib-CDM5aEJG.cjs","sources":["../../src/v2/modules/global/dates/dates.helper.ts"],"sourcesContent":["import dayjs from 'dayjs'\nimport utcPlugin from 'dayjs/plugin/utc'\nimport { type PeriodUnit } from './dates.schema'\n\n/**\n * Generic calendar primitives — period alignment and whole-period arithmetic. Built on `dayjs`\n * (already used by every consumer), so calendar arithmetic and month-end clamping come for free.\n *\n * These functions are locale-agnostic: the week start is always an injected number (1 = Monday …\n * 7 = Sunday), never derived here. Callers that need a locale-aware week start resolve it with\n * `global/locale`'s `getWeekStart(locale)` and pass the result in. That keeps this module free of\n * any dependency on other v2 modules.\n *\n * The `utc` flag selects the calendar the alignment runs in: `false` (default) uses the ambient\n * local calendar (a viewer's timezone); `true` uses UTC (the backend). Everything else is shared.\n */\n\ndayjs.extend(utcPlugin)\n\n// ISO Monday — the week start assumed when the caller doesn't inject a locale-derived one. Matches\n// DEFAULT_LOCALE (es-ES), whose week also starts on Monday.\nexport const DEFAULT_WEEK_START = 1\n\n// Builds the dayjs instance in the requested calendar (UTC or ambient local).\nexport function toCalendar(ms: number, utc: boolean): dayjs.Dayjs {\n return utc ? dayjs.utc(ms) : dayjs(ms)\n}\n\n// dayjs `.day()` is 0 = Sunday … 6 = Saturday; convert to ISO 1 = Monday … 7 = Sunday.\nfunction isoWeekday(d: dayjs.Dayjs): number {\n const day = d.day()\n return day === 0 ? 7 : day\n}\n\n/**\n * Aligns an instant to the start of the calendar period it falls in:\n * weeks → the injected first weekday at midnight, months → the 1st at midnight,\n * days → midnight, hours → the start of the hour. `utc` runs the alignment in UTC.\n */\nexport function getPeriodStart(\n ms: number,\n unit: PeriodUnit,\n weekStart: number = DEFAULT_WEEK_START,\n utc = false,\n): number {\n const d = toCalendar(ms, utc)\n if (unit === 'week') {\n // Not `startOf('week')`: that follows the dayjs locale, but the week start here is caller-driven.\n const diff = (isoWeekday(d) - weekStart + 7) % 7\n return d.subtract(diff, 'day').startOf('day').valueOf()\n }\n return d.startOf(unit).valueOf()\n}\n\n/**\n * Subtracts `value` whole calendar periods from an instant, without aligning. Month subtraction\n * clamps to the last day of the target month (e.g. 31 Mar − 1 month → 28 Feb), which dayjs does\n * natively. `utc` runs the arithmetic in UTC.\n */\nexport function subtractPeriods(ms: number, value: number, unit: PeriodUnit, utc = false): number {\n return toCalendar(ms, utc).subtract(value, unit).valueOf()\n}\n"],"names":[],"mappings":";;;AAiBA,MAAM,OAAO,SAAS;AAIf,MAAM,qBAAqB;AAG3B,SAAS,WAAW,IAAY,KAA2B;AAChE,SAAO,MAAM,MAAM,IAAI,EAAE,IAAI,MAAM,EAAE;AACvC;AAGA,SAAS,WAAW,GAAwB;AAC1C,QAAM,MAAM,EAAE,IAAA;AACd,SAAO,QAAQ,IAAI,IAAI;AACzB;AAOO,SAAS,eACd,IACA,MACA,YAAoB,oBACpB,MAAM,OACE;AACR,QAAM,IAAI,WAAW,IAAI,GAAG;AAC5B,MAAI,SAAS,QAAQ;AAEnB,UAAM,QAAQ,WAAW,CAAC,IAAI,YAAY,KAAK;AAC/C,WAAO,EAAE,SAAS,MAAM,KAAK,EAAE,QAAQ,KAAK,EAAE,QAAA;AAAA,EAChD;AACA,SAAO,EAAE,QAAQ,IAAI,EAAE,QAAA;AACzB;AAOO,SAAS,gBAAgB,IAAY,OAAe,MAAkB,MAAM,OAAe;AAChG,SAAO,WAAW,IAAI,GAAG,EAAE,SAAS,OAAO,IAAI,EAAE,QAAA;AACnD;;;;"}
@@ -0,0 +1,28 @@
1
+ import dayjs from "dayjs";
2
+ import utcPlugin from "dayjs/plugin/utc";
3
+ dayjs.extend(utcPlugin);
4
+ const DEFAULT_WEEK_START = 1;
5
+ function toCalendar(ms, utc) {
6
+ return utc ? dayjs.utc(ms) : dayjs(ms);
7
+ }
8
+ function isoWeekday(d) {
9
+ const day = d.day();
10
+ return day === 0 ? 7 : day;
11
+ }
12
+ function getPeriodStart(ms, unit, weekStart = DEFAULT_WEEK_START, utc = false) {
13
+ const d = toCalendar(ms, utc);
14
+ if (unit === "week") {
15
+ const diff = (isoWeekday(d) - weekStart + 7) % 7;
16
+ return d.subtract(diff, "day").startOf("day").valueOf();
17
+ }
18
+ return d.startOf(unit).valueOf();
19
+ }
20
+ function subtractPeriods(ms, value, unit, utc = false) {
21
+ return toCalendar(ms, utc).subtract(value, unit).valueOf();
22
+ }
23
+ export {
24
+ getPeriodStart as g,
25
+ subtractPeriods as s,
26
+ toCalendar as t
27
+ };
28
+ //# sourceMappingURL=lib-XRCJ_UAQ.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lib-XRCJ_UAQ.js","sources":["../../src/v2/modules/global/dates/dates.helper.ts"],"sourcesContent":["import dayjs from 'dayjs'\nimport utcPlugin from 'dayjs/plugin/utc'\nimport { type PeriodUnit } from './dates.schema'\n\n/**\n * Generic calendar primitives — period alignment and whole-period arithmetic. Built on `dayjs`\n * (already used by every consumer), so calendar arithmetic and month-end clamping come for free.\n *\n * These functions are locale-agnostic: the week start is always an injected number (1 = Monday …\n * 7 = Sunday), never derived here. Callers that need a locale-aware week start resolve it with\n * `global/locale`'s `getWeekStart(locale)` and pass the result in. That keeps this module free of\n * any dependency on other v2 modules.\n *\n * The `utc` flag selects the calendar the alignment runs in: `false` (default) uses the ambient\n * local calendar (a viewer's timezone); `true` uses UTC (the backend). Everything else is shared.\n */\n\ndayjs.extend(utcPlugin)\n\n// ISO Monday — the week start assumed when the caller doesn't inject a locale-derived one. Matches\n// DEFAULT_LOCALE (es-ES), whose week also starts on Monday.\nexport const DEFAULT_WEEK_START = 1\n\n// Builds the dayjs instance in the requested calendar (UTC or ambient local).\nexport function toCalendar(ms: number, utc: boolean): dayjs.Dayjs {\n return utc ? dayjs.utc(ms) : dayjs(ms)\n}\n\n// dayjs `.day()` is 0 = Sunday … 6 = Saturday; convert to ISO 1 = Monday … 7 = Sunday.\nfunction isoWeekday(d: dayjs.Dayjs): number {\n const day = d.day()\n return day === 0 ? 7 : day\n}\n\n/**\n * Aligns an instant to the start of the calendar period it falls in:\n * weeks → the injected first weekday at midnight, months → the 1st at midnight,\n * days → midnight, hours → the start of the hour. `utc` runs the alignment in UTC.\n */\nexport function getPeriodStart(\n ms: number,\n unit: PeriodUnit,\n weekStart: number = DEFAULT_WEEK_START,\n utc = false,\n): number {\n const d = toCalendar(ms, utc)\n if (unit === 'week') {\n // Not `startOf('week')`: that follows the dayjs locale, but the week start here is caller-driven.\n const diff = (isoWeekday(d) - weekStart + 7) % 7\n return d.subtract(diff, 'day').startOf('day').valueOf()\n }\n return d.startOf(unit).valueOf()\n}\n\n/**\n * Subtracts `value` whole calendar periods from an instant, without aligning. Month subtraction\n * clamps to the last day of the target month (e.g. 31 Mar − 1 month → 28 Feb), which dayjs does\n * natively. `utc` runs the arithmetic in UTC.\n */\nexport function subtractPeriods(ms: number, value: number, unit: PeriodUnit, utc = false): number {\n return toCalendar(ms, utc).subtract(value, unit).valueOf()\n}\n"],"names":[],"mappings":";;AAiBA,MAAM,OAAO,SAAS;AAIf,MAAM,qBAAqB;AAG3B,SAAS,WAAW,IAAY,KAA2B;AAChE,SAAO,MAAM,MAAM,IAAI,EAAE,IAAI,MAAM,EAAE;AACvC;AAGA,SAAS,WAAW,GAAwB;AAC1C,QAAM,MAAM,EAAE,IAAA;AACd,SAAO,QAAQ,IAAI,IAAI;AACzB;AAOO,SAAS,eACd,IACA,MACA,YAAoB,oBACpB,MAAM,OACE;AACR,QAAM,IAAI,WAAW,IAAI,GAAG;AAC5B,MAAI,SAAS,QAAQ;AAEnB,UAAM,QAAQ,WAAW,CAAC,IAAI,YAAY,KAAK;AAC/C,WAAO,EAAE,SAAS,MAAM,KAAK,EAAE,QAAQ,KAAK,EAAE,QAAA;AAAA,EAChD;AACA,SAAO,EAAE,QAAQ,IAAI,EAAE,QAAA;AACzB;AAOO,SAAS,gBAAgB,IAAY,OAAe,MAAkB,MAAM,OAAe;AAChG,SAAO,WAAW,IAAI,GAAG,EAAE,SAAS,OAAO,IAAI,EAAE,QAAA;AACnD;"}
@@ -1 +1 @@
1
- {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../src/app.ts"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAA;AAOrB,OAAO,EAAE,mBAAmB,EAA4B,MAAM,gCAAgC,CAAA;AAoC9F,iBAAe,MAAM,CAAC,QAAQ,UAAQ,EAAE,WAAW,CAAC,EAAE,OAAO,2SAgN5D;AAED,eAAe,MAAM,CAAA"}
1
+ {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../src/app.ts"],"names":[],"mappings":"AAAA,OAAO,cAAc,CAAA;AAOrB,OAAO,EAAE,mBAAmB,EAA4B,MAAM,gCAAgC,CAAA;AAoC9F,iBAAe,MAAM,CAAC,QAAQ,UAAQ,EAAE,WAAW,CAAC,EAAE,OAAO,2SAoN5D;AAED,eAAe,MAAM,CAAA"}
@@ -26,6 +26,7 @@ declare const AppConfig: {
26
26
  QUEUE_ADMIN_CREDENTIALS: string;
27
27
  QUEUE_ADMIN_DISABLED: boolean;
28
28
  API_DOCUMENTATION_PASSWORD: string;
29
+ CORS_ORIGINS: string[];
29
30
  THRYVE_AUTH: string;
30
31
  THRYVE_API_BASE_URL: string;
31
32
  HEALTH_DATA_URL: string;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../src/config/config.ts"],"names":[],"mappings":"AAEA,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;AAC5C,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAAA;AACpE,wBAAgB,OAAO,CAAC,GAAG,EAAE,IAAI,GAAG,IAAI,CAAA;AACxC,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;AAyBlF,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiCd,CAAA;AAED,eAAe,SAAS,CAAA"}
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../src/config/config.ts"],"names":[],"mappings":"AAEA,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;AAC5C,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAAA;AACpE,wBAAgB,OAAO,CAAC,GAAG,EAAE,IAAI,GAAG,IAAI,CAAA;AACxC,wBAAgB,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;AAyBlF,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkCd,CAAA;AAED,eAAe,SAAS,CAAA"}
@@ -1829,7 +1829,7 @@
1829
1829
  "type": "boolean"
1830
1830
  },
1831
1831
  "basePeriod": {
1832
- "$ref": "#/definitions/TrendBasePeriodConfig"
1832
+ "$ref": "#/definitions/TrendPeriodConfig"
1833
1833
  },
1834
1834
  "conditionalProps": {
1835
1835
  "type": "array",
@@ -1860,36 +1860,23 @@
1860
1860
  "TrendPeriodConfig": {
1861
1861
  "type": "object",
1862
1862
  "properties": {
1863
- "value": {
1864
- "type": "number"
1865
- },
1866
1863
  "unit": {
1867
1864
  "$ref": "#/definitions/TrendPeriodUnit"
1868
- }
1869
- },
1870
- "required": ["value", "unit"],
1871
- "additionalProperties": false
1872
- },
1873
- "TrendPeriodUnit": {
1874
- "type": "string",
1875
- "enum": ["hour", "day", "week", "month", "records"]
1876
- },
1877
- "TrendBasePeriodConfig": {
1878
- "type": "object",
1879
- "properties": {
1865
+ },
1880
1866
  "fromValue": {
1881
1867
  "type": "number"
1882
1868
  },
1883
1869
  "toValue": {
1884
1870
  "type": "number"
1885
- },
1886
- "unit": {
1887
- "$ref": "#/definitions/TrendPeriodUnit"
1888
1871
  }
1889
1872
  },
1890
- "required": ["fromValue", "unit"],
1873
+ "required": ["unit", "fromValue", "toValue"],
1891
1874
  "additionalProperties": false
1892
1875
  },
1876
+ "TrendPeriodUnit": {
1877
+ "type": "string",
1878
+ "enum": ["hour", "day", "week", "month", "records"]
1879
+ },
1893
1880
  "TrendConditionalStyleProps": {
1894
1881
  "type": "object",
1895
1882
  "properties": {
@@ -1403,7 +1403,7 @@
1403
1403
  "type": "boolean"
1404
1404
  },
1405
1405
  "basePeriod": {
1406
- "$ref": "#/definitions/TrendBasePeriodConfig"
1406
+ "$ref": "#/definitions/TrendPeriodConfig"
1407
1407
  },
1408
1408
  "conditionalProps": {
1409
1409
  "type": "array",
@@ -1434,36 +1434,23 @@
1434
1434
  "TrendPeriodConfig": {
1435
1435
  "type": "object",
1436
1436
  "properties": {
1437
- "value": {
1438
- "type": "number"
1439
- },
1440
1437
  "unit": {
1441
1438
  "$ref": "#/definitions/TrendPeriodUnit"
1442
- }
1443
- },
1444
- "required": ["value", "unit"],
1445
- "additionalProperties": false
1446
- },
1447
- "TrendPeriodUnit": {
1448
- "type": "string",
1449
- "enum": ["hour", "day", "week", "month", "records"]
1450
- },
1451
- "TrendBasePeriodConfig": {
1452
- "type": "object",
1453
- "properties": {
1439
+ },
1454
1440
  "fromValue": {
1455
1441
  "type": "number"
1456
1442
  },
1457
1443
  "toValue": {
1458
1444
  "type": "number"
1459
- },
1460
- "unit": {
1461
- "$ref": "#/definitions/TrendPeriodUnit"
1462
1445
  }
1463
1446
  },
1464
- "required": ["fromValue", "unit"],
1447
+ "required": ["unit", "fromValue", "toValue"],
1465
1448
  "additionalProperties": false
1466
1449
  },
1450
+ "TrendPeriodUnit": {
1451
+ "type": "string",
1452
+ "enum": ["hour", "day", "week", "month", "records"]
1453
+ },
1467
1454
  "TrendConditionalStyleProps": {
1468
1455
  "type": "object",
1469
1456
  "properties": {
@@ -101,13 +101,9 @@ export interface SelectOptionMapping {
101
101
  chartValue: number;
102
102
  }
103
103
  export interface TrendPeriodConfig {
104
- value: number;
105
104
  unit: TrendPeriodUnit;
106
- }
107
- export interface TrendBasePeriodConfig {
108
105
  fromValue: number;
109
- toValue?: number;
110
- unit: TrendPeriodUnit;
106
+ toValue: number;
111
107
  }
112
108
  export interface TrendPresentationWidgetStyleFields {
113
109
  template?: string;
@@ -129,7 +125,7 @@ export interface TrendPresentationWidgetProps extends TrendPresentationWidgetSty
129
125
  aggregationType: string;
130
126
  comparisonPeriod?: TrendPeriodConfig;
131
127
  basePeriodSameAsComparison?: boolean;
132
- basePeriod?: TrendBasePeriodConfig;
128
+ basePeriod?: TrendPeriodConfig;
133
129
  conditionalProps?: TrendConditionalStyleProps[];
134
130
  }
135
131
  export type PresentationWidgetSettingsV2 = TextPresentationWidgetProps | IconPresentationWidgetProps | IconTextPresentationWidgetProps | LinkPresentationWidgetFields | TrendPresentationWidgetProps;
@@ -1 +1 @@
1
- {"version":3,"file":"PatientListProps.d.ts","sourceRoot":"","sources":["../../../../../../src/schemas/container_widget/widgetTypes/PatientListProps.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,wCAAwC,CAAA;AACxE,OAAO,EACL,2BAA2B,EAC3B,+BAA+B,EAC/B,4BAA4B,EAC5B,2BAA2B,EAC5B,MAAM,2BAA2B,CAAA;AAClC,OAAO,EAAE,2BAA2B,EAAE,MAAM,kDAAkD,CAAA;AAE9F;;;;;GAKG;AACH,MAAM,WAAW,aAAa;IAC5B,oEAAoE;IACpE,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,MAAM,WAAW,gBAAgB;IAC/B,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAA;IACtB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,kBAAkB,CAAC,EAAE,OAAO,CAAA;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACzB,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACjC,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,iBAAiB,CAAC,EAAE,gBAAgB,EAAE,CAAA;IACtC,OAAO,CAAC,EAAE,iBAAiB,EAAE,CAAA;IAC7B,UAAU,CAAC,EAAE,qBAAqB,CAAA;IAClC,aAAa,CAAC,EAAE,aAAa,CAAA;CAC9B;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,CAAC,EAAE,MAAM,EAAE,CAAA;IACjB,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,iBAAiB,CAA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,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB"}
1
+ {"version":3,"file":"PatientListProps.d.ts","sourceRoot":"","sources":["../../../../../../src/schemas/container_widget/widgetTypes/PatientListProps.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,wCAAwC,CAAA;AACxE,OAAO,EACL,2BAA2B,EAC3B,+BAA+B,EAC/B,4BAA4B,EAC5B,2BAA2B,EAC5B,MAAM,2BAA2B,CAAA;AAClC,OAAO,EAAE,2BAA2B,EAAE,MAAM,kDAAkD,CAAA;AAE9F;;;;;GAKG;AACH,MAAM,WAAW,aAAa;IAC5B,oEAAoE;IACpE,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,MAAM,WAAW,gBAAgB;IAC/B,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAA;IACtB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,kBAAkB,CAAC,EAAE,OAAO,CAAA;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACzB,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACjC,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,iBAAiB,CAAC,EAAE,gBAAgB,EAAE,CAAA;IACtC,OAAO,CAAC,EAAE,iBAAiB,EAAE,CAAA;IAC7B,UAAU,CAAC,EAAE,qBAAqB,CAAA;IAClC,aAAa,CAAC,EAAE,aAAa,CAAA;CAC9B;AAED,MAAM,WAAW,aAAa;IAC5B,MAAM,CAAC,EAAE,MAAM,EAAE,CAAA;IACjB,MAAM,CAAC,EAAE,YAAY,CAAA;IACrB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,iBAAiB,CAAC,EAAE,gBAAgB,EAAE,CAAA;IACtC,OAAO,CAAC,EAAE,iBAA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ACrC,IAAI,SAAS;IACb,KAAK,UAAU;CAChB;AAED,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,MAAM,CAAA;AAE9E,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,OAAO,CAAA;IACjB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC9B,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB;AAED,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,cAAc,CAAA;IACpB,QAAQ,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,MAAM,kBAAkB,GAAG,OAAO,GAAG,SAAS,CAAA;AAEpD,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,kBAAkB,CAAA;IAC1B,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAA;CACzC;AAED;;;;;;;;GAQG;AACH,MAAM,MAAM,gBAAgB,GAAG,MAAM,CAAA;AAErC,MAAM,MAAM,sBAAsB,GAAG;IACnC,CAAC,UAAU,EAAE,gBAAgB,GAAG;QAC9B,CAAC,SAAS,EAAE,MAAM,GAAG,YAAY,CAAA;KAClC,CAAA;CACF,CAAA;AAED,oBAAY,eAAe;IACzB,KAAK,UAAU;IACf,IAAI,SAAS;IACb,QAAQ,aAAa;IACrB,GAAG,QAAQ;IACX,GAAG,QAAQ;IACX,GAAG,QAAQ;IACX,GAAG,QAAQ;IACX,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,KAAK,UAAU;CAChB;AAED,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,eAAe,CAAA;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB"}
@@ -0,0 +1,46 @@
1
+ import { RelativePeriodConfig, TrendWindow, TrendWindowConfig } from './container-widget.schema';
2
+ /**
3
+ * Trend-widget time windows: the `value`/`from`/`to` → concrete-window resolution shared by the trend
4
+ * widget (front, viewer-local) and the health-data time-range filter (backend, UTC). Built on the
5
+ * generic calendar primitives of `global/dates` (which take the week start as a plain number) and the
6
+ * locale week-start resolver of `global/locale`, so the trend-specific rules live here in one place.
7
+ *
8
+ * The `utc` flag is forwarded to the primitives: `false` (default) uses the ambient local calendar
9
+ * (the front, viewer's timezone); `true` uses UTC (the backend). Both callers produce the exact same
10
+ * window for the same inputs and timezone.
11
+ */
12
+ /**
13
+ * Resolves a `from`/`to` range into a concrete, calendar-aligned window. `fromValue` and `toValue`
14
+ * are inclusive bucket offsets ("N units ago"), so the window covers the buckets from `toValue`-ago
15
+ * up to `fromValue`-ago and spans `fromValue − toValue + 1` buckets:
16
+ *
17
+ * - `start` (inclusive) = `getPeriodStart(now − fromValue·unit)` — start of the oldest bucket.
18
+ * - `end` (exclusive) = `now` when `toValue = 0` (the current, in-progress bucket is included,
19
+ * up to now); otherwise `getPeriodStart(now − (toValue − 1)·unit)` — the start of the bucket
20
+ * just after the newest included one, which drops the current bucket.
21
+ *
22
+ * Example (unit = week, weekStart = 1 Monday, now = Tue 2026-07-07):
23
+ * from 2, to 0 → [Mon 22 Jun, now) (3 weeks including the current one)
24
+ * from 3, to 1 → [Mon 15 Jun, Mon 06 Jul) (3 complete weeks, current one excluded)
25
+ */
26
+ export declare function resolveTrendWindow(nowMs: number, config: TrendWindowConfig, weekStart?: number, utc?: boolean): TrendWindow;
27
+ /**
28
+ * Resolves a count-based relative period into a concrete window — the single source of truth for the
29
+ * `value` → from/to mapping shared by every consumer (backend health-data filter, front trend widget),
30
+ * so the "current period counts as one of the N" rule is defined exactly once:
31
+ * - including it → `from = value - 1`, `to = 0` (buckets `value-1`…0 ago, ending now);
32
+ * - excluding it → `from = value`, `to = 1` (`value` complete buckets before the current one).
33
+ */
34
+ export declare function resolveRelativePeriod(nowMs: number, { value, unit, excludeCurrentPeriod }: RelativePeriodConfig, weekStart?: number, utc?: boolean): TrendWindow;
35
+ /**
36
+ * Resolves a count-based relative period into a formatted date range, keeping the whole calculation
37
+ * (from/to mapping + the day-level rule + formatting) in one shared place:
38
+ * - `daily`: date-only `YYYY-MM-DD`; when excluding the current period the inclusive end becomes the
39
+ * last completed calendar day (the day before the current period's start).
40
+ * - `discrete`: ISO-8601, with the exclusive upper bound used verbatim.
41
+ */
42
+ export declare function resolveRelativeDateRange(nowMs: number, config: RelativePeriodConfig, format: 'daily' | 'discrete', weekStart?: number, utc?: boolean): {
43
+ start_date: string;
44
+ end_date: string;
45
+ };
46
+ //# sourceMappingURL=container-widget.helper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"container-widget.helper.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/ecosystem/container-widget/container-widget.helper.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,oBAAoB,EAAE,KAAK,WAAW,EAAE,KAAK,iBAAiB,EAAE,MAAM,2BAA2B,CAAA;AAE/G;;;;;;;;;GASG;AAEH;;;;;;;;;;;;;GAaG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,iBAAiB,EACzB,SAAS,GAAE,MAAuB,EAClC,GAAG,UAAQ,GACV,WAAW,CAOb;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CACnC,KAAK,EAAE,MAAM,EACb,EAAE,KAAK,EAAE,IAAI,EAAE,oBAA4B,EAAE,EAAE,oBAAoB,EACnE,SAAS,GAAE,MAAuB,EAClC,GAAG,UAAQ,GACV,WAAW,CAOb;AAED;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,oBAAoB,EAC5B,MAAM,EAAE,OAAO,GAAG,UAAU,EAC5B,SAAS,GAAE,MAAuB,EAClC,GAAG,UAAQ,GACV;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,CAQ1C"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=container-widget.helper.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"container-widget.helper.test.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/ecosystem/container-widget/container-widget.helper.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,22 @@
1
+ import { PeriodUnit } from '../../global/dates/dates.schema';
2
+ /**
3
+ * Calendar-aligned relative time window contracts, shared by the trend widget (front, viewer-local)
4
+ * and the health-data time-range filter (backend, UTC). Pure types/constants only — the calculation
5
+ * logic that consumes them lives in `container-widget.helper.ts`.
6
+ */
7
+ export type TrendWindowUnit = PeriodUnit;
8
+ export interface TrendWindowConfig {
9
+ fromValue: number;
10
+ toValue?: number;
11
+ unit: TrendWindowUnit;
12
+ }
13
+ export interface TrendWindow {
14
+ start: number;
15
+ end: number;
16
+ }
17
+ export interface RelativePeriodConfig {
18
+ value: number;
19
+ unit: TrendWindowUnit;
20
+ excludeCurrentPeriod?: boolean;
21
+ }
22
+ //# sourceMappingURL=container-widget.schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"container-widget.schema.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/ecosystem/container-widget/container-widget.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,iCAAiC,CAAA;AAEjE;;;;GAIG;AAIH,MAAM,MAAM,eAAe,GAAG,UAAU,CAAA;AAExC,MAAM,WAAW,iBAAiB;IAEhC,SAAS,EAAE,MAAM,CAAA;IAGjB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,IAAI,EAAE,eAAe,CAAA;CACtB;AAGD,MAAM,WAAW,WAAW;IAC1B,KAAK,EAAE,MAAM,CAAA;IACb,GAAG,EAAE,MAAM,CAAA;CACZ;AAID,MAAM,WAAW,oBAAoB;IACnC,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,eAAe,CAAA;IACrB,oBAAoB,CAAC,EAAE,OAAO,CAAA;CAC/B"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"container-widget.service.test.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/ecosystem/container-widget/container-widget.service.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ export * from './container-widget.schema';
2
+ export * from './container-widget.helper';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/ecosystem/container-widget/index.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAA;AACzC,cAAc,2BAA2B,CAAA"}
@@ -0,0 +1,3 @@
1
+ export * from './container-widget.schema';
2
+ export { resolveTrendWindow, resolveRelativePeriod, resolveRelativeDateRange } from './container-widget.helper';
3
+ //# sourceMappingURL=lib.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lib.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/ecosystem/container-widget/lib.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAA;AACzC,OAAO,EAAE,kBAAkB,EAAE,qBAAqB,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAA"}
@@ -0,0 +1,17 @@
1
+ import { default as dayjs } from 'dayjs';
2
+ import { PeriodUnit } from './dates.schema';
3
+ export declare const DEFAULT_WEEK_START = 1;
4
+ export declare function toCalendar(ms: number, utc: boolean): dayjs.Dayjs;
5
+ /**
6
+ * Aligns an instant to the start of the calendar period it falls in:
7
+ * weeks → the injected first weekday at midnight, months → the 1st at midnight,
8
+ * days → midnight, hours → the start of the hour. `utc` runs the alignment in UTC.
9
+ */
10
+ export declare function getPeriodStart(ms: number, unit: PeriodUnit, weekStart?: number, utc?: boolean): number;
11
+ /**
12
+ * Subtracts `value` whole calendar periods from an instant, without aligning. Month subtraction
13
+ * clamps to the last day of the target month (e.g. 31 Mar − 1 month → 28 Feb), which dayjs does
14
+ * natively. `utc` runs the arithmetic in UTC.
15
+ */
16
+ export declare function subtractPeriods(ms: number, value: number, unit: PeriodUnit, utc?: boolean): number;
17
+ //# sourceMappingURL=dates.helper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dates.helper.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/global/dates/dates.helper.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAmBhD,eAAO,MAAM,kBAAkB,IAAI,CAAA;AAGnC,wBAAgB,UAAU,CAAC,EAAE,EAAE,MAAM,EAAE,GAAG,EAAE,OAAO,GAAG,KAAK,CAAC,KAAK,CAEhE;AAQD;;;;GAIG;AACH,wBAAgB,cAAc,CAC5B,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,UAAU,EAChB,SAAS,GAAE,MAA2B,EACtC,GAAG,UAAQ,GACV,MAAM,CAQR;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,EAAE,GAAG,UAAQ,GAAG,MAAM,CAEhG"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=dates.helper.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dates.helper.test.d.ts","sourceRoot":"","sources":["../../../../../../../src/v2/modules/global/dates/dates.helper.test.ts"],"names":[],"mappings":""}