Skip to content

Commit ffaadd5

Browse files
mjqclaude
andcommitted
fix(perf): Clamp negative otherPercentage in operation duration breakdown
The `otherPercentage` value could go negative due to floating-point drift, producing an invalid negative CSS width. Use Math.max to clamp it to zero. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 50fb9c6 commit ffaadd5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

static/app/views/performance/eap/overviewSpansTable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ function renderOperationDurationCell(row: Record<string, any>, theme: Theme) {
432432
</div>
433433
);
434434
})}
435-
<div key="other" style={{width: toPercent(otherPercentage || 0)}}>
435+
<div key="other" style={{width: toPercent(Math.max(otherPercentage, 0))}}>
436436
<Tooltip title={<div>{t('Other')}</div>} containerDisplayMode="block">
437437
<OtherRelativeOpsBreakdown />
438438
</Tooltip>

0 commit comments

Comments
 (0)