refactor: remove intermediate var

This commit is contained in:
ayn2op 2025-06-18 16:22:47 -04:00
parent 3260c07438
commit 0243039600
2 changed files with 1 additions and 4 deletions

View file

@ -49,7 +49,6 @@ func newMessageInput(cfg *config.Config) *messageInput {
}
mi.Box = ui.NewConfiguredBox(mi.Box, &cfg.Theme)
mi.
SetTextStyle(tcell.StyleDefault.Background(tcell.GetColor(cfg.Theme.BackgroundColor))).
SetClipboard(func(s string) {

View file

@ -49,8 +49,6 @@ func newMessagesText(cfg *config.Config) *messagesText {
}
mt.Box = ui.NewConfiguredBox(mt.Box, &cfg.Theme)
t := cfg.Theme
mt.
SetDynamicColors(true).
SetRegions(true).
@ -60,7 +58,7 @@ func newMessagesText(cfg *config.Config) *messagesText {
SetTitle("Messages").
SetInputCapture(mt.onInputCapture)
markdown.DefaultRenderer.AddOptions(renderer.WithOption("theme", t.MessagesText))
markdown.DefaultRenderer.AddOptions(renderer.WithOption("theme", cfg.Theme.MessagesText))
return mt
}