HomePhabricator

Introduce TRANSLATABLEPAGE magic word

Description

Introduce TRANSLATABLEPAGE magic word

This variable magic word returns the title of the translatable (source)
page on translatable and translation pages, and an empty string
otherwise. Examples:

  • On Fréttinga (a translatable page), it returns Fréttinga
  • On Fréttinga/fr, it also returns Fréttinga
  • On Main Page (a not translatable page), it returns an empty string.

Although the use cases listed in the Phabricator task don’t require
this, it’s also possible to distinguish between translatable and
translation pages:

{{#switch:{{TRANSLATABLEPAGE}}
|=not translatable
|{{FULLPAGENAME}}=translatable page
|#default=translation page
}}

Similarly to <languages/>, a page counts as translatable after being
marked for translation, translation markup alone doesn’t make it
translatable.

Bug: T290239
Change-Id: I90302af408e9320f77a5c07b95f19ee6bdd473cd

Details

Provenance
TacsipacsiAuthored on Apr 30 2023, 5:34 PM
jenkins-botCommitted on May 8 2023, 10:05 AM
Parents
rETRA3476ec6aa13c: Localisation updates from https://translatewiki.net.
Branches
Unknown
Tags
Unknown
References
wmf/1.41.0-wmf.8
ChangeId
I90302af408e9320f77a5c07b95f19ee6bdd473cd

Event Timeline