@crowdstrike/logscale-dashboard 1.142.0--devbuild-1482--sha-600b83cccfc65669cb6801e5299bff21e1bd2a7c → 1.143.0--build-1495--sha-1355c819ee5552532633ad01cad6e6969d1624da

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/index.d.ts CHANGED
@@ -125,6 +125,14 @@ export declare class Dashboard extends WebcomponentBase<Options> {
125
125
  * @public
126
126
  */
127
127
  onDashboardStateChanged(callback: (dashboardState: DashboardNavigationTargetInfo) => void | null): void;
128
+ /**
129
+ * Implement this hook to receive notifications about invocations of `HostInteractions` of type "row".
130
+ *
131
+ * @param callback - function for handling `HostInteractionTarget`.
132
+ *
133
+ * @public
134
+ */
135
+ onHostInteractionInvoked(callback: (hostInteractionEvent: HostInteractionEvent) => void | null): void;
128
136
  }
129
137
 
130
138
  /**
@@ -238,6 +246,14 @@ export declare type EditState = {
238
246
  widgetId?: string;
239
247
  };
240
248
 
249
+ /**
250
+ * Encapsulates information about the LogScale data which has been interacted with,
251
+ * and which interaction was the source of the event.
252
+ *
253
+ * @public
254
+ */
255
+ export declare type HostInteractionEvent = RowInteractionEvent;
256
+
241
257
  /**
242
258
  * LogScale Interactions.
243
259
  * See [documentation](https://library.humio.com/data-analysis/dashboards-interactions.html) for more information.
@@ -252,12 +268,12 @@ export declare type Interaction = CustomLinkInteraction | SearchLinkInteraction
252
268
  * @public
253
269
  */
254
270
  export declare type InteractionCondition = {
255
- "operator": "present" | "not-present";
256
- "fieldName": string;
271
+ operator: "present" | "not-present";
272
+ fieldName: string;
257
273
  } | {
258
- "operator": "starts-with" | "ends-with" | "equal" | "not-equal" | "contains" | "not-contains";
259
- "fieldName": string;
260
- "argument": string;
274
+ operator: "starts-with" | "ends-with" | "equal" | "not-equal" | "contains" | "not-contains";
275
+ fieldName: string;
276
+ argument: string;
261
277
  };
262
278
 
263
279
  /**
@@ -335,7 +351,7 @@ export declare interface Options extends CommonOptions, DashboardParams {
335
351
  * Note: `hostInteractions` can only be configured through the host application and will not be configurable through the
336
352
  * interactions panel inside LogScale.
337
353
  */
338
- hostInteractions?: Array<Interaction>;
354
+ hostInteractions?: Array<Interaction | RowInteraction>;
339
355
  /**
340
356
  * Hook for handling LogScale navigation targets, e.g. navigating from SearchView to Dashboard or vice versa.
341
357
  *
@@ -407,12 +423,48 @@ export declare type QueryPaginationOptions = {
407
423
  * A repository or view option for the LogScale Search view Repository or View selector.
408
424
  *
409
425
  * @public */
410
- declare type RepoOrViewOption = {
426
+ export declare type RepoOrViewOption = {
411
427
  name: string;
412
428
  label: string;
413
429
  type: "repo" | "view";
414
430
  };
415
431
 
432
+ /**
433
+ * A generic row interaction type which has to be handled by the host application (you).
434
+ *
435
+ * The name of the interaction is attached to the corresponding `RowInteractionTarget`
436
+ * which is generated when interaction is invoked.
437
+ *
438
+ * @public
439
+ */
440
+ export declare type RowInteraction = {
441
+ type: "row";
442
+ id: string;
443
+ /**
444
+ * A template to render a title for the interaction when rendered in the interactions menu.
445
+ * This supports [LogScale template expressions](https://library.humio.com/data-analysis/template-language-expressions.html).
446
+ */
447
+ titleTemplate: string;
448
+ conditions?: Array<InteractionCondition> | null;
449
+ };
450
+
451
+ /**
452
+ * Event generated from the invocation of a `RowInteraction`.
453
+ *
454
+ * @public
455
+ */
456
+ export declare type RowInteractionEvent = {
457
+ type: "row";
458
+ /**
459
+ * The id of the interaction which was the source of the event.
460
+ */
461
+ id: string;
462
+ /**
463
+ * The row which has been interacted with.
464
+ */
465
+ row: Record<string, string>;
466
+ };
467
+
416
468
  /**
417
469
  * Search Link interaction type.
418
470
  * If `onNavigationTargetChange` hook is implemented, these interactions will
@@ -521,7 +573,17 @@ export declare type SetParametersOptions = {
521
573
  * @public
522
574
  */
523
575
  export declare type SharedInteractionProperties = {
576
+ /**
577
+ * The name of the interaction.
578
+ * This should be unique.
579
+ */
524
580
  name: string;
581
+ /**
582
+ * A template to render a title for the interaction when rendered in the interactions menu.
583
+ * This supports [LogScale template expressions](https://library.humio.com/data-analysis/template-language-expressions.html).
584
+ *
585
+ * If omitted, `name` will be used to render the interaction title.
586
+ */
525
587
  titleTemplate?: string | null;
526
588
  conditions?: Array<InteractionCondition> | null;
527
589
  };