Use native bubble table

This commit is contained in:
Martin Pander
2026-02-26 20:03:48 +01:00
parent 418bcd96a8
commit 9eda92503e
6 changed files with 826 additions and 7 deletions

View File

@@ -24,10 +24,10 @@ func NewMainPage(common *common.Common) *MainPage {
common: common,
}
// m.taskPage = NewReportPage(common, common.TW.GetReport(common.TW.GetConfig().Get("uda.tasksquire.report.default")))
m.taskPage = NewTaskPage(common, common.TW.GetReport(common.TW.GetConfig().Get("uda.tasksquire.report.default")))
// m.timePage = NewTimePage(common)
//
// m.activePage = m.taskPage
m.activePage = m.taskPage
m.currentTab = 0
return m
@@ -82,9 +82,9 @@ func (m *MainPage) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
// }
// }
//
// activePage, cmd := m.activePage.Update(msg)
// m.activePage = activePage.(common.Component)
//
activePage, cmd := m.activePage.Update(msg)
m.activePage = activePage.(common.Component)
return m, cmd
}
@@ -105,7 +105,7 @@ func (m *MainPage) renderTabBar() string {
}
func (m *MainPage) View() tea.View {
v := tea.NewView("test")
v := tea.NewView(lipgloss.JoinVertical(lipgloss.Left, m.renderTabBar(), m.activePage.View().Content))
v.AltScreen = true
return v
// return lipgloss.JoinVertical(lipgloss.Left, m.renderTabBar(), m.activePage.View())