INNER CODE UNIT · Python
compose
idoavrah/terraform-tui · src/tftui/app.py:103
def compose(self) -> ComposeResult:
yield AppHeader(
version=f"{__version__}{self.telemetry.update_suffix}",
directory=str(self.client.cwd),
id="header",
)
# `select_on_focus=False`: returning to the box must let the existing
# text be extended or corrected, not replaced by the first keystroke.
yield Input(
id="search",
placeholder=_SEARCH_PLACEHOLDER[TREE],
select_on_focus=False,
)
with ContentSwitcher(id="switcher", initial=TREE):
yield StateTree("State", id=TREE)
yield ResourceView(id=RESOURCE)
yield PlanView(id=PLAN)
# Compact, and without the command-palette hint: tftui has enough