# `MingaEditor.State.ModalOverlay.CommandCompletion`
[🔗](https://github.com/jsmestad/minga/blob/main/lib/minga_editor/state/modal_overlay/command_completion.ex#L1)

Modal-overlay payload for the ex-command completion popup.

Unlike the LSP `:completion` variant, this overlay is a rendering-oriented
state container. The command mode FSM owns all key routing; this payload
holds pre-computed candidate data so the TUI renderer avoids recomputing
fuzzy scores during rendering.

Opened when entering command mode, updated on each keystroke, and closed
on mode exit. No trigger lifecycle or tab ownership needed since command
mode is inherently single-context.

# `t`

```elixir
@type t() :: %MingaEditor.State.ModalOverlay.CommandCompletion{
  candidates: [MingaEditor.MinibufferData.candidate()],
  filter_text: String.t(),
  selected: non_neg_integer(),
  total: non_neg_integer()
}
```

# `new`

```elixir
@spec new(keyword()) :: t()
```

# `update`

```elixir
@spec update(
  t(),
  keyword()
) :: t()
```

---

*Consult [api-reference.md](api-reference.md) for complete listing*
