Skip to content

Conversation

@basnijholt
Copy link
Owner

Summary

  • Replace single-form options flow with collapsible sections
  • Basic options (9 fields) always visible at top
  • Advanced options (~26 fields) in collapsed section (collapsed by default)
  • Single form, no multi-step navigation needed

Alternative to #1311

This PR offers an alternative UX to the multi-step approach in #1311. Compare both to decide which is better:

Aspect This PR (sections) #1311 (multi-step)
User clicks 0 extra 2+ extra
Code complexity Simpler More complex
State management None _basic_options dict
User sees advanced exists Yes (collapsed) Only if they click menu

Test plan

  • All config flow tests pass
  • Test in Home Assistant UI that section renders correctly
  • Verify collapsed section expands properly
  • Check that saving options works (data flattening)

basnijholt and others added 4 commits November 28, 2025 15:32
Replace single-form options flow with collapsible sections:
- Basic options always visible (9 fields)
- Advanced options in collapsed section (collapsed by default)
- Single form, no multi-step navigation needed

Changes:
- const.py: Add BASIC_OPTIONS set defining which options are basic
- config_flow.py: Use section() from data_entry_flow to wrap advanced options
- strings.json: Restructure with sections.advanced for section translations
- tests: Update to handle nested section input format
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