submodels

package
v0.0.0-...-b82ce1f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 15, 2025 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ScrollbarTrack = "░"
	ScrollbarThumb = "█"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ConsoleModel

type ConsoleModel struct {
	Width  int
	Height int

	ConsoleOpened bool
	Focused       bool
	LogsContent   [][2]string
	Viewport      viewport.Model
}

func (ConsoleModel) Init

func (m ConsoleModel) Init() tea.Cmd

func (ConsoleModel) Update

func (m ConsoleModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (ConsoleModel) View

func (m ConsoleModel) View() string

type GuideTreeModel

type GuideTreeModel struct {
	Width  int
	Height int

	GuidesPath        string
	ReadGuideCallback func(string)

	Focused  bool
	Viewport viewport.Model
	Tree     tree.Model

	Scrollbar ScrollbarModel
	// contains filtered or unexported fields
}

func (GuideTreeModel) Init

func (m GuideTreeModel) Init() tea.Cmd

func (GuideTreeModel) Update

func (m GuideTreeModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (GuideTreeModel) View

func (m GuideTreeModel) View() string

type InspectModel

type InspectModel struct {
	Width  int
	Height int

	Focused            bool
	ProgressBar        MultilineProgress
	InspectingDownload *core.Resource
	// contains filtered or unexported fields
}

func (InspectModel) Init

func (m InspectModel) Init() tea.Cmd

func (InspectModel) PrintResourceStatus

func (m InspectModel) PrintResourceStatus() string

func (InspectModel) Update

func (m InspectModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (InspectModel) UpdateContent

func (m InspectModel) UpdateContent() string

func (InspectModel) View

func (m InspectModel) View() string

type MultilineProgress

type MultilineProgress struct {
	// contains filtered or unexported fields
}

func NewMultilineProgress

func NewMultilineProgress(width, height int, style, fillStyle lipgloss.Style) MultilineProgress

func (*MultilineProgress) GetPercent

func (m *MultilineProgress) GetPercent() float64

func (*MultilineProgress) SetPercent

func (m *MultilineProgress) SetPercent(percent float64)

func (*MultilineProgress) SetStyles

func (m *MultilineProgress) SetStyles(background, fill lipgloss.Style)

func (*MultilineProgress) View

func (m *MultilineProgress) View(overlay string) string
type NavigateToGuideMsg guides.Guide

type ResizeMsgL2

type ResizeMsgL2 struct {
	Width  int
	Height int
}

type ResizeMsgL3

type ResizeMsgL3 struct {
	Width  int
	Height int
}

type ScrollbarModel

type ScrollbarModel struct {
	Height        int  // Total height of the scrollbar
	ContentHeight int  // Total height of the content being scrolled
	ViewHeight    int  // Height of the visible viewport
	ScrollOffset  int  // Current scroll position
	ShowScrollbar bool // Whether to show the scrollbar
}

func NewScrollbar

func NewScrollbar() ScrollbarModel

func (ScrollbarModel) View

func (m ScrollbarModel) View() string

type StatusModel

type StatusModel struct {
	Width  int
	Height int

	Focused           bool
	ApplicationObject *core.Application
	Progress          MultilineProgress
	FillStyle         lipgloss.Style
	BackStyle         lipgloss.Style
}

func (StatusModel) Init

func (m StatusModel) Init() tea.Cmd

func (StatusModel) Update

func (m StatusModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (StatusModel) View

func (m StatusModel) View() string

type StatusbarModel

type StatusbarModel struct {
	Width int
}

func (StatusbarModel) Init

func (m StatusbarModel) Init() tea.Cmd

func (StatusbarModel) Update

func (m StatusbarModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (StatusbarModel) View

func (m StatusbarModel) View() string

type TextViewerModel

type TextViewerModel struct {
	Width  int
	Height int

	Focused   bool
	Path      string
	Viewport  viewport.Model
	Heading   string
	Content   string
	Scrollbar ScrollbarModel
}

func (*TextViewerModel) GetSetViewerContent

func (m *TextViewerModel) GetSetViewerContent()

func (TextViewerModel) Init

func (m TextViewerModel) Init() tea.Cmd

func (TextViewerModel) Update

func (m TextViewerModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

func (TextViewerModel) View

func (m TextViewerModel) View() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL