elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.62k stars 8.22k forks source link

[visualize embeddable] Filters notification not displayed for visualize embeddable in Dashboard #193598

Open nreese opened 1 month ago

nreese commented 1 month ago

Following https://github.com/elastic/kibana/pull/192002, filters notification badge is only displayed for embeddables that partially implement the unified search interface. The code snippet below shows the isApiCompatible check used by the filters notification action. If this check returns false, then the filters notification badge is not displayed for a panel.

https://github.com/elastic/kibana/blob/main/src/plugins/dashboard/public/dashboard_actions/filters_notification_action.tsx#L41

const isApiCompatible = (api: unknown | null): api is FiltersNotificationActionApi =>
  Boolean(
    apiHasUniqueId(api) && apiCanAccessViewMode(api) && apiPublishesPartialUnifiedSearch(api)
  );

The visualize embeddable does not implement unified search interface and provide filters$ or query$. This results in the filters notification badge not getting displayed for the visualize embeddable.

Steps to reproduce

  1. install sample web logs
  2. create aggregation based embeddable with filter
  3. add visualize to dashboard. Filter notification badge should be displayed in the panel heading. Instead, it is missing. In the screen shot below, notice how the saved search panel displays the filter notification badge while the visualize panel does not. Image
elasticmachine commented 1 month ago

Pinging @elastic/kibana-visualizations (Team:Visualizations)

mbondyra commented 1 month ago

Hi @nreese , thank you for identifying the root cause! Would you mind taking this one on? It looks like the bug was introduced with the recent embeddable refactor, and it’s not clear if it falls under the Visualizations team as it is related to Embeddables new architecture. We’re currently tied up with the Lens refactor, so your help here would be incredibly appreciated! 🙏

elasticmachine commented 1 month ago

Pinging @elastic/kibana-presentation (Team:Presentation)