Dashboard home screen renderer.
Renders the editor's landing page when no file buffers are open. Shows an ASCII mountain range header, quick-action shortcuts, recent files, and a version string. All content is horizontally centered.
This is a pure rendering module: it takes dimensions, theme, and state,
and returns a list of DisplayList.draw() tuples. No side effects.
Summary
Types
Command dispatched when a dashboard item is selected.
Dashboard item: an action the user can select.
Dashboard state: cursor position and computed items.
Functions
Moves the dashboard cursor down, wrapping at the bottom.
Moves the dashboard cursor up, wrapping at the top.
Returns a fresh dashboard state with quick actions and recent files.
Renders the dashboard as a list of display list draws.
Returns the command for the currently selected item, or nil if no items.
Types
Command dispatched when a dashboard item is selected.
Dashboard item: an action the user can select.
@type state() :: %{cursor: non_neg_integer(), items: [item()]}
Dashboard state: cursor position and computed items.
Functions
Moves the dashboard cursor down, wrapping at the bottom.
Moves the dashboard cursor up, wrapping at the top.
Returns a fresh dashboard state with quick actions and recent files.
@spec render(pos_integer(), pos_integer(), MingaEditor.UI.Theme.t(), state()) :: [ MingaEditor.DisplayList.draw() ]
Renders the dashboard as a list of display list draws.
Lays out the mountain range header, quick actions, recent files
heading, recent file entries, and a bottom-pinned version string, all
horizontally centered in the given width x height area.
Returns the command for the currently selected item, or nil if no items.