From 479fc541eb9cc35b8f5e84b4ce159d4a3c5728ec Mon Sep 17 00:00:00 2001 From: Kyren223 Date: Fri, 7 Feb 2025 17:39:39 +0200 Subject: UI, memberlist and banlist colors are now runtime-friendly --- internal/client/ui/ui.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'internal/client/ui/ui.go') diff --git a/internal/client/ui/ui.go b/internal/client/ui/ui.go index 08071d7..56f7b5e 100644 --- a/internal/client/ui/ui.go +++ b/internal/client/ui/ui.go @@ -29,14 +29,14 @@ var ( Height int Program *tea.Program - UserStyle = lipgloss.NewStyle().Foreground(colors.Purple).SetString("󰀉") - AdminStyle = lipgloss.NewStyle().Foreground(colors.Red).Bold(true).SetString("󰓏") - OwnerStyle = AdminStyle.Foreground(colors.Gold).SetString("󱟜") - TrustedUserStyle = UserStyle.Foreground(colors.Turquoise).SetString("󰢏") - TrustedMemberStyle = UserStyle.SetString("󰢏") - TrustedAdminStyle = AdminStyle.SetString("󱄻") - TrustedOwnerStyle = OwnerStyle.SetString("󱢼") - UntrustedSymbol = lipgloss.NewStyle().Foreground(colors.Red).Render("󱈸") + UserStyle = func() lipgloss.Style { return lipgloss.NewStyle().Foreground(colors.Purple).SetString("󰀉") } + AdminStyle = func() lipgloss.Style { return lipgloss.NewStyle().Foreground(colors.Red).Bold(true).SetString("󰓏") } + OwnerStyle = func() lipgloss.Style { return AdminStyle().Foreground(colors.Gold).SetString("󱟜") } + TrustedUserStyle = func() lipgloss.Style { return UserStyle().Foreground(colors.Turquoise).SetString("󰢏") } + TrustedMemberStyle = func() lipgloss.Style { return UserStyle().SetString("󰢏") } + TrustedAdminStyle = func() lipgloss.Style { return AdminStyle().SetString("󱄻") } + TrustedOwnerStyle = func() lipgloss.Style { return OwnerStyle().SetString("󱢼") } + UntrustedSymbol = func() string { return lipgloss.NewStyle().Foreground(colors.Red).Render("󱈸") } ) var NewAuth func() tea.Model -- cgit v1.3.1