Commit graph

9484 commits

Author SHA1 Message Date
James D. Forrester cabf2d9ab3 Update VE core submodule to master (d449684)
New changes:
e98b4ab build: Bump various devDependencies
910af78 jsduck: Set --processes=0 to fix warnings-exit-nonzero
ed29114 Factor attribute setting code into ElementLinearData
143d3ff Move ve.dm.Document#spliceMetadata to dm.MetaLinearData
9ca7a70 Remove unused variables in dm.TransactionProcessor#applyAnnotations
a4847a3 Remove unnecessary support for nesting annotation and replace operations
c451a3c Queue linear model modifications in TransactionProcessor
98b253d Followup 11f507a98f62: also restore rowspan and colspan on TableCellNodes
dbecd01 Fix margins of indicators in table context

Change-Id: If137035b36a47eef5d8f16a3e0ef8c93542f7b19
2015-03-09 09:19:06 -07:00
Roan Kattouw 6648f94982 Remove useless ve-ce-mw*Node classes from GCN subclasses
Since GCN aggressively modifies this.$element, these classes
didn't survive for very long, and they weren't being used
anyway.

Change-Id: I6e9827499374941fbded983956c57cc250d957c8
2015-03-09 12:05:30 +01:00
Translation updater bot b982ec4a77 Localisation updates from https://translatewiki.net.
Change-Id: Iba1d7414b1c8fd1e3215fb965ff849553c24ecf6
2015-03-08 21:50:54 +01:00
Jamison Lofthouse 6b4608c7f3 i18n: Change grammar of suppress redirect update message
Changed the message of the update redirect message that is found in the page settings popup to something that is grammatically correct.

Change-Id: I71eaa143274742ebc19720f5a1b72008025d69e3
2015-03-08 01:28:09 +00:00
Timo Tijhof 9fd753e7a7 build: Enforce disallowMixedSpacesAndTabs jscs rule
Also, fix @returns comments (should be @return) and remove unnecessary
@method comments from the documentation.

Change-Id: Icd303626ac745c7ab5bff164f9b8cac276de1523
2015-03-07 16:49:30 +00:00
James D. Forrester 5db66faea9 build: Update jscs to latest
Change-Id: Ic1193d5557e0a3468c16896767888e8a593671e0
2015-03-07 04:05:44 +00:00
jenkins-bot 26a7e990fa Merge "Update VE core submodule to master (300b89a)" 2015-03-06 20:13:07 +00:00
jenkins-bot cdee219127 Merge "Add composer entry point for phpcs and linting" 2015-03-06 16:51:20 +00:00
Kunal Mehta 5ffdabd2db Add composer entry point for phpcs and linting
Bug: T90943
Change-Id: I0a95ef0f12149aaccdc3e7383c99b694a9dce990
2015-03-06 08:44:30 -08:00
jenkins-bot cce90e48e4 Merge "ve.ui.MWLinkTargetInputWidget: Fix documentation" 2015-03-06 11:21:54 +00:00
jenkins-bot b63b7ab744 Merge "ve.init.mw.ViewPageTarget: Use mw.Api#postWithToken for setting hidebetawelcome pref" 2015-03-06 11:21:52 +00:00
jenkins-bot a79d587125 Merge "ve.init.mw.Target: Don't go into infinite recursion on API errors" 2015-03-06 11:20:13 +00:00
Bartosz Dziewoński 4c22083d07 ve.ui.MWLinkTargetInputWidget: Fix documentation
This function was not returning a jqXHR for a long time. It's usually
a mw.Api promise, but might be something else.

Change-Id: I59975cc9dfbea70e5ae666fcc9915f10bd199e4d
2015-03-06 11:14:34 +00:00
Bartosz Dziewoński d5bf7e9e9e ve.init.mw.ViewPageTarget: Use mw.Api#postWithToken for setting hidebetawelcome pref
We can't use it for saving because we need to display a warning if
the user's identity changed.

Change-Id: I05919e407cd19d96c506671020bcdb95f3e2acaf
2015-03-06 11:11:03 +00:00
Bartosz Dziewoński 1656d3495e ve.init.mw.Target: Don't go into infinite recursion on API errors
The #tryWithPreparedCacheKey method was assuming that the request
could only fail because of invalid cache key. It can also fail because
of a bad token, and probably for a number of other reasons.

So only retry only once, and then fail. If it's a 'badtoken' error
during save, the caller will handle it and retry with a working token.
If it's something else, who knows, but we don't go into infinite loop
at least.

Failing in a way that will be handled is weird because 8e48f945 changed
the signatures of the promises, but not the functions that use them.
This must be fixed later.

Bug: T91158
Change-Id: I103cf888d339b44e3fd4fe2376edf5e37ce4157f
2015-03-06 02:47:47 +01:00
James D. Forrester 679b29cbf4 Update VE core submodule to master (300b89a)
New changes:
300b89a Follow-up Id9e657f12: Don't add moreTextStyle to the same group as it breaks downstream

Change-Id: Ie1373765e0836c6e9c85fd68efb5489f8be18416
2015-03-05 16:19:36 -08:00
James D. Forrester 19eacc8fe1 Follow-up I11b9f0ab: Make the MWTransclusionNode icon a fixed size
Change-Id: Ib4fd9abbd36c59c5bc5e0b5378793f9d57c0568f
2015-03-05 23:48:04 +00:00
James D. Forrester 2c689a4790 Follow-up I5918367: Add new classes to jsduck.json
No idea how this passed the first time…

Change-Id: I690d10f4f69c657bc58f989c545905649f97add8
2015-03-05 15:43:24 -08:00
James D. Forrester 9d0bb8f56e Update VE core submodule to master (9fb4bdb)
New changes:
266b558 Fix typo in direction calculation
6469b5b Update OOjs UI to v0.9.0
f98bb5c ve.ce.CommentNode: Specify 'background-size' override
4358560 Localisation updates from https://translatewiki.net.
cba6ffe Fold text style dropdown into basic text style bar in toolbar

Change-Id: I59183674ad2cfab2ef62bbd4d4acd105735aa293
2015-03-05 14:57:20 -08:00
Timo Tijhof 5813d53271 Update JSDuck config to standard jsduck.json
Also
* This way we don't need to pass the --config=jsduck.config.json
  parameter but can run plain 'jsduck' in Jenkins. Allowing it
  to use the standard job template for testing.

* Move processes=0 to jsduck.json.
  Workaround for https://github.com/senchalabs/jsduck/issues/525

* Use standard ' - Documentation' suffix, which makes the first
  part of the title render in bold (similar to how we do in OOjs
  and OOjs UI already).

Change-Id: I6c9c7a1f29df0a72dc8cd0d37a83aaef23068062
2015-03-05 23:51:53 +01:00
jenkins-bot 432384096e Merge "Add an icon to hidden templates" 2015-03-05 22:38:47 +00:00
Translation updater bot 16f7de1e04 Localisation updates from https://translatewiki.net.
Change-Id: I6b844d3548e64a696f772acc20062b70f676fded
2015-03-05 22:30:14 +01:00
Amir E. Aharoni adb4b2106a [BrowserTest] Update Ruby gems
The latest version of selenium-webdriver is needed to work with Firefox 36.

Change-Id: If00700141527fc5d0c1779bd186a71039c8063e4
2015-03-05 10:51:19 +00:00
jenkins-bot 56b95f2fac Merge "Update VE core submodule to master (79004c9)" 2015-03-04 19:20:23 +00:00
jenkins-bot 1a40f3c048 Merge "Add a threshold to 'read more' calculation in media dialog info" 2015-03-04 19:15:01 +00:00
Moriel Schottlender 06f29f343a Add a threshold to 'read more' calculation in media dialog info
When calculating whether to show the 'read more' button on fields
that are configured 'descriptions', use a threshold to check if
the height is enough to be shown.

Bug: T87265
Change-Id: I0601e4fa92cb58903641a146500cf560bc029425
2015-03-04 11:04:53 -08:00
James D. Forrester ba45620da9 Update VE core submodule to master (79004c9)
New changes:
b66e48d Use the inspector's previousSelection for context positioning

Change-Id: I7855519f5ad806ace2304ed6e1f5458363ffb440
2015-03-04 10:49:32 -08:00
Moriel Schottlender 2ae9fa6b29 Add an icon to hidden templates
Check if, after being fully rendered, a template is effectively
empty. If it is, add an icon and style to it so it displays for
the user and is clickable.

Bug: T51806
Change-Id: I11b9f0aba3398a3deb3e755051366e174a28e586
2015-03-04 10:30:50 -08:00
jenkins-bot 0ea0691ad7 Merge "Correct jquery.uls dependencies" 2015-03-04 18:05:36 +00:00
Matthias Mullie 63b5de3a83 Correct jquery.uls dependencies
ve.init.mw.Platform.js, ve.init.sa.Platform.js & ve.ui.MWLanguagesPage.js
use $.uls, but nothing in the ext.visualEditor.core module does.

Change-Id: I0b3d8c2b25694e29c86b91d7df7875f1be24fb2d
2015-03-04 18:00:07 +00:00
James D. Forrester 32613d204d Update VE core submodule to master (7dcd5e8)
New changes:
61e1646 Resolve URLs in LinkContextItem
91d1814 Handle optional parameters correctly in table selection
c2810ce Fix up selection if we cursor into or next to a table node
11f507a Don't call .addClass() in CE nodes' setup handlers

Change-Id: Iad402ddab1ca8b736c79589e4724882a41eaa6e1
2015-03-04 09:48:35 -08:00
Roan Kattouw ec2bff5535 Resolve URLs in MWInternalLinkContextItem
Exactly the same change as Ifee722a7f60.
Because we have such excellent code reuse, or something.

Bug: T85622
Change-Id: I18bd5d3923771b6ff149aa589bb2fa23beecf4f5
2015-03-04 17:17:06 +01:00
Željko Filipin 273995058e [BrowserTest] Use Cucumber tag to specify which scenario to run
By adding this tag we were able to delete VisualEditor JJB builder and reuse
browsertest-website builder. See the task in Phabricator (linked below) for
more information.

Bug: T90423
Change-Id: I206d512adcb304b6e8823cc9e05acfcf3880c6c8
2015-03-04 09:03:42 +00:00
Ed Sanders 94fe054257 Update VE core submodule to master (a65ad7c)
New changes:
a65ad7c Move special character inserter to toolbar dialog manager

… and add it to the toolbar as a terminal option.

Change-Id: I35834d866a13c5dea7f5a520c63b8a99451fcf6d
2015-03-03 18:20:13 -08:00
James D. Forrester 13945462ce Update VE core submodule to master (b90965c)
New changes:
a9c35d6 build: Add disconnect tolerance to karma config
d468b00 Work around Array.prototype.splice being broken in Safari
9d63353 Make annotation inspector getMode method trim
4acd774 Only store selections which yield a valid context position
245062f Fix desktop context positioning (again)

Change-Id: I8f2f58c955221d1366de2ce9d69283694e78b473
2015-03-03 17:40:42 -08:00
James D. Forrester 0096c37fae VisualEditor.php: Warn people to use extension.json instead
Change-Id: I28f06581fae91d950c08c9bfc63779df6d60d4ad
2015-03-03 13:32:12 -08:00
Moriel Schottlender ae72184c8f Work with the new mw.Feedback and add UserAgent checkbox
Add the new feature for user agent checkbox for the mw.Feedback
dialog. This bumps our MediaWiki dependency to 1.25wmf20.

Change-Id: I741ded83de4f575777a15cb20735e351039dc81f
2015-03-03 10:58:34 -08:00
jenkins-bot 536c72097e Merge "Update VE core submodule to master (0cb3b6f)" 2015-03-03 16:52:22 +00:00
Timo Tijhof 46369a2969 Update VE core submodule to master (0cb3b6f)
New changes:
e6554e8 Localisation updates from https://translatewiki.net.
397a53d Localisation updates from https://translatewiki.net.
56c5937 Provide isAlignable checks for alignable nodes
2431396 ce.ContentBranchNode: Don't compare new rendering with old on first render
0131fe8 ve.ce.GeneratedContentNode: Avoid calling $.fn.add, it's slow
89f66fc Fix documentation lies about rewrap event
fb42667 Add insert/edit modes to FragmentInspector
511e0a7 Make ce.BranchNode#updateTagName do what its documentation says
626936d Localisation updates from https://translatewiki.net.
0cb3b6f build: Rename JSDuck config standard jsduck.json

Change-Id: I58d210a549ea5faa2142f716ad37c2fad9be94f5
2015-03-03 17:09:18 +01:00
Roan Kattouw ea3fccccaa Reduce complexity around onbeforeunload handler
We used to attempt to not break Firefox's bfcache, but this
didn't really work very well, and it's not clear that avoiding
bfcache breakage is even a good idea. It's more sensible and
consistent to deliberately break bfcache while VE is active.
On top of that, the Firefox people believe that our trick
shouldn't even have worked to begin with:
https://bugzilla.mozilla.org/show_bug.cgi?id=1102664

Because the onbeforeunload handler is removed when VE
is deactivated, bfcache still works if you first click
Read, then navigate away.

Also clean up the management of the unload handler, using
addEventListener() and removing the return value fallback
code that is needed for beforeunload but not unload.
For beforeunload this is harder to clean up because
the addEventListener()-based API for returning a value
isn't consistent across browsers.

Change-Id: Ie4fe9ea3a59a54ba462733aa5e42bfc0ed5b15eb
2015-03-03 16:36:22 +01:00
Alex Monk 6f1b6c85a5 Send abort event on unload
Still misses some preinit aborts because we need to figure out
a way to attach the unload handler early enough to catch these.

Change-Id: I0ce721e24e69c31318064c6b443c1bfe01077546
2015-03-03 15:25:57 +00:00
jenkins-bot 4b840ab725 Merge "Promote the Language tool Beta Feature to always-on status" 2015-03-02 23:58:27 +00:00
jenkins-bot 58a685386b Merge "Fix transfer of reference contents from removed reference" 2015-03-02 21:39:21 +00:00
Roan Kattouw f24dbb3435 Fix transfer of reference contents from removed reference
We unconditionally retrieved originalHtml from itemNode,
even if there was no data-mw.body.id, so as long as
the reference itself wasn't edited, we would never overwrite
data-mw. This meant that if the <ref> with the contents
was deleted, the contents wouldn't be transfered to the
first <ref> tag with that name like they're supposed to be.
The solution is to only look at originalHtml from itemNode
if data-mw.body.id is set.

Change-Id: Ib87491b6fa6a77d62384158f8e8f7dcc2a36c23a
2015-03-02 22:26:05 +01:00
Translation updater bot bf51864690 Localisation updates from https://translatewiki.net.
Change-Id: Iaa353f0cfc791baac3e76efd41b675644b5f985b
2015-03-02 22:13:06 +01:00
Roan Kattouw 6642e4f0bc Don't claim all links exist when ParserCache misses
On a ParserCache miss when viewing the current version of a
page, we'd output {missing: [], extant: true} which means
all links are marked blue. That's wrong, instead output
that we don't know anything.

Bug: T91299
Change-Id: Icf66735141a8d2a6579dce0ffd847dd099437029
2015-03-02 21:14:38 +01:00
jenkins-bot 91d0c4ff03 Merge "mw.ViewPageTarget: Use CSS for toolbar transition" 2015-03-02 11:39:13 +00:00
jenkins-bot 78a014ce9f Merge "Show the toolbar as soon as the target has been activated" 2015-03-02 11:32:48 +00:00
James D. Forrester bddd84b1e9 Promote the Language tool Beta Feature to always-on status
No complaints in over nine months. Time to just make this available.

Change-Id: I601699573c0d50384720e5a1f0098c7f780de8cf
2015-03-01 17:15:48 -08:00
Translation updater bot a4c2984332 Localisation updates from https://translatewiki.net.
Change-Id: Idace01361190c048b6df3d374fd008569d669c1d
2015-03-01 22:10:25 +01:00