Current provider is going away. Switching to another free provider.
Implemented caching with a cookie for speed and to avoid generating
unnecessary load on the service.
Bug: T143542
Change-Id: I191d69a6fb8abe9556f475dfef1368dc9f96b846
Consistently with getInterlanguageList(). Without this 'nds-NL'
will be handled incorrectly when the article in it is featured.
Bug: T143527
Change-Id: Ie7fe5a270cb3030899b6034512351d5d66d7be06
Enable several of the ULS modules so they can be used in a mobile context,
in particular by the Translate Extension
Changes:
* Create a ext.uls.common module that can be loaded safely on mobile
* Only add the ext.uls.init entry point module on desktop (ensured by
the use of targets). On mobile it has no impact other than to increase
the amount of bytes shipped to users.
* Note various modules have not been enabled for mobile usage.
Bug: T102922
Change-Id: If2808886f0bfa153f5918e3c7536e88641028da9
This doesn't appear to be justified due to the one use case. This
will now be done via OOjs UI and given jquery.tipsy is deprecated
it is better to replace it (T117720).
Bug: T119417
Bug: T102922
Change-Id: I60cce248884308bf0728d153f6137a8d25e01300
* Remove scrolling from positioning code
* Make sure that any calculated default positions also apply to
* modules by updating this.top and this.left.
Bug: T143074
Change-Id: Iffc49674abcca8a8c4a600569a05db1314fae3f6
This is just a simple search for elements with lang attribute.
This will be executed only when previous languages, geo-IP based languages,
browser, UI, content languages etc. are not filling the defined compact size.
Bug: T70077
Change-Id: I77d1efa5e29deeaaf595753fb5519c8b70c7f2b5
So that it is loaded for compact language links. The ext.mediawiki.uls
module is starting to look very empty now can could be removed easily
in follow-up. ext.uls.init depends on jquery.uls.data so this is safe.
Bug: T139949
Change-Id: Icac10f073e122284723c48782c2a1cf7f10b45ec
Not outputting language codes with proper casing should
be solved upstream in jquery.uls.
Bug: T139795
Change-Id: Ide81c76135b23a031f1f09a33462e767e57a50b0
We were executing all compacting strategies even when we have
more than enough items as candidates. If the strategy is expensive,
(performance wise) this is a problem.
In this commit, we execute them one by one and stop when we have enough
candidates.
The methods in CompactInterlanguageList class also arranged as
individual function declarations than comma seperated method list.
Change-Id: Idce6489387d139852125f4448d0e192f6a7e1353
Let them assume normal size with regular padding. In the case that
the buttons do not fit one line, some will overflow to the second
line. In my opinion that looks less ugly than irregular padding
and truncated language names.
Bug: T136273
Change-Id: I26dd7745ac03e1b940348b318d74d0a2bd27e1a3
IE9+ which is lowest that MediaWiki still supports is supposed to
support both ttf and woff par some exceptions.
This reduces uncompressed repo size almost 4000 bytes.
Change-Id: If80f4ec898d86d5fd4cf873d0d86245e66da2f0b
Now that Compact Language Links also started to add to this list, ULS would
show incorrect language change tooltip notifications. ULS interface language
selection will still keep updating the list of previously selected languages.
Refactored the code a bit: 1) created minimal Store that wraps around plain
localStorage, since mediawiki.storage cannot be used yet. 2) Inlined the
userHasChangedLanguage function to new initTooltip function. 3) Split parts
of the huge initInterface to new initTooltip and initIme functions for
increased readability. 4) Solved a TODO for moving language change recording
out of the tooltip showing code.
Change-Id: If8478a59168d89264f4d46938ac865c0c9a04f25
This is already expected by the callers. Added addPreviousLanguage
to make updating the list easier.
Change-Id: Ie4f888235ea4de4a2ce6bf5a9f24955e423e8c48
The benefit of this is that '/' is no longer escaped, making
ext.uls.webfonts.repository.js file 376 bytes smaller. I expect
that the difference in compressed size is neglible.
Change-Id: I77c0b88fa23f2245f09615c354546b6a9ebf650c
This is now new standard way of doing this in MediaWiki.
Since this makes the font repo bit longer, compensated by no
longer providing version information, which also simplifies the code.
Uncompressed increase is 542 bytes.
Depends on https://github.com/wikimedia/jquery.webfonts/pull/45
Bug: T135806
Change-Id: I1921115fc1abc20e6e756044c0a84a9fe4133884
jquery.uls.compact module is kept for now as some other
extensions depend on it. But it does not do anything
anymore.
There are some styles which should be in jquery.uls
upstream, but given the current state that is easiest
done in a follow-up later.
The main change is that language selection is now
compact by default: no heading etc.
Includes style changes for the dialogs, and especially
for the new position of the callout caret.
Bug: T85519
Change-Id: Iade8005439b4f58ab241752f69a5365d8bb88d2c
Load jquery.uls only when the trigger is clicked.
Reduces the initial footprint by 63.9 KB (uncompressed)
Bug: T135210
Change-Id: I972cb6ea1794485917ea530f7abe68bdddc2014f
Modern browsers will use woff2, which has smaller size than woff
Updated the README in the font repository explaining how different
file formats are produced.
Bug: T128291
Change-Id: I81c5380fdbf0ff76142b67cf8fce9db20e8164fa
It re-triggers mw.uls.getFrequentLanguageList(),
getPreviousLanguages() and localstorage read.
In this patch the result was saved and reused.
Bug: T122341
Change-Id: I14839eb611cd3e995e8d8ab729ee3f714840f9ad