66a64cfe0674a83a6d4d3ffbd41dc6e35dd86a84
- Author
- Ayman Bagabas <ayman.bagabas@gmail.com>
- Committer
- Ayman Bagabas <ayman.bagabas@gmail.com>
- Date
Message
fix: update bubbles window size on change
Diff
1diff --git a/internal/tui/bubbles/git/bubble.go b/internal/tui/bubbles/git/bubble.go
2index d2c6bb0025e16c180d52f231f2a76ef4d978fa9f..6b5ea700c42478615b56e36c06f7a554e3cc4e0f 100644
3--- a/internal/tui/bubbles/git/bubble.go
4+++ b/internal/tui/bubbles/git/bubble.go
5@@ -80,6 +80,13 @@ func (b *Bubble) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
6 case tea.WindowSizeMsg:
7 b.width = msg.Width
8 b.height = msg.Height
9+ for i, bx := range b.boxes {
10+ m, cmd := bx.Update(msg)
11+ b.boxes[i] = m
12+ if cmd != nil {
13+ cmds = append(cmds, cmd)
14+ }
15+ }
16 case refs.RefMsg:
17 b.state = treeState
18 b.ref = msg