Page MenuHomePhabricator

Lexemes in Ottoman Turkish (ota) tagged as ltr text on special pages
Closed, ResolvedPublic

Description

When https://www.wikidata.org/wiki/Lexeme:L18649 is shown on special pages such as Special:RecentChanges and Special:Contributions (e.g. here), the HTML contains <span class="mw-content-ltr" dir="ltr" lang="ota">قوقوروز</span>. Ottoman Turkish is written in the Arabic script, so it should be tagged as rtl, not ltr.

Arabic itself is correctly tagged as rtl, so it seems to be a problem with Ottoman Turkish specifically. The language-data database knows that ota uses the Arabic script. Perhaps it's caused by ota being one of the languages added for Wikidata via wmgExtraLanguageNames in InitialiseSettings.php?

Event Timeline

Yeah, the reproduction link now shows:

<span class="mw-content-rtl" dir="rtl" lang="ota">قوقوروز</span>

In principle, the general issue remains – if there’s a language only in $wmgExtraLanguageNames but without a MessagesXxx.php file, then MediaWiki doesn’t know whether it’s LTR or RTL yet. But the change Amir linked above should’ve fixed that for several RTL languages, so I think we can close this task for now. (IIRC there was also some other task for adding this kind of information to MediaWiki in general but I don’t think I could find it again.)