@mx-cartographer/experiences 3.12.5-alpha.j1 → 3.13.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,16 +1,20 @@
1
- import { default as React } from 'react';
1
+ import { default as React, CSSProperties } from 'react';
2
2
  interface LineChartProps {
3
+ baseline?: string;
3
4
  colors: (string | undefined)[];
4
5
  datasets: {
5
6
  x: string;
6
7
  y: number;
7
8
  }[][];
8
9
  height?: number;
10
+ getMarkStyles?: (markIndex: number) => CSSProperties;
9
11
  labels: string[];
10
12
  showArea?: boolean;
11
13
  showAverage?: boolean;
12
14
  showBars?: boolean;
13
15
  showMarkLabel?: boolean;
16
+ useCustomMark?: boolean;
17
+ valueFormatterString?: string;
14
18
  width?: number;
15
19
  }
16
20
  export declare const LineChart: React.FC<LineChartProps>;
@@ -1,20 +1,23 @@
1
1
  import { default as React } from 'react';
2
+ type DataPoint = {
3
+ x: Date;
4
+ y: number;
5
+ };
6
+ type Dataset = DataPoint[];
7
+ interface StackedLineChartData {
8
+ top_level_category_guid: string;
9
+ category_guid: string;
10
+ category_name: string;
11
+ category_color: string;
12
+ dataset: Dataset;
13
+ }
2
14
  interface StackedLineChartProps {
15
+ stackedDatasets: StackedLineChartData[];
16
+ unstackedDatasets?: StackedLineChartData[];
3
17
  onHoverArea?: (category: string) => void;
4
18
  onHoverPoint?: (category: string) => void;
5
19
  onHoverLegend?: (category: string) => void;
6
- stackedColors: (string | undefined)[];
7
- stackedDatasets: {
8
- x: string;
9
- y: number;
10
- }[][];
11
- stackedCategoryGuids: string[];
12
- unstackedColors?: (string | undefined)[];
13
- unstackedDatasets?: {
14
- x: string;
15
- y: number;
16
- }[][];
17
- unstackedCategoryGuids?: string[];
20
+ onClickLegend?: (category: string) => void;
18
21
  height?: number;
19
22
  width?: number;
20
23
  }
@@ -1,6 +1,7 @@
1
1
  import { default as React } from 'react';
2
2
  import { MarkElementProps } from '@mui/x-charts';
3
3
  interface CustomMarkProps extends MarkElementProps {
4
+ showLabel: boolean;
4
5
  yData: number[];
5
6
  }
6
7
  export declare const CustomMark: React.FC<CustomMarkProps>;
@@ -1,4 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  export declare const CategoryIconLabel: React.FC<{
3
3
  categoryGuid: string;
4
+ topLevelCategoryGuid: string;
4
5
  }>;
@@ -4,7 +4,10 @@ type DataPoint = {
4
4
  y: number;
5
5
  };
6
6
  declare const _default: React.FunctionComponent<{
7
- categoryGuid: string;
7
+ categoryGuids: {
8
+ guid: string;
9
+ topLevelGuid: string;
10
+ };
8
11
  hoveredAreaData: DataPoint[];
9
12
  cursorPosition: {
10
13
  x: number;
@@ -1,13 +1,13 @@
1
1
  import { default as React } from 'react';
2
2
  interface CustomLegendProps {
3
- labels: string[];
4
- stackedLabels: string[];
5
3
  sx?: object;
6
- unstackedLabels: string[];
7
- stackedColors: (string | undefined)[];
8
- unstackedColors: (string | undefined)[];
4
+ categoryGuids: {
5
+ guid: string;
6
+ top_level_guid: string;
7
+ }[];
9
8
  hoveredLegend: string | null;
10
- setHoveredLegend: (label: string | null) => void;
9
+ onHoverLegend: (label: string | null) => void;
10
+ onClickLegend: (label: string | null) => void;
11
11
  }
12
12
  export declare const CustomLegend: React.FC<CustomLegendProps>;
13
13
  export {};
@@ -1,7 +1,11 @@
1
1
  import { default as React } from 'react';
2
2
  import { ChartsItemContentProps } from '@mui/x-charts';
3
3
  interface CustomPointTooltipProps extends ChartsItemContentProps<'line'> {
4
- categoryGuid: string;
4
+ categoryGuids: {
5
+ guid: string;
6
+ topLevelGuid: string;
7
+ };
8
+ xData: Date[];
5
9
  }
6
10
  export declare const CustomPointTooltip: React.FC<CustomPointTooltipProps>;
7
11
  export {};
@@ -0,0 +1 @@
1
+ export declare const smoothData: (data: number[], smoothingFactor?: number) => number[];
@@ -45,6 +45,7 @@ export declare const ANALYTICS_EVENTS: {
45
45
  TRENDS_CLICK_DATE: string;
46
46
  TRENDS_CLICK_TABLE_SORT: string;
47
47
  TRENDS_CLICK_TABLE_ROW: string;
48
+ TRENDS_CLICK_LEGEND: string;
48
49
  TRENDS_HOVER_LEGEND: string;
49
50
  TRENDS_HOVER_AREA: string;
50
51
  TRENDS_HOVER_POINT: string;
@@ -2,7 +2,7 @@ export { ApiEndpoints } from './ApiEndpoints';
2
2
  export { ANALYTICS_EVENTS } from './Analytics';
3
3
  export { DATE_FORMATS_INTL, formatDate, ORDINAL_DATE_FORMAT, ORDINAL_MONTH_DAY_YEAR_FORMAT, } from './DateFormats';
4
4
  export { INCOME_ACCOUNT_TYPES, PAYMENT_ACCOUNT_TYPES, SPENDING_ACCOUNT_TYPES } from './Account';
5
- export { CategoryColors, CategoryGuids, CategoryGuidToName, CategoryIcon } from './Category';
5
+ export { CategoryColors, CategoryGuids, CategoryGuidToName, CategoryIcon, PaymentCategories, } from './Category';
6
6
  export { CurrencyCodes } from './Numbers';
7
7
  export { RecurrenceTypes, RECURRENCE_COPY } from './ScheduledPayment';
8
8
  export { IterationItemTypes, LOADING_STATUS, PlanTypes } from './SpendingPlan';
@@ -1,4 +1,5 @@
1
1
  export interface TrendsCopy {
2
+ all_categories: string;
2
3
  income_label: string;
3
4
  mini_title: string;
4
5
  payments_label: string;