Browse files

update wymeditor to 0.5rc2, fixes images insertion among other things

  • Loading branch information...
1 parent c62d0ea commit fdaf7e47af2d8780a36c9bf0e15a23ef25e3e179 @sbeam sbeam committed Nov 19, 2010
Showing with 1,450 additions and 164 deletions.
  1. +278 −0 public/javascripts/wymeditor/GPL-license.txt
  2. +20 −0 public/javascripts/wymeditor/MIT-license.txt
  3. +33 −0 public/javascripts/wymeditor/README
  4. +1 −1 public/javascripts/wymeditor/iframe/default/wymiframe.css
  5. +2 −1 public/javascripts/wymeditor/iframe/default/wymiframe.html
  6. +136 −124 public/javascripts/wymeditor/jquery.wymeditor.js
  7. +1 −0 public/javascripts/wymeditor/jquery.wymeditor.min.js
  8. +1 −1 public/javascripts/wymeditor/jquery.wymeditor.pack.js
  9. +278 −0 public/javascripts/wymeditor/jquery/GPL-LICENSE.txt
  10. +20 −0 public/javascripts/wymeditor/jquery/MIT-LICENSE.txt
  11. +67 −0 public/javascripts/wymeditor/jquery/README
  12. +11 −0 public/javascripts/wymeditor/jquery/jquery.js
  13. +1 −0 public/javascripts/wymeditor/jquery/jquery.ui.draggable.js
  14. +1 −0 public/javascripts/wymeditor/jquery/jquery.ui.js
  15. +1 −0 public/javascripts/wymeditor/jquery/jquery.ui.resizable.js
  16. +1 −0 public/javascripts/wymeditor/jquery/jquery.ui.sortable.js
  17. +45 −0 public/javascripts/wymeditor/lang/bg.js
  18. +45 −0 public/javascripts/wymeditor/lang/cy.js
  19. +44 −0 public/javascripts/wymeditor/lang/fi.js
  20. +45 −0 public/javascripts/wymeditor/lang/gl.js
  21. +45 −0 public/javascripts/wymeditor/lang/hr.js
  22. +52 −0 public/javascripts/wymeditor/plugins/embed/jquery.wymeditor.embed.js
  23. BIN public/javascripts/wymeditor/plugins/fullscreen/icon_fullscreen.gif
  24. +127 −0 public/javascripts/wymeditor/plugins/fullscreen/jquery.wymeditor.fullscreen.js
  25. +1 −1 public/javascripts/wymeditor/plugins/hovertools/jquery.wymeditor.hovertools.js
  26. +10 −21 public/javascripts/wymeditor/plugins/resizable/jquery.wymeditor.resizable.js
  27. +1 −1 public/javascripts/wymeditor/plugins/tidy/README
  28. +8 −8 public/javascripts/wymeditor/plugins/tidy/jquery.wymeditor.tidy.js
  29. BIN public/javascripts/wymeditor/skins/compact/icons.png
  30. +134 −0 public/javascripts/wymeditor/skins/compact/skin.css
  31. +35 −0 public/javascripts/wymeditor/skins/compact/skin.js
  32. +2 −2 public/javascripts/wymeditor/skins/default/skin.css
  33. +1 −1 public/javascripts/wymeditor/skins/default/skin.js
  34. +1 −1 public/javascripts/wymeditor/skins/minimal/skin.css
  35. +1 −1 public/javascripts/wymeditor/skins/silver/skin.css
  36. +1 −1 public/javascripts/wymeditor/skins/twopanels/skin.css
View
278 public/javascripts/wymeditor/GPL-license.txt
@@ -0,0 +1,278 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
View
20 public/javascripts/wymeditor/MIT-license.txt
@@ -0,0 +1,20 @@
+Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
View
33 public/javascripts/wymeditor/README
@@ -0,0 +1,33 @@
+WYMeditor : what you see is What You Mean web-based editor
+Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
+Dual licensed under the MIT (MIT-license.txt)
+and GPL (GPL-license.txt) licenses.
+
+For further information visit:
+ http://www.wymeditor.org/
+
+File Name:
+ README
+ Readme file.
+
+File Authors:
+ Jean-François Hovinne - http://www.hovinne.com/
+
+
+README
+======
+
+For WYMeditor to work, you'll need at least jQuery 1.1.3.x
+jQuery is available at http://jquery.com/
+
+WYMeditor is compatible with MSIE 6.0+,
+Gecko-based browsers (e.g. Firefox 1.5+),
+Opera 9.5+, Safari 3.0+, Google Chrome.
+
+WYMeditor integration examples are available in the 'examples' directory.
+
+For more information, please read the documentation, available at:
+http://trac.wymeditor.org/trac/wiki
+
+If you need help, feel free to create an account on the forum and ask your question.
+http://forum.wymeditor.org/
View
2 public/javascripts/wymeditor/iframe/default/wymiframe.css
@@ -1,6 +1,6 @@
/*
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
View
3 public/javascripts/wymeditor/iframe/default/wymiframe.html
@@ -1,7 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!--
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
@@ -19,6 +19,7 @@
<html>
<head>
<title>WYMeditor iframe</title>
+<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<link rel="stylesheet" type="text/css" media="screen" href="wymiframe.css" />
</head>
<body class="wym_iframe"></body>
View
260 public/javascripts/wymeditor/jquery.wymeditor.js
@@ -1,6 +1,8 @@
-/*
+/**
+ * @version 0.5-rc1
+ *
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
@@ -19,7 +21,7 @@
* Scott Lewis (lewiscot a-t gmail dotcom)
* Bermi Ferrer (wymeditor a-t bermi dotorg)
* Daniel Reszka (d.reszka a-t wymeditor dotorg)
- * Jonatan Lundin (jonatan.lundin _at_ gmail.com)
+ * Jonatan Lundin (jonatan.lundin a-t gmail dotcom)
*/
/*
@@ -118,7 +120,7 @@ jQuery.extend(WYMeditor, {
*/
- VERSION : "0.5-b2",
+ VERSION : "0.5-rc1",
INSTANCES : [],
STRINGS : [],
SKINS : [],
@@ -131,7 +133,7 @@ jQuery.extend(WYMeditor, {
SKINS_DEFAULT_PATH : "skins/",
SKINS_DEFAULT_CSS : "skin.css",
SKINS_DEFAULT_JS : "skin.js",
- LANG_DEFAULT_PATH : "lang/",
+ LANG_DEFAULT_PATH : "lang/",
IFRAME_BASE_PATH : "{Wym_Iframe_Base_Path}",
IFRAME_DEFAULT : "iframe/default/",
JQUERY_PATH : "{Wym_Jquery_Path}",
@@ -198,10 +200,9 @@ jQuery.extend(WYMeditor, {
TOGGLE_HTML : "ToggleHtml",
FORMAT_BLOCK : "FormatBlock",
PREVIEW : "Preview",
-
- UNLINK : "Unlink",
- INSERT_UNORDEREDLIST : "InsertUnorderedList",
- INSERT_ORDEREDLIST : "InsertOrderedList",
+ UNLINK : "Unlink",
+ INSERT_UNORDEREDLIST: "InsertUnorderedList",
+ INSERT_ORDEREDLIST : "InsertOrderedList",
MAIN_CONTAINERS : new Array("p","h1","h2","h3","h4","h5","h6","pre","blockquote"),
@@ -456,7 +457,9 @@ jQuery.fn.wymeditor = function(options) {
+ WYMeditor.CLASSES_ITEMS
+ "</ul></div>",
- classesItemHtml: "<li><a href='#' name='"
+ classesItemHtml: "<li class='wym_classes_"
+ + WYMeditor.CLASS_NAME
+ + "'><a href='#' name='"
+ WYMeditor.CLASS_NAME
+ "'>"
+ WYMeditor.CLASS_TITLE
@@ -514,6 +517,8 @@ jQuery.fn.wymeditor = function(options) {
dialogFeatures: "menubar=no,titlebar=no,toolbar=no,resizable=no"
+ ",width=560,height=300,top=0,left=0",
+ dialogFeaturesPreview: "menubar=no,titlebar=no,toolbar=no,resizable=no"
+ + ",scrollbars=yes,width=560,height=300,top=0,left=0",
dialogHtml: "<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN'"
+ " 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'>"
@@ -734,12 +739,14 @@ WYMeditor.editor.prototype.init = function() {
for (var prop in WymClass) { this[prop] = WymClass[prop]; }
//load wymbox
- this._box = jQuery(this._element).hide().after(this._options.boxHtml).next();
+ this._box = jQuery(this._element).hide().after(this._options.boxHtml).next().addClass('wym_box_' + this._index);
- //store the instance index in the wymbox element
+ //store the instance index in wymbox and element replaced by editor instance
//but keep it compatible with jQuery < 1.2.3, see #122
- if( jQuery.isFunction( jQuery.fn.data ) )
+ if( jQuery.isFunction( jQuery.fn.data ) ) {
jQuery.data(this._box.get(0), WYMeditor.WYM_INDEX, this._index);
+ jQuery.data(this._element.get(0), WYMeditor.WYM_INDEX, this._index);
+ }
var h = WYMeditor.Helper;
@@ -833,7 +840,8 @@ WYMeditor.editor.prototype.bindEvents = function() {
//handle click event on tools buttons
jQuery(this._box).find(this._options.toolSelector).click(function() {
- wym.exec(jQuery(this).attr(WYMeditor.NAME));
+ wym._iframe.contentWindow.focus(); //See #154
+ wym.exec(jQuery(this).attr(WYMeditor.NAME));
return(false);
});
@@ -844,10 +852,12 @@ WYMeditor.editor.prototype.bindEvents = function() {
});
//handle keyup event on html value: set the editor value
- jQuery(this._box).find(this._options.htmlValSelector).keyup(function() {
- jQuery(wym._doc.body).html(jQuery(this).val());
- });
-
+ //handle focus/blur events to check if the element has focus, see #147
+ jQuery(this._box).find(this._options.htmlValSelector)
+ .keyup(function() { jQuery(wym._doc.body).html(jQuery(this).val());})
+ .focus(function() { jQuery(this).toggleClass('hasfocus'); })
+ .blur(function() { jQuery(this).toggleClass('hasfocus'); });
+
//handle click event on classes buttons
jQuery(this._box).find(this._options.classSelector).click(function() {
@@ -860,6 +870,7 @@ WYMeditor.editor.prototype.bindEvents = function() {
var jqexpr = oClass.expr;
wym.toggleClass(sName, jqexpr);
}
+ wym._iframe.contentWindow.focus(); //See #154
return(false);
});
@@ -928,14 +939,10 @@ WYMeditor.editor.prototype.exec = function(cmd) {
case WYMeditor.TOGGLE_HTML:
this.update();
this.toggleHtml();
-
- //partially fixes #121 when the user manually inserts an image
- if(!jQuery(this._box).find(this._options.htmlSelector).is(':visible'))
- this.listen();
break;
case WYMeditor.PREVIEW:
- this.dialog(WYMeditor.PREVIEW);
+ this.dialog(WYMeditor.PREVIEW, this._options.dialogFeaturesPreview);
break;
default:
@@ -1137,18 +1144,16 @@ WYMeditor.editor.prototype.update = function() {
var html = this.xhtml();
jQuery(this._element).val(html);
- jQuery(this._box).find(this._options.htmlValSelector).val(html);
+ jQuery(this._box).find(this._options.htmlValSelector).not('.hasfocus').val(html); //#147
};
/* @name dialog
* @description Opens a dialog box
*/
-WYMeditor.editor.prototype.dialog = function( dialogType, bodyHtml ) {
+WYMeditor.editor.prototype.dialog = function( dialogType, dialogFeatures, bodyHtml ) {
- var wDialog = window.open(
- '',
- 'dialog',
- this._wym._options.dialogFeatures);
+ var features = dialogFeatures || this._wym._options.dialogFeatures;
+ var wDialog = window.open('', 'dialog', features);
if(wDialog) {
@@ -1264,6 +1269,17 @@ WYMeditor.editor.prototype.unwrap = function() {
}
};
+WYMeditor.editor.prototype.setFocusToNode = function(node, toStart) {
+ var range = this._doc.createRange(),
+ selection = this._iframe.contentWindow.getSelection();
+ toStart = toStart ? 0 : 1;
+
+ range.selectNodeContents(node);
+ selection.addRange(range);
+ selection.collapse(node, toStart);
+ this._iframe.contentWindow.focus();
+};
+
WYMeditor.editor.prototype.addCssRules = function(doc, aCss) {
var styles = doc.styleSheets[0];
if(styles) {
@@ -1278,19 +1294,19 @@ WYMeditor.editor.prototype.addCssRules = function(doc, aCss) {
WYMeditor.editor.prototype.computeBasePath = function() {
return jQuery(jQuery.grep(jQuery('script'), function(s){
- return (s.src && s.src.match(/jquery\.wymeditor(\.pack){0,1}\.js(\?.*)?$/ ))
- })).attr('src').replace(/jquery\.wymeditor(\.pack){0,1}\.js(\?.*)?$/, '');
+ return (s.src && s.src.match(/jquery\.wymeditor(\.pack|\.min|\.packed)?\.js(\?.*)?$/ ))
+ })).attr('src').replace(/jquery\.wymeditor(\.pack|\.min|\.packed)?\.js(\?.*)?$/, '');
};
WYMeditor.editor.prototype.computeWymPath = function() {
return jQuery(jQuery.grep(jQuery('script'), function(s){
- return (s.src && s.src.match(/jquery\.wymeditor(\.pack){0,1}\.js(\?.*)?$/ ))
+ return (s.src && s.src.match(/jquery\.wymeditor(\.pack|\.min|\.packed)?\.js(\?.*)?$/ ))
})).attr('src');
};
WYMeditor.editor.prototype.computeJqueryPath = function() {
return jQuery(jQuery.grep(jQuery('script'), function(s){
- return (s.src && s.src.match(/jquery(-(.*)){0,1}(\.pack){0,1}\.js(\?.*)?$/ ))
+ return (s.src && s.src.match(/jquery(-(.*)){0,1}(\.pack|\.min|\.packed)?\.js(\?.*)?$/ ))
})).attr('src');
};
@@ -1323,23 +1339,16 @@ WYMeditor.editor.prototype.configureEditorUsingRawCss = function() {
/********** EVENTS **********/
WYMeditor.editor.prototype.listen = function() {
+ //don't use jQuery.find() on the iframe body
+ //because of MSIE + jQuery + expando issue (#JQ1143)
+ //jQuery(this._doc.body).find("*").bind("mouseup", this.mouseup);
- //don't use jQuery.find() on the iframe body
- //because of MSIE + jQuery + expando issue (#JQ1143)
- //jQuery(this._doc.body).find("*").bind("mouseup", this.mouseup);
-
- jQuery(this._doc.body).bind("mousedown", this.mousedown);
- var images = this._doc.body.getElementsByTagName("img");
- for(var i=0; i < images.length; i++) {
- jQuery(images[i]).bind("mousedown", this.mousedown);
- }
+ jQuery(this._doc.body).bind("mousedown", this.mousedown);
};
WYMeditor.editor.prototype.mousedown = function(evt) {
-
- var wym = WYMeditor.INSTANCES[this.ownerDocument.title];
- wym._selected_image = (this.tagName.toLowerCase() == WYMeditor.IMG) ? this : null;
- evt.stopPropagation();
+ var wym = WYMeditor.INSTANCES[this.ownerDocument.title];
+ wym._selected_image = (evt.target.tagName.toLowerCase() == WYMeditor.IMG) ? evt.target : null;
};
/********** SKINS **********/
@@ -1465,11 +1474,16 @@ WYMeditor.INIT_DIALOG = function(index) {
var sUrl = jQuery(wym._options.hrefSelector).val();
if(sUrl.length > 0) {
+ var link;
+
+ if (selected[0] && selected[0].tagName.toLowerCase() == WYMeditor.A) {
+ link = selected;
+ } else {
+ wym._exec(WYMeditor.CREATE_LINK, sStamp);
+ link = jQuery("a[href=" + sStamp + "]", wym._doc.body);
+ }
- wym._exec(WYMeditor.CREATE_LINK, sStamp);
-
- jQuery("a[@href=" + sStamp + "]", wym._doc.body)
- .attr(WYMeditor.HREF, sUrl)
+ link.attr(WYMeditor.HREF, sUrl)
.attr(WYMeditor.TITLE, jQuery(wym._options.titleSelector).val());
}
@@ -1484,7 +1498,7 @@ WYMeditor.INIT_DIALOG = function(index) {
wym._exec(WYMeditor.INSERT_IMAGE, sStamp);
- jQuery("img[@src=" + sStamp + "]", wym._doc.body)
+ jQuery("img[src$=" + sStamp + "]", wym._doc.body)
.attr(WYMeditor.SRC, sUrl)
.attr(WYMeditor.TITLE, jQuery(wym._options.titleSelector).val())
.attr(WYMeditor.ALT, jQuery(wym._options.altSelector).val());
@@ -2887,7 +2901,7 @@ WYMeditor.Lexer.prototype._decodeSpecial = function(mode)
WYMeditor.Lexer.prototype._invokeParser = function(content, is_match)
{
- if (!/ +/.test(content) && ((content === '') || (content == false))) {
+ if (content === '') {
return true;
}
var current = this._mode.getCurrent();
@@ -3409,13 +3423,14 @@ WYMeditor.XhtmlSaxListener.prototype.afterParsing = function(xhtml)
xhtml = this.replaceNamedEntities(xhtml);
xhtml = this.joinRepeatedEntities(xhtml);
xhtml = this.removeEmptyTags(xhtml);
+ xhtml = this.removeBrInPre(xhtml);
return xhtml;
};
WYMeditor.XhtmlSaxListener.prototype.replaceNamedEntities = function(xhtml)
{
for (var entity in this.entities) {
- xhtml = xhtml.replace(entity, this.entities[entity]);
+ xhtml = xhtml.replace(new RegExp(entity, 'g'), this.entities[entity]);
}
return xhtml;
};
@@ -3429,7 +3444,18 @@ WYMeditor.XhtmlSaxListener.prototype.joinRepeatedEntities = function(xhtml)
WYMeditor.XhtmlSaxListener.prototype.removeEmptyTags = function(xhtml)
{
- return xhtml.replace(new RegExp('<('+this.block_tags.join("|").replace(/\|td/,'')+')>(<br \/>|&#160;|&nbsp;|\\s)*<\/\\1>' ,'g'),'');
+ return xhtml.replace(new RegExp('<('+this.block_tags.join("|").replace(/\|td/,'').replace(/\|th/, '')+')>(<br \/>|&#160;|&nbsp;|\\s)*<\/\\1>' ,'g'),'');
+};
+
+WYMeditor.XhtmlSaxListener.prototype.removeBrInPre = function(xhtml)
+{
+ var matches = xhtml.match(new RegExp('<pre[^>]*>(.*?)<\/pre>','gmi'));
+ if(matches) {
+ for(var i=0; i<matches.length; i++) {
+ xhtml = xhtml.replace(matches[i], matches[i].replace(new RegExp('<br \/>', 'g'), String.fromCharCode(13,10)));
+ }
+ }
+ return xhtml;
};
WYMeditor.XhtmlSaxListener.prototype.getResult = function()
@@ -3580,16 +3606,16 @@ WYMeditor.WymCssLexer = function(parser, only_wym_blocks)
this.addExitPattern("/\\\x2a[<\/\\s]*WYMeditor[>\\s]*\\\x2a/", 'WymCss');
}
- this.addSpecialPattern("\\\x2e[a-z-_0-9]+[\\sa-z1-6]*", 'WymCss', 'WymCssStyleDeclaration');
+ this.addSpecialPattern("[\\sa-z1-6]*\\\x2e[a-z-_0-9]+", 'WymCss', 'WymCssStyleDeclaration');
this.addEntryPattern("/\\\x2a", 'WymCss', 'WymCssComment');
this.addExitPattern("\\\x2a/", 'WymCssComment');
this.addEntryPattern("\x7b", 'WymCss', 'WymCssStyle');
this.addExitPattern("\x7d", 'WymCssStyle');
- this.addEntryPattern("/\\\x2a", 'WymCssStyle', 'WymCssFeddbackStyle');
- this.addExitPattern("\\\x2a/", 'WymCssFeddbackStyle');
+ this.addEntryPattern("/\\\x2a", 'WymCssStyle', 'WymCssFeedbackStyle');
+ this.addExitPattern("\\\x2a/", 'WymCssFeedbackStyle');
return this;
};
@@ -3653,7 +3679,7 @@ WYMeditor.WymCssParser.prototype.WymCssStyle = function(match, status)
return true;
};
-WYMeditor.WymCssParser.prototype.WymCssFeddbackStyle = function(match, status)
+WYMeditor.WymCssParser.prototype.WymCssFeedbackStyle = function(match, status)
{
if(status == WYMeditor.LEXER_UNMATCHED){
this._current_item[this._current_element].feedback_style = match.replace(/^([\s\/\*]*)|([\s\/\*]*)$/gm,'');
@@ -3666,10 +3692,10 @@ WYMeditor.WymCssParser.prototype.WymCssStyleDeclaration = function(match)
match = match.replace(/^([\s\.]*)|([\s\.*]*)$/gm, '');
var tag = '';
- if(match.indexOf(' ') > 0){
- var parts = match.split(' ');
- this._current_element = parts[0];
- var tag = parts[1];
+ if(match.indexOf('.') > 0){
+ var parts = match.split('.');
+ this._current_element = parts[1];
+ var tag = parts[0];
}else{
this._current_element = match;
}
@@ -3701,7 +3727,7 @@ WYMeditor.WymCssParser.prototype.addStyleSetting = function(style_details)
this.css_settings.classesItems.push({
'name': WYMeditor.Helper.trim(details.name),
'title': style_details.title,
- 'expr' : WYMeditor.Helper.trim((details.expressions||details.tags||[]).join(', '))
+ 'expr' : WYMeditor.Helper.trim((details.expressions||details.tags).join(', '))
});
if(details.feedback_style){
this.css_settings.editorStyles.push({
@@ -3808,7 +3834,7 @@ WYMeditor.Helper = {
/*
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
@@ -3824,14 +3850,15 @@ WYMeditor.Helper = {
* Jean-Francois Hovinne (jf.hovinne a-t wymeditor dotorg)
* Bermi Ferrer (wymeditor a-t bermi dotorg)
* Frédéric Palluel-Lafleur (fpalluel a-t gmail dotcom)
- * Jonatan Lundin (jonatan.lundin _at_ gmail.com)
+ * Jonatan Lundin (jonatan.lundin a-t gmail dotcom)
*/
WYMeditor.WymClassExplorer = function(wym) {
this._wym = wym;
this._class = "className";
this._newLine = "\r\n";
+
};
WYMeditor.WymClassExplorer.prototype.initIframe = function(iframe) {
@@ -3912,16 +3939,20 @@ WYMeditor.WymClassExplorer.prototype._exec = function(cmd,param) {
case WYMeditor.INDENT: case WYMeditor.OUTDENT:
var container = this.findUp(this.container(), WYMeditor.LI);
- if(container)
- this._doc.execCommand(cmd);
+ if(container) {
+ var ancestor = container.parentNode.parentNode;
+ if(container.parentNode.childNodes.length>1
+ || ancestor.tagName.toLowerCase() == WYMeditor.OL
+ || ancestor.tagName.toLowerCase() == WYMeditor.UL)
+ this._doc.execCommand(cmd);
+ }
break;
default:
if(param) this._doc.execCommand(cmd,false,param);
else this._doc.execCommand(cmd);
break;
}
-
- this.listen();
+
};
WYMeditor.WymClassExplorer.prototype.selected = function() {
@@ -3995,18 +4026,19 @@ WYMeditor.WymClassExplorer.prototype.keyup = function() {
this._selected_image = null;
};
-WYMeditor.WymClassExplorer.prototype.setFocusToNode = function(node) {
+WYMeditor.WymClassExplorer.prototype.setFocusToNode = function(node, toStart) {
var range = this._doc.selection.createRange();
+ toStart = toStart ? true : false;
+
range.moveToElementText(node);
- range.collapse(false);
- range.move('character',-1);
+ range.collapse(toStart);
range.select();
node.focus();
};
/*
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
@@ -4023,6 +4055,7 @@ WYMeditor.WymClassExplorer.prototype.setFocusToNode = function(node) {
* Volker Mische (vmx a-t gmx dotde)
* Bermi Ferrer (wymeditor a-t bermi dotorg)
* Frédéric Palluel-Lafleur (fpalluel a-t gmail dotcom)
+ * Jonatan Lundin (jonatan.lundin a-t gmail dotcom)
*/
WYMeditor.WymClassMozilla = function(wym) {
@@ -4033,7 +4066,8 @@ WYMeditor.WymClassMozilla = function(wym) {
};
WYMeditor.WymClassMozilla.prototype.initIframe = function(iframe) {
-
+ var wym = this;
+
this._iframe = iframe;
this._doc = iframe.contentDocument;
@@ -4068,7 +4102,10 @@ WYMeditor.WymClassMozilla.prototype.initIframe = function(iframe) {
jQuery(this._doc).bind("keyup", this.keyup);
//bind editor focus events (used to reset designmode - Gecko bug)
- jQuery(this._doc).bind("focus", this.enableDesignMode);
+ jQuery(this._doc).bind("focus", function () {
+ // Fix scope
+ wym.enableDesignMode.call(wym);
+ });
//post-init functions
if(jQuery.isFunction(this._options.postInit)) this._options.postInit(this);
@@ -4089,11 +4126,11 @@ WYMeditor.WymClassMozilla.prototype.html = function(html) {
//replace em by i and strong by bold
//(designMode issue)
- html = html.replace(/<em([^>]*)>/gi, "<i$1>")
+ html = html.replace(/<em(\b[^>]*)>/gi, "<i$1>")
.replace(/<\/em>/gi, "</i>")
- .replace(/<strong([^>]*)>/gi, "<b$1>")
+ .replace(/<strong(\b[^>]*)>/gi, "<b$1>")
.replace(/<\/strong>/gi, "</b>");
-
+
//update the html body
jQuery(this._doc.body).html(html);
@@ -4142,10 +4179,6 @@ WYMeditor.WymClassMozilla.prototype._exec = function(cmd,param) {
var container = this.selected();
if(container.tagName.toLowerCase() == WYMeditor.BODY)
this._exec(WYMeditor.FORMAT_BLOCK, WYMeditor.P);
-
- //add event handlers on doc elements
-
- this.listen();
};
/* @name selected
@@ -4173,7 +4206,8 @@ WYMeditor.WymClassMozilla.prototype.keydown = function(evt) {
//'this' is the doc
var wym = WYMeditor.INSTANCES[this.title];
-
+ var container = null;
+
if(evt.ctrlKey){
if(evt.keyCode == 66){
//CTRL+b => STRONG
@@ -4186,6 +4220,17 @@ WYMeditor.WymClassMozilla.prototype.keydown = function(evt) {
return false;
}
}
+
+ else if(evt.keyCode == 13) {
+ if(!evt.shiftKey){
+ //fix PRE bug #73
+ container = wym.selected();
+ if(container && container.tagName.toLowerCase() == WYMeditor.PRE) {
+ evt.preventDefault();
+ wym.insert('<p></p>');
+ }
+ }
+ }
};
//keyup handler, mainly used for cleanups
@@ -4202,14 +4247,9 @@ WYMeditor.WymClassMozilla.prototype.keyup = function(evt) {
//RETURN key
//cleanup <br><br> between paragraphs
jQuery(wym._doc.body).children(WYMeditor.BR).remove();
-
- //fix PRE bug #73
- container = wym.selected();
- if(container && container.tagName.toLowerCase() == WYMeditor.PRE)
- wym._exec(WYMeditor.FORMAT_BLOCK, WYMeditor.P); //create P after PRE
}
- else if(evt.keyCode != 8
+ if(evt.keyCode != 8
&& evt.keyCode != 17
&& evt.keyCode != 46
&& evt.keyCode != 224
@@ -4239,23 +4279,14 @@ WYMeditor.WymClassMozilla.prototype.keyup = function(evt) {
};
WYMeditor.WymClassMozilla.prototype.enableDesignMode = function() {
- if(this.designMode == "off") {
+ if(this._doc.designMode == "off") {
try {
- this.designMode = "on";
- this.execCommand("styleWithCSS", '', false);
+ this._doc.designMode = "on";
+ this._doc.execCommand("styleWithCSS", '', false);
} catch(e) { }
}
};
-WYMeditor.WymClassMozilla.prototype.setFocusToNode = function(node) {
- var range = document.createRange();
- range.selectNode(node);
- var selected = this._iframe.contentWindow.getSelection();
- selected.addRange(range);
- selected.collapse(node, node.childNodes.length);
- this._iframe.contentWindow.focus();
-};
-
WYMeditor.WymClassMozilla.prototype.openBlockTag = function(tag, attributes)
{
var attributes = this.validator.getValidTagAttributes(tag, attributes);
@@ -4281,13 +4312,13 @@ WYMeditor.WymClassMozilla.prototype.getTagForStyle = function(style) {
if(/bold/.test(style)) return 'strong';
if(/italic/.test(style)) return 'em';
if(/sub/.test(style)) return 'sub';
- if(/sub/.test(style)) return 'super';
+ if(/super/.test(style)) return 'sup';
return false;
};
/*
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
@@ -4355,8 +4386,7 @@ WYMeditor.WymClassOpera.prototype._exec = function(cmd,param) {
if(param) this._doc.execCommand(cmd,false,param);
else this._doc.execCommand(cmd);
-
- this.listen();
+
};
WYMeditor.WymClassOpera.prototype.selected = function() {
@@ -4405,15 +4435,9 @@ WYMeditor.WymClassOpera.prototype.keyup = function(evt) {
var wym = WYMeditor.INSTANCES[this.title];
wym._selected_image = null;
};
-
-// TODO: implement me
-WYMeditor.WymClassOpera.prototype.setFocusToNode = function(node) {
-
-};
-
/*
* WYMeditor : what you see is What You Mean web-based editor
- * Copyright (c) 2008 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
* Dual licensed under the MIT (MIT-license.txt)
* and GPL (GPL-license.txt) licenses.
*
@@ -4531,8 +4555,6 @@ WYMeditor.WymClassSafari.prototype._exec = function(cmd,param) {
if(container && container.tagName.toLowerCase() == WYMeditor.BODY)
this._exec(WYMeditor.FORMAT_BLOCK, WYMeditor.P);
- //add event handlers on doc elements
- this.listen();
};
/* @name selected
@@ -4631,16 +4653,6 @@ WYMeditor.WymClassSafari.prototype.keyup = function(evt) {
}
};
-//TODO
-WYMeditor.WymClassSafari.prototype.setFocusToNode = function(node) {
- /*var range = document.createRange();
- range.selectNode(node);
- var selected = this._iframe.contentWindow.getSelection();
- selected.addRange(range);
- selected.collapse(node, node.childNodes.length);
- this._iframe.contentWindow.focus();*/
-};
-
WYMeditor.WymClassSafari.prototype.openBlockTag = function(tag, attributes)
{
var attributes = this.validator.getValidTagAttributes(tag, attributes);
View
1 public/javascripts/wymeditor/jquery.wymeditor.min.js
@@ -0,0 +1 @@
+if(!WYMeditor){var WYMeditor={}}(function(){if(!window.console||!console.firebug){var b=["log","debug","info","warn","error","assert","dir","dirxml","group","groupEnd","time","timeEnd","count","trace","profile","profileEnd"];WYMeditor.console={};for(var a=0;a<b.length;++a){WYMeditor.console[b[a]]=function(){}}}else{WYMeditor.console=window.console}})();jQuery.extend(WYMeditor,{VERSION:"0.5-rc1",INSTANCES:[],STRINGS:[],SKINS:[],NAME:"name",INDEX:"{Wym_Index}",WYM_INDEX:"wym_index",BASE_PATH:"{Wym_Base_Path}",CSS_PATH:"{Wym_Css_Path}",WYM_PATH:"{Wym_Wym_Path}",SKINS_DEFAULT_PATH:"skins/",SKINS_DEFAULT_CSS:"skin.css",SKINS_DEFAULT_JS:"skin.js",LANG_DEFAULT_PATH:"lang/",IFRAME_BASE_PATH:"{Wym_Iframe_Base_Path}",IFRAME_DEFAULT:"iframe/default/",JQUERY_PATH:"{Wym_Jquery_Path}",DIRECTION:"{Wym_Direction}",LOGO:"{Wym_Logo}",TOOLS:"{Wym_Tools}",TOOLS_ITEMS:"{Wym_Tools_Items}",TOOL_NAME:"{Wym_Tool_Name}",TOOL_TITLE:"{Wym_Tool_Title}",TOOL_CLASS:"{Wym_Tool_Class}",CLASSES:"{Wym_Classes}",CLASSES_ITEMS:"{Wym_Classes_Items}",CLASS_NAME:"{Wym_Class_Name}",CLASS_TITLE:"{Wym_Class_Title}",CONTAINERS:"{Wym_Containers}",CONTAINERS_ITEMS:"{Wym_Containers_Items}",CONTAINER_NAME:"{Wym_Container_Name}",CONTAINER_TITLE:"{Wym_Containers_Title}",CONTAINER_CLASS:"{Wym_Container_Class}",HTML:"{Wym_Html}",IFRAME:"{Wym_Iframe}",STATUS:"{Wym_Status}",DIALOG_TITLE:"{Wym_Dialog_Title}",DIALOG_BODY:"{Wym_Dialog_Body}",STRING:"string",BODY:"body",DIV:"div",P:"p",H1:"h1",H2:"h2",H3:"h3",H4:"h4",H5:"h5",H6:"h6",PRE:"pre",BLOCKQUOTE:"blockquote",A:"a",BR:"br",IMG:"img",TABLE:"table",TD:"td",TH:"th",UL:"ul",OL:"ol",LI:"li",CLASS:"class",HREF:"href",SRC:"src",TITLE:"title",ALT:"alt",DIALOG_LINK:"Link",DIALOG_IMAGE:"Image",DIALOG_TABLE:"Table",DIALOG_PASTE:"Paste_From_Word",BOLD:"Bold",ITALIC:"Italic",CREATE_LINK:"CreateLink",INSERT_IMAGE:"InsertImage",INSERT_TABLE:"InsertTable",INSERT_HTML:"InsertHTML",PASTE:"Paste",INDENT:"Indent",OUTDENT:"Outdent",TOGGLE_HTML:"ToggleHtml",FORMAT_BLOCK:"FormatBlock",PREVIEW:"Preview",UNLINK:"Unlink",INSERT_UNORDEREDLIST:"InsertUnorderedList",INSERT_ORDEREDLIST:"InsertOrderedList",MAIN_CONTAINERS:new Array("p","h1","h2","h3","h4","h5","h6","pre","blockquote"),BLOCKS:new Array("address","blockquote","div","dl","fieldset","form","h1","h2","h3","h4","h5","h6","hr","noscript","ol","p","pre","table","ul","dd","dt","li","tbody","td","tfoot","th","thead","tr"),KEY:{BACKSPACE:8,ENTER:13,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,CURSOR:new Array(37,38,39,40),DELETE:46},NODE:{ELEMENT:1,ATTRIBUTE:2,TEXT:3},editor:function(b,a){this._index=WYMeditor.INSTANCES.push(this)-1;this._element=b;this._options=a;this._html=jQuery(b).val();if(this._options.html){this._html=this._options.html}this._options.basePath=this._options.basePath||this.computeBasePath();this._options.skinPath=this._options.skinPath||this._options.basePath+WYMeditor.SKINS_DEFAULT_PATH+this._options.skin+"/";this._options.wymPath=this._options.wymPath||this.computeWymPath();this._options.langPath=this._options.langPath||this._options.basePath+WYMeditor.LANG_DEFAULT_PATH;this._options.iframeBasePath=this._options.iframeBasePath||this._options.basePath+WYMeditor.IFRAME_DEFAULT;this._options.jQueryPath=this._options.jQueryPath||this.computeJqueryPath();this.init()}});jQuery.fn.wymeditor=function(a){a=jQuery.extend({html:"",basePath:false,skinPath:false,wymPath:false,iframeBasePath:false,jQueryPath:false,styles:false,stylesheet:false,skin:"default",initSkin:true,loadSkin:true,lang:"en",direction:"ltr",boxHtml:"<div class='wym_box'><div class='wym_area_top'>"+WYMeditor.TOOLS+"</div><div class='wym_area_left'></div><div class='wym_area_right'>"+WYMeditor.CONTAINERS+WYMeditor.CLASSES+"</div><div class='wym_area_main'>"+WYMeditor.HTML+WYMeditor.IFRAME+WYMeditor.STATUS+"</div><div class='wym_area_bottom'>"+WYMeditor.LOGO+"</div></div>",logoHtml:"<a class='wym_wymeditor_link' href='http://www.wymeditor.org/'>WYMeditor</a>",iframeHtml:"<div class='wym_iframe wym_section'><iframe src='"+WYMeditor.IFRAME_BASE_PATH+"wymiframe.html' onload='this.contentWindow.parent.WYMeditor.INSTANCES["+WYMeditor.INDEX+"].initIframe(this)'></iframe></div>",editorStyles:[],toolsHtml:"<div class='wym_tools wym_section'><h2>{Tools}</h2><ul>"+WYMeditor.TOOLS_ITEMS+"</ul></div>",toolsItemHtml:"<li class='"+WYMeditor.TOOL_CLASS+"'><a href='#' name='"+WYMeditor.TOOL_NAME+"' title='"+WYMeditor.TOOL_TITLE+"'>"+WYMeditor.TOOL_TITLE+"</a></li>",toolsItems:[{name:"Bold",title:"Strong",css:"wym_tools_strong"},{name:"Italic",title:"Emphasis",css:"wym_tools_emphasis"},{name:"Superscript",title:"Superscript",css:"wym_tools_superscript"},{name:"Subscript",title:"Subscript",css:"wym_tools_subscript"},{name:"InsertOrderedList",title:"Ordered_List",css:"wym_tools_ordered_list"},{name:"InsertUnorderedList",title:"Unordered_List",css:"wym_tools_unordered_list"},{name:"Indent",title:"Indent",css:"wym_tools_indent"},{name:"Outdent",title:"Outdent",css:"wym_tools_outdent"},{name:"Undo",title:"Undo",css:"wym_tools_undo"},{name:"Redo",title:"Redo",css:"wym_tools_redo"},{name:"CreateLink",title:"Link",css:"wym_tools_link"},{name:"Unlink",title:"Unlink",css:"wym_tools_unlink"},{name:"InsertImage",title:"Image",css:"wym_tools_image"},{name:"InsertTable",title:"Table",css:"wym_tools_table"},{name:"Paste",title:"Paste_From_Word",css:"wym_tools_paste"},{name:"ToggleHtml",title:"HTML",css:"wym_tools_html"},{name:"Preview",title:"Preview",css:"wym_tools_preview"}],containersHtml:"<div class='wym_containers wym_section'><h2>{Containers}</h2><ul>"+WYMeditor.CONTAINERS_ITEMS+"</ul></div>",containersItemHtml:"<li class='"+WYMeditor.CONTAINER_CLASS+"'><a href='#' name='"+WYMeditor.CONTAINER_NAME+"'>"+WYMeditor.CONTAINER_TITLE+"</a></li>",containersItems:[{name:"P",title:"Paragraph",css:"wym_containers_p"},{name:"H1",title:"Heading_1",css:"wym_containers_h1"},{name:"H2",title:"Heading_2",css:"wym_containers_h2"},{name:"H3",title:"Heading_3",css:"wym_containers_h3"},{name:"H4",title:"Heading_4",css:"wym_containers_h4"},{name:"H5",title:"Heading_5",css:"wym_containers_h5"},{name:"H6",title:"Heading_6",css:"wym_containers_h6"},{name:"PRE",title:"Preformatted",css:"wym_containers_pre"},{name:"BLOCKQUOTE",title:"Blockquote",css:"wym_containers_blockquote"},{name:"TH",title:"Table_Header",css:"wym_containers_th"}],classesHtml:"<div class='wym_classes wym_section'><h2>{Classes}</h2><ul>"+WYMeditor.CLASSES_ITEMS+"</ul></div>",classesItemHtml:"<li class='wym_classes_"+WYMeditor.CLASS_NAME+"'><a href='#' name='"+WYMeditor.CLASS_NAME+"'>"+WYMeditor.CLASS_TITLE+"</a></li>",classesItems:[],statusHtml:"<div class='wym_status wym_section'><h2>{Status}</h2></div>",htmlHtml:"<div class='wym_html wym_section'><h2>{Source_Code}</h2><textarea class='wym_html_val'></textarea></div>",boxSelector:".wym_box",toolsSelector:".wym_tools",toolsListSelector:" ul",containersSelector:".wym_containers",classesSelector:".wym_classes",htmlSelector:".wym_html",iframeSelector:".wym_iframe iframe",iframeBodySelector:".wym_iframe",statusSelector:".wym_status",toolSelector:".wym_tools a",containerSelector:".wym_containers a",classSelector:".wym_classes a",htmlValSelector:".wym_html_val",hrefSelector:".wym_href",srcSelector:".wym_src",titleSelector:".wym_title",altSelector:".wym_alt",textSelector:".wym_text",rowsSelector:".wym_rows",colsSelector:".wym_cols",captionSelector:".wym_caption",summarySelector:".wym_summary",submitSelector:".wym_submit",cancelSelector:".wym_cancel",previewSelector:"",dialogTypeSelector:".wym_dialog_type",dialogLinkSelector:".wym_dialog_link",dialogImageSelector:".wym_dialog_image",dialogTableSelector:".wym_dialog_table",dialogPasteSelector:".wym_dialog_paste",dialogPreviewSelector:".wym_dialog_preview",updateSelector:".wymupdate",updateEvent:"click",dialogFeatures:"menubar=no,titlebar=no,toolbar=no,resizable=no,width=560,height=300,top=0,left=0",dialogFeaturesPreview:"menubar=no,titlebar=no,toolbar=no,resizable=no,scrollbars=yes,width=560,height=300,top=0,left=0",dialogHtml:"<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'><html dir='"+WYMeditor.DIRECTION+"'><head><link rel='stylesheet' type='text/css' media='screen' href='"+WYMeditor.CSS_PATH+"' /><title>"+WYMeditor.DIALOG_TITLE+"</title><script type='text/javascript' src='"+WYMeditor.JQUERY_PATH+"'><\/script><script type='text/javascript' src='"+WYMeditor.WYM_PATH+"'><\/script></head>"+WYMeditor.DIALOG_BODY+"</html>",dialogLinkHtml:"<body class='wym_dialog wym_dialog_link' onload='WYMeditor.INIT_DIALOG("+WYMeditor.INDEX+")'><form><fieldset><input type='hidden' class='wym_dialog_type' value='"+WYMeditor.DIALOG_LINK+"' /><legend>{Link}</legend><div class='row'><label>{URL}</label><input type='text' class='wym_href' value='' size='40' /></div><div class='row'><label>{Title}</label><input type='text' class='wym_title' value='' size='40' /></div><div class='row row-indent'><input class='wym_submit' type='button' value='{Submit}' /><input class='wym_cancel' type='button'value='{Cancel}' /></div></fieldset></form></body>",dialogImageHtml:"<body class='wym_dialog wym_dialog_image' onload='WYMeditor.INIT_DIALOG("+WYMeditor.INDEX+")'><form><fieldset><input type='hidden' class='wym_dialog_type' value='"+WYMeditor.DIALOG_IMAGE+"' /><legend>{Image}</legend><div class='row'><label>{URL}</label><input type='text' class='wym_src' value='' size='40' /></div><div class='row'><label>{Alternative_Text}</label><input type='text' class='wym_alt' value='' size='40' /></div><div class='row'><label>{Title}</label><input type='text' class='wym_title' value='' size='40' /></div><div class='row row-indent'><input class='wym_submit' type='button' value='{Submit}' /><input class='wym_cancel' type='button'value='{Cancel}' /></div></fieldset></form></body>",dialogTableHtml:"<body class='wym_dialog wym_dialog_table' onload='WYMeditor.INIT_DIALOG("+WYMeditor.INDEX+")'><form><fieldset><input type='hidden' class='wym_dialog_type' value='"+WYMeditor.DIALOG_TABLE+"' /><legend>{Table}</legend><div class='row'><label>{Caption}</label><input type='text' class='wym_caption' value='' size='40' /></div><div class='row'><label>{Summary}</label><input type='text' class='wym_summary' value='' size='40' /></div><div class='row'><label>{Number_Of_Rows}</label><input type='text' class='wym_rows' value='3' size='3' /></div><div class='row'><label>{Number_Of_Cols}</label><input type='text' class='wym_cols' value='2' size='3' /></div><div class='row row-indent'><input class='wym_submit' type='button' value='{Submit}' /><input class='wym_cancel' type='button'value='{Cancel}' /></div></fieldset></form></body>",dialogPasteHtml:"<body class='wym_dialog wym_dialog_paste' onload='WYMeditor.INIT_DIALOG("+WYMeditor.INDEX+")'><form><input type='hidden' class='wym_dialog_type' value='"+WYMeditor.DIALOG_PASTE+"' /><fieldset><legend>{Paste_From_Word}</legend><div class='row'><textarea class='wym_text' rows='10' cols='50'></textarea></div><div class='row'><input class='wym_submit' type='button' value='{Submit}' /><input class='wym_cancel' type='button'value='{Cancel}' /></div></fieldset></form></body>",dialogPreviewHtml:"<body class='wym_dialog wym_dialog_preview' onload='WYMeditor.INIT_DIALOG("+WYMeditor.INDEX+")'></body>",dialogStyles:[],stringDelimiterLeft:"{",stringDelimiterRight:"}",preInit:null,preBind:null,postInit:null,preInitDialog:null,postInitDialog:null},a);return this.each(function(){new WYMeditor.editor(jQuery(this),a)})};jQuery.extend({wymeditors:function(a){return(WYMeditor.INSTANCES[a])}});WYMeditor.editor.prototype.init=function(){if(jQuery.browser.msie){var WymClass=new WYMeditor.WymClassExplorer(this)}else{if(jQuery.browser.mozilla){var WymClass=new WYMeditor.WymClassMozilla(this)}else{if(jQuery.browser.opera){var WymClass=new WYMeditor.WymClassOpera(this)}else{if(jQuery.browser.safari){var WymClass=new WYMeditor.WymClassSafari(this)}}}}if(WymClass){if(jQuery.isFunction(this._options.preInit)){this._options.preInit(this)}var SaxListener=new WYMeditor.XhtmlSaxListener();jQuery.extend(SaxListener,WymClass);this.parser=new WYMeditor.XhtmlParser(SaxListener);if(this._options.styles||this._options.stylesheet){this.configureEditorUsingRawCss()}this.helper=new WYMeditor.XmlHelper();for(var prop in WymClass){this[prop]=WymClass[prop]}this._box=jQuery(this._element).hide().after(this._options.boxHtml).next().addClass("wym_box_"+this._index);if(jQuery.isFunction(jQuery.fn.data)){jQuery.data(this._box.get(0),WYMeditor.WYM_INDEX,this._index);jQuery.data(this._element.get(0),WYMeditor.WYM_INDEX,this._index)}var h=WYMeditor.Helper;var iframeHtml=this._options.iframeHtml;iframeHtml=h.replaceAll(iframeHtml,WYMeditor.INDEX,this._index);iframeHtml=h.replaceAll(iframeHtml,WYMeditor.IFRAME_BASE_PATH,this._options.iframeBasePath);var boxHtml=jQuery(this._box).html();boxHtml=h.replaceAll(boxHtml,WYMeditor.LOGO,this._options.logoHtml);boxHtml=h.replaceAll(boxHtml,WYMeditor.TOOLS,this._options.toolsHtml);boxHtml=h.replaceAll(boxHtml,WYMeditor.CONTAINERS,this._options.containersHtml);boxHtml=h.replaceAll(boxHtml,WYMeditor.CLASSES,this._options.classesHtml);boxHtml=h.replaceAll(boxHtml,WYMeditor.HTML,this._options.htmlHtml);boxHtml=h.replaceAll(boxHtml,WYMeditor.IFRAME,iframeHtml);boxHtml=h.replaceAll(boxHtml,WYMeditor.STATUS,this._options.statusHtml);var aTools=eval(this._options.toolsItems);var sTools="";for(var i=0;i<aTools.length;i++){var oTool=aTools[i];if(oTool.name&&oTool.title){var sTool=this._options.toolsItemHtml}var sTool=h.replaceAll(sTool,WYMeditor.TOOL_NAME,oTool.name);sTool=h.replaceAll(sTool,WYMeditor.TOOL_TITLE,this._options.stringDelimiterLeft+oTool.title+this._options.stringDelimiterRight);sTool=h.replaceAll(sTool,WYMeditor.TOOL_CLASS,oTool.css);sTools+=sTool}boxHtml=h.replaceAll(boxHtml,WYMeditor.TOOLS_ITEMS,sTools);var aClasses=eval(this._options.classesItems);var sClasses="";for(var i=0;i<aClasses.length;i++){var oClass=aClasses[i];if(oClass.name&&oClass.title){var sClass=this._options.classesItemHtml}sClass=h.replaceAll(sClass,WYMeditor.CLASS_NAME,oClass.name);sClass=h.replaceAll(sClass,WYMeditor.CLASS_TITLE,oClass.title);sClasses+=sClass}boxHtml=h.replaceAll(boxHtml,WYMeditor.CLASSES_ITEMS,sClasses);var aContainers=eval(this._options.containersItems);var sContainers="";for(var i=0;i<aContainers.length;i++){var oContainer=aContainers[i];if(oContainer.name&&oContainer.title){var sContainer=this._options.containersItemHtml}sContainer=h.replaceAll(sContainer,WYMeditor.CONTAINER_NAME,oContainer.name);sContainer=h.replaceAll(sContainer,WYMeditor.CONTAINER_TITLE,this._options.stringDelimiterLeft+oContainer.title+this._options.stringDelimiterRight);sContainer=h.replaceAll(sContainer,WYMeditor.CONTAINER_CLASS,oContainer.css);sContainers+=sContainer}boxHtml=h.replaceAll(boxHtml,WYMeditor.CONTAINERS_ITEMS,sContainers);boxHtml=this.replaceStrings(boxHtml);jQuery(this._box).html(boxHtml);jQuery(this._box).find(this._options.htmlSelector).hide();this.loadSkin()}};WYMeditor.editor.prototype.bindEvents=function(){var wym=this;jQuery(this._box).find(this._options.toolSelector).click(function(){wym._iframe.contentWindow.focus();wym.exec(jQuery(this).attr(WYMeditor.NAME));return(false)});jQuery(this._box).find(this._options.containerSelector).click(function(){wym.container(jQuery(this).attr(WYMeditor.NAME));return(false)});jQuery(this._box).find(this._options.htmlValSelector).keyup(function(){jQuery(wym._doc.body).html(jQuery(this).val())}).focus(function(){jQuery(this).toggleClass("hasfocus")}).blur(function(){jQuery(this).toggleClass("hasfocus")});jQuery(this._box).find(this._options.classSelector).click(function(){var aClasses=eval(wym._options.classesItems);var sName=jQuery(this).attr(WYMeditor.NAME);var oClass=WYMeditor.Helper.findByName(aClasses,sName);if(oClass){var jqexpr=oClass.expr;wym.toggleClass(sName,jqexpr)}wym._iframe.contentWindow.focus();return(false)});jQuery(this._options.updateSelector).bind(this._options.updateEvent,function(){wym.update()})};WYMeditor.editor.prototype.ready=function(){return(this._doc!=null)};WYMeditor.editor.prototype.box=function(){return(this._box)};WYMeditor.editor.prototype.html=function(a){if(typeof a==="string"){jQuery(this._doc.body).html(a)}else{return(jQuery(this._doc.body).html())}};WYMeditor.editor.prototype.xhtml=function(){return this.parser.parse(this.html())};WYMeditor.editor.prototype.exec=function(b){switch(b){case WYMeditor.CREATE_LINK:var a=this.container();if(a||this._selected_image){this.dialog(WYMeditor.DIALOG_LINK)}break;case WYMeditor.INSERT_IMAGE:this.dialog(WYMeditor.DIALOG_IMAGE);break;case WYMeditor.INSERT_TABLE:this.dialog(WYMeditor.DIALOG_TABLE);break;case WYMeditor.PASTE:this.dialog(WYMeditor.DIALOG_PASTE);break;case WYMeditor.TOGGLE_HTML:this.update();this.toggleHtml();break;case WYMeditor.PREVIEW:this.dialog(WYMeditor.PREVIEW,this._options.dialogFeaturesPreview);break;default:this._exec(b);break}};WYMeditor.editor.prototype.container=function(a){if(a){var d=null;if(a.toLowerCase()==WYMeditor.TH){d=this.container();switch(d.tagName.toLowerCase()){case WYMeditor.TD:case WYMeditor.TH:break;default:var e=new Array(WYMeditor.TD,WYMeditor.TH);d=this.findUp(this.container(),e);break}if(d!=null){a=(d.tagName.toLowerCase()==WYMeditor.TD)?WYMeditor.TH:WYMeditor.TD;this.switchTo(d,a);this.update()}}else{var e=new Array(WYMeditor.P,WYMeditor.H1,WYMeditor.H2,WYMeditor.H3,WYMeditor.H4,WYMeditor.H5,WYMeditor.H6,WYMeditor.PRE,WYMeditor.BLOCKQUOTE);d=this.findUp(this.container(),e);if(d){var i=null;if(a.toLowerCase()==WYMeditor.BLOCKQUOTE){var f=this.findUp(this.container(),WYMeditor.BLOCKQUOTE);if(f==null){i=this._doc.createElement(a);d.parentNode.insertBefore(i,d);i.appendChild(d);this.setFocusToNode(i.firstChild)}else{var c=f.childNodes;var g=c.length;var b=null;if(g>0){b=c.item(0)}for(var h=0;h<g;h++){f.parentNode.insertBefore(c.item(0),f)}f.parentNode.removeChild(f);if(b){this.setFocusToNode(b)}}}else{this.switchTo(d,a)}this.update()}}}else{return(this.selected())}};WYMeditor.editor.prototype.toggleClass=function(c,b){var a=(this._selected_image?this._selected_image:jQuery(this.selected()));a=jQuery(a).parentsOrSelf(b);jQuery(a).toggleClass(c);if(!jQuery(a).attr(WYMeditor.CLASS)){jQuery(a).removeAttr(this._class)}};WYMeditor.editor.prototype.findUp=function(d,c){if(d){var e=d.tagName.toLowerCase();if(typeof(c)==WYMeditor.STRING){while(e!=c&&e!=WYMeditor.BODY){d=d.parentNode;e=d.tagName.toLowerCase()}}else{var b=false;while(!b&&e!=WYMeditor.BODY){for(var a=0;a<c.length;a++){if(e==c[a]){b=true;break}}if(!b){d=d.parentNode;e=d.tagName.toLowerCase()}}}if(e!=WYMeditor.BODY){return(d)}else{return(null)}}else{return(null)}};WYMeditor.editor.prototype.switchTo=function(c,d){var b=this._doc.createElement(d);var a=jQuery(c).html();c.parentNode.replaceChild(b,c);jQuery(b).html(a);this.setFocusToNode(b)};WYMeditor.editor.prototype.replaceStrings=function(sVal){if(!WYMeditor.STRINGS[this._options.lang]){try{eval(jQuery.ajax({url:this._options.langPath+this._options.lang+".js",async:false}).responseText)}catch(e){WYMeditor.console.error("WYMeditor: error while parsing language file.");return sVal}}for(var key in WYMeditor.STRINGS[this._options.lang]){sVal=WYMeditor.Helper.replaceAll(sVal,this._options.stringDelimiterLeft+key+this._options.stringDelimiterRight,WYMeditor.STRINGS[this._options.lang][key])}return(sVal)};WYMeditor.editor.prototype.encloseString=function(a){return(this._options.stringDelimiterLeft+a+this._options.stringDelimiterRight)};WYMeditor.editor.prototype.status=function(a){jQuery(this._box).find(this._options.statusSelector).html(a)};WYMeditor.editor.prototype.update=function(){var a=this.xhtml();jQuery(this._element).val(a);jQuery(this._box).find(this._options.htmlValSelector).not(".hasfocus").val(a)};WYMeditor.editor.prototype.dialog=function(j,c,f){var a=c||this._wym._options.dialogFeatures;var d=window.open("","dialog",a);if(d){var b="";switch(j){case (WYMeditor.DIALOG_LINK):b=this._options.dialogLinkHtml;break;case (WYMeditor.DIALOG_IMAGE):b=this._options.dialogImageHtml;break;case (WYMeditor.DIALOG_TABLE):b=this._options.dialogTableHtml;break;case (WYMeditor.DIALOG_PASTE):b=this._options.dialogPasteHtml;break;case (WYMeditor.PREVIEW):b=this._options.dialogPreviewHtml;break;default:b=f}var e=WYMeditor.Helper;var g=this._options.dialogHtml;g=e.replaceAll(g,WYMeditor.BASE_PATH,this._options.basePath);g=e.replaceAll(g,WYMeditor.DIRECTION,this._options.direction);g=e.replaceAll(g,WYMeditor.CSS_PATH,this._options.skinPath+WYMeditor.SKINS_DEFAULT_CSS);g=e.replaceAll(g,WYMeditor.WYM_PATH,this._options.wymPath);g=e.replaceAll(g,WYMeditor.JQUERY_PATH,this._options.jQueryPath);g=e.replaceAll(g,WYMeditor.DIALOG_TITLE,this.encloseString(j));g=e.replaceAll(g,WYMeditor.DIALOG_BODY,b);g=e.replaceAll(g,WYMeditor.INDEX,this._index);g=this.replaceStrings(g);var i=d.document;i.write(g);i.close()}};WYMeditor.editor.prototype.toggleHtml=function(){jQuery(this._box).find(this._options.htmlSelector).toggle()};WYMeditor.editor.prototype.uniqueStamp=function(){var a=new Date();return("wym-"+a.getTime())};WYMeditor.editor.prototype.paste=function(b){var e;var a=this.selected();var c=b.split(this._newLine+this._newLine);var d=new RegExp(this._newLine,"g");if(a&&a.tagName.toLowerCase()!=WYMeditor.BODY){for(x=c.length-1;x>=0;x--){e=c[x];e=e.replace(d,"<br />");jQuery(a).after("<p>"+e+"</p>")}}else{for(x=0;x<c.length;x++){e=c[x];e=e.replace(d,"<br />");jQuery(this._doc.body).append("<p>"+e+"</p>")}}};WYMeditor.editor.prototype.insert=function(a){if(this._iframe.contentWindow.getSelection().focusNode!=null){this._exec(WYMeditor.INSERT_HTML,a)}else{this.paste(a)}};WYMeditor.editor.prototype.wrap=function(b,a){if(this._iframe.contentWindow.getSelection().focusNode!=null){this._exec(WYMeditor.INSERT_HTML,b+this._iframe.contentWindow.getSelection().toString()+a)}};WYMeditor.editor.prototype.unwrap=function(){if(this._iframe.contentWindow.getSelection().focusNode!=null){this._exec(WYMeditor.INSERT_HTML,this._iframe.contentWindow.getSelection().toString())}};WYMeditor.editor.prototype.setFocusToNode=function(d,b){var a=this._doc.createRange(),c=this._iframe.contentWindow.getSelection();b=b?0:1;a.selectNodeContents(d);c.addRange(a);c.collapse(d,b);this._iframe.contentWindow.focus()};WYMeditor.editor.prototype.addCssRules=function(e,c){var b=e.styleSheets[0];if(b){for(var a=0;a<c.length;a++){var d=c[a];if(d.name&&d.css){this.addCssRule(b,d)}}}};WYMeditor.editor.prototype.computeBasePath=function(){return jQuery(jQuery.grep(jQuery("script"),function(a){return(a.src&&a.src.match(/jquery\.wymeditor(\.pack|\.min|\.packed)?\.js(\?.*)?$/))})).attr("src").replace(/jquery\.wymeditor(\.pack|\.min|\.packed)?\.js(\?.*)?$/,"")};WYMeditor.editor.prototype.computeWymPath=function(){return jQuery(jQuery.grep(jQuery("script"),function(a){return(a.src&&a.src.match(/jquery\.wymeditor(\.pack|\.min|\.packed)?\.js(\?.*)?$/))})).attr("src")};WYMeditor.editor.prototype.computeJqueryPath=function(){return jQuery(jQuery.grep(jQuery("script"),function(a){return(a.src&&a.src.match(/jquery(-(.*)){0,1}(\.pack|\.min|\.packed)?\.js(\?.*)?$/))})).attr("src")};WYMeditor.editor.prototype.computeCssPath=function(){return jQuery(jQuery.grep(jQuery("link"),function(a){return(a.href&&a.href.match(/wymeditor\/skins\/(.*)screen\.css(\?.*)?$/))})).attr("href")};WYMeditor.editor.prototype.configureEditorUsingRawCss=function(){var a=new WYMeditor.WymCssParser();if(this._options.stylesheet){a.parse(jQuery.ajax({url:this._options.stylesheet,async:false}).responseText)}else{a.parse(this._options.styles,false)}if(this._options.classesItems.length==0){this._options.classesItems=a.css_settings.classesItems}if(this._options.editorStyles.length==0){this._options.editorStyles=a.css_settings.editorStyles}if(this._options.dialogStyles.length==0){this._options.dialogStyles=a.css_settings.dialogStyles}};WYMeditor.editor.prototype.listen=function(){jQuery(this._doc.body).bind("mousedown",this.mousedown)};WYMeditor.editor.prototype.mousedown=function(a){var b=WYMeditor.INSTANCES[this.ownerDocument.title];b._selected_image=(a.target.tagName.toLowerCase()==WYMeditor.IMG)?a.target:null};WYMeditor.loadCss=function(a){var c=document.createElement("link");c.rel="stylesheet";c.href=a;var b=jQuery("head").get(0);b.appendChild(c)};WYMeditor.editor.prototype.loadSkin=function(){if(this._options.loadSkin&&!WYMeditor.SKINS[this._options.skin]){var found=false;var rExp=new RegExp(this._options.skin+"/"+WYMeditor.SKINS_DEFAULT_CSS+"$");jQuery("link").each(function(){if(this.href.match(rExp)){found=true}});if(!found){WYMeditor.loadCss(this._options.skinPath+WYMeditor.SKINS_DEFAULT_CSS)}}jQuery(this._box).addClass("wym_skin_"+this._options.skin);if(this._options.initSkin&&!WYMeditor.SKINS[this._options.skin]){eval(jQuery.ajax({url:this._options.skinPath+WYMeditor.SKINS_DEFAULT_JS,async:false}).responseText)}if(WYMeditor.SKINS[this._options.skin]&&WYMeditor.SKINS[this._options.skin].init){WYMeditor.SKINS[this._options.skin].init(this)}};WYMeditor.INIT_DIALOG=function(index){var wym=window.opener.WYMeditor.INSTANCES[index];var doc=window.document;var selected=wym.selected();var dialogType=jQuery(wym._options.dialogTypeSelector).val();var sStamp=wym.uniqueStamp();switch(dialogType){case WYMeditor.DIALOG_LINK:if(selected&&selected.tagName&&selected.tagName.toLowerCase!=WYMeditor.A){selected=jQuery(selected).parentsOrSelf(WYMeditor.A)}if(!selected&&wym._selected_image){selected=jQuery(wym._selected_image).parentsOrSelf(WYMeditor.A)}break}if(jQuery.isFunction(wym._options.preInitDialog)){wym._options.preInitDialog(wym,window)}var styles=doc.styleSheets[0];var aCss=eval(wym._options.dialogStyles);wym.addCssRules(doc,aCss);if(selected){jQuery(wym._options.hrefSelector).val(jQuery(selected).attr(WYMeditor.HREF));jQuery(wym._options.srcSelector).val(jQuery(selected).attr(WYMeditor.SRC));jQuery(wym._options.titleSelector).val(jQuery(selected).attr(WYMeditor.TITLE));jQuery(wym._options.altSelector).val(jQuery(selected).attr(WYMeditor.ALT))}if(wym._selected_image){jQuery(wym._options.dialogImageSelector+" "+wym._options.srcSelector).val(jQuery(wym._selected_image).attr(WYMeditor.SRC));jQuery(wym._options.dialogImageSelector+" "+wym._options.titleSelector).val(jQuery(wym._selected_image).attr(WYMeditor.TITLE));jQuery(wym._options.dialogImageSelector+" "+wym._options.altSelector).val(jQuery(wym._selected_image).attr(WYMeditor.ALT))}jQuery(wym._options.dialogLinkSelector+" "+wym._options.submitSelector).click(function(){var sUrl=jQuery(wym._options.hrefSelector).val();if(sUrl.length>0){var link;if(selected[0]&&selected[0].tagName.toLowerCase()==WYMeditor.A){link=selected}else{wym._exec(WYMeditor.CREATE_LINK,sStamp);link=jQuery("a[href="+sStamp+"]",wym._doc.body)}link.attr(WYMeditor.HREF,sUrl).attr(WYMeditor.TITLE,jQuery(wym._options.titleSelector).val())}window.close()});jQuery(wym._options.dialogImageSelector+" "+wym._options.submitSelector).click(function(){var sUrl=jQuery(wym._options.srcSelector).val();if(sUrl.length>0){wym._exec(WYMeditor.INSERT_IMAGE,sStamp);jQuery("img[src$="+sStamp+"]",wym._doc.body).attr(WYMeditor.SRC,sUrl).attr(WYMeditor.TITLE,jQuery(wym._options.titleSelector).val()).attr(WYMeditor.ALT,jQuery(wym._options.altSelector).val())}window.close()});jQuery(wym._options.dialogTableSelector+" "+wym._options.submitSelector).click(function(){var iRows=jQuery(wym._options.rowsSelector).val();var iCols=jQuery(wym._options.colsSelector).val();if(iRows>0&&iCols>0){var table=wym._doc.createElement(WYMeditor.TABLE);var newRow=null;var newCol=null;var sCaption=jQuery(wym._options.captionSelector).val();var newCaption=table.createCaption();newCaption.innerHTML=sCaption;for(x=0;x<iRows;x++){newRow=table.insertRow(x);for(y=0;y<iCols;y++){newRow.insertCell(y)}}jQuery(table).attr("summary",jQuery(wym._options.summarySelector).val());var node=jQuery(wym.findUp(wym.container(),WYMeditor.MAIN_CONTAINERS)).get(0);if(!node||!node.parentNode){jQuery(wym._doc.body).append(table)}else{jQuery(node).after(table)}}window.close()});jQuery(wym._options.dialogPasteSelector+" "+wym._options.submitSelector).click(function(){var sText=jQuery(wym._options.textSelector).val();wym.paste(sText);window.close()});jQuery(wym._options.dialogPreviewSelector+" "+wym._options.previewSelector).html(wym.xhtml());jQuery(wym._options.cancelSelector).mousedown(function(){window.close()});if(jQuery.isFunction(wym._options.postInitDialog)){wym._options.postInitDialog(wym,window)}};WYMeditor.XmlHelper=function(){this._entitiesDiv=document.createElement("div");return this};WYMeditor.XmlHelper.prototype.tag=function(c,b,a){b=b||false;a=a||false;return"<"+c+(b?this.tagOptions(b):"")+(a?">":" />")};WYMeditor.XmlHelper.prototype.contentTag=function(b,c,a){a=a||false;return"<"+b+(a?this.tagOptions(a):"")+">"+c+"</"+b+">"};WYMeditor.XmlHelper.prototype.cdataSection=function(a){return"<![CDATA["+a+"]]>"};WYMeditor.XmlHelper.prototype.escapeOnce=function(a){return this._fixDoubleEscape(this.escapeEntities(a))};WYMeditor.XmlHelper.prototype._fixDoubleEscape=function(a){return a.replace(/&amp;([a-z]+|(#\d+));/ig,"&$1;")};WYMeditor.XmlHelper.prototype.tagOptions=function(b){var a=this;a._formated_options="";for(var c in b){var d="";var e=b[c];if(typeof e!="function"&&e.length>0){if(parseInt(c)==c&&typeof e=="object"){c=e.shift();e=e.pop()}if(c!=""&&e!=""){a._formated_options+=" "+c+'="'+a.escapeOnce(e)+'"'}}}return a._formated_options};WYMeditor.XmlHelper.prototype.escapeEntities=function(c,b){this._entitiesDiv.innerHTML=c;this._entitiesDiv.textContent=c;var a=this._entitiesDiv.innerHTML;if(typeof b=="undefined"){if(b!=false){a=a.replace('"',"&quot;")}if(b==true){a=a.replace('"',"&#039;")}}return a};WYMeditor.XmlHelper.prototype.parseAttributes=function(h){var a=[];var g=h.split(/((=\s*")(")("))|((=\s*\')(\')(\'))|((=\s*[^>\s]*))/g);if(g.toString()!=h){for(var d in g){var c=g[d];if(typeof c!="function"&&c.length!=0){var e=new RegExp("(\\w+)\\s*"+c);if(match=h.match(e)){var f=c.replace(/^[\s=]+/,"");var b=f.charAt(0);b=b=='"'?'"':(b=="'"?"'":"");if(b!=""){f=b=='"'?f.replace(/^"|"+$/g,""):f.replace(/^'|'+$/g,"")}h=h.replace(match[0],"");a.push([match[1],f])}}}}return a};WYMeditor.XhtmlValidator={_attributes:{core:{except:["base","head","html","meta","param","script","style","title"],attributes:["class","id","style","title","accesskey","tabindex"]},language:{except:["base","br","hr","iframe","param","script"],attributes:{dir:["ltr","rtl"],"0":"lang","1":"xml:lang"}},keyboard:{attributes:{accesskey:/^(\w){1}$/,tabindex:/^(\d)+$/}}},_events:{window:{only:["body"],attributes:["onload","onunload"]},form:{only:["form","input","textarea","select","a","label","button"],attributes:["onchange","onsubmit","onreset","onselect","onblur","onfocus"]},keyboard:{except:["base","bdo","br","frame","frameset","head","html","iframe","meta","param","script","style","title"],attributes:["onkeydown","onkeypress","onkeyup"]},mouse:{except:["base","bdo","br","head","html","meta","param","script","style","title"],attributes:["onclick","ondblclick","onmousedown","onmousemove","onmouseover","onmouseout","onmouseup"]}},_tags:{a:{attributes:{"0":"charset","1":"coords","2":"href","3":"hreflang","4":"name",rel:/^(alternate|designates|stylesheet|start|next|prev|contents|index|glossary|copyright|chapter|section|subsection|appendix|help|bookmark| |shortcut|icon)+$/,rev:/^(alternate|designates|stylesheet|start|next|prev|contents|index|glossary|copyright|chapter|section|subsection|appendix|help|bookmark| |shortcut|icon)+$/,shape:/^(rect|rectangle|circ|circle|poly|polygon)$/,"5":"type"}},"0":"abbr","1":"acronym","2":"address",area:{attributes:{"0":"alt","1":"coords","2":"href",nohref:/^(true|false)$/,shape:/^(rect|rectangle|circ|circle|poly|polygon)$/},required:["alt"]},"3":"b",base:{attributes:["href"],required:["href"]},bdo:{attributes:{dir:/^(ltr|rtl)$/},required:["dir"]},"4":"big",blockquote:{attributes:["cite"]},"5":"body","6":"br",button:{attributes:{disabled:/^(disabled)$/,type:/^(button|reset|submit)$/,"0":"value"},inside:"form"},"7":"caption","8":"cite","9":"code",col:{attributes:{align:/^(right|left|center|justify)$/,"0":"char","1":"charoff",span:/^(\d)+$/,valign:/^(top|middle|bottom|baseline)$/,"2":"width"},inside:"colgroup"},colgroup:{attributes:{align:/^(right|left|center|justify)$/,"0":"char","1":"charoff",span:/^(\d)+$/,valign:/^(top|middle|bottom|baseline)$/,"2":"width"}},"10":"dd",del:{attributes:{"0":"cite",datetime:/^([0-9]){8}/}},"11":"div","12":"dfn","13":"dl","14":"dt","15":"em",fieldset:{inside:"form"},form:{attributes:{"0":"action","1":"accept","2":"accept-charset","3":"enctype",method:/^(get|post)$/},required:["action"]},head:{attributes:["profile"]},"16":"h1","17":"h2","18":"h3","19":"h4","20":"h5","21":"h6","22":"hr",html:{attributes:["xmlns"]},"23":"i",img:{attributes:["alt","src","height","ismap","longdesc","usemap","width"],required:["alt","src"]},input:{attributes:{"0":"accept","1":"alt",checked:/^(checked)$/,disabled:/^(disabled)$/,maxlength:/^(\d)+$/,"2":"name",readonly:/^(readonly)$/,size:/^(\d)+$/,"3":"src",type:/^(button|checkbox|file|hidden|image|password|radio|reset|submit|text)$/,"4":"value"},inside:"form"},ins:{attributes:{"0":"cite",datetime:/^([0-9]){8}/}},"24":"kbd",label:{attributes:["for"],inside:"form"},"25":"legend","26":"li",link:{attributes:{"0":"charset","1":"href","2":"hreflang",media:/^(all|braille|print|projection|screen|speech|,|;| )+$/i,rel:/^(alternate|appendix|bookmark|chapter|contents|copyright|glossary|help|home|index|next|prev|section|start|stylesheet|subsection| |shortcut|icon)+$/i,rev:/^(alternate|appendix|bookmark|chapter|contents|copyright|glossary|help|home|index|next|prev|section|start|stylesheet|subsection| |shortcut|icon)+$/i,"3":"type"},inside:"head"},map:{attributes:["id","name"],required:["id"]},meta:{attributes:{"0":"content","http-equiv":/^(content\-type|expires|refresh|set\-cookie)$/i,"1":"name","2":"scheme"},required:["content"]},"27":"noscript",object:{attributes:["archive","classid","codebase","codetype","data","declare","height","name","standby","type","usemap","width"]},"28":"ol",optgroup:{attributes:{"0":"label",disabled:/^(disabled)$/},required:["label"]},option:{attributes:{"0":"label",disabled:/^(disabled)$/,selected:/^(selected)$/,"1":"value"},inside:"select"},"29":"p",param:{attributes:{"0":"type",valuetype:/^(data|ref|object)$/,"1":"valuetype","2":"value"},required:["name"]},"30":"pre",q:{attributes:["cite"]},"31":"samp",script:{attributes:{type:/^(text\/ecmascript|text\/javascript|text\/jscript|text\/vbscript|text\/vbs|text\/xml)$/,"0":"charset",defer:/^(defer)$/,"1":"src"},required:["type"]},select:{attributes:{disabled:/^(disabled)$/,multiple:/^(multiple)$/,"0":"name","1":"size"},inside:"form"},"32":"small","33":"span","34":"strong",style:{attributes:{"0":"type",media:/^(screen|tty|tv|projection|handheld|print|braille|aural|all)$/},required:["type"]},"35":"sub","36":"sup",table:{attributes:{"0":"border","1":"cellpadding","2":"cellspacing",frame:/^(void|above|below|hsides|lhs|rhs|vsides|box|border)$/,rules:/^(none|groups|rows|cols|all)$/,"3":"summary","4":"width"}},tbody:{attributes:{align:/^(right|left|center|justify)$/,"0":"char","1":"charoff",valign:/^(top|middle|bottom|baseline)$/}},td:{attributes:{"0":"abbr",align:/^(left|right|center|justify|char)$/,"1":"axis","2":"char","3":"charoff",colspan:/^(\d)+$/,"4":"headers",rowspan:/^(\d)+$/,scope:/^(col|colgroup|row|rowgroup)$/,valign:/^(top|middle|bottom|baseline)$/}},textarea:{attributes:["cols","rows","disabled","name","readonly"],required:["cols","rows"],inside:"form"},tfoot:{attributes:{align:/^(right|left|center|justify)$/,"0":"char","1":"charoff",valign:/^(top|middle|bottom)$/,"2":"baseline"}},th:{attributes:{"0":"abbr",align:/^(left|right|center|justify|char)$/,"1":"axis","2":"char","3":"charoff",colspan:/^(\d)+$/,"4":"headers",rowspan:/^(\d)+$/,scope:/^(col|colgroup|row|rowgroup)$/,valign:/^(top|middle|bottom|baseline)$/}},thead:{attributes:{align:/^(right|left|center|justify)$/,"0":"char","1":"charoff",valign:/^(top|middle|bottom|baseline)$/}},"37":"title",tr:{attributes:{align:/^(right|left|center|justify|char)$/,"0":"char","1":"charoff",valign:/^(top|middle|bottom|baseline)$/}},"38":"tt","39":"ul","40":"var"},skiped_attributes:[],skiped_attribute_values:[],getValidTagAttributes:function(a,b){var c={};var g=this.getPossibleTagAttributes(a);for(var e in b){var f=b[e];var d=WYMeditor.Helper;if(!d.contains(this.skiped_attributes,e)&&!d.contains(this.skiped_attribute_values,f)){if(typeof f!="function"&&d.contains(g,e)){if(this.doesAttributeNeedsValidation(a,e)){if(this.validateAttribute(a,e,f)){c[e]=f}}else{c[e]=f}}}}return c},getUniqueAttributesAndEventsForTag:function(b){var a=[];if(this._tags[b]&&this._tags[b]["attributes"]){for(k in this._tags[b]["attributes"]){a.push(parseInt(k)==k?this._tags[b]["attributes"][k]:k)}}return a},getDefaultAttributesAndEventsForTags:function(){var a=[];for(var b in this._events){a.push(this._events[b])}for(var b in this._attributes){a.push(this._attributes[b])}return a},isValidTag:function(a){if(this._tags[a]){return true}for(var b in this._tags){if(this._tags[b]==a){return true}}return false},getDefaultAttributesAndEventsForTag:function(a){var i=[];if(this.isValidTag(a)){var g=this.getDefaultAttributesAndEventsForTags();for(var d in g){var f=g[d];if(typeof f=="object"){var e=WYMeditor.Helper;if((f.except&&e.contains(f.except,a))||(f.only&&!e.contains(f.only,a))){continue}var c=f.attributes?f.attributes:f.events;for(var b in c){i.push(typeof c[b]!="string"?b:c[b])}}}}return i},doesAttributeNeedsValidation:function(a,b){return this._tags[a]&&((this._tags[a]["attributes"]&&this._tags[a]["attributes"][b])||(this._tags[a]["required"]&&WYMeditor.Helper.contains(this._tags[a]["required"],b)))},validateAttribute:function(a,b,c){if(this._tags[a]&&(this._tags[a]["attributes"]&&this._tags[a]["attributes"][b]&&c.length>0&&!c.match(this._tags[a]["attributes"][b]))||(this._tags[a]&&this._tags[a]["required"]&&WYMeditor.Helper.contains(this._tags[a]["required"],b)&&c.length==0)){return false}return typeof this._tags[a]!="undefined"},getPossibleTagAttributes:function(a){if(!this._possible_tag_attributes){this._possible_tag_attributes={}}if(!this._possible_tag_attributes[a]){this._possible_tag_attributes[a]=this.getUniqueAttributesAndEventsForTag(a).concat(this.getDefaultAttributesAndEventsForTag(a))}return this._possible_tag_attributes[a]}};WYMeditor.ParallelRegex=function(a){this._case=a;this._patterns=[];this._labels=[];this._regex=null;return this};WYMeditor.ParallelRegex.prototype.addPattern=function(c,a){a=a||true;var b=this._patterns.length;this._patterns[b]=c;this._labels[b]=a;this._regex=null};WYMeditor.ParallelRegex.prototype.match=function(c){if(this._patterns.length==0){return[false,""]}var d=c.match(this._getCompoundedRegex());if(!d){return[false,""]}var a=d[0];for(var b=1;b<d.length;b++){if(d[b]){return[this._labels[b-1],a]}}return[true,d[0]]};WYMeditor.ParallelRegex.prototype._getCompoundedRegex=function(){if(this._regex==null){for(var a=0,b=this._patterns.length;a<b;a++){this._patterns[a]="("+this._untokenizeRegex(this._tokenizeRegex(this._patterns[a]).replace(/([\/\(\)])/g,"\\$1"))+")"}this._regex=new RegExp(this._patterns.join("|"),this._getPerlMatchingFlags())}return this._regex};WYMeditor.ParallelRegex.prototype._tokenizeRegex=function(a){return a.replace(/\(\?(i|m|s|x|U)\)/,"~~~~~~Tk1$1~~~~~~").replace(/\(\?(\-[i|m|s|x|U])\)/,"~~~~~~Tk2$1~~~~~~").replace(/\(\?\=(.*)\)/,"~~~~~~Tk3$1~~~~~~").replace(/\(\?\!(.*)\)/,"~~~~~~Tk4$1~~~~~~").replace(/\(\?\<\=(.*)\)/,"~~~~~~Tk5$1~~~~~~").replace(/\(\?\<\!(.*)\)/,"~~~~~~Tk6$1~~~~~~").replace(/\(\?\:(.*)\)/,"~~~~~~Tk7$1~~~~~~")};WYMeditor.ParallelRegex.prototype._untokenizeRegex=function(a){return a.replace(/~~~~~~Tk1(.{1})~~~~~~/,"(?$1)").replace(/~~~~~~Tk2(.{2})~~~~~~/,"(?$1)").replace(/~~~~~~Tk3(.*)~~~~~~/,"(?=$1)").replace(/~~~~~~Tk4(.*)~~~~~~/,"(?!$1)").replace(/~~~~~~Tk5(.*)~~~~~~/,"(?<=$1)").replace(/~~~~~~Tk6(.*)~~~~~~/,"(?<!$1)").replace(/~~~~~~Tk7(.*)~~~~~~/,"(?:$1)")};WYMeditor.ParallelRegex.prototype._getPerlMatchingFlags=function(){return(this._case?"m":"mi")};WYMeditor.StateStack=function(a){this._stack=[a];return this};WYMeditor.StateStack.prototype.getCurrent=function(){return this._stack[this._stack.length-1]};WYMeditor.StateStack.prototype.enter=function(a){this._stack.push(a)};WYMeditor.StateStack.prototype.leave=function(){if(this._stack.length==1){return false}this._stack.pop();return true};WYMeditor.LEXER_ENTER=1;WYMeditor.LEXER_MATCHED=2;WYMeditor.LEXER_UNMATCHED=3;WYMeditor.LEXER_EXIT=4;WYMeditor.LEXER_SPECIAL=5;WYMeditor.Lexer=function(c,b,a){b=b||"accept";this._case=a||false;this._regexes={};this._parser=c;this._mode=new WYMeditor.StateStack(b);this._mode_handlers={};this._mode_handlers[b]=b;return this};WYMeditor.Lexer.prototype.addPattern=function(a,b){var b=b||"accept";if(typeof this._regexes[b]=="undefined"){this._regexes[b]=new WYMeditor.ParallelRegex(this._case)}this._regexes[b].addPattern(a);if(typeof this._mode_handlers[b]=="undefined"){this._mode_handlers[b]=b}};WYMeditor.Lexer.prototype.addEntryPattern=function(b,c,a){if(typeof this._regexes[c]=="undefined"){this._regexes[c]=new WYMeditor.ParallelRegex(this._case)}this._regexes[c].addPattern(b,a);if(typeof this._mode_handlers[a]=="undefined"){this._mode_handlers[a]=a}};WYMeditor.Lexer.prototype.addExitPattern=function(a,b){if(typeof this._regexes[b]=="undefined"){this._regexes[b]=new WYMeditor.ParallelRegex(this._case)}this._regexes[b].addPattern(a,"__exit");if(typeof this._mode_handlers[b]=="undefined"){this._mode_handlers[b]=b}};WYMeditor.Lexer.prototype.addSpecialPattern=function(b,c,a){if(typeof this._regexes[c]=="undefined"){this._regexes[c]=new WYMeditor.ParallelRegex(this._case)}this._regexes[c].addPattern(b,"_"+a);if(typeof this._mode_handlers[a]=="undefined"){this._mode_handlers[a]=a}};WYMeditor.Lexer.prototype.mapHandler=function(b,a){this._mode_handlers[b]=a};WYMeditor.Lexer.prototype.parse=function(d){if(typeof this._parser=="undefined"){return false}var e=d.length;var c;while(typeof(c=this._reduce(d))=="object"){var d=c[0];var b=c[1];var a=c[2];var f=c[3];if(!this._dispatchTokens(b,a,f)){return false}if(d==""){return true}if(d.length==e){return false}e=d.length}if(!c){return false}return this._invokeParser(d,WYMeditor.LEXER_UNMATCHED)};WYMeditor.Lexer.prototype._dispatchTokens=function(b,a,c){c=c||false;if(!this._invokeParser(b,WYMeditor.LEXER_UNMATCHED)){return false}if(typeof c=="boolean"){return this._invokeParser(a,WYMeditor.LEXER_MATCHED)}if(this._isModeEnd(c)){if(!this._invokeParser(a,WYMeditor.LEXER_EXIT)){return false}return this._mode.leave()}if(this._isSpecialMode(c)){this._mode.enter(this._decodeSpecial(c));if(!this._invokeParser(a,WYMeditor.LEXER_SPECIAL)){return false}return this._mode.leave()}this._mode.enter(c);return this._invokeParser(a,WYMeditor.LEXER_ENTER)};WYMeditor.Lexer.prototype._isModeEnd=function(a){return(a==="__exit")};WYMeditor.Lexer.prototype._isSpecialMode=function(a){return(a.substring(0,1)=="_")};WYMeditor.Lexer.prototype._decodeSpecial=function(a){return a.substring(1)};WYMeditor.Lexer.prototype._invokeParser=function(content,is_match){if(content===""){return true}var current=this._mode.getCurrent();var handler=this._mode_handlers[current];var result;eval("result = this._parser."+handler+"(content, is_match);");return result};WYMeditor.Lexer.prototype._reduce=function(c){var a=this._regexes[this._mode.getCurrent()].match(c);var b=a[1];var e=a[0];if(e){var f=c.indexOf(b);var d=c.substr(0,f);c=c.substring(f+b.length);return[c,d,b,e]}return true};WYMeditor.XhtmlLexer=function(a){jQuery.extend(this,new WYMeditor.Lexer(a,"Text"));this.mapHandler("Text","Text");this.addTokens();this.init();return this};WYMeditor.XhtmlLexer.prototype.init=function(){};WYMeditor.XhtmlLexer.prototype.addTokens=function(){this.addCommentTokens("Text");this.addScriptTokens("Text");this.addCssTokens("Text");this.addTagTokens("Text")};WYMeditor.XhtmlLexer.prototype.addCommentTokens=function(a){this.addEntryPattern("<!--",a,"Comment");this.addExitPattern("-->","Comment")};WYMeditor.XhtmlLexer.prototype.addScriptTokens=function(a){this.addEntryPattern("<script",a,"Script");this.addExitPattern("<\/script>","Script")};WYMeditor.XhtmlLexer.prototype.addCssTokens=function(a){this.addEntryPattern("<style",a,"Css");this.addExitPattern("</style>","Css")};WYMeditor.XhtmlLexer.prototype.addTagTokens=function(a){this.addSpecialPattern("<\\s*[a-z0-9:-]+\\s*>",a,"OpeningTag");this.addEntryPattern("<[a-z0-9:-]+[\\/ \\>]+",a,"OpeningTag");this.addInTagDeclarationTokens("OpeningTag");this.addSpecialPattern("</\\s*[a-z0-9:-]+\\s*>",a,"ClosingTag")};WYMeditor.XhtmlLexer.prototype.addInTagDeclarationTokens=function(a){this.addSpecialPattern("\\s+",a,"Ignore");this.addAttributeTokens(a);this.addExitPattern("/>",a);this.addExitPattern(">",a)};WYMeditor.XhtmlLexer.prototype.addAttributeTokens=function(a){this.addSpecialPattern("\\s*[a-z-_0-9]*:?[a-z-_0-9]+\\s*(?==)\\s*",a,"TagAttributes");this.addEntryPattern('=\\s*"',a,"DoubleQuotedAttribute");this.addPattern('\\\\"',"DoubleQuotedAttribute");this.addExitPattern('"',"DoubleQuotedAttribute");this.addEntryPattern("=\\s*'",a,"SingleQuotedAttribute");this.addPattern("\\\\'","SingleQuotedAttribute");this.addExitPattern("'","SingleQuotedAttribute");this.addSpecialPattern("=\\s*[^>\\s]*",a,"UnquotedAttribute")};WYMeditor.XhtmlParser=function(a,b){var b=b||"Text";this._Lexer=new WYMeditor.XhtmlLexer(this);this._Listener=a;this._mode=b;this._matches=[];this._last_match="";this._current_match="";return this};WYMeditor.XhtmlParser.prototype.parse=function(a){this._Lexer.parse(this.beforeParsing(a));return this.afterParsing(this._Listener.getResult())};WYMeditor.XhtmlParser.prototype.beforeParsing=function(a){if(a.match(/class="MsoNormal"/)||a.match(/ns = "urn:schemas-microsoft-com/)){this._Listener.avoidStylingTagsAndAttributes()}return this._Listener.beforeParsing(a)};WYMeditor.XhtmlParser.prototype.afterParsing=function(a){if(this._Listener._avoiding_tags_implicitly){this._Listener.allowStylingTagsAndAttributes()}return this._Listener.afterParsing(a)};WYMeditor.XhtmlParser.prototype.Ignore=function(a,b){return true};WYMeditor.XhtmlParser.prototype.Text=function(a){this._Listener.addContent(a);return true};WYMeditor.XhtmlParser.prototype.Comment=function(b,a){return this._addNonTagBlock(b,a,"addComment")};WYMeditor.XhtmlParser.prototype.Script=function(b,a){return this._addNonTagBlock(b,a,"addScript")};WYMeditor.XhtmlParser.prototype.Css=function(b,a){return this._addNonTagBlock(b,a,"addCss")};WYMeditor.XhtmlParser.prototype._addNonTagBlock=function(a,c,b){switch(c){case WYMeditor.LEXER_ENTER:this._non_tag=a;break;case WYMeditor.LEXER_UNMATCHED:this._non_tag+=a;break;case WYMeditor.LEXER_EXIT:switch(b){case"addComment":this._Listener.addComment(this._non_tag+a);break;case"addScript":this._Listener.addScript(this._non_tag+a);break;case"addCss":this._Listener.addCss(this._non_tag+a);break}}return true};WYMeditor.XhtmlParser.prototype.OpeningTag=function(a,b){switch(b){case WYMeditor.LEXER_ENTER:this._tag=this.normalizeTag(a);this._tag_attributes={};break;case WYMeditor.LEXER_SPECIAL:this._callOpenTagListener(this.normalizeTag(a));break;case WYMeditor.LEXER_EXIT:this._callOpenTagListener(this._tag,this._tag_attributes)}return true};WYMeditor.XhtmlParser.prototype.ClosingTag=function(a,b){this._callCloseTagListener(this.normalizeTag(a));return true};WYMeditor.XhtmlParser.prototype._callOpenTagListener=function(a,b){var b=b||{};this.autoCloseUnclosedBeforeNewOpening(a);if(this._Listener.isBlockTag(a)){this._Listener._tag_stack.push(a);this._Listener.fixNestingBeforeOpeningBlockTag(a,b);this._Listener.openBlockTag(a,b);this._increaseOpenTagCounter(a)}else{if(this._Listener.isInlineTag(a)){this._Listener.inlineTag(a,b)}else{this._Listener.openUnknownTag(a,b);this._increaseOpenTagCounter(a)}}this._Listener.last_tag=a;this._Listener.last_tag_opened=true;this._Listener.last_tag_attributes=b};WYMeditor.XhtmlParser.prototype._callCloseTagListener=function(a){if(this._decreaseOpenTagCounter(a)){this.autoCloseUnclosedBeforeTagClosing(a);if(this._Listener.isBlockTag(a)){var b=this._Listener._tag_stack.pop();if(b==false){return}else{if(b!=a){a=b}}this._Listener.closeBlockTag(a)}else{this._Listener.closeUnknownTag(a)}}else{this._Listener.closeUnopenedTag(a)}this._Listener.last_tag=a;this._Listener.last_tag_opened=false};WYMeditor.XhtmlParser.prototype._increaseOpenTagCounter=function(a){this._Listener._open_tags[a]=this._Listener._open_tags[a]||0;this._Listener._open_tags[a]++};WYMeditor.XhtmlParser.prototype._decreaseOpenTagCounter=function(a){if(this._Listener._open_tags[a]){this._Listener._open_tags[a]--;if(this._Listener._open_tags[a]==0){this._Listener._open_tags[a]=undefined}return true}return false};WYMeditor.XhtmlParser.prototype.autoCloseUnclosedBeforeNewOpening=function(a){this._autoCloseUnclosed(a,false)};WYMeditor.XhtmlParser.prototype.autoCloseUnclosedBeforeTagClosing=function(a){this._autoCloseUnclosed(a,true)};WYMeditor.XhtmlParser.prototype._autoCloseUnclosed=function(c,d){var d=d||false;if(this._Listener._open_tags){for(var a in this._Listener._open_tags){var b=this._Listener._open_tags[a];if(b>0&&this._Listener.shouldCloseTagAutomatically(a,c,d)){this._callCloseTagListener(a,true)}}}};WYMeditor.XhtmlParser.prototype.getTagReplacements=function(){return this._Listener.getTagReplacements()};WYMeditor.XhtmlParser.prototype.normalizeTag=function(a){a=a.replace(/^([\s<\/>]*)|([\s<\/>]*)$/gm,"").toLowerCase();var b=this._Listener.getTagReplacements();if(b[a]){return b[a]}return a};WYMeditor.XhtmlParser.prototype.TagAttributes=function(a,b){if(WYMeditor.LEXER_SPECIAL==b){this._current_attribute=a}return true};WYMeditor.XhtmlParser.prototype.DoubleQuotedAttribute=function(a,b){if(WYMeditor.LEXER_UNMATCHED==b){this._tag_attributes[this._current_attribute]=a}return true};WYMeditor.XhtmlParser.prototype.SingleQuotedAttribute=function(a,b){if(WYMeditor.LEXER_UNMATCHED==b){this._tag_attributes[this._current_attribute]=a}return true};WYMeditor.XhtmlParser.prototype.UnquotedAttribute=function(a,b){this._tag_attributes[this._current_attribute]=a.replace(/^=/,"");return true};WYMeditor.XhtmlSaxListener=function(){this.output="";this.helper=new WYMeditor.XmlHelper();this._open_tags={};this.validator=WYMeditor.XhtmlValidator;this._tag_stack=[];this.avoided_tags=[];this.entities={"&nbsp;":"&#160;","&iexcl;":"&#161;","&cent;":"&#162;","&pound;":"&#163;","&curren;":"&#164;","&yen;":"&#165;","&brvbar;":"&#166;","&sect;":"&#167;","&uml;":"&#168;","&copy;":"&#169;","&ordf;":"&#170;","&laquo;":"&#171;","&not;":"&#172;","&shy;":"&#173;","&reg;":"&#174;","&macr;":"&#175;","&deg;":"&#176;","&plusmn;":"&#177;","&sup2;":"&#178;","&sup3;":"&#179;","&acute;":"&#180;","&micro;":"&#181;","&para;":"&#182;","&middot;":"&#183;","&cedil;":"&#184;","&sup1;":"&#185;","&ordm;":"&#186;","&raquo;":"&#187;","&frac14;":"&#188;","&frac12;":"&#189;","&frac34;":"&#190;","&iquest;":"&#191;","&Agrave;":"&#192;","&Aacute;":"&#193;","&Acirc;":"&#194;","&Atilde;":"&#195;","&Auml;":"&#196;","&Aring;":"&#197;","&AElig;":"&#198;","&Ccedil;":"&#199;","&Egrave;":"&#200;","&Eacute;":"&#201;","&Ecirc;":"&#202;","&Euml;":"&#203;","&Igrave;":"&#204;","&Iacute;":"&#205;","&Icirc;":"&#206;","&Iuml;":"&#207;","&ETH;":"&#208;","&Ntilde;":"&#209;","&Ograve;":"&#210;","&Oacute;":"&#211;","&Ocirc;":"&#212;","&Otilde;":"&#213;","&Ouml;":"&#214;","&times;":"&#215;","&Oslash;":"&#216;","&Ugrave;":"&#217;","&Uacute;":"&#218;","&Ucirc;":"&#219;","&Uuml;":"&#220;","&Yacute;":"&#221;","&THORN;":"&#222;","&szlig;":"&#223;","&agrave;":"&#224;","&aacute;":"&#225;","&acirc;":"&#226;","&atilde;":"&#227;","&auml;":"&#228;","&aring;":"&#229;","&aelig;":"&#230;","&ccedil;":"&#231;","&egrave;":"&#232;","&eacute;":"&#233;","&ecirc;":"&#234;","&euml;":"&#235;","&igrave;":"&#236;","&iacute;":"&#237;","&icirc;":"&#238;","&iuml;":"&#239;","&eth;":"&#240;","&ntilde;":"&#241;","&ograve;":"&#242;","&oacute;":"&#243;","&ocirc;":"&#244;","&otilde;":"&#245;","&ouml;":"&#246;","&divide;":"&#247;","&oslash;":"&#248;","&ugrave;":"&#249;","&uacute;":"&#250;","&ucirc;":"&#251;","&uuml;":"&#252;","&yacute;":"&#253;","&thorn;":"&#254;","&yuml;":"&#255;","&OElig;":"&#338;","&oelig;":"&#339;","&Scaron;":"&#352;","&scaron;":"&#353;","&Yuml;":"&#376;","&fnof;":"&#402;","&circ;":"&#710;","&tilde;":"&#732;","&Alpha;":"&#913;","&Beta;":"&#914;","&Gamma;":"&#915;","&Delta;":"&#916;","&Epsilon;":"&#917;","&Zeta;":"&#918;","&Eta;":"&#919;","&Theta;":"&#920;","&Iota;":"&#921;","&Kappa;":"&#922;","&Lambda;":"&#923;","&Mu;":"&#924;","&Nu;":"&#925;","&Xi;":"&#926;","&Omicron;":"&#927;","&Pi;":"&#928;","&Rho;":"&#929;","&Sigma;":"&#931;","&Tau;":"&#932;","&Upsilon;":"&#933;","&Phi;":"&#934;","&Chi;":"&#935;","&Psi;":"&#936;","&Omega;":"&#937;","&alpha;":"&#945;","&beta;":"&#946;","&gamma;":"&#947;","&delta;":"&#948;","&epsilon;":"&#949;","&zeta;":"&#950;","&eta;":"&#951;","&theta;":"&#952;","&iota;":"&#953;","&kappa;":"&#954;","&lambda;":"&#955;","&mu;":"&#956;","&nu;":"&#957;","&xi;":"&#958;","&omicron;":"&#959;","&pi;":"&#960;","&rho;":"&#961;","&sigmaf;":"&#962;","&sigma;":"&#963;","&tau;":"&#964;","&upsilon;":"&#965;","&phi;":"&#966;","&chi;":"&#967;","&psi;":"&#968;","&omega;":"&#969;","&thetasym;":"&#977;","&upsih;":"&#978;","&piv;":"&#982;","&ensp;":"&#8194;","&emsp;":"&#8195;","&thinsp;":"&#8201;","&zwnj;":"&#8204;","&zwj;":"&#8205;","&lrm;":"&#8206;","&rlm;":"&#8207;","&ndash;":"&#8211;","&mdash;":"&#8212;","&lsquo;":"&#8216;","&rsquo;":"&#8217;","&sbquo;":"&#8218;","&ldquo;":"&#8220;","&rdquo;":"&#8221;","&bdquo;":"&#8222;","&dagger;":"&#8224;","&Dagger;":"&#8225;","&bull;":"&#8226;","&hellip;":"&#8230;","&permil;":"&#8240;","&prime;":"&#8242;","&Prime;":"&#8243;","&lsaquo;":"&#8249;","&rsaquo;":"&#8250;","&oline;":"&#8254;","&frasl;":"&#8260;","&euro;":"&#8364;","&image;":"&#8465;","&weierp;":"&#8472;","&real;":"&#8476;","&trade;":"&#8482;","&alefsym;":"&#8501;","&larr;":"&#8592;","&uarr;":"&#8593;","&rarr;":"&#8594;","&darr;":"&#8595;","&harr;":"&#8596;","&crarr;":"&#8629;","&lArr;":"&#8656;","&uArr;":"&#8657;","&rArr;":"&#8658;","&dArr;":"&#8659;","&hArr;":"&#8660;","&forall;":"&#8704;","&part;":"&#8706;","&exist;":"&#8707;","&empty;":"&#8709;","&nabla;":"&#8711;","&isin;":"&#8712;","&notin;":"&#8713;","&ni;":"&#8715;","&prod;":"&#8719;","&sum;":"&#8721;","&minus;":"&#8722;","&lowast;":"&#8727;","&radic;":"&#8730;","&prop;":"&#8733;","&infin;":"&#8734;","&ang;":"&#8736;","&and;":"&#8743;","&or;":"&#8744;","&cap;":"&#8745;","&cup;":"&#8746;","&int;":"&#8747;","&there4;":"&#8756;","&sim;":"&#8764;","&cong;":"&#8773;","&asymp;":"&#8776;","&ne;":"&#8800;","&equiv;":"&#8801;","&le;":"&#8804;","&ge;":"&#8805;","&sub;":"&#8834;","&sup;":"&#8835;","&nsub;":"&#8836;","&sube;":"&#8838;","&supe;":"&#8839;","&oplus;":"&#8853;","&otimes;":"&#8855;","&perp;":"&#8869;","&sdot;":"&#8901;","&lceil;":"&#8968;","&rceil;":"&#8969;","&lfloor;":"&#8970;","&rfloor;":"&#8971;","&lang;":"&#9001;","&rang;":"&#9002;","&loz;":"&#9674;","&spades;":"&#9824;","&clubs;":"&#9827;","&hearts;":"&#9829;","&diams;":"&#9830;"};this.block_tags=["a","abbr","acronym","address","area","b","base","bdo","big","blockquote","body","button","caption","cite","code","col","colgroup","dd","del","div","dfn","dl","dt","em","fieldset","form","head","h1","h2","h3","h4","h5","h6","html","i","ins","kbd","label","legend","li","map","noscript","object","ol","optgroup","option","p","param","pre","q","samp","script","select","small","span","strong","style","sub","sup","table","tbody","td","textarea","tfoot","th","thead","title","tr","tt","ul","var","extends"];this.inline_tags=["br","hr","img","input"];return this};WYMeditor.XhtmlSaxListener.prototype.shouldCloseTagAutomatically=function(a,c,b){var b=b||false;if(a=="td"){if((b&&c=="tr")||(!b&&c=="td")){return true}}if(a=="option"){if((b&&c=="select")||(!b&&c=="option")){return true}}return false};WYMeditor.XhtmlSaxListener.prototype.beforeParsing=function(a){this.output="";return a};WYMeditor.XhtmlSaxListener.prototype.afterParsing=function(a){a=this.replaceNamedEntities(a);a=this.joinRepeatedEntities(a);a=this.removeEmptyTags(a);a=this.removeBrInPre(a);return a};WYMeditor.XhtmlSaxListener.prototype.replaceNamedEntities=function(b){for(var a in this.entities){b=b.replace(new RegExp(a,"g"),this.entities[a])}return b};WYMeditor.XhtmlSaxListener.prototype.joinRepeatedEntities=function(b){var a="em|strong|sub|sup|acronym|pre|del|address";return b.replace(new RegExp("</("+a+")><\\1>",""),"").replace(new RegExp("(s*<("+a+")>s*){2}(.*)(s*</\\2>s*){2}",""),"<$2>$3<$2>")};WYMeditor.XhtmlSaxListener.prototype.removeEmptyTags=function(a){return a.replace(new RegExp("<("+this.block_tags.join("|").replace(/\|td/,"").replace(/\|th/,"")+")>(<br />|&#160;|&nbsp;|\\s)*</\\1>","g"),"")};WYMeditor.XhtmlSaxListener.prototype.removeBrInPre=function(c){var b=c.match(new RegExp("<pre[^>]*>(.*?)</pre>","gmi"));if(b){for(var a=0;a<b.length;a++){c=c.replace(b[a],b[a].replace(new RegExp("<br />","g"),String.fromCharCode(13,10)))}}return c};WYMeditor.XhtmlSaxListener.prototype.getResult=function(){return this.output};WYMeditor.XhtmlSaxListener.prototype.getTagReplacements=function(){return{b:"strong",i:"em"}};WYMeditor.XhtmlSaxListener.prototype.addContent=function(a){this.output+=a};WYMeditor.XhtmlSaxListener.prototype.addComment=function(a){if(this.remove_comments){this.output+=a}};WYMeditor.XhtmlSaxListener.prototype.addScript=function(a){if(!this.remove_scripts){this.output+=a}};WYMeditor.XhtmlSaxListener.prototype.addCss=function(a){if(!this.remove_embeded_styles){this.output+=a}};WYMeditor.XhtmlSaxListener.prototype.openBlockTag=function(a,b){this.output+=this.helper.tag(a,this.validator.getValidTagAttributes(a,b),true)};WYMeditor.XhtmlSaxListener.prototype.inlineTag=function(a,b){this.output+=this.helper.tag(a,this.validator.getValidTagAttributes(a,b))};WYMeditor.XhtmlSaxListener.prototype.openUnknownTag=function(a,b){};WYMeditor.XhtmlSaxListener.prototype.closeBlockTag=function(a){this.output=this.output.replace(/<br \/>$/,"")+this._getClosingTagContent("before",a)+"</"+a+">"+this._getClosingTagContent("after",a)};WYMeditor.XhtmlSaxListener.prototype.closeUnknownTag=function(a){};WYMeditor.XhtmlSaxListener.prototype.closeUnopenedTag=function(a){this.output+="</"+a+">"};WYMeditor.XhtmlSaxListener.prototype.avoidStylingTagsAndAttributes=function(){this.avoided_tags=["div","span"];this.validator.skiped_attributes=["style"];this.validator.skiped_attribute_values=["MsoNormal","main1"];this._avoiding_tags_implicitly=true};WYMeditor.XhtmlSaxListener.prototype.allowStylingTagsAndAttributes=function(){this.avoided_tags=[];this.validator.skiped_attributes=[];this.validator.skiped_attribute_values=[];this._avoiding_tags_implicitly=false};WYMeditor.XhtmlSaxListener.prototype.isBlockTag=function(a){return !WYMeditor.Helper.contains(this.avoided_tags,a)&&WYMeditor.Helper.contains(this.block_tags,a)};WYMeditor.XhtmlSaxListener.prototype.isInlineTag=function(a){return !WYMeditor.Helper.contains(this.avoided_tags,a)&&WYMeditor.Helper.contains(this.inline_tags,a)};WYMeditor.XhtmlSaxListener.prototype.insertContentAfterClosingTag=function(a,b){this._insertContentWhenClosingTag("after",a,b)};WYMeditor.XhtmlSaxListener.prototype.insertContentBeforeClosingTag=function(a,b){this._insertContentWhenClosingTag("before",a,b)};WYMeditor.XhtmlSaxListener.prototype.fixNestingBeforeOpeningBlockTag=function(a,b){if(a!="li"&&(a=="ul"||a=="ol")&&this.last_tag&&!this.last_tag_opened&&this.last_tag=="li"){this.output=this.output.replace(/<\/li>$/,"");this.insertContentAfterClosingTag(a,"</li>")}};WYMeditor.XhtmlSaxListener.prototype._insertContentWhenClosingTag=function(b,a,c){if(!this["_insert_"+b+"_closing"]){this["_insert_"+b+"_closing"]=[]}if(!this["_insert_"+b+"_closing"][a]){this["_insert_"+b+"_closing"][a]=[]}this["_insert_"+b+"_closing"][a].push(c)};WYMeditor.XhtmlSaxListener.prototype._getClosingTagContent=function(b,a){if(this["_insert_"+b+"_closing"]&&this["_insert_"+b+"_closing"][a]&&this["_insert_"+b+"_closing"][a].length>0){return this["_insert_"+b+"_closing"][a].pop()}return""};WYMeditor.WymCssLexer=function(b,a){var a=(typeof a=="undefined"?true:a);jQuery.extend(this,new WYMeditor.Lexer(b,(a?"Ignore":"WymCss")));this.mapHandler("WymCss","Ignore");if(a==true){this.addEntryPattern("/\\\x2a[<\\s]*WYMeditor[>\\s]*\\\x2a/","Ignore","WymCss");this.addExitPattern("/\\\x2a[</\\s]*WYMeditor[>\\s]*\\\x2a/","WymCss")}this.addSpecialPattern("[\\sa-z1-6]*\\\x2e[a-z-_0-9]+","WymCss","WymCssStyleDeclaration");this.addEntryPattern("/\\\x2a","WymCss","WymCssComment");this.addExitPattern("\\\x2a/","WymCssComment");this.addEntryPattern("\x7b","WymCss","WymCssStyle");this.addExitPattern("\x7d","WymCssStyle");this.addEntryPattern("/\\\x2a","WymCssStyle","WymCssFeedbackStyle");this.addExitPattern("\\\x2a/","WymCssFeedbackStyle");return this};WYMeditor.WymCssParser=function(){this._in_style=false;this._has_title=false;this.only_wym_blocks=true;this.css_settings={classesItems:[],editorStyles:[],dialogStyles:[]};return this};WYMeditor.WymCssParser.prototype.parse=function(a,b){var b=(typeof b=="undefined"?this.only_wym_blocks:b);this._Lexer=new WYMeditor.WymCssLexer(this,b);this._Lexer.parse(a)};WYMeditor.WymCssParser.prototype.Ignore=function(a,b){return true};WYMeditor.WymCssParser.prototype.WymCssComment=function(b,a){if(b.match(/end[a-z0-9\s]*wym[a-z0-9\s]*/mi)){return false}if(a==WYMeditor.LEXER_UNMATCHED){if(!this._in_style){this._has_title=true;this._current_item={title:WYMeditor.Helper.trim(b)}}else{if(this._current_item[this._current_element]){if(!this._current_item[this._current_element].expressions){this._current_item[this._current_element].expressions=[b]}else{this._current_item[this._current_element].expressions.push(b)}}}this._in_style=true}return true};WYMeditor.WymCssParser.prototype.WymCssStyle=function(b,a){if(a==WYMeditor.LEXER_UNMATCHED){b=WYMeditor.Helper.trim(b);if(b!=""){this._current_item[this._current_element].style=b}}else{if(a==WYMeditor.LEXER_EXIT){this._in_style=false;this._has_title=false;this.addStyleSetting(this._current_item)}}return true};WYMeditor.WymCssParser.prototype.WymCssFeedbackStyle=function(b,a){if(a==WYMeditor.LEXER_UNMATCHED){this._current_item[this._current_element].feedback_style=b.replace(/^([\s\/\*]*)|([\s\/\*]*)$/gm,"")}return true};WYMeditor.WymCssParser.prototype.WymCssStyleDeclaration=function(b){b=b.replace(/^([\s\.]*)|([\s\.*]*)$/gm,"");var a="";if(b.indexOf(".")>0){var c=b.split(".");this._current_element=c[1];var a=c[0]}else{this._current_element=b}if(!this._has_title){this._current_item={title:(!a?"":a.toUpperCase()+": ")+this._current_element};this._has_title=true}if(!this._current_item[this._current_element]){this._current_item[this._current_element]={name:this._current_element}}if(a){if(!this._current_item[this._current_element].tags){this._current_item[this._current_element].tags=[a]}else{this._current_item[this._current_element].tags.push(a)}}return true};WYMeditor.WymCssParser.prototype.addStyleSetting=function(a){for(var b in a){var c=a[b];if(typeof c=="object"&&b!="title"){this.css_settings.classesItems.push({name:WYMeditor.Helper.trim(c.name),title:a.title,expr:WYMeditor.Helper.trim((c.expressions||c.tags).join(", "))});if(c.feedback_style){this.css_settings.editorStyles.push({name:"."+WYMeditor.Helper.trim(c.name),css:c.feedback_style})}if(c.style){this.css_settings.dialogStyles.push({name:"."+WYMeditor.Helper.trim(c.name),css:c.style})}}}};jQuery.fn.isPhantomNode=function(){if(this[0].nodeType==3){return !(/[^\t\n\r ]/.test(this[0].data))}return false};WYMeditor.isPhantomNode=function(a){if(a.nodeType==3){return !(/[^\t\n\r ]/.test(a.data))}return false};WYMeditor.isPhantomString=function(a){return !(/[^\t\n\r ]/.test(a))};jQuery.fn.parentsOrSelf=function(b){var a=this;if(a[0].nodeType==3){a=a.parents().slice(0,1)}if(a.filter(b).size()==1){return a}else{return a.parents(b).slice(0,1)}};WYMeditor.Helper={replaceAll:function(d,a,c){var b=new RegExp(a,"g");return(d.replace(b,c))},insertAt:function(b,a,c){return(b.substr(0,c)+a+b.substring(c))},trim:function(a){return a.replace(/^(\s*)|(\s*)$/gm,"")},contains:function(a,c){for(var b=0;b<a.length;b++){if(a[b]===c){return true}}return false},indexOf:function(a,d){var b=-1;for(var c=0;c<a.length;c++){if(a[c]==d){b=c;break}}return(b)},findByName:function(a,b){for(var c=0;c<a.length;c++){var d=a[c];if(d.name==b){return(d)}}return(null)}};WYMeditor.WymClassExplorer=function(a){this._wym=a;this._class="className";this._newLine="\r\n"};WYMeditor.WymClassExplorer.prototype.initIframe=function(iframe){this._iframe=iframe;this._doc=iframe.contentWindow.document;var styles=this._doc.styleSheets[0];var aCss=eval(this._options.editorStyles);this.addCssRules(this._doc,aCss);this._doc.title=this._wym._index;jQuery("html",this._doc).attr("dir",this._options.direction);jQuery(this._doc.body).html(this._wym._html);var wym=this;this._doc.body.onfocus=function(){wym._doc.designMode="on";wym._doc=iframe.contentWindow.document};this._doc.onbeforedeactivate=function(){wym.saveCaret()};this._doc.onkeyup=function(){wym.saveCaret();wym.keyup()};this._doc.onclick=function(){wym.saveCaret()};this._doc.body.onbeforepaste=function(){wym._iframe.contentWindow.event.returnValue=false};this._doc.body.onpaste=function(){wym._iframe.contentWindow.event.returnValue=false;wym.paste(window.clipboardData.getData("Text"))};if(this._initialized){if(jQuery.isFunction(this._options.preBind)){this._options.preBind(this)}this._wym.bindEvents();if(jQuery.isFunction(this._options.postInit)){this._options.postInit(this)}this.listen()}this._initialized=true;this._doc.designMode="on";try{this._doc=iframe.contentWindow.document}catch(e){}};WYMeditor.WymClassExplorer.prototype._exec=function(c,d){switch(c){case WYMeditor.INDENT:case WYMeditor.OUTDENT:var a=this.findUp(this.container(),WYMeditor.LI);if(a){var b=a.parentNode.parentNode;if(a.parentNode.childNodes.length>1||b.tagName.toLowerCase()==WYMeditor.OL||b.tagName.toLowerCase()==WYMeditor.UL){this._doc.execCommand(c)}}break;default:if(d){this._doc.execCommand(c,false,d)}else{this._doc.execCommand(c)}break}};WYMeditor.WymClassExplorer.prototype.selected=function(){var a=this._iframe.contentWindow.document.caretPos;if(a!=null){if(a.parentElement!=undefined){return(a.parentElement())}}};WYMeditor.WymClassExplorer.prototype.saveCaret=function(){this._doc.caretPos=this._doc.selection.createRange()};WYMeditor.WymClassExplorer.prototype.addCssRule=function(a,b){a.addRule(b.name,b.css)};WYMeditor.WymClassExplorer.prototype.insert=function(b){var a=this._doc.selection.createRange();if(jQuery(a.parentElement()).parents(this._options.iframeBodySelector).is("*")){try{a.pasteHTML(b)}catch(c){}}else{this.paste(b)}};WYMeditor.WymClassExplorer.prototype.wrap=function(d,b){var a=this._doc.selection.createRange();if(jQuery(a.parentElement()).parents(this._options.iframeBodySelector).is("*")){try{a.pasteHTML(d+a.text+b)}catch(c){}}};WYMeditor.WymClassExplorer.prototype.unwrap=function(){var a=this._doc.selection.createRange();if(jQuery(a.parentElement()).parents(this._options.iframeBodySelector).is("*")){try{var c=a.text;this._exec("Cut");a.pasteHTML(c)}catch(b){}}};WYMeditor.WymClassExplorer.prototype.keyup=function(){this._selected_image=null};WYMeditor.WymClassExplorer.prototype.setFocusToNode=function(c,b){var a=this._doc.selection.createRange();b=b?true:false;a.moveToElementText(c);a.collapse(b);a.select();c.focus()};WYMeditor.WymClassMozilla=function(a){this._wym=a;this._class="class";this._newLine="\n"};WYMeditor.WymClassMozilla.prototype.initIframe=function(iframe){var wym=this;this._iframe=iframe;this._doc=iframe.contentDocument;var styles=this._doc.styleSheets[0];var aCss=eval(this._options.editorStyles);this.addCssRules(this._doc,aCss);this._doc.title=this._wym._index;jQuery("html",this._doc).attr("dir",this._options.direction);this.html(this._wym._html);this.enableDesignMode();if(jQuery.isFunction(this._options.preBind)){this._options.preBind(this)}this._wym.bindEvents();jQuery(this._doc).bind("keydown",this.keydown);jQuery(this._doc).bind("keyup",this.keyup);jQuery(this._doc).bind("focus",function(){wym.enableDesignMode.call(wym)});if(jQuery.isFunction(this._options.postInit)){this._options.postInit(this)}this.listen()};WYMeditor.WymClassMozilla.prototype.html=function(a){if(typeof a==="string"){try{this._doc.designMode="off"}catch(b){}a=a.replace(/<em(\b[^>]*)>/gi,"<i$1>").replace(/<\/em>/gi,"</i>").replace(/<strong(\b[^>]*)>/gi,"<b$1>").replace(/<\/strong>/gi,"</b>");jQuery(this._doc.body).html(a);this.enableDesignMode()}else{return(jQuery(this._doc.body).html())}};WYMeditor.WymClassMozilla.prototype._exec=function(e,g){if(!this.selected()){return(false)}switch(e){case WYMeditor.INDENT:case WYMeditor.OUTDENT:var f=this.selected();var d=this._iframe.contentWindow.getSelection();var b=d.anchorNode;if(b.nodeName=="#text"){b=b.parentNode}f=this.findUp(f,WYMeditor.BLOCKS);b=this.findUp(b,WYMeditor.BLOCKS);if(f&&f==b&&f.tagName.toLowerCase()==WYMeditor.LI){var c=f.parentNode.parentNode;if(f.parentNode.childNodes.length>1||c.tagName.toLowerCase()==WYMeditor.OL||c.tagName.toLowerCase()==WYMeditor.UL){this._doc.execCommand(e,"",null)}}break;default:if(g){this._doc.execCommand(e,"",g)}else{this._doc.execCommand(e,"",null)}}var a=this.selected();if(a.tagName.toLowerCase()==WYMeditor.BODY){this._exec(WYMeditor.FORMAT_BLOCK,WYMeditor.P)}};WYMeditor.WymClassMozilla.prototype.selected=function(){var b=this._iframe.contentWindow.getSelection();var a=b.focusNode;if(a){if(a.nodeName=="#text"){return(a.parentNode)}else{return(a)}}else{return(null)}};WYMeditor.WymClassMozilla.prototype.addCssRule=function(a,b){a.insertRule(b.name+" {"+b.css+"}",a.cssRules.length)};WYMeditor.WymClassMozilla.prototype.keydown=function(b){var c=WYMeditor.INSTANCES[this.title];var a=null;if(b.ctrlKey){if(b.keyCode==66){c._exec(WYMeditor.BOLD);return false}if(b.keyCode==73){c._exec(WYMeditor.ITALIC);return false}}else{if(b.keyCode==13){if(!b.shiftKey){a=c.selected();if(a&&a.tagName.toLowerCase()==WYMeditor.PRE){b.preventDefault();c.insert("<p></p>")}}}}};WYMeditor.WymClassMozilla.prototype.keyup=function(b){var d=WYMeditor.INSTANCES[this.title];d._selected_image=null;var a=null;if(b.keyCode==13&&!b.shiftKey){jQuery(d._doc.body).children(WYMeditor.BR).remove()}if(b.keyCode!=8&&b.keyCode!=17&&b.keyCode!=46&&b.keyCode!=224&&!b.metaKey&&!b.ctrlKey){a=d.selected();var c=a.tagName.toLowerCase();if(c=="strong"||c=="b"||c=="em"||c=="i"||c=="sub"||c=="sup"||c=="a"){c=a.parentNode.tagName.toLowerCase()}if(c==WYMeditor.BODY){d._exec(WYMeditor.FORMAT_BLOCK,WYMeditor.P)}}};WYMeditor.WymClassMozilla.prototype.enableDesignMode=function(){if(this._doc.designMode=="off"){try{this._doc.designMode="on";this._doc.execCommand("styleWithCSS","",false)}catch(a){}}};WYMeditor.WymClassMozilla.prototype.openBlockTag=function(a,c){var c=this.validator.getValidTagAttributes(a,c);if(a=="span"&&c.style){var b=this.getTagForStyle(c.style);if(b){this._tag_stack.pop();var a=b;this._tag_stack.push(b);c.style=""}else{return}}this.output+=this.helper.tag(a,c,true)};WYMeditor.WymClassMozilla.prototype.getTagForStyle=function(a){if(/bold/.test(a)){return"strong"}if(/italic/.test(a)){return"em"}if(/sub/.test(a)){return"sub"}if(/super/.test(a)){return"sup"}return false};WYMeditor.WymClassOpera=function(a){this._wym=a;this._class="class";this._newLine="\r\n"};WYMeditor.WymClassOpera.prototype.initIframe=function(iframe){this._iframe=iframe;this._doc=iframe.contentWindow.document;var styles=this._doc.styleSheets[0];var aCss=eval(this._options.editorStyles);this.addCssRules(this._doc,aCss);this._doc.title=this._wym._index;jQuery("html",this._doc).attr("dir",this._options.direction);this._doc.designMode="on";this.html(this._wym._html);if(jQuery.isFunction(this._options.preBind)){this._options.preBind(this)}this._wym.bindEvents();jQuery(this._doc).bind("keydown",this.keydown);jQuery(this._doc).bind("keyup",this.keyup);if(jQuery.isFunction(this._options.postInit)){this._options.postInit(this)}this.listen()};WYMeditor.WymClassOpera.prototype._exec=function(a,b){if(b){this._doc.execCommand(a,false,b)}else{this._doc.execCommand(a)}};WYMeditor.WymClassOpera.prototype.selected=function(){var b=this._iframe.contentWindow.getSelection();var a=b.focusNode;if(a){if(a.nodeName=="#text"){return(a.parentNode)}else{return(a)}}else{return(null)}};WYMeditor.WymClassOpera.prototype.addCssRule=function(a,b){a.insertRule(b.name+" {"+b.css+"}",a.cssRules.length)};WYMeditor.WymClassOpera.prototype.keydown=function(a){var c=WYMeditor.INSTANCES[this.title];var b=c._iframe.contentWindow.getSelection();startNode=b.getRangeAt(0).startContainer;if(!jQuery(startNode).parentsOrSelf(WYMeditor.MAIN_CONTAINERS.join(","))[0]&&!jQuery(startNode).parentsOrSelf("li")&&a.keyCode!=WYMeditor.KEY.ENTER&&a.keyCode!=WYMeditor.KEY.LEFT&&a.keyCode!=WYMeditor.KEY.UP&&a.keyCode!=WYMeditor.KEY.RIGHT&&a.keyCode!=WYMeditor.KEY.DOWN&&a.keyCode!=WYMeditor.KEY.BACKSPACE&&a.keyCode!=WYMeditor.KEY.DELETE){c._exec(WYMeditor.FORMAT_BLOCK,WYMeditor.P)}};WYMeditor.WymClassOpera.prototype.keyup=function(a){var b=WYMeditor.INSTANCES[this.title];b._selected_image=null};WYMeditor.WymClassSafari=function(a){this._wym=a;this._class="class";this._newLine="\n"};WYMeditor.WymClassSafari.prototype.initIframe=function(iframe){this._iframe=iframe;this._doc=iframe.contentDocument;var styles=this._doc.styleSheets[0];var aCss=eval(this._options.editorStyles);this.addCssRules(this._doc,aCss);this._doc.title=this._wym._index;jQuery("html",this._doc).attr("dir",this._options.direction);this._doc.designMode="on";this.html(this._wym._html);if(jQuery.isFunction(this._options.preBind)){this._options.preBind(this)}this._wym.bindEvents();jQuery(this._doc).bind("keydown",this.keydown);jQuery(this._doc).bind("keyup",this.keyup);if(jQuery.isFunction(this._options.postInit)){this._options.postInit(this)}this.listen()};WYMeditor.WymClassSafari.prototype._exec=function(e,g){if(!this.selected()){return(false)}switch(e){case WYMeditor.INDENT:case WYMeditor.OUTDENT:var f=this.selected();var d=this._iframe.contentWindow.getSelection();var b=d.anchorNode;if(b.nodeName=="#text"){b=b.parentNode}f=this.findUp(f,WYMeditor.BLOCKS);b=this.findUp(b,WYMeditor.BLOCKS);if(f&&f==b&&f.tagName.toLowerCase()==WYMeditor.LI){var c=f.parentNode.parentNode;if(f.parentNode.childNodes.length>1||c.tagName.toLowerCase()==WYMeditor.OL||c.tagName.toLowerCase()==WYMeditor.UL){this._doc.execCommand(e,"",null)}}break;case WYMeditor.INSERT_ORDEREDLIST:case WYMeditor.INSERT_UNORDEREDLIST:this._doc.execCommand(e,"",null);var f=this.selected();var a=this.findUp(f,WYMeditor.MAIN_CONTAINERS);if(a){jQuery(a).replaceWith(jQuery(a).html())}break;default:if(g){this._doc.execCommand(e,"",g)}else{this._doc.execCommand(e,"",null)}}var a=this.selected();if(a&&a.tagName.toLowerCase()==WYMeditor.BODY){this._exec(WYMeditor.FORMAT_BLOCK,WYMeditor.P)}};WYMeditor.WymClassSafari.prototype.selected=function(){var b=this._iframe.contentWindow.getSelection();var a=b.focusNode;if(a){if(a.nodeName=="#text"){return(a.parentNode)}else{return(a)}}else{return(null)}};WYMeditor.WymClassSafari.prototype.addCssRule=function(a,b){a.insertRule(b.name+" {"+b.css+"}",a.cssRules.length)};WYMeditor.WymClassSafari.prototype.keydown=function(a){var b=WYMeditor.INSTANCES[this.title];if(a.ctrlKey){if(a.keyCode==66){b._exec(WYMeditor.BOLD);return false}if(a.keyCode==73){b._exec(WYMeditor.ITALIC);return false}}};WYMeditor.WymClassSafari.prototype.keyup=function(b){var d=WYMeditor.INSTANCES[this.title];d._selected_image=null;var a=null;if(b.keyCode==13&&!b.shiftKey){jQuery(d._doc.body).children(WYMeditor.BR).remove();a=d.selected();if(a&&a.tagName.toLowerCase()==WYMeditor.PRE){d._exec(WYMeditor.FORMAT_BLOCK,WYMeditor.P)}}if(b.keyCode==13&&b.shiftKey){d._exec("InsertLineBreak")}if(b.keyCode!=8&&b.keyCode!=17&&b.keyCode!=46&&b.keyCode!=224&&!b.metaKey&&!b.ctrlKey){a=d.selected();var c=a.tagName.toLowerCase();if(c=="strong"||c=="b"||c=="em"||c=="i"||c=="sub"||c=="sup"||c=="a"||c=="span"){c=a.parentNode.tagName.toLowerCase()}if(c==WYMeditor.BODY||c==WYMeditor.DIV){d._exec(WYMeditor.FORMAT_BLOCK,WYMeditor.P)}}};WYMeditor.WymClassSafari.prototype.openBlockTag=function(a,c){var c=this.validator.getValidTagAttributes(a,c);if(a=="span"&&c.style){var b=this.getTagForStyle(c.style);if(b){this._tag_stack.pop();var a=b;this._tag_stack.push(b);c.style="";if(typeof c["class"]=="string"){c["class"]=c["class"].replace(/apple-style-span/gi,"")}}else{return}}this.output+=this.helper.tag(a,c,true)};WYMeditor.WymClassSafari.prototype.getTagForStyle=function(a){if(/bold/.test(a)){return"strong"}if(/italic/.test(a)){return"em"}if(/sub/.test(a)){return"sub"}if(/super/.test(a)){return"sup"}return false};
View
2 public/javascripts/wymeditor/jquery.wymeditor.pack.js
1 addition, 1 deletion not shown because the diff is too large. Please use a local Git client to view these changes.
View
278 public/javascripts/wymeditor/jquery/GPL-LICENSE.txt
@@ -0,0 +1,278 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
View
20 public/javascripts/wymeditor/jquery/MIT-LICENSE.txt
@@ -0,0 +1,20 @@
+Copyright (c) 2007 John Resig, http://jquery.com/
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
View
67 public/javascripts/wymeditor/jquery/README
@@ -0,0 +1,67 @@
+
+--------------------------------
+jQuery - New Wave Javascript
+http://jquery.com/
+--------------------------------
+
+What you need to build your own jQuery:
+ - Make sure that you have Java installed.
+
+ If not, go to this page and download "Java Runtime Environment (JRE) 5.0"
+ http://java.sun.com/javase/downloads/index.jsp
+
+ - You now have two options for building jQuery, if you have access to
+ common UNIX commands (like 'make', 'mkdir', 'rm', 'cat', and 'echo')
+ then simply type 'make' to build all the components.
+
+ - The other option is if you have Ant installed (or are on Windows and
+ don't have access to make). You can download Ant from here:
+ http://ant.apache.org/bindownload.cgi
+
+ If you do have Ant, everytime (in this README) that I say 'make', do
+ 'ant' instead - it works identically (for all intents and purposes).
+
+How to build your own jQuery:
+
+In the main directory of the distribution (the one that this file is in), type
+the following to make all versions of jQuery, the documentation, and the test suite:
+ make
+
+Here are each of the individual items that are buildable from the Makefile.
+
+make jquery
+ The standard, uncompressed, jQuery code.
+ Makes: ./dist/jquery.js
+
+make lite
+ jQuery without all the additional inline documentation and test cases.
+ Makes: ./dist/jquery.lite.js
+
+make pack
+ A compressed version of jQuery (made with Packer).
+ Makes: ./dist/jquery.pack.js
+
+make docs
+ Builds a complete copy of the documentation, based upon the jQuery source.
+ Makes ./docs/
+ Open this file in your browser:
+ ./docs/index.xml
+
+make test
+ Builds a complete copy of the test suite, based upon the jQuery source.
+ Makes ./test/
+ Open this file in your browser:
+ ./test/index.html
+
+Finally, you can remove all the built files using the command:
+ make clean
+
+Additionally, if you want to install jQuery to a location that is not this
+directory, you can specify the PREFIX directory, for example:
+ make PREFIX=/home/john/test/
+OR
+ make PREFIX=~/www/ docs
+
+If you have any questions, please feel free to ask them on the jQuery
+mailing list, which can be found here:
+ http://jquery.com/discuss/
View
11 public/javascripts/wymeditor/jquery/jquery.js
@@ -0,0 +1,11 @@
+/*
+ * jQuery 1.2.6 - New Wave Javascript
+ *
+ * Copyright (c) 2008 John Resig (jquery.com)
+ * Dual licensed under the MIT (MIT-LICENSE.txt)
+ * and GPL (GPL-LICENSE.txt) licenses.
+ *
+ * $Date: 2008-05-24 14:22:17 -0400 (Sat, 24 May 2008) $
+ * $Rev: 5685 $
+ */
+eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('(H(){J w=1b.4M,3m$=1b.$;J D=1b.4M=1b.$=H(a,b){I 2B D.17.5j(a,b)};J u=/^[^<]*(<(.|\\s)+>)[^>]*$|^#(\\w+)$/,62=/^.[^:#\\[\\.]*$/,12;D.17=D.44={5j:H(d,b){d=d||S;G(d.16){7[0]=d;7.K=1;I 7}G(1j d=="23"){J c=u.2D(d);G(c&&(c[1]||!b)){G(c[1])d=D.4h([c[1]],b);N{J a=S.61(c[3]);G(a){G(a.2v!=c[3])I D().2q(d);I D(a)}d=[]}}N I D(b).2q(d)}N G(D.1D(d))I D(S)[D.17.27?"27":"43"](d);I 7.6Y(D.2d(d))},5w:"1.2.6",8G:H(){I 7.K},K:0,3p:H(a){I a==12?D.2d(7):7[a]},2I:H(b){J a=D(b);a.5n=7;I a},6Y:H(a){7.K=0;2p.44.1p.1w(7,a);I 7},P:H(a,b){I D.P(7,a,b)},5i:H(b){J a=-1;I D.2L(b&&b.5w?b[0]:b,7)},1K:H(c,a,b){J d=c;G(c.1q==56)G(a===12)I 7[0]&&D[b||"1K"](7[0],c);N{d={};d[c]=a}I 7.P(H(i){R(c 1n d)D.1K(b?7.V:7,c,D.1i(7,d[c],b,i,c))})},1g:H(b,a){G((b==\'2h\'||b==\'1Z\')&&3d(a)<0)a=12;I 7.1K(b,a,"2a")},1r:H(b){G(1j b!="49"&&b!=U)I 7.4E().3v((7[0]&&7[0].2z||S).5F(b));J a="";D.P(b||7,H(){D.P(7.3t,H(){G(7.16!=8)a+=7.16!=1?7.76:D.17.1r([7])})});I a},5z:H(b){G(7[0])D(b,7[0].2z).5y().39(7[0]).2l(H(){J a=7;1B(a.1x)a=a.1x;I a}).3v(7);I 7},8Y:H(a){I 7.P(H(){D(7).6Q().5z(a)})},8R:H(a){I 7.P(H(){D(7).5z(a)})},3v:H(){I 7.3W(19,M,Q,H(a){G(7.16==1)7.3U(a)})},6F:H(){I 7.3W(19,M,M,H(a){G(7.16==1)7.39(a,7.1x)})},6E:H(){I 7.3W(19,Q,Q,H(a){7.1d.39(a,7)})},5q:H(){I 7.3W(19,Q,M,H(a){7.1d.39(a,7.2H)})},3l:H(){I 7.5n||D([])},2q:H(b){J c=D.2l(7,H(a){I D.2q(b,a)});I 7.2I(/[^+>] [^+>]/.11(b)||b.1h("..")>-1?D.4r(c):c)},5y:H(e){J f=7.2l(H(){G(D.14.1f&&!D.4n(7)){J a=7.6o(M),5h=S.3h("1v");5h.3U(a);I D.4h([5h.4H])[0]}N I 7.6o(M)});J d=f.2q("*").5c().P(H(){G(7[E]!=12)7[E]=U});G(e===M)7.2q("*").5c().P(H(i){G(7.16==3)I;J c=D.L(7,"3w");R(J a 1n c)R(J b 1n c[a])D.W.1e(d[i],a,c[a][b],c[a][b].L)});I f},1E:H(b){I 7.2I(D.1D(b)&&D.3C(7,H(a,i){I b.1k(a,i)})||D.3g(b,7))},4Y:H(b){G(b.1q==56)G(62.11(b))I 7.2I(D.3g(b,7,M));N b=D.3g(b,7);J a=b.K&&b[b.K-1]!==12&&!b.16;I 7.1E(H(){I a?D.2L(7,b)<0:7!=b})},1e:H(a){I 7.2I(D.4r(D.2R(7.3p(),1j a==\'23\'?D(a):D.2d(a))))},3F:H(a){I!!a&&D.3g(a,7).K>0},7T:H(a){I 7.3F("."+a)},6e:H(b){G(b==12){G(7.K){J c=7[0];G(D.Y(c,"2A")){J e=c.64,63=[],15=c.15,2V=c.O=="2A-2V";G(e<0)I U;R(J i=2V?e:0,2f=2V?e+1:15.K;i<2f;i++){J d=15[i];G(d.2W){b=D.14.1f&&!d.at.2x.an?d.1r:d.2x;G(2V)I b;63.1p(b)}}I 63}N I(7[0].2x||"").1o(/\\r/g,"")}I 12}G(b.1q==4L)b+=\'\';I 7.P(H(){G(7.16!=1)I;G(b.1q==2p&&/5O|5L/.11(7.O))7.4J=(D.2L(7.2x,b)>=0||D.2L(7.34,b)>=0);N G(D.Y(7,"2A")){J a=D.2d(b);D("9R",7).P(H(){7.2W=(D.2L(7.2x,a)>=0||D.2L(7.1r,a)>=0)});G(!a.K)7.64=-1}N 7.2x=b})},2K:H(a){I a==12?(7[0]?7[0].4H:U):7.4E().3v(a)},7b:H(a){I 7.5q(a).21()},79:H(i){I 7.3s(i,i+1)},3s:H(){I 7.2I(2p.44.3s.1w(7,19))},2l:H(b){I 7.2I(D.2l(7,H(a,i){I b.1k(a,i,a)}))},5c:H(){I 7.1e(7.5n)},L:H(d,b){J a=d.1R(".");a[1]=a[1]?"."+a[1]:"";G(b===12){J c=7.5C("9z"+a[1]+"!",[a[0]]);G(c===12&&7.K)c=D.L(7[0],d);I c===12&&a[1]?7.L(a[0]):c}N I 7.1P("9u"+a[1]+"!",[a[0],b]).P(H(){D.L(7,d,b)})},3b:H(a){I 7.P(H(){D.3b(7,a)})},3W:H(g,f,h,d){J e=7.K>1,3x;I 7.P(H(){G(!3x){3x=D.4h(g,7.2z);G(h)3x.9o()}J b=7;G(f&&D.Y(7,"1T")&&D.Y(3x[0],"4F"))b=7.3H("22")[0]||7.3U(7.2z.3h("22"));J c=D([]);D.P(3x,H(){J a=e?D(7).5y(M)[0]:7;G(D.Y(a,"1m"))c=c.1e(a);N{G(a.16==1)c=c.1e(D("1m",a).21());d.1k(b,a)}});c.P(6T)})}};D.17.5j.44=D.17;H 6T(i,a){G(a.4d)D.3Y({1a:a.4d,31:Q,1O:"1m"});N D.5u(a.1r||a.6O||a.4H||"");G(a.1d)a.1d.37(a)}H 1z(){I+2B 8J}D.1l=D.17.1l=H(){J b=19[0]||{},i=1,K=19.K,4x=Q,15;G(b.1q==8I){4x=b;b=19[1]||{};i=2}G(1j b!="49"&&1j b!="H")b={};G(K==i){b=7;--i}R(;i<K;i++)G((15=19[i])!=U)R(J c 1n 15){J a=b[c],2w=15[c];G(b===2w)6M;G(4x&&2w&&1j 2w=="49"&&!2w.16)b[c]=D.1l(4x,a||(2w.K!=U?[]:{}),2w);N G(2w!==12)b[c]=2w}I b};J E="4M"+1z(),6K=0,5r={},6G=/z-?5i|8B-?8A|1y|6B|8v-?1Z/i,3P=S.3P||{};D.1l({8u:H(a){1b.$=3m$;G(a)1b.4M=w;I D},1D:H(a){I!!a&&1j a!="23"&&!a.Y&&a.1q!=2p&&/^[\\s[]?H/.11(a+"")},4n:H(a){I a.1C&&!a.1c||a.2j&&a.2z&&!a.2z.1c},5u:H(a){a=D.3k(a);G(a){J b=S.3H("6w")[0]||S.1C,1m=S.3h("1m");1m.O="1r/4t";G(D.14.1f)1m.1r=a;N 1m.3U(S.5F(a));b.39(1m,b.1x);b.37(1m)}},Y:H(b,a){I b.Y&&b.Y.2r()==a.2r()},1Y:{},L:H(c,d,b){c=c==1b?5r:c;J a=c[E];G(!a)a=c[E]=++6K;G(d&&!D.1Y[a])D.1Y[a]={};G(b!==12)D.1Y[a][d]=b;I d?D.1Y[a][d]:a},3b:H(c,b){c=c==1b?5r:c;J a=c[E];G(b){G(D.1Y[a]){2U D.1Y[a][b];b="";R(b 1n D.1Y[a])1X;G(!b)D.3b(c)}}N{1U{2U c[E]}1V(e){G(c.5l)c.5l(E)}2U D.1Y[a]}},P:H(d,a,c){J e,i=0,K=d.K;G(c){G(K==12){R(e 1n d)G(a.1w(d[e],c)===Q)1X}N R(;i<K;)G(a.1w(d[i++],c)===Q)1X}N{G(K==12){R(e 1n d)G(a.1k(d[e],e,d[e])===Q)1X}N R(J b=d[0];i<K&&a.1k(b,i,b)!==Q;b=d[++i]){}}I d},1i:H(b,a,c,i,d){G(D.1D(a))a=a.1k(b,i);I a&&a.1q==4L&&c=="2a"&&!6G.11(d)?a+"2X":a},1F:{1e:H(c,b){D.P((b||"").1R(/\\s+/),H(i,a){G(c.16==1&&!D.1F.3T(c.1F,a))c.1F+=(c.1F?" ":"")+a})},21:H(c,b){G(c.16==1)c.1F=b!=12?D.3C(c.1F.1R(/\\s+/),H(a){I!D.1F.3T(b,a)}).6s(" "):""},3T:H(b,a){I D.2L(a,(b.1F||b).6r().1R(/\\s+/))>-1}},6q:H(b,c,a){J e={};R(J d 1n c){e[d]=b.V[d];b.V[d]=c[d]}a.1k(b);R(J d 1n c)b.V[d]=e[d]},1g:H(d,e,c){G(e=="2h"||e=="1Z"){J b,3X={30:"5x",5g:"1G",18:"3I"},35=e=="2h"?["5e","6k"]:["5G","6i"];H 5b(){b=e=="2h"?d.8f:d.8c;J a=0,2C=0;D.P(35,H(){a+=3d(D.2a(d,"57"+7,M))||0;2C+=3d(D.2a(d,"2C"+7+"4b",M))||0});b-=29.83(a+2C)}G(D(d).3F(":4j"))5b();N D.6q(d,3X,5b);I 29.2f(0,b)}I D.2a(d,e,c)},2a:H(f,l,k){J e,V=f.V;H 3E(b){G(!D.14.2k)I Q;J a=3P.54(b,U);I!a||a.52("3E")==""}G(l=="1y"&&D.14.1f){e=D.1K(V,"1y");I e==""?"1":e}G(D.14.2G&&l=="18"){J d=V.50;V.50="0 7Y 7W";V.50=d}G(l.1I(/4i/i))l=y;G(!k&&V&&V[l])e=V[l];N G(3P.54){G(l.1I(/4i/i))l="4i";l=l.1o(/([A-Z])/g,"-$1").3y();J c=3P.54(f,U);G(c&&!3E(f))e=c.52(l);N{J g=[],2E=[],a=f,i=0;R(;a&&3E(a);a=a.1d)2E.6h(a);R(;i<2E.K;i++)G(3E(2E[i])){g[i]=2E[i].V.18;2E[i].V.18="3I"}e=l=="18"&&g[2E.K-1]!=U?"2F":(c&&c.52(l))||"";R(i=0;i<g.K;i++)G(g[i]!=U)2E[i].V.18=g[i]}G(l=="1y"&&e=="")e="1"}N G(f.4g){J h=l.1o(/\\-(\\w)/g,H(a,b){I b.2r()});e=f.4g[l]||f.4g[h];G(!/^\\d+(2X)?$/i.11(e)&&/^\\d/.11(e)){J j=V.1A,66=f.65.1A;f.65.1A=f.4g.1A;V.1A=e||0;e=V.aM+"2X";V.1A=j;f.65.1A=66}}I e},4h:H(l,h){J k=[];h=h||S;G(1j h.3h==\'12\')h=h.2z||h[0]&&h[0].2z||S;D.P(l,H(i,d){G(!d)I;G(d.1q==4L)d+=\'\';G(1j d=="23"){d=d.1o(/(<(\\w+)[^>]*?)\\/>/g,H(b,a,c){I c.1I(/^(aK|4f|7E|aG|4T|7A|aB|3n|az|ay|av)$/i)?b:a+"></"+c+">"});J f=D.3k(d).3y(),1v=h.3h("1v");J e=!f.1h("<au")&&[1,"<2A 7w=\'7w\'>","</2A>"]||!f.1h("<ar")&&[1,"<7v>","</7v>"]||f.1I(/^<(aq|22|am|ak|ai)/)&&[1,"<1T>","</1T>"]||!f.1h("<4F")&&[2,"<1T><22>","</22></1T>"]||(!f.1h("<af")||!f.1h("<ad"))&&[3,"<1T><22><4F>","</4F></22></1T>"]||!f.1h("<7E")&&[2,"<1T><22></22><7q>","</7q></1T>"]||D.14.1f&&[1,"1v<1v>","</1v>"]||[0,"",""];1v.4H=e[1]+d+e[2];1B(e[0]--)1v=1v.5T;G(D.14.1f){J g=!f.1h("<1T")&&f.1h("<22")<0?1v.1x&&1v.1x.3t:e[1]=="<1T>"&&f.1h("<22")<0?1v.3t:[];R(J j=g.K-1;j>=0;--j)G(D.Y(g[j],"22")&&!g[j].3t.K)g[j].1d.37(g[j]);G(/^\\s/.11(d))1v.39(h.5F(d.1I(/^\\s*/)[0]),1v.1x)}d=D.2d(1v.3t)}G(d.K===0&&(!D.Y(d,"3V")&&!D.Y(d,"2A")))I;G(d[0]==12||D.Y(d,"3V")||d.15)k.1p(d);N k=D.2R(k,d)});I k},1K:H(d,f,c){G(!d||d.16==3||d.16==8)I 12;J e=!D.4n(d),40=c!==12,1f=D.14.1f;f=e&&D.3X[f]||f;G(d.2j){J g=/5Q|4d|V/.11(f);G(f=="2W"&&D.14.2k)d.1d.64;G(f 1n d&&e&&!g){G(40){G(f=="O"&&D.Y(d,"4T")&&d.1d)7p"O a3 a1\'t 9V 9U";d[f]=c}G(D.Y(d,"3V")&&d.7i(f))I d.7i(f).76;I d[f]}G(1f&&e&&f=="V")I D.1K(d.V,"9T",c);G(40)d.9Q(f,""+c);J h=1f&&e&&g?d.4G(f,2):d.4G(f);I h===U?12:h}G(1f&&f=="1y"){G(40){d.6B=1;d.1E=(d.1E||"").1o(/7f\\([^)]*\\)/,"")+(3r(c)+\'\'=="9L"?"":"7f(1y="+c*7a+")")}I d.1E&&d.1E.1h("1y=")>=0?(3d(d.1E.1I(/1y=([^)]*)/)[1])/7a)+\'\':""}f=f.1o(/-([a-z])/9H,H(a,b){I b.2r()});G(40)d[f]=c;I d[f]},3k:H(a){I(a||"").1o(/^\\s+|\\s+$/g,"")},2d:H(b){J a=[];G(b!=U){J i=b.K;G(i==U||b.1R||b.4I||b.1k)a[0]=b;N 1B(i)a[--i]=b[i]}I a},2L:H(b,a){R(J i=0,K=a.K;i<K;i++)G(a[i]===b)I i;I-1},2R:H(a,b){J i=0,T,2S=a.K;G(D.14.1f){1B(T=b[i++])G(T.16!=8)a[2S++]=T}N 1B(T=b[i++])a[2S++]=T;I a},4r:H(a){J c=[],2o={};1U{R(J i=0,K=a.K;i<K;i++){J b=D.L(a[i]);G(!2o[b]){2o[b]=M;c.1p(a[i])}}}1V(e){c=a}I c},3C:H(c,a,d){J b=[];R(J i=0,K=c.K;i<K;i++)G(!d!=!a(c[i],i))b.1p(c[i]);I b},2l:H(d,a){J c=[];R(J i=0,K=d.K;i<K;i++){J b=a(d[i],i);G(b!=U)c[c.K]=b}I c.7d.1w([],c)}});J v=9B.9A.3y();D.14={5B:(v.1I(/.+(?:9y|9x|9w|9v)[\\/: ]([\\d.]+)/)||[])[1],2k:/75/.11(v),2G:/2G/.11(v),1f:/1f/.11(v)&&!/2G/.11(v),42:/42/.11(v)&&!/(9s|75)/.11(v)};J y=D.14.1f?"7o":"72";D.1l({71:!D.14.1f||S.70=="6Z",3X:{"R":"9n","9k":"1F","4i":y,72:y,7o:y,9h:"9f",9e:"9d",9b:"99"}});D.P({6W:H(a){I a.1d},97:H(a){I D.4S(a,"1d")},95:H(a){I D.3a(a,2,"2H")},91:H(a){I D.3a(a,2,"4l")},8Z:H(a){I D.4S(a,"2H")},8X:H(a){I D.4S(a,"4l")},8W:H(a){I D.5v(a.1d.1x,a)},8V:H(a){I D.5v(a.1x)},6Q:H(a){I D.Y(a,"8U")?a.8T||a.8S.S:D.2d(a.3t)}},H(c,d){D.17[c]=H(b){J a=D.2l(7,d);G(b&&1j b=="23")a=D.3g(b,a);I 7.2I(D.4r(a))}});D.P({6P:"3v",8Q:"6F",39:"6E",8P:"5q",8O:"7b"},H(c,b){D.17[c]=H(){J a=19;I 7.P(H(){R(J i=0,K=a.K;i<K;i++)D(a[i])[b](7)})}});D.P({8N:H(a){D.1K(7,a,"");G(7.16==1)7.5l(a)},8M:H(a){D.1F.1e(7,a)},8L:H(a){D.1F.21(7,a)},8K:H(a){D.1F[D.1F.3T(7,a)?"21":"1e"](7,a)},21:H(a){G(!a||D.1E(a,[7]).r.K){D("*",7).1e(7).P(H(){D.W.21(7);D.3b(7)});G(7.1d)7.1d.37(7)}},4E:H(){D(">*",7).21();1B(7.1x)7.37(7.1x)}},H(a,b){D.17[a]=H(){I 7.P(b,19)}});D.P(["6N","4b"],H(i,c){J b=c.3y();D.17[b]=H(a){I 7[0]==1b?D.14.2G&&S.1c["5t"+c]||D.14.2k&&1b["5s"+c]||S.70=="6Z"&&S.1C["5t"+c]||S.1c["5t"+c]:7[0]==S?29.2f(29.2f(S.1c["4y"+c],S.1C["4y"+c]),29.2f(S.1c["2i"+c],S.1C["2i"+c])):a==12?(7.K?D.1g(7[0],b):U):7.1g(b,a.1q==56?a:a+"2X")}});H 25(a,b){I a[0]&&3r(D.2a(a[0],b,M),10)||0}J C=D.14.2k&&3r(D.14.5B)<8H?"(?:[\\\\w*3m-]|\\\\\\\\.)":"(?:[\\\\w\\8F-\\8E*3m-]|\\\\\\\\.)",6L=2B 4v("^>\\\\s*("+C+"+)"),6J=2B 4v("^("+C+"+)(#)("+C+"+)"),6I=2B 4v("^([#.]?)("+C+"*)");D.1l({6H:{"":H(a,i,m){I m[2]=="*"||D.Y(a,m[2])},"#":H(a,i,m){I a.4G("2v")==m[2]},":":{8D:H(a,i,m){I i<m[3]-0},8C:H(a,i,m){I i>m[3]-0},3a:H(a,i,m){I m[3]-0==i},79:H(a,i,m){I m[3]-0==i},3o:H(a,i){I i==0},3S:H(a,i,m,r){I i==r.K-1},6D:H(a,i){I i%2==0},6C:H(a,i){I i%2},"3o-4u":H(a){I a.1d.3H("*")[0]==a},"3S-4u":H(a){I D.3a(a.1d.5T,1,"4l")==a},"8z-4u":H(a){I!D.3a(a.1d.5T,2,"4l")},6W:H(a){I a.1x},4E:H(a){I!a.1x},8y:H(a,i,m){I(a.6O||a.8x||D(a).1r()||"").1h(m[3])>=0},4j:H(a){I"1G"!=a.O&&D.1g(a,"18")!="2F"&&D.1g(a,"5g")!="1G"},1G:H(a){I"1G"==a.O||D.1g(a,"18")=="2F"||D.1g(a,"5g")=="1G"},8w:H(a){I!a.3R},3R:H(a){I a.3R},4J:H(a){I a.4J},2W:H(a){I a.2W||D.1K(a,"2W")},1r:H(a){I"1r"==a.O},5O:H(a){I"5O"==a.O},5L:H(a){I"5L"==a.O},5p:H(a){I"5p"==a.O},3Q:H(a){I"3Q"==a.O},5o:H(a){I"5o"==a.O},6A:H(a){I"6A"==a.O},6z:H(a){I"6z"==a.O},2s:H(a){I"2s"==a.O||D.Y(a,"2s")},4T:H(a){I/4T|2A|6y|2s/i.11(a.Y)},3T:H(a,i,m){I D.2q(m[3],a).K},8t:H(a){I/h\\d/i.11(a.Y)},8s:H(a){I D.3C(D.3O,H(b){I a==b.T}).K}}},6x:[/^(\\[) *@?([\\w-]+) *([!*$^~=]*) *(\'?"?)(.*?)\\4 *\\]/,/^(:)([\\w-]+)\\("?\'?(.*?(\\(.*?\\))?[^(]*?)"?\'?\\)/,2B 4v("^([:.#]*)("+C+"+)")],3g:H(a,c,b){J d,1t=[];1B(a&&a!=d){d=a;J f=D.1E(a,c,b);a=f.t.1o(/^\\s*,\\s*/,"");1t=b?c=f.r:D.2R(1t,f.r)}I 1t},2q:H(t,o){G(1j t!="23")I[t];G(o&&o.16!=1&&o.16!=9)I[];o=o||S;J d=[o],2o=[],3S,Y;1B(t&&3S!=t){J r=[];3S=t;t=D.3k(t);J l=Q,3j=6L,m=3j.2D(t);G(m){Y=m[1].2r();R(J i=0;d[i];i++)R(J c=d[i].1x;c;c=c.2H)G(c.16==1&&(Y=="*"||c.Y.2r()==Y))r.1p(c);d=r;t=t.1o(3j,"");G(t.1h(" ")==0)6M;l=M}N{3j=/^([>+~])\\s*(\\w*)/i;G((m=3j.2D(t))!=U){r=[];J k={};Y=m[2].2r();m=m[1];R(J j=0,3i=d.K;j<3i;j++){J n=m=="~"||m=="+"?d[j].2H:d[j].1x;R(;n;n=n.2H)G(n.16==1){J g=D.L(n);G(m=="~"&&k[g])1X;G(!Y||n.Y.2r()==Y){G(m=="~")k[g]=M;r.1p(n)}G(m=="+")1X}}d=r;t=D.3k(t.1o(3j,""));l=M}}G(t&&!l){G(!t.1h(",")){G(o==d[0])d.4s();2o=D.2R(2o,d);r=d=[o];t=" "+t.6v(1,t.K)}N{J h=6J;J m=h.2D(t);G(m){m=[0,m[2],m[3],m[1]]}N{h=6I;m=h.2D(t)}m[2]=m[2].1o(/\\\\/g,"");J f=d[d.K-1];G(m[1]=="#"&&f&&f.61&&!D.4n(f)){J p=f.61(m[2]);G((D.14.1f||D.14.2G)&&p&&1j p.2v=="23"&&p.2v!=m[2])p=D(\'[@2v="\'+m[2]+\'"]\',f)[0];d=r=p&&(!m[3]||D.Y(p,m[3]))?[p]:[]}N{R(J i=0;d[i];i++){J a=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];G(a=="*"&&d[i].Y.3y()=="49")a="3n";r=D.2R(r,d[i].3H(a))}G(m[1]==".")r=D.5m(r,m[2]);G(m[1]=="#"){J e=[];R(J i=0;r[i];i++)G(r[i].4G("2v")==m[2]){e=[r[i]];1X}r=e}d=r}t=t.1o(h,"")}}G(t){J b=D.1E(t,r);d=r=b.r;t=D.3k(b.t)}}G(t)d=[];G(d&&o==d[0])d.4s();2o=D.2R(2o,d);I 2o},5m:H(r,m,a){m=" "+m+" ";J c=[];R(J i=0;r[i];i++){J b=(" "+r[i].1F+" ").1h(m)>=0;G(!a&&b||a&&!b)c.1p(r[i])}I c},1E:H(t,r,h){J d;1B(t&&t!=d){d=t;J p=D.6x,m;R(J i=0;p[i];i++){m=p[i].2D(t);G(m){t=t.8r(m[0].K);m[2]=m[2].1o(/\\\\/g,"");1X}}G(!m)1X;G(m[1]==":"&&m[2]=="4Y")r=62.11(m[3])?D.1E(m[3],r,M).r:D(r).4Y(m[3]);N G(m[1]==".")r=D.5m(r,m[2],h);N G(m[1]=="["){J g=[],O=m[3];R(J i=0,3i=r.K;i<3i;i++){J a=r[i],z=a[D.3X[m[2]]||m[2]];G(z==U||/5Q|4d|2W/.11(m[2]))z=D.1K(a,m[2])||\'\';G((O==""&&!!z||O=="="&&z==m[5]||O=="!="&&z!=m[5]||O=="^="&&z&&!z.1h(m[5])||O=="$="&&z.6v(z.K-m[5].K)==m[5]||(O=="*="||O=="~=")&&z.1h(m[5])>=0)^h)g.1p(a)}r=g}N G(m[1]==":"&&m[2]=="3a-4u"){J e={},g=[],11=/(-?)(\\d*)n((?:\\+|-)?\\d*)/.2D(m[3]=="6D"&&"2n"||m[3]=="6C"&&"2n+1"||!/\\D/.11(m[3])&&"8q+"+m[3]||m[3]),3o=(11[1]+(11[2]||1))-0,d=11[3]-0;R(J i=0,3i=r.K;i<3i;i++){J j=r[i],1d=j.1d,2v=D.L(1d);G(!e[2v]){J c=1;R(J n=1d.1x;n;n=n.2H)G(n.16==1)n.4q=c++;e[2v]=M}J b=Q;G(3o==0){G(j.4q==d)b=M}N G((j.4q-d)%3o==0&&(j.4q-d)/3o>=0)b=M;G(b^h)g.1p(j)}r=g}N{J f=D.6H[m[1]];G(1j f=="49")f=f[m[2]];G(1j f=="23")f=6u("Q||H(a,i){I "+f+";}");r=D.3C(r,H(a,i){I f(a,i,m,r)},h)}}I{r:r,t:t}},4S:H(b,c){J a=[],1t=b[c];1B(1t&&1t!=S){G(1t.16==1)a.1p(1t);1t=1t[c]}I a},3a:H(a,e,c,b){e=e||1;J d=0;R(;a;a=a[c])G(a.16==1&&++d==e)1X;I a},5v:H(n,a){J r=[];R(;n;n=n.2H){G(n.16==1&&n!=a)r.1p(n)}I r}});D.W={1e:H(f,i,g,e){G(f.16==3||f.16==8)I;G(D.14.1f&&f.4I)f=1b;G(!g.24)g.24=7.24++;G(e!=12){J h=g;g=7.3M(h,H(){I h.1w(7,19)});g.L=e}J j=D.L(f,"3w")||D.L(f,"3w",{}),1H=D.L(f,"1H")||D.L(f,"1H",H(){G(1j D!="12"&&!D.W.5k)I D.W.1H.1w(19.3L.T,19)});1H.T=f;D.P(i.1R(/\\s+/),H(c,b){J a=b.1R(".");b=a[0];g.O=a[1];J d=j[b];G(!d){d=j[b]={};G(!D.W.2t[b]||D.W.2t[b].4p.1k(f)===Q){G(f.3K)f.3K(b,1H,Q);N G(f.6t)f.6t("4o"+b,1H)}}d[g.24]=g;D.W.26[b]=M});f=U},24:1,26:{},21:H(e,h,f){G(e.16==3||e.16==8)I;J i=D.L(e,"3w"),1L,5i;G(i){G(h==12||(1j h=="23"&&h.8p(0)=="."))R(J g 1n i)7.21(e,g+(h||""));N{G(h.O){f=h.2y;h=h.O}D.P(h.1R(/\\s+/),H(b,a){J c=a.1R(".");a=c[0];G(i[a]){G(f)2U i[a][f.24];N R(f 1n i[a])G(!c[1]||i[a][f].O==c[1])2U i[a][f];R(1L 1n i[a])1X;G(!1L){G(!D.W.2t[a]||D.W.2t[a].4A.1k(e)===Q){G(e.6p)e.6p(a,D.L(e,"1H"),Q);N G(e.6n)e.6n("4o"+a,D.L(e,"1H"))}1L=U;2U i[a]}}})}R(1L 1n i)1X;G(!1L){J d=D.L(e,"1H");G(d)d.T=U;D.3b(e,"3w");D.3b(e,"1H")}}},1P:H(h,c,f,g,i){c=D.2d(c);G(h.1h("!")>=0){h=h.3s(0,-1);J a=M}G(!f){G(7.26[h])D("*").1e([1b,S]).1P(h,c)}N{G(f.16==3||f.16==8)I 12;J b,1L,17=D.1D(f[h]||U),W=!c[0]||!c[0].32;G(W){c.6h({O:h,2J:f,32:H(){},3J:H(){},4C:1z()});c[0][E]=M}c[0].O=h;G(a)c[0].6m=M;J d=D.L(f,"1H");G(d)b=d.1w(f,c);G((!17||(D.Y(f,\'a\')&&h=="4V"))&&f["4o"+h]&&f["4o"+h].1w(f,c)===Q)b=Q;G(W)c.4s();G(i&&D.1D(i)){1L=i.1w(f,b==U?c:c.7d(b));G(1L!==12)b=1L}G(17&&g!==Q&&b!==Q&&!(D.Y(f,\'a\')&&h=="4V")){7.5k=M;1U{f[h]()}1V(e){}}7.5k=Q}I b},1H:H(b){J a,1L,38,5f,4m;b=19[0]=D.W.6l(b||1b.W);38=b.O.1R(".");b.O=38[0];38=38[1];5f=!38&&!b.6m;4m=(D.L(7,"3w")||{})[b.O];R(J j 1n 4m){J c=4m[j];G(5f||c.O==38){b.2y=c;b.L=c.L;1L=c.1w(7,19);G(a!==Q)a=1L;G(1L===Q){b.32();b.3J()}}}I a},6l:H(b){G(b[E]==M)I b;J d=b;b={8o:d};J c="8n 8m 8l 8k 2s 8j 47 5d 6j 5E 8i L 8h 8g 4K 2y 5a 59 8e 8b 58 6f 8a 88 4k 87 86 84 6d 2J 4C 6c O 82 81 35".1R(" ");R(J i=c.K;i;i--)b[c[i]]=d[c[i]];b[E]=M;b.32=H(){G(d.32)d.32();d.80=Q};b.3J=H(){G(d.3J)d.3J();d.7Z=M};b.4C=b.4C||1z();G(!b.2J)b.2J=b.6d||S;G(b.2J.16==3)b.2J=b.2J.1d;G(!b.4k&&b.4K)b.4k=b.4K==b.2J?b.6c:b.4K;G(b.58==U&&b.5d!=U){J a=S.1C,1c=S.1c;b.58=b.5d+(a&&a.2e||1c&&1c.2e||0)-(a.6b||0);b.6f=b.6j+(a&&a.2c||1c&&1c.2c||0)-(a.6a||0)}G(!b.35&&((b.47||b.47===0)?b.47:b.5a))b.35=b.47||b.5a;G(!b.59&&b.5E)b.59=b.5E;G(!b.35&&b.2s)b.35=(b.2s&1?1:(b.2s&2?3:(b.2s&4?2:0)));I b},3M:H(a,b){b.24=a.24=a.24||b.24||7.24++;I b},2t:{27:{4p:H(){55();I},4A:H(){I}},3D:{4p:H(){G(D.14.1f)I Q;D(7).2O("53",D.W.2t.3D.2y);I M},4A:H(){G(D.14.1f)I Q;D(7).4e("53",D.W.2t.3D.2y);I M},2y:H(a){G(F(a,7))I M;a.O="3D";I D.W.1H.1w(7,19)}},3N:{4p:H(){G(D.14.1f)I Q;D(7).2O("51",D.W.2t.3N.2y);I M},4A:H(){G(D.14.1f)I Q;D(7).4e("51",D.W.2t.3N.2y);I M},2y:H(a){G(F(a,7))I M;a.O="3N";I D.W.1H.1w(7,19)}}}};D.17.1l({2O:H(c,a,b){I c=="4X"?7.2V(c,a,b):7.P(H(){D.W.1e(7,c,b||a,b&&a)})},2V:H(d,b,c){J e=D.W.3M(c||b,H(a){D(7).4e(a,e);I(c||b).1w(7,19)});I 7.P(H(){D.W.1e(7,d,e,c&&b)})},4e:H(a,b){I 7.P(H(){D.W.21(7,a,b)})},1P:H(c,a,b){I 7.P(H(){D.W.1P(c,a,7,M,b)})},5C:H(c,a,b){I 7[0]&&D.W.1P(c,a,7[0],Q,b)},2m:H(b){J c=19,i=1;1B(i<c.K)D.W.3M(b,c[i++]);I 7.4V(D.W.3M(b,H(a){7.4Z=(7.4Z||0)%i;a.32();I c[7.4Z++].1w(7,19)||Q}))},7X:H(a,b){I 7.2O(\'3D\',a).2O(\'3N\',b)},27:H(a){55();G(D.2Q)a.1k(S,D);N D.3A.1p(H(){I a.1k(7,D)});I 7}});D.1l({2Q:Q,3A:[],27:H(){G(!D.2Q){D.2Q=M;G(D.3A){D.P(D.3A,H(){7.1k(S)});D.3A=U}D(S).5C("27")}}});J x=Q;H 55(){G(x)I;x=M;G(S.3K&&!D.14.2G)S.3K("69",D.27,Q);G(D.14.1f&&1b==1S)(H(){G(D.2Q)I;1U{S.1C.7V("1A")}1V(3e){3B(19.3L,0);I}D.27()})();G(D.14.2G)S.3K("69",H(){G(D.2Q)I;R(J i=0;i<S.4W.K;i++)G(S.4W[i].3R){3B(19.3L,0);I}D.27()},Q);G(D.14.2k){J a;(H(){G(D.2Q)I;G(S.3f!="68"&&S.3f!="1J"){3B(19.3L,0);I}G(a===12)a=D("V, 7A[7U=7S]").K;G(S.4W.K!=a){3B(19.3L,0);I}D.27()})()}D.W.1e(1b,"43",D.27)}D.P(("7R,7Q,43,85,4y,4X,4V,7P,"+"7O,7N,89,53,51,7M,2A,"+"5o,7L,7K,8d,3e").1R(","),H(i,b){D.17[b]=H(a){I a?7.2O(b,a):7.1P(b)}});J F=H(a,c){J b=a.4k;1B(b&&b!=c)1U{b=b.1d}1V(3e){b=c}I b==c};D(1b).2O("4X",H(){D("*").1e(S).4e()});D.17.1l({67:D.17.43,43:H(g,d,c){G(1j g!=\'23\')I 7.67(g);J e=g.1h(" ");G(e>=0){J i=g.3s(e,g.K);g=g.3s(0,e)}c=c||H(){};J f="2P";G(d)G(D.1D(d)){c=d;d=U}N{d=D.3n(d);f="6g"}J h=7;D.3Y({1a:g,O:f,1O:"2K",L:d,1J:H(a,b){G(b=="1W"||b=="7J")h.2K(i?D("<1v/>").3v(a.4U.1o(/<1m(.|\\s)*?\\/1m>/g,"")).2q(i):a.4U);h.P(c,[a.4U,b,a])}});I 7},aL:H(){I D.3n(7.7I())},7I:H(){I 7.2l(H(){I D.Y(7,"3V")?D.2d(7.aH):7}).1E(H(){I 7.34&&!7.3R&&(7.4J||/2A|6y/i.11(7.Y)||/1r|1G|3Q/i.11(7.O))}).2l(H(i,c){J b=D(7).6e();I b==U?U:b.1q==2p?D.2l(b,H(a,i){I{34:c.34,2x:a}}):{34:c.34,2x:b}}).3p()}});D.P("7H,7G,7F,7D,7C,7B".1R(","),H(i,o){D.17[o]=H(f){I 7.2O(o,f)}});J B=1z();D.1l({3p:H(d,b,a,c){G(D.1D(b)){a=b;b=U}I D.3Y({O:"2P",1a:d,L:b,1W:a,1O:c})},aE:H(b,a){I D.3p(b,U,a,"1m")},aD:H(c,b,a){I D.3p(c,b,a,"3z")},aC:H(d,b,a,c){G(D.1D(b)){a=b;b={}}I D.3Y({O:"6g",1a:d,L:b,1W:a,1O:c})},aA:H(a){D.1l(D.60,a)},60:{1a:5Z.5Q,26:M,O:"2P",2T:0,7z:"4R/x-ax-3V-aw",7x:M,31:M,L:U,5Y:U,3Q:U,4Q:{2N:"4R/2N, 1r/2N",2K:"1r/2K",1m:"1r/4t, 4R/4t",3z:"4R/3z, 1r/4t",1r:"1r/as",4w:"*/*"}},4z:{},3Y:H(s){s=D.1l(M,s,D.1l(M,{},D.60,s));J g,2Z=/=\\?(&|$)/g,1u,L,O=s.O.2r();G(s.L&&s.7x&&1j s.L!="23")s.L=D.3n(s.L);G(s.1O=="4P"){G(O=="2P"){G(!s.1a.1I(2Z))s.1a+=(s.1a.1I(/\\?/)?"&":"?")+(s.4P||"7u")+"=?"}N G(!s.L||!s.L.1I(2Z))s.L=(s.L?s.L+"&":"")+(s.4P||"7u")+"=?";s.1O="3z"}G(s.1O=="3z"&&(s.L&&s.L.1I(2Z)||s.1a.1I(2Z))){g="4P"+B++;G(s.L)s.L=(s.L+"").1o(2Z,"="+g+"$1");s.1a=s.1a.1o(2Z,"="+g+"$1");s.1O="1m";1b[g]=H(a){L=a;1W();1J();1b[g]=12;1U{2U 1b[g]}1V(e){}G(i)i.37(h)}}G(s.1O=="1m"&&s.1Y==U)s.1Y=Q;G(s.1Y===Q&&O=="2P"){J j=1z();J k=s.1a.1o(/(\\?|&)3m=.*?(&|$)/,"$ap="+j+"$2");s.1a=k+((k==s.1a)?(s.1a.1I(/\\?/)?"&":"?")+"3m="+j:"")}G(s.L&&O=="2P"){s.1a+=(s.1a.1I(/\\?/)?"&":"?")+s.L;s.L=U}G(s.26&&!D.4O++)D.W.1P("7H");J n=/^(?:\\w+:)?\\/\\/([^\\/?#]+)/;G(s.1O=="1m"&&O=="2P"&&n.11(s.1a)&&n.2D(s.1a)[1]!=5Z.al){J i=S.3H("6w")[0];J h=S.3h("1m");h.4d=s.1a;G(s.7t)h.aj=s.7t;G(!g){J l=Q;h.ah=h.ag=H(){G(!l&&(!7.3f||7.3f=="68"||7.3f=="1J")){l=M;1W();1J();i.37(h)}}}i.3U(h);I 12}J m=Q;J c=1b.7s?2B 7s("ae.ac"):2B 7r();G(s.5Y)c.6R(O,s.1a,s.31,s.5Y,s.3Q);N c.6R(O,s.1a,s.31);1U{G(s.L)c.4B("ab-aa",s.7z);G(s.5S)c.4B("a9-5R-a8",D.4z[s.1a]||"a7, a6 a5 a4 5N:5N:5N a2");c.4B("X-9Z-9Y","7r");c.4B("9W",s.1O&&s.4Q[s.1O]?s.4Q[s.1O]+", */*":s.4Q.4w)}1V(e){}G(s.7m&&s.7m(c,s)===Q){s.26&&D.4O--;c.7l();I Q}G(s.26)D.W.1P("7B",[c,s]);J d=H(a){G(!m&&c&&(c.3f==4||a=="2T")){m=M;G(f){7k(f);f=U}1u=a=="2T"&&"2T"||!D.7j(c)&&"3e"||s.5S&&D.7h(c,s.1a)&&"7J"||"1W";G(1u=="1W"){1U{L=D.6X(c,s.1O,s.9S)}1V(e){1u="5J"}}G(1u=="1W"){J b;1U{b=c.5I("7g-5R")}1V(e){}G(s.5S&&b)D.4z[s.1a]=b;G(!g)1W()}N D.5H(s,c,1u);1J();G(s.31)c=U}};G(s.31){J f=4I(d,13);G(s.2T>0)3B(H(){G(c){c.7l();G(!m)d("2T")}},s.2T)}1U{c.9P(s.L)}1V(e){D.5H(s,c,U,e)}G(!s.31)d();H 1W(){G(s.1W)s.1W(L,1u);G(s.26)D.W.1P("7C",[c,s])}H 1J(){G(s.1J)s.1J(c,1u);G(s.26)D.W.1P("7F",[c,s]);G(s.26&&!--D.4O)D.W.1P("7G")}I c},5H:H(s,a,b,e){G(s.3e)s.3e(a,b,e);G(s.26)D.W.1P("7D",[a,s,e])},4O:0,7j:H(a){1U{I!a.1u&&5Z.9O=="5p:"||(a.1u>=7e&&a.1u<9N)||a.1u==7c||a.1u==9K||D.14.2k&&a.1u==12}1V(e){}I Q},7h:H(a,c){1U{J b=a.5I("7g-5R");I a.1u==7c||b==D.4z[c]||D.14.2k&&a.1u==12}1V(e){}I Q},6X:H(a,c,b){J d=a.5I("9J-O"),2N=c=="2N"||!c&&d&&d.1h("2N")>=0,L=2N?a.9I:a.4U;G(2N&&L.1C.2j=="5J")7p"5J";G(b)L=b(L,c);G(c=="1m")D.5u(L);G(c=="3z")L=6u("("+L+")");I L},3n:H(a){J s=[];G(a.1q==2p||a.5w)D.P(a,H(){s.1p(3u(7.34)+"="+3u(7.2x))});N R(J j 1n a)G(a[j]&&a[j].1q==2p)D.P(a[j],H(){s.1p(3u(j)+"="+3u(7))});N s.1p(3u(j)+"="+3u(D.1D(a[j])?a[j]():a[j]));I s.6s("&").1o(/%20/g,"+")}});D.17.1l({1N:H(c,b){I c?7.2g({1Z:"1N",2h:"1N",1y:"1N"},c,b):7.1E(":1G").P(H(){7.V.18=7.5D||"";G(D.1g(7,"18")=="2F"){J a=D("<"+7.2j+" />").6P("1c");7.V.18=a.1g("18");G(7.V.18=="2F")7.V.18="3I";a.21()}}).3l()},1M:H(b,a){I b?7.2g({1Z:"1M",2h:"1M",1y:"1M"},b,a):7.1E(":4j").P(H(){7.5D=7.5D||D.1g(7,"18");7.V.18="2F"}).3l()},78:D.17.2m,2m:H(a,b){I D.1D(a)&&D.1D(b)?7.78.1w(7,19):a?7.2g({1Z:"2m",2h:"2m",1y:"2m"},a,b):7.P(H(){D(7)[D(7).3F(":1G")?"1N":"1M"]()})},9G:H(b,a){I 7.2g({1Z:"1N"},b,a)},9F:H(b,a){I 7.2g({1Z:"1M"},b,a)},9E:H(b,a){I 7.2g({1Z:"2m"},b,a)},9D:H(b,a){I 7.2g({1y:"1N"},b,a)},9M:H(b,a){I 7.2g({1y:"1M"},b,a)},9C:H(c,a,b){I 7.2g({1y:a},c,b)},2g:H(k,j,i,g){J h=D.77(j,i,g);I 7[h.36===Q?"P":"36"](H(){G(7.16!=1)I Q;J f=D.1l({},h),p,1G=D(7).3F(":1G"),46=7;R(p 1n k){G(k[p]=="1M"&&1G||k[p]=="1N"&&!1G)I f.1J.1k(7);G(p=="1Z"||p=="2h"){f.18=D.1g(7,"18");f.33=7.V.33}}G(f.33!=U)7.V.33="1G";f.45=D.1l({},k);D.P(k,H(c,a){J e=2B D.28(46,f,c);G(/2m|1N|1M/.11(a))e[a=="2m"?1G?"1N":"1M":a](k);N{J b=a.6r().1I(/^([+-]=)?([\\d+-.]+)(.*)$/),2b=e.1t(M)||0;G(b){J d=3d(b[2]),2M=b[3]||"2X";G(2M!="2X"){46.V[c]=(d||1)+2M;2b=((d||1)/e.1t(M))*2b;46.V[c]=2b+2M}G(b[1])d=((b[1]=="-="?-1:1)*d)+2b;e.3G(2b,d,2M)}N e.3G(2b,a,"")}});I M})},36:H(a,b){G(D.1D(a)||(a&&a.1q==2p)){b=a;a="28"}G(!a||(1j a=="23"&&!b))I A(7[0],a);I 7.P(H(){G(b.1q==2p)A(7,a,b);N{A(7,a).1p(b);G(A(7,a).K==1)b.1k(7)}})},9X:H(b,c){J a=D.3O;G(b)7.36([]);7.P(H(){R(J i=a.K-1;i>=0;i--)G(a[i].T==7){G(c)a[i](M);a.7n(i,1)}});G(!c)7.5A();I 7}});J A=H(b,c,a){G(b){c=c||"28";J q=D.L(b,c+"36");G(!q||a)q=D.L(b,c+"36",D.2d(a))}I q};D.17.5A=H(a){a=a||"28";I 7.P(H(){J q=A(7,a);q.4s();G(q.K)q[0].1k(7)})};D.1l({77:H(b,a,c){J d=b&&b.1q==a0?b:{1J:c||!c&&a||D.1D(b)&&b,2u:b,41:c&&a||a&&a.1q!=9t&&a};d.2u=(d.2u&&d.2u.1q==4L?d.2u:D.28.5K[d.2u])||D.28.5K.74;d.5M=d.1J;d.1J=H(){G(d.36!==Q)D(7).5A();G(D.1D(d.5M))d.5M.1k(7)};I d},41:{73:H(p,n,b,a){I b+a*p},5P:H(p,n,b,a){I((-29.9r(p*29.9q)/2)+0.5)*a+b}},3O:[],48:U,28:H(b,c,a){7.15=c;7.T=b;7.1i=a;G(!c.3Z)c.3Z={}}});D.28.44={4D:H(){G(7.15.2Y)7.15.2Y.1k(7.T,7.1z,7);(D.28.2Y[7.1i]||D.28.2Y.4w)(7);G(7.1i=="1Z"||7.1i=="2h")7.T.V.18="3I"},1t:H(a){G(7.T[7.1i]!=U&&7.T.V[7.1i]==U)I 7.T[7.1i];J r=3d(D.1g(7.T,7.1i,a));I r&&r>-9p?r:3d(D.2a(7.T,7.1i))||0},3G:H(c,b,d){7.5V=1z();7.2b=c;7.3l=b;7.2M=d||7.2M||"2X";7.1z=7.2b;7.2S=7.4N=0;7.4D();J e=7;H t(a){I e.2Y(a)}t.T=7.T;D.3O.1p(t);G(D.48==U){D.48=4I(H(){J a=D.3O;R(J i=0;i<a.K;i++)G(!a[i]())a.7n(i--,1);G(!a.K){7k(D.48);D.48=U}},13)}},1N:H(){7.15.3Z[7.1i]=D.1K(7.T.V,7.1i);7.15.1N=M;7.3G(0,7.1t());G(7.1i=="2h"||7.1i=="1Z")7.T.V[7.1i]="9m";D(7.T).1N()},1M:H(){7.15.3Z[7.1i]=D.1K(7.T.V,7.1i);7.15.1M=M;7.3G(7.1t(),0)},2Y:H(a){J t=1z();G(a||t>7.15.2u+7.5V){7.1z=7.3l;7.2S=7.4N=1;7.4D();7.15.45[7.1i]=M;J b=M;R(J i 1n 7.15.45)G(7.15.45[i]!==M)b=Q;G(b){G(7.15.18!=U){7.T.V.33=7.15.33;7.T.V.18=7.15.18;G(D.1g(7.T,"18")=="2F")7.T.V.18="3I"}G(7.15.1M)7.T.V.18="2F";G(7.15.1M||7.15.1N)R(J p 1n 7.15.45)D.1K(7.T.V,p,7.15.3Z[p])}G(b)7.15.1J.1k(7.T);I Q}N{J n=t-7.5V;7.4N=n/7.15.2u;7.2S=D.41[7.15.41||(D.41.5P?"5P":"73")](7.4N,n,0,1,7.15.2u);7.1z=7.2b+((7.3l-7.2b)*7.2S);7.4D()}I M}};D.1l(D.28,{5K:{9l:9j,9i:7e,74:9g},2Y:{2e:H(a){a.T.2e=a.1z},2c:H(a){a.T.2c=a.1z},1y:H(a){D.1K(a.T.V,"1y",a.1z)},4w:H(a){a.T.V[a.1i]=a.1z+a.2M}}});D.17.2i=H(){J b=0,1S=0,T=7[0],3q;G(T)ao(D.14){J d=T.1d,4a=T,1s=T.1s,1Q=T.2z,5U=2k&&3r(5B)<9c&&!/9a/i.11(v),1g=D.2a,3c=1g(T,"30")=="3c";G(T.7y){J c=T.7y();1e(c.1A+29.2f(1Q.1C.2e,1Q.1c.2e),c.1S+29.2f(1Q.1C.2c,1Q.1c.2c));1e(-1Q.1C.6b,-1Q.1C.6a)}N{1e(T.5X,T.5W);1B(1s){1e(1s.5X,1s.5W);G(42&&!/^t(98|d|h)$/i.11(1s.2j)||2k&&!5U)2C(1s);G(!3c&&1g(1s,"30")=="3c")3c=M;4a=/^1c$/i.11(1s.2j)?4a:1s;1s=1s.1s}1B(d&&d.2j&&!/^1c|2K$/i.11(d.2j)){G(!/^96|1T.*$/i.11(1g(d,"18")))1e(-d.2e,-d.2c);G(42&&1g(d,"33")!="4j")2C(d);d=d.1d}G((5U&&(3c||1g(4a,"30")=="5x"))||(42&&1g(4a,"30")!="5x"))1e(-1Q.1c.5X,-1Q.1c.5W);G(3c)1e(29.2f(1Q.1C.2e,1Q.1c.2e),29.2f(1Q.1C.2c,1Q.1c.2c))}3q={1S:1S,1A:b}}H 2C(a){1e(D.2a(a,"6V",M),D.2a(a,"6U",M))}H 1e(l,t){b+=3r(l,10)||0;1S+=3r(t,10)||0}I 3q};D.17.1l({30:H(){J a=0,1S=0,3q;G(7[0]){J b=7.1s(),2i=7.2i(),4c=/^1c|2K$/i.11(b[0].2j)?{1S:0,1A:0}:b.2i();2i.1S-=25(7,\'94\');2i.1A-=25(7,\'aF\');4c.1S+=25(b,\'6U\');4c.1A+=25(b,\'6V\');3q={1S:2i.1S-4c.1S,1A:2i.1A-4c.1A}}I 3q},1s:H(){J a=7[0].1s;1B(a&&(!/^1c|2K$/i.11(a.2j)&&D.1g(a,\'30\')==\'93\'))a=a.1s;I D(a)}});D.P([\'5e\',\'5G\'],H(i,b){J c=\'4y\'+b;D.17[c]=H(a){G(!7[0])I;I a!=12?7.P(H(){7==1b||7==S?1b.92(!i?a:D(1b).2e(),i?a:D(1b).2c()):7[c]=a}):7[0]==1b||7[0]==S?46[i?\'aI\':\'aJ\']||D.71&&S.1C[c]||S.1c[c]:7[0][c]}});D.P(["6N","4b"],H(i,b){J c=i?"5e":"5G",4f=i?"6k":"6i";D.17["5s"+b]=H(){I 7[b.3y()]()+25(7,"57"+c)+25(7,"57"+4f)};D.17["90"+b]=H(a){I 7["5s"+b]()+25(7,"2C"+c+"4b")+25(7,"2C"+4f+"4b")+(a?25(7,"6S"+c)+25(7,"6S"+4f):0)}})})();',62,669,'|||||||this|||||||||||||||||||||||||||||||||||if|function|return|var|length|data|true|else|type|each|false|for|document|elem|null|style|event||nodeName|||test|undefined||browser|options|nodeType|fn|display|arguments|url|window|body|parentNode|add|msie|css|indexOf|prop|typeof|call|extend|script|in|replace|push|constructor|text|offsetParent|cur|status|div|apply|firstChild|opacity|now|left|while|documentElement|isFunction|filter|className|hidden|handle|match|complete|attr|ret|hide|show|dataType|trigger|doc|split|top|table|try|catch|success|break|cache|height||remove|tbody|string|guid|num|global|ready|fx|Math|curCSS|start|scrollTop|makeArray|scrollLeft|max|animate|width|offset|tagName|safari|map|toggle||done|Array|find|toUpperCase|button|special|duration|id|copy|value|handler|ownerDocument|select|new|border|exec|stack|none|opera|nextSibling|pushStack|target|html|inArray|unit|xml|bind|GET|isReady|merge|pos|timeout|delete|one|selected|px|step|jsre|position|async|preventDefault|overflow|name|which|queue|removeChild|namespace|insertBefore|nth|removeData|fixed|parseFloat|error|readyState|multiFilter|createElement|rl|re|trim|end|_|param|first|get|results|parseInt|slice|childNodes|encodeURIComponent|append|events|elems|toLowerCase|json|readyList|setTimeout|grep|mouseenter|color|is|custom|getElementsByTagName|block|stopPropagation|addEventListener|callee|proxy|mouseleave|timers|defaultView|password|disabled|last|has|appendChild|form|domManip|props|ajax|orig|set|easing|mozilla|load|prototype|curAnim|self|charCode|timerId|object|offsetChild|Width|parentOffset|src|unbind|br|currentStyle|clean|float|visible|relatedTarget|previousSibling|handlers|isXMLDoc|on|setup|nodeIndex|unique|shift|javascript|child|RegExp|_default|deep|scroll|lastModified|teardown|setRequestHeader|timeStamp|update|empty|tr|getAttribute|innerHTML|setInterval|checked|fromElement|Number|jQuery|state|active|jsonp|accepts|application|dir|input|responseText|click|styleSheets|unload|not|lastToggle|outline|mouseout|getPropertyValue|mouseover|getComputedStyle|bindReady|String|padding|pageX|metaKey|keyCode|getWH|andSelf|clientX|Left|all|visibility|container|index|init|triggered|removeAttribute|classFilter|prevObject|submit|file|after|windowData|inner|client|globalEval|sibling|jquery|absolute|clone|wrapAll|dequeue|version|triggerHandler|oldblock|ctrlKey|createTextNode|Top|handleError|getResponseHeader|parsererror|speeds|checkbox|old|00|radio|swing|href|Modified|ifModified|lastChild|safari2|startTime|offsetTop|offsetLeft|username|location|ajaxSettings|getElementById|isSimple|values|selectedIndex|runtimeStyle|rsLeft|_load|loaded|DOMContentLoaded|clientTop|clientLeft|toElement|srcElement|val|pageY|POST|unshift|Bottom|clientY|Right|fix|exclusive|detachEvent|cloneNode|removeEventListener|swap|toString|join|attachEvent|eval|substr|head|parse|textarea|reset|image|zoom|odd|even|before|prepend|exclude|expr|quickClass|quickID|uuid|quickChild|continue|Height|textContent|appendTo|contents|open|margin|evalScript|borderTopWidth|borderLeftWidth|parent|httpData|setArray|CSS1Compat|compatMode|boxModel|cssFloat|linear|def|webkit|nodeValue|speed|_toggle|eq|100|replaceWith|304|concat|200|alpha|Last|httpNotModified|getAttributeNode|httpSuccess|clearInterval|abort|beforeSend|splice|styleFloat|throw|colgroup|XMLHttpRequest|ActiveXObject|scriptCharset|callback|fieldset|multiple|processData|getBoundingClientRect|contentType|link|ajaxSend|ajaxSuccess|ajaxError|col|ajaxComplete|ajaxStop|ajaxStart|serializeArray|notmodified|keypress|keydown|change|mouseup|mousedown|dblclick|focus|blur|stylesheet|hasClass|rel|doScroll|black|hover|solid|cancelBubble|returnValue|wheelDelta|view|round|shiftKey|resize|screenY|screenX|relatedNode|mousemove|prevValue|originalTarget|offsetHeight|keyup|newValue|offsetWidth|eventPhase|detail|currentTarget|cancelable|bubbles|attrName|attrChange|altKey|originalEvent|charAt|0n|substring|animated|header|noConflict|line|enabled|innerText|contains|only|weight|font|gt|lt|uFFFF|u0128|size|417|Boolean|Date|toggleClass|removeClass|addClass|removeAttr|replaceAll|insertAfter|prependTo|wrap|contentWindow|contentDocument|iframe|children|siblings|prevAll|wrapInner|nextAll|outer|prev|scrollTo|static|marginTop|next|inline|parents|able|cellSpacing|adobeair|cellspacing|522|maxLength|maxlength|readOnly|400|readonly|fast|600|class|slow|1px|htmlFor|reverse|10000|PI|cos|compatible|Function|setData|ie|ra|it|rv|getData|userAgent|navigator|fadeTo|fadeIn|slideToggle|slideUp|slideDown|ig|responseXML|content|1223|NaN|fadeOut|300|protocol|send|setAttribute|option|dataFilter|cssText|changed|be|Accept|stop|With|Requested|Object|can|GMT|property|1970|Jan|01|Thu|Since|If|Type|Content|XMLHTTP|th|Microsoft|td|onreadystatechange|onload|cap|charset|colg|host|tfoot|specified|with|1_|thead|leg|plain|attributes|opt|embed|urlencoded|www|area|hr|ajaxSetup|meta|post|getJSON|getScript|marginLeft|img|elements|pageYOffset|pageXOffset|abbr|serialize|pixelLeft'.split('|'),0,{}))
View
1 public/javascripts/wymeditor/jquery/jquery.ui.draggable.js
@@ -0,0 +1 @@
+eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(c(A){A.2I("g.i",A.2c({},A.g.2L,{2G:c(){a B=4.9;7(B.d=="24"&&!(/(l|V|13)/).1h(4.j.e("m"))){4.j.e("m","l")}4.j.1M("g-i");(B.1O&&4.j.1M("g-i-1O"));4.2M()},2n:c(F){a H=4.9;7(4.d||H.1O||A(F.2a).2A(".g-2F-1G")){n 15}a C=!4.9.1G||!A(4.9.1G,4.j).1C?v:15;A(4.9.1G,4.j).2C("*").2E().1d(c(){7(4==F.2a){C=v}});7(!C){n 15}7(A.g.1b){A.g.1b.2Z=4}4.d=A.2P(H.d)?A(H.d.30(4.j[0],[F])):(H.d=="28"?4.j.28():4.j);7(!4.d.31("12").1C){4.d.1u((H.1u=="k"?4.j[0].1t:H.1u))}7(4.d[0]!=4.j[0]&&!(/(13|V)/).1h(4.d.e("m"))){4.d.e("m","V")}4.S={6:(o(4.j.e("33"),10)||0),5:(o(4.j.e("2S"),10)||0)};4.z=4.d.e("m");4.8=4.j.8();4.8={5:4.8.5-4.S.5,6:4.8.6-4.S.6};4.8.r={6:F.1r-4.8.6,5:F.1s-4.8.5};4.p=4.d.p();a B=4.p.8();7(4.p[0]==f.12&&A.2V.2Y){B={5:0,6:0}}4.8.k={5:B.5+(o(4.p.e("1N"),10)||0),6:B.6+(o(4.p.e("1T"),10)||0)};a E=4.j.m();4.8.l=4.z=="l"?{5:E.5-(o(4.d.e("5"),10)||0)+4.p[0].q,6:E.6-(o(4.d.e("6"),10)||0)+4.p[0].s}:{5:0,6:0};4.1g=4.1S(F);4.w={t:4.d.26(),u:4.d.1Q()};7(H.16){7(H.16.6!=1A){4.8.r.6=H.16.6+4.S.6}7(H.16.2s!=1A){4.8.r.6=4.w.t-H.16.2s+4.S.6}7(H.16.5!=1A){4.8.r.5=H.16.5+4.S.5}7(H.16.2k!=1A){4.8.r.5=4.w.u-H.16.2k+4.S.5}}7(H.h){7(H.h=="k"){H.h=4.d[0].1t}7(H.h=="f"||H.h=="1o"){4.h=[0-4.8.l.6-4.8.k.6,0-4.8.l.5-4.8.k.5,A(H.h=="f"?f:1o).t()-4.8.l.6-4.8.k.6-4.w.t-4.S.6-(o(4.j.e("2i"),10)||0),(A(H.h=="f"?f:1o).u()||f.12.1t.2u)-4.8.l.5-4.8.k.5-4.w.u-4.S.5-(o(4.j.e("2h"),10)||0)]}7(!(/^(f|1o|k)$/).1h(H.h)){a D=A(H.h)[0];a G=A(H.h).8();4.h=[G.6+(o(A(D).e("1T"),10)||0)-4.8.l.6-4.8.k.6,G.5+(o(A(D).e("1N"),10)||0)-4.8.l.5-4.8.k.5,G.6+T.2g(D.2U,D.1U)-(o(A(D).e("1T"),10)||0)-4.8.l.6-4.8.k.6-4.w.t-4.S.6-(o(4.j.e("2i"),10)||0),G.5+T.2g(D.2u,D.1V)-(o(A(D).e("1N"),10)||0)-4.8.l.5-4.8.k.5-4.w.u-4.S.5-(o(4.j.e("2h"),10)||0)]}}4.19("18",F);4.w={t:4.d.26(),u:4.d.1Q()};7(A.g.1b&&!H.2m){A.g.1b.2Q(4,F)}4.d.1M("g-i-2p");4.2d(F);n v},X:c(C,D){7(!D){D=4.m}a B=C=="V"?1:-1;n{5:(D.5+4.8.l.5*B+4.8.k.5*B-(4.z=="13"||(4.z=="V"&&4.p[0]==f.12)?0:4.p[0].q)*B+(4.z=="13"?A(f).q():0)*B+4.S.5*B),6:(D.6+4.8.l.6*B+4.8.k.6*B-(4.z=="13"||(4.z=="V"&&4.p[0]==f.12)?0:4.p[0].s)*B+(4.z=="13"?A(f).s():0)*B+4.S.6*B)}},1S:c(E){a F=4.9;a B={5:(E.1s-4.8.r.5-4.8.l.5-4.8.k.5+(4.z=="13"||(4.z=="V"&&4.p[0]==f.12)?0:4.p[0].q)-(4.z=="13"?A(f).q():0)),6:(E.1r-4.8.r.6-4.8.l.6-4.8.k.6+(4.z=="13"||(4.z=="V"&&4.p[0]==f.12)?0:4.p[0].s)-(4.z=="13"?A(f).s():0))};7(!4.1g){n B}7(4.h){7(B.6<4.h[0]){B.6=4.h[0]}7(B.5<4.h[1]){B.5=4.h[1]}7(B.6>4.h[2]){B.6=4.h[2]}7(B.5>4.h[3]){B.5=4.h[3]}}7(F.1a){a D=4.1g.5+T.2l((B.5-4.1g.5)/F.1a[1])*F.1a[1];B.5=4.h?(!(D<4.h[1]||D>4.h[3])?D:(!(D<4.h[1])?D-F.1a[1]:D+F.1a[1])):D;a C=4.1g.6+T.2l((B.6-4.1g.6)/F.1a[0])*F.1a[0];B.6=4.h?(!(C<4.h[0]||C>4.h[2])?C:(!(C<4.h[0])?C-F.1a[0]:C+F.1a[0])):C}n B},2d:c(B){4.m=4.1S(B);4.1j=4.X("V");4.m=4.19("1c",B)||4.m;7(!4.9.1w||4.9.1w!="y"){4.d[0].1x.6=4.m.6+"1J"}7(!4.9.1w||4.9.1w!="x"){4.d[0].1x.5=4.m.5+"1J"}7(A.g.1b){A.g.1b.1c(4,B)}n 15},2b:c(C){a D=15;7(A.g.1b&&!4.9.2m){a D=A.g.1b.34(4,C)}7((4.9.1m=="2N"&&!D)||(4.9.1m=="2D"&&D)||4.9.1m===v){a B=4;A(4.d).2B(4.1g,o(4.9.1m,10)||2O,c(){B.19("1k",C);B.22()})}1y{4.19("1k",C);4.22()}n 15},22:c(){4.d.2o("g-i-2p");7(4.9.d!="24"&&!4.1z){4.d.2e()}4.d=2K;4.1z=15},2H:{},23:c(B){n{d:4.d,m:4.m,1P:4.1j,9:4.9}},19:c(C,B){A.g.17.2t(4,C,[B,4.23()]);7(C=="1c"){4.1j=4.X("V")}n 4.j.2z(C=="1c"?C:"1c"+C,[B,4.23()],4.9[C])},2T:c(){7(!4.j.U("i")){n}4.j.3d("i").3x(".i").2o("g-i");4.35()}}));A.2c(A.g.i,{3l:{1u:"k",1w:15,3r:":3p",3q:0,3n:1,d:"24"}});A.g.17.1e("i","1p",{18:c(D,C){a B=A("12");7(B.e("1p")){C.9.21=B.e("1p")}B.e("1p",C.9.1p)},1k:c(C,B){7(B.9.21){A("12").e("1p",B.9.21)}}});A.g.17.1e("i","Z",{18:c(D,C){a B=A(C.d);7(B.e("Z")){C.9.1W=B.e("Z")}B.e("Z",C.9.Z)},1k:c(C,B){7(B.9.1W){A(B.d).e("Z",B.9.1W)}}});A.g.17.1e("i","1l",{18:c(D,C){a B=A(C.d);7(B.e("1l")){C.9.1X=B.e("1l")}B.e("1l",C.9.1l)},1k:c(C,B){7(B.9.1X){A(B.d).e("1l",B.9.1X)}}});A.g.17.1e("i","1K",{18:c(C,B){A(B.9.1K===v?"3v":B.9.1K).1d(c(){A(\'<1Y 3y="g-i-1K" 1x="3t: #3u;"></1Y>\').e({t:4.1U+"1J",u:4.1V+"1J",m:"V",1l:"0.3a",Z:3k}).e(A(4).8()).1u("12")})},1k:c(C,B){A("1Y.37").1d(c(){4.1t.3c(4)})}});A.g.17.1e("i","1v",{18:c(D,C){a E=C.9;a B=A(4).U("i");E.14=E.14||20;E.11=E.11||20;B.W=c(F){2f{7(/1D|1v/.1h(F.e("1L"))||(/1D|1v/).1h(F.e("1L-y"))){n F}F=F.k()}2j(F[0].1t);n A(f)}(4);B.Y=c(F){2f{7(/1D|1v/.1h(F.e("1L"))||(/1D|1v/).1h(F.e("1L-x"))){n F}F=F.k()}2j(F[0].1t);n A(f)}(4);7(B.W[0]!=f&&B.W[0].1F!="1E"){B.1Z=B.W.8()}7(B.Y[0]!=f&&B.Y[0].1F!="1E"){B.25=B.Y.8()}},1c:c(D,C){a E=C.9;a B=A(4).U("i");7(B.W[0]!=f&&B.W[0].1F!="1E"){7((B.1Z.5+B.W[0].1V)-D.1s<E.14){B.W[0].q=B.W[0].q+E.11}7(D.1s-B.1Z.5<E.14){B.W[0].q=B.W[0].q-E.11}}1y{7(D.1s-A(f).q()<E.14){A(f).q(A(f).q()-E.11)}7(A(1o).u()-(D.1s-A(f).q())<E.14){A(f).q(A(f).q()+E.11)}}7(B.Y[0]!=f&&B.Y[0].1F!="1E"){7((B.25.6+B.Y[0].1U)-D.1r<E.14){B.Y[0].s=B.Y[0].s+E.11}7(D.1r-B.25.6<E.14){B.Y[0].s=B.Y[0].s-E.11}}1y{7(D.1r-A(f).s()<E.14){A(f).s(A(f).s()-E.11)}7(A(1o).t()-(D.1r-A(f).s())<E.14){A(f).s(A(f).s()+E.11)}}}});A.g.17.1e("i","1R",{18:c(D,C){a B=A(4).U("i");B.1i=[];A(C.9.1R===v?".g-i":C.9.1R).1d(c(){a F=A(4);a E=F.8();7(4!=B.j[0]){B.1i.2x({2q:4,t:F.26(),u:F.1Q(),5:E.5,6:E.6})}})},1c:c(J,N){a I=A(4).U("i");a L=N.9.3j||20;a D=N.1P.6,C=D+I.w.t,P=N.1P.5,O=P+I.w.u;3s(a H=I.1i.1C-1;H>=0;H--){a E=I.1i[H].6,B=E+I.1i[H].t,R=I.1i[H].5,M=R+I.1i[H].u;7(!((E-L<D&&D<B+L&&R-L<P&&P<M+L)||(E-L<D&&D<B+L&&R-L<O&&O<M+L)||(E-L<C&&C<B+L&&R-L<P&&P<M+L)||(E-L<C&&C<B+L&&R-L<O&&O<M+L))){3w}7(N.9.2w!="3b"){a K=T.1f(R-O)<=20;a Q=T.1f(M-P)<=20;a G=T.1f(E-C)<=20;a F=T.1f(B-D)<=20;7(K){N.m.5=I.X("l",{5:R-I.w.u,6:0}).5}7(Q){N.m.5=I.X("l",{5:M,6:0}).5}7(G){N.m.6=I.X("l",{5:0,6:E-I.w.t}).6}7(F){N.m.6=I.X("l",{5:0,6:B}).6}}7(N.9.2w!="36"){a K=T.1f(R-P)<=20;a Q=T.1f(M-O)<=20;a G=T.1f(E-D)<=20;a F=T.1f(B-C)<=20;7(K){N.m.5=I.X("l",{5:R,6:0}).5}7(Q){N.m.5=I.X("l",{5:M-I.w.u,6:0}).5}7(G){N.m.6=I.X("l",{5:0,6:E}).6}7(F){N.m.6=I.X("l",{5:0,6:B-I.w.t}).6}}}}});A.g.17.1e("i","2v",{18:c(D,C){a B=A(4).U("i");B.1H=[];A(C.9.2v).1d(c(){7(A.U(4,"27")){a E=A.U(4,"27");B.1H.2x({b:E,2y:E.9.1m});E.3g();E.19("39",D,B)}})},1k:c(D,C){a B=A(4).U("i");A.1d(B.1H,c(){7(4.b.1q){4.b.1q=0;B.1z=v;4.b.1z=15;7(4.2y){4.b.9.1m=v}4.b.2b(D);4.b.j.2z("3f",[D,A.2c(4.b.g(),{3e:B.j})],4.b.9.3h);4.b.9.d=4.b.9.29}1y{4.b.19("3i",D,B)}})},1c:c(F,E){a D=A(4).U("i"),B=4;a C=c(K){a H=K.6,J=H+K.t,I=K.5,G=I+K.u;n(H<(4.1j.6+4.8.r.6)&&(4.1j.6+4.8.r.6)<J&&I<(4.1j.5+4.8.r.5)&&(4.1j.5+4.8.r.5)<G)};A.1d(D.1H,c(G){7(C.2t(D,4.b.3o)){7(!4.b.1q){4.b.1q=1;4.b.1I=A(B).28().1u(4.b.j).U("27-2q",v);4.b.9.29=4.b.9.d;4.b.9.d=c(){n E.d[0]};F.2a=4.b.1I[0];4.b.3m(F,v);4.b.2n(F,v,v);4.b.8.r.5=D.8.r.5;4.b.8.r.6=D.8.r.6;4.b.8.k.6-=D.8.k.6-4.b.8.k.6;4.b.8.k.5-=D.8.k.5-4.b.8.k.5;D.19("2J",F)}7(4.b.1I){4.b.2d(F)}}1y{7(4.b.1q){4.b.1q=0;4.b.1z=v;4.b.9.1m=15;4.b.2b(F,v);4.b.9.d=4.b.9.29;4.b.1I.2e();7(4.b.2r){4.b.2r.2e()}D.19("32",F)}}})}});A.g.17.1e("i","1n",{18:c(D,B){a C=A.2X(A(B.9.1n.2W)).2R(c(F,E){n(o(A(F).e("Z"),10)||B.9.1n.1B)-(o(A(E).e("Z"),10)||B.9.1n.1B)});A(C).1d(c(E){4.1x.Z=B.9.1n.1B+E});4[0].1x.Z=B.9.1n.1B+C.1C}})})(38);',62,221,'||||this|top|left|if|offset|options|var|instance|function|helper|css|document|ui|containment|draggable|element|parent|relative|position|return|parseInt|offsetParent|scrollTop|click|scrollLeft|width|height|true|helperProportions|||cssPosition|||||||||||||||||||margins|Math|data|absolute|overflowY|convertPositionTo|overflowX|zIndex||scrollSpeed|body|fixed|scrollSensitivity|false|cursorAt|plugin|start|propagate|grid|ddmanager|drag|each|add|abs|originalPosition|test|snapElements|positionAbs|stop|opacity|revert|stack|window|cursor|isOver|pageX|pageY|parentNode|appendTo|scroll|axis|style|else|cancelHelperRemoval|undefined|min|length|auto|HTML|tagName|handle|sortables|currentItem|px|iframeFix|overflow|addClass|borderTopWidth|disabled|absolutePosition|outerHeight|snap|generatePosition|borderLeftWidth|offsetWidth|offsetHeight|_zIndex|_opacity|div|overflowYOffset||_cursor|clear|uiHash|original|overflowXOffset|outerWidth|sortable|clone|_helper|target|mouseStop|extend|mouseDrag|remove|do|max|marginBottom|marginRight|while|bottom|round|dropBehaviour|mouseStart|removeClass|dragging|item|placeholder|right|call|scrollHeight|connectToSortable|snapMode|push|shouldRevert|triggerHandler|is|animate|find|valid|andSelf|resizable|init|plugins|widget|toSortable|null|mouse|mouseInit|invalid|500|isFunction|prepareOffsets|sort|marginTop|destroy|scrollWidth|browser|group|makeArray|mozilla|current|apply|parents|fromSortable|marginLeft|drop|mouseDestroy|outer|DragDropIframeFix|jQuery|activate|001|inner|removeChild|removeData|sender|sortreceive|refreshItems|receive|deactivate|snapTolerance|1000|defaults|mouseCapture|distance|containerCache|input|delay|cancel|for|background|fff|iframe|continue|unbind|class'.split('|'),0,{}))
View
1 public/javascripts/wymeditor/jquery/jquery.ui.js
@@ -0,0 +1 @@
+eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(3(C){C.a={1N:{19:3(E,F,H){6 G=C.a[E].j;1d(6 D 1O H){G.w[D]=G.w[D]||[];G.w[D].1P([F,H[D]])}},1b:3(D,F,E){6 H=D.w[F];5(!H){4}1d(6 G=0;G<H.1M;G++){5(D.b[H[G][0]]){H[G][1].q(D.8,E)}}}},n:{},f:3(D){5(C.a.n[D]){4 C.a.n[D]}6 E=C(\'<1L 1H="a-1I">\').1i(D).f({1J:"1K",X:"-1f",1Q:"-1f",1R:"1X"}).1Y("13");C.a.n[D]=!!((!(/1Z|1W/).g(E.f("1V"))||(/^[1-9]/).g(E.f("1S"))||(/^[1-9]/).g(E.f("1G"))||!(/14/).g(E.f("1U"))||!(/20|1C\\(0, 0, 0, 0\\)/).g(E.f("1y"))));1w{C("13").1a(0).1z(E.1a(0))}1F(F){}4 C.a.n[D]},1A:3(D){D.l="1g";D.17=3(){4 7};5(D.r){D.r.15="14"}},1D:3(D){D.l="1B";D.17=3(){4 d};5(D.r){D.r.15=""}},1E:3(G,E){6 D=/X/.g(E||"X")?"23":"21",F=7;5(G[D]>0){4 d}G[D]=1;F=G[D]>0?d:7;G[D]=0;4 F}};6 B=C.P.p;C.P.p=3(){C("*",2).19(2).2m("p");4 B.q(2,1c)};3 A(E,F,G){6 D=C[E][F].2j||[];D=(R D=="N"?D.V(/,?\\s+/):D);4(C.2i(G,D)!=-1)}C.k=3(E,D){6 F=E.V(".")[0];E=E.V(".")[1];C.P[E]=3(J){6 H=(R J=="N"),I=2n.j.2o.1b(1c,1);5(H&&A(F,E,J)){6 G=C.M(2[0],E);4(G?G[J].q(G,I):2p)}4 2.2g(3(){6 K=C.M(2,E);5(H&&K&&C.2f(K[J])){K[J].q(K,I)}27{5(!H){C.M(2,E,24 C[F][E](2,J))}}})};C[F][E]=3(I,H){6 G=2;2.e=E;2.16=F+"-"+E;2.b=C.1e({},C.k.u,C[F][E].u,H);2.8=C(I).h("i."+E,3(L,J,K){4 G.i(J,K)}).h("O."+E,3(K,J){4 G.O(J)}).h("p",3(){4 G.1h()});2.18()};C[F][E].j=C.1e({},C.k.j,D)};C.k.j={18:3(){},1h:3(){2.8.2q(2.e)},O:3(D){4 2.b[D]},i:3(D,E){2.b[D]=E;5(D=="o"){2.8[E?"1i":"29"](2.16+"-o")}},22:3(){2.i("o",7)},25:3(){2.i("o",d)}};C.k.u={o:7};C.a.1n={2r:3(){6 D=2;2.8.h("2h."+2.e,3(E){4 D.1t(E)});5(C.z.y){2.1v=2.8.x("l");2.8.x("l","1g")}2.2l=7},2k:3(){2.8.S("."+2.e);(C.z.y&&2.8.x("l",2.1v))},1t:3(F){(2.c&&2.m(F));2.v=F;6 E=2,G=(F.26==1),D=(R 2.b.Y=="N"?C(F.28).2c(2.b.Y):7);5(!G||D||!2.1m(F)){4 d}2.t=!2.b.Q;5(!2.t){2.2b=2a(3(){E.t=d},2.b.Q)}5(2.T(F)&&2.U(F)){2.c=(2.Z(F)!==7);5(!2.c){F.2d();4 d}}2.10=3(H){4 E.1o(H)};2.12=3(H){4 E.m(H)};C(1q).h("1j."+2.e,2.10).h("1u."+2.e,2.12);4 7},1o:3(D){5(C.z.y&&!D.2s){4 2.m(D)}5(2.c){2.11(D);4 7}5(2.T(D)&&2.U(D)){2.c=(2.Z(2.v,D)!==7);(2.c?2.11(D):2.m(D))}4!2.c},m:3(D){C(1q).S("1j."+2.e,2.10).S("1u."+2.e,2.12);5(2.c){2.c=7;2.1k(D)}4 7},T:3(D){4(W.1T(W.1s(2.v.1r-D.1r),W.1s(2.v.1p-D.1p))>=2.b.1l)},U:3(D){4 2.t},Z:3(D){},11:3(D){},1k:3(D){},1m:3(D){4 d}};C.a.1n.u={Y:1x,1l:1,Q:0}})(2e);',62,153,'||this|function|return|if|var|false|element||ui|options|_mouseStarted|true|widgetName|css|test|bind|setData|prototype|widget|unselectable|mouseUp|cssCache|disabled|remove|apply|style||_mouseDelayMet|defaults|_mouseDownEvent|plugins|attr|msie|browser|||||||||||||data|string|getData|fn|delay|typeof|unbind|mouseDistanceMet|mouseDelayMet|split|Math|top|cancel|mouseStart|_mouseMoveDelegate|mouseDrag|_mouseUpDelegate|body|none|MozUserSelect|widgetBaseClass|onselectstart|init|add|get|call|arguments|for|extend|5000px|on|destroy|addClass|mousemove|mouseStop|distance|mouseCapture|mouse|mouseMove|pageY|document|pageX|abs|mouseDown|mouseup|_mouseUnselectable|try|null|backgroundColor|removeChild|disableSelection|off|rgba|enableSelection|hasScroll|catch|width|class|gen|position|absolute|div|length|plugin|in|push|left|display|height|max|backgroundImage|cursor|default|block|appendTo|auto|transparent|scrollLeft|enable|scrollTop|new|disable|which|else|target|removeClass|setTimeout|_mouseDelayTimer|is|preventDefault|jQuery|isFunction|each|mousedown|inArray|getter|mouseDestroy|started|trigger|Array|slice|undefined|removeData|mouseInit|button'.split('|'),0,{}))
View
1 public/javascripts/wymeditor/jquery/jquery.ui.resizable.js
@@ -0,0 +1 @@
+eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(h(A){A.3n("b.d",A.17(A.b.3w,{3u:h(){f M=4,N=4.m;f Q=4.j.c("g");4.2p=4.j;4.j.1j("b-d").c({g:/1W/.q(Q)?"1i":Q});A.17(N,{1J:!!(N.19),l:N.l||N.13||N.1q?N.l||"3p":1l,1k:N.1k===1x?"b-d-1N-11":N.1k});f H="2A 3a #3t";N.3h={"b-d":{22:"2H"},"b-d-11":{g:"1z",3j:"#3g",3v:"0.2A"},"b-d-n":{t:"n-o",8:"14",5:"p",1t:"p",2C:H},"b-d-s":{t:"s-o",8:"14",5:"p",1t:"p",2z:H},"b-d-e":{t:"e-o",6:"14",9:"p",1s:"p",2E:H},"b-d-w":{t:"w-o",6:"14",9:"p",1s:"p",2F:H},"b-d-y":{t:"y-o",6:"14",8:"14",2E:H,2z:H},"b-d-z":{t:"z-o",6:"14",8:"14",2z:H,2F:H},"b-d-Z":{t:"Z-o",6:"14",8:"14",2E:H,2C:H},"b-d-x":{t:"x-o",6:"14",8:"14",2F:H,2C:H}};N.2g={"b-d-11":{3j:"#3g",3G:"2A 3a #3F",8:"3c",6:"3c"},"b-d-n":{t:"n-o",9:"p",5:"45%"},"b-d-s":{t:"s-o",1s:"p",5:"45%"},"b-d-e":{t:"e-o",1t:"p",9:"45%"},"b-d-w":{t:"w-o",5:"p",9:"45%"},"b-d-y":{t:"y-o",1t:"p",1s:"p"},"b-d-z":{t:"z-o",5:"p",1s:"p"},"b-d-x":{t:"x-o",5:"p",9:"p"},"b-d-Z":{t:"Z-o",1t:"p",9:"p"}};N.2s=4.j[0].2B;a(N.2s.2l(/3L|29|2a|2N|2K|3D/i)){f B=4.j;a(/1i/.q(B.c("g"))&&A.1e.2Q){B.c({g:"1i",9:"1T",5:"1T"})}B.3E(A(\'<1B 3l="b-2n" 2t="2x: 2h;"></1B>\').c({g:B.c("g"),6:B.1u(),8:B.1v(),9:B.c("9"),5:B.c("5")}));f J=4.j;4.j=4.j.1G();4.j.12("d",4);4.j.c({2c:J.c("2c"),2b:J.c("2b"),2i:J.c("2i"),2e:J.c("2e")});J.c({2c:0,2b:0,2i:0,2e:0});a(A.1e.3C&&N.3b){J.c("o","36")}N.1g=J.c({g:"1W",3B:1,22:"2H"});4.j.c({2w:J.c("2w")});4.1Q()}a(!N.u){N.u=!A(".b-d-11",4.j).1H?"e,s,y":{n:".b-d-n",e:".b-d-e",s:".b-d-s",w:".b-d-w",y:".b-d-y",z:".b-d-z",Z:".b-d-Z",x:".b-d-x"}}a(N.u.2P==2R){N.1D=N.1D||3y;a(N.u=="3z"){N.u="n,e,s,w,y,z,Z,x"}f O=N.u.3A(",");N.u={};f G={11:"g: 1z; 22: 36; 2x:2h;",n:"9: 1o; 6:28%;",e:"1t: 1o; 8:28%;",s:"1s: 1o; 6:28%;",w:"5: 1o; 8:28%;",y:"1s: 1o; 1t: p;",z:"1s: 1o; 5: p;",Z:"9: 1o; 1t: p;",x:"9: 1o; 5: p;"};2m(f R=0;R<O.1H;R++){f S=A.3N(O[R]),L=N.3h,F="b-d-"+S,C=!A.b.c(F)&&!N.1k,P=A.b.c("b-d-1N-11"),T=A.17(L[F],L["b-d-11"]),D=A.17(N.2g[F],!P?N.2g["b-d-11"]:{});f K=/z|y|Z|x/.q(S)?{1D:++N.1D}:{};f I=(C?G[S]:""),E=A([\'<1B 3l="b-d-11 \',F,\'" 2t="\',I,G.11,\'"></1B>\'].2o("")).c(K);N.u[S]=".b-d-"+S;4.j.35(E.c(C?T:{}).c(N.1k?D:{}).1j(N.1k?"b-d-1N-11":"").1j(N.1k))}a(N.1k){4.j.1j("b-d-1N").c(!A.b.c("b-d-1N")?{}:{})}}4.2V=h(Y){Y=Y||4.j;2m(f V 2L N.u){a(N.u[V].2P==2R){N.u[V]=A(N.u[V],4.j).2M()}a(N.2u){N.u[V].c({34:0})}a(4.j.2q(".b-2n")&&N.2s.2l(/29|2a|2N|2K/i)){f W=A(N.u[V],4.j),X=0;X=/z|Z|x|y|n|s/.q(V)?W.1v():W.1u();f U=["3O",/Z|x|n/.q(V)?"3M":/y|z|s/.q(V)?"3x":/^e$/.q(V)?"3I":"3J"].2o("");a(!N.2u){Y.c(U,X)}4.1Q()}a(!A(N.u[V]).1H){3K}}};4.2V(4.j);N.1y=A(".b-d-11",M.j);a(N.1L){N.1y.1E(h(U,V){A.b.1L(V)})}N.1y.3P(h(){a(!N.24){a(4.37){f U=4.37.2l(/b-d-(y|z|Z|x|n|e|s|w)/i)}M.1w=N.1w=U&&U[1]?U[1]:"y"}});a(N.3d){N.1y.38();A(M.j).1j("b-d-2k").3s(h(){A(4).3e("b-d-2k");N.1y.2M()},h(){a(!N.24){A(4).1j("b-d-2k");N.1y.38()}})}4.3r()},3q:{},b:h(){r{2p:4.2p,j:4.j,l:4.l,g:4.g,k:4.k,m:4.m,16:4.16,15:4.15}},1U:h(C,B){A.b.1F.3o(4,C,[B,4.b()]);a(C!="o"){4.j.33(["o",C].2o(""),[B,4.b()],4.m[C])}},3H:h(){f D=4.j,C=D.3V(".b-d").1d(0);4.4p();f B=h(E){A(E).3e("b-d b-d-3m").3f("d").4q(".d").4n(".b-d-11").2v()};B(D);a(D.2q(".b-2n")&&C){D.1G().35(A(C).c({g:D.c("g"),6:D.1u(),8:D.1v(),9:D.c("9"),5:D.c("5")})).4g().2v();B(C)}},4f:h(K){a(4.m.3m){r 1b}f J=1b;2m(f H 2L 4.m.u){a(A(4.m.u[H])[0]==K.4i){J=1x}}a(!J){r 1b}f C=4.m,B=4.j.g(),D=4.j,I=h(O){r v(O,10)||0},G=A.1e.20&&A.1e.2d<7;C.24=1x;C.2r={9:A(1n).4j(),5:A(1n).4h()};a(D.2q(".b-4k")||(/1z/).q(D.c("g"))){f M=A.1e.20&&!C.2G&&(/1z/).q(D.c("g"))&&!(/1i/).q(D.1G().c("g"));f L=M?C.2r.9:0,F=M?C.2r.5:0;D.c({g:"1z",9:(B.9+L),5:(B.5+F)})}a(A.1e.2Q&&/1i/.q(D.c("g"))){D.c({g:"1i",9:"1T",5:"1T"})}4.2Z();f N=I(4.l.c("5")),E=I(4.l.c("9"));4.1h=4.l.1h();4.g={5:N,9:E};4.k=C.l||G?{6:D.1u(),8:D.1v()}:{6:D.6(),8:D.8()};4.16=C.l||G?{6:D.1u(),8:D.1v()}:{6:D.6(),8:D.8()};4.15={5:N,9:E};4.1p={6:D.1u()-D.6(),8:D.1v()-D.8()};4.2O={5:K.2U,9:K.2X};C.19=(1R C.19=="2W")?C.19:((4.16.8/4.16.6)||1);a(C.2I){A("26").c("t",4.1w+"-o")}4.1U("1O",K);r 1x},3Q:h(I){f D=4.l,C=4.m,J={},M=4,F=4.2O,K=4.1w;f N=(I.2U-F.5)||0,L=(I.2X-F.9)||0;f E=4.1c[K];a(!E){r 1b}f H=E.1m(4,[I,N,L]),G=A.1e.20&&A.1e.2d<7,B=4.1p;a(C.1J||I.1Y){H=4.32(H,I)}H=4.31(H,I);4.1U("o",I);D.c({9:4.g.9+"1r",5:4.g.5+"1r",6:4.k.6+"1r",8:4.k.8+"1r"});a(!C.l&&C.1g){4.1Q()}4.2j(H);4.j.33("o",[I,4.b()],4.m.o);r 1b},4l:h(I){4.m.24=1b;f E=4.m,H=h(M){r v(M,10)||0},K=4;a(E.l){f D=E.1g,B=D&&(/29/i).q(D.1d(0).2B),C=B&&A.b.1X(D.1d(0),"5")?0:K.1p.8,G=B?0:K.1p.6;f L={6:(K.k.6-G),8:(K.k.8-C)},F=(v(K.j.c("5"),10)+(K.g.5-K.15.5))||1l,J=(v(K.j.c("9"),10)+(K.g.9-K.15.9))||1l;a(!E.1q){4.j.c(A.17(L,{9:J,5:F}))}a(E.l&&!E.1q){4.1Q()}}a(E.2I){A("26").c("t","1T")}4.1U("1P",I);a(E.l){4.l.2v()}r 1b},2j:h(B){f C=4.m;4.1h=4.l.1h();a(B.5){4.g.5=B.5}a(B.9){4.g.9=B.9}a(B.8){4.k.8=B.8}a(B.6){4.k.6=B.6}},32:h(D,E){f F=4.m,G=4.g,C=4.k,B=4.1w;a(D.8){D.6=(C.8/F.19)}1a{a(D.6){D.8=(C.6*F.19)}}a(B=="z"){D.5=G.5+(C.6-D.6);D.9=1l}a(B=="x"){D.9=G.9+(C.8-D.8);D.5=G.5+(C.6-D.6)}r D},31:h(H,I){f F=4.l,E=4.m,N=E.1J||I.1Y,M=4.1w,P=H.6&&E.1V&&E.1V<H.6,J=H.8&&E.1Z&&E.1Z<H.8,D=H.6&&E.1M&&E.1M>H.6,O=H.8&&E.1S&&E.1S>H.8;a(D){H.6=E.1M}a(O){H.8=E.1S}a(P){H.6=E.1V}a(J){H.8=E.1Z}f C=4.15.5+4.16.6,L=4.g.9+4.k.8;f G=/z|x|w/.q(M),B=/x|Z|n/.q(M);a(D&&G){H.5=C-E.1M}a(P&&G){H.5=C-E.1V}a(O&&B){H.9=L-E.1S}a(J&&B){H.9=L-E.1Z}f K=!H.6&&!H.8;a(K&&!H.5&&H.9){H.9=1l}1a{a(K&&!H.9&&H.5){H.5=1l}}r H},1Q:h(){f F=4.m;a(!F.1g){r}f D=F.1g,C=4.l||4.j;a(!F.1C){f B=[D.c("4o"),D.c("4r"),D.c("4s"),D.c("4m")],E=[D.c("4d"),D.c("3X"),D.c("3Y"),D.c("3Z")];F.1C=A.40(B,h(G,I){f H=v(G,10)||0,J=v(E[I],10)||0;r H+J})}D.c({8:(C.8()-F.1C[0]-F.1C[2])+"1r",6:(C.6()-F.1C[1]-F.1C[3])+"1r"})},2Z:h(){f C=4.j,F=4.m;4.2f=C.1h();a(F.l){4.l=4.l||A(\'<1B 2t="2x:2h;"></1B>\');f B=A.1e.20&&A.1e.2d<7,D=(B?1:0),E=(B?2:-1);4.l.1j(F.l).c({6:C.1u()+E,8:C.1v()+E,g:"1z",5:4.2f.5-D+"1r",9:4.2f.9-D+"1r",1D:++F.1D});4.l.39("26");a(F.1L){A.b.1L(4.l.1d(0))}}1a{4.l=C}},1c:{e:h(D,C,B){r{6:4.16.6+C}},w:h(F,C,B){f G=4.m,D=4.16,E=4.15;r{5:E.5+C,6:D.6-C}},n:h(F,C,B){f G=4.m,D=4.16,E=4.15;r{9:E.9+B,8:D.8-B}},s:h(D,C,B){r{8:4.16.8+B}},y:h(D,C,B){r A.17(4.1c.s.1m(4,27),4.1c.e.1m(4,[D,C,B]))},z:h(D,C,B){r A.17(4.1c.s.1m(4,27),4.1c.w.1m(4,[D,C,B]))},Z:h(D,C,B){r A.17(4.1c.n.1m(4,27),4.1c.e.1m(4,[D,C,B]))},x:h(D,C,B){r A.17(4.1c.n.1m(4,27),4.1c.w.1m(4,[D,C,B]))}}}));A.17(A.b.d,{3S:{3T:":2a",3U:1,41:0,3b:1x,2u:1b,1M:10,1S:10,19:1b,1L:1x,2I:1x,3d:1b,1k:1b}});A.b.1F.1K("d","2G",{1O:h(I,K){f E=K.m,M=A(4).12("d"),G=M.j;f C=E.2G,F=(C 49 A)?C.1d(0):(/1G/.q(C))?G.1G().1d(0):C;a(!F){r}M.2D=A(F);a(/1n/.q(C)||C==1n){M.1I={5:0,9:0};M.23={5:0,9:0};M.1A={j:A(1n),5:0,9:0,6:A(1n).6(),8:A(1n).8()||1n.26.43.3k}}1a{M.1I=A(F).1h();M.23=A(F).g();M.21={8:A(F).30(),6:A(F).2T()};f J=M.1I,B=M.21.8,H=M.21.6,D=(A.b.1X(F,"5")?F.44:H),L=(A.b.1X(F)?F.3k:B);M.1A={j:F,5:J.5,9:J.9,6:D,8:L}}},o:h(H,K){f E=K.m,N=A(4).12("d"),C=N.21,J=N.1I,G=N.k,I=N.g,L=E.1J||H.1Y,B={9:0,5:0},D=N.2D;a(D[0]!=1n&&/1W/.q(D.c("g"))){B=N.23}a(I.5<(E.l?J.5:B.5)){N.k.6=N.k.6+(E.l?(N.g.5-J.5):(N.g.5-B.5));a(L){N.k.8=N.k.6*E.19}N.g.5=E.l?J.5:B.5}a(I.9<(E.l?J.9:0)){N.k.8=N.k.8+(E.l?(N.g.9-J.9):N.g.9);a(L){N.k.6=N.k.8/E.19}N.g.9=E.l?J.9:0}f F=(E.l?N.1h.5-J.5:(N.g.5-B.5))+N.1p.6,M=(E.l?N.1h.9-J.9:N.g.9)+N.1p.8;a(F+N.k.6>=N.1A.6){N.k.6=N.1A.6-F;a(L){N.k.8=N.k.6*E.19}}a(M+N.k.8>=N.1A.8){N.k.8=N.1A.8-M;a(L){N.k.6=N.k.8/E.19}}},1P:h(G,J){f C=J.m,L=A(4).12("d"),H=L.g,I=L.1I,B=L.23,D=L.2D;f E=A(L.l),M=E.1h(),K=E.2T(),F=E.30();a(C.l&&!C.1q&&/1i/.q(D.c("g"))){A(4).c({5:(M.5-I.5),9:(M.9-I.9),6:K,8:F})}a(C.l&&!C.1q&&/1W/.q(D.c("g"))){A(4).c({5:B.5+(M.5-I.5),9:B.9+(M.9-I.9),6:K,8:F})}}});A.b.1F.1K("d","1f",{o:h(H,J){f D=J.m,L=A(4).12("d"),G=L.k,E=L.16,F=L.15,K=L.1w,I=D.1J||H.1Y;D.1f=1R D.1f=="2W"?[D.1f,D.1f]:D.1f;f C=2J.2S((G.6-E.6)/(D.1f[0]||1))*(D.1f[0]||1),B=2J.2S((G.8-E.8)/(D.1f[1]||1))*(D.1f[1]||1);a(/^(y|s|e)$/.q(K)){L.k.6=E.6+C;L.k.8=E.8+B}1a{a(/^(Z)$/.q(K)){L.k.6=E.6+C;L.k.8=E.8+B;L.g.9=F.9-B}1a{a(/^(z)$/.q(K)){L.k.6=E.6+C;L.k.8=E.8+B;L.g.5=F.5-C}1a{L.k.6=E.6+C;L.k.8=E.8+B;L.g.9=F.9-B;L.g.5=F.5-C}}}}});A.b.1F.1K("d","1q",{1P:h(I,K){f F=K.m,L=A(4).12("d");f E=F.1g,B=E&&(/29/i).q(E.1d(0).2B),C=B&&A.b.1X(E.1d(0),"5")?0:L.1p.8,H=B?0:L.1p.6;f D={6:(L.k.6-H),8:(L.k.8-C)},G=(v(L.j.c("5"),10)+(L.g.5-L.15.5))||1l,J=(v(L.j.c("9"),10)+(L.g.9-L.15.9))||1l;L.j.1q(A.17(D,J&&G?{9:J,5:G}:{}),{48:F.4c||"4b",4a:F.42||"4e",3W:h(){f M={6:v(L.j.c("6"),10),8:v(L.j.c("8"),10),9:v(L.j.c("9"),10),5:v(L.j.c("5"),10)};a(E){E.c({6:M.6,8:M.8})}L.2j(M);L.1U("1q",I)}})}});A.b.1F.1K("d","13",{1O:h(E,D){f F=D.m,B=A(4).12("d"),G=F.1g,C=B.k;a(!G){B.13=B.j.2Y()}1a{B.13=G.2Y()}B.13.c({34:0.25,22:"2H",g:"1i",8:C.8,6:C.6,2w:0,5:0,9:0}).1j("b-d-13").1j(1R F.13=="47"?F.13:"");B.13.39(B.l)},o:h(D,C){f E=C.m,B=A(4).12("d"),F=E.1g;a(B.13){B.13.c({g:"1i",8:B.k.8,6:B.k.6})}},1P:h(D,C){f E=C.m,B=A(4).12("d"),F=E.1g;a(B.13&&B.l){B.l.1d(0).46(B.13.1d(0))}}});A.b.1F.1K("d","18",{1O:h(E,C){f F=C.m,B=A(4).12("d"),D=h(G){A(G).1E(h(){A(4).12("d-2y",{6:v(A(4).6(),10),8:v(A(4).8(),10),5:v(A(4).c("5"),10),9:v(A(4).c("9"),10)})})};a(1R(F.18)=="3i"){a(F.18.1H){F.18=F.18[0];D(F.18)}1a{A.1E(F.18,h(G,H){D(G)})}}1a{D(F.18)}},o:h(F,E){f G=E.m,C=A(4).12("d"),D=C.16,I=C.15;f H={8:(C.k.8-D.8)||0,6:(C.k.6-D.6)||0,9:(C.g.9-I.9)||0,5:(C.g.5-I.5)||0},B=h(J,K){A(J).1E(h(){f N=A(4).12("d-2y"),M={},L=K&&K.1H?K:["6","8","9","5"];A.1E(L||["6","8","9","5"],h(O,Q){f P=(N[Q]||0)+(H[Q]||0);a(P&&P>=0){M[Q]=P||1l}});A(4).c(M)})};a(1R(G.18)=="3i"){A.1E(G.18,h(J,K){B(J,K)})}1a{B(G.18)}},1P:h(C,B){A(4).3f("d-2y-1O")}})})(3R);',62,277,'||||this|left|width||height|top|if|ui|css|resizable||var|position|function||element|size|helper|options||resize|0px|test|return||cursor|handles|parseInt||nw|se|sw||||||||||||||||||||||||||ne||handle|data|ghost|4px|originalPosition|originalSize|extend|alsoResize|aspectRatio|else|false|_change|get|browser|grid|proportionallyResize|offset|relative|addClass|knobHandles|null|apply|document|0pt|sizeDiff|animate|px|bottom|right|outerWidth|outerHeight|axis|true|_handles|absolute|parentData|div|borderDif|zIndex|each|plugin|parent|length|containerOffset|_aspectRatio|add|disableSelection|minWidth|knob|start|stop|_proportionallyResize|typeof|minHeight|auto|propagate|maxWidth|static|hasScroll|shiftKey|maxHeight|msie|containerSize|display|containerPosition|resizing||body|arguments|100|textarea|input|marginTop|marginLeft|version|marginBottom|elementOffset|knobTheme|hidden|marginRight|_updateCache|autohide|match|for|wrapper|join|originalElement|is|documentScroll|_nodeName|style|transparent|remove|margin|overflow|alsoresize|borderBottom|1px|nodeName|borderTop|containerElement|borderRight|borderLeft|containment|block|preserveCursor|Math|button|in|show|select|originalMousePosition|constructor|opera|String|round|innerWidth|pageX|_renderAxis|number|pageY|clone|_renderProxy|innerHeight|_respectSize|_updateRatio|triggerHandler|opacity|append|none|className|hide|appendTo|solid|preventDefault|8px|autoHide|removeClass|removeData|F2F2F2|defaultTheme|object|background|scrollHeight|class|disabled|widget|call|proxy|plugins|mouseInit|hover|DEDEDE|init|fontSize|mouse|Bottom|1000|all|split|zoom|safari|img|wrap|808080|border|destroy|Right|Left|continue|canvas|Top|trim|padding|mouseover|mouseDrag|jQuery|defaults|cancel|distance|children|step|paddingRight|paddingBottom|paddingLeft|map|delay|animateEasing|parentNode|scrollWidth||removeChild|string|duration|instanceof|easing|slow|animateDuration|paddingTop|swing|mouseStart|end|scrollLeft|target|scrollTop|draggable|mouseStop|borderLeftWidth|find|borderTopWidth|mouseDestroy|unbind|borderRightWidth|borderBottomWidth'.split('|'),0,{}))
View
1 public/javascripts/wymeditor/jquery/jquery.ui.sortable.js
@@ -0,0 +1 @@
+eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(b(B){b A(E,D){9 C=B.2M.3e&&B.2M.3f<3g;5(E.2I&&!C){e E.2I(D)}5(E.2E){e!!(E.2E(D)&16)}1Q(D=D.1e){5(D==E){e V}}e L}B.3d("j.p",B.2r({},B.j.3c,{38:b(){9 C=4.8;4.R={};4.g.22("j-p");4.2B();4.Z=4.c.z?(/6|1Z/).1c(4.c[0].t.f("39")):L;5(!(/(2U|1j|3a)/).1c(4.g.f("Q"))){4.g.f("Q","2U")}4.a=4.g.a();4.3b()},3h:{},j:b(C){e{l:(C||4)["l"],r:(C||4)["r"]||B([]),Q:(C||4)["Q"],3i:(C||4)["17"],8:4.8,g:4.g,t:(C||4)["h"],3o:C?C.g:O}},v:b(F,E,C,D){B.j.1g.X(4,F,[E,4.j(C)]);5(!D){4.g.2Y(F=="1b"?F:"1b"+F,[E,4.j(C)],4.8[F])}},2F:b(E){9 C=(B.1E(4.8.c)?4.8.c.X(4.g):B(4.8.c,4.g)).2a(".j-p-l");9 D=[];E=E||{};C.1x(b(){9 F=(B(4).2f(E.3p||"2g")||"").3q(E.2j||(/(.+)[-=3n](.+)/));5(F){D.1u((E.2m||F[1])+"[]="+(E.2m&&E.2j?F[1]:F[2]))}});e D.37("&")},2V:b(C){9 D=(B.1E(4.8.c)?4.8.c.X(4.g):B(4.8.c,4.g)).2a(".j-p-l");9 E=[];D.1x(b(){E.1u(B(4).2f(C||"2g"))});e E},2R:b(J){9 E=4.17.6,D=E+4.s.n,I=4.17.7,H=I+4.s.o;9 F=J.6,C=F+J.n,K=J.7,G=K+J.o;5(4.8.1p=="2n"||4.8.3j||(4.8.1p=="2e"&&4.s[4.Z?"n":"o"]>J[4.Z?"n":"o"])){e(I+4.a.q.7>K&&I+4.a.q.7<G&&E+4.a.q.6>F&&E+4.a.q.6<C)}Y{e(F<E+(4.s.n/2)&&D-(4.s.n/2)<C&&K<I+(4.s.o/2)&&H-(4.s.o/2)<G)}},2x:b(J){9 E=4.17.6,D=E+4.s.n,I=4.17.7,H=I+4.s.o;9 F=J.6,C=F+J.n,K=J.7,G=K+J.o;5(4.8.1p=="2n"||(4.8.1p=="2e"&&4.s[4.Z?"n":"o"]>J[4.Z?"n":"o"])){5(!(I+4.a.q.7>K&&I+4.a.q.7<G&&E+4.a.q.6>F&&E+4.a.q.6<C)){e L}5(4.Z){5(E+4.a.q.6>F&&E+4.a.q.6<F+J.n/2){e 2}5(E+4.a.q.6>F+J.n/2&&E+4.a.q.6<C){e 1}}Y{5(I+4.a.q.7>K&&I+4.a.q.7<K+J.o/2){e 2}5(I+4.a.q.7>K+J.o/2&&I+4.a.q.7<G){e 1}}}Y{5(!(F<E+(4.s.n/2)&&D-(4.s.n/2)<C&&K<I+(4.s.o/2)&&H-(4.s.o/2)<G)){e L}5(4.Z){5(D>F&&E<F){e 2}5(E<C&&D>C){e 1}}Y{5(H>K&&I<K){e 1}5(I<G&&H>G){e 2}}}e L},2B:b(){4.28();4.1I()},28:b(){4.c=[];4.d=[4];9 D=4.c;9 C=4;9 F=[[B.1E(4.8.c)?4.8.c.X(4.g,O,{8:4.8,t:4.h}):B(4.8.c,4.g),4]];5(4.8.1S){P(9 G=4.8.1S.z-1;G>=0;G--){9 I=B(4.8.1S[G]);P(9 E=I.z-1;E>=0;E--){9 H=B.1f(I[E],"p");5(H&&!H.8.26){F.1u([B.1E(H.8.c)?H.8.c.X(H.g):B(H.8.c,H.g),H]);4.d.1u(H)}}}}P(9 G=F.z-1;G>=0;G--){F[G][0].1x(b(){B.1f(4,"p-t",F[G][1]);D.1u({t:B(4),2y:F[G][1],n:0,o:0,6:0,7:0})})}},1I:b(D){5(4.u){9 C=4.u.a();4.a.m={7:C.7+4.1w.7,6:C.6+4.1w.6}}P(9 F=4.c.z-1;F>=0;F--){5(4.c[F].2y!=4.1q&&4.1q&&4.c[F].t[0]!=4.h[0]){1C}9 E=4.8.2z?B(4.8.2z,4.c[F].t):4.c[F].t;5(!D){4.c[F].n=E[0].24;4.c[F].o=E[0].1X}9 G=E.a();4.c[F].6=G.6;4.c[F].7=G.7}5(4.8.1O&&4.8.1O.2w){4.8.1O.2w.X(4)}Y{P(9 F=4.d.z-1;F>=0;F--){9 G=4.d[F].g.a();4.d[F].R.6=G.6;4.d[F].R.7=G.7;4.d[F].R.n=4.d[F].g.1z();4.d[F].R.o=4.d[F].g.1H()}}},3l:b(){4.g.3r("j-p j-p-26").2i("p").30(".p");4.34();P(9 C=4.c.z-1;C>=0;C--){4.c[C].t.2i("p-t")}},21:b(E){9 C=E||4,F=C.8;5(F.r.31==2Z){9 D=F.r;F.r={g:b(){e B("<2S></2S>").22(D)[0]},1o:b(G,H){H.f(G.a()).f({n:G.1z(),o:G.1H()})}}}C.r=B(F.r.g.X(C.g,C.h)).1M("W").f({Q:"1j"});F.r.1o.X(C.g,C.h,C.r)},2X:b(F){P(9 D=4.d.z-1;D>=0;D--){5(4.2R(4.d[D].R)){5(!4.d[D].R.1d){5(4.1q!=4.d[D]){9 I=36;9 H=O;9 E=4.17[4.d[D].Z?"6":"7"];P(9 C=4.c.z-1;C>=0;C--){5(!A(4.d[D].g[0],4.c[C].t[0])){1C}9 G=4.c[C][4.d[D].Z?"6":"7"];5(1m.2D(G-E)<I){I=1m.2D(G-E);H=4.c[C]}}5(!H&&!4.8.2C){1C}5(4.r){4.r.1A()}5(4.d[D].8.r){4.d[D].21(4)}Y{4.r=O}4.1q=4.d[D];H?4.1B(F,H,O,V):4.1B(F,O,4.d[D].g,V);4.v("1T",F);4.d[D].v("1T",F,4)}4.d[D].v("1d",F,4);4.d[D].R.1d=1}}Y{5(4.d[D].R.1d){4.d[D].v("2p",F,4);4.d[D].R.1d=0}}}},35:b(G,F){5(4.8.26||4.8.2T=="33"){e L}4.28();9 E=O,D=4,C=B(G.1D).2P().1x(b(){5(B.1f(4,"p-t")==D){E=B(4);e L}});5(B.1f(G.1D,"p-t")==D){E=B(G.1D)}5(!E){e L}5(4.8.2L&&!F){9 H=L;B(4.8.2L,E).3m("*").3A().1x(b(){5(4==G.1D){H=V}});5(!H){e L}}4.h=E;e V},3P:b(H,F,C){9 J=4.8;4.1q=4;4.1I();4.l=3L J.l=="b"?B(J.l.3M(4.g[0],[H,4.h])):4.h.2c();5(!4.l.2P("W").z){B(J.1M!="m"?J.1M:4.h[0].1e)[0].2O(4.l[0])}4.l.f({Q:"1j",1F:"3N"}).22("j-p-l");4.T={6:(w(4.h.f("3S"),10)||0),7:(w(4.h.f("3T"),10)||0)};4.a=4.h.a();4.a={7:4.a.7-4.T.7,6:4.a.6-4.T.6};4.a.q={6:H.1l-4.a.6,7:H.1k-4.a.7};4.u=4.l.u();9 D=4.u.a();4.1w={7:(w(4.u.f("29"),10)||0),6:(w(4.u.f("27"),10)||0)};4.a.m={7:D.7+4.1w.7,6:D.6+4.1w.6};4.15=4.1R(H);4.2d={1t:4.h.1t()[0],m:4.h.m()[0]};4.s={n:4.l.1z(),o:4.l.1H()};5(J.r){4.21()}4.v("1v",H);4.s={n:4.l.1z(),o:4.l.1H()};5(J.13){5(J.13.6!=1G){4.a.q.6=J.13.6}5(J.13.1Z!=1G){4.a.q.6=4.s.n-J.13.1Z}5(J.13.7!=1G){4.a.q.7=J.13.7}5(J.13.2t!=1G){4.a.q.7=4.s.o-J.13.2t}}5(J.k){5(J.k=="m"){J.k=4.l[0].1e}5(J.k=="i"||J.k=="1h"){4.k=[0-4.a.m.6,0-4.a.m.7,B(J.k=="i"?i:1h).n()-4.a.m.6-4.s.n-4.T.6-(w(4.g.f("2u"),10)||0),(B(J.k=="i"?i:1h).o()||i.W.1e.2q)-4.a.m.7-4.s.o-4.T.7-(w(4.g.f("2v"),10)||0)]}5(!(/^(i|1h|m)$/).1c(J.k)){9 G=B(J.k)[0];9 I=B(J.k).a();4.k=[I.6+(w(B(G).f("27"),10)||0)-4.a.m.6,I.7+(w(B(G).f("29"),10)||0)-4.a.m.7,I.6+1m.2s(G.3W,G.24)-(w(B(G).f("27"),10)||0)-4.a.m.6-4.s.n-4.T.6-(w(4.h.f("2u"),10)||0),I.7+1m.2s(G.2q,G.1X)-(w(B(G).f("29"),10)||0)-4.a.m.7-4.s.o-4.T.7-(w(4.h.f("2v"),10)||0)]}}5(4.8.r!="2c"){4.h.f("2A","3K")}5(!C){P(9 E=4.d.z-1;E>=0;E--){4.d[E].v("3y",H,4)}}5(B.j.18){B.j.18.3z=4}5(B.j.18&&!J.2J){B.j.18.3u(4,H)}4.2N=V;4.2o(H);e V},1P:b(D,E){5(!E){E=4.Q}9 C=D=="1j"?1:-1;e{7:(E.7+4.a.m.7*C-(4.u[0]==i.W?0:4.u[0].N)*C+4.T.7*C),6:(E.6+4.a.m.6*C-(4.u[0]==i.W?0:4.u[0].M)*C+4.T.6*C)}},1R:b(F){9 G=4.8;9 C={7:(F.1k-4.a.q.7-4.a.m.7+(4.u[0]==i.W?0:4.u[0].N)),6:(F.1l-4.a.q.6-4.a.m.6+(4.u[0]==i.W?0:4.u[0].M))};5(!4.15){e C}5(4.k){5(C.6<4.k[0]){C.6=4.k[0]}5(C.7<4.k[1]){C.7=4.k[1]}5(C.6>4.k[2]){C.6=4.k[2]}5(C.7>4.k[3]){C.7=4.k[3]}}5(G.11){9 E=4.15.7+1m.2h((C.7-4.15.7)/G.11[1])*G.11[1];C.7=4.k?(!(E<4.k[1]||E>4.k[3])?E:(!(E<4.k[1])?E-G.11[1]:E+G.11[1])):E;9 D=4.15.6+1m.2h((C.6-4.15.6)/G.11[0])*G.11[0];C.6=4.k?(!(D<4.k[0]||D>4.k[2])?D:(!(D<4.k[0])?D-G.11[0]:D+G.11[0])):D}e C},2o:b(D){4.Q=4.1R(D);4.17=4.1P("1j");B.j.1g.X(4,"1b",[D,4.j()]);4.17=4.1P("1j");4.l[0].2l.6=4.Q.6+"2k";4.l[0].2l.7=4.Q.7+"2k";P(9 C=4.c.z-1;C>=0;C--){9 E=4.2x(4.c[C]);5(!E){1C}5(4.c[C].t[0]!=4.h[0]&&4.h[E==1?"3D":"1t"]()[0]!=4.c[C].t[0]&&!A(4.h[0],4.c[C].t[0])&&(4.8.2T=="3E-3J"?!A(4.g[0],4.c[C].t[0]):V)){4.2H=E==1?"2G":"3F";4.1B(D,4.c[C]);4.v("1T",D);3G}}4.2X(D);5(B.j.18){B.j.18.3I(4,D)}4.g.2Y("1b",[D,4.j()],4.8.1b);e L},1B:b(H,G,D,F){D?D[0].2O(4.h[0]):G.t[0].1e.3B(4.h[0],(4.2H=="2G"?G.t[0]:G.t[0].3t));4.1s=4.1s?++4.1s:1;9 E=4,C=4.1s;1h.3w(b(){5(C==E.1s){E.1I(!F)}},0);5(4.8.r){4.8.r.1o.X(4.g,4.h,4.r)}},3Y:b(E,D){5(B.j.18&&!4.8.2J){B.j.18.3O(4,E)}5(4.8.2b){9 C=4;9 F=C.h.a();5(C.r){C.r.2K({1a:"3R"},(w(4.8.2b,10)||2Q)-3Q)}B(4.l).2K({6:F.6-4.a.m.6-C.T.6+(4.u[0]==i.W?0:4.u[0].M),7:F.7-4.a.m.7-C.T.7+(4.u[0]==i.W?0:4.u[0].N)},w(4.8.2b,10)||2Q,b(){C.1F(E)})}Y{4.1F(E,D)}e L},1F:b(E,D){5(4.2d.1t!=4.h.1t().2a(".j-p-l")[0]||4.2d.m!=4.h.m()[0]){4.v("1o",E,O,D)}5(!A(4.g[0],4.h[0])){4.v("1A",E,O,D);P(9 C=4.d.z-1;C>=0;C--){5(A(4.d[C].g[0],4.h[0])){4.d[C].v("1o",E,4,D);4.d[C].v("3v",E,4,D)}}}P(9 C=4.d.z-1;C>=0;C--){4.d[C].v("3V",E,4,D);5(4.d[C].R.1d){4.d[C].v("2p",E,4);4.d[C].R.1d=0}}4.2N=L;5(4.32){4.v("1y",E,O,D);e L}B(4.h).f("2A","");5(4.r){4.r.1A()}4.l.1A();4.l=O;4.v("1y",E,O,D);e V}}));B.2r(B.j.p,{3k:"2F 2V",3s:{l:"2c",1p:"2e",3X:1,3H:0,1n:V,14:20,12:20,3C:":3U",c:"> *",19:3Z,2C:V,1M:"m"}});B.j.1g.1r("p","1i",{1v:b(E,D){9 C=B("W");5(C.f("1i")){D.8.1U=C.f("1i")}C.f("1i",D.8.1i)},1y:b(D,C){5(C.8.1U){B("W").f("1i",C.8.1U)}}});B.j.1g.1r("p","19",{1v:b(E,D){9 C=D.l;5(C.f("19")){D.8.1V=C.f("19")}C.f("19",D.8.19)},1y:b(D,C){5(C.8.1V){B(C.l).f("19",C.8.1V)}}});B.j.1g.1r("p","1a",{1v:b(E,D){9 C=D.l;5(C.f("1a")){D.8.1W=C.f("1a")}C.f("1a",D.8.1a)},1y:b(D,C){5(C.8.1W){B(C.l).f("1a",C.8.1W)}}});B.j.1g.1r("p","1n",{1v:b(E,D){9 F=D.8;9 C=B(4).1f("p");C.U=b(G){2W{5(/1L|1n/.1c(G.f("1K"))||(/1L|1n/).1c(G.f("1K-y"))){e G}G=G.m()}1Q(G[0].1e);e B(i)}(C.h);C.S=b(G){2W{5(/1L|1n/.1c(G.f("1K"))||(/1L|1n/).1c(G.f("1K-x"))){e G}G=G.m()}1Q(G[0].1e);e B(i)}(C.h);5(C.U[0]!=i&&C.U[0].1J!="1N"){C.1Y=C.U.a()}5(C.S[0]!=i&&C.S[0].1J!="1N"){C.23=C.S.a()}},1b:b(E,D){9 F=D.8;9 C=B(4).1f("p");5(C.U[0]!=i&&C.U[0].1J!="1N"){5((C.1Y.7+C.U[0].1X)-E.1k<F.14){C.U[0].N=C.U[0].N+F.12}5(E.1k-C.1Y.7<F.14){C.U[0].N=C.U[0].N-F.12}}Y{5(E.1k-B(i).N()<F.14){B(i).N(B(i).N()-F.12)}5(B(1h).o()-(E.1k-B(i).N())<F.14){B(i).N(B(i).N()+F.12)}}5(C.S[0]!=i&&C.S[0].1J!="1N"){5((C.23.6+C.S[0].24)-E.1l<F.14){C.S[0].M=C.S[0].M+F.12}5(E.1l-C.23.6<F.14){C.S[0].M=C.S[0].M-F.12}}Y{5(E.1l-B(i).M()<F.14){B(i).M(B(i).M()-F.12)}5(B(1h).n()-(E.1l-B(i).M())<F.14){B(i).M(B(i).M()+F.12)}}}});B.j.1g.1r("p","25",{1b:b(E,D){9 C=B(4).1f("p");5(D.8.25=="y"){C.Q.6=C.15.6}5(D.8.25=="x"){C.Q.7=C.15.7}}})})(3x);',62,248,'||||this|if|left|top|options|var|offset|function|items|containers|return|css|element|currentItem|document|ui|containment|helper|parent|width|height|sortable|click|placeholder|helperProportions|item|offsetParent|propagate|parseInt|||length||||||||||||false|scrollLeft|scrollTop|null|for|position|containerCache|overflowX|margins|overflowY|true|body|call|else|floating||grid|scrollSpeed|cursorAt|scrollSensitivity|originalPosition||positionAbs|ddmanager|zIndex|opacity|sort|test|over|parentNode|data|plugin|window|cursor|absolute|pageY|pageX|Math|scroll|update|tolerance|currentContainer|add|counter|prev|push|start|offsetParentBorders|each|stop|outerWidth|remove|rearrange|continue|target|isFunction|clear|undefined|outerHeight|refreshPositions|tagName|overflow|auto|appendTo|HTML|custom|convertPositionTo|while|generatePosition|connectWith|change|_cursor|_zIndex|_opacity|offsetHeight|overflowYOffset|right||createPlaceholder|addClass|overflowXOffset|offsetWidth|axis|disabled|borderLeftWidth|refreshItems|borderTopWidth|not|revert|clone|domPosition|guess|attr|id|round|removeData|expression|px|style|key|pointer|mouseDrag|out|scrollHeight|extend|max|bottom|marginRight|marginBottom|refreshContainers|intersectsWithEdge|instance|toleranceElement|visibility|refresh|dropOnEmpty|abs|compareDocumentPosition|serialize|down|direction|contains|dropBehaviour|animate|handle|browser|dragging|appendChild|parents|500|intersectsWith|div|type|relative|toArray|do|contactContainers|triggerHandler|String|unbind|constructor|cancelHelperRemoval|static|mouseDestroy|mouseCapture|10000|join|init|float|fixed|mouseInit|mouse|widget|safari|version|522|plugins|absolutePosition|forcePointerForContainers|getter|destroy|find|_|sender|attribute|match|removeClass|defaults|nextSibling|prepareOffsets|receive|setTimeout|jQuery|activate|current|andSelf|insertBefore|cancel|next|semi|up|break|delay|drag|dynamic|hidden|typeof|apply|both|drop|mouseStart|50|hide|marginLeft|marginTop|input|deactivate|scrollWidth|distance|mouseStop|1000'.split('|'),0,{}))
View
45 public/javascripts/wymeditor/lang/bg.js
@@ -0,0 +1,45 @@
+WYMeditor.STRINGS['bg'] = {
+ Strong: 'Получер',
+ Emphasis: 'Курсив',
+ Superscript: 'Горен индекс',
+ Subscript: 'Долен индекс',
+ Ordered_List: 'Подреден списък',
+ Unordered_List: 'Неподреден списък',
+ Indent: 'Блок навътре',
+ Outdent: 'Блок навън',
+ Undo: 'Стъпка назад',
+ Redo: 'Стъпка напред',
+ Link: 'Създай хипервръзка',
+ Unlink: 'Премахни хипервръзката',
+ Image: 'Изображение',
+ Table: 'Таблица',
+ HTML: 'HTML',
+ Paragraph: 'Абзац',
+ Heading_1: 'Заглавие 1',
+ Heading_2: 'Заглавие 2',
+ Heading_3: 'Заглавие 3',
+ Heading_4: 'Заглавие 4',
+ Heading_5: 'Заглавие 5',
+ Heading_6: 'Заглавие 6',
+ Preformatted: 'Преформатиран',
+ Blockquote: 'Цитат',
+ Table_Header: 'Заглавие на таблицата',
+ URL: 'URL',
+ Title: 'Заглавие',
+ Alternative_Text: 'Алтернативен текст',
+ Caption: 'Етикет',
+ Summary: 'Общо',
+ Number_Of_Rows: 'Брой редове',
+ Number_Of_Cols: 'Брой колони',
+ Submit: 'Изпрати',
+ Cancel: 'Отмени',
+ Choose: 'Затвори',
+ Preview: 'Предварителен преглед',
+ Paste_From_Word: 'Вмъкни от MS WORD',
+ Tools: 'Инструменти',
+ Containers: 'Контейнери',
+ Classes: 'Класове',
+ Status: 'Статус',
+ Source_Code: 'Източник, код'
+};
+
View
45 public/javascripts/wymeditor/lang/cy.js
@@ -0,0 +1,45 @@
+WYMeditor.STRINGS['cy'] = {
+ Strong: 'Bras',
+ Emphasis: 'Italig',
+ Superscript: 'Uwchsgript',
+ Subscript: 'Is-sgript',
+ Ordered_List: 'Rhestr mewn Trefn',
+ Unordered_List: 'Pwyntiau Bwled',
+ Indent: 'Mewnoli',
+ Outdent: 'Alloli',
+ Undo: 'Dadwneud',
+ Redo: 'Ailwneud',
+ Link: 'Cysylltu',
+ Unlink: 'Datgysylltu',
+ Image: 'Delwedd',
+ Table: 'Tabl',
+ HTML: 'HTML',
+ Paragraph: 'Paragraff',
+ Heading_1: 'Pennawd 1',
+ Heading_2: 'Pennawd 2',
+ Heading_3: 'Pennawd 3',
+ Heading_4: 'Pennawd 4',
+ Heading_5: 'Pennawd 5',
+ Heading_6: 'Pennawd 6',
+ Preformatted: 'Rhagfformat',
+ Blockquote: 'Bloc Dyfyniad',
+ Table_Header: 'Pennyn Tabl',
+ URL: 'URL',
+ Title: 'Teitl',
+ Alternative_Text: 'Testun Amgen',
+ Caption: 'Pennawd',
+ Summary: 'Crynodeb',
+ Number_Of_Rows: 'Nifer y rhesi',
+ Number_Of_Cols: 'Nifer y colofnau',
+ Submit: 'Anfon',
+ Cancel: 'Diddymu',
+ Choose: 'Dewis',
+ Preview: 'Rhagolwg',
+ Paste_From_Word: 'Gludo o Word',
+ Tools: 'Offer',
+ Containers: 'Cynhwysyddion',
+ Classes: 'Dosbarthiadau',
+ Status: 'Statws',
+ Source_Code: 'Cod ffynhonnell'
+};
+
View
44 public/javascripts/wymeditor/lang/fi.js
@@ -0,0 +1,44 @@
+WYMeditor.STRINGS['fi'] = {
+ Strong: 'Lihavoitu',
+ Emphasis: 'Korostus',
+ Superscript: 'Yläindeksi',
+ Subscript: 'Alaindeksi',
+ Ordered_List: 'Numeroitu lista',
+ Unordered_List: 'Luettelomerkit',
+ Indent: 'Suurenna sisennystä',
+ Outdent: 'Pienennä sisennystä',
+ Undo: 'Kumoa',
+ Redo: 'Toista',
+ Link: 'Linkitä',
+ Unlink: 'Poista linkitys',
+ Image: 'Kuva',
+ Table: 'Taulukko',
+ HTML: 'HTML',
+ Paragraph: 'Kappale',
+ Heading_1: 'Otsikko 1',
+ Heading_2: 'Otsikko 2',
+ Heading_3: 'Otsikko 3',
+ Heading_4: 'Otsikko 4',
+ Heading_5: 'Otsikko 5',
+ Heading_6: 'Otsikko 6',
+ Preformatted: 'Esimuotoilu',
+ Blockquote: 'Sitaatti',
+ Table_Header: 'Taulukon otsikko',
+ URL: 'URL',
+ Title: 'Otsikko',
+ Alternative_Text: 'Vaihtoehtoinen teksti',
+ Caption: 'Kuvateksti',
+ Summary: 'Yhteenveto',
+ Number_Of_Rows: 'Rivien määrä',
+ Number_Of_Cols: 'Palstojen määrä',
+ Submit: 'Lähetä',
+ Cancel: 'Peruuta',
+ Choose: 'Valitse',
+ Preview: 'Esikatsele',
+ Paste_From_Word: 'Tuo Wordista',
+ Tools: 'Työkalut',
+ Containers: 'Muotoilut',
+ Classes: 'Luokat',
+ Status: 'Tila',
+ Source_Code: 'Lähdekoodi'
+};
View
45 public/javascripts/wymeditor/lang/gl.js
@@ -0,0 +1,45 @@
+WYMeditor.STRINGS['gl'] = {
+ Strong: 'Moita énfase',
+ Emphasis: 'Énfase',
+ Superscript: 'Superíndice',
+ Subscript: 'Subíndice',
+ Ordered_List: 'Lista ordenada',
+ Unordered_List: 'Lista sen ordenar',
+ Indent: 'Aniñar',
+ Outdent: 'Desaniñar',
+ Undo: 'Desfacer',
+ Redo: 'Refacer',
+ Link: 'Ligazón',
+ Unlink: 'Desligar',
+ Image: 'Imaxe',
+ Table: 'Táboa',
+ HTML: 'HTML',
+ Paragraph: 'Parágrafo',
+ Heading_1: 'Título 1',
+ Heading_2: 'Título 2',
+ Heading_3: 'Título 3',
+ Heading_4: 'Título 4',
+ Heading_5: 'Título 5',
+ Heading_6: 'Título 6',
+ Preformatted: 'Preformatado',
+ Blockquote: 'Cita en parágrafo',
+ Table_Header: 'Cabeceira da táboa',
+ URL: 'URL',
+ Title: 'Título',
+ Alternative_Text: 'Texto alternativo',
+ Caption: 'Título',
+ Summary: 'Resumo',
+ Number_Of_Rows: 'Número de filas',
+ Number_Of_Cols: 'Número de columnas',
+ Submit: 'Enviar',
+ Cancel: 'Cancelar',
+ Choose: 'Escoller',
+ Preview: 'Previsualizar',
+ Paste_From_Word: 'Colar dende Word',
+ Tools: 'Ferramentas',
+ Containers: 'Contenedores',
+ Classes: 'Clases',
+ Status: 'Estado',
+ Source_Code: 'Código fonte'
+};
+
View
45 public/javascripts/wymeditor/lang/hr.js
@@ -0,0 +1,45 @@
+WYMeditor.STRINGS['hr'] = {
+ Strong: 'Podebljano',
+ Emphasis: 'Naglašeno',
+ Superscript: 'Iznad',
+ Subscript: 'Ispod',
+ Ordered_List: 'Pobrojana lista',
+ Unordered_List: 'Nepobrojana lista',
+ Indent: 'Uvuci',
+ Outdent: 'Izvuci',
+ Undo: 'Poništi promjenu',
+ Redo: 'Ponovno promjeni',
+ Link: 'Hiperveza',
+ Unlink: 'Ukloni hipervezu',
+ Image: 'Slika',
+ Table: 'Tablica',
+ HTML: 'HTML',
+ Paragraph: 'Paragraf',
+ Heading_1: 'Naslov 1',
+ Heading_2: 'Naslov 2',
+ Heading_3: 'Naslov 3',
+ Heading_4: 'Naslov 4',
+ Heading_5: 'Naslov 5',
+ Heading_6: 'Naslov 6',
+ Preformatted: 'Unaprijed formatirano',
+ Blockquote: 'Citat',
+ Table_Header: 'Zaglavlje tablice',
+ URL: 'URL',
+ Title: 'Naslov',
+ Alternative_Text: 'Alternativni tekst',
+ Caption: 'Zaglavlje',
+ Summary: 'Sažetak',
+ Number_Of_Rows: 'Broj redova',
+ Number_Of_Cols: 'Broj kolona',
+ Submit: 'Snimi',
+ Cancel: 'Odustani',
+ Choose: 'Izaberi',
+ Preview: 'Pregled',
+ Paste_From_Word: 'Zalijepi iz Word-a',
+ Tools: 'Alati',
+ Containers: 'Kontejneri',
+ Classes: 'Klase',
+ Status: 'Status',
+ Source_Code: 'Izvorni kod'
+};
+
View
52 public/javascripts/wymeditor/plugins/embed/jquery.wymeditor.embed.js
@@ -0,0 +1,52 @@
+/*
+ * WYMeditor : what you see is What You Mean web-based editor
+ * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
+ * Dual licensed under the MIT (MIT-license.txt)
+ * and GPL (GPL-license.txt) licenses.
+ *
+ * For further information visit:
+ * http://www.wymeditor.org/
+ *
+ * File Name:
+ * jquery.wymeditor.embed.js
+ * Experimental embed plugin
+ *
+ * File Authors:
+ * Jonatan Lundin (jonatan.lundin a-t gmail dotcom)
+ */
+
+/*
+ * ISSUES:
+ * - The closing object tag seems to be stripped out...
+ */
+(function() {
+ if (WYMeditor && WYMeditor.XhtmlValidator['_tags']['param']['attributes']) {
+
+ WYMeditor.XhtmlValidator['_tags']["embed"] = {
+ "attributes":[
+ "allowscriptaccess",
+ "allowfullscreen",
+ "height",
+ "src",
+ "type",
+ "width"
+ ]
+ };
+
+ WYMeditor.XhtmlValidator[