Commit graph

955 commits

Author SHA1 Message Date
Bartosz Dziewoński 59cc4b10aa Update VE core submodule to master (f7f72b5c5)
New changes:
42fea96be Add some accessibility labels to buttons on mobile

Change-Id: I37f03d547b1891c05b50fb1761620e7af9209e2b
2020-03-06 15:09:44 +01:00
Akinwale Alagbe d3292378cc Fix:Internal and External Link annotation widget
Adding the ability to special aria-label for the link annotation widgets
in order to aid accessibility to visually impaired audience

Bug: T245294
Change-Id: I3e1fd4a3e3a951092b5212397acc38b2b89a23c2
2020-02-24 16:40:19 -08:00
Bartosz Dziewoński 9119e57a2e Improve rendering of audio files (for real this time)
ve.dm.MWImageNode:
* Define sensible scalable properties for audio files. They are now
  scalable to any width but have a fixed height. (Ideally they would
  have no concept of height, but that would require many more changes.)
  This prevents them from resetting to 0x0 when resized.

ve.ce.MWBlockImageNode:
* Remove override for #isResizable, audio files can be resized now.
* Move #updateMediaType to MWImageNode mixin so it applies to
  MWInlineImageNode as well.

ve.ce.MWImageNode:
* Add #updateMediaType from MWBlockImageNode.
* Hide the real image 'src' using CSS rather than changing the
  attribute. It seems the previous solution depended on the order in
  which methods are called, because it stopped working when I moved
  the code here. (This depends on VE/VE change If5b1b5b5d.)

audioPlayer.svg:
* Make the file nicely resizeable. The dimensions of the "play" icon
  and time are fixed, the bar adjusts to the width of the container.

Bug: T206022
Change-Id: Ia0f38ca11e0d55a5b725fd9aeb6c79ec1345376d
2020-02-14 04:18:28 +01:00
Bartosz Dziewoński c95be08cc4 Localize remaining hardcoded English error messages
Bug: T227325
Change-Id: Ibee27bd8457f83910da03ecb8801e5f26bdb3b2a
2020-02-12 22:18:40 +01:00
Bartosz Dziewoński 6d993fee49 ArticleTargetSaver: Fix error messages
Follow-up to 5f1c68945d, which renamed
these messages while moving them into MediaWiki core.

Also, parse HTML in them. This is consistent with real API error
messages, and with the behavior of mw.Api#getErrorMessage. (And also
fixes potential HTML escaping issues.)

Change-Id: I307ca9873e245169a0d4b43499317acbac69fb9b
2020-02-12 22:18:40 +01:00
jenkins-bot 5b2ba08c44 Merge "Use WMUI styled WikiEditor switcher when in Vector" 2020-02-08 02:37:12 +00:00
Ed Sanders eebe103fe4 Use WMUI styled WikiEditor switcher when in Vector
Bug: T223155
Change-Id: I6cf305e77cfeda96e7736dc26f1d7feff6fb3911
2020-02-07 18:20:39 -08:00
David Lynch 0d6f984cc5 Change tags method so anon edits will go through
It turns out anonymous users can't apply change tags, so change
I2c1d0f8d69bc03e5c1877c790247e165f160e966 broke editing for them.

Bug: T242184
Change-Id: I7c27e4d9995428e213a980819810f235fdfe9435
2020-02-06 15:31:45 -06:00
David Lynch 078fbcf737 Update VE core submodule to master (e1760b7f7)
New changes:
fb4f0a83b Completion framework

Local changes to wire in the completion framework

Bug: T232601
Depends-On: If6aee9df67e7a1234d47c0ba0c2f05ef47e5bd51
Change-Id: I075cac9aa195574c3d416a40bbdc5ec2d64424e2
2020-02-06 12:05:48 -08:00
jenkins-bot d5ea567039 Merge "Match WikiEditor switching widget to Apex toolbar theme" 2020-02-05 22:40:59 +00:00
Ed Sanders 787d16f512 Match WikiEditor switching widget to Apex toolbar theme
Bug: T223155
Change-Id: I5c14f28ba3c341c74875bac090c6106655c6b4c7
2020-02-04 17:25:59 -08:00
jenkins-bot 124ae7a444 Merge "Tag VE edits from the client-side" 2020-02-04 16:43:59 +00:00
Máté Szabó ff4f382322 Use autogenerated parameter info for templates without TemplateData
When a template does not have user-provided TemplateData documentation,
the TemplateData API falls back to extracting possible parameters from the raw wikitext
to generate an API response with a list of potential parameters. However, it also
sets the "notemplatedata" field in the response, causing the VisualEditor to think
the response contains no useful information and ignore it. This appears to have been
an unintended side-effect of I97a1bfc9f9ead082a673a91b9d2053630a90309c.

This patch ensures that the VisualEditor will correctly consider such responses from
TemplateData by modifying ve.dm.MWTransclusionModel to check if the response contains
a parameter map. Some unit tests were added for the class to verify this behavior.

Bug: T243868
Change-Id: I72005880d9301a53224473900efe2917379e8708
2020-01-31 13:43:56 +01:00
David Lynch d85d30f9b3 Tag VE edits from the client-side
This opens up the API so that other tools can use it without being
forced to tag those edits as being from VE.

Also, document that tags is a working parameter that can be passed
through to the edit API.

Bug: T242184
Change-Id: I2c1d0f8d69bc03e5c1877c790247e165f160e966
2020-01-29 21:55:07 -08:00
Bartosz Dziewoński c1ea108327 Enable visual diff code on mobile
Bug: T242351
Change-Id: I4cf6c9ef846d24847a844d443952c7026fcd306b
2020-01-29 11:15:18 -08:00
jenkins-bot 9e6a40a827 Merge "Use mw.Api#getErrorMessage instead of custom handling" 2020-01-10 14:22:14 +00:00
Ed Sanders 8e20c1c66b Update VE core submodule to master (6bed6aaa5)
New changes:
06ad0c769 git-build: Fix name of grunt.log.error
6bed6aaa5 CommentAnnotation: Replace 'reply' with 'comment'

Change-Id: If7e298eaafdd7cf9ab07b6314cb9c214a2072229
2019-12-20 16:22:33 +00:00
jenkins-bot 7452bcca73 Merge "rebaser: Add missing message" 2019-12-20 15:52:36 +00:00
Ed Sanders 90eb775978 rebaser: Add missing message
Change-Id: Id9fbbe47d0e886a235d5fcafefcb768e8c28e666
2019-12-20 15:38:13 +00:00
Ed Sanders f2a5c10dee Update VE core submodule to master (0aa09c12e)
New changes:
0aa09c12e Make CommentAnnotation use replyable threads

Change-Id: Idaadecace168a0c19741a231b887578274902a86
2019-12-20 14:57:14 +00:00
Thiemo Kreuz 326944402d Simplify Hooks section in extension.json
It is possible, but very rare to have more than a single hook handler
per hook in a single extension. The value can be an array or string in
both version 1 and 2 of extension.json.

Change-Id: Idab5bb1ee606fe07c0886c8f6ae180bad1f9a4e3
2019-12-18 08:20:28 +01:00
Bartosz Dziewoński 5f1c68945d Use mw.Api#getErrorMessage instead of custom handling
Bug: T240519
Depends-On: Ie18666b41f4aff1ab4bcf93f9df6e3000ac7b500
Change-Id: I69d9432162f195dcfe9470485b549a1b007617ff
2019-12-14 17:01:35 +00:00
jenkins-bot 95a46f1666 Merge "Exactly match collapsible logic of jquery.makeCollapsible" 2019-12-13 15:42:46 +00:00
Ed Sanders a007781e81 Support wikitext link editing
Depends-On: I3eb2d5ee0da52942db1de75ef9f8b0ae2632657e
Change-Id: I7ad61899a221a198a06e206614d907a331861dbb
2019-12-12 02:33:35 +01:00
James D. Forrester 015f796b63 Update VE core submodule to master (3b3dcad84)
New changes:
7017efbce Sanitize HTML on paste

Bug: T239209
Change-Id: I5f59d537d39b64838a222ab0637957429860508f
2019-12-02 17:26:58 -08:00
Bartosz Dziewoński 092d0c332b MWSaveDialog: Fix error handling for diffs
In case of HTTP errors we'd crash and show no message.

Change-Id: Ideeff4ce75e7ca82ce63bf7ede6dff03eaa1c5d7
2019-11-24 09:51:43 +00:00
jenkins-bot a1b6c47962 Merge "Localize some hardcoded English error messages" 2019-11-19 21:18:04 +00:00
Bartosz Dziewoński a8ab487876 Localize some hardcoded English error messages
Bug: T227325
Change-Id: I5a43b34a4492c20cab4b4ef3eceafaf669e89730
2019-11-19 15:23:58 -05:00
jenkins-bot 2e6e75233f Merge "Remove unused message 'visualeditor-loaderror-title'" 2019-11-19 16:09:11 +00:00
Roan Kattouw eebe4cd993 Unbreak instrumentation of init events
ve.track.js was being loaded twice, once early on as part of the
ext.visualEditor.track module, and again later on as part of the
ext.visualEditor.core.utils module (which it was added to by b676b22).
This caused ve.trackSubscribe()'s buffer to be reset. Recording the
first init event relies on this buffer, because it's logged with
ve.track() before the logger subscribes with ve.trackSubscribe().
Subsequent init events did get logged. Some performance logging during
initialization was also dropped, but the 'ready' event and subsequent
events were logged correctly.

Fix this by loading ve.track.js only once, as part of the
ext.visualEditor.track module. Make ext.visualEditor.core.utils depend
on ext.visualEditor.track, rather than also adding ve.track.js to it.

Change-Id: I781595d27edb2dc0ad662fcc8e3c7cb0ddae78f1
2019-11-18 17:19:16 -08:00
Bartosz Dziewoński 99cd4e26e9 Remove unused message 'visualeditor-loaderror-title'
Introduced in 7653dec439 (2015),
has never actually been used.

Change-Id: I35d06b50fbfdfdfbfdcfd0acbe094895a4f7698d
2019-11-18 15:25:45 -05:00
Bartosz Dziewoński 050227aee6 Remove unused message 'visualeditor-loadwarning-token'
No longer used since a701e87caa (2013).

Change-Id: I7708453ac321a92893a1d92c3082023f9ebe769c
2019-11-18 15:18:36 -05:00
Bartosz Dziewoński c8fa50c3b2 Exactly match collapsible logic of jquery.makeCollapsible
Bug: T236247
Change-Id: Iaf8e8515585989fd8ca64ffd33b02399a69278b4
2019-11-13 23:26:08 +00:00
Ed Sanders 545c6f1301 Add missing FragmentInspector tests to MW
Requires unregistering MWLinkAnnotationInspector

Bonus: Remove unnecessary list of unregsiters as
teardownOverrides is run on init.

Change-Id: I3e36ab7736cc8479ab53f40d2eb24c0fa15d3dc0
2019-11-12 13:52:35 +00:00
Ed Sanders 3542799ab4 tests: Have MWDummyTarget create the correct surface type
Change-Id: I3cd025d726e9db56a2391ef52852d1cb2f4305a0
2019-11-11 20:22:33 +00:00
David Lynch 46e7b3ba19 Config value for X-Parsoid-Variant
Bug: T229074
Change-Id: Ib1403638b12ec5808f6b81bd114949043aa9ac2e
2019-11-05 10:56:10 -06:00
Ed Sanders bfdb664ef7 Add missing dependency for parsing utils
Change-Id: If231b00db6b562fd529c1d0a5143a4613c9835c4
2019-11-04 16:20:51 +00:00
Ed Sanders 381b58585c Factor out save logic into ArticleTargetSaver
Change-Id: I63fa04598e0d703fe1ba715c9c5a0abbb0d7ba5b
2019-11-01 15:45:27 +00:00
Ed Sanders 1bb72f0bb5 Replace deprecated easy-deflate.deflate with mediawiki.deflate
Change-Id: I5c77d4818074fd3dc937d7688d449952b92ee358
2019-10-30 19:13:47 +00:00
Bartosz Dziewoński 372f04fc6f Tweak dependency on 'mediawiki.diff.styles'
It's only needed for the save dialog.

Change-Id: Ifada463e95e2e911161f6ba898de6656412b4f83
2019-10-24 18:35:53 +02:00
Ed Sanders b676b2295b Update VE core submodule to master (3fac5f1f2)
New changes:
8cbedc3c8 build: Update linters
a211e9fd8 TargetWidget: Use surface view focus/blur events
57aeb8b38 Separate utilities required for DOM parsing into separate file

Local changes:
* Setup modules for new parsing utils files

Change-Id: Ie4e59650fdb869e7e4148c97cd03d79ce35187dc
2019-10-23 18:34:17 +02:00
Bartosz Dziewoński 3f0f302577 Enforce that some files must not use the ve global
Previously, the ve-mw/init/ directory contained two kinds of files:
those that were used when initializing VE, and those that may be
loaded even if VE is not going to be initialized at all. The latter
kind must not use the `ve` global variable.

After moving those files to ve-mw/preinit/ we can enforce this with
.eslintrc.json in that directory. This would have prevented T228684.

(Technically they merely must not use `ve.init`, and may use `ve`,
but that's harder to enforce. We should instead move the few non-init
methods out of `ve`: now, track, trackSubscribe, trackSubscribeAll).

Also, group some files under ve-mw/init/: targets/ now (only)
contains ve.init.mw.Target and its subclasses, apiresponsecache/
now contains ve.init.mw.ApiResponseCache and its subclasses.

Bug: T228684
Change-Id: I945249a27f6a0fa10a432d5c5dc57bc7e0461fd8
2019-10-10 15:15:40 +00:00
James D. Forrester 673d2bc657 Update VE core submodule to master (163767591)
New changes:
05306a572 ve.ui.SpecialCharacterPage: Remove unused icon handling
738244b1f Localisation updates from https://translatewiki.net.
7527b151c Upgrade DOMPurify 1.0.10 -> 2.0.0
ff5c1def9 Catch errors when applying initial history

Change-Id: I43c2668ddf1c2a15d724b24532256fc2d222facd
2019-10-01 14:37:01 -07:00
Timo Tijhof aae62a87be Remove cache group setting from styles modules
Follows-up 35eead0f3. This caused an extra stylesheet and HTTP
request to be added to all page views, because
'ext.visualEditor.desktopArticleTarget.noscript' is a styles
module, which should be allowed to join the regular batch.

Also remove it from other styles-only modules known to be loaded
with addModuleStyles().

Bug: T233095
Change-Id: Iea1f33199ec8dc83a42ac7102595a033300e33e6
2019-09-17 19:06:23 +01:00
jenkins-bot cc5a5dfaff Merge "Break up our massive load.php request to work around network issues" 2019-08-30 22:25:16 +00:00
jenkins-bot bc963f4155 Merge "Support for defined template context items" 2019-08-30 18:50:27 +00:00
Ed Sanders e5f5a49344 Support for defined template context items
Context items can be created for specific template titles. Titles
are mapped to context items using an on-wiki message.

Bug: T211243
Change-Id: Icfc39e350452da238d0e0c17cb2305c60d9ca16a
2019-08-30 13:02:47 +01:00
David Lynch 1761b6d6d6 MobileArticleTarget: v1 of toolbar refresh
Bug: T211789
Bug: T230807
Change-Id: Ifd2319039628a8143dc09f6fa35e4a9825d3062c
2019-08-29 15:27:56 +00:00
jenkins-bot dd86fc76aa Merge "Use upstream pulsating dot" 2019-08-28 17:31:52 +00:00
Ed Sanders 7cc538fe51 Use upstream pulsating dot
Bug: T226719
Depends-On: Ibd035ea48b7d0316a7627a91623ff6116ccbae31
Change-Id: Iedf88e9c5ac8efa809ccb25f2081eff9946da395
2019-08-28 13:40:29 +01:00
Bartosz Dziewoński 756572ed8a ve.init.mw.ArticleTarget: Use errorformat=html when saving
When saving fails for a reason we don't handle explicitly, the error
message will have HTML formatting and will respect any on-wiki
overridden messages, rather than being plain text generic message.

Extensions providing custom SaveErrorHandlers may need to be updated.
The only one in Gerrit that requires a fix is TitleBlacklist:
Ibeae79c95557a7af699716c9d921f34c310bee6d.

* Remove handling for errors returned in .visualeditoredit.edit.info
  rather than .errors (.error in old format). AFAIK this is only used
  by some extensions, it is probably incorrect to do (T229539) and all
  extensions I know of that do this (AbuseFilter, SpamBlacklist,
  ConfirmEdit) have custom SaveErrorHandlers.

* Remove custom error messages for 'readonly' (identical to API
  response) and for 'hookaborted' (very unhelpful and there is a
  chance that the API response is better, if the extension causing
  this error generates any error message).

* Add a silly shim for MobileFrontend integration, because we allow it
  to handle error responses, and it expects them in the old format.
  This is probably subtly wrong in many ways, but MobileFrontend code
  only uses this for logging, so it shouldn't explode. In the future
  we will hopefully change it to use errorformat=html (T228897#5366960).

Bug: T229532
Change-Id: I3b9c4fefc0869ef7999c21cef754434febd852ec
2019-08-22 00:37:15 +00:00
Ed Sanders 9a1994e47c Update VE core submodule to master (7cb9caca1)
New changes:
28aea2e4d Edit cards v2 design
739017973 Track usage of the new "close context" button

Local changes:
* Edit cards v2 pull through

Bug: T222396
Change-Id: I1ca885e8d8127e7827a059755315ed789a7b9210
2019-07-25 22:24:48 +02:00
Bartosz Dziewoński 0fb7d5efda Update VE core submodule to 962335a40293cf4b1314c0236788f35f080ae877
New changes:
a06204317 Fix TableNode unit test getOffsetFromCoords failure on Firefox
dfe0eb025 Refactor mobile context logic into ve.ui.MobileContext

Local changes:
* Pull through for edit cards refactor

Bug: T227532
Bug: T228767
Change-Id: I6c043e039fbef62a56f475b0dc365e171ab7bf59
2019-07-23 22:13:27 +00:00
Ed Sanders 393de5985f Update VE core submodule to abf2bfa85e64e67cdf963601fe1da2a11fd9e89a
New changes:
1a7460058 Remove ve.newMobileContext feature flag

Local changes:
* Remove ve.newMobileContext feature flag

Change-Id: Ia8def997b7cba4623866080752b06068d2118cc3
2019-07-23 22:12:48 +00:00
Bartosz Dziewoński a5867818ff MWEditingTabDialog: Don't use ve.init.target because it may not be loaded
We also show this dialog on the old wikitext editor, where
ve.init.target is not set, because the relevant code is not loaded.

Follow-up to 478b0bcbb9.

Similar to e88cd81f94, which fixed the
same issue in a different file.

I checked all uses of ve.init.target in files under ve-mw/init/ and I
think this was the only remaining mistake.

Bug: T228684
Change-Id: I15551870cdb01d570e24ba9668e67330b8072e01
2019-07-23 19:09:37 +00:00
Bartosz Dziewoński 59bc6f6a76 Add dependency on 'mediawiki.interface.helpers.styles'
This module is now needed to correctly display log excerpts,
like in our edit notices popup for protected pages.

Bug: T227190
Change-Id: I19dec69a33a2b3246ff1abe6bec90b2359ac36a4
2019-07-16 20:58:38 +00:00
jenkins-bot 2d25d15a39 Merge "Add number of images to gallery context" 2019-07-15 23:26:30 +00:00
Ed Sanders c958ea383d Add number of images to gallery context
Change-Id: I3e54c6cb2b29ecb1153afd5f2f61adaabceb095b
2019-07-16 01:04:08 +02:00
Ed Sanders fba9585dbf Add validation feedback to external link
Bug: T227899
Change-Id: I165ed59402bdffb63b0c79b68a41d509c4574837
2019-07-15 22:35:46 +00:00
Ed Sanders b64cd4ced1 Update VE core submodule to master (213b79783)
New changes:
6cd9ba63f Localisation updates from https://translatewiki.net.
c9cebed32 Update OOUI to v0.33.2
65c66b8a6 Localisation updates from https://translatewiki.net.
8d94ad13f Replace unrendered parts of the view tree with a stub node
213b79783 Basic unit tests for attachedRoot functionality

Bug: T215717
Change-Id: I7bd8106a82e4fa7c912ce9f8d4fab86bfb546702
2019-07-14 15:26:28 +01:00
Bartosz Dziewoński 35eead0f3d Break up our massive load.php request to work around network issues
I suspect that the size of our singular load.php request (~600 KB
after gzip, depending on the installed extensions) is somehow
triggering the network problems on T213214. To test this theory,
break it up by putting some modules (all that start with
'ext.visualEditor.') into a separate ResourceLoader group.

Now we have two load.php requests (~300 KB each after gzip).
This may increase load times (it will be interesting to see by
how much), but may also fix T213214.

Bug: T213214
Bug: T221197
Change-Id: I0b1a65963267ba52d7962ce31db5a8e6f913322d
2019-07-09 21:35:37 +02:00
James D. Forrester 56df3cc4cb Update VE core submodule to master (75510a515)
New changes:
a3d860daf Localisation updates from https://translatewiki.net.
0421bf6f0 Gather annotations from clicked node where possible
2d2491877 Change#squash: Compact multiple transactions into one
dc0e4650e Fix documentation of ve.dm.Change#serialize
a40f8314f Fix contexedAnnotations equality check
ec62ccb34 Use 16px font size on SA mobile demo
57984c072 Update OOUI to v0.33.1

Add lib/ve/src/dm/ve.dm.TransactionSquasher.js to debugScripts.

Bug: T188026
Bug: T226708
Change-Id: I6eb4ab50ef2c6774963f692f600f059662bf0ac3
2019-07-04 00:31:57 +00:00
jenkins-bot 7796b569c9 Merge "MobileArticleTarget: Prevent unwanted page zooming on focus on iOS" 2019-07-01 16:14:35 +00:00
Bartosz Dziewoński 2563bb3d89 MobileArticleTarget: Prevent unwanted page zooming on focus on iOS
Bug: T216446
Change-Id: I48beb1e120b5b087533b0827904212be9286529f
2019-07-01 15:53:29 +02:00
James D. Forrester 34158b8568 Stop loading oojs-ui.styles.textures, gone as of OOUI 0.33.0
Change-Id: I38aa1ce529bed43175d2ecdcecd1c6a2a0ed603f
2019-06-26 20:54:49 -07:00
Ed Sanders df8feb6faf Move mobile context to bottom of page
Hidden behind ve.newMobileContext feature flag.

Bug: T204733
Depends-On: Id276686a0e82c12c457c81eaec9939722c65c7ec
Depends-On: Id5f7ead769dc30c0fbd2a8b8f6f6c4d68dcfabac
Change-Id: Ibd4b699dfe4bb9bcaec6898b6b82357eb287d128
2019-06-14 20:57:22 +00:00
Ed Sanders 2b7bbf0737 Cleanup mwcore messages and dependencies
* Move many messages from mwcore to articletarget or mwsave
* Delete old unused messages
  - visualeditor-beta-label
  - visualeditor-toolbar-savedialog
  - visualeditor-toolbar-savedialog-short
* Remove unused core messages (showtoc/hidetoc)
* Fix typos in comments

Change-Id: I59455f4cad272db9fd05f45f8a66069e5da0421d
2019-06-11 20:42:01 +00:00
Ed Sanders 7ad624f0a3 Remove switch confirm dialogs
Bug: T220007
Change-Id: I81b39a02d573d96bcb6b4238aabbcd077e874906
2019-06-11 22:35:34 +02:00
Bartosz Dziewoński 8ae4925676 Allow switching from WTE to VE with changes in non-RESTBase mode
* Change the query in ve.init.mw.ArticleTargetLoader#requestParsoidData
  so that in non-RESTBase mode with wikitext it still returns the
  metadata required to initialize the editor, using the backend API
  code added in I1b35b28e428a1f86d2e34d90ddbe73361ce14818. This fixes
  the exception from T222312.

* Introduce new configuration option $wgVisualEditorAllowLossySwitching
  to control this feature. It is enabled by default, fixing T214542.
  We allow it to be disabled because switching in non-RESTBase mode may
  cause "dirty diffs" (non-semantic changes to the wikitext), which are
  undesirable on wikis where users carefully review all changes.

Bug: T214542
Bug: T222312
Change-Id: I58879cba5612002c70c24731306214d2577c2c52
2019-05-30 20:18:53 +02:00
Ed Sanders b1ac5b74d3 Update VE core submodule to master (06f1ebb8e)
New changes:
06f1ebb8e Local/SessionStorage refactor

Local changes:
* Update for core storage refactor

Depends-On: I3cc1d5adfbce794e8345b7f1090c10fb0d42d150
Change-Id: If855ee33b0993788cc159d8c3acf03070e6a9566
2019-05-29 14:49:53 -07:00
James D. Forrester 0e7e88c43e Update VE core submodule to master (d9ece414a)
New changes:
c0799b060 Source mode performance optimizations
d9ece414a ve.dm.MetaItem: Add removable flag

Bug: T96528
Change-Id: Ifc0d3322c0ab0c0384fd179281cb1ed7f3ff6b31
2019-05-29 12:31:24 -07:00
David Lynch 5c7d913f62 Add missing translations from VE submodule
New table context keys were missing from extension.json.

Bug: T211240
Change-Id: I10acc3fc7191441e5c454ed869dc6b1db717b6bf
2019-05-13 11:07:11 -05:00
James D. Forrester 622e77d620 Update VE core submodule to master (6fc2d029c)
New changes:
8df948f5d TableLineContext: add context for the entire table
aae86a822 TableNode: Change mobile behavior so initial tap enters the cell
195d8cb3a Check resizeable node is focused before rendering handles

Bug: T211240
Change-Id: Ib2430c521abb4e59aaa2c5e4f9b26a16437db02e
2019-05-13 13:30:15 +01:00
Bartosz Dziewoński 636531808c ApiVisualEditor: Fix use of getBlockInfo()
The method ApiQueryUserInfo::getBlockInfo() was removed in unannounced
breaking change in MW core: I84ed21641c44b2f65ebe1980b0893d1846db3b34.
Apparently we're supposed to use the method from ApiBlockInfoTrait now.

Bug: T209599
Change-Id: I7ab5492310980b1527c7329faf65655330b8bef0
2019-05-08 22:36:38 +02:00
Ed Sanders c035073cf9 Fix abandon edit warning message
This message was upstreamed to core and later renamed.

Use the upstreamed dialog itself when switching sections.

Bug: T222525
Change-Id: Ibd2d75ec503e92b5ddec2105f762b0c9f0dc96fb
2019-05-06 15:11:58 -05:00
Ed Sanders f9330c8564 Replace the save button with a save tool
Now shows correct tooltip for save button (including
the access key).

Bug: T163142
Change-Id: If14a1a5a5829fc215cb79827392173dc05c4bdd7
2019-04-30 19:32:33 +00:00
Ed Sanders a7149cc3ee Update VE core submodule to master (7cd15cfe9)
New changes:
9b162a5da Localisation updates from https://translatewiki.net.
10dbdabf4 Remove valid-jsdoc exceptions for @chainable
a424f804d Make blockquote a non-content branch node

Local changes:
* Update stuff for making blockquote a non-content branch node

Bug: T76426
Change-Id: I95ae25f20d3d102da69bf5ffdff55335f6c07635
2019-04-22 12:39:14 +01:00
jenkins-bot 8401da1073 Merge "Move autosave logic up to mw.Target" 2019-04-18 22:36:47 +00:00
Ed Sanders 1123c1eadc Move autosave logic up to mw.Target
This would allow non-article targets to implement
autosave more easily.

Change-Id: Icc945575d0982cf82647c9078caf9a39bb715c2e
2019-04-18 15:21:33 -07:00
jenkins-bot ebe04bb856 Merge "Apply styles for WikimediaUI theme by default rather than only Vector and Minerva" 2019-04-17 19:13:41 +00:00
jenkins-bot b17acda9b6 Merge "Remove unnecessary duplications of 'default' theme files" 2019-04-16 15:47:56 +00:00
Bartosz Dziewoński b1d3fdbb0c Apply styles for WikimediaUI theme by default rather than only Vector and Minerva
They will now apply for other skins not mentioned here, e.g. Timeless.
The most noticeable change is proper styling for target widgets.

Change-Id: Ibf4c080aaaeedd65144ac5e95ed2f48a1cd17635
2019-04-16 17:35:56 +02:00
jenkins-bot 7197fd49c3 Merge "Update VE core submodule to master (6590e0ac5)" 2019-04-16 14:58:46 +00:00
Timo Tijhof cc599c2e36 init: Bundle wgVisualEditorUnsupportedEditParams with DesktopArticleTarget.init
Bug: T219342
Change-Id: I4b5a048779bd4b957cc5d99c3a7686363ffb3df9
2019-04-16 16:33:53 +02:00
James D. Forrester 51b68049d1 Update VE core submodule to master (6590e0ac5)
New changes:
6590e0ac5 Create generic command to move focus to context

Change-Id: Iba309ca5f7299f4157a3a43836064e17b5f4d62b
2019-04-15 14:13:42 -07:00
jenkins-bot 1b2c1425ee Merge "Allow external link pasting to be enabled by config" 2019-04-09 16:05:26 +00:00
Ed Sanders c1bc3f00e0 Remove unnecessary duplications of 'default' theme files
Change-Id: I52b4851a44ad9e472f006d4a892d8cc54c7ab5db
2019-04-05 14:47:58 +01:00
jenkins-bot 96dfb99016 Merge "Edit summary autocomplete" 2019-04-04 17:44:36 +00:00
Aaron Schulz 1a5fc05dda Avoid keeping excess keys from storeInSerializationCache() in cache
Remove overkill $VisualEditorSerializationCacheTimeout config setting
and just use a simple constant instead (convention over configuration).

Bug: T203786
Change-Id: I94424088a03a3262fcea30132883a612465c546e
2019-04-03 18:34:07 +00:00
Ed Sanders 1ffb574450 Edit summary autocomplete
Bug: T50274
Change-Id: Ida462f3dea325902459546af97e66cd9d0c86166
2019-03-09 14:03:27 +00:00
Ed Sanders 2092529fb1 Allow external link pasting to be enabled by config
Bug: T129546
Change-Id: I3346c842cf56fb79fb65a8bd7d716c22134636b9
2019-02-27 19:54:55 +00:00
Ed Sanders 18907dde5a Implementations for read-only mode
Depends-On: Ifaa74be266c048d87f94b4ae2df59cafc7aa155f
Change-Id: Iedd1bd9ce17750ad8528c1a053293c4a7321c5de
2019-02-22 18:20:51 +00:00
Ed Sanders e21d4fab3f Update VE core submodule to master (2951e9378)
New changes:
202adf904 [BREAKING CHANGE] Unify FragmentInspector/Dialog behaviour

Local changes:
* Update dialogs to use common actions & FragmentWindow

Change-Id: Ib744b8996db48d1ee58bc873120400566c490e88
2019-02-22 01:13:36 +01:00
jenkins-bot 8846e65e44 Merge "Support only surfacing part of the document" 2019-02-20 19:06:30 +00:00
James D. Forrester f6a9dc8d85 tests: Register TestModules via extension.json
The 'ext.visualEditor.test' module is no more.

Change-Id: I25e047ca4de7d9082a5a86efa0ea0d403dc1b0fb
2019-02-13 21:55:41 +00:00
Ed Sanders 3269d53632 Support only surfacing part of the document
Bug: T76541
Depends-On: I227a0d704b9b337cff2102d424be9795d6362ed7
Change-Id: Iac71a51c8696434658f24fbb41c8142237bd810e
2019-02-13 19:03:44 +00:00
Bartosz Dziewoński 6e076b3b6c DesktopArticleTarget: Make the progress bar into a reusable widget
We want to add a similar progress bar on mobile without copy-pasting
all this code.

Bug: T210630
Change-Id: I7192869cb719114ffd04940eabf38cf0f0421c13
2019-02-06 22:20:37 +01:00
James D. Forrester c1d690e53d MWTemplateTitleInputWidget: Filter out templates named '…/doc'
As configured on-wiki via MediaWiki:templatedata-doc-subpage; this will
probably have a few false positives, but that's worth it.

Bug: T54448
Change-Id: Id91f95b5865e151f8007a2421428aeb82b11b3fd
2019-01-26 13:23:38 -08:00
David Chan 0d362040bd Update VE core module to master (469c6340e)
New changes:
6515e03e1 ve.ce.Surface: Rearrange #findBlockSlug test to check other cases
cbfdc8570 Localisation updates from https://translatewiki.net.
708ba0557 Prevent block slugs from overlapping floated elements
3703fd66d Separate the concept of a document node and a root node in CSS

Bug: T211844
Change-Id: Ia86cf9b23e561d3c32601d41c1bc5a9824e9953c
2019-01-06 07:47:17 +08:00
Ed Sanders 85974b171c Bring back 'alert' indicator
Was removed upstream in OOUI, but we require it to
show that parameters are deprecated.

Resize to fit new 12x12 size for indicators.

Change-Id: I2356de0754a2ccf09b87b152f3023282f2e37f41
2018-12-11 14:25:48 +00:00
Ed Sanders 278789e27d Remove TitleBlacklist handling code
This has been moved to the TitleBlacklist extension.

Bug: T211242
Change-Id: Ia15c2619e6c642b3ceb567c28f77b50ccf41731a
Depends-On: Ibaf8a37f1aaef510923bde5ed9114f1f00fff461
2018-12-06 15:00:06 -05:00
Ed Sanders 041e7b77a1 Create SaveErrorHandler class to better define structure
Change-Id: I036ee32847cc3b25a1cc478247cfe54599781098
2018-11-29 15:47:03 +00:00
jenkins-bot fc126c1260 Merge "Rename configs for tracking block notices on visual editor" 2018-11-29 00:43:31 +00:00
Thalia 2516753c53 Rename configs for tracking block notices on visual editor
* Also make sure block notices have type 'block'.
* Remove old flag for tracking since we'll be using one
  from core

Change-Id: I4b66e73c8a4c4dd7bffd7c0239b1d5ec06eed12f
Depends-On: I6bd1c95548616677e1f72ba6bcfc6f2b551c1ca6
2018-11-28 15:26:15 -05:00
Ed Sanders 0d54a62858 Use mw.Title.wantSignaturesNamespace
Change-Id: I60187f0a3eb9cf5d56a4fdaa3401b107758bd8e3
Depends-On: Ib2faa22c429096d545ddb829a6b4025427ad6071
2018-11-27 18:42:44 +00:00
jenkins-bot 44fcea9f65 Merge "Track when block notices are returned on the api" 2018-11-20 22:31:27 +00:00
Dayllan Maza 3269bb136c Track when block notices are returned on the api
Tracking is behind $VisualEditorTrackBlockNotices config flag
which is set to false by default. Additional data will be logged
into a different bucket on the client and both metrics will be
considered with their known limitations.

The reason behind this is to get an idea on how frequently blocked
users attempt to edit a page. Similar tracking is being added to
MobileFrontend and mediawiki/core.

Bug: T201718
Change-Id: I51576276b97be0716c2c22348eaa756ffb04fe50
2018-11-19 23:02:02 -05:00
Bartosz Dziewoński 7bcb1ac50c Update VE core submodule to master (f32c0be7c)
New changes:
61992def0 Remove dedicated annotation operation types
c18308313 Move 'enter' and 'f2' keydown handlers to command/trigger code

Bug: T205535
Change-Id: Ibbf578070c820ae63a8b8ab50e6e4520cabfebe6
2018-11-08 13:45:21 +01:00
Ed Sanders ff1a05e245 Bump version number due to recent breaking change
Specifically I715ae805f, which changes the signature of
ve.dm.*Selection objects.

Change-Id: Iffa657179dd8a126e9f16787f3b33743f6e3d489
2018-11-07 16:50:35 +00:00
jenkins-bot 73deda8f66 Merge "ve.init.mw.DesktopArticleTarget.init: Move Vector styles to separate file" 2018-11-07 13:18:47 +00:00
jenkins-bot 07856d2a16 Merge "ve.init.mw.DesktopArticleTarget: Edit surface padding and gutter for Minerva" 2018-11-07 13:18:42 +00:00
jenkins-bot 45c9ff5e21 Merge "ve.init.mw.DesktopArticleTarget.init: Make multi-tab mode compatible with Minerva" 2018-11-07 12:26:38 +00:00
Bartosz Dziewoński b0c0553dc2 ve.init.mw.DesktopArticleTarget.init: Move Vector styles to separate file
Change-Id: Iecf25bf71c1e4fca8964d608082e42ef0c929044
2018-11-06 16:47:31 +00:00
Bartosz Dziewoński c87b010da0 ve.init.mw.DesktopArticleTarget: Edit surface padding and gutter for Minerva
Bug: T208102
Change-Id: I0a43550c938144f79f04dc91c2c742229f939177
2018-11-06 16:47:23 +00:00
Bartosz Dziewoński 5996cf15e9 ve.init.mw.DesktopArticleTarget.init: Make multi-tab mode compatible with Minerva
* Make inserting secondary tab work with Minerva's non-standard structure
  of navigation menus
* Distinguish primary and secondary tabs with tiny icons, since Minerva
  hides their text
* Hide section edit link dividers (unnecessary when we use icons)

Bug: T208102
Change-Id: Ieaec60165617e3b423ec58857d6f0a0406e22b1d
2018-11-06 17:45:48 +01:00
jenkins-bot 314bfdfc3e Merge "Missing dependency resulting in a missing icon" 2018-11-05 21:56:26 +00:00
jenkins-bot 3f97176f7c Merge "Use upstream AbandonEditDialog" 2018-11-05 18:19:23 +00:00
Seb35 951fa31a7c Missing dependency resulting in a missing icon
Bug: T208686
Change-Id: I0780a66bc70fe25154322c256958cea0c67613c2
2018-11-04 18:47:07 +01:00
Roan Kattouw 817987466d Unbreak input debugging images
They're the only thing in ve.ce.debug.js, and that file is never loaded
by VE-MW.

Change-Id: I22e64dc55a4b9d44728a235cf9edf4019504cbc2
2018-11-02 10:58:36 -07:00
jenkins-bot 9ac196777a Merge "Blocked apply if redirect address is invalid" 2018-11-01 22:17:03 +00:00
flutters f847880292 Blocked apply if redirect address is invalid
Extracted extractValue to a separate method
Added checkValidRedirect method to MWSettingsPage
Added errors when redirect address is invalid
Added 1 error message to localisation strings
Added 1 TODO (more precise error messages)

Bug: T74971
Change-Id: I8bcf16e97e5211671759acdf0846243df2c03fc2
2018-11-01 21:20:01 +01:00
Bjornskjald 9490ff370c
Update the styles for VisualEditor's "Format" dropdown
Now when using the MonoBook skin, the text size for headings inside the dropdown is the same as their size on the page.

Bug: T72559
Change-Id: Ie0c30369021f8022b788730a6de90e44a288b13b
2018-11-01 20:40:56 +01:00
Ed Sanders eab2b728e9 Use upstream AbandonEditDialog
Bug: T192333
Depends-On: Ib581528363a3fe5461529515835bd7fb1ce66e56
Change-Id: I206366e096aafc02102357648b9f85f879479500
2018-10-31 13:38:31 +00:00
Bartosz Dziewoński 9e47873a65 Update VE core submodule to master (236effcd7)
New changes:
0e923fe1b Use initClass in test class
900962720 Add ve.deepFreeze for detecting inadvertent data modification during testing
0761cd90c Localisation updates from https://translatewiki.net.
0e44545b7 Update .gitignore
82b6b80bb Use consistent method for finding nearest cursor offset
0b604de30 ve.ce.TableArrowKeyDownHandler.test: Remove eww gross FIXME

Bug: T202359
Change-Id: I73c46edfbf66a0c76bc719010c017ef71670931b
2018-10-30 00:50:37 +01:00
jenkins-bot a022a27a30 Merge "Simplify handling of messages for section edit links" 2018-10-29 11:02:37 +00:00
jenkins-bot 9a5840d96d Merge "Define localisation messages for File namespace edit tab in visual mode" 2018-10-29 11:02:10 +00:00
Bartosz Dziewoński ac45e919ab Update VE core submodule to master (d89186159)
New changes:
d89186159 Add F2 keydown handler

Bug: T172042
Change-Id: I3bc2bb33bec2f5f08f26af49ab8b72e436dbe4cf
2018-10-24 20:51:36 +02:00
Bartosz Dziewoński aa137ef2ad Move styles that are not theme-wide out of themes/
Reasons why these files should not be in a directory named "themes/":
* They are specific to MediaWiki skins, not OOUI themes
* They are specific to one module, rather than affecting many widgets

The new locations/filenames are consistent with other modules that
have skin-specific styles.

Note that we have one more themes/ directory elsewhere in this repo
(and another in VE core) and that is okay.

Bug: T96704
Change-Id: I70bb61e339aeccb3afea657f665785ceaa091777
2018-10-23 05:04:27 +02:00
Bartosz Dziewoński 62273183a8 Simplify handling of messages for section edit links
Change-Id: I5b84fc3863747b4d092a7025475730bb28efeff2
2018-10-13 03:16:53 +02:00
Bartosz Dziewoński 6540bbd422 Define localisation messages for File namespace edit tab in visual mode
I think we must have not been allowing visual editing of File pages
when this code was written?

Bug: T206892
Change-Id: If38642492825877c4b65e395a00b789acdc27eef
2018-10-13 03:14:40 +02:00
Volker E a5a3d829a9 Update user avatar icon and make use of OOUI's built-in
Bug: T123810
Change-Id: I3ed04d3037836b47706d9f7284eeb9668712bdcb
2018-10-10 18:34:27 -07:00
Bartosz Dziewoński e354092417 Update VE core submodule to master (f9afaa3e4)
New changes:
3931cc33a Update OOUI to v0.29.1
5bcab0073 Move node-specific code into rebaser/
8aa80d88b Remove ES6 support for async/await
2536870f9 Separate files for protocol and transport server
b443b7a4f Update OOUI to v0.29.2
70b3ec210 Minor cleanup of ve.ui.MediaSizeWidget

Bug: T206236
Change-Id: Id3bbcd1a9ccb1563e4feb3572aa8f51932677693
2018-10-09 11:06:23 +01:00
Ed Sanders d44e7fb3e8 Mobile target improvements
Change-Id: If55097a45ae812b712a74f41af350bfaa69f6135
2018-10-07 12:47:53 +01:00
Ed Sanders 29b277260f Fix OOUI->MW theme mappings in extension.json
Bug: T206002
Change-Id: I1fcafa397d1054f4d380a60e0ba46c4ece34c7f0
2018-10-03 22:17:49 +01:00
James D. Forrester 22b40aeb2c Update VE core submodule to master (1191c3687)
New changes:
8a7a3f8a5 Fix margin override on block slug
786cb5266 ve.ui.MediaSizeWidget: Fix conditions for when we need error messages
1829982ed ve.ui.MediaSizeWidget: Remove "Make full size" button
1191c3687 ve.ui.MediaSizeWidget: Remove comments about full size button

Bug: T205645
Bug: T205874
Change-Id: I5c87c18088e754ec95bcf36775d046bb92870aa8
2018-10-02 12:18:50 -07:00
Bartosz Dziewoński d094bfa0d0 ext.visualEditor.mwlanguage: Actually load all of the code
Follow-up to bbed4307d7.

Bug: T205834
Change-Id: Idb2febd210891b62976919cd7c6a04784c156807
2018-10-01 20:37:04 +02:00
Bartosz Dziewoński 9cf5515ccb ve.ui.MWMediaDialog: Remove unused widget and messages
* visualeditor-dialog-media-size-originalsize-error
  Unused since 37b3c07b26.

* visualeditor-dialog-media-originaldimensions
  Never used (introduced in 4947420650).

Change-Id: I22f37b457cc6fbac03593fece003e97f4f5a2ccf
2018-09-27 18:31:20 +02:00
Thalia 9813d876e1 Enable the media dialog on mobile visual editor
Also make improvements to the layout, so that the dialog works
in desktop and mobile - most importantly, change from booklet
to index layout.

Bug: T190885
Bug: T118710
Change-Id: I1915d06c9b0e4b7907136e645f60be96e30cc287
2018-09-27 13:21:15 +01:00
Amir Aharoni d80c383ad2 Move VisualEditor apihelp/apierror messages to a separate i18n file
Should be merged along with the corresponding translatewiki change:
I89310a638e75f974af77db313bb9ca090c437bf2

Change-Id: Ie5be8dc09051907d3aea53e33bdd1b3f849ead1e
Big: T189982
2018-09-26 01:53:54 +03:00
jenkins-bot c68b0d9ea0 Merge "Update VE core submodule to master (2d668bdbb)" 2018-09-24 16:07:22 +00:00
Ed Sanders 1631a35c18 Update VE core submodule to master (2d668bdbb)
New changes:
2d668bdbb Separate node classes into individual files

Bug: T205231
Change-Id: Ib628149732e40b139876404867253d0ffa1fb0d0
2018-09-24 08:27:23 -07:00
Thalia bbed4307d7 Separate node classes into individual files
Bug: T205231
Change-Id: I84a6f2f7a842ab44e1f7103c0f288deda0451e79
2018-09-24 12:44:45 +01:00
James D. Forrester a70051d75e Update VE core submodule to master (7c9ceb939)
New changes:
bdd52111a Collapse this.getSurface().getView() to this in ve.ce.Surface
012f77c87 Localisation updates from https://translatewiki.net.
c40692bf5 Use rooms instead of namespaces
31360982e Fix author list when reconnecting
c176f8bba Remove $.isPlainObject warning
ad9edb87a Separate core module into model/view/ui
4475785d5 Merge author name/color data, make naming consistent
8601509c4 Move whitespaceHtmlCharacters to ve.utils.js and rename
361e5d646 Call parent in DimensionsWidget#setDisabled
3a53ca899 Update eslint-plugin-html to 4.0.6
5f88a02bc Allow '/' in path
2ad8dc94d Separate out client-specific utils from ve.utils.js
e8eb8dc97 Fix ve.sanitize to only depend on utils
cdcd7f19b Update UnicodeJS to v0.2.2
689baa436 Report html indent errors
d613e9d48 Create get/setSessionObject methods for JSON storage

Bug: T195111
Bug: T205096
Bug: T205123
Change-Id: Ia519138734ca0c174c20fec2d42f1437c903b82d
2018-09-23 13:53:29 -07:00
Ed Sanders 164ccecf4d CollabPad: Show current sub-page as separate tab
Change-Id: I15da5a3122e7a0dfeb5131e528efa498a7cd1356
2018-09-17 16:25:42 +00:00
Ed Sanders 7eb836adbc Update VE core submodule to master (7420443fe)
New changes:
a273ba69c [BREAKING CHANGE] Implement a SourceConverter

Local changes:
* Use SourceConverter
* Handle `this.doc` being a string in source mode now

Bug: T203114
Bug: T203156
Change-Id: I7bce7b57668e0c1dd511803a54178ae69694a86d
2018-09-14 11:42:34 +01:00
Bartosz Dziewoński 6ba42c6f12 Update VE core submodule to master (7926154e3)
New changes:
8fd23db41 Fix MediaSizeWidget#setDisabled: Call parent method
545f03b12 Don't trust client-supplied docName
e718ee115 Localisation updates from https://translatewiki.net.
a2aeb1c36 Update jQuery 3.2.1 -> 3.3.1
8d6ccce61 Fix alignment in visual editor table dialog

Bug: T203467
Bug: T203889
Change-Id: I91393ab3eb50cb3c320a406d880fcb459a03ad4b
2018-09-10 14:18:44 +02:00
jenkins-bot 048ac8193e Merge "Remove unnecessary IE10 blacklist" 2018-08-31 18:30:07 +00:00
Thalia 58f6fb8910 Add description link message for gallery dialog
Bug: T203262
Change-Id: Ic9ab5ffe5c4f8ea60cb7e9abf6ebea210aeef645
2018-08-31 17:38:42 +01:00
Ed Sanders 10ce48a57e Remove unnecessary IE10 blacklist
IE10 support was dropped from MediaWiki core in 1.31.

Change-Id: I1c8c790428df5afe019e10a65ba5e891f5895dfb
2018-08-30 19:01:59 +01:00
jenkins-bot bf9d3c1b06 Merge "Template dialog: Lazy resize multiline text inputs on first focus" 2018-08-27 20:43:38 +00:00
Ed Sanders 0f81aae133 Template dialog: Lazy resize multiline text inputs on first focus
Bug: T134814
Bug: T200834
Change-Id: I3ec84ad01db1ed896c41ac8ef38cce8eddb0b8c2
2018-08-23 17:34:25 +01:00
James D. Forrester f4ad32173f Update VE core submodule to master (2f4c0537e)
New changes:
a80089a36 Add missing command help registration for HR tool
330311722 Define command group order separately
35ea5b8f0 build: Bump `grunt-css-url-embed` and `karma` to latest to avoid security issues
31b134668 Cursor into table captions if present, instead of the first cell

Bug: T201870
Change-Id: I4e3a946a992a07215a3af8351c3b54ceae664d40
2018-08-22 11:36:01 -07:00
Ed Sanders cb10316a7b Export to page using action=submit
Change-Id: I0d719905203d24a545d9b7dcea5bb9d032f10a76
2018-08-19 11:25:17 +00:00
Ed Sanders 5be3be4ba4 Store importTitle in document, and display in sub heading
Change-Id: I431b721d8af3180b78a565e322a45745d06f67a1
2018-08-12 16:13:00 +01:00
Bartosz Dziewoński 1c3bad67c5 Update VE core submodule to master (086de2707)
New changes:
9aecc6946 Add CheckList type
be0469524 Allow cursoring between active nodes
954b21f33 Localisation updates from https://translatewiki.net.
38e1e7667 Do not try searching outside of valid range when using regex
deec79971 ve.dm.TransactionProcessor: Fix edge case handling, avoid ES6 methods

Bug: T196521
Bug: T200455
Bug: T200525
Change-Id: Ie87e19d13c68425f5d46bd1be5121c9169c2ebf4
2018-08-01 00:12:29 +02:00
jenkins-bot b487c3f9a4 Merge "CollabTarget: Add convert to wikitext dialog" 2018-07-28 16:06:36 +00:00
Ed Sanders a6ea005f15 Remove EasyDeflate libs, upstreamed to core
Change-Id: I70ac6669038238b91eba8484792b75b09e7355d4
Depends-On: I12a5879188f46f17dc4c33bdad52317d218d4172
Depends-On: I0fa382c2828ff2644ed308dc1ccca85735d0a80d
2018-07-26 18:18:52 +00:00
Ed Sanders 5b043520c0 CollabTarget: Add convert to wikitext dialog
Change-Id: I49841fd17dd106154a2f53df2e051c6dc0cc3910
2018-07-26 10:46:12 -04:00
Ed Sanders 0f06ad2d76 Add missing debugbar message
Change-Id: Id95bf914601c75eba120e2c0fa14a869ed26c960
2018-07-21 14:13:53 +02:00
Ed Sanders ff10c01687 Update VE core submodule to master (d2a120e66)
New changes:
35eaf8209 Move annotation nail functionality to a mixin
d2a120e66 Rebaser: Create a multi-user flag on the surface model

Change-Id: Iffad3c90a9b8ac08f646721bfdbc0503cea2890b
2018-07-19 13:22:25 +01:00
jenkins-bot d18e9e964f Merge "Add missing rebaser messages" 2018-07-19 10:32:02 +00:00
Ed Sanders 8a6f592884 Add missing rebaser messages
Change-Id: I3f969abfc5899350854bf105ef1b16d35ccdc062
2018-07-19 11:02:05 +01:00
James D. Forrester f08eb6028a Update VE core submodule to master (8d0ab0587)
New changes:
cd6932096 Fix rebaser dependecies
bdcbf8f81 Rebaser: make the server synchronous again
52e6873b1 Cleanup rebaser
31ef4c5ec Handle authentication and reconnection
22d6feea3 Squash Changes to use fewer transactions
4d93f0819 Fix confusion between #getSetupProcess and #getReadyProcess
8d0ab0587 Localisation updates from https://translatewiki.net.

Bug: T185745
Bug: T185944
Bug: T188026
Change-Id: Ie33d3dd4746c9c91fe676f140f416af72ac218b0
2018-07-18 02:54:07 +02:00
jenkins-bot ffaab335ce Merge "Move some styles from mw.ArticleTarget to mw.Target" 2018-07-16 23:16:56 +00:00
James D. Forrester 3160429959 Follow-up dfe27be: Add missing i18n keys to manifest
I thought I'd done this. I didn't.

Bug: T198064
Change-Id: I1c78ce957f26e8c297d97d6f78b3451600b4657c
2018-07-10 15:55:56 -07:00
Bartosz Dziewoński 6db1fd41ef Move some styles from mw.ArticleTarget to mw.Target
They look like they should also apply to Flow, ContentTranslation, etc.

And apparently CollabTarget was already loading them separately.

Change-Id: I5c502f8e060968ecee67567747f29eb630cda718
2018-07-05 18:01:10 +02:00
David Lynch 56a3aa9f01 Update link contexts with label info from core
Bug: T124305
Depends-On: Iad48fb559f3dae16cc0013791b79ec71308a1f9f
Change-Id: I341a15199bddb45e2cd8391b9b00c86e1c3a193e
2018-06-26 21:16:53 +00:00
jenkins-bot 7e72ef63e4 Merge "Update VE core submodule to master (52bd0592b)" 2018-06-22 07:29:20 +00:00
Ed Sanders 47e6e3f6b1 Update VE core submodule to master (52bd0592b)
New changes:
c5df99d3a Remove remaining assert.expect's
593b09992 Localisation updates from https://translatewiki.net.
14a29056c Follow-up 593b099: Add 'lfn' language to build to unbreak the repo
faba29bde Fix cursor position when adjacent to a nail
9854cc88c Sanitize message body in standalone using DOMPurify
52bd0592b ve.dm.Change: Store DOM node arrays as single strings

Local changes:
Add sanitize module

Bug: T197723
Bug: T197894
Change-Id: I572f5bcc80175cc50ef176efb961c9b10b38c7f0
2018-06-22 09:12:35 +02:00
Ed Sanders 963289bd1b Add missing rebase client message
Change-Id: I6c60c25752df356d61fcba5caad05062c7519607
2018-06-21 11:52:49 +01:00
Ed Sanders 040a7e6635 Move apierror-readonly message to ArticleTarget module
Bug: T197498
Change-Id: I5f7d189918b5e699678321ebf7d15481ec6d2684
2018-06-16 14:19:26 +01:00
Ed Sanders a7049dacea Update language variant node to use new invisible icon API
Bug: T195887
Depends-On: I4eab7b9edf04454ef1a62535656b179480c3054b
Change-Id: I655757b13514e8ff89c312dcc2e1147d188a2718
2018-06-04 17:34:22 +00:00
jenkins-bot 6c90442326 Merge "ce.MWWikitextSurface: ask on paste about wikitext conversion" 2018-05-24 17:21:07 +00:00
jenkins-bot f805169fdc Merge "Remove dependencies on deprecated modules 'mediawiki.api.*'" 2018-05-23 19:19:19 +00:00
jenkins-bot 514189b7d1 Merge "Separate save dialog from article target module" 2018-05-23 17:15:49 +00:00
jenkins-bot c99c96e805 Merge "Allow CollabTarget to load on mobile" 2018-05-23 17:01:57 +00:00
Ed Sanders ab59f3d06f Update VE core submodule to master (d214a66aa)
New changes:
aa8b2d3da rebaser: Clarify document name is optional
eb4955b84 $.isEmptyObject -> ve.isEmptyObject
681fa50e1 Don't use $.isNumeric in DM
0c8483d8a Avoid more jQuery in DM
a9f6bef78 Replace $.extend with ve.extendObject
34eb4311d Initialise socketIO twice to avoid query cache
b70cb7520 Teardown synchronizer
8f829895f Use passive event listeners
f9e84fa8b Localisation updates from https://translatewiki.net.
db24bb81c ve.ce.FocusableNode: Fix minor code issues
ae981404e Rebaser: show connect/disconnect in the server console
0118e89c2 Show progress bar while connecting to rebase server
160bbe5fd Use new name for 'comment' icon, 'speechBubble'
fb549248a Remove unused APIResults* objects
5daa71d7e Remove IE9 support comment

Bug: T178371
Bug: T195111
Depends-On: I186ebd9d63299d828692a745b62fbc4314a4ed4e
Change-Id: Ie0fee3d4cc069383b8cb48e7d6c2ff520fedb590
2018-05-23 09:01:07 -07:00
David Lynch 4d263afaa2 ce.MWWikitextSurface: ask on paste about wikitext conversion
Throw a dialog box up to ask whether to convert something with formatting to
wikitext, or downconvert it to plain text.

This logically depends on Ie9aaaa59e9dfa138d394051fe491573253df1805.

Bug: T190079
Change-Id: I6afbbe303d1506426109e75c95f6be546ec48536
Depends-On: Ie9aaaa59e9dfa138d394051fe491573253df1805
2018-05-23 08:08:22 -05:00
Ed Sanders 2cd7abf88b Allow CollabTarget to load on mobile
It's not great, but it works, so allow people to at least
experiment with it.

Change-Id: Iaa54189f7aa63b0bd029dd25a898db54119eff70
2018-05-22 22:39:36 +01:00
Fomafix a64468ad0d Remove dependencies on deprecated modules 'mediawiki.api.*'
In core the modules 'mediawiki.api.*' get merged into 'mediawiki.api'
and get deprecated in ecc812f06e included in MediaWiki 1.32.

Change-Id: I6cc2023beea0b0d0801733906959325d781a2915
2018-05-21 13:46:15 +02:00
Ed Sanders ed3492acbd Separate save dialog from article target module
Change-Id: I3d1af81b3023f11f53806091cc70f51e90665e42
2018-05-20 19:42:46 +02:00
James D. Forrester 44acd98903 Update VE core submodule to master (511911451)
New changes:
463169fd1 Re-emit 'initDoc' from synchronizer
eed2af89e Fix RTL mode in demo
700ab1015 Follow-up I6abf7535: Call parent method in onPopupToggle override
e04433acc Fix tests for new qunit package name
9a12ca4fd ce.Surface: Refactor afterPaste
a763ad892 Add 'safe' flag to language dialog 'back'
9aa90f26a Remove nested fields from LanguageInputWidget

Bug: T190079
Change-Id: Ifbc8aafb93867e8960fc270da02793e3363b36f5
2018-05-19 19:24:45 +02:00
Ed Sanders 0fe6c53b2e Import button for CollabPad
Change-Id: I1f454fb7914b2de0cb5f393aeed9001b6a5a2e40
2018-05-19 19:42:35 +08:00
James D. Forrester 9e52ece21f Update VE core submodule to master (1d341ca7d)
New changes:
3a6d868bf Separate (Comment/Link)InspectorTools into separate files
cb5d36e32 Localisation updates from https://translatewiki.net.
c75491b16 build: Extend 'svgmin' options and amend
ddef270d9 Genericise activeLink behaviour to any annotation
d13d44e12 Create simple comment annotation type for rebaser.
7e49a1f33 Add getters for author properties
1d341ca7d Follow-up I16942623d: Only filter inactive models if they are 'canBeActive'

Local changes:
Change .ve-ce-linkAnnotation-active > .ve-ce-linkAnnotation.ve-ce-annotation-active

Bug: T185596
Change-Id: I2a49315d01aa075373f9b5f0d8802a7e7dd4dca3
2018-05-18 17:07:28 +02:00
Ed Sanders 70cd11e32d CategoriesPage: Remove unnecessary input widget width
Change-Id: I7fa38b866d0489de612b0ed08cf0b9eb3b9b71af
2018-05-16 18:04:08 +01:00
jenkins-bot d70ddfb85a Merge "Use better align change descriptions" 2018-05-16 09:49:05 +00:00
jenkins-bot 4ca3f1661d Merge "ArticleTarget: Change rendering of category preview" 2018-05-15 13:28:57 +00:00
Ed Sanders 7254fbe2cf Use better align change descriptions
Adds support for align=none.

Also don't show changes from class names.

Change-Id: Ia00a51dd52af73183e98c8a87f4c60ee5380d81f
Depends-On: Ic668454c4b4b069dab46a608530c85a5bb7e7ad8
2018-05-15 11:57:33 +00:00
David Lynch 5d19272aa1 ArticleTarget: Change rendering of category preview
Just generate the standard wiki skin markup for categories. Adjust linkcache to always know
whether links are hidden categories. (It previously knew *sometimes*,
depending on whether a MWCategoryWidget had interacted with that category.)

Make the save dialog preview use the same method as the bottom-of-editor preview.

Bug: T194092
Change-Id: I37fea15eaef0a5847f27ce41dd92370a4bf353b6
2018-05-13 16:40:59 -05:00
Ed Sanders 60e129062a Add missing mw-content-(dir) class to MWPreviewElement
Also allow preview elements to existing with an mw-body-content
area withouth the font size being applied twice.

Depends-On: Ibbf989dcebf2d21fd2ac481f17062f366ff29e41
Change-Id: I284bcd5dd25cdbb883427ebacb41af1bbf50b60f
2018-05-11 16:59:12 +00:00
James D. Forrester 99a226020e Update VE core submodule to master (b8c05e38c)
New changes:
1d0130404 Move logic for creating a view node into ve.ce.NodeFactory
3db54b22a Improve behavior of newlines and non-text content elements in find-and-replace
11f9ea9d0 Create a quick 'useView' mode for PreviewElement

Bug: T94130
Bug: T184163
Bug: T188651
Change-Id: I7fc539f75a1c9d672efc139b7884ecdfdff5f301
2018-05-11 09:54:06 -07:00
Ed Sanders 86fdda21c6 Remove some no longer required CSS from switch popup
Change-Id: Ic965c147b195b4546f8f1e7d36395c96597a159e
2018-05-07 21:35:24 +01:00
Ed Sanders 8bddec44e3 Create an MWSurface and move langChange handling there
Change-Id: I8a75b5f431f454b66441fc301b90e5f28636612e
2018-05-07 11:53:23 +01:00
Ed Sanders 4346e339f6 Get rid of mwdiffing module
No longer needed now visual diffs are out of beta.

Change-Id: I75cc7a6f3ecd3c5a547685aa4db586abfa482f2d
2018-04-27 21:09:07 +01:00
Ed Sanders 95258a9969 Visual diff: Describe redirect changes
Change-Id: Id31e8399556dab9b47bc1d21c62cb82af3a0e7bb
2018-04-27 21:07:41 +01:00
jenkins-bot ec8be1bfa1 Merge "Add a plain text paste transfer handler for source mode" 2018-04-23 21:00:41 +00:00
David Lynch 6f8e58fa8a Add a plain text paste transfer handler for source mode
This allows plain text pasting into source mode without interfering with the
possible-conversion that should happen when it's pasted into visual mode.

Bug: T190590
Bug: T192320
Depends-On: I47a5bf321fb64d4a631ec6fd728bee269d4cdae0
Change-Id: I71db368c683a6a846569d7627f4cc73e907a61d2
2018-04-22 12:52:56 -05:00
jenkins-bot 6902e81768 Merge "Use ellipsis on toolbar save/publish button" 2018-04-17 18:34:17 +00:00
jenkins-bot a8e6d1ddd5 Merge "Add label to Options dialog > Categories input fields" 2018-04-17 18:18:55 +00:00
hunter be5289689f Add label to Options dialog > Categories input fields
Add label to indicate the function of the input field underneath the
categories label in the options dialog. The <label> element is
preferred for screen readers and users with visual disabilities.

Bug: T146966
Change-Id: Ib300ca7a1fd55d320c1a1a8c8c7fd01ab8b0b9c5
2018-04-17 06:28:32 +00:00
Kunal Mehta c765524709 Set extension type to editor
Change-Id: I5712224c5ec4bfa6ac7c1b3091f6f80e0916941f
2018-04-13 22:07:13 -07:00
James D. Forrester d99b687791 Update VE core submodule to master (9c0b07868)
New changes:
bd0dd861f Replace LinearContextItem mixins with sub-widgets
60ea01484 ve.Document: Use more specific type for documentation
96b95e288 Use correct action test in CommentInspector teardown
a493d5bf1 Update OOUI to v0.26.3
9c0b07868 Remove table move icons, upstreamed to OOUI

Bug: T191623
Bug: T191818
Change-Id: Ia633375f56c1b844e70d101d0a9383fa4f73e1e9
2018-04-11 12:44:27 -07:00
jenkins-bot f5b0d655cf Merge "FeedbackTool: Add the ability to vary feedback page for source mode" 2018-04-04 21:24:09 +00:00
James D. Forrester 31730cc5b3 FeedbackTool: Add the ability to vary feedback page for source mode
Wikis with a local link over-ride configured will need to do so here
for the new message `visualeditor-sourcefeedback-link`; wikis with a
remote link configured will need to update their configuration ahead
of this being deployed, setting $wgVisualEditorSourceFeedbackTitle.

Bug: T157953
Change-Id: Iea7ad8328b03f69e01d7c67ca1ddbb7ae7906288
2018-04-04 18:11:10 +00:00
jenkins-bot 9c82472546 Merge "MWExternalLinkAnnotation: add CSS to override plainlinks styling" 2018-04-04 15:53:51 +00:00
Ed Sanders 11eaab48c8 Move redirect building methods from DesktopArticleTarget to ArticleTarget
These are not specific to desktop.

Also make the static builders static, and move VE target specific
code to caller, such as the click handler.

Change-Id: Ib7e769e3d6d339b9e66e1bc924480b0b0d5db17d
2018-04-02 17:32:24 +01:00
Bartosz Dziewoński f8522b7aac Update VE core submodule to master (4922429f7)
New changes:
4922429f7 Merge all theme overrides into single files

Local changes:
* Update extension.json module definitions for 4922429f7
* Merge all VE-MW theme overrides into single files

Change-Id: Ie8bb4a78c3c50dd4e930f25f6f72bc2f395bd10c
2018-03-28 09:17:12 -07:00
David Lynch 7f5b6fafb4 MWExternalLinkAnnotation: add CSS to override plainlinks styling
Was causing the active link highlight to look broken.

Bug: T190582
Change-Id: Ia59e762689211625027367511ffd922f445a13ae
2018-03-28 10:57:10 -05:00
David Lynch d77ea2bf16 DesktopArticleTarget: use -published message instead of -saved
Bug: T183901
Change-Id: I09f6e44f9f743f079ca5504ec06706c764ce6e25
2018-03-27 10:49:03 -05:00
jenkins-bot 5f8d287e12 Merge "Autosave recovery prompt" 2018-03-26 20:55:18 +00:00
Ed Sanders a58b529104 Autosave recovery prompt
Prompts the user before recovering if the document
has been edited since last load.

Bug: T190077
Change-Id: Ibc0e1d1342510fbca57ad599c1816918c84e5487
2018-03-21 16:23:35 -07:00
jenkins-bot 9d004c4d35 Merge "Use OOUI 'markup' icon instead of local 'alienextension'" 2018-03-20 19:50:55 +00:00
Ed Sanders 0f56af016d Use ellipsis on toolbar save/publish button
Bug: T189803
Depends-On: Ic29717a660de5e80ee2a37f583b2a61c11fa87c4
Change-Id: Idaf80ea7e6ae9ffa165a8638af886bf6ab21a7f0
2018-03-20 19:46:36 +00:00
Ed Sanders c245dd9ca0 Improve media context item to show Image/Video/Audio instead of 'Media'
Change-Id: Ie3b7ec62483e725d3ce073095a2a958c1db930d5
2018-03-20 17:45:48 +00:00
Ed Sanders 78ba8bbe3c Use OOUI 'markup' icon instead of local 'alienextension'
Change-Id: Id15596ab0013cb2078480bdb4dde25ef8e7ae50b
2018-03-20 17:27:54 +00:00
jenkins-bot e23dd5fb6d Merge "Make gallery dialog work with native gallery implementation" 2018-03-19 23:39:00 +00:00
Thalia 12cc56400b Make gallery dialog work with native gallery implementation
Updates the model and re-renders the gallery.

Bug: T150621
Bug: T149602
Bug: T149596
Change-Id: I1e93c3af02eeeff1fcdaa5549cccc61ea755ee04
2018-03-19 23:55:17 +01:00
Bartosz Dziewoński a021482b6f Update VE core submodule to master (dc5a65131)
New changes:
8d8030fd1 Localisation updates from https://translatewiki.net.
37302d389 Show timeout message if diff times out
4fa6e3005 ve.dm.Converter: Handle meta nodes for empty annotations same as normal
f74c630d6 ve.Node: Make #getOffsetPath not fail while rebuilding the document
bd62f3e74 Fix global overlay classes

Bug: T180842
Bug: T187690
Bug: T189118
Change-Id: Ieb404db788bd9ff743f00131458c44f01deac466
2018-03-14 20:55:40 +01:00
Bartosz Dziewoński dc9b7170e3 DesktopArticleTarget: Add explicit dependency on 'mediawiki.storage'
This happens to work correctly because we depend on 'mediawiki.user',
and that depends on 'mediawiki.storage'. This is just an implementation
detail though and could change.

Change-Id: Ia23c83ae73bfbcc65b4a169bddf861d83691822e
2018-03-14 18:48:10 +01:00
Ed Sanders 94db6545bb Update VE core submodule to master (23666aff0)
New changes:
23666aff0 color-picker: Remove fallback PNGs we don't use

Local changes:
Pull through color picker lib from core

Change-Id: Ib213f801a90e400fae2838e21bbdb011dc61311a
2018-03-06 17:46:47 +00:00
James D. Forrester d144599cea Update VE core submodule to master (ca771b8bc)
New changes:
7551f6c66 [BREAKING CHANGE] Rename class ve.dm.IndexValueStore->ve.dm.HashValueStore

Local changes:
Follow-through rename of IndexValueStore->HashValueStore

Bug: T188900
Change-Id: If60d0c637fe92f0e7afe916c064fafb17980d063
2018-03-06 12:55:30 +00:00
jenkins-bot 8727ecd181 Merge "Do not use deprecated jquery.byteLength" 2018-02-27 22:10:23 +00:00
jenkins-bot b5ceb1b956 Merge "ve.ui.MWSaveDialog: Allow limiting comment length by characters rather than bytes" 2018-02-27 22:06:01 +00:00
Bartosz Dziewoński 974ea82c50 Do not use deprecated jquery.byteLength
Change-Id: If3f921d60563bd614c269d1d26b745161f8cfc7b
2018-02-27 22:35:29 +01:00
Bartosz Dziewo??ski dbfe6c0b5a ve.ui.MWSaveDialog: Allow limiting comment length by characters rather than bytes
Bug: T185948
Change-Id: I882d69beb1cd442868c8d73988f5b3a2bbb084bc
2018-02-27 22:35:08 +01:00
jenkins-bot b3adaa5fc1 Merge "Show notification when document is recovered (or fails)" 2018-02-27 21:03:51 +00:00
Ed Sanders a46b30a161 Show notification when document is recovered (or fails)
Change-Id: Id2f6651ba7743c05043bbbe64cd9cb7bd762d74b
2018-02-27 20:54:18 +00:00
jenkins-bot c44390e6f8 Merge "Use session storage to auto-save" 2018-02-27 20:20:31 +00:00
Ed Sanders 76caef6b4b Use session storage to auto-save
Ensure we start with the same HTML (i.e. if an edit has
been made since the crash-recovery):
* Whenever an article target is activated, stash the initial
  document html, other parsoid response data, and the request
  parameters (pageName, mode, section) in session storage.
* Whenever an article is fetched through the target loader,
  recover from session storage if the request parameters match.

Store transactions:
* On document transaction (debounced) append the latest
  changes to session storage.
* If a document state is recovered from session storage,
  attempt to re-apply the stored transactions.

Clear transactions:
* Whenever the target is torn down (i.e. save, deliberately
  closing the editor to go back to read mode)

Other:
* If writing to session storage fails once, disable future
  attempts for that session (assume storage quota exceeded)
* Disable tempWikitextEditor when recovering. We don't have
  the transaction code loaded yet to perform the recovery.

Bug: T57370
Depends-On: I3832243fc347a99641fcb7e39a887a153c9a3b22
Depends-On: I448fb566fe9f7f5b5a76e88b70ca000e3d35b415
Change-Id: Id9d877f903cf4796a52f90991c030417a9f8786f
2018-02-27 12:19:06 +00:00
James D. Forrester 4ede488647 Simplify 2017 wikitext editor config when Beta Features is enabled
Depends-On: Id12e08f9dca0a6676488a255480670e9badeb300
Change-Id: Ibe031f0ce5a7b06aa4b8f6d59c2a85b873b8e35b
2018-02-26 12:27:19 +00:00
Ed Sanders 05a504887d Drop IE10 support
Change-Id: Ib1cb8fb32c499ba0bdc87ec55e1e2e95d2eb39ec
Depends-On: I68c882e64fba95d5e1bf41f64658fcef7524dcf5
2018-02-22 00:47:38 +00:00
James D. Forrester fa9438e5fa build: Move PHP files to expected paths
Principal code is in includes/*.php with the file named the same as the class it
contains. The maintenance script is moved to maintenance/ for clarity.

Change-Id: Icb4cdffb1bd4716e14f883d667def96671b42992
2018-02-07 12:31:08 -08:00
Ed Sanders 245eafee67 VisualDiffs: Create an optional BetaFeature for historical diffs
Bug: T185708
Change-Id: Ie937ed52a79ca66ed290be27f21373cab0d9a6d2
2018-02-06 19:29:16 +00:00
Ed Sanders 7027d9eb3b Fix byteLimit/byteLength dependencies
Change-Id: Id88e5474a76e8677f7d59ff1651bfbd02985789c
2018-02-05 21:48:09 +00:00
zoranzoki21 a95e80c8f5 Removed deprecated position statements from resource loader module
Bug: T184257
Change-Id: I0771dda6664c965f323ef276c6baf4df9d83a1d6
2018-02-04 10:19:51 +00:00
James D. Forrester 4ce103abb9 Update VE core submodule to master (c5fddd508)
New changes:
21a5d55b8 [BREAKING CHANGE] Store metadata as block nodes in the main data list
2f9868aae Localisation updates from https://translatewiki.net.
7a224cf4b Remove <style> tags from pasteTarget ASAP
fb4e894b6 Workaround missing child selector in OOUI for menuLayout
fa4f35281 rebaser: Fix sequencing of server operations
931ee29f6 SurfaceSynchronizer: Also translate selections that are not mentioned in the change
d232b8f04 Disable undo/usurp within SurfaceSynchronizer
d1b7fc597 ve.dm.Change: Truncate stores as well as transactions on conflict
7606f684d rebaser: Only apply artificial delay to submitChange events
9473e8b42 Toolbars: Replace $.width with clientWidth/offsetWidth
abb8f2075 ve.ui.DesktopContext: Remove unused CSS
050414205 ve.ui.DesktopContext: Remove old unnecessary CSS
7b8cbb830 Failing test case for losing annotations
5447d33e4 CommentNode: Protect against call after teardown
bf98ca2b6 Rebaser: Use better hack for disabling history commands
90c07f46c Rebaser: uninitialize fully
2a59016e4 Move updatingName recursion guard out of debounce

Bug: T56299
Bug: T185532
Bug: T185544
Bug: T185599
Bug: T185716
Bug: T185747
Change-Id: I45251811e3fbb3323a25ca5cf364e4cb94aa1d01
2018-01-29 08:43:08 -08:00
jenkins-bot 140ec5f2ab Merge "NWE: Show temporary wikitext input widget while loading" 2018-01-16 18:13:47 +00:00
Ed Sanders 886faf2adc NWE: Show temporary wikitext input widget while loading
Bug: T184614
Change-Id: I2e4964cb6329660957815dcb9a74d2ad24d5256b
2018-01-10 21:34:53 +01:00
David Lynch 64944c119a Use mw.storage instead of localStorage
mw.storage catches errors, so we won't crash horribly when the user has
localStorage disabled / full.

Bug: T181822
Change-Id: I212994eb535b9a8fb5f6c09deaa10b16c3d7f10e
2018-01-10 11:44:24 -06:00
jenkins-bot fcdc45a191 Merge "Remove unused module alias "unicodejs.wordbreak"" 2018-01-05 00:04:08 +00:00
Ed Sanders a55e6cb428 Remove unused module alias "unicodejs.wordbreak"
Deprecated for several years, not used anywhere.

Change-Id: Iaca725f7f249119c97f0ca2cc069003409b4155e
2018-01-04 23:35:27 +00:00
James D. Forrester 3c525446ce Update AUTHORS.txt for the last couple of years' work
Not updated since November 2015, whoops! Also added a few
normalisations to the .mailmap file.

Change-Id: I6de4b84bfb34ee1d2ea0b5df4e0f0eb358fd46b6
2018-01-03 11:51:37 -08:00
Bartosz Dziewoński 4987c07793 Move things that are not modules out of modules/ directory
* Move SpecialCollabPad.php to /.
* Move screenshots for BetaFeatures to images/.
* Move localisation messages to i18n/.

Change-Id: I874ae135a3ac58118c3dea105136c8c8b6fb41bc
2018-01-02 11:05:23 +01:00
Ed Sanders ba6082d6f8 Don't depend on ArticleTarget for source editor
Change-Id: Iaf1aefcbf94e4548b45e7c55f0af57d15235e8f5
2017-12-20 13:18:01 +00:00
Ed Sanders d8ff15ec7a Depend on new mediawiki.editfont.styles module
Depends-On: Ifff40f756558e30f6551f29a945a31f0eef4cfed
Change-Id: If78466736d502eb031f7c4f32baf45495430b5fa
2017-11-07 04:31:17 +00:00
Ed Sanders 4fd9e02f1c Use 'mediawiki.user' module, and never user.options/user.tokens
The user.- modules are dependencies of mediawiki.user.

Change-Id: I55ee81e4010abf38f84b70d9fd2a8196ee068928
2017-11-01 15:36:34 +00:00
Ed Sanders 50217d2a19 Rename mediawikitheme -> wikimediatheme
Change-Id: I48e1fcc0b71dccdb6d8e034d686a4bfe5dbe39e6
2017-11-01 15:36:34 +00:00
James D. Forrester a70b417f4e Fix switcher icon dependencies
Bug: T178532
Change-Id: I0bcb02d15e520ffc3c0821d8275c6b7d42c056a3
2017-10-19 17:57:30 +00:00
James D. Forrester 81ccbd58e4 Account for 'eye' icon having moved icon packs
ext.visualEditor.articleTarget (for ve.ui.MWSaveDialog) previously
missed the editing-advanced pack, so the [[ ]] icon only showed up
by happy accident of the VE toolbar loading it and generally being
there.

ext.visualEditor.diffPage.init (for ve.init.mw.DiffPage.init) just
needed being switched over.

Bug: T178532
Change-Id: Id12ef14434fd30a442bbbf6e9ccd8e50c3376cd5
2017-10-19 17:18:22 +00:00
jenkins-bot fb7ae340d2 Merge "Convert mobile overrides to LESS" 2017-10-17 15:37:23 +00:00
Ed Sanders 8f11796c43 Convert mobile overrides to LESS
Change-Id: I44754f2d6e69ad9a8a6ce941962714a6d2617b5a
2017-10-17 11:46:17 +01:00
Ed Sanders d6d5bd963b Make diffLoader module available on mobile
Unbreaks visual diffs on mobile.

Change-Id: Iaa935d8c42cc539a04a2ce52b5b5a246077524e8
2017-10-16 21:39:52 +01:00
James D. Forrester bd2deb3ac4 DesktopArticleTarget.init: Load 'mediawiki.action.view.postEdit' via loader
Bug: T164148
Change-Id: I537144bfd52ff84499f5d086f5d05efe2ba0493b
2017-10-05 15:54:20 -07:00
Ed Sanders a1583a7310 Move 'parentheses' message to MWSaveDialog's modules
Bug: T177446
Change-Id: I26a1a5eed5aca4dec55624927011204eb4d1c263
2017-10-05 13:11:56 +01:00
Ed Sanders 582a3e62fb Remove upstreamed link inspector page icons
Change-Id: I997b299d9a61ec9307025a7f4d106f185283eb40
Depends-On: I297648d14b4a2540a40f3a0b7d22a7905ef7c035
2017-09-29 16:27:50 +00:00
jenkins-bot 0dce4c52d8 Merge "Inspectors for editing LanguageConverter markup" 2017-09-15 16:31:38 +00:00
C. Scott Ananian 853ec0bc9c Inspectors for editing LanguageConverter markup
Basic inspectors for editing.  Changing from block to inline, or
adding "hidden" or "describe" flags not supported.

The UI layout for two-way and one-way rules could certainly be improved.

Bug: T49411
Change-Id: I5ce29e4bf47abf509afde0a57f64b5d1189f5185
2017-09-15 09:24:33 -07:00
Ed Sanders 31122758bb Remove unused polyfills from EasyDeflate lib
Base64 and TypedArrays polyfills were required to
support IE9, but VE now requires IE10.

* http://www.caniuse.com/#feat=atob-btoa
* http://www.caniuse.com/#feat=typedarrays

Change-Id: I311a16f98fb1d091f55dda52d97bebfc012e2a14
2017-09-15 15:57:55 +01:00
Ed Sanders b280ae985c Make ve.dm.Change part of core module
Also:
* Add ve.dm.Change.test.js to MW test suite
* Remove server scripts from ext.visualEditor.rebase, they
  only need to be in rebaser.build in core.
* Don't load ext.visualEditor.rebase on every page

Bug: T175828
Change-Id: I0ed0c320373b0d653b0d7a012aa7416e88e43e00
2017-09-13 16:36:17 +02:00
Ed Sanders faf852f335 Update VE core submodule to master (f88cd00a6)
New changes:
c1c38136d ui.TableLineContext: adjust positioning
37d0c2747 Trigger proper undo/redo when inputType=historyUndo/Redo
8b7fc6fcc Make special keys translatable

Bug: T175417
Bug: T175449
Bug: T175634
Change-Id: Ic663108ff19ea90adc9b033f6df1f0feac7994a6
2017-09-12 09:27:02 -07:00
jenkins-bot 822db7eacf Merge "Add feedback link for visual diff inside save dialog" 2017-09-11 12:01:39 +00:00
Ed Sanders e4585d520b CollabTarget: Minimise dependencies, and make toolbar tweaks
Change-Id: I37cccd5760b8e65fc4232ca4572147f3b031255d
2017-09-08 15:46:45 +00:00
James D. Forrester d9739c0b2e Update VE core submodule to master (834fd702f)
New changes:
86bd6c879 Localisation updates from https://translatewiki.net.
6d7a4cef0 Update OOjs UI to v0.23.0
37d1512a7 TransactionProcessor: modify DM tree branches instead of rebuilding them

Bug: T162762
Bug: T166041
Bug: T167027
Change-Id: Idfaa990dd940e26d7d572513220282bc97ca65fa
2017-09-06 13:44:33 -07:00
Thalia a3902ebff8 Add feedback link for visual diff inside save dialog
Bug: T170665
Change-Id: I0b09b1089c834a013ad5fee4ecdf75b483b56323
2017-09-05 13:35:37 +01:00
James D. Forrester a18508e7e4 Update VE core submodule to master (7a8829509)
New changes:
4523b11c0 Make RebaseServer asynchronous
2eb09b6ba Localisation updates from https://translatewiki.net.
c806b7131 Remove execute mode from non-executable
622c62c9e Follow-up 2eb09b6b: Add kab to build to unbreak the repo
b69e4ba1c DiffElement: Fix insert/delete-to-end loops
8c6dfdde9 FocusableNode: Redraw highlights using focus toggle
2bded2d16 Debounce FocusableNode#redrawHighlights
3cb7844b1 Localisation updates from https://translatewiki.net.
fb13239b2 VisualDiff: Don't diff close elements
7a8829509 Localisation updates from https://translatewiki.net.

Also, exempt the Rebaser ES6 code from jsduck, as we do in VE itself,
because jsduck doesn't understand ES6 syntax.

Bug: T129541
Bug: T171862
Bug: T173860
Change-Id: Ia08022afb0b94b8a6907f97b161bc04d8a210232
2017-08-31 11:39:36 -07:00
jenkins-bot 842b3336bd Merge "Move historical diff loading to DiffLoader util" 2017-08-24 18:33:45 +00:00
Bartosz Dziewoński 101eda99a2 VisualEditorDataModule: Do not expand templates in plain text messages
Changing `->text()` to `->plain()` and some variable
names and comments to match that. This is now the same
as normal ResourceLoader behavior for messages added
via `'messages'` in RL modules.

Also remove a duplicate use of the
'visualeditor-quick-access-characters.json' message.

Bug: T159529
Change-Id: I63593db445433e7da5c71e6800f96daf63054fcf
2017-08-23 20:08:36 +02:00
Ed Sanders 3cf074c6ea Move historical diff loading to DiffLoader util
Change-Id: I318752ede2e5c90f9d0ecd26b39e997fff2d60bd
2017-08-13 15:31:42 -04:00
jenkins-bot 69b237c96a Merge "extension.json: Depend on MediaWiki 1.30+, not 1.29+" 2017-08-11 23:21:12 +00:00
jenkins-bot 8975449eaf Merge "Context item for LanguageConverter markup" 2017-08-11 14:29:09 +00:00
jenkins-bot 6f12d066d1 Merge "Rename LanguageConverter markup fields" 2017-08-11 14:28:11 +00:00
James D. Forrester c22d3a8909 extension.json: Depend on MediaWiki 1.30+, not 1.29+
We're using newer versions of OOjs UI than 1.29 provide.

Change-Id: I7691b231c7f139fccf5c35a06a21bb2826910d52
2017-08-11 10:07:54 -04:00
C. Scott Ananian c89a3059f8 Context item for LanguageConverter markup
Add a context item giving more information on language converter markup.

Bug: T49411
Change-Id: I3c91db84793a9a965dcb760253b24edee5d7bd23
2017-08-10 11:02:41 -04:00
C. Scott Ananian 4ff740fe21 Rename LanguageConverter markup fields
Avoid confusion by using `twoway` instead of `bidir`, which could be
confused with the Unicode bidirectional layout algorithm.

Depends-On: Ib59dff22e64f235e30778a5a5b3e525e4fc7fdd3
Change-Id: I7efb35245d48125b167dc0f0ef8f12aa0fff94e5
2017-08-10 10:59:57 -04:00
Ed Sanders 5104f63cf3 Support visual diffs on Special:ComparePages
Bug: T171821
Change-Id: I13fe8349ab2d078b172637c931f1b80f7108c927
2017-08-05 23:38:20 +01:00
C. Scott Ananian 9ee713d480 Display LanguageConverter markup in VisualEditor
Implement special node types for language variant markup, so that they
display appropriately based on the currently-selected variant.

(Parsoid uses empty elements to represent this markup, so without this
patch anything in -{ ... }- is alienated and disappears.)

A follow-up patch will implement context items and inspectors to
allow editing these nodes.  This patch is basic "read-only" support.

Depends on I4fcdebc2290ec35ba188f4c2e69d578791fbcd67 in Parsoid to
generate the appropriate markup, but this patch is safe to merge
independently.

Bug: T49411
Change-Id: Ie11e9301d2513bfe4a36036481cee9a047f46d37
2017-07-25 15:26:41 +00:00
jenkins-bot 05bc265198 Merge "Keep TOC in correct place in document" 2017-06-28 12:31:33 +00:00
Thalia cbd7a579a7 Include message for comment diff
Bug: T149821
Change-Id: I6bfe77ecd53432e5c400f7efd60a1421d7917c4f
2017-06-26 13:32:55 -07:00
jenkins-bot ba3a5d85bd Merge "Show visual diffs on DiffPage" 2017-06-25 03:30:29 +00:00
Ed Sanders fd1adfb3b5 Keep TOC in correct place in document
Change-Id: I6ad8cd8cbd7ef902204408673eb096b7405abd24
2017-06-22 15:16:15 -07:00
Ed Sanders 6f72ef82d9 Show simple category list in preview
Bug: T153534
Change-Id: Ie86abdad76a38855d5ad1a394c0bfb3c8dd5a8c6
2017-06-20 23:50:52 +00:00
Ed Sanders 0e6d8d5fff Show visual diffs on DiffPage
Only shown if VisualEditorEnableDiffPage is set, or query
string param 'visualdiff' is present.

Currently:
* All VE javascript is loaded (could be cut down to just DM code)
* The entire Parsoid HTML of both revisions being compared is loaded
* Both Parsoid HTML docs are parsed into VE DM trees and diffed

Bug: T167508
Change-Id: I151fc9bab3d3032f50c8d11be6b54e45a06fcc34
2017-06-16 19:29:19 +01:00
jenkins-bot b170e81d83 Merge "Fix i18n TODOs in CollabPad" 2017-06-12 18:51:31 +00:00
Ed Sanders 23c0b6997e Fix i18n TODOs in CollabPad
Change-Id: Ifa802773881e2f2763578223bc76ca2798a08b17
2017-06-10 12:48:09 +01:00
Ed Sanders 4a163020a8 Add filename to gallery dialog page
Also add fieldset headings consistent with media dialog.

Bug: T167049
Change-Id: I8112b70d8e3ba19079fdab0806ad343b233c9c18
2017-06-06 15:48:24 +01:00
James D. Forrester 3617154f5a Add the alerts, content and interactions icon packs overall
Change-Id: Id52921b31046e0a594a16dbcd059d7c343870ddd
2017-06-01 17:10:24 -07:00
jenkins-bot 3667b6c2a5 Merge "ext.visualEditor.articleTarget: Depend on 'layout' for the menu icon" 2017-06-01 15:05:05 +00:00
James D. Forrester b960dddee1 ext.visualEditor.articleTarget: Depend on 'layout' for the menu icon
Change-Id: Idd496f2caca7e026cd67a1d307f0647941cff983
2017-06-01 14:53:22 +00:00
James D. Forrester ea3997d3f2 Update VE core submodule to master (cd4e0fa2d)
New changes:
839311756 Add missing icon set 'layout'
66634c032 Add missing icon sets to rebaser demo
2e8bca7b9 Localisation updates from https://translatewiki.net.
cd4e0fa2d Depend on 'movement' so we have arrows in the find and replace dialog

Change-Id: Idd888df1d59fe13cb982610d0e465ab87f61362a
2017-06-01 07:50:31 -07:00
jenkins-bot c9d9361c5b Merge "Update VE core submodule to master (8be817396)" 2017-06-01 01:16:43 +00:00
Ed Sanders c7221988a1 Update VE core submodule to master (8be817396)
New changes:
26085a853 Make author list a ListPopupTool
c4ea53eef Update OOjs to v2.1.0
8c94697f3 Update OOjs UI to v0.22.0
cdebc4817 Follow-up 8c94697f: Actually commit the icon changes I had locally
8be817396 Update OOjs UI to v0.22.1

Local changes for author list popup

Change-Id: I36bcaf122528a4a12882aaff3b33ef936082a391
2017-05-31 17:48:45 -07:00
James D. Forrester 756079d477 Replace uses of the removed 'remove' icon with the 'trash' one
Bug: T166730
Change-Id: I528dcdb390a4488ffac89fc823ff35bc1eda4f24
2017-05-31 16:30:17 -07:00
James D. Forrester 9136cb7e55 extension.json: Sort config to match documentation
Makes updating it much easier, groups sensible configs together.

Change-Id: I95b9c1b76ea25e8bd2d852a99b4aad753b09846d
2017-05-24 17:05:35 +02:00
jenkins-bot 71fb85fab3 Merge "[BREAKING CHANGE] Drop support for contacting Parsoid without VirtualRestConfig" 2017-05-23 19:04:37 +00:00
jenkins-bot efd8ab25ca Merge "Remove mobile browsers from the blacklist" 2017-05-22 13:23:40 +00:00
Ed Sanders 004ca16a8f Remove mobile browsers from the blacklist
They are already blacklisted by MW:
https://www.mediawiki.org/wiki/Compatibility#Browser_support_matrix_.28mobile.29

Change-Id: I8d6bfc415604a74b6da82d8c4b8f7d9ec7b9d89d
2017-05-22 14:58:54 +02:00
James D. Forrester 1bb69b7f2c Update VE core submodule to master (0c243838f)
New changes:
d21e8e93f Revert "TransactionProcessor: modify DM tree branches instead of rebuilding them"

Bug: T165965
Change-Id: Ic28e0a8f8e45217b1f1ce89dbfaab3d16198069b
2017-05-22 13:14:03 +02:00
James D. Forrester afa929cc46 Update VE core submodule to master (69d8607cf)
New changes:
8bd2e1ffc ui.DebugBar: Transaction log
b3ad56e0e rebaser: Focus surface on load
69d8607cf Localisation updates from https://translatewiki.net.

Change-Id: I5e64845ccfcb82621b66e02e3a346ef4ef67426a
2017-05-21 10:39:42 +02:00
Ed Sanders 574baf2e8e Provide VE-rebaser in MediaWiki as Special:CollabPad
Change-Id: I3ffe0e2b6af43d4018dcd79877f4f27ed7d6a7e7
2017-05-20 19:51:09 +00:00
James D. Forrester 1ffb299f18 Update VE core submodule to master (ee59e9d33)
New changes:
d336169fe rebaser: Don't spam the entire document into the log on initialization
1963a9993 ve.dm.SurfaceFragment#delete: Don't pre-build a sequence of transactions
6c915f305 TransactionProcessor: modify DM tree branches instead of rebuilding them
8773258bb ve.dm.ElementLinearData.test: Cover compareElements
7a073c78f RebaseClient: Don't log empty rebases in acceptChange
5adce57ea rebaser: Implement author names
78c7beecb rebaser: Tidy up author list UI
85d26f491 Get minimal diff when word starts/ends the paragraph
ca273a56c rebaser: Move author list to widget
ab693bead rebaser: Show active user count

Bug: T160795
Bug: T162762
Bug: T165772
Change-Id: Ibd21e6a78c3958db1c0ec8f0317c4c07f3fa5735
2017-05-20 12:29:48 +00:00