Permalink
Browse files

Merge branch 'hotfix-0.21.x' of github.com:alohaeditor/Aloha-Editor i…

…nto hotfix-0.21.x
  • Loading branch information...
2 parents ff603a5 + 4d3f298 commit b224cc264a5be9f92020b1ec55d321a8ac631fc3 Petro Salema committed Sep 5, 2012
Showing with 6,251 additions and 5,372 deletions.
  1. +76 −0 CHANGELOG.md
  2. 0 build/command-tests-changelog.md
  3. +0 −31 build/hotfix-0.21.x-changelog.md
  4. +7 −2 build/hotfix-changelog.md
  5. +3 −1 doc/guides/output/plugin_block.html
  6. +183 −0 doc/guides/output/plugin_captioned-image.html
  7. +3 −0 doc/guides/output/plugin_contenthandler.html
  8. +15 −12 doc/guides/output/plugin_image.html
  9. +1 −0 doc/guides/output/plugins.html
  10. +39 −0 doc/guides/source/plugin_captioned-image.textile
  11. +3 −0 doc/guides/source/plugin_contenthandler.textile
  12. +1 −0 doc/guides/source/plugins.textile
  13. +3 −1 pom.xml
  14. +1 −1 src/css/aloha.css
  15. +5 −1 src/demo/boilerplate/index.html
  16. +3 −0 src/demo/boilerplate/js/aloha-config.js
  17. +447 −283 src/lib/aloha/engine.js
  18. +10 −0 src/lib/aloha/markup.js
  19. +554 −555 src/lib/aloha/repositorymanager.js
  20. +102 −78 src/lib/aloha/selection.js
  21. +16 −22 src/plugins/common/align/lib/align-plugin.js
  22. +1 −1 src/plugins/common/contenthandler/lib/contenthandler-plugin.js
  23. +48 −19 src/plugins/common/contenthandler/lib/sanitizecontenthandler.js
  24. +2 −2 src/plugins/common/format/lib/format-plugin.js
  25. +1 −1 src/plugins/common/table/lib/table.js
  26. +27 −27 src/plugins/common/ui/css/ui.css
  27. +4 −0 src/plugins/common/ui/lib/ui-plugin.js
  28. +131 −8 src/plugins/extra/captioned-image/lib/captioned-image-plugin.js
  29. +596 −0 src/plugins/extra/wai-lang/lib/iso639-1-de.js
  30. +0 −587 src/plugins/extra/wai-lang/lib/iso639-1-de.json
  31. +595 −0 src/plugins/extra/wai-lang/lib/iso639-1-en.js
  32. +0 −587 src/plugins/extra/wai-lang/lib/iso639-1-en.json
  33. +1,570 −0 src/plugins/extra/wai-lang/lib/iso639-2-de.js
  34. +0 −1,562 src/plugins/extra/wai-lang/lib/iso639-2-de.json
  35. +1,570 −0 src/plugins/extra/wai-lang/lib/iso639-2-en.js
  36. +0 −1,562 src/plugins/extra/wai-lang/lib/iso639-2-en.json
  37. +17 −17 src/plugins/extra/wai-lang/lib/languages.js
  38. +11 −11 src/test/unit/commandtest.js
  39. +37 −0 src/test/unit/util/arrays-tests.js
  40. +1 −1 src/test/unit/util/index.html
  41. +57 −0 src/test/unit/wailangrepo.html
  42. +111 −0 src/test/unit/wailangrepotests.js
View
@@ -12,8 +12,47 @@ All changes are categorized into one of the following keywords:
usage, or intent of an existing one.
- **MANUAL CHANGE**: The change requires changes to existing implementation.
+# 0.22.x
+
+## 0.22.0 - 2012/09/03
+
+- **MANUAL CHANGE**: Updated UI CSS regarding button selector.
+
+- **MANUAL CHANGE**: Added a demo of placeholders to boilerplate.
+
+- **FEATURE**: Image Caption Plugin: caption now supports sanitize contenthandler & disable / enable of line breaks;
+ <code>
+ Aloha.settings.contentHandler.handler: {
+ sanitize: {
+ '.aloha-captioned-image-caption': { elements: [ 'em', 'strong' ] }
+ }
+ }
+ </code>
+
+ <code>
+ Aloha.settings.plugins: {
+ captionedImage: {
+ allowLinebreak: [ 'p' ], // ['br', 'p'], true or false (default)
+ }
+ }
+ </code>
+
+- **BUG**: In the sidebar the panel entry for the format plugin was always shown; now when the formatOptions is empty the empty (useless) sidebar panel will be hidden.
+
+- **BUG**: Align Plugin button status was not shown correctly.
+
# 0.21.x
+## 0.21.4 - 2012/09/03
+
+- **ENHANCEMENT**: Added labels to the image-plugin url, title, width, height input fields
+
+ This change also rearranges the order of image-plugin components in the toolbar.
+
+- **BUG**: Fixed the ContentHandlerManager to use the content handlers in the correct order.
+
+- **BUG**: Fixed clicking custom block handles activates the image plugin
+
## 0.21.3 - 2012/08/24
- **ENHANCEMENT**: An error was turned into a warning
@@ -498,6 +537,41 @@ All changes are categorized into one of the following keywords:
- **BUG**: core&numerated-headers-plugin: Fixed that sometimes DOM INDEX EXCEPTIONS occured when formating a list of paragraphs.
+
+# 0.20.x
+
+## 0.20.23 - 2012/08/24
+
+- **ENHANCEMENT**: changed loading procedure of languages in wai lang plugin from AJAX to require.js
+- **BUG**: resolved issue with opening the sidebar when clicking on table WAI button.
+
+## 0.20.22 - 2012/08/16
+
+- **ENHANCEMENT**: link-plugin: Removed unwanted margins from the sidebar panel of the link attribute.
+- **BUG**: Fixed block formatting (p, h1, ...)
+
+ To reproduce the error
+
+ * insert two paragraphs into an editable
+
+ "
+ Paragraph1
+ Paragraph2
+ "
+
+ * select both paragraphs and format them as h2
+ * click into the second paragraph and format as h3
+
+ The result before this fix would have been that in the last step both
+ paragraphs were formatted as h3.
+
+- **BUG**: core: We now also remove jquery* attributes before the content is saved.
+- **BUG**: core: We now log a warning to the console if repositories run into timeouts.
+- **BUG**: wai-lang: We now load the language dataset in the query method. This fixes the issue that if the first request went wrong it was never loaded again.
+- **BUG**: sidebar: The sidebar now remembers the current selection and refreshes itself when it is being opened.
+- **BUG**: wordcontenthandler: Fixed the pasting of tables with empty cells.
+- **BUG**: wordcontenthandler: Fixed the pasting of lists in chrome and IE9.
+
## 0.20.21 - 2012/08/06
- **MANUAL CHANGE**: Changed the aloha-smart-content-changed event
@@ -706,6 +780,7 @@ All changes are categorized into one of the following keywords:
- **BUG** floatingmenu: Fixed problem with showing floatingmenu shadow too early
- **BUG** core: Fixed a permission error in Firefox, when Aloha Editor tried to access a document property of an external ressource
- **BUG** table-plugin: Fixed the cleanup of the table cells on blur not cleaning up correctly (caused by a typo in the element class)
+- **BUG** core: Fixed a javascript error in IE9 stating that the method createContextualFragment doesn't exist (fixed in extjs)
## 0.20.8 - 2012/04/06
@@ -714,6 +789,7 @@ All changes are categorized into one of the following keywords:
- **BUG** core: The cursor processing around non-contenteditable elements (blocks) was not functioning as described or desired. It now behaves with more stability especially on Internet Explorer.
- **ENHANCEMENT** core: Improved efficiency of cursor processing, especially around blocks.
- **FEATURE** core: It is now possible to place the caret between two adjecent non-contenteditable elements.
+- **ENHANCEMENT** core: The jquery-plugin require plugin will now be able to return loaded plugins. Previously loaded plugins were just accessible through the extended jquery object.
- **FEATURE** editable.js: introduced method setContents() -- use Aloha.getEditableById('my-editable').setContents('Aloha World') to set the contents of the editable with the ID my-editable
- **BUG** smartContentChange is now again triggered when pressing enter key; and new: delete / backspace keys
- **ENHANCEMENT** enabled image plugin in boilerplate demo. needs some enhancements to be more user friendly
No changes.
@@ -8,34 +8,3 @@ All changes are categorized into one of the following keywords:
----
-- **BUG**: the sidebar didn't always update the height of panels correctly.
-
-- **ENHANCEMENT**: error was turned into a warning
-
- The error message "encountered range object without start or end
- container" was incorrectly logged as an error instead of a
- warning.
-
-- **ENHANCEMENT**: Added a new block implementation of Aloha Editor blocks, which
- doesn't render any tag fill icons or borders. This is useful for
- tags that should be editable with Aloha Editor.
-
- To use this block type, just wrap your tag content in a <div>
- with the following attribute:
-
- data-aloha-block-type="EmptyBlock"
-
-- **BUG**: Fixed JS error in Aloha.unbind()
-
-- **ENHANCEMENT**: Added jQuery method mahaloBlock() to "unblock" the elements from a jQuery collection. Added method .unblock() for Blocks to "unblock" a block instance (in both cases without removing the DOM element from the DOM).
-
-- **BUG**: Fixed adding of unwanted <span>'S before tables every time an editable was deactivated when the table plugin and block plugin was used.
-
-- **ENHANCEMENT**: repository-browser: The repository browser will now automatically increase its height.
-
-- **BUG**: Fixed selecting with keyboard or mouse in editables that are nested in blocks, when using the Internet Explorer.
-
-- **BUG**: Fixed block draghandles are sometimes missing
-
-- **BUG**: Fixed the ContentHandlerManager to use the content handlers in the correct order.
-- **BUG**: Fixed clicking custom block handles activates the image plugin
@@ -8,6 +8,11 @@ All changes are categorized into one of the following keywords:
----
-- **ENHANCEMENT**: added labels to the image-plugin url, title, width, height input fields
+- **BUG**: added the del format button to the possible format plugin buttons
- This change also rearranges the order of image-plugin components in the toolbar.
+ The del button is not enabled by default. To enable it, it has to
+ be configured. For example
+
+ Aloha.settings.plugins.format.config = ['del', ...];
+
+ See http://aloha-editor.org/guides/plugin_format.html
@@ -293,7 +293,9 @@ <h4 id="custom-block-handles">4.2 Custom Block Handles</h4>
}
}
}
-</pre></div><h4 id="nested-aloha-editables">4.3 Nested Aloha Editables</h4>
+</pre></div>
+<div class="note"><p>if you use image elements as icons, mark them with the class &#8216;aloha-ui&#8217;, otherwise the image plugin will pick them up as normal content images that can be resized etc.</p></div>
+<h4 id="nested-aloha-editables">4.3 Nested Aloha Editables</h4>
<p>If you want to mark a certain area inside a block as Aloha editable again, you just need to apply the <tt>aloha-editable</tt> <span class="caps">CSS</span> class to it. If the default behavior is not what you want, you can also call <code>$element.find(...).aloha()</code> in the <code>init()</code> and/or <code>update()</code> method.</p>
<h3 id="editing-api">5 Editing <span class="caps">API</span></h3>
<p>The attributes of an Aloha Block can be edited through an automatically generated User Interface in the <strong>Aloha Sidebar</strong>. Of course, this user interface needs to know which block attributes are editable. For that, an Aloha Block can contain a <strong>schema</strong> that defines this information. Simply override the <code>getSchema()</code> method and make it return a schema.</p>
@@ -0,0 +1,183 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+ <meta charset="utf-8" />
+ <title>: The Captioned Image Plugin</title>
+
+ <!-- guides styles -->
+ <link rel="stylesheet" type="text/css" href="stylesheets/style.css" />
+ <link rel="stylesheet" type="text/css" href="stylesheets/print.css" media="print" />
+ <link rel="stylesheet" type="text/css" href="stylesheets/strobe.css" />
+ <link rel="stylesheet" type="text/css" href="stylesheets/overrides.style.css" />
+ <link rel="stylesheet" type="text/css" href="stylesheets/overrides.print.css" media="print" />
+ <!--[if lt IE 9]>
+ <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
+ <![endif]-->
+
+ <!-- syntax highlighting styles -->
+ <link rel="stylesheet" type="text/css" href="stylesheets/syntaxhighlighter/shCore.css" />
+ <link rel="stylesheet" type="text/css" href="stylesheets/shThemeStrobeGuides.css" />
+</head>
+<body class="guide">
+
+ <header role="banner">
+ <div class="container">
+ <h1 id="logo">
+ <a href="http://aloha-editor.org"><img src="images/header/logo.png" height="50" alt="Aloha Editor" /></a>
+ </h1>
+ <nav role="navigation">
+ <ul>
+ <li><a href="http://aloha-editor.org/features.php" title="A shortcut for Aloha Editor features" class="new">Features</a></li>
+ <li><a href="http://aloha-editor.org/plugins.php" title="A list of all known Aloha Editor plugins.">Plugins</a></li>
+ <li class="active"><a href="http://aloha-editor.org/guides/" title="The Aloha Editor documentation">Guides</a></li>
+ <li><a href="http://aloha-editor.org/about.php" title="Why Aloha? Why HTML5? Lern more about Aloha Editor">About</a></li>
+ <li><a href="http://getsatisfaction.com/aloha_editor" title="Get help or help others">Forum</a></li>
+ <li><a href="http://aloha-editor.org/demos.php" title="Feel the Aloha">Try it</a></li>
+ </ul>
+ </nav>
+ </div>
+ </header>
+
+ <div id="feature">
+ <div class="wrapper">
+ <div class="feature_header">
+ <a href="/"><img src="images/strobe/guides.png"></a>
+ <h2><a href="/"></a></h2>
+ <p>These guides help you to make your content editable and to develop Aloha Editor.</p>
+ </div>
+ <div class="feature_sidebar">
+ <a href="index.html" id="guidesMenu">
+ Guides Index <span id="guidesArrow">&#9656;</span>
+ </a>
+ <div id="guides" class="clearfix" style="display: none;">
+ <a href="index.html" class="guidesMenu">
+ Guides Index <span class="guidesArrow">&#9662;</span>
+ </a>
+ <hr style="clear:both;">
+ <dl class="L">
+ <dt>Start Here</dt>
+ <dd><a href="using_aloha.html">Using Aloha Editor</a></dd>
+ <dd><a href="functional_description.html">Functional Description</a></dd>
+ <dd><a href="develop_aloha.html">Developing and building Aloha Editor</a></dd>
+ <dd>Configuring Aloha Editor</dd>
+ <dd>Aloha Editor and jQuery</dd>
+ <dd><a href="develop_aloha.html">Developing and building Aloha Editor</a></dd>
+ <dd><a href="require.html">Aloha Editor dependency management</a></dd>
+ <dd><a href="writing_plugins.html">Writing Plugins</a></dd>
+ <dd><a href="repository.html">Working with repositories</a></dd>
+ <dt>The Core</dt>
+ <dd><a href="core.html">The Core</a></dd>
+ <dt>Commands</dt>
+ <dd><a href="using_commands.html">Using commands</a></dd>
+ <dt>UI</dt>
+ <dd><a href="ui.html">Aloha Editor UI</a></dd>
+ <dd>Aloha Editor toolbar</dd>
+ <dd>Aloha Editor sidebar</dd>
+ <dd>Aloha Editor UI API</dd>
+</dl>
+<dl class="R">
+ <dt>Plugins</dt>
+ <dd><a href="plugins.html">Aloha Editor plugins</a></dd>
+ <dd><a href="plugin_block.html">Block</a></dd>
+ <dd><a href="plugin_image.html">Image</a></dd>
+ <dd><a href="plugin_contenthandler.html">Content Handler</a></dd>
+ <dd><a href="plugin_browser.html">Browser</a></dd>
+ <dd>Numerated Headers</dd>
+ <dd><a href="plugin_undo.html">Undo</a></dd>
+ <dd><a href="plugin_table.html">Table</a></dd>
+ <dd><a href="plugin_paste.html">Paste</a></dd>
+ <dd><a href="plugin_formatlesspaste.html">Formatless paste</a></dd>
+ <dd><a href="plugin_dom_to_xhtml.html">DOM to XHTML</a></dd>
+ <dd><a href="plugin_wai-lang.html">WAI Language</a></dd>
+ <dt>Contributing to Aloha Editor</dt>
+ <dd><a href="releasing.html">Releasing</a></dd>
+ <dd>Development Process</dd>
+ <dd><a href="style_guide.html">Javascript Style Guide</a></dd>
+ <dd><a href="documentation_guidelines.html">Documentation Guidelines</a></dd>
+</dl>
+
+
+ </div>
+ </div>
+ </div>
+ </div>
+
+ <div id="container">
+ <div class="wrapper">
+ <div id="mainCol">
+ <div class="headerSection">
+ <h2>The Captioned Image Plugin</h2>
+<p>After reading this guide, you will be able to:</p>
+<ul>
+ <li>Understand what Captioned Image Plugin isand how to use it</li>
+</ul>
+
+ </div>
+
+<div class="warning"><p>This guide is currently work-in-progress.</p></div>
+<h3 id="what-is-a-captioned-image">1 What is a Captioned Image?</h3>
+<p><strong>Captioned Image</strong> is used in Aloha Editor to display an image with a caption (as AE Block).</p>
+<div class="code_container">
+<pre class="brush: xml; gutter: false; toolbar: false">
+
+ &lt;img src=&quot;http://www.aloha-editor.org/logo/Aloha%20Editor%20HTML5%20sticker%20transparent%20256.png&quot;
+ alt=&quot;Sample alt text&quot;
+ data-caption=&quot;Short caption.&quot;
+ class=&quot;aloha-captioned-image&quot;
+ /&gt;
+</pre></div><p>This will create an AE Block containing an image with a caption.</p>
+<h4 id="using-configuration">1.1 Using Configuration</h4>
+<div class="code_container">
+<pre class="brush: javascript; gutter: false; toolbar: false">
+
+ Aloha.settings.plugins.captionedImage: {
+ allowLinebreak: false, // ['br', 'p'], true or false (default)
+ selector: 'img.aloha-captioned-image',
+ render: function (properties, callback, error) {
+ error({message: 'noop'});
+ },
+ defaultCSS: false,
+ captionedImageClass: 'aloha-captioned-image',
+ blockClass: 'mycms-captioned-image-block'
+ }
+</pre></div>
+
+ </div>
+ <div id="subCol">
+ <h3 class="chapter"><img src="images/strobe/chapters.png" alt="" />Chapters</h3>
+ <ol class="chapters">
+ <li><a href="#what-is-a-captioned-image"><p>What is a Captioned Image?</p>
+</a><ul><li><a href="#using-configuration"><p>Using Configuration</p>
+</a></li></ul></li>
+ </ol>
+ </div>
+ </div>
+ </div>
+
+ <hr class="hide" />
+ <footer>
+ <div class="container">
+ <div class="col">
+ <a href="index.html"><img src="images/footer/logo.png" alt="Aloha Editor" /></a>
+ <p>
+ Templates based on <a href="https://github.com/sproutcore/sproutguides">SproutCore guides</a>.
+ </p>
+ </div>
+ <a href="#feature" class="top">Back To Top</a>
+ </div>
+ </footer>
+
+ <script src="http://code.jquery.com/jquery-1.6.min.js" type="text/javascript" charset="utf-8"></script>
+ <script type="text/javascript" src="javascripts/alohaEditorGuides.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shCore.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shBrushRuby.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shBrushJScript.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shBrushCss.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shBrushXml.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shBrushSql.js"></script>
+ <script type="text/javascript" src="javascripts/syntaxhighlighter/shBrushPlain.js"></script>
+ <script type="text/javascript">
+ SyntaxHighlighter.all()
+ </script>
+</body>
+</html>
@@ -166,6 +166,9 @@ <h4 id="using-configuration">2.1 Using Configuration</h4>
handler: {
generic: {
transformFormattings: false // this will disable the transformFormattings method in the generic content handler
+ },
+ sanitize: {
+ '.aloha-captioned-image-caption': { elements: [ 'em', 'strong' ] }
}
}
}
Oops, something went wrong.

0 comments on commit b224cc2

Please sign in to comment.