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

[RAC][Observability] fix flyout in fullscreen mode #108746

Merged
merged 3 commits into from
Aug 17, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
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
1 change: 1 addition & 0 deletions x-pack/plugins/observability/public/pages/alerts/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import { AlertsTableTGrid } from './alerts_table_t_grid';
import { StatusFilter } from './status_filter';
import { useFetcher } from '../../hooks/use_fetcher';
import { callObservabilityApi } from '../../services/call_observability_api';
import './styles.scss';

export interface TopAlert {
fields: ParsedTechnicalFields;
Expand Down
12 changes: 12 additions & 0 deletions x-pack/plugins/observability/public/pages/alerts/styles.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
$fullscreenFlyoutTop: 72px;
Copy link
Contributor

Choose a reason for hiding this comment

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

This "magic number" makes me a little nervous. There are sass variables for things like the kbnHeaderOffset: https://github.com/elastic/kibana/blob/master/src/core/public/_variables.scss#L6, but there doesn't seem to be anything suitable for here and this use case.

.kbnBody.euiBody--headerIsFixed.euiDataGrid__restrictBody {
Copy link
Contributor

Choose a reason for hiding this comment

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

Again, makes me a little nervous how deeply we're nesting into EUI classes, but I can't think of a better solution right now 🤔

.euiOverlayMask--belowHeader {
top: $fullscreenFlyoutTop;
}

.euiFlyout,
.euiCollapsibleNav {
top: $fullscreenFlyoutTop;
height: calc(100% - #{$fullscreenFlyoutTop});
}
}