@luzmo/ngx-analytics-components-kit 1.0.8 → 1.0.9-beta.10

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 (66) hide show
  1. package/esm/components/add-to-dashboard.d.ts +48 -0
  2. package/esm/components/add-to-dashboard.js +129 -0
  3. package/esm/components/ai-chat-empty-state.d.ts +41 -0
  4. package/esm/components/ai-chat-empty-state.js +107 -0
  5. package/esm/components/ai-chat.d.ts +149 -0
  6. package/esm/components/ai-chat.js +463 -0
  7. package/esm/components/ai-interaction-textarea.d.ts +108 -0
  8. package/esm/components/ai-interaction-textarea.js +313 -0
  9. package/esm/components/data-field-level.d.ts +50 -0
  10. package/esm/components/data-field-level.js +129 -0
  11. package/esm/components/data-field-panel.d.ts +4 -4
  12. package/esm/components/data-field.d.ts +4 -4
  13. package/esm/components/data-fields-select.d.ts +87 -0
  14. package/esm/components/data-fields-select.js +243 -0
  15. package/esm/components/dataset-icon.d.ts +34 -0
  16. package/esm/components/dataset-icon.js +86 -0
  17. package/esm/components/dataset-selector-list.d.ts +56 -0
  18. package/esm/components/dataset-selector-list.js +155 -0
  19. package/esm/components/dataset-selector-row.d.ts +72 -0
  20. package/esm/components/dataset-selector-row.js +205 -0
  21. package/esm/components/display-settings-binning.d.ts +37 -0
  22. package/esm/components/display-settings-binning.js +91 -0
  23. package/esm/components/display-settings-datetime.d.ts +40 -0
  24. package/esm/components/display-settings-datetime.js +99 -0
  25. package/esm/components/display-settings-grand-totals.d.ts +37 -0
  26. package/esm/components/display-settings-grand-totals.js +91 -0
  27. package/esm/components/display-settings-numeric.d.ts +45 -0
  28. package/esm/components/display-settings-numeric.js +115 -0
  29. package/esm/components/display-settings-period-over-period.d.ts +50 -0
  30. package/esm/components/display-settings-period-over-period.js +123 -0
  31. package/esm/components/display-settings.d.ts +83 -0
  32. package/esm/components/display-settings.js +231 -0
  33. package/esm/components/filter-expression-picker.d.ts +64 -0
  34. package/esm/components/filter-expression-picker.js +179 -0
  35. package/esm/components/filter-item.d.ts +74 -0
  36. package/esm/components/filter-item.js +222 -0
  37. package/esm/components/filter-parameter-picker.d.ts +56 -0
  38. package/esm/components/filter-parameter-picker.js +151 -0
  39. package/esm/components/filter-value-picker-datetime.d.ts +47 -0
  40. package/esm/components/filter-value-picker-datetime.js +131 -0
  41. package/esm/components/filter-value-picker-hierarchy.d.ts +53 -0
  42. package/esm/components/filter-value-picker-hierarchy.js +155 -0
  43. package/esm/components/filter-value-picker-numeric.d.ts +53 -0
  44. package/esm/components/filter-value-picker-numeric.js +155 -0
  45. package/esm/components/filter-value-picker.d.ts +57 -0
  46. package/esm/components/filter-value-picker.js +171 -0
  47. package/esm/components/filters.d.ts +14 -4
  48. package/esm/components/filters.js +39 -3
  49. package/esm/components/formula-editor.d.ts +1 -0
  50. package/esm/components/formula-editor.js +1 -1
  51. package/esm/components/formula-field.d.ts +70 -0
  52. package/esm/components/formula-field.js +209 -0
  53. package/esm/components/interactive-viz-item.d.ts +76 -0
  54. package/esm/components/interactive-viz-item.js +224 -0
  55. package/esm/components/item-grid-item-actions-menu.d.ts +10 -8
  56. package/esm/components/item-grid-item-actions-menu.js +12 -6
  57. package/esm/components/item-grid.d.ts +5 -3
  58. package/esm/components/item-grid.js +8 -2
  59. package/esm/components/item-slot-drop.d.ts +5 -5
  60. package/esm/components/slot-menu-list.d.ts +46 -0
  61. package/esm/components/slot-menu-list.js +123 -0
  62. package/esm/components/slot-menu.d.ts +104 -0
  63. package/esm/components/slot-menu.js +300 -0
  64. package/esm/index.d.ts +54 -2
  65. package/esm/index.js +106 -2
  66. package/package.json +2 -2
@@ -1,10 +1,10 @@
1
1
  import { OnChanges, SimpleChanges } from '@angular/core';
2
2
  import '@luzmo/analytics-components-kit/item-grid';
3
- import type { LuzmoItemGrid as LuzmoItemGridHostElement, ClonedItemPositioning, GridItemActionEventDetail, GridItemData, GridItemRenderer, GridItemStatesChangedEventDetail, GridLifecycleEventDetail, InputActionGroup, ItemStates } from '@luzmo/analytics-components-kit/item-grid';
3
+ import type { LuzmoItemGrid as LuzmoItemGridHostElement, ClonedItemPositioning, GridItemActionEventDetail, GridItemData, GridItemRenderer, GridItemStatesChangedEventDetail, GridLifecycleEventDetail, InputActionGroup, ItemGridItemActionHoverEventDetail, ItemStates } from '@luzmo/analytics-components-kit/item-grid';
4
4
  import type { ThemeConfig } from '@luzmo/dashboard-contents-types';
5
5
  import type { Placement } from '@luzmo/lucero';
6
6
  import * as i0 from "@angular/core";
7
- export type { Action, ActionGroup, AddGridItemInput, ClonedItemPositioning, DefaultActionType, GridItemActionEventDetail, GridItemData, GridItemPatch, GridItemPosition, GridItemPositionPatch, GridItemRenderer, GridItemSizePatch, GridItemStatesChangedEventDetail, GridLifecycleEventDetail, InputActionGroup, ItemStates } from '@luzmo/analytics-components-kit/item-grid';
7
+ export type { Action, ActionGroup, AddGridItemInput, ClonedItemPositioning, DefaultActionType, GridItemActionEventDetail, GridItemData, GridItemPatch, GridItemPosition, GridItemPositionPatch, GridItemRenderer, GridItemSizePatch, GridItemStatesChangedEventDetail, GridLifecycleEventDetail, InputActionGroup, ItemGridItemActionEventDetail, ItemGridItemActionHoverEventDetail, ItemStates } from '@luzmo/analytics-components-kit/item-grid';
8
8
  export declare class LuzmoItemGrid implements OnChanges {
9
9
  private readonly elementRef;
10
10
  private readonly renderer;
@@ -55,6 +55,8 @@ export declare class LuzmoItemGrid implements OnChanges {
55
55
  initialItemStates?: ItemStates;
56
56
  /** Fired when an item action is performed */
57
57
  readonly luzmoItemGridItemAction: import("@angular/core").OutputEmitterRef<CustomEvent<GridItemActionEventDetail>>;
58
+ /** Bubbles from the item actions menu when the pointer enters an action. The detail has only `action` and `type`, not the item. */
59
+ readonly luzmoItemGridItemActionHover: import("@angular/core").OutputEmitterRef<CustomEvent<ItemGridItemActionHoverEventDetail>>;
58
60
  /** Fired when the grid layout is changed */
59
61
  readonly luzmoItemGridLayoutChanged: import("@angular/core").OutputEmitterRef<CustomEvent<GridLifecycleEventDetail>>;
60
62
  /** Fired when the grid is ready */
@@ -72,7 +74,7 @@ export declare class LuzmoItemGrid implements OnChanges {
72
74
  private setHostProperty;
73
75
  private bindEvents;
74
76
  static ɵfac: i0.ɵɵFactoryDeclaration<LuzmoItemGrid, never>;
75
- static ɵcmp: i0.ɵɵComponentDeclaration<LuzmoItemGrid, "luzmo-item-grid", ["luzmoItemGrid"], { "appServer": { "alias": "appServer"; "required": false; }; "apiHost": { "alias": "apiHost"; "required": false; }; "authKey": { "alias": "authKey"; "required": false; }; "authToken": { "alias": "authToken"; "required": false; }; "cacheTime": { "alias": "cacheTime"; "required": false; }; "language": { "alias": "language"; "required": false; }; "contentLanguage": { "alias": "contentLanguage"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "viewMode": { "alias": "viewMode"; "required": false; }; "itemActionsDocumentPopover": { "alias": "itemActionsDocumentPopover"; "required": false; }; "placementItemActionsMenu": { "alias": "placementItemActionsMenu"; "required": false; }; "defaultItemActionsMenu": { "alias": "defaultItemActionsMenu"; "required": false; }; "clonedItemPositioning": { "alias": "clonedItemPositioning"; "required": false; }; "theme": { "alias": "theme"; "required": false; }; "items": { "alias": "items"; "required": false; }; "initialItems": { "alias": "initialItems"; "required": false; }; "renderers": { "alias": "renderers"; "required": false; }; "itemStates": { "alias": "itemStates"; "required": false; }; "initialItemStates": { "alias": "initialItemStates"; "required": false; }; }, { "luzmoItemGridItemAction": "luzmoItemGridItemAction"; "luzmoItemGridLayoutChanged": "luzmoItemGridLayoutChanged"; "luzmoItemGridReady": "luzmoItemGridReady"; "luzmoItemGridItemStatesChanged": "luzmoItemGridItemStatesChanged"; }, never, ["*"], true, never>;
77
+ static ɵcmp: i0.ɵɵComponentDeclaration<LuzmoItemGrid, "luzmo-item-grid", ["luzmoItemGrid"], { "appServer": { "alias": "appServer"; "required": false; }; "apiHost": { "alias": "apiHost"; "required": false; }; "authKey": { "alias": "authKey"; "required": false; }; "authToken": { "alias": "authToken"; "required": false; }; "cacheTime": { "alias": "cacheTime"; "required": false; }; "language": { "alias": "language"; "required": false; }; "contentLanguage": { "alias": "contentLanguage"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "viewMode": { "alias": "viewMode"; "required": false; }; "itemActionsDocumentPopover": { "alias": "itemActionsDocumentPopover"; "required": false; }; "placementItemActionsMenu": { "alias": "placementItemActionsMenu"; "required": false; }; "defaultItemActionsMenu": { "alias": "defaultItemActionsMenu"; "required": false; }; "clonedItemPositioning": { "alias": "clonedItemPositioning"; "required": false; }; "theme": { "alias": "theme"; "required": false; }; "items": { "alias": "items"; "required": false; }; "initialItems": { "alias": "initialItems"; "required": false; }; "renderers": { "alias": "renderers"; "required": false; }; "itemStates": { "alias": "itemStates"; "required": false; }; "initialItemStates": { "alias": "initialItemStates"; "required": false; }; }, { "luzmoItemGridItemAction": "luzmoItemGridItemAction"; "luzmoItemGridItemActionHover": "luzmoItemGridItemActionHover"; "luzmoItemGridLayoutChanged": "luzmoItemGridLayoutChanged"; "luzmoItemGridReady": "luzmoItemGridReady"; "luzmoItemGridItemStatesChanged": "luzmoItemGridItemStatesChanged"; }, never, ["*"], true, never>;
76
78
  static ngAcceptInputType_viewMode: unknown;
77
79
  static ngAcceptInputType_itemActionsDocumentPopover: unknown;
78
80
  }
@@ -57,6 +57,8 @@ export class LuzmoItemGrid {
57
57
  initialItemStates;
58
58
  /** Fired when an item action is performed */
59
59
  luzmoItemGridItemAction = output({ alias: 'luzmoItemGridItemAction' });
60
+ /** Bubbles from the item actions menu when the pointer enters an action. The detail has only `action` and `type`, not the item. */
61
+ luzmoItemGridItemActionHover = output({ alias: 'luzmoItemGridItemActionHover' });
60
62
  /** Fired when the grid layout is changed */
61
63
  luzmoItemGridLayoutChanged = output({ alias: 'luzmoItemGridLayoutChanged' });
62
64
  /** Fired when the grid is ready */
@@ -153,6 +155,10 @@ export class LuzmoItemGrid {
153
155
  const typed = event;
154
156
  this.luzmoItemGridItemAction.emit(typed);
155
157
  }));
158
+ this.listenerCleanup.push(this.renderer.listen(this.host, 'luzmo-item-grid-item-action-hover', (event) => {
159
+ const typed = event;
160
+ this.luzmoItemGridItemActionHover.emit(typed);
161
+ }));
156
162
  this.listenerCleanup.push(this.renderer.listen(this.host, 'luzmo-item-grid-layout-changed', (event) => {
157
163
  const typed = event;
158
164
  this.luzmoItemGridLayoutChanged.emit(typed);
@@ -167,7 +173,7 @@ export class LuzmoItemGrid {
167
173
  }));
168
174
  }
169
175
  static ɵfac = function LuzmoItemGrid_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || LuzmoItemGrid)(); };
170
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LuzmoItemGrid, selectors: [["luzmo-item-grid"]], inputs: { appServer: "appServer", apiHost: "apiHost", authKey: "authKey", authToken: "authToken", cacheTime: "cacheTime", language: "language", contentLanguage: "contentLanguage", columns: "columns", rowHeight: "rowHeight", viewMode: [2, "viewMode", "viewMode", booleanAttribute], itemActionsDocumentPopover: [2, "itemActionsDocumentPopover", "itemActionsDocumentPopover", booleanAttribute], placementItemActionsMenu: "placementItemActionsMenu", defaultItemActionsMenu: "defaultItemActionsMenu", clonedItemPositioning: "clonedItemPositioning", theme: "theme", items: "items", initialItems: "initialItems", renderers: "renderers", itemStates: "itemStates", initialItemStates: "initialItemStates" }, outputs: { luzmoItemGridItemAction: "luzmoItemGridItemAction", luzmoItemGridLayoutChanged: "luzmoItemGridLayoutChanged", luzmoItemGridReady: "luzmoItemGridReady", luzmoItemGridItemStatesChanged: "luzmoItemGridItemStatesChanged" }, exportAs: ["luzmoItemGrid"], features: [i0.ɵɵNgOnChangesFeature], ngContentSelectors: _c0, decls: 1, vars: 0, template: function LuzmoItemGrid_Template(rf, ctx) { if (rf & 1) {
176
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LuzmoItemGrid, selectors: [["luzmo-item-grid"]], inputs: { appServer: "appServer", apiHost: "apiHost", authKey: "authKey", authToken: "authToken", cacheTime: "cacheTime", language: "language", contentLanguage: "contentLanguage", columns: "columns", rowHeight: "rowHeight", viewMode: [2, "viewMode", "viewMode", booleanAttribute], itemActionsDocumentPopover: [2, "itemActionsDocumentPopover", "itemActionsDocumentPopover", booleanAttribute], placementItemActionsMenu: "placementItemActionsMenu", defaultItemActionsMenu: "defaultItemActionsMenu", clonedItemPositioning: "clonedItemPositioning", theme: "theme", items: "items", initialItems: "initialItems", renderers: "renderers", itemStates: "itemStates", initialItemStates: "initialItemStates" }, outputs: { luzmoItemGridItemAction: "luzmoItemGridItemAction", luzmoItemGridItemActionHover: "luzmoItemGridItemActionHover", luzmoItemGridLayoutChanged: "luzmoItemGridLayoutChanged", luzmoItemGridReady: "luzmoItemGridReady", luzmoItemGridItemStatesChanged: "luzmoItemGridItemStatesChanged" }, exportAs: ["luzmoItemGrid"], features: [i0.ɵɵNgOnChangesFeature], ngContentSelectors: _c0, decls: 1, vars: 0, template: function LuzmoItemGrid_Template(rf, ctx) { if (rf & 1) {
171
177
  i0.ɵɵprojectionDef();
172
178
  i0.ɵɵprojection(0);
173
179
  } }, encapsulation: 2 });
@@ -241,5 +247,5 @@ export class LuzmoItemGrid {
241
247
  }], initialItemStates: [{
242
248
  type: Input,
243
249
  args: [{ alias: 'initialItemStates' }]
244
- }], luzmoItemGridItemAction: [{ type: i0.Output, args: ["luzmoItemGridItemAction"] }], luzmoItemGridLayoutChanged: [{ type: i0.Output, args: ["luzmoItemGridLayoutChanged"] }], luzmoItemGridReady: [{ type: i0.Output, args: ["luzmoItemGridReady"] }], luzmoItemGridItemStatesChanged: [{ type: i0.Output, args: ["luzmoItemGridItemStatesChanged"] }] }); })();
250
+ }], luzmoItemGridItemAction: [{ type: i0.Output, args: ["luzmoItemGridItemAction"] }], luzmoItemGridItemActionHover: [{ type: i0.Output, args: ["luzmoItemGridItemActionHover"] }], luzmoItemGridLayoutChanged: [{ type: i0.Output, args: ["luzmoItemGridLayoutChanged"] }], luzmoItemGridReady: [{ type: i0.Output, args: ["luzmoItemGridReady"] }], luzmoItemGridItemStatesChanged: [{ type: i0.Output, args: ["luzmoItemGridItemStatesChanged"] }] }); })();
245
251
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(LuzmoItemGrid, { className: "LuzmoItemGrid", filePath: "components/item-grid.ts", lineNumber: 18 }); })();
@@ -1,10 +1,10 @@
1
1
  import { OnChanges, SimpleChanges } from '@angular/core';
2
2
  import '@luzmo/analytics-components-kit/item-slot-drop';
3
- import type { LuzmoItemSlotDrop as LuzmoItemSlotDropHostElement, SlotConfig, SlotContentsChangedEventDetail } from '@luzmo/analytics-components-kit/item-slot-drop';
3
+ import type { LuzmoItemSlotDrop as LuzmoItemSlotDropHostElement, InfoVisibilityChangedEventDetail, SlotConfig, SlotContentsChangedEventDetail, SlotMenuActiveEventDetail, SlotMenuHighlightEventDetail } from '@luzmo/analytics-components-kit/item-slot-drop';
4
4
  import type { SlotName, VizItemSlot, VizItemType } from '@luzmo/dashboard-contents-types';
5
5
  import type { Placement } from '@luzmo/lucero';
6
6
  import * as i0 from "@angular/core";
7
- export type { SlotConfig, SlotContentsChangedEventDetail } from '@luzmo/analytics-components-kit/item-slot-drop';
7
+ export type { InfoVisibilityChangedEventDetail, SlotConfig, SlotContentsChangedEventDetail, SlotMenuActiveEventDetail, SlotMenuHighlightEventDetail } from '@luzmo/analytics-components-kit/item-slot-drop';
8
8
  export declare class LuzmoItemSlotDrop implements OnChanges {
9
9
  private readonly elementRef;
10
10
  private readonly renderer;
@@ -50,11 +50,11 @@ export declare class LuzmoItemSlotDrop implements OnChanges {
50
50
  /** Emitted when the slot menu overlay closes / becomes inactive. */
51
51
  readonly luzmoSlotMenuInactive: import("@angular/core").OutputEmitterRef<CustomEvent<unknown>>;
52
52
  /** Emitted when the slot menu overlay opens for a slot */
53
- readonly luzmoSlotMenuActive: import("@angular/core").OutputEmitterRef<unknown>;
53
+ readonly luzmoSlotMenuActive: import("@angular/core").OutputEmitterRef<CustomEvent<SlotMenuActiveEventDetail>>;
54
54
  /** Emitted to highlight the active column or formula in the slot menu */
55
- readonly luzmoSlotMenuHighlight: import("@angular/core").OutputEmitterRef<unknown>;
55
+ readonly luzmoSlotMenuHighlight: import("@angular/core").OutputEmitterRef<CustomEvent<SlotMenuHighlightEventDetail>>;
56
56
  /** Event that is fired when the info button is clicked in display-settings, includes the visibility state and ID values */
57
- readonly luzmoInfoVisibilityChanged: import("@angular/core").OutputEmitterRef<unknown>;
57
+ readonly luzmoInfoVisibilityChanged: import("@angular/core").OutputEmitterRef<CustomEvent<InfoVisibilityChangedEventDetail>>;
58
58
  /** Announces that the slot contents has changed */
59
59
  readonly luzmoSlotContentsChanged: import("@angular/core").OutputEmitterRef<CustomEvent<SlotContentsChangedEventDetail>>;
60
60
  constructor();
@@ -0,0 +1,46 @@
1
+ import { OnChanges, SimpleChanges } from '@angular/core';
2
+ import '@luzmo/analytics-components-kit/slot-menu-list';
3
+ import type { LuzmoSlotMenuList as LuzmoSlotMenuListHostElement, SlotListChangedEventDetail } from '@luzmo/analytics-components-kit/slot-menu-list';
4
+ import type { SlotContent } from '@luzmo/analytics-components-kit/types';
5
+ import type { SlotName } from '@luzmo/dashboard-contents-types';
6
+ import * as i0 from "@angular/core";
7
+ export type { SlotListChangedEventDetail } from '@luzmo/analytics-components-kit/slot-menu-list';
8
+ export declare class LuzmoSlotMenuList implements OnChanges {
9
+ private readonly elementRef;
10
+ private readonly renderer;
11
+ private readonly destroyRef;
12
+ private readonly host;
13
+ private readonly listenerCleanup;
14
+ /** The underlying custom element instance. Use to call imperative methods. */
15
+ get nativeElement(): LuzmoSlotMenuListHostElement;
16
+ /** The language of the settings interface */
17
+ language?: string;
18
+ /** The language to use for locale-aware formatting and labels */
19
+ contentLanguage?: string;
20
+ /** The list of slot contents (columns/formulas) shown in the reorderable list. */
21
+ slotContents?: SlotContent[];
22
+ /** The containing slot name used to identify measure calculations. */
23
+ slotName?: SlotName;
24
+ /** The containing slot type used to identify measure calculations. */
25
+ slotType?: string;
26
+ /** Index of the currently active/selected slot content. */
27
+ activeIndex?: number;
28
+ /** The size of the element */
29
+ size?: 's' | 'm' | 'l' | 'xl';
30
+ /** Emitted when the slot list changes */
31
+ readonly luzmoSlotListChanged: import("@angular/core").OutputEmitterRef<CustomEvent<SlotListChangedEventDetail>>;
32
+ constructor();
33
+ ngOnChanges(changes: SimpleChanges): void;
34
+ /**
35
+ * Forward a wrapper @Input to the underlying host element via Renderer2 so
36
+ * the wrapper stays compatible with non-DOM Angular platforms (SSR, tests).
37
+ * Unlike a "skip undefined" guard, this lets consumers reset values back to
38
+ * undefined / null by clearing their bindings.
39
+ */
40
+ private setHostProperty;
41
+ private bindEvents;
42
+ static ɵfac: i0.ɵɵFactoryDeclaration<LuzmoSlotMenuList, never>;
43
+ static ɵcmp: i0.ɵɵComponentDeclaration<LuzmoSlotMenuList, "luzmo-slot-menu-list", ["luzmoSlotMenuList"], { "language": { "alias": "language"; "required": false; }; "contentLanguage": { "alias": "contentLanguage"; "required": false; }; "slotContents": { "alias": "slotContents"; "required": false; }; "slotName": { "alias": "slotName"; "required": false; }; "slotType": { "alias": "slotType"; "required": false; }; "activeIndex": { "alias": "activeIndex"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, { "luzmoSlotListChanged": "luzmoSlotListChanged"; }, never, ["*"], true, never>;
44
+ }
45
+ /** The underlying custom element type for LuzmoSlotMenuList */
46
+ export type LuzmoSlotMenuListElement = LuzmoSlotMenuListHostElement;
@@ -0,0 +1,123 @@
1
+ import { ChangeDetectionStrategy, Component, DestroyRef, ElementRef, inject, Input, output, Renderer2 } from '@angular/core';
2
+ import '@luzmo/analytics-components-kit/slot-menu-list';
3
+ import * as i0 from "@angular/core";
4
+ const _c0 = ["*"];
5
+ /**
6
+ * Angular wrapper component for <luzmo-slot-menu-list>
7
+ */
8
+ export class LuzmoSlotMenuList {
9
+ elementRef = inject(ElementRef);
10
+ renderer = inject(Renderer2);
11
+ destroyRef = inject(DestroyRef);
12
+ host = this.elementRef.nativeElement;
13
+ listenerCleanup = [];
14
+ /** The underlying custom element instance. Use to call imperative methods. */
15
+ get nativeElement() {
16
+ return this.host;
17
+ }
18
+ /** The language of the settings interface */
19
+ language;
20
+ /** The language to use for locale-aware formatting and labels */
21
+ contentLanguage;
22
+ /** The list of slot contents (columns/formulas) shown in the reorderable list. */
23
+ slotContents;
24
+ /** The containing slot name used to identify measure calculations. */
25
+ slotName;
26
+ /** The containing slot type used to identify measure calculations. */
27
+ slotType;
28
+ /** Index of the currently active/selected slot content. */
29
+ activeIndex;
30
+ /** The size of the element */
31
+ size;
32
+ /** Emitted when the slot list changes */
33
+ luzmoSlotListChanged = output({ alias: 'luzmoSlotListChanged' });
34
+ constructor() {
35
+ this.bindEvents();
36
+ this.destroyRef.onDestroy(() => {
37
+ for (const cleanup of this.listenerCleanup) {
38
+ cleanup();
39
+ }
40
+ });
41
+ }
42
+ ngOnChanges(changes) {
43
+ for (const key of Object.keys(changes)) {
44
+ switch (key) {
45
+ case 'language':
46
+ this.setHostProperty('language', changes['language'].currentValue);
47
+ break;
48
+ case 'contentLanguage':
49
+ this.setHostProperty('contentLanguage', changes['contentLanguage'].currentValue);
50
+ break;
51
+ case 'slotContents':
52
+ this.setHostProperty('slotContents', changes['slotContents'].currentValue);
53
+ break;
54
+ case 'slotName':
55
+ this.setHostProperty('slotName', changes['slotName'].currentValue);
56
+ break;
57
+ case 'slotType':
58
+ this.setHostProperty('slotType', changes['slotType'].currentValue);
59
+ break;
60
+ case 'activeIndex':
61
+ this.setHostProperty('activeIndex', changes['activeIndex'].currentValue);
62
+ break;
63
+ case 'size':
64
+ this.setHostProperty('size', changes['size'].currentValue);
65
+ break;
66
+ default:
67
+ break;
68
+ }
69
+ }
70
+ }
71
+ /**
72
+ * Forward a wrapper @Input to the underlying host element via Renderer2 so
73
+ * the wrapper stays compatible with non-DOM Angular platforms (SSR, tests).
74
+ * Unlike a "skip undefined" guard, this lets consumers reset values back to
75
+ * undefined / null by clearing their bindings.
76
+ */
77
+ setHostProperty(key, value) {
78
+ this.renderer.setProperty(this.host, key, value);
79
+ }
80
+ bindEvents() {
81
+ this.listenerCleanup.push(this.renderer.listen(this.host, 'luzmo-slot-list-changed', (event) => {
82
+ const typed = event;
83
+ this.luzmoSlotListChanged.emit(typed);
84
+ }));
85
+ }
86
+ static ɵfac = function LuzmoSlotMenuList_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || LuzmoSlotMenuList)(); };
87
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LuzmoSlotMenuList, selectors: [["luzmo-slot-menu-list"]], inputs: { language: "language", contentLanguage: "contentLanguage", slotContents: "slotContents", slotName: "slotName", slotType: "slotType", activeIndex: "activeIndex", size: "size" }, outputs: { luzmoSlotListChanged: "luzmoSlotListChanged" }, exportAs: ["luzmoSlotMenuList"], features: [i0.ɵɵNgOnChangesFeature], ngContentSelectors: _c0, decls: 1, vars: 0, template: function LuzmoSlotMenuList_Template(rf, ctx) { if (rf & 1) {
88
+ i0.ɵɵprojectionDef();
89
+ i0.ɵɵprojection(0);
90
+ } }, encapsulation: 2 });
91
+ }
92
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LuzmoSlotMenuList, [{
93
+ type: Component,
94
+ args: [{
95
+ selector: 'luzmo-slot-menu-list',
96
+ exportAs: 'luzmoSlotMenuList',
97
+ standalone: true,
98
+ changeDetection: ChangeDetectionStrategy.OnPush,
99
+ template: '<ng-content />'
100
+ }]
101
+ }], () => [], { language: [{
102
+ type: Input,
103
+ args: [{ alias: 'language' }]
104
+ }], contentLanguage: [{
105
+ type: Input,
106
+ args: [{ alias: 'contentLanguage' }]
107
+ }], slotContents: [{
108
+ type: Input,
109
+ args: [{ alias: 'slotContents' }]
110
+ }], slotName: [{
111
+ type: Input,
112
+ args: [{ alias: 'slotName' }]
113
+ }], slotType: [{
114
+ type: Input,
115
+ args: [{ alias: 'slotType' }]
116
+ }], activeIndex: [{
117
+ type: Input,
118
+ args: [{ alias: 'activeIndex' }]
119
+ }], size: [{
120
+ type: Input,
121
+ args: [{ alias: 'size' }]
122
+ }], luzmoSlotListChanged: [{ type: i0.Output, args: ["luzmoSlotListChanged"] }] }); })();
123
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(LuzmoSlotMenuList, { className: "LuzmoSlotMenuList", filePath: "components/slot-menu-list.ts", lineNumber: 18 }); })();
@@ -0,0 +1,104 @@
1
+ import { OnChanges, SimpleChanges } from '@angular/core';
2
+ import '@luzmo/analytics-components-kit/slot-menu';
3
+ import type { LuzmoSlotMenu as LuzmoSlotMenuHostElement, InfoVisibilityChangedEventDetail, MeasureColumnsItem, SlotContentsChangedEventDetail, SlotMenuActiveEventDetail, SlotMenuHighlightEventDetail } from '@luzmo/analytics-components-kit/slot-menu';
4
+ import type { DatasetDataFields } from '@luzmo/analytics-components-kit/data-field-panel';
5
+ import type { LuzmoDisplaySettings } from '@luzmo/analytics-components-kit/display-settings';
6
+ import type { LuzmoSlotMenuList } from '@luzmo/analytics-components-kit/slot-menu-list';
7
+ import type { SlotContent } from '@luzmo/analytics-components-kit/types';
8
+ import type { SlotName, VizItemType } from '@luzmo/dashboard-contents-types';
9
+ import * as i0 from "@angular/core";
10
+ export type { InfoVisibilityChangedEventDetail, MeasureColumnsItem, SlotContentChangedEventDetail, SlotContentsChangedEventDetail, SlotListChangedEventDetail, SlotMenuActiveEventDetail, SlotMenuHighlightEventDetail } from '@luzmo/analytics-components-kit/slot-menu';
11
+ export declare class LuzmoSlotMenu implements OnChanges {
12
+ private readonly elementRef;
13
+ private readonly renderer;
14
+ private readonly destroyRef;
15
+ private readonly host;
16
+ private readonly listenerCleanup;
17
+ /** The underlying custom element instance. Use to call imperative methods. */
18
+ get nativeElement(): LuzmoSlotMenuHostElement;
19
+ /** The language of the settings interface */
20
+ language?: string;
21
+ /** The language to use for locale-aware formatting and labels */
22
+ contentLanguage?: string;
23
+ /** The slot type */
24
+ slotType?: 'numeric' | 'categorical' | 'mixed';
25
+ /** The name of the slot being edited. */
26
+ slotName?: SlotName;
27
+ /** The visualization item type that provides slot and option configuration. */
28
+ itemType?: VizItemType;
29
+ /** Whether to show the drag handle and allow dragging */
30
+ noDrag?: boolean;
31
+ /** Whether to show the close button */
32
+ noClose?: boolean;
33
+ /** The variant to show */
34
+ variant?: 'popup' | 'draggable' | 'default';
35
+ /** Whether to show the top menu label & delete button */
36
+ noTopMenuLabel?: boolean;
37
+ /** CSS selector for the boundary element that constrains dragging of the menu. */
38
+ dragBoundary?: string;
39
+ /** Whether grand-totals options are available for this slot. */
40
+ areGrandTotalsEnabled?: boolean;
41
+ /** Whether datetime display options are available for this slot. */
42
+ areDatetimeOptionsEnabled?: boolean;
43
+ /** Whether numeric binning options are hidden for this slot. */
44
+ isBinningDisabled?: boolean;
45
+ /** Whether aggregation options are hidden for this slot. */
46
+ isAggregationDisabled?: boolean;
47
+ /** Whether cumulative-sum options are available for this slot. */
48
+ isCumulativeSumEnabled?: boolean;
49
+ /** The contents (columns/formulas) assigned to this slot. */
50
+ slotContents?: SlotContent[];
51
+ /** Measure columns available for rate aggregation. */
52
+ measureColumns?: MeasureColumnsItem[];
53
+ /** (Optional) If you only want to display a specific content of a slot, you can set the slotIndex to the index of the content you want to display. */
54
+ slotIndex?: number;
55
+ /** Reference to the rendered display-settings element. */
56
+ displaySettingsElement?: LuzmoDisplaySettings;
57
+ /** Reference to the rendered slot-menu-list element. */
58
+ slotMenuListElement?: LuzmoSlotMenuList;
59
+ /** The API URL of the databroker */
60
+ apiUrl?: string;
61
+ /** The auth key of the databroker */
62
+ authKey?: string;
63
+ /** The auth token of the databroker */
64
+ authToken?: string;
65
+ /** Datasets used to resolve column names in ad-hoc calculation previews. */
66
+ datasetsDataFields?: DatasetDataFields[];
67
+ /** The size of the element */
68
+ size?: 's' | 'm' | 'l' | 'xl';
69
+ /** Emitted when the slot contents change */
70
+ readonly luzmoSlotContentsChanged: import("@angular/core").OutputEmitterRef<CustomEvent<SlotContentsChangedEventDetail>>;
71
+ /** Emitted when the slot menu is closed */
72
+ readonly luzmoClose: import("@angular/core").OutputEmitterRef<CustomEvent<void>>;
73
+ /** Emitted when the slot menu becomes active for a dataset */
74
+ readonly luzmoSlotMenuActive: import("@angular/core").OutputEmitterRef<CustomEvent<SlotMenuActiveEventDetail>>;
75
+ /** Emitted to highlight a column or formula in the slot menu */
76
+ readonly luzmoSlotMenuHighlight: import("@angular/core").OutputEmitterRef<CustomEvent<SlotMenuHighlightEventDetail>>;
77
+ /** Emitted when the menu becomes inactive. */
78
+ readonly luzmoSlotMenuInactive: import("@angular/core").OutputEmitterRef<CustomEvent<unknown>>;
79
+ /** Event that is fired when the info button is clicked in display-settings, includes the visibility state and ID values */
80
+ readonly luzmoInfoVisibilityChanged: import("@angular/core").OutputEmitterRef<CustomEvent<InfoVisibilityChangedEventDetail>>;
81
+ constructor();
82
+ ngOnChanges(changes: SimpleChanges): void;
83
+ /**
84
+ * Forward a wrapper @Input to the underlying host element via Renderer2 so
85
+ * the wrapper stays compatible with non-DOM Angular platforms (SSR, tests).
86
+ * Unlike a "skip undefined" guard, this lets consumers reset values back to
87
+ * undefined / null by clearing their bindings.
88
+ */
89
+ private setHostProperty;
90
+ private bindEvents;
91
+ close(): void;
92
+ static ɵfac: i0.ɵɵFactoryDeclaration<LuzmoSlotMenu, never>;
93
+ static ɵcmp: i0.ɵɵComponentDeclaration<LuzmoSlotMenu, "luzmo-slot-menu", ["luzmoSlotMenu"], { "language": { "alias": "language"; "required": false; }; "contentLanguage": { "alias": "contentLanguage"; "required": false; }; "slotType": { "alias": "slotType"; "required": false; }; "slotName": { "alias": "slotName"; "required": false; }; "itemType": { "alias": "itemType"; "required": false; }; "noDrag": { "alias": "noDrag"; "required": false; }; "noClose": { "alias": "noClose"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "noTopMenuLabel": { "alias": "noTopMenuLabel"; "required": false; }; "dragBoundary": { "alias": "dragBoundary"; "required": false; }; "areGrandTotalsEnabled": { "alias": "areGrandTotalsEnabled"; "required": false; }; "areDatetimeOptionsEnabled": { "alias": "areDatetimeOptionsEnabled"; "required": false; }; "isBinningDisabled": { "alias": "isBinningDisabled"; "required": false; }; "isAggregationDisabled": { "alias": "isAggregationDisabled"; "required": false; }; "isCumulativeSumEnabled": { "alias": "isCumulativeSumEnabled"; "required": false; }; "slotContents": { "alias": "slotContents"; "required": false; }; "measureColumns": { "alias": "measureColumns"; "required": false; }; "slotIndex": { "alias": "slotIndex"; "required": false; }; "displaySettingsElement": { "alias": "displaySettingsElement"; "required": false; }; "slotMenuListElement": { "alias": "slotMenuListElement"; "required": false; }; "apiUrl": { "alias": "apiUrl"; "required": false; }; "authKey": { "alias": "authKey"; "required": false; }; "authToken": { "alias": "authToken"; "required": false; }; "datasetsDataFields": { "alias": "datasetsDataFields"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, { "luzmoSlotContentsChanged": "luzmoSlotContentsChanged"; "luzmoClose": "luzmoClose"; "luzmoSlotMenuActive": "luzmoSlotMenuActive"; "luzmoSlotMenuHighlight": "luzmoSlotMenuHighlight"; "luzmoSlotMenuInactive": "luzmoSlotMenuInactive"; "luzmoInfoVisibilityChanged": "luzmoInfoVisibilityChanged"; }, never, ["*"], true, never>;
94
+ static ngAcceptInputType_noDrag: unknown;
95
+ static ngAcceptInputType_noClose: unknown;
96
+ static ngAcceptInputType_noTopMenuLabel: unknown;
97
+ static ngAcceptInputType_areGrandTotalsEnabled: unknown;
98
+ static ngAcceptInputType_areDatetimeOptionsEnabled: unknown;
99
+ static ngAcceptInputType_isBinningDisabled: unknown;
100
+ static ngAcceptInputType_isAggregationDisabled: unknown;
101
+ static ngAcceptInputType_isCumulativeSumEnabled: unknown;
102
+ }
103
+ /** The underlying custom element type for LuzmoSlotMenu */
104
+ export type LuzmoSlotMenuElement = LuzmoSlotMenuHostElement;