Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webhost: Allow Option Groups to specify whether they start collapsed #3370

Merged
merged 8 commits into from
May 24, 2024

Conversation

alwaysintreble
Copy link
Collaborator

@alwaysintreble alwaysintreble commented May 22, 2024

What is this fixing or adding?

title. game options group defaults to false, and can be overridden. item & location options is forced hidden as those options can be overwhelming.

How was this tested?

made a group and changed the new attribute around to verify new behavior on both pages

If this makes graphical changes, please attach screenshots.

Screenshot_232

@github-actions github-actions bot added affects: core Issues/PRs that touch core and may need additional validation. affects: webhost Issues/PRs that touch webhost and may need additional validation. waiting-on: peer-review Issue/PR has not been reviewed by enough people yet. labels May 22, 2024
@alwaysintreble alwaysintreble added the is: enhancement Issues requesting new features or pull requests implementing new features. label May 22, 2024
Copy link
Collaborator

@PoryGone PoryGone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed that the start_collapsed field on the OptionGroup does function as advertised.
Did not test the Group Name changes.
Reviewed Python code, did not assess HTML.

Looks good. I like this change.

Copy link
Member

@LegendaryLinux LegendaryLinux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like it works fine, but I would prefer you maintained boolean consistency. Giving the option a start_collapsed key, but then labeling it group_visibility later is confusing. Either change the key to start_uncollapsed or continue using start_collapsed in the templates.

@LegendaryLinux
Copy link
Member

I'll merge this after the conflicts are resolved.

# Conflicts:
#	WebHostLib/options.py
#	worlds/AutoWorld.py
@LegendaryLinux LegendaryLinux merged commit 8045c87 into ArchipelagoMW:main May 24, 2024
16 checks passed
jnschurig pushed a commit to Tranquilite0/Archipelago-SoulBlazer that referenced this pull request Jun 13, 2024
…rchipelagoMW#3370)

* allow option groups to specify whether they should be hidden or not

* allow worlds to override whether game options starts collapsed

* remove Game Options assert so the visibility of that group can be changed

* if "Game Options" or "Item & Location Options" groups are specified, fix casing

* don't allow item & location options to have duplicates of the auto added options

* use a generator instead of a comprehension

* use consistent naming
sflavelle pushed a commit to sflavelle/Archipelago-tgc that referenced this pull request Jun 20, 2024
…rchipelagoMW#3370)

* allow option groups to specify whether they should be hidden or not

* allow worlds to override whether game options starts collapsed

* remove Game Options assert so the visibility of that group can be changed

* if "Game Options" or "Item & Location Options" groups are specified, fix casing

* don't allow item & location options to have duplicates of the auto added options

* use a generator instead of a comprehension

* use consistent naming
qwint pushed a commit to qwint/Archipelago that referenced this pull request Jun 24, 2024
…rchipelagoMW#3370)

* allow option groups to specify whether they should be hidden or not

* allow worlds to override whether game options starts collapsed

* remove Game Options assert so the visibility of that group can be changed

* if "Game Options" or "Item & Location Options" groups are specified, fix casing

* don't allow item & location options to have duplicates of the auto added options

* use a generator instead of a comprehension

* use consistent naming
AustinSumigray pushed a commit to AustinSumigray/Archipelago that referenced this pull request Jan 4, 2025
…rchipelagoMW#3370)

* allow option groups to specify whether they should be hidden or not

* allow worlds to override whether game options starts collapsed

* remove Game Options assert so the visibility of that group can be changed

* if "Game Options" or "Item & Location Options" groups are specified, fix casing

* don't allow item & location options to have duplicates of the auto added options

* use a generator instead of a comprehension

* use consistent naming
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects: core Issues/PRs that touch core and may need additional validation. affects: webhost Issues/PRs that touch webhost and may need additional validation. is: enhancement Issues requesting new features or pull requests implementing new features. waiting-on: peer-review Issue/PR has not been reviewed by enough people yet.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants