refactor(ui): standardize on lipgloss semantic color system
Replace all fatih/color usages with internal/ui package that provides: - Semantic color tokens (Pass, Warn, Fail, Accent, Muted) - Adaptive light/dark mode support via Lipgloss AdaptiveColor - Ayu theme colors for consistent, accessible output - Tufte-inspired data-ink ratio principles Files migrated: 35 command files in cmd/bd/ Add docs/ui-philosophy.md documenting: - Semantic token usage guidelines - Light/dark terminal optimization rationale - Tufte and perceptual UI/UX theory application - When to use (and not use) color in CLI output
This commit is contained in:
@@ -10,9 +10,9 @@ import (
|
||||
"regexp"
|
||||
"strings"
|
||||
|
||||
"github.com/fatih/color"
|
||||
"github.com/spf13/cobra"
|
||||
"github.com/steveyegge/beads/internal/types"
|
||||
"github.com/steveyegge/beads/internal/ui"
|
||||
"github.com/steveyegge/beads/internal/validation"
|
||||
)
|
||||
|
||||
@@ -397,8 +397,7 @@ func createIssuesFromMarkdown(_ *cobra.Command, filepath string) {
|
||||
|
||||
// Report failures if any
|
||||
if len(failedIssues) > 0 {
|
||||
red := color.New(color.FgRed).SprintFunc()
|
||||
fmt.Fprintf(os.Stderr, "\n%s Failed to create %d issues:\n", red("✗"), len(failedIssues))
|
||||
fmt.Fprintf(os.Stderr, "\n%s Failed to create %d issues:\n", ui.RenderFail("✗"), len(failedIssues))
|
||||
for _, title := range failedIssues {
|
||||
fmt.Fprintf(os.Stderr, " - %s\n", title)
|
||||
}
|
||||
@@ -407,8 +406,7 @@ func createIssuesFromMarkdown(_ *cobra.Command, filepath string) {
|
||||
if jsonOutput {
|
||||
outputJSON(createdIssues)
|
||||
} else {
|
||||
green := color.New(color.FgGreen).SprintFunc()
|
||||
fmt.Printf("%s Created %d issues from %s:\n", green("✓"), len(createdIssues), filepath)
|
||||
fmt.Printf("%s Created %d issues from %s:\n", ui.RenderPass("✓"), len(createdIssues), filepath)
|
||||
for _, issue := range createdIssues {
|
||||
fmt.Printf(" %s: %s [P%d, %s]\n", issue.ID, issue.Title, issue.Priority, issue.IssueType)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user