fix(search): show previews for commands truncated by custom columns#3601
fix(search): show previews for commands truncated by custom columns#3601ychampion wants to merge 1 commit into
Conversation
Constraint: Preview visibility must use the same fixed and expanding column model as the result list. Confidence: high Scope-risk: narrow Directive: Keep preview visibility width calculations aligned with result-column layout changes. Tested: client-only atuin unit tests, focused preview tests, Clippy, rustfmt, and git diff checks. Not-tested: full default-feature workspace suite due local disk limits.
Fossier: Manual Review Requested
Score BreakdownTotal Score: 60.4/100 | Confidence: 100% | Outcome: REVIEW
|
Greptile SummaryFixes incorrect preview-height calculation when users configure extra UI columns (
Confidence Score: 5/5Safe to merge — the change is isolated to preview height calculation and has no effect on data or history storage. The fix replaces a hardcoded constant with a dynamic computation that correctly accounts for all configured columns. The math reproduces the original behaviour with default columns, the new test covers the reported scenario, and there are no side effects outside the display path. No files require special attention. Important Files Changed
Reviews (1): Last reviewed commit: "Ensure auto previews follow configured r..." | Re-trigger Greptile |
Summary
Why
The auto strategy still assumed the default 19-cell prefix. With
datetimeandexitcolumns enabled, the selected command can be truncated even though the preview calculation thinks it fits.Fixes #3599.
Validation
cargo test -p atuin --no-default-features --features client calc_preview_height -- --nocapture- passed (2 tests)cargo test -p atuin --no-default-features --features client --bin atuin- passed (200 tests)cargo clippy -p atuin --no-default-features --features client --bin atuin -- -D warnings -A unused-variables- passedcargo fmt --all -- --check- passedChecks