diff options
| author | Paul Bütow <1224732+snonux@users.noreply.github.com> | 2025-06-20 00:23:48 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-20 00:23:48 +0300 |
| commit | 603024c59e04019cb867c43d8e8298b2d459de3d (patch) | |
| tree | cf37cacd7af2d3c837d1bd9cffeef962450c93a8 /cmd | |
| parent | 77620dcd609aa53a81effd23174d56e622f16cc8 (diff) | |
| parent | 17ae0b210c109e625f8afb54b08de2c25f272c96 (diff) | |
Merge pull request #9 from snonux/codex/add-helper-functions-for-task-manipulation
Implement task helpers and refine due date style
Diffstat (limited to 'cmd')
| -rw-r--r-- | cmd/tasksamurai/main.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/cmd/tasksamurai/main.go b/cmd/tasksamurai/main.go index 658cb05..56ee08a 100644 --- a/cmd/tasksamurai/main.go +++ b/cmd/tasksamurai/main.go @@ -85,8 +85,9 @@ func formatDue(s string) string { days := int(time.Until(ts).Hours() / 24) val := fmt.Sprintf("%dd", days) + style := lipgloss.NewStyle() if days < 0 { - val = lipgloss.NewStyle().Background(lipgloss.Color("1")).Render(val) + style = style.Background(lipgloss.Color("1")) } - return val + return style.Render(val) } |
