refactor(ui): bump tview and adapt to tview.Screen API
This commit is contained in:
parent
24ced4d8bf
commit
c38fc3d9c0
4 changed files with 4 additions and 8 deletions
2
go.mod
2
go.mod
|
|
@ -15,7 +15,7 @@ require (
|
|||
github.com/andybalholm/brotli v1.2.3
|
||||
github.com/ayn2op/arikawa/v3 v3.0.0-20260904042054-7df757872273
|
||||
github.com/ayn2op/ningen/v3 v3.0.1-0.20260904045623-5978c9be899f
|
||||
github.com/ayn2op/tview v0.0.0-20260905034126-cc87af9b5ca0
|
||||
github.com/ayn2op/tview v0.0.0-20260909221424-dbf33e91537d
|
||||
github.com/bogdanfinn/fhttp v0.6.9
|
||||
github.com/bogdanfinn/tls-client v1.16.0
|
||||
github.com/gdamore/tcell/v3 v3.4.2
|
||||
|
|
|
|||
4
go.sum
4
go.sum
|
|
@ -14,8 +14,8 @@ github.com/ayn2op/arikawa/v3 v3.0.0-20260904042054-7df757872273 h1:cJ1donaon2Cjh
|
|||
github.com/ayn2op/arikawa/v3 v3.0.0-20260904042054-7df757872273/go.mod h1:bzMgZqBnJr1pu7EHq2d9906sAtHA+iklIxxvnS5kfDo=
|
||||
github.com/ayn2op/ningen/v3 v3.0.1-0.20260904045623-5978c9be899f h1:RrbCgoBOmYsLJAaf4lES+eoJYOG7zQMykACIFZgEvdU=
|
||||
github.com/ayn2op/ningen/v3 v3.0.1-0.20260904045623-5978c9be899f/go.mod h1:j8CBNjCkOpsgQm6X2xYJ0kXu5Y/PiQ+6QxxmExCq1Fs=
|
||||
github.com/ayn2op/tview v0.0.0-20260905034126-cc87af9b5ca0 h1:ctaWqFaNHrRJoORGunb/+6RpU34695xYpRXVoMd5qHM=
|
||||
github.com/ayn2op/tview v0.0.0-20260905034126-cc87af9b5ca0/go.mod h1:iFzkW7DBltCaeLMR9SvXVUAw/zgKIbgE8JaUU8W8crk=
|
||||
github.com/ayn2op/tview v0.0.0-20260909221424-dbf33e91537d h1:w4PI1//W9Af8wQalOf53VNU6ga86WqxXIcWvpyiUcKw=
|
||||
github.com/ayn2op/tview v0.0.0-20260909221424-dbf33e91537d/go.mod h1:iFzkW7DBltCaeLMR9SvXVUAw/zgKIbgE8JaUU8W8crk=
|
||||
github.com/bdandy/go-errors v1.2.2 h1:WdFv/oukjTJCLa79UfkGmwX7ZxONAihKu4V0mLIs11Q=
|
||||
github.com/bdandy/go-errors v1.2.2/go.mod h1:NkYHl4Fey9oRRdbB1CoC6e84tuqQHiqrOcZpqFEkBxM=
|
||||
github.com/bdandy/go-socks4 v1.2.3 h1:Q6Y2heY1GRjCtHbmlKfnwrKVU/k81LS8mRGLRlmDlic=
|
||||
|
|
|
|||
|
|
@ -406,7 +406,7 @@ func (m *Model) setFocus(target tview.Model) {
|
|||
}
|
||||
}
|
||||
|
||||
func (m *Model) View(screen tcell.Screen) {
|
||||
func (m *Model) View(screen tview.Screen) {
|
||||
ui.BlurBox(m.guildsTree.Box, &m.cfg.Theme)
|
||||
ui.BlurBox(m.messagesList.Box, &m.cfg.Theme)
|
||||
ui.BlurBox(m.composer.Box, &m.cfg.Theme)
|
||||
|
|
|
|||
|
|
@ -163,10 +163,6 @@ func (m *Model) render() {
|
|||
m.TextView.SetRect(m.Rect())
|
||||
}
|
||||
|
||||
func (m *Model) View(screen tcell.Screen) {
|
||||
m.TextView.View(screen)
|
||||
}
|
||||
|
||||
func (m *Model) centerText(content text.Text) text.Text {
|
||||
_, _, _, height := m.InnerRect()
|
||||
if height == 0 {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue