types

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package types provides specific event type implementations

Package types provides specific event type implementations

Index

Constants

View Source
const (
	ActionDisplayOrder = 100
)

Variables

This section is empty.

Functions

func NewActionEvent

func NewActionEvent(actions interface{}, opts ...event.CustomEventOption) event.CustomEvent

NewActionEvent uses strings and makes simple selectable actions in the UI (always displayed last)

func NewTableEvent

func NewTableEvent(tableData TableData, opts ...event.CustomEventOption) event.CustomEvent

NewTableEvent creates a table event with columns and rows

Types

type ActionWrapper

type ActionWrapper struct {
	Prompts interface{} `json:"prompts"`
}

type TableColumn

type TableColumn struct {
	Key   string `json:"key"`
	Label string `json:"label"`
}

TableColumn represents a column in a table

type TableData

type TableData struct {
	Columns []TableColumn `json:"columns"`
	Rows    []TableRow    `json:"rows"`
}

TableData represents the structure of a table

type TableRow

type TableRow = map[string]any

TableRow represents a row of data in a table

type TableWrapper

type TableWrapper struct {
	Table TableData `json:"table"`
}

Jump to

Keyboard shortcuts

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