@quillsql/react 2.10.1 → 2.10.3
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/cjs/Chart.d.ts +39 -12
- package/dist/cjs/Chart.d.ts.map +1 -1
- package/dist/cjs/Chart.js +2 -2
- package/dist/esm/Chart.d.ts +39 -12
- package/dist/esm/Chart.d.ts.map +1 -1
- package/dist/esm/Chart.js +2 -2
- package/package.json +1 -1
package/dist/cjs/Chart.d.ts
CHANGED
|
@@ -1,16 +1,43 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
2
|
+
interface BaseChartProps {
|
|
3
|
+
colors: string[];
|
|
4
|
+
containerStyle?: React.CSSProperties;
|
|
5
|
+
dashboard: any;
|
|
6
|
+
dispatch: any;
|
|
7
|
+
client: any;
|
|
8
|
+
dateFilter?: any;
|
|
9
|
+
theme: any;
|
|
10
|
+
isDateFilter?: boolean;
|
|
11
|
+
isAnimationActive?: boolean;
|
|
12
|
+
hideXAxis?: boolean;
|
|
13
|
+
hideYAxis?: boolean;
|
|
14
|
+
hideCartesionGrid?: boolean;
|
|
15
|
+
}
|
|
16
|
+
interface WithChartId extends BaseChartProps {
|
|
3
17
|
chartId: string;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
18
|
+
}
|
|
19
|
+
export type FieldFormat = 'whole_number' | 'one_decimal_place' | 'two_decimal_places' | 'dollar_amount' | 'dollar_cents' | 'MMM_yyyy' | 'MMM_dd_yyyy' | 'MMM_dd-MMM_dd' | 'MMM_dd_hh:mm_ap_pm' | 'hh_ap_pm' | 'percent' | 'string';
|
|
20
|
+
interface YAxisField {
|
|
21
|
+
label: string;
|
|
22
|
+
field: string;
|
|
23
|
+
chartType: string;
|
|
24
|
+
format: FieldFormat;
|
|
25
|
+
}
|
|
26
|
+
export interface DashboardItem {
|
|
27
|
+
name: string;
|
|
28
|
+
chartType: string;
|
|
29
|
+
xAxisField: string;
|
|
30
|
+
xAxisLabel: string;
|
|
31
|
+
xAxisFormat: FieldFormat;
|
|
32
|
+
yAxisFields: YAxisField[];
|
|
33
|
+
rows: any[];
|
|
34
|
+
columns: any[];
|
|
35
|
+
pivot: any;
|
|
36
|
+
}
|
|
37
|
+
interface WithConfig extends BaseChartProps {
|
|
38
|
+
config: DashboardItem | any;
|
|
39
|
+
}
|
|
40
|
+
type ChartProps = WithChartId | WithConfig;
|
|
41
|
+
declare const Chart: ({ chartId, config, colors, containerStyle, query, SelectComponent, dateRangeFilterDisabled, isAnimationActive, hideXAxis, hideYAxis, hideCartesionGrid, }: ChartProps) => import("react/jsx-runtime").JSX.Element;
|
|
15
42
|
export default Chart;
|
|
16
43
|
//# sourceMappingURL=Chart.d.ts.map
|
package/dist/cjs/Chart.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Chart.d.ts","sourceRoot":"","sources":["../../src/Chart.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Chart.d.ts","sourceRoot":"","sources":["../../src/Chart.tsx"],"names":[],"mappings":";AAyBA,UAAU,cAAc;IACtB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,cAAc,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACrC,SAAS,EAAE,GAAG,CAAC;IACf,QAAQ,EAAE,GAAG,CAAC;IACd,MAAM,EAAE,GAAG,CAAC;IACZ,UAAU,CAAC,EAAE,GAAG,CAAC;IACjB,KAAK,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAED,UAAU,WAAY,SAAQ,cAAc;IAC1C,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,WAAW,GACnB,cAAc,GACd,mBAAmB,GACnB,oBAAoB,GACpB,eAAe,GACf,cAAc,GACd,UAAU,GACV,aAAa,GACb,eAAe,GACf,oBAAoB,GACpB,UAAU,GACV,SAAS,GACT,QAAQ,CAAC;AAEb,UAAU,UAAU;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,WAAW,CAAC;CACrB;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,WAAW,CAAC;IACzB,WAAW,EAAE,UAAU,EAAE,CAAC;IAC1B,IAAI,EAAE,GAAG,EAAE,CAAC;IACZ,OAAO,EAAE,GAAG,EAAE,CAAC;IACf,KAAK,EAAE,GAAG,CAAC;CACZ;AAED,UAAU,UAAW,SAAQ,cAAc;IACzC,MAAM,EAAE,aAAa,GAAG,GAAG,CAAC;CAC7B;AAED,KAAK,UAAU,GAAG,WAAW,GAAG,UAAU,CAAC;AAgF3C,QAAA,MAAM,KAAK,8JAYR,UAAU,4CAkCZ,CAAC;AA2hBF,eAAe,KAAK,CAAC"}
|
package/dist/cjs/Chart.js
CHANGED
|
@@ -78,7 +78,7 @@ function hashCode(s) {
|
|
|
78
78
|
return a & a;
|
|
79
79
|
}, 0);
|
|
80
80
|
}
|
|
81
|
-
const Chart = ({ chartId, config, colors, containerStyle, query, SelectComponent,
|
|
81
|
+
const Chart = ({ chartId, config, colors, containerStyle, query, SelectComponent, dateRangeFilterDisabled = false, isAnimationActive = true, hideXAxis = false, hideYAxis = false, hideCartesionGrid = false, }) => {
|
|
82
82
|
const { dispatch, dashboard } = (0, react_1.useContext)(Context_1.DashboardContext);
|
|
83
83
|
const { dashboardFilters } = (0, react_1.useContext)(Context_1.DashboardFiltersContext);
|
|
84
84
|
// eslint-disable-next-line no-unused-vars
|
|
@@ -91,7 +91,7 @@ const Chart = ({ chartId, config, colors, containerStyle, query, SelectComponent
|
|
|
91
91
|
? theme.chartColors
|
|
92
92
|
: ['#4E80EE', '#E14F62', '#55B5A6', '#E9A23B', '#6466E9', '#55B685'];
|
|
93
93
|
}, [colors]);
|
|
94
|
-
return ((0, jsx_runtime_1.jsx)(ChartUpdater, { config: config, dispatch: dispatch, dashboard: dashboard, chartId: chartId, containerStyle: containerStyle, colors: chartColors, client: client, theme: theme, dashboardFilters: dashboardFilters, query: query,
|
|
94
|
+
return ((0, jsx_runtime_1.jsx)(ChartUpdater, { config: config, dispatch: dispatch, dashboard: dashboard, chartId: chartId, containerStyle: containerStyle, colors: chartColors, client: client, theme: theme, dashboardFilters: dashboardFilters, query: query, isAnimationActive: isAnimationActive, hideXAxis: hideXAxis, hideYAxis: hideYAxis, hideCartesionGrid: hideCartesionGrid, dateRangeFilterDisabled: dateRangeFilterDisabled }));
|
|
95
95
|
};
|
|
96
96
|
const ChartUpdater = ({ colors, chartId, config, containerStyle, dashboard, dispatch, client, theme, dashboardFilters, isAnimationActive, hideXAxis, hideYAxis, hideCartesionGrid, dateRangeFilterDisabled, }) => {
|
|
97
97
|
const [loading, setLoading] = (0, react_1.useState)(false);
|
package/dist/esm/Chart.d.ts
CHANGED
|
@@ -1,16 +1,43 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
2
|
+
interface BaseChartProps {
|
|
3
|
+
colors: string[];
|
|
4
|
+
containerStyle?: React.CSSProperties;
|
|
5
|
+
dashboard: any;
|
|
6
|
+
dispatch: any;
|
|
7
|
+
client: any;
|
|
8
|
+
dateFilter?: any;
|
|
9
|
+
theme: any;
|
|
10
|
+
isDateFilter?: boolean;
|
|
11
|
+
isAnimationActive?: boolean;
|
|
12
|
+
hideXAxis?: boolean;
|
|
13
|
+
hideYAxis?: boolean;
|
|
14
|
+
hideCartesionGrid?: boolean;
|
|
15
|
+
}
|
|
16
|
+
interface WithChartId extends BaseChartProps {
|
|
3
17
|
chartId: string;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
18
|
+
}
|
|
19
|
+
export type FieldFormat = 'whole_number' | 'one_decimal_place' | 'two_decimal_places' | 'dollar_amount' | 'dollar_cents' | 'MMM_yyyy' | 'MMM_dd_yyyy' | 'MMM_dd-MMM_dd' | 'MMM_dd_hh:mm_ap_pm' | 'hh_ap_pm' | 'percent' | 'string';
|
|
20
|
+
interface YAxisField {
|
|
21
|
+
label: string;
|
|
22
|
+
field: string;
|
|
23
|
+
chartType: string;
|
|
24
|
+
format: FieldFormat;
|
|
25
|
+
}
|
|
26
|
+
export interface DashboardItem {
|
|
27
|
+
name: string;
|
|
28
|
+
chartType: string;
|
|
29
|
+
xAxisField: string;
|
|
30
|
+
xAxisLabel: string;
|
|
31
|
+
xAxisFormat: FieldFormat;
|
|
32
|
+
yAxisFields: YAxisField[];
|
|
33
|
+
rows: any[];
|
|
34
|
+
columns: any[];
|
|
35
|
+
pivot: any;
|
|
36
|
+
}
|
|
37
|
+
interface WithConfig extends BaseChartProps {
|
|
38
|
+
config: DashboardItem | any;
|
|
39
|
+
}
|
|
40
|
+
type ChartProps = WithChartId | WithConfig;
|
|
41
|
+
declare const Chart: ({ chartId, config, colors, containerStyle, query, SelectComponent, dateRangeFilterDisabled, isAnimationActive, hideXAxis, hideYAxis, hideCartesionGrid, }: ChartProps) => import("react/jsx-runtime").JSX.Element;
|
|
15
42
|
export default Chart;
|
|
16
43
|
//# sourceMappingURL=Chart.d.ts.map
|
package/dist/esm/Chart.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Chart.d.ts","sourceRoot":"","sources":["../../src/Chart.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"Chart.d.ts","sourceRoot":"","sources":["../../src/Chart.tsx"],"names":[],"mappings":";AAyBA,UAAU,cAAc;IACtB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,cAAc,CAAC,EAAE,KAAK,CAAC,aAAa,CAAC;IACrC,SAAS,EAAE,GAAG,CAAC;IACf,QAAQ,EAAE,GAAG,CAAC;IACd,MAAM,EAAE,GAAG,CAAC;IACZ,UAAU,CAAC,EAAE,GAAG,CAAC;IACjB,KAAK,EAAE,GAAG,CAAC;IACX,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAED,UAAU,WAAY,SAAQ,cAAc;IAC1C,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,WAAW,GACnB,cAAc,GACd,mBAAmB,GACnB,oBAAoB,GACpB,eAAe,GACf,cAAc,GACd,UAAU,GACV,aAAa,GACb,eAAe,GACf,oBAAoB,GACpB,UAAU,GACV,SAAS,GACT,QAAQ,CAAC;AAEb,UAAU,UAAU;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,WAAW,CAAC;CACrB;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,WAAW,CAAC;IACzB,WAAW,EAAE,UAAU,EAAE,CAAC;IAC1B,IAAI,EAAE,GAAG,EAAE,CAAC;IACZ,OAAO,EAAE,GAAG,EAAE,CAAC;IACf,KAAK,EAAE,GAAG,CAAC;CACZ;AAED,UAAU,UAAW,SAAQ,cAAc;IACzC,MAAM,EAAE,aAAa,GAAG,GAAG,CAAC;CAC7B;AAED,KAAK,UAAU,GAAG,WAAW,GAAG,UAAU,CAAC;AAgF3C,QAAA,MAAM,KAAK,8JAYR,UAAU,4CAkCZ,CAAC;AA2hBF,eAAe,KAAK,CAAC"}
|
package/dist/esm/Chart.js
CHANGED
|
@@ -73,7 +73,7 @@ function hashCode(s) {
|
|
|
73
73
|
return a & a;
|
|
74
74
|
}, 0);
|
|
75
75
|
}
|
|
76
|
-
const Chart = ({ chartId, config, colors, containerStyle, query, SelectComponent,
|
|
76
|
+
const Chart = ({ chartId, config, colors, containerStyle, query, SelectComponent, dateRangeFilterDisabled = false, isAnimationActive = true, hideXAxis = false, hideYAxis = false, hideCartesionGrid = false, }) => {
|
|
77
77
|
const { dispatch, dashboard } = useContext(DashboardContext);
|
|
78
78
|
const { dashboardFilters } = useContext(DashboardFiltersContext);
|
|
79
79
|
// eslint-disable-next-line no-unused-vars
|
|
@@ -86,7 +86,7 @@ const Chart = ({ chartId, config, colors, containerStyle, query, SelectComponent
|
|
|
86
86
|
? theme.chartColors
|
|
87
87
|
: ['#4E80EE', '#E14F62', '#55B5A6', '#E9A23B', '#6466E9', '#55B685'];
|
|
88
88
|
}, [colors]);
|
|
89
|
-
return (_jsx(ChartUpdater, { config: config, dispatch: dispatch, dashboard: dashboard, chartId: chartId, containerStyle: containerStyle, colors: chartColors, client: client, theme: theme, dashboardFilters: dashboardFilters, query: query,
|
|
89
|
+
return (_jsx(ChartUpdater, { config: config, dispatch: dispatch, dashboard: dashboard, chartId: chartId, containerStyle: containerStyle, colors: chartColors, client: client, theme: theme, dashboardFilters: dashboardFilters, query: query, isAnimationActive: isAnimationActive, hideXAxis: hideXAxis, hideYAxis: hideYAxis, hideCartesionGrid: hideCartesionGrid, dateRangeFilterDisabled: dateRangeFilterDisabled }));
|
|
90
90
|
};
|
|
91
91
|
const ChartUpdater = ({ colors, chartId, config, containerStyle, dashboard, dispatch, client, theme, dashboardFilters, isAnimationActive, hideXAxis, hideYAxis, hideCartesionGrid, dateRangeFilterDisabled, }) => {
|
|
92
92
|
const [loading, setLoading] = useState(false);
|