Skip to content

feat: hide advanced inputs behind More options in the run form - #15

Merged
piekstra merged 2 commits into
mainfrom
piekstra/advanced-inputs
Oct 26, 2026
Merged

piekstra merged 2 commits into
mainfrom
piekstra/advanced-inputs

Conversation

@piekstra

@piekstra piekstra commented Oct 26, 2026 •

Copy link
Copy Markdown
Member

Summary

Flows often carry inputs that most runs leave at their default (a tenant, a region, a fixture id). Showing all of them in the run form makes the form noisy. advanced: true keeps such an input behind More options:

inputs:
  - { name: greeting, default: hi }
  - { name: tenant, advanced: true, default: acme }
  • The run form shows non-advanced inputs, plus a More options (N) button that reveals the rest (aria-expanded).
  • --input tenant=globex sets an advanced input from the CLI like any other.
  • lest get marks advanced inputs.
  • Validation: a required advanced input needs a default, so the form can always start without opening More options.

Verification

  • New validate test an_advanced_required_input_needs_a_default, new UI tests for formInputs.
  • Ran a sample flow headless through lest ui with Playwright: closed form shows greeting and More options (2); opened, it shows greeting | Tenant | region.
  • lest run hello --input tenant=globex --input region=us passes.
  • make lint, make build, UI tests and all Rust tests pass except parallel_group_runs_concurrently and cancel_stops_steps_but_runs_finally_and_cleanup, which fail the same way on main on this machine under load (timing assertions); CI is the reference.

An input with advanced: true stays out of the run form until More options is opened, and runs with its default otherwise. The CLI still sets it with --input, and lest get marks it. A required advanced input must have a default so the form can start without it.
@piekstra

Copy link
Copy Markdown
Member Author

Review pass on the diff (self-review; no findings needing a change):

  • A required advanced input without a default would leave Run disabled with the field hidden. Prevented in validation rather than in the form, so every client (UI, CLI) sees the same rule.
  • The More options button only renders when the flow has advanced inputs, so flows without them look unchanged.
  • Advanced is presentation only: the run request, CLI --input and the report treat these inputs like any other.

@piekstra piekstra closed this Oct 26, 2026
@piekstra piekstra reopened this Oct 26, 2026
@piekstra
piekstra marked this pull request as ready for review October 26, 2026 17:39
# Conflicts:
#	crates/lest-core/src/validate.rs
@piekstra
piekstra merged commit 1de1078 into main Oct 26, 2026
5 checks passed
@piekstra
piekstra deleted the piekstra/advanced-inputs branch October 26, 2026 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant