Skip to content

Commit ac15669

Browse files
committed
fix(tui): use fixed glamour style to avoid slow terminal detection
- Replace glamour.WithAutoStyle() with glamour.WithStylePath("dark") - Fixes 7+ second delays when entering bean detail view - WithAutoStyle() terminal detection was causing hangs across all terminals Closes: beans-52yy
1 parent 024656d commit ac15669

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

.beans/beans-52yy--tui-random-long-delays-when-entering-bean-detail-v.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
---
22
title: 'TUI: Random long delays when entering bean detail view'
3-
status: todo
3+
status: completed
44
type: bug
55
priority: normal
66
created_at: 2025-12-13T01:27:14Z
7-
updated_at: 2025-12-13T01:27:34Z
7+
updated_at: 2025-12-13T01:47:46Z
88
---
99

1010
## Description

internal/tui/detail.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@ var (
2828
func getGlamourRenderer() *glamour.TermRenderer {
2929
glamourRendererOnce.Do(func() {
3030
var err error
31-
glamourRenderer, err = glamour.NewTermRenderer(glamour.WithAutoStyle())
31+
// Use DarkStyle instead of WithAutoStyle() to avoid slow terminal detection
32+
// that can cause multi-second delays in some terminals
33+
glamourRenderer, err = glamour.NewTermRenderer(glamour.WithStylePath("dark"))
3234
if err != nil {
3335
glamourRenderer = nil
3436
}

0 commit comments

Comments
 (0)