@databrainhq/plugin 0.7.15 → 0.7.16
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/Button/index.d.ts +8 -0
- package/dist/components/ChartModal/ChartConfig.d.ts +18 -0
- package/dist/components/ChartModal/ChartModalOptions.d.ts +6 -0
- package/dist/components/ChartModal/SelectField.d.ts +2 -0
- package/dist/components/ChartModal/index.d.ts +3 -0
- package/dist/components/Charts/AreaChart.d.ts +3 -0
- package/dist/components/Charts/BarChart.d.ts +24 -0
- package/dist/components/Charts/BoxPlot.d.ts +3 -0
- package/dist/components/Charts/BubbleChart.d.ts +3 -0
- package/dist/components/Charts/ComboChart.d.ts +3 -0
- package/dist/components/Charts/DoughnutChart.d.ts +3 -0
- package/dist/components/Charts/FunnelChart.d.ts +3 -0
- package/dist/components/Charts/GaugeChart.d.ts +3 -0
- package/dist/components/Charts/Histogram.d.ts +3 -0
- package/dist/components/Charts/LineChart.d.ts +25 -0
- package/dist/components/Charts/PieChart.d.ts +3 -0
- package/dist/components/Charts/RowChart.d.ts +3 -0
- package/dist/components/Charts/SankeyChart.d.ts +3 -0
- package/dist/components/Charts/ScatterChart.d.ts +3 -0
- package/dist/components/Charts/SingleValueChart/index.d.ts +3 -0
- package/dist/components/Charts/StackedBarChart.d.ts +3 -0
- package/dist/components/Charts/SteppedAreaChart.d.ts +3 -0
- package/dist/components/Charts/Table/TableChart.d.ts +3 -0
- package/dist/components/Charts/WaterfallChart.d.ts +3 -0
- package/dist/components/DataType/index.d.ts +2 -0
- package/dist/components/Error/index.d.ts +6 -0
- package/dist/components/ErrorFallback/index.d.ts +2 -0
- package/dist/components/ExternalMetricForm/index.d.ts +15 -0
- package/dist/components/FilterDropDown/index.d.ts +11 -0
- package/dist/components/FilterField/index.d.ts +21 -0
- package/dist/components/FloatingDropDown/index.d.ts +23 -0
- package/dist/components/FullScreenChart/index.d.ts +9 -0
- package/dist/components/GlobalFilters/index.d.ts +11 -0
- package/dist/components/InfoTooltip/index.d.ts +8 -0
- package/dist/components/InputField/index.d.ts +15 -0
- package/dist/components/MetricChart/CsvDownloadButton.d.ts +10 -0
- package/dist/components/MetricChart/MetricChart.d.ts +36 -0
- package/dist/components/MetricChart/index.d.ts +2 -0
- package/dist/components/MetricCreation/MetricCreation.d.ts +3 -0
- package/dist/components/MetricCreation/components/ConstructMetric/ConstructMetric.d.ts +3 -0
- package/dist/components/MetricCreation/components/ConstructMetric/components/MetricForm/index.d.ts +3 -0
- package/dist/components/MetricCreation/components/ConstructMetric/index.d.ts +2 -0
- package/dist/components/MetricCreation/components/Dataset/index.d.ts +3 -0
- package/dist/components/MetricCreation/components/Header/index.d.ts +3 -0
- package/dist/components/MetricCreation/components/MetricOutput/MetricOutput.d.ts +3 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/ChartTab/components/ChartConfigure/index.d.ts +20 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/ChartTab/components/ChartSettings/index.d.ts +32 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/ChartTab/index.d.ts +50 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/TableTab/components/InputTables/index.d.ts +2 -0
- package/dist/components/MetricCreation/components/MetricOutput/components/TableTab/index.d.ts +9 -0
- package/dist/components/MetricCreation/components/MetricOutput/index.d.ts +3 -0
- package/dist/components/MetricCreation/index.d.ts +5 -0
- package/dist/components/MetricList/MetricList.d.ts +45 -0
- package/dist/components/MetricList/components/MetricCard.d.ts +18 -0
- package/dist/components/MetricList/components/SingleValueCard.d.ts +3 -0
- package/dist/components/MetricList/index.d.ts +3 -0
- package/dist/components/MetricTable/index.d.ts +7 -0
- package/dist/components/Modal/Modal.d.ts +9 -0
- package/dist/components/Modal/ModalFooter.d.ts +5 -0
- package/dist/components/Modal/index.d.ts +2 -0
- package/dist/components/PopoverMenu/index.d.ts +11 -0
- package/dist/components/SearchTab/index.d.ts +2 -0
- package/dist/components/Select/index.d.ts +48 -0
- package/dist/components/Tab/index.d.ts +10 -0
- package/dist/components/Table/index.d.ts +8 -0
- package/dist/components/Text/index.d.ts +11 -0
- package/dist/components/TextAreaField/index.d.ts +19 -0
- package/dist/components/TimeGrainField/index.d.ts +13 -0
- package/dist/components/ToggleButton/index.d.ts +12 -0
- package/dist/components/index.d.ts +27 -0
- package/dist/consts/app.d.ts +39 -0
- package/dist/consts/index.d.ts +2 -0
- package/dist/consts/metricOptions.d.ts +17 -0
- package/dist/containers/Dashboard/Dashboard.d.ts +6 -0
- package/dist/containers/Dashboard/EmbededDashboard.d.ts +12 -0
- package/dist/containers/Dashboard/index.d.ts +2 -0
- package/dist/containers/index.d.ts +1 -0
- package/dist/contexts/globalTheme.d.ts +9 -0
- package/dist/helpers/cardActions.d.ts +4 -0
- package/dist/helpers/getModifiedQuery.d.ts +6 -0
- package/dist/helpers/getTimeFilterValue.d.ts +8 -0
- package/dist/helpers/groupArray.d.ts +1 -0
- package/dist/helpers/groupBy.d.ts +6 -0
- package/dist/helpers/index.d.ts +4 -0
- package/dist/hooks/index.d.ts +5 -0
- package/dist/hooks/useEmbeddedDashboard.d.ts +53 -0
- package/dist/hooks/useExternalMetric.d.ts +39 -0
- package/dist/hooks/useGenerateDatasetMetrics.d.ts +13 -0
- package/dist/hooks/useGenerateEmbeddedMetric.d.ts +15 -0
- package/dist/hooks/useOutsideAlerter.d.ts +7 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.es.js +92114 -0
- package/dist/index.umd.js +340 -0
- package/dist/style.css +1 -0
- package/dist/types/app.d.ts +132 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/metricCreate.d.ts +132 -0
- package/dist/typings.d.ts +17 -0
- package/dist/utils/arrayToCsvString.d.ts +6 -0
- package/dist/utils/colors.d.ts +1 -0
- package/dist/utils/fetcher.d.ts +1 -0
- package/dist/utils/generated/graphql.d.ts +1863 -0
- package/dist/utils/getChartAttributes.d.ts +27 -0
- package/dist/utils/getFormattedDataType.d.ts +1 -0
- package/dist/utils/index.d.ts +5 -0
- package/dist/utils/theme.d.ts +87 -0
- package/package.json +3 -2
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
declare type Params = {
|
|
2
|
+
data: any[] | undefined;
|
|
3
|
+
yAxisList: string[] | undefined;
|
|
4
|
+
xAxis: string | undefined;
|
|
5
|
+
measure: string | undefined;
|
|
6
|
+
step: string | undefined;
|
|
7
|
+
sankeyValues: string[] | undefined;
|
|
8
|
+
singleValue: string | undefined;
|
|
9
|
+
};
|
|
10
|
+
export declare const getChartAttributes: ({ data, measure, sankeyValues, singleValue, step, xAxis, yAxisList, }: Params) => {
|
|
11
|
+
labels: string[];
|
|
12
|
+
datasets: {
|
|
13
|
+
label: string;
|
|
14
|
+
data: any[];
|
|
15
|
+
borderColor: string;
|
|
16
|
+
}[] | undefined;
|
|
17
|
+
funnelData: ("" | {
|
|
18
|
+
value: any;
|
|
19
|
+
name: any;
|
|
20
|
+
} | undefined)[];
|
|
21
|
+
sankeyData: any[][] | undefined;
|
|
22
|
+
singleValueData: ("" | {
|
|
23
|
+
value: any;
|
|
24
|
+
label: string;
|
|
25
|
+
} | undefined)[];
|
|
26
|
+
};
|
|
27
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const getFormattedDataType: (datatype: string) => 'text' | 'number' | 'boolean';
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* colors - object of customizable colors
|
|
3
|
+
* typography - object of customizable typography
|
|
4
|
+
* border - object of customizable border
|
|
5
|
+
* shadow - object of customizable box shadow
|
|
6
|
+
* breakpoint - object of customizable breakpoint
|
|
7
|
+
* metricLayoutCols - object of customizable metric chart layout columns
|
|
8
|
+
*/
|
|
9
|
+
export interface ThemeType {
|
|
10
|
+
colors?: {
|
|
11
|
+
background?: string;
|
|
12
|
+
primary?: string;
|
|
13
|
+
secondary?: string;
|
|
14
|
+
tertiary?: string;
|
|
15
|
+
dark?: string;
|
|
16
|
+
light?: string;
|
|
17
|
+
primaryDark?: string;
|
|
18
|
+
primaryLight?: string;
|
|
19
|
+
secondaryDark?: string;
|
|
20
|
+
secondaryLight?: string;
|
|
21
|
+
tertiaryDark?: string;
|
|
22
|
+
tertiaryLight?: string;
|
|
23
|
+
error?: string;
|
|
24
|
+
errorDark?: string;
|
|
25
|
+
errorLight?: string;
|
|
26
|
+
success?: string;
|
|
27
|
+
successLight?: string;
|
|
28
|
+
successDark?: string;
|
|
29
|
+
warning?: string;
|
|
30
|
+
warningLight?: string;
|
|
31
|
+
warningDark?: string;
|
|
32
|
+
gray50?: string;
|
|
33
|
+
gray100?: string;
|
|
34
|
+
gray200?: string;
|
|
35
|
+
gray300?: string;
|
|
36
|
+
gray400?: string;
|
|
37
|
+
gray500?: string;
|
|
38
|
+
gray600?: string;
|
|
39
|
+
gray700?: string;
|
|
40
|
+
gray800?: string;
|
|
41
|
+
gray900?: string;
|
|
42
|
+
};
|
|
43
|
+
typography?: {
|
|
44
|
+
colorPrimary?: string;
|
|
45
|
+
colorSecondary?: string;
|
|
46
|
+
colorTertiary?: string;
|
|
47
|
+
fontFamily?: string;
|
|
48
|
+
fontSize?: string;
|
|
49
|
+
fontWeightThin?: number;
|
|
50
|
+
fontWeightLight?: number;
|
|
51
|
+
fontWeightRegular?: number;
|
|
52
|
+
fontWeightSemibold?: number;
|
|
53
|
+
fontWeightBold?: number;
|
|
54
|
+
};
|
|
55
|
+
breakpoint?: {
|
|
56
|
+
xl?: number;
|
|
57
|
+
lg?: number;
|
|
58
|
+
md?: number;
|
|
59
|
+
sm?: number;
|
|
60
|
+
xs?: number;
|
|
61
|
+
};
|
|
62
|
+
metricLayoutCols?: {
|
|
63
|
+
xl?: number;
|
|
64
|
+
lg?: number;
|
|
65
|
+
md?: number;
|
|
66
|
+
sm?: number;
|
|
67
|
+
xs?: number;
|
|
68
|
+
xxs?: number;
|
|
69
|
+
};
|
|
70
|
+
border?: {
|
|
71
|
+
radiusNone?: number | string;
|
|
72
|
+
radiusSm?: number | string;
|
|
73
|
+
radiusMd?: number | string;
|
|
74
|
+
radiusDefault?: number | string;
|
|
75
|
+
radiusLg?: number | string;
|
|
76
|
+
radiusXl?: number | string;
|
|
77
|
+
radius2xl?: number | string;
|
|
78
|
+
radius3xl?: number | string;
|
|
79
|
+
radiusFull?: number | string;
|
|
80
|
+
};
|
|
81
|
+
shadow?: {
|
|
82
|
+
primary?: string;
|
|
83
|
+
secondary?: string;
|
|
84
|
+
tertiary?: string;
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
export declare const applyTheme: (theme: ThemeType) => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@databrainhq/plugin",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.16",
|
|
4
4
|
"description": "Databrain app dashboard ui plugin.",
|
|
5
5
|
"author": "",
|
|
6
6
|
"license": "MIT",
|
|
@@ -27,7 +27,8 @@
|
|
|
27
27
|
"husky": "husky install",
|
|
28
28
|
"predeploy": "cd example && npm install && npm run build",
|
|
29
29
|
"lint": "eslint --ext .tsx,.ts --ignore-path .gitignore --fix src",
|
|
30
|
-
"codegen": "graphql-codegen --config codegen.yml -r dotenv/config"
|
|
30
|
+
"codegen": "graphql-codegen --config codegen.yml -r dotenv/config",
|
|
31
|
+
"prepare": "npm run build"
|
|
31
32
|
},
|
|
32
33
|
"devDependencies": {
|
|
33
34
|
"@commitlint/cli": "^17.0.3",
|