Page MenuHomePhabricator

[Epic] replace plain contenteditable with VisualEditor in ContentTranslation
Open, LowPublic160 Story Points

Description

This is just an exploration of an idea at this point, without architecture or due date.

ContentTranslation uses contenteditable for the translation editor. This works out mostly OK, because CX's purpose is to be a simple article creation tool rather than an advanced article editing tool.

Nevertheless, there are some issues in CX that could be solved by switching to the VE. Among them:

  • Compatibility with IE (for example T104646 and T105446).
  • Ability to start typing in empty lists (VE probably handles things like T103504 already).
  • Inserting templates (T105445).
  • ES: This list is a lot longer now - see "Blocks" list above.

Additionally, there are some other advantages, most obviously:

  • General consistency in different editing interfaces.
  • Possibility to share some of the linking controls.
  • localization of the formatting toolbar (T90221, although this can probably be achieved also with OOJS-ui).

What would be the disadvantages and the blockers? When I proposed this in early 2014, there was a consensus that VE is not ready to be used as a component, although I don't know any technical details about this. Did this change since then? For what it's worth, it seems to function fairly well as a component of Flow.

Blockers, challenges, disadvantages:

  • ULS IME - VE doesn't fully support it (yet). (T51569 - many of the remaining issues affect both CX & VE)
  • Highlighting parallel sentences may be challenging (but Ed says that it may be done with VE fragments).
  • Saving and retrieving. CX does it with DOM. With VE it will have to be something like saving the DM and applying transactions to restore that state of the annotations. VE can load and save DOM. You'd only need to store transactions if you wanted to preserve history.
  • Corresponding elements in source and translation - links, references, templates, highlighted sentences.
  • CX's parallel corpora functionality must be preserved.
  • Ability to restore drafts that were saved before the transition to VE. - ES: this shouldn't be an issue. May not be needed with the backwards compatibility plan.
  • Should it be before or after moving out of Beta?
  • LE team has few resources, but the more we delay it, the more tech debt accumulates.

Related Objects

View Standalone Graph
This task is connected to more than 200 other tasks. Only direct parents and subtasks are shown here. Use View Standalone Graph to show more of the graph.
StatusAssignedTask
ResolvedPginer-WMF
ResolvedPginer-WMF
InvalidNone
OpenNone
ResolvedPginer-WMF
ResolvedPginer-WMF
DuplicateNone
ResolvedAmire80
ResolvedEtonkovidova
OpenNone
ResolvedPginer-WMF
ResolvedPginer-WMF
ResolvedPginer-WMF
DuplicateNone
ResolvedAmire80
OpenNone
ResolvedArrbee
OpenNone
DuplicateNone
ResolvedPginer-WMF
ResolvedPginer-WMF
ResolvedPginer-WMF
ResolvedPginer-WMF
Resolvedsanthosh
DeclinedNone
OpenNone
OpenNone
ResolvedAmire80
InvalidNone
OpenAmire80
Resolveddchan
Resolvedsanthosh

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes
Amire80 updated the task description. (Show Details)Jul 16 2015, 4:49 PM

We have very simple APIs for getting the DM HTML from a surface, and loading DM HTML into a surface, so saving and retrieving can be done quite easily. You'd only need to save the transactions if you wanted to save the undo stack state.

Also you'll be able to load your current HTML via this same API, so it would solve "Ability to restore drafts that were saved before the transition to VE." as well.

One should also note that the "Blocks" list in this bug only goes one level deep. If you click through some of those bugs are epics which are blocked by an even longer lists bugs, e.g. T76455 on the link editor, which lists about 25 open bugs that using VE would fix.

Esanders updated the task description. (Show Details)Dec 20 2015, 1:03 PM
Elitre added a subscriber: Elitre.Jan 20 2016, 4:43 PM
Esanders added a comment.EditedApr 2 2016, 6:12 PM

One of the technical issues discussed was maintaining parallel paragraphs during translation. This commit in core https://gerrit.wikimedia.org/r/#/c/281124/ adds support for isolated sections which can't be merged, or selected across.

Jdforrester-WMF set the point value for this task to 0.Feb 9 2017, 6:01 PM
Jdforrester-WMF changed the point value for this task from 0 to 160.
Jdforrester-WMF moved this task from To Triage to VE-CX on the ContentTranslation-FY2017-18 board.
Jdforrester-WMF changed the point value for this task from 160 to 0.Jan 31 2018, 4:08 PM
Jdforrester-WMF changed the point value for this task from 0 to 160.
Pginer-WMF updated the task description. (Show Details)Mar 16 2018, 10:37 AM