Commit graph

838 commits

Author SHA1 Message Date
Mateusz Rybarski e4b28b1691 XW-2444: adding # to color if not provided, formatting 2016-12-28 16:30:24 +01:00
Mateusz Rybarski 8f10a879ca XW-2444: 'use' statements for exceptions 2016-12-28 16:01:15 +01:00
Mateusz Rybarski 11b917d0f7 XW-2444: minor cr remarks 2016-12-28 15:51:33 +01:00
Mateusz Rybarski 2402a0210f XW-2444: cr remarks 2016-12-28 15:18:51 +01:00
Mateusz Rybarski 2498b0111a XW-2444: cr remarks 2016-12-28 15:14:54 +01:00
Mateusz Rybarski 2eaae9de06 XW-2444: unittests for ParserTagController 2016-12-28 14:56:04 +01:00
Mateusz Rybarski 34bea1521f XW-2444: notice fix 2016-12-28 13:55:24 +01:00
Mateusz Rybarski c5c1a2c071 XW-2444: adding tests 2016-12-28 13:36:57 +01:00
Mateusz Rybarski 39ccd95df9 XW-2444: render custom accent colors 2016-12-28 13:10:57 +01:00
Mateusz Rybarski 0db0229550 XW-2444: fixing tests 2016-12-28 12:10:57 +01:00
Mateusz Rybarski 3ad591cec6 Merge branch 'pi-render-service-refactor' into XW-2444 2016-12-28 11:29:36 +01:00
Mateusz Rybarski 9f96ab9f45 XW-2444: unittests for color validation 2016-12-28 10:12:21 +01:00
Mateusz Rybarski c2fc1f2e76 XW-2444: handling case when no color is set 2016-12-28 09:38:27 +01:00
idradm e4736fc79c add empty values check, make sure asJson is run only on mobile, set mobile image width 2016-12-28 09:32:06 +01:00
Mateusz Rybarski 9e89577acf XW-2444: extracting validation from ParserTagController 2016-12-28 09:27:25 +01:00
idradm 39d9302a93 refactor template engine logic to separate class 2016-12-27 15:58:01 +01:00
Mateusz Rybarski 194b8e4e03 XW-2444: error when color is in wrong format 2016-12-27 15:57:14 +01:00
idradm 51e2cbfb18 make mobile renderer service a child of desktop renderer 2016-12-27 15:34:21 +01:00
Mateusz Rybarski d56e77855c XW-2444: trim params value 2016-12-27 15:22:45 +01:00
idradm 36b582a164 refactor render service to skin based services 2016-12-27 15:09:55 +01:00
Mateusz Rybarski 3a3894a1a3 XW-2444: fixing unittests for render service, cleanup 2016-12-27 14:35:48 +01:00
Mateusz Rybarski 1ec85d8594 XW-2444: validating hex color, support for accent-color-text params 2016-12-27 13:50:53 +01:00
Mateusz Rybarski be71d1b0f4 XW-2444: accent-color param without validation 2016-12-27 12:10:11 +01:00
Damian Jozwiak 4acf41caef XW-2307 | Whitelist videos in Portable Infoboxes 2016-11-22 13:02:56 +01:00
Weronika Rudnicka c9363473b2 XW-2307 | mocking getMediaType method in custom width logic test 2016-11-21 23:17:32 +01:00
Weronika Rudnicka 8d055fb35c XW-2307 | fixed whitespaces, using getMediaType method 2016-11-21 23:15:51 +01:00
Weronika Rudnicka 33210522f2 XW-2307 | in infobox only image files are displayed 2016-11-21 15:13:13 +01:00
idradm 3e586523e4 XW-2278 fix wikitext lists after variables were replaced 2016-11-14 11:24:44 +01:00
Weronika Rudnicka 0fd6074159 Merge pull request #11770 from Wikia/XW-2277
XW-2277 | Replace image links in PI on Monobook with File page URLs
2016-11-04 13:27:38 +01:00
Igor Rogatty 7a9a95b81c XW-2277 | cancel the change if there is no data-image-key 2016-11-04 13:14:34 +01:00
Igor Rogatty 3dee529ca8 XW-2277 | data-image-key is already encoded with urlencode() 2016-11-04 13:00:41 +01:00
Igor Rogatty bcc409483a XW-2277 | use wgArticlePath 2016-11-03 16:56:35 +01:00
Igor Rogatty 7d505ab62f XW-2277 | replace link only on click 2016-11-03 16:11:23 +01:00
Damian Jozwiak d4a9943eaf XW-2234 | Fix testRenderInfobox unit test 2016-11-03 15:40:21 +01:00
Damian Jozwiak 6e1a075cad XW-2234 | Fix testCustomWidthLogic unit test 2016-11-03 15:32:16 +01:00
Weronika Rudnicka 89ba74b37e XW-2234 | displaying better quality images for retina for infoboxes image collections 2016-11-03 15:04:37 +01:00
Igor Rogatty e0394adb61 XW-2277 | replace image links in PI on Monobook with File page URLs 2016-11-03 14:44:29 +01:00
Weronika Rudnicka ee7404ef6b XW-2234 | added srcset to infobox image, to display better quality images for retina 2016-11-03 14:27:43 +01:00
macbre a444abc707 Revert "PortableInfoboxRenderServiceTest: temporarily skip testRenderInfobox"
This reverts commit 63ba16643458ce39f61050acc4259156cfb35305.
2016-06-27 12:19:13 +02:00
macbre 4f5e9462dc PortableInfoboxRenderServiceTest: temporarily skip testRenderInfobox 2016-06-24 10:23:45 +02:00
grunny 36f77e2a8d Add comment explaining where the Mercury PI replacements occur 2016-06-20 18:24:38 +10:00
grunny c006c42035 (CE-3844) Refactor fix for PI and parser tag fix
A security fix from MW core added quotes to the Parser's strip tag
markers in order to prevent an XSS vulnerability. When this was deployed
PIs and our Wikia tag extensions broke in Mercury because ArticlesAsJson
JSON encodes the parser output in the ParserAfterTidy, but then PI and
the tag extensions were manually replacing the Parser tag strip markers
on the already JSON encoded string within their own ParserAfterTidy methods
(which were always run after the ArticlesAsJson method). This meant that the
strip marker had the quote escaped with a backslash in the encoded string,
so the string replacements failed.

This change follows the previous quick and dirty fix by moving the replacements
in PI and the tag extensions to just before ArticlesAsJson encodes the output.
Which also removes the need from before the fix in #10701 to JSON encode the
parser output of the tags that will be replaced into the text.
2016-06-17 20:57:12 +10:00
grunny 61bdc6e652 (DAT-4494) Only decode when it's the main JSON array 2016-06-17 04:14:47 +10:00
grunny ddd6c61e79 (DAT-4494) We don't need to json encode here anymore 2016-06-17 03:59:52 +10:00
grunny e191fbd396 Fix unit tests 2016-06-17 03:52:32 +10:00
grunny 899b127b00 (DAT-4494) Don't perform replacements on JSON encoded content 2016-06-16 17:39:06 +00:00
grunny 8186618eb9 (DAT-4494) Fix galleries and tabber in PortableInfoboxes 2016-06-16 16:59:48 +00:00
Warkot 10f96eaa96 XW-1478 | extendImageData has to be run even for the first PI 2016-05-31 00:20:39 +02:00
Warkot 1fa29ea03b XW-1478 | don't render the whole hero module including the title on Mercury 2016-05-30 21:30:25 +02:00
Warkot 908327db5d XW-1478 | don't render hero image in first infobox on Mercury 2016-05-30 18:35:11 +02:00