70 lines
990 B
Go
70 lines
990 B
Go
package pages
|
|
|
|
import tea "github.com/charmbracelet/bubbletea"
|
|
|
|
type UpdatedTasksMsg struct{}
|
|
|
|
type nextColumnMsg struct{}
|
|
|
|
func nextColumn() tea.Cmd {
|
|
return func() tea.Msg {
|
|
return nextColumnMsg{}
|
|
}
|
|
}
|
|
|
|
type prevColumnMsg struct{}
|
|
|
|
func prevColumn() tea.Cmd {
|
|
return func() tea.Msg {
|
|
return prevColumnMsg{}
|
|
}
|
|
}
|
|
|
|
type nextFieldMsg struct{}
|
|
|
|
func nextField() tea.Cmd {
|
|
return func() tea.Msg {
|
|
return nextFieldMsg{}
|
|
}
|
|
}
|
|
|
|
type prevFieldMsg struct{}
|
|
|
|
func prevField() tea.Cmd {
|
|
return func() tea.Msg {
|
|
return prevFieldMsg{}
|
|
}
|
|
}
|
|
|
|
type nextAreaMsg struct{}
|
|
|
|
func nextArea() tea.Cmd {
|
|
return func() tea.Msg {
|
|
return nextAreaMsg{}
|
|
}
|
|
}
|
|
|
|
type prevAreaMsg struct{}
|
|
|
|
func prevArea() tea.Cmd {
|
|
return func() tea.Msg {
|
|
return prevAreaMsg{}
|
|
}
|
|
}
|
|
|
|
type changeAreaMsg int
|
|
|
|
func changeArea(a int) tea.Cmd {
|
|
return func() tea.Msg {
|
|
return changeAreaMsg(a)
|
|
}
|
|
}
|
|
|
|
func changeMode(mode mode) tea.Cmd {
|
|
return func() tea.Msg {
|
|
return changeModeMsg(mode)
|
|
}
|
|
}
|
|
|
|
type changeModeMsg mode
|