Repository navigation
fix(scenarios): hide agentic options when 'Agentic scenario' is unchecked - #47
Merged
SushantGautam merged 1 commit intoOct 13, 2026
Conversation
…cked On the scenario edit/add forms, wrap the agentic metadata JSON editor and the structured agentic controls in a section that starts hidden unless the scenario is agentic, and show/hide it live as the checkbox toggles. This matches the backend, which already strips agentic metadata on save when the box is off, so the UI no longer shows ~30 irrelevant fields for non-agentic scenarios. Fixes #45 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
SushantGautam
deleted the
agents/see-https-github-com-simulamet-simpleauditstudio-87af98a6
branch
October 13, 2026 22:11
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #45 (Need better UI in agentic scenario edit).
On
/scenarios/?set=XX, each scenario's inline edit form (and the add-scenario form) showed the full set of ~30 agentic options regardless of whether the scenario was actually agentic — visual noise for non-agentic scenarios.This change hides those options when Agentic scenario is unchecked, and shows/hides them live as you toggle it.
What changed
All in
templates/scenarios.html:agentic_controls.htmlinclude in a<div data-agentic-section>that starts hidden when the revision has nometadata.agentic(edit form) or always (add form).toggleAgenticSection(form)+ achangelistener on everyagentic_scenariocheckbox so the section shows/hides instantly.This matches existing backend behavior —
infra/ui.pyalready strips allagenticmetadata on save when the box is off — so the UI now reflects what actually gets stored.Verification
display:nonewith an unchecked box./scenarios/?set=5): checked →block, uncheck →none, re-check →block; add-form default →none.uv run ruff check .— clean.pytest infra/tests/test_scenarios.py,test_agentic_integration.py,test_seed_agentic_scenarios.py,test_scenario_import_export.py— all passing.No migrations or config changes; purely template/client-side.