Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

corrected spy fullscreen mode #8844

Merged
merged 2 commits into from
Oct 28, 2016
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/ui/public/visualize/visualize.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,20 @@ uiModules

let applyClassNames = function () {
let $visEl = getVisContainer();
const $spyEl = getter('.visualize-spy-container')();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what do you think about defining getSpyElement in a way getVisContainer is defined just for consistency reasons ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getSpyContainer would be more consistent though ;o)

let fullSpy = ($scope.spy.mode && ($scope.spy.mode.fill || $scope.fullScreenSpy));

$visEl.toggleClass('spy-only', Boolean(fullSpy));
if ($spyEl) {
$spyEl.toggleClass('only', Boolean(fullSpy));
}

$timeout(function () {
if (shouldHaveFullSpy()) {
$visEl.addClass('spy-only');
if ($spyEl) {
$spyEl.addClass('only');
}
};
}, 0);
};
Expand Down
4 changes: 2 additions & 2 deletions src/ui/public/visualize/visualize.less
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ visualize-spy {
margin-right: 5px;
}

&.only {
.visualize-spy-container {
.visualize-spy-container {
&.only {
height: auto;
}
}
Expand Down