fix(span-tree): Sibling span multi groups#33211
Conversation
| toggleSpanTree: () => void; | ||
| trace: Readonly<ParsedTraceType>; | ||
| treeDepth: number; | ||
| groupOccurrence?: number; |
There was a problem hiding this comment.
I chose to name it groupOccurrence here as opposed to just occurrence, since I thought it would be confusing without clarification, as this prop is part of just a regular spanBar
k-fish
left a comment
There was a problem hiding this comment.
Assuming you get it passing 👍 , like the use of groupOccurrence for clarity.
| | ((props: {eventSlug: string; orgSlug: string}) => void) | ||
| | undefined; | ||
| toggleSiblingSpanGroup: ((span: SpanType) => void) | undefined; | ||
| toggleSiblingSpanGroup: ((span: SpanType, occurrence?: number) => void) | undefined; |
There was a problem hiding this comment.
I know you switched it, but I actually think it shouldn't be optional, conceptually, if you are picking a group, it must have occurred.
There was a problem hiding this comment.
Yeah true, I agree it shouldn't be optional at least for spanSiblingGroupBar, but I think it should be kept optional for spanBar, since this component is associated with a group only when it is part of an expanded sibling group. So regular spanBars won't have an occurrence.
There was a problem hiding this comment.
Nevermind you're right, I changed it so it's required here as well, since the function should always receive an occurrence number.
This PR fixes a bug with autogrouped sibling spans, where clicking to expand/collapse one group would do the same for other groups that share the same operation and description.