-
Notifications
You must be signed in to change notification settings - Fork 33
/
data.go
30 lines (27 loc) · 945 Bytes
/
data.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
package main
import "github.com/charmbracelet/bubbles/list"
// Provides the mock data to fill the kanban board
func (b *Board) initLists() {
b.cols = []column{
newColumn(todo),
newColumn(inProgress),
newColumn(done),
}
// Init To Do
b.cols[todo].list.Title = "To Do"
b.cols[todo].list.SetItems([]list.Item{
Task{status: todo, title: "buy milk", description: "strawberry milk"},
Task{status: todo, title: "eat sushi", description: "negitoro roll, miso soup, rice"},
Task{status: todo, title: "fold laundry", description: "or wear wrinkly t-shirts"},
})
// Init in progress
b.cols[inProgress].list.Title = "In Progress"
b.cols[inProgress].list.SetItems([]list.Item{
Task{status: inProgress, title: "write code", description: "don't worry, it's Go"},
})
// Init done
b.cols[done].list.Title = "Done"
b.cols[done].list.SetItems([]list.Item{
Task{status: done, title: "stay cool", description: "as a cucumber"},
})
}