From 26178f88944085382f6ed31294bfe9ad3d7f37d9 Mon Sep 17 00:00:00 2001 From: Mikael Fangel <34864484+MikaelFangel@users.noreply.github.com> Date: Sat, 25 May 2024 18:42:44 +0000 Subject: [PATCH] fix(input, write): re-enable cursor style (#592) * input: uncomment cursor theme * write: add theme to huh form --- input/command.go | 2 +- write/command.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/input/command.go b/input/command.go index c02f65c..58252dd 100644 --- a/input/command.go +++ b/input/command.go @@ -23,7 +23,7 @@ func (o Options) Run() error { theme := huh.ThemeCharm() theme.Focused.Base = lipgloss.NewStyle() - // theme.Focused.TextInput.Cursor = o.CursorStyle.ToLipgloss() + theme.Focused.TextInput.Cursor = o.CursorStyle.ToLipgloss() theme.Focused.TextInput.Placeholder = o.PlaceholderStyle.ToLipgloss() theme.Focused.TextInput.Prompt = o.PromptStyle.ToLipgloss() theme.Focused.Title = o.HeaderStyle.ToLipgloss() diff --git a/write/command.go b/write/command.go index 04a3a8a..54cdb85 100644 --- a/write/command.go +++ b/write/command.go @@ -37,6 +37,7 @@ func (o Options) Run() error { ). WithWidth(o.Width). WithHeight(o.Height). + WithTheme(theme). WithShowHelp(false).Run() if err != nil {