W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2014


From: Ben Peters <Ben.Peters@microsoft.com>
Date: Fri, 2 May 2014 00:31:00 +0000
To: "public-webapps@w3.org" <public-webapps@w3.org>
Message-ID: <53c1901341cd4136b9ea868754700bdc@BLUPR03MB437.namprd03.prod.outlook.com>
I have been discussing a new concept with some people for enabling a subset of contentEditable behavior without all of the built-in formatting and some other functionality. It was discussed a bit at the Extensible Web Summit [1]. Below is a draft I wrote about this, which is also on GitHub [2]. We would like feedback on this concept from the broader community.

HTML uses the contentEditable='true' attribute to allow text input. The behavior of contentEditable varies widely from browser to browser and is very complex, resulting in many bugs and behavior differences between browsers. Editing frameworks like TinyMCE, goog.editor, and CKEditor are used in thousands of sites to overcome these issues. However, built-in browser editing varies so much that these frameworks and sites like Google Docs and Microsoft Office Online that have built custom solutions end up disable a large portion of the functionality of contentEditable. Ultimately this means that browsers support functionality that is largely disabled, and frameworks and sites have to work around the default behavior.

To make this simpler for sites, frameworks, and browsers, it makes sense to enable a new, simpler version of contentEditable that provides basic functionality only. For the sake of discussion, call it contentEditable='minimal'. The functionality provided by the browser under contentEditable='minimal' would be as follows:
* Caret drawing
* Events such as Keyboard , Clipboard, Drag and Drop
* Some keyboard input handling- caret movement, typing of characters including Input Method Editor input
* Selection drawing and manipulation according to the new Selection API spec

Frameworks and sites would then enable any formatting they desire using script.

- Ben

[1] http://oksoclap.com/p/extensible_content_editing
[2] https://github.com/w3c/editing-explainer/wiki/contentEditable=minimal 
Received on Friday, 2 May 2014 00:31:30 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:27:12 UTC