Commit graph

10833 commits

Author SHA1 Message Date
jenkins-bot a40c0082b0 Merge "Make 'moment' a dependency of just 'mwimage', not all of VE-MW" 2015-11-17 23:42:36 +00:00
Ed Sanders b5c16ac95c Make 'moment' a dependency of just 'mwimage', not all of VE-MW
Change-Id: I23c193bfb34203aa6f2ef1d3633c208e5c692c97
2015-11-17 14:55:10 -08:00
Translation updater bot b4f2194085 Localisation updates from https://translatewiki.net.
Change-Id: I15540a448677ac4e4b6a0eba024e230ce4846b22
2015-11-17 21:55:40 +01:00
Timo Tijhof c895ba38b1 Don't load non-existant 'visualeditor-linkinspector-open' message
Follows-up 55f78fc which deleted this message.

> MessageBlobStore::fetchMessage failed to find: 'visualeditor-linkinspector-open' (en)

Change-Id: Iccfd51f597b991146209b7a639179ff0deb0e119
2015-11-17 06:18:14 +00:00
Alex Monk 889358f24c Ensure we always catch the wikiEditor-toolbar-doneInitialSections event
Don't wait for module loading. Before, this was only actually working half the
time.

Change-Id: I7fb284a800927672642c59231a322982b613f16b
2015-11-17 02:23:25 +00:00
jenkins-bot 2fcbc18dff Merge "Provide a tool to insert a signature in namespaces that need it" 2015-11-17 00:16:42 +00:00
jenkins-bot 3e9d040a79 Merge "AceEditorWidget: Allow users to force an Ace editor refresh" 2015-11-16 22:46:24 +00:00
Translation updater bot 64d8e394ce Localisation updates from https://translatewiki.net.
Change-Id: Iaf8fb457fd0b835d5b8819f5dab015c4a59e0a78
2015-11-16 22:19:07 +01:00
jenkins-bot b99dfee49b Merge "Update VE core submodule to master (3549158)" 2015-11-16 20:15:23 +00:00
Ed Sanders 35c44db988 AceEditorWidget: Allow users to force an Ace editor refresh
Ace is clever about not updating the rendering of elements
which aren't visible, so allow users to force an update, for
example if they changed the value while the whole widget
was hidden.

Change-Id: I7bbbffd17489bc80fe5fa80911f29d7223e125a3
2015-11-16 12:12:10 -08:00
Ed Sanders 470a4a551b AceEditorWidget: Refactor to ensure setValue runs synchronously
Also ensure setEditorWidget is only called once when
loadingPromise resolves.

Change-Id: I1a95bda5e9ff17d7575326f29fa01d273193c4a5
2015-11-16 11:36:08 -08:00
James D. Forrester 09da242d6a Update VE core submodule to master (3549158)
New changes:
fbb2b2e Localisation updates from https://translatewiki.net.
933f979 mailmap: Remove unused alias for ttijhof@wikimedia.org
72ce0e6 Better faking of onselectionchange
0d550d9 Paste sanitization: Treat <br> breaks as node splits
966b0a1 Localisation updates from https://translatewiki.net.
414cebb ContentAction: Add 'collapseToEnd' option to 'insert'
60de784 demos: Fix 'TypeError: ve.demo.target not a function' in desktop-dist.html
71f272e Localisation updates from https://translatewiki.net.
60376d2 RangeFix: Update from 0.1.1 to 0.1.2
2470042 Localisation updates from https://translatewiki.net.
7b1cdda Range offsets: Special case when adjacent to a nail
7ecde6c Add ve.ui.AnnotationContextItem

Change-Id: Iaab4cb7f9d4ec9d7120f42350fd613458c996c85
2015-11-16 10:49:53 -08:00
Bartosz Dziewoński 9be5c85db4 Provide a tool to insert a signature in namespaces that need it
VisualEditor is usually not enabled in talk namespaces... but
sometimes it is. And when users see the button to edit with VE,
they're going to click it and expect to be able to sign their posts.

This tool is only loaded on talk pages and pages in additional
namespaces defined in $wgExtraSignatureNamespaces.

Code adapted with small tweaks from my own gadget
<https://meta.wikimedia.org/wiki/User:Matma_Rex/visualeditor-signature.js?oldid=13461327>,
which is already available under the MIT license.

Changes include:
* The tool is now always visible if the wiki allows signatures in any
  VE namespaces, but disabled when not allowed in the current namespace.
* Register '~~~~' sequence to insert the signature.
* Code style tweaks for stricter lint checks in this repository.
* Documentation corrections.

Swedish translation provided by André Costa (already credited
as a translator as Lokal_Profil).

Depends on changes in VisualEditor core:
* I89fe53890ab59d12260ea6b41de802c38c24e8b9
* I14cd7efac521687ea38580341ae08ddc522edeeb

Bug: T53154
Change-Id: I6be5fb2118cf3eef5098d4c5320228aa81411ccb
2015-11-16 18:06:32 +01:00
Translation updater bot 9d01677f75 Localisation updates from https://translatewiki.net.
Change-Id: I2e18f18c1614e74a5681ea7e8faf0ce71c1b5db1
2015-11-15 22:22:40 +01:00
jenkins-bot f44e127eb5 Merge "AceEditorWidget: Emit resize event at end of cycle" 2015-11-15 02:38:22 +00:00
Translation updater bot 8a456d3e31 Localisation updates from https://translatewiki.net.
Change-Id: I1eb678891af629bf935f2837e76ba5b856d5f9fd
2015-11-14 22:19:35 +01:00
Ed Sanders b21b939a67 AceEditorWidget: Emit resize event at end of cycle
Ensures the widget has taken its new size before emitting the event.

Bug: T117926
Change-Id: If1dab2ecadb2a581100c0ae154b341ce8d173a7c
2015-11-13 18:48:35 -08:00
C. Scott Ananian 236fad19b6 Ensure magic link nodes inherit the annotations of their text
If you create an autolink in the middle of bolded text, the magic link
should also be bolded.  Similarly, if you convert a bolded simple link
to a magic link, the magic link should stay bolded.

Change-Id: I38c7f3c0c275851049088a37f3b37d815ed38e4e
2015-11-13 13:48:18 -08:00
Translation updater bot 73918e0e1e Localisation updates from https://translatewiki.net.
Change-Id: I63a0e4185c61a42cf0d142d520fdc1e7c7f9000f
2015-11-13 21:35:36 +01:00
Timo Tijhof 7c54043812 mailmap: Remove unused alias for ttijhof@wikimedia.org
This was accidentally added based on AUTHORS.txt (Fixed in 2c3a2f7).

This address was never used as either author or commiter in the history
of this repository (based on grepping 'git log --format='%ae %ce').

Change-Id: Ifb21d881e210be18acea227a3297daee3c7ba122
2015-11-13 16:26:47 +00:00
Translation updater bot a284d335a8 Localisation updates from https://translatewiki.net.
Change-Id: I7f7dba15312b3fda8e9a737428f4bc191604ac4f
2015-11-12 23:02:52 +01:00
jenkins-bot c6aeff4ba9 Merge "Edit mode switching: Separate styles" 2015-11-11 22:33:35 +00:00
jenkins-bot 96f91758f6 Merge "Update VE core submodule to master (77d786a)" 2015-11-11 22:10:08 +00:00
Translation updater bot c1ac8806c6 Localisation updates from https://translatewiki.net.
Change-Id: I7f3c0dfe04074271159b7f22032c587374f72836
2015-11-11 21:57:36 +01:00
Ed Sanders 9bcc61e195 Update VE core submodule to master (77d786a)
New changes:
95589a6 test: Add a Rakefile for new CI requirement
1a4497e ve.ui.DialogTool: Do not require that a command is set
cbf1bff ve.ui.Tool: Fix documentation for getCommandName
530022d Localisation updates from https://translatewiki.net.
9529093 Update OOjs UI to v0.13.2
b8d6c15 Add icon: Rename 'insert' to 'add'
2f3015b Update OOjs to v1.1.10
78ceb18 Fix deletion inside a structural node at start/end of document
ce3e9a4 ve.utils: Use binarySearch from OOjs

Local change:
* MW test cases for new structural deletion logic

Bug: T52250
Change-Id: I643449c1fa08ea12c8c3aa13f4a4b97d8876990d
2015-11-11 12:35:53 -08:00
Ed Sanders 86a1d1bfa3 Edit mode switching: Separate styles
Ensures that these styles are loaded *after* OOUI by making
them dependent on it, unlike DesktopArticleTarget.init
which isn't.

Change-Id: Ia1fff16432d20fb56707c5e21c6a930d2478e311
2015-11-11 18:50:55 +00:00
jenkins-bot c815c3242d Merge "Edit mode switching: Only show WE toolbar button once module is loaded" 2015-11-11 02:21:04 +00:00
jenkins-bot 53dbf3ac2f Merge "Replace 'source' icon with OOUI's 'wikiText' one" 2015-11-11 01:42:00 +00:00
jenkins-bot 1f2905c39f Merge "DesktopTarget: Fix opacity of #siteSub and #contentSub" 2015-11-10 23:39:03 +00:00
Translation updater bot 7bb161d5f7 Localisation updates from https://translatewiki.net.
Change-Id: Ia25e40a77c416e2dde09b7e68d6e836baf9b3adc
2015-11-10 22:36:30 +01:00
jenkins-bot 77ee4e8bad Merge "Remove redundant VisualEditorDataModule::getGitHeadHash static cache" 2015-11-10 20:08:22 +00:00
jenkins-bot db6452ad76 Merge "Enable new module versioning for VisualEditorDataModule" 2015-11-10 20:06:12 +00:00
Ed Sanders cfe3d9b561 Edit mode switching: Only show WE toolbar button once module is loaded
No point showing the icon if we don't have the functionality to
make it do anything. Also this reduces the number of RL requests
made as we never fetch OOUI separately.

Change-Id: Iac9aa6f34c485223e73981b3377c7d0cfd31dae9
2015-11-10 10:43:33 -08:00
Alex Monk 6213c23db1 Fix updating of display title upon save
Bug: T117643
Change-Id: Ibd3d4f056a2d175e52b60b6e3a4c0ece04f26f50
2015-11-10 13:50:00 +00:00
Željko Filipin 0bf32cd252 Added Rakefile
This is needed for our continuous integration.

Bug: T117993
Change-Id: I387ab6f4c51eff65f75f6724807f4a250aec56e0
2015-11-10 10:24:39 +00:00
James D. Forrester f0887bca81 Update VE core submodule to master (6f8f3db)
New changes:
cda23ea CommandHelpDialog: Layout tweak
a4fcff4 Localisation updates from https://translatewiki.net.
dac9067 Remove unused jquery.visibleText library
58beb8c lib: Add AUTHORS, LICENSE and README files for libraries missing them
efb1749 Surface drop: Show branch node drop markers for file drop
a55574b Localisation updates from https://translatewiki.net.
0ad3133 Add ve.Scheduler
55cc3e0 Close inspectors before executing a ve.ui.Tool command
6132af8 Localisation updates from https://translatewiki.net.
24fed63 Watch for hashchange on the demo
0f04339 ve.ui.Sequence: Allow sequences to insert content

Change-Id: Idf26d9fb1970b994a54085b43fcc848b005da273
2015-11-09 17:36:27 -08:00
Timo Tijhof 370b0bfeb5 Remove redundant VisualEditorDataModule::getGitHeadHash static cache
This method is only called once, in getScript(). There is no need to
indefinitely cache it in the class.

Besides, the GitInfo class already caches it in much the same way in its
own class.

Also move the class instantiation of GitInto into getScript() so that it is
deferred until getScript() is needed – which in turn is only called once and
will naturally gargage collect it as it's now a local variable.

Change-Id: I545baa04e9ff2333fbf2ca7d0473dab0cf9269fd
2015-11-10 01:06:33 +00:00
Timo Tijhof 4613449b65 Enable new module versioning for VisualEditorDataModule
This module effectively uses it already since this module doesn't
add meta data to getDefinitionSummary, but rather adds all of getScript()
into the hash, which is exactly what enableModuleContentVersion is for.

Using this has the advantage of being well-tested and better cached,
as right now the script has to be computed twice (once for the response,
and once for the version header), whereas enableModuleContentVersion
uses RL's in-process cache.

Bug: T102578
Change-Id: I42fb720988b4b4b4310bde238dc321b62866f827
2015-11-10 00:46:55 +00:00
Alex Monk 87affb5ca4 Restructure education popup code to work without overriding onSelect
That code was breaking on mobile which uses a subclass of the normal
link inspector.

Bug: T117603
Change-Id: I75541230c21b1ee9eb73f6fb4b1fe5a5f9c14e75
2015-11-09 23:18:01 +00:00
Alex Monk 5f162522eb Merge "ve.init.mw.DesktopArticleTarget.init: Make switching to VE for new pages work" 2015-11-09 22:42:34 +00:00
Translation updater bot e87b56b53e Localisation updates from https://translatewiki.net.
Change-Id: Ie37b9b551d0af53d2420af4a798a26c1954ecf0b
2015-11-09 21:50:10 +01:00
Bartosz Dziewoński 7d69e86265 ve.init.mw.DesktopArticleTarget.init: Make switching to VE for new pages work
Work around RESTBase problem that causes errors if we try to switch to
VE when the wikitext is empty. This would prevent non-power-users from
opening VE entirely.

This only solves the issue for new empty pages, and not when the user
intentionally empties the edit box. In that case, though, they get a
dialog where they can choose to "keep" or "discard" changes, and
discarding lets you open the editor.

Bug: T118152
Change-Id: Ie808bcaa9826deacac392dd6cbc90a9446602b79
2015-11-09 18:55:21 +01:00
jenkins-bot b966333009 Merge "Unset 'action' query parameter from veEditUri, which should always point to VE" 2015-11-09 15:26:18 +00:00
Translation updater bot 280b68b183 Localisation updates from https://translatewiki.net.
Change-Id: I96650b4066bf3a33e0b31e53ddefa15dac49d5b7
2015-11-08 22:14:22 +01:00
Alex Monk 1e4889bbc7 Unset 'action' query parameter from veEditUri, which should always point to VE
Bug: T117780
Change-Id: I1377145bbbe05611ee75ae27922cf7a2cc5895e7
2015-11-08 20:32:28 +00:00
Translation updater bot a8dbf5f828 Localisation updates from https://translatewiki.net.
Change-Id: I37ec76d17c9c7f24c6691d8cb85faf7422f28633
2015-11-07 22:45:38 +01:00
Alex Monk 3e23d3b96d Only load switching module (depending on OOUI etc.) on edit pages
This wasn't as bad as T112401 (that was blocking render), but we
still shouldn't be loading the module on page views.

Bug: T118088
Change-Id: If86701ed7ff4e8d6defb1c682aa9a38c211be0fa
2015-11-07 19:08:29 +00:00
jenkins-bot 69bce26579 Merge "Drop any beforeunload handlers when loading from existing wikitext" 2015-11-07 16:09:50 +00:00
Alex Monk 6247a2f430 WikiEditor integration: Fix dependencies for switch button
Change-Id: Ic8fb607e8c467e89c0b9af0a9baab84e59b19ba8
2015-11-07 04:15:14 +00:00
Alex Monk 2910cd2384 Drop any beforeunload handlers when loading from existing wikitext
Bug: T117769
Change-Id: I823737b17e5af8ed15bc2b62db61a31886e8d418
2015-11-07 03:57:19 +00:00