Skip to content

Commit 4005691

Browse files
jorgerojas26Mariusz Kuchta
authored and
Mariusz Kuchta
committed
Merge pull request jorgerojas26#127 from svanharmelen/feat/confirmation
Make the active button stand out in more terminal themes
2 parents c78cb87 + 94a49e9 commit 4005691

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Diff for: components/ConfirmationModal.go

+5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package components
22

33
import (
4+
"github.com/gdamore/tcell/v2"
45
"github.com/rivo/tview"
56

67
"github.com/jorgerojas26/lazysql/app"
@@ -19,6 +20,10 @@ func NewConfirmationModal(confirmationText string) *ConfirmationModal {
1920
}
2021
modal.AddButtons([]string{"Yes", "No"})
2122
modal.SetBackgroundColor(app.Styles.PrimitiveBackgroundColor)
23+
modal.SetButtonActivatedStyle(tcell.StyleDefault.
24+
Background(app.Styles.InverseTextColor).
25+
Foreground(app.Styles.ContrastSecondaryTextColor),
26+
)
2227
modal.SetTextColor(app.Styles.PrimaryTextColor)
2328

2429
return &ConfirmationModal{

0 commit comments

Comments
 (0)