Page MenuHomePhabricator

Translate extension should remove references to the "legacy" Codex design tokens file
Open, Needs TriagePublic

Description

The Translate extension contains a couple of references to theme-wikimedia-ui-legacy.less from the @wikimedia/codex-design-tokens package. It looks like this file (or at least some of the tokens that it contains) is being vendored into the Translate extension source code.

Recent versions of Codex have eliminated all differences between theme-wikimedia-ui-legacy.less and the default theme-wikimedia-ui.less file. We are in the process of removing all traces of the "legacy" set of tokens from Codex (see T360806).

For the time being, Codex will continue to produce a copy of the main theme-wikimedia-ui.less design tokens file under the old "legacy" name, for backwards compatibility purposes. However, this file will eventually be removed (probably at the same time we do an official Codex 2.0 release).

The Translate extension front-end code should be updated to remove these references in favor of the standard theme-wikimedia-ui.less file.

Event Timeline

Same as in T363762: per the MediaWiki Language Extension Bundle support policy, Translate needs to support the last two MediaWiki releases, which are 1.40 and 1.41 currently (1.42 has been branched but not released yet).

Same as in T363762: per the MediaWiki Language Extension Bundle support policy, Translate needs to support the last two MediaWiki releases, which are 1.40 and 1.41 currently (1.42 has been branched but not released yet).

I think that the Translate extension currently vendors some of the Codex design tokens directly into its codebase. This approach may continue to be necessary for a while in order to provide the desired level of backwards compatibility. The best approach may be to vendor a more recent version (and use the non-legacy tokens file).