Files
MuyueWorkspace/internal/tui/styles.go
Augustin 035e923e6c refactor: redesign TUI with 4 tabs, red/rose theme, split layouts
- Dashboard: tools, agents status, updates, quick actions
- Studio: central chat + agents/workflows sidebar (Ctrl+S toggle)
- Shell: terminal + AI assistant panel side-by-side (Ctrl+A toggle)
- Config: profile, API keys, terminal/starship settings in 2 columns
- New red/rose color scheme (#E8364F → #FF6B8A → #FFB3C6)
- Animated header with visual tab bar and pulse loading
- Remove old chat.go, agents.go, workflow_tab.go (merged into studio.go)
- All tests pass, build clean

💘 Generated with Crush

Assisted-by: GLM-5.1 via Crush <crush@charm.land>
2026-04-20 21:03:49 +02:00

132 lines
3.1 KiB
Go

package tui
import (
"github.com/charmbracelet/lipgloss"
)
var (
primaryColor = lipgloss.Color("#E8364F")
roseColor = lipgloss.Color("#FF6B8A")
roseLightColor = lipgloss.Color("#FFB3C6")
accentColor = lipgloss.Color("#FF8FA3")
warmColor = lipgloss.Color("#FF4D6D")
successColor = lipgloss.Color("#4ADE80")
warningColor = lipgloss.Color("#FBBF24")
errorColor = lipgloss.Color("#FF4D4D")
mutedColor = lipgloss.Color("#8B7E8E")
dimColor = lipgloss.Color("#5A4F5E")
textColor = lipgloss.Color("#F0E6E8")
textDimColor = lipgloss.Color("#B8A9AD")
bgDark = lipgloss.Color("#0D0A0B")
bgPanel = lipgloss.Color("#1A1215")
bgCard = lipgloss.Color("#231A1D")
bgInput = lipgloss.Color("#2A2023")
bgHover = lipgloss.Color("#332528")
borderColor = lipgloss.Color("#3D2E32")
borderAccent = lipgloss.Color("#E8364F")
tabActiveBg = lipgloss.Color("#E8364F")
tabInactiveBg = lipgloss.Color("#1A1215")
sectionStyle = lipgloss.NewStyle().
Foreground(roseColor).
Bold(true)
sectionIconStyle = lipgloss.NewStyle().
Foreground(primaryColor).
Bold(true)
itemOKStyle = lipgloss.NewStyle().
Foreground(successColor)
itemMissingStyle = lipgloss.NewStyle().
Foreground(errorColor)
itemWarnStyle = lipgloss.NewStyle().
Foreground(warningColor)
itemPendingStyle = lipgloss.NewStyle().
Foreground(mutedColor)
userMsgStyle = lipgloss.NewStyle().
Foreground(roseLightColor)
aiMsgStyle = lipgloss.NewStyle().
Foreground(textColor)
errMsgStyle = lipgloss.NewStyle().
Foreground(errorColor)
inputStyle = lipgloss.NewStyle().
Foreground(roseColor)
stepDoneStyle = lipgloss.NewStyle().
Foreground(successColor)
stepPendingStyle = lipgloss.NewStyle().
Foreground(mutedColor)
stepCurrentStyle = lipgloss.NewStyle().
Foreground(primaryColor).
Bold(true)
stepErrorStyle = lipgloss.NewStyle().
Foreground(errorColor)
statusBarStyle = lipgloss.NewStyle().
Background(bgPanel).
Foreground(textDimColor).
Padding(0, 1)
confirmBoxStyle = lipgloss.NewStyle().
Border(lipgloss.RoundedBorder()).
BorderForeground(primaryColor).
Background(bgCard).
Foreground(textColor).
Padding(1, 3).
Bold(true)
confirmYesStyle = lipgloss.NewStyle().
Foreground(successColor).
Bold(true)
confirmNoStyle = lipgloss.NewStyle().
Foreground(mutedColor)
cardStyle = lipgloss.NewStyle().
Background(bgCard).
Border(lipgloss.RoundedBorder()).
BorderForeground(borderColor).
Padding(0, 1)
sidebarStyle = lipgloss.NewStyle().
Background(bgPanel).
Border(lipgloss.Border{Right: "│"}).
BorderForeground(borderColor).
Padding(0, 1)
badgeStyle = lipgloss.NewStyle().
Background(primaryColor).
Foreground(lipgloss.Color("#FFFFFF")).
Padding(0, 1).
Bold(true)
labelStyle = lipgloss.NewStyle().
Foreground(mutedColor).
Width(14)
valueStyle = lipgloss.NewStyle().
Foreground(textColor)
tabBarStyle = lipgloss.NewStyle().
Background(bgPanel)
pulseFrames = []string{"⣾", "⣽", "⣻", "⢿", "⡿", "⣟", "⣯", "⣷"}
)
func getAnimFrame(frame int) string {
return pulseFrames[frame%len(pulseFrames)]
}