summaryrefslogtreecommitdiff
path: root/internal/picker/defaults.go
diff options
context:
space:
mode:
authorBenjamin Chausse <benjamin@chausse.xyz>2024-12-27 17:54:43 -0500
committerBenjamin Chausse <benjamin@chausse.xyz>2024-12-27 17:54:43 -0500
commit3b8fa0766a0050c0dd026be5d6a1ce2827956530 (patch)
treee6e6e0d05da592fe36aade35201a52898209ceb1 /internal/picker/defaults.go
parent858c07f0b805558b0961514200ffb822dd2248cf (diff)
All ui info in one location
Diffstat (limited to 'internal/picker/defaults.go')
-rw-r--r--internal/picker/defaults.go37
1 files changed, 20 insertions, 17 deletions
diff --git a/internal/picker/defaults.go b/internal/picker/defaults.go
index a7a0d89..5500465 100644
--- a/internal/picker/defaults.go
+++ b/internal/picker/defaults.go
@@ -1,31 +1,34 @@
package picker
import (
- "github.com/ChausseBenjamin/termpicker/internal/progress"
"github.com/ChausseBenjamin/termpicker/internal/slider"
+ "github.com/ChausseBenjamin/termpicker/internal/ui"
)
func RGB() *Model {
- r := slider.New('R', 255, progress.WithGradient("#660000", "#ff0000"))
- g := slider.New('G', 255, progress.WithGradient("#006600", "#00ff00"))
- b := slider.New('B', 255, progress.WithGradient("#000066", "#0000ff"))
- rgb := New([]slider.Model{r, g, b}, "RGB")
- return rgb
+ return New(
+ []slider.Model{
+ slider.New('R', 255, ui.Style().Sliders.R...),
+ slider.New('G', 255, ui.Style().Sliders.G...),
+ slider.New('B', 255, ui.Style().Sliders.B...),
+ }, "RGB")
}
func CMYK() *Model {
- c := slider.New('C', 100, progress.WithGradient("#006666", "#00ffff"))
- m := slider.New('M', 100, progress.WithGradient("#660066", "#ff00ff"))
- y := slider.New('Y', 100, progress.WithGradient("#666600", "#ffff00"))
- k := slider.New('K', 100, progress.WithSolidFill("#000000"))
- cmyk := New([]slider.Model{c, m, y, k}, "CMYK")
- return cmyk
+ return New(
+ []slider.Model{
+ slider.New('C', 100, ui.Style().Sliders.C...),
+ slider.New('M', 100, ui.Style().Sliders.M...),
+ slider.New('Y', 100, ui.Style().Sliders.Y...),
+ slider.New('K', 100, ui.Style().Sliders.K...),
+ }, "CMYK")
}
func HSL() *Model {
- h := slider.New('H', 360, progress.WithDefaultGradient())
- s := slider.New('S', 100, progress.WithGradient("#a68e59", "#ffae00"))
- l := slider.New('L', 100, progress.WithGradient("#222222", "#ffffff"))
- hsl := New([]slider.Model{h, s, l}, "HSL")
- return hsl
+ return New(
+ []slider.Model{
+ slider.New('H', 360, ui.Style().Sliders.H...),
+ slider.New('S', 100, ui.Style().Sliders.S...),
+ slider.New('L', 100, ui.Style().Sliders.L...),
+ }, "HSL")
}