mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Added playlist controls to new react DashNav
This commit is contained in:
@@ -120,12 +120,13 @@ export function grafanaAppDirective(playlistSrv, contextSrv, $timeout, $rootScop
|
||||
body.toggleClass('sidemenu-hidden');
|
||||
});
|
||||
|
||||
scope.$watch(
|
||||
() => playlistSrv.isPlaying,
|
||||
newValue => {
|
||||
elem.toggleClass('view-mode--playlist', newValue === true);
|
||||
}
|
||||
);
|
||||
appEvents.on('playlist-started', () => {
|
||||
elem.toggleClass('view-mode--playlist', true);
|
||||
});
|
||||
|
||||
appEvents.on('playlist-stopped', () => {
|
||||
elem.toggleClass('view-mode--playlist', false);
|
||||
});
|
||||
|
||||
// check if we are in server side render
|
||||
if (document.cookie.indexOf('renderKey') !== -1) {
|
||||
@@ -258,10 +259,6 @@ export function grafanaAppDirective(playlistSrv, contextSrv, $timeout, $rootScop
|
||||
}, 100);
|
||||
}
|
||||
|
||||
if (target.parents('.navbar-buttons--playlist').length === 0) {
|
||||
playlistSrv.stop();
|
||||
}
|
||||
|
||||
// hide search
|
||||
if (body.find('.search-container').length > 0) {
|
||||
if (target.parents('.search-results-container, .search-field-wrapper').length === 0) {
|
||||
|
||||
Reference in New Issue
Block a user