Reading/Web/Desktop Improvements/Features/Loading Vector 2010 scripts
When working on Vector 2022, we wanted to ease the transition from Vector legacy (2010) for communities. To fulfill this, we didn't change how scripts worked. So Vector 2022 would initially:
- load both
MediaWiki:Vector.(css,js)
andMediaWiki:Vector-2022.(css,js)
for sites - load both
User:<username>/vector.(css,js)
andUser:<username>/vector-2022.(css,js)
for users
This meant less work for the communities at the time of changing the default skin for their wikis.
But this was temporary. In early 2024, Vector 2022 will not load any scripts for Vector 2010 on any wiki. Communities, interface administrators, and individual users will need to make some decisions.
It is also possible for communities to request the change to take place sooner.[1] To do that, write on our talk page or create a new task on Phabricator, tagged Wikimedia-Site-requests
, that requests the disabling of VectorShareUserScripts
.
A community may decide to do nothing. But the new behaviour of Vector 2022 will become the default. Delaying action here is likely to cause problems for users.
Examples
[edit]Before | After |
---|---|
Vector 2022 loads both MediaWiki:Vector.css and also MediaWiki:Vector-2022.css .
|
Vector 2022 does not load MediaWiki:Vector.css but instead only MediaWiki:Vector-2022.css .
|
Alice uses Vector 2010 skin, and can load scripts with User:Alice/vector.js and styles with User:Alice/vector.css . They're not affected by the change.
| |
Bob uses Vector 2022 skin, and can load scripts with User:Bob/vector-2022.js and styles with User:Bob/vector-2022.css .
|
Bob can load scripts on Vector 2022 using User:Bob/vector-2022.js and styles using User:Bob/vector-2022.css .
|
In early 2024, users will suddenly see the message "Behaviour after site request". This will mean local site styles would have stopped loading (if those would still be relied on). In consequence, many user scripts will stop loading unexpectedly.
Recommendations
[edit]Communities' decisions
[edit]We recommend that communities:
- discuss this change – please decide if it's preferable for your community to change this configuration earlier than the end of the year,
- if/when your community decides to do so:
- notify any users it might affect, to avoid disruption or confusion,
- use this as an opportunity to encourage housekeeping. E.g. deletion of local skin JS/CSS that is no longer used,
- after making changes to your code, write on our talk page or create a new task on Phabricator, tagged
Wikimedia-Site-requests
, that requests the disabling ofVectorShareUserScripts
. Example: T332809.[2]
Actions for interface administrators
[edit]- CSS: Copy any necessary content from
MediaWiki:Vector.css
intoMediaWiki:Vector-2022.css
. - JavaScript: Migrate any content from
MediaWiki:Vector.js
intoMediaWiki:Common.js
. (NOT duplicating it, because that can cause errors, unless you know what you are doing.) - General cleanup, as needed.
Actions for users
[edit]- CSS: Copy or migrate any necessary content from
User:<username>/vector.css
intoUser:<username>/vector-2022.css
– OR –m:User:<username>/global.css
. - JavaScript: Migrate any content from
User:<username>/vector.js
intoUser:<username>/common.js
– OR –m:User:<username>/global.js
. (NOT duplicating it, because that can cause errors, unless you know what you are doing.)
References
[edit]- ↑ Technically, this may be done by a configuration change to
wgVectorShareUserScripts
. See T301212. - ↑ For details see Requesting wiki configuration changes.