fix(tracemetrics): Remove sorting styles from embedded table#114588
Conversation
When the metrics samples table is embedded in the trace waterfall view, header columns are not interactive. Disable sorting in embedded mode so headers render as plain divs without hover effects or button semantics. Co-Authored-By: Claude Opus 4 <noreply@anthropic.com>
Add 'Type' as the header label for the METRIC_TYPE column in the embedded metrics samples table. Co-Authored-By: Claude Opus 4 <noreply@anthropic.com>
f6bfd5a to
43bd3e8
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 43bd3e8. Configure here.
| const label = getFieldLabel(field); | ||
| const hasPadding = field !== VirtualTableSampleColumnKey.EXPAND_ROW; | ||
| const canSort = SORTABLE_SAMPLE_COLUMNS.has(field); | ||
| const canSort = !embedded && SORTABLE_SAMPLE_COLUMNS.has(field); |
There was a problem hiding this comment.
Sort indicator still visible in embedded table
Medium Severity
The sort prop is still passed unconditionally to StyledSimpleTableHeaderCell even when embedded is true. The underlying SimpleTable.HeaderCell uses sort to derive isSorted, which renders a sort arrow icon and changes the header text color. So while the click handler is correctly suppressed for embedded mode, the visual sort indicators (arrow + text color) can still appear if query params contain matching sort fields like METRIC_VALUE or TIMESTAMP. The sort prop also needs to be conditioned on !embedded (or on canSort) to fully remove sorting styles.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 43bd3e8. Configure here.
There was a problem hiding this comment.
I think this is fine? just so that users know how they are sorted ...
This PR removes the sorting styles from the embedded application metrics table. As well I added in a header value for metric type so now it'll render "Type" for that column rather than being just blank. Closes LOGS-726 --------- Co-authored-by: Claude Opus 4 <noreply@anthropic.com>


This PR removes the sorting styles from the embedded application metrics table. As well I added in a header value for metric type so now it'll render "Type" for that column rather than being just blank.
Closes LOGS-726