[silva.core.editor][Sylvain Viollon] Tag 3.0.2.
[email protected] Wed, 09 Oct 2013 15:38:01 +0200
| Newsgroups | gmane.comp.web.zope.silva.cvs |
|---|---|
| Message-ID | <[email protected]> |
author: Sylvain Viollon
date: Wed Oct 09 15:37:16 2013 +0200
revision: 267:4247880ece43 in silva.core.editor
branch:
details: https://hg.infrae.com/silva.core.editor?cmd=changeset;node=4247880ece43
modified: README.txt docs/HISTORY.txt setup.py src/silva/core/editor/static/content.min.css src/silva/core/editor/static/editor.min.js
added:
removed:
log: Tag 3.0.2.
Subject: [silva.core.editor][Sylvain Viollon] Added tag silva.core.editor-3.0.2 for changeset 4247880ece43
author: Sylvain Viollon
date: Wed Oct 09 15:37:26 2013 +0200
revision: 268:9efd869768e2 in silva.core.editor
branch:
details: https://hg.infrae.com/silva.core.editor?cmd=changeset;node=9efd869768e2
modified: .hgtags
added:
removed:
log: Added tag silva.core.editor-3.0.2 for changeset 4247880ece43
Subject: [silva.core.editor][Sylvain Viollon] Bump version.
author: Sylvain Viollon
date: Wed Oct 09 15:37:58 2013 +0200
revision: 269:9b6c9b4e5968 in silva.core.editor
branch:
details: https://hg.infrae.com/silva.core.editor?cmd=changeset;node=9b6c9b4e5968
modified: docs/HISTORY.txt setup.py
added:
removed:
log: Bump version.
diffstat:
.hgtags | 1 +
README.txt | 2 +-
docs/HISTORY.txt | 18 +++++++++++++++++-
setup.py | 2 +-
src/silva/core/editor/static/content.min.css | 2 +-
src/silva/core/editor/static/editor.min.js | 2 +-
6 files changed, 22 insertions(+), 5 deletions(-)
diffs (80 lines):
diff -r 13da072f66cf -r 9b6c9b4e5968 .hgtags
--- a/.hgtags Tue Sep 17 14:57:16 2013 +0200
+++ b/.hgtags Wed Oct 09 15:37:58 2013 +0200
@@ -3,3 +3,4 @@
f9e7a364c9faf1a93a4ebd0dbaecbab6276ad86f silva.core.editor-3.0c2
4ebfd9a038d3a73c5586442697667350c5a327c7 silva.core.editor-3.0
7816230c832cae9a5d450f93c0497a0a777802e9 silva.core.editor-3.0.1
+4247880ece430d1d2f67c885eafd00495473ca56 silva.core.editor-3.0.2
diff -r 13da072f66cf -r 9b6c9b4e5968 README.txt
--- a/README.txt Tue Sep 17 14:57:16 2013 +0200
+++ b/README.txt Wed Oct 09 15:37:58 2013 +0200
@@ -8,7 +8,7 @@
Support for `CKEditor`_ within `Silva`_.
.. _CKEditor: http://ckeditor.com/
-.. _Silva: http://infrae.com/products/silva
+.. _Silva: http://silvacms.org/
Code repository
===============
diff -r 13da072f66cf -r 9b6c9b4e5968 docs/HISTORY.txt
--- a/docs/HISTORY.txt Tue Sep 17 14:57:16 2013 +0200
+++ b/docs/HISTORY.txt Wed Oct 09 15:37:58 2013 +0200
@@ -1,11 +1,27 @@
Changes
=======
-3.0.2 (unreleased)
+3.0.3 (unreleased)
------------------
* ...
+3.0.2 (2013/10/09)
+------------------
+
+* Extend text API: introduction can be truncated to a given of words
+ in addition to a number of letters. Support changing the level of
+ titles (like h1 are converted to h2 and so on).
+
+* Add a CKEditor plugin to style tables.
+
+* Improve selection of Silva block elements in CKEditor.
+
+* Add support for various flavor of broken links, like invalid external URL.
+
+* Add a per-tag HTML sanitizer for more control on the edition
+ process. An upgrade is required for it to work.
+
3.0.1 (2013/05/24)
------------------
diff -r 13da072f66cf -r 9b6c9b4e5968 setup.py
--- a/setup.py Tue Sep 17 14:57:16 2013 +0200
+++ b/setup.py Wed Oct 09 15:37:58 2013 +0200
@@ -5,7 +5,7 @@
from setuptools import setup, find_packages
import os
-version = '3.0.2dev'
+version = '3.0.3dev'
tests_require = [
'Products.Silva [test]',
diff -r 13da072f66cf -r 9b6c9b4e5968 src/silva/core/editor/static/content.min.css
--- a/src/silva/core/editor/static/content.min.css Tue Sep 17 14:57:16 2013 +0200
+++ b/src/silva/core/editor/static/content.min.css Wed Oct 09 15:37:58 2013 +0200
@@ -1,1 +1,1 @@
-body{font:70% Verdana,Helvetica,Arial,sans-serif}h1,h2,h3,h4,h5,h6{margin:1em 0 0}h1{margin-top:.8em;margin-bottom:.7em;font-size:170%}h2{margin-bottom:.6em;font-size:145%}h3{margin-bottom:.5em;font-size:120%}h4{margin-bottom:.2em;font-size:110%}h5{margin-bottom:.1em;font-size:105%}ul{margin:.5em 0;padding-left:1.4em}ol{margin:.5em 0;padding-left:1.9em}p.lead{font-weight:700}p.annotation{font-style:italic}a.broken-link{color:#a00}table.plain,table.list,table.grid,table.datagrid{width:100%;border:0;border-collapse:collapse}table.datagrid{border-collapse:separate;border-spacing:2px}table.plain td,table.plain th,table.list td,table.list th,table.grid td,table.grid th,table.datagrid td,table.datagrid th{border:1px solid #777;text-align:left;padding:0 4px 0 0}table.plain td,table.plain th{bord
er-style:dashed}table.list td,table.list th{border-right-style:dashed;border-left-style:dashed}table.grid td,table.grid th,table.datagrid td,table.datagrid th{padding:0 2px}table.datagrid td
,table.datagrid th{border-width:2px}
\ No newline at end of file
+body{font:70% Verdana,Helvetica,Arial,sans-serif}h1,h2,h3,h4,h5,h6{margin:1em 0 0 0}h1{margin-top:.8em;margin-bottom:.7em;font-size:170%}h2{margin-bottom:.6em;font-size:145%}h3{margin-bottom:.5em;font-size:120%}h4{margin-bottom:.2em;font-size:110%}h5{margin-bottom:.1em;font-size:105%}ul{margin:.5em 0;padding-left:1.4em}ol{margin:.5em 0;padding-left:1.9em}p.lead{font-weight:700}p.annotation{font-style:italic}a.broken-link{color:#a00}table.plain,table.list,table.grid,table.datagrid{width:100%;border:0;border-collapse:collapse}table.datagrid{border-collapse:separate;border-spacing:2px}table.plain td,table.plain th,table.list td,table.list th,table.grid td,table.grid th,table.datagrid td,table.datagrid th{border:1px solid #777;text-align:left;padding:0 4px 0 0}table.plain td,table.plain th{bo
rder-style:dashed}table.list td,table.list th{border-right-style:dashed;border-left-style:dashed}table.grid td,table.grid th,table.datagrid td,table.datagrid th{padding:0 2px}table.datagrid
td,table.datagrid th{border-width:2px}
\ No newline at end of file
diff -r 13da072f66cf -r 9b6c9b4e5968 src/silva/core/editor/static/editor.min.js
--- a/src/silva/core/editor/static/editor.min.js Tue Sep 17 14:57:16 2013 +0200
+++ b/src/silva/core/editor/static/editor.min.js Wed Oct 09 15:37:58 2013 +0200
@@ -1,1 +1,1 @@
-!function($,infrae,CKEDITOR){infrae.interfaces.register("editor");var MODULE_BLACKLIST=["save","link","flash","image","filebrowser","iframe","forms"],FULL_SETTINGS=[],EMBDED_SETTINGS=[];$(document).bind("load-smiplugins",function(event,smi){var build_settings=function(configuration,embded){var plugins_blacklist=MODULE_BLACKLIST.slice(),plugins_extra=configuration.plugins;if(embded){var index=$.inArray("silvasave",plugins_extra);plugins_blacklist.push("silvasave"),index>-1&&plugins_extra.splice(index,1)}var settings={entities:!1,fullPage:!1,basicEntities:!0,language:smi.get_language(),contentsCss:configuration.contents_css,silvaFormats:configuration.formats,silvaTableStyles:configuration.table_styles,extraPlugins:plugins_extra.join(","),removePlugins:plugins_blacklist.join(","),toolbar:"Si
lva",toolbar_Silva:configuration.toolbars,height:"2000px",resize_enabled:!1,disable_colors:configuration.disable_colors,startupShowBorders:configuration.startup_show_borders,bodyClass:config
uration.editor_body_class,dialog_buttonsOrder:"rtl"};return configuration.skin&&(settings.skin=configuration.skin),settings},get_settings=function(name,embded){var registry=embded?EMBDED_SETTINGS:FULL_SETTINGS;return void 0!==registry[name]?$.when(registry[name]):function(){return $.ajax({url:smi.options.editor.configuration,dataType:"json",data:[{name:"name",value:name}]}).then(function(configuration){for(var key in configuration.paths)CKEDITOR.plugins.addExternal(key,configuration.paths[key]);return FULL_SETTINGS[name]=build_settings(configuration,!1),EMBDED_SETTINGS[name]=build_settings(configuration,!0),registry[name]},function(request){return $.Deferred().reject(request)})}()},create_html_field=function(data){var $textarea=$(this);get_settings($textarea.data("editor-configuration"),!
0).done(function(settings){var editor=CKEDITOR.replace($textarea.get(0),$.extend({},settings,{height:"300px"}));editor.on("instanceReady",function(){void 0!==data.popup&&infrae.ui.ResizeDial
og(data.popup)}),data.form.bind("serialize-smiform",function(){$textarea.val(editor.getData())}),data.container.bind("clean-smiform",function(){try{editor.destroy(!0)}catch(error){window.console&&console.log&&console.log("Error while destroying field editor",error)}})})};$(document).on("loadwidget-smiform",".form-fields-container",function(event,data){$(this).find(".field-htmltext").each(function(){create_html_field.call(this,data)}),event.stopPropagation()}),infrae.views.view({iface:"editor",name:"content",factory:function($content,data,smi){var editor=null;return smi.objection=function(){return null!=editor&&editor.checkDirty()?infrae.ui.ConfirmationDialog({title:"Modifications",message:"This document has been modified. If you continue you will lose these modifications. Do you want to c
ontinue?",buttons:{Save:function(){var url=$("#content-url").attr("href")+"/++rest++silva.core.editor.save",data={};return data[editor.name]=editor.getData(),$.ajax({url:url,type:"POST",data
:data})},Discard:function(){return!0},Cancel:function(){return!1}}}):null},{jsont:'<textarea name="{data.name|htmltag}">{data.text|html}</textarea>',render:function(){return get_settings(data.configuration).done(function(settings){var textarea=$content.children("textarea").get(0),resize=function(){var height=$content.innerHeight()-4,width=$content.innerWidth();editor.resize(width,height)};editor=CKEDITOR.replace(textarea,settings),editor.on("instanceReady",resize),editor.on("instanceReady",function(){$(window).bind("resize.smi-editor",resize),$(window).bind("workspace-resize-smi.smi-editor",resize)})})},cleanup:function(){if($(window).unbind("resize.smi-editor"),$(window).unbind("workspace-resize-smi.smi-editor"),$content.empty(),null!=editor)try{editor.destroy(!0),editor=null}catch(error
){window.console&&console.log&&console.log("Error while destroying editor",error)}}}}})})}(jQuery,infrae,CKEDITOR);
\ No newline at end of file
+(function($,infrae,CKEDITOR){infrae.interfaces.register("editor");var MODULE_BLACKLIST=["save","link","flash","image","filebrowser","iframe","forms"],FULL_SETTINGS=[],EMBDED_SETTINGS=[];$(document).bind("load-smiplugins",function(event,smi){var build_settings=function(configuration,embded){var plugins_blacklist=MODULE_BLACKLIST.slice(),plugins_extra=configuration.plugins;if(embded){var index=$.inArray("silvasave",plugins_extra);plugins_blacklist.push("silvasave"),index>-1&&plugins_extra.splice(index,1)}var settings={entities:!1,fullPage:!1,basicEntities:!0,language:smi.get_language(),contentsCss:configuration.contents_css,silvaFormats:configuration.formats,silvaTableStyles:configuration.table_styles,extraPlugins:plugins_extra.join(","),removePlugins:plugins_blacklist.join(","),toolbar:"Si
lva",toolbar_Silva:configuration.toolbars,height:"2000px",resize_enabled:!1,disable_colors:configuration.disable_colors,startupShowBorders:configuration.startup_show_borders,bodyClass:config
uration.editor_body_class,dialog_buttonsOrder:"rtl"};return configuration.skin&&(settings.skin=configuration.skin),settings},get_settings=function(name,embded){var registry=embded?EMBDED_SETTINGS:FULL_SETTINGS;return void 0!==registry[name]?$.when(registry[name]):function(){return $.ajax({url:smi.options.editor.configuration,dataType:"json",data:[{name:"name",value:name}]}).then(function(configuration){for(var key in configuration.paths)CKEDITOR.plugins.addExternal(key,configuration.paths[key]);return FULL_SETTINGS[name]=build_settings(configuration,!1),EMBDED_SETTINGS[name]=build_settings(configuration,!0),registry[name]},function(request){return $.Deferred().reject(request)})}()},create_html_field=function(data){var $textarea=$(this);get_settings($textarea.data("editor-configuration"),!
0).done(function(settings){var editor=CKEDITOR.replace($textarea.get(0),$.extend({},settings,{height:"300px"}));editor.on("instanceReady",function(){void 0!==data.popup&&infrae.ui.ResizeDial
og(data.popup)}),data.form.bind("serialize-smiform",function(){$textarea.val(editor.getData())}),data.container.bind("clean-smiform",function(){try{editor.destroy(!0)}catch(error){window.console&&console.log&&console.log("Error while destroying field editor",error)}})})};$(document).on("loadwidget-smiform",".form-fields-container",function(event,data){$(this).find(".field-htmltext").each(function(){create_html_field.call(this,data)}),event.stopPropagation()}),infrae.views.view({iface:"editor",name:"content",factory:function($content,data,smi){var editor=null;return smi.objection=function(){return null!=editor&&editor.checkDirty()?infrae.ui.ConfirmationDialog({title:"Modifications",message:"This document has been modified. If you continue you will lose these modifications. Do you want to c
ontinue?",buttons:{Save:function(){var url=$("#content-url").attr("href")+"/++rest++silva.core.editor.save",data={};return data[editor.name]=editor.getData(),$.ajax({url:url,type:"POST",data
:data})},Discard:function(){return!0},Cancel:function(){return!1}}}):null},{jsont:'<textarea name="{data.name|htmltag}">{data.text|html}</textarea>',render:function(){return get_settings(data.configuration).done(function(settings){var textarea=$content.children("textarea").get(0),resize=function(){var height=$content.innerHeight()-4,width=$content.innerWidth();editor.resize(width,height)};editor=CKEDITOR.replace(textarea,settings),editor.on("instanceReady",resize),editor.on("instanceReady",function(){$(window).bind("resize.smi-editor",resize),$(window).bind("workspace-resize-smi.smi-editor",resize)})})},cleanup:function(){if($(window).unbind("resize.smi-editor"),$(window).unbind("workspace-resize-smi.smi-editor"),$content.empty(),null!=editor)try{editor.destroy(!0),editor=null}catch(error
){window.console&&console.log&&console.log("Error while destroying editor",error)}}}}})})})(jQuery,infrae,CKEDITOR);
\ No newline at end of file