package steps import ( "miasma-installer/tui/styles" tea "github.com/charmbracelet/bubbletea" ) type WelcomeModel struct { Finished bool } func NewWelcomeModel() WelcomeModel { return WelcomeModel{Finished: false} } func (m WelcomeModel) Init() tea.Cmd { return nil } func (m WelcomeModel) Update(msg tea.Msg) (tea.Model, tea.Cmd) { if m.Finished { return m, nil } switch msg := msg.(type) { case tea.KeyMsg: switch msg.String() { case "enter": m.Finished = true } } return m, nil } func (m WelcomeModel) View() string { s := styles.TitleStyle.Render("Welcome to the Miasma OS Installer") s += "\n\n" s += "This program will guide you through installing Miasma OS. \n" s += "Please ensure that you have backed up any important data before proceding" s += "\n\n" s += styles.HelpStyle.Render("Press [Enter] to continue") s += styles.HelpStyle.Render("Press [Ctrl+C] to exit") return styles.MainStyle.Render(s) }