Page MenuHomePhabricator

OOUI block form should be visible if JS is not enabled (expanding multiblock functionality to old block form)
Open, Needs TriagePublicFeature

Description

Feature summary (what you would like to be able to do and where):

Since the new block form uses Codex, and Codex appears to require JavaScript at this time, if JavaScript is not enabled, and both $wgUseCodexSpecialBlock = true; and $wgEnableMultiBlocks = true; are present on LocalSettings.php the block form is unusable. Likewise, if $wgUseCodexSpecialBlock = false; (the feature flag which will eventually be removed) then it is impossible to issue multiblocks.

image.png (1,585×383 px, 43 KB)

The old OOUI block form should continue to be available and should also support multiblocks without Codex. This could be done by adding a list of all active blocks with their block IDs to Special:Block and Special:Unblock when Codex is not enabled, and allowing a user to select a block when blocking or unblocking.

On Special:Block, we can provide a warning that a new block will be created unless if a block ID is specified in the username field, in which case the block will be modified instead. On Special:Unblock, we can provide a warning that typing a username into the unblock field will remove ALL blocks associated with that user, while typing a block ID will remove only the block associated with that block ID.

Use case(s) (list the steps that you performed to discover that problem, and describe the actual underlying problem which you want to solve. Do not describe only a solution):

  1. I disable JavaScript.
  2. I visit Special:Block or Special:Unblock.
  3. I get the above notice that JavaScript is required.

Benefits (why should this be implemented?):

The benefit is to provide a way to use the block form when JavaScript is not enabled or supported. For example one may want to disable JavaScript when editing from a low end machine for improved browser performance.

Event Timeline

JJMC89 subscribed.

This is likely not worth the dev time it would take. T404524: Codex Special:Block should support no-Javascript environments is the better alternative.

If it is not going to be significant dev time, then maybe it is worth it (until Codex can support environments that do not support JS) until the task mentioned is completed.

Otherwise I am okay with merging.

Change #1222015 had a related patch set uploaded (by Awesome Aasim; author: Awesome Aasim):

[mediawiki/core@master] [WIP/Proof of Concept] blocks: Add multiblock support to fallback OOUI form

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

I did get the ball rolling a little bit. I do think it is a good temporary solution, but I do think there will be some major blockers given I was very sleep deprived and thus working a bit more sluggishly than other days.

As a proof of concept here is a clip:

Yeah there are still some problems but at least you get an idea of how the form is supposed to behave