runtime

package
v0.3.7 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2026 License: BSD-3-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Effect

type Effect interface {
	// contains filtered or unexported methods
}

Effect is an engine output that must be executed by runtime adapter.

type Engine

type Engine interface {
	HandleEvent(Event) []Effect
	View() string
}

Engine is the runtime-agnostic TUI state machine.

type Event

type Event interface {
	// contains filtered or unexported methods
}

Event is an engine-level input event independent from UI frameworks.

type KeyPressedEvent

type KeyPressedEvent struct {
	Key string
}

type LoadPreviewEffect

type LoadPreviewEffect struct {
	Request preview.Request
}

type PersistPreviewEffect

type PersistPreviewEffect struct {
	IndexPath string
	Cap       int
	Record    preview.IndexRecord
}

type PreviewLoadedEvent

type PreviewLoadedEvent struct {
	Message preview.LoadedMsg
}

type PreviewPersistedEvent

type PreviewPersistedEvent struct {
	Message preview.IndexPersistedMsg
}

type QuitEffect

type QuitEffect struct{}

type Runtime

type Runtime interface {
	Run(engine Engine) error
}

Runtime runs one TUI engine using a concrete event loop implementation.

func NewBubbleTea

func NewBubbleTea() Runtime

type WindowSizeEvent

type WindowSizeEvent struct {
	Width  int
	Height int
}

Jump to

Keyboard shortcuts

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