drizzle-cube 0.1.23 → 0.1.24
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/client/charts/chartConfigs.d.ts +31 -1
- package/dist/client/charts.d.ts +1 -0
- package/dist/client/charts.js +1 -1
- package/dist/client/chunks/charts-Dx3asDBi.js +2269 -0
- package/dist/client/chunks/charts-Dx3asDBi.js.map +1 -0
- package/dist/client/chunks/{icons-QczkAx61.js → icons-BMGOKdZb.js} +268 -233
- package/dist/client/chunks/icons-BMGOKdZb.js.map +1 -0
- package/dist/client/components/ChartConfigPanel.d.ts +3 -2
- package/dist/client/components/ColorPaletteSelector.d.ts +11 -0
- package/dist/client/components/DashboardGrid.d.ts +3 -1
- package/dist/client/components/DataHistogram.d.ts +23 -0
- package/dist/client/components/PortletEditModal.d.ts +3 -2
- package/dist/client/components/charts/ActivityGridChart.d.ts +1 -1
- package/dist/client/components/charts/AreaChart.d.ts +1 -1
- package/dist/client/components/charts/BarChart.d.ts +1 -1
- package/dist/client/components/charts/BubbleChart.d.ts +1 -1
- package/dist/client/components/charts/KpiNumber.config.d.ts +5 -0
- package/dist/client/components/charts/KpiNumber.d.ts +2 -0
- package/dist/client/components/charts/KpiText.config.d.ts +5 -0
- package/dist/client/components/charts/KpiText.d.ts +2 -0
- package/dist/client/components/charts/LineChart.d.ts +1 -1
- package/dist/client/components/charts/PieChart.d.ts +1 -1
- package/dist/client/components/charts/RadarChart.d.ts +1 -1
- package/dist/client/components/charts/RadialBarChart.d.ts +1 -1
- package/dist/client/components/charts/ScatterChart.d.ts +1 -1
- package/dist/client/components/charts/TreeMapChart.d.ts +1 -1
- package/dist/client/components/charts/index.d.ts +2 -0
- package/dist/client/components.js +4420 -2417
- package/dist/client/components.js.map +1 -1
- package/dist/client/index.d.ts +1 -0
- package/dist/client/index.js +1 -1
- package/dist/client/types.d.ts +12 -4
- package/dist/client/utils/colorPalettes.d.ts +35 -0
- package/dist/client-bundle-stats.html +1 -1
- package/package.json +1 -1
- package/dist/client/chunks/charts-8KmxUVvG.js +0 -2285
- package/dist/client/chunks/charts-8KmxUVvG.js.map +0 -1
- package/dist/client/chunks/icons-QczkAx61.js.map +0 -1
package/dist/client/index.d.ts
CHANGED
|
@@ -11,4 +11,5 @@ export { CubeProvider, useCubeContext } from './providers/CubeProvider';
|
|
|
11
11
|
export { useCubeQuery } from './hooks/useCubeQuery';
|
|
12
12
|
export { createCubeClient } from './client/CubeClient';
|
|
13
13
|
export type { PortletConfig, ChartType, ChartAxisConfig, ChartDisplayConfig, CubeQuery, CubeQueryOptions, CubeApiOptions, DashboardConfig } from './types';
|
|
14
|
+
export type { ChartTypeConfig, DisplayOptionConfig, AxisDropZoneConfig } from './charts/chartConfigs';
|
|
14
15
|
export { createDashboardLayout, formatChartData } from './utils/index';
|
package/dist/client/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AnalyticsDashboard as t, AnalyticsPortlet as e, DashboardEditModal as s, DashboardGrid as o, Modal as h, PortletContainer as C, PortletEditModal as c, QueryBuilder as d } from "./components.js";
|
|
2
2
|
import { C as l, c as u, u as R } from "./chunks/providers-B7MVnAAt.js";
|
|
3
3
|
import { useCubeQuery as n } from "./hooks.js";
|
|
4
|
-
import { D as f, A as P, B as m, L as p, P as x, R as y, a as A, S as B, T as M, c as L, f as T } from "./chunks/charts-
|
|
4
|
+
import { D as f, A as P, B as m, L as p, P as x, R as y, a as A, S as B, T as M, c as L, f as T } from "./chunks/charts-Dx3asDBi.js";
|
|
5
5
|
export {
|
|
6
6
|
t as AnalyticsDashboard,
|
|
7
7
|
e as AnalyticsPortlet,
|
package/dist/client/types.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
* Type definitions for drizzle-cube client components
|
|
3
|
-
*/
|
|
1
|
+
import { ColorPalette } from './utils/colorPalettes';
|
|
4
2
|
export type { CubeMeta, CubeMetaCube, CubeMetaField, FieldLabelMap } from './hooks/useCubeMeta';
|
|
5
|
-
export type
|
|
3
|
+
export type { ColorPalette } from './utils/colorPalettes';
|
|
4
|
+
export type ChartType = 'line' | 'bar' | 'pie' | 'table' | 'area' | 'scatter' | 'radar' | 'radialBar' | 'treemap' | 'bubble' | 'activityGrid' | 'kpiNumber' | 'kpiText';
|
|
6
5
|
export interface ChartAxisConfig {
|
|
7
6
|
xAxis?: string[];
|
|
8
7
|
yAxis?: string[];
|
|
@@ -26,6 +25,12 @@ export interface ChartDisplayConfig {
|
|
|
26
25
|
bubbleOpacity?: number;
|
|
27
26
|
showLabels?: boolean;
|
|
28
27
|
colorIntensity?: 'low' | 'medium' | 'high';
|
|
28
|
+
template?: string;
|
|
29
|
+
prefix?: string;
|
|
30
|
+
suffix?: string;
|
|
31
|
+
decimals?: number;
|
|
32
|
+
valueColor?: string;
|
|
33
|
+
valueColorIndex?: number;
|
|
29
34
|
}
|
|
30
35
|
export interface PortletConfig {
|
|
31
36
|
id: string;
|
|
@@ -44,6 +49,7 @@ export interface DashboardConfig {
|
|
|
44
49
|
layouts?: {
|
|
45
50
|
[key: string]: any;
|
|
46
51
|
};
|
|
52
|
+
colorPalette?: string;
|
|
47
53
|
}
|
|
48
54
|
export type FilterOperator = 'equals' | 'notEquals' | 'contains' | 'notContains' | 'startsWith' | 'notStartsWith' | 'endsWith' | 'notEndsWith' | 'like' | 'notLike' | 'ilike' | 'gt' | 'gte' | 'lt' | 'lte' | 'between' | 'notBetween' | 'in' | 'notIn' | 'set' | 'notSet' | 'isEmpty' | 'isNotEmpty' | 'inDateRange' | 'beforeDate' | 'afterDate' | 'regex' | 'notRegex';
|
|
49
55
|
export interface SimpleFilter {
|
|
@@ -96,6 +102,7 @@ export interface AnalyticsPortletProps {
|
|
|
96
102
|
displayConfig?: ChartDisplayConfig;
|
|
97
103
|
height?: string | number;
|
|
98
104
|
title?: string;
|
|
105
|
+
colorPalette?: ColorPalette;
|
|
99
106
|
onDebugDataReady?: (debugData: {
|
|
100
107
|
chartConfig: ChartAxisConfig;
|
|
101
108
|
displayConfig: ChartDisplayConfig;
|
|
@@ -117,6 +124,7 @@ export interface ChartProps {
|
|
|
117
124
|
displayConfig?: ChartDisplayConfig;
|
|
118
125
|
queryObject?: CubeQuery;
|
|
119
126
|
height?: string | number;
|
|
127
|
+
colorPalette?: ColorPalette;
|
|
120
128
|
}
|
|
121
129
|
export interface FeaturesConfig {
|
|
122
130
|
enableAI?: boolean;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Unified Color Palette System
|
|
3
|
+
* Each palette contains coordinated series and gradient colors that work well together
|
|
4
|
+
*/
|
|
5
|
+
export interface ColorPalette {
|
|
6
|
+
name: string;
|
|
7
|
+
label: string;
|
|
8
|
+
colors: string[];
|
|
9
|
+
gradient: string[];
|
|
10
|
+
}
|
|
11
|
+
export declare const COLOR_PALETTES: ColorPalette[];
|
|
12
|
+
/**
|
|
13
|
+
* Get a color palette by name, with fallback to default
|
|
14
|
+
*/
|
|
15
|
+
export declare function getColorPalette(paletteName?: string): ColorPalette;
|
|
16
|
+
/**
|
|
17
|
+
* Get just the series colors for a palette
|
|
18
|
+
*/
|
|
19
|
+
export declare function getSeriesColors(paletteName?: string): string[];
|
|
20
|
+
/**
|
|
21
|
+
* Get just the gradient colors for a palette
|
|
22
|
+
*/
|
|
23
|
+
export declare function getGradientColors(paletteName?: string): string[];
|
|
24
|
+
/**
|
|
25
|
+
* Chart types that use series colors (discrete categories)
|
|
26
|
+
*/
|
|
27
|
+
export declare const SERIES_CHART_TYPES: readonly ["bar", "line", "area", "pie", "scatter", "radar", "radialBar", "treeMap"];
|
|
28
|
+
/**
|
|
29
|
+
* Chart types that use gradient colors (continuous values)
|
|
30
|
+
*/
|
|
31
|
+
export declare const GRADIENT_CHART_TYPES: readonly ["bubble", "activityGrid"];
|
|
32
|
+
/**
|
|
33
|
+
* Determine if a chart type uses gradient colors
|
|
34
|
+
*/
|
|
35
|
+
export declare function usesGradientColors(chartType: string): boolean;
|