-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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] Single Metric Viewer embeddable: add open and edit panel actions #179364
Changes from 11 commits
24e4b4d
db9a4fd
da7983d
c14ca22
6647978
bc6fb2c
a7d5a1e
fc585a5
120d0f2
c39b883
4c0191b
902197b
6b6025a
26dbdce
968eb17
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,7 +14,7 @@ import type { JobId, CombinedJob } from '../../../common/types/anomaly_detection | |
*/ | ||
export function getControlsForDetector( | ||
selectedDetectorIndex: number, | ||
selectedEntities: Record<string, any>, | ||
selectedEntities: Record<string, any> | undefined, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can you please use the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Went back to double check and the original There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think |
||
selectedJobId: JobId, | ||
job?: CombinedJob | ||
): Entity[] { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: can be simplified even further, preventing access to the
isTImeBased
method on each render!There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a reliance on the
isTimeBasedIndex
variable a few lines down - I considered wrapping in a useEffect but I think the addition of the function would negate any small optimization we'd get from that, in my opinion. Happy to discuss further if you feel strongly. 😄