Open main menu

Visual editor

Revision as of 23:35, 19 April 2023 by Admin (talk | contribs) (Updated for 2023)

(diff) ← Older revision | Approved revision (diff) | Latest revision (diff) | Newer revision → (diff)
Visual editor Dialog-information.svg
Direct editing
Image shows: Direct editing
Summary
Description: A reliable rich-text editor for MediaWiki. Allows you to just "edit the page you see" while being aware of all the syntactically rich features of templates, extensions etc.
More
Notes: The Visual Editor is available Here and on Wikipedia.
Test: Login to the wiki, and make an edit in your personal sandbox.




Visual Editor

Links

Back story

Wiki markup is a sort of shorthand for more complicated HTML markup designed to create nicely formatted web documents. Although in the beginning wiki markup simplified the process of creating nicely formatted content, that shorthand can get increasingly complex in order to produce complicated layout and content. The extension of the markup system over time to include a template subsystem and macros inevitably leads to a tension between ease of use, and power. This tension was one of the primary factors that the Wikimedia Foundation cited as an impediment to new content collaborators for the Wikipedia. [1][2][3]. A visual editor was deemed nearly impossible after many early attempts failed, but with the advent of Node.js technology, it became an idea that was plausible again.

Fast-forward to 2016 when VisualEditor was fully working as a Visual WYSIWYG interface for editing MediaWiki content, using a Node.js backend called 'Parsoid' which is a bidirectional runtime wiki parser. This caused a big software architectural problem: there were two parsers to maintain: the 'normal' (now 'legacy') core parser in PHP, and the Visual Editor parser (Parsoid) in JavaScript. So, by the end of 2019, Parsoid was ported to PHP, and distributed with MediaWiki 1.35 as part of the [mw:Parsoid/Parser_Unification|Parser Unification initiative]].

Intro

  • VIDEO Wikimania 2013
  • VIDEO (47 min.) with James Forrester - Product Manager and Roan Kattouw - Sr. Software Engineer presenting Jan 13, 2014 at Linux.conf.au on the contentEditable aspects of the system.

The Visual Editor for MediaWiki relies on Parsoid

"Parsoid implements a bidirectional wikitext parser and interpreter. It converts and interprets wikitext into an annotated HTML DOM, which can then be edited with HTML editor tools such as the Visual Editor. It also provides the conversion of a (possibly modified) HTML DOM back to wikitext."

Robin Cover would be proud. It round-trips wiki to HTML + RDFa and back.

Installation

VisualEditor is included with MediaWiki. See https://www.mediawiki.org/wiki/Extension:VisualEditor


Extensions

  1. mw:Extension:VisualEditor
  2. mw:Extension:Parsoid

Extensions that hook into VE

Extension authors should register VisualEditorPluginModules

  1. https://www.mediawiki.org/wiki/Extension:Proofread_Page
  2. https://www.mediawiki.org/wiki/Extension:CodeMirror (syntax highlighting)
  3. https://www.mediawiki.org/wiki/Extension:Disambiguator
  4. https://www.mediawiki.org/wiki/Extension:Graph
  5. https://www.mediawiki.org/wiki/Extension:Kartographer (Open Street Maps)
  6. https://www.mediawiki.org/wiki/Extension:LanguageTool
  7. https://www.mediawiki.org/wiki/Extension:Math
  8. https://www.mediawiki.org/wiki/Extension:Score (LillyPond)
  9. https://www.mediawiki.org/wiki/Extension:SyntaxHighlight
  10. https://www.mediawiki.org/wiki/Extension:TemplateData
  11. https://www.mediawiki.org/wiki/Extension:WikiHiero


Customizing Visual Editor with custom menus, tools, commands


API / Developer Docs / DevOps

References