feat: better onboarding

This commit is contained in:
leonardotrapani
2026-01-31 22:55:10 +01:00
parent f251df302d
commit 27eb9076de
7 changed files with 71 additions and 334 deletions
+6 -2
View File
@@ -36,13 +36,17 @@ func getConfiguredProviders(cfg *config.Config) []string {
}
// editProviders handles the providers section edit with submenu
func editProviders(cfg *config.Config) error {
func editProviders(cfg *config.Config, onboarding bool) error {
exitLabel := "Done"
if onboarding {
exitLabel = "Next"
}
for {
var options []huh.Option[string]
for _, name := range AllProviders {
options = append(options, huh.NewOption(formatProviderOption(cfg, name), name))
}
options = append(options, huh.NewOption("Back", "back"))
options = append(options, huh.NewOption(exitLabel, "back"))
var selected string
form := huh.NewForm(