@mx-cartographer/experiences 3.14.0-alpha.mm6 → 3.16.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 +245 -96
- package/dist/accounts/stores/AccountStore.d.ts +1 -0
- package/dist/budgets/api/BudgetsApi.d.ts +2 -2
- package/dist/budgets/components/AddBudgets.d.ts +3 -0
- package/dist/budgets/components/BubbleBudgets.d.ts +1 -3
- package/dist/budgets/components/BubbleChart.d.ts +4 -5
- package/dist/budgets/components/BudgetDetailsDrawer.d.ts +3 -0
- package/dist/budgets/components/BudgetList.d.ts +3 -7
- package/dist/budgets/components/addbudget/Header.d.ts +3 -0
- package/dist/budgets/components/addbudget/RecalculateBudgetRow.d.ts +7 -0
- package/dist/budgets/components/addbudget/RecalculateBudgets.d.ts +1 -0
- package/dist/budgets/components/addbudget/UnbudgetedRow.d.ts +8 -0
- package/dist/budgets/components/bubblechart/Bubble.d.ts +1 -1
- package/dist/budgets/components/bubblechart/Mercury.d.ts +2 -0
- package/dist/budgets/components/budgetdetails/AddSubBudget.d.ts +8 -0
- package/dist/budgets/components/{BudgetDetails.d.ts → budgetdetails/BudgetDetails.d.ts} +1 -1
- package/dist/budgets/components/budgetdetails/Header.d.ts +7 -0
- package/dist/budgets/components/budgetdetails/SubBudgetList.d.ts +7 -0
- package/dist/budgets/components/budgetlist/BudgetRow.d.ts +1 -1
- package/dist/budgets/components/budgetlist/SubBudgetRow.d.ts +1 -1
- package/dist/budgets/components/budgetlist/SubBudgetZeroState.d.ts +3 -1
- package/dist/budgets/components/shared/BudgetAmount.d.ts +8 -0
- package/dist/budgets/store/BudgetsStore.d.ts +8 -2
- package/dist/budgets/utils/BubblesSVG.d.ts +5 -3
- package/dist/budgets/utils/BudgetUtil.d.ts +6 -4
- package/dist/categories/index.d.ts +1 -0
- package/dist/categories/stores/CategoryStore.d.ts +5 -36
- package/dist/categories/util/CategoryUtil.d.ts +8 -0
- package/dist/common/components/WidgetContainer.d.ts +1 -1
- package/dist/common/components/charts/LineChart.d.ts +7 -1
- package/dist/common/components/charts/linechart/CustomMark.d.ts +7 -0
- package/dist/common/components/daterangeselector/DateRangeSelector.d.ts +1 -1
- package/dist/common/components/dialog/Dialog.d.ts +2 -0
- package/dist/common/components/drawer/Drawer.d.ts +4 -0
- package/dist/common/components/drawer/Header.d.ts +1 -0
- package/dist/common/components/index.d.ts +1 -0
- package/dist/common/constants/Analytics.d.ts +5 -0
- package/dist/common/context/hooks.d.ts +3 -1
- package/dist/common/context/index.d.ts +1 -1
- package/dist/common/stores/GlobalStore.d.ts +4 -0
- package/dist/common/types/Account.d.ts +1 -0
- package/dist/common/types/Budget.d.ts +2 -4
- package/dist/common/types/Category.d.ts +22 -9
- package/dist/common/types/Debt.d.ts +15 -0
- package/dist/common/types/index.d.ts +3 -2
- package/dist/common/types/localization/BudgetsCopy.d.ts +36 -0
- package/dist/common/utils/Categories.d.ts +4 -1
- package/dist/common/utils/DateUtil.d.ts +1 -0
- package/dist/common/utils/index.d.ts +2 -1
- package/dist/debts/DebtsWidget.d.ts +5 -0
- package/dist/debts/index.d.ts +2 -0
- package/dist/debts/store/DebtsStore.d.ts +6 -0
- package/dist/debts/utils/DebtStore.d.ts +5 -0
- package/dist/goals/index.d.ts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +5792 -4707
- package/dist/index.es.js.map +1 -1
- package/dist/networth/NetWorthWidget.d.ts +3 -0
- package/dist/networth/components/AssetsLiabilitiesDetail.d.ts +4 -0
- package/dist/networth/components/GainsLossesDetail.d.ts +4 -0
- package/dist/networth/components/NetWorthChange.d.ts +12 -0
- package/dist/networth/components/NetWorthChart.d.ts +3 -0
- package/dist/networth/components/NetWorthList.d.ts +2 -6
- package/dist/networth/components/NetWorthListItem.d.ts +17 -0
- package/dist/networth/components/NetWorthSummary.d.ts +7 -0
- package/dist/networth/index.d.ts +3 -0
- package/dist/networth/stores/NetWorthStore.d.ts +7 -1
- package/dist/networth/types/NetWorth.d.ts +40 -1
- package/dist/networth/utils/NetWorthUtils.d.ts +22 -1
- package/dist/recurringactivity/stores/RecurringActivityStore.d.ts +1 -0
- package/dist/transactions/index.d.ts +1 -0
- package/package.json +3 -3
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Theme } from '@mui/material';
|
|
2
|
+
import { TypographyProps } from '@mui/material/Typography';
|
|
3
|
+
import { NetWorth } from '../types/NetWorth';
|
|
4
|
+
interface NetWorthChangeProps {
|
|
5
|
+
netWorth: NetWorth;
|
|
6
|
+
currencyVariant?: TypographyProps['variant'];
|
|
7
|
+
currencyLabel?: string;
|
|
8
|
+
iconSize?: number;
|
|
9
|
+
theme: Theme;
|
|
10
|
+
}
|
|
11
|
+
declare const _default: import('react').FunctionComponent<NetWorthChangeProps>;
|
|
12
|
+
export default _default;
|
|
@@ -1,8 +1,4 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
chartData: NetWorth[];
|
|
5
|
-
selectedData: NetWorth;
|
|
6
|
-
}
|
|
7
|
-
declare const _default: React.FunctionComponent<NetWorthListProps>;
|
|
2
|
+
import { NetWorthProps } from '../types/NetWorth';
|
|
3
|
+
declare const _default: React.FunctionComponent<NetWorthProps>;
|
|
8
4
|
export default _default;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { NetWorth } from '../types/NetWorth';
|
|
3
|
+
interface NetWorthListItemProps {
|
|
4
|
+
item: NetWorth;
|
|
5
|
+
getStyles: (item: NetWorth) => {
|
|
6
|
+
backgroundColor: string;
|
|
7
|
+
borderBottom: string;
|
|
8
|
+
color: string;
|
|
9
|
+
};
|
|
10
|
+
isHovered: boolean;
|
|
11
|
+
isSelected: boolean;
|
|
12
|
+
onItemClick?: (event: React.MouseEvent<HTMLDivElement, MouseEvent>, dataIndex: number) => void;
|
|
13
|
+
onMouseEnter: (dataIndex: number) => void;
|
|
14
|
+
onMouseLeave: () => void;
|
|
15
|
+
}
|
|
16
|
+
declare const _default: React.FunctionComponent<NetWorthListItemProps>;
|
|
17
|
+
export default _default;
|
package/dist/networth/index.d.ts
CHANGED
|
@@ -1,2 +1,5 @@
|
|
|
1
1
|
export { NetWorthStore } from './stores/NetWorthStore';
|
|
2
|
+
export { default as NetWorthChart } from './components/NetWorthChart';
|
|
2
3
|
export { default as NetWorthList } from './components/NetWorthList';
|
|
4
|
+
export { default as NetWorthSummary } from './components/NetWorthSummary';
|
|
5
|
+
export { NetWorthWidget } from './NetWorthWidget';
|
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
import { GlobalStore } from '../../common';
|
|
2
|
-
import { NetWorth, NetWorthData } from '../types/NetWorth';
|
|
2
|
+
import { AssetsLiabilities, GainsLosses, NetWorth, NetWorthData } from '../types/NetWorth';
|
|
3
3
|
export declare class NetWorthStore {
|
|
4
4
|
globalStore: GlobalStore;
|
|
5
5
|
netWorthData: NetWorthData;
|
|
6
6
|
netWorthChartData: NetWorth[];
|
|
7
|
+
hoveredData?: NetWorth;
|
|
8
|
+
selectedData?: NetWorth;
|
|
7
9
|
constructor(globalStore: GlobalStore);
|
|
8
10
|
loadNetWorthData: () => Promise<void>;
|
|
9
11
|
loadChartData: (numberOfMonths: number) => Promise<void>;
|
|
12
|
+
get gainsLosses(): GainsLosses;
|
|
13
|
+
get assetsLiabilities(): AssetsLiabilities;
|
|
14
|
+
setSelectedData: (dataIndex: number) => void;
|
|
15
|
+
setHoveredData: (dataIndex: number | null) => void;
|
|
10
16
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Account, MonthlyAccountBalance } from '../../common';
|
|
1
|
+
import { Account, AccountType, MonthlyAccountBalance } from '../../common';
|
|
2
2
|
export type MonthlyAccountSummary = {
|
|
3
3
|
balance: number;
|
|
4
4
|
change: number;
|
|
@@ -17,3 +17,42 @@ export type NetWorthData = {
|
|
|
17
17
|
accounts: Account[];
|
|
18
18
|
monthlyAccountBalances: MonthlyAccountBalance[];
|
|
19
19
|
};
|
|
20
|
+
export type NetWorthProps = {
|
|
21
|
+
chartData: NetWorth[];
|
|
22
|
+
hoveredData?: NetWorth;
|
|
23
|
+
onButtonClick?: any;
|
|
24
|
+
onDataClick: any;
|
|
25
|
+
onMouseEnter: any;
|
|
26
|
+
onMouseLeave: any;
|
|
27
|
+
selectedData?: NetWorth;
|
|
28
|
+
};
|
|
29
|
+
export interface FinancialAccount {
|
|
30
|
+
accountName?: string;
|
|
31
|
+
accountType: AccountType;
|
|
32
|
+
balance: number;
|
|
33
|
+
}
|
|
34
|
+
export interface AccountGroup {
|
|
35
|
+
icon: string;
|
|
36
|
+
name: string;
|
|
37
|
+
accounts: FinancialAccount[];
|
|
38
|
+
}
|
|
39
|
+
export interface AssetsLiabilities {
|
|
40
|
+
netWorth?: NetWorth;
|
|
41
|
+
assets: FinancialAccount[];
|
|
42
|
+
liabilities: FinancialAccount[];
|
|
43
|
+
totalAssets: number;
|
|
44
|
+
totalLiabilities: number;
|
|
45
|
+
}
|
|
46
|
+
export interface GainsLosses {
|
|
47
|
+
netWorth?: NetWorth;
|
|
48
|
+
gains: {
|
|
49
|
+
accountName: string;
|
|
50
|
+
gain: number;
|
|
51
|
+
}[];
|
|
52
|
+
losses: {
|
|
53
|
+
accountName: string;
|
|
54
|
+
loss: number;
|
|
55
|
+
}[];
|
|
56
|
+
totalGains: number;
|
|
57
|
+
totalLosses: number;
|
|
58
|
+
}
|
|
@@ -1,6 +1,27 @@
|
|
|
1
1
|
import { Account, Member, MonthlyAccountBalance } from '../../common/types';
|
|
2
|
+
import { FinancialAccount, AccountGroup, NetWorth } from '../types/NetWorth';
|
|
2
3
|
export declare const filterAccounts: (accounts: Account[], members: Member[]) => Account[];
|
|
3
4
|
export declare const flattenBalances: (balances: any, balance: any) => any[];
|
|
5
|
+
export declare const getLatestNetWorthData: (chartData: NetWorth[]) => NetWorth | undefined;
|
|
4
6
|
export declare const sortByYearMonthAscending: (a: MonthlyAccountBalance, b: MonthlyAccountBalance) => number;
|
|
5
|
-
export declare const getCurrentMonth: () => string;
|
|
6
7
|
export declare const buildChartData: (accounts: Account[], monthlyAccountBalances: MonthlyAccountBalance[], numberOfMonths: number) => any;
|
|
8
|
+
export declare const buildGainsLosses: (selectedData?: NetWorth) => {
|
|
9
|
+
netWorth: NetWorth | undefined;
|
|
10
|
+
gains: {
|
|
11
|
+
accountName: string;
|
|
12
|
+
gain: number;
|
|
13
|
+
}[];
|
|
14
|
+
losses: {
|
|
15
|
+
accountName: string;
|
|
16
|
+
loss: number;
|
|
17
|
+
}[];
|
|
18
|
+
totalGains: number;
|
|
19
|
+
totalLosses: number;
|
|
20
|
+
};
|
|
21
|
+
export declare const buildAssetsLiabilities: (accounts: Account[]) => {
|
|
22
|
+
assets: FinancialAccount[];
|
|
23
|
+
liabilities: FinancialAccount[];
|
|
24
|
+
totalAssets: number;
|
|
25
|
+
totalLiabilities: number;
|
|
26
|
+
};
|
|
27
|
+
export declare const groupAccounts: (accounts: FinancialAccount[]) => AccountGroup[];
|
|
@@ -21,6 +21,7 @@ export declare class RecurringActivityStore {
|
|
|
21
21
|
get upcomingIncome(): Activity[];
|
|
22
22
|
get nextIncomeActivity(): Activity | undefined;
|
|
23
23
|
get selectedDayActivities(): Activity[] | undefined;
|
|
24
|
+
get projectedIncome(): number;
|
|
24
25
|
addCashflowEvent: (cashflowEvent: CashflowEvent) => Promise<void>;
|
|
25
26
|
addCashflowSequence: (cashflowSequence: CashflowSequence) => Promise<CashflowSequence | undefined>;
|
|
26
27
|
addScheduledPayment: (scheduledPayemnt: ScheduledPayment, transaction: Transaction) => Promise<void>;
|
|
@@ -3,6 +3,7 @@ export { BottomActions, TopActions } from './constants/Actions';
|
|
|
3
3
|
export { ON_CLICK_EVENTS as TRANSACTION_EVENTS } from './constants/OnClickEvents';
|
|
4
4
|
export { TransactionStore } from './stores/TransactionStore';
|
|
5
5
|
export { useTransactionsUiStore } from './context/hooks';
|
|
6
|
+
export { exportTransactionsToCSV } from './utils/exportTransactionsToCSV';
|
|
6
7
|
export { default as TransactionRow } from './components/shared/transactionlist/TransactionRow';
|
|
7
8
|
export { default as TransactionList } from './components/shared/TransactionList';
|
|
8
9
|
export { default as TransactionTable } from './components/shared/TransactionTable';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mx-cartographer/experiences",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.16.0",
|
|
4
4
|
"description": "Library containing experience widgets",
|
|
5
5
|
"main": "dist/index.es.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"@emotion/styled": "^11.11.0",
|
|
28
28
|
"@honeybadger-io/js": "^6.8.3",
|
|
29
29
|
"@honeybadger-io/react": "^6.1.19",
|
|
30
|
-
"@kyper/mui": "^4.
|
|
30
|
+
"@kyper/mui": "^4.4.2",
|
|
31
31
|
"@mui/icons-material": "^5.16.0",
|
|
32
32
|
"@mui/lab": "^5.0.0-alpha.172",
|
|
33
33
|
"@mui/material": "^5.16.0",
|
|
@@ -121,5 +121,5 @@
|
|
|
121
121
|
"CHANGELOG.md",
|
|
122
122
|
"README.md"
|
|
123
123
|
],
|
|
124
|
-
"packageManager": "yarn@4.5.
|
|
124
|
+
"packageManager": "yarn@4.5.3"
|
|
125
125
|
}
|