@luzmo/embed 6.0.1 → 6.1.0-beta.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 (200) hide show
  1. package/CHANGELOG.md +5 -1
  2. package/MIGRATIONS.md +1 -1
  3. package/README.md +121 -15
  4. package/index.cjs +52769 -28
  5. package/index.d.ts +4 -1
  6. package/index.js +52768 -30
  7. package/lib/dashboard-component/dashboard-base.d.ts +7 -7
  8. package/lib/viz-item/viz-item-component.d.ts +4 -0
  9. package/lib/viz-item/viz-item.base.d.ts +73 -0
  10. package/libs/dashboard-contents-types/index.d.ts +2 -0
  11. package/libs/dashboard-contents-types/json-schemas.d.ts +1 -0
  12. package/libs/dashboard-contents-types/src/index.d.ts +27 -0
  13. package/libs/dashboard-contents-types/src/lib/area-chart/area-chart-options.d.ts +330 -0
  14. package/libs/dashboard-contents-types/src/lib/area-chart/area-chart-slots.d.ts +39 -0
  15. package/libs/dashboard-contents-types/src/lib/area-chart/area-chart.d.ts +23 -0
  16. package/libs/dashboard-contents-types/src/lib/area-chart/index.d.ts +3 -0
  17. package/libs/dashboard-contents-types/src/lib/bar-chart/bar-chart-options.d.ts +257 -0
  18. package/libs/dashboard-contents-types/src/lib/bar-chart/bar-chart.d.ts +23 -0
  19. package/libs/dashboard-contents-types/src/lib/bar-chart/bar-chart.slots.d.ts +39 -0
  20. package/libs/dashboard-contents-types/src/lib/bar-chart/index.d.ts +3 -0
  21. package/libs/dashboard-contents-types/src/lib/box-plot/box-plot-options.d.ts +310 -0
  22. package/libs/dashboard-contents-types/src/lib/box-plot/box-plot-slots.d.ts +30 -0
  23. package/libs/dashboard-contents-types/src/lib/box-plot/box-plot.d.ts +23 -0
  24. package/libs/dashboard-contents-types/src/lib/box-plot/index.d.ts +3 -0
  25. package/libs/dashboard-contents-types/src/lib/bubble-chart/bubble-chart-options.d.ts +98 -0
  26. package/libs/dashboard-contents-types/src/lib/bubble-chart/bubble-chart-slots.d.ts +41 -0
  27. package/libs/dashboard-contents-types/src/lib/bubble-chart/bubble-chart.d.ts +23 -0
  28. package/libs/dashboard-contents-types/src/lib/bubble-chart/index.d.ts +3 -0
  29. package/libs/dashboard-contents-types/src/lib/bullet-chart/bullet-chart-options.d.ts +99 -0
  30. package/libs/dashboard-contents-types/src/lib/bullet-chart/bullet-chart-slots.d.ts +40 -0
  31. package/libs/dashboard-contents-types/src/lib/bullet-chart/bullet-chart.d.ts +23 -0
  32. package/libs/dashboard-contents-types/src/lib/bullet-chart/index.d.ts +3 -0
  33. package/libs/dashboard-contents-types/src/lib/choropleth-map/choropleth-map-options.d.ts +138 -0
  34. package/libs/dashboard-contents-types/src/lib/choropleth-map/choropleth-map-slots.d.ts +41 -0
  35. package/libs/dashboard-contents-types/src/lib/choropleth-map/choropleth-map.d.ts +23 -0
  36. package/libs/dashboard-contents-types/src/lib/choropleth-map/index.d.ts +3 -0
  37. package/libs/dashboard-contents-types/src/lib/circular-gauge/circular-gauge-options.d.ts +122 -0
  38. package/libs/dashboard-contents-types/src/lib/circular-gauge/circular-gauge-slots.d.ts +29 -0
  39. package/libs/dashboard-contents-types/src/lib/circular-gauge/circular-gauge.d.ts +23 -0
  40. package/libs/dashboard-contents-types/src/lib/circular-gauge/index.d.ts +3 -0
  41. package/libs/dashboard-contents-types/src/lib/column-chart/column-chart-options.d.ts +258 -0
  42. package/libs/dashboard-contents-types/src/lib/column-chart/column-chart-slots.d.ts +39 -0
  43. package/libs/dashboard-contents-types/src/lib/column-chart/column-chart.d.ts +23 -0
  44. package/libs/dashboard-contents-types/src/lib/column-chart/index.d.ts +3 -0
  45. package/libs/dashboard-contents-types/src/lib/combination-chart/combination-chart-options.d.ts +344 -0
  46. package/libs/dashboard-contents-types/src/lib/combination-chart/combination-chart-slots.d.ts +28 -0
  47. package/libs/dashboard-contents-types/src/lib/combination-chart/combination-chart.d.ts +23 -0
  48. package/libs/dashboard-contents-types/src/lib/combination-chart/index.d.ts +3 -0
  49. package/libs/dashboard-contents-types/src/lib/conditional-number/conditional-number-options.d.ts +94 -0
  50. package/libs/dashboard-contents-types/src/lib/conditional-number/conditional-number-slots.d.ts +29 -0
  51. package/libs/dashboard-contents-types/src/lib/conditional-number/conditional-number.d.ts +23 -0
  52. package/libs/dashboard-contents-types/src/lib/conditional-number/index.d.ts +3 -0
  53. package/libs/dashboard-contents-types/src/lib/date-filter/date-filter-options.d.ts +147 -0
  54. package/libs/dashboard-contents-types/src/lib/date-filter/date-filter-slots.d.ts +18 -0
  55. package/libs/dashboard-contents-types/src/lib/date-filter/date-filter.d.ts +23 -0
  56. package/libs/dashboard-contents-types/src/lib/date-filter/index.d.ts +3 -0
  57. package/libs/dashboard-contents-types/src/lib/donut-chart/donut-chart-options.d.ts +130 -0
  58. package/libs/dashboard-contents-types/src/lib/donut-chart/donut-chart-slots.d.ts +28 -0
  59. package/libs/dashboard-contents-types/src/lib/donut-chart/donut-chart.d.ts +23 -0
  60. package/libs/dashboard-contents-types/src/lib/donut-chart/index.d.ts +3 -0
  61. package/libs/dashboard-contents-types/src/lib/dropdown-filter/dropdown-filter-options.d.ts +84 -0
  62. package/libs/dashboard-contents-types/src/lib/dropdown-filter/dropdown-filter-slots.d.ts +17 -0
  63. package/libs/dashboard-contents-types/src/lib/dropdown-filter/dropdown-filter.d.ts +23 -0
  64. package/libs/dashboard-contents-types/src/lib/dropdown-filter/index.d.ts +3 -0
  65. package/libs/dashboard-contents-types/src/lib/evolution-number/evolution-number-options.d.ts +185 -0
  66. package/libs/dashboard-contents-types/src/lib/evolution-number/evolution-number-slots.d.ts +29 -0
  67. package/libs/dashboard-contents-types/src/lib/evolution-number/evolution-number.d.ts +23 -0
  68. package/libs/dashboard-contents-types/src/lib/evolution-number/index.d.ts +3 -0
  69. package/libs/dashboard-contents-types/src/lib/funnel-chart/funnel-chart-options.d.ts +110 -0
  70. package/libs/dashboard-contents-types/src/lib/funnel-chart/funnel-chart-slots.d.ts +29 -0
  71. package/libs/dashboard-contents-types/src/lib/funnel-chart/funnel-chart.d.ts +23 -0
  72. package/libs/dashboard-contents-types/src/lib/funnel-chart/index.d.ts +3 -0
  73. package/libs/dashboard-contents-types/src/lib/image/image-options.d.ts +63 -0
  74. package/libs/dashboard-contents-types/src/lib/image/image.d.ts +16 -0
  75. package/libs/dashboard-contents-types/src/lib/image/index.d.ts +2 -0
  76. package/libs/dashboard-contents-types/src/lib/line-chart/index.d.ts +3 -0
  77. package/libs/dashboard-contents-types/src/lib/line-chart/line-chart-options.d.ts +354 -0
  78. package/libs/dashboard-contents-types/src/lib/line-chart/line-chart-slots.d.ts +39 -0
  79. package/libs/dashboard-contents-types/src/lib/line-chart/line-chart.d.ts +23 -0
  80. package/libs/dashboard-contents-types/src/lib/pivot-table/index.d.ts +3 -0
  81. package/libs/dashboard-contents-types/src/lib/pivot-table/pivot-table-options.d.ts +206 -0
  82. package/libs/dashboard-contents-types/src/lib/pivot-table/pivot-table-slots.d.ts +37 -0
  83. package/libs/dashboard-contents-types/src/lib/pivot-table/pivot-table.d.ts +23 -0
  84. package/libs/dashboard-contents-types/src/lib/regular-table/index.d.ts +3 -0
  85. package/libs/dashboard-contents-types/src/lib/regular-table/regular-table-options.d.ts +124 -0
  86. package/libs/dashboard-contents-types/src/lib/regular-table/regular-table-slots.d.ts +17 -0
  87. package/libs/dashboard-contents-types/src/lib/regular-table/regular-table.d.ts +23 -0
  88. package/libs/dashboard-contents-types/src/lib/sankey-diagram/index.d.ts +3 -0
  89. package/libs/dashboard-contents-types/src/lib/sankey-diagram/sankey-diagram-options.d.ts +122 -0
  90. package/libs/dashboard-contents-types/src/lib/sankey-diagram/sankey-diagram-slots.d.ts +50 -0
  91. package/libs/dashboard-contents-types/src/lib/sankey-diagram/sankey-diagram.d.ts +23 -0
  92. package/libs/dashboard-contents-types/src/lib/scatter-plot/index.d.ts +3 -0
  93. package/libs/dashboard-contents-types/src/lib/scatter-plot/scatter-plot-options.d.ts +212 -0
  94. package/libs/dashboard-contents-types/src/lib/scatter-plot/scatter-plot-slots.d.ts +61 -0
  95. package/libs/dashboard-contents-types/src/lib/scatter-plot/scatter-plot.d.ts +23 -0
  96. package/libs/dashboard-contents-types/src/lib/shared/axes.d.ts +35 -0
  97. package/libs/dashboard-contents-types/src/lib/shared/axis-view-options.d.ts +3 -0
  98. package/libs/dashboard-contents-types/src/lib/shared/common.d.ts +102 -0
  99. package/libs/dashboard-contents-types/src/lib/shared/drop-object-view-options.d.ts +11 -0
  100. package/libs/dashboard-contents-types/src/lib/shared/filters.d.ts +30 -0
  101. package/libs/dashboard-contents-types/src/lib/shared/formula.d.ts +28 -0
  102. package/libs/dashboard-contents-types/src/lib/shared/index.d.ts +29 -0
  103. package/libs/dashboard-contents-types/src/lib/shared/info-tooltip-options.d.ts +24 -0
  104. package/libs/dashboard-contents-types/src/lib/shared/interactivity-brush.d.ts +11 -0
  105. package/libs/dashboard-contents-types/src/lib/shared/interactivity-custom-events.d.ts +61 -0
  106. package/libs/dashboard-contents-types/src/lib/shared/interactivity-custom-tooltip.d.ts +13 -0
  107. package/libs/dashboard-contents-types/src/lib/shared/interactivity-drilldown.d.ts +81 -0
  108. package/libs/dashboard-contents-types/src/lib/shared/interactivity-export.d.ts +24 -0
  109. package/libs/dashboard-contents-types/src/lib/shared/interactivity-filter.d.ts +11 -0
  110. package/libs/dashboard-contents-types/src/lib/shared/interactivity-go-to-url.d.ts +28 -0
  111. package/libs/dashboard-contents-types/src/lib/shared/interactivity-measure-dimension-picker.d.ts +66 -0
  112. package/libs/dashboard-contents-types/src/lib/shared/interactivity-target.d.ts +1 -0
  113. package/libs/dashboard-contents-types/src/lib/shared/interpolation.d.ts +4 -0
  114. package/libs/dashboard-contents-types/src/lib/shared/item-filter-group.d.ts +122 -0
  115. package/libs/dashboard-contents-types/src/lib/shared/legend.d.ts +31 -0
  116. package/libs/dashboard-contents-types/src/lib/shared/map-object-view-options.d.ts +37 -0
  117. package/libs/dashboard-contents-types/src/lib/shared/object-view-options.d.ts +5 -0
  118. package/libs/dashboard-contents-types/src/lib/shared/placeholder.d.ts +7 -0
  119. package/libs/dashboard-contents-types/src/lib/shared/query.d.ts +25 -0
  120. package/libs/dashboard-contents-types/src/lib/shared/ranges.d.ts +17 -0
  121. package/libs/dashboard-contents-types/src/lib/shared/slots.d.ts +316 -0
  122. package/libs/dashboard-contents-types/src/lib/shared/sort.d.ts +64 -0
  123. package/libs/dashboard-contents-types/src/lib/shared/theme.d.ts +267 -0
  124. package/libs/dashboard-contents-types/src/lib/shared/title.d.ts +18 -0
  125. package/libs/dashboard-contents-types/src/lib/slicer-filter/index.d.ts +3 -0
  126. package/libs/dashboard-contents-types/src/lib/slicer-filter/slicer-filter-options.d.ts +204 -0
  127. package/libs/dashboard-contents-types/src/lib/slicer-filter/slicer-filter-slots.d.ts +28 -0
  128. package/libs/dashboard-contents-types/src/lib/slicer-filter/slicer-filter.d.ts +23 -0
  129. package/libs/dashboard-contents-types/src/lib/slider-filter/index.d.ts +3 -0
  130. package/libs/dashboard-contents-types/src/lib/slider-filter/slider-filter-options.d.ts +22 -0
  131. package/libs/dashboard-contents-types/src/lib/slider-filter/slider-filter-slots.d.ts +17 -0
  132. package/libs/dashboard-contents-types/src/lib/slider-filter/slider-filter.d.ts +23 -0
  133. package/libs/dashboard-contents-types/src/lib/text/index.d.ts +2 -0
  134. package/libs/dashboard-contents-types/src/lib/text/text-options.d.ts +53 -0
  135. package/libs/dashboard-contents-types/src/lib/text/text.d.ts +16 -0
  136. package/libs/dashboard-contents-types/src/options.d.ts +26 -0
  137. package/libs/dashboard-contents-types/src/slots.d.ts +24 -0
  138. package/libs/embed-libs/embed/src/index.d.ts +5 -0
  139. package/libs/embed-libs/embed/src/lib/dashboard-component/dashboard-base.d.ts +98 -0
  140. package/libs/embed-libs/embed/src/lib/dashboard-component/dashboard-component.d.ts +8 -0
  141. package/libs/embed-libs/embed/src/lib/dashboard-component/dashboard-styles.d.ts +1 -0
  142. package/libs/embed-libs/embed/src/lib/helper/event-bus-handler.d.ts +1 -0
  143. package/libs/embed-libs/embed/src/lib/luzmo-service.d.ts +6 -0
  144. package/libs/embed-libs/embed/src/lib/viz-item/viz-item-component.d.ts +4 -0
  145. package/libs/embed-libs/embed/src/lib/viz-item/viz-item.base.d.ts +73 -0
  146. package/libs/embed-libs/shared-embed/src/index.common.d.ts +33 -0
  147. package/libs/embed-libs/shared-embed/src/index.d.ts +2 -0
  148. package/libs/embed-libs/shared-embed/src/lib/constants/class-constants.d.ts +1 -0
  149. package/libs/embed-libs/shared-embed/src/lib/helpers/browser-check.d.ts +2 -0
  150. package/libs/embed-libs/shared-embed/src/lib/helpers/default-parameters.d.ts +2 -0
  151. package/libs/embed-libs/shared-embed/src/lib/helpers/error.d.ts +5 -0
  152. package/libs/embed-libs/shared-embed/src/lib/helpers/extents.d.ts +7 -0
  153. package/libs/embed-libs/shared-embed/src/lib/helpers/get-loader.d.ts +5 -0
  154. package/libs/embed-libs/shared-embed/src/lib/helpers/iframe-url.d.ts +1 -0
  155. package/libs/embed-libs/shared-embed/src/lib/helpers/promise-dispatch.d.ts +3 -0
  156. package/libs/embed-libs/shared-embed/src/lib/helpers/remote-federation.d.ts +16 -0
  157. package/libs/embed-libs/shared-embed/src/lib/helpers/set-selected-data-utils.d.ts +7 -0
  158. package/libs/embed-libs/shared-embed/src/lib/helpers/styles.d.ts +8 -0
  159. package/libs/embed-libs/shared-embed/src/lib/helpers/translations.d.ts +18 -0
  160. package/libs/embed-libs/shared-embed/src/lib/helpers/update-iframe-url.d.ts +1 -0
  161. package/libs/embed-libs/shared-embed/src/lib/helpers/utils.d.ts +27 -0
  162. package/libs/embed-libs/shared-embed/src/lib/methods/export-dashboard.d.ts +4 -0
  163. package/libs/embed-libs/shared-embed/src/lib/methods/get-accessible-dashboards.d.ts +3 -0
  164. package/libs/embed-libs/shared-embed/src/lib/methods/get-data.d.ts +3 -0
  165. package/libs/embed-libs/shared-embed/src/lib/methods/get-filters.d.ts +3 -0
  166. package/libs/embed-libs/shared-embed/src/lib/methods/refresh-data.d.ts +2 -0
  167. package/libs/embed-libs/shared-embed/src/lib/methods/reload-dashboard.d.ts +2 -0
  168. package/libs/embed-libs/shared-embed/src/lib/methods/set-authorization.d.ts +2 -0
  169. package/libs/embed-libs/shared-embed/src/lib/methods/set-edit-mode.d.ts +3 -0
  170. package/libs/embed-libs/shared-embed/src/lib/methods/set-preview.d.ts +3 -0
  171. package/libs/embed-libs/shared-embed/src/lib/methods/set-selected-data.d.ts +4 -0
  172. package/libs/embed-libs/shared-embed/src/lib/models/common.model.d.ts +103 -0
  173. package/libs/embed-libs/shared-embed/src/lib/models/dashboard.model.d.ts +45 -0
  174. package/libs/embed-libs/shared-embed/src/lib/models/events.model.d.ts +73 -0
  175. package/libs/embed-libs/shared-embed/src/lib/models/filters.model.d.ts +17 -0
  176. package/libs/embed-libs/shared-embed/src/lib/models/styles.model.d.ts +32 -0
  177. package/libs/embed-libs/shared-embed/src/lib/models/viz-item-post-message.model.d.ts +44 -0
  178. package/libs/embed-libs/shared-embed/src/lib/models/viz-item.model.d.ts +4 -0
  179. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/areachart.model.d.ts +13 -0
  180. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/barchart.model.d.ts +24 -0
  181. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/choroplethmap.model.d.ts +13 -0
  182. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/circlepack.model.d.ts +2 -0
  183. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/columnchart.model.d.ts +24 -0
  184. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/datetime.model.d.ts +13 -0
  185. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/donutchart.model.d.ts +2 -0
  186. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/dropdownfilter.model.d.ts +13 -0
  187. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/index.d.ts +36 -0
  188. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/linechart.model.d.ts +36 -0
  189. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/parallelcoordinatesplot.model.d.ts +14 -0
  190. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/piechart.model.d.ts +24 -0
  191. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/scatterplot.model.d.ts +13 -0
  192. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/slicer.model.d.ts +24 -0
  193. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/slider.model.d.ts +13 -0
  194. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/stripplot.model.d.ts +15 -0
  195. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/sunburst.model.d.ts +14 -0
  196. package/libs/embed-libs/shared-embed/src/lib/models/viz-items/treemap.model.d.ts +24 -0
  197. package/libs/embed-libs/shared-embed/src/lib/service/calculate-dimensions.d.ts +1 -0
  198. package/libs/embed-libs/shared-embed/src/lib/service/extend-and-validate.d.ts +2 -0
  199. package/luzmo-embed.min.js +62579 -2650
  200. package/package.json +5 -2
@@ -1,6 +1,7 @@
1
1
  import * as SharedLib from '@luzmo/shared-embed';
2
2
  import { LitElement, PropertyValues, TemplateResult } from 'lit';
3
- import { CombinedFilterInput } from '@luzmo/shared-embed';
3
+ import { LuzmoElement, CombinedSelectedDataInput } from '@luzmo/shared-embed';
4
+ import type { FilterGroup } from '@luzmo/dashboard-contents-types';
4
5
  /**
5
6
  * Luzmo Dashboard
6
7
  * Base component isn't registered in customEvents registry so that it can be reused.
@@ -51,9 +52,9 @@ export declare class LuzmoDashboard extends LitElement implements SharedLib.ES6L
51
52
  browserErrorMsg: string;
52
53
  dashboardError: boolean;
53
54
  browserNotSupported: any[];
54
- VERSION: string;
55
+ libVersion: string;
55
56
  protected isLibraryLoaded: boolean;
56
- protected dashboardReference: SharedLib.LuzmoElement;
57
+ protected dashboardReference: LuzmoElement;
57
58
  currentAuthKey: string;
58
59
  currentAuthToken: string;
59
60
  isInitCalled: boolean;
@@ -67,7 +68,6 @@ export declare class LuzmoDashboard extends LitElement implements SharedLib.ES6L
67
68
  iframeWidth?: string;
68
69
  _resizeObserver: ResizeObserver;
69
70
  constructor();
70
- private loadLibrary;
71
71
  connectedCallback(): void;
72
72
  disconnectedCallback(): void;
73
73
  firstUpdated(): void;
@@ -84,14 +84,14 @@ export declare class LuzmoDashboard extends LitElement implements SharedLib.ES6L
84
84
  render(): TemplateResult;
85
85
  getDashboards(): Promise<LuzmoDashboard[]>;
86
86
  getData(itemId: string): Promise<SharedLib.ItemData>;
87
- getFilters(): Promise<SharedLib.FilterGroup[]>;
88
- setFilters<K extends CombinedFilterInput>(itemId: string, filters: K): Promise<SharedLib.SetFilters>;
87
+ getFilters(): Promise<FilterGroup[]>;
88
+ setSelectedData<K extends CombinedSelectedDataInput>(itemId: string, filters: K): Promise<SharedLib.SetSelectedData>;
89
89
  setAuthorization(key: string, token: string): Promise<void>;
90
90
  refreshData(itemId?: string): Promise<void>;
91
91
  reloadDashboard(): Promise<void>;
92
92
  exportDashboard(format?: SharedLib.ExportType): Promise<SharedLib.ExportDashboard>;
93
93
  getAccessibleDashboards(): Promise<SharedLib.AccessibleDashboard[]>;
94
- addFilters(itemId: string, filters: SharedLib.FilterGroup[]): Promise<SharedLib.AddFilters>;
94
+ addFilters(itemId: string, filters: FilterGroup[]): Promise<SharedLib.AddFilters>;
95
95
  setEditMode(editMode?: SharedLib.DashboardEditMode): Promise<SharedLib.SetEditMode>;
96
96
  setPreview(preview: boolean): Promise<SharedLib.SetPreview>;
97
97
  getIsViewMode(): boolean;
@@ -0,0 +1,4 @@
1
+ import { LuzmoBaseVizItem } from './viz-item.base';
2
+ export { LuzmoVizItemComponentInterface } from './viz-item.base';
3
+ export declare class LuzmoEmbedVizItem extends LuzmoBaseVizItem {
4
+ }
@@ -0,0 +1,73 @@
1
+ import { LitElement, PropertyValues } from 'lit';
2
+ import * as SharedLib from '@luzmo/shared-embed';
3
+ import type { VizItemOptions, VizItemType, VizItemSlots, FilterGroup } from '@luzmo/dashboard-contents-types';
4
+ /**
5
+ * The version of the dashboard contents that is linked to the current library.
6
+ *
7
+ * If custom options/slots/etc. are passed to the component, the library assumes that
8
+ * they are using this dashboard contents version. Then custom options/slots/etc.
9
+ * together with this dashboard contents version are passed to the dashboard app (https://app.luzmo.com/dashboard-app/remoteEntry.mjs)
10
+ * and if needed the migration will be applied on the dashboard app level.
11
+ */
12
+ export declare const dashboardContentsVersion = "0.1.88";
13
+ type FunctionCall = [(...args: any) => any, any[]];
14
+ export interface LuzmoVizItemComponentInterface extends HTMLElement {
15
+ options?: VizItemOptions;
16
+ type?: VizItemType;
17
+ appServer?: string;
18
+ apiHost?: string;
19
+ slots?: VizItemSlots;
20
+ canFilter?: string[] | 'all';
21
+ filters?: FilterGroup[];
22
+ contextId?: string;
23
+ authKey?: string;
24
+ authToken?: string;
25
+ dashboardId?: string;
26
+ itemId?: string;
27
+ getFilters: () => FilterGroup[];
28
+ export: () => void;
29
+ refreshData: () => void;
30
+ getData: () => SharedLib.ItemData;
31
+ setSelectedData: (selectedDataInput: SharedLib.SelectedDataInput) => SharedLib.SetSelectedData;
32
+ setAuthorization: (key: string, token: string) => void;
33
+ }
34
+ export declare class LuzmoBaseVizItem extends LitElement implements LuzmoVizItemComponentInterface {
35
+ appServer?: string;
36
+ apiHost?: string;
37
+ slots?: VizItemSlots;
38
+ options?: VizItemOptions;
39
+ type?: VizItemType;
40
+ authKey?: string;
41
+ authToken?: string;
42
+ version?: string;
43
+ contextId?: string;
44
+ canFilter?: SharedLib.CanFilter;
45
+ filters?: FilterGroup[];
46
+ dashboardId?: string;
47
+ itemId?: string;
48
+ selectedData: SharedLib.SelectedDataInput;
49
+ dashboardContentsVersion?: string;
50
+ libVersion?: string;
51
+ chartElement: HTMLElement & Partial<LuzmoVizItemComponentInterface> & {
52
+ setSelectedData?: (itemId?: string, filters?: SharedLib.SelectedDataInput) => SharedLib.SetSelectedData;
53
+ };
54
+ postInitCallQueue: FunctionCall[];
55
+ static styles: import("lit").CSSResult;
56
+ constructor();
57
+ protected createRenderRoot(): HTMLElement | DocumentFragment;
58
+ canInitializeVizItem(): boolean;
59
+ getFilters(): FilterGroup[];
60
+ export(): void;
61
+ getData(): any;
62
+ refreshData(): void;
63
+ setSelectedData(selectedDataInput: SharedLib.SelectedDataInput): SharedLib.SetSelectedData;
64
+ setAuthorization(key: string, token: string): void;
65
+ attributeChangedCallback(name: string, _old: string | null, value: string | null): void;
66
+ protected firstUpdated(_changedProperties: PropertyValues): Promise<void>;
67
+ private createAndAppendElement;
68
+ private updateVizItemProperties;
69
+ updated(changedProperties: PropertyValues): Promise<void>;
70
+ private parseAndValidate;
71
+ protected render(): unknown;
72
+ }
73
+ export {};
@@ -0,0 +1,2 @@
1
+ export * from './src/index';
2
+ export * from './json-schemas';
@@ -0,0 +1 @@
1
+ export declare const JSON_SCHEMAS: Record<string, any>;
@@ -0,0 +1,27 @@
1
+ export * from './lib/bar-chart';
2
+ export * from './lib/column-chart';
3
+ export * from './lib/line-chart';
4
+ export * from './lib/text';
5
+ export * from './lib/dropdown-filter';
6
+ export * from './lib/evolution-number';
7
+ export * from './lib/date-filter';
8
+ export * from './lib/pivot-table';
9
+ export * from './lib/image';
10
+ export * from './lib/donut-chart';
11
+ export * from './lib/regular-table';
12
+ export * from './lib/slicer-filter';
13
+ export * from './lib/choropleth-map';
14
+ export * from './lib/bubble-chart';
15
+ export * from './lib/slider-filter';
16
+ export * from './lib/combination-chart';
17
+ export * from './lib/area-chart';
18
+ export * from './lib/box-plot';
19
+ export * from './lib/circular-gauge';
20
+ export * from './lib/bullet-chart';
21
+ export * from './lib/scatter-plot';
22
+ export * from './lib/conditional-number';
23
+ export * from './lib/sankey-diagram';
24
+ export * from './lib/funnel-chart';
25
+ export * from './lib/shared';
26
+ export * from './options';
27
+ export * from './slots';
@@ -0,0 +1,330 @@
1
+ import { InteractivityBrushViewOptions } from '../shared';
2
+ import { AxisGridlinesStyle, AxisScaleType, AxisTicksDensity, ManualAxesRange, XAxisLabelPosition, YAxisLabelPosition } from '../shared/axes';
3
+ import { AxisObjectViewOptions } from '../shared/axis-view-options';
4
+ import type { AxisTicksMode, AxisTicksStyle, Guidelines, LimitViewOptions, MissingValueViewOptions, NullBreakViewOptions } from '../shared/common';
5
+ import { InfoTooltipViewOptions } from '../shared/info-tooltip-options';
6
+ import { InteractivityCustomEventsViewOptions } from '../shared/interactivity-custom-events';
7
+ import { InteractivityCustomTooltipViewOptions } from '../shared/interactivity-custom-tooltip';
8
+ import { InteractivityExportViewOptions } from '../shared/interactivity-export';
9
+ import { InteractivityGoToUrlViewOptions } from '../shared/interactivity-go-to-url';
10
+ import { InteractivityMeasureDimensionPickerViewOptions } from '../shared/interactivity-measure-dimension-picker';
11
+ import { Interpolation } from '../shared/interpolation';
12
+ import { DisplayLegendViewOptions, LegendViewOptions } from '../shared/legend';
13
+ import { DisplayTitleViewOptions, TitleViewOptions } from '../shared/title';
14
+ export interface AreaChartViewOptions extends Omit<AxisObjectViewOptions, 'interactivity' | 'display'>, InfoTooltipViewOptions, LegendViewOptions, MissingValueViewOptions, NullBreakViewOptions, TitleViewOptions, LimitViewOptions, AreaChartDisplayViewOptions, AreaChartInteractivityViewOptions {
15
+ /**
16
+ * Mode of the Area chart: stacked, unstacked, stream or 100% stacked
17
+ * @default "stacked"
18
+ */
19
+ mode?: 'stacked' | 'unstacked' | 'stream' | '100';
20
+ /**
21
+ * This option fine-tunes the 'mode' option. When it's 'area-stack' the 'mode' will become 'stacked', if it's area-unstacked the 'mode' will become 'unstacked', if it's area-stream the 'mode' will become 'stream' and if it's area-100 the 'mode' will become '100'.
22
+ */
23
+ startWithSubType?: AreaChartSubtype;
24
+ /**
25
+ * This option set the interpolation for the area drawn: "linear" or "step-before" or "step-after" or "monotone"
26
+ * @default 'linear'
27
+ */
28
+ interpolation?: Interpolation;
29
+ /**
30
+ * Axes labels options
31
+ */
32
+ axislabels?: {
33
+ /**
34
+ * X-axis label options
35
+ */
36
+ x?: {
37
+ /**
38
+ * Show or hide the X-axis labels
39
+ * @default false
40
+ */
41
+ enabled: boolean;
42
+ /**
43
+ * Position of the X-axis labels
44
+ * @default "center"
45
+ */
46
+ position: XAxisLabelPosition;
47
+ };
48
+ /**
49
+ * Y-axis label options
50
+ */
51
+ y?: {
52
+ /**
53
+ * Show or hide the Y-axis labels
54
+ * @default false
55
+ */
56
+ enabled: boolean;
57
+ /**
58
+ * Position of the Y-axis labels
59
+ * @default "middle"
60
+ */
61
+ position: YAxisLabelPosition;
62
+ };
63
+ /**
64
+ * Another Y-axis label options
65
+ */
66
+ y2?: {
67
+ /**
68
+ * Show or hide the Y2-axis labels
69
+ * @default false
70
+ */
71
+ enabled: boolean;
72
+ /**
73
+ * Position of the Y2-axis labels
74
+ * @default "middle"
75
+ */
76
+ position: YAxisLabelPosition;
77
+ };
78
+ };
79
+ /**
80
+ * Axes options
81
+ */
82
+ axis?: {
83
+ /**
84
+ * X-axis options
85
+ */
86
+ x?: {
87
+ /**
88
+ * X-axis color
89
+ * @examples ["#000000", "black", "rgba(0,0,0,1)"]
90
+ */
91
+ color?: string;
92
+ /**
93
+ * Ticks mode of the X-axis: hide, ticks, or gridlines
94
+ * @default "ticks"
95
+ */
96
+ ticksMode?: AxisTicksMode;
97
+ /**
98
+ * Ticks style of the X-axis: auto or user defined
99
+ */
100
+ ticksStyle?: AxisTicksStyle;
101
+ };
102
+ /**
103
+ * Y2-axis options
104
+ */
105
+ y?: {
106
+ /**
107
+ * Y-axis color
108
+ * @examples ["#000000", "black", "rgba(0,0,0,1)"]
109
+ */
110
+ color?: string;
111
+ /**
112
+ * Y-axis scale type: linear or logarithmic
113
+ * @default "linear"
114
+ */
115
+ scale?: AxisScaleType;
116
+ /**
117
+ * Base of the logarithmic scale. Only applies if the scale is logarithmic.
118
+ * @examples [2, 10]
119
+ */
120
+ scaleLogBase?: number;
121
+ /**
122
+ * Density of the ticks on the Y-axis
123
+ */
124
+ ticksDensity?: AxisTicksDensity;
125
+ /**
126
+ * Ticks mode of the Y-axis: hide, ticks, or gridlines
127
+ * @default "ticks"
128
+ */
129
+ ticksMode?: AxisTicksMode;
130
+ /**
131
+ * Set manual axes range
132
+ * @example [0, 100]
133
+ */
134
+ manualAxesRange?: ManualAxesRange;
135
+ /**
136
+ * Y-axis type: default, manual or variable
137
+ * @default "default"
138
+ */
139
+ type?: AreaChartMeasureAxisType;
140
+ };
141
+ /**
142
+ * Y2-axis options
143
+ */
144
+ y2?: {
145
+ /**
146
+ * Y2-axis color
147
+ * @examples ["#000000", "black", "rgba(0,0,0,1)"]
148
+ */
149
+ color?: string;
150
+ /**
151
+ * Y-axis scale type: linear or logarithmic
152
+ */
153
+ scale?: AxisScaleType;
154
+ /**
155
+ * Base of the logarithmic scale. Only applies if the scale is logarithmic.
156
+ * @examples [2, 10]
157
+ */
158
+ scaleLogBase?: number;
159
+ /**
160
+ * Density of the ticks on the Y2-axis
161
+ */
162
+ ticksDensity?: AxisTicksDensity;
163
+ /**
164
+ * Ticks mode of the Y2-axis: hide, ticks, or gridlines
165
+ * @default "ticks"
166
+ */
167
+ ticksMode?: AxisTicksMode;
168
+ /**
169
+ * Set manual axes range
170
+ * @example [0, 100]
171
+ */
172
+ manualAxesRange?: ManualAxesRange;
173
+ /**
174
+ * Y-axis type: default, manual or variable
175
+ * @default "default"
176
+ */
177
+ type?: AreaChartMeasureAxisType;
178
+ /**
179
+ * Toggle whether the Y2-axis is active
180
+ * @default false
181
+ */
182
+ active?: boolean;
183
+ /**
184
+ * Array of measure indexes to be displayed on the Y2-axis
185
+ * @default [1]
186
+ * @examples [[1, 2]]
187
+ */
188
+ measureIndexes?: number[];
189
+ };
190
+ };
191
+ /**
192
+ * Chart grid options
193
+ */
194
+ grid?: {
195
+ /**
196
+ * X-axis grid options
197
+ */
198
+ x?: {
199
+ /**
200
+ * Show or hide the X-axis grid
201
+ * @default false
202
+ */
203
+ enabled: boolean;
204
+ /**
205
+ * Style of the X-axis grid
206
+ */
207
+ style?: AxisGridlinesStyle;
208
+ /**
209
+ * Opacity of the X-axis grid
210
+ * @examples [1, 0.5, 0.1]
211
+ */
212
+ opacity?: number;
213
+ };
214
+ /**
215
+ * Y-axis grid options
216
+ */
217
+ y?: {
218
+ /**
219
+ * Show or hide the Y-axis grid
220
+ * @default false
221
+ */
222
+ enabled: boolean;
223
+ /**
224
+ * Style of the Y-axis grid
225
+ */
226
+ style?: AxisGridlinesStyle;
227
+ /**
228
+ * Opacity of the Y-axis grid
229
+ * @examples [1, 0.5, 0.1]
230
+ */
231
+ opacity?: number;
232
+ };
233
+ /**
234
+ * Y-axis grid options
235
+ */
236
+ y2?: {
237
+ /**
238
+ * Show or hide the Y2-axis grid
239
+ * @default false
240
+ */
241
+ enabled: boolean;
242
+ /**
243
+ * Style of the Y2-axis grid
244
+ */
245
+ style?: AxisGridlinesStyle;
246
+ /**
247
+ * Opacity of the Y2-axis grid
248
+ * @examples [1, 0.5, 0.1]
249
+ */
250
+ opacity?: number;
251
+ };
252
+ };
253
+ /**
254
+ * @TJS-ignore
255
+ */
256
+ area?: {
257
+ index?: number;
258
+ };
259
+ /**
260
+ * Guidelines options
261
+ */
262
+ guidelines?: Guidelines;
263
+ }
264
+ interface AreaChartDisplayViewOptions extends DisplayLegendViewOptions, DisplayTitleViewOptions {
265
+ /**
266
+ * General display options of the Area chart: title, legend and mode option
267
+ */
268
+ display: {
269
+ /**
270
+ * Show or hide the title
271
+ * @default true
272
+ */
273
+ title: NonNullable<NonNullable<DisplayTitleViewOptions['display']>['title']>;
274
+ /**
275
+ * Show or hide the legend
276
+ * @default true
277
+ */
278
+ legend?: NonNullable<NonNullable<DisplayLegendViewOptions['display']>['legend']>;
279
+ /**
280
+ * Show or hide the mode option
281
+ * @default false
282
+ */
283
+ modeOption?: boolean;
284
+ };
285
+ }
286
+ interface AreaChartInteractivityViewOptions extends InteractivityCustomEventsViewOptions, InteractivityCustomTooltipViewOptions, InteractivityExportViewOptions, InteractivityGoToUrlViewOptions, InteractivityMeasureDimensionPickerViewOptions {
287
+ /**
288
+ * Interactivity options
289
+ */
290
+ interactivity?: {
291
+ /**
292
+ * Available export types interactivity option
293
+ * @default ["xlsx", "csv", "png"]
294
+ */
295
+ availableExportTypes?: NonNullable<NonNullable<InteractivityExportViewOptions['interactivity']>['availableExportTypes']>;
296
+ /**
297
+ * Filter on brush interactivity option
298
+ * @default true
299
+ */
300
+ brush?: NonNullable<NonNullable<InteractivityBrushViewOptions['interactivity']>['brush']>;
301
+ /**
302
+ * Custom events interactivity option
303
+ * @default null
304
+ */
305
+ customEvents?: NonNullable<NonNullable<InteractivityCustomEventsViewOptions['interactivity']>['customEvents']>;
306
+ /**
307
+ * Custom tooltip interactivity option, in format {locale: "tooltip"}, for example, {en: "Total Revenue"}
308
+ * @default null
309
+ */
310
+ customTooltip?: NonNullable<NonNullable<InteractivityCustomTooltipViewOptions['interactivity']>['customTooltip']>;
311
+ /**
312
+ * Export types interactivity option
313
+ * @default ["xlsx", "csv", "png"]
314
+ */
315
+ exportTypes?: NonNullable<NonNullable<InteractivityExportViewOptions['interactivity']>['exportTypes']>;
316
+ /**
317
+ * An array of measure dimension picker configurations
318
+ * @default [[]]
319
+ */
320
+ measureDimensionPicker?: NonNullable<NonNullable<InteractivityMeasureDimensionPickerViewOptions['interactivity']>['measureDimensionPicker']>;
321
+ /**
322
+ * Go to URL interactivity option
323
+ * @default { target: '_blank', url: null }
324
+ */
325
+ urlConfig?: NonNullable<NonNullable<InteractivityGoToUrlViewOptions['interactivity']>['urlConfig']>;
326
+ };
327
+ }
328
+ export type AreaChartMeasureAxisType = 'default' | 'manual' | 'variable';
329
+ export type AreaChartSubtype = 'area' | 'area-stack' | 'area-100' | 'area-stream';
330
+ export {};
@@ -0,0 +1,39 @@
1
+ import { DashboardContentVizItemSlot, DateTimeSlotContent, HierarchySlotContent, NumericSlotContent } from '../shared/slots';
2
+ /**
3
+ * Category slot definition of the area chart. This defines the areas on the Y-axis.
4
+ */
5
+ interface XAxisSlot extends DashboardContentVizItemSlot {
6
+ name: 'x-axis';
7
+ /**
8
+ * X-axis slot definition
9
+ * @maxItems 1
10
+ */
11
+ content: (HierarchySlotContent | NumericSlotContent | DateTimeSlotContent)[];
12
+ }
13
+ /**
14
+ * Measure slot definition of the area chart. A area chart can contain any number of measures but if it contains 2 or more measures, the measures become the legend.
15
+ */
16
+ interface MeasureSlot extends DashboardContentVizItemSlot {
17
+ name: 'measure';
18
+ /**
19
+ * Measure slot definition
20
+ */
21
+ content: (HierarchySlotContent | NumericSlotContent | DateTimeSlotContent)[];
22
+ }
23
+ /**
24
+ * Legend slot definition of the area chart. This defines the legend of the area chart. If 2 measures are used, the legend cannot be used.
25
+ */
26
+ interface LegendSlot extends DashboardContentVizItemSlot {
27
+ name: 'legend';
28
+ /**
29
+ * Legend slot definition
30
+ * @maxItems 1
31
+ */
32
+ content: (HierarchySlotContent | NumericSlotContent | DateTimeSlotContent)[];
33
+ }
34
+ /**
35
+ * Data definition of the Area chart
36
+ * @maxItems 3
37
+ */
38
+ export type AreaChartSlots = (MeasureSlot | XAxisSlot | LegendSlot)[];
39
+ export {};
@@ -0,0 +1,23 @@
1
+ import { VizItemType } from '../shared/common';
2
+ import { AreaChartViewOptions } from './area-chart-options';
3
+ import { AreaChartSlots } from './area-chart-slots';
4
+ /**
5
+ * Area chart item
6
+ */
7
+ export interface AreaChart {
8
+ /**
9
+ * Type of the item
10
+ */
11
+ type: Extract<VizItemType, 'area-chart'>;
12
+ /**
13
+ * Options of the area chart item
14
+ * @$ref ./area-chart-options.schema.json/
15
+ */
16
+ options: AreaChartViewOptions;
17
+ /**
18
+ * Data definition of the Area chart
19
+ * @maxItems 3
20
+ * @$ref ./area-chart-slots.schema.json
21
+ */
22
+ slots: AreaChartSlots;
23
+ }
@@ -0,0 +1,3 @@
1
+ export * from './area-chart-options';
2
+ export * from './area-chart-slots';
3
+ export * from './area-chart';