Commit graph

12602 commits

Author SHA1 Message Date
jenkins-bot 7a81159941 Merge "Fix NWE-only edit tab" 2017-01-03 17:04:09 +00:00
jenkins-bot 80e0edd275 Merge "Allow switching between 'edit source' and 'add topic'" 2017-01-03 17:04:08 +00:00
James D. Forrester 122f49b2dd build: Bump file copyright notices for 2017
Change-Id: I3c20809e71cc0da58123e1b5f29c4f3aac945496
2017-01-03 08:58:33 -08:00
jenkins-bot e0d5b0e829 Merge "Update VE core submodule to master (da4a0b5)" 2017-01-03 16:42:25 +00:00
jenkins-bot 71808e07ee Merge "Replace all usages of Linker::link() with LinkRenderer" 2017-01-03 16:42:23 +00:00
James D. Forrester 3c420baa70 Update VE core submodule to master (da4a0b5)
New changes:
8562e02 Ensure document is always sliced in #insertDocument when newDocRange passed
38885da Unwrap single pasted content branch nodes
afcc2b5 Use this.document directly in surface fragment
9a06a01 Don't show help for a trigger if the command is not registered
16fa88e Rename 'commandName' to 'commandHelpName' and refactor object copy
8640858 Localisation updates from https://translatewiki.net.
3e147fd Localisation updates from https://translatewiki.net.
df590e3 ce.Surface: in blur, make sure activeElement exists before blurring it
2883d2a Localisation updates from https://translatewiki.net.
89b8927 Remove serialization test cheat; make tests actually pass
41e77ad ve.ce.CommentNode: Don't assume icon exists yet
55185ec Rebaser: Allow document id & server to be changed by config
3b06cf3 Filter out nodes completely sanitized away by DOMPurify
755768c Pass dm doc to deserialize to hydrate selections properly
a9b1c86 DOMPurify config: Change ALLOWED_ATTR to ADD_ATTR
3796061 Remove unit test hack, no longer needed.
ef7b4e4 Rebaser: Separate namespace creation from /doc/edit
da4a0b5 Localisation updates from https://translatewiki.net.

Bug: T153247
Bug: T153249
Bug: T153960
Change-Id: Iaa277b86aea4182c8e96ec6ad4ed6c1beaf00ee1
2017-01-03 07:33:55 -08:00
Ed Sanders 4628e9e68c When switching check wikitext is a non string, not just empty
Also add documentation.

Bug: T154437
Change-Id: Icacc0ad522d3e7fa28ecea9876c2c0465c4eb8e6
2017-01-02 18:40:07 +00:00
Translation updater bot daa5085917 Localisation updates from https://translatewiki.net.
Change-Id: I1dbde448e5f2d60675d35d070969b3890ea2aa49
2017-01-01 10:17:23 +01:00
Ed Sanders 58071f59f1 Add editintro to notices
Bug: T56029
Bug: T51622
Change-Id: Ib43cc66b817ff394b4f1c82fcba4503df825819c
2016-12-31 23:23:17 +00:00
Ed Sanders c853475a1a Give focus to preview panel for keyboard scrolling
Bug: T154334
Change-Id: Ibc093e3111411b6183bf24528a2e0419ba8d40b6
2016-12-31 22:04:19 +00:00
Ed Sanders fe85ee1ba6 Don't block VE/NWE from loading if 'editintro' is specified
Later we should actually show the edit intro, but that is a
separate issue (T56029).

Bug: T153481
Change-Id: I97622a3d86b975866305aaa745bac51f6b55f217
2016-12-31 15:22:11 +00:00
jo12bar 0533c329fb
Replace all usages of Linker::link() with LinkRenderer
Linker::link was deprected in 1.28. This replaces all usages of
Linker::link with an instance of LinkRenderer in ApiVisualEditor.php, as
this seems to be the only file generating links with Linker::link.

Bug: T149346
Change-Id: Ib395f137787e7dd7c5cfe91905f5feb88ce9f604
2016-12-30 21:27:17 -08:00
Ed Sanders 9eebfbcac5 Fix NWE-only edit tab
Change-Id: I5d08e30f43fbe08eb8809692728a8ab37f3a1491
2016-12-30 16:42:54 +00:00
Ed Sanders 3f47aec20b Use preferred number casting method
Change-Id: I77215f2bdb6eb055375e5b803d23b6f26df2d8d1
2016-12-29 20:33:15 +00:00
Alex Monk 4af862e6d3 Also allow opening in source mode if VE is unavailable on action=edit
Bug: T153508
Change-Id: I5678d3b417c93707edc90bbb76ce4dafcd2098c6
2016-12-29 20:32:58 +00:00
Ed Sanders c963b73e71 Factor out preferred editor check
Change-Id: Ic2e2e2e1d24dba8854315dff068ea9ce5d409c5a
2016-12-29 20:17:55 +00:00
Ed Sanders 7de023caee Allow switching between 'edit source' and 'add topic'
Also between section editing and full page editing
by clicking on 'edit source'.

Change-Id: I9165a7ad4ac2a588a09532c7181ba72b6fd2f811
2016-12-29 15:48:38 +00:00
Translation updater bot 2217913182 Localisation updates from https://translatewiki.net.
Change-Id: If99a57be3026afdfd71533ff227649069c092674
2016-12-29 10:25:31 +01:00
jenkins-bot 927856aff3 Merge "Use mw.Message#parseDom where appropriate" 2016-12-28 21:40:18 +00:00
Ed Sanders c625398b78 Use the monospace hack consistently
Change-Id: I6b223e5f0760902c1f34fa5a284703055c763234
2016-12-28 13:36:14 +00:00
Translation updater bot 786f354ec5 Localisation updates from https://translatewiki.net.
Change-Id: I6a6785f8b9a0f0448a0f0e0af11dcebf2ab9ec3b
2016-12-28 10:57:13 +01:00
Bartosz Dziewoński a811168c2a ve.ui.MWParameterPage: Restructure constructor to reduce needless work
We were constructing a lot of widgets, and never using them all
(they were forever hidden or not even appended to DOM). For large
transclusions this was causing a noticeable performance hit.

I don't think this quite resolves T134814, but it should improve the
situation.

* this.rawFallbackButton is now constructed and appended only when needed.
* this.removeButton is now constructed and appended only when needed.
* this.infoButton can now be a PopupButtonWidget or a disabled ButtonWidget.

Bug: T134814
Change-Id: I2ea00a88a1ea22b73b0c6d10334a94f45734ec3b
2016-12-27 23:54:49 +00:00
Bartosz Dziewoński e0c97ab2f0 ve.ui.MWParameterPage: Hide the "Fall back to plain wikitext" button when in wikitext
We were trying to hide it by detaching, which did not work because it
was getting attached again in later code. Clicking the button just did
nothing.

Change-Id: I027550eb723c43dc85453959159b93e6e802e099
2016-12-27 23:54:42 +00:00
Bartosz Dziewoński 90ff82a035 Use mw.Message#parseDom where appropriate
Avoid turning DOM into HTML markup and parsing it back into DOM.

Change-Id: I34f56ee60b836a7e0556130a153fc95adb4f3467
2016-12-27 23:54:12 +00:00
Ed Sanders 827d4185c4 Move translate extension hack up to 'isAvailable'
All modes of VE should be disabled on these pages.

Bug: T153445
Change-Id: I5adfae940ee35c5ee6712e620a0ddda967a542ad
2016-12-27 13:56:10 +00:00
Translation updater bot f5b1a5bb18 Localisation updates from https://translatewiki.net.
Change-Id: I1c8e16e199bbef502b296802acbb3cc15ee417be
2016-12-26 22:42:30 +01:00
Translation updater bot 2ea87fcaf3 Localisation updates from https://translatewiki.net.
Change-Id: Ia3b0f68931e0894aa10d2992f90dc8703f8712cb
2016-12-25 22:20:41 +01:00
Translation updater bot d87a54a31b Localisation updates from https://translatewiki.net.
Change-Id: I21a43826c79cf6d234fb003f3f20c254758380fd
2016-12-24 22:41:04 +01:00
Alex Monk 4c061de2e0 Fix MWInternalLinkAnnotation.getTargetDataFromHref's behaviour with URLs containing query parts
ve.dm.MWInternalLinkAnnotation.static.getTargetDataFromHref(
	'http://mediawiki.krenair.dev/mediawiki_dev/wiki/Main_Page?veaction=editsource',
	ve.init.target.surface.model.documentModel.htmlDocument
)

Wrong, current result:
Object {
	title: "Main Page?veaction=editsource",
	rawTitle: "Main_Page?veaction=editsource",
	hrefPrefix: "",
	isInternal: true
}

New result:
Object {
	title: "http://mediawiki.krenair.dev/mediawiki dev/wiki/Main Page?veaction=editsource",
	rawTitle: "http://mediawiki.krenair.dev/mediawiki_dev/wiki/Main_Page?veaction=editsource",
	hrefPrefix: "",
	isInternal: false
}

Change-Id: I3d6d7fcfeb0d8354623026c831605c7633c3e11a
2016-12-24 20:12:44 +01:00
Alex Monk d7cf29f1c0 rm stray fileRepoPromise property from media dialog
seems to have gone upstream to core's mw.widgets.APIResultsQueue

Change-Id: I3c2a6dbdca60ceadc9e7175e5f8ad83b7fc4b7a0
2016-12-24 18:59:48 +01:00
Translation updater bot 55a9cf5208 Localisation updates from https://translatewiki.net.
Change-Id: I39a587eeb157951e8f848cda002f9a46b77d162a
2016-12-23 22:34:34 +01:00
Ed Sanders 7611ee5a2c Register shortcuts for minoredit/watchlist
Bug: T153925
Change-Id: I3f569a75a66e816d0a5c4ad966344100510a4f2b
2016-12-23 13:36:48 +00:00
Translation updater bot 2dc86af85a Localisation updates from https://translatewiki.net.
Change-Id: Ic57783cd0222ba31b3c343881a4a4732ad7d0404
2016-12-22 23:00:45 +01:00
jenkins-bot d5f66e4fe9 Merge "Preserve checkbox data when switching from VE to NWE" 2016-12-22 12:37:37 +00:00
jenkins-bot 50da8d8ab9 Merge "Add comments in some places where we really want to treat messages as HTML" 2016-12-22 00:32:23 +00:00
Ed Sanders aee5e665f1 Preserve checkbox data when switching from VE to NWE
Bug: T153889
Change-Id: Ifc41ea9320c9f2627efff6f33d4ad87c59fad496
2016-12-21 22:35:52 +00:00
Alex Monk 101b0ff45c Don't try to JSON stringify load error messages that are already strings
Change-Id: Ib180c3ac7eb62d351e05153defd6330c3397c478
2016-12-21 04:00:05 +01:00
jenkins-bot 8497b06287 Merge "ve.init.MWWelcomeDialog: Don't treat text messages as HTML" 2016-12-21 02:49:09 +00:00
jenkins-bot d1b243e660 Merge "Ensure document base is always correct, even in source mode" 2016-12-20 18:51:23 +00:00
jenkins-bot 477f892423 Merge "Change wikitext link inspector name to avoid conflict" 2016-12-20 13:44:36 +00:00
jenkins-bot ced46300cb Merge "MWTemplatePage: Show a link to the template even when there's a description" 2016-12-20 11:04:24 +00:00
Bartosz Dziewoński 72569159b8 Add comments in some places where we really want to treat messages as HTML
Change-Id: I439338dabd4b031ed1c4cfc9d89af5a6f2971676
2016-12-20 10:50:15 +00:00
Bartosz Dziewoński dc3bae7d36 ve.init.MWWelcomeDialog: Don't treat text messages as HTML
This appears to be unintentional. The messages don't have any markup.

Change-Id: I6f6570c5ef90e4a06ead1a23f6f851021a77c234
2016-12-20 10:50:10 +00:00
jenkins-bot 2a4da6ede6 Merge "Update VE core submodule to master (f8fc228)" 2016-12-20 07:37:57 +00:00
Translation updater bot f6ba11dec9 Localisation updates from https://translatewiki.net.
Change-Id: I7601c2c303782796f9ca3090f0798b9e354baffa
2016-12-19 22:50:11 +01:00
Ed Sanders 46385a557e Ensure document base is always correct, even in source mode
Bug: T153624
Change-Id: I3f74f67ce975f5b371ab42adf5213256ae816f7f
2016-12-19 21:08:58 +00:00
Ed Sanders 323050467f Change wikitext link inspector name to avoid conflict
This was causing the VE link inspector to fail badly if
NWE was enabled.

Bug: T153668
Change-Id: Ie665715a5f5401e59fc6468b81a4122ca5ebd5a3
2016-12-19 12:03:58 +00:00
James D. Forrester d576fac49f MWTemplatePage: Show a link to the template even when there's a description
Bug: T51772
Change-Id: Ia7084dc7dd4e4c092c0d24b123da19721dca54a9
2016-12-18 21:56:12 +00:00
Translation updater bot 4a1cd55503 Localisation updates from https://translatewiki.net.
Change-Id: I19262ad5964b36fc84551c68ede397705980d44a
2016-12-18 22:18:37 +01:00
Ed Sanders ab78f52fa9 Don't allow $section to be unset
Change-Id: I46a36a08fc2e98aeb35774af8b26ebee313965f3
2016-12-18 11:30:18 +00:00