fix: stubs shell y tui usan tipos nativos en firmas en vez de Result/Option de core
Result[T] y Option[T] de core no son accesibles desde otros paquetes sin import. Cambiado a (T, error) y (T, bool) siguiendo la regla de tipos nativos en firmas. Añadidas dependencias bubbletea/bubbles/lipgloss al go.mod raíz para que tui compile. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
package tui
|
||||
|
||||
// Implementation: github.com/lucasdataproyects/devfactory/tui
|
||||
import "fmt"
|
||||
|
||||
// Confirm muestra un dialogo de confirmacion Si/No en terminal y devuelve la eleccion del usuario.
|
||||
func Confirm(prompt string) Result[bool] {
|
||||
// Confirm muestra un prompt de confirmacion si/no en la terminal.
|
||||
func Confirm(prompt string) (bool, error) {
|
||||
// stub — implementation in devfactory/tui
|
||||
return Result[bool]{Value: false}
|
||||
return false, fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
package tui
|
||||
|
||||
// Implementation: github.com/lucasdataproyects/devfactory/tui
|
||||
import tea "github.com/charmbracelet/bubbletea"
|
||||
|
||||
import "github.com/charmbracelet/bubbletea"
|
||||
|
||||
// RunFullscreen ejecuta un modelo Bubble Tea en modo fullscreen.
|
||||
func RunFullscreen[T tea.Model](model T) Result[T] {
|
||||
// RunFullscreen ejecuta un modelo Bubbletea en modo fullscreen.
|
||||
func RunFullscreen[T tea.Model](model T) (T, error) {
|
||||
// stub — implementation in devfactory/tui
|
||||
var zero T
|
||||
return Result[T]{Value: zero}
|
||||
return zero, nil
|
||||
}
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
package tui
|
||||
|
||||
// Implementation: github.com/lucasdataproyects/devfactory/tui
|
||||
import tea "github.com/charmbracelet/bubbletea"
|
||||
|
||||
import "github.com/charmbracelet/bubbletea"
|
||||
|
||||
// RunModel ejecuta un modelo Bubble Tea y devuelve el modelo final o error.
|
||||
func RunModel[T tea.Model](model T) Result[T] {
|
||||
// RunModel ejecuta un modelo Bubbletea y devuelve el modelo final.
|
||||
func RunModel[T tea.Model](model T) (T, error) {
|
||||
// stub — implementation in devfactory/tui
|
||||
var zero T
|
||||
return Result[T]{Value: zero}
|
||||
return zero, nil
|
||||
}
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
package tui
|
||||
|
||||
// Implementation: github.com/lucasdataproyects/devfactory/tui
|
||||
import tea "github.com/charmbracelet/bubbletea"
|
||||
|
||||
import "github.com/charmbracelet/bubbletea"
|
||||
|
||||
// RunWithMouseSupport ejecuta un modelo Bubble Tea con soporte de raton habilitado.
|
||||
func RunWithMouseSupport[T tea.Model](model T) Result[T] {
|
||||
// RunWithMouseSupport ejecuta un modelo Bubbletea con soporte de mouse.
|
||||
func RunWithMouseSupport[T tea.Model](model T) (T, error) {
|
||||
// stub — implementation in devfactory/tui
|
||||
var zero T
|
||||
return Result[T]{Value: zero}
|
||||
return zero, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user