Help us shape the future of Go! Take the 2026 Go Developer Survey

saveDialog

package
v0.0.0-...-978d0fb Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hit

type Hit int
const (
	HitNone Hit = iota
	HitCancel
	HitContinue
	HitCloudShare
)

type ModeOption

type ModeOption struct {
	Label  string
	Mode   SaveMode
	GOOS   string
	GOARCH string
	Ext    string
}

type Model

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

func New

func New(fillSignOnly bool) Model

func (Model) CloudShare

func (m Model) CloudShare() Result

CloudShare produces the result for uploading the fill/sign document to the cloud.

func (Model) Content

func (m Model) Content(width, height int) string

func (Model) Continue

func (m Model) Continue() Result

Continue produces the save result for the current selection — the same action as pressing enter or clicking the continue button.

func (Model) MouseHit

func (m Model) MouseHit(x, y, width, height int) Hit

MouseHit reports which button the given content-area coordinate lands on. It locates the buttons by scanning the rendered output for their labels, so it stays in sync with the view layout by construction.

func (Model) RowAt

func (m Model) RowAt(x, y, width, height int) int

RowAt reports the index of the checkbox row at the given content-area coordinate, or -1. The clickable area spans the indicator and the label.

func (Model) StatusHint

func (m Model) StatusHint() string

func (Model) ToggleRow

func (m Model) ToggleRow(i int) Model

ToggleRow toggles the checkbox row with the given index — the same action as moving the cursor there and pressing space.

func (Model) Update

func (m Model) Update(msg tea.KeyMsg) (Model, Result)

func (Model) UpdateHover

func (m Model) UpdateHover(x, y, width, height int) Model

type Result

type Result struct {
	Done         bool
	Saved        bool
	FillSignOnly bool
	CloudShare   bool
	Options      []ModeOption
}

type SaveMode

type SaveMode int
const (
	SaveModePact SaveMode = iota
	SaveModeDivider
	SaveModePlatform
)

Source Files

  • model.go
  • mouse.go
  • update.go
  • view.go

Jump to

Keyboard shortcuts

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