summaryrefslogtreecommitdiffhomepage
path: root/internal/tui
diff options
context:
space:
mode:
authoradamdottv <[email protected]>2025-05-15 15:45:22 -0500
committeradamdottv <[email protected]>2025-05-15 15:45:22 -0500
commit3944930fc04a57c3da9c80d9d7377effd1277004 (patch)
tree96fd8401e637fa89794abbef55796af5347ec661 /internal/tui
parent825c0b64af785e1bac6fa7ecb288725011b18768 (diff)
downloadopencode-3944930fc04a57c3da9c80d9d7377effd1277004.tar.gz
opencode-3944930fc04a57c3da9c80d9d7377effd1277004.zip
chore: cleanup
Diffstat (limited to 'internal/tui')
-rw-r--r--internal/tui/components/chat/editor.go1
-rw-r--r--internal/tui/components/chat/messages.go (renamed from internal/tui/components/chat/list.go)0
-rw-r--r--internal/tui/layout/container.go11
3 files changed, 4 insertions, 8 deletions
diff --git a/internal/tui/components/chat/editor.go b/internal/tui/components/chat/editor.go
index 0b2c9abb8..4d5ba0128 100644
--- a/internal/tui/components/chat/editor.go
+++ b/internal/tui/components/chat/editor.go
@@ -243,7 +243,6 @@ func (m *editorCmp) SetSize(width, height int) tea.Cmd {
m.height = height
m.textarea.SetWidth(width - 3) // account for the prompt and padding right
m.textarea.SetHeight(height)
- m.textarea.SetWidth(width)
return nil
}
diff --git a/internal/tui/components/chat/list.go b/internal/tui/components/chat/messages.go
index baa7c7e6d..baa7c7e6d 100644
--- a/internal/tui/components/chat/list.go
+++ b/internal/tui/components/chat/messages.go
diff --git a/internal/tui/layout/container.go b/internal/tui/layout/container.go
index 08b10fdd6..b5bdca20a 100644
--- a/internal/tui/layout/container.go
+++ b/internal/tui/layout/container.go
@@ -11,16 +11,16 @@ type Container interface {
tea.Model
Sizeable
Bindings
- Focus() // Add focus method
- Blur() // Add blur method
+ Focus()
+ Blur()
}
+
type container struct {
width int
height int
content tea.Model
- // Style options
paddingTop int
paddingRight int
paddingBottom int
@@ -32,7 +32,7 @@ type container struct {
borderLeft bool
borderStyle lipgloss.Border
- focused bool // Track focus state
+ focused bool
}
func (c *container) Init() tea.Cmd {
@@ -152,16 +152,13 @@ func (c *container) Blur() {
type ContainerOption func(*container)
func NewContainer(content tea.Model, options ...ContainerOption) Container {
-
c := &container{
content: content,
borderStyle: lipgloss.NormalBorder(),
}
-
for _, option := range options {
option(c)
}
-
return c
}