Skip to content

Commit

Permalink
[dashboard] fix Chrome no longer hidden for reports (elastic#206988)
Browse files Browse the repository at this point in the history
Fixes elastic#205794

elastic#196275 removed `setIsVisible`
because https://github.com/elastic/kibana/pull/196275/files#r1811034594.
I could not reproduce the top nav disappearing and reappearing issue.

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
  • Loading branch information
2 people authored and cqliu1 committed Jan 21, 2025
1 parent f7a275e commit de5be06
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,13 @@ export function InternalDashboardTopNav({
dashboardTitleRef.current?.focus();
}, [title, viewMode]);

/*
* Manage chrome visibility when dashboard is in print mode.
*/
useEffect(() => {
if (!embedSettings && viewMode === 'print') coreServices.chrome.setIsVisible(false);
}, [embedSettings, viewMode]);

/**
* populate recently accessed, and set is chrome visible.
*/
Expand Down

0 comments on commit de5be06

Please sign in to comment.