@databrainhq/plugin 0.11.38 → 0.12.0

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.
Files changed (36) hide show
  1. package/dist/components/ExternalMetricForm/index.d.ts +2 -2
  2. package/dist/components/MetricCreation/MetricCreation.d.ts +1 -1
  3. package/dist/components/MetricList/MetricList.d.ts +1 -2
  4. package/dist/components/MetricList/components/DownloadRawCsvModal/index.d.ts +1 -1
  5. package/dist/components/MetricList/components/FullScreenView/index.d.ts +1 -1
  6. package/dist/components/MetricList/components/MetricCards/MetricCard.d.ts +1 -1
  7. package/dist/components/MetricList/components/index.d.ts +0 -1
  8. package/dist/components/Table/index.d.ts +2 -1
  9. package/dist/consts/api.d.ts +37 -0
  10. package/dist/hooks/index.d.ts +0 -2
  11. package/dist/hooks/useApplyAdminTheme.d.ts +1 -2
  12. package/dist/hooks/useDashboardContext.d.ts +4 -4
  13. package/dist/hooks/useDownloadRawCsv.d.ts +6 -44
  14. package/dist/hooks/useEmbeddedMetric.d.ts +2 -3
  15. package/dist/hooks/useExternalMetric.d.ts +14 -3
  16. package/dist/hooks/useGenerateDatasetMetrics.d.ts +9 -11
  17. package/dist/hooks/useMetricCard.d.ts +1 -2
  18. package/dist/hooks/useNewEmbeddedDashboard.d.ts +4 -4
  19. package/dist/hooks/useScheduleEmail.d.ts +2 -11
  20. package/dist/queries/externalDashboard.mutation.d.ts +43 -0
  21. package/dist/queries/externalDashboard.query.d.ts +13 -0
  22. package/dist/queries/metric.mutation.d.ts +13 -0
  23. package/dist/queries/metric.query.d.ts +7 -0
  24. package/dist/types/app.d.ts +5 -0
  25. package/dist/types/metricCreate.d.ts +1 -1
  26. package/dist/types/queryTypes.d.ts +239 -0
  27. package/dist/utils/fetcher.d.ts +10 -1
  28. package/dist/utils/getChartAttributes.d.ts +2 -1
  29. package/dist/webcomponents.es.js +32083 -32473
  30. package/dist/webcomponents.umd.js +241 -575
  31. package/package.json +1 -2
  32. package/dist/components/MetricList/components/MetricCards/SingleValueCard.d.ts +0 -3
  33. package/dist/helpers/timesAgo.d.ts +0 -2
  34. package/dist/hooks/useEmbeddedDashboard.d.ts +0 -67
  35. package/dist/hooks/useGenerateEmbeddedMetric.d.ts +0 -15
  36. package/dist/utils/generated/graphql.d.ts +0 -4514
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@databrainhq/plugin",
3
- "version": "0.11.38",
3
+ "version": "0.12.0",
4
4
  "description": "Databrain app ui plugin.",
5
5
  "author": "",
6
6
  "license": "MIT",
@@ -25,7 +25,6 @@
25
25
  "husky": "husky install",
26
26
  "predeploy": "cd example && npm install && npm run build",
27
27
  "lint": "eslint --ext .tsx,.ts --ignore-path .gitignore --fix src",
28
- "codegen": "graphql-codegen --config codegen.yml -r dotenv/config",
29
28
  "prepare": "npm run build",
30
29
  "storybook:repl": "storybook dev -p 6006 --host 0.0.0.0",
31
30
  "storybook": "storybook dev -p 6006",
@@ -1,3 +0,0 @@
1
- import React from 'react';
2
- import { MetricCardProps } from '@/components/MetricList/components/MetricCards/MetricCard';
3
- export declare const SingleValueCard: React.FC<Omit<MetricCardProps, 'onMaximize'>>;
@@ -1,2 +0,0 @@
1
- declare const timeAgo: (unixTimestamp: number) => string;
2
- export default timeAgo;
@@ -1,67 +0,0 @@
1
- export declare const useEmbeddedDashboard: ({ token, dashboardId, }: {
2
- token: string;
3
- dashboardId?: string | undefined;
4
- }) => {
5
- isLoading: boolean;
6
- data: {
7
- clientId: string | undefined;
8
- companyId: any;
9
- isLiveMode: any;
10
- externalDashboardMetrics: {
11
- __typename?: "externalDashboardMetrics" | undefined;
12
- externalMetricId: any;
13
- externalDashboardId: any;
14
- externalMetric: {
15
- __typename?: "externalMetrics" | undefined;
16
- chartOptions: any;
17
- clientId?: string | null | undefined;
18
- companyId: any;
19
- companyIntegrationId: any;
20
- createdAt: any;
21
- createdBy?: string | null | undefined;
22
- description: string;
23
- id: any;
24
- inputFields?: any;
25
- integrationName: string;
26
- isCreatedByClient: boolean;
27
- isLive: boolean;
28
- metricId: string;
29
- metricQuery?: string | null | undefined;
30
- name: string;
31
- outputColumns?: string | null | undefined;
32
- query: string;
33
- timeGrain?: string | null | undefined;
34
- updatedAt: any;
35
- selectedGroupBy: any;
36
- isEnableGroupBy: boolean;
37
- groupBy: any;
38
- resizeAttributes: any;
39
- rlsConditions: any;
40
- clickActions: any;
41
- drillDownSettings?: any;
42
- datasetMetricSettings?: any;
43
- companyIntegration: {
44
- __typename?: "companyIntegrations" | undefined;
45
- name: string;
46
- workspaceId: any;
47
- };
48
- };
49
- }[] | undefined;
50
- externalDashboard: {
51
- __typename?: "externalDashboards" | undefined;
52
- id: any;
53
- name: string;
54
- filters: any;
55
- layout: any;
56
- } | undefined;
57
- externalDashboardId: any;
58
- rlsSettings: any;
59
- companyTenancyType: any;
60
- isAllowedToCreateMetrics: boolean;
61
- isAllowedToDeleteMetrics: boolean;
62
- isAllowedToUpdateMetrics: boolean;
63
- isAllowedToChangeLayout: boolean;
64
- workspace: any;
65
- sharingSettingsId: any;
66
- };
67
- };
@@ -1,15 +0,0 @@
1
- /// <reference types="react" />
2
- import { FieldValues } from 'react-hook-form';
3
- type Params = {
4
- clientId: string | null;
5
- companyId: string | null;
6
- setError: React.Dispatch<React.SetStateAction<string>>;
7
- setLoading: React.Dispatch<React.SetStateAction<boolean>>;
8
- setData: React.Dispatch<React.SetStateAction<any[] | undefined>>;
9
- setQuery: React.Dispatch<React.SetStateAction<string>>;
10
- setMetricQuery: React.Dispatch<React.SetStateAction<string | undefined>>;
11
- };
12
- export declare const useGenerateEmbeddedMetric: ({ clientId, companyId, setData, setError, setLoading, setQuery, setMetricQuery, }: Params) => {
13
- generateEmbeddedMetric: (data: FieldValues) => void;
14
- };
15
- export {};