Skip to content

refactor(features): reorganize UI and use static group controls - #87

Merged
georgezakinih merged 3 commits into
FNLCR-DMAP:devfrom
zhan4329:ref/features-ui-structure
Sep 17, 2026
Merged

georgezakinih merged 3 commits into
FNLCR-DMAP:devfrom
zhan4329:ref/features-ui-structure

Conversation

@zhan4329

@zhan4329 zhan4329 commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Description

This PR refactors the SPAC Shiny Features tab into focused control and result components, organizes the existing inputs in features_ui.py into clearer configuration sections, and replaces server-inserted Group By controls in features_server.py with stable conditional UI in features_ui.py.

The refactor preserves the current histogram behavior.

Related

Changes

  • Changes the Features layout from 2/10 to 3/9 control/result columns.
  • Extracts _controls_panel() and _plot_panel(); Adds a local _collapsible_section() helper for presentation-only disclosure behavior.
  • Organizes Feature and Table as always-visible Core Parameters, Group By and log controls under Plot Configuration, and label rotation under Figure Configuration.
  • Makes Render Plot span the width of the controls panel by adding w-100 in the button class.
  • Declares Annotation, Plot Together, and Stack Type as nested conditional UI; Removes the corresponding dynamic insertion targets, reactive state, and insertion/removal effects from features_server.py.
  • Updates Features annotation choices through the existing central effect_update_server.py.

Testing

  • User-tested the complete Features workflow in Shiny, including disclosure sections, ordinary and grouped rendering, Plot Together and Stack Type conditions, repeated toggling and rendering, label rotation, plot display, and CSV download.
  • Full application import in the existing local Docker image passed.
  • Rendered UI construction, unique identifiers, preserved defaults, 3/9 layout, and conditional-expression checks passed.
  • Direct ordinary, grouped-separate, grouped-together, repeated-render, dataframe, and download-path checks passed.
  • python tests/test_utils/test_plot_utils.py -v — 6 passed in the project Docker image.
  • Python AST syntax checks and git diff --check dev...HEAD passed.

Notes for Review

Suggested review order:

  1. ui/features_ui.py for the extracted composition, disclosure sections, and static conditional controls.
  2. server/effect_update_server.py for centralized Annotation choices.
  3. server/features_server.py for removal of the dynamic UI lifecycle while retaining the existing render arguments.

The static dependent inputs retain their selections while hidden; the renderer ignores them whenever Group By is disabled.

A better reusable cross-tab visualization design (and CSS styling) are postponed.

Screenshots

The new collapsible UI looks like this:

image

@zhan4329 zhan4329 changed the title Ref/features UI structure refactor: features UI structure and shared CSS styling Sep 15, 2026
@zhan4329 zhan4329 changed the title refactor: features UI structure and shared CSS styling refactor: improve features ui code structure and control ownership Sep 15, 2026
@zhan4329 zhan4329 changed the title refactor: improve features ui code structure and control ownership refactor(features): reorganize UI and use static group controls Sep 15, 2026
@zhan4329
zhan4329 marked this pull request as ready for review September 15, 2026 19:40
zhan4329 added a commit to zhan4329/SPAC_Shiny that referenced this pull request Sep 16, 2026
- update overview and PR summary to document PR FNLCR-DMAP#86 / FNLCR-DMAP#87 integration strategy
- record combined baseline integration requirements in implementation notes
- update task reassignment links to match renumbered PR plan entries
zhan4329 added a commit to zhan4329/SPAC_Shiny that referenced this pull request Sep 16, 2026
- mark PR FNLCR-DMAP#86 as merged into dev on 2026-09-16 in overview
- add decision D21 recording completion of template delegation PR
- update next steps to integrate PR FNLCR-DMAP#87 and point to Features facet tracker
zhan4329 added a commit to zhan4329/SPAC_Shiny that referenced this pull request Sep 16, 2026
- mark Tasks 3 (verification) and 4 (static Group By controls) complete
- record postponement of Task 5 (shared styling) to cross-tab roadmap
- add PR FNLCR-DMAP#87 summary covering changes, testing, and notes for review
- update overview and implementation notes to coordinate PR FNLCR-DMAP#86 / FNLCR-DMAP#87 integration
zhan4329 added a commit to zhan4329/SPAC_Shiny that referenced this pull request Sep 16, 2026
- mark Tasks 3 (verification) and 4 (static Group By controls) complete
- record postponement of Task 5 (shared styling) to cross-tab roadmap
- add PR FNLCR-DMAP#87 summary covering changes, testing, and notes for review
- update overview and implementation notes to coordinate PR FNLCR-DMAP#86 / FNLCR-DMAP#87 integration
- Group existing inputs into core, plot, and figure configuration sections.
- Add a local disclosure helper while preserving input IDs, dynamic insertion targets, defaults, and server behavior.
- Make the primary render action span the controls panel.
- Declare Annotation, Plot Together, and Stack Type in nested conditional UI.
- Update Features annotation choices through the central effect updater.
- Remove dynamic insertion state and effects while preserving histogram behavior.
@zhan4329
zhan4329 force-pushed the ref/features-ui-structure branch from 12e16dd to efc514b Compare September 16, 2026 16:40
zhan4329 added a commit to zhan4329/SPAC_Shiny that referenced this pull request Sep 16, 2026
- update overview with prerequisite PR FNLCR-DMAP#86 and PR FNLCR-DMAP#87 context and open issues
- add decisions D2 (branch stacking) and D3 (inheriting UI structure)
- detail template boundary, Together/Facet conflicts, and verification in notes
- establish development-details tracker structure for facet implementation
@georgezakinih
georgezakinih merged commit e156136 into FNLCR-DMAP:dev Sep 17, 2026
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.

2 participants