charmbracelet / charmbracelet/bubbletea
Hard-tab cursor optimization breaks column alignment in View() output
- Dominant language
- Go
- Stars
- 44.9k
- Forks
- 1.3k
- PR merge metrics
- No merged PRs in 30d
Description
## Bug Description
The v2 cursor optimization that replaces space runs with hard tabs silently breaks column alignment in `View()` output. `relativeCursorMove()` in `screen.go` treats "clear" cells as tab candidates, breaking space-based column alignment.
## Expected Behavior
Tab compression should not alter the visual layout of space-based column alignment.
## Suggested Fix
Add `tea.WithHardTabs(false)` option or restrict tab compression to renderer-internal output only.
Related to #1614.
Contributor guide
Research direction
Start in screen.go at relativeCursorMove() and reproduce the View() output described in the issue, checking how clear cells become hard-tab candidates. Compare the behavior with related issue #1614; done means tab compression no longer changes the visual layout of space-based column alignment.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100