[BUG] /insights report: bar-chart labels truncated (width: 100px too narrow)

Resolved 💬 1 comment Opened Apr 25, 2026 by laurac8r Closed May 29, 2026

Summary

In the HTML report produced by /insights (~/.claude/usage-data/report.html), several bar-chart row labels are truncated with an ellipsis because the .bar-label CSS rule hard-codes width: 100px, while the longest labels exceed that width.

Repro

  1. Run /insights in any Claude Code session with enough history.
  2. Open the resulting ~/.claude/usage-data/report.html.
  3. Look at the What Helped Most (Claude's Capabilities) chart — the row labeled Fast/Accurate Search (20 chars) shows as Fast/Accurate Se....

The same truncation hits other charts that share .bar-label:

| Label | Chars |
|------------------------|-------|
| Tool Permission Denied | 22 |
| Misunderstood Request | 21 |
| User Rejected Action | 20 |
| Pause And Checkpoint | 20 |
| Iterative Refinement | 20 |
| Fast/Accurate Search | 20 |

At font-size: 11px, ~22 chars needs ≈140–150px.

Source of the bug

In the rendered HTML:

.bar-label {
  width: 100px;            /* too narrow */
  font-size: 11px;
  color: #475569;
  flex-shrink: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

The width is fixed and text-overflow: ellipsis clips anything wider.

Suggested fix

Bump width in the /insights report template to ~150px (or, more robustly, switch to a per-chart auto-sized column via CSS grid so the column always matches the widest label in that chart).

Workaround

Editing width: 100pxwidth: 150px in the rendered report.html fixes it for the current run, but the next /insights regenerates the file from the same template, so the bug returns each run.

Screenshot

Local screenshot shows the truncated Fast/Accurate Se... row in the What Helped Most chart; happy to attach if useful.

Environment

  • Claude Code CLI, Opus 4.7 (1M ctx)
  • macOS Darwin 25.4.0
  • Date observed: 2026-04-25

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗