Documentation
¶
Index ¶
- Variables
- type Action
- type Application
- type Applications
- type Command
- type CommandMode
- type CommandParam
- type CommandRef
- type CommandSpec
- type CommandType
- type Detail
- type DropDownItem
- type Form
- type FormItem
- type FormItemType
- type List
- type ListItem
- type Manifest
- type Metadata
- type Page
- type PageType
- type ParamType
- type Platform
Constants ¶
This section is empty.
Variables ¶
View Source
var ( PlatformWindows = "windows" PlatformMac = "mac" PlatformLinux = "linux" )
Functions ¶
This section is empty.
Types ¶
type Application ¶
type Applications ¶
type Applications []Application
func (*Applications) UnmarshalJSON ¶
func (a *Applications) UnmarshalJSON(b []byte) error
type Command ¶
type Command struct {
Type CommandType `json:"type,omitempty"`
Text string `json:"text,omitempty"`
App Applications `json:"app,omitempty"`
Target string `json:"target,omitempty"`
Exit bool `json:"exit,omitempty"`
Reload bool `json:"reload,omitempty"`
CommandRef
Exec string `json:"exec,omitempty"`
}
type CommandMode ¶
type CommandMode string
const ( CommandModeView CommandMode = "view" CommandModeNoView CommandMode = "no-view" )
type CommandParam ¶
type CommandRef ¶
type CommandSpec ¶
type CommandSpec struct {
Name string `json:"name"`
Title string `json:"title"`
Hidden bool `json:"hidden,omitempty"`
Params []CommandParam `json:"params,omitempty"`
Mode CommandMode `json:"mode,omitempty"`
}
type CommandType ¶
type CommandType string
const ( CommandTypeRun CommandType = "run" CommandTypeOpen CommandType = "open" CommandTypeCopy CommandType = "copy" CommandTypeReload CommandType = "reload" CommandTypeExit CommandType = "exit" CommandTypePop CommandType = "pop" CommandTypePass CommandType = "pass" CommandTypeExec CommandType = "exec" )
type DropDownItem ¶
type FormItem ¶
type FormItem struct {
Type FormItemType `json:"type"`
Name string `json:"name,omitempty"`
Title string `json:"title"`
Placeholder string `json:"placeholder,omitempty"`
Default any `json:"default,omitempty"`
Optional bool `json:"optional,omitempty"`
// Only for dropdown
Items []DropDownItem `json:"items,omitempty"`
// Only for checkbox
Label string `json:"label,omitempty"`
}
type FormItemType ¶
type FormItemType string
const ( TextInput FormItemType = "text" TextAreaInput FormItemType = "textarea" SelectInput FormItemType = "select" CheckboxInput FormItemType = "checkbox" )
type Manifest ¶
type Manifest struct {
Title string `json:"title"`
Description string `json:"description,omitempty"`
Commands []CommandSpec `json:"commands"`
}
Click to show internal directories.
Click to hide internal directories.