Commit graph

13009 commits

Author SHA1 Message Date
Bartosz Dziewoński b109c3405f ve.ui.MWWikitextStringTransferHandler: Avoid API call for magic links
Updated tests to stop assuming that MWWikitextStringTransferHandler
always goes through an API request and Parsoid.

Bug: T117165
Change-Id: I24dffaaf3b4051b1b807ec29ac456d24da2f1fe9
2017-03-13 19:54:19 +01:00
Translation updater bot 35ec87a601 Localisation updates from https://translatewiki.net.
Change-Id: I5c8bc3f7edb775dc1c0a851540e75a386b79ab2f
2017-03-12 23:00:40 +01:00
James D. Forrester 2771ea3f34 Update VE core submodule to master (bc0001c53)
New changes:
a98515c7f Localisation updates from https://translatewiki.net.
788a1b4be FindAndReplace: Use Intl.Collator instead of localeCompare
a02ce2cd1 Use Intl.Collator for all searches if available
69328692d findText: Fix documentation and tests
833c29b67 PositionedTargetToolbar: Move code that assumes surface exists to after check
15de62106 Remove $returnFocusTo hack now null is supported upstream
a09efa1f8 Fix cursor style on language search widget
c60e7ba66 demo: Move qqx language option into the language selector

Bug: T159439
Change-Id: Ib292a25c79969a063a634837118e837e477f39ac
2017-03-10 15:49:21 -08:00
jenkins-bot b53e4a5d37 Merge "DesktopArticleTarget: Clear stored summary value after save completes" 2017-03-10 20:32:30 +00:00
Thalia c3650a9c07 Remove line breaks from gallery dialog captions
A gallery tag is parsed line by line, so captions
(and other image data) should not contain line breaks

Bug: T153373
Change-Id: Ib1d1c18216d07c83b2d4358d2dda71c9d17e3e44
2017-03-10 17:27:22 +00:00
David Lynch a9f54aacd4 DesktopArticleTarget: Clear stored summary value after save completes
Bug: T160130
Change-Id: Id906da69c743f3a966d4182862cd173b26017059
2017-03-10 10:19:12 -06:00
James D. Forrester d1f2bf1ecf ArticleTarget#switchToVisualEditor: Bail if the server won't let you switch
Because otherwise you're just throwing all the user's input on the floor.

Bug: T158692
Change-Id: I5df00842697be11ecde9ea8ba2ab16b0dc90205e
2017-03-09 17:09:16 -08:00
Translation updater bot 0d113dd032 Localisation updates from https://translatewiki.net.
Change-Id: I57d7ebfb1bec4f31bda91eb12d0127fb5715f354
2017-03-09 23:35:43 +01:00
David Lynch 05e2a3119e ArticleTarget: Improve edit summary behavior when switching
Distinguish between the initial summary state, and a value stored from the
summary when switching modes. This lets us avoid overwriting a stored value
when section-editing, or assuming a stored value after a switch was never
edited.

Bug: T159686
Change-Id: Ie7640538140a14bbafd539b3a45928f5c55cf804
2017-03-09 14:23:36 -06:00
jenkins-bot 71fe1a8cea Merge "ArticleTarget: use existing initialEditSummary if present" 2017-03-09 19:12:52 +00:00
David Lynch 261d4e8974 ArticleTarget: use existing initialEditSummary if present
Switching modes recreates the toolbar, so if someone has already edited the
save summary it shouldn't update the initialEditSummary to that.

Bug: T159686
Change-Id: I4109442853916bebae2bce804fcd6777e3eb6d34
2017-03-09 12:05:12 -06:00
David Lynch c5bb912e80 ArticleTargetLoader: wikitext switch shouldn't require FullRestbaseURL
The non-FullRestbaseURL branch didn't handle converting the provided wikitext,
causing data loss when switching from source to visual modes.

Bug: T158692
Change-Id: I283afc4be1e322228d6ec572bfa8542ba8fd9ce7
2017-03-09 11:30:16 -06:00
jenkins-bot 832674fa85 Merge "Switching modes created an infinite loop onBeforeUnload" 2017-03-09 17:14:47 +00:00
jenkins-bot 10857b2d9f Merge "ve.ui.MWMagicLinkNodeContextItem: Do not display 'Clear styling' button in context" 2017-03-09 16:59:28 +00:00
Bartosz Dziewoński 7b618c55aa ve.ui.MWGalleryDialog: Fix 'Display mode' dropdown options' styling
It's actually a bit surprising that the only thing broken by using
OptionWidget instead of MenuOptionWidget is some missing styles.

Change-Id: I3961fedbfc61f2f17d91dc7375d47a3cdff2a257
2017-03-09 16:16:21 +01:00
jenkins-bot 272dc9a725 Merge "Fix load order of LanguageContextItem" 2017-03-08 19:15:16 +00:00
Ed Sanders f0b0af45ff Fix load order of LanguageContextItem
Ensure dm.LanguageAnnotation exists when it runs, otherwise
it won't match and the context will fall back to a tool
context which doesn't have the clear annotation button.

Change-Id: Ie5474a93fcc1beab2a752bbc3beb17b3ef9cab76
2017-03-08 19:05:08 +00:00
David Lynch d6c71632ef Switching modes created an infinite loop onBeforeUnload
Switching from visual to source reruns setupUnloadHandlers, which caused an
infinite loop where it thought it was its own fallback pre-existing handler.

Bug: T153346
Change-Id: I8df55a5395ede02fc34ec47a94f2c780dc08595f
2017-03-08 11:32:03 -06:00
James D. Forrester 879ae1092f Update VE core submodule to master (de2dd95c6)
New changes:
9dbb3729b DiffElement: Measure box-shadow borders in pixels to avoid blurring
cbcaed302 ve.ce.Surface: Prevent horizontal scrollbars when hovering FocusableNodes in RTL
b715b1ad6 DiffElement: Use a real ve.Range instead of a plain object
d2567df6c DesktopContext: Unhide context before positioning popup
1afcce366 Localisation updates from https://translatewiki.net.
c31dccebd Update OOjs UI to v0.19.5

Bug: T159472
Change-Id: Icbff2ef3bdb3269db53183f27e2b682a755ee781
2017-03-08 09:10:48 -08:00
Translation updater bot b27fe68833 Localisation updates from https://translatewiki.net.
Change-Id: I71344493334c65b08754134fe3bd3202fb72f04c
2017-03-07 23:00:20 +01:00
jenkins-bot f9af257b7e Merge "ve.init.mw.DesktopTarget: Use mw-body-content instead of mw-body to match Vector changes" 2017-03-07 18:32:22 +00:00
Ed Sanders 387f9a5514 ve.init.mw.DesktopTarget: Use mw-body-content instead of mw-body to match Vector changes
This ensures the styles are still applied to surfaces in dialogs.

Change-Id: I30e0cc7dc87dc8c8b6b3be84f821aa22baab457f
2017-03-07 18:17:35 +00:00
jenkins-bot 9a90148d05 Merge "Add external classes to mw:ExtLinks in NWE preview" 2017-03-07 18:17:11 +00:00
Bartosz Dziewoński 48f227b263 ve.ui.MWMagicLinkNodeContextItem: Do not display 'Clear styling' button in context
It doesn't work, you can't turn a MWMagicLinkNode into text by
clearing its styling. (You can still do that by clicking 'Edit',
'Convert to simple link', 'Clear styling'.)

`clearable = true` was being inherited from ve.ui.LinkContextItem.

Change-Id: Ib40e952554966fb74b3e72662a6e1e44ad748a57
2017-03-07 16:34:18 +01:00
Translation updater bot 53cff258cf Localisation updates from https://translatewiki.net.
Change-Id: Id6df97f02c3d04ff546d52afaa98efaa67d5906f
2017-03-06 22:54:27 +01:00
jenkins-bot 81c9b5b032 Merge "Apex: Fix target margins" 2017-03-06 19:22:00 +00:00
Translation updater bot 9062ab75ab Localisation updates from https://translatewiki.net.
Change-Id: Ia42483cea0eaf12517b602850dc2ae362c46b005
2017-03-05 22:54:46 +01:00
Ed Sanders aa8f477dab Apex: Fix target margins
Apex is basically abandonware, so we should consider deleting
this code.

Change-Id: Ie0c21fc21d4c37ab0344978bbd0d071415866397
2017-03-05 18:07:04 +00:00
Translation updater bot a2ef681fd9 Localisation updates from https://translatewiki.net.
Change-Id: I9a379fbf4bf30911eb8f7d796a4f8a94c1622c2b
2017-03-04 23:06:24 +01:00
jenkins-bot 82355461fe Merge "Comment Parsoid hacks as such" 2017-03-03 22:58:25 +00:00
Ed Sanders 8802aa331b Add external classes to mw:ExtLinks in NWE preview
Bug: T153413
Change-Id: I118d3b1794b99ed2d120dd5c5201c1fd18b6245b
2017-03-03 22:46:21 +00:00
Ed Sanders 91822ddbd5 Comment Parsoid hacks as such
Change-Id: I23fcc49031e3b34e5b83d7acea56845b325f3026
2017-03-03 22:41:36 +00:00
Translation updater bot 8a76e9fe81 Localisation updates from https://translatewiki.net.
Change-Id: I538b21eb94aacba63d2ff173e67c18146923ba04
2017-03-03 22:50:06 +01:00
jenkins-bot 5aba0ee22b Merge "Improve NWE new section styles" 2017-03-03 18:06:04 +00:00
jenkins-bot 8d29d962c5 Merge "Cleanup DesktopTarget styles" 2017-03-03 17:54:43 +00:00
Ed Sanders 06fa5166c7 Improve NWE new section styles
* Use <h2> for TextInputWidget to avoid duplicating skin styles
* Fix placeholder colour and font

Change-Id: I36c0b79ec9cbf3fa2ead0541ef5bac4a14a8781b
2017-03-03 11:59:06 +00:00
Translation updater bot d53d15ec41 Localisation updates from https://translatewiki.net.
Change-Id: I3865ee179a56f5eddf123afa31e98ee6d13c4ed8
2017-03-02 23:26:47 +01:00
David Lynch 6cb6933e67 DesktopArticleTarget: Correctly bind section link handler
Since December, the handler now expects to be passed the mode we're switching
to. Since we're filtering for just the edit link and not edit source, we can
hardcode 'visual' here.

Bug: T159374
Change-Id: I160045dd59ff1b4c2d180dbbe37280a1839886df
2017-03-02 11:43:11 -06:00
jenkins-bot 59d52158a9 Merge "MWWikitextStringTransferHandler.test: Don't pass around an invalid doc" 2017-03-02 05:56:23 +00:00
jenkins-bot e55e6d7c99 Merge "MWWikitextSurfaceFragment#convertFromSource: Don't make an invalid doc" 2017-03-02 05:56:22 +00:00
jenkins-bot c24d8a355d Merge "Update VE core submodule to master (3056a4a46)" 2017-03-02 05:56:20 +00:00
jenkins-bot c537a8f0a2 Merge "ArticleTarget#getWikitextFragment: Optimise no-op" 2017-03-02 05:45:58 +00:00
James D. Forrester 9b4e27a91c MWWikitextStringTransferHandler.test: Don't pass around an invalid doc
Even if it sounds cool, it isn't.

Change-Id: Ib6612bc0ea8d66fc1964b3a782ad56356da65952
2017-03-02 05:43:10 +00:00
James D. Forrester 6fd475e8ec MWWikitextSurfaceFragment#convertFromSource: Don't make an invalid doc
Though neat, this hack to get the internal list doesn't seem to be used
and creates an invalid document (just an internal list with no content,
so the internal list is at the start and the default selection position
is inside it). Instead, use the ve.dm.Document.static.newBlankDocument()
utility function that was made for this use case.

Bug: T153509
Change-Id: Iba5931cb5e3f939a803c1d59fa0d8f30a0513f84
2017-03-02 05:43:03 +00:00
James D. Forrester 1865702448 Update VE core submodule to master (3056a4a46)
New changes:
f83a68c22 ve.ce.ContentBranchNode: Don't set 'white-space: normal' on `<pre>` tags
ee5920781 DiffElement: Fix remaining class->data-attribute conversions
a07c9e345 DiffElement: De-clutter left margin, removing the blue border
3056a4a46 ve.dm.Document: Provide a utility method to provide a blank Document

Bug: T159231
Change-Id: I3b71d995c915fa6ea10a0eea7cb727ee68733ae9
2017-03-01 21:41:03 -08:00
James D. Forrester e0814210e9 ArticleTarget#getWikitextFragment: Optimise no-op
Change-Id: I6b54ae26e26c5ca697848d2534c128fc9c4bc4aa
2017-03-01 19:17:26 -08:00
Bartosz Dziewoński 461f99e9da Document usages of ve.dm.Node.static.suggestedParentNodeTypes
Ed told me this.

Change-Id: I5e3160d3e5c38f9babc133db8977a6e6b8bbd610
2017-03-02 00:11:54 +01:00
Translation updater bot 603a5a6bd9 Localisation updates from https://translatewiki.net.
Change-Id: I99dbcc74f0ff9a76c6463de302ea9fc90045f83e
2017-03-01 22:47:27 +01:00
jenkins-bot 4b3ad8e322 Merge "Update VE core submodule to master (8211ebc70)" 2017-03-01 14:21:53 +00:00
jenkins-bot 15a0325dde Merge "Update VE core submodule to master (15f36bc75)" 2017-03-01 14:21:51 +00:00