@mx-cartographer/experiences 9.1.0 → 9.1.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 (35) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/dist/{AccountDetailsDrawer-CZPeLsCq.mjs → AccountDetailsDrawer-C1hhmlmI.mjs} +2 -2
  3. package/dist/{AccountDetailsDrawer-CZPeLsCq.mjs.map → AccountDetailsDrawer-C1hhmlmI.mjs.map} +1 -1
  4. package/dist/AccountDetailsHeader-BliEZhz7.mjs +230 -0
  5. package/dist/AccountDetailsHeader-BliEZhz7.mjs.map +1 -0
  6. package/dist/AccountUtils-Cbh8r9cP.mjs +29 -0
  7. package/dist/AccountUtils-Cbh8r9cP.mjs.map +1 -0
  8. package/dist/{ManageIncome-Dcsnnz86.mjs → ManageIncome-Be9WHv-s.mjs} +3 -3
  9. package/dist/{ManageIncome-Dcsnnz86.mjs.map → ManageIncome-Be9WHv-s.mjs.map} +1 -1
  10. package/dist/{NetWorthUtils-DfSH3z70.mjs → NetWorthUtils-Dj7CgAg2.mjs} +2 -2
  11. package/dist/{NetWorthUtils-DfSH3z70.mjs.map → NetWorthUtils-Dj7CgAg2.mjs.map} +1 -1
  12. package/dist/{RecurringSettings-D8hBbXV_.mjs → RecurringSettings-kRqAViNn.mjs} +2 -2
  13. package/dist/{RecurringSettings-D8hBbXV_.mjs.map → RecurringSettings-kRqAViNn.mjs.map} +1 -1
  14. package/dist/{UserStore-C1fdL3Iu.mjs → UserStore-BjnNCO5a.mjs} +266 -199
  15. package/dist/UserStore-BjnNCO5a.mjs.map +1 -0
  16. package/dist/accounts/index.es.js +4 -4
  17. package/dist/budgets/index.es.js +1 -1
  18. package/dist/cashflow/context/hooks.d.ts +7 -6
  19. package/dist/cashflow/index.es.js +435 -463
  20. package/dist/cashflow/index.es.js.map +1 -1
  21. package/dist/common/index.es.js +1 -1
  22. package/dist/core/index.es.js +1 -1
  23. package/dist/core/stores/CashflowStore.d.ts +8 -7
  24. package/dist/core/stores/RecurringTransactionsStore.d.ts +24 -0
  25. package/dist/core/utils/AccountUtils.d.ts +8 -0
  26. package/dist/debts/index.es.js +1 -1
  27. package/dist/finstrong/index.es.js +3 -3
  28. package/dist/networth/index.es.js +1 -1
  29. package/dist/recurringtransactions/index.es.js +4 -4
  30. package/package.json +1 -1
  31. package/dist/AccountDetailsHeader-BvbCUQSS.mjs +0 -231
  32. package/dist/AccountDetailsHeader-BvbCUQSS.mjs.map +0 -1
  33. package/dist/AccountUtils-B8ZzWI-d.mjs +0 -28
  34. package/dist/AccountUtils-B8ZzWI-d.mjs.map +0 -1
  35. package/dist/UserStore-C1fdL3Iu.mjs.map +0 -1
@@ -1,43 +1,43 @@
1
1
  import { makeAutoObservable as d, runInAction as c, reaction as ut, autorun as St, observable as Tt } from "mobx";
2
- import { d as At } from "./AccountUtils-B8ZzWI-d.mjs";
3
- import { i as wt, f as bt, b as It, c as k } from "./BudgetUtil-Bg2AQJpQ.mjs";
4
- import { c as h, d as M } from "./Account-DR7Plrqy.mjs";
5
- import { F as g, B as v, G as H } from "./GlobalCopyApi-wcnDUzMV.mjs";
2
+ import { d as At, g as wt } from "./AccountUtils-Cbh8r9cP.mjs";
3
+ import { i as bt, f as It, b as Ct, c as W } from "./BudgetUtil-Bg2AQJpQ.mjs";
4
+ import { c as h, d as O } from "./Account-DR7Plrqy.mjs";
5
+ import { F as g, B as $, G as V } from "./GlobalCopyApi-wcnDUzMV.mjs";
6
6
  import { A as i } from "./ApiEndpoints-DXwIYNUV.mjs";
7
- import Ct from "posthog-js";
7
+ import Et from "posthog-js";
8
8
  import { endOfMonth as T } from "date-fns/endOfMonth";
9
9
  import { startOfMonth as E } from "date-fns/startOfMonth";
10
10
  import { startOfToday as y } from "date-fns/startOfToday";
11
- import { C as w, b as Et } from "./Category-DEKZGLYe.mjs";
12
- import { addDays as Rt } from "date-fns/addDays";
13
- import { differenceInDays as Dt } from "date-fns/differenceInDays";
14
- import { isBefore as F } from "date-fns/isBefore";
11
+ import { C as w, b as Rt } from "./Category-DEKZGLYe.mjs";
12
+ import { addDays as Dt } from "date-fns/addDays";
13
+ import { differenceInDays as Lt } from "date-fns/differenceInDays";
14
+ import { isBefore as H } from "date-fns/isBefore";
15
15
  import { getUnixTime as m } from "date-fns/getUnixTime";
16
- import { subMonths as $ } from "date-fns/subMonths";
17
- import { c as Lt, d as vt, C as $t, h as Gt, i as Nt, s as Bt, j as xt, T as Mt, D as Ot } from "./TransactionUtils-BphBJBbU.mjs";
18
- import { l as Pt, D as Ut } from "./DebtUtils-i4pI2Uoe.mjs";
19
- import { format as Ft } from "date-fns/format";
20
- import { fromUnixTime as kt } from "date-fns/fromUnixTime";
21
- import { f as P, D as U } from "./DateFormats-HudZ3Bjs.mjs";
22
- import { T as S, c as W } from "./GoalsUtil-C9EnLWvC.mjs";
23
- import { A as Ht, m as Wt, a as Vt, b as zt } from "./InvestmentUtil-BItV7uEs.mjs";
24
- import { f as Kt, b as Qt, a as V, c as qt, d as Yt, e as jt, s as Xt } from "./NetWorthUtils-DfSH3z70.mjs";
25
- import { f as Jt } from "./NotificationUtils-BRGFTePr.mjs";
26
- import { isAfter as z } from "date-fns/isAfter";
27
- import { isSameDay as K } from "date-fns/isSameDay";
16
+ import { subMonths as G } from "date-fns/subMonths";
17
+ import { c as vt, d as $t, C as Gt, h as Nt, i as Bt, s as xt, j as Mt, T as Ot, D as Pt } from "./TransactionUtils-BphBJBbU.mjs";
18
+ import { l as Ft, D as Ut } from "./DebtUtils-i4pI2Uoe.mjs";
19
+ import { format as kt } from "date-fns/format";
20
+ import { fromUnixTime as Ht } from "date-fns/fromUnixTime";
21
+ import { f as U, D as k } from "./DateFormats-HudZ3Bjs.mjs";
22
+ import { T as S, c as z } from "./GoalsUtil-C9EnLWvC.mjs";
23
+ import { A as Wt, m as Vt, a as zt, b as Kt } from "./InvestmentUtil-BItV7uEs.mjs";
24
+ import { f as Qt, b as qt, a as K, c as Yt, d as jt, e as Xt, s as Jt } from "./NetWorthUtils-Dj7CgAg2.mjs";
25
+ import { f as Zt } from "./NotificationUtils-BRGFTePr.mjs";
26
+ import { isAfter as P } from "date-fns/isAfter";
27
+ import { isSameDay as Q } from "date-fns/isSameDay";
28
28
  import { isWithinInterval as gt } from "date-fns/isWithinInterval";
29
29
  import { subDays as pt } from "date-fns/subDays";
30
- import { f as O, h as Zt, a as f, b as Q } from "./RecurringTransactionsUtil-CHWmqvW5.mjs";
31
- import { I as u, A as _, B as G } from "./Notification-DTNYSd8P.mjs";
30
+ import { f as F, h as te, b as L, a as f } from "./RecurringTransactionsUtil-CHWmqvW5.mjs";
31
+ import { I as u, A as _, B as N } from "./Notification-DTNYSd8P.mjs";
32
32
  import { endOfToday as q } from "date-fns/endOfToday";
33
- import { formatISO as te } from "date-fns/formatISO";
34
- import { addSeconds as ee } from "date-fns/addSeconds";
35
- import { differenceInCalendarMonths as se } from "date-fns/differenceInCalendarMonths";
36
- import { f as ae, b as ne } from "./TrendsUtil-D9z3kIj_.mjs";
37
- import { addMonths as ie } from "date-fns/addMonths";
38
- import { getMonth as L } from "date-fns/getMonth";
39
- import { a as re } from "./Help-CkQTjORd.mjs";
40
- class N {
33
+ import { formatISO as ee } from "date-fns/formatISO";
34
+ import { addSeconds as se } from "date-fns/addSeconds";
35
+ import { differenceInCalendarMonths as ae } from "date-fns/differenceInCalendarMonths";
36
+ import { f as ne, b as ie } from "./TrendsUtil-D9z3kIj_.mjs";
37
+ import { addMonths as re } from "date-fns/addMonths";
38
+ import { getMonth as v } from "date-fns/getMonth";
39
+ import { a as oe } from "./Help-CkQTjORd.mjs";
40
+ class B {
41
41
  fetchInstance;
42
42
  constructor(t, e, s) {
43
43
  this.fetchInstance = new g(t, e, void 0, s);
@@ -245,7 +245,7 @@ class rt {
245
245
  updateUserCommunicationProfile = async (t) => this.fetchInstance.put(i.USER_COMMUNICATION_PROFILE, t).then((e) => e.user_communication_profile);
246
246
  getInsightsNotificationProfiles = async () => this.fetchInstance.get(`${i.NOTIFICATION_PROFILES}/${i.INSIGHTS_NOTIFICATION_PROFILES}`).then((t) => t);
247
247
  }
248
- class B {
248
+ class x {
249
249
  fetchInstance;
250
250
  constructor(t, e, s) {
251
251
  this.fetchInstance = new g(t, e, void 0, s);
@@ -343,9 +343,9 @@ class ct {
343
343
  }
344
344
  requestWidgetUrl = async (t) => this.fetchInstance.post(i.WIDGET_URLS, t).then((e) => e.widget_url);
345
345
  }
346
- class oe {
346
+ class ce {
347
347
  globalStore;
348
- api = new N("/", "");
348
+ api = new B("/", "");
349
349
  accounts = [];
350
350
  accountsLoaded = !1;
351
351
  accountsLoading = !1;
@@ -357,7 +357,7 @@ class oe {
357
357
  membersLoading = !1;
358
358
  uiStore;
359
359
  constructor(t) {
360
- this.globalStore = t, this.uiStore = new ce(), this.api = new N(t.endpoint, t.sessionToken, t.onError), d(this);
360
+ this.globalStore = t, this.uiStore = new le(), this.api = new B(t.endpoint, t.sessionToken, t.onError), d(this);
361
361
  }
362
362
  loadAccountData = async () => {
363
363
  await Promise.all([this.loadAccounts(), this.loadMembers(), this.loadInstitutions()]);
@@ -366,7 +366,7 @@ class oe {
366
366
  return this.accountsLoaded && this.membersLoaded && this.institutionsLoaded;
367
367
  }
368
368
  get detailedAccounts() {
369
- const t = this.globalStore.userStore.userFeatures, e = wt(t, "MD_EXCLUDE_EXTERNAL_ACCOUNTS"), s = this.globalStore.appConfig.config.display_only_external_accounts_in_accounts && this.globalStore.appConfig.options.subtype === "accounts";
369
+ const t = this.globalStore.userStore.userFeatures, e = bt(t, "MD_EXCLUDE_EXTERNAL_ACCOUNTS"), s = this.globalStore.appConfig.config.display_only_external_accounts_in_accounts && this.globalStore.appConfig.options.subtype === "accounts";
370
370
  return At(
371
371
  this.accounts,
372
372
  this.institutions,
@@ -420,7 +420,7 @@ class oe {
420
420
  }
421
421
  get retirementAccounts() {
422
422
  return this.detailedAccounts.filter(
423
- (t) => t.account_type === h.INVESTMENT || t.account_type === h.SAVINGS || t.account_type === h.CHECKING || t.account_type === h.CASH || t.account_type === h.PROPERTY || t.account_type === h.INSURANCE && (t.account_subtype === M.WHOLE_LIFE || t.account_subtype === M.UNIVERSAL_LIFE || t.account_subtype === M.VARIABLE_UNIVERSAL_LIFE)
423
+ (t) => t.account_type === h.INVESTMENT || t.account_type === h.SAVINGS || t.account_type === h.CHECKING || t.account_type === h.CASH || t.account_type === h.PROPERTY || t.account_type === h.INSURANCE && (t.account_subtype === O.WHOLE_LIFE || t.account_subtype === O.UNIVERSAL_LIFE || t.account_subtype === O.VARIABLE_UNIVERSAL_LIFE)
424
424
  );
425
425
  }
426
426
  get visibleAccounts() {
@@ -580,7 +580,7 @@ class oe {
580
580
  this.setAccounts(a);
581
581
  };
582
582
  }
583
- let ce = class {
583
+ let le = class {
584
584
  selectedAccount = {};
585
585
  selectedMember = {};
586
586
  constructor() {
@@ -589,7 +589,7 @@ let ce = class {
589
589
  setSelectedAccount = (t) => this.selectedAccount = t;
590
590
  setSelectedMember = (t) => this.selectedMember = t;
591
591
  };
592
- class le {
592
+ class de {
593
593
  globalStore;
594
594
  api = new Y("/", "");
595
595
  bannerApi = new j("/");
@@ -642,7 +642,7 @@ class le {
642
642
  setUserCommunicationProfile = (t) => this.appData.user_communication_profile = t;
643
643
  setUserProfile = (t) => this.appData.user_profile = t;
644
644
  }
645
- class de {
645
+ class he {
646
646
  globalStore;
647
647
  survey = null;
648
648
  currentQuestionIndex = 0;
@@ -672,7 +672,7 @@ class de {
672
672
  return this.survey ? this.survey.questions : [];
673
673
  }
674
674
  loadSurvey = (t = !1) => {
675
- Ct.getActiveMatchingSurveys((e) => {
675
+ Et.getActiveMatchingSurveys((e) => {
676
676
  c(() => {
677
677
  if (e.length > 0) {
678
678
  const s = e.find((a) => a.id === this.surveyId);
@@ -691,11 +691,11 @@ class de {
691
691
  this.response = t, this.question && (this.responses[`$survey_response_${this.question.id}`] = t);
692
692
  };
693
693
  }
694
- function he(n, t, e, s = "asc") {
694
+ function ue(n, t, e, s = "asc") {
695
695
  const a = s === "desc" ? -1 : 1;
696
696
  return [...n, ...t].sort((o, r) => o[e] < r[e] ? -1 * a : o[e] > r[e] ? 1 * a : 0);
697
697
  }
698
- const ue = (n) => ({
698
+ const ge = (n) => ({
699
699
  ...n,
700
700
  //fields that are offer specific, adding here for visibility
701
701
  image_url: n.image_url,
@@ -738,19 +738,19 @@ const ue = (n) => ({
738
738
  user_guid: "",
739
739
  user_verification: 0
740
740
  });
741
- class ge {
741
+ class pe {
742
742
  globalStore;
743
- api = new v("/", "");
743
+ api = new $("/", "");
744
744
  beats = [];
745
745
  isLoading = !1;
746
746
  constructor(t) {
747
- this.globalStore = t, this.api = new v(t.endpoint, t.sessionToken, t.onError), d(this);
747
+ this.globalStore = t, this.api = new $(t.endpoint, t.sessionToken, t.onError), d(this);
748
748
  }
749
749
  loadBeats = async () => {
750
750
  this.isLoading = !0;
751
- const t = await this.api.getBeats(), s = (await this.api.getOffers()).map((a) => ue(a));
751
+ const t = await this.api.getBeats(), s = (await this.api.getOffers()).map((a) => ge(a));
752
752
  c(() => {
753
- this.beats = he(t, s, "active_at", "desc"), this.isLoading = !1;
753
+ this.beats = ue(t, s, "active_at", "desc"), this.isLoading = !1;
754
754
  });
755
755
  };
756
756
  getFilteredBeats(t) {
@@ -767,7 +767,7 @@ class ge {
767
767
  return t.filter((s) => e.some((a) => s.template === a));
768
768
  }
769
769
  }
770
- class pe {
770
+ class _e {
771
771
  api = new X("/", "");
772
772
  globalStore;
773
773
  alert = "";
@@ -787,9 +787,9 @@ class pe {
787
787
  (t) => {
788
788
  if (t) {
789
789
  const e = this.selectedBudget;
790
- e && (this.selectedBudget = bt(t, e.guid));
790
+ e && (this.selectedBudget = It(t, e.guid));
791
791
  const s = this.selectedSubBudget;
792
- s && s.parent_guid && (this.selectedSubBudget = It(
792
+ s && s.parent_guid && (this.selectedSubBudget = Ct(
793
793
  t,
794
794
  s.guid,
795
795
  s.parent_guid
@@ -799,7 +799,7 @@ class pe {
799
799
  );
800
800
  };
801
801
  get detailedBudgets() {
802
- return k(
802
+ return W(
803
803
  this.budgets.filter(
804
804
  (t) => t.category_guid !== w.INCOME && t.category_guid !== w.TRANSFER && t.category_guid !== w.INVESTMENTS
805
805
  ),
@@ -810,7 +810,7 @@ class pe {
810
810
  }
811
811
  // TODO: Replace this with income from recurring transactions. Income budgets are deprecated.
812
812
  get incomeBudget() {
813
- return k(
813
+ return W(
814
814
  this.budgets.filter((s) => !s.parent_guid),
815
815
  this.globalStore.categoryStore.detailedCategories,
816
816
  this.globalStore.copyStore.copy.budgets,
@@ -935,11 +935,11 @@ class pe {
935
935
  }
936
936
  };
937
937
  }
938
- class _e {
938
+ class fe {
939
939
  globalStore;
940
940
  uiStore;
941
941
  constructor(t) {
942
- this.globalStore = t, this.uiStore = new fe(), d(this);
942
+ this.globalStore = t, this.uiStore = new ye(t), d(this);
943
943
  }
944
944
  completeOnboarding = async () => {
945
945
  const t = {
@@ -949,36 +949,63 @@ class _e {
949
949
  await this.globalStore.userStore.updateUserProfile(t);
950
950
  };
951
951
  }
952
- let fe = class {
953
- // Cashflow is hard-coded to display 30 days starting from today
954
- dateRange = { start: y(), end: Rt(y(), 30) };
952
+ let ye = class {
953
+ globalStore;
954
+ // Cashflow is hard-coded to display 30 days starting from today. This is the
955
+ // single source of truth for Cash Flow's window; it intentionally does NOT
956
+ // mutate RecurringTransactionsStore.dateRange, so Cash Flow stays decoupled
957
+ // from other widgets (e.g. Recurring Transactions) that drive that shared range.
958
+ dateRange = { start: y(), end: Dt(y(), 30) };
955
959
  isDirty = !1;
956
- nextIncome = void 0;
957
- upcomingExpenses = [];
958
- selectedCashAccounts = [];
959
- constructor() {
960
- d(this);
960
+ constructor(t) {
961
+ this.globalStore = t, d(this);
962
+ }
963
+ // Recurrence data scoped to Cash Flow's own dateRange, sourced from the
964
+ // range-parameterized helpers on RecurringTransactionsStore. Computeds (not
965
+ // component state) per the project's MobX conventions.
966
+ get income() {
967
+ return this.globalStore.recurringTransactionsStore.incomeForRange(this.dateRange);
968
+ }
969
+ get upcomingIncome() {
970
+ return this.globalStore.recurringTransactionsStore.upcomingIncomeForRange(this.dateRange);
971
+ }
972
+ get upcomingExpenses() {
973
+ return this.globalStore.recurringTransactionsStore.upcomingExpensesForRange(this.dateRange);
974
+ }
975
+ get nextIncome() {
976
+ return this.globalStore.recurringTransactionsStore.nextIncomeForRange(this.dateRange);
977
+ }
978
+ // Visible cash accounts that are currently selected in the account filter.
979
+ // Computed (single source of truth) so it stays in sync with account data and
980
+ // the filter without effect-based syncing in components.
981
+ get selectedCashAccounts() {
982
+ const { selectedAccountGuids: t } = this.globalStore.globalUiStore;
983
+ return this.globalStore.accountStore.visibleCashAccounts.filter(
984
+ (e) => t.includes(e.guid)
985
+ );
986
+ }
987
+ // Total spendable/starting balance across the selected cash accounts, using
988
+ // the shared per-account balance rule (available vs current balance).
989
+ get selectedCashBalance() {
990
+ const t = this.globalStore.appConfig.config.display_available_balance_in_accounts;
991
+ return this.selectedCashAccounts.reduce(
992
+ (e, s) => e + wt(s, t),
993
+ 0
994
+ );
961
995
  }
962
996
  // Returns the number of days until the next income activity or 0 if there is no income activity
963
997
  get daysUntilNextIncome() {
964
- return this.nextIncome ? Math.abs(Dt(y(), this.nextIncome.expectedDate)) : 0;
998
+ return this.nextIncome ? Math.abs(Lt(y(), this.nextIncome.expectedDate)) : 0;
965
999
  }
966
1000
  // Returns the expenses (Activities) until the next income activity or the end of the month
967
1001
  // if there is no income activity
968
1002
  get expensesTilNextIncome() {
969
1003
  return this.upcomingExpenses.filter(
970
- (t) => F(t.expectedDate, this.nextIncome?.expectedDate || T(/* @__PURE__ */ new Date()))
1004
+ (t) => H(t.expectedDate, this.nextIncome?.expectedDate || T(/* @__PURE__ */ new Date()))
971
1005
  );
972
1006
  }
973
- setNextIncome = (t) => {
974
- this.nextIncome = t;
975
- };
976
- setUpcomingExpenses = (t) => {
977
- this.upcomingExpenses = t;
978
- };
979
- setSelectedCashAccounts = (t) => this.selectedCashAccounts = t;
980
1007
  };
981
- class ye {
1008
+ class me {
982
1009
  globalStore;
983
1010
  uiStore;
984
1011
  api = new J("/", "");
@@ -992,10 +1019,10 @@ class ye {
992
1019
  monthlyTotalsLoaded = !1;
993
1020
  monthlyTotalsLoading = !1;
994
1021
  constructor(t) {
995
- this.globalStore = t, this.uiStore = new me(), this.api = new J(t.endpoint, t.sessionToken, t.onError), d(this);
1022
+ this.globalStore = t, this.uiStore = new Se(), this.api = new J(t.endpoint, t.sessionToken, t.onError), d(this);
996
1023
  }
997
1024
  get detailedCategories() {
998
- return this.globalStore.isInitialized ? Lt(
1025
+ return this.globalStore.isInitialized ? vt(
999
1026
  this.categories,
1000
1027
  this.globalStore.copyStore.copy.categories,
1001
1028
  this.dateRangeCategoryTotals,
@@ -1003,7 +1030,7 @@ class ye {
1003
1030
  ) : [];
1004
1031
  }
1005
1032
  get detailedCategoriesWithTransactions() {
1006
- return vt(
1033
+ return $t(
1007
1034
  this.detailedCategories,
1008
1035
  this.globalStore.transactionStore.sortedTransactions
1009
1036
  );
@@ -1068,7 +1095,7 @@ class ye {
1068
1095
  loadMonthlyCategoryTotals = async (t = this.globalStore.globalUiStore.selectedAccounts, e, s) => {
1069
1096
  if (this.monthlyTotalsLoading) return;
1070
1097
  this.monthlyTotalsLoading = !0;
1071
- const a = m(E(e ?? $(/* @__PURE__ */ new Date(), 11))), o = m(T(s ?? /* @__PURE__ */ new Date()));
1098
+ const a = m(E(e ?? G(/* @__PURE__ */ new Date(), 11))), o = m(T(s ?? /* @__PURE__ */ new Date()));
1072
1099
  try {
1073
1100
  const r = await this.api.getMonthlyCategoryTotals(a, o, t);
1074
1101
  this.setMonthlyCategoryTotals(r);
@@ -1077,7 +1104,7 @@ class ye {
1077
1104
  }
1078
1105
  };
1079
1106
  reloadCategoryTotals = async (t, e, s) => {
1080
- const a = e ?? $(/* @__PURE__ */ new Date(), 11), o = s ?? T(/* @__PURE__ */ new Date());
1107
+ const a = e ?? G(/* @__PURE__ */ new Date(), 11), o = s ?? T(/* @__PURE__ */ new Date());
1081
1108
  try {
1082
1109
  await Promise.all([
1083
1110
  this.loadMonthlyCategoryTotals(t, a, o),
@@ -1102,9 +1129,9 @@ class ye {
1102
1129
  }
1103
1130
  };
1104
1131
  // TODO: Remove this after refactoring Trends components to use detailedCategories
1105
- getCategoryName = (t) => this.categories.find((s) => s.guid === t)?.name ?? Et[t];
1132
+ getCategoryName = (t) => this.categories.find((s) => s.guid === t)?.name ?? Rt[t];
1106
1133
  }
1107
- let me = class {
1134
+ let Se = class {
1108
1135
  expandedGuid = null;
1109
1136
  selectedGuid = null;
1110
1137
  searchValue = "";
@@ -1127,7 +1154,7 @@ let me = class {
1127
1154
  onSelect = (t) => this.savedOnSelect(t);
1128
1155
  setOnSelect = (t) => this.savedOnSelect = t;
1129
1156
  };
1130
- class Se {
1157
+ class Te {
1131
1158
  globalStore;
1132
1159
  widgetApi = new ct("/", "");
1133
1160
  constructor(t) {
@@ -1137,21 +1164,21 @@ class Se {
1137
1164
  widget_url: { widget_type: t, color_scheme: e, ...s }
1138
1165
  });
1139
1166
  }
1140
- class Te {
1167
+ class Ae {
1141
1168
  globalStore;
1142
1169
  uiStore;
1143
1170
  constructor(t) {
1144
- this.globalStore = t, this.uiStore = new Ae(), d(this);
1171
+ this.globalStore = t, this.uiStore = new we(), d(this);
1145
1172
  }
1146
1173
  get debts() {
1147
1174
  const { visibleDebtAccounts: t } = this.globalStore.accountStore, { selectedAccountGuids: e } = this.globalStore.globalUiStore, { debtGoals: s } = this.globalStore.goalStore, a = e.length ? t.filter((o) => e.includes(o.guid)) : t;
1148
- return Pt(a, s);
1175
+ return Ft(a, s);
1149
1176
  }
1150
1177
  get totalMonthlyPayments() {
1151
1178
  return this.debts.map((e) => Number(e.monthly_payment)).filter((e) => !isNaN(e)).reduce((e, s) => e + s, 0);
1152
1179
  }
1153
1180
  }
1154
- let Ae = class {
1181
+ let we = class {
1155
1182
  isLoading = !1;
1156
1183
  selectedDebtChartData = {};
1157
1184
  selectedDebtPriority = Ut.LOWEST_BALANCE;
@@ -1169,16 +1196,16 @@ let Ae = class {
1169
1196
  setSelectedDebtChartData = (t) => this.selectedDebtChartData = t;
1170
1197
  setSelectedDebtPriority = (t) => this.selectedDebtPriority = t;
1171
1198
  };
1172
- const we = (n) => n.sort((t, e) => t.monthly_health_score_average.year !== e.monthly_health_score_average.year ? t.monthly_health_score_average.year - e.monthly_health_score_average.year : t.monthly_health_score_average.month - e.monthly_health_score_average.month).map((t) => ({
1173
- x: P(
1199
+ const be = (n) => n.sort((t, e) => t.monthly_health_score_average.year !== e.monthly_health_score_average.year ? t.monthly_health_score_average.year - e.monthly_health_score_average.year : t.monthly_health_score_average.month - e.monthly_health_score_average.month).map((t) => ({
1200
+ x: U(
1174
1201
  new Date(0, t.monthly_health_score_average.month - 1, 1),
1175
- U.MONTH_SHORT
1202
+ k.MONTH_SHORT
1176
1203
  ),
1177
1204
  y: Math.round(t.monthly_health_score_average.average_health_score)
1178
- })), be = (n) => n.map(({ transaction: e }) => ({
1205
+ })), Ie = (n) => n.map(({ transaction: e }) => ({
1179
1206
  ...e
1180
1207
  })).sort((e, s) => s.date - e.date);
1181
- class Ie {
1208
+ class Ce {
1182
1209
  api = new Z("/", "");
1183
1210
  augmentedChartData = [];
1184
1211
  averageHealthScores = [];
@@ -1258,7 +1285,7 @@ class Ie {
1258
1285
  }
1259
1286
  };
1260
1287
  loadHealthScoreChangeReports = async () => {
1261
- const t = m($(/* @__PURE__ */ new Date(), 2)), e = m(/* @__PURE__ */ new Date());
1288
+ const t = m(G(/* @__PURE__ */ new Date(), 2)), e = m(/* @__PURE__ */ new Date());
1262
1289
  try {
1263
1290
  const s = await this.api.getHealthScoreChangeReports(
1264
1291
  t,
@@ -1272,7 +1299,7 @@ class Ie {
1272
1299
  }
1273
1300
  };
1274
1301
  loadPeerScore = async () => {
1275
- const t = Ft(kt(this.globalStore.appDataStore.user.birthday), "yyyy");
1302
+ const t = kt(Ht(this.globalStore.appDataStore.user.birthday), "yyyy");
1276
1303
  try {
1277
1304
  const e = await this.api.getPeerScore(t);
1278
1305
  c(() => {
@@ -1286,7 +1313,7 @@ class Ie {
1286
1313
  try {
1287
1314
  const t = await this.api.getAverageHealthScores();
1288
1315
  c(() => {
1289
- this.augmentedChartData = we(t);
1316
+ this.augmentedChartData = be(t);
1290
1317
  });
1291
1318
  } catch (t) {
1292
1319
  console.error(`Error occurred while getting augmented chart data: ${t}`);
@@ -1294,7 +1321,7 @@ class Ie {
1294
1321
  };
1295
1322
  getSpendingFeeTransactions = async () => {
1296
1323
  try {
1297
- const t = await this.api.getSpendingFeeTransactions(), e = be(t);
1324
+ const t = await this.api.getSpendingFeeTransactions(), e = Ie(t);
1298
1325
  c(() => {
1299
1326
  this.spendingFeeTransactions = e;
1300
1327
  });
@@ -1431,7 +1458,7 @@ const lt = {
1431
1458
  postHogPublicKey: "phc_1fVYJICC69TpW4wagp9o2XqQ8E7X98cAmcR5psSpfkE",
1432
1459
  userFeatures: []
1433
1460
  };
1434
- class Gs {
1461
+ class Ns {
1435
1462
  // Global properties
1436
1463
  appConfig = lt;
1437
1464
  endpoint = "/";
@@ -1464,7 +1491,7 @@ class Gs {
1464
1491
  // UI Stores
1465
1492
  globalUiStore;
1466
1493
  constructor(t = lt, e = "/", s, a) {
1467
- this.appConfig = t, this.endpoint = e, this.sessionToken = t.options.session_token ?? "", this.onError = s, this.onStoreUpdate = a, this.accountStore = new oe(this), this.appDataStore = new le(this), this.analyticsStore = new de(this), this.beatStore = new ge(this), this.budgetsStore = new pe(this), this.cashflowStore = new _e(this), this.categoryStore = new ye(this), this.connectStore = new Se(this), this.copyStore = new Ee(this), this.debtsStore = new Te(this), this.finstrongStore = new Ie(this), this.goalStore = new Re(this), this.helpStore = new ve(this), this.holdingStore = new $e(this), this.merchantStore = new Ge(this), this.netWorthStore = new Ne(this), this.notificationStore = new Be(this), this.recurringTransactionsStore = new xe(this), this.settingsStore = new Pe(this), this.transactionStore = new Ue(this), this.trendsStore = new ke(this), this.userStore = new He(this), this.globalUiStore = new Ce(this), d(this), St(() => {
1494
+ this.appConfig = t, this.endpoint = e, this.sessionToken = t.options.session_token ?? "", this.onError = s, this.onStoreUpdate = a, this.accountStore = new ce(this), this.appDataStore = new de(this), this.analyticsStore = new he(this), this.beatStore = new pe(this), this.budgetsStore = new _e(this), this.cashflowStore = new fe(this), this.categoryStore = new me(this), this.connectStore = new Te(this), this.copyStore = new Re(this), this.debtsStore = new Ae(this), this.finstrongStore = new Ce(this), this.goalStore = new De(this), this.helpStore = new $e(this), this.holdingStore = new Ge(this), this.merchantStore = new Ne(this), this.netWorthStore = new Be(this), this.notificationStore = new xe(this), this.recurringTransactionsStore = new Me(this), this.settingsStore = new Fe(this), this.transactionStore = new Ue(this), this.trendsStore = new He(this), this.userStore = new We(this), this.globalUiStore = new Ee(this), d(this), St(() => {
1468
1495
  const { transactions: o } = this.transactionStore;
1469
1496
  this.emitUpdate({
1470
1497
  transactions: o
@@ -1501,7 +1528,7 @@ class Gs {
1501
1528
  (!e || !p) && await this.loadConfigData(), e && this.appDataStore.setAppData(e), p && this.userStore.setUserFeatures(p), t && (await this.accountStore.loadMembers(), o && this.accountStore.setInstitutions(o), this.accountStore.setAccounts(t)), s && this.transactionStore.setAssociatedBeats(s), a && this.categoryStore.setCategories(a), l && this.transactionStore.setTransactions(l), r && this.transactionStore.setTransactionRules(r), b && this.budgetsStore.setMerchantBudgets(b);
1502
1529
  };
1503
1530
  }
1504
- class Ce {
1531
+ class Ee {
1505
1532
  globalStore;
1506
1533
  accountFilterMap = /* @__PURE__ */ new Map();
1507
1534
  displayedDate = /* @__PURE__ */ new Date();
@@ -1560,22 +1587,22 @@ class Ce {
1560
1587
  };
1561
1588
  };
1562
1589
  get shouldDisableNextDate() {
1563
- const t = L(this.displayedDate), e = L(ie(/* @__PURE__ */ new Date(), 1));
1590
+ const t = v(this.displayedDate), e = v(re(/* @__PURE__ */ new Date(), 1));
1564
1591
  return t === e;
1565
1592
  }
1566
1593
  get shouldDisablePrevDate() {
1567
- const t = L(this.displayedDate), e = L(/* @__PURE__ */ new Date());
1594
+ const t = v(this.displayedDate), e = v(/* @__PURE__ */ new Date());
1568
1595
  return t === e;
1569
1596
  }
1570
1597
  }
1571
- class Ee {
1598
+ class Re {
1572
1599
  globalStore;
1573
- api = new H("/", "");
1600
+ api = new V("/", "");
1574
1601
  copy = {};
1575
1602
  featureNamespace = "experiences";
1576
1603
  isInitialized = !1;
1577
1604
  constructor(t) {
1578
- this.globalStore = t, this.api = new H(
1605
+ this.globalStore = t, this.api = new V(
1579
1606
  t.endpoint,
1580
1607
  t.sessionToken,
1581
1608
  t.onError
@@ -1597,7 +1624,7 @@ class Ee {
1597
1624
  }
1598
1625
  };
1599
1626
  }
1600
- class Re {
1627
+ class De {
1601
1628
  globalStore;
1602
1629
  api = new tt("/", "");
1603
1630
  goals = [];
@@ -1624,7 +1651,7 @@ class Re {
1624
1651
  amount: s.target_amount,
1625
1652
  name: t.retirement,
1626
1653
  track_type: S.RETIREMENT_TRACK,
1627
- projected_to_complete_at: s.retirement_age && e ? W(s.retirement_age, e) : void 0
1654
+ projected_to_complete_at: s.retirement_age && e ? z(s.retirement_age, e) : void 0
1628
1655
  }))
1629
1656
  ];
1630
1657
  }
@@ -1734,7 +1761,7 @@ class Re {
1734
1761
  amount: s.target_amount,
1735
1762
  name: e.retirement,
1736
1763
  track_type: S.RETIREMENT_TRACK,
1737
- projected_to_complete_at: s.retirement_age && o ? W(s.retirement_age, o) : void 0
1764
+ projected_to_complete_at: s.retirement_age && o ? z(s.retirement_age, o) : void 0
1738
1765
  }
1739
1766
  ], this.setRetirementGoalAccounts([...this.retirementGoalAccounts, ...a]);
1740
1767
  } catch (s) {
@@ -1835,9 +1862,9 @@ class Re {
1835
1862
  }
1836
1863
  };
1837
1864
  }
1838
- const De = (n, t) => n.guid === "general" || n.guid === "insights" ? !0 : n.flags ? n.flags.every((e) => t[e]) : !1, Le = (n, t) => {
1865
+ const Le = (n, t) => n.guid === "general" || n.guid === "insights" ? !0 : n.flags ? n.flags.every((e) => t[e]) : !1, ve = (n, t) => {
1839
1866
  const e = [];
1840
- for (const s of re) {
1867
+ for (const s of oe) {
1841
1868
  const a = t[s.guid];
1842
1869
  if (!a) continue;
1843
1870
  const o = {
@@ -1848,11 +1875,11 @@ const De = (n, t) => n.guid === "general" || n.guid === "insights" ? !0 : n.flag
1848
1875
  label: a.topics[l]
1849
1876
  }))
1850
1877
  };
1851
- De(o, n) && e.push(o);
1878
+ Le(o, n) && e.push(o);
1852
1879
  }
1853
1880
  return e;
1854
1881
  };
1855
- class ve {
1882
+ class $e {
1856
1883
  alert = { message: "", severity: void 0 };
1857
1884
  api = new et("/", "");
1858
1885
  appConfig;
@@ -1878,7 +1905,7 @@ class ve {
1878
1905
  const { client_communication_profile: t, client_profile: e } = this.globalStore.appDataStore.appData, {
1879
1906
  help: { category_list: s }
1880
1907
  } = this.globalStore.copyStore.copy;
1881
- return Le(
1908
+ return ve(
1882
1909
  {
1883
1910
  ...t,
1884
1911
  ...e,
@@ -1888,8 +1915,8 @@ class ve {
1888
1915
  );
1889
1916
  }
1890
1917
  }
1891
- class $e {
1892
- analysisType = Ht.Stocks;
1918
+ class Ge {
1919
+ analysisType = Wt.Stocks;
1893
1920
  api = new st("/", "");
1894
1921
  holdings = [];
1895
1922
  holdingsLoaded = !1;
@@ -1899,10 +1926,10 @@ class $e {
1899
1926
  this.globalStore = t, this.api = new st(t.endpoint, t.sessionToken, t.onError), d(this);
1900
1927
  }
1901
1928
  get analysisChartData() {
1902
- return Wt(Vt(this.visibleHoldings), this.analysisType);
1929
+ return Vt(zt(this.visibleHoldings), this.analysisType);
1903
1930
  }
1904
1931
  get analysisDetails() {
1905
- return zt(this.visibleHoldings)[this.analysisType] || {};
1932
+ return Kt(this.visibleHoldings)[this.analysisType] || {};
1906
1933
  }
1907
1934
  get visibleHoldings() {
1908
1935
  return this.holdings.filter(
@@ -1941,7 +1968,7 @@ class $e {
1941
1968
  }
1942
1969
  };
1943
1970
  }
1944
- class Ge {
1971
+ class Ne {
1945
1972
  globalStore;
1946
1973
  api = new at("/", "");
1947
1974
  merchant = null;
@@ -1962,9 +1989,9 @@ class Ge {
1962
1989
  c(() => this.merchant = e);
1963
1990
  };
1964
1991
  }
1965
- class Ne {
1992
+ class Be {
1966
1993
  globalStore;
1967
- accountsApi = new N("/", "");
1994
+ accountsApi = new B("/", "");
1968
1995
  monthlyAccountBalances = [];
1969
1996
  monthlyAccountBalancesLoaded = !1;
1970
1997
  hoveredIndex = -1;
@@ -1972,7 +1999,7 @@ class Ne {
1972
1999
  timeframe = 6;
1973
2000
  // default timeframe is 6 months
1974
2001
  constructor(t) {
1975
- this.globalStore = t, this.accountsApi = new N(
2002
+ this.globalStore = t, this.accountsApi = new B(
1976
2003
  t.endpoint,
1977
2004
  t.sessionToken,
1978
2005
  t.onError
@@ -1982,7 +2009,7 @@ class Ne {
1982
2009
  return this.globalStore.accountStore.isAccountDataLoaded && this.monthlyAccountBalancesLoaded;
1983
2010
  }
1984
2011
  get netWorthAccounts() {
1985
- return Kt(
2012
+ return Qt(
1986
2013
  this.globalStore.globalUiStore.selectedAccounts,
1987
2014
  this.globalStore.accountStore.members
1988
2015
  );
@@ -1994,24 +2021,24 @@ class Ne {
1994
2021
  };
1995
2022
  }
1996
2023
  get netWorthChartData() {
1997
- return Qt(this.netWorthAccounts, this.monthlyAccountBalances, this.timeframe);
2024
+ return qt(this.netWorthAccounts, this.monthlyAccountBalances, this.timeframe);
1998
2025
  }
1999
2026
  get selectedData() {
2000
2027
  if (!(!this.netWorthChartData || this.netWorthChartData.length === 0))
2001
- return this.selectedIndex === -1 ? V(this.netWorthChartData) : this.netWorthChartData[this.selectedIndex];
2028
+ return this.selectedIndex === -1 ? K(this.netWorthChartData) : this.netWorthChartData[this.selectedIndex];
2002
2029
  }
2003
2030
  get hoveredData() {
2004
2031
  return this.hoveredIndex >= 0 ? this.netWorthChartData[this.hoveredIndex] : void 0;
2005
2032
  }
2006
2033
  get gainsLosses() {
2007
- return qt(this.selectedData);
2034
+ return Yt(this.selectedData);
2008
2035
  }
2009
2036
  get assetsLiabilities() {
2010
- const { assets: t, liabilities: e, totalAssets: s, totalLiabilities: a } = Yt(
2037
+ const { assets: t, liabilities: e, totalAssets: s, totalLiabilities: a } = jt(
2011
2038
  this.netWorthData.accounts
2012
2039
  );
2013
2040
  return {
2014
- netWorth: V(this.netWorthChartData),
2041
+ netWorth: K(this.netWorthChartData),
2015
2042
  assets: t,
2016
2043
  liabilities: e,
2017
2044
  totalAssets: s,
@@ -2022,7 +2049,7 @@ class Ne {
2022
2049
  this.globalStore.accountStore.isAccountDataLoaded || await this.globalStore.accountStore.loadAccountData();
2023
2050
  const e = (await Promise.all(
2024
2051
  this.netWorthAccounts.map((s) => this.getMonthlyAccountBalances(s.guid))
2025
- )).reduce(jt, []).sort(Xt);
2052
+ )).reduce(Xt, []).sort(Jt);
2026
2053
  this.setMonthlyAccountBalances(e);
2027
2054
  };
2028
2055
  getMonthlyAccountBalances = async (t) => {
@@ -2039,7 +2066,7 @@ class Ne {
2039
2066
  setSelectedIndex = (t) => this.selectedIndex = t;
2040
2067
  setTimeframe = (t) => this.timeframe = t;
2041
2068
  }
2042
- class Be {
2069
+ class xe {
2043
2070
  globalStore;
2044
2071
  api = new nt("/", "");
2045
2072
  isLoading = !0;
@@ -2057,7 +2084,7 @@ class Be {
2057
2084
  return this.recentNotifications.filter((t) => !t.has_been_viewed);
2058
2085
  }
2059
2086
  get recentNotifications() {
2060
- return Jt(this.notifications);
2087
+ return Zt(this.notifications);
2061
2088
  }
2062
2089
  setNotifications = (t) => {
2063
2090
  this.notifications = t, this.notificationsLoaded = !0;
@@ -2083,7 +2110,7 @@ class Be {
2083
2110
  };
2084
2111
  }
2085
2112
  const dt = (n, t) => gt(t.expectedDate, n), A = (n, t) => n + t.amount;
2086
- class xe {
2113
+ class Me {
2087
2114
  globalStore;
2088
2115
  api = new it("/", "");
2089
2116
  repeatingTransactions = [];
@@ -2098,24 +2125,64 @@ class xe {
2098
2125
  t.endpoint,
2099
2126
  t.sessionToken,
2100
2127
  t.onError
2101
- ), d(this);
2128
+ ), d(this, {
2129
+ recurrencesForRange: !1,
2130
+ upcomingExpensesForRange: !1,
2131
+ upcomingIncomeForRange: !1,
2132
+ incomeForRange: !1,
2133
+ nextIncomeForRange: !1
2134
+ });
2102
2135
  }
2103
2136
  get copy() {
2104
2137
  return this.globalStore.copyStore.copy.recurring;
2105
2138
  }
2106
2139
  get detailedRepeatingTransactions() {
2107
- return O(
2140
+ return F(
2108
2141
  this.globalStore.accountStore.visibleAccounts,
2109
2142
  this.repeatingTransactions,
2110
2143
  this.globalStore.transactionStore.transactions
2111
2144
  );
2112
2145
  }
2146
+ /**
2147
+ * Returns all recurrences built from repeating transactions and filtered by
2148
+ * accounts, scoped to the supplied date range. This is the range-parameterized
2149
+ * core used by both the shared getters (which pass this.dateRange) and by
2150
+ * consumers such as Cash Flow that need their own independent window without
2151
+ * mutating the shared dateRange.
2152
+ */
2153
+ recurrencesForRange = (t) => {
2154
+ const e = this.globalStore.accountStore.visibleAccounts;
2155
+ return te(this.detailedRepeatingTransactions, t).filter((s) => e.some((a) => a.guid === s.accountGuid && !a.is_excluded_from_accounts)).filter((s) => gt(s.expectedDate, t));
2156
+ };
2157
+ /**
2158
+ * Returns the upcoming expense recurrences scoped to the supplied date range.
2159
+ */
2160
+ upcomingExpensesForRange = (t) => this.recurrencesForRange(t).filter(
2161
+ (e) => e.type === L.Expense && e.status === f.Upcoming
2162
+ );
2163
+ /**
2164
+ * Returns the income recurrences scoped to the supplied date range.
2165
+ */
2166
+ incomeForRange = (t) => this.recurrencesForRange(t).filter(
2167
+ (e) => e.type === L.Income
2168
+ );
2169
+ /**
2170
+ * Returns the upcoming income recurrences scoped to the supplied date range.
2171
+ */
2172
+ upcomingIncomeForRange = (t) => this.incomeForRange(t).filter(
2173
+ (e) => e.status === f.Upcoming
2174
+ );
2175
+ /**
2176
+ * Returns the next upcoming income recurrence scoped to the supplied range.
2177
+ */
2178
+ nextIncomeForRange = (t) => this.upcomingIncomeForRange(t).find(
2179
+ (e) => P(e.expectedDate, y())
2180
+ );
2113
2181
  /**
2114
2182
  * Returns all recurrences built from repeating transactions and filtered by accounts.
2115
2183
  */
2116
2184
  get recurrences() {
2117
- const t = this.globalStore.accountStore.visibleAccounts;
2118
- return Zt(this.detailedRepeatingTransactions, this.dateRange).filter((e) => t.some((s) => s.guid === e.accountGuid && !s.is_excluded_from_accounts)).filter((e) => gt(e.expectedDate, this.dateRange));
2185
+ return this.recurrencesForRange(this.dateRange);
2119
2186
  }
2120
2187
  /**
2121
2188
  * Returns all recurrences that have occurred in the past, including those that are paid or missed
@@ -2131,7 +2198,7 @@ class xe {
2131
2198
  */
2132
2199
  get upcomingRecurrences() {
2133
2200
  return this.recurrences.filter(
2134
- (t) => z(t.expectedDate, pt(y(), 3)) && F(t.expectedDate, this.dateRange.end) && t.status === f.Upcoming
2201
+ (t) => P(t.expectedDate, pt(y(), 3)) && H(t.expectedDate, this.dateRange.end) && t.status === f.Upcoming
2135
2202
  );
2136
2203
  }
2137
2204
  /**
@@ -2139,7 +2206,7 @@ class xe {
2139
2206
  */
2140
2207
  get expenses() {
2141
2208
  return this.recurrences.filter(
2142
- (t) => t.type === Q.Expense
2209
+ (t) => t.type === L.Expense
2143
2210
  );
2144
2211
  }
2145
2212
  /**
@@ -2155,7 +2222,7 @@ class xe {
2155
2222
  */
2156
2223
  get income() {
2157
2224
  return this.recurrences.filter(
2158
- (t) => t.type === Q.Income
2225
+ (t) => t.type === L.Income
2159
2226
  );
2160
2227
  }
2161
2228
  /**
@@ -2167,7 +2234,7 @@ class xe {
2167
2234
  );
2168
2235
  }
2169
2236
  get nextIncomeRecurrence() {
2170
- return this.upcomingIncome.find((t) => z(t.expectedDate, y()));
2237
+ return this.upcomingIncome.find((t) => P(t.expectedDate, y()));
2171
2238
  }
2172
2239
  /**
2173
2240
  * Returns the expense recurrences for the current month.
@@ -2232,7 +2299,7 @@ class xe {
2232
2299
  */
2233
2300
  get selectedDayRecurrences() {
2234
2301
  return this.selectedDay && this.recurrences.filter(
2235
- (t) => this.selectedDay && K(t.occurredOnDate || t.expectedDate, this.selectedDay)
2302
+ (t) => this.selectedDay && Q(t.occurredOnDate || t.expectedDate, this.selectedDay)
2236
2303
  );
2237
2304
  }
2238
2305
  get selectedRepeatingTransaction() {
@@ -2255,7 +2322,7 @@ class xe {
2255
2322
  * @param day - The day to select.
2256
2323
  */
2257
2324
  setSelectedDay = (t) => {
2258
- this.selectedDay = this.selectedDay && K(t, this.selectedDay) ? void 0 : t;
2325
+ this.selectedDay = this.selectedDay && Q(t, this.selectedDay) ? void 0 : t;
2259
2326
  };
2260
2327
  loadRepeatingTransactionData = async () => {
2261
2328
  await Promise.all([
@@ -2289,7 +2356,7 @@ class xe {
2289
2356
  }), c(() => {
2290
2357
  this.repeatingTransactions = [
2291
2358
  ...this.repeatingTransactions,
2292
- ...O(
2359
+ ...F(
2293
2360
  this.globalStore.accountStore.visibleAccounts,
2294
2361
  [s],
2295
2362
  this.globalStore.transactionStore.transactions
@@ -2328,7 +2395,7 @@ class xe {
2328
2395
  c(() => {
2329
2396
  this.repeatingTransactions = [
2330
2397
  ...this.repeatingTransactions.slice(0, s),
2331
- ...O(
2398
+ ...F(
2332
2399
  this.globalStore.accountStore.visibleAccounts,
2333
2400
  [e],
2334
2401
  this.globalStore.transactionStore.transactions
@@ -2371,9 +2438,9 @@ class xe {
2371
2438
  };
2372
2439
  setAlert = (t, e = void 0) => this.alert = { message: t, severity: e };
2373
2440
  }
2374
- const ht = "PARENT-ENTITY", Me = (n, t) => ({
2375
- [G.BudgetExceeded]: t.notification_budget_exceeded,
2376
- [G.BudgetOffTarget]: t.notification_budget_off_target,
2441
+ const ht = "PARENT-ENTITY", Oe = (n, t) => ({
2442
+ [N.BudgetExceeded]: t.notification_budget_exceeded,
2443
+ [N.BudgetOffTarget]: t.notification_budget_off_target,
2377
2444
  [_.DebtPaymentReminder]: t.notification_debt_payment_reminder,
2378
2445
  [_.AccountBalanceLow]: t.notification_low_balance,
2379
2446
  [_.AccountDepositLargePosted]: t.notification_large_deposit,
@@ -2404,7 +2471,7 @@ const ht = "PARENT-ENTITY", Me = (n, t) => ({
2404
2471
  [u.TransactionExpenseLarge]: t.large_transaction,
2405
2472
  [u.PromotionalCampaignMessages]: t.promotional_campaign_messages,
2406
2473
  [u.TransparentOverdraft]: t.transparent_overdraft
2407
- })[n] || "", Oe = (n, t, e, s, a, o) => {
2474
+ })[n] || "", Pe = (n, t, e, s, a, o) => {
2408
2475
  const r = [], {
2409
2476
  email_notifications_enabled: l,
2410
2477
  sms_notifications_enabled: p,
@@ -2415,14 +2482,14 @@ const ht = "PARENT-ENTITY", Me = (n, t) => ({
2415
2482
  opted_out_of_push_notifications: yt
2416
2483
  } = a;
2417
2484
  for (const I of s.filter((R) => R.entity_guid === ht)) {
2418
- const R = Me(I.notification_type, e), mt = s.filter(
2419
- (C) => C.entity_guid !== ht && C.notification_type === I.notification_type && n.some((x) => x.guid === C.entity_guid)
2485
+ const R = Oe(I.notification_type, e), mt = s.filter(
2486
+ (C) => C.entity_guid !== ht && C.notification_type === I.notification_type && n.some((M) => M.guid === C.entity_guid)
2420
2487
  ), D = [];
2421
2488
  l && !_t && I.email_channel && o.email && D.push(e.delivery_method_email_label), p && !ft && I.sms_channel && o.phone && D.push(e.delivery_method_sms_label), b && !yt && I.push_channel && D.push(e.delivery_method_push_label), r.push({
2422
2489
  ...I,
2423
2490
  children: mt.map((C) => ({
2424
2491
  ...C,
2425
- account: n.find((x) => x.guid === C.entity_guid),
2492
+ account: n.find((M) => M.guid === C.entity_guid),
2426
2493
  label: R
2427
2494
  })),
2428
2495
  deliveryMethodsLabel: D.join(", "),
@@ -2431,17 +2498,17 @@ const ht = "PARENT-ENTITY", Me = (n, t) => ({
2431
2498
  }
2432
2499
  return r;
2433
2500
  };
2434
- class Pe {
2501
+ class Fe {
2435
2502
  globalStore;
2436
2503
  api = new rt("/", "");
2437
- transactionApi = new B("/", "");
2504
+ transactionApi = new x("/", "");
2438
2505
  alert = { message: "", severity: void 0 };
2439
2506
  devices = [];
2440
2507
  notificationProfiles = [];
2441
2508
  selectedRule = void 0;
2442
2509
  transactionRules = [];
2443
2510
  constructor(t) {
2444
- this.globalStore = t, this.api = new rt(t.endpoint, t.sessionToken, t.onError), this.transactionApi = new B(
2511
+ this.globalStore = t, this.api = new rt(t.endpoint, t.sessionToken, t.onError), this.transactionApi = new x(
2445
2512
  t.endpoint,
2446
2513
  t.sessionToken,
2447
2514
  t.onError
@@ -2456,7 +2523,7 @@ class Pe {
2456
2523
  get budgetProfiles() {
2457
2524
  const t = this.globalStore.appDataStore.clientCommunicationProfile;
2458
2525
  return this.detailedNotificationProfiles.filter(
2459
- (e) => e.notification_type === G.BudgetExceeded && t.budget_exceeded_notifications_enabled || e.notification_type === G.BudgetOffTarget && t.budget_off_target_notifications_enabled
2526
+ (e) => e.notification_type === N.BudgetExceeded && t.budget_exceeded_notifications_enabled || e.notification_type === N.BudgetOffTarget && t.budget_off_target_notifications_enabled
2460
2527
  );
2461
2528
  }
2462
2529
  get insightsProfiles() {
@@ -2471,7 +2538,7 @@ class Pe {
2471
2538
  return this.globalStore.copyStore.copy.settings;
2472
2539
  }
2473
2540
  get detailedNotificationProfiles() {
2474
- return this.globalStore.isInitialized ? Oe(
2541
+ return this.globalStore.isInitialized ? Pe(
2475
2542
  this.globalStore.accountStore.accounts,
2476
2543
  this.clientCommunicationProfile,
2477
2544
  this.copy,
@@ -2617,8 +2684,8 @@ class Pe {
2617
2684
  class Ue {
2618
2685
  globalStore;
2619
2686
  uiStore;
2620
- api = new B("/", "");
2621
- beatApi = new v("/", "");
2687
+ api = new x("/", "");
2688
+ beatApi = new $("/", "");
2622
2689
  associatedBeats = [];
2623
2690
  associatedBeatsLoaded = !1;
2624
2691
  associatedBeatsLoading = !1;
@@ -2639,14 +2706,14 @@ class Ue {
2639
2706
  filter = {};
2640
2707
  isLoading = !0;
2641
2708
  alert = "";
2642
- sortColumn = $t.DATE;
2643
- sortDirection = Gt.DESC;
2709
+ sortColumn = Gt.DATE;
2710
+ sortDirection = Nt.DESC;
2644
2711
  constructor(t) {
2645
- this.globalStore = t, this.uiStore = new Fe(), this.api = new B(
2712
+ this.globalStore = t, this.uiStore = new ke(), this.api = new x(
2646
2713
  t.endpoint,
2647
2714
  t.sessionToken,
2648
2715
  t.onError
2649
- ), this.beatApi = new v(t.endpoint, t.sessionToken, t.onError), d(this);
2716
+ ), this.beatApi = new $(t.endpoint, t.sessionToken, t.onError), d(this);
2650
2717
  }
2651
2718
  loadTransactionData = async () => {
2652
2719
  this.globalStore.accountStore.isAccountDataLoaded || await this.globalStore.accountStore.loadAccountData(), this.globalStore.categoryStore.categoriesLoaded || await this.globalStore.categoryStore.loadCategories(), await Promise.all([
@@ -2662,7 +2729,7 @@ class Ue {
2662
2729
  return this.associatedBeatsLoaded && this.tagsLoaded && this.taggingsLoaded && this.transactionRulesLoaded && this.transactionsLoaded;
2663
2730
  }
2664
2731
  get detailedTransactions() {
2665
- return this.isTransactionDataLoaded ? Nt(
2732
+ return this.isTransactionDataLoaded ? Bt(
2666
2733
  this.transactions,
2667
2734
  this.globalStore.accountStore.visibleAccounts,
2668
2735
  this.globalStore.categoryStore.categories,
@@ -2670,7 +2737,7 @@ class Ue {
2670
2737
  ) : [];
2671
2738
  }
2672
2739
  get sortedTransactions() {
2673
- return Bt(
2740
+ return xt(
2674
2741
  this.filter,
2675
2742
  this.uiStore.expandedSplits,
2676
2743
  this.sortColumn,
@@ -2680,7 +2747,7 @@ class Ue {
2680
2747
  );
2681
2748
  }
2682
2749
  get sortedTransactionsWithSplits() {
2683
- return xt(this.sortedTransactions, this.detailedTransactions);
2750
+ return Mt(this.sortedTransactions, this.detailedTransactions);
2684
2751
  }
2685
2752
  setAssociatedBeats = (t) => {
2686
2753
  this.associatedBeats = t, this.associatedBeatsLoading = !1, this.associatedBeatsLoaded = !0;
@@ -2727,14 +2794,14 @@ class Ue {
2727
2794
  const e = await this.api.addTransaction(t);
2728
2795
  if (e) {
2729
2796
  this.setTransactions([e, ...this.transactions]);
2730
- const s = e.transaction_type === Mt.CREDIT ? e.amount : -e.amount;
2797
+ const s = e.transaction_type === Ot.CREDIT ? e.amount : -e.amount;
2731
2798
  this.globalStore.accountStore.updateAccountBalance(e.account_guid, s);
2732
2799
  }
2733
2800
  };
2734
2801
  loadAssociatedBeats = async (t) => {
2735
2802
  if (this.associatedBeatsLoading) return;
2736
2803
  this.associatedBeatsLoading = !0;
2737
- const e = t ? te(t, { representation: "date" }) : void 0;
2804
+ const e = t ? ee(t, { representation: "date" }) : void 0;
2738
2805
  try {
2739
2806
  const s = await this.beatApi.getBeatsWithAssociatedTransaction(e);
2740
2807
  this.setAssociatedBeats(s);
@@ -2805,7 +2872,7 @@ class Ue {
2805
2872
  }
2806
2873
  };
2807
2874
  setFilter = (t) => {
2808
- this.filter = t, t.dateRange && F(t.dateRange.start, this.cachedStartDate) && this.loadTransactions(t.dateRange.start).then(() => {
2875
+ this.filter = t, t.dateRange && H(t.dateRange.start, this.cachedStartDate) && this.loadTransactions(t.dateRange.start).then(() => {
2809
2876
  t.dateRange && (this.cachedStartDate = t.dateRange.start);
2810
2877
  });
2811
2878
  };
@@ -2883,7 +2950,7 @@ class Ue {
2883
2950
  }
2884
2951
  };
2885
2952
  }
2886
- class Fe {
2953
+ class ke {
2887
2954
  beginDate = E(/* @__PURE__ */ new Date());
2888
2955
  endDate = T(/* @__PURE__ */ new Date());
2889
2956
  expandedSplits = [];
@@ -2892,7 +2959,7 @@ class Fe {
2892
2959
  shouldDisableDrawerScroll = !1;
2893
2960
  searchValue = "";
2894
2961
  selectedAccountGuids = [];
2895
- manualTransaction = Ot;
2962
+ manualTransaction = Pt;
2896
2963
  isAmountValid = !1;
2897
2964
  showInsights = !1;
2898
2965
  constructor() {
@@ -2922,14 +2989,14 @@ class Fe {
2922
2989
  this.manualTransaction = t;
2923
2990
  };
2924
2991
  }
2925
- class ke {
2992
+ class He {
2926
2993
  globalStore;
2927
2994
  selectedCategoryData = null;
2928
2995
  selectedDateRange;
2929
2996
  visibleListLength = 5;
2930
2997
  constructor(t) {
2931
2998
  this.globalStore = t, this.selectedDateRange = {
2932
- start: ee(T($(/* @__PURE__ */ new Date(), 6)), 1),
2999
+ start: se(T(G(/* @__PURE__ */ new Date(), 6)), 1),
2933
3000
  end: T(/* @__PURE__ */ new Date())
2934
3001
  }, d(this);
2935
3002
  }
@@ -2943,15 +3010,15 @@ class ke {
2943
3010
  this.visibleListLength = t;
2944
3011
  };
2945
3012
  get sortedDetailedCategoriesWithTransactions() {
2946
- return ae(
3013
+ return ne(
2947
3014
  this.globalStore.categoryStore.detailedCategoriesWithTransactions
2948
3015
  );
2949
3016
  }
2950
3017
  get selectedDateRangeMonthCount() {
2951
- return se(this.selectedDateRange.end, this.selectedDateRange.start) + 1;
3018
+ return ae(this.selectedDateRange.end, this.selectedDateRange.start) + 1;
2952
3019
  }
2953
3020
  get selectedDateRangeMonthRange() {
2954
- const t = P(this.selectedDateRange.start, U.MONTH_LONG), e = P(this.selectedDateRange.end, U.MONTH_LONG);
3021
+ const t = U(this.selectedDateRange.start, k.MONTH_LONG), e = U(this.selectedDateRange.end, k.MONTH_LONG);
2955
3022
  return `${t} - ${e}`;
2956
3023
  }
2957
3024
  get visibleCategories() {
@@ -2961,13 +3028,13 @@ class ke {
2961
3028
  return this.sortedDetailedCategoriesWithTransactions.slice(this.visibleListLength);
2962
3029
  }
2963
3030
  get categoryDetailsChartData() {
2964
- return ne(
3031
+ return ie(
2965
3032
  this.selectedCategoryData,
2966
3033
  this.selectedDateRangeMonthCount
2967
3034
  );
2968
3035
  }
2969
3036
  }
2970
- class He {
3037
+ class We {
2971
3038
  globalStore;
2972
3039
  api = new ot("/", "");
2973
3040
  userFeatures = [];
@@ -3010,45 +3077,45 @@ class He {
3010
3077
  };
3011
3078
  }
3012
3079
  export {
3013
- N as A,
3080
+ B as A,
3014
3081
  j as B,
3015
- _e as C,
3016
- Te as D,
3082
+ fe as C,
3083
+ Ae as D,
3017
3084
  Z as F,
3018
- Ee as G,
3085
+ Re as G,
3019
3086
  et as H,
3020
3087
  at as M,
3021
- Ne as N,
3022
- xe as R,
3088
+ Be as N,
3089
+ Me as R,
3023
3090
  rt as S,
3024
- B as T,
3091
+ x as T,
3025
3092
  ot as U,
3026
3093
  ct as W,
3027
- oe as a,
3028
- de as b,
3094
+ ce as a,
3095
+ he as b,
3029
3096
  Y as c,
3030
- le as d,
3031
- ge as e,
3097
+ de as d,
3098
+ pe as e,
3032
3099
  X as f,
3033
- pe as g,
3100
+ _e as g,
3034
3101
  J as h,
3035
- ye as i,
3036
- Se as j,
3037
- Ie as k,
3038
- Gs as l,
3039
- Ce as m,
3102
+ me as i,
3103
+ Te as j,
3104
+ Ce as k,
3105
+ Ns as l,
3106
+ Ee as m,
3040
3107
  tt as n,
3041
- Re as o,
3042
- ve as p,
3108
+ De as o,
3109
+ $e as p,
3043
3110
  st as q,
3044
- $e as r,
3045
- Ge as s,
3111
+ Ge as r,
3112
+ Ne as s,
3046
3113
  nt as t,
3047
- Be as u,
3114
+ xe as u,
3048
3115
  it as v,
3049
- Pe as w,
3116
+ Fe as w,
3050
3117
  Ue as x,
3051
- ke as y,
3052
- He as z
3118
+ He as y,
3119
+ We as z
3053
3120
  };
3054
- //# sourceMappingURL=UserStore-C1fdL3Iu.mjs.map
3121
+ //# sourceMappingURL=UserStore-BjnNCO5a.mjs.map