pace-chart-lib 1.0.33 → 1.0.35
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/dist/Components/Charts/ChartsWithAxis/ChartsWithAxisFunctions.d.ts +6 -32
- package/dist/Components/Charts/ChartsWithAxis/ChartsWithAxisTypes.types.d.ts +2 -0
- package/dist/Components/Charts/Core/Common.types.d.ts +10 -2
- package/dist/Components/Charts/Core/CommonFunctions.d.ts +11 -2
- package/dist/Components/Charts/Core/DefaultProperties.types.d.ts +3 -0
- package/dist/pace-chart-lib.es.js +1358 -602
- package/dist/pace-chart-lib.umd.js +1358 -602
- package/package.json +1 -1
|
@@ -348,7 +348,7 @@ export declare function responsiveXaxisLabel(dimensionList: string[], innerWidth
|
|
|
348
348
|
*
|
|
349
349
|
* @returns {any} The updated SVG group element (`gTag`) with the initialized X axis.
|
|
350
350
|
*/
|
|
351
|
-
export declare function initXaxis(gTag: any, chartJSON: TChartJSON, xLabel: number, formatOptions: TDefaultChartFormatOptionsType, dataTableHeight: number, yScaleLeft: any, xAxis: any, dimensionHeightWidthArray: number[], height: number, barWidth: number, isDateType: string, innerWidth: number, innerHeight: number, filteredDimensionList: string[]): any;
|
|
351
|
+
export declare function initXaxis(gTag: any, chartJSON: TChartJSON, xLabel: number, formatOptions: TDefaultChartFormatOptionsType, dataTableHeight: number, yScaleLeft: any, xAxis: any, dimensionHeightWidthArray: number[], height: number, barWidth: number, isDateType: string, innerWidth: number, innerHeight: number, filteredDimensionList: string[], xScale: any): any;
|
|
352
352
|
export declare function detectBrowserName(): string;
|
|
353
353
|
/**
|
|
354
354
|
* Formats date dimension marks based on the specified format and datasource.
|
|
@@ -417,33 +417,7 @@ export declare function setChartTitle(svg: any, formatOptions: TDefaultChartForm
|
|
|
417
417
|
* @returns The appropriate D3 curve function based on the interpolation and smoothing settings.
|
|
418
418
|
*/
|
|
419
419
|
export declare function getCurveType(formatOptions: TDefaultChartFormatOptionsType): d3.CurveFactory;
|
|
420
|
-
|
|
421
|
-
* @param {TSeries[]} chartData - Array of data series for the chart.
|
|
422
|
-
* @param {any} xScale - D3 scale function for the X axis.
|
|
423
|
-
* @param {any} yScaleLeft - D3 scale function for the left Y axis.
|
|
424
|
-
* @param {any} yScaleRight - D3 scale function for the right Y axis.
|
|
425
|
-
* @param {TMargin} margin - Margin object defining chart margins.
|
|
426
|
-
* @param {any} d3Annotation - D3 annotation library or object.
|
|
427
|
-
* @param {string[]} labelExcludeList - List of labels to exclude from annotations.
|
|
428
|
-
* @param {any[]} individualLabelColor - Array of colors for individual labels.
|
|
429
|
-
* @param {any[]} oldAnnotationList - List of existing annotations to update or remove.
|
|
430
|
-
* @param {TDefaultChartFormatOptionsType} formatOptions - Formatting options for the chart.
|
|
431
|
-
* @param {string} chartType - Type of the chart (e.g., "line", "area").
|
|
432
|
-
* @param {number} height - Total height of the SVG container.
|
|
433
|
-
* @param {number} width - Total width of the SVG container.
|
|
434
|
-
* @param {number} innerWidth - Inner width of the chart area.
|
|
435
|
-
* @param {string[]} dimensionList - List of dimensions present in the chart data.
|
|
436
|
-
* @param {number} innerHeight - Inner height of the chart area.
|
|
437
|
-
* @param {string} widgetId - Unique identifier for the widget/chart instance.
|
|
438
|
-
* @param {any} svg - D3 selection of the SVG element to render annotations.
|
|
439
|
-
* @param {any} xScaleForLegends - D3 scale function for the X axis for legends.
|
|
440
|
-
* @param {number} columnWidth - Column width for the chart.
|
|
441
|
-
* @param {boolean} isSensitivityChart - Flag indicating if the chart is a sensitivity chart.
|
|
442
|
-
* @param {boolean} barChart - Flag indicating if the chart is a barChart chart.
|
|
443
|
-
*
|
|
444
|
-
* @return {void} - This function does not return a value; it updates the SVG with annotations.
|
|
445
|
-
*/
|
|
446
|
-
export declare function commonAnnotations(chartData: TSeries[], xScale: any, yScaleLeft: any, yScaleRight: any, margin: TMargin, d3Annotation: any, labelExcludeList: string[], individualLabelColor: any[], oldAnnotationList: any[], formatOptions: TDefaultChartFormatOptionsType, chartType: string, height: number, width: number, innerWidth: number, dimensionList: string[], innerHeight: number, widgetId: string, svg: any, xScaleForLegends?: any, columnWidth?: number, isReportEditable?: boolean, isSensitivityChart?: boolean, barChart?: boolean): void;
|
|
420
|
+
export declare function commonAnnotations(chartData: TSeries[], xScale: any, yScaleLeft: any, yScaleRight: any, margin: TMargin, d3Annotation: any, labelExcludeList: string[], individualLabelColor: any[], formatOptions: TDefaultChartFormatOptionsType, chartType: string, height: number, width: number, innerWidth: number, dimensionList: string[], innerHeight: number, widgetId: string, svg: any, onDataLabelCoordinatesChange: (coordinates: any[]) => void, xScaleForLegends?: any, columnWidth?: number, isReportEditable?: boolean, isSensitivityChart?: boolean, barChart?: boolean, isAATornado?: boolean): void;
|
|
447
421
|
/**
|
|
448
422
|
* @param {Array} chartData - The main data used to render the chart.
|
|
449
423
|
* @param {Function} xscale - D3 scale function for the x-axis.
|
|
@@ -469,7 +443,7 @@ export declare function commonAnnotations(chartData: TSeries[], xScale: any, ySc
|
|
|
469
443
|
*
|
|
470
444
|
* @return {void} - This function does not return a value; it updates the SVG with annotations.
|
|
471
445
|
*/
|
|
472
|
-
export declare function commonAnnotationsForCustomChart(chartData: TSeries[], xScale: any, yScaleLeft: any, yScaleRight: any, margin: TMargin, d3Annotation: any, stackColumnData: any[], stackAreaData: any[], labelExcludeList: string[], individualLabelColor: any[], columnWidth: number,
|
|
446
|
+
export declare function commonAnnotationsForCustomChart(chartData: TSeries[], xScale: any, yScaleLeft: any, yScaleRight: any, margin: TMargin, d3Annotation: any, stackColumnData: any[], stackAreaData: any[], labelExcludeList: string[], individualLabelColor: any[], columnWidth: number, formatOptions: TDefaultChartFormatOptionsType, height: number, width: number, innerWidth: number, dimensionList: string[], innerHeight: number, widgetId: string, svg: any, onDataLabelCoordinatesChange: (coordinates: any[]) => void, xScaleForLegends: any, isReportEditable: boolean): void;
|
|
473
447
|
/**
|
|
474
448
|
* Pre-calculates data table layout information based on format options and series data.
|
|
475
449
|
*
|
|
@@ -499,7 +473,7 @@ export declare const dataTablePreCalculation: (formatOptions: TDefaultChartForma
|
|
|
499
473
|
* @param {Function} getBarColor - Function to get bar colors.
|
|
500
474
|
* @param {boolean} isColorScaleApplied - Flag indicating if color scaling is applied.
|
|
501
475
|
* @param {number} dataTableHeight - Total height reserved for the data table.
|
|
502
|
-
* @param {string} chartType - Type of chart (e.g.,
|
|
476
|
+
* @param {string} chartType - Type of chart (e.g., chartTypes.LineChart, "stackColumn").
|
|
503
477
|
* @param {TDefaultChartFormatOptionsType} formatOptions - Formatting options for chart and data table.
|
|
504
478
|
* @param {number} yLabel - Space allocated for y-axis labels.
|
|
505
479
|
* @param {number} yTitle - Space allocated for y-axis title.
|
|
@@ -583,7 +557,7 @@ export declare function prepareDataForSeriesLabel(innerWidth: number, yScaleLeft
|
|
|
583
557
|
*
|
|
584
558
|
* @return - void. This function performs side effects by rendering annotations onto the provided SVG element.
|
|
585
559
|
*/
|
|
586
|
-
export declare function stacklineAnnotations(chartData: any[], xScale: any, yScaleLeft: any, yScaleRight: any, margin: TMargin, d3Annotation: any, labelExcludeList: string[], individualLabelColor: any[],
|
|
560
|
+
export declare function stacklineAnnotations(chartData: any[], xScale: any, yScaleLeft: any, yScaleRight: any, margin: TMargin, d3Annotation: any, labelExcludeList: string[], individualLabelColor: any[], formatOptions: TDefaultChartFormatOptionsType, chartType: string, height: number, width: number, innerWidth: number, dimensionList: string[], innerHeight: number, widgetId: string, svg: any, onDataLabelCoordinatesChange: (coordinates: any[]) => void, dataTableHeight: number, isReportEditable: boolean, barChart?: boolean): void;
|
|
587
561
|
/**
|
|
588
562
|
* Initializes the X-axis of a bar chart using provided formatting options and axis configuration.
|
|
589
563
|
*
|
|
@@ -619,7 +593,7 @@ export declare const initXaxisBar: (formatOptions: TDefaultChartFormatOptionsTyp
|
|
|
619
593
|
*
|
|
620
594
|
* @returns {void} This function does not return a value; it modifies the chart by rendering or adjusting axes.
|
|
621
595
|
*/
|
|
622
|
-
export declare const initYaxisBar: (formatOptions: TDefaultChartFormatOptionsType, gTag: any, xLabel: number, innerHeight: number, innerWidth: number, yAxis: any, xAxisTop: any, xScaleBottom: any, yMaxLeft: number, dimensionList: string[], chartType: string, isDateType: any, width: number, dimensionHeightWidthArray: number[], columnWidth: number) => void;
|
|
596
|
+
export declare const initYaxisBar: (formatOptions: TDefaultChartFormatOptionsType, gTag: any, xLabel: number, innerHeight: number, innerWidth: number, yAxis: any, xAxisTop: any, xScaleBottom: any, yMaxLeft: number, dimensionList: string[], chartType: string, isDateType: any, width: number, dimensionHeightWidthArray: number[], columnWidth: number, xScale: any) => void;
|
|
623
597
|
export declare const dataLabelsPositionForBarChartFamily: (formatOptions: TDefaultChartFormatOptionsType, xCordinate: number, position: number, xScale: any, minValue: number, prevValue?: number, chartType?: string, isSensitivityChart?: boolean, axis?: string) => any;
|
|
624
598
|
export declare const initXaxisTop: (formatOptions: TDefaultChartFormatOptionsType, gTag: any, xLabelSecondary: number, xAxisTop: any) => void;
|
|
625
599
|
export declare const xAxisTitleTop: (formatOptions: TDefaultChartFormatOptionsType, svg: any, margin: TMargin, isSecondaryAxisDrawn: boolean, xLabelSecondary: number, xTitleSecondary: number) => void;
|
|
@@ -53,6 +53,8 @@ export type TChartProps = {
|
|
|
53
53
|
chartId?: string;
|
|
54
54
|
formatOptions?: TDefaultChartFormatOptionsType;
|
|
55
55
|
isReportEditable?: any;
|
|
56
|
+
isAdvancedAnalyticsWaterFall?: boolean;
|
|
57
|
+
onDataLabelCoordinatesChange?: (coords: any[]) => void;
|
|
56
58
|
};
|
|
57
59
|
export type TChartJSON = {
|
|
58
60
|
dimensionList: string[];
|
|
@@ -294,7 +294,7 @@ export type TData = {
|
|
|
294
294
|
IsadvanceanalyticsChart?: any;
|
|
295
295
|
ChartData: TSeries[];
|
|
296
296
|
DimensionList: string[];
|
|
297
|
-
LegendList:
|
|
297
|
+
LegendList: any[];
|
|
298
298
|
};
|
|
299
299
|
export type TDataPoint = {
|
|
300
300
|
0?: number;
|
|
@@ -304,6 +304,7 @@ export type TDataPoint = {
|
|
|
304
304
|
legend: string;
|
|
305
305
|
hideZero?: boolean;
|
|
306
306
|
axis?: string;
|
|
307
|
+
legendUniqueId?: string;
|
|
307
308
|
key?: string;
|
|
308
309
|
type?: string;
|
|
309
310
|
labelPosition?: string;
|
|
@@ -389,7 +390,7 @@ export type TScatterChartProps = {
|
|
|
389
390
|
formatOptions: TDefaultChartFormatOptionsType;
|
|
390
391
|
};
|
|
391
392
|
export declare enum commonColors {
|
|
392
|
-
white = "#
|
|
393
|
+
white = "#ffffff",
|
|
393
394
|
black = "#000000",
|
|
394
395
|
transparent = "#FFFFFF00"
|
|
395
396
|
}
|
|
@@ -398,4 +399,11 @@ export declare enum tornadoEntryName {
|
|
|
398
399
|
negative = "Negative",
|
|
399
400
|
default = "defaultEntry"
|
|
400
401
|
}
|
|
402
|
+
export declare enum waterfallKeys {
|
|
403
|
+
total = "Total",
|
|
404
|
+
base = "base",
|
|
405
|
+
dimensionTotal = "dimensionTotal",
|
|
406
|
+
up = "up",
|
|
407
|
+
down = "down"
|
|
408
|
+
}
|
|
401
409
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as d3 from "d3";
|
|
2
2
|
import type { TChartJSON } from "../ChartsWithAxis/ChartsWithAxisTypes.types";
|
|
3
3
|
import { TVennSeries } from "../ChartsWithoutAxis/ChartsWithoutAxisTypes.types";
|
|
4
|
-
import { type TAnnotationObject, type TChartMargins, type TDefaultChartFormatOptionsType, type TSeries, type TTextDimensions } from "./Common.types";
|
|
4
|
+
import { type TAnnotationObject, type TChartMargins, TData, type TDataPoint, type TDefaultChartFormatOptionsType, type TSeries, type TTextDimensions } from "./Common.types";
|
|
5
5
|
export declare const svgID = "scaling-svg-";
|
|
6
6
|
export declare function getRandomColor(): {
|
|
7
7
|
color: string;
|
|
@@ -67,7 +67,7 @@ export declare function lineMarkers(lines: any, chartData: TSeries[], type: any,
|
|
|
67
67
|
*
|
|
68
68
|
* @return {void} This function modifies the chart's behavior by adding interactivity but does not return a value.
|
|
69
69
|
*/
|
|
70
|
-
export declare function onHoverMarkerForAreaChartFamily(formatOptions: TDefaultChartFormatOptionsType, areas: any, focus: any, filteredDimension: string[], lineData: any[], xScale: any, yScaleLeft: any, chartType: string): void;
|
|
70
|
+
export declare function onHoverMarkerForAreaChartFamily(formatOptions: TDefaultChartFormatOptionsType, areas: any, focus: any, filteredDimension: string[], lineData: any[], xScale: any, yScaleLeft: any, chartType: string, isStackChart?: boolean): void;
|
|
71
71
|
/**
|
|
72
72
|
* Function to calculate actual height, width of content primarily used for margin calculations
|
|
73
73
|
* @returns { width: 0, height: 0, rotatedWidth: 0, rotatedHeight: 0 }
|
|
@@ -238,3 +238,12 @@ export declare function generalizedChartData(chartData: any, dimensionList?: any
|
|
|
238
238
|
export declare const getJQuerySelector: (strSeletor?: string) => string;
|
|
239
239
|
export declare const connectorNumberFormat: (numerator: any, denominator: any, decimalValues: any, numberFormat: any, x: any, y: any, formatOptions: TDefaultChartFormatOptionsType) => any;
|
|
240
240
|
export declare const getHoverId: (inputText: string) => string;
|
|
241
|
+
export declare function modifySeriesDataForTornadoChart(seriesData: TSeries[], data: TData, isAdvanceAnalyticsChart: boolean): TSeries[] | {
|
|
242
|
+
properties: any;
|
|
243
|
+
legendUniqueId: any;
|
|
244
|
+
Type: any;
|
|
245
|
+
Axis: any;
|
|
246
|
+
AxisDataList: any;
|
|
247
|
+
legend: string;
|
|
248
|
+
data: TDataPoint[];
|
|
249
|
+
}[];
|
|
@@ -51,6 +51,8 @@ export declare const defaultChartFormatOptions: {
|
|
|
51
51
|
xAxisSortBy: string;
|
|
52
52
|
customSort: any[];
|
|
53
53
|
labelTextWrap: boolean;
|
|
54
|
+
multiLineLabelWrap: boolean;
|
|
55
|
+
maxXAxisLabelWidth: number;
|
|
54
56
|
};
|
|
55
57
|
xAxisScale: {
|
|
56
58
|
absoluteXAxisScale: boolean;
|
|
@@ -566,6 +568,7 @@ export declare const defaultChartFormatOptions: {
|
|
|
566
568
|
dataTableDecimalPrecision: string;
|
|
567
569
|
dataTableDisplayUnits: string;
|
|
568
570
|
dataTableLabelColor: commonColors;
|
|
571
|
+
dataTableAxisLabel: boolean;
|
|
569
572
|
};
|
|
570
573
|
dataTableOuterBorder: {
|
|
571
574
|
borderButtonVisibility: boolean;
|