wiki.techinc.nl/tests
Ebrahim Byagowi e1385d3bdf Add {{#dir}} parser function
Template:Dir is one of the most used templates in Wikimedia Commons,
this tries to provide parts of its functionality in hope we can
perhaps simplify or get rid of the template eventually for clarity and
performance reasons.

As a convenience, `{{#dir}}` and `{{#dir:}}` are synonyms for
`{{#dir:{{PAGELANGUAGE}}}}`: they return the direction of the target
language.  For articles, the target language is the content language;
for messages, the target language is the user language.

In addition, to avoid confusion between BCP-47 language codes and
MediaWiki-internal language codes, an optional second parameter can be
supplied.  If the second parameter is the (localizable) string
'bcp47', the language code given in the first parameter will be
treated as a BCP-47 code.  For example: `{{#dir:sr-Cyrl|bcp47}}`.

(See LanguageCode::bcp47ToInternal() for a description of the
differences and overlaps between MediaWiki internal and BCP-47
codes.  These overlaps *so far* don't result in any case where
encouraging editors to be precise about which set of enumerated
string values they are using for consistency with other
language-related functions, and because MediaWiki internally
differentiates between BCP-47 codes and internal codes.)

Bug: T359761
Change-Id: I19c3e91a924e080f37dc95a0d4e61493583b533e
2024-07-19 16:57:48 -04:00
..
api-testing api-testing/action/PageProtection.js: clear state for each test 2024-07-11 09:27:21 +00:00
common content: Improve roundtrip tests for JavaScriptContent 2024-07-05 19:28:14 +01:00
parser Add {{#dir}} parser function 2024-07-19 16:57:48 -04:00
phan rdbms: Create IReadableDatabase::andExpr() / ::orExpr() 2024-07-11 15:29:20 +00:00
phpunit Merge "RealTempUserConfig: Ensure match pattern is available when known" 2024-07-19 16:44:37 +00:00
qunit Replace direct use of $wgRestPath with wfScript() 2024-07-01 22:01:32 +00:00
selenium selenium: Example code for Selenium/Getting Started/Create a simple test 2024-07-17 11:36:43 +02:00
uidesign tests: move uidesign/ to tests/ and fix 404 errors 2024-07-02 13:52:42 +00:00
.htaccess Update Apache config syntax in .htaccess files 2024-03-23 23:36:31 -04:00