-
Notifications
You must be signed in to change notification settings - Fork 8.5k
[ML] Performance improvements to annotations editing in Single Metric Viewer & buttons placement #83216
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
Merged
Merged
[ML] Performance improvements to annotations editing in Single Metric Viewer & buttons placement #83216
Changes from 4 commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
db8673c
[ML] Change placement of annotation footer buttons
qn895 3d854a2
[ML] Fix performance issue with annotation/renderFocusChart on SMV
qn895 b5166e6
[ML] Add AnnotationUpdatesService and MlAnnotationComponent
qn895 528a8de
[ML] Update type definition
qn895 81e20c4
[ML] Add to AnnotationUpdatesService context, update tests
qn895 bafde0d
[ML] Update snapshots for AnnotationsTable
qn895 927b38d
Merge remote upstream into ml-annotations-smv-improvements
qn895 c4ebb5e
Merge remote-tracking branch 'upstream/master' into ml-annotations-sm…
qn895 d3d4ce4
Merge remote-tracking branch 'upstream/master' into ml-annotations-sm…
qn895 eb1da71
Merge remote-tracking branch 'upstream/master' into ml-annotations-sm…
qn895 6eff2c8
[ML] Delete MlAnnotationComponent
qn895 1365c52
[ML] Update updateBtn to grab by id
qn895 0cf7ad0
[ML] Rename update$, isAnnotationInitialized$
qn895 2165da7
[ML] Add MlAnnotationUpdatesContext.Provider, rename file
qn895 d2cb370
Merge upstream/main into ml-annotations-smv-improvements
qn895 3575d6a
Update test types
qn895 f179e79
Merge remote-tracking branch 'upstream/master' into ml-annotations-sm…
qn895 588bedd
[ML] Remove console log
qn895 b67515d
Merge remote-tracking branch 'upstream/master' into ml-annotations-sm…
qn895 9b8020b
[ML] Move annotationUpdatesService to beforeEach
qn895 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
...s/ml/public/application/components/annotations/annotations_service/annotation_service.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| /* | ||
| * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
| * or more contributor license agreements. Licensed under the Elastic License; | ||
| * you may not use this file except in compliance with the Elastic License. | ||
| */ | ||
|
|
||
| import React, { FC, useMemo } from 'react'; | ||
| import { AnnotationUpdatesService } from '../../../services/annotations_service'; | ||
|
|
||
| interface MlAnnotationWrapperProps { | ||
| children: (annotationUpdatesService: AnnotationUpdatesService) => React.ReactElement; | ||
| } | ||
|
|
||
| export const MlAnnotationComponent: FC<MlAnnotationWrapperProps> = ({ children }) => { | ||
darnautov marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| const service = useMemo(() => new AnnotationUpdatesService(), []); | ||
| return <>{children(service)}</>; | ||
| }; | ||
7 changes: 7 additions & 0 deletions
7
x-pack/plugins/ml/public/application/components/annotations/annotations_service/index.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| /* | ||
| * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
| * or more contributor license agreements. Licensed under the Elastic License; | ||
| * you may not use this file except in compliance with the Elastic License. | ||
| */ | ||
|
|
||
| export { MlAnnotationComponent } from './annotation_service'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.