@mx-cartographer/experiences 9.0.0-alpha.mega1 → 9.0.0
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 +676 -9
- package/README.md +216 -47
- package/dist/{Account-CMjOp7S2.mjs → Account-BaJmiJAG.mjs} +4 -4
- package/dist/{Account-BIKn4XEZ.mjs → Account-BxHMlV9R.mjs} +1 -1
- package/dist/AccountDetailsHeader-DIysk_4w.mjs +95 -0
- package/dist/AccountFields-mwJ8NXsX.mjs +141 -0
- package/dist/AccountListItem-BDXHs4tV.mjs +94 -0
- package/dist/AccountUtils-T5_Odvos.mjs +27 -0
- package/dist/Accounts-CseLC3lL.mjs +5 -0
- package/dist/Analytics-CkYXKvco.mjs +53 -0
- package/dist/Analytics-CzGzz_sE.mjs +136 -0
- package/dist/ApiEndpoints-DXwIYNUV.mjs +49 -0
- package/dist/BudgetUtil-Bg2AQJpQ.mjs +74 -0
- package/dist/{Category-Ccoew_sA.mjs → Category-DEKZGLYe.mjs} +3 -3
- package/dist/{CategorySelectorDrawer-C4aZYP4N.mjs → CategorySelectorDrawer-CmaDLhnf.mjs} +131 -119
- package/dist/Connect-Dk6GZEsA.mjs +39 -0
- package/dist/ConnectCard-CCep7Zqe.mjs +54 -0
- package/dist/ConnectDrawer-Cnjr3Ddg.mjs +58 -0
- package/dist/{ConnectionsDrawer-BExzgE16.mjs → ConnectionsDrawer-CtfPXk0M.mjs} +13 -12
- package/dist/CurrencyDialog-DumQCTPO.mjs +373 -0
- package/dist/CurrencyInput-adTIRtL3.mjs +87 -0
- package/dist/{CurrencyText-C-85TnUF.mjs → CurrencyText-CCbE6MmF.mjs} +1 -1
- package/dist/DateFormats-HudZ3Bjs.mjs +64 -0
- package/dist/DateUtil-Bhq59ZVg.mjs +58 -0
- package/dist/DebtUtils-DD3186U-.mjs +153 -0
- package/dist/Dialog-CwWc0AbH.mjs +63 -0
- package/dist/Donut-SzzfZDHF.mjs +88 -0
- package/dist/{Drawer-Bet2ZPJo.mjs → Drawer-BXqqBMxg.mjs} +32 -34
- package/dist/EmbeddedCard-DPwJjqMH.mjs +856 -0
- package/dist/{EmptyState-DoxNUae-.mjs → EmptyState-CJUDc3kD.mjs} +21 -22
- package/dist/Error-Dogaw2jO.mjs +84 -0
- package/dist/ErrorBoundary-CsdOcnJ9.mjs +23 -0
- package/dist/{ExportCsvAction-oG_Mn66T.mjs → ExportCsvAction-Bw02ZJEj.mjs} +6 -6
- package/dist/GlobalAccountFilter-7Cg2-9A5.mjs +237 -0
- package/dist/GlobalCopyApi-wcnDUzMV.mjs +128 -0
- package/dist/GoalsUtil-C9EnLWvC.mjs +107 -0
- package/dist/HeaderCell-P8w6CmfO.mjs +6 -0
- package/dist/{Help-c-zHlDbv.mjs → Help-CkQTjORd.mjs} +6 -27
- package/dist/{Help-BW_ar-4B.mjs → Help-DJ8PrVHX.mjs} +594 -562
- package/dist/InformationTooltip-4su8bn1e.mjs +41 -0
- package/dist/{InvestmentUtil-jOyOgzIB.mjs → InvestmentUtil-BItV7uEs.mjs} +17 -17
- package/dist/LineChart-CejWS_rh.mjs +612 -0
- package/dist/{ListItemAction-Cbr3417C.mjs → ListItemAction-CwspSmQi.mjs} +26 -26
- package/dist/ListItemRow-kH1rn8Xu.mjs +67 -0
- package/dist/ListItemWrapper-B5r-YQQ_.mjs +42 -0
- package/dist/Loader-CxeBwuPG.mjs +21 -0
- package/dist/Localization-DnoVyBNK.mjs +38 -0
- package/dist/ManageIncome-B1JfqslT.mjs +595 -0
- package/dist/{MicroWidgetContainer-DSyYwRCU.mjs → MicroWidgetContainer-CfKdQfhi.mjs} +2 -2
- package/dist/MiniWidgetContainer-BdPiUU-u.mjs +66 -0
- package/dist/NetWorthUtils-DilGN1nW.mjs +95 -0
- package/dist/Notification-DTNYSd8P.mjs +7 -0
- package/dist/{NotificationSettings-e789PcRb.mjs → NotificationSettings-6p-h5phZ.mjs} +143 -142
- package/dist/NotificationUtils-BRGFTePr.mjs +23 -0
- package/dist/{NumberFormatting-DjTD0t3W.mjs → NumberFormatting--XMeeBfr.mjs} +2 -1
- package/dist/OriginalBalanceAction-CkJPnp2c.mjs +114 -0
- package/dist/{RecurringSettings-BpCUcE8w.mjs → RecurringSettings-cm6MK_aS.mjs} +4 -4
- package/dist/RecurringTransactionsUtil-B3rLEx_g.mjs +253 -0
- package/dist/{ResponsiveButton-C6KH8JH4.mjs → ResponsiveButton-CC9F_Ezk.mjs} +4 -4
- package/dist/SearchBox-Cpgu_gdO.mjs +50 -0
- package/dist/Select-BFt-HD-L.mjs +55 -0
- package/dist/SelectionBox-B4xELRgp.mjs +48 -0
- package/dist/{SingleSegmentDonut-PsRQPkmV.mjs → SingleSegmentDonut-7Uy6VEld.mjs} +1 -1
- package/dist/Sizes-DISGrlUg.mjs +6 -0
- package/dist/{SpendingData-B7NuTQ9s.mjs → SpendingData-PKlh8caU.mjs} +6 -6
- package/dist/SpendingLegend-5Ct_FZ8o.mjs +193 -0
- package/dist/ToggleListItem-Dl1lXNwj.mjs +91 -0
- package/dist/TransactionDetails-C3dlAzYf.mjs +1714 -0
- package/dist/TransactionUtils-BphBJBbU.mjs +234 -0
- package/dist/TrendsUtil-D9z3kIj_.mjs +69 -0
- package/dist/UserStore-CRpKQjpP.mjs +3002 -0
- package/dist/ViewMoreMicroCard-BD_MNc2z.mjs +1295 -0
- package/dist/WidgetContainer-DNuz_s7W.mjs +479 -0
- package/dist/accounts/AccountsMiniWidget.d.ts +1 -1
- package/dist/accounts/AccountsWidget.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/hooks/useUiStore.d.ts +6 -1
- package/dist/accounts/index.d.ts +0 -2
- package/dist/accounts/index.es.js +628 -527
- package/dist/accounts/utils/AccountDetails.d.ts +1 -1
- package/dist/accounts/utils/AccountFields.d.ts +3 -3
- 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/components/BubbleChart.d.ts +1 -1
- package/dist/budgets/components/BudgetDetailsDrawerV2.d.ts +11 -0
- 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.d.ts +2 -1
- package/dist/budgets/index.es.js +989 -813
- package/dist/budgets/utils/BubblesSVG.d.ts +3 -3
- package/dist/cashflow/CashflowMiniWidget.d.ts +1 -1
- package/dist/cashflow/CashflowWidget.d.ts +1 -1
- package/dist/cashflow/components/DetailsExpenseRow.d.ts +1 -1
- package/dist/cashflow/context/hooks.d.ts +15 -1
- package/dist/cashflow/index.d.ts +0 -2
- package/dist/cashflow/index.es.js +461 -490
- 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/context/hooks.d.ts +19 -1
- package/dist/categories/index.d.ts +0 -1
- package/dist/categories/index.es.js +4 -6
- package/dist/common/components/CurrencyDialog.d.ts +19 -0
- package/dist/common/components/CurrencyInput.d.ts +1 -1
- package/dist/common/components/EmptyState.d.ts +0 -1
- package/dist/common/components/Error.d.ts +13 -0
- package/dist/common/components/GlobalAccountFilter.d.ts +3 -2
- package/dist/common/components/Loader.d.ts +1 -2
- package/dist/common/components/MiniWidgetContainer.d.ts +1 -0
- package/dist/common/components/TinyBarChart.d.ts +10 -0
- package/dist/common/components/WidgetContainer.d.ts +4 -3
- package/dist/common/components/WidgetDateRangeSelector.d.ts +12 -0
- 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/charts/stackedlinechart/CustomAreaTooltip.d.ts +1 -1
- package/dist/common/components/daterangeselector/DateRangeSelector.d.ts +1 -0
- package/dist/common/components/globalaccountfilter/GlobalAccountFilterList.d.ts +1 -1
- package/dist/common/components/index.d.ts +2 -1
- package/dist/common/constants/Account.d.ts +1 -1
- package/dist/common/constants/Analytics.d.ts +12 -0
- 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 -6
- package/dist/common/context/GlobalDataProvider.d.ts +2 -1
- package/dist/common/context/hooks.d.ts +24 -24
- package/dist/common/hooks/index.d.ts +2 -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/hooks/useWidgetHeaderStyles.d.ts +34 -0
- package/dist/common/index.d.ts +3 -3
- package/dist/common/index.es.js +254 -1348
- package/dist/common/utils/AccountDisplayName.d.ts +1 -1
- package/dist/common/utils/AccountFilter.d.ts +2 -2
- package/dist/common/utils/Analytics.d.ts +1 -1
- package/dist/common/utils/PostMessage.d.ts +1 -0
- package/dist/common/utils/Theme.d.ts +7 -6
- package/dist/common/utils/index.d.ts +1 -6
- package/dist/{accounts → core}/api/AccountApi.d.ts +2 -2
- package/dist/{common → core}/api/AnalyticsApi.d.ts +1 -1
- package/dist/{common → core}/api/AppDataApi.d.ts +2 -2
- package/dist/{common → core}/api/BannerApi.d.ts +1 -1
- package/dist/{common → core}/api/BeatApi.d.ts +2 -2
- package/dist/{budgets → core}/api/BudgetsApi.d.ts +5 -1
- package/dist/{common → core}/api/CategoryApi.d.ts +2 -2
- package/dist/{finstrong → core}/api/FinstrongApi.d.ts +2 -2
- package/dist/{common → core}/api/GlobalCopyApi.d.ts +2 -2
- package/dist/{goals → core}/api/GoalApi.d.ts +2 -2
- package/dist/{help → core}/api/HelpApi.d.ts +2 -2
- package/dist/{investments → core}/api/HoldingApi.d.ts +2 -2
- package/dist/{merchants → core}/api/MerchantApi.d.ts +2 -2
- package/dist/{common → core}/api/NotificationApi.d.ts +2 -2
- package/dist/{recurringtransactions → core}/api/RepeatingTransactionsApi.d.ts +2 -1
- package/dist/{common → core}/api/ScheduledPaymentsApi.d.ts +2 -2
- package/dist/{settings → core}/api/SettingsApi.d.ts +2 -3
- package/dist/{transactions → core}/api/TransactionApi.d.ts +2 -2
- package/dist/{common → core}/api/UserApi.d.ts +2 -2
- package/dist/{common → core}/api/WidgetApi.d.ts +1 -1
- package/dist/core/api/index.d.ts +20 -0
- package/dist/{common → core}/constants/ApiEndpoints.d.ts +1 -2
- package/dist/{common → core}/constants/DefaultConfig.d.ts +1 -1
- package/dist/core/constants/Transaction.d.ts +10 -0
- package/dist/core/constants/index.d.ts +4 -0
- package/dist/core/constants/repeatingTransactions.d.ts +10 -0
- package/dist/core/index.d.ts +4 -0
- package/dist/core/index.es.js +108 -0
- package/dist/{accounts → core}/stores/AccountStore.d.ts +15 -3
- package/dist/{analytics → core}/stores/AnalyticsStore.d.ts +1 -1
- package/dist/{common → core}/stores/AppDataStore.d.ts +1 -2
- package/dist/{insights/store → core/stores}/BeatStore.d.ts +3 -3
- package/dist/{budgets/store → core/stores}/BudgetsStore.d.ts +15 -2
- package/dist/{cashflow/stores/UiStore.d.ts → core/stores/CashflowStore.d.ts} +10 -2
- package/dist/{categories → core}/stores/CategoryStore.d.ts +24 -2
- package/dist/{common → core}/stores/ConnectStore.d.ts +1 -1
- package/dist/core/stores/DebtsStore.d.ts +22 -0
- package/dist/{finstrong → core}/stores/FinstrongStore.d.ts +5 -4
- package/dist/{common → core}/stores/GlobalStore.d.ts +4 -25
- package/dist/{goals → core}/stores/GoalStore.d.ts +3 -2
- package/dist/{help/store → core/stores}/HelpStore.d.ts +4 -5
- package/dist/{investments → core}/stores/HoldingStore.d.ts +4 -3
- package/dist/{merchants → core}/stores/MerchantStore.d.ts +3 -2
- package/dist/{networth → core}/stores/NetWorthStore.d.ts +3 -3
- package/dist/{notifications → core}/stores/NotificationStore.d.ts +3 -1
- package/dist/{recurringtransactions → core}/stores/RecurringTransactionsStore.d.ts +3 -2
- package/dist/{settings → core}/stores/SettingsStore.d.ts +4 -4
- package/dist/{transactions → core}/stores/TransactionStore.d.ts +30 -4
- package/dist/{trends → core}/stores/TrendsStore.d.ts +11 -4
- package/dist/core/stores/index.d.ts +24 -0
- package/dist/{common → core}/types/Analytics.d.ts +6 -3
- package/dist/{common → core}/types/AppData.d.ts +8 -2
- 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/Client.d.ts +1 -0
- package/dist/{common → core}/types/Expense.d.ts +2 -1
- package/dist/{common → core}/types/Finstrong.d.ts +0 -2
- package/dist/{networth → core}/types/NetWorth.d.ts +1 -10
- package/dist/{common → core}/types/Notification.d.ts +15 -5
- package/dist/core/types/Offer.d.ts +32 -0
- package/dist/{common → core}/types/Widgets.d.ts +1 -0
- package/dist/{common → core}/types/index.d.ts +4 -3
- package/dist/{common → core}/types/localization/BudgetsCopy.d.ts +26 -0
- package/dist/{common → core}/types/localization/CashflowCopy.d.ts +1 -0
- package/dist/{common → core}/types/localization/CommonCopy.d.ts +3 -0
- package/dist/{common → core}/types/localization/DebtsCopy.d.ts +5 -0
- package/dist/{common → core}/types/localization/GoalsCopy.d.ts +0 -1
- package/dist/{common → core}/types/localization/InsightsFeedCopy.d.ts +11 -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/{common → core}/types/localization/TransactionsCopy.d.ts +11 -6
- package/dist/{common → core}/types/localization/TrendsCopy.d.ts +2 -0
- package/dist/{accounts/utils/Accounts.d.ts → core/utils/AccountUtils.d.ts} +2 -2
- package/dist/{microinsights/utils/beatUtils.d.ts → core/utils/BeatUtils.d.ts} +1 -1
- package/dist/{budgets → core}/utils/BudgetUtil.d.ts +7 -2
- package/dist/{categories/util → core/utils}/CategoryUtil.d.ts +6 -1
- package/dist/core/utils/DebtUtils.d.ts +31 -0
- package/dist/core/utils/FinstrongUtils.d.ts +7 -0
- package/dist/{goals/util → core/utils}/GoalsUtil.d.ts +1 -1
- package/dist/core/utils/HelpUtil.d.ts +3 -0
- package/dist/{investments/util → core/utils}/InvestmentUtil.d.ts +2 -2
- package/dist/{common → core}/utils/Localization.d.ts +9 -1
- package/dist/{networth → core}/utils/NetWorthUtils.d.ts +1 -2
- package/dist/{notifications → core}/utils/NotificationUtils.d.ts +2 -1
- package/dist/{common → core}/utils/NumberFormatting.d.ts +1 -1
- package/dist/{recurringtransactions/util/RecurringTransactions.d.ts → core/utils/RecurringTransactionsUtil.d.ts} +2 -2
- package/dist/{settings/util/Notifications.d.ts → core/utils/SettingsUtil.d.ts} +1 -1
- package/dist/{transactions/utils/buildDetailedTransactions.d.ts → core/utils/TransactionUtils.d.ts} +12 -2
- package/dist/{trends/utils/TrendsData.d.ts → core/utils/TrendsUtil.d.ts} +1 -1
- package/dist/core/utils/index.d.ts +2 -0
- package/dist/dashboard/index.es.js +39 -38
- package/dist/debts/DebtsWidget.d.ts +1 -1
- package/dist/debts/components/DebtsChart.d.ts +1 -1
- package/dist/debts/components/DebtsTable.d.ts +1 -1
- package/dist/debts/components/SnowballCard.d.ts +1 -1
- package/dist/debts/components/actions/DebtsPriorityAction.d.ts +6 -1
- package/dist/debts/components/actions/InterestRateAction.d.ts +1 -1
- package/dist/debts/components/actions/MonthlyPaymentAction.d.ts +1 -1
- package/dist/debts/components/actions/OriginalBalanceAction.d.ts +1 -1
- package/dist/debts/components/debtspaydown/PaydownButton.d.ts +2 -1
- package/dist/debts/components/debtspriority/DebtsPriorityButton.d.ts +3 -1
- package/dist/debts/hooks/useDebtsUiStore.d.ts +1 -1
- package/dist/debts/index.d.ts +0 -1
- package/dist/debts/index.es.js +715 -775
- package/dist/debts/utils/DebtsTable.d.ts +1 -1
- package/dist/debts/utils/SnowballCard.d.ts +2 -2
- package/dist/finstrong/FinstrongWidget.d.ts +2 -2
- 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.d.ts +0 -2
- package/dist/finstrong/index.es.js +1587 -1349
- package/dist/finstrong/util/finstrongUtils.d.ts +3 -9
- package/dist/goals/GoalsWidget.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 +2 -2
- package/dist/goals/components/managegoals/CompleteListItem.d.ts +1 -1
- package/dist/goals/components/managegoals/OngoingListItem.d.ts +3 -2
- package/dist/goals/components/managegoals/ReorderGoals.d.ts +1 -1
- package/dist/goals/components/micro/GoalMicroStatusCard.d.ts +1 -1
- package/dist/goals/index.d.ts +0 -2
- package/dist/goals/index.es.js +707 -787
- package/dist/help/HelpWidget.d.ts +2 -2
- 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 +19 -10
- package/dist/help/utils/index.d.ts +0 -1
- package/dist/{hooks-fY_n74f7.mjs → hooks-BaO_gOI6.mjs} +23 -23
- package/dist/insights/components/feed/Header.d.ts +8 -0
- package/dist/insights/components/index.d.ts +53 -0
- package/dist/insights/components/insights/AccountDiscoverability/AccountDiscoverability.d.ts +3 -0
- package/dist/insights/components/insights/AccountDiscoverability/index.d.ts +1 -0
- package/dist/insights/components/insights/AccountDiscoverability/types/AccountDiscoverability.d.ts +3 -0
- package/dist/insights/components/insights/AmericanUpcomingTaxDeadlineAlert/AmericanUpcomingTaxDeadlineAlert.d.ts +2 -0
- package/dist/insights/components/insights/AmericanUpcomingTaxDeadlineAlert/index.d.ts +1 -0
- package/dist/insights/components/insights/AmericanUpcomingTaxDeadlineAlert/types/AmericanUpcomingTaxDeadlineProps.d.ts +4 -0
- package/dist/insights/components/insights/BillAmountNotStandard/BillAmountNotStandard.d.ts +3 -0
- package/dist/insights/components/insights/BillAmountNotStandard/BillAmountNotStandardMUI.d.ts +3 -0
- package/dist/insights/components/insights/BillAmountNotStandard/index.d.ts +2 -0
- package/dist/insights/components/insights/BillAmountNotStandard/types/BillAmountNotStandard.d.ts +4 -0
- package/dist/insights/components/insights/CashBack/CashBack.d.ts +3 -0
- package/dist/insights/components/insights/CashBack/index.d.ts +1 -0
- package/dist/insights/components/insights/CashBack/types/CashBack.d.ts +7 -0
- package/dist/insights/components/insights/CategoryBudget/CategoryBudget.d.ts +3 -0
- package/dist/insights/components/insights/CategoryBudget/index.d.ts +1 -0
- package/dist/insights/components/insights/CategoryBudget/types/CategoryBudget.d.ts +10 -0
- package/dist/insights/components/insights/CategorySpendingV2/CategorySpendingV2.d.ts +2 -0
- package/dist/insights/components/insights/CategorySpendingV2/CategorySpendingV2MUI.d.ts +2 -0
- package/dist/insights/components/insights/CategorySpendingV2/index.d.ts +2 -0
- package/dist/insights/components/insights/CategorySpendingV2/types/CategorySpendingV2.d.ts +7 -0
- package/dist/insights/components/insights/CelebrateCreditCardPayoff/CelebrateCreditCardPayoff.d.ts +3 -0
- package/dist/insights/components/insights/CelebrateCreditCardPayoff/index.d.ts +1 -0
- package/dist/insights/components/insights/CelebrateCreditCardPayoff/types/CelebrateCreditCardPayoffProps.d.ts +9 -0
- package/dist/insights/components/insights/CustomTransaction/CustomTransaction.d.ts +3 -0
- package/dist/insights/components/insights/CustomTransaction/index.d.ts +1 -0
- package/dist/insights/components/insights/DiscoveredAccounts/DiscoveredAccountsBody.d.ts +9 -0
- package/dist/insights/components/insights/DiscoveredAccounts/DiscoveredAccountsLearnMoreDrawerContent.d.ts +21 -0
- package/dist/insights/components/insights/DiscoveredAccounts/DiscoveredAccountsMiniInsight.d.ts +6 -0
- package/dist/insights/components/insights/DiscoveredAccounts/index.d.ts +3 -0
- package/dist/insights/components/insights/FederalBankHoliday/FederalBankHoliday.d.ts +3 -0
- package/dist/insights/components/insights/FederalBankHoliday/FederalBankHolidayMUI.d.ts +3 -0
- package/dist/insights/components/insights/FederalBankHoliday/index.d.ts +2 -0
- package/dist/insights/components/insights/FederalBankHoliday/types/FederalBankHoliday.d.ts +4 -0
- package/dist/insights/components/insights/MarketingHub/Offer.d.ts +3 -0
- package/dist/insights/components/insights/MarketingHub/Types.d.ts +33 -0
- package/dist/insights/components/insights/MarketingHub/index.d.ts +2 -0
- package/dist/insights/components/insights/MonthlyDebtToIncomeComparisonV2/MonthlyDebtToIncomeComparisonV2.d.ts +2 -0
- package/dist/insights/components/insights/MonthlyDebtToIncomeComparisonV2/index.d.ts +1 -0
- package/dist/insights/components/insights/MonthlyDebtToIncomeComparisonV2/types/index.d.ts +4 -0
- package/dist/insights/components/insights/MonthlyEmergencyFundReview/LastMonthsContributionSection.d.ts +6 -0
- package/dist/insights/components/insights/MonthlyEmergencyFundReview/MonthlyEmergencyFundReviewBody.d.ts +21 -0
- package/dist/insights/components/insights/MonthlyEmergencyFundReview/ProjectedCompletionSection.d.ts +6 -0
- package/dist/insights/components/insights/MonthlyEmergencyFundReview/TotalSection.d.ts +7 -0
- package/dist/insights/components/insights/MonthlyEmergencyFundReview/index.d.ts +4 -0
- package/dist/insights/components/insights/MonthlySavingsToIncomeComparison/MonthlySavingsToIncomeComparison.d.ts +2 -0
- package/dist/insights/components/insights/MonthlySavingsToIncomeComparison/index.d.ts +1 -0
- package/dist/insights/components/insights/MonthlySavingsToIncomeComparison/types/index.d.ts +4 -0
- package/dist/insights/components/insights/MonthlySpendToIncomeComparisonV2/MonthlySpendToIncomeComparisonV2.d.ts +2 -0
- package/dist/insights/components/insights/MonthlySpendToIncomeComparisonV2/index.d.ts +1 -0
- package/dist/insights/components/insights/MonthlySpendToIncomeComparisonV2/types/index.d.ts +4 -0
- package/dist/insights/components/insights/MonthlySpendingComparisonV2/MonthlySpendingComparisonV2.d.ts +3 -0
- package/dist/insights/components/insights/MonthlySpendingComparisonV2/__test__/MonthlySpendComparisonV2.test.d.ts +1 -0
- package/dist/insights/components/insights/MonthlySpendingComparisonV2/index.d.ts +1 -0
- package/dist/insights/components/insights/MonthlySpendingComparisonV2/types/MonthlySpendComparisonV2.d.ts +4 -0
- package/dist/insights/components/insights/P2pCategorization/P2pCategorization.d.ts +3 -0
- package/dist/insights/components/insights/P2pCategorization/_tests_/P2pCategorizationMultipleTransaction.test.d.ts +0 -0
- package/dist/insights/components/insights/P2pCategorization/_tests_/P2pCategorizationSingleTransaction.test.d.ts +0 -0
- package/dist/insights/components/insights/P2pCategorization/index.d.ts +4 -0
- package/dist/insights/components/insights/P2pCategorization/shared/P2pCategorizationMultipleTransactions.d.ts +3 -0
- package/dist/insights/components/insights/P2pCategorization/shared/P2pCategorizationSingleTransaction.d.ts +3 -0
- package/dist/insights/components/insights/P2pCategorization/types/P2pCategorization.d.ts +17 -0
- package/dist/insights/components/insights/SavingsAccountBalancesSummary/SavingsAccountBalancesSummary.d.ts +2 -0
- package/dist/insights/components/insights/SavingsAccountBalancesSummary/index.d.ts +1 -0
- package/dist/insights/components/insights/SavingsAccountBalancesSummary/types/SavingsAccountBalancesSummary.d.ts +4 -0
- package/dist/insights/components/insights/SetUpDirectDeposit/SetUpDirectDepositBody.d.ts +3 -0
- package/dist/insights/components/insights/SetUpDirectDeposit/index.d.ts +1 -0
- package/dist/insights/components/insights/SharedDeposit/SharedDeposit.d.ts +2 -0
- package/dist/insights/components/insights/SharedDeposit/index.d.ts +1 -0
- package/dist/insights/components/insights/SharedDeposit/types/index.d.ts +7 -0
- package/dist/insights/components/insights/SwitchDirectDeposit/AccountBox.d.ts +7 -0
- package/dist/insights/components/insights/SwitchDirectDeposit/SwitchDirectDepositBody.d.ts +10 -0
- package/dist/insights/components/insights/SwitchDirectDeposit/SwitchDirectDepositMainContainer.d.ts +9 -0
- package/dist/insights/components/insights/SwitchDirectDeposit/index.d.ts +3 -0
- package/dist/insights/components/insights/UnifiedDeposit/UnifiedDeposit.d.ts +7 -0
- package/dist/insights/components/insights/UnifiedDeposit/UnifiedDepositBody.d.ts +11 -0
- package/dist/insights/components/insights/UnifiedDeposit/index.d.ts +1 -0
- package/dist/insights/components/insights/UserFeedback/StyledToggleButton.d.ts +7 -0
- package/dist/insights/components/insights/UserFeedback/Types.d.ts +27 -0
- package/dist/insights/components/insights/UserFeedback/UserFeedback.d.ts +3 -0
- package/dist/insights/components/insights/UserFeedback/index.d.ts +1 -0
- package/dist/insights/components/insights/WeeklyNoSpendDays/BubbleWeek.d.ts +9 -0
- package/dist/insights/components/insights/WeeklyNoSpendDays/NoSpendIcons.d.ts +1 -0
- package/dist/insights/components/insights/WeeklyNoSpendDays/WeeklyNoSpendDays.d.ts +12 -0
- package/dist/insights/components/insights/WeeklyNoSpendDays/_tests_/WeeklyNoSpendDays.test.d.ts +0 -0
- package/dist/insights/components/insights/WeeklyNoSpendDays/index.d.ts +1 -0
- package/dist/insights/components/insights/index.d.ts +25 -0
- package/dist/insights/components/shared/AccountBalanceCard.d.ts +13 -0
- package/dist/insights/components/shared/BottomSheet.d.ts +13 -0
- package/dist/insights/components/shared/CarouselControls.d.ts +14 -0
- package/dist/insights/components/shared/ChartDrawerTemplate/ChartDrawerTemplate.d.ts +30 -0
- package/dist/insights/components/shared/ChartDrawerTemplate/TipSection.d.ts +9 -0
- package/dist/insights/components/shared/ChartTransactionWithDrillDown.d.ts +22 -0
- package/dist/insights/components/shared/Charts/BarChart/BarChart.d.ts +2 -0
- package/dist/insights/components/shared/Charts/BarChart/BarChartV2.d.ts +2 -0
- package/dist/insights/components/shared/Charts/BarChart/ChartLegend.d.ts +9 -0
- package/dist/insights/components/shared/Charts/BarChart/ChartLegendV2.d.ts +10 -0
- package/dist/insights/components/shared/Charts/BarChart/CustomBarPlot.d.ts +18 -0
- package/dist/insights/components/shared/Charts/BarChart/CustomBarPlotV2.d.ts +18 -0
- package/dist/insights/components/shared/Charts/BarChart/CustomDoubleBarPlot.d.ts +18 -0
- package/dist/insights/components/shared/Charts/BarChart/CustomDoubleBarPlotMXUI.d.ts +18 -0
- package/dist/insights/components/shared/Charts/BarChart/DoubleBarChart.d.ts +2 -0
- package/dist/insights/components/shared/Charts/BarChart/DoubleBarChartLegend.d.ts +10 -0
- package/dist/insights/components/shared/Charts/BarChart/DoubleBarChartLegendMXUI.d.ts +10 -0
- package/dist/insights/components/shared/Charts/BarChart/DoubleBarChartMXUI.d.ts +2 -0
- package/dist/insights/components/shared/Charts/BarChart/index.d.ts +4 -0
- package/dist/insights/components/shared/Charts/EmptyBarChart.d.ts +1 -0
- package/dist/insights/components/shared/Charts/index.d.ts +2 -0
- package/dist/insights/components/shared/Confetti.d.ts +5 -0
- package/dist/insights/components/shared/ConnectionCard.d.ts +14 -0
- package/dist/insights/components/shared/ConnectionDetailDrillDown.d.ts +25 -0
- package/dist/insights/components/shared/Coupon.d.ts +8 -0
- package/dist/insights/components/shared/DeepLinks/DeepLinkDialog.d.ts +11 -0
- package/dist/insights/components/shared/DeepLinks/DirectDeposit/Circle.d.ts +6 -0
- package/dist/insights/components/shared/DeepLinks/DirectDeposit/DirectDepositDeepLink.d.ts +24 -0
- package/dist/insights/components/shared/DeepLinks/DirectDeposit/Dot.d.ts +1 -0
- package/dist/insights/components/shared/DeepLinks/DirectDeposit/Oval.d.ts +1 -0
- package/dist/insights/components/shared/DirectDeposit/DirectDeposit.d.ts +3 -0
- package/dist/insights/components/shared/DirectDeposit/DirectDepositSubHeader.d.ts +14 -0
- package/dist/insights/components/shared/DirectDeposit/FullFeedBodyHeader.d.ts +10 -0
- package/dist/insights/components/shared/DirectDeposit/LeftBox.d.ts +7 -0
- package/dist/insights/components/shared/DirectDeposit/MiniBodyHeader.d.ts +10 -0
- package/dist/insights/components/shared/DirectDeposit/RightBox.d.ts +8 -0
- package/dist/insights/components/shared/DiscoveredAccountsConnect.d.ts +8 -0
- package/dist/insights/components/shared/DonutChartV2.d.ts +13 -0
- package/dist/insights/components/shared/DrillDownCalculation/BalanceStepper.d.ts +12 -0
- package/dist/insights/components/shared/DrillDownCalculation/DrillDownCalculation.d.ts +31 -0
- package/dist/insights/components/shared/ErrorCard/ErrorCard.d.ts +8 -0
- package/dist/insights/components/shared/GenericFeedback/FeedbackButtons.d.ts +15 -0
- package/dist/insights/components/shared/GenericFeedback/FeedbackDescription.d.ts +5 -0
- package/dist/insights/components/shared/GenericFeedback/FeedbackHeader.d.ts +15 -0
- package/dist/insights/components/shared/GenericFeedback/FeedbackOptions.d.ts +12 -0
- package/dist/insights/components/shared/GenericFeedback/FeedbackText.d.ts +13 -0
- package/dist/insights/components/shared/GoalProgress.d.ts +10 -0
- package/dist/insights/components/shared/GradientBox.d.ts +8 -0
- package/dist/insights/components/shared/InsightsCard/BeatCard.d.ts +20 -0
- package/dist/insights/components/shared/InsightsCard/BeatCardMUI.d.ts +20 -0
- package/dist/insights/components/shared/InsightsCard/CardButtonSection.d.ts +7 -0
- package/dist/insights/components/shared/InsightsCard/CardError.d.ts +5 -0
- package/dist/insights/components/shared/InsightsCard/CardFooter.d.ts +7 -0
- package/dist/insights/components/shared/InsightsCard/CardHeader.d.ts +11 -0
- package/dist/insights/components/shared/InsightsCard/CardHeaderMUI.d.ts +11 -0
- package/dist/insights/components/shared/InsightsCard/CardLoading.d.ts +5 -0
- package/dist/insights/components/shared/InsightsCard/ClientConfigurableCta.d.ts +5 -0
- package/dist/insights/components/shared/InsightsCard/ContentAndDescription.d.ts +15 -0
- package/dist/insights/components/shared/InsightsCard/ContentAndDescriptionMUI.d.ts +15 -0
- package/dist/insights/components/shared/InsightsCard/Description.d.ts +10 -0
- package/dist/insights/components/shared/InsightsCard/DescriptionMUI.d.ts +10 -0
- package/dist/insights/components/shared/InsightsCard/EmbeddedCard.d.ts +9 -0
- package/dist/insights/components/shared/InsightsCard/FeedbackCard.d.ts +13 -0
- package/dist/insights/components/shared/InsightsCard/InsightButton.d.ts +12 -0
- package/dist/insights/components/shared/InsightsCard/MiniDescription.d.ts +9 -0
- package/dist/insights/components/shared/InsightsCard/MiniDescriptionMUI.d.ts +9 -0
- package/dist/insights/components/shared/MenuAction.d.ts +15 -0
- package/dist/insights/components/shared/MiniInsightCard.d.ts +16 -0
- package/dist/insights/components/shared/P2P/P2PMultipleCategorization.d.ts +12 -0
- package/dist/insights/components/shared/P2PCategorizationSingleAccount/P2PCategorizationSingleAccount.d.ts +10 -0
- package/dist/insights/components/shared/ProgressBar.d.ts +9 -0
- package/dist/insights/components/shared/SaveAnExtra100/SaveAnExtra100.d.ts +9 -0
- package/dist/insights/components/shared/SaveEnoughToLiveOnBottomSection.d.ts +11 -0
- package/dist/insights/components/shared/SaveEnoughToLiveOnTopSection.d.ts +2 -0
- package/dist/insights/components/shared/StatusIndicator.d.ts +15 -0
- package/dist/insights/components/shared/TabContainer.d.ts +8 -0
- package/dist/insights/components/shared/ThemedSVGImage.d.ts +2 -0
- package/dist/insights/components/shared/TransactionCard.d.ts +14 -0
- package/dist/insights/components/shared/ZeroState/LinedCardZeroState.d.ts +1 -0
- package/dist/insights/components/shared/index.d.ts +2 -0
- package/dist/insights/hooks/useContainerDimensions.d.ts +5 -0
- package/dist/insights/index.d.ts +1 -1
- package/dist/insights/index.es.js +4843 -2
- package/dist/insights/themes/Typography.d.ts +1 -0
- package/dist/insights/themes/index.d.ts +1 -0
- package/dist/insights/types/Charts/BarChart.d.ts +96 -0
- package/dist/insights/types/CommonBeat.d.ts +367 -0
- package/dist/insights/types/DirectDeposit.d.ts +16 -0
- package/dist/insights/types/ThemedSVGImage.d.ts +5 -0
- package/dist/investments/InvestmentsWidget.d.ts +2 -2
- package/dist/investments/components/AnalysisDetails.d.ts +1 -1
- package/dist/investments/components/allocation/util/createInvestementsAllocationData.d.ts +2 -2
- package/dist/investments/index.es.js +574 -574
- package/dist/merchants/index.d.ts +0 -1
- package/dist/merchants/index.es.js +18 -20
- package/dist/microinsights/InsightsMicroWidget.d.ts +1 -14
- package/dist/microinsights/MicroCardTemplate.d.ts +2 -4
- 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 +3 -3
- package/dist/microinsights/cards/NoRelevantInsightsCard.d.ts +3 -3
- package/dist/microinsights/cards/ViewMoreMicroCard.d.ts +3 -3
- package/dist/microinsights/cards/ZeroStateCard.d.ts +3 -3
- package/dist/microinsights/carousel/BeatList.d.ts +3 -3
- package/dist/microinsights/carousel/CarouselHeader.d.ts +4 -2
- package/dist/microinsights/carousel/MicroBeatCarousel.d.ts +12 -12
- 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.d.ts +1 -1
- package/dist/microinsights/index.es.js +1 -1
- package/dist/microinsights/interfaces.d.ts +23 -40
- package/dist/microinsights/stores/CopyStore.d.ts +2 -2
- package/dist/microinsights/stores/InsightsMicroWidgetStore.d.ts +2 -2
- 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/AssetsLiabilitiesDetail.d.ts +1 -1
- package/dist/networth/components/GainsLossesDetail.d.ts +1 -1
- package/dist/networth/components/NetWorthChange.d.ts +1 -1
- package/dist/networth/components/NetWorthListItem.d.ts +1 -1
- package/dist/networth/components/NetWorthSummary.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.d.ts +0 -4
- package/dist/networth/index.es.js +302 -314
- 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.d.ts +0 -2
- package/dist/notifications/index.es.js +101 -93
- package/dist/recurringtransactions/RecurringTransactionsMiniWidget.d.ts +1 -1
- package/dist/recurringtransactions/RecurringTransactionsWidget.d.ts +2 -2
- 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.d.ts +0 -1
- package/dist/recurringtransactions/index.es.js +489 -462
- package/dist/settings/NotificationSettingsWidget.d.ts +1 -1
- package/dist/settings/SettingsWidget.d.ts +2 -2
- package/dist/settings/TransactionRulesWidget.d.ts +1 -1
- 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.d.ts +0 -2
- package/dist/settings/index.es.js +419 -430
- package/dist/spending/SpendingMiniWidget.d.ts +1 -1
- package/dist/spending/SpendingWidget.d.ts +1 -1
- package/dist/spending/index.es.js +229 -222
- package/dist/spending/utils/SpendingData.d.ts +1 -1
- package/dist/transactions/TransactionWidget.d.ts +1 -1
- package/dist/transactions/components/shared/TransactionDetails.d.ts +1 -1
- package/dist/transactions/components/shared/TransactionList.d.ts +3 -4
- package/dist/transactions/components/shared/getEmbeddedInstanceSlotByBeatTemplates.d.ts +17 -0
- 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/ExcludeAction.d.ts +7 -0
- 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 +2 -1
- package/dist/transactions/components/shared/transactionlist/TransactionRow.d.ts +1 -1
- package/dist/transactions/components/shared/transactiontable/cells/PayeeCell.d.ts +4 -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/context/hooks.d.ts +1 -1
- package/dist/transactions/index.d.ts +0 -5
- package/dist/transactions/index.es.js +344 -351
- package/dist/transactions/utils/Filters.d.ts +1 -1
- package/dist/transactions/utils/Transactions.d.ts +17 -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.d.ts → TrendsTableContainer.d.ts} +2 -2
- package/dist/trends/components/trendstable/AccessibleSortIcon.d.ts +13 -0
- package/dist/trends/components/trendstable/TrendsTable.d.ts +12 -0
- package/dist/trends/index.d.ts +0 -1
- package/dist/trends/index.es.js +987 -874
- package/dist/trends/utils/SpendingData.d.ts +1 -1
- package/dist/trends/utils/TrendsTable.d.ts +5 -3
- package/dist/trends/utils/TrendsWidget.d.ts +7 -0
- package/dist/trends/utils/shared.d.ts +2 -2
- package/dist/{useAccountDisplayName-DbkgGLdg.mjs → useAccountDisplayName-CFa_MrS6.mjs} +5 -5
- package/dist/{useAriaLive-B3_pRUio.mjs → useAriaLive-MkYebyUR.mjs} +4 -4
- package/dist/{useDimensions-27p2evRx.mjs → useDimensions-CeDR9V8N.mjs} +6 -6
- package/dist/{useInsightsEnabled-dhmXeSyF.mjs → useInsightsEnabled-DaNLPmUU.mjs} +1 -1
- package/dist/{useScreenSize-B6JyS_Lj.mjs → useScreenSize-mWpmnh5w.mjs} +3 -3
- package/dist/{useWidgetLoadTimer-CrUzxN-P.mjs → useWidgetLoadTimer-CJb-RELP.mjs} +1 -1
- package/package.json +65 -43
- package/dist/AccountApi-DgZ8ILj1.mjs +0 -19
- package/dist/AccountDetailsHeader-BOV91g1o.mjs +0 -95
- package/dist/AccountFields-BRRH37K1.mjs +0 -140
- package/dist/AccountListItem-Ds5C0mOT.mjs +0 -90
- package/dist/AccountStore-BFKvXJSD.mjs +0 -244
- package/dist/Accounts-CuE8aSZN.mjs +0 -27
- package/dist/BeatApi-De2IaqH2.mjs +0 -21
- package/dist/BeatStore-D_NYuBSz.mjs +0 -81
- package/dist/BudgetUtil-CDSOZXem.mjs +0 -101
- package/dist/CashflowStore-naOtJcwo.mjs +0 -91
- package/dist/CategoryStore-DEqAnHbi.mjs +0 -186
- package/dist/CategoryUtil-CFHBvaV4.mjs +0 -80
- package/dist/CurrencyInput-DDQ4DBrE.mjs +0 -85
- package/dist/DateUtil-CVsMhbZU.mjs +0 -48
- package/dist/DebtsStore-Dv_T7Dts.mjs +0 -63
- package/dist/Dialog-CWymUiuO.mjs +0 -120
- package/dist/Donut-Dmy3JTWd.mjs +0 -86
- package/dist/Fetch-DecPFeGU.mjs +0 -119
- package/dist/FinstrongStore-BjFkMTIL.mjs +0 -451
- package/dist/GlobalAccountFilter-BpWlPAl5.mjs +0 -316
- package/dist/GoalStore-Dbjgft2i.mjs +0 -422
- package/dist/HeaderCell-DjuifqHJ.mjs +0 -6
- package/dist/LineChart-DHj-Bufi.mjs +0 -580
- package/dist/Loader-BSWSYqvn.mjs +0 -24
- package/dist/Localization-2MODESHW.mjs +0 -30
- package/dist/ManageIncome-DIIyqDTp.mjs +0 -585
- package/dist/MerchantStore-WvZ4gnQe.mjs +0 -37
- package/dist/MiniWidgetContainer-DKn7ndO6.mjs +0 -56
- package/dist/NetWorthStore-B6ziBtaH.mjs +0 -168
- package/dist/Notification-Bs1fdbzI.mjs +0 -95
- package/dist/NotificationStore-Ck2KdNmT.mjs +0 -79
- package/dist/OriginalBalanceAction-DFoG79Ba.mjs +0 -115
- package/dist/RecurringTransactionsStore-D_--5PWH.mjs +0 -277
- package/dist/RepeatingTransaction-C2txVA9O.mjs +0 -292
- package/dist/SearchBox-B2_zLv8-.mjs +0 -42
- package/dist/SettingsStore-CInvh-rQ.mjs +0 -269
- package/dist/SpendingLegend-BxefXiQd.mjs +0 -193
- package/dist/TransactionApi-CjBoLleL.mjs +0 -86
- package/dist/TransactionDetails-CPwv9xtZ.mjs +0 -1374
- package/dist/TransactionStore-D2aMUClq.mjs +0 -688
- package/dist/TrendsStore-BdsYfCc7.mjs +0 -183
- package/dist/User-CulNdZUr.mjs +0 -314
- package/dist/ViewMoreMicroCard-CDWR16_h.mjs +0 -1147
- package/dist/WidgetContainer-mzejMmz2.mjs +0 -555
- package/dist/accounts/stores/UiStore.d.ts +0 -10
- package/dist/accounts/utils/index.d.ts +0 -1
- package/dist/cashflow/api/CashflowApi.d.ts +0 -13
- package/dist/cashflow/stores/CashflowStore.d.ts +0 -8
- package/dist/categories/stores/UiStore.d.ts +0 -20
- package/dist/common/api/LocalizedCopyApi.d.ts +0 -8
- package/dist/common/api/index.d.ts +0 -10
- 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/stores/index.d.ts +0 -3
- package/dist/common/types/SpendingPlan.d.ts +0 -44
- package/dist/common/utils/Categories.d.ts +0 -6
- package/dist/debts/store/DebtsStore.d.ts +0 -9
- package/dist/debts/store/DebtsUiStore.d.ts +0 -13
- package/dist/debts/utils/DebtStore.d.ts +0 -4
- package/dist/debts/utils/DebtsWidget.d.ts +0 -14
- package/dist/debts/utils/shared.d.ts +0 -12
- package/dist/exportTransactionsToCSV-BU1jTY0Q.mjs +0 -48
- package/dist/help/constants/index.d.ts +0 -1
- package/dist/help/utils/getAccessibleHelpCategories.d.ts +0 -3
- package/dist/transactions/analytics.d.ts +0 -3
- package/dist/transactions/components/shared/transactiondetails/actions/HideAction.d.ts +0 -7
- package/dist/transactions/components/shared/transactionlist/DateRow.d.ts +0 -7
- package/dist/transactions/constants/Transaction.d.ts +0 -2
- package/dist/transactions/constants/TransactionsTable.d.ts +0 -17
- package/dist/transactions/stores/UiStore.d.ts +0 -25
- package/dist/transactions/utils/exportTransactionsToCSV.d.ts +0 -9
- package/dist/transactions/utils/sortAndFilterTransactions.d.ts +0 -3
- package/dist/trends/components/CategoryDetailDrawer.d.ts +0 -7
- package/dist/useCombineEvents-CRwX-qWE.mjs +0 -92
- package/dist/{common → core}/constants/Category.d.ts +0 -0
- package/dist/{common → core}/constants/DateFormats.d.ts +0 -0
- package/dist/{debts/constants/index.d.ts → core/constants/Debts.d.ts} +0 -0
- package/dist/{help → core}/constants/Help.d.ts +0 -0
- package/dist/{investments/constants/index.d.ts → core/constants/Investments.d.ts} +0 -0
- package/dist/{common → core}/constants/Numbers.d.ts +0 -0
- package/dist/{common → core}/constants/Table.d.ts +0 -0
- package/dist/{common → core}/stores/GlobalCopyStore.d.ts +0 -0
- package/dist/{common → core}/stores/GlobalUiStore.d.ts +0 -0
- package/dist/{common → core}/stores/UserStore.d.ts +1 -1
- /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/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/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/HelpCopy.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/index.d.ts +0 -0
- /package/dist/{common → core}/utils/DateUtil.d.ts +0 -0
- /package/dist/{common → core}/utils/Fetch.d.ts +0 -0
- /package/dist/{common/utils/User.d.ts → core/utils/UserUtils.d.ts} +0 -0
package/dist/trends/index.es.js
CHANGED
|
@@ -1,121 +1,124 @@
|
|
|
1
|
-
import { jsxs as C, jsx as e, Fragment as
|
|
2
|
-
import
|
|
3
|
-
import { observer as
|
|
4
|
-
import { CategoryIcon as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import { addSeconds as
|
|
1
|
+
import { jsxs as C, jsx as e, Fragment as vt } from "react/jsx-runtime";
|
|
2
|
+
import g, { useRef as wt, useState as Dt, useEffect as It } from "react";
|
|
3
|
+
import { observer as A } from "mobx-react-lite";
|
|
4
|
+
import { CategoryIcon as ve, Text as F, Icon as He, H3 as Ge, P as pe } from "@mxenabled/mxui";
|
|
5
|
+
import H from "@mui/material/Box";
|
|
6
|
+
import S from "@mui/material/Stack";
|
|
7
|
+
import Te from "@mui/material/Button";
|
|
8
|
+
import { addSeconds as et } from "date-fns/addSeconds";
|
|
9
9
|
import { differenceInCalendarMonths as Se } from "date-fns/differenceInCalendarMonths";
|
|
10
|
-
import
|
|
11
|
-
import { useTheme as
|
|
12
|
-
import { useItemTooltip as
|
|
13
|
-
import { LineChart as
|
|
14
|
-
import { u as
|
|
15
|
-
import { u as
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import {
|
|
21
|
-
import { b as
|
|
22
|
-
import { C as xe } from "../CurrencyText-
|
|
23
|
-
import { a as Re,
|
|
24
|
-
import { f as
|
|
25
|
-
import { f as
|
|
26
|
-
import { a as
|
|
27
|
-
import {
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import {
|
|
32
|
-
import { T as
|
|
33
|
-
import {
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
import {
|
|
44
|
-
import { M as
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import
|
|
58
|
-
import {
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
10
|
+
import Lt from "numeral";
|
|
11
|
+
import { useTheme as Z, styled as Et, alpha as Mt } from "@mui/material/styles";
|
|
12
|
+
import { useItemTooltip as At, ChartsTooltipContainer as Rt } from "@mui/x-charts/ChartsTooltip";
|
|
13
|
+
import { LineChart as kt } from "@mui/x-charts/LineChart";
|
|
14
|
+
import { u as Q } from "../useScreenSize-mWpmnh5w.mjs";
|
|
15
|
+
import { u as Ht } from "../useDimensions-CeDR9V8N.mjs";
|
|
16
|
+
import tt from "@mui/material/Card";
|
|
17
|
+
import ot from "@mui/material/CardContent";
|
|
18
|
+
import Ne from "@mui/material/Divider";
|
|
19
|
+
import Fe from "@mui/material/Grid";
|
|
20
|
+
import { b as nt } from "../Localization-DnoVyBNK.mjs";
|
|
21
|
+
import { u as R, l as q, g as $, b as fe, h as we, d as De, B as ye, D as st, f as Be, a as rt } from "../hooks-BaO_gOI6.mjs";
|
|
22
|
+
import { C as xe } from "../CurrencyText-CCbE6MmF.mjs";
|
|
23
|
+
import { a as Re, C as $e, b as Nt } from "../Category-DEKZGLYe.mjs";
|
|
24
|
+
import { f as X, D as G } from "../DateFormats-HudZ3Bjs.mjs";
|
|
25
|
+
import { f as re, a as Wt } from "../NumberFormatting--XMeeBfr.mjs";
|
|
26
|
+
import { a as Ke, c as Ot, g as Gt } from "../TrendsUtil-D9z3kIj_.mjs";
|
|
27
|
+
import { c as Bt, i as Pt, d as Vt, e as zt, g as at, b as it, f as Ye } from "../SpendingData-PKlh8caU.mjs";
|
|
28
|
+
import Ft from "@mui/material/ToggleButton";
|
|
29
|
+
import $t from "@mui/material/ToggleButtonGroup";
|
|
30
|
+
import { parseISO as lt } from "date-fns/parseISO";
|
|
31
|
+
import { H as ke } from "../HeaderCell-P8w6CmfO.mjs";
|
|
32
|
+
import { T as W, a as Kt } from "../ViewMoreMicroCard-BD_MNc2z.mjs";
|
|
33
|
+
import { useGridApiContext as Yt, useGridRootProps as jt, DataGridPro as Ut } from "@mui/x-data-grid-pro";
|
|
34
|
+
import Xt from "@mui/material/Badge";
|
|
35
|
+
import Zt from "@mui/material/IconButton";
|
|
36
|
+
import { A as w } from "../Analytics-CzGzz_sE.mjs";
|
|
37
|
+
import { T as ct } from "../EmbeddedCard-DPwJjqMH.mjs";
|
|
38
|
+
import { T as dt } from "../TransactionDetails-C3dlAzYf.mjs";
|
|
39
|
+
import { D as Pe } from "../Drawer-BXqqBMxg.mjs";
|
|
40
|
+
import { u as Ie } from "../useWidgetLoadTimer-CJb-RELP.mjs";
|
|
41
|
+
import { L as Le } from "../Loader-CxeBwuPG.mjs";
|
|
42
|
+
import { W as ut } from "../WidgetContainer-DNuz_s7W.mjs";
|
|
43
|
+
import { L as Ve } from "../LineChart-CejWS_rh.mjs";
|
|
44
|
+
import { M as Qt } from "../MiniWidgetContainer-BdPiUU-u.mjs";
|
|
45
|
+
import { subMonths as qt } from "date-fns";
|
|
46
|
+
import { TrendingUp as Jt, TrendingDown as eo, MultilineChart as to, ExpandLess as oo, ExpandMore as no, ChevronRight as so, ArrowBack as ro } from "@mxenabled/mx-icons";
|
|
47
|
+
import { M as ao } from "../MicroWidgetContainer-CfKdQfhi.mjs";
|
|
48
|
+
import io from "@mui/material/Collapse";
|
|
49
|
+
import We from "@mui/material/List";
|
|
50
|
+
import mt from "@mui/material/ListItem";
|
|
51
|
+
import lo from "@mui/material/ListItemButton";
|
|
52
|
+
import co from "@mui/material/ListItemIcon";
|
|
53
|
+
import ht from "@mui/material/ListItemText";
|
|
54
|
+
import { g as Oe } from "../TransactionUtils-BphBJBbU.mjs";
|
|
55
|
+
import { L as uo } from "../ListItemRow-kH1rn8Xu.mjs";
|
|
56
|
+
import { Stack as mo } from "@mui/material";
|
|
57
|
+
import ho from "@mui/material/ListItemAvatar";
|
|
58
|
+
import { E as go } from "../ExportCsvAction-Bw02ZJEj.mjs";
|
|
59
|
+
import { u as po } from "../useInsightsEnabled-DaNLPmUU.mjs";
|
|
60
|
+
import { E as fo } from "../EmptyState-CJUDc3kD.mjs";
|
|
61
|
+
import { C as yo } from "../ConnectDrawer-Cnjr3Ddg.mjs";
|
|
62
|
+
const gt = ({ categoryGuid: t, topLevelCategoryGuid: n }) => {
|
|
63
|
+
const { categories: s } = R(), { getCategoryName: o } = q(), r = o(t);
|
|
64
|
+
return /* @__PURE__ */ C(S, { alignItems: "center", direction: "column", gap: "8", justifyContent: "center", mb: 4, children: [
|
|
62
65
|
/* @__PURE__ */ e(
|
|
63
|
-
|
|
66
|
+
H,
|
|
64
67
|
{
|
|
65
|
-
"aria-label":
|
|
68
|
+
"aria-label": nt(s.category_icon_label_aria, r),
|
|
66
69
|
mb: 4,
|
|
67
70
|
role: "img",
|
|
68
|
-
children: /* @__PURE__ */ e(
|
|
71
|
+
children: /* @__PURE__ */ e(ve, { categoryGuid: n })
|
|
69
72
|
}
|
|
70
73
|
),
|
|
71
|
-
/* @__PURE__ */ e(
|
|
74
|
+
/* @__PURE__ */ e(F, { variant: "body1", children: r })
|
|
72
75
|
] });
|
|
73
|
-
},
|
|
74
|
-
categoryGuids: { guid:
|
|
75
|
-
hoveredAreaData:
|
|
76
|
-
cursorPosition:
|
|
76
|
+
}, Co = ({
|
|
77
|
+
categoryGuids: { guid: t, topLevelGuid: n },
|
|
78
|
+
hoveredAreaData: s,
|
|
79
|
+
cursorPosition: o,
|
|
77
80
|
chartContainerRef: r
|
|
78
81
|
}) => {
|
|
79
|
-
const
|
|
80
|
-
if (
|
|
82
|
+
const c = Z(), a = wt(null), [d, u] = Dt({ x: o.x, y: o.y });
|
|
83
|
+
if (It(() => {
|
|
81
84
|
(() => {
|
|
82
|
-
const m =
|
|
85
|
+
const m = a.current, _ = r.current;
|
|
83
86
|
if (!m || !_) return;
|
|
84
|
-
const
|
|
85
|
-
let y =
|
|
86
|
-
y +
|
|
87
|
+
const h = m.getBoundingClientRect(), p = _.getBoundingClientRect();
|
|
88
|
+
let y = o.x, T = o.y;
|
|
89
|
+
y + h.width * 2 > p.right ? y = o.x - h.width : y - h.width < p.left && (y = o.x), T + h.height * 2 > p.bottom && (T = o.y - h.height), u({ x: y, y: T });
|
|
87
90
|
})();
|
|
88
|
-
}, [
|
|
89
|
-
const
|
|
91
|
+
}, [o, r]), !s) return null;
|
|
92
|
+
const i = s.reduce((f, m) => f + m.y, 0);
|
|
90
93
|
return /* @__PURE__ */ e(
|
|
91
|
-
|
|
94
|
+
tt,
|
|
92
95
|
{
|
|
93
|
-
ref:
|
|
96
|
+
ref: a,
|
|
94
97
|
sx: {
|
|
95
98
|
position: "absolute",
|
|
96
|
-
top:
|
|
97
|
-
left:
|
|
99
|
+
top: d.y,
|
|
100
|
+
left: d.x,
|
|
98
101
|
width: 250,
|
|
99
102
|
pointerEvents: "none"
|
|
100
103
|
},
|
|
101
|
-
children: /* @__PURE__ */ C(
|
|
102
|
-
/* @__PURE__ */ C(
|
|
103
|
-
/* @__PURE__ */ e(
|
|
104
|
-
/* @__PURE__ */ e(
|
|
105
|
-
/* @__PURE__ */ e(xe, { amount:
|
|
104
|
+
children: /* @__PURE__ */ C(ot, { children: [
|
|
105
|
+
/* @__PURE__ */ C(H, { alignItems: "center", display: "flex", flexDirection: "column", children: [
|
|
106
|
+
/* @__PURE__ */ e(gt, { categoryGuid: t, topLevelCategoryGuid: n }),
|
|
107
|
+
/* @__PURE__ */ e(F, { variant: "body2", children: `${s.length}-month total` }),
|
|
108
|
+
/* @__PURE__ */ e(xe, { amount: i, bold: !0, formatString: "0,0", variant: "body2" })
|
|
106
109
|
] }),
|
|
107
|
-
/* @__PURE__ */ e(
|
|
108
|
-
/* @__PURE__ */ e(
|
|
109
|
-
m > 0 && m % 3 === 0 && /* @__PURE__ */ e(
|
|
110
|
-
/* @__PURE__ */ e(
|
|
111
|
-
/* @__PURE__ */ e(
|
|
110
|
+
/* @__PURE__ */ e(Ne, { sx: { my: 16, width: "100%" } }),
|
|
111
|
+
/* @__PURE__ */ e(Fe, { container: !0, children: s.map((f, m) => /* @__PURE__ */ C(g.Fragment, { children: [
|
|
112
|
+
m > 0 && m % 3 === 0 && /* @__PURE__ */ e(Ne, { sx: { my: 16, width: "100%" } }),
|
|
113
|
+
/* @__PURE__ */ e(Fe, { size: 4, children: /* @__PURE__ */ C(H, { alignItems: "center", display: "flex", flexDirection: "column", children: [
|
|
114
|
+
/* @__PURE__ */ e(F, { color: c.palette.text.secondary, variant: "caption", children: f.x }),
|
|
112
115
|
/* @__PURE__ */ e(
|
|
113
116
|
xe,
|
|
114
117
|
{
|
|
115
|
-
amount:
|
|
118
|
+
amount: f.y,
|
|
116
119
|
bold: !0,
|
|
117
120
|
formatString: "0,0",
|
|
118
|
-
variant: "
|
|
121
|
+
variant: "body1"
|
|
119
122
|
}
|
|
120
123
|
)
|
|
121
124
|
] }) })
|
|
@@ -123,31 +126,31 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
123
126
|
] })
|
|
124
127
|
}
|
|
125
128
|
);
|
|
126
|
-
},
|
|
127
|
-
sx:
|
|
128
|
-
categoryGuids:
|
|
129
|
-
hoveredLegend:
|
|
130
|
-
legendRef:
|
|
129
|
+
}, _o = A(Co), bo = ({
|
|
130
|
+
sx: t,
|
|
131
|
+
categoryGuids: n,
|
|
132
|
+
hoveredLegend: s,
|
|
133
|
+
legendRef: o,
|
|
131
134
|
onHoverLegend: r,
|
|
132
|
-
onClickLegend:
|
|
135
|
+
onClickLegend: c
|
|
133
136
|
}) => {
|
|
134
|
-
const { isMobile:
|
|
137
|
+
const { isMobile: a } = Q(), { getCategoryName: d } = q();
|
|
135
138
|
return /* @__PURE__ */ e(
|
|
136
|
-
|
|
139
|
+
S,
|
|
137
140
|
{
|
|
138
141
|
direction: "row",
|
|
139
142
|
flexWrap: "wrap",
|
|
140
|
-
gap:
|
|
143
|
+
gap: a ? 2 : 6,
|
|
141
144
|
justifyContent: "start",
|
|
142
|
-
ref:
|
|
143
|
-
sx:
|
|
144
|
-
children:
|
|
145
|
-
const
|
|
145
|
+
ref: o,
|
|
146
|
+
sx: t,
|
|
147
|
+
children: n.map(({ guid: u, top_level_guid: i }) => {
|
|
148
|
+
const f = s === u, m = Re[u], _ = Re[i], h = m ?? _ ?? Re.default, p = h + "33";
|
|
146
149
|
return /* @__PURE__ */ C(
|
|
147
|
-
|
|
150
|
+
Te,
|
|
148
151
|
{
|
|
149
|
-
onClick: () =>
|
|
150
|
-
onMouseEnter: () => r(
|
|
152
|
+
onClick: () => c(u),
|
|
153
|
+
onMouseEnter: () => r(u),
|
|
151
154
|
onMouseLeave: () => r(null),
|
|
152
155
|
sx: {
|
|
153
156
|
color: "text.primary",
|
|
@@ -158,151 +161,151 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
158
161
|
paddingX: 8,
|
|
159
162
|
paddingY: 4,
|
|
160
163
|
borderRadius: 1,
|
|
161
|
-
opacity:
|
|
164
|
+
opacity: f ? 1 : 0.7
|
|
162
165
|
},
|
|
163
166
|
children: [
|
|
164
167
|
/* @__PURE__ */ e(
|
|
165
|
-
|
|
168
|
+
H,
|
|
166
169
|
{
|
|
167
170
|
sx: {
|
|
168
171
|
width: 16,
|
|
169
172
|
height: 16,
|
|
170
|
-
marginRight:
|
|
173
|
+
marginRight: a ? 5 : 10,
|
|
171
174
|
borderRadius: "2px",
|
|
172
|
-
backgroundColor:
|
|
175
|
+
backgroundColor: s ? f ? h : p : h
|
|
173
176
|
}
|
|
174
177
|
}
|
|
175
178
|
),
|
|
176
|
-
/* @__PURE__ */ e(
|
|
179
|
+
/* @__PURE__ */ e(F, { variant: "body1", children: d(u) })
|
|
177
180
|
]
|
|
178
181
|
},
|
|
179
|
-
|
|
182
|
+
u
|
|
180
183
|
);
|
|
181
184
|
})
|
|
182
185
|
}
|
|
183
186
|
);
|
|
184
|
-
},
|
|
185
|
-
categoryGuids: { guid:
|
|
186
|
-
series:
|
|
187
|
-
xData:
|
|
187
|
+
}, To = ({
|
|
188
|
+
categoryGuids: { guid: t, topLevelGuid: n },
|
|
189
|
+
series: s,
|
|
190
|
+
xData: o
|
|
188
191
|
}) => {
|
|
189
|
-
const r =
|
|
192
|
+
const r = At(), c = Z();
|
|
190
193
|
if (!r?.identifier) return null;
|
|
191
|
-
const { dataIndex:
|
|
192
|
-
if (
|
|
193
|
-
const
|
|
194
|
-
return
|
|
195
|
-
/* @__PURE__ */ e(
|
|
196
|
-
/* @__PURE__ */ e(
|
|
197
|
-
/* @__PURE__ */ e(xe, { amount: String(
|
|
194
|
+
const { dataIndex: a, seriesId: d } = r.identifier;
|
|
195
|
+
if (a == null || !d) return null;
|
|
196
|
+
const i = s.find((m) => m.id === d)?.data?.[a], f = o?.[a];
|
|
197
|
+
return i === void 0 || !f ? null : /* @__PURE__ */ e(tt, { sx: { pt: 4, px: 8 }, children: /* @__PURE__ */ e(ot, { children: /* @__PURE__ */ C(H, { alignItems: "center", display: "flex", flexDirection: "column", children: [
|
|
198
|
+
/* @__PURE__ */ e(gt, { categoryGuid: t, topLevelCategoryGuid: n }),
|
|
199
|
+
/* @__PURE__ */ e(F, { color: c.palette.text.secondary, variant: "body2", children: X(f, G.MONTH_SHORT_YEAR) }),
|
|
200
|
+
/* @__PURE__ */ e(xe, { amount: String(i), bold: !0, formatString: "0,0", variant: "body1" })
|
|
198
201
|
] }) }) });
|
|
199
|
-
},
|
|
200
|
-
onHoverArea:
|
|
201
|
-
onHoverPoint:
|
|
202
|
-
onHoverLegend:
|
|
203
|
-
onClickLegend:
|
|
202
|
+
}, So = ({
|
|
203
|
+
onHoverArea: t,
|
|
204
|
+
onHoverPoint: n,
|
|
205
|
+
onHoverLegend: s,
|
|
206
|
+
onClickLegend: o,
|
|
204
207
|
stackedDatasets: r,
|
|
205
|
-
unstackedDatasets:
|
|
206
|
-
availableHeight:
|
|
207
|
-
minimumHeight:
|
|
208
|
+
unstackedDatasets: c = [],
|
|
209
|
+
availableHeight: a = 0,
|
|
210
|
+
minimumHeight: d = 350
|
|
208
211
|
}) => {
|
|
209
|
-
const
|
|
210
|
-
|
|
211
|
-
const
|
|
212
|
-
|
|
213
|
-
}, [
|
|
214
|
-
const [y,
|
|
212
|
+
const u = Z(), { isMobile: i } = Q(), [f, { height: m }] = Ht(), _ = g.useRef(null), [h, p] = g.useState(0);
|
|
213
|
+
g.useEffect(() => {
|
|
214
|
+
const l = Math.max(a - m, d);
|
|
215
|
+
p(l);
|
|
216
|
+
}, [a, m]);
|
|
217
|
+
const [y, T] = g.useState(null), [N, x] = g.useState({
|
|
215
218
|
hoveredSeriesId: null,
|
|
216
219
|
hoveredAreaData: null,
|
|
217
220
|
isAreaHovered: !1,
|
|
218
221
|
cursorPos: { x: 0, y: 0 }
|
|
219
|
-
}), { hoveredSeriesId:
|
|
220
|
-
(
|
|
221
|
-
) ?? [0],
|
|
222
|
-
...
|
|
223
|
-
),
|
|
224
|
-
id: `stacked-${
|
|
225
|
-
guid:
|
|
226
|
-
top_level_guid:
|
|
222
|
+
}), { hoveredSeriesId: L, hoveredAreaData: M, isAreaHovered: E, cursorPos: v } = N, K = E && L && M, ae = !K, Y = [...r, ...c], J = Y[0]?.dataset.length ?? 0, P = Y.flatMap((l) => l.dataset.map((b) => b.x)), V = Y.flatMap((l) => l.dataset.map((b) => b.y)), O = r[0]?.dataset?.map(
|
|
223
|
+
(l, b) => r.reduce((I, z) => I + z.dataset[b]?.y || 0, 0)
|
|
224
|
+
) ?? [0], ee = Math.max(...O), Ce = Math.max(
|
|
225
|
+
...c.flatMap((l) => l.dataset.map((b) => b.y))
|
|
226
|
+
), ie = Math.floor(Math.min(...V) / 100) * 100, te = Math.ceil(Math.max(ee, Ce) / 100) * 100, j = r.map((l, b) => ({
|
|
227
|
+
id: `stacked-${b}`,
|
|
228
|
+
guid: l.category_guid,
|
|
229
|
+
top_level_guid: l.top_level_category_guid,
|
|
227
230
|
area: !0,
|
|
228
|
-
color: r[
|
|
229
|
-
data:
|
|
230
|
-
label: r[
|
|
231
|
+
color: r[b].category_color ?? u.palette.primary.main,
|
|
232
|
+
data: l.dataset.map((I) => I.y),
|
|
233
|
+
label: r[b].category_name,
|
|
231
234
|
stack: "total",
|
|
232
235
|
type: "line",
|
|
233
236
|
highlightScope: { highlight: "item" },
|
|
234
|
-
valueFormatter: (
|
|
235
|
-
})),
|
|
236
|
-
id: `unstacked-${
|
|
237
|
-
guid:
|
|
238
|
-
top_level_guid:
|
|
237
|
+
valueFormatter: (I) => re(I, "0,0")
|
|
238
|
+
})), ne = c.map((l, b) => ({
|
|
239
|
+
id: `unstacked-${b}`,
|
|
240
|
+
guid: l.category_guid,
|
|
241
|
+
top_level_guid: l.top_level_category_guid,
|
|
239
242
|
area: !1,
|
|
240
|
-
color:
|
|
241
|
-
data:
|
|
242
|
-
label:
|
|
243
|
+
color: l.category_color,
|
|
244
|
+
data: l.dataset.map((I) => I.y),
|
|
245
|
+
label: l.category_name,
|
|
243
246
|
type: "line",
|
|
244
|
-
valueFormatter: (
|
|
245
|
-
})),
|
|
246
|
-
...
|
|
247
|
-
guid:
|
|
248
|
-
top_level_guid:
|
|
247
|
+
valueFormatter: (I) => re(I, "0,0")
|
|
248
|
+
})), U = [...j, ...ne], de = [
|
|
249
|
+
...j.map(({ guid: l, top_level_guid: b }) => ({
|
|
250
|
+
guid: l,
|
|
251
|
+
top_level_guid: b
|
|
249
252
|
})),
|
|
250
|
-
...
|
|
251
|
-
guid:
|
|
252
|
-
top_level_guid:
|
|
253
|
+
...ne.map(({ guid: l, top_level_guid: b }) => ({
|
|
254
|
+
guid: l,
|
|
255
|
+
top_level_guid: b
|
|
253
256
|
}))
|
|
254
|
-
],
|
|
255
|
-
const
|
|
257
|
+
], B = (l) => {
|
|
258
|
+
const I = l.startsWith("stacked-") ? r[parseInt(l.split("-")[1])] : c[parseInt(l.split("-")[1])];
|
|
256
259
|
return {
|
|
257
|
-
guid:
|
|
258
|
-
topLevelGuid:
|
|
260
|
+
guid: I?.category_guid,
|
|
261
|
+
topLevelGuid: I?.top_level_category_guid
|
|
259
262
|
};
|
|
260
|
-
},
|
|
261
|
-
|
|
262
|
-
},
|
|
263
|
-
|
|
264
|
-
},
|
|
265
|
-
const
|
|
266
|
-
|
|
267
|
-
}, ce = (
|
|
268
|
-
const
|
|
263
|
+
}, ue = (l) => {
|
|
264
|
+
T(l), s?.(l ?? "");
|
|
265
|
+
}, se = (l) => {
|
|
266
|
+
o?.(l ?? "");
|
|
267
|
+
}, le = () => {
|
|
268
|
+
const l = B(String(L)).guid;
|
|
269
|
+
l && o?.(l);
|
|
270
|
+
}, ce = (l) => {
|
|
271
|
+
const b = String(l?.seriesId), I = B(b).guid, z = U.find((he) => he.id === b), Ee = z && l?.dataIndex !== void 0, _e = z && l?.dataIndex === void 0;
|
|
269
272
|
if (Ee)
|
|
270
|
-
|
|
271
|
-
hoveredSeriesId:
|
|
273
|
+
x({
|
|
274
|
+
hoveredSeriesId: b,
|
|
272
275
|
hoveredAreaData: null,
|
|
273
276
|
isAreaHovered: !1,
|
|
274
|
-
cursorPos:
|
|
275
|
-
}),
|
|
277
|
+
cursorPos: v
|
|
278
|
+
}), n?.(I);
|
|
276
279
|
else if (_e) {
|
|
277
|
-
const
|
|
278
|
-
x:
|
|
280
|
+
const he = z?.data.map((Me, Ae) => ({
|
|
281
|
+
x: P[Ae],
|
|
279
282
|
y: Me
|
|
280
283
|
})) ?? [];
|
|
281
|
-
|
|
282
|
-
hoveredSeriesId:
|
|
283
|
-
hoveredAreaData:
|
|
284
|
+
x({
|
|
285
|
+
hoveredSeriesId: b,
|
|
286
|
+
hoveredAreaData: he,
|
|
284
287
|
isAreaHovered: !0,
|
|
285
|
-
cursorPos:
|
|
286
|
-
}),
|
|
288
|
+
cursorPos: v
|
|
289
|
+
}), t?.(I);
|
|
287
290
|
} else
|
|
288
|
-
|
|
291
|
+
x({
|
|
289
292
|
hoveredSeriesId: null,
|
|
290
293
|
hoveredAreaData: null,
|
|
291
294
|
isAreaHovered: !1,
|
|
292
|
-
cursorPos:
|
|
295
|
+
cursorPos: v
|
|
293
296
|
});
|
|
294
|
-
},
|
|
295
|
-
if (
|
|
297
|
+
}, me = (l) => {
|
|
298
|
+
if (l.target instanceof Element && l.target.classList[0]?.includes("MuiMarkElement-root"))
|
|
296
299
|
return;
|
|
297
|
-
const
|
|
298
|
-
|
|
299
|
-
...
|
|
300
|
+
const b = l.currentTarget.getBoundingClientRect();
|
|
301
|
+
x((I) => ({
|
|
302
|
+
...I,
|
|
300
303
|
cursorPos: {
|
|
301
|
-
x:
|
|
302
|
-
y:
|
|
304
|
+
x: l.clientX - b.left,
|
|
305
|
+
y: l.clientY - b.top
|
|
303
306
|
}
|
|
304
307
|
}));
|
|
305
|
-
},
|
|
308
|
+
}, D = {
|
|
306
309
|
p: 4,
|
|
307
310
|
"& .MuiBarLabel-root": {
|
|
308
311
|
fontSize: 10,
|
|
@@ -318,17 +321,17 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
318
321
|
'& [class*="MuiLineElement-series-unstacked-"]': {
|
|
319
322
|
strokeWidth: 3
|
|
320
323
|
},
|
|
321
|
-
...y &&
|
|
322
|
-
const
|
|
323
|
-
return
|
|
324
|
-
opacity:
|
|
325
|
-
},
|
|
324
|
+
...y && j.reduce((l, b, I) => {
|
|
325
|
+
const z = `.MuiAreaElement-series-stacked-${I}`;
|
|
326
|
+
return l[z] = {
|
|
327
|
+
opacity: j[I].guid === y ? 0.9 : 0.2
|
|
328
|
+
}, l;
|
|
326
329
|
}, {})
|
|
327
330
|
};
|
|
328
331
|
return /* @__PURE__ */ e(
|
|
329
|
-
|
|
332
|
+
H,
|
|
330
333
|
{
|
|
331
|
-
onMouseMove:
|
|
334
|
+
onMouseMove: me,
|
|
332
335
|
ref: _,
|
|
333
336
|
sx: {
|
|
334
337
|
position: "relative",
|
|
@@ -342,75 +345,75 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
342
345
|
}
|
|
343
346
|
},
|
|
344
347
|
children: /* @__PURE__ */ C(
|
|
345
|
-
|
|
348
|
+
S,
|
|
346
349
|
{
|
|
347
350
|
direction: { xs: "column", md: "column" },
|
|
348
351
|
spacing: { xs: 0, md: 4 },
|
|
349
352
|
sx: { width: "100%", position: "relative" },
|
|
350
353
|
children: [
|
|
351
354
|
/* @__PURE__ */ e(
|
|
352
|
-
|
|
355
|
+
kt,
|
|
353
356
|
{
|
|
354
|
-
height:
|
|
357
|
+
height: h,
|
|
355
358
|
hideLegend: !0,
|
|
356
359
|
margin: { bottom: 24, left: 12, right: 54, top: 48 },
|
|
357
|
-
onAreaClick:
|
|
360
|
+
onAreaClick: le,
|
|
358
361
|
onHighlightChange: ce,
|
|
359
|
-
series:
|
|
362
|
+
series: U,
|
|
360
363
|
skipAnimation: !0,
|
|
361
364
|
slotProps: {
|
|
362
|
-
tooltip: { trigger:
|
|
365
|
+
tooltip: { trigger: ae ? "item" : "none" }
|
|
363
366
|
},
|
|
364
367
|
slots: {
|
|
365
|
-
tooltip:
|
|
366
|
-
|
|
368
|
+
tooltip: ae && L ? (l) => /* @__PURE__ */ e(Rt, { children: /* @__PURE__ */ e(
|
|
369
|
+
To,
|
|
367
370
|
{
|
|
368
|
-
...
|
|
369
|
-
categoryGuids:
|
|
370
|
-
series:
|
|
371
|
-
xData:
|
|
371
|
+
...l,
|
|
372
|
+
categoryGuids: B(L),
|
|
373
|
+
series: U,
|
|
374
|
+
xData: P
|
|
372
375
|
}
|
|
373
376
|
) }) : void 0
|
|
374
377
|
},
|
|
375
|
-
sx:
|
|
378
|
+
sx: D,
|
|
376
379
|
xAxis: [
|
|
377
380
|
{
|
|
378
|
-
data:
|
|
381
|
+
data: P,
|
|
379
382
|
scaleType: "time",
|
|
380
|
-
valueFormatter: (
|
|
381
|
-
tickNumber:
|
|
383
|
+
valueFormatter: (l) => X(l, G.MONTH_SHORT_YEAR),
|
|
384
|
+
tickNumber: J
|
|
382
385
|
// How many ticks to show on the x-axis
|
|
383
386
|
}
|
|
384
387
|
],
|
|
385
388
|
yAxis: [
|
|
386
389
|
{
|
|
387
|
-
min:
|
|
388
|
-
max:
|
|
389
|
-
valueFormatter: (
|
|
390
|
+
min: ie,
|
|
391
|
+
max: te || 100,
|
|
392
|
+
valueFormatter: (l) => Lt(l).format("0a")
|
|
390
393
|
}
|
|
391
394
|
]
|
|
392
395
|
}
|
|
393
396
|
),
|
|
394
397
|
/* @__PURE__ */ e(
|
|
395
|
-
|
|
398
|
+
bo,
|
|
396
399
|
{
|
|
397
|
-
categoryGuids:
|
|
400
|
+
categoryGuids: de,
|
|
398
401
|
hoveredLegend: y,
|
|
399
|
-
legendRef:
|
|
400
|
-
onClickLegend:
|
|
401
|
-
onHoverLegend:
|
|
402
|
-
sx: { px:
|
|
402
|
+
legendRef: f,
|
|
403
|
+
onClickLegend: se,
|
|
404
|
+
onHoverLegend: ue,
|
|
405
|
+
sx: { px: i ? 0 : 24 }
|
|
403
406
|
}
|
|
404
407
|
),
|
|
405
|
-
|
|
406
|
-
|
|
408
|
+
K && /* @__PURE__ */ e(
|
|
409
|
+
_o,
|
|
407
410
|
{
|
|
408
|
-
categoryGuids:
|
|
411
|
+
categoryGuids: B(L),
|
|
409
412
|
chartContainerRef: _,
|
|
410
|
-
cursorPosition:
|
|
411
|
-
hoveredAreaData:
|
|
412
|
-
...
|
|
413
|
-
x:
|
|
413
|
+
cursorPosition: v,
|
|
414
|
+
hoveredAreaData: M.map((l) => ({
|
|
415
|
+
...l,
|
|
416
|
+
x: X(l.x, G.MONTH_SHORT_YEAR)
|
|
414
417
|
}))
|
|
415
418
|
}
|
|
416
419
|
)
|
|
@@ -419,196 +422,222 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
419
422
|
)
|
|
420
423
|
}
|
|
421
424
|
);
|
|
422
|
-
},
|
|
423
|
-
const { common:
|
|
425
|
+
}, pt = ({ selectedTab: t, onTabChange: n }) => {
|
|
426
|
+
const { common: s } = R();
|
|
424
427
|
return /* @__PURE__ */ e(
|
|
425
|
-
|
|
428
|
+
$t,
|
|
426
429
|
{
|
|
427
|
-
"aria-label":
|
|
430
|
+
"aria-label": s.view_toggle,
|
|
428
431
|
exclusive: !0,
|
|
429
|
-
onChange:
|
|
432
|
+
onChange: n,
|
|
430
433
|
orientation: "horizontal",
|
|
431
|
-
value:
|
|
432
|
-
children: ["Chart", "Table"].map((
|
|
433
|
-
|
|
434
|
+
value: t,
|
|
435
|
+
children: ["Chart", "Table"].map((o) => /* @__PURE__ */ e(
|
|
436
|
+
Ft,
|
|
434
437
|
{
|
|
435
|
-
"aria-label":
|
|
436
|
-
"aria-pressed":
|
|
438
|
+
"aria-label": o === "Chart" ? s.view_chart : s.view_table,
|
|
439
|
+
"aria-pressed": t === o,
|
|
437
440
|
color: "primary",
|
|
438
441
|
sx: { width: 56 },
|
|
439
|
-
value:
|
|
440
|
-
children:
|
|
442
|
+
value: o,
|
|
443
|
+
children: o === "Chart" ? /* @__PURE__ */ e(He, { name: "table_chart_view" }) : /* @__PURE__ */ e(He, { name: "format_list_bulleted" })
|
|
441
444
|
},
|
|
442
|
-
|
|
445
|
+
o
|
|
443
446
|
))
|
|
444
447
|
}
|
|
445
448
|
);
|
|
446
|
-
},
|
|
447
|
-
const { trends:
|
|
448
|
-
const
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
) :
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
),
|
|
455
|
-
|
|
456
|
-
|
|
449
|
+
}, ft = ({ selectedDateRange: t, selectedCategoryGuid: n }) => {
|
|
450
|
+
const { trends: s } = R(), { isMobile: o, isDesktop: r } = Q(), { getCategoryName: c } = q(), a = g.useMemo(() => {
|
|
451
|
+
const i = t.start.getFullYear() === t.end.getFullYear() ? X(
|
|
452
|
+
t.start,
|
|
453
|
+
o ? G.MONTH_SHORT : G.MONTH_LONG
|
|
454
|
+
) : X(
|
|
455
|
+
t.start,
|
|
456
|
+
o ? G.MONTH_SHORT_YEAR : G.MONTH_YEAR
|
|
457
|
+
), f = X(
|
|
458
|
+
t.end,
|
|
459
|
+
o ? G.MONTH_SHORT_YEAR : G.MONTH_YEAR
|
|
457
460
|
);
|
|
458
|
-
return `${
|
|
459
|
-
}, [
|
|
460
|
-
return /* @__PURE__ */ C(
|
|
461
|
+
return `${i} - ${f}`;
|
|
462
|
+
}, [t, o]), u = c(n) || (o ? s.sub_title : s.sub_title_by_category);
|
|
463
|
+
return /* @__PURE__ */ C(H, { children: [
|
|
461
464
|
/* @__PURE__ */ e(
|
|
462
|
-
|
|
465
|
+
Ge,
|
|
463
466
|
{
|
|
464
|
-
display: "block",
|
|
465
|
-
fontWeight: 700,
|
|
466
467
|
sx: {
|
|
467
|
-
|
|
468
|
+
fontSize: r ? null : 15,
|
|
468
469
|
overflow: "visible",
|
|
469
470
|
textOverflow: "unset"
|
|
470
471
|
},
|
|
471
|
-
|
|
472
|
-
children: c
|
|
472
|
+
children: u
|
|
473
473
|
}
|
|
474
474
|
),
|
|
475
|
-
/* @__PURE__ */ e(
|
|
475
|
+
/* @__PURE__ */ e(F, { variant: r ? "subtitle1" : "body2", children: a })
|
|
476
476
|
] });
|
|
477
|
-
},
|
|
478
|
-
|
|
479
|
-
/* @__PURE__ */
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
) }), ze = (o) => {
|
|
487
|
-
const s = o.row.category_guid, n = o.row.top_level_category_guid, t = s === Ve.INCOME || n === Ve.INCOME, r = o.row[o.field];
|
|
488
|
-
return /* @__PURE__ */ e(x, { alignItems: "flex-end", direction: "row", tabIndex: o.tabIndex, children: /* @__PURE__ */ e(
|
|
477
|
+
}, xo = (t) => {
|
|
478
|
+
const n = t.id === "total";
|
|
479
|
+
return /* @__PURE__ */ C(S, { alignItems: "center", direction: "row", role: "rowheader", tabIndex: t.tabIndex, children: [
|
|
480
|
+
!n && /* @__PURE__ */ e(H, { "aria-hidden": !0, children: /* @__PURE__ */ e(ve, { categoryGuid: t.row.top_level_category_guid, variant: "twotone" }) }),
|
|
481
|
+
/* @__PURE__ */ e(F, { bold: n, sx: { ml: 12 }, variant: n ? "body1" : "body2", children: t.row.category })
|
|
482
|
+
] });
|
|
483
|
+
}, je = (t) => {
|
|
484
|
+
const n = t.row.category_guid, s = t.row.top_level_category_guid, o = n === $e.INCOME || s === $e.INCOME, r = t.id === "total", c = t.field === "total", a = c ? t.row[t.field] : t.row.monthlyAmounts[t.field];
|
|
485
|
+
return /* @__PURE__ */ e(S, { alignItems: "flex-end", direction: "row", tabIndex: t.tabIndex, children: /* @__PURE__ */ e(
|
|
489
486
|
xe,
|
|
490
487
|
{
|
|
491
|
-
amount:
|
|
492
|
-
isIncome:
|
|
493
|
-
sx: { fontWeight:
|
|
494
|
-
symbol:
|
|
495
|
-
variant: "body2"
|
|
488
|
+
amount: o ? Math.abs(a) : a,
|
|
489
|
+
isIncome: o,
|
|
490
|
+
sx: { fontWeight: o || c || r ? 600 : 500 },
|
|
491
|
+
symbol: o ? "+" : void 0,
|
|
492
|
+
variant: r ? "body1" : "body2"
|
|
496
493
|
}
|
|
497
494
|
) });
|
|
498
|
-
},
|
|
499
|
-
const
|
|
500
|
-
return
|
|
501
|
-
},
|
|
502
|
-
const
|
|
503
|
-
return
|
|
504
|
-
},
|
|
505
|
-
const
|
|
506
|
-
for (;
|
|
507
|
-
const r =
|
|
508
|
-
|
|
495
|
+
}, Ue = (t, n) => {
|
|
496
|
+
const s = X(lt(n.isoDate), G.MONTH_LONG);
|
|
497
|
+
return t[s] = n.amount, t;
|
|
498
|
+
}, Xe = (t) => (n, s) => {
|
|
499
|
+
const o = X(lt(s.isoDate), G.MONTH_LONG);
|
|
500
|
+
return n + (t.includes(o) ? s.amount : 0);
|
|
501
|
+
}, vo = (t, n) => {
|
|
502
|
+
const s = [], o = new Date(t);
|
|
503
|
+
for (; o <= n; ) {
|
|
504
|
+
const r = X(o, G.MONTH_LONG);
|
|
505
|
+
s.push(r), o.setMonth(o.getMonth() + 1);
|
|
509
506
|
}
|
|
510
|
-
return
|
|
511
|
-
},
|
|
512
|
-
const
|
|
507
|
+
return s;
|
|
508
|
+
}, wo = (t, n) => {
|
|
509
|
+
const s = {
|
|
513
510
|
field: "category",
|
|
514
511
|
flex: 1,
|
|
515
512
|
headerClassName: "trends-table-header",
|
|
516
|
-
headerName:
|
|
513
|
+
headerName: n.category_title,
|
|
517
514
|
minWidth: 210,
|
|
518
515
|
renderHeader: ke,
|
|
519
|
-
renderCell:
|
|
516
|
+
renderCell: xo,
|
|
520
517
|
sortable: !0,
|
|
521
|
-
sortComparator:
|
|
518
|
+
sortComparator: Ot,
|
|
522
519
|
type: "string"
|
|
523
|
-
},
|
|
524
|
-
field:
|
|
520
|
+
}, o = t.map((c) => ({
|
|
521
|
+
field: c,
|
|
525
522
|
flex: 1,
|
|
526
523
|
headerClassName: "trends-table-header",
|
|
527
|
-
headerName:
|
|
524
|
+
headerName: c,
|
|
528
525
|
minWidth: 100,
|
|
529
526
|
renderHeader: ke,
|
|
530
|
-
renderCell:
|
|
531
|
-
align: "
|
|
532
|
-
headerAlign: "
|
|
527
|
+
renderCell: je,
|
|
528
|
+
align: "center",
|
|
529
|
+
headerAlign: "center",
|
|
533
530
|
sortable: !0,
|
|
534
531
|
hideSortIcons: !1,
|
|
535
532
|
type: "number",
|
|
536
|
-
sortComparator:
|
|
533
|
+
sortComparator: Ke,
|
|
534
|
+
valueGetter: (a, d) => d.monthlyAmounts?.[c] ?? 0
|
|
537
535
|
})), r = {
|
|
538
536
|
field: "total",
|
|
539
537
|
flex: 1,
|
|
540
538
|
headerClassName: "trends-table-header",
|
|
541
|
-
headerName:
|
|
539
|
+
headerName: n.table_column_total,
|
|
542
540
|
minWidth: 100,
|
|
543
541
|
renderHeader: ke,
|
|
544
|
-
renderCell:
|
|
545
|
-
align: "
|
|
546
|
-
headerAlign: "
|
|
542
|
+
renderCell: je,
|
|
543
|
+
align: "center",
|
|
544
|
+
headerAlign: "center",
|
|
547
545
|
sortable: !0,
|
|
548
546
|
hideSortIcons: !1,
|
|
549
547
|
type: "number",
|
|
550
|
-
sortComparator:
|
|
548
|
+
sortComparator: Ke
|
|
551
549
|
};
|
|
552
|
-
return [
|
|
553
|
-
},
|
|
554
|
-
const
|
|
555
|
-
let d =
|
|
556
|
-
return
|
|
557
|
-
id:
|
|
558
|
-
category:
|
|
559
|
-
category_guid:
|
|
550
|
+
return [s, ...o, r];
|
|
551
|
+
}, Ze = (t, n, s, o, r) => {
|
|
552
|
+
const c = t.filter((a) => a.is_income === s).map((a) => {
|
|
553
|
+
let d = a.totalMonthlyAmounts;
|
|
554
|
+
return r && (d = a.monthlyAmounts), {
|
|
555
|
+
id: a.guid,
|
|
556
|
+
category: a.name,
|
|
557
|
+
category_guid: a.guid,
|
|
560
558
|
isParent: !1,
|
|
561
|
-
top_level_category_guid:
|
|
562
|
-
total: d.reduce(
|
|
563
|
-
|
|
559
|
+
top_level_category_guid: a.parent_guid || a.guid,
|
|
560
|
+
total: d.reduce(Xe(o), 0),
|
|
561
|
+
monthlyAmounts: d.reduce(Ue, {})
|
|
564
562
|
};
|
|
565
563
|
});
|
|
566
|
-
if (
|
|
567
|
-
const
|
|
568
|
-
|
|
569
|
-
id: `sub-${
|
|
570
|
-
category:
|
|
571
|
-
category_guid:
|
|
564
|
+
if (r && r.is_income === s) {
|
|
565
|
+
const a = r.monthlyAmounts.reduce(Xe(o), 0);
|
|
566
|
+
a !== 0 && c.push({
|
|
567
|
+
id: `sub-${r.guid}`,
|
|
568
|
+
category: nt(n.category_general, r.name),
|
|
569
|
+
category_guid: r.guid,
|
|
572
570
|
isParent: !0,
|
|
573
|
-
top_level_category_guid:
|
|
574
|
-
total:
|
|
575
|
-
|
|
571
|
+
top_level_category_guid: r.guid,
|
|
572
|
+
total: a,
|
|
573
|
+
monthlyAmounts: r.monthlyAmounts.reduce(Ue, {})
|
|
576
574
|
});
|
|
577
575
|
}
|
|
578
|
-
return
|
|
579
|
-
},
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
576
|
+
return c;
|
|
577
|
+
}, Do = Et("div")({
|
|
578
|
+
display: "flex",
|
|
579
|
+
visibility: "hidden",
|
|
580
|
+
width: 0
|
|
581
|
+
});
|
|
582
|
+
function Io({
|
|
583
|
+
direction: t,
|
|
584
|
+
index: n,
|
|
585
|
+
sortingOrder: s,
|
|
586
|
+
disabled: o,
|
|
587
|
+
className: r,
|
|
588
|
+
field: c
|
|
589
|
+
}) {
|
|
590
|
+
const a = Yt(), d = jt();
|
|
591
|
+
let u = null;
|
|
592
|
+
const i = {};
|
|
593
|
+
if (t === "asc" ? u = d.slots.columnSortedAscendingIcon : t === "desc" ? u = d.slots.columnSortedDescendingIcon : (u = d.slots.columnUnsortedIcon ?? null, i.sortingOrder = s), !u) return null;
|
|
594
|
+
const m = a.current.getColumn(c)?.headerName ?? c;
|
|
595
|
+
let _ = "";
|
|
596
|
+
t === "asc" ? _ = ", sorted ascending" : t === "desc" && (_ = ", sorted descending");
|
|
597
|
+
const h = ["Total", "Category"].includes(m) ? "" : " category totals", p = `Sort by ${m}${h}${_}`, y = /* @__PURE__ */ e(u, { className: "MuiDataGrid-sortIcon", fontSize: "small", ...i }), T = /* @__PURE__ */ e(
|
|
598
|
+
Zt,
|
|
599
|
+
{
|
|
600
|
+
disabled: o,
|
|
601
|
+
size: "small",
|
|
602
|
+
tabIndex: -1,
|
|
603
|
+
...d.slotProps?.baseIconButton,
|
|
604
|
+
"aria-label": p,
|
|
605
|
+
className: `MuiDataGrid-sortButton${r ? ` ${r}` : ""}`,
|
|
606
|
+
title: p,
|
|
607
|
+
children: y
|
|
608
|
+
}
|
|
609
|
+
);
|
|
610
|
+
return /* @__PURE__ */ e(Do, { className: "MuiDataGrid-iconButtonContainer", children: n != null ? /* @__PURE__ */ e(Xt, { badgeContent: n, color: "default", overlap: "circular", children: T }) : T });
|
|
611
|
+
}
|
|
612
|
+
const Lo = g.memo(Io), Qe = ({
|
|
613
|
+
columns: t,
|
|
614
|
+
onRowClick: n,
|
|
615
|
+
parentCategory: s,
|
|
616
|
+
rows: o,
|
|
617
|
+
totalRow: r
|
|
585
618
|
}) => {
|
|
586
|
-
const
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
}, [s, c]), f = u.useMemo(() => {
|
|
590
|
-
let g = c;
|
|
591
|
-
return _ && (g = _.subCategories.filter(
|
|
592
|
-
(y) => y.monthlyAmounts.some((w) => w.amount !== 0)
|
|
593
|
-
)), Co(g, h, l, _);
|
|
594
|
-
}, [c, l, _, h]);
|
|
595
|
-
return /* @__PURE__ */ e(A, { sx: { height: t, width: "100%", overflowX: "auto", boxShadow: "none", ...r }, children: /* @__PURE__ */ e(
|
|
596
|
-
Bt,
|
|
619
|
+
const c = Z(), { onEvent: a } = $(), d = c.palette.mode === "light";
|
|
620
|
+
return /* @__PURE__ */ e(
|
|
621
|
+
Ut,
|
|
597
622
|
{
|
|
598
|
-
columns:
|
|
623
|
+
columns: t,
|
|
599
624
|
disableColumnFilter: !0,
|
|
600
625
|
disableColumnMenu: !0,
|
|
601
626
|
hideFooter: !0,
|
|
602
627
|
initialState: { sorting: { sortModel: [{ field: "category", sort: "asc" }] } },
|
|
603
|
-
onRowClick: (
|
|
604
|
-
|
|
605
|
-
...
|
|
606
|
-
listItem:
|
|
628
|
+
onRowClick: (u) => {
|
|
629
|
+
s || n?.(u.row.category_guid), a(w.TRENDS_CLICK_LIST_ITEM, {
|
|
630
|
+
...W,
|
|
631
|
+
listItem: Nt[u.row.category_guid]
|
|
607
632
|
});
|
|
608
633
|
},
|
|
634
|
+
pinnedRows: {
|
|
635
|
+
bottom: r ? [r] : []
|
|
636
|
+
},
|
|
609
637
|
rowHeight: 64,
|
|
610
|
-
rows:
|
|
638
|
+
rows: o,
|
|
611
639
|
slotProps: { baseIconButton: { color: "secondary", sx: { ml: 8 } } },
|
|
640
|
+
slots: { columnHeaderSortIcon: Lo },
|
|
612
641
|
sortingOrder: ["asc", "desc"],
|
|
613
642
|
sx: {
|
|
614
643
|
borderColor: "divider",
|
|
@@ -616,180 +645,241 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
616
645
|
borderStyle: "solid",
|
|
617
646
|
borderRadius: 2,
|
|
618
647
|
"& .MuiDataGrid-columnHeaders": {
|
|
619
|
-
bgcolor:
|
|
648
|
+
bgcolor: d ? "neutral.50" : "neutral.800",
|
|
620
649
|
borderBottom: "none"
|
|
621
650
|
},
|
|
622
651
|
"& .trends-table-header": {
|
|
623
|
-
bgcolor:
|
|
652
|
+
bgcolor: d ? "neutral.50" : "neutral.800"
|
|
624
653
|
}
|
|
625
654
|
}
|
|
626
655
|
}
|
|
627
|
-
)
|
|
628
|
-
},
|
|
656
|
+
);
|
|
657
|
+
}, yt = ({
|
|
658
|
+
selectedDateRange: t,
|
|
659
|
+
selectedCategory: n,
|
|
660
|
+
onClickRow: s,
|
|
661
|
+
height: o = "100%",
|
|
662
|
+
sx: r = {}
|
|
663
|
+
}) => {
|
|
664
|
+
const { trends: c } = R(), { trendsCategories: a } = q(), d = g.useMemo(() => vo(t.start, t.end), [t]), u = g.useMemo(() => wo(d, c), [d, c]), i = g.useMemo(() => {
|
|
665
|
+
if (n)
|
|
666
|
+
return a.find((h) => h.guid === n);
|
|
667
|
+
}, [n, a]), [f, m] = g.useMemo(() => {
|
|
668
|
+
let h = a;
|
|
669
|
+
return i && (h = i.subCategories.filter(
|
|
670
|
+
(p) => p.monthlyAmounts.some((y) => y.amount !== 0)
|
|
671
|
+
)), [
|
|
672
|
+
Ze(h, c, !0, d, i),
|
|
673
|
+
Ze(h, c, !1, d, i)
|
|
674
|
+
];
|
|
675
|
+
}, [a, d, i, c]), _ = {
|
|
676
|
+
id: "total",
|
|
677
|
+
category: c.table_column_total,
|
|
678
|
+
category_guid: "total",
|
|
679
|
+
isParent: !1,
|
|
680
|
+
top_level_category_guid: "total",
|
|
681
|
+
total: m.reduce((h, p) => h + p.total, 0),
|
|
682
|
+
monthlyAmounts: m.reduce(
|
|
683
|
+
(h, p) => (Object.entries(p.monthlyAmounts).forEach(([y, T]) => {
|
|
684
|
+
h[y] = (h[y] || 0) + T;
|
|
685
|
+
}), h),
|
|
686
|
+
{}
|
|
687
|
+
)
|
|
688
|
+
};
|
|
689
|
+
return /* @__PURE__ */ C(
|
|
690
|
+
S,
|
|
691
|
+
{
|
|
692
|
+
gap: 24,
|
|
693
|
+
sx: { height: o, width: "100%", overflowX: "auto", boxShadow: "none", ...r },
|
|
694
|
+
children: [
|
|
695
|
+
(!i || i && i.is_income) && /* @__PURE__ */ e(
|
|
696
|
+
Qe,
|
|
697
|
+
{
|
|
698
|
+
columns: u,
|
|
699
|
+
onRowClick: s,
|
|
700
|
+
parentCategory: i,
|
|
701
|
+
rows: f
|
|
702
|
+
}
|
|
703
|
+
),
|
|
704
|
+
(!i || i && !i.is_income) && /* @__PURE__ */ e(
|
|
705
|
+
Qe,
|
|
706
|
+
{
|
|
707
|
+
columns: u,
|
|
708
|
+
onRowClick: s,
|
|
709
|
+
parentCategory: i,
|
|
710
|
+
rows: m,
|
|
711
|
+
totalRow: _
|
|
712
|
+
}
|
|
713
|
+
)
|
|
714
|
+
]
|
|
715
|
+
}
|
|
716
|
+
);
|
|
717
|
+
}, Eo = {
|
|
629
718
|
title: "Transaction List"
|
|
630
|
-
},
|
|
631
|
-
categoryGuid:
|
|
632
|
-
dateRange:
|
|
633
|
-
isOpen:
|
|
634
|
-
onClose:
|
|
719
|
+
}, Mo = ({
|
|
720
|
+
categoryGuid: t,
|
|
721
|
+
dateRange: n,
|
|
722
|
+
isOpen: s,
|
|
723
|
+
onClose: o
|
|
635
724
|
}) => {
|
|
636
|
-
const { onEvent: r } =
|
|
637
|
-
() =>
|
|
638
|
-
[
|
|
725
|
+
const { onEvent: r } = $(), { selectedAccountGuids: c } = fe(), { common: a } = R(), { setFilter: d, sortedTransactions: u } = we(), [i, f] = g.useState(""), m = g.useMemo(
|
|
726
|
+
() => u.find((h) => h.guid === i),
|
|
727
|
+
[i, u]
|
|
639
728
|
);
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
accounts:
|
|
643
|
-
dateRange:
|
|
644
|
-
custom: (
|
|
645
|
-
showSplits: !!
|
|
729
|
+
g.useEffect(() => {
|
|
730
|
+
d({
|
|
731
|
+
accounts: c,
|
|
732
|
+
dateRange: n,
|
|
733
|
+
custom: (h) => t === "" || t === h.category_guid || t === h.top_level_category_guid,
|
|
734
|
+
showSplits: !!t
|
|
646
735
|
});
|
|
647
|
-
}, [
|
|
736
|
+
}, [c, t, n]), g.useEffect(() => r(w.TRENDS_VIEW_TRANSACTIONS), []);
|
|
648
737
|
const _ = () => {
|
|
649
|
-
|
|
738
|
+
f(""), o();
|
|
650
739
|
};
|
|
651
740
|
return /* @__PURE__ */ C(
|
|
652
|
-
|
|
741
|
+
Pe,
|
|
653
742
|
{
|
|
654
|
-
ariaLabelClose:
|
|
655
|
-
isOpen:
|
|
743
|
+
ariaLabelClose: a.close_aria,
|
|
744
|
+
isOpen: s,
|
|
656
745
|
onClose: _,
|
|
657
|
-
title:
|
|
746
|
+
title: Eo.title,
|
|
658
747
|
children: [
|
|
659
|
-
m && /* @__PURE__ */ e(
|
|
660
|
-
!m && /* @__PURE__ */ e(
|
|
748
|
+
m && /* @__PURE__ */ e(dt, { transaction: m }),
|
|
749
|
+
!m && /* @__PURE__ */ e(ct, { onClick: f })
|
|
661
750
|
]
|
|
662
751
|
}
|
|
663
752
|
);
|
|
664
|
-
},
|
|
665
|
-
const { onEvent:
|
|
666
|
-
categoriesLoaded:
|
|
667
|
-
loadCategories:
|
|
668
|
-
loadDateRangeCategoryTotals:
|
|
669
|
-
loadMonthlyCategoryTotals:
|
|
670
|
-
monthlyCategoryTotals:
|
|
671
|
-
getCategoryName:
|
|
672
|
-
} =
|
|
673
|
-
isTransactionDataLoaded:
|
|
674
|
-
loadTransactionData:
|
|
675
|
-
sortedTransactions:
|
|
676
|
-
} =
|
|
753
|
+
}, Ao = A(Mo), Ro = ({ onBackClick: t, onMenuClick: n, sx: s }) => {
|
|
754
|
+
const { onEvent: o } = $(), { isDesktop: r, isTablet: c, isMobile: a } = Q(), { isAccountDataLoaded: d, loadAccountData: u } = De(), {
|
|
755
|
+
categoriesLoaded: i,
|
|
756
|
+
loadCategories: f,
|
|
757
|
+
loadDateRangeCategoryTotals: m,
|
|
758
|
+
loadMonthlyCategoryTotals: _,
|
|
759
|
+
monthlyCategoryTotals: h,
|
|
760
|
+
getCategoryName: p
|
|
761
|
+
} = q(), {
|
|
762
|
+
isTransactionDataLoaded: y,
|
|
763
|
+
loadTransactionData: T,
|
|
764
|
+
sortedTransactions: N
|
|
765
|
+
} = we(), { selectedDateRange: x, setSelectedDateRange: L } = ye(), { isInitialized: M, selectedAccounts: E } = fe(), { trends: v } = R(), [K, ae] = g.useState(!1), [Y, J] = g.useState(!1), [P, V] = g.useState("Chart"), [O, ee] = g.useState(""), [Ce, ie] = g.useState(window.innerHeight), j = Ce - (a ? 315 : 345);
|
|
677
766
|
Ie({
|
|
678
767
|
widgetName: "TrendsFullWidget",
|
|
679
|
-
isLoaded:
|
|
680
|
-
}),
|
|
681
|
-
const D = () =>
|
|
682
|
-
return window.addEventListener("resize", D), d ||
|
|
683
|
-
}, []),
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
768
|
+
isLoaded: K
|
|
769
|
+
}), g.useEffect(() => {
|
|
770
|
+
const D = () => ie(window.innerHeight);
|
|
771
|
+
return window.addEventListener("resize", D), d || u().finally(), i || f().finally(), y || T().finally(), () => window.removeEventListener("resize", D);
|
|
772
|
+
}, []), g.useEffect(() => {
|
|
773
|
+
M && m(E, x.start, x.end).then(() => {
|
|
774
|
+
_(
|
|
775
|
+
E,
|
|
776
|
+
x.start,
|
|
777
|
+
x.end
|
|
689
778
|
);
|
|
690
779
|
}).finally(() => {
|
|
691
|
-
|
|
692
|
-
...
|
|
693
|
-
time_period: `${Se(
|
|
780
|
+
ae(!0), o(w.TRENDS_LOAD_WIDGET, {
|
|
781
|
+
...W,
|
|
782
|
+
time_period: `${Se(x.end, x.start)}M`
|
|
694
783
|
});
|
|
695
784
|
});
|
|
696
|
-
}, [
|
|
697
|
-
const
|
|
698
|
-
if (!
|
|
699
|
-
const D =
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
),
|
|
704
|
-
(
|
|
705
|
-
) :
|
|
785
|
+
}, [M, E, x]);
|
|
786
|
+
const ne = g.useMemo(() => {
|
|
787
|
+
if (!K) return { stackedDatasets: [], unstackedDatasets: [] };
|
|
788
|
+
const D = Gt(
|
|
789
|
+
h,
|
|
790
|
+
x.start,
|
|
791
|
+
x.end
|
|
792
|
+
), l = O.length ? D.filter(
|
|
793
|
+
(b) => b.top_level_category_guid === O || b.category_guid === O
|
|
794
|
+
) : Bt(D);
|
|
706
795
|
return {
|
|
707
|
-
stackedDatasets:
|
|
708
|
-
unstackedDatasets:
|
|
796
|
+
stackedDatasets: l.filter(Vt),
|
|
797
|
+
unstackedDatasets: l.filter(Pt)
|
|
709
798
|
};
|
|
710
|
-
}, [
|
|
711
|
-
|
|
712
|
-
},
|
|
713
|
-
const
|
|
714
|
-
|
|
715
|
-
time_period:
|
|
799
|
+
}, [h, O, x]), U = (D, l) => {
|
|
800
|
+
V(l ?? P), o(w.TRENDS_CLICK_TOGGLE_VIEW);
|
|
801
|
+
}, de = (D) => {
|
|
802
|
+
const l = et(D?.[0], 1), b = D?.[1], I = Se(b, l);
|
|
803
|
+
L({ start: l, end: b }), o(w.TRENDS_CLICK_TIME_WINDOW, {
|
|
804
|
+
time_period: I + "M"
|
|
716
805
|
});
|
|
717
|
-
},
|
|
718
|
-
|
|
719
|
-
},
|
|
720
|
-
|
|
721
|
-
},
|
|
722
|
-
|
|
723
|
-
},
|
|
724
|
-
|
|
725
|
-
}, ie = (D) => {
|
|
726
|
-
n(v.TRENDS_HOVER_AREA, { category: D });
|
|
806
|
+
}, B = () => {
|
|
807
|
+
o(w.TRENDS_CLICK_FILTER);
|
|
808
|
+
}, ue = (D) => {
|
|
809
|
+
ee(D);
|
|
810
|
+
}, se = (D) => {
|
|
811
|
+
ee(D), o(w.TRENDS_CLICK_LEGEND, { category: p(D) });
|
|
812
|
+
}, le = (D) => {
|
|
813
|
+
o(w.TRENDS_HOVER_LEGEND, { category: p(D) });
|
|
727
814
|
}, ce = (D) => {
|
|
728
|
-
|
|
815
|
+
o(w.TRENDS_HOVER_AREA, { category: D });
|
|
816
|
+
}, me = (D) => {
|
|
817
|
+
o(w.TRENDS_HOVER_POINT, { category: D });
|
|
729
818
|
};
|
|
730
|
-
return !
|
|
731
|
-
|
|
819
|
+
return !M || !K ? /* @__PURE__ */ e(Le, {}) : /* @__PURE__ */ C(
|
|
820
|
+
ut,
|
|
732
821
|
{
|
|
733
|
-
calendarActions: { onRangeChanged:
|
|
734
|
-
dateRange:
|
|
822
|
+
calendarActions: { onRangeChanged: de },
|
|
823
|
+
dateRange: x,
|
|
735
824
|
dateRangeVariant: "timeframebuttons",
|
|
736
|
-
onAccountsFilterClick:
|
|
737
|
-
onBackClick:
|
|
825
|
+
onAccountsFilterClick: B,
|
|
826
|
+
onBackClick: t,
|
|
827
|
+
onMenuClick: n,
|
|
738
828
|
sx: s,
|
|
739
|
-
title:
|
|
829
|
+
title: v.title,
|
|
740
830
|
children: [
|
|
741
831
|
/* @__PURE__ */ C(
|
|
742
|
-
|
|
832
|
+
S,
|
|
743
833
|
{
|
|
744
834
|
sx: {
|
|
745
835
|
// eslint-disable-next-line no-nested-ternary
|
|
746
|
-
px:
|
|
836
|
+
px: r ? 48 : c ? 24 : 12
|
|
747
837
|
},
|
|
748
838
|
children: [
|
|
749
839
|
/* @__PURE__ */ C(
|
|
750
|
-
|
|
840
|
+
S,
|
|
751
841
|
{
|
|
752
842
|
flexDirection: "row",
|
|
753
843
|
justifyContent: "space-between",
|
|
754
|
-
sx: { pb:
|
|
844
|
+
sx: { pb: a ? 12 : 24, pt: a ? 24 : 48 },
|
|
755
845
|
children: [
|
|
756
846
|
/* @__PURE__ */ e(
|
|
757
|
-
|
|
847
|
+
ft,
|
|
758
848
|
{
|
|
759
849
|
selectedCategoryGuid: O,
|
|
760
|
-
selectedDateRange:
|
|
850
|
+
selectedDateRange: x
|
|
761
851
|
}
|
|
762
852
|
),
|
|
763
|
-
/* @__PURE__ */ e(
|
|
853
|
+
/* @__PURE__ */ e(pt, { onTabChange: U, selectedTab: P })
|
|
764
854
|
]
|
|
765
855
|
}
|
|
766
856
|
),
|
|
767
|
-
/* @__PURE__ */ C(
|
|
768
|
-
/* @__PURE__ */ e(
|
|
769
|
-
/* @__PURE__ */ e(
|
|
770
|
-
|
|
857
|
+
/* @__PURE__ */ C(S, { alignItems: "center", flexDirection: "row", width: "100%", children: [
|
|
858
|
+
/* @__PURE__ */ e(H, { flexGrow: 1, children: O && /* @__PURE__ */ C(Te, { onClick: () => ee(""), sx: { p: 0, pr: 5 }, children: [
|
|
859
|
+
/* @__PURE__ */ e(He, { name: "arrow_back" }),
|
|
860
|
+
v.all_categories
|
|
771
861
|
] }) }),
|
|
772
|
-
/* @__PURE__ */ e(
|
|
862
|
+
/* @__PURE__ */ e(Te, { onClick: () => J(!0), sx: { px: 5 }, children: `${v.view_transactions} (${N.length})` })
|
|
773
863
|
] }),
|
|
774
|
-
/* @__PURE__ */ C(
|
|
775
|
-
|
|
776
|
-
|
|
864
|
+
/* @__PURE__ */ C(H, { children: [
|
|
865
|
+
P === "Chart" && /* @__PURE__ */ e(
|
|
866
|
+
So,
|
|
777
867
|
{
|
|
778
|
-
availableHeight:
|
|
779
|
-
onClickLegend:
|
|
780
|
-
onHoverArea:
|
|
781
|
-
onHoverLegend:
|
|
782
|
-
onHoverPoint:
|
|
783
|
-
stackedDatasets:
|
|
784
|
-
unstackedDatasets:
|
|
868
|
+
availableHeight: j,
|
|
869
|
+
onClickLegend: se,
|
|
870
|
+
onHoverArea: ce,
|
|
871
|
+
onHoverLegend: le,
|
|
872
|
+
onHoverPoint: me,
|
|
873
|
+
stackedDatasets: ne.stackedDatasets,
|
|
874
|
+
unstackedDatasets: ne.unstackedDatasets
|
|
785
875
|
}
|
|
786
876
|
),
|
|
787
|
-
|
|
788
|
-
|
|
877
|
+
P === "Table" && /* @__PURE__ */ e(
|
|
878
|
+
yt,
|
|
789
879
|
{
|
|
790
|
-
onClickRow:
|
|
880
|
+
onClickRow: ue,
|
|
791
881
|
selectedCategory: O,
|
|
792
|
-
selectedDateRange:
|
|
882
|
+
selectedDateRange: x
|
|
793
883
|
}
|
|
794
884
|
)
|
|
795
885
|
] })
|
|
@@ -797,27 +887,27 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
797
887
|
}
|
|
798
888
|
),
|
|
799
889
|
/* @__PURE__ */ e(
|
|
800
|
-
|
|
890
|
+
Ao,
|
|
801
891
|
{
|
|
802
892
|
categoryGuid: O,
|
|
803
|
-
dateRange:
|
|
804
|
-
isOpen:
|
|
805
|
-
onClose: () =>
|
|
893
|
+
dateRange: x,
|
|
894
|
+
isOpen: Y,
|
|
895
|
+
onClose: () => J(!1)
|
|
806
896
|
}
|
|
807
897
|
)
|
|
808
898
|
]
|
|
809
899
|
}
|
|
810
900
|
);
|
|
811
|
-
},
|
|
812
|
-
const { monthlyCategoryTotals:
|
|
901
|
+
}, rs = A(Ro), ko = () => {
|
|
902
|
+
const { monthlyCategoryTotals: t } = q(), { trends: n } = R(), s = Z(), { availableHeight: o = 300 } = st(), r = g.useMemo(() => zt(t), [t]);
|
|
813
903
|
return /* @__PURE__ */ e(
|
|
814
|
-
|
|
904
|
+
Ve,
|
|
815
905
|
{
|
|
816
906
|
baseline: "min",
|
|
817
|
-
colors: [
|
|
907
|
+
colors: [s.palette.primary.main],
|
|
818
908
|
datasets: [r],
|
|
819
|
-
height:
|
|
820
|
-
labels: [
|
|
909
|
+
height: o,
|
|
910
|
+
labels: [n.spending_label],
|
|
821
911
|
showArea: !0,
|
|
822
912
|
showAverage: !0,
|
|
823
913
|
showLegend: !0,
|
|
@@ -826,41 +916,41 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
826
916
|
valueFormatterString: "0,0"
|
|
827
917
|
}
|
|
828
918
|
);
|
|
829
|
-
},
|
|
830
|
-
const { isAccountDataLoaded:
|
|
831
|
-
return
|
|
832
|
-
|
|
919
|
+
}, Ho = A(ko), No = ({ onPrimaryCtaClick: t, sx: n }) => {
|
|
920
|
+
const { isAccountDataLoaded: s, loadAccountData: o } = De(), { loadMonthlyCategoryTotals: r, monthlyTotalsLoaded: c } = q(), { isInitialized: a } = Be(), { trends: d } = R(), { selectedAccounts: u } = fe();
|
|
921
|
+
return g.useEffect(() => {
|
|
922
|
+
s || o().finally();
|
|
833
923
|
}, []), Ie({
|
|
834
924
|
widgetName: "TrendsMiniWidget",
|
|
835
|
-
isLoaded:
|
|
836
|
-
}),
|
|
837
|
-
|
|
838
|
-
}, [
|
|
839
|
-
|
|
925
|
+
isLoaded: c
|
|
926
|
+
}), g.useEffect(() => {
|
|
927
|
+
a && s && r(u).finally();
|
|
928
|
+
}, [s, a, u]), !s || !a || !c ? /* @__PURE__ */ e(Le, {}) : /* @__PURE__ */ e(
|
|
929
|
+
Qt,
|
|
840
930
|
{
|
|
841
931
|
contentStyles: { height: "calc(100% - 72px)", minHeight: 300, ":last-child": { pb: 0 } },
|
|
842
|
-
onPrimaryCtaClick:
|
|
843
|
-
primaryCtaLabel:
|
|
844
|
-
subTitle:
|
|
845
|
-
sx: { height: "100%", ...
|
|
846
|
-
title:
|
|
847
|
-
children: /* @__PURE__ */ e(
|
|
932
|
+
onPrimaryCtaClick: t,
|
|
933
|
+
primaryCtaLabel: d.primary_cta,
|
|
934
|
+
subTitle: d.sub_title,
|
|
935
|
+
sx: { height: "100%", ...n },
|
|
936
|
+
title: d.mini_title,
|
|
937
|
+
children: /* @__PURE__ */ e(Ho, {})
|
|
848
938
|
}
|
|
849
939
|
);
|
|
850
|
-
},
|
|
851
|
-
title:
|
|
852
|
-
totalAmount:
|
|
853
|
-
transactionType:
|
|
854
|
-
percentage:
|
|
940
|
+
}, as = A(No), Wo = 70, qe = ({
|
|
941
|
+
title: t,
|
|
942
|
+
totalAmount: n,
|
|
943
|
+
transactionType: s,
|
|
944
|
+
percentage: o,
|
|
855
945
|
secondaryLabel: r,
|
|
856
|
-
shouldDisplayPercentage:
|
|
946
|
+
shouldDisplayPercentage: c
|
|
857
947
|
}) => {
|
|
858
|
-
const { availableWidth:
|
|
948
|
+
const { availableWidth: a } = st(), d = g.useRef(null), u = g.useRef(null), i = Wt(Number(Math.abs(o)), {
|
|
859
949
|
style: "percent",
|
|
860
950
|
minimumIntegerDigits: 1
|
|
861
|
-
}),
|
|
951
|
+
}), f = a === 288 && re(n, "0,0.00").length > 10 ? re(n, "0,0") : re(n, "0,0.00"), m = s === "spending" ? o > 0 : o >= 0, _ = s === "spending" ? "error.main" : "success.main", h = s === "spending" ? "success.main" : "text.secondary", p = d?.current, y = u?.current, T = p && y ? p.scrollWidth > y.clientWidth - Wo : !1;
|
|
862
952
|
return /* @__PURE__ */ C(
|
|
863
|
-
|
|
953
|
+
S,
|
|
864
954
|
{
|
|
865
955
|
sx: {
|
|
866
956
|
border: 1,
|
|
@@ -873,7 +963,7 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
873
963
|
},
|
|
874
964
|
children: [
|
|
875
965
|
/* @__PURE__ */ C(
|
|
876
|
-
|
|
966
|
+
S,
|
|
877
967
|
{
|
|
878
968
|
sx: {
|
|
879
969
|
alignItems: "center",
|
|
@@ -881,18 +971,18 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
881
971
|
justifyContent: "space-between"
|
|
882
972
|
},
|
|
883
973
|
children: [
|
|
884
|
-
/* @__PURE__ */ e(
|
|
885
|
-
|
|
886
|
-
m ? /* @__PURE__ */ e(
|
|
974
|
+
/* @__PURE__ */ e(pe, { color: "text.secondary", variant: "caption", children: t }),
|
|
975
|
+
c && /* @__PURE__ */ C(S, { sx: { alignItems: "center", flexDirection: "row", gap: 4 }, children: [
|
|
976
|
+
m ? /* @__PURE__ */ e(Jt, { size: 20, sx: { color: _ } }) : /* @__PURE__ */ e(eo, { size: 20, sx: { color: h } }),
|
|
887
977
|
/* @__PURE__ */ e(
|
|
888
|
-
|
|
978
|
+
pe,
|
|
889
979
|
{
|
|
890
980
|
sx: {
|
|
891
|
-
color: m ? _ :
|
|
981
|
+
color: m ? _ : h,
|
|
892
982
|
fontWeight: 600
|
|
893
983
|
},
|
|
894
984
|
variant: "body2",
|
|
895
|
-
children:
|
|
985
|
+
children: i
|
|
896
986
|
}
|
|
897
987
|
)
|
|
898
988
|
] })
|
|
@@ -900,9 +990,9 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
900
990
|
}
|
|
901
991
|
),
|
|
902
992
|
/* @__PURE__ */ C(
|
|
903
|
-
|
|
993
|
+
S,
|
|
904
994
|
{
|
|
905
|
-
ref:
|
|
995
|
+
ref: u,
|
|
906
996
|
sx: {
|
|
907
997
|
alignItems: "center",
|
|
908
998
|
flexDirection: "row",
|
|
@@ -910,17 +1000,17 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
910
1000
|
},
|
|
911
1001
|
children: [
|
|
912
1002
|
/* @__PURE__ */ e(
|
|
913
|
-
|
|
1003
|
+
H,
|
|
914
1004
|
{
|
|
915
|
-
ref:
|
|
1005
|
+
ref: d,
|
|
916
1006
|
sx: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" },
|
|
917
|
-
children: /* @__PURE__ */ e(
|
|
1007
|
+
children: /* @__PURE__ */ e(Ge, { children: f })
|
|
918
1008
|
}
|
|
919
1009
|
),
|
|
920
|
-
|
|
921
|
-
|
|
1010
|
+
c && a >= 450 && !T && /* @__PURE__ */ e(
|
|
1011
|
+
pe,
|
|
922
1012
|
{
|
|
923
|
-
color: m ? _ :
|
|
1013
|
+
color: m ? _ : h,
|
|
924
1014
|
variant: "caption",
|
|
925
1015
|
children: r
|
|
926
1016
|
}
|
|
@@ -931,55 +1021,55 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
931
1021
|
]
|
|
932
1022
|
}
|
|
933
1023
|
);
|
|
934
|
-
},
|
|
935
|
-
const { trends:
|
|
936
|
-
return /* @__PURE__ */ C(
|
|
937
|
-
/* @__PURE__ */ e(
|
|
938
|
-
/* @__PURE__ */ C(
|
|
939
|
-
/* @__PURE__ */ e(
|
|
940
|
-
/* @__PURE__ */ e(
|
|
1024
|
+
}, Oo = A(() => {
|
|
1025
|
+
const { trends: t } = R();
|
|
1026
|
+
return /* @__PURE__ */ C(S, { sx: { alignItems: "start", flexDirection: "row", gap: 12 }, children: [
|
|
1027
|
+
/* @__PURE__ */ e(to, { size: 32 }),
|
|
1028
|
+
/* @__PURE__ */ C(S, { children: [
|
|
1029
|
+
/* @__PURE__ */ e(pe, { fontWeight: 600, variant: "body1", children: t.zero_state_content_header }),
|
|
1030
|
+
/* @__PURE__ */ e(pe, { color: "text.secondary", variant: "subtitle2", children: t.zero_state_content_description })
|
|
941
1031
|
] })
|
|
942
1032
|
] });
|
|
943
|
-
}),
|
|
944
|
-
const { isAccountDataLoaded:
|
|
945
|
-
|
|
946
|
-
|
|
1033
|
+
}), is = A(({ onCtaClick: t }) => {
|
|
1034
|
+
const { isAccountDataLoaded: n, loadAccountData: s, visibleAccounts: o } = De();
|
|
1035
|
+
g.useEffect(() => {
|
|
1036
|
+
n || s().finally();
|
|
947
1037
|
}, []);
|
|
948
|
-
const { onEvent: r } =
|
|
949
|
-
start:
|
|
1038
|
+
const { onEvent: r } = $(), { monthlyCategoryTotals: c, loadMonthlyCategoryTotals: a, monthlyTotalsLoaded: d } = q(), u = {
|
|
1039
|
+
start: qt(/* @__PURE__ */ new Date(), 1),
|
|
950
1040
|
end: /* @__PURE__ */ new Date()
|
|
951
|
-
}, { trends:
|
|
1041
|
+
}, { trends: i } = R(), { selectedAccounts: f, isInitialized: m } = fe();
|
|
952
1042
|
Ie({
|
|
953
1043
|
widgetName: "TrendsMicroWidget",
|
|
954
|
-
isLoaded:
|
|
955
|
-
}),
|
|
956
|
-
m &&
|
|
957
|
-
r(
|
|
958
|
-
state:
|
|
1044
|
+
isLoaded: d
|
|
1045
|
+
}), g.useEffect(() => {
|
|
1046
|
+
m && a(f, u.start).then(() => {
|
|
1047
|
+
r(w.TRENDS_LOAD_WIDGET, {
|
|
1048
|
+
state: o?.length ? "default" : "zeroState"
|
|
959
1049
|
});
|
|
960
1050
|
});
|
|
961
|
-
}, [m,
|
|
962
|
-
const { spendingData: _, incomeData:
|
|
1051
|
+
}, [m, f]);
|
|
1052
|
+
const { spendingData: _, incomeData: h } = g.useMemo(
|
|
963
1053
|
() => ({
|
|
964
|
-
spendingData:
|
|
965
|
-
incomeData:
|
|
1054
|
+
spendingData: it(c, u),
|
|
1055
|
+
incomeData: at(c, u)
|
|
966
1056
|
}),
|
|
967
|
-
[
|
|
968
|
-
), [
|
|
1057
|
+
[c, u]
|
|
1058
|
+
), [p, y] = _, [T, N] = h, x = Ye(y.y, p.y), L = Ye(N.y, T.y), M = m && !o?.length, E = () => {
|
|
969
1059
|
r(
|
|
970
|
-
|
|
971
|
-
),
|
|
1060
|
+
M ? w.TRENDS_CLICK_GET_STARTED : w.TRENDS_CLICK_VIEW_MORE
|
|
1061
|
+
), t();
|
|
972
1062
|
};
|
|
973
|
-
return !
|
|
974
|
-
|
|
1063
|
+
return !d || !m ? /* @__PURE__ */ e(Le, {}) : /* @__PURE__ */ e(
|
|
1064
|
+
ao,
|
|
975
1065
|
{
|
|
976
1066
|
className: "mx-trends-microwidget",
|
|
977
|
-
ctaLabel:
|
|
978
|
-
onCTAClick:
|
|
979
|
-
subHeader:
|
|
980
|
-
title:
|
|
981
|
-
children:
|
|
982
|
-
|
|
1067
|
+
ctaLabel: i.micro_primary_cta_label,
|
|
1068
|
+
onCTAClick: E,
|
|
1069
|
+
subHeader: M ? void 0 : i.micro_subheader,
|
|
1070
|
+
title: i.title,
|
|
1071
|
+
children: M ? /* @__PURE__ */ e(Oo, {}) : /* @__PURE__ */ C(
|
|
1072
|
+
S,
|
|
983
1073
|
{
|
|
984
1074
|
sx: {
|
|
985
1075
|
alignItems: "stretch",
|
|
@@ -988,24 +1078,24 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
988
1078
|
},
|
|
989
1079
|
children: [
|
|
990
1080
|
/* @__PURE__ */ e(
|
|
991
|
-
|
|
1081
|
+
qe,
|
|
992
1082
|
{
|
|
993
|
-
percentage:
|
|
994
|
-
secondaryLabel:
|
|
995
|
-
shouldDisplayPercentage: y.y !== 0 &&
|
|
996
|
-
title:
|
|
1083
|
+
percentage: x,
|
|
1084
|
+
secondaryLabel: i.micro_secondary_label,
|
|
1085
|
+
shouldDisplayPercentage: y.y !== 0 && p.y !== 0,
|
|
1086
|
+
title: i.spending_label,
|
|
997
1087
|
totalAmount: y.y,
|
|
998
1088
|
transactionType: "spending"
|
|
999
1089
|
}
|
|
1000
1090
|
),
|
|
1001
1091
|
/* @__PURE__ */ e(
|
|
1002
|
-
|
|
1092
|
+
qe,
|
|
1003
1093
|
{
|
|
1004
|
-
percentage:
|
|
1005
|
-
secondaryLabel:
|
|
1006
|
-
shouldDisplayPercentage:
|
|
1007
|
-
title:
|
|
1008
|
-
totalAmount:
|
|
1094
|
+
percentage: L,
|
|
1095
|
+
secondaryLabel: i.micro_secondary_label,
|
|
1096
|
+
shouldDisplayPercentage: N.y !== 0 && T.y !== 0,
|
|
1097
|
+
title: i.income_label,
|
|
1098
|
+
totalAmount: N.y,
|
|
1009
1099
|
transactionType: "income"
|
|
1010
1100
|
}
|
|
1011
1101
|
)
|
|
@@ -1014,21 +1104,21 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
1014
1104
|
)
|
|
1015
1105
|
}
|
|
1016
1106
|
);
|
|
1017
|
-
}),
|
|
1018
|
-
({ isExpanded:
|
|
1019
|
-
const
|
|
1020
|
-
return /* @__PURE__ */ e(
|
|
1021
|
-
|
|
1107
|
+
}), Go = A(
|
|
1108
|
+
({ isExpanded: t, onClick: n }) => {
|
|
1109
|
+
const s = Z();
|
|
1110
|
+
return /* @__PURE__ */ e(mt, { children: /* @__PURE__ */ e(lo, { onClick: n, sx: { justifyContent: "center" }, children: /* @__PURE__ */ C(
|
|
1111
|
+
S,
|
|
1022
1112
|
{
|
|
1023
|
-
sx: { color:
|
|
1113
|
+
sx: { color: s.palette.primary.main, flexDirection: "row", alignItems: "center" },
|
|
1024
1114
|
children: [
|
|
1025
|
-
/* @__PURE__ */ e(
|
|
1026
|
-
/* @__PURE__ */ e(
|
|
1027
|
-
|
|
1115
|
+
/* @__PURE__ */ e(ht, { children: /* @__PURE__ */ e(F, { bold: !0, variant: "body2", children: t ? "View less" : "View more" }) }),
|
|
1116
|
+
/* @__PURE__ */ e(co, { sx: { color: s.palette.primary.main }, children: t ? /* @__PURE__ */ e(oo, {}) : /* @__PURE__ */ e(
|
|
1117
|
+
no,
|
|
1028
1118
|
{
|
|
1029
1119
|
sx: {
|
|
1030
1120
|
transition: "transform 0.3s ease-in-out",
|
|
1031
|
-
transform:
|
|
1121
|
+
transform: t ? "rotate(180deg)" : "rotate(0deg)"
|
|
1032
1122
|
}
|
|
1033
1123
|
}
|
|
1034
1124
|
) })
|
|
@@ -1036,128 +1126,139 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
1036
1126
|
}
|
|
1037
1127
|
) }) });
|
|
1038
1128
|
}
|
|
1039
|
-
),
|
|
1129
|
+
), Je = A(
|
|
1040
1130
|
({
|
|
1041
|
-
totalAmount:
|
|
1042
|
-
guid:
|
|
1043
|
-
name:
|
|
1044
|
-
transactions:
|
|
1131
|
+
totalAmount: t,
|
|
1132
|
+
guid: n,
|
|
1133
|
+
name: s,
|
|
1134
|
+
transactions: o,
|
|
1045
1135
|
onClick: r,
|
|
1046
|
-
isLastItem:
|
|
1047
|
-
showDivider:
|
|
1136
|
+
isLastItem: c = !1,
|
|
1137
|
+
showDivider: a = !0
|
|
1048
1138
|
}) => {
|
|
1049
|
-
const { trends:
|
|
1050
|
-
r?.(),
|
|
1051
|
-
...
|
|
1052
|
-
listItem:
|
|
1139
|
+
const { trends: d } = R(), { onEvent: u } = $(), i = Z(), f = `${o.length} ${o.length === 1 ? d.transaction : d.transactions}`, m = () => {
|
|
1140
|
+
r?.(), u(w.TRENDS_CLICK_LIST_ITEM, {
|
|
1141
|
+
...W,
|
|
1142
|
+
listItem: s
|
|
1053
1143
|
});
|
|
1054
1144
|
};
|
|
1055
|
-
return /* @__PURE__ */ C(
|
|
1145
|
+
return /* @__PURE__ */ C(g.Fragment, { children: [
|
|
1056
1146
|
/* @__PURE__ */ e(
|
|
1057
|
-
|
|
1147
|
+
uo,
|
|
1058
1148
|
{
|
|
1059
|
-
leftIcon:
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1149
|
+
leftIcon: n ? /* @__PURE__ */ e(
|
|
1150
|
+
ve,
|
|
1151
|
+
{
|
|
1152
|
+
categoryGuid: n,
|
|
1153
|
+
sx: {
|
|
1154
|
+
bgcolor: Mt(Oe(n, i), 0.15),
|
|
1155
|
+
border: `1px solid ${Oe(n, i)}`,
|
|
1156
|
+
color: "text.primary"
|
|
1157
|
+
}
|
|
1158
|
+
}
|
|
1159
|
+
) : void 0,
|
|
1160
|
+
onClick: m,
|
|
1161
|
+
rightContent: re(Math.abs(t), "0,0.00"),
|
|
1162
|
+
rightIcon: r ? /* @__PURE__ */ e(so, {}) : void 0,
|
|
1163
|
+
subtitle: f,
|
|
1164
|
+
title: s
|
|
1065
1165
|
}
|
|
1066
1166
|
),
|
|
1067
|
-
|
|
1068
|
-
] },
|
|
1167
|
+
a && /* @__PURE__ */ e(Ne, { component: "li", sx: { ml: c ? 24 : 68 } })
|
|
1168
|
+
] }, n);
|
|
1069
1169
|
}
|
|
1070
|
-
),
|
|
1071
|
-
({ availableHeight:
|
|
1072
|
-
const { collapsedCategories:
|
|
1073
|
-
|
|
1074
|
-
const
|
|
1075
|
-
|
|
1076
|
-
}, [
|
|
1170
|
+
), Bo = A(
|
|
1171
|
+
({ availableHeight: t = 0, onCategoryClick: n }) => {
|
|
1172
|
+
const { collapsedCategories: s, visibleCategories: o, setVisibleListLength: r } = ye(), { isLargeDesktop: c, isDesktop: a } = Q(), { trends: d } = R(), { onEvent: u } = $(), [i, f] = g.useState(!1), m = a || c;
|
|
1173
|
+
g.useEffect(() => {
|
|
1174
|
+
const p = Math.floor(t / 64) - 1, y = o.length + s.length;
|
|
1175
|
+
p !== o.length && (r(m ? Math.max(p, 5) : 5), f(p >= y));
|
|
1176
|
+
}, [t]);
|
|
1077
1177
|
const _ = () => {
|
|
1078
|
-
|
|
1079
|
-
...
|
|
1178
|
+
f(!i), u(w.TRENDS_CLICK_VIEW_MORE, {
|
|
1179
|
+
...W
|
|
1080
1180
|
});
|
|
1081
|
-
},
|
|
1082
|
-
return /* @__PURE__ */
|
|
1083
|
-
/* @__PURE__ */ e(
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1181
|
+
}, h = o.length + (i ? s.length : 0);
|
|
1182
|
+
return /* @__PURE__ */ C(S, { sx: { width: "100%" }, children: [
|
|
1183
|
+
/* @__PURE__ */ e(S, { sx: { pb: 4, pt: 16, px: 16 }, children: /* @__PURE__ */ e(Ge, { children: d.categories }) }),
|
|
1184
|
+
/* @__PURE__ */ C(We, { children: [
|
|
1185
|
+
o.map((p, y) => /* @__PURE__ */ e(
|
|
1186
|
+
Je,
|
|
1187
|
+
{
|
|
1188
|
+
...p,
|
|
1189
|
+
isLastItem: y === h - 1,
|
|
1190
|
+
onClick: p.transactions.length > 0 ? () => n(p) : void 0,
|
|
1191
|
+
showDivider: !0
|
|
1192
|
+
},
|
|
1193
|
+
p.guid
|
|
1194
|
+
)),
|
|
1195
|
+
/* @__PURE__ */ e(
|
|
1196
|
+
io,
|
|
1197
|
+
{
|
|
1198
|
+
component: "li",
|
|
1199
|
+
in: i,
|
|
1200
|
+
sx: { "&.MuiCollapse-root .MuiListItemButton-root": { paddingLeft: 24 } },
|
|
1201
|
+
children: /* @__PURE__ */ e(We, { children: s.map((p, y) => {
|
|
1202
|
+
const T = o.length + y;
|
|
1203
|
+
return /* @__PURE__ */ e(
|
|
1204
|
+
Je,
|
|
1205
|
+
{
|
|
1206
|
+
...p,
|
|
1207
|
+
isLastItem: T === h - 1,
|
|
1208
|
+
onClick: p.transactions.length > 0 ? () => n(p) : void 0,
|
|
1209
|
+
showDivider: !0
|
|
1210
|
+
},
|
|
1211
|
+
p.guid
|
|
1212
|
+
);
|
|
1213
|
+
}) })
|
|
1214
|
+
}
|
|
1215
|
+
),
|
|
1216
|
+
s.length > 0 && /* @__PURE__ */ e(Go, { isExpanded: i, onClick: _ })
|
|
1217
|
+
] })
|
|
1218
|
+
] });
|
|
1116
1219
|
}
|
|
1117
|
-
),
|
|
1118
|
-
const { onEvent:
|
|
1119
|
-
|
|
1120
|
-
},
|
|
1121
|
-
return /* @__PURE__ */ e(
|
|
1122
|
-
|
|
1220
|
+
), Po = ({ beats: t, onInsightCardClick: n }) => {
|
|
1221
|
+
const { onEvent: s } = $(), { isMobile: o, isDesktop: r, isLargeDesktop: c } = Q(), { beatStore: a, endpoint: d, sessionToken: u } = Be(), i = r || c, f = i || o ? 1 : 2, m = () => null, _ = (T) => {
|
|
1222
|
+
n?.(T), s(w.TRENDS_CLICK_INSIGHT, W);
|
|
1223
|
+
}, h = i ? 200 : 170, p = i ? 170 : 124, y = t.length > 0 ? h : p;
|
|
1224
|
+
return /* @__PURE__ */ e(mo, { sx: { height: y }, children: /* @__PURE__ */ e(
|
|
1225
|
+
Kt,
|
|
1123
1226
|
{
|
|
1124
|
-
areBeatsLoading:
|
|
1125
|
-
beats:
|
|
1126
|
-
|
|
1127
|
-
|
|
1227
|
+
areBeatsLoading: a.isLoading,
|
|
1228
|
+
beats: t,
|
|
1229
|
+
cardStyle: "border",
|
|
1230
|
+
endpoint: d,
|
|
1231
|
+
headerSx: { p: 0 },
|
|
1128
1232
|
logOutUser: m,
|
|
1129
1233
|
onCardClick: _,
|
|
1130
|
-
showBorder: !0,
|
|
1131
|
-
showCTAColocatedWithText: !1,
|
|
1132
1234
|
showCarouselControls: !0,
|
|
1133
|
-
showHeader:
|
|
1235
|
+
showHeader: i,
|
|
1134
1236
|
showIcon: !0,
|
|
1135
1237
|
showWithMargin: !1,
|
|
1136
|
-
token:
|
|
1238
|
+
token: u,
|
|
1137
1239
|
userHasFullInsightFeedBeats: !1,
|
|
1138
|
-
|
|
1139
|
-
visibleCardsCount: p
|
|
1240
|
+
visibleCardsCount: f
|
|
1140
1241
|
}
|
|
1141
1242
|
) });
|
|
1142
|
-
},
|
|
1143
|
-
const { onEvent:
|
|
1144
|
-
categoryDetailsChartData: { monthlyAmounts:
|
|
1145
|
-
} =
|
|
1146
|
-
return /* @__PURE__ */ e(
|
|
1147
|
-
|
|
1243
|
+
}, Vo = A(Po), zo = A(({ chartLabel: t, chartColor: n }) => {
|
|
1244
|
+
const { onEvent: s } = $(), {
|
|
1245
|
+
categoryDetailsChartData: { monthlyAmounts: o, tooltipLabels: r }
|
|
1246
|
+
} = ye();
|
|
1247
|
+
return /* @__PURE__ */ e(S, { sx: { pt: 12, width: "100%" }, children: /* @__PURE__ */ e(
|
|
1248
|
+
Ve,
|
|
1148
1249
|
{
|
|
1149
1250
|
baseline: "min",
|
|
1150
|
-
colors: [
|
|
1251
|
+
colors: [n],
|
|
1151
1252
|
curveType: "bump",
|
|
1152
1253
|
customTooltipLabels: r,
|
|
1153
|
-
datasets: [
|
|
1254
|
+
datasets: [o],
|
|
1154
1255
|
height: 265,
|
|
1155
|
-
labels: [
|
|
1256
|
+
labels: [t],
|
|
1156
1257
|
markStyles: () => ({
|
|
1157
|
-
stroke:
|
|
1258
|
+
stroke: n
|
|
1158
1259
|
}),
|
|
1159
1260
|
onItemClick: () => {
|
|
1160
|
-
|
|
1261
|
+
s(w.TRENDS_CLICK_CHART, W);
|
|
1161
1262
|
},
|
|
1162
1263
|
showArea: !0,
|
|
1163
1264
|
showAverage: !0,
|
|
@@ -1172,100 +1273,92 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
1172
1273
|
valueFormatterString: "0,0"
|
|
1173
1274
|
}
|
|
1174
1275
|
) });
|
|
1175
|
-
}),
|
|
1176
|
-
const
|
|
1177
|
-
if (!
|
|
1276
|
+
}), Fo = A(() => {
|
|
1277
|
+
const t = Z(), { is_mobile_webview: n } = rt(), { isDesktop: s, isSmallTablet: o, isTablet: r } = Q(), { common: c, trends: a } = R(), { selectedCategoryData: d, selectedDateRangeMonthRange: u } = ye(), { sortedTransactions: i } = we(), [f, m] = g.useState(null);
|
|
1278
|
+
if (!d)
|
|
1178
1279
|
return null;
|
|
1179
|
-
const { guid:
|
|
1180
|
-
() =>
|
|
1181
|
-
[
|
|
1182
|
-
),
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
{
|
|
1188
|
-
ariaLabelClose: c.close_category_details,
|
|
1189
|
-
isOpen: !0,
|
|
1190
|
-
onClose: K,
|
|
1191
|
-
shouldShowHeaderShadow: !0,
|
|
1192
|
-
title: M,
|
|
1193
|
-
children: [
|
|
1194
|
-
/* @__PURE__ */ C(x, { sx: { alignItems: "center", height: "100%" }, children: [
|
|
1195
|
-
/* @__PURE__ */ C(oo, { sx: { borderRadius: 0, pb: 4, pt: 16, width: "100%" }, children: [
|
|
1196
|
-
/* @__PURE__ */ e(
|
|
1197
|
-
tt,
|
|
1198
|
-
{
|
|
1199
|
-
leftIcon: /* @__PURE__ */ e(we, { categoryGuid: g }),
|
|
1200
|
-
rightContent: oe(Math.abs(b), "0,0.00"),
|
|
1201
|
-
subtitle: p,
|
|
1202
|
-
title: y
|
|
1203
|
-
}
|
|
1204
|
-
),
|
|
1205
|
-
/* @__PURE__ */ e(Ro, { chartColor: I, chartLabel: S }),
|
|
1206
|
-
/* @__PURE__ */ C(x, { alignItems: "center", direction: "row", justifyContent: "space-between", sx: { mx: 24 }, children: [
|
|
1207
|
-
/* @__PURE__ */ e(X, { bold: !0, variant: "body1", children: H }),
|
|
1208
|
-
$ && /* @__PURE__ */ e(so, { filter: V })
|
|
1209
|
-
] })
|
|
1210
|
-
] }),
|
|
1211
|
-
/* @__PURE__ */ e(
|
|
1212
|
-
it,
|
|
1213
|
-
{
|
|
1214
|
-
bgcolor: "transparent",
|
|
1215
|
-
filter: V,
|
|
1216
|
-
height: "calc(100vh - 475px)",
|
|
1217
|
-
onClick: f
|
|
1218
|
-
}
|
|
1219
|
-
)
|
|
1220
|
-
] }),
|
|
1280
|
+
const { guid: _, name: h, is_income: p, totalAmount: y } = d, T = Oe(_, t), N = p ? a.income_label : a.spending_label, x = ` ${d.transactions.length === 1 ? a.transaction : a.transactions} (${d.transactions.length})`, L = g.useMemo(
|
|
1281
|
+
() => i.find((v) => v.guid === f),
|
|
1282
|
+
[f, i]
|
|
1283
|
+
), M = i.length > 0 && !n && (s || r && !o), E = (v) => v.category_guid === _ || v.top_level_category_guid === _;
|
|
1284
|
+
return /* @__PURE__ */ C(S, { sx: { alignItems: "center", height: "100%" }, children: [
|
|
1285
|
+
/* @__PURE__ */ C(S, { sx: { borderRadius: 0, pb: 4, pt: 16, px: 12, width: "100%" }, children: [
|
|
1286
|
+
/* @__PURE__ */ e(We, { sx: { px: 12 }, children: /* @__PURE__ */ C(mt, { children: [
|
|
1287
|
+
/* @__PURE__ */ e(ho, { children: /* @__PURE__ */ e(ve, { categoryGuid: _ }) }),
|
|
1221
1288
|
/* @__PURE__ */ e(
|
|
1222
|
-
|
|
1289
|
+
ht,
|
|
1223
1290
|
{
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1291
|
+
primary: h,
|
|
1292
|
+
secondary: u,
|
|
1293
|
+
slotProps: {
|
|
1294
|
+
primary: { component: "div", variant: "h3", fontSize: 18, fontWeight: 700 },
|
|
1295
|
+
secondary: { component: "div", variant: "body2", fontSize: 13 }
|
|
1296
|
+
}
|
|
1229
1297
|
}
|
|
1230
|
-
)
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
}
|
|
1238
|
-
|
|
1298
|
+
),
|
|
1299
|
+
/* @__PURE__ */ e(F, { component: "div", variant: "h3", children: re(Math.abs(y), "0,0.00") })
|
|
1300
|
+
] }) }),
|
|
1301
|
+
/* @__PURE__ */ e(zo, { chartColor: T, chartLabel: N }),
|
|
1302
|
+
/* @__PURE__ */ C(S, { alignItems: "center", direction: "row", justifyContent: "space-between", sx: { mx: 12 }, children: [
|
|
1303
|
+
/* @__PURE__ */ e(F, { bold: !0, variant: "body1", children: x }),
|
|
1304
|
+
M && /* @__PURE__ */ e(go, { filter: E })
|
|
1305
|
+
] })
|
|
1306
|
+
] }),
|
|
1307
|
+
/* @__PURE__ */ e(
|
|
1308
|
+
ct,
|
|
1309
|
+
{
|
|
1310
|
+
bgcolor: "transparent",
|
|
1311
|
+
filter: E,
|
|
1312
|
+
height: "calc(100vh - 475px)",
|
|
1313
|
+
onClick: m
|
|
1314
|
+
}
|
|
1315
|
+
),
|
|
1316
|
+
/* @__PURE__ */ e(
|
|
1317
|
+
Pe,
|
|
1318
|
+
{
|
|
1319
|
+
ariaLabelClose: c.close_aria,
|
|
1320
|
+
isOpen: !!L,
|
|
1321
|
+
onClose: () => m(""),
|
|
1322
|
+
title: a.transaction,
|
|
1323
|
+
children: L && /* @__PURE__ */ e(dt, { transaction: L })
|
|
1324
|
+
}
|
|
1325
|
+
)
|
|
1326
|
+
] });
|
|
1327
|
+
}), $o = (t, n) => {
|
|
1328
|
+
const s = at(t, n), o = it(t, n);
|
|
1329
|
+
return [s, o].filter((r) => r.length > 0);
|
|
1330
|
+
}, Ko = (t, n) => {
|
|
1331
|
+
const [s, o] = t, r = s, c = o ?? s, a = [];
|
|
1239
1332
|
if (r) {
|
|
1240
|
-
const
|
|
1241
|
-
|
|
1333
|
+
const d = r.reduce((u, i) => u + i.y, 0);
|
|
1334
|
+
a.push({ label: n.income_label, amount: d });
|
|
1242
1335
|
}
|
|
1243
|
-
if (
|
|
1244
|
-
const
|
|
1245
|
-
|
|
1336
|
+
if (c) {
|
|
1337
|
+
const d = c.reduce((u, i) => u + i.y, 0);
|
|
1338
|
+
a.push({ label: n.spending_label, amount: d });
|
|
1246
1339
|
}
|
|
1247
|
-
return
|
|
1248
|
-
},
|
|
1249
|
-
availableHeight:
|
|
1250
|
-
minHeight:
|
|
1251
|
-
selectedDateRange:
|
|
1252
|
-
totals:
|
|
1340
|
+
return a;
|
|
1341
|
+
}, Yo = ({
|
|
1342
|
+
availableHeight: t = 0,
|
|
1343
|
+
minHeight: n = 500,
|
|
1344
|
+
selectedDateRange: s,
|
|
1345
|
+
totals: o
|
|
1253
1346
|
}) => {
|
|
1254
|
-
const r =
|
|
1255
|
-
return
|
|
1256
|
-
const
|
|
1257
|
-
y(
|
|
1258
|
-
}, [
|
|
1259
|
-
|
|
1347
|
+
const r = Z(), { onEvent: c } = $(), { trends: a } = R(), { isSmallMobile: d, isMobile: u, isSmallTablet: i, isTablet: f } = Q(), m = [r.palette.chart?.chart1, r.palette.chart?.chart2], _ = $o(o, s), h = Ko(_, a), [p, y] = g.useState(0), T = 458, N = 195, x = 56, L = u || d ? N : i || f ? T : p;
|
|
1348
|
+
return g.useEffect(() => {
|
|
1349
|
+
const E = Math.max(t - x, n);
|
|
1350
|
+
y(E);
|
|
1351
|
+
}, [t]), /* @__PURE__ */ e(
|
|
1352
|
+
Ve,
|
|
1260
1353
|
{
|
|
1261
1354
|
baseline: "min",
|
|
1262
1355
|
colors: m,
|
|
1263
1356
|
curveType: "bump",
|
|
1264
1357
|
datasets: _,
|
|
1265
|
-
height:
|
|
1266
|
-
labels:
|
|
1358
|
+
height: L,
|
|
1359
|
+
labels: h,
|
|
1267
1360
|
onItemClick: () => {
|
|
1268
|
-
|
|
1361
|
+
c(w.TRENDS_CLICK_CHART, W);
|
|
1269
1362
|
},
|
|
1270
1363
|
showArea: !0,
|
|
1271
1364
|
showAxisHighlight: !0,
|
|
@@ -1278,7 +1371,7 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
1278
1371
|
valueFormatterString: "0.0a"
|
|
1279
1372
|
}
|
|
1280
1373
|
);
|
|
1281
|
-
},
|
|
1374
|
+
}, jo = A(Yo), Uo = [
|
|
1282
1375
|
"BillAmountNotStandard",
|
|
1283
1376
|
"CategorySpendingV2",
|
|
1284
1377
|
"CostOfLivingToIncome",
|
|
@@ -1312,189 +1405,209 @@ const lt = ({ categoryGuid: o, topLevelCategoryGuid: s }) => {
|
|
|
1312
1405
|
"WeeklyNewMerchantsV2",
|
|
1313
1406
|
"WeeklyNoSpendDays",
|
|
1314
1407
|
"WeeklySmallPurchasesSummary"
|
|
1315
|
-
],
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1408
|
+
], Xo = (t, n, s) => ({
|
|
1409
|
+
description: n ? t.empty_state_sub_text : t.empty_state_sub_text_no_aggregation,
|
|
1410
|
+
header: n ? t.zero_state_content_header : t.zero_state_content_header_no_aggregation,
|
|
1411
|
+
onClickHandler: n ? s : void 0,
|
|
1412
|
+
primaryButton: n ? t.empty_state_primary : void 0
|
|
1413
|
+
}), Zo = ({
|
|
1414
|
+
onBackClick: t,
|
|
1415
|
+
onMenuClick: n,
|
|
1416
|
+
onInsightCardClick: s,
|
|
1417
|
+
sx: o
|
|
1418
|
+
}) => {
|
|
1419
|
+
const { onEvent: r } = $(), { config: c } = rt(), { isDesktop: a, isLargeDesktop: d, isMobile: u } = Q(), { isAccountDataLoaded: i, loadAccountData: f, visibleAccounts: m } = De(), {
|
|
1420
|
+
categoriesLoaded: _,
|
|
1421
|
+
loadCategories: h,
|
|
1422
|
+
loadDateRangeCategoryTotals: p,
|
|
1423
|
+
loadMonthlyCategoryTotals: y,
|
|
1424
|
+
monthlyCategoryTotals: T,
|
|
1425
|
+
monthlyTotalsLoaded: N
|
|
1426
|
+
} = q(), { isTransactionDataLoaded: x, loadTransactionData: L, setFilter: M } = we(), { selectedCategoryData: E, selectedDateRange: v, setSelectedCategoryData: K, setSelectedDateRange: ae } = ye(), { isInitialized: Y, selectedAccounts: J, selectedAccountGuids: P } = fe(), { trends: V, connect: O } = R(), { beatStore: ee } = Be(), ie = po() && c.show_insights_widget_in_master, te = a || d, [j, ne] = g.useState(!1), [U, de] = g.useState(!1), [B, ue] = g.useState("Chart"), [se, le] = g.useState(""), [ce, me] = g.useState(window.innerHeight), D = te ? 56 : 0, l = ce - 208, b = ce - (ie ? 550 + D : 266), [I, z] = g.useState(!1), Ee = c.show_connections_widget_in_master;
|
|
1324
1427
|
Ie({
|
|
1325
1428
|
widgetName: "TrendsWidget",
|
|
1326
|
-
isLoaded:
|
|
1429
|
+
isLoaded: j
|
|
1327
1430
|
});
|
|
1328
|
-
const _e =
|
|
1329
|
-
|
|
1330
|
-
const
|
|
1331
|
-
return window.addEventListener("resize",
|
|
1332
|
-
}, []),
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
);
|
|
1431
|
+
const _e = g.useMemo(() => U ? ee.getFilteredBeats({ templates: Uo }) : [], [U]);
|
|
1432
|
+
g.useEffect(() => {
|
|
1433
|
+
const k = () => me(window.innerHeight);
|
|
1434
|
+
return window.addEventListener("resize", k), i || f().finally(), _ || h().finally(), x || L().finally(), () => window.removeEventListener("resize", k);
|
|
1435
|
+
}, []), g.useEffect(() => {
|
|
1436
|
+
Y && i && (ee.loadBeats().finally(() => de(!0)), p(J, v.start, v.end).then(() => {
|
|
1437
|
+
y(
|
|
1438
|
+
J,
|
|
1439
|
+
v.start,
|
|
1440
|
+
v.end
|
|
1441
|
+
).finally();
|
|
1339
1442
|
}).finally(() => {
|
|
1340
|
-
|
|
1341
|
-
...
|
|
1342
|
-
time_period: `${Se(
|
|
1443
|
+
ne(!0), r(w.TRENDS_LOAD_WIDGET, {
|
|
1444
|
+
...W,
|
|
1445
|
+
time_period: `${Se(v.end, v.start)}M`
|
|
1343
1446
|
});
|
|
1344
1447
|
}));
|
|
1345
|
-
}, [
|
|
1346
|
-
if (
|
|
1347
|
-
const
|
|
1348
|
-
accounts:
|
|
1349
|
-
dateRange: { start:
|
|
1448
|
+
}, [Y, i, J, v]), g.useEffect(() => {
|
|
1449
|
+
if (T.length !== 0) {
|
|
1450
|
+
const k = {
|
|
1451
|
+
accounts: P,
|
|
1452
|
+
dateRange: { start: v.start, end: v.end }
|
|
1350
1453
|
};
|
|
1351
|
-
|
|
1352
|
-
...
|
|
1353
|
-
custom: (
|
|
1354
|
-
(
|
|
1454
|
+
M({
|
|
1455
|
+
...k,
|
|
1456
|
+
custom: (oe) => !!T.find(
|
|
1457
|
+
(ge) => ge.top_level_category_guid === oe.top_level_category_guid || ge.category_guid === oe.category_guid
|
|
1355
1458
|
)
|
|
1356
1459
|
});
|
|
1357
1460
|
}
|
|
1358
|
-
}, [
|
|
1359
|
-
const
|
|
1360
|
-
|
|
1461
|
+
}, [T]);
|
|
1462
|
+
const he = (k) => {
|
|
1463
|
+
K(k);
|
|
1361
1464
|
}, Me = () => {
|
|
1362
|
-
|
|
1465
|
+
K(null), r(w.TRENDS_CLICK_BACK, W);
|
|
1363
1466
|
}, Ae = () => {
|
|
1364
|
-
|
|
1365
|
-
},
|
|
1366
|
-
|
|
1367
|
-
...
|
|
1368
|
-
toggleView:
|
|
1467
|
+
z(!0), r(w.TRENDS_CLICK_CONNECT_ACCOUNTS);
|
|
1468
|
+
}, Ct = (k, oe) => {
|
|
1469
|
+
ue(oe ?? B), r(w.TRENDS_CLICK_TOGGLE_VIEW, {
|
|
1470
|
+
...W,
|
|
1471
|
+
toggleView: oe
|
|
1369
1472
|
});
|
|
1370
|
-
},
|
|
1371
|
-
const
|
|
1372
|
-
|
|
1373
|
-
...
|
|
1374
|
-
time_period:
|
|
1473
|
+
}, _t = (k) => {
|
|
1474
|
+
const oe = et(k?.[0], 1), ge = k?.[1], xt = Se(ge, oe);
|
|
1475
|
+
ae({ start: oe, end: ge }), r(w.TRENDS_CLICK_TIME_WINDOW, {
|
|
1476
|
+
...W,
|
|
1477
|
+
time_period: xt + "M"
|
|
1375
1478
|
});
|
|
1376
|
-
},
|
|
1377
|
-
|
|
1378
|
-
...
|
|
1379
|
-
filterValue:
|
|
1479
|
+
}, bt = (k) => {
|
|
1480
|
+
r(w.TRENDS_CLICK_FILTER, {
|
|
1481
|
+
...W,
|
|
1482
|
+
filterValue: k
|
|
1380
1483
|
});
|
|
1381
|
-
},
|
|
1382
|
-
|
|
1383
|
-
},
|
|
1384
|
-
|
|
1484
|
+
}, Tt = (k) => {
|
|
1485
|
+
le(k);
|
|
1486
|
+
}, St = () => {
|
|
1487
|
+
le(""), r(w.TRENDS_CLICK_ALL_CATEGORIES, W);
|
|
1385
1488
|
};
|
|
1386
|
-
if (
|
|
1387
|
-
|
|
1489
|
+
if (!Y || !i || !j || !N)
|
|
1490
|
+
return /* @__PURE__ */ e(Le, {});
|
|
1491
|
+
const ze = m.length === 0 || T.length === 0, be = Xo(V, Ee, Ae);
|
|
1388
1492
|
return /* @__PURE__ */ C(
|
|
1389
|
-
|
|
1493
|
+
ut,
|
|
1390
1494
|
{
|
|
1391
|
-
calendarActions: { onRangeChanged:
|
|
1392
|
-
dateRange:
|
|
1393
|
-
dateRangeVariant:
|
|
1394
|
-
onAccountsFilterClick:
|
|
1395
|
-
onBackClick:
|
|
1396
|
-
|
|
1397
|
-
|
|
1495
|
+
calendarActions: { onRangeChanged: _t },
|
|
1496
|
+
dateRange: v,
|
|
1497
|
+
dateRangeVariant: u ? "timeframetabs" : "timeframebuttons",
|
|
1498
|
+
onAccountsFilterClick: bt,
|
|
1499
|
+
onBackClick: t,
|
|
1500
|
+
onMenuClick: n,
|
|
1501
|
+
sx: o,
|
|
1502
|
+
title: V.title,
|
|
1398
1503
|
children: [
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
{
|
|
1402
|
-
header: E.zero_state_content_header,
|
|
1403
|
-
icon: "",
|
|
1404
|
-
onClick: Ae,
|
|
1405
|
-
primaryButton: E.empty_state_primary,
|
|
1406
|
-
subText: E.empty_state_sub_text,
|
|
1407
|
-
sx: { height: a },
|
|
1408
|
-
variant: Ee
|
|
1409
|
-
}
|
|
1410
|
-
),
|
|
1411
|
-
!Ge && /* @__PURE__ */ C(
|
|
1412
|
-
x,
|
|
1504
|
+
/* @__PURE__ */ C(
|
|
1505
|
+
S,
|
|
1413
1506
|
{
|
|
1414
1507
|
sx: {
|
|
1415
|
-
px:
|
|
1508
|
+
px: u ? 0 : 48
|
|
1416
1509
|
},
|
|
1417
1510
|
children: [
|
|
1418
1511
|
/* @__PURE__ */ C(
|
|
1419
|
-
|
|
1512
|
+
S,
|
|
1420
1513
|
{
|
|
1421
1514
|
flexDirection: "row",
|
|
1422
1515
|
justifyContent: "space-between",
|
|
1423
|
-
sx: {
|
|
1516
|
+
sx: { px: u ? 16 : 0, py: 16 },
|
|
1424
1517
|
children: [
|
|
1425
1518
|
/* @__PURE__ */ e(
|
|
1426
|
-
|
|
1519
|
+
ft,
|
|
1427
1520
|
{
|
|
1428
|
-
selectedCategoryGuid:
|
|
1429
|
-
selectedDateRange:
|
|
1521
|
+
selectedCategoryGuid: se,
|
|
1522
|
+
selectedDateRange: v
|
|
1430
1523
|
}
|
|
1431
1524
|
),
|
|
1432
|
-
/* @__PURE__ */ e(
|
|
1525
|
+
/* @__PURE__ */ e(pt, { onTabChange: Ct, selectedTab: B })
|
|
1433
1526
|
]
|
|
1434
1527
|
}
|
|
1435
1528
|
),
|
|
1436
|
-
/* @__PURE__ */ e(
|
|
1437
|
-
/* @__PURE__ */ e(
|
|
1438
|
-
|
|
1529
|
+
/* @__PURE__ */ e(S, { alignItems: "center", flexDirection: "row", sx: { pb: 8 }, width: "100%", children: /* @__PURE__ */ e(H, { flexGrow: 1, children: se && /* @__PURE__ */ C(Te, { onClick: St, sx: { p: 0, pr: 5 }, children: [
|
|
1530
|
+
/* @__PURE__ */ e(ro, {}),
|
|
1531
|
+
V.all_categories
|
|
1439
1532
|
] }) }) }),
|
|
1440
|
-
/* @__PURE__ */
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1533
|
+
ze && /* @__PURE__ */ e(
|
|
1534
|
+
fo,
|
|
1535
|
+
{
|
|
1536
|
+
header: be.header,
|
|
1537
|
+
icon: "multiline_chart",
|
|
1538
|
+
onClick: be.onClickHandler,
|
|
1539
|
+
primaryButton: be.primaryButton,
|
|
1540
|
+
subText: be.description,
|
|
1541
|
+
sx: { height: l, maxWidth: 432 }
|
|
1542
|
+
}
|
|
1543
|
+
),
|
|
1544
|
+
!ze && /* @__PURE__ */ C(S, { flexDirection: te ? "row" : "column", gap: te ? 48 : 16, children: [
|
|
1545
|
+
B === "Chart" && /* @__PURE__ */ C(vt, { children: [
|
|
1546
|
+
/* @__PURE__ */ e(H, { sx: { width: te ? "68%" : "100%" }, children: /* @__PURE__ */ e(
|
|
1547
|
+
jo,
|
|
1444
1548
|
{
|
|
1445
|
-
availableHeight:
|
|
1549
|
+
availableHeight: l,
|
|
1446
1550
|
minHeight: 450,
|
|
1447
|
-
selectedDateRange:
|
|
1448
|
-
totals:
|
|
1551
|
+
selectedDateRange: v,
|
|
1552
|
+
totals: T
|
|
1449
1553
|
}
|
|
1450
1554
|
) }),
|
|
1451
|
-
/* @__PURE__ */ C(
|
|
1452
|
-
|
|
1453
|
-
|
|
1555
|
+
/* @__PURE__ */ C(S, { gap: 16, sx: { width: te ? "32%" : "100%" }, children: [
|
|
1556
|
+
ie && U && _e.length > 0 && /* @__PURE__ */ e(
|
|
1557
|
+
Vo,
|
|
1454
1558
|
{
|
|
1455
1559
|
beats: _e,
|
|
1456
1560
|
onInsightCardClick: s
|
|
1457
1561
|
}
|
|
1458
1562
|
),
|
|
1459
1563
|
/* @__PURE__ */ e(
|
|
1460
|
-
|
|
1564
|
+
Bo,
|
|
1461
1565
|
{
|
|
1462
|
-
availableHeight:
|
|
1463
|
-
onCategoryClick:
|
|
1566
|
+
availableHeight: b,
|
|
1567
|
+
onCategoryClick: he
|
|
1464
1568
|
}
|
|
1465
1569
|
)
|
|
1466
1570
|
] })
|
|
1467
1571
|
] }),
|
|
1468
|
-
|
|
1469
|
-
|
|
1572
|
+
B === "Table" && /* @__PURE__ */ e(H, { sx: { width: "100%" }, children: /* @__PURE__ */ e(
|
|
1573
|
+
yt,
|
|
1470
1574
|
{
|
|
1471
1575
|
height: "unset",
|
|
1472
|
-
onClickRow:
|
|
1473
|
-
selectedCategory:
|
|
1474
|
-
selectedDateRange:
|
|
1576
|
+
onClickRow: Tt,
|
|
1577
|
+
selectedCategory: se,
|
|
1578
|
+
selectedDateRange: v
|
|
1475
1579
|
}
|
|
1476
1580
|
) })
|
|
1477
1581
|
] }),
|
|
1478
|
-
|
|
1582
|
+
/* @__PURE__ */ e(
|
|
1583
|
+
Pe,
|
|
1584
|
+
{
|
|
1585
|
+
ariaLabelClose: V.close_category_details,
|
|
1586
|
+
isOpen: !!E,
|
|
1587
|
+
onClose: Me,
|
|
1588
|
+
shouldShowHeaderShadow: !0,
|
|
1589
|
+
title: E?.is_income ? V.category_income : V.category_spending,
|
|
1590
|
+
children: E && /* @__PURE__ */ e(Fo, {})
|
|
1591
|
+
}
|
|
1592
|
+
)
|
|
1479
1593
|
]
|
|
1480
1594
|
}
|
|
1481
1595
|
),
|
|
1482
1596
|
/* @__PURE__ */ e(
|
|
1483
|
-
|
|
1597
|
+
yo,
|
|
1484
1598
|
{
|
|
1485
|
-
onClose: () =>
|
|
1486
|
-
showConnectWidget:
|
|
1487
|
-
title:
|
|
1599
|
+
onClose: () => z(!1),
|
|
1600
|
+
showConnectWidget: I,
|
|
1601
|
+
title: O.mini_title
|
|
1488
1602
|
}
|
|
1489
1603
|
)
|
|
1490
1604
|
]
|
|
1491
1605
|
}
|
|
1492
1606
|
);
|
|
1493
|
-
},
|
|
1607
|
+
}, ls = A(Zo);
|
|
1494
1608
|
export {
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
jn as TrendsWidget
|
|
1609
|
+
rs as TrendsFullWidget,
|
|
1610
|
+
is as TrendsMicroWidget,
|
|
1611
|
+
as as TrendsMiniWidget,
|
|
1612
|
+
ls as TrendsWidget
|
|
1500
1613
|
};
|