Skip to main content

Module app

Module app 

Source
Expand description

Application root: terminal setup, the shared/UI state split, and the main event loop.

Feature-specific state types and the matching App methods live in the submodules declared below; this file keeps the core types (App, AppState, ViewState, Screen, SortOrder) and the run / main-loop plumbing. Every public item of the submodules is re-exported here so the rest of the crate keeps using the flat crate::app::Type paths.

Structs§

App
Root application struct — owns the terminal, state, and event channel.
AppState
Application data shared between the UI thread and background SSH tasks. Wrapped in Arc<RwLock<_>> — multiple readers, rare writers.
FileManagerView
All UI state for the File Manager screen.
FilePanelView
UI state for a single file panel (local or remote).
FmClipboard
Items held in the copy clipboard.
FormField
A single editable text field in the host form.
GroupHeader
One section of the grouped dashboard grid.
HostForm
The host add/edit form, containing all editable fields.
HostListView
UI state specific to the host list / Dashboard screen.
PassphrasePrompt
In-memory prompt for an encrypted SSH identity file.
PasswordPrompt
In-memory prompt for the login password a connection waits on.
SnippetForm
The snippet add/edit form.
SnippetResultEntry
One host’s result entry for the snippet execution results popup.
SnippetsView
UI state specific to the Snippets screen.
SplitView
Layout description when split-view is active.
TermHostPicker
Host-picker popup for opening a new terminal tab.
TermTab
A single open SSH/PTY tab.
TerminalView
All UI state for the Terminal screen.
UpdatePopup
State of the startup “update available” popup.
ViewState
UI-specific state that lives only on the main thread.

Enums§

AppAction
Actions that a UI input handler can request from the main event loop. Separating them from events allows the main loop to remain the sole owner of state mutations.
FileManagerPopup
Active popup on the File Manager screen.
FmPanel
Which of the two file panels is currently focused.
GridRow
One visual row of the dashboard grid.
HostPopup
Which popup is currently visible over the host list.
NavDir
Direction for dashboard grid navigation.
Screen
The active top-level screen shown to the user.
SnippetPopup
Which popup is currently shown over the Snippets screen (or as a full-screen overlay from any screen).
SortOrder
How dashboard cards are sorted.
SplitDirection
Direction of the split-view layout.
SplitFocus
Which pane currently has keyboard focus in split-view mode.
UpdateButton
A button in the startup update popup. Buttons are laid out left-to-right in UPDATE_BUTTONS order.
UpdatePopupPhase
Lifecycle phase of the update popup.

Constants§

CLOSE_KEY_GRACE
How long after an ended tab closes Enter and Esc still count as closing it.
FORM_FIELD_LABELS
Labels for every field in the host add/edit form.
SNIPPET_FORM_FIELD_LABELS
Labels for each field in the snippet add/edit form.
UPDATE_BUTTONS
The three update-popup buttons, in display order.

Functions§

filter_hosts
Simple case-insensitive substring filter over name / hostname / tags / notes.
filter_snippets
Case-insensitive substring filter over snippet name / command / tags.
forwards_value
Renders a host’s port forwards the way their form field holds them.