file

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2023 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OpName = "file-manager"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CallerStore

type CallerStore interface {
	input.Action
	Caller(context.Context, input.Binder) input.Action
}

type Close

type Close struct{}

func NewClose

func NewClose() *Close

func (*Close) DefaultEvent

func (c *Close) DefaultEvent() string

func (*Close) Menu

func (c *Close) Menu(context.Context) string

func (*Close) Name

func (c *Close) Name(context.Context) string

func (*Close) Op

func (c *Close) Op(ctx context.Context, b input.Binder) (input.Operation, error)

func (*Close) Type

func (c *Close) Type(input.Command)

func (*Close) Valid

func (c *Close) Valid(_ context.Context, b input.Binder) error

type CompletionHook

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

func NewCompletionHook

func NewCompletionHook() *CompletionHook

func (*CompletionHook) Name

func (*CompletionHook) OpNames

func (*CompletionHook) OpNames(context.Context) []string

func (*CompletionHook) TextChanged

func (h *CompletionHook) TextChanged(ctx context.Context, b input.Binder, _ ...struct {
	Before text.State
	Edit   input.Edit
})

func (*CompletionHook) TextChangedOp

func (*CompletionHook) Type

func (*CompletionHook) Type(input.Hook)

func (*CompletionHook) Valid added in v0.7.0

func (h *CompletionHook) Valid(ctx context.Context, b input.Binder) error

type CompletionScroll

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

func NewCompletionScroll

func NewCompletionScroll(dir caret.Direction) *CompletionScroll

func (*CompletionScroll) Menu

func (*CompletionScroll) Name

func (*CompletionScroll) Op

func (*CompletionScroll) Type

func (*CompletionScroll) Valid added in v0.7.0

func (c *CompletionScroll) Valid(ctx context.Context, b input.Binder) error

type CompletionSelect

type CompletionSelect struct{}

func NewCompletionSelect

func NewCompletionSelect() *CompletionSelect

func (*CompletionSelect) Menu

func (*CompletionSelect) Name

func (*CompletionSelect) Op

func (*CompletionSelect) Type

func (*CompletionSelect) Valid added in v0.7.0

func (c *CompletionSelect) Valid(ctx context.Context, b input.Binder) error

type Completions

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

func NewCompletions

func NewCompletions() *Completions

func (*Completions) Name

func (*Completions) Run

func (c *Completions) Run(ctx context.Context, b input.Binder) error

func (*Completions) StartUpdate

func (c *Completions) StartUpdate(ctx context.Context, b input.Binder) input.Operation

func (*Completions) Type

func (*Completions) Type(input.Operation)

func (*Completions) Valid added in v0.7.0

func (c *Completions) Valid(ctx context.Context, b input.Binder) error

type FileManager

type FileManager interface {
	OpenFile(name, path string) input.Operation
	SaveFile() input.Operation
	CloseFile() input.Operation
}

type Open

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

func NewOpen

func NewOpen(ctx context.Context) *Open

func (*Open) DefaultEvent

func (o *Open) DefaultEvent() string

func (*Open) Menu

func (o *Open) Menu(context.Context) string

func (*Open) Name

func (o *Open) Name(context.Context) string

func (*Open) Op

func (o *Open) Op(ctx context.Context, b input.Binder) (input.Operation, error)

func (*Open) Type

func (o *Open) Type(input.Command)

type Pather

type Pather interface {
	input.Binder
	Path(context.Context) (string, bool)
}

type Prompt added in v0.7.0

type Prompt interface {
	input.Action

	Prompt(...ui.Span) input.Operation
	Input(string) input.Operation
	Extra(...[]ui.Span) input.Operation
	Caller(input.Action) input.Operation
	Callback(func(context.Context, input.Binder, []ui.Span, string, [][]ui.Span) (input.Operation, error)) input.Operation
}

type Save

type Save struct{}

func NewSave

func NewSave() *Save

func (*Save) DefaultEvent

func (s *Save) DefaultEvent() string

func (*Save) Menu

func (s *Save) Menu(context.Context) string

func (*Save) Name

func (s *Save) Name(context.Context) string

func (*Save) Op

func (s *Save) Op(ctx context.Context, b input.Binder) (input.Operation, error)

func (*Save) Type

func (s *Save) Type(input.Command)

func (*Save) Valid

func (s *Save) Valid(_ context.Context, b input.Binder) error

type StateContainer

type StateContainer interface {
	input.Binder
	State(context.Context) text.State
}

Jump to

Keyboard shortcuts

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