summaryrefslogtreecommitdiff
path: root/menu
diff options
context:
space:
mode:
authorewy <ewy0@protonmail.com>2026-05-02 19:31:48 +0200
committerewy <ewy0@protonmail.com>2026-05-02 19:31:48 +0200
commitb84ea05c63294cd2c3c5a9329c55e5ed5617d2f7 (patch)
treee1342e478a7298e51c6aecf63a492602bcccedf0 /menu
parent45847dc53ec51c090175d8621711250b60b28263 (diff)
be more cool about weird icons
Diffstat (limited to 'menu')
-rw-r--r--menu/icon.go3
-rw-r--r--menu/source.go5
2 files changed, 4 insertions, 4 deletions
diff --git a/menu/icon.go b/menu/icon.go
index 2043731..102706e 100644
--- a/menu/icon.go
+++ b/menu/icon.go
@@ -14,9 +14,6 @@ var (
)
func Icon(input string) string {
- if strings.TrimSpace(input) == "" {
- return ""
- }
return IconStyle.Render(input)
}
diff --git a/menu/source.go b/menu/source.go
index 9e0f56a..2d02a5d 100644
--- a/menu/source.go
+++ b/menu/source.go
@@ -32,6 +32,9 @@ var (
st := lipgloss.NewStyle().Faint(true)
return st
})
+ SourceIconStyle = style.New(func() lipgloss.Style {
+ return lipgloss.NewStyle().Width(3)
+ })
)
func (m *Model) Source(src *model.HydratedSource) string {
@@ -52,7 +55,7 @@ func (m *Model) Source(src *model.HydratedSource) string {
targetContent := lipgloss.JoinVertical(lipgloss.Top, targets...)
- icon := PaddedIcon(src.Icon)
+ icon := SourceIconStyle.Render(PaddedIcon(src.Icon))
parts := []string{
SourceHeaderStyle.Render(lipgloss.JoinHorizontal(lipgloss.Left, SourceLabelStyle.Render(lipgloss.JoinHorizontal(lipgloss.Left, icon, src.Label()), SourcePathStyle.Render(src.ShortPath())))),