MCPcopy Create free account
hub / github.com/Thunder-Compute/thunder-cli / NewDeleteModel

Function NewDeleteModel

tui/delete.go:40–56  ·  view source on GitHub ↗
(client *api.Client, instances []api.Instance)

Source from the content-addressed store, hash-verified

38}
39
40func NewDeleteModel(client *api.Client, instances []api.Instance) deleteModel {
41 s := NewPrimarySpinner()
42
43 ps := NewPanelStyles()
44 // Override title with margins matching delete layout
45 ps.Title = PrimaryTitleStyle().MarginTop(1).MarginBottom(1)
46
47 return deleteModel{
48 step: deleteStepSelect,
49 client: client,
50 loading: false,
51 spinner: s,
52 instances: instances,
53 styles: ps,
54 warningBox: WarningBoxStyle().MarginTop(1).MarginBottom(1),
55 }
56}
57
58func (m deleteModel) Init() tea.Cmd {
59 return nil

Callers 1

RunDeleteInteractiveFunction · 0.85

Calls 4

NewPrimarySpinnerFunction · 0.85
NewPanelStylesFunction · 0.85
PrimaryTitleStyleFunction · 0.85
WarningBoxStyleFunction · 0.85

Tested by

no test coverage detected