Commit graph

11 commits

Author SHA1 Message Date
Jan Drewniak 816bda69c5 Replace pageterms with description API
Bug: T190953
Change-Id: Ia188a7bdc4d3533d6ee0e9bb06fa62da4b759c66
2018-04-13 10:02:14 +02:00
Ed Sanders 10de1deaf4 build: Update eslint and stylelint
Change-Id: I82bfb5fbfea4997f3048305574d2ff7d28ecd1b8
2017-10-09 15:37:28 +01:00
jdlrobson 9b75e0b372 Hygiene: Remove unnecessary variable
Improves readability...

Change-Id: Ib0e9cbc083e6c0a384c81815b470063698e0595f
2017-07-14 16:15:35 -07:00
jdlrobson 9126c7d0ef Make number of RelatedArticles configurable
Wikivoyage pages have more than 3 related articles as they make use
of the {{#related:}}  magic word.

After speaking with Nirzar we should allow this project to show more than 3.
This change allows this while keeping the existing behaviour on other wikis and
will pave the way for removing a bunch of code from this extension.

Additional changes:
* Cleanup skinStyles definitions
* Limit cards to 30% maximum width and give margin top to account for
situations where the number of cards are multiple of 3
** In Minerva hardcode the max-width to pixels.
* Margins are switched from hardcoded 10px to percentage based. Yes
this changes the right margin slightly but is more maintable and visually
the same.

Bug: T164765
Change-Id: I41119de3228c2df799f740d4bd00082101c21b97
2017-07-06 11:17:47 -07:00
jdlrobson 298790a944 Upgrade to eslint
We're going to want to use a newer version of JSHint
anyway to support use of ES6 in our browser tests so now
seems a good time to do this.

Bug: T149202
Change-Id: I5526b020cfc12c0e065ad15ed711a0e3a7bff1bc
2017-04-10 14:12:25 +02:00
Sam Smith 8b8db66dd1 Cache "morelike" requests for all users
In order to minimize loading time of RA for as many users as possible,
we need to maximize the number of users that can be served by our edge
caches.

Currently, if you're logged in, then the API uses your language by
default and so responses are always private, i.e. they shouldn't be
cached by a shared cache and can be cached by the browser.

By requesting that the response be in the language of the content, the
API ignores your language and responses become public, i.e. they can be
cached in a shared cache and can be cached by the browser.

Changes:
* Add the `uselang=content` parameter to the morelike request
* Add the `maxage=86400` parameter to the morelike request, allowing the
  browser to cache the response for 24 hours, which'll save the device
  even making the request

Bug: T126455
Change-Id: I6216a088d865f27f7cc3725fc311191da42a27ba
2016-09-05 11:33:12 +01:00
Baha 8afb02b64a Cache morelike requrests
The cache length is 24 hours.

Bug: T126455
Change-Id: Icd328f70ced16cc43fc0ad62c8a1f49ce71d6369
2016-08-29 15:54:53 -04:00
Baha 9ca3eb6dda Use 'classic_noboostlinks' search profile
Bug: T141398
Change-Id: I0db2d21fe9e4735e27af6071b2190a5829477278
2016-08-29 15:38:09 -04:00
jhobs 40dc624620 Temporary fix for blurry images
Request double the size until pithumbmode is implemented.

Bug: T123549
Change-Id: I773c5a1a68c73f1ed721b1acc729db3d51b8b661
2016-04-11 21:36:06 +00:00
Paladox 8a73239abf Update packages
Update grunt-jscs to 2.4.0

Update grunt-jsonlint to 1.0.6

Change-Id: I34b1f23469a35e64345ee42a183dd74679e50b81
2015-12-07 21:00:56 +00:00
Baha 8cf9b60ab5 Make RelatedArticles soft-depend on Cards
RelatedArticles tries to load the 'ext.cards' module and if
it succeeds it continues with showing the related articles
on the page.

Dependency: I6661527175eb889cec4193b18fa18207f332b4fc
Bug: T117108
Change-Id: I33936a3e9cd5d1f0296e48fd1c2bba77fff4e466
2015-11-18 22:22:10 +05:00