Class: Rubino::UI::Composer::SubagentPanel
- Inherits:
-
Object
- Object
- Rubino::UI::Composer::SubagentPanel
- Defined in:
- lib/rubino/ui/composer/subagent_panel.rb
Overview
The SINGLE live representation of running background subagents, rendered by the composer BELOW the input (next to the status footer). Replaces the old split where the same subagent showed up twice — once as an inline card block above the timeline and again as the navigable menu.
Two faces, one place:
- default: the compact, read-only cards (one calm line per subagent),
supplied by the composer (UI::SubagentCards, fed from the registry);
- when the user opens the picker (↓): the navigable UI::AgentMenu, so
↑/↓ select and Enter drills the chosen agent into the timeline.
Pure composition: it owns no state and does no I/O — it just asks the menu/cards for their rows. Empty array when nothing is live, so the composer clears the region.
Instance Method Summary collapse
-
#initialize(agent_menu:, cards:) ⇒ SubagentPanel
constructor
A new instance of SubagentPanel.
-
#rows(cols) ⇒ Object
The rows to draw below the input this frame.
Constructor Details
#initialize(agent_menu:, cards:) ⇒ SubagentPanel
Returns a new instance of SubagentPanel.
23 24 25 26 |
# File 'lib/rubino/ui/composer/subagent_panel.rb', line 23 def initialize(agent_menu:, cards:) @agent_menu = @cards = cards end |
Instance Method Details
#rows(cols) ⇒ Object
The rows to draw below the input this frame.
29 30 31 |
# File 'lib/rubino/ui/composer/subagent_panel.rb', line 29 def rows(cols) @agent_menu.open? ? @agent_menu.rows(cols) : Array(@cards.call) end |