Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type HitTest ¶ added in v1.20.1
type HitTest struct {
// contains filtered or unexported fields
}
HitTest determines what UI element is at the given coordinates. This centralizes all hit-testing logic in one place, making it easier to understand the clickable regions and their priorities.
func NewHitTest ¶ added in v1.20.1
func NewHitTest(page *chatPage) *HitTest
NewHitTest creates a hit tester for the given chat page.
func (*HitTest) At ¶ added in v1.20.1
func (h *HitTest) At(x, y int) MouseTarget
At determines what target is at the given coordinates. It checks regions in priority order (most specific first).
type MouseTarget ¶ added in v1.20.1
type MouseTarget int
MouseTarget represents what the mouse is interacting with.
const ( TargetNone MouseTarget = iota TargetSidebarToggle TargetSidebarResizeHandle TargetSidebarStar TargetSidebarTitle TargetSidebarContent TargetMessages )
type Page ¶
type Page interface {
layout.Model
layout.Sizeable
layout.Help
CompactSession(additionalPrompt string) tea.Cmd
Cleanup()
// SetSessionStarred updates the sidebar star indicator
SetSessionStarred(starred bool)
// SetTitleRegenerating sets the title regenerating state on the sidebar
SetTitleRegenerating(regenerating bool) tea.Cmd
// ScrollToBottom scrolls the messages viewport to the bottom if auto-scroll is active.
ScrollToBottom() tea.Cmd
// IsWorking returns whether the agent is currently working
IsWorking() bool
// QueueLength returns the number of queued messages
QueueLength() int
// FocusMessages gives focus to the messages panel for keyboard scrolling
FocusMessages() tea.Cmd
// FocusMessageAt gives focus and selects the message at the given screen coordinates
FocusMessageAt(x, y int) tea.Cmd
// BlurMessages removes focus from the messages panel
BlurMessages()
// GetSidebarSettings returns the current sidebar display settings
GetSidebarSettings() SidebarSettings
// SetSidebarSettings applies sidebar display settings
SetSidebarSettings(settings SidebarSettings)
}
Page represents the main chat content area (messages + sidebar). The editor and resize handle are owned by the parent (tui.Model).
type SidebarSettings ¶ added in v1.20.6
SidebarSettings holds the sidebar display settings that should persist across session changes.
Click to show internal directories.
Click to hide internal directories.