Page MenuHomePhabricator

Vector-2022.js should no longer load legacy Vector site and user scripts/styles
Open, Needs TriagePublicBUG REPORT

Description

As part of the splitting of the Vector skins, here was a product requirement to minimize impact on communities.

To fulfil this the new modern Vector skin:

  • loads both MediaWiki:Vector.(css,js) and MediaWiki:Vector-2022.(css,js)
  • loads both User:<username>/Vector.(css,js) and User:<username>/Vector-2022.(css,js)

At some point, when we're reading we'll want to change this behaviour using the following plan:

Plan

  • A configuration flag will be added to Vector to disable the site styles/scripts behaviour. Communities can request to disable it, when they are ready. When enabled Vector 2022 will not load either JS or CSS. This is a good opportunity for communities to do some housekeeping, e.g. moving styles to TemplateStyles and scripts to gadgets.
  • A User-notice will be sent out to communities. Users using modern Vector will be instructed to delete/blank their user vector.(js|css) in preparation for the change.
  • We'll remove the Vector user module behaviour when we feel like sufficient time has elapsed sending another user notice to notify users that during the week if they've not done anything and they are using the Vector 2022 skin their user style/scripts will stop working.

Event Timeline

Jdlrobson renamed this task from Vector-22.js should no longer load Vector.js to Vector-22.js should no longer load legacy Vector site and user scripts/styles.Feb 8 2022, 12:09 AM
Nux renamed this task from Vector-22.js should no longer load legacy Vector site and user scripts/styles to Vector-2022.js should no longer load legacy Vector site and user scripts/styles.Feb 9 2022, 2:54 PM
Nux updated the task description. (Show Details)

I've checked that 2022 is loaded https://pl.wikipedia.org/wiki/MediaWiki:Vector-2022.js

Could you clarify this point?

A configuration flag will be added to Vector to disable the site styles/scripts behaviour. Communities can request to disable it, when they are ready. When enabled Vector 2022 will not load either JS or CSS. This is a good opportunity for communities to do some housekeeping, e.g. moving styles to TemplateStyles and scripts to gadgets.

  1. Do I understand correctly that the flag will be enabled by default? (and disabled on demand)... Or the other way around?
  2. Will enabling the flag will make new Vector not to load anything (so no Vector.css and no Vector-2022.css etc) or will it just load Vector-2022.css (and not Vector.css)?
  3. Common.css will be loaded, we are talking about Vector.css/js only, right?

I understand that it would be nice to have everything in gadgets/styles.css, but I don't think this is something feasible to do in a day nor probably in a month for big wikis 😉. That have to be done more gradually. Not sure if an intentional disruption would be a good thing. I mean there might be some angry people after that change 😉

Do I understand correctly that the flag will be enabled by default? (and disabled on demand)... Or the other way around?

The flag when added will retain the existing behaviour of loading both Vector.css and Vector-2022.css

Will enabling the flag will make new Vector not to load anything (so no Vector.css and no Vector-2022.css etc) or will it just load Vector-2022.css (and not Vector.css)?

After enabling the flag:

  • Vector skin will load Vector.css and Common.css
  • Vector-2022 will load Vector-2022.css, Common.css but NOT Vector.css

Common.css will be loaded, we are talking about Vector.css/js only, right?

Common.css loads on all desktop skins and will continue to do so.

Will this also change the similar behavior of User:Username/vector.xxx loading for users with vector-2022 skinned (meaning they will need to fork or migrate their userscripts to user:username/vector-2022.xxx)?

There's no exact implementation/migration plan yet, but the proposal on the table would be to allow one wiki page to control one skin. This might mean introducing User:Username/vector-legacy.(css|js) for example or a breaking change that stops vector-2022 loading User:Username/vector.(css|js)