bdac20b13740956e40d4ffdd31052825489a83be
- Author
- Ayman Bagabas <ayman.bagabas@gmail.com>
- Committer
- Ayman Bagabas <ayman.bagabas@gmail.com>
- Date
Message
fix(ui): clear filename statusbar value on event
Diff
1diff --git a/ui/pages/repo/files.go b/ui/pages/repo/files.go
2index d634bc9a1c9f4201a6284356c68d0c50fa5b67ee..edae23f1ff318e1ec2505d16edc809e035de38b7 100644
3--- a/ui/pages/repo/files.go
4+++ b/ui/pages/repo/files.go
5@@ -265,6 +265,8 @@ func (f *Files) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
6 }
7 }
8 }
9+ case selector.ActiveMsg:
10+ cmds = append(cmds, updateStatusBarCmd)
11 case EmptyRepoMsg:
12 f.ref = nil
13 f.path = ""
14@@ -307,7 +309,8 @@ func (f *Files) View() string {
15 func (f *Files) StatusBarValue() string {
16 p := f.path
17 if p == "." {
18- return ""
19+ // FIXME: this is a hack to force clear the status bar value
20+ return " "
21 }
22 return p
23 }