Currently the Codex styles markup is only guaranteed to be loaded on Vector 2022 and Minerva. Several templates rely on behaviour defined here: https://phabricator.wikimedia.org/source/mediawiki/browse/master/includes/skins/Skin.php;6ddbd53edad0$467
To support migrations described in T346468: DEPRECATION: MediaWiki UI modules are to be replaced with Codex CSS components (gadgets) we should make Codex search styles load in the same way that mediawiki ui does - in that if button markup is detected in the article content we load the module in other skins e.g. Monobook,Timeless. Modern, CologneBlue and Vector.
Note we have a decision to make here to either officially support this behaviour for wiki-based code or encourage templates to move away from this behaviour given the existing inline comment that this behaviour was deprecated in 1.26 but that only refers to ResourceLoader based modules so doesn't seem to have considered the wiki-based code use case.
// Deprecated since 1.26: Unconditional loading of mediawiki.ui.button // on every page is deprecated. Express a dependency instead. if ( strpos( $out->getHTML(), 'mw-ui-button' ) !== false ) { $modules['styles']['content'][] = 'mediawiki.ui.button'; }
TODO
- Determine if codex-search-styles and use of CSS component markup by Codex is supported
- If it's not supported determine alternative proposal for community to migrate away.
Sign off
- Communicate to tech news