Page MenuHomePhabricator

LivePreview: no changes reflected on preview/diff when using CodeEditor
Closed, ResolvedPublic

Description

Shortly: go to any JS/CSS/Scribunto source page (example), type anything, click on Show preview/changes - apparently no changes have been made. CodeEditor uses a different textarea box, so this won't work unless you switch to the standard editor mode (the upper-left corner button on the editor panel) and switch back again.

Event Timeline

PeterBowman raised the priority of this task from to Needs Triage.
PeterBowman updated the task description. (Show Details)
PeterBowman changed Security from none to None.
PeterBowman subscribed.
Aklapper triaged this task as Lowest priority.Dec 19 2014, 3:04 PM

Change 181944 had a related patch set uploaded (by Gerrit Patch Uploader):
mediawiki.action.edit.preview: Restore trigger LivePreviewPrepare

https://gerrit.wikimedia.org/r/181944

Patch-For-Review

matmarex assigned this task to Fomafix.
matmarex removed a project: Patch-For-Review.

Change 181944 merged by jenkins-bot:
mediawiki.action.edit.preview: Restore trigger LivePreviewPrepare

https://gerrit.wikimedia.org/r/181944

https://gerrit.wikimedia.org/r/182354 is an other solution without trigger LivePreviewPrepare.

We already solved the underlying problem in MediaWiki core and CodeEditor by standardising on TextSelection API for retrieval of textarea content. This is already used by editWarning, and LivePreview should use it as well. That eliminates this problem.

Change 182415 had a related patch set uploaded (by Gerrit Patch Uploader):
mediawiki.action.edit.preview: Use .textSelection( 'getContents' )

https://gerrit.wikimedia.org/r/182415

Patch-For-Review

Change 182415 merged by jenkins-bot:
mediawiki.action.edit.preview: Use .textSelection( 'getContents' )

https://gerrit.wikimedia.org/r/182415