@mx-cartographer/experiences 8.0.0-alpha.test2 → 8.0.0-alpha.v2
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.
- package/CHANGELOG.md +335 -0
- package/README.md +5 -3
- package/dist/{Account-CMjOp7S2.mjs → Account-BiB1F8lL.mjs} +2 -2
- package/dist/{Account-BIKn4XEZ.mjs → Account-DuOz1a27.mjs} +1 -1
- package/dist/{AccountApi-DgZ8ILj1.mjs → AccountApi-ChQr5PAZ.mjs} +1 -1
- package/dist/AccountDetailsHeader-D9gbTbUt.mjs +95 -0
- package/dist/{AccountFields-DuFtmuud.mjs → AccountFields-CxqONzjY.mjs} +12 -12
- package/dist/AccountListItem-D9WJDbZ1.mjs +94 -0
- package/dist/{AccountStore-Cq_w2Hfb.mjs → AccountStore-DpYvNnql.mjs} +15 -9
- package/dist/Accounts-CseLC3lL.mjs +5 -0
- package/dist/Accounts-o7ohkngR.mjs +27 -0
- package/dist/{Analytics-i5h6BxR1.mjs → Analytics-BYItVAe-.mjs} +10 -0
- package/dist/{BeatApi-De2IaqH2.mjs → BeatApi-EFHXULDx.mjs} +1 -1
- package/dist/{BeatStore-D_NYuBSz.mjs → BeatStore-C6CAT-ce.mjs} +1 -1
- package/dist/BudgetUtil-CLhRnCoX.mjs +479 -0
- package/dist/CashflowStore-CeAzChyD.mjs +91 -0
- package/dist/{Category-Ccoew_sA.mjs → Category-CevNQ03n.mjs} +2 -2
- package/dist/{CategorySelectorDrawer-CzRxYpiP.mjs → CategorySelectorDrawer-Dc9Widy9.mjs} +118 -110
- package/dist/{CategoryStore-V-0d9oje.mjs → CategoryStore-FTxUbn0f.mjs} +3 -3
- package/dist/{CategoryUtil-DB-9JMbi.mjs → CategoryUtil-BVixr0d5.mjs} +4 -4
- package/dist/Connect-eYIWqCEr.mjs +39 -0
- package/dist/ConnectDrawer-C0wjwcJt.mjs +58 -0
- package/dist/{ConnectionsDrawer-DMBBzlIJ.mjs → ConnectionsDrawer-IA7vnv1J.mjs} +10 -9
- package/dist/CurrencyInput-DuMktPu3.mjs +85 -0
- package/dist/{CurrencyText-C-85TnUF.mjs → CurrencyText-CA-E5N_y.mjs} +1 -1
- package/dist/{DateFormats-Cs-NbEZ7.mjs → DateFormats-BMpMrZpW.mjs} +1 -1
- package/dist/{DateUtil-CVXVMbjf.mjs → DateUtil-wcYTmDRD.mjs} +1 -1
- package/dist/{DebtsStore-Dv_T7Dts.mjs → DebtsStore-BZqNLaqd.mjs} +3 -3
- package/dist/Dialog-Ck34yr-d.mjs +63 -0
- package/dist/{Donut-DKY8mL3P.mjs → Donut-CpxJlVvJ.mjs} +29 -27
- package/dist/{Drawer-Bet2ZPJo.mjs → Drawer-Bbe4AMB1.mjs} +14 -14
- package/dist/{ExportCsvAction-Cc14QGA9.mjs → ExportCsvAction-ErKh7wJ2.mjs} +4 -4
- package/dist/{Fetch-DecPFeGU.mjs → Fetch-B6tMJC1r.mjs} +2 -1
- package/dist/{FinstrongStore-DW7-LvAh.mjs → FinstrongStore-BQxXxxYD.mjs} +129 -129
- package/dist/GlobalAccountFilter-B73Pw1hJ.mjs +237 -0
- package/dist/Goal-0loDagc5.mjs +6 -0
- package/dist/GoalStore-fgXt--2Y.mjs +418 -0
- package/dist/HeaderCell-P8w6CmfO.mjs +6 -0
- package/dist/{Help-CgpJK03Q.mjs → Help-B8mD4aLJ.mjs} +6 -6
- package/dist/{Help-DOPJteew.mjs → Help-D-laTbKu.mjs} +544 -493
- package/dist/{IconBacking-DgT8DCeh.mjs → IconBacking-B9oC6uL2.mjs} +11 -11
- package/dist/LineChart-EAr5ox5U.mjs +612 -0
- package/dist/{ListItemAction-engf-T9W.mjs → ListItemAction-4KB7P75M.mjs} +2 -2
- package/dist/Loader-D3rjKx72.mjs +21 -0
- package/dist/Localization-CPkpIwIx.mjs +37 -0
- package/dist/{ManageIncome-BVqHHIO7.mjs → ManageIncome-Cc-wba0I.mjs} +118 -113
- package/dist/{MerchantStore-WvZ4gnQe.mjs → MerchantStore-BzGi4JAZ.mjs} +1 -1
- package/dist/MicroWidgetContainer-B_EnfvCq.mjs +45 -0
- package/dist/MiniWidgetContainer-Bhkv-hpz.mjs +66 -0
- package/dist/{NetWorthStore-B6ziBtaH.mjs → NetWorthStore-BqZ44-4M.mjs} +5 -5
- package/dist/Notification-DTNYSd8P.mjs +7 -0
- package/dist/{NotificationSettings-CEzQSKfg.mjs → NotificationSettings-D7VqsrZy.mjs} +160 -159
- package/dist/{NotificationStore-Ck2KdNmT.mjs → NotificationStore-D_e8zo5M.mjs} +28 -21
- package/dist/{NumberFormatting-DjTD0t3W.mjs → NumberFormatting-QCaNwbjv.mjs} +1 -1
- package/dist/{Transaction-C8QRYhYc.mjs → OnClickEvents-CseHDZ94.mjs} +32 -25
- package/dist/{OriginalBalanceAction-CYqr8z8w.mjs → OriginalBalanceAction-DjpvVVFz.mjs} +10 -10
- package/dist/{RecurringSettings-rEotGPcM.mjs → RecurringSettings-BN9H5ALr.mjs} +4 -4
- package/dist/RecurringTransactions-BCJp-Nap.mjs +297 -0
- package/dist/{RecurringTransactionsStore-DpzLX8E8.mjs → RecurringTransactionsStore-CkMA7gY3.mjs} +11 -10
- package/dist/RepeatingTransaction-DF4vJn_v.mjs +7 -0
- package/dist/{ResponsiveButton-BNsV08Ud.mjs → ResponsiveButton-DZFp78fJ.mjs} +12 -12
- package/dist/SearchBox-CwDgvWVJ.mjs +48 -0
- package/dist/{SettingsStore-ImYpLCSK.mjs → SettingsStore-BoIoiRLj.mjs} +3 -3
- package/dist/{SingleSegmentDonut-PsRQPkmV.mjs → SingleSegmentDonut-BgbLgwHi.mjs} +5 -5
- package/dist/{SpendingData-CI_C9xln.mjs → SpendingData-Bz1bCWAs.mjs} +4 -4
- package/dist/SpendingLegend-BgjazduU.mjs +193 -0
- package/dist/{StatusBar-CPfSXe80.mjs → StatusBar-BK_uYHAB.mjs} +6 -6
- package/dist/StatusIndicator-4tWnjeKS.mjs +264 -0
- package/dist/{TabContentContainer-CnMXkVqr.mjs → TabContentContainer-j01JYR_7.mjs} +8 -8
- package/dist/ToggleListItem-BLu_fWA2.mjs +90 -0
- package/dist/Transaction-Cn5_iFm0.mjs +5 -0
- package/dist/{TransactionApi-CjBoLleL.mjs → TransactionApi-Ck5Ua-7F.mjs} +1 -1
- package/dist/TransactionDetails-D1I1XEsT.mjs +1469 -0
- package/dist/{TransactionStore-CEehNrKo.mjs → TransactionStore-Bx9euVrY.mjs} +195 -177
- package/dist/{TrendsStore-ncmbS9eE.mjs → TrendsStore-CYdTo7cN.mjs} +10 -10
- package/dist/ViewMoreMicroCard-D24H9kDm.mjs +1291 -0
- package/dist/{WidgetContainer-DFwVgavi.mjs → WidgetContainer-B7xDq2bM.mjs} +47 -46
- package/dist/accounts/AccountsMiniWidget.d.ts +1 -1
- package/dist/accounts/AccountsWidget.d.ts +1 -1
- package/dist/accounts/api/AccountApi.d.ts +1 -1
- package/dist/accounts/components/AccountListItem.d.ts +1 -1
- package/dist/accounts/components/AccountsListCompact.d.ts +1 -1
- package/dist/accounts/components/detailsdrawer/Accounts/AccountActionsRow.d.ts +1 -0
- package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsChart.d.ts +1 -1
- package/dist/accounts/hooks/useGetMergeableAccounts.d.ts +1 -1
- package/dist/accounts/index.es.js +459 -368
- package/dist/accounts/stores/AccountStore.d.ts +2 -1
- package/dist/accounts/stores/UiStore.d.ts +1 -1
- package/dist/accounts/utils/AccountDetails.d.ts +1 -1
- package/dist/accounts/utils/AccountFields.d.ts +1 -1
- package/dist/accounts/utils/Accounts.d.ts +2 -2
- package/dist/analytics/index.es.js +93 -112
- package/dist/budgets/BubbleBudgetsMiniWidget.d.ts +1 -1
- package/dist/budgets/BubbleBudgetsWidget.d.ts +1 -1
- package/dist/budgets/api/BudgetsApi.d.ts +5 -1
- package/dist/budgets/components/BubbleChart.d.ts +1 -1
- package/dist/budgets/components/BudgetDetailsDrawerV2.d.ts +4 -1
- package/dist/budgets/components/MerchantBudgetDetailsDrawer.d.ts +17 -0
- package/dist/budgets/components/addbudget/RecalculateBudgetRow.d.ts +1 -1
- package/dist/budgets/components/addbudget/UnbudgetedRow.d.ts +1 -1
- package/dist/budgets/components/bubblechart/Bubble.d.ts +1 -1
- package/dist/budgets/components/budgetdetails/AddSubBudget.d.ts +1 -1
- package/dist/budgets/components/budgetdetails/BudgetDetails.d.ts +1 -1
- package/dist/budgets/components/budgetdetails/Header.d.ts +1 -1
- package/dist/budgets/components/budgetdetails/SubBudgetList.d.ts +1 -1
- package/dist/budgets/components/budgetlist/BudgetRow.d.ts +1 -1
- package/dist/budgets/components/budgetlist/SubBudgetRow.d.ts +1 -1
- package/dist/budgets/components/shared/BudgetDetailsTopSection.d.ts +13 -0
- package/dist/budgets/index.es.js +851 -865
- package/dist/budgets/store/BudgetsStore.d.ts +15 -1
- package/dist/budgets/utils/BubblesSVG.d.ts +3 -3
- package/dist/budgets/utils/BudgetUtil.d.ts +6 -1
- package/dist/cashflow/CashflowMiniWidget.d.ts +1 -1
- package/dist/cashflow/CashflowWidget.d.ts +1 -1
- package/dist/cashflow/api/CashflowApi.d.ts +1 -1
- package/dist/cashflow/components/DetailsExpenseRow.d.ts +1 -1
- package/dist/cashflow/index.es.js +290 -288
- package/dist/cashflow/stores/UiStore.d.ts +1 -1
- package/dist/cashflow/util/Filters.d.ts +1 -1
- package/dist/categories/components/CategoryRow.d.ts +1 -1
- package/dist/categories/components/CustomCategories/AddSubcategory.d.ts +1 -1
- package/dist/categories/components/CustomCategories/DeleteSubcategory.d.ts +1 -1
- package/dist/categories/components/CustomCategories/RenameSubcategory.d.ts +1 -1
- package/dist/categories/components/SubcategoryList.d.ts +1 -1
- package/dist/categories/components/SubcategoryRow.d.ts +1 -1
- package/dist/categories/index.es.js +2 -2
- package/dist/categories/stores/CategoryStore.d.ts +2 -1
- package/dist/categories/util/CategoryUtil.d.ts +1 -1
- package/dist/common/api/AnalyticsApi.d.ts +1 -1
- package/dist/common/api/AppDataApi.d.ts +1 -1
- package/dist/common/api/BeatApi.d.ts +1 -1
- package/dist/common/api/CategoryApi.d.ts +1 -1
- package/dist/common/api/GlobalCopyApi.d.ts +1 -1
- package/dist/common/api/LocalizedCopyApi.d.ts +1 -1
- package/dist/common/api/NotificationApi.d.ts +1 -1
- package/dist/common/api/ScheduledPaymentsApi.d.ts +1 -1
- package/dist/common/api/UserApi.d.ts +1 -1
- package/dist/common/components/CurrencyDialog.d.ts +1 -1
- package/dist/common/components/CurrencyInput.d.ts +1 -1
- package/dist/common/components/ErrorBoundary.d.ts +1 -1
- package/dist/common/components/GlobalAccountFilter.d.ts +1 -1
- package/dist/common/components/Loader.d.ts +1 -2
- package/dist/common/components/MiniWidgetContainer.d.ts +1 -0
- package/dist/common/components/WidgetContainer.d.ts +1 -1
- package/dist/common/components/charts/LineChart.d.ts +1 -0
- package/dist/common/components/charts/index.d.ts +1 -0
- package/dist/common/components/charts/linechart/CustomTooltip.d.ts +2 -1
- package/dist/common/components/charts/linechart/utils/markerShapes.d.ts +3 -0
- package/dist/common/components/globalaccountfilter/GlobalAccountFilterList.d.ts +1 -1
- package/dist/common/components/index.d.ts +0 -1
- package/dist/common/constants/Account.d.ts +1 -1
- package/dist/common/constants/Analytics.d.ts +10 -0
- package/dist/common/constants/ApiEndpoints.d.ts +1 -0
- package/dist/common/constants/DefaultConfig.d.ts +1 -1
- package/dist/common/constants/ScheduledPayment.d.ts +1 -10
- package/dist/common/constants/SpendingPlan.d.ts +0 -10
- package/dist/common/constants/index.d.ts +2 -2
- package/dist/common/context/GlobalDataProvider.d.ts +2 -1
- package/dist/common/context/hooks.d.ts +4 -4
- package/dist/common/hooks/index.d.ts +1 -0
- package/dist/common/hooks/useAccountDisplayName.d.ts +1 -1
- package/dist/common/hooks/useCombineEvents.d.ts +1 -1
- package/dist/common/hooks/usePrevious.d.ts +2 -0
- package/dist/common/index.d.ts +0 -1
- package/dist/common/index.es.js +625 -860
- package/dist/common/stores/AppDataStore.d.ts +3 -3
- package/dist/common/stores/GlobalCopyStore.d.ts +1 -1
- package/dist/common/stores/GlobalStore.d.ts +4 -2
- package/dist/common/stores/GlobalUiStore.d.ts +3 -3
- package/dist/common/stores/UserStore.d.ts +1 -1
- package/dist/common/utils/AccountDisplayName.d.ts +1 -1
- package/dist/common/utils/AccountFilter.d.ts +1 -1
- package/dist/common/utils/Analytics.d.ts +1 -1
- package/dist/common/utils/Categories.d.ts +1 -1
- package/dist/common/utils/Fetch.d.ts +1 -1
- package/dist/common/utils/Localization.d.ts +9 -1
- package/dist/common/utils/Theme.d.ts +3 -3
- package/dist/common/utils/User.d.ts +1 -1
- package/dist/common/utils/index.d.ts +1 -1
- package/dist/core/constants/index.d.ts +1 -0
- package/dist/core/constants/repeatingTransactions.d.ts +10 -0
- package/dist/core/index.d.ts +2 -0
- package/dist/core/index.es.js +41 -0
- package/dist/{common → core}/types/Analytics.d.ts +6 -3
- package/dist/{common → core}/types/AppData.d.ts +1 -0
- package/dist/{common → core}/types/Beat.d.ts +2 -0
- package/dist/{common → core}/types/Budget.d.ts +8 -0
- package/dist/{common → core}/types/Expense.d.ts +2 -1
- package/dist/{common → core}/types/Finstrong.d.ts +0 -2
- package/dist/{common → core}/types/Notification.d.ts +15 -5
- package/dist/{common → core}/types/index.d.ts +1 -2
- package/dist/{common → core}/types/localization/BudgetsCopy.d.ts +11 -0
- package/dist/{common → core}/types/localization/CashflowCopy.d.ts +1 -0
- package/dist/{common → core}/types/localization/CommonCopy.d.ts +2 -0
- package/dist/{common → core}/types/localization/DebtsCopy.d.ts +5 -0
- package/dist/{common → core}/types/localization/RecurringCopy.d.ts +2 -0
- package/dist/{common → core}/types/localization/SpendingCopy.d.ts +1 -0
- package/dist/dashboard/index.es.js +46 -45
- package/dist/debts/DebtsWidget.d.ts +1 -1
- package/dist/debts/components/actions/DebtsPriorityAction.d.ts +5 -1
- package/dist/debts/components/debtspaydown/PaydownButton.d.ts +2 -1
- package/dist/debts/components/debtspriority/DebtsPriorityButton.d.ts +2 -1
- package/dist/debts/index.es.js +705 -646
- package/dist/debts/store/DebtsStore.d.ts +2 -1
- package/dist/debts/utils/DebtStore.d.ts +1 -1
- package/dist/debts/utils/DebtsWidget.d.ts +7 -1
- package/dist/debts/utils/shared.d.ts +1 -1
- package/dist/{exportTransactionsToCSV-CGnrndmA.mjs → exportTransactionsToCSV-MCYH_zzN.mjs} +5 -5
- package/dist/finstrong/FinstrongWidget.d.ts +1 -1
- package/dist/finstrong/api/FinstrongApi.d.ts +1 -1
- package/dist/finstrong/components/HealthChart.d.ts +1 -1
- package/dist/finstrong/components/onboarding/OnboardingAddMonthlyIncome.d.ts +1 -1
- package/dist/finstrong/components/onboarding/OnboardingStepsDrawer.d.ts +1 -1
- package/dist/finstrong/components/shared/Accounts.d.ts +1 -1
- package/dist/finstrong/components/shared/DoubleBarChart.d.ts +1 -0
- package/dist/finstrong/components/shared/ScoreHistoryTimeline.d.ts +1 -1
- package/dist/finstrong/components/shared/Transactions.d.ts +1 -1
- package/dist/finstrong/index.es.js +161 -159
- package/dist/finstrong/stores/FinstrongStore.d.ts +3 -2
- package/dist/finstrong/util/finstrongUtils.d.ts +3 -3
- package/dist/goals/GoalsWidget.d.ts +1 -1
- package/dist/goals/api/GoalApi.d.ts +2 -2
- package/dist/goals/components/AccountSelectionDrawer.d.ts +1 -1
- package/dist/goals/components/AddGoal.d.ts +1 -1
- package/dist/goals/components/GoalDetails.d.ts +1 -1
- package/dist/goals/components/GoalDetailsDrawer.d.ts +1 -1
- package/dist/goals/components/GoalList.d.ts +1 -1
- package/dist/goals/components/GoalStatusCard.d.ts +1 -1
- package/dist/goals/components/ManageGoals.d.ts +1 -1
- package/dist/goals/components/actions/AccountAction.d.ts +1 -1
- package/dist/goals/components/actions/AddRetirementAccountAction.d.ts +1 -1
- package/dist/goals/components/actions/AmountToSaveAction.d.ts +1 -1
- package/dist/goals/components/actions/BirthdayAction.d.ts +1 -1
- package/dist/goals/components/actions/ChangeAccountAction.d.ts +1 -1
- package/dist/goals/components/actions/ContributionAction.d.ts +1 -1
- package/dist/goals/components/actions/GoalNameAction.d.ts +1 -1
- package/dist/goals/components/actions/InterestRateAction.d.ts +1 -1
- package/dist/goals/components/actions/MonthlyPaymentAction.d.ts +1 -1
- package/dist/goals/components/actions/OriginalBalanceAction.d.ts +1 -1
- package/dist/goals/components/actions/RetirementAgeAction.d.ts +1 -1
- package/dist/goals/components/addgoal/AddGoalListItem.d.ts +1 -1
- package/dist/goals/components/managegoals/CompleteListItem.d.ts +1 -1
- package/dist/goals/components/managegoals/OngoingListItem.d.ts +1 -1
- package/dist/goals/components/managegoals/ReorderGoals.d.ts +1 -1
- package/dist/goals/components/micro/GoalMicroStatusCard.d.ts +1 -1
- package/dist/goals/index.es.js +445 -419
- package/dist/goals/stores/GoalStore.d.ts +2 -1
- package/dist/goals/util/GoalsUtil.d.ts +1 -1
- package/dist/help/HelpWidget.d.ts +1 -1
- package/dist/help/api/HelpApi.d.ts +1 -1
- package/dist/help/components/HelpContent.d.ts +1 -1
- package/dist/help/components/HelpList.d.ts +1 -1
- package/dist/help/components/content/BottomImageContent.d.ts +1 -1
- package/dist/help/components/content/ContentItem.d.ts +1 -1
- package/dist/help/components/content/LeftImageContent.d.ts +1 -1
- package/dist/help/components/content/NoImageContent.d.ts +1 -1
- package/dist/help/components/content/RightImageContent.d.ts +1 -1
- package/dist/help/components/content/TopImageContent.d.ts +1 -1
- package/dist/help/components/content/section/Accounts.d.ts +1 -1
- package/dist/help/components/content/section/Budgets.d.ts +1 -1
- package/dist/help/components/content/section/CashFlow.d.ts +1 -1
- package/dist/help/components/content/section/Debts.d.ts +1 -1
- package/dist/help/components/content/section/General.d.ts +1 -1
- package/dist/help/components/content/section/Goals.d.ts +1 -1
- package/dist/help/components/content/section/Insights.d.ts +1 -1
- package/dist/help/components/content/section/Investments.d.ts +1 -1
- package/dist/help/components/content/section/Mobile.d.ts +1 -1
- package/dist/help/components/content/section/NetWorth.d.ts +1 -1
- package/dist/help/components/content/section/Notifications.d.ts +1 -1
- package/dist/help/components/content/section/RecurringTransactions.d.ts +1 -1
- package/dist/help/components/content/section/Spending.d.ts +1 -1
- package/dist/help/components/content/section/Transactions.d.ts +1 -1
- package/dist/help/components/content/section/Trends.d.ts +1 -1
- package/dist/help/components/content/section/index.d.ts +15 -15
- package/dist/help/components/requestsupport/ContactSupport.d.ts +1 -1
- package/dist/help/components/requestsupport/HelpByCategoryList.d.ts +1 -1
- package/dist/help/components/requestsupport/MissingInstitution.d.ts +1 -1
- package/dist/help/components/requestsupport/PopularTopicsDrawer.d.ts +1 -1
- package/dist/help/components/requestsupport/PopularTopicsList.d.ts +1 -1
- package/dist/help/components/requestsupport/RequestSupport.d.ts +1 -1
- package/dist/help/components/requestsupport/RequestSupportFooter.d.ts +1 -1
- package/dist/help/components/requestsupport/RequestSupportInstitution.d.ts +1 -1
- package/dist/help/components/requestsupport/SupportSuccessMessage.d.ts +1 -1
- package/dist/help/index.es.js +8 -8
- package/dist/help/store/HelpStore.d.ts +5 -4
- package/dist/help/utils/getAccessibleHelpCategories.d.ts +2 -2
- package/dist/{hooks-CBl85iRr.mjs → hooks-BxkfR-Ff.mjs} +12 -12
- package/dist/insights/components/feed/Header.d.ts +8 -0
- package/dist/insights/components/index.d.ts +4 -0
- package/dist/insights/components/insights/CategoryBudget/types/CategoryBudget.d.ts +1 -0
- package/dist/insights/components/insights/CategorySpendingV2/types/CategorySpendingV2.d.ts +1 -0
- package/dist/insights/components/shared/ChartDrawerTemplate/ChartDrawerTemplate.d.ts +2 -1
- package/dist/insights/components/shared/ChartDrawerTemplate/TipSection.d.ts +3 -1
- package/dist/insights/components/shared/ChartTransactionWithDrillDown.d.ts +2 -1
- package/dist/insights/components/shared/DonutChartV2.d.ts +13 -0
- package/dist/insights/components/shared/InsightsCard/BeatCardMUI.d.ts +20 -0
- package/dist/insights/components/shared/InsightsCard/CardHeaderMUI.d.ts +11 -0
- package/dist/insights/components/shared/InsightsCard/ContentAndDescriptionMUI.d.ts +17 -0
- package/dist/insights/components/shared/InsightsCard/DescriptionMUI.d.ts +12 -0
- package/dist/insights/components/shared/InsightsCard/MiniDescriptionMUI.d.ts +9 -0
- package/dist/insights/components/shared/StatusIndicator.d.ts +1 -1
- package/dist/insights/components/shared/TransactionCard.d.ts +14 -0
- package/dist/insights/index.es.js +1361 -1081
- package/dist/insights/store/BeatStore.d.ts +1 -1
- package/dist/investments/InvestmentsWidget.d.ts +1 -1
- package/dist/investments/api/HoldingApi.d.ts +1 -1
- package/dist/investments/components/allocation/util/createInvestementsAllocationData.d.ts +2 -2
- package/dist/investments/index.es.js +258 -258
- package/dist/investments/stores/HoldingStore.d.ts +2 -1
- package/dist/investments/util/InvestmentUtil.d.ts +1 -1
- package/dist/merchants/api/MerchantApi.d.ts +1 -1
- package/dist/merchants/index.es.js +16 -16
- package/dist/merchants/stores/MerchantStore.d.ts +2 -1
- package/dist/microinsights/InsightsMicroWidget.d.ts +1 -1
- package/dist/microinsights/beaticons/AreaChartIcon.d.ts +3 -0
- package/dist/microinsights/beaticons/AverageSpendComparisonIcon.d.ts +3 -0
- package/dist/microinsights/beaticons/BeatMaterialIcon.d.ts +5 -1
- package/dist/microinsights/beaticons/InstitutionLogoIcon.d.ts +5 -0
- package/dist/microinsights/beaticons/MonthlySpendComparisonIcon.d.ts +0 -2
- package/dist/microinsights/beaticons/index.d.ts +3 -0
- package/dist/microinsights/cards/InsightCard.d.ts +1 -1
- package/dist/microinsights/carousel/BeatList.d.ts +1 -1
- package/dist/microinsights/carousel/CarouselHeader.d.ts +1 -1
- package/dist/microinsights/carousel/MicroBeatCarousel.d.ts +1 -1
- package/dist/microinsights/constants/Analytics.d.ts +1 -1
- package/dist/microinsights/context/InsightsMicroWidgetDataProvider.d.ts +1 -1
- package/dist/microinsights/context/hooks.d.ts +1 -1
- package/dist/microinsights/index.es.js +1 -1
- package/dist/microinsights/interfaces.d.ts +1 -1
- package/dist/microinsights/stores/CopyStore.d.ts +1 -1
- package/dist/microinsights/stores/InsightsMicroWidgetStore.d.ts +1 -1
- package/dist/microinsights/utils/DataSeries.d.ts +1 -1
- package/dist/microinsights/utils/colorType.d.ts +22 -0
- package/dist/networth/NetWorthWidget.d.ts +1 -1
- package/dist/networth/components/micro/NetworthData.d.ts +1 -1
- package/dist/networth/components/micro/ZeroState.d.ts +1 -1
- package/dist/networth/index.es.js +181 -174
- package/dist/networth/stores/NetWorthStore.d.ts +2 -1
- package/dist/networth/types/NetWorth.d.ts +1 -1
- package/dist/networth/utils/NetWorthUtils.d.ts +1 -1
- package/dist/notifications/components/NotificationBadge.d.ts +1 -1
- package/dist/notifications/components/NotificationCard.d.ts +1 -1
- package/dist/notifications/components/NotificationDrawer.d.ts +1 -1
- package/dist/notifications/components/NotificationList.d.ts +2 -1
- package/dist/notifications/index.es.js +104 -92
- package/dist/notifications/stores/NotificationStore.d.ts +2 -1
- package/dist/notifications/utils/NotificationUtils.d.ts +2 -1
- package/dist/recurringtransactions/RecurringTransactionsMiniWidget.d.ts +1 -1
- package/dist/recurringtransactions/RecurringTransactionsWidget.d.ts +1 -1
- package/dist/recurringtransactions/api/RepeatingTransactionsApi.d.ts +2 -1
- package/dist/recurringtransactions/components/PaymentSchedule.d.ts +1 -1
- package/dist/recurringtransactions/components/RecurrenceList.d.ts +1 -1
- package/dist/recurringtransactions/components/RecurrenceRow.d.ts +1 -1
- package/dist/recurringtransactions/components/RecurringTransactionDetails.d.ts +1 -1
- package/dist/recurringtransactions/components/actions/PaymentScheduleAction.d.ts +1 -1
- package/dist/recurringtransactions/components/micro/MerchantLogosRow.d.ts +1 -1
- package/dist/recurringtransactions/components/micro/OverlappingMerchantLogos.d.ts +1 -1
- package/dist/recurringtransactions/components/shared/recurringsettings/AddRecurringTransactionDetails.d.ts +1 -1
- package/dist/recurringtransactions/components/shared/recurringsettings/RecurringRow.d.ts +1 -1
- package/dist/recurringtransactions/index.es.js +477 -451
- package/dist/recurringtransactions/stores/RecurringTransactionsStore.d.ts +2 -1
- package/dist/recurringtransactions/util/RecurringTransactions.d.ts +1 -1
- package/dist/repeatingTransactions-DHIG94pi.mjs +4 -0
- package/dist/settings/NotificationSettingsWidget.d.ts +1 -1
- package/dist/settings/SettingsWidget.d.ts +1 -1
- package/dist/settings/TransactionRulesWidget.d.ts +1 -1
- package/dist/settings/api/SettingsApi.d.ts +1 -2
- package/dist/settings/components/devices/DeviceDialog.d.ts +1 -1
- package/dist/settings/components/devices/DeviceList.d.ts +1 -1
- package/dist/settings/components/devices/DeviceTable.d.ts +1 -1
- package/dist/settings/components/notifications/AccountNotificationProfile.d.ts +1 -1
- package/dist/settings/components/notifications/AccountProfileListItem.d.ts +1 -1
- package/dist/settings/components/notifications/NotificationProfile.d.ts +1 -1
- package/dist/settings/components/notifications/NotificationSettings.d.ts +1 -1
- package/dist/settings/components/transactionrules/actions/EditRuleAction.d.ts +1 -1
- package/dist/settings/index.es.js +314 -323
- package/dist/settings/stores/SettingsStore.d.ts +3 -2
- package/dist/settings/util/Notifications.d.ts +1 -1
- package/dist/spending/SpendingMiniWidget.d.ts +1 -1
- package/dist/spending/SpendingWidget.d.ts +1 -1
- package/dist/spending/index.es.js +167 -166
- package/dist/spending/utils/SpendingData.d.ts +1 -1
- package/dist/transactions/TransactionWidget.d.ts +1 -1
- package/dist/transactions/api/TransactionApi.d.ts +1 -1
- package/dist/transactions/components/shared/TransactionDetails.d.ts +1 -1
- package/dist/transactions/components/shared/TransactionList.d.ts +1 -1
- package/dist/transactions/components/shared/getEmbeddedInstanceSlotByBeatTemplates.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/Description.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/FlagTransaction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/TransactionAmountHeader.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/TransactionDetailsView.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/AddMerchantBudgetAction.d.ts +13 -0
- package/dist/transactions/components/shared/transactiondetails/actions/CategoryAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/DateAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/DeleteAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/DeleteLogoAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/HideAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/MemoAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/SplitAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/TagsAction.d.ts +1 -1
- package/dist/transactions/components/shared/transactiondetails/actions/index.d.ts +1 -0
- package/dist/transactions/components/shared/transactionlist/TransactionRow.d.ts +1 -1
- package/dist/transactions/components/splitmanager/SplitManager.d.ts +1 -1
- package/dist/transactions/components/splitmanager/SplitRow.d.ts +1 -1
- package/dist/transactions/components/tagmanager/TagRow.d.ts +1 -1
- package/dist/transactions/components/transactionwidget/actions/EditCategoryAction.d.ts +1 -1
- package/dist/transactions/components/transactionwidget/actions/ExportCsvAction.d.ts +1 -1
- package/dist/transactions/constants/Actions.d.ts +4 -3
- package/dist/transactions/constants/Transaction.d.ts +1 -1
- package/dist/transactions/index.es.js +195 -187
- package/dist/transactions/stores/TransactionStore.d.ts +2 -1
- package/dist/transactions/stores/UiStore.d.ts +1 -1
- package/dist/transactions/utils/Filters.d.ts +1 -1
- package/dist/transactions/utils/Transactions.d.ts +1 -1
- package/dist/transactions/utils/buildDetailedTransactions.d.ts +2 -2
- package/dist/transactions/utils/exportTransactionsToCSV.d.ts +1 -1
- package/dist/transactions/utils/sortAndFilterTransactions.d.ts +1 -1
- package/dist/trends/TrendsFullWidget.d.ts +1 -1
- package/dist/trends/TrendsMiniWidget.d.ts +1 -1
- package/dist/trends/TrendsWidget.d.ts +1 -1
- package/dist/trends/components/CategoriesList.d.ts +1 -1
- package/dist/trends/components/CategoriesListItem.d.ts +1 -1
- package/dist/trends/components/CategoryDetails.d.ts +3 -0
- package/dist/trends/components/TrendsChartTotals.d.ts +1 -1
- package/dist/trends/components/TrendsInsights.d.ts +1 -1
- package/dist/trends/components/trendstable/AccessibleSortIcon.d.ts +13 -0
- package/dist/trends/components/trendstable/TrendsTable.d.ts +1 -1
- package/dist/trends/index.es.js +817 -764
- package/dist/trends/stores/TrendsStore.d.ts +2 -1
- package/dist/trends/utils/SpendingData.d.ts +1 -1
- package/dist/trends/utils/TrendsData.d.ts +1 -1
- package/dist/trends/utils/TrendsTable.d.ts +1 -1
- package/dist/trends/utils/TrendsWidget.d.ts +7 -0
- package/dist/trends/utils/shared.d.ts +1 -1
- package/dist/{useAccountDisplayName-b2xxcD0C.mjs → useAccountDisplayName-DKwT1mWv.mjs} +1 -1
- package/dist/{useCombineEvents-ARuNN9Xh.mjs → useCombineEvents-Bqojlv8q.mjs} +3 -3
- package/dist/{useInsightsEnabled-Dd-AfsqC.mjs → useInsightsEnabled-DL_oNyI0.mjs} +1 -1
- package/dist/{useWidgetLoadTimer-DmNCCLa-.mjs → useWidgetLoadTimer-DgN1bTyu.mjs} +1 -1
- package/package.json +17 -10
- package/dist/AccountDetailsHeader-Bn2E0Qjk.mjs +0 -95
- package/dist/AccountListItem-k63LpVBs.mjs +0 -90
- package/dist/Accounts-CuE8aSZN.mjs +0 -27
- package/dist/BudgetUtil-BZiGckNY.mjs +0 -238
- package/dist/CashflowStore-naOtJcwo.mjs +0 -91
- package/dist/CurrencyInput-BEB3FS70.mjs +0 -85
- package/dist/Dialog-jmgGw5WA.mjs +0 -58
- package/dist/GlobalAccountFilter-CIF-aT3F.mjs +0 -316
- package/dist/GoalStore-BjHKNAVm.mjs +0 -421
- package/dist/HeaderCell-DjuifqHJ.mjs +0 -6
- package/dist/LineChart-CnscUFUG.mjs +0 -580
- package/dist/Loader-icSc5MlE.mjs +0 -24
- package/dist/Localization-2MODESHW.mjs +0 -30
- package/dist/MicroWidgetContainer-CBRk9KG-.mjs +0 -45
- package/dist/MiniWidgetContainer-CXQcSWSl.mjs +0 -56
- package/dist/Notification-Bs1fdbzI.mjs +0 -95
- package/dist/RecurringTransactions-DlKYwpfK.mjs +0 -296
- package/dist/SearchBox-B2_zLv8-.mjs +0 -42
- package/dist/SpendingLegend-Bld71d7q.mjs +0 -193
- package/dist/StatusIndicator-CNMQeYyJ.mjs +0 -55
- package/dist/TransactionDetails-Lvt9GCU5.mjs +0 -1194
- package/dist/TransactionList-BDffKJMO.mjs +0 -204
- package/dist/User-DS18cMaz.mjs +0 -237
- package/dist/ViewMoreMicroCard-YHRLl08A.mjs +0 -1152
- package/dist/common/components/barchart/Bar.d.ts +0 -25
- package/dist/common/components/barchart/BarChart.d.ts +0 -34
- package/dist/common/components/barchart/BarColumn.d.ts +0 -37
- package/dist/common/components/barchart/Legend.d.ts +0 -8
- package/dist/common/components/barchart/Util.d.ts +0 -42
- package/dist/common/components/barchart/index.d.ts +0 -1
- package/dist/common/types/SpendingPlan.d.ts +0 -44
- package/dist/transactions/components/shared/transactionlist/DateRow.d.ts +0 -7
- package/dist/trends/components/CategoryDetailDrawer.d.ts +0 -7
- /package/dist/{common → core}/types/Account.d.ts +0 -0
- /package/dist/{common → core}/types/Cashflow.d.ts +0 -0
- /package/dist/{common → core}/types/Category.d.ts +0 -0
- /package/dist/{common → core}/types/Client.d.ts +0 -0
- /package/dist/{common → core}/types/Date.d.ts +0 -0
- /package/dist/{common → core}/types/Debt.d.ts +0 -0
- /package/dist/{common → core}/types/Global.d.ts +0 -0
- /package/dist/{common → core}/types/GlobalCopy.d.ts +0 -0
- /package/dist/{common → core}/types/Goal.d.ts +0 -0
- /package/dist/{common → core}/types/Handlers.d.ts +0 -0
- /package/dist/{common → core}/types/Help.d.ts +0 -0
- /package/dist/{common → core}/types/Holding.d.ts +0 -0
- /package/dist/{common → core}/types/Institution.d.ts +0 -0
- /package/dist/{common → core}/types/LocalizedContent.d.ts +0 -0
- /package/dist/{common → core}/types/Merchant.d.ts +0 -0
- /package/dist/{common → core}/types/RepeatingTransaction.d.ts +0 -0
- /package/dist/{common → core}/types/ScheduledPayment.d.ts +0 -0
- /package/dist/{common → core}/types/ScreenSize.d.ts +0 -0
- /package/dist/{common → core}/types/Transaction.d.ts +0 -0
- /package/dist/{common → core}/types/User.d.ts +0 -0
- /package/dist/{common → core}/types/Widgets.d.ts +0 -0
- /package/dist/{common → core}/types/localization/AccountFilterCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/AccountTypeCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/AccountsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/AnalyticsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/CategoryCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/ConnectCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/CurrencyInputCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/DateRangePickerCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/FinstrongCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/GoalsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/HelpCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/InsightsFeedCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/InvestmentsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/MicroInsightsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/NetWorthCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/NotificationsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/SettingsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/TransactionsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/TrendsCopy.d.ts +0 -0
- /package/dist/{common → core}/types/localization/index.d.ts +0 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { A as e, C as u, E as p, c as y, M as d } from "./Account-BiB1F8lL.mjs";
|
|
2
|
+
const m = (t) => t && (t.account_type === e.CREDIT_CARD || t.account_type === e.LOAN || t.account_type === e.MORTGAGE || t.account_type === e.LINE_OF_CREDIT || t.account_type === e.CHECKING_LINE_OF_CREDIT), I = (t) => t.is_manual || !t.guid, f = (t) => t.account_type === e.LINE_OF_CREDIT || t.account_type === e.CREDIT_CARD || t.account_type === e.CHECKING_LINE_OF_CREDIT, R = (t) => t.account_type === e.SAVINGS || t.account_type === e.CHECKING || t.account_type === e.LINE_OF_CREDIT || t.account_type === e.CREDIT_CARD || t.account_type === e.LOAN || t.account_type === e.MORTGAGE, A = (t) => t.account_type === e.LOAN || t.account_type === e.MORTGAGE, N = (t, n, s, _, a) => t.filter((i) => !(i.member_is_managed_by_user && _)).filter((i) => !(!i.member_is_managed_by_user && a)).sort(C).map((i) => {
|
|
3
|
+
const r = n.find((c) => c.guid === i.institution_guid), o = s.find((c) => c.guid === i.member_guid);
|
|
4
|
+
return E(i, r, o);
|
|
5
|
+
}), E = (t, n, s) => {
|
|
6
|
+
let _ = u.Connected;
|
|
7
|
+
s && (p.includes(s.connection_status) ? _ = u.Error : y.includes(s.connection_status) ? _ = u.Processing : d.includes(s.connection_status) && (_ = u.RequiresMfa));
|
|
8
|
+
const a = [
|
|
9
|
+
t.user_name || t.feed_name || "",
|
|
10
|
+
t.account_number ? `*${t.account_number}` : ""
|
|
11
|
+
].join(" ").trim();
|
|
12
|
+
return {
|
|
13
|
+
...t,
|
|
14
|
+
connectionStatus: _,
|
|
15
|
+
displayName: a,
|
|
16
|
+
institution: n,
|
|
17
|
+
member: s
|
|
18
|
+
};
|
|
19
|
+
}, C = (t, n) => t.account_type > n.account_type ? 1 : t.account_type < n.account_type ? -1 : (t.name || "") > (n.name || "") ? 1 : (t.name || "") < (n.name || "") ? -1 : 0;
|
|
20
|
+
export {
|
|
21
|
+
m as a,
|
|
22
|
+
f as b,
|
|
23
|
+
A as c,
|
|
24
|
+
N as d,
|
|
25
|
+
I as i,
|
|
26
|
+
R as u
|
|
27
|
+
};
|
|
@@ -35,6 +35,16 @@ const _ = {
|
|
|
35
35
|
GOALS_CLICK_FILTER: "goals_widget_click_filter_accounts",
|
|
36
36
|
GOALS_VIEW: "goals",
|
|
37
37
|
GOALS_MICRO_WIDGET_CTA: "goals_micro_widget_click_see_details_cta",
|
|
38
|
+
HELP_CLICK_CATEGORY: "help_click_category",
|
|
39
|
+
HELP_CLICK_REQUEST_SUPPORT: "help_click_requestSupport",
|
|
40
|
+
HELP_CLICK_SUPPORT_FOR_INSTITUTION: "help_click_supportForInstitution",
|
|
41
|
+
HELP_CLICK_SUPPORT_FOR_MISSING_INSTITUTION: "help_click_supportForMissingInstitution",
|
|
42
|
+
HELP_CLICK_SUPPORT_TOPIC: "help_click_supportTopic",
|
|
43
|
+
HELP_CLICK_TOPIC: "help_click_topic",
|
|
44
|
+
HELP_EXPAND_CATEGORY: "help_expand_category",
|
|
45
|
+
HELP_EXPAND_TOPIC: "help_expand_topic",
|
|
46
|
+
HELP_OPEN_SUPPORT_REQUEST: "help_open_supportRequest",
|
|
47
|
+
HELP_SUBMIT_SUPPORT_REQUEST: "help_submit_supportRequest",
|
|
38
48
|
INVESTMENTS: "Investments",
|
|
39
49
|
INVESTMENT_WIDGET_ACCOUNT_FILTER_CLICK: "investment_widget_account_filter_click",
|
|
40
50
|
INVESTMENT_WIDGET_ALLOCATION_CLICK: "investment_widget_allocation_click",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { makeAutoObservable as c, runInAction as r } from "mobx";
|
|
2
|
-
import { B as l } from "./BeatApi-
|
|
2
|
+
import { B as l } from "./BeatApi-EFHXULDx.mjs";
|
|
3
3
|
function d(t, e, s, i = "asc") {
|
|
4
4
|
const a = i === "desc" ? -1 : 1;
|
|
5
5
|
return [...t, ...e].sort((_, n) => _[s] < n[s] ? -1 * a : _[s] > n[s] ? 1 * a : 0);
|
|
@@ -0,0 +1,479 @@
|
|
|
1
|
+
import { jsxs as h, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import k from "react";
|
|
3
|
+
import { css as R } from "@mxenabled/cssinjs";
|
|
4
|
+
import { addDays as G } from "date-fns/addDays";
|
|
5
|
+
import { addMonths as P } from "date-fns/addMonths";
|
|
6
|
+
import { eachDayOfInterval as Y } from "date-fns/eachDayOfInterval";
|
|
7
|
+
import { eachWeekOfInterval as Z } from "date-fns/eachWeekOfInterval";
|
|
8
|
+
import { endOfMonth as q } from "date-fns/endOfMonth";
|
|
9
|
+
import { format as L } from "date-fns/format";
|
|
10
|
+
import { isBefore as J } from "date-fns/isBefore";
|
|
11
|
+
import { isSameMonth as K } from "date-fns/isSameMonth";
|
|
12
|
+
import { startOfMonth as Q } from "date-fns/startOfMonth";
|
|
13
|
+
import { startOfToday as I } from "date-fns/startOfToday";
|
|
14
|
+
import { subMonths as U } from "date-fns/subMonths";
|
|
15
|
+
import C from "@mui/material/Button";
|
|
16
|
+
import V from "@mui/material/Paper";
|
|
17
|
+
import { H2 as X, Text as z, H3 as tt, P as et } from "@mxenabled/mxui";
|
|
18
|
+
import { ChevronLeft as nt, ChevronRight as ot, Icon as rt } from "@mxenabled/mx-icons";
|
|
19
|
+
import { f as at, D as it } from "./DateFormats-BMpMrZpW.mjs";
|
|
20
|
+
import { isSameDay as f } from "date-fns/isSameDay";
|
|
21
|
+
import { isWithinInterval as st } from "date-fns/isWithinInterval";
|
|
22
|
+
import ct from "@mui/material/styles/useTheme";
|
|
23
|
+
import lt from "@mui/material/Dialog";
|
|
24
|
+
import dt from "@mui/material/DialogActions";
|
|
25
|
+
import mt from "@mui/material/DialogContent";
|
|
26
|
+
import ut from "@mui/material/IconButton";
|
|
27
|
+
import gt from "@mui/material/InputAdornment";
|
|
28
|
+
import E from "@mui/material/Stack";
|
|
29
|
+
import ft from "@mui/material/TextField";
|
|
30
|
+
import { u as pt } from "./useScreenSize-B6JyS_Lj.mjs";
|
|
31
|
+
import { m as ht } from "./hooks-BxkfR-Ff.mjs";
|
|
32
|
+
import { b as T } from "./Category-CevNQ03n.mjs";
|
|
33
|
+
import { b as j } from "./Localization-CPkpIwIx.mjs";
|
|
34
|
+
import { f as O } from "./NumberFormatting-QCaNwbjv.mjs";
|
|
35
|
+
const W = (t, n) => t.find((e) => e.guid === n), xt = (t, n) => t.find((e) => e.guid === n), yt = (t, n) => {
|
|
36
|
+
const e = t.find((o) => o.subCategories.find((a) => a.guid === n));
|
|
37
|
+
if (e)
|
|
38
|
+
return e.subCategories.find((o) => o.guid === n);
|
|
39
|
+
}, ce = (t, n) => {
|
|
40
|
+
const e = [];
|
|
41
|
+
for (const o of n) {
|
|
42
|
+
const a = W(t, o.category_guid);
|
|
43
|
+
if (!a) continue;
|
|
44
|
+
const s = a.parent_guid ?? a.guid, d = W(t, s);
|
|
45
|
+
if (!d) continue;
|
|
46
|
+
const i = {
|
|
47
|
+
amount: o.total,
|
|
48
|
+
category: a,
|
|
49
|
+
guid: a.guid,
|
|
50
|
+
subCategoryTotals: []
|
|
51
|
+
}, l = e.find((m) => m.guid === s);
|
|
52
|
+
l ? (l.amount += o.total, l.subCategoryTotals.push(i)) : e.push({
|
|
53
|
+
amount: o.total,
|
|
54
|
+
category: d,
|
|
55
|
+
guid: s,
|
|
56
|
+
subCategoryTotals: [i]
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
return e;
|
|
60
|
+
}, le = (t, n) => {
|
|
61
|
+
const e = t.find((o) => o.guid === n);
|
|
62
|
+
return e ? e.guid === T.INCOME || e.parent_guid === T.INCOME : !1;
|
|
63
|
+
}, bt = ({ copy: t, date: n, onNextClick: e, onPreviousClick: o }) => {
|
|
64
|
+
const a = Ct();
|
|
65
|
+
return /* @__PURE__ */ h("div", { className: `mx-cmn-calendar-header ${a}`, children: [
|
|
66
|
+
/* @__PURE__ */ r(X, { className: "mx-cmn-calendar-header-title", variant: "h3", children: at(n, it.MONTH_YEAR) }),
|
|
67
|
+
/* @__PURE__ */ h("div", { className: "mx-cmn-calendar-header-button-container", children: [
|
|
68
|
+
/* @__PURE__ */ r(C, { "aria-label": t.prevAria, onClick: o, children: /* @__PURE__ */ r(nt, { size: 24 }) }),
|
|
69
|
+
/* @__PURE__ */ r(C, { "aria-label": t.nextAria, onClick: e, children: /* @__PURE__ */ r(ot, { size: 24 }) })
|
|
70
|
+
] })
|
|
71
|
+
] });
|
|
72
|
+
}, Ct = () => R({
|
|
73
|
+
alignItems: "center",
|
|
74
|
+
display: "flex",
|
|
75
|
+
marginBottom: 16,
|
|
76
|
+
marginRight: -16,
|
|
77
|
+
paddingLeft: 8,
|
|
78
|
+
"& .mx-cmn-calendar-header-title": {
|
|
79
|
+
flexGrow: 1
|
|
80
|
+
},
|
|
81
|
+
"& .mx-cmn-calendar-header-button-container": {
|
|
82
|
+
display: "flex",
|
|
83
|
+
gap: 4
|
|
84
|
+
}
|
|
85
|
+
}), vt = ({ beginDate: t, date: n, endDate: e, isInMonth: o, onClick: a }) => {
|
|
86
|
+
const s = ct(), d = kt(s), i = t && e && st(n, { start: t, end: e }) && !f(n, t) && !f(n, e), l = t && e && f(t, n) && !f(t, e), m = e && t && f(e, n) && !f(t, e), u = t && f(t, n) || e && f(e, n), p = f(n, I());
|
|
87
|
+
return /* @__PURE__ */ r(
|
|
88
|
+
"div",
|
|
89
|
+
{
|
|
90
|
+
className: `
|
|
91
|
+
mx-cmn-calendar-day
|
|
92
|
+
${d}
|
|
93
|
+
${o ? "" : "mx-cmn-out-of-month"}
|
|
94
|
+
${i ? "mx-cmn-date-interval" : ""}
|
|
95
|
+
`,
|
|
96
|
+
children: /* @__PURE__ */ r(
|
|
97
|
+
C,
|
|
98
|
+
{
|
|
99
|
+
className: `
|
|
100
|
+
mx-cmn-calendar-day-button
|
|
101
|
+
${l ? "mx-cmn-range-start" : ""}
|
|
102
|
+
${m ? "mx-cmn-range-end" : ""}
|
|
103
|
+
`,
|
|
104
|
+
color: u ? "primary" : "secondary",
|
|
105
|
+
onClick: () => a(n),
|
|
106
|
+
variant: u ? "contained" : "text",
|
|
107
|
+
children: /* @__PURE__ */ r(
|
|
108
|
+
z,
|
|
109
|
+
{
|
|
110
|
+
className: `
|
|
111
|
+
mx-cmn-calendar-day-text
|
|
112
|
+
${u ? "mx-cmn-day-selected" : ""}
|
|
113
|
+
${p ? "mx-cmn-today" : ""}`,
|
|
114
|
+
variant: "body2",
|
|
115
|
+
children: L(n, "d")
|
|
116
|
+
}
|
|
117
|
+
)
|
|
118
|
+
}
|
|
119
|
+
)
|
|
120
|
+
}
|
|
121
|
+
);
|
|
122
|
+
}, kt = (t) => R({
|
|
123
|
+
height: B,
|
|
124
|
+
width: B,
|
|
125
|
+
display: "flex",
|
|
126
|
+
justifyContent: "center",
|
|
127
|
+
"&.mx-cmn-out-of-month": {
|
|
128
|
+
backgroundColor: t.palette.background.default
|
|
129
|
+
},
|
|
130
|
+
"&.mx-cmn-date-interval": {
|
|
131
|
+
backgroundColor: t.palette.secondary.light
|
|
132
|
+
},
|
|
133
|
+
"& .MuiButton-root": {
|
|
134
|
+
maxWidth: 44,
|
|
135
|
+
minWidth: 44,
|
|
136
|
+
height: 44,
|
|
137
|
+
padding: 0,
|
|
138
|
+
width: 44,
|
|
139
|
+
"&.mx-cmn-range-start": {
|
|
140
|
+
borderTopRightRadius: 0,
|
|
141
|
+
borderBottomRightRadius: 0,
|
|
142
|
+
"&:focus": {
|
|
143
|
+
boxShadow: "none"
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
"&.mx-cmn-range-end": {
|
|
147
|
+
borderTopLeftRadius: 0,
|
|
148
|
+
borderBottomLeftRadius: 0,
|
|
149
|
+
"&:focus": {
|
|
150
|
+
boxShadow: "none"
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"& .mx-cmn-calendar-day-text": {
|
|
155
|
+
"&.mx-cmn-day-selected": {
|
|
156
|
+
color: t.palette.primary,
|
|
157
|
+
"&.mx-cmn-day-selected": {
|
|
158
|
+
borderColor: t.palette.common.white
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
"&.mx-cmn-today": {
|
|
162
|
+
borderBottom: `solid 2px ${t.palette.primary.main}`,
|
|
163
|
+
marginBottom: -6,
|
|
164
|
+
paddingBottom: 5
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}), Bt = 340, B = 44;
|
|
168
|
+
var wt = /* @__PURE__ */ ((t) => (t.None = "None", t.Single = "Single", t.Range = "Range", t))(wt || {});
|
|
169
|
+
const _t = ({
|
|
170
|
+
copy: t,
|
|
171
|
+
beginDate: n = void 0,
|
|
172
|
+
endDate: e = void 0,
|
|
173
|
+
onDateSelected: o,
|
|
174
|
+
onRangeSelected: a,
|
|
175
|
+
selectionType: s = "Single"
|
|
176
|
+
/* Single */
|
|
177
|
+
}) => {
|
|
178
|
+
const d = St(), [i, l] = k.useState(I), [m, u] = k.useState(n), [p, g] = k.useState(e);
|
|
179
|
+
k.useEffect(() => {
|
|
180
|
+
u(n), g(e), n && l(n);
|
|
181
|
+
}, [n, e]);
|
|
182
|
+
const v = k.useMemo(() => {
|
|
183
|
+
const c = Z({ start: Q(i), end: q(i) }), y = [];
|
|
184
|
+
for (let b = 0; b < c.length; b++) {
|
|
185
|
+
const w = c[b], $ = Y({ start: w, end: G(w, 6) }), A = [];
|
|
186
|
+
for (let M = 0; M < $.length; M++)
|
|
187
|
+
A.push($[M]);
|
|
188
|
+
y.push(A);
|
|
189
|
+
}
|
|
190
|
+
return y;
|
|
191
|
+
}, [i]), _ = (c) => {
|
|
192
|
+
if (s !== "None") {
|
|
193
|
+
if (s === "Single") {
|
|
194
|
+
u(c), o?.(c);
|
|
195
|
+
return;
|
|
196
|
+
}
|
|
197
|
+
!m || p ? (u(c), g(void 0)) : J(c, m) ? (g(m), u(c), a?.(c, m)) : (g(c), a?.(m, c));
|
|
198
|
+
}
|
|
199
|
+
}, S = () => {
|
|
200
|
+
const c = I();
|
|
201
|
+
l(c), s !== "None" && (u(c), s === "Single" ? o?.(c) : (g(c), a?.(c, c)));
|
|
202
|
+
}, N = () => {
|
|
203
|
+
l(P(i, 1));
|
|
204
|
+
}, x = () => {
|
|
205
|
+
l(U(i, 1));
|
|
206
|
+
};
|
|
207
|
+
return /* @__PURE__ */ r("div", { className: `mx-cmn-calendar ${d}`, children: /* @__PURE__ */ h(V, { sx: { boxShadow: "none" }, children: [
|
|
208
|
+
/* @__PURE__ */ r(
|
|
209
|
+
bt,
|
|
210
|
+
{
|
|
211
|
+
copy: t,
|
|
212
|
+
date: i,
|
|
213
|
+
onNextClick: N,
|
|
214
|
+
onPreviousClick: x
|
|
215
|
+
}
|
|
216
|
+
),
|
|
217
|
+
/* @__PURE__ */ r("div", { className: "mx-cmn-calendar-header-row", children: v[0].map((c, y) => /* @__PURE__ */ r("div", { className: "mx-cmn-calendar-header-cell", children: /* @__PURE__ */ r(z, { bold: !0, variant: "body2", children: L(c, "EEEEE") }) }, y)) }),
|
|
218
|
+
v.map((c, y) => /* @__PURE__ */ r("div", { className: "mx-cmn-calendar-week", children: c.map((b, w) => /* @__PURE__ */ r(
|
|
219
|
+
vt,
|
|
220
|
+
{
|
|
221
|
+
beginDate: m,
|
|
222
|
+
date: b,
|
|
223
|
+
endDate: p,
|
|
224
|
+
isInMonth: K(b, i),
|
|
225
|
+
onClick: _
|
|
226
|
+
},
|
|
227
|
+
w
|
|
228
|
+
)) }, `w-${y}`)),
|
|
229
|
+
/* @__PURE__ */ r("div", { className: "mx-cmn-calendar-today-container", children: /* @__PURE__ */ r(C, { onClick: S, size: "small", variant: "text", children: t.today }) })
|
|
230
|
+
] }) });
|
|
231
|
+
}, St = () => R({
|
|
232
|
+
width: Bt,
|
|
233
|
+
"& .MuiPaper-root": {
|
|
234
|
+
paddingLeft: 24,
|
|
235
|
+
paddingRight: 24,
|
|
236
|
+
paddingTop: 4,
|
|
237
|
+
paddingBottom: 4
|
|
238
|
+
},
|
|
239
|
+
"& .mx-cmn-calendar-header-row": {
|
|
240
|
+
display: "flex",
|
|
241
|
+
justifyContent: "center",
|
|
242
|
+
textAlign: "center",
|
|
243
|
+
"& .mx-cmn-calendar-header-cell": {
|
|
244
|
+
height: B,
|
|
245
|
+
width: B,
|
|
246
|
+
minWidth: B,
|
|
247
|
+
"& .kmui-text": {
|
|
248
|
+
alignItems: "center",
|
|
249
|
+
display: "flex",
|
|
250
|
+
height: "100%",
|
|
251
|
+
justifyContent: "center",
|
|
252
|
+
width: "100%"
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
},
|
|
256
|
+
"& .mx-cmn-calendar-week": {
|
|
257
|
+
display: "flex",
|
|
258
|
+
justifyContent: "center",
|
|
259
|
+
textAlign: "center"
|
|
260
|
+
},
|
|
261
|
+
"& .mx-cmn-calendar-today-container": {
|
|
262
|
+
display: "block",
|
|
263
|
+
marginTop: 16,
|
|
264
|
+
textAlign: "center",
|
|
265
|
+
width: "100%",
|
|
266
|
+
"& > .MuiButton-root": {
|
|
267
|
+
display: "inline-block",
|
|
268
|
+
marginLeft: "auto",
|
|
269
|
+
marginRight: "auto"
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}), de = _t, Nt = ({
|
|
273
|
+
closeAriaLabel: t,
|
|
274
|
+
content: n,
|
|
275
|
+
inputLabel: e,
|
|
276
|
+
inputValue: o,
|
|
277
|
+
isOpen: a,
|
|
278
|
+
handleInputChange: s,
|
|
279
|
+
handleModalClose: d,
|
|
280
|
+
handlePrimaryAction: i,
|
|
281
|
+
handleSecondaryAction: l,
|
|
282
|
+
primaryColor: m = "primary",
|
|
283
|
+
primaryText: u,
|
|
284
|
+
secondaryColor: p = "primary",
|
|
285
|
+
secondaryText: g,
|
|
286
|
+
title: v
|
|
287
|
+
}) => {
|
|
288
|
+
const _ = parseFloat(o ?? "0"), S = o !== "" && o !== "0" && !isNaN(_), { isSmallMobile: N } = pt();
|
|
289
|
+
return /* @__PURE__ */ r(
|
|
290
|
+
lt,
|
|
291
|
+
{
|
|
292
|
+
"aria-label": v,
|
|
293
|
+
"aria-labelledby": "modal-title",
|
|
294
|
+
maxWidth: "xs",
|
|
295
|
+
onClose: d,
|
|
296
|
+
open: a,
|
|
297
|
+
role: "dialog",
|
|
298
|
+
sx: {
|
|
299
|
+
"& .MuiDialogContent-root": { p: 0 },
|
|
300
|
+
...N && { "& .MuiDialog-paper": { minWidth: "100%" } }
|
|
301
|
+
},
|
|
302
|
+
children: /* @__PURE__ */ r(mt, { children: /* @__PURE__ */ h(
|
|
303
|
+
"form",
|
|
304
|
+
{
|
|
305
|
+
onSubmit: (x) => {
|
|
306
|
+
x.preventDefault(), i();
|
|
307
|
+
},
|
|
308
|
+
children: [
|
|
309
|
+
/* @__PURE__ */ h(
|
|
310
|
+
E,
|
|
311
|
+
{
|
|
312
|
+
sx: {
|
|
313
|
+
alignItems: "center",
|
|
314
|
+
flexDirection: "row",
|
|
315
|
+
justifyContent: "space-between",
|
|
316
|
+
pb: 12,
|
|
317
|
+
pl: 24,
|
|
318
|
+
position: "relative",
|
|
319
|
+
pr: 16,
|
|
320
|
+
pt: 24
|
|
321
|
+
},
|
|
322
|
+
children: [
|
|
323
|
+
/* @__PURE__ */ r(tt, { id: "modal-title", children: v }),
|
|
324
|
+
/* @__PURE__ */ r(
|
|
325
|
+
ut,
|
|
326
|
+
{
|
|
327
|
+
"aria-label": t,
|
|
328
|
+
onClick: d,
|
|
329
|
+
sx: { minHeight: 24, position: "absolute", right: 8, top: 18 },
|
|
330
|
+
children: /* @__PURE__ */ r(rt, { name: "close", sx: { color: "action.active" } })
|
|
331
|
+
}
|
|
332
|
+
)
|
|
333
|
+
]
|
|
334
|
+
}
|
|
335
|
+
),
|
|
336
|
+
/* @__PURE__ */ h(E, { sx: { gap: 24, px: 24 }, children: [
|
|
337
|
+
/* @__PURE__ */ r(et, { variant: "subtitle1", children: n }),
|
|
338
|
+
e && /* @__PURE__ */ r(
|
|
339
|
+
ft,
|
|
340
|
+
{
|
|
341
|
+
InputProps: {
|
|
342
|
+
startAdornment: /* @__PURE__ */ r(gt, { position: "start", children: "$" })
|
|
343
|
+
},
|
|
344
|
+
autoFocus: !0,
|
|
345
|
+
inputMode: "decimal",
|
|
346
|
+
inputProps: {
|
|
347
|
+
"aria-label": e,
|
|
348
|
+
noValidate: !0,
|
|
349
|
+
pattern: "[0-9]*\\.?[0-9]*"
|
|
350
|
+
},
|
|
351
|
+
label: e,
|
|
352
|
+
onChange: ({ target: { value: x } }) => {
|
|
353
|
+
/^\d*\.?\d*$/.test(x) && s?.(x);
|
|
354
|
+
},
|
|
355
|
+
type: "text",
|
|
356
|
+
value: o
|
|
357
|
+
}
|
|
358
|
+
)
|
|
359
|
+
] }),
|
|
360
|
+
/* @__PURE__ */ h(
|
|
361
|
+
dt,
|
|
362
|
+
{
|
|
363
|
+
sx: {
|
|
364
|
+
justifyContent: "flex-end",
|
|
365
|
+
gap: 16,
|
|
366
|
+
p: 24,
|
|
367
|
+
">:not(style)~:not(style)": { ml: 0 }
|
|
368
|
+
},
|
|
369
|
+
children: [
|
|
370
|
+
g && /* @__PURE__ */ r(
|
|
371
|
+
C,
|
|
372
|
+
{
|
|
373
|
+
"aria-label": g,
|
|
374
|
+
color: p,
|
|
375
|
+
onClick: l,
|
|
376
|
+
children: g
|
|
377
|
+
}
|
|
378
|
+
),
|
|
379
|
+
/* @__PURE__ */ r(
|
|
380
|
+
C,
|
|
381
|
+
{
|
|
382
|
+
"aria-label": u,
|
|
383
|
+
color: m,
|
|
384
|
+
disabled: e ? !S : !1,
|
|
385
|
+
onClick: i,
|
|
386
|
+
variant: "contained",
|
|
387
|
+
children: u
|
|
388
|
+
}
|
|
389
|
+
)
|
|
390
|
+
]
|
|
391
|
+
}
|
|
392
|
+
)
|
|
393
|
+
]
|
|
394
|
+
}
|
|
395
|
+
) })
|
|
396
|
+
}
|
|
397
|
+
);
|
|
398
|
+
}, me = Nt, ue = (t, n) => !!t.find((e) => e.feature_name === n)?.is_enabled, H = (t, n) => !t && !n ? 0 : !t && n ? 101 : n / t * 100, D = (t, n) => {
|
|
399
|
+
const e = {
|
|
400
|
+
background: n.palette.success.main,
|
|
401
|
+
description: t <= 100 ? n.palette.text.secondary : n.palette.error.main,
|
|
402
|
+
text: n.palette.common.white,
|
|
403
|
+
mercury: n.palette.success.lighter
|
|
404
|
+
};
|
|
405
|
+
return t > 100 ? (e.background = n.palette.error.main, e.mercury = n.palette.error.lighter) : t > 80 && (e.background = n.palette.warning.main, e.text = n.palette.grey[900], e.mercury = n.palette.warning.lighter), e;
|
|
406
|
+
}, ge = () => {
|
|
407
|
+
const { detailedBudgets: t } = ht();
|
|
408
|
+
return t.map((e) => {
|
|
409
|
+
const o = e.transaction_total;
|
|
410
|
+
return e.amount - o;
|
|
411
|
+
}).reduce((e, o) => e + o, 0);
|
|
412
|
+
}, fe = (t, n, e, o) => {
|
|
413
|
+
const a = [];
|
|
414
|
+
for (const s of t) {
|
|
415
|
+
const d = xt(n, s.category_guid);
|
|
416
|
+
if (!d) continue;
|
|
417
|
+
const i = d.totalAmount, l = H(s.amount, i), m = s.amount - i;
|
|
418
|
+
a.push({
|
|
419
|
+
...s,
|
|
420
|
+
budgetColors: D(l, o),
|
|
421
|
+
category: d,
|
|
422
|
+
description: j(
|
|
423
|
+
m < 0 ? e.budget_remaining_over : e.budget_remaining_left,
|
|
424
|
+
O(Math.abs(m), "0,0")
|
|
425
|
+
),
|
|
426
|
+
percentage: l,
|
|
427
|
+
subBudgets: [],
|
|
428
|
+
transaction_total: i
|
|
429
|
+
});
|
|
430
|
+
}
|
|
431
|
+
for (const s of t) {
|
|
432
|
+
const d = yt(n, s.category_guid);
|
|
433
|
+
if (!d) continue;
|
|
434
|
+
const i = d.currentAmount, l = a.find((p) => p.category_guid === d.parent_guid);
|
|
435
|
+
if (!l) continue;
|
|
436
|
+
const m = s.amount - i, u = H(s.amount, i);
|
|
437
|
+
l && l.subBudgets.push({
|
|
438
|
+
...s,
|
|
439
|
+
budgetColors: D(u, o),
|
|
440
|
+
category: d,
|
|
441
|
+
description: j(
|
|
442
|
+
m < 0 ? e.budget_remaining_over : e.budget_remaining_left,
|
|
443
|
+
O(Math.abs(m), "0,0")
|
|
444
|
+
),
|
|
445
|
+
percentage: u,
|
|
446
|
+
subBudgets: [],
|
|
447
|
+
transaction_total: i
|
|
448
|
+
});
|
|
449
|
+
}
|
|
450
|
+
return a;
|
|
451
|
+
}, F = (t, n) => t.find((e) => e.guid === n), pe = (t, n, e) => {
|
|
452
|
+
const o = F(t, e);
|
|
453
|
+
if (o)
|
|
454
|
+
return F(o.subBudgets, n);
|
|
455
|
+
}, he = (t, n) => {
|
|
456
|
+
const e = Math.max(0, n - t), o = n > 0 ? Math.min(100, t / n * 100) : 0;
|
|
457
|
+
let a = "success";
|
|
458
|
+
return o >= 100 ? a = "error" : o >= 50 && (a = "warning"), {
|
|
459
|
+
remainingAmount: e,
|
|
460
|
+
spentPercentage: o,
|
|
461
|
+
iconColor: a
|
|
462
|
+
};
|
|
463
|
+
};
|
|
464
|
+
export {
|
|
465
|
+
me as C,
|
|
466
|
+
de as a,
|
|
467
|
+
wt as b,
|
|
468
|
+
pe as c,
|
|
469
|
+
fe as d,
|
|
470
|
+
W as e,
|
|
471
|
+
F as f,
|
|
472
|
+
he as g,
|
|
473
|
+
xt as h,
|
|
474
|
+
ue as i,
|
|
475
|
+
yt as j,
|
|
476
|
+
ce as k,
|
|
477
|
+
le as l,
|
|
478
|
+
ge as u
|
|
479
|
+
};
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { jsx as t, jsxs as m } from "react/jsx-runtime";
|
|
2
|
+
import { useState as l } from "react";
|
|
3
|
+
import p from "@mui/material/IconButton";
|
|
4
|
+
import f from "@mui/material/Stack";
|
|
5
|
+
import d from "@mui/material/Tooltip";
|
|
6
|
+
import { Text as a, Icon as h } from "@mxenabled/mxui";
|
|
7
|
+
import { makeAutoObservable as c } from "mobx";
|
|
8
|
+
import { addDays as u } from "date-fns/addDays";
|
|
9
|
+
import { differenceInDays as x } from "date-fns/differenceInDays";
|
|
10
|
+
import { endOfMonth as g } from "date-fns/endOfMonth";
|
|
11
|
+
import { isBefore as S } from "date-fns/isBefore";
|
|
12
|
+
import { startOfToday as s } from "date-fns/startOfToday";
|
|
13
|
+
const I = ({
|
|
14
|
+
body: o,
|
|
15
|
+
iconName: e = "info",
|
|
16
|
+
title: n
|
|
17
|
+
}) => {
|
|
18
|
+
const [i, r] = l(!1);
|
|
19
|
+
return /* @__PURE__ */ t(
|
|
20
|
+
d,
|
|
21
|
+
{
|
|
22
|
+
open: i,
|
|
23
|
+
title: /* @__PURE__ */ m(f, { gap: 2, p: 12, sx: { textOverflow: "none" }, children: [
|
|
24
|
+
/* @__PURE__ */ t(a, { bold: !0, variant: "body1", children: n }),
|
|
25
|
+
/* @__PURE__ */ t(a, { sx: { whiteSpace: "unset" }, variant: "body2", children: o })
|
|
26
|
+
] }),
|
|
27
|
+
children: /* @__PURE__ */ t(
|
|
28
|
+
p,
|
|
29
|
+
{
|
|
30
|
+
"aria-label": n,
|
|
31
|
+
onClick: () => r(!i),
|
|
32
|
+
onMouseEnter: () => r(!0),
|
|
33
|
+
onMouseLeave: () => r(!1),
|
|
34
|
+
sx: {
|
|
35
|
+
minHeight: 0,
|
|
36
|
+
minWidth: 0,
|
|
37
|
+
p: 0
|
|
38
|
+
},
|
|
39
|
+
children: /* @__PURE__ */ t(h, { name: e, sx: { color: "primary.main", fontSize: 16 } })
|
|
40
|
+
}
|
|
41
|
+
)
|
|
42
|
+
}
|
|
43
|
+
);
|
|
44
|
+
}, k = I;
|
|
45
|
+
class b {
|
|
46
|
+
// Cashflow is hard-coded to display 30 days starting from today
|
|
47
|
+
dateRange = { start: s(), end: u(s(), 30) };
|
|
48
|
+
isDirty = !1;
|
|
49
|
+
nextIncome = void 0;
|
|
50
|
+
upcomingExpenses = [];
|
|
51
|
+
selectedCashAccounts = [];
|
|
52
|
+
constructor() {
|
|
53
|
+
c(this);
|
|
54
|
+
}
|
|
55
|
+
// Returns the number of days until the next income activity or 0 if there is no income activity
|
|
56
|
+
get daysUntilNextIncome() {
|
|
57
|
+
return this.nextIncome ? Math.abs(x(s(), this.nextIncome.expectedDate)) : 0;
|
|
58
|
+
}
|
|
59
|
+
// Returns the expenses (Activities) until the next income activity or the end of the month
|
|
60
|
+
// if there is no income activity
|
|
61
|
+
get expensesTilNextIncome() {
|
|
62
|
+
return this.upcomingExpenses.filter(
|
|
63
|
+
(e) => S(e.expectedDate, this.nextIncome?.expectedDate || g(/* @__PURE__ */ new Date()))
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
setNextIncome = (e) => {
|
|
67
|
+
this.nextIncome = e;
|
|
68
|
+
};
|
|
69
|
+
setUpcomingExpenses = (e) => {
|
|
70
|
+
this.upcomingExpenses = e;
|
|
71
|
+
};
|
|
72
|
+
setSelectedCashAccounts = (e) => this.selectedCashAccounts = e;
|
|
73
|
+
}
|
|
74
|
+
class N {
|
|
75
|
+
globalStore;
|
|
76
|
+
uiStore;
|
|
77
|
+
constructor(e) {
|
|
78
|
+
this.globalStore = e, this.uiStore = new b(), c(this);
|
|
79
|
+
}
|
|
80
|
+
completeOnboarding = async () => {
|
|
81
|
+
const e = {
|
|
82
|
+
...this.globalStore.userStore.userProfile,
|
|
83
|
+
has_completed_cash_flow_onboarding: !0
|
|
84
|
+
};
|
|
85
|
+
await this.globalStore.userStore.updateUserProfile(e);
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
export {
|
|
89
|
+
N as C,
|
|
90
|
+
k as I
|
|
91
|
+
};
|