* DirectParsoidClient makes use of parsoid directly for performing
transformations on both wikitext and/or HTML contents.
* Also, it's used to fetch HTML from parsoid's parser cache. Before,
this operation was done via RESTBase but now it's being fetched in
core's parsoid parser cache.
* This patch also enables VE clients to transform HTML to
Wikitext when switching from HTML to source mode on. It
makes use of the HtmlInputTransformHelper to perform this
transformation.
* Now, VE client can make use of core code for switching
between HTML to source mode and back without RESTBase.
Change-Id: I5c7cfcc4086d8da7905897194d8601aa07418b59
Part of my secret plan to delete ApiParsoidTrait.
* Inject RevisionLookup into ApiVisualEditor
* Use RevisionLookup::getRevisionById instead of ApiParsoidTrait::getValidRevision
* Use RevisionLookup::getRevisionByTitle instead of ApiParsoidTrait::getLatestRevision
* Use standard MediaWiki error messages
* Delete unused ApiParsoidTrait::getValidRevision
* Delete unused ApiParsoidTrait::getLatestRevision
Depends-On: I7244ee4916fb011fad5faa1d9f837e83f6ac2dc1
Change-Id: I8089c0c516d9dba52e931a0a80740c0361216dbd
New changes:
878ebf301 Localisation updates from https://translatewiki.net.
b56ad2792 Localisation updates from https://translatewiki.net.
a3a861bae Localisation updates from https://translatewiki.net.
754ee73dd Fix transformStyleAttributes tests on Firefox on Windows
5dcc0f107 build: Upgrade various devDependencies to latest and make pass
Bug: T319520
Change-Id: I3fa0175b69b6a97835c7edb856e4ab0af4cb61cc
This adds assertions for the return values of the following pactions:
metadata, parse, parsefragment.
It also adds a test that asserts that edits are not possible with
an invalid token.
Change-Id: Idb453d3561a46930afb5366c1a96787895fc8e40
This VE paction was removed in I90d775dd71d5f5a61d651b63d946ab60a27e2ca3
so this code can be deleted per Bartosz, so this patch removes the code.
NOTE: A merged API test that uses this is also removed along side.
Change-Id: I4ff75df57fd58f508ef7212486e52cb11a7cfb57
New changes:
945ca158b Localisation updates from https://translatewiki.net.
42ce721c8 build: Update language lists
dfeda8a1a Localisation updates from https://translatewiki.net.
d0d5771cb Localisation updates from https://translatewiki.net.
0b78ead3f build: Update language lists to add 'mrh'
13d8c8d4f Fixup Chromium's native Enter behaviour on Android Gboard
37bdbb860 Localisation updates from https://translatewiki.net.
6b9937c19 Update OOUI to v0.45.0
Bug: T312558
Change-Id: Icfb0c6f4e70ffd53533d3f0e8cf40ca43b3d8663
The previous implementation tried to do this, but looked
at the query string which can be set to action=edit by VE.
Bug: T318772
Change-Id: I4f0f8d52488a6b259033232afb8ea616458275de
The test file is just a placeholder for now, so we can enable the CI job.
Actual tests will follow in a separate patch.
Bug: T318403
Change-Id: I8105f49f8898c8ebfd80eb898d30a49e58db5b25
* DirectParsoidClient: Actually allow null to be provided.
Previously we tried to call methods on it unconditionally.
* VRSParsoidClient: Require the param to be provided (even if null).
No reason to diverge from the interface, which requires it.
Change-Id: Id9a450dc8b8eb3e82cf87718b96975e5a3c6180c
Setting the config var then loading mediawiki.action.view.postEdit
will already trigger the notification code, so we can remove this
duplicated code now.
Bug: T240041
Change-Id: If0d1aa4e734dab7cca168e78216f229b9924bab7
This follows up the initial fix with additional sanitation and a
regression test. See I21c7a2b2541061a858a9791a2cb12866acd38dc5.
Bug: T318083
Change-Id: I4e433e711c068336a888f4aafa243455764fd710
All code that used to live in ParsoidHelper has been moved to
VisualEditorParsoidClientFactory and VRSParsoidClient.
ParsoidHelper is no longer needed.
Change-Id: I21c4a8cd86f8d085e75a601ed6d2509dedd75d42