Skip to content

Commit 9f85110

Browse files
feat: implement onboarding system, add tag filter state management, and update version to 1.5.7
- closes #43 - closes #48 - closes #49
1 parent 4c1aed3 commit 9f85110

8 files changed

Lines changed: 33 additions & 38 deletions

File tree

CHANGELOG.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2626
- Added `[projects] default = "project_name"` config to set startup project.
2727
- Added `<All Projects>` view to see tasks across all contexts.
2828
- Projects are now visible in the header and can be optionally displayed in the list view.
29-
- Added per-tag color highlighting via `[tags.highlight]` in config.toml with `ui-*` theme alias support.
30-
- Added `edit.preview` config option to persist the preview panel's default state.
29+
- Added per-tag color highlighting via `[tags.highlight]` in config.toml with theme-aware alias support. - Added `edit.preview` config option to persist the preview panel's default state.
3130
- Added task duplication with `D` shortcut; automatically opens edit mode on the duplicate.
3231
- Added Multi-Selection support:
3332
- Toggle task selection with `Space`.
@@ -144,7 +143,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
144143

145144
### Added
146145

147-
- **Interactive Onboarding**: A complete, keyboard-driven welcome tour for new users with a "smooth af" animated slanted logo that cycles through theme colors. Teaches core navigation, task creation, and completion in under 60 seconds.
146+
* **Interactive Onboarding**: A complete, keyboard-driven welcome tour for new users with a "smooth af" animated slanted logo that cycles through theme colors. Teaches core navigation, task creation, completion, and now includes **Undo/Redo (ctrl+z/y)**.
148147
- **Onboarding Trigger**: Added `ctrl+d` as a global shortcut to relaunch the welcome tour at any time.
149148
- **Auto-Onboarding**: Kairo now automatically launches the welcome tour on new installations to ensure a smooth first-time experience.
150149
- **AI Assistant Polish**: The AI Assistant shortcut (`ctrl+a`), footer pill, and help menu entry are now fully disabled and hidden if no Gemini API key is configured, providing a cleaner interface for new users.

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,13 +101,13 @@ A Lua plugin system hooks into task events. A headless CLI API enables full scri
101101
Kairo now tracks your every move with a local history engine. Instantly reverse mistakes with `ctrl+z` or re-apply undone actions with `ctrl+y`. Supports task creation, deletion (including bulk), editing, and status changes. Everything is synchronized live with the database.
102102

103103
### 🎨 Tag Highlighting
104-
Color-code your tags directly in `config.toml`. Supports hex codes or theme-aware `ui-*` aliases (e.g., `ui-accent`).
104+
Color-code your tags directly in `config.toml`. Supports hex codes or theme-aware aliases (e.g., `accent`).
105105

106106
```toml
107107
[tags.highlight]
108108
work = { fg = "#CCCCCC" }
109109
private = "fg=#EEEEEE,bg=#0000FF,bold"
110-
diy = "bg=ui-accent"
110+
diy = "bg=accent"
111111
```
112112

113113
---
@@ -143,6 +143,7 @@ diy = "bg=ui-accent"
143143
<img src="screenshots/settings_menu.png" width="30%" />
144144
<img src="screenshots/theme_menu.png" width="30%" />
145145
<img src="screenshots/dashboard.png" width="30%" />
146+
<img src="screenshots/welcome_tour.png" width="30%" />
146147
</div>
147148

148149
---

VERSION.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.5.6
1+
1.5.7

internal/app/model.go

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1003,6 +1003,21 @@ func (m *Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
10031003
}
10041004
m.mode = ModeList
10051005
return m, m.deleteTasksCmd(ids)
1006+
case "t":
1007+
visible := m.list.GetVisibleTasks()
1008+
var ids []string
1009+
for _, item := range visible {
1010+
ids = append(ids, item.ID)
1011+
}
1012+
m.mode = ModeList
1013+
var animCmd tea.Cmd
1014+
if m.cfg.App.Animations {
1015+
m.transitioning = m.cfg.App.Animations
1016+
m.transitionStarted = time.Now()
1017+
m.animationGen++
1018+
animCmd = m.viewTransitionTickCmd()
1019+
}
1020+
return m, tea.Batch(m.deleteTasksCmd(ids), animCmd)
10061021
case "a":
10071022
m.mode = ModeList
10081023
var animCmd tea.Cmd
@@ -2035,7 +2050,7 @@ func (m *Model) renderFooter() string {
20352050
delLeft := m.s.TagLeft.Foreground(m.s.Theme.Bad).Render()
20362051
delRight := m.s.TagRight.Foreground(m.s.Theme.Bad).Render()
20372052
delPill := delLeft + m.s.BadgeDelete.Render("DELETE?") + delRight
2038-
left = " " + delPill + " " + makePill("y/enter confirm") + sep + makePill("a delete all") + sep + makePill("n/esc cancel")
2053+
left = " " + delPill + " " + makePill("y/enter confirm") + sep + makePill("t delete tab") + sep + makePill("a delete all") + sep + makePill("n/esc cancel")
20392054
case ModeConfirmQuit:
20402055
quitLeft := m.s.TagLeft.Foreground(m.s.Theme.Warn).Render()
20412056
quitRight := m.s.TagRight.Foreground(m.s.Theme.Warn).Render()

internal/lua/engine.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ func (e *Engine) SetupKairoAPI(L *lua.LState) {
6161
L.SetField(kairo, "notify", L.NewFunction(e.luaNotify))
6262

6363
// Meta
64-
L.SetField(kairo, "version", lua.LString("1.5.6"))
64+
L.SetField(kairo, "version", lua.LString("1.5.7"))
6565

6666
// Set as global
6767
L.SetGlobal("kairo", kairo)

internal/ui/onboarding/model.go

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ const (
2222
StepAI
2323
StepRecurring
2424
StepAdvanced
25+
StepUndoRedo
2526
StepFinish
2627
)
2728

@@ -118,6 +119,10 @@ func (m Model) Update(msg tea.Msg) (Model, tea.Cmd) {
118119
}
119120
case StepAdvanced:
120121
if x.String() == "ctrl+s" {
122+
m.step = StepUndoRedo
123+
}
124+
case StepUndoRedo:
125+
if x.Type == tea.KeyCtrlZ || strings.EqualFold(x.String(), "ctrl+z") {
121126
m.step = StepFinish
122127
}
123128
case StepFinish:
@@ -183,6 +188,10 @@ func (m Model) View() string {
183188
title = "ADVANCED CONFIG"
184189
body = "Fine-tune Kairo's behavior, themes, and keybindings in the Settings menu."
185190
action = "Press [CTRL+S] for Settings"
191+
case StepUndoRedo:
192+
title = "UNDO & REDO"
193+
body = "Made a mistake? Instantly reverse any action with Undo [CTRL+Z] or re-apply with Redo [CTRL+Y]."
194+
action = "Press [CTRL+Z] to continue"
186195
case StepFinish:
187196
title = "YOU'RE ALL SET"
188197
body = "You're now proficient with Kairo! Explore more via the palette [CTRL+P].\n\n(Tip: Relaunch tour anytime with [CTRL+W])"
@@ -218,7 +227,7 @@ func (m Model) View() string {
218227
}
219228

220229
func (m Model) renderProgress() string {
221-
steps := 9
230+
steps := 10
222231
var b strings.Builder
223232
for i := 0; i < steps; i++ {
224233
if i == int(m.step) {

internal/ui/theme/theme.go

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -18,35 +18,6 @@ type Theme struct {
1818
Overlay lipgloss.Color
1919
}
2020

21-
func (t Theme) GetColor(alias string) (lipgloss.Color, bool) {
22-
switch alias {
23-
case "ui-red":
24-
return t.Bad, true
25-
case "ui-green":
26-
return t.Good, true
27-
case "ui-yellow":
28-
return t.Warn, true
29-
case "ui-blue":
30-
return t.Accent, true
31-
case "ui-magenta":
32-
return t.Bad, true // Fallback
33-
case "ui-cyan":
34-
return t.Accent, true // Fallback
35-
case "ui-warn":
36-
return t.Warn, true
37-
case "ui-info":
38-
return t.Accent, true
39-
case "ui-error":
40-
return t.Bad, true
41-
case "ui-accent":
42-
return t.Accent, true
43-
case "ui-muted":
44-
return t.Muted, true
45-
default:
46-
return "", false
47-
}
48-
}
49-
5021
// --- DARK THEMES ---
5122

5223
var Catppuccin = Theme{

screenshots/welcome_tour.png

27.6 KB
Loading

0 commit comments

Comments
 (0)