Commit graph

5213 commits

Author SHA1 Message Date
jenkins-bot 23eb869d9d Merge "Get rid of ?venotify= from URL post-save" 2016-10-14 23:30:16 +00:00
Alex Monk b5815e9ffd Send RB errors through the normal error handling process
Change-Id: I230ff6d3c9a6a183fb483f5adfd7ccdc025a07af
2016-10-14 11:17:56 -07:00
Alex Monk 39aa3021a7 Switch to the wikitext editor if VE fails to load
Also kill some dead HACK code in DesktopWikitextArticleTarget#switchToWikitextEditor

Bug: T135748
Change-Id: Ie5aaa0f3c3bd20755abaac9b86af015b71eb777b
2016-10-14 18:15:16 +00:00
jenkins-bot a9240d6f2f Merge "Strip RESTBase IDs from HTML generated when wikitext is pasted" 2016-10-14 00:55:48 +00:00
Alex Monk 25933c09ec Strip RESTBase IDs from HTML generated when wikitext is pasted
Bug: T146054
Change-Id: I0013673a9e41ea191ea64f3208a06288efb2ecd3
2016-10-13 17:42:11 -07:00
jenkins-bot 246e2ebb4e Merge "Tidy up DAT load failure handling" 2016-10-14 00:32:30 +00:00
jenkins-bot 414a333b5e Merge "Update VE core submodule to master (90cbd62)" 2016-10-14 00:20:55 +00:00
Ed Sanders e1e02fa0d8 Update VE core submodule to master (90cbd62)
New changes:
abf8f41 Replace Array#concat with Array#push in converter
02aeb90 Localisation updates from https://translatewiki.net.
902ddda Use safer batchPush in converter
6368191 Use current surface's sequence registry in command help dialog
f7ce4b9 Optimize batchPush on small lists
fb43a0a ve.batchPush: add unit test to exercise long-array path
d6c7d24 Factor out RESTBase ID regular expression
ffcbf4b IndentationCommand: Use hasMatchingAncestor
d447023 Allow ommission of range from ve.dm.Document cloneFromRange
cfbc344 Don't strip empty paragraphs on paste if they are generated
01c918b Localisation updates from https://translatewiki.net.
1467947 Fix documentation of getMetadataIdRegExp

Local changes:
* Define RESTBase ID pattern in platform and fix slightly
* Bring in paste test from core, which requires platform switching.

Bug: T147607
Depends-On: Ifc1c15872a50f915e5ef8d561b3a363dc5f4d28f
Change-Id: I3eb21e115de92a67afa85b5675fcbca5b111adb6
2016-10-13 17:10:33 -07:00
Ed Sanders 85f8030053 MWMediaSearchWidget: Fix indentation in var
It is alarming that jscs is not picking this up..

Change-Id: Ibd3b113ebfedede9fa45120c24f00623ec5ea2fb
2016-10-13 23:45:37 +00:00
jenkins-bot 684b490597 Merge "More NWE-SET integration fixes" 2016-10-13 22:12:18 +00:00
jenkins-bot 2ea26a205b Merge "Take only the last part of a URL query in media search widget" 2016-10-13 22:04:13 +00:00
jenkins-bot e55c822817 Merge "Fix typo in DAT.init.js" 2016-10-13 22:04:12 +00:00
Thalia 7ec7acf108 Take only the last part of a URL query in media search widget
Quick fix to the problem that searching for the file name or
page title currently returns the image, but searching for the
URL does not.

Bug: T121354
Change-Id: I13e665226e5dc15ba626126dc4806ce8f4e0040b
2016-10-13 21:54:10 +00:00
Alex Monk 70bf00e9b0 More NWE-SET integration fixes
Also stop calling $skin->getUser() so much, store the result

Change-Id: Ic91a660bc4b97a82f1d2b0bffb55425564696da1
2016-10-13 22:46:16 +01:00
Alex Monk 49283f7250 Fix typo in DAT.init.js
Change-Id: I75f7de16ea06d62a1bdfa0e04294fef5560fd5c9
2016-10-13 22:22:57 +01:00
Translation updater bot 9939a68db2 Localisation updates from https://translatewiki.net.
Change-Id: Ida7e81c4c8b762f36c338ccf874205ff50ed37a3
2016-10-13 22:55:14 +02:00
Alex Monk 6b87b2671e Fix another case where we need to pass the section
Bug: T144654
Change-Id: I5f91b9329525ceaeb971d02f93c959d908d748f7
2016-10-13 20:28:21 +01:00
jenkins-bot 56c5ecb0f1 Merge "Fix sanitizing of query value in media search" 2016-10-13 04:14:10 +00:00
Ed Sanders 972094788c Fix sanitizing of query value in media search
Always use #getQueryValue which trims whitespace, so we
don't pass whitespace to the API.

Also rename some variables for clarity, and remove some
unused arguments.

Change-Id: I0d27f59488295bc1c398d0fd287e3e16a3f5aaec
2016-10-13 04:03:57 +00:00
jenkins-bot d20040aec0 Merge "Section editing in NWE" 2016-10-13 01:51:56 +00:00
jenkins-bot 12d63b17c0 Merge "Set gallery dialog to larger size when search panel is focused" 2016-10-13 00:52:10 +00:00
jenkins-bot 78df357278 Merge "mw.LinkCache: Links aren't missing if they're known" 2016-10-13 00:52:09 +00:00
Thalia 91ca88f6e8 Set gallery dialog to larger size when search panel is focused
Bug: T145246
Change-Id: I49b218f704d31b4f699fe39f414a84abbfffc093
2016-10-12 17:42:54 -07:00
James D. Forrester 0a3dbfb621 mw.LinkCache: Links aren't missing if they're known
Thanks to new sparkly API data.

Bug: T72123
Change-Id: I9d4ff14bb2e81404224819c9153a7b8d86ca6f11
2016-10-12 17:21:58 -07:00
Ed Sanders 4040442ad8 Section editing in NWE
Bug: T144654
Change-Id: Ida6e721e0d980b47e3fda6a1f0744cbce1b2235a
2016-10-12 12:55:11 -07:00
Kunal Mehta 6c93a49244 Get rid of ?venotify= from URL post-save
Use history.replaceState if available to get rid of the venotify query
parameter to avoid polluting URLs.

Ideally this would just use a cookie like the core post-edit
notification.

Change-Id: I6ce142012053e2fc18dd44fd0f7b82914acea076
2016-10-12 11:05:12 -07:00
jenkins-bot 9694ef6e63 Merge "Follow-up I9547dfd: Only enable VE tabs if VE is available" 2016-10-11 21:32:37 +00:00
Ed Sanders 4fc2904a87 Follow-up I9547dfd: Only enable VE tabs if VE is available
Otherwise VE is launched on namespaces where it is disabled
(but NWE is enabled).

Bug: T147890
Change-Id: I62f4ff96b991553a4eb0be9efb2e84bc80ca2bb4
2016-10-11 14:19:36 -07:00
Translation updater bot 0f7c0972f5 Localisation updates from https://translatewiki.net.
Change-Id: Ic768923084efb9d251d6229d8e87ee38aa62918c
2016-10-11 22:51:06 +02:00
jenkins-bot 00af103293 Merge "Fix detection of headings in NWE format menu" 2016-10-10 22:46:46 +00:00
Translation updater bot 913a1a943e Localisation updates from https://translatewiki.net.
Change-Id: I4c889135c1b62c4d7a7b60342f750b73623c876b
2016-10-10 22:29:24 +02:00
Translation updater bot 5b5249c77b Localisation updates from https://translatewiki.net.
Change-Id: Iacab38668920ea1e26b209bedd16910985a8b0ff
2016-10-09 22:58:22 +02:00
jenkins-bot eafbe8cf8c Merge "Add big/small support to NWE" 2016-10-08 21:00:35 +00:00
Ed Sanders 3d39b80991 Fix detection of headings in NWE format menu
Use regex to include match any character after '='.

Bug: T147585
Change-Id: I22228bedf497613506a676eca465d3bc7bc5fe67
2016-10-08 20:53:58 +00:00
Ebrahim Byagowi e55d1b2a3c i18n: Native digits on 'visualeditor-editnotices-tool'
Change-Id: I5a802199a9d736d0082775052d5224cfa9580450
2016-10-08 18:36:36 +00:00
Ed Sanders 2ad4015775 Add big/small support to NWE
Change-Id: Id42cb7563d7f6d14d0f225edb8a283c8b9eaa8db
2016-10-07 22:44:52 -04:00
jenkins-bot 800dceaa0e Merge "Hid category links in source edit mode" 2016-10-07 22:08:30 +00:00
Ed Sanders 605f7b625b Hid category links in source edit mode
Change-Id: Ib44e393d3a8d070a4ced002a11cb26f58447e67c
2016-10-07 16:24:23 -04:00
Ed Sanders 31a3f2f0b6 Move editfont class down to surface view, so it doesn't break DebugBar
Change-Id: I779ab9d581af37ae104acf4ea6a83b86504bb257
2016-10-07 16:10:58 -04:00
jenkins-bot 7551b0e788 Merge "Use createTextNode in wikitext converter" 2016-10-06 23:20:21 +00:00
Ed Sanders 01ed8e954e Use createTextNode in wikitext converter
Has better browser support. innerText is for getting the
text as rendered.

Bug: T147584
Change-Id: Ie2cf732d537aa4053d5b45d85c2d678a0d338017
2016-10-06 14:50:08 -04:00
Ed Sanders aa7da97f2d Use safer batchPush in converter
Some older browsers may fail with >1024 arguments. This
does not have a noticeable effect on performance.

Change-Id: I8c85f43425997735bbbe08d27374b79502e02ecf
2016-10-06 13:19:00 -04:00
Alex Monk d2dd3689cf Tidy up DAT load failure handling
Get rid of the 504 Gateway Timeout handling while we're here, in preparation
for bug T135748 where that kind of thing will be made normal.

Change-Id: Ia4abb1a68ff7ab7ff365c7348bf4d2ad35c43a27
2016-10-06 00:52:28 +01:00
jenkins-bot c8f3474f3d Merge "Fix styling of categories now they are editable" 2016-10-05 21:33:49 +00:00
Translation updater bot bbac9dad9f Localisation updates from https://translatewiki.net.
Change-Id: I3eec08b6d83c2338fda9d5b7cff84f99e16f59e1
2016-10-05 22:46:35 +02:00
jenkins-bot 1321452197 Merge "New wikitext editor: unwrap lists when changing style" 2016-10-05 19:40:01 +00:00
jenkins-bot 6604a6a3a9 Merge "Use a proper error message when VE fails to load due to not being able to connect" 2016-10-05 18:29:28 +00:00
jenkins-bot 80596f9f22 Merge "Disable switch-to-VE button in NWE if VE is unavailable, don't hide it" 2016-10-05 18:29:26 +00:00
jenkins-bot eae2305269 Merge "Allow NWE on non-VE namespaces" 2016-10-05 18:22:56 +00:00
jenkins-bot 31a7c96a38 Merge "Use a streamlined 'converter' in wikitext mode" 2016-10-05 16:53:43 +00:00
jenkins-bot d5d8223244 Merge "Allow users who haven't enabled NWE in their preferences to use veaction=editsource" 2016-10-05 16:51:34 +00:00
Ed Sanders a0dd888485 Use a streamlined 'converter' in wikitext mode
Converting a document we know contains just plain text paragraphs
is slower than it needs to be. The speeds up the conversion of
[[Barack Obama]] from ~2000ms to <100ms.

Change-Id: I2081858d835286b48db0627696a9eb5294317c2e
2016-10-05 16:40:28 +00:00
Alex Monk f860bd0d36 Use a proper error message when VE fails to load due to not being able to connect
Not just 'HTTP 0'

Change-Id: Icd1b5b64ca8ea4af80e3cf32f8502d8fb0d11ae2
2016-10-05 16:39:27 +00:00
Alex Monk 9dabce28b2 Allow users who haven't enabled NWE in their preferences to use veaction=editsource
Instead of being completely broken when they try this, let it just work.

Change-Id: I173d82a748289e73c5792ca5aee22b8871f6a2d8
2016-10-04 23:48:43 +01:00
jenkins-bot 26e235211d Merge "Pass excludeCurrentPage option to TitleSearchWidget in link inspector" 2016-10-04 22:45:10 +00:00
jenkins-bot 8990d9f82e Merge "Detect format in wikitext" 2016-10-04 22:26:08 +00:00
Translation updater bot fdc4bab12a Localisation updates from https://translatewiki.net.
Change-Id: Iec3713516a34514afc14ab3de14452d2f146ffbe
2016-10-04 22:42:49 +02:00
Ed Sanders a9233045c7 Detect format in wikitext
Logically depends on I575d92c4fa.

Should really use a registry, and also doesn't update when
format is changed by deleting text, but is an improvement
for now.

Bug: T147218
Change-Id: I0cb87dbad2ab4269c4f89bdff8a4ccd9b35c8635
2016-10-04 11:04:54 -07:00
Alex Monk aeaa49f9b2 Disable switch-to-VE button in NWE if VE is unavailable, don't hide it
Bug: T146182
Change-Id: I9d5095147288a78e2ba7dbddd3d7e6673c97859f
2016-10-04 18:41:11 +01:00
jenkins-bot 9da0eaef03 Merge "Pre-load the article title in gallery dialog search" 2016-10-04 16:24:00 +00:00
jenkins-bot c1cb6edf83 Merge "Don't try to add suggested/required parameters already set under alias names" 2016-10-04 15:49:27 +00:00
Alex Monk d15034011f Allow NWE on non-VE namespaces
Bug: T146182
Change-Id: I9547dfd591ad1e68e045b4928765a95895e37737
2016-10-03 22:20:18 +01:00
Ed Sanders 69c332d1ad New wikitext editor: unwrap lists when changing style
Bug: T147227
Change-Id: I1a7f86e2a97855be5c44671d8f5918fb87bc70d0
2016-10-03 16:16:04 -04:00
jenkins-bot 1e89ab7d7a Merge "Remove commented out code" 2016-10-03 19:37:27 +00:00
Ed Sanders 755500b463 Remove commented out code
Change-Id: Ie3edc36c5d51eb7f6363416594a8aab37dec074c
2016-10-03 15:08:47 -04:00
jenkins-bot d415a003cd Merge "Apply user preference 'editfont' to NWE" 2016-10-03 17:01:11 +00:00
Alex Monk e3a387b517 Don't try to add suggested/required parameters already set under alias names
Bug: T143650
Change-Id: I6d5ed2903a468205760f715b9bb36a40bdef926a
2016-10-03 17:57:55 +01:00
jenkins-bot b8373f572d Merge "ce.MWTransclusionNode: Clean up href normalization" 2016-10-03 15:28:00 +00:00
Ed Sanders 1ce3a81c63 Fix styling of categories now they are editable
Bug: T147084
Change-Id: I8c2acf507c72f6a35aadf595bad0c8c378140a0b
2016-10-02 15:43:17 -04:00
Translation updater bot 88a44f3fe0 Localisation updates from https://translatewiki.net.
Change-Id: I9ae8d8970ecf34e232d9c663ea2e8bea912e2e6d
2016-10-02 10:43:42 +02:00
Ed Sanders 4d1f8b5928 Pass excludeCurrentPage option to TitleSearchWidget in link inspector
Logically depends on Ieade9d0ff for the actual functionality.

Bug: T147050
Change-Id: I2cc4fc170398c80d7f0103772bc56666685b8baf
2016-09-30 15:41:08 -04:00
Translation updater bot a71e015764 Localisation updates from https://translatewiki.net.
Change-Id: Ib5bb67d1ec84e5993da18c07bf8151bdbde3b585
2016-09-29 23:03:24 +02:00
jenkins-bot 89f1ac8f09 Merge "Add wikitext sequences for lower heading levels" 2016-09-29 17:06:08 +00:00
Roan Kattouw f2c715aaa0 ce.MWTransclusionNode: Clean up href normalization
This became a special case when decodeURIComponentIntoArticleTitle()
was introduced, presumably because we skipped underscore transformation
out of laziness here. It doesn't matter whether we do underscore normalization
because we do title normalization right after, so make this code
less exceptional by using the fully decoded title.

Change-Id: I036cc7f1e08895d36224c94b8edc3ad700af1947
2016-09-29 00:16:15 +00:00
Translation updater bot ad45145a20 Localisation updates from https://translatewiki.net.
Change-Id: I3debd46c2f469651fe40c83f65d4e0df01fccca5
2016-09-28 22:28:13 +02:00
Ed Sanders 2ce9979d36 Apply user preference 'editfont' to NWE
Expects I5f0433e9 in core

Bug: T145016
Change-Id: I3b57d566d2846ea284e620d7335c4a3f62df518a
2016-09-28 20:06:43 +00:00
Ed Sanders ba8ca2ab73 Add wikitext sequences for lower heading levels
Bug: T146264
Change-Id: I0f9afad27ab11d4eb487c5a18c667eeead3f1c75
2016-09-28 11:59:55 -07:00
jenkins-bot 97315a6763 Merge "NWE: Don't show button to switch to VE if it isn't available" 2016-09-28 16:40:24 +00:00
Thalia 1d8d4accff Pre-load the article title in gallery dialog search
Bug: T145243
Change-Id: I4cd04dee4c875524ecdf90027dc878eb15f47ce6
2016-09-27 14:01:31 -07:00
Translation updater bot 749dfc9828 Localisation updates from https://translatewiki.net.
Change-Id: Ie1589d4f1c2161c83c20be3f53b9dda9effecbc7
2016-09-27 22:40:25 +02:00
Translation updater bot b9ab005c6c Localisation updates from https://translatewiki.net.
Change-Id: Ibcdc76d2e8e9ddfcd14be99a0ada167d444d95ec
2016-09-26 22:44:11 +02:00
Derk-Jan Hartman fbdad82b99 Use slice instead of substring per code conventions
Change-Id: I5de8b485d287db097f2ad63a7edf75f86a86822d
2016-09-26 21:34:37 +02:00
jenkins-bot 8375c57a6c Merge "Revert "ve.dm.MWMediaResourceProvider: Use mw.ForeignApi rather than JSONP"" 2016-09-26 18:55:13 +00:00
Bartosz Dziewoński 1d8032db1c Revert "ve.dm.MWMediaResourceProvider: Use mw.ForeignApi rather than JSONP"
The change was merged without the necessary dependencies.
This reverts commit 2b1c3914ec.

Bug: T143279
Bug: T146661
Change-Id: I5ce945f6167c9db5d5f03c824dee3d89cd0931a8
2016-09-26 18:49:00 +00:00
jenkins-bot 720b97694e Merge "Change mid-upload 'cancel' button to 'back'" 2016-09-26 18:34:38 +00:00
jenkins-bot d9ed33208a Merge "MWAceEditorWidget: Configure Ace with its base path" 2016-09-26 13:50:42 +00:00
Derk-Jan Hartman 148c6b53b4 MWAceEditorWidget: Configure Ace with its base path
Configure the basePath for Ace, so that its own loader knows from where
to lazy-load additional resources. This will enable all known modes and
the worker scripts for linting.

Bug: T124419
Change-Id: Ie71518917ab966743e8397b23ffb050ca47e9ff4
2016-09-26 14:54:42 +02:00
Translation updater bot 2cb81c9973 Localisation updates from https://translatewiki.net.
Change-Id: I2a10ed479e33d9e37a3d90036d746f5b88b67b7a
2016-09-24 22:43:19 +02:00
Alex Monk d0abe11aca NWE: Don't show button to switch to VE if it isn't available
Bug: T146182
Change-Id: I4bd039726ebccfd4351ecc68e6d7662752412d1b
2016-09-24 02:43:38 +01:00
Translation updater bot c302e0804f Localisation updates from https://translatewiki.net.
Change-Id: I8052278bd63e4093cf4a84361fb116c232263ad8
2016-09-23 22:37:08 +02:00
Translation updater bot df68db60ab Localisation updates from https://translatewiki.net.
Change-Id: Ibab4cd837a2e55e65ad8bb1bd5acdb434811de45
2016-09-22 23:43:10 +02:00
David Lynch d28819f795 ui.MWLinkAnnotationInspector: skip internal link checking if the value has changed
If the value has changed since the event was fired, we're operating on old
data, *and* another event will have been fired for that change anyway. So
abort this check.

Bug: T146306
Change-Id: Ia6682ec0218fd3fbc573582753d815a56963eb71
2016-09-22 11:23:48 -05:00
jenkins-bot 80618cc629 Merge "dm.MWInternalLinkAnnotation: Fix href normalization for special characters" 2016-09-22 16:19:12 +00:00
Roan Kattouw bb45d984ca dm.MWInternalLinkAnnotation: Fix href normalization for special characters
<a href="Foo%3F"> would dirty-diff to <a href="Foo?"> and also render
as such, pointing to the wrong page.

We also called decodeURIComponent() on the href twice, which can't
have been good.

Move URI decoding and underscore normalization into
getTargetDataFromHref(), and add rawTitle for callers that need it.
Put rawTitle in the origTitle attribute, so that equivalence
comparisons (decode(origTitle) === title) work as intended.

Bug: T145978
Change-Id: I29331a4ab0f8f7ef059c109f6813fa670a2c7390
2016-09-22 09:10:41 -07:00
Matthias Mullie 2b4948b0b6 Change mid-upload 'cancel' button to 'back'
Bug: T114938
Change-Id: I964708e1267223b181630b9bea5b19e2bdf242be
2016-09-22 16:13:57 +02:00
jenkins-bot 6d583291bb Merge "Only unregister WT string handler in WT handler factory" 2016-09-22 04:09:18 +00:00
jenkins-bot a44a4d402e Merge "ve.dm.MWMediaResourceProvider: Use mw.ForeignApi rather than JSONP" 2016-09-22 03:01:54 +00:00
Ed Sanders d8fb7b84d3 Only unregister WT string handler in WT handler factory
Bug: T144653
Change-Id: I91528b56ac3905a05e8da51455055537958e026e
2016-09-21 13:08:10 -07:00
David Lynch 5bc54fd036 dm.MWInternalLinkAnnotation: Add some test cases
Change-Id: Ie338d5538959ea2cc296886b623e9dc2cd84fa8f
2016-09-21 09:57:45 -07:00
Ed Sanders 4c8a97f9e8 Temporarily override broken toolbar border colour
Will be fixed in the next OOUI release via I91862c2e609.

Change-Id: I741bb8d5396bed256ee1907eaa4ba86e4697f325
2016-09-20 22:51:02 -07:00