@vizzly/dashboard 0.15.0-dev-4a90180f693d878d9bfd1449280e08ac6afa15d7 → 0.15.0-dev-0deaef621a2f2e1193124d502137c2500f5e1855

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.
@@ -3,6 +3,7 @@ export interface BarChartRepresentation extends BaseChartRepresentation {
3
3
  conditionalFormattingRules: ConditionalFormattingRule[];
4
4
  goalLines: GoalLine[];
5
5
  bars: ShapeDefinition<BarStyles>[];
6
+ formattingFunctionY?: (value: any, nullValueAlias?: string) => string;
6
7
  }
7
8
  export declare type BarStyles = {
8
9
  type: 'bar';
@@ -0,0 +1,25 @@
1
+ import { Tick } from './types';
2
+ declare type FormattingFunction = (value: any, nullValueAlias?: string) => string;
3
+ export declare const DEFAULT_TICK_COUNT = 10;
4
+ interface getMetricAxisTickValuesArgs {
5
+ min: number;
6
+ max: number;
7
+ interval: number;
8
+ stacked: boolean;
9
+ }
10
+ interface getMetricAxisTicksArgs {
11
+ min: number | null;
12
+ max: number | null;
13
+ tickCount: number;
14
+ nullValue: string | undefined;
15
+ formattingFunction: FormattingFunction;
16
+ stacked: boolean;
17
+ }
18
+ interface getMetricAxisTicksReturn {
19
+ ticks: Array<Tick<number>>;
20
+ minTickValue: number;
21
+ maxTickValue: number;
22
+ }
23
+ export declare const getMetricAxisTickValues: ({ min, max, interval, stacked }: getMetricAxisTickValuesArgs) => number[];
24
+ export declare const getMetricAxisTicks: ({ min, max, tickCount, nullValue, formattingFunction, stacked, }: getMetricAxisTicksArgs) => getMetricAxisTicksReturn;
25
+ export {};
@@ -0,0 +1,2 @@
1
+ import { Tick } from '../ChartsV2/types';
2
+ export declare function getStackedPercentageAxisTicks(convertedStackedPercentageData: Record<string, any>[], yKeys: string[], xKey: string | null): Tick<number>[];
@@ -0,0 +1 @@
1
+ export declare function getStackedPercentageScaleLinearDomain(convertedStackedPercentageData: Record<string, any>[], yKeys: string[], xKey: string | null): number[];
@@ -0,0 +1 @@
1
+ export declare function getStackedPercentageTickValues(convertedStackedPercentageData: Record<string, any>[], yKeys: string[], xKey: string | null): number[];
@@ -1,9 +1,8 @@
1
- import { QueryAttributes } from '../QueryAttributes/types';
1
+ import { GoalLine, KeyId, Tick } from '../ChartsV2/types';
2
2
  import { DataType } from '../Field/types';
3
+ import { QueryAttributes } from '../QueryAttributes/types';
3
4
  import { FormattedResult } from '../Result/types';
4
- import { GoalLine, KeyId, Tick } from '../ChartsV2/types';
5
5
  declare type FormattingFunction = (value: any, nullValueAlias?: string) => string;
6
- export declare const DEFAULT_TICK_COUNT = 10;
7
6
  interface getScaleAndTicksArgs {
8
7
  data: FormattedResult['contentMapped'];
9
8
  xKey: string | null;
@@ -1,6 +1,6 @@
1
+ import { Result as ResultType } from '../../../shared-logic/src/Result/types';
1
2
  import { BarChartRepresentation } from '../BarChartV2/types';
2
3
  import { LineChartRepresentation } from '../LineChartV2/types';
3
- import { Result as ResultType } from '../../../shared-logic/src/Result/types';
4
4
  export declare function buildComboChartRepresentation(xKeyField: ResultType.Field | undefined, barChartRepresentation: BarChartRepresentation, lineChartRepresentation: LineChartRepresentation): {
5
5
  x: {
6
6
  scale: {
@@ -3,6 +3,7 @@ export interface LineChartRepresentation extends BaseChartRepresentation {
3
3
  conditionalFormattingRules: ConditionalFormattingRule[];
4
4
  goalLines: GoalLine[];
5
5
  lines: ShapeDefinition<LineStyles>[];
6
+ formattingFunctionY?: (value: any, nullValueAlias?: string) => string;
6
7
  }
7
8
  export declare type LineStyles = {
8
9
  type: 'line';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vizzly/dashboard",
3
3
  "author": "james@vizzly.co",
4
- "version": "0.15.0-dev-4a90180f693d878d9bfd1449280e08ac6afa15d7",
4
+ "version": "0.15.0-dev-0deaef621a2f2e1193124d502137c2500f5e1855",
5
5
  "source": "src/index.tsx",
6
6
  "types": "./dist/dashboard/src/index.d.ts",
7
7
  "module": "./dist/dashboard.esm.js",