spiderfw 0.6.38 → 0.6.39
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +13 -5
- data/CHANGELOG +23 -0
- data/VERSION +1 -1
- data/apps/core/admin/views/admin.layout.shtml +6 -0
- data/apps/core/auth/controllers/login_controller.rb +1 -1
- data/apps/core/components/assets.rb +55 -6
- data/apps/core/components/public/bootstrap/scss/_variables.scss +5 -2
- data/apps/core/components/public/bootstrap/scss/bootstrap.css +942 -236
- data/apps/core/components/public/bootstrap/scss/responsive.css +187 -30
- data/apps/core/components/public/css/tinymce/skins/lightgray/AbsoluteLayout.less +17 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Animations.less +10 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Button.less +172 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ButtonGroup.less +71 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Checkbox.less +49 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ColorBox.less +6 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ColorButton.less +72 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ColorPicker.less +80 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ComboBox.less +39 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Container.less +9 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Content.Inline.less +4 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Content.Objects.less +166 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Content.less +27 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/CropRect.less +54 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/FieldSet.less +15 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/FitLayout.less +9 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/FloatPanel.less +69 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/FlowLayout.less +36 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Icons.Ie7.less +136 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Icons.less +180 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Iframe.less +6 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ImagePanel.less +20 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/InfoBox.less +71 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Label.less +38 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ListBox.less +26 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Menu.less +34 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/MenuBar.less +32 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/MenuButton.less +34 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/MenuItem.less +142 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Mixins.less +54 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Notification.less +144 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Panel.less +7 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Path.less +45 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Progress.less +34 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Radio.less +1 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Reset.less +32 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ResizeHandle.less +18 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Scrollable.less +44 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/SelectBox.less +6 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Slider.less +29 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Spacer.less +5 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/SplitButton.less +49 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/StackLayout.less +5 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/TabPanel.less +44 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/TextBox.less +41 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Throbber.less +19 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/TinyMCE.less +159 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/ToolTip.less +129 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Variables.less +214 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/Window.less +127 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/content.inline.min.css +1 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/content.min.css +1 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/readme.md +1 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce-small.eot +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce-small.json +1277 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce-small.svg +63 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce-small.ttf +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce-small.woff +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce.eot +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce.json +3381 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce.svg +129 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce.ttf +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/fonts/tinymce.woff +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/img/anchor.gif +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/img/loader.gif +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/img/object.gif +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/img/trans.gif +0 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/skin.dev.less +46 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/skin.ie7.dev.less +46 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/skin.ie7.less +2542 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/skin.ie7.min.css +1 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/skin.less +2586 -0
- data/apps/core/components/public/css/tinymce/skins/lightgray/skin.min.css +1 -0
- data/apps/core/components/public/js/bootbox_2/bootbox.js +551 -0
- data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-it-min.js +4 -0
- data/apps/core/components/public/js/spider.js +7 -3
- data/apps/core/components/public/js/tinymce/classes/AddOnManager.js +265 -0
- data/apps/core/components/public/js/tinymce/classes/Compat.js +90 -0
- data/apps/core/components/public/js/tinymce/classes/DragDropOverrides.js +224 -0
- data/apps/core/components/public/js/tinymce/classes/Editor.js +2221 -0
- data/apps/core/components/public/js/tinymce/classes/EditorCommands.js +1028 -0
- data/apps/core/components/public/js/tinymce/classes/EditorManager.js +715 -0
- data/apps/core/components/public/js/tinymce/classes/EditorObservable.js +204 -0
- data/apps/core/components/public/js/tinymce/classes/EditorUpload.js +191 -0
- data/apps/core/components/public/js/tinymce/classes/EnterKey.js +676 -0
- data/apps/core/components/public/js/tinymce/classes/Env.js +177 -0
- data/apps/core/components/public/js/tinymce/classes/FocusManager.js +266 -0
- data/apps/core/components/public/js/tinymce/classes/ForceBlocks.js +138 -0
- data/apps/core/components/public/js/tinymce/classes/Formatter.js +2378 -0
- data/apps/core/components/public/js/tinymce/classes/LegacyInput.js +82 -0
- data/apps/core/components/public/js/tinymce/classes/Mode.js +54 -0
- data/apps/core/components/public/js/tinymce/classes/NodeChange.js +154 -0
- data/apps/core/components/public/js/tinymce/classes/NotificationManager.js +156 -0
- data/apps/core/components/public/js/tinymce/classes/Register.js +34 -0
- data/apps/core/components/public/js/tinymce/classes/SelectionOverrides.js +810 -0
- data/apps/core/components/public/js/tinymce/classes/Shortcuts.js +172 -0
- data/apps/core/components/public/js/tinymce/classes/UndoManager.js +346 -0
- data/apps/core/components/public/js/tinymce/classes/WindowManager.js +278 -0
- data/apps/core/components/public/js/tinymce/classes/caret/CaretBookmark.js +263 -0
- data/apps/core/components/public/js/tinymce/classes/caret/CaretCandidate.js +86 -0
- data/apps/core/components/public/js/tinymce/classes/caret/CaretContainer.js +151 -0
- data/apps/core/components/public/js/tinymce/classes/caret/CaretPosition.js +371 -0
- data/apps/core/components/public/js/tinymce/classes/caret/CaretUtils.js +302 -0
- data/apps/core/components/public/js/tinymce/classes/caret/CaretWalker.js +215 -0
- data/apps/core/components/public/js/tinymce/classes/caret/FakeCaret.js +192 -0
- data/apps/core/components/public/js/tinymce/classes/caret/LineUtils.js +135 -0
- data/apps/core/components/public/js/tinymce/classes/caret/LineWalker.js +166 -0
- data/apps/core/components/public/js/tinymce/classes/data/Binding.js +79 -0
- data/apps/core/components/public/js/tinymce/classes/data/ObservableArray.js +196 -0
- data/apps/core/components/public/js/tinymce/classes/data/ObservableObject.js +194 -0
- data/apps/core/components/public/js/tinymce/classes/dom/BookmarkManager.js +456 -0
- data/apps/core/components/public/js/tinymce/classes/dom/ControlSelection.js +634 -0
- data/apps/core/components/public/js/tinymce/classes/dom/DOMUtils.js +1853 -0
- data/apps/core/components/public/js/tinymce/classes/dom/Dimensions.js +64 -0
- data/apps/core/components/public/js/tinymce/classes/dom/DomQuery.js +1578 -0
- data/apps/core/components/public/js/tinymce/classes/dom/ElementUtils.js +118 -0
- data/apps/core/components/public/js/tinymce/classes/dom/EventUtils.js +583 -0
- data/apps/core/components/public/js/tinymce/classes/dom/NodePath.js +50 -0
- data/apps/core/components/public/js/tinymce/classes/dom/NodeType.js +110 -0
- data/apps/core/components/public/js/tinymce/classes/dom/Range.js +785 -0
- data/apps/core/components/public/js/tinymce/classes/dom/RangeUtils.js +628 -0
- data/apps/core/components/public/js/tinymce/classes/dom/ScriptLoader.js +254 -0
- data/apps/core/components/public/js/tinymce/classes/dom/Selection.js +1008 -0
- data/apps/core/components/public/js/tinymce/classes/dom/Serializer.js +506 -0
- data/apps/core/components/public/js/tinymce/classes/dom/Sizzle.jQuery.js +23 -0
- data/apps/core/components/public/js/tinymce/classes/dom/Sizzle.js +2039 -0
- data/apps/core/components/public/js/tinymce/classes/dom/StyleSheetLoader.js +190 -0
- data/apps/core/components/public/js/tinymce/classes/dom/TreeWalker.js +127 -0
- data/apps/core/components/public/js/tinymce/classes/dom/TridentSelection.js +508 -0
- data/apps/core/components/public/js/tinymce/classes/file/BlobCache.js +72 -0
- data/apps/core/components/public/js/tinymce/classes/file/Conversions.js +106 -0
- data/apps/core/components/public/js/tinymce/classes/file/ImageScanner.js +145 -0
- data/apps/core/components/public/js/tinymce/classes/file/Uploader.js +193 -0
- data/apps/core/components/public/js/tinymce/classes/fmt/Hooks.js +66 -0
- data/apps/core/components/public/js/tinymce/classes/fmt/Preview.js +151 -0
- data/apps/core/components/public/js/tinymce/classes/geom/ClientRect.js +136 -0
- data/apps/core/components/public/js/tinymce/classes/geom/Rect.js +214 -0
- data/apps/core/components/public/js/tinymce/classes/html/DomParser.js +822 -0
- data/apps/core/components/public/js/tinymce/classes/html/Entities.js +268 -0
- data/apps/core/components/public/js/tinymce/classes/html/Node.js +496 -0
- data/apps/core/components/public/js/tinymce/classes/html/SaxParser.js +474 -0
- data/apps/core/components/public/js/tinymce/classes/html/Schema.js +1004 -0
- data/apps/core/components/public/js/tinymce/classes/html/Serializer.js +158 -0
- data/apps/core/components/public/js/tinymce/classes/html/Styles.js +363 -0
- data/apps/core/components/public/js/tinymce/classes/html/Writer.js +199 -0
- data/apps/core/components/public/js/tinymce/classes/jquery.tinymce.js +377 -0
- data/apps/core/components/public/js/tinymce/classes/text/ExtendingChar.js +53 -0
- data/apps/core/components/public/js/tinymce/classes/text/Zwsp.js +36 -0
- data/apps/core/components/public/js/tinymce/classes/ui/AbsoluteLayout.js +63 -0
- data/apps/core/components/public/js/tinymce/classes/ui/BoxUtils.js +98 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Button.js +199 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ButtonGroup.js +62 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Checkbox.js +162 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ClassList.js +149 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Collection.js +438 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ColorBox.js +72 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ColorButton.js +124 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ColorPicker.js +206 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ComboBox.js +306 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Container.js +506 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Control.js +1301 -0
- data/apps/core/components/public/js/tinymce/classes/ui/DomUtils.js +107 -0
- data/apps/core/components/public/js/tinymce/classes/ui/DragHelper.js +144 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ElementPath.js +79 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Factory.js +105 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FieldSet.js +59 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FilePicker.js +85 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FitLayout.js +48 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FlexLayout.js +246 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FloatPanel.js +409 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FlowLayout.js +46 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Form.js +157 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FormItem.js +56 -0
- data/apps/core/components/public/js/tinymce/classes/ui/FormatControls.js +535 -0
- data/apps/core/components/public/js/tinymce/classes/ui/GridLayout.js +233 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Iframe.js +85 -0
- data/apps/core/components/public/js/tinymce/classes/ui/InfoBox.js +93 -0
- data/apps/core/components/public/js/tinymce/classes/ui/KeyboardNavigation.js +406 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Label.js +144 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Layout.js +120 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ListBox.js +152 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Menu.js +195 -0
- data/apps/core/components/public/js/tinymce/classes/ui/MenuBar.js +33 -0
- data/apps/core/components/public/js/tinymce/classes/ui/MenuButton.js +268 -0
- data/apps/core/components/public/js/tinymce/classes/ui/MenuItem.js +336 -0
- data/apps/core/components/public/js/tinymce/classes/ui/MessageBox.js +202 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Movable.js +200 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Notification.js +154 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Panel.js +67 -0
- data/apps/core/components/public/js/tinymce/classes/ui/PanelButton.js +114 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Path.js +127 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Progress.js +81 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Radio.js +29 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ReflowQueue.js +79 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Resizable.js +68 -0
- data/apps/core/components/public/js/tinymce/classes/ui/ResizeHandle.js +86 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Scrollable.js +141 -0
- data/apps/core/components/public/js/tinymce/classes/ui/SelectBox.js +106 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Selector.js +369 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Slider.js +161 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Spacer.js +39 -0
- data/apps/core/components/public/js/tinymce/classes/ui/SplitButton.js +146 -0
- data/apps/core/components/public/js/tinymce/classes/ui/StackLayout.js +34 -0
- data/apps/core/components/public/js/tinymce/classes/ui/TabPanel.js +178 -0
- data/apps/core/components/public/js/tinymce/classes/ui/TextBox.js +208 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Throbber.js +88 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Toolbar.js +56 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Tooltip.js +73 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Widget.js +151 -0
- data/apps/core/components/public/js/tinymce/classes/ui/Window.js +474 -0
- data/apps/core/components/public/js/tinymce/classes/util/Arr.js +153 -0
- data/apps/core/components/public/js/tinymce/classes/util/Class.js +167 -0
- data/apps/core/components/public/js/tinymce/classes/util/Color.js +235 -0
- data/apps/core/components/public/js/tinymce/classes/util/Delay.js +191 -0
- data/apps/core/components/public/js/tinymce/classes/util/EventDispatcher.js +294 -0
- data/apps/core/components/public/js/tinymce/classes/util/Fun.js +87 -0
- data/apps/core/components/public/js/tinymce/classes/util/I18n.js +116 -0
- data/apps/core/components/public/js/tinymce/classes/util/JSON.js +109 -0
- data/apps/core/components/public/js/tinymce/classes/util/JSONP.js +38 -0
- data/apps/core/components/public/js/tinymce/classes/util/JSONRequest.js +110 -0
- data/apps/core/components/public/js/tinymce/classes/util/LocalStorage.js +213 -0
- data/apps/core/components/public/js/tinymce/classes/util/Observable.js +129 -0
- data/apps/core/components/public/js/tinymce/classes/util/Promise.js +200 -0
- data/apps/core/components/public/js/tinymce/classes/util/Quirks.js +1701 -0
- data/apps/core/components/public/js/tinymce/classes/util/Tools.js +442 -0
- data/apps/core/components/public/js/tinymce/classes/util/URI.js +411 -0
- data/apps/core/components/public/js/tinymce/classes/util/VK.js +37 -0
- data/apps/core/components/public/js/tinymce/classes/util/XHR.js +110 -0
- data/apps/core/components/public/js/tinymce/jquery.tinymce.min.js +1 -0
- data/apps/core/components/public/js/tinymce/langs/it.js +219 -0
- data/apps/core/components/public/js/tinymce/langs/readme.md +3 -0
- data/apps/core/components/public/js/tinymce/license.txt +504 -0
- data/apps/core/components/public/js/tinymce/plugins/advlist/plugin.js +97 -0
- data/apps/core/components/public/js/tinymce/plugins/advlist/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/anchor/plugin.js +55 -0
- data/apps/core/components/public/js/tinymce/plugins/anchor/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/autolink/plugin.js +204 -0
- data/apps/core/components/public/js/tinymce/plugins/autolink/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/autoresize/plugin.js +162 -0
- data/apps/core/components/public/js/tinymce/plugins/autoresize/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/autosave/plugin.js +165 -0
- data/apps/core/components/public/js/tinymce/plugins/autosave/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/bbcode/plugin.js +123 -0
- data/apps/core/components/public/js/tinymce/plugins/bbcode/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/charmap/plugin.js +450 -0
- data/apps/core/components/public/js/tinymce/plugins/charmap/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/code/plugin.js +60 -0
- data/apps/core/components/public/js/tinymce/plugins/code/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/classes/Dialog.js +121 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/classes/Plugin.js +95 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/classes/Prism.js +937 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/classes/Utils.js +33 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/css/prism.css +138 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/plugin.dev.js +141 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/plugin.js +1299 -0
- data/apps/core/components/public/js/tinymce/plugins/codesample/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/colorpicker/plugin.js +112 -0
- data/apps/core/components/public/js/tinymce/plugins/colorpicker/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/css/dialog.css +118 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/buttons.png +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/icons.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/items.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/menu_arrow.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/menu_check.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/progress.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/img/tabs.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/plugin.js +297 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/tiny_mce_popup.js +542 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/utils/editable_selects.js +70 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/utils/form_utils.js +210 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/utils/mctabs.js +164 -0
- data/apps/core/components/public/js/tinymce/plugins/compat3x/utils/validate.js +252 -0
- data/apps/core/components/public/js/tinymce/plugins/contextmenu/plugin.js +88 -0
- data/apps/core/components/public/js/tinymce/plugins/contextmenu/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/directionality/plugin.js +64 -0
- data/apps/core/components/public/js/tinymce/plugins/directionality/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-cool.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-cry.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-embarassed.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-foot-in-mouth.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-frown.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-innocent.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-kiss.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-laughing.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-money-mouth.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-sealed.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-smile.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-surprised.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-tongue-out.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-undecided.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-wink.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/img/smiley-yell.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/plugin.js +65 -0
- data/apps/core/components/public/js/tinymce/plugins/emoticons/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/example/dialog.html +8 -0
- data/apps/core/components/public/js/tinymce/plugins/example/plugin.js +68 -0
- data/apps/core/components/public/js/tinymce/plugins/example/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/example_dependency/plugin.js +22 -0
- data/apps/core/components/public/js/tinymce/plugins/example_dependency/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/fullpage/plugin.js +490 -0
- data/apps/core/components/public/js/tinymce/plugins/fullpage/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/fullscreen/plugin.js +154 -0
- data/apps/core/components/public/js/tinymce/plugins/fullscreen/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/hr/plugin.js +30 -0
- data/apps/core/components/public/js/tinymce/plugins/hr/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/image/plugin.js +630 -0
- data/apps/core/components/public/js/tinymce/plugins/image/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/config/bolt/atomic.js +6 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/config/bolt/browser.js +6 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/config/bolt/demo.js +8 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/config/bolt/prod.js +6 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/plugin.js +2668 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/demo/html/demo.html +16 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/demo/js/Demo.js +92 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/main/js/CropRect.js +214 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/main/js/Dialog.js +485 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/main/js/ImagePanel.js +218 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/main/js/Plugin.js +411 -0
- data/apps/core/components/public/js/tinymce/plugins/imagetools/src/main/js/UndoStack.js +57 -0
- data/apps/core/components/public/js/tinymce/plugins/importcss/plugin.js +227 -0
- data/apps/core/components/public/js/tinymce/plugins/importcss/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/insertdatetime/plugin.js +121 -0
- data/apps/core/components/public/js/tinymce/plugins/insertdatetime/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/layer/plugin.js +225 -0
- data/apps/core/components/public/js/tinymce/plugins/layer/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/legacyoutput/plugin.js +211 -0
- data/apps/core/components/public/js/tinymce/plugins/legacyoutput/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/link/plugin.js +403 -0
- data/apps/core/components/public/js/tinymce/plugins/link/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/lists/plugin.js +885 -0
- data/apps/core/components/public/js/tinymce/plugins/lists/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/media/moxieplayer.swf +0 -0
- data/apps/core/components/public/js/tinymce/plugins/media/plugin.js +878 -0
- data/apps/core/components/public/js/tinymce/plugins/media/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/nonbreaking/plugin.js +53 -0
- data/apps/core/components/public/js/tinymce/plugins/nonbreaking/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/noneditable/plugin.js +101 -0
- data/apps/core/components/public/js/tinymce/plugins/noneditable/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/pagebreak/plugin.js +88 -0
- data/apps/core/components/public/js/tinymce/plugins/pagebreak/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/classes/Clipboard.js +672 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/classes/Plugin.js +121 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/classes/Quirks.js +159 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/classes/Utils.js +140 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/classes/WordFilter.js +500 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/plugin.dev.js +142 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/plugin.js +1708 -0
- data/apps/core/components/public/js/tinymce/plugins/paste/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/preview/plugin.js +88 -0
- data/apps/core/components/public/js/tinymce/plugins/preview/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/print/plugin.js +32 -0
- data/apps/core/components/public/js/tinymce/plugins/print/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/save/plugin.js +98 -0
- data/apps/core/components/public/js/tinymce/plugins/save/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/searchreplace/plugin.js +609 -0
- data/apps/core/components/public/js/tinymce/plugins/searchreplace/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/spellchecker/classes/DomTextMatcher.js +480 -0
- data/apps/core/components/public/js/tinymce/plugins/spellchecker/classes/Plugin.js +439 -0
- data/apps/core/components/public/js/tinymce/plugins/spellchecker/plugin.dev.js +139 -0
- data/apps/core/components/public/js/tinymce/plugins/spellchecker/plugin.js +1026 -0
- data/apps/core/components/public/js/tinymce/plugins/spellchecker/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/tabfocus/plugin.js +120 -0
- data/apps/core/components/public/js/tinymce/plugins/tabfocus/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/CellSelection.js +202 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/Dialogs.js +824 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/Plugin.js +599 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/Quirks.js +400 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/ResizeBars.js +984 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/TableGrid.js +941 -0
- data/apps/core/components/public/js/tinymce/plugins/table/classes/Utils.js +36 -0
- data/apps/core/components/public/js/tinymce/plugins/table/plugin.dev.js +142 -0
- data/apps/core/components/public/js/tinymce/plugins/table/plugin.js +4106 -0
- data/apps/core/components/public/js/tinymce/plugins/table/plugin.min.js +2 -0
- data/apps/core/components/public/js/tinymce/plugins/template/plugin.js +270 -0
- data/apps/core/components/public/js/tinymce/plugins/template/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/textcolor/plugin.js +282 -0
- data/apps/core/components/public/js/tinymce/plugins/textcolor/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/textpattern/plugin.js +268 -0
- data/apps/core/components/public/js/tinymce/plugins/textpattern/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/css/visualblocks.css +135 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/address.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/article.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/aside.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/blockquote.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/div.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/dl.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/figure.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/h1.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/h2.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/h3.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/h4.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/h5.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/h6.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/hgroup.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/ol.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/p.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/pre.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/section.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/img/ul.gif +0 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/plugin.js +86 -0
- data/apps/core/components/public/js/tinymce/plugins/visualblocks/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/visualchars/plugin.js +123 -0
- data/apps/core/components/public/js/tinymce/plugins/visualchars/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/plugins/wordcount/plugin.js +69 -0
- data/apps/core/components/public/js/tinymce/plugins/wordcount/plugin.min.js +1 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/AbsoluteLayout.less +17 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Animations.less +10 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Button.less +172 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ButtonGroup.less +71 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Checkbox.less +49 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ColorBox.less +6 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ColorButton.less +72 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ColorPicker.less +80 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ComboBox.less +39 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Container.less +9 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Content.Inline.less +4 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Content.Objects.less +166 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Content.less +27 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/CropRect.less +54 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/FieldSet.less +15 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/FitLayout.less +9 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/FloatPanel.less +69 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/FlowLayout.less +36 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Icons.Ie7.less +136 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Icons.less +180 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Iframe.less +6 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ImagePanel.less +20 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/InfoBox.less +71 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Label.less +38 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ListBox.less +26 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Menu.less +34 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/MenuBar.less +32 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/MenuButton.less +34 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/MenuItem.less +142 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Mixins.less +54 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Notification.less +144 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Panel.less +7 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Path.less +45 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Progress.less +34 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Radio.less +1 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Reset.less +32 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ResizeHandle.less +18 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Scrollable.less +44 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/SelectBox.less +6 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Slider.less +29 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Spacer.less +5 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/SplitButton.less +49 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/StackLayout.less +5 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/TabPanel.less +44 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/TextBox.less +41 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Throbber.less +19 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/TinyMCE.less +159 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/ToolTip.less +129 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Variables.less +214 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/Window.less +127 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/content.inline.min.css +1 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/content.min.css +1 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/readme.md +1 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce-small.eot +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce-small.json +1277 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce-small.svg +63 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce-small.ttf +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce-small.woff +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce.eot +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce.json +3381 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce.svg +129 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce.ttf +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/fonts/tinymce.woff +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/img/anchor.gif +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/img/loader.gif +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/img/object.gif +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/img/trans.gif +0 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/skin.dev.less +46 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/skin.ie7.dev.less +46 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/skin.ie7.less +2542 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/skin.ie7.min.css +1 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/skin.less +2586 -0
- data/apps/core/components/public/js/tinymce/skins/lightgray/skin.min.css +1 -0
- data/apps/core/components/public/js/tinymce/themes/modern/theme.js +878 -0
- data/apps/core/components/public/js/tinymce/themes/modern/theme.min.js +1 -0
- data/apps/core/components/public/js/tinymce/tinymce.dev.js +286 -0
- data/apps/core/components/public/js/tinymce/tinymce.js +45811 -0
- data/apps/core/components/public/js/tinymce/tinymce.min.js +13 -0
- data/apps/core/forms/widgets/form/form.rb +3 -1
- data/apps/core/forms/widgets/form/form.shtml +1 -0
- data/apps/core/forms/widgets/inputs/search_select/search_select.rb +1 -1
- data/apps/core/forms/widgets/inputs/select/select.rb +1 -1
- data/apps/core/forms/widgets/inputs/select/select.shtml +0 -1
- data/apps/messenger/backends/sms/skebby.rb +1 -1
- data/apps/messenger/controllers/mixins/messenger_helper.rb +23 -5
- data/lib/spiderfw/config/options/spider.rb +1 -1
- data/lib/spiderfw/controller/mixins/visual.rb +2 -0
- data/lib/spiderfw/http/adapters/rack.rb +10 -5
- data/lib/spiderfw/http/http.rb +4 -2
- data/lib/spiderfw/model/base_model.rb +4 -4
- data/lib/spiderfw/model/mappers/db_mapper.rb +4 -2
- data/lib/spiderfw/model/storage/db/adapters/mysql.rb +2 -1
- data/lib/spiderfw/model/storage/db/db_storage.rb +4 -0
- data/lib/spiderfw/spider.rb +6 -0
- data/lib/spiderfw/templates/layout.rb +1 -1
- data/lib/spiderfw/utils/monkey/object.rb +3 -0
- data/spider.gemspec +6 -2
- metadata +539 -42
- data/blueprints/.DS_Store +0 -0
@@ -0,0 +1,218 @@
|
|
1
|
+
/**
|
2
|
+
* ImagePanel.js
|
3
|
+
*
|
4
|
+
* Released under LGPL License.
|
5
|
+
* Copyright (c) 1999-2016 Ephox Corp. All rights reserved
|
6
|
+
*
|
7
|
+
* License: http://www.tinymce.com/license
|
8
|
+
* Contributing: http://www.tinymce.com/contributing
|
9
|
+
*/
|
10
|
+
|
11
|
+
/**
|
12
|
+
* ...
|
13
|
+
*
|
14
|
+
* @-x-less ImagePanel.less
|
15
|
+
*/
|
16
|
+
define("tinymce/imagetoolsplugin/ImagePanel", [
|
17
|
+
"global!tinymce.ui.Control",
|
18
|
+
"global!tinymce.ui.DragHelper",
|
19
|
+
"global!tinymce.geom.Rect",
|
20
|
+
"global!tinymce.util.Tools",
|
21
|
+
"global!tinymce.util.Promise",
|
22
|
+
"tinymce/imagetoolsplugin/CropRect"
|
23
|
+
], function(Control, DragHelper, Rect, Tools, Promise, CropRect) {
|
24
|
+
function loadImage(image) {
|
25
|
+
return new Promise(function(resolve) {
|
26
|
+
function loaded() {
|
27
|
+
image.removeEventListener('load', loaded);
|
28
|
+
resolve(image);
|
29
|
+
}
|
30
|
+
|
31
|
+
if (image.complete) {
|
32
|
+
resolve(image);
|
33
|
+
} else {
|
34
|
+
image.addEventListener('load', loaded);
|
35
|
+
}
|
36
|
+
});
|
37
|
+
}
|
38
|
+
|
39
|
+
return Control.extend({
|
40
|
+
Defaults: {
|
41
|
+
classes: "imagepanel"
|
42
|
+
},
|
43
|
+
|
44
|
+
selection: function(rect) {
|
45
|
+
if (arguments.length) {
|
46
|
+
this.state.set('rect', rect);
|
47
|
+
return this;
|
48
|
+
}
|
49
|
+
|
50
|
+
return this.state.get('rect');
|
51
|
+
},
|
52
|
+
|
53
|
+
imageSize: function() {
|
54
|
+
var viewRect = this.state.get('viewRect');
|
55
|
+
|
56
|
+
return {
|
57
|
+
w: viewRect.w,
|
58
|
+
h: viewRect.h
|
59
|
+
};
|
60
|
+
},
|
61
|
+
|
62
|
+
toggleCropRect: function(state) {
|
63
|
+
this.state.set('cropEnabled', state);
|
64
|
+
},
|
65
|
+
|
66
|
+
imageSrc: function(url) {
|
67
|
+
var self = this, img = new Image();
|
68
|
+
|
69
|
+
img.src = url;
|
70
|
+
|
71
|
+
loadImage(img).then(function() {
|
72
|
+
var rect, $img, lastRect = self.state.get('viewRect');
|
73
|
+
|
74
|
+
$img = self.$el.find('img');
|
75
|
+
if ($img[0]) {
|
76
|
+
$img.replaceWith(img);
|
77
|
+
} else {
|
78
|
+
self.getEl().appendChild(img);
|
79
|
+
}
|
80
|
+
|
81
|
+
rect = {x: 0, y: 0, w: img.naturalWidth, h: img.naturalHeight};
|
82
|
+
self.state.set('viewRect', rect);
|
83
|
+
self.state.set('rect', Rect.inflate(rect, -20, -20));
|
84
|
+
|
85
|
+
if (!lastRect || lastRect.w != rect.w || lastRect.h != rect.h) {
|
86
|
+
self.zoomFit();
|
87
|
+
}
|
88
|
+
|
89
|
+
self.repaintImage();
|
90
|
+
self.fire('load');
|
91
|
+
});
|
92
|
+
},
|
93
|
+
|
94
|
+
zoom: function(value) {
|
95
|
+
if (arguments.length) {
|
96
|
+
this.state.set('zoom', value);
|
97
|
+
return this;
|
98
|
+
}
|
99
|
+
|
100
|
+
return this.state.get('zoom');
|
101
|
+
},
|
102
|
+
|
103
|
+
postRender: function() {
|
104
|
+
this.imageSrc(this.settings.imageSrc);
|
105
|
+
return this._super();
|
106
|
+
},
|
107
|
+
|
108
|
+
zoomFit: function() {
|
109
|
+
var self = this, $img, pw, ph, w, h, zoom, padding;
|
110
|
+
|
111
|
+
padding = 10;
|
112
|
+
$img = self.$el.find('img');
|
113
|
+
pw = self.getEl().clientWidth;
|
114
|
+
ph = self.getEl().clientHeight;
|
115
|
+
w = $img[0].naturalWidth;
|
116
|
+
h = $img[0].naturalHeight;
|
117
|
+
zoom = Math.min((pw - padding) / w, (ph - padding) / h);
|
118
|
+
|
119
|
+
if (zoom >= 1) {
|
120
|
+
zoom = 1;
|
121
|
+
}
|
122
|
+
|
123
|
+
self.zoom(zoom);
|
124
|
+
},
|
125
|
+
|
126
|
+
repaintImage: function() {
|
127
|
+
var x, y, w, h, pw, ph, $img, zoom, rect, elm;
|
128
|
+
|
129
|
+
elm = this.getEl();
|
130
|
+
zoom = this.zoom();
|
131
|
+
rect = this.state.get('rect');
|
132
|
+
$img = this.$el.find('img');
|
133
|
+
pw = elm.offsetWidth;
|
134
|
+
ph = elm.offsetHeight;
|
135
|
+
w = $img[0].naturalWidth * zoom;
|
136
|
+
h = $img[0].naturalHeight * zoom;
|
137
|
+
x = Math.max(0, pw / 2 - w / 2);
|
138
|
+
y = Math.max(0, ph / 2 - h / 2);
|
139
|
+
|
140
|
+
$img.css({
|
141
|
+
left: x,
|
142
|
+
top: y,
|
143
|
+
width: w,
|
144
|
+
height: h
|
145
|
+
});
|
146
|
+
|
147
|
+
if (this.cropRect) {
|
148
|
+
this.cropRect.setRect({
|
149
|
+
x: rect.x * zoom + x,
|
150
|
+
y: rect.y * zoom + y,
|
151
|
+
w: rect.w * zoom,
|
152
|
+
h: rect.h * zoom
|
153
|
+
});
|
154
|
+
|
155
|
+
this.cropRect.setClampRect({
|
156
|
+
x: x,
|
157
|
+
y: y,
|
158
|
+
w: w,
|
159
|
+
h: h
|
160
|
+
});
|
161
|
+
|
162
|
+
this.cropRect.setViewPortRect({
|
163
|
+
x: 0,
|
164
|
+
y: 0,
|
165
|
+
w: pw,
|
166
|
+
h: ph
|
167
|
+
});
|
168
|
+
}
|
169
|
+
},
|
170
|
+
|
171
|
+
bindStates: function() {
|
172
|
+
var self = this;
|
173
|
+
|
174
|
+
function setupCropRect(rect) {
|
175
|
+
self.cropRect = new CropRect(
|
176
|
+
rect,
|
177
|
+
self.state.get('viewRect'),
|
178
|
+
self.state.get('viewRect'),
|
179
|
+
self.getEl()
|
180
|
+
);
|
181
|
+
|
182
|
+
self.cropRect.on('updateRect', function(e) {
|
183
|
+
var rect = e.rect, zoom = self.zoom();
|
184
|
+
|
185
|
+
rect = {
|
186
|
+
x: Math.round(rect.x / zoom),
|
187
|
+
y: Math.round(rect.y / zoom),
|
188
|
+
w: Math.round(rect.w / zoom),
|
189
|
+
h: Math.round(rect.h / zoom)
|
190
|
+
};
|
191
|
+
|
192
|
+
self.state.set('rect', rect);
|
193
|
+
});
|
194
|
+
|
195
|
+
self.on('remove', self.cropRect.destroy);
|
196
|
+
}
|
197
|
+
|
198
|
+
self.state.on('change:cropEnabled', function(e) {
|
199
|
+
self.cropRect.toggleVisibility(e.value);
|
200
|
+
self.repaintImage();
|
201
|
+
});
|
202
|
+
|
203
|
+
self.state.on('change:zoom', function() {
|
204
|
+
self.repaintImage();
|
205
|
+
});
|
206
|
+
|
207
|
+
self.state.on('change:rect', function(e) {
|
208
|
+
var rect = e.value;
|
209
|
+
|
210
|
+
if (!self.cropRect) {
|
211
|
+
setupCropRect(rect);
|
212
|
+
}
|
213
|
+
|
214
|
+
self.cropRect.setRect(rect);
|
215
|
+
});
|
216
|
+
}
|
217
|
+
});
|
218
|
+
});
|
@@ -0,0 +1,411 @@
|
|
1
|
+
/**
|
2
|
+
* Plugin.js
|
3
|
+
*
|
4
|
+
* Released under LGPL License.
|
5
|
+
* Copyright (c) 1999-2016 Ephox Corp. All rights reserved
|
6
|
+
*
|
7
|
+
* License: http://www.tinymce.com/license
|
8
|
+
* Contributing: http://www.tinymce.com/contributing
|
9
|
+
*/
|
10
|
+
|
11
|
+
/**
|
12
|
+
*
|
13
|
+
* Settings:
|
14
|
+
* imagetools_cors_hosts - Array of remote domains that has CORS setup.
|
15
|
+
* imagetools_proxy - Url to proxy that streams images from remote host to local host.
|
16
|
+
* imagetools_toolbar - Toolbar items to render when an editable image is selected.
|
17
|
+
*/
|
18
|
+
define("tinymce/imagetoolsplugin/Plugin", [
|
19
|
+
"global!tinymce.PluginManager",
|
20
|
+
"global!tinymce.Env",
|
21
|
+
"global!tinymce.util.Promise",
|
22
|
+
"global!tinymce.util.URI",
|
23
|
+
"global!tinymce.util.Tools",
|
24
|
+
"global!tinymce.util.Delay",
|
25
|
+
"ephox/imagetools/api/ImageTransformations",
|
26
|
+
"ephox/imagetools/api/BlobConversions",
|
27
|
+
"tinymce/imagetoolsplugin/Dialog"
|
28
|
+
], function(PluginManager, Env, Promise, URI, Tools, Delay, ImageTransformations, BlobConversions, Dialog) {
|
29
|
+
var plugin = function(editor) {
|
30
|
+
var count = 0, imageUploadTimer, lastSelectedImage;
|
31
|
+
|
32
|
+
if (!Env.fileApi) {
|
33
|
+
return;
|
34
|
+
}
|
35
|
+
|
36
|
+
/*
|
37
|
+
function startCrop() {
|
38
|
+
var imageRect, viewPortRect;
|
39
|
+
|
40
|
+
imageRect = getSelectedImage().getBoundingClientRect();
|
41
|
+
|
42
|
+
imageRect = {
|
43
|
+
x: imageRect.left,
|
44
|
+
y: imageRect.top,
|
45
|
+
w: imageRect.width,
|
46
|
+
h: imageRect.height
|
47
|
+
};
|
48
|
+
|
49
|
+
viewPortRect = {
|
50
|
+
x: 0,
|
51
|
+
y: 0,
|
52
|
+
w: editor.getBody().scrollWidth,
|
53
|
+
h: editor.getBody().scrollHeight
|
54
|
+
};
|
55
|
+
|
56
|
+
cropRect = new CropRect(imageRect, viewPortRect, imageRect, editor.getBody());
|
57
|
+
cropRect.toggleVisibility(true);
|
58
|
+
|
59
|
+
editor.selection.getSel().removeAllRanges();
|
60
|
+
editor.nodeChanged();
|
61
|
+
}
|
62
|
+
|
63
|
+
function stopCrop() {
|
64
|
+
if (cropRect) {
|
65
|
+
cropRect.destroy();
|
66
|
+
cropRect = null;
|
67
|
+
}
|
68
|
+
}
|
69
|
+
*/
|
70
|
+
|
71
|
+
function getImageSize(img) {
|
72
|
+
var width, height;
|
73
|
+
|
74
|
+
function isPxValue(value) {
|
75
|
+
return value.indexOf('px') == value.length - 2;
|
76
|
+
}
|
77
|
+
|
78
|
+
width = img.style.width;
|
79
|
+
height = img.style.height;
|
80
|
+
if (width || height) {
|
81
|
+
if (isPxValue(width) && isPxValue(height)) {
|
82
|
+
return {
|
83
|
+
w: parseInt(width, 10),
|
84
|
+
h: parseInt(height, 10)
|
85
|
+
};
|
86
|
+
}
|
87
|
+
|
88
|
+
return null;
|
89
|
+
}
|
90
|
+
|
91
|
+
width = editor.$(img).attr('width');
|
92
|
+
height = editor.$(img).attr('height');
|
93
|
+
if (width && height) {
|
94
|
+
return {
|
95
|
+
w: parseInt(width, 10),
|
96
|
+
h: parseInt(height, 10)
|
97
|
+
};
|
98
|
+
}
|
99
|
+
|
100
|
+
return null;
|
101
|
+
}
|
102
|
+
|
103
|
+
function setImageSize(img, size) {
|
104
|
+
var width, height;
|
105
|
+
|
106
|
+
if (size) {
|
107
|
+
width = img.style.width;
|
108
|
+
height = img.style.height;
|
109
|
+
|
110
|
+
if (width || height) {
|
111
|
+
editor.$(img).css({
|
112
|
+
width: size.w,
|
113
|
+
height: size.h
|
114
|
+
}).removeAttr('data-mce-style');
|
115
|
+
}
|
116
|
+
|
117
|
+
width = img.width;
|
118
|
+
height = img.height;
|
119
|
+
|
120
|
+
if (width || height) {
|
121
|
+
editor.$(img).attr({
|
122
|
+
width: size.w,
|
123
|
+
height: size.h
|
124
|
+
});
|
125
|
+
}
|
126
|
+
}
|
127
|
+
}
|
128
|
+
|
129
|
+
function getNaturalImageSize(img) {
|
130
|
+
return {
|
131
|
+
w: img.naturalWidth,
|
132
|
+
h: img.naturalHeight
|
133
|
+
};
|
134
|
+
}
|
135
|
+
|
136
|
+
function getSelectedImage() {
|
137
|
+
return editor.selection.getNode();
|
138
|
+
}
|
139
|
+
|
140
|
+
function createId() {
|
141
|
+
return 'imagetools' + count++;
|
142
|
+
}
|
143
|
+
|
144
|
+
function isLocalImage(img) {
|
145
|
+
var url = img.src;
|
146
|
+
|
147
|
+
return url.indexOf('data:') === 0 || url.indexOf('blob:') === 0 || new URI(url).host === editor.documentBaseURI.host;
|
148
|
+
}
|
149
|
+
|
150
|
+
function isCorsImage(img) {
|
151
|
+
return Tools.inArray(editor.settings.imagetools_cors_hosts, new URI(img.src).host) !== -1;
|
152
|
+
}
|
153
|
+
|
154
|
+
function getApiKey() {
|
155
|
+
return editor.settings.api_key || editor.settings.imagetools_api_key;
|
156
|
+
}
|
157
|
+
|
158
|
+
function requestUrlAsBlob(url) {
|
159
|
+
return new Promise(function(resolve) {
|
160
|
+
var xhr, apiKey;
|
161
|
+
|
162
|
+
xhr = new XMLHttpRequest();
|
163
|
+
xhr.onload = function() {
|
164
|
+
resolve(this.response);
|
165
|
+
};
|
166
|
+
|
167
|
+
xhr.open('GET', url, true);
|
168
|
+
|
169
|
+
apiKey = getApiKey();
|
170
|
+
if (apiKey) {
|
171
|
+
xhr.setRequestHeader("Content-Type", "application/json;charset=UTF-8");
|
172
|
+
xhr.setRequestHeader('tiny-api-key', apiKey);
|
173
|
+
}
|
174
|
+
|
175
|
+
xhr.responseType = 'blob';
|
176
|
+
xhr.send();
|
177
|
+
});
|
178
|
+
}
|
179
|
+
|
180
|
+
function imageToBlob(img) {
|
181
|
+
var src = img.src;
|
182
|
+
|
183
|
+
if (isCorsImage(img)) {
|
184
|
+
return requestUrlAsBlob(img.src);
|
185
|
+
}
|
186
|
+
|
187
|
+
if (!isLocalImage(img)) {
|
188
|
+
src = editor.settings.imagetools_proxy;
|
189
|
+
src += (src.indexOf('?') === -1 ? '?' : '&') + 'url=' + encodeURIComponent(img.src);
|
190
|
+
|
191
|
+
if (getApiKey()) {
|
192
|
+
return requestUrlAsBlob(src);
|
193
|
+
}
|
194
|
+
|
195
|
+
img = new Image();
|
196
|
+
img.src = src;
|
197
|
+
}
|
198
|
+
|
199
|
+
return BlobConversions.imageToBlob(img);
|
200
|
+
}
|
201
|
+
|
202
|
+
function findSelectedBlobInfo() {
|
203
|
+
var blobInfo;
|
204
|
+
|
205
|
+
blobInfo = editor.editorUpload.blobCache.getByUri(getSelectedImage().src);
|
206
|
+
if (blobInfo) {
|
207
|
+
return blobInfo;
|
208
|
+
}
|
209
|
+
|
210
|
+
return imageToBlob(getSelectedImage()).then(function(blob) {
|
211
|
+
return BlobConversions.blobToBase64(blob).then(function(base64) {
|
212
|
+
var blobCache = editor.editorUpload.blobCache;
|
213
|
+
var blobInfo = blobCache.create(createId(), blob, base64);
|
214
|
+
blobCache.add(blobInfo);
|
215
|
+
return blobInfo;
|
216
|
+
});
|
217
|
+
});
|
218
|
+
}
|
219
|
+
|
220
|
+
function startTimedUpload() {
|
221
|
+
imageUploadTimer = Delay.setEditorTimeout(editor, function() {
|
222
|
+
editor.editorUpload.uploadImagesAuto();
|
223
|
+
}, 30000);
|
224
|
+
}
|
225
|
+
|
226
|
+
function cancelTimedUpload() {
|
227
|
+
clearTimeout(imageUploadTimer);
|
228
|
+
}
|
229
|
+
|
230
|
+
function updateSelectedImage(blob, uploadImmediately) {
|
231
|
+
return BlobConversions.blobToDataUri(blob).then(function(dataUri) {
|
232
|
+
var id, base64, blobCache, blobInfo, selectedImage;
|
233
|
+
|
234
|
+
selectedImage = getSelectedImage();
|
235
|
+
id = createId();
|
236
|
+
blobCache = editor.editorUpload.blobCache;
|
237
|
+
base64 = URI.parseDataUri(dataUri).data;
|
238
|
+
|
239
|
+
blobInfo = blobCache.create(id, blob, base64);
|
240
|
+
blobCache.add(blobInfo);
|
241
|
+
|
242
|
+
editor.undoManager.transact(function() {
|
243
|
+
function imageLoadedHandler() {
|
244
|
+
editor.$(selectedImage).off('load', imageLoadedHandler);
|
245
|
+
editor.nodeChanged();
|
246
|
+
|
247
|
+
if (uploadImmediately) {
|
248
|
+
editor.editorUpload.uploadImagesAuto();
|
249
|
+
} else {
|
250
|
+
cancelTimedUpload();
|
251
|
+
startTimedUpload();
|
252
|
+
}
|
253
|
+
}
|
254
|
+
|
255
|
+
editor.$(selectedImage).on('load', imageLoadedHandler);
|
256
|
+
|
257
|
+
editor.$(selectedImage).attr({
|
258
|
+
src: blobInfo.blobUri()
|
259
|
+
}).removeAttr('data-mce-src');
|
260
|
+
});
|
261
|
+
|
262
|
+
return blobInfo;
|
263
|
+
});
|
264
|
+
}
|
265
|
+
|
266
|
+
function selectedImageOperation(fn) {
|
267
|
+
return function() {
|
268
|
+
return editor._scanForImages().then(findSelectedBlobInfo).then(fn).then(updateSelectedImage);
|
269
|
+
};
|
270
|
+
}
|
271
|
+
|
272
|
+
function rotate(angle) {
|
273
|
+
return function() {
|
274
|
+
return selectedImageOperation(function(blobInfo) {
|
275
|
+
var size = getImageSize(getSelectedImage());
|
276
|
+
|
277
|
+
if (size) {
|
278
|
+
setImageSize(getSelectedImage(), {
|
279
|
+
w: size.h,
|
280
|
+
h: size.w
|
281
|
+
});
|
282
|
+
}
|
283
|
+
|
284
|
+
return ImageTransformations.rotate(blobInfo.blob(), angle);
|
285
|
+
})();
|
286
|
+
};
|
287
|
+
}
|
288
|
+
|
289
|
+
function flip(axis) {
|
290
|
+
return function() {
|
291
|
+
return selectedImageOperation(function(blobInfo) {
|
292
|
+
return ImageTransformations.flip(blobInfo.blob(), axis);
|
293
|
+
})();
|
294
|
+
};
|
295
|
+
}
|
296
|
+
|
297
|
+
function editImageDialog() {
|
298
|
+
var img = getSelectedImage(), originalSize = getNaturalImageSize(img);
|
299
|
+
|
300
|
+
if (img) {
|
301
|
+
imageToBlob(img).then(Dialog.edit).then(function(blob) {
|
302
|
+
return new Promise(function(resolve) {
|
303
|
+
BlobConversions.blobToImage(blob).then(function(newImage) {
|
304
|
+
var newSize = getNaturalImageSize(newImage);
|
305
|
+
|
306
|
+
if (originalSize.w != newSize.w || originalSize.h != newSize.h) {
|
307
|
+
if (getImageSize(img)) {
|
308
|
+
setImageSize(img, newSize);
|
309
|
+
}
|
310
|
+
}
|
311
|
+
|
312
|
+
URL.revokeObjectURL(newImage.src);
|
313
|
+
resolve(blob);
|
314
|
+
});
|
315
|
+
});
|
316
|
+
}).then(function(blob) {
|
317
|
+
updateSelectedImage(blob, true);
|
318
|
+
}, function() {
|
319
|
+
// Close dialog
|
320
|
+
});
|
321
|
+
}
|
322
|
+
}
|
323
|
+
|
324
|
+
function addButtons() {
|
325
|
+
editor.addButton('rotateleft', {
|
326
|
+
title: 'Rotate counterclockwise',
|
327
|
+
onclick: rotate(-90)
|
328
|
+
});
|
329
|
+
|
330
|
+
editor.addButton('rotateright', {
|
331
|
+
title: 'Rotate clockwise',
|
332
|
+
onclick: rotate(90)
|
333
|
+
});
|
334
|
+
|
335
|
+
editor.addButton('flipv', {
|
336
|
+
title: 'Flip vertically',
|
337
|
+
onclick: flip('v')
|
338
|
+
});
|
339
|
+
|
340
|
+
editor.addButton('fliph', {
|
341
|
+
title: 'Flip horizontally',
|
342
|
+
onclick: flip('h')
|
343
|
+
});
|
344
|
+
|
345
|
+
editor.addButton('editimage', {
|
346
|
+
title: 'Edit image',
|
347
|
+
onclick: editImageDialog
|
348
|
+
});
|
349
|
+
|
350
|
+
editor.addButton('imageoptions', {
|
351
|
+
title: 'Image options',
|
352
|
+
icon: 'options',
|
353
|
+
cmd: 'mceImage'
|
354
|
+
});
|
355
|
+
|
356
|
+
/*
|
357
|
+
editor.addButton('crop', {
|
358
|
+
title: 'Crop',
|
359
|
+
onclick: startCrop
|
360
|
+
});
|
361
|
+
*/
|
362
|
+
}
|
363
|
+
|
364
|
+
function addEvents() {
|
365
|
+
editor.on('NodeChange', function(e) {
|
366
|
+
//If the last node we selected was an image
|
367
|
+
//And had a source that doesn't match the current blob url
|
368
|
+
//We need to attempt to upload it
|
369
|
+
if (lastSelectedImage && lastSelectedImage.src != e.element.src) {
|
370
|
+
cancelTimedUpload();
|
371
|
+
editor.editorUpload.uploadImagesAuto();
|
372
|
+
lastSelectedImage = undefined;
|
373
|
+
}
|
374
|
+
|
375
|
+
//Set up the lastSelectedImage
|
376
|
+
if (isEditableImage(e.element)) {
|
377
|
+
lastSelectedImage = e.element;
|
378
|
+
}
|
379
|
+
});
|
380
|
+
}
|
381
|
+
|
382
|
+
function isEditableImage(img) {
|
383
|
+
var selectorMatched = editor.dom.is(img, 'img:not([data-mce-object],[data-mce-placeholder])');
|
384
|
+
|
385
|
+
return selectorMatched && (isLocalImage(img) || isCorsImage(img) || editor.settings.imagetools_proxy);
|
386
|
+
}
|
387
|
+
|
388
|
+
function addToolbars() {
|
389
|
+
var toolbarItems = editor.settings.imagetools_toolbar;
|
390
|
+
|
391
|
+
if (!toolbarItems) {
|
392
|
+
toolbarItems = 'rotateleft rotateright | flipv fliph | crop editimage imageoptions';
|
393
|
+
}
|
394
|
+
|
395
|
+
editor.addContextToolbar(
|
396
|
+
isEditableImage,
|
397
|
+
toolbarItems
|
398
|
+
);
|
399
|
+
}
|
400
|
+
|
401
|
+
addButtons();
|
402
|
+
addToolbars();
|
403
|
+
addEvents();
|
404
|
+
|
405
|
+
editor.addCommand('mceEditImage', editImageDialog);
|
406
|
+
};
|
407
|
+
|
408
|
+
PluginManager.add('imagetools', plugin);
|
409
|
+
|
410
|
+
return function() {};
|
411
|
+
});
|