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

[ML] Resizable/Collapsible Top Influencers section #130018

Merged
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
13 changes: 13 additions & 0 deletions x-pack/plugins/ml/common/types/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ export const ML_GETTING_STARTED_CALLOUT_DISMISSED = 'ml.gettingStarted.isDismiss

export const ML_FROZEN_TIER_PREFERENCE = 'ml.frozenDataTierPreference';

export const ML_ANOMALY_EXPLORER_PANELS = 'ml.anomalyExplorerPanels';

export type PartitionFieldConfig =
| {
/**
Expand Down Expand Up @@ -42,11 +44,22 @@ export type PartitionFieldsConfig =

export type ApplyTimeRangeConfig = boolean | undefined;

export interface PanelState {
size: number;
isCollapsed: boolean;
}

export interface AnomalyExplorerPanelsState {
topInfluencers: PanelState;
mainPage: { size: number };
}

export type MlStorage = Partial<{
[ML_ENTITY_FIELDS_CONFIG]: PartitionFieldsConfig;
[ML_APPLY_TIME_RANGE_CONFIG]: ApplyTimeRangeConfig;
[ML_GETTING_STARTED_CALLOUT_DISMISSED]: boolean | undefined;
[ML_FROZEN_TIER_PREFERENCE]: 'exclude_frozen' | 'include_frozen';
[ML_ANOMALY_EXPLORER_PANELS]: AnomalyExplorerPanelsState | undefined;
}> | null;

export type MlStorageKey = keyof Exclude<MlStorage, null>;
11 changes: 0 additions & 11 deletions x-pack/plugins/ml/public/application/explorer/_explorer.scss
Original file line number Diff line number Diff line change
@@ -1,18 +1,7 @@
$borderRadius: $euiBorderRadius / 2;

.ml-explorer {
width: 100%;
display: inline-block;
color: $euiColorDarkShade;

.results-container {
padding: 0 0 $euiSize 0;

// SASSTODO: Overwrite of bootstrap
.col-xs-12 {
width: calc(100% - #{$euiSizeXL});
padding-left: $euiSize;
}

.no-influencers-warning {
float: left;
Expand Down
Loading