Changes for page ContentEditable

Last modified by mflorea on 2010/07/06 16:39

From version 13.1
edited by mflorea
on 2010/07/06 18:19
Change comment: There is no comment for this version
To version 21.1
edited by mflorea
on 2010/07/06 18:37
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -1,22 +1,10 @@
1 1  {{html clean="false"}}
2 -<style type="text/css">
3 -span.readOnly-selected::selection {
4 - background: #AAA;
5 -}
6 -span.readOnly-selected::-moz-selection {
7 - background: #AAA;
8 -}
9 -span.readOnly {
10 - border: 1px dashed #777;
11 - padding: 3px;
12 -}
13 -</style>
14 14  <script type="text/javascript">
15 15  function onAction(hook){
16 16   var iframe = document.createElement('iframe');
17 17   iframe.style.border = '1px solid black';
18 18   iframe.addEventListener('load', function() {
19 - iframe.contentWindow.document.body.innerHTML = '<p>before<span contentEditable="false" class="readOnly" onclick="this.className=\'readOnly readOnly-selected\'">text</span>after</p>';
7 + iframe.contentWindow.document.body.innerHTML = '<link rel="stylesheet" type="text/css" href="/xwiki/bin/ssx/Test/ContentEditable?language=en"/><p>before<span contentEditable="false" class="readOnly" onclick="this.className=\'readOnly readOnly-selected\'">text</span>after</p>';
20 20   //iframe.contentWindow.document.designMode = 'on';
21 21   iframe.contentWindow.document.body.contentEditable = true;
22 22   iframe.focus();
XWiki.StyleSheetExtension[0]
Caching policy
... ... @@ -1,0 +1,1 @@
1 +long
Code
... ... @@ -1,0 +1,14 @@
1 +span.readOnly-selected::selection {
2 + background-color: transparent;
3 +}
4 +span.readOnly-selected::-moz-selection {
5 + background-color: transparent;
6 +}
7 +span.readOnly {
8 + border: 1px dashed #777;
9 + padding: 3px;
10 +}
11 +
12 +span.readOnly-selected {
13 + background-color: #EEE;
14 +}
Name
... ... @@ -1,0 +1,1 @@
1 +ContentEditable
Parse content
... ... @@ -1,0 +1,1 @@
1 +No
Use this extension
... ... @@ -1,0 +1,1 @@
1 +onDemand