a567b2ce73
Card-by-card walkthrough of entries untouched for 30+ days. Prevents write-mostly decay by bringing old entries back to attention. - S from list triggers stumble, loads entries where modified_at < 30d - Single-card view with markdown body, glyph, tags, age indicator - Actions: n skip, d dismiss, ! pin, p promote, m absorb, esc exit - Progress indicator: stumble [3/12] - After promote/absorb from stumble, returns to deck (not list) - "All caught up" screen when deck exhausted - DB: add ModifiedBefore to ListParams, modified_at sort column
150 lines
3.6 KiB
Go
150 lines
3.6 KiB
Go
package tui
|
||
|
||
import "github.com/charmbracelet/lipgloss"
|
||
|
||
var (
|
||
subtle = lipgloss.AdaptiveColor{Light: "#D9DCCF", Dark: "#383838"}
|
||
highlight = lipgloss.AdaptiveColor{Light: "#874BFD", Dark: "#7D56F4"}
|
||
dim = lipgloss.AdaptiveColor{Light: "#A49FA5", Dark: "#777777"}
|
||
|
||
titleStyle = lipgloss.NewStyle().
|
||
Bold(true).
|
||
Foreground(highlight).
|
||
PaddingLeft(1)
|
||
|
||
statusStyle = lipgloss.NewStyle().
|
||
Foreground(dim).
|
||
PaddingLeft(1)
|
||
|
||
listItemStyle = lipgloss.NewStyle().
|
||
PaddingLeft(2)
|
||
|
||
selectedItemStyle = lipgloss.NewStyle().
|
||
PaddingLeft(1).
|
||
Bold(true).
|
||
Foreground(highlight).
|
||
SetString("›")
|
||
|
||
glyphStyle = lipgloss.NewStyle().
|
||
Width(2)
|
||
|
||
completedGlyphStyle = lipgloss.NewStyle().
|
||
Width(2).
|
||
Foreground(dim)
|
||
|
||
tagStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#43BF6D", Dark: "#73F59F"})
|
||
|
||
idStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
inputPromptStyle = lipgloss.NewStyle().
|
||
Foreground(highlight).
|
||
Bold(true)
|
||
|
||
detailHeaderStyle = lipgloss.NewStyle().
|
||
Bold(true).
|
||
Foreground(highlight).
|
||
MarginBottom(1)
|
||
|
||
detailBodyStyle = lipgloss.NewStyle().
|
||
PaddingLeft(2).
|
||
PaddingTop(1)
|
||
|
||
helpStyle = lipgloss.NewStyle().
|
||
Foreground(dim).
|
||
PaddingLeft(1)
|
||
|
||
errorStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.Color("#FF0000")).
|
||
PaddingLeft(1)
|
||
|
||
dateHeaderStyle = lipgloss.NewStyle().
|
||
Foreground(dim).
|
||
PaddingLeft(1)
|
||
|
||
pinnedStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#D4A017", Dark: "#FFD700"})
|
||
|
||
filterPillStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#43BF6D", Dark: "#73F59F"}).
|
||
Bold(true)
|
||
|
||
helpKeyStyle = lipgloss.NewStyle().
|
||
Foreground(highlight).
|
||
Bold(true).
|
||
Width(18)
|
||
|
||
helpDescStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
affordanceStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#5B8EF0", Dark: "#7AAFFF"}).
|
||
Bold(true)
|
||
|
||
useCountStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#B07D3A", Dark: "#D4A54A"})
|
||
|
||
modeStyle = lipgloss.NewStyle().
|
||
Foreground(dim).
|
||
Bold(true)
|
||
|
||
detailLabelStyle = lipgloss.NewStyle().
|
||
Foreground(highlight).
|
||
Bold(true)
|
||
|
||
detailValueStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#555555", Dark: "#BBBBBB"})
|
||
|
||
checkDoneStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#43BF6D", Dark: "#73F59F"})
|
||
|
||
checkPendingStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
searchPillStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#E06C75", Dark: "#E06C75"}).
|
||
Bold(true)
|
||
|
||
gutterStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
drawerBorderStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
drawerHintsStyle = lipgloss.NewStyle().
|
||
Foreground(dim).
|
||
PaddingLeft(2)
|
||
|
||
drawerPreviewStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#555555", Dark: "#AAAAAA"}).
|
||
PaddingLeft(2)
|
||
|
||
separatorStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
hintKeyStyle = lipgloss.NewStyle().
|
||
Foreground(highlight).
|
||
Bold(true)
|
||
|
||
hintDescStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
railHeaderStyle = lipgloss.NewStyle().
|
||
Bold(true).
|
||
Foreground(dim)
|
||
|
||
railTagStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#43BF6D", Dark: "#73F59F"})
|
||
|
||
railActiveTagStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#43BF6D", Dark: "#73F59F"}).
|
||
Bold(true)
|
||
|
||
railCountStyle = lipgloss.NewStyle().
|
||
Foreground(dim)
|
||
|
||
stumbleAgeStyle = lipgloss.NewStyle().
|
||
Foreground(lipgloss.AdaptiveColor{Light: "#cc4400", Dark: "#fab387"})
|
||
)
|