This card's purpose is to find a way to import 'wikimedia-ui-base.less' in projects that use it (skins, extensions).
Former stalled approach: T123359: Provide WikimediaUI Base's tokens in Wikimedia Design Style Guide following skins
The problem
- @import 'wikimedia-ui-base' cannot be used in skins and extensions (it's imported to some extensions using OOUI, though)
- WMUI Base is not specific to OOUI
Status quo
Currently, there's a copy of wikimedia-ui-base.less in core in the 'ooui' library.
Related task: T176964: Upstream font stack to wikimedia-ui-base
Patch that added it: https://gerrit.wikimedia.org/r/c/mediawiki/core/+/372904
There's a task that updates it: resources/lib/foreign-resources.yaml
Worth considering
Questions
- Should we split 'wikimedia-ui-base' from OOUI in core/src/lib/ ? Patch 579858
- This requires updating the ooui import path in 'resources/Resources.php'.
- And the updater in foreign-resources.yaml.
Current solution
Patch 573403 resources: Enable importing 'wikimedia-ui-base.less' in skins, extensions
Can be used directly by: @import 'mediawiki.theme/wikimedia-ui-base';
However, the preferred way to use it is: @import 'mediawiki.theme/variables';
which imports the active skin's theme variables.