Page MenuHomePhabricator

Fix 'local exceptions for global preference' toggle in mobile Special:Preferences
Closed, ResolvedPublic

Description

When users have specified a preference should be global via Special:GlobalPreferences, they can set local exceptions (overrides) in Special:Preferences. In the new MinervaNeue design, this is not possible, as the toggle does not re-enable the form fields for the preference.

Steps to reproduce

In MinervaNeue:

  • Navigate to Special:GlobalPreferences
  • Check the box next to a preference and save
  • Navigate to the same preference at Special:Preferences
  • A toggle labeled "Set a local exception for this global preference." should display under this preference, for which form fields should be disabled
  • Activating this toggle does not re-enable the form fields above, but it should.

Checking the box in Vector re-enables the form fields:

Screenshot 2023-04-24 at 14.26.50.png (452×1 px, 115 KB)

Toggling in MinervaNeue does not:

Screenshot 2023-04-24 at 14.27.19.png (798×818 px, 133 KB)

Event Timeline

Restricted Application added subscribers: Masumrezarock100, Aklapper. · View Herald Transcript

Not only for local exceptions, this also happened to all fields with the disable-if param set. Including Allow emails from brand-new users which should only be enabled when Allow other users to email me is on.

Change 910544 had a related patch set uploaded (by Func; author: Func):

[mediawiki/core@master] preferences: Sync states between hidden checkbox and toggle widgets

https://gerrit.wikimedia.org/r/910544

What projects still have the toggles showing in global preferences on minerva? I would expect them to use checkboxes instead since our quick fix for T334260: GlobalPreferences formatting is broken on mobile was deployed.

What projects still have the toggles showing in global preferences on minerva? I would expect them to use checkboxes instead since our quick fix for T334260: GlobalPreferences formatting is broken on mobile was deployed.

The toggles show in Special:Preferences after a global preference has been selected and saved.

Ah, gotcha, I should have run through the reproduce steps before commenting. Thanks!

TheresNoTime subscribed.

Going to boldly assume this comes under Moderator Tools' scope of work and untag us — please feel free to re-tag if incorrect :-)

Test wiki created on Patch demo by SCardenas (WMF) using patch(es) linked to this task:
https://patchdemo.wmflabs.org/wikis/37917f7ee2/w

Test wiki created on Patch demo by SCardenas (WMF) using patch(es) linked to this task:
https://patchdemo.wmflabs.org/wikis/37917f7ee2/w

This looks good to me!

Change 910544 merged by jenkins-bot:

[mediawiki/core@master] preferences: Sync states between hidden checkbox and toggle widgets

https://gerrit.wikimedia.org/r/910544

Change 911805 had a related patch set uploaded (by Func; author: Func):

[mediawiki/core@REL1_40] preferences: Sync states between hidden checkbox and toggle widgets

https://gerrit.wikimedia.org/r/911805

Jdforrester-WMF assigned this task to Func.

Change 911805 merged by jenkins-bot:

[mediawiki/core@REL1_40] preferences: Sync states between hidden checkbox and toggle widgets

https://gerrit.wikimedia.org/r/911805

Change 916921 had a related patch set uploaded (by Func; author: Func):

[mediawiki/core@master] preferences: Use the new DOM element after infusion

https://gerrit.wikimedia.org/r/916921

Change 917732 had a related patch set uploaded (by Func; author: Func):

[mediawiki/core@REL1_40] preferences: Follow-up to commit b2062d11

https://gerrit.wikimedia.org/r/917732

Change 916921 merged by jenkins-bot:

[mediawiki/core@master] preferences: Use the new DOM element after infusion

https://gerrit.wikimedia.org/r/916921

Change 917732 merged by jenkins-bot:

[mediawiki/core@REL1_40] preferences: Follow-up to commit b2062d11

https://gerrit.wikimedia.org/r/917732

Test wiki on Patch demo by SCardenas (WMF) using patch(es) linked to this task was deleted:

https://patchdemo.wmflabs.org/wikis/37917f7ee2/w/