├── .editorconfig ├── .gitignore ├── Gruntfile.js ├── ISSUE_TEMPLATE.md ├── LICENSE ├── README.md ├── _examples ├── addCustomizeButton.js ├── addCustomizeCombox.js ├── addCustomizeDialog.js ├── charts.html ├── completeDemo.html ├── customPluginDemo.html ├── customToolbarDemo.html ├── customizeDialogPage.html ├── customizeToolbarUIDemo.html ├── editor_api.js ├── filterRuleDemo.html ├── highlightDemo.html ├── index.html ├── jqueryCompleteDemo.html ├── jqueryValidation.html ├── multiDemo.html ├── multiEditorWithOneInstance.html ├── renderInTable.html ├── resetDemo.html ├── sectiondemo.html ├── server │ ├── getContent.ashx │ ├── getContent.asp │ ├── getContent.jsp │ └── getContent.php ├── setWidthHeightDemo.html ├── simpleDemo.html ├── sortableDemo.html ├── submitFormDemo.html ├── textareaDemo.html └── uparsedemo.html ├── _parse ├── background.js ├── charts.js ├── insertcode.js ├── list.js ├── parse.js ├── table.js └── video.js ├── _src ├── adapter │ ├── autosave.js │ ├── editor.js │ ├── editorui.js │ └── message.js ├── api.js ├── core │ ├── Editor.defaultoptions.js │ ├── Editor.js │ ├── EventBase.js │ ├── Range.js │ ├── Selection.js │ ├── ajax.js │ ├── browser.js │ ├── domUtils.js │ ├── dtd.js │ ├── filternode.js │ ├── filterword.js │ ├── htmlparser.js │ ├── keymap.js │ ├── loadconfig.js │ ├── localstorage.js │ ├── node.js │ ├── plugin.js │ └── utils.js ├── editor.js ├── plugins │ ├── anchor.js │ ├── autofloat.js │ ├── autoheight.js │ ├── autolink.js │ ├── autosave.js │ ├── autosubmit.js │ ├── autotypeset.js │ ├── autoupload.js │ ├── background.js │ ├── basestyle.js │ ├── blockquote.js │ ├── catchremoteimage.js │ ├── charts.js │ ├── cleardoc.js │ ├── contextmenu.js │ ├── convertcase.js │ ├── copy.js │ ├── customstyle.js │ ├── defaultfilter.js │ ├── directionality.js │ ├── dragdrop.js │ ├── elementpath.js │ ├── enterkey.js │ ├── fiximgclick.js │ ├── font.js │ ├── formatmatch.js │ ├── horizontal.js │ ├── iframe.js │ ├── image.js │ ├── indent.js │ ├── insertcode.js │ ├── insertfile.js │ ├── inserthtml.js │ ├── insertparagraph.js │ ├── justify.js │ ├── keystrokes.js │ ├── lineheight.js │ ├── link.js │ ├── list.js │ ├── music.js │ ├── pagebreak.js │ ├── paragraph.js │ ├── paste.js │ ├── preview.js │ ├── print.js │ ├── puretxtpaste.js │ ├── removeformat.js │ ├── rowspacing.js │ ├── scrawl.js │ ├── searchreplace.js │ ├── section.js │ ├── selectall.js │ ├── serverparam.js │ ├── shortcutmenu.js │ ├── simpleupload.js │ ├── snapscreen.js │ ├── source.js │ ├── table.action.js │ ├── table.cmds.js │ ├── table.core.js │ ├── table.sort.js │ ├── template.js │ ├── time.js │ ├── undo.js │ ├── video.js │ ├── webapp.js │ ├── wordcount.js │ └── wordimage.js └── ui │ ├── autotypesetbutton.js │ ├── autotypesetpicker.js │ ├── breakline.js │ ├── button.js │ ├── cellalignpicker.js │ ├── colorbutton.js │ ├── colorpicker.js │ ├── combox.js │ ├── dialog.js │ ├── mask.js │ ├── menu.js │ ├── menubutton.js │ ├── message.js │ ├── multiMenu.js │ ├── pastepicker.js │ ├── popup.js │ ├── separator.js │ ├── shortcutmenu.js │ ├── splitbutton.js │ ├── stateful.js │ ├── tablebutton.js │ ├── tablepicker.js │ ├── toolbar.js │ ├── ui.js │ ├── uibase.js │ └── uiutils.js ├── _test ├── build_run.xml ├── build_run_core.xml ├── build_run_plugin.xml ├── build_run_ui.xml ├── core │ ├── Editor.js │ ├── EventBase.js │ ├── Range.js │ ├── Selection.js │ ├── ajax.js │ ├── ajax.php │ ├── browser.js │ ├── domUtils.js │ ├── filternode.js │ ├── filterword.js │ ├── htmlparser.js │ ├── localstorage.js │ ├── node.js │ ├── plugin.js │ ├── tools.js │ └── utils.js ├── editor_config.js ├── editor_config_src.js ├── import.js ├── index.php ├── plugins │ ├── anchor.js │ ├── auto.js │ ├── autofloat.js │ ├── autoheight.js │ ├── autolink.js │ ├── autosave.js │ ├── autosubmit.js │ ├── autotypeset.js │ ├── autoupload.js │ ├── background.js │ ├── basestyle.js │ ├── blockquote.js │ ├── catchremoteimage.js │ ├── charts.js │ ├── cleardoc.js │ ├── contextmenu.js │ ├── convertcase.js │ ├── copy.js │ ├── customstyle.js │ ├── defaultfilter.js │ ├── directionality.js │ ├── dragdrop.js │ ├── elementpath.js │ ├── enterkey.js │ ├── fiximgclick.js │ ├── font.js │ ├── formatmatch.js │ ├── horizontal.js │ ├── iframe.js │ ├── image.js │ ├── indent.js │ ├── insertcode.js │ ├── inserthtml.js │ ├── insertparagraph.js │ ├── justify.js │ ├── keystrokes.js │ ├── lineheight.js │ ├── link.js │ ├── list.js │ ├── music.js │ ├── pagebreak.js │ ├── paragraph.js │ ├── paste.js │ ├── preview.js │ ├── print.js │ ├── removeformat.js │ ├── rowspacing.js │ ├── scrawl.js │ ├── searchreplace.js │ ├── section.js │ ├── selectall.js │ ├── serverparam.js │ ├── shortcutkeys.js │ ├── shortcutmenu.js │ ├── snapscreen.js │ ├── source.js │ ├── table.action.js │ ├── table.cmds.js │ ├── table.core.js │ ├── table.sort.js │ ├── template.js │ ├── time.js │ ├── tools.js │ ├── ueditor.config.js │ ├── undo.js │ ├── video.js │ ├── webapp.js │ ├── wordcount.js │ └── wordimage.js ├── qunit │ ├── jquery-1.5.1.js │ ├── qunit.css │ ├── qunit.js │ └── tools.js ├── testDesign │ ├── Manual regression cases.xmind │ └── readme.txt ├── tools │ ├── br │ │ ├── analysis.php │ │ ├── batchrun.sh │ │ ├── case.class.php │ │ ├── config.php │ │ ├── coverage │ │ │ ├── jscov.php │ │ │ ├── jscoverage-highlight.css │ │ │ ├── jscoverage-ie.css │ │ │ ├── jscoverage-throbber.gif │ │ │ ├── jscoverage.css │ │ │ ├── jscoverage.html │ │ │ ├── jscoverage.js │ │ │ └── readCoverage.js │ │ ├── css │ │ │ ├── bg_button_a.gif │ │ │ ├── bg_button_span.gif │ │ │ ├── qunit.css │ │ │ ├── tangramtest.css │ │ │ └── testsuite.css │ │ ├── filehelper.php │ │ ├── geneHTML.php │ │ ├── geneHistory.php │ │ ├── geneXML.php │ │ ├── import.php │ │ ├── js │ │ │ ├── UserAction manual.rar │ │ │ ├── UserAction.js │ │ │ ├── ext_qunit.js │ │ │ ├── jquery-1.5.1.js │ │ │ ├── run.js │ │ │ ├── tangram.js │ │ │ ├── testrunner.js │ │ │ └── tools.js │ │ ├── lib │ │ │ ├── Staf.php │ │ │ └── StafResult.php │ │ ├── list.php │ │ ├── log.php │ │ ├── mail.php │ │ ├── read.php │ │ ├── record.php │ │ ├── report.php │ │ ├── run.php │ │ ├── runC.php │ │ ├── runall.php │ │ └── txt │ │ │ ├── test1_1.txt │ │ │ ├── test1_2.txt │ │ │ ├── test1_3.txt │ │ │ ├── test2_1.txt │ │ │ ├── test2_2.txt │ │ │ ├── test2_3.txt │ │ │ └── test3_1.txt │ ├── coverage │ │ ├── cov.bat │ │ └── jscoverage.exe │ ├── data │ │ ├── frame.html │ │ ├── frame.php │ │ ├── test.JPG │ │ ├── test.html │ │ └── testReady.html │ └── lib │ │ ├── ant_tangram_ext.jar │ │ ├── js.jar │ │ ├── jshunter_1.2.0.1 │ │ └── jshunter_dev │ │ │ └── jshunter │ │ │ ├── conf │ │ │ ├── check.cfg │ │ │ ├── custcheck.conf │ │ │ ├── ignore.list │ │ │ └── omitfiles.conf │ │ │ ├── core │ │ │ ├── customcheck │ │ │ │ └── cust.sh │ │ │ ├── jshint │ │ │ │ ├── js.jar │ │ │ │ └── jshint-rhino.js │ │ │ └── tpl │ │ │ │ ├── htmlpart.html │ │ │ │ └── toggle_tpl.html │ │ │ ├── hint.py │ │ │ ├── jshint.js │ │ │ └── version │ │ ├── jslint4java-2.0.2.jar │ │ ├── jslint4java-ant-1.4.2.jar │ │ └── npPlugintest.dll ├── ui │ ├── autotypesetbutton.js │ ├── button.js │ ├── colorbutton.js │ ├── combox.js │ ├── css │ │ └── DEFAULT.css │ ├── editor.js │ ├── editorui.js │ ├── mask.js │ ├── menu.js │ ├── menubutton.js │ ├── popup.js │ ├── separator.js │ ├── splitbutton.js │ ├── stateful.js │ ├── tablebutton.js │ ├── toolbar.js │ ├── tools.js │ ├── uibase.js │ └── uiutils.js └── 关键字.txt ├── changelog.md ├── dialogs ├── anchor │ └── anchor.html ├── attachment │ ├── attachment.css │ ├── attachment.html │ ├── attachment.js │ ├── fileTypeImages │ │ ├── icon_chm.gif │ │ ├── icon_default.png │ │ ├── icon_doc.gif │ │ ├── icon_exe.gif │ │ ├── icon_jpg.gif │ │ ├── icon_mp3.gif │ │ ├── icon_mv.gif │ │ ├── icon_pdf.gif │ │ ├── icon_ppt.gif │ │ ├── icon_psd.gif │ │ ├── icon_rar.gif │ │ ├── icon_txt.gif │ │ └── icon_xls.gif │ └── images │ │ ├── alignicon.gif │ │ ├── alignicon.png │ │ ├── bg.png │ │ ├── file-icons.gif │ │ ├── file-icons.png │ │ ├── icons.gif │ │ ├── icons.png │ │ ├── image.png │ │ ├── progress.png │ │ ├── success.gif │ │ └── success.png ├── background │ ├── background.css │ ├── background.html │ ├── background.js │ └── images │ │ ├── bg.png │ │ └── success.png ├── charts │ ├── chart.config.js │ ├── charts.css │ ├── charts.html │ ├── charts.js │ └── images │ │ ├── charts0.png │ │ ├── charts1.png │ │ ├── charts2.png │ │ ├── charts3.png │ │ ├── charts4.png │ │ └── charts5.png ├── emotion │ ├── emotion.css │ ├── emotion.html │ ├── emotion.js │ └── images │ │ ├── 0.gif │ │ ├── bface.gif │ │ ├── cface.gif │ │ ├── fface.gif │ │ ├── jxface2.gif │ │ ├── neweditor-tab-bg.png │ │ ├── tface.gif │ │ ├── wface.gif │ │ └── yface.gif ├── gmap │ └── gmap.html ├── help │ ├── help.css │ ├── help.html │ └── help.js ├── image │ ├── image.css │ ├── image.html │ ├── image.js │ └── images │ │ ├── alignicon.jpg │ │ ├── bg.png │ │ ├── icons.gif │ │ ├── icons.png │ │ ├── image.png │ │ ├── progress.png │ │ ├── success.gif │ │ └── success.png ├── insertframe │ └── insertframe.html ├── internal.js ├── link │ └── link.html ├── map │ ├── map.html │ └── show.html ├── music │ ├── music.css │ ├── music.html │ └── music.js ├── preview │ └── preview.html ├── scrawl │ ├── images │ │ ├── addimg.png │ │ ├── brush.png │ │ ├── delimg.png │ │ ├── delimgH.png │ │ ├── empty.png │ │ ├── emptyH.png │ │ ├── eraser.png │ │ ├── redo.png │ │ ├── redoH.png │ │ ├── scale.png │ │ ├── scaleH.png │ │ ├── size.png │ │ ├── undo.png │ │ └── undoH.png │ ├── scrawl.css │ ├── scrawl.html │ └── scrawl.js ├── searchreplace │ ├── searchreplace.html │ └── searchreplace.js ├── snapscreen │ └── snapscreen.html ├── spechars │ ├── spechars.html │ └── spechars.js ├── table │ ├── dragicon.png │ ├── edittable.css │ ├── edittable.html │ ├── edittable.js │ ├── edittd.html │ └── edittip.html ├── template │ ├── config.js │ ├── images │ │ ├── bg.gif │ │ ├── pre0.png │ │ ├── pre1.png │ │ ├── pre2.png │ │ ├── pre3.png │ │ └── pre4.png │ ├── template.css │ ├── template.html │ └── template.js ├── video │ ├── images │ │ ├── bg.png │ │ ├── center_focus.jpg │ │ ├── file-icons.gif │ │ ├── file-icons.png │ │ ├── icons.gif │ │ ├── icons.png │ │ ├── image.png │ │ ├── left_focus.jpg │ │ ├── none_focus.jpg │ │ ├── progress.png │ │ ├── right_focus.jpg │ │ ├── success.gif │ │ └── success.png │ ├── video.css │ ├── video.html │ └── video.js ├── webapp │ └── webapp.html └── wordimage │ ├── fClipboard_ueditor.swf │ ├── imageUploader.swf │ ├── tangram.js │ ├── wordimage.html │ └── wordimage.js ├── lang ├── en │ ├── en.js │ └── images │ │ ├── addimage.png │ │ ├── alldeletebtnhoverskin.png │ │ ├── alldeletebtnupskin.png │ │ ├── background.png │ │ ├── button.png │ │ ├── copy.png │ │ ├── deletedisable.png │ │ ├── deleteenable.png │ │ ├── listbackground.png │ │ ├── localimage.png │ │ ├── music.png │ │ ├── rotateleftdisable.png │ │ ├── rotateleftenable.png │ │ ├── rotaterightdisable.png │ │ ├── rotaterightenable.png │ │ └── upload.png └── zh-cn │ ├── images │ ├── copy.png │ ├── localimage.png │ ├── music.png │ └── upload.png │ └── zh-cn.js ├── package.json ├── themes ├── default │ ├── _css │ │ ├── autotypesetpicker.css │ │ ├── button.css │ │ ├── buttonicon.css │ │ ├── cellalignpicker.css │ │ ├── colorbutton.css │ │ ├── colorpicker.css │ │ ├── combox.css │ │ ├── contextmenu.css │ │ ├── dialog.css │ │ ├── editor.css │ │ ├── menu.css │ │ ├── menubutton.css │ │ ├── message.css │ │ ├── multiMenu.css │ │ ├── paragraphpicker.css │ │ ├── pastepicker.css │ │ ├── popup.css │ │ ├── separtor.css │ │ ├── shortcutmenu.css │ │ ├── splitbutton.css │ │ ├── tablepicker.css │ │ ├── toolbar.css │ │ ├── ueditor.css │ │ └── uibase.css │ ├── dialogbase.css │ └── images │ │ ├── anchor.gif │ │ ├── arrow.png │ │ ├── arrow_down.png │ │ ├── arrow_up.png │ │ ├── button-bg.gif │ │ ├── cancelbutton.gif │ │ ├── charts.png │ │ ├── cursor_h.gif │ │ ├── cursor_h.png │ │ ├── cursor_v.gif │ │ ├── cursor_v.png │ │ ├── dialog-title-bg.png │ │ ├── filescan.png │ │ ├── highlighted.gif │ │ ├── icons-all.gif │ │ ├── icons.gif │ │ ├── icons.png │ │ ├── img-cracked.png │ │ ├── loaderror.png │ │ ├── loading.gif │ │ ├── lock.gif │ │ ├── neweditor-tab-bg.png │ │ ├── pagebreak.gif │ │ ├── scale.png │ │ ├── sortable.png │ │ ├── spacer.gif │ │ ├── sparator_v.png │ │ ├── table-cell-align.png │ │ ├── tangram-colorpicker.png │ │ ├── toolbar_bg.png │ │ ├── unhighlighted.gif │ │ ├── upload.png │ │ ├── videologo.gif │ │ ├── word.gif │ │ └── wordpaste.png └── iframe.css ├── third-party ├── SyntaxHighlighter │ ├── shCore.js │ └── shCoreDefault.css ├── codemirror │ ├── codemirror.css │ └── codemirror.js ├── highcharts │ ├── adapters │ │ ├── mootools-adapter.js │ │ ├── mootools-adapter.src.js │ │ ├── prototype-adapter.js │ │ ├── prototype-adapter.src.js │ │ ├── standalone-framework.js │ │ └── standalone-framework.src.js │ ├── highcharts-more.js │ ├── highcharts-more.src.js │ ├── highcharts.js │ ├── highcharts.src.js │ ├── modules │ │ ├── annotations.js │ │ ├── annotations.src.js │ │ ├── canvas-tools.js │ │ ├── canvas-tools.src.js │ │ ├── data.js │ │ ├── data.src.js │ │ ├── drilldown.js │ │ ├── drilldown.src.js │ │ ├── exporting.js │ │ ├── exporting.src.js │ │ ├── funnel.js │ │ ├── funnel.src.js │ │ ├── heatmap.js │ │ ├── heatmap.src.js │ │ ├── map.js │ │ ├── map.src.js │ │ ├── no-data-to-display.js │ │ └── no-data-to-display.src.js │ └── themes │ │ ├── dark-blue.js │ │ ├── dark-green.js │ │ ├── gray.js │ │ ├── grid.js │ │ └── skies.js ├── jquery-1.10.2.js ├── jquery-1.10.2.min.js ├── jquery-1.10.2.min.map ├── snapscreen │ └── UEditorSnapscreen.exe ├── video-js │ ├── font │ │ ├── vjs.eot │ │ ├── vjs.svg │ │ ├── vjs.ttf │ │ └── vjs.woff │ ├── video-js.css │ ├── video-js.min.css │ ├── video-js.swf │ ├── video.dev.js │ └── video.js ├── webuploader │ ├── Uploader.swf │ ├── webuploader.css │ ├── webuploader.custom.js │ ├── webuploader.custom.min.js │ ├── webuploader.flashonly.js │ ├── webuploader.flashonly.min.js │ ├── webuploader.html5only.js │ ├── webuploader.html5only.min.js │ ├── webuploader.js │ ├── webuploader.min.js │ ├── webuploader.withoutimage.js │ └── webuploader.withoutimage.min.js └── zeroclipboard │ ├── ZeroClipboard.js │ ├── ZeroClipboard.min.js │ └── ZeroClipboard.swf ├── ueditor.config.js └── ueditor.parse.js /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | # Unix-style newlines with a newline ending every file 4 | [*] 5 | end_of_line = lf 6 | insert_final_newline = true 7 | charset = utf-8 8 | 9 | [*.{html,js,css,scss,xml}] 10 | indent_style = space 11 | indent_size = 4 12 | trim_trailing_whitespace = true 13 | 14 | [*.yml] 15 | indent_style = space 16 | indent_size = 2 -------------------------------------------------------------------------------- /ISSUE_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | **声明:如果不看该说明,只在标题中描述问题,一律忽略** 2 | 3 | **首先**,感谢各位使用 UEditor,并来到这儿提 `ISSUE`。 4 | 5 | **其次**,在回答大量用户提出的 `ISSUE` 的过程中,我们发现需要建立一个提 `ISSUE` 的规则, 6 | 将我们的主要精力投入到修复 `UEditor` Bugs 和改进 `UEditor` 中去,让越来越多的人能够使用的舒心。 7 | 8 | ## 规则 9 | 10 | * 提 `ISSUE` 之前,**请先看看文档**。传送门:[文档](http://fex.baidu.com/ueditor/)。很多问题,在文档中都能有答案。特别是配置之类的。 11 | * 提 `ISSUE` 之前,**请先问问搜索引擎(百度、Google)**,因为你遇到的问题,可能其他人也遇到了,并且已经解决了。 12 | 只需要动动手指,在输入框里输入,就会有答案,这样方便,远比等我们回复快捷。 13 | * 提 `ISSUE` 之前,如果你已经走过上面两步了,来到 `ISSUE` 这个页面了,此刻,请别急,**建议你再搜索一下`ISSUE`**。 14 | 因为,或许你将提的问题,也有人遇到了,而且我们已经反馈了。这时,你只需要找到相应的 `ISSUE`,在那个 `ISSUE` 里留下你的关注就好了。很简单吧! 15 | 16 | 以上都不满足你,看来这一定是个新的问题。首先,我们要感谢你,帮我们发现了一个新的问题,但是,为了使问题能尽快得到解决。我们建议你按照如下的规则来提: 17 | 18 | * 构想清楚问题的表达; 19 | * 写一个简明扼要的标题 20 | * 写一个能描述清楚问题的内容,如果有复现步骤及截图当是极好的; 21 | 22 | **最后,是我们的一点希望:希望提 `ISSUE` 的同学,能自行排查、定位问题,甚至自行修复,然后给我们提 `Pull Request`。即使做不到提 `Pull Request`,但是你的排查的过程也是在增加你的 `debug` 的能力。** 23 | 24 | ### 再次感谢各位选择 `UEditor`! 25 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2013 ueditor 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -------------------------------------------------------------------------------- /_examples/addCustomizeDialog.js: -------------------------------------------------------------------------------- 1 | UE.registerUI('dialog',function(editor,uiName){ 2 | 3 | //创建dialog 4 | var dialog = new UE.ui.Dialog({ 5 | //指定弹出层中页面的路径,这里只能支持页面,因为跟addCustomizeDialog.js相同目录,所以无需加路径 6 | iframeUrl:'customizeDialogPage.html', 7 | //需要指定当前的编辑器实例 8 | editor:editor, 9 | //指定dialog的名字 10 | name:uiName, 11 | //dialog的标题 12 | title:"这是个测试浮层", 13 | 14 | //指定dialog的外围样式 15 | cssRules:"width:600px;height:300px;", 16 | 17 | //如果给出了buttons就代表dialog有确定和取消 18 | buttons:[ 19 | { 20 | className:'edui-okbutton', 21 | label:'确定', 22 | onclick:function () { 23 | dialog.close(true); 24 | } 25 | }, 26 | { 27 | className:'edui-cancelbutton', 28 | label:'取消', 29 | onclick:function () { 30 | dialog.close(false); 31 | } 32 | } 33 | ]}); 34 | 35 | //参考addCustomizeButton.js 36 | var btn = new UE.ui.Button({ 37 | name:'dialogbutton' + uiName, 38 | title:'dialogbutton' + uiName, 39 | //需要添加的额外样式,指定icon图标,这里默认使用一个重复的icon 40 | cssRules :'background-position: -500px 0;', 41 | onclick:function () { 42 | //渲染dialog 43 | dialog.render(); 44 | dialog.open(); 45 | } 46 | }); 47 | 48 | return btn; 49 | }/*index 指定添加到工具栏上的那个位置,默认时追加到最后,editorId 指定这个UI是那个编辑器实例上的,默认是页面上所有的编辑器都会添加这个按钮*/); -------------------------------------------------------------------------------- /_examples/customPluginDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |

UEditor自定义插件

12 | 13 | 14 | 18 | 50 | 51 | 52 | 53 | 54 | 55 | -------------------------------------------------------------------------------- /_examples/customizeDialogPage.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 |

测试页面

11 |
12 | 13 | 14 | 15 | 24 | 25 | -------------------------------------------------------------------------------- /_examples/customizeToolbarUIDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 完整demo 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 26 | 27 | 28 |
29 |

二次开发demo

30 | 31 |
32 | 33 | 43 | -------------------------------------------------------------------------------- /_examples/highlightDemo.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |

代码高亮演示

16 |

获得编辑器实例

17 |
18 |
19 |         UE.getEditor('myEditor');
20 |     
21 |
22 | 23 | 24 | 30 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /_examples/jqueryCompleteDemo.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 使用jquery的完整demo 6 | 7 | 8 | 9 | 10 | 34 | 35 | 36 |
37 | 40 | 41 |
42 | 43 | -------------------------------------------------------------------------------- /_examples/multiDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |

UEditor多实例

11 | 12 | 13 | 15 | 18 | 20 | 21 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /_examples/multiEditorWithOneInstance.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 13 | 14 | 15 |

UEditor多编辑区域一个编辑器实例

16 | 17 | 18 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 33 | 34 | 35 |
19 | 编辑区域一 20 |
25 | 编辑区域二 26 | 内容2
31 | 编辑区域三 32 | 内容3
36 | 37 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /_examples/renderInTable.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 表格内实例化编辑器实例 8 | 9 | 10 | 11 |
12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 |
表格标题
标题内容
中国
21 |
22 | 25 | 26 | -------------------------------------------------------------------------------- /_examples/resetDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 重置编辑器 7 | 8 | 9 | 16 | 17 | 18 |

重置编辑器和销毁编辑器示例

19 |
20 |

21 |

22 | 51 | 52 | -------------------------------------------------------------------------------- /_examples/server/getContent.ashx: -------------------------------------------------------------------------------- 1 | <%@ WebHandler Language="C#" Class="getContent" %> 2 | /** 3 | * Created by visual studio 2010 4 | * User: xuheng 5 | * Date: 12-3-6 6 | * Time: 下午21:23 7 | * To get the value of editor and output the value . 8 | */ 9 | using System; 10 | using System.Web; 11 | 12 | public class getContent : IHttpHandler { 13 | 14 | public void ProcessRequest (HttpContext context) { 15 | context.Response.ContentType = "text/html"; 16 | 17 | //获取数据 18 | string content = context.Server.HtmlEncode(context.Request.Form["myEditor"]); 19 | 20 | 21 | //存入数据库或者其他操作 22 | //------------- 23 | 24 | //显示 25 | context.Response.Write(""); 26 | context.Response.Write( 27 | 28 | ""); 32 | 33 | context.Response.Write("Content of First Editor: "); 34 | context.Response.Write("
" + context.Server.HtmlDecode(content) + "
"); 35 | 36 | } 37 | 38 | public bool IsReusable { 39 | get { 40 | return false; 41 | } 42 | } 43 | 44 | } -------------------------------------------------------------------------------- /_examples/server/getContent.asp: -------------------------------------------------------------------------------- 1 | <% @LANGUAGE="VBSCRIPT" CODEPAGE="65001" %> 2 | 3 | 4 | 10 | <% 11 | Dim content 12 | content = Request.Form("myEditor") 13 | Response.Write("第1个编辑器的值") 14 | Response.Write("
" + content + "
") 15 | %> -------------------------------------------------------------------------------- /_examples/server/getContent.jsp: -------------------------------------------------------------------------------- 1 | <%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%> 2 | 3 | 4 | 9 | <% 10 | request.setCharacterEncoding("utf-8"); 11 | response.setCharacterEncoding("utf-8"); 12 | String content = request.getParameter("myEditor"); 13 | 14 | 15 | 16 | response.getWriter().print("第1个编辑器的值"); 17 | response.getWriter().print("
"+content+"
"); 18 | 19 | %> -------------------------------------------------------------------------------- /_examples/server/getContent.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 9 | ".htmlspecialchars_decode($content).""; 20 | -------------------------------------------------------------------------------- /_examples/setWidthHeightDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |

UEditor设置宽高demo

15 |

这里的宽高都只是编辑区域的宽高,不包括工具栏的高度和状态栏的高度

16 |

容器给定编辑器的宽高

17 | 18 | 19 | 20 |
21 |

初始化时给定编辑器的宽高

22 | 23 | 24 |

没有工具栏的编辑器

25 |
26 | 27 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /_examples/simpleDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |

UEditor简单功能

12 | 13 | 14 | 17 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /_examples/submitFormDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 14 | 15 | 16 |

UEditor提交示例

17 |
18 | 21 | 22 |
23 |

24 | 从1.2.6开始,会自动同步数据无需再手动调用sync方法 25 | 26 | 27 |

28 | 29 | 50 | 51 | 52 | 53 | 54 | 55 | -------------------------------------------------------------------------------- /_examples/textareaDemo.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 16 | 17 | 18 |

文本域渲染编辑器

19 | 20 | 21 | 22 |
23 | 24 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /_parse/background.js: -------------------------------------------------------------------------------- 1 | UE.parse.register("background", function(utils) { 2 | var me = this, 3 | root = me.root, 4 | p = root.getElementsByTagName("p"), 5 | styles; 6 | 7 | for (var i = 0, ci; (ci = p[i++]); ) { 8 | styles = ci.getAttribute("data-background"); 9 | if (styles) { 10 | ci.parentNode.removeChild(ci); 11 | } 12 | } 13 | 14 | //追加默认的表格样式 15 | styles && 16 | utils.cssRule( 17 | "ueditor_background", 18 | me.selector + "{" + styles + "}", 19 | document 20 | ); 21 | }); 22 | -------------------------------------------------------------------------------- /_parse/insertcode.js: -------------------------------------------------------------------------------- 1 | UE.parse.register("insertcode", function(utils) { 2 | var pres = this.root.getElementsByTagName("pre"); 3 | if (pres.length) { 4 | if (typeof XRegExp == "undefined") { 5 | var jsurl, cssurl; 6 | if (this.rootPath !== undefined) { 7 | jsurl = 8 | utils.removeLastbs(this.rootPath) + 9 | "/third-party/SyntaxHighlighter/shCore.js"; 10 | cssurl = 11 | utils.removeLastbs(this.rootPath) + 12 | "/third-party/SyntaxHighlighter/shCoreDefault.css"; 13 | } else { 14 | jsurl = this.highlightJsUrl; 15 | cssurl = this.highlightCssUrl; 16 | } 17 | utils.loadFile(document, { 18 | id: "syntaxhighlighter_css", 19 | tag: "link", 20 | rel: "stylesheet", 21 | type: "text/css", 22 | href: cssurl 23 | }); 24 | utils.loadFile( 25 | document, 26 | { 27 | id: "syntaxhighlighter_js", 28 | src: jsurl, 29 | tag: "script", 30 | type: "text/javascript", 31 | defer: "defer" 32 | }, 33 | function() { 34 | utils.each(pres, function(pi) { 35 | if (pi && /brush/i.test(pi.className)) { 36 | SyntaxHighlighter.highlight(pi); 37 | } 38 | }); 39 | } 40 | ); 41 | } else { 42 | utils.each(pres, function(pi) { 43 | if (pi && /brush/i.test(pi.className)) { 44 | SyntaxHighlighter.highlight(pi); 45 | } 46 | }); 47 | } 48 | } 49 | }); 50 | -------------------------------------------------------------------------------- /_parse/video.js: -------------------------------------------------------------------------------- 1 | UE.parse.register("vedio", function(utils) { 2 | var video = this.root.getElementsByTagName("video"), 3 | audio = this.root.getElementsByTagName("audio"); 4 | 5 | document.createElement("video"); 6 | document.createElement("audio"); 7 | if (video.length || audio.length) { 8 | var sourcePath = utils.removeLastbs(this.rootPath), 9 | jsurl = sourcePath + "/third-party/video-js/video.js", 10 | cssurl = sourcePath + "/third-party/video-js/video-js.min.css", 11 | swfUrl = sourcePath + "/third-party/video-js/video-js.swf"; 12 | 13 | if (window.videojs) { 14 | videojs.autoSetup(); 15 | } else { 16 | utils.loadFile(document, { 17 | id: "video_css", 18 | tag: "link", 19 | rel: "stylesheet", 20 | type: "text/css", 21 | href: cssurl 22 | }); 23 | utils.loadFile( 24 | document, 25 | { 26 | id: "video_js", 27 | src: jsurl, 28 | tag: "script", 29 | type: "text/javascript" 30 | }, 31 | function() { 32 | videojs.options.flash.swf = swfUrl; 33 | videojs.autoSetup(); 34 | } 35 | ); 36 | } 37 | } 38 | }); 39 | -------------------------------------------------------------------------------- /_src/adapter/autosave.js: -------------------------------------------------------------------------------- 1 | UE.registerUI("autosave", function(editor) { 2 | var timer = null, 3 | uid = null; 4 | editor.on("afterautosave", function() { 5 | clearTimeout(timer); 6 | 7 | timer = setTimeout(function() { 8 | if (uid) { 9 | editor.trigger("hidemessage", uid); 10 | } 11 | uid = editor.trigger("showmessage", { 12 | content: editor.getLang("autosave.success"), 13 | timeout: 2000 14 | }); 15 | }, 2000); 16 | }); 17 | }); 18 | -------------------------------------------------------------------------------- /_src/adapter/message.js: -------------------------------------------------------------------------------- 1 | UE.registerUI("message", function(editor) { 2 | var editorui = baidu.editor.ui; 3 | var Message = editorui.Message; 4 | var holder; 5 | var _messageItems = []; 6 | var me = editor; 7 | 8 | me.setOpt("enableMessageShow", true); 9 | if (me.getOpt("enableMessageShow") === false) { 10 | return; 11 | } 12 | 13 | me.addListener("ready", function() { 14 | holder = document.getElementById(me.ui.id + "_message_holder"); 15 | updateHolderPos(); 16 | setTimeout(function() { 17 | updateHolderPos(); 18 | }, 500); 19 | }); 20 | 21 | me.addListener("showmessage", function(type, opt) { 22 | opt = utils.isString(opt) 23 | ? { 24 | content: opt 25 | } 26 | : opt; 27 | var message = new Message({ 28 | timeout: opt.timeout, 29 | type: opt.type, 30 | content: opt.content, 31 | keepshow: opt.keepshow, 32 | editor: me 33 | }), 34 | mid = opt.id || "msg_" + (+new Date()).toString(36); 35 | message.render(holder); 36 | _messageItems[mid] = message; 37 | message.reset(opt); 38 | updateHolderPos(); 39 | return mid; 40 | }); 41 | 42 | me.addListener("updatemessage", function(type, id, opt) { 43 | opt = utils.isString(opt) 44 | ? { 45 | content: opt 46 | } 47 | : opt; 48 | var message = _messageItems[id]; 49 | message.render(holder); 50 | message && message.reset(opt); 51 | }); 52 | 53 | me.addListener("hidemessage", function(type, id) { 54 | var message = _messageItems[id]; 55 | message && message.hide(); 56 | }); 57 | 58 | function updateHolderPos() { 59 | if (!holder || !me.ui) return; 60 | var toolbarbox = me.ui.getDom("toolbarbox"); 61 | if (toolbarbox) { 62 | holder.style.top = toolbarbox.offsetHeight + 3 + "px"; 63 | } 64 | holder.style.zIndex = 65 | Math.max(me.options.zIndex, me.iframe.style.zIndex) + 1; 66 | } 67 | }); 68 | -------------------------------------------------------------------------------- /_src/api.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 该文件定义了API文档所使用到的本地函数的说明 3 | * @file 4 | * @module Native 5 | */ 6 | 7 | /** 8 | * 辅助接口说明 9 | * @module Native 10 | * @unfile 11 | */ 12 | 13 | /** 14 | * 原生String对象, 字符串 15 | * @class String 16 | */ 17 | 18 | /** 19 | * 原生Function对象, 函数 20 | * @class Function 21 | */ 22 | 23 | /** 24 | * 原生Object对象, 普通对象 25 | * @remind 如果某一方法的参数类型为Object时, 表示该参数应该接受一个key-value集合 26 | * @class Object 27 | */ 28 | 29 | /** 30 | * 原生Boolean对象, 布尔值 31 | * @class Boolean 32 | */ 33 | 34 | /** 35 | * 原生Number对象, 数值 36 | * @class Number 37 | */ 38 | 39 | /** 40 | * 原生NULL对象, 空 41 | * @class NULL 42 | */ 43 | 44 | /** 45 | * 原生Array对象, 数组 46 | * @class Array 47 | */ 48 | 49 | /** 50 | * 浏览器Node, dom节点 51 | * @class Node 52 | */ 53 | 54 | /** 55 | * 浏览器Element, dom元素 56 | * @class Element 57 | */ 58 | 59 | /** 60 | * UEditor模拟dom节点对象 61 | * @class uNode 62 | */ 63 | -------------------------------------------------------------------------------- /_src/core/Editor.defaultoptions.js: -------------------------------------------------------------------------------- 1 | //维护编辑器一下默认的不在插件中的配置项 2 | UE.Editor.defaultOptions = function(editor) { 3 | var _url = editor.options.UEDITOR_HOME_URL; 4 | return { 5 | isShow: true, 6 | initialContent: "", 7 | initialStyle: "", 8 | autoClearinitialContent: false, 9 | iframeCssUrl: _url + "themes/iframe.css", 10 | textarea: "editorValue", 11 | focus: false, 12 | focusInEnd: true, 13 | autoClearEmptyNode: true, 14 | fullscreen: false, 15 | readonly: false, 16 | zIndex: 999, 17 | imagePopup: true, 18 | enterTag: "p", 19 | customDomain: false, 20 | lang: "zh-cn", 21 | langPath: _url + "lang/", 22 | theme: "default", 23 | themePath: _url + "themes/", 24 | allHtmlEnabled: false, 25 | scaleEnabled: false, 26 | tableNativeEditInFF: false, 27 | autoSyncData: true, 28 | fileNameFormat: "{time}{rand:6}" 29 | }; 30 | }; 31 | -------------------------------------------------------------------------------- /_src/core/keymap.js: -------------------------------------------------------------------------------- 1 | var keymap = (UE.keymap = { 2 | Backspace: 8, 3 | Tab: 9, 4 | Enter: 13, 5 | 6 | Shift: 16, 7 | Control: 17, 8 | Alt: 18, 9 | CapsLock: 20, 10 | 11 | Esc: 27, 12 | 13 | Spacebar: 32, 14 | 15 | PageUp: 33, 16 | PageDown: 34, 17 | End: 35, 18 | Home: 36, 19 | 20 | Left: 37, 21 | Up: 38, 22 | Right: 39, 23 | Down: 40, 24 | 25 | Insert: 45, 26 | 27 | Del: 46, 28 | 29 | NumLock: 144, 30 | 31 | Cmd: 91, 32 | 33 | "=": 187, 34 | "-": 189, 35 | 36 | b: 66, 37 | i: 73, 38 | //回退 39 | z: 90, 40 | y: 89, 41 | //粘贴 42 | v: 86, 43 | x: 88, 44 | 45 | s: 83, 46 | 47 | n: 78 48 | }); 49 | -------------------------------------------------------------------------------- /_src/editor.js: -------------------------------------------------------------------------------- 1 | UEDITOR_CONFIG = window.UEDITOR_CONFIG || {}; 2 | 3 | var baidu = window.baidu || {}; 4 | 5 | window.baidu = baidu; 6 | 7 | window.UE = baidu.editor = { 8 | plugins: {}, 9 | commands: {}, 10 | instants: {}, 11 | I18N: {}, 12 | _customizeUI: {}, 13 | version: "1.5.0" 14 | }; 15 | var dom = (UE.dom = {}); 16 | -------------------------------------------------------------------------------- /_src/plugins/autosubmit.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 快捷键提交 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 提交表单 9 | * @command autosubmit 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'autosubmit' ); 15 | * ``` 16 | */ 17 | 18 | UE.plugin.register("autosubmit", function() { 19 | return { 20 | shortcutkey: { 21 | autosubmit: "ctrl+13" //手动提交 22 | }, 23 | commands: { 24 | autosubmit: { 25 | execCommand: function() { 26 | var me = this, 27 | form = domUtils.findParentByTagName(me.iframe, "form", false); 28 | if (form) { 29 | if (me.fireEvent("beforesubmit") === false) { 30 | return; 31 | } 32 | me.sync(); 33 | form.submit(); 34 | } 35 | } 36 | } 37 | } 38 | }; 39 | }); 40 | -------------------------------------------------------------------------------- /_src/plugins/cleardoc.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 清空文档插件 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 清空文档 9 | * @command cleardoc 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * //editor 是编辑器实例 15 | * editor.execCommand('cleardoc'); 16 | * ``` 17 | */ 18 | 19 | UE.commands["cleardoc"] = { 20 | execCommand: function(cmdName) { 21 | var me = this, 22 | enterTag = me.options.enterTag, 23 | range = me.selection.getRange(); 24 | if (enterTag == "br") { 25 | me.body.innerHTML = "
"; 26 | range.setStart(me.body, 0).setCursor(); 27 | } else { 28 | me.body.innerHTML = "

" + (ie ? "" : "
") + "

"; 29 | range.setStart(me.body.firstChild, 0).setCursor(false, true); 30 | } 31 | setTimeout(function() { 32 | me.fireEvent("clearDoc"); 33 | }, 0); 34 | } 35 | }; 36 | -------------------------------------------------------------------------------- /_src/plugins/convertcase.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 大小写转换 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 把选区内文本变大写,与“tolowercase”命令互斥 9 | * @command touppercase 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'touppercase' ); 15 | * ``` 16 | */ 17 | 18 | /** 19 | * 把选区内文本变小写,与“touppercase”命令互斥 20 | * @command tolowercase 21 | * @method execCommand 22 | * @param { String } cmd 命令字符串 23 | * @example 24 | * ```javascript 25 | * editor.execCommand( 'tolowercase' ); 26 | * ``` 27 | */ 28 | UE.commands["touppercase"] = UE.commands["tolowercase"] = { 29 | execCommand: function(cmd) { 30 | var me = this; 31 | var rng = me.selection.getRange(); 32 | if (rng.collapsed) { 33 | return rng; 34 | } 35 | var bk = rng.createBookmark(), 36 | bkEnd = bk.end, 37 | filterFn = function(node) { 38 | return !domUtils.isBr(node) && !domUtils.isWhitespace(node); 39 | }, 40 | curNode = domUtils.getNextDomNode(bk.start, false, filterFn); 41 | while ( 42 | curNode && 43 | domUtils.getPosition(curNode, bkEnd) & domUtils.POSITION_PRECEDING 44 | ) { 45 | if (curNode.nodeType == 3) { 46 | curNode.nodeValue = curNode.nodeValue[ 47 | cmd == "touppercase" ? "toUpperCase" : "toLowerCase" 48 | ](); 49 | } 50 | curNode = domUtils.getNextDomNode(curNode, true, filterFn); 51 | if (curNode === bkEnd) { 52 | break; 53 | } 54 | } 55 | rng.moveToBookmark(bk).select(); 56 | } 57 | }; 58 | -------------------------------------------------------------------------------- /_src/plugins/elementpath.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 选取路径命令 3 | * @file 4 | */ 5 | UE.plugins["elementpath"] = function() { 6 | var currentLevel, 7 | tagNames, 8 | me = this; 9 | me.setOpt("elementPathEnabled", true); 10 | if (!me.options.elementPathEnabled) { 11 | return; 12 | } 13 | me.commands["elementpath"] = { 14 | execCommand: function(cmdName, level) { 15 | var start = tagNames[level], 16 | range = me.selection.getRange(); 17 | currentLevel = level * 1; 18 | range.selectNode(start).select(); 19 | }, 20 | queryCommandValue: function() { 21 | //产生一个副本,不能修改原来的startElementPath; 22 | var parents = [].concat(this.selection.getStartElementPath()).reverse(), 23 | names = []; 24 | tagNames = parents; 25 | for (var i = 0, ci; (ci = parents[i]); i++) { 26 | if (ci.nodeType == 3) { 27 | continue; 28 | } 29 | var name = ci.tagName.toLowerCase(); 30 | if (name == "img" && ci.getAttribute("anchorname")) { 31 | name = "anchor"; 32 | } 33 | names[i] = name; 34 | if (currentLevel == i) { 35 | currentLevel = -1; 36 | break; 37 | } 38 | } 39 | return names; 40 | } 41 | }; 42 | }; 43 | -------------------------------------------------------------------------------- /_src/plugins/iframe.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import plugins\inserthtml.js 3 | ///commands 插入框架 4 | ///commandsName InsertFrame 5 | ///commandsTitle 插入Iframe 6 | ///commandsDialog dialogs\insertframe 7 | 8 | UE.plugins["insertframe"] = function() { 9 | var me = this; 10 | function deleteIframe() { 11 | me._iframe && delete me._iframe; 12 | } 13 | 14 | me.addListener("selectionchange", function() { 15 | deleteIframe(); 16 | }); 17 | }; 18 | -------------------------------------------------------------------------------- /_src/plugins/indent.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 首行缩进 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 缩进 9 | * @command indent 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'indent' ); 15 | * ``` 16 | */ 17 | UE.commands["indent"] = { 18 | execCommand: function() { 19 | var me = this, 20 | value = me.queryCommandState("indent") 21 | ? "0em" 22 | : me.options.indentValue || "2em"; 23 | me.execCommand("Paragraph", "p", { style: "text-indent:" + value }); 24 | }, 25 | queryCommandState: function() { 26 | var pN = domUtils.filterNodeList( 27 | this.selection.getStartElementPath(), 28 | "p h1 h2 h3 h4 h5 h6" 29 | ); 30 | return pN && pN.style.textIndent && parseInt(pN.style.textIndent) ? 1 : 0; 31 | } 32 | }; 33 | -------------------------------------------------------------------------------- /_src/plugins/insertparagraph.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 插入段落 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 插入段落 9 | * @command insertparagraph 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * //editor是编辑器实例 15 | * editor.execCommand( 'insertparagraph' ); 16 | * ``` 17 | */ 18 | 19 | UE.commands["insertparagraph"] = { 20 | execCommand: function(cmdName, front) { 21 | var me = this, 22 | range = me.selection.getRange(), 23 | start = range.startContainer, 24 | tmpNode; 25 | while (start) { 26 | if (domUtils.isBody(start)) { 27 | break; 28 | } 29 | tmpNode = start; 30 | start = start.parentNode; 31 | } 32 | if (tmpNode) { 33 | var p = me.document.createElement("p"); 34 | if (front) { 35 | tmpNode.parentNode.insertBefore(p, tmpNode); 36 | } else { 37 | tmpNode.parentNode.insertBefore(p, tmpNode.nextSibling); 38 | } 39 | domUtils.fillNode(me.document, p); 40 | range.setStart(p, 0).setCursor(false, true); 41 | } 42 | } 43 | }; 44 | -------------------------------------------------------------------------------- /_src/plugins/lineheight.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 设置行内间距 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | UE.plugins["lineheight"] = function() { 7 | var me = this; 8 | me.setOpt({ lineheight: ["1", "1.5", "1.75", "2", "3", "4", "5"] }); 9 | 10 | /** 11 | * 行距 12 | * @command lineheight 13 | * @method execCommand 14 | * @param { String } cmdName 命令字符串 15 | * @param { String } value 传入的行高值, 该值是当前字体的倍数, 例如: 1.5, 1.75 16 | * @example 17 | * ```javascript 18 | * editor.execCommand( 'lineheight', 1.5); 19 | * ``` 20 | */ 21 | /** 22 | * 查询当前选区内容的行高大小 23 | * @command lineheight 24 | * @method queryCommandValue 25 | * @param { String } cmd 命令字符串 26 | * @return { String } 返回当前行高大小 27 | * @example 28 | * ```javascript 29 | * editor.queryCommandValue( 'lineheight' ); 30 | * ``` 31 | */ 32 | 33 | me.commands["lineheight"] = { 34 | execCommand: function(cmdName, value) { 35 | this.execCommand("paragraph", "p", { 36 | style: "line-height:" + (value == "1" ? "normal" : value + "em") 37 | }); 38 | return true; 39 | }, 40 | queryCommandValue: function() { 41 | var pN = domUtils.filterNodeList( 42 | this.selection.getStartElementPath(), 43 | function(node) { 44 | return domUtils.isBlockElm(node); 45 | } 46 | ); 47 | if (pN) { 48 | var value = domUtils.getComputedStyle(pN, "line-height"); 49 | return value == "normal" ? 1 : value.replace(/[^\d.]*/gi, ""); 50 | } 51 | } 52 | }; 53 | }; 54 | -------------------------------------------------------------------------------- /_src/plugins/preview.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 预览 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 预览 9 | * @command preview 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'preview' ); 15 | * ``` 16 | */ 17 | UE.commands["preview"] = { 18 | execCommand: function() { 19 | var w = window.open("", "_blank", ""), 20 | d = w.document; 21 | d.open(); 22 | d.write( 23 | '
" + 30 | this.getContent(null, null, true) + 31 | "
" 32 | ); 33 | d.close(); 34 | }, 35 | notNeedUndo: 1 36 | }; 37 | -------------------------------------------------------------------------------- /_src/plugins/print.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 打印 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 打印 9 | * @command print 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'print' ); 15 | * ``` 16 | */ 17 | UE.commands["print"] = { 18 | execCommand: function() { 19 | this.window.print(); 20 | }, 21 | notNeedUndo: 1 22 | }; 23 | -------------------------------------------------------------------------------- /_src/plugins/rowspacing.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 段前段后间距插件 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 设置段间距 9 | * @command rowspacing 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @param { String } value 段间距的值,以px为单位 13 | * @param { String } dir 间距位置,top或bottom,分别表示段前和段后 14 | * @example 15 | * ```javascript 16 | * editor.execCommand( 'rowspacing', '10', 'top' ); 17 | * ``` 18 | */ 19 | 20 | UE.plugins["rowspacing"] = function() { 21 | var me = this; 22 | me.setOpt({ 23 | rowspacingtop: ["5", "10", "15", "20", "25"], 24 | rowspacingbottom: ["5", "10", "15", "20", "25"] 25 | }); 26 | me.commands["rowspacing"] = { 27 | execCommand: function(cmdName, value, dir) { 28 | this.execCommand("paragraph", "p", { 29 | style: "margin-" + dir + ":" + value + "px" 30 | }); 31 | return true; 32 | }, 33 | queryCommandValue: function(cmdName, dir) { 34 | var pN = domUtils.filterNodeList( 35 | this.selection.getStartElementPath(), 36 | function(node) { 37 | return domUtils.isBlockElm(node); 38 | } 39 | ), 40 | value; 41 | //trace:1026 42 | if (pN) { 43 | value = domUtils 44 | .getComputedStyle(pN, "margin-" + dir) 45 | .replace(/[^\d]/g, ""); 46 | return !value ? 0 : value; 47 | } 48 | return 0; 49 | } 50 | }; 51 | }; 52 | -------------------------------------------------------------------------------- /_src/plugins/scrawl.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///commands 涂鸦 3 | ///commandsName Scrawl 4 | ///commandsTitle 涂鸦 5 | ///commandsDialog dialogs\scrawl 6 | UE.commands["scrawl"] = { 7 | queryCommandState: function() { 8 | return browser.ie && browser.version <= 8 ? -1 : 0; 9 | } 10 | }; 11 | -------------------------------------------------------------------------------- /_src/plugins/selectall.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 全选 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 选中所有内容 9 | * @command selectall 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'selectall' ); 15 | * ``` 16 | */ 17 | UE.plugins["selectall"] = function() { 18 | var me = this; 19 | me.commands["selectall"] = { 20 | execCommand: function() { 21 | //去掉了原生的selectAll,因为会出现报错和当内容为空时,不能出现闭合状态的光标 22 | var me = this, 23 | body = me.body, 24 | range = me.selection.getRange(); 25 | range.selectNodeContents(body); 26 | if (domUtils.isEmptyBlock(body)) { 27 | //opera不能自动合并到元素的里边,要手动处理一下 28 | if (browser.opera && body.firstChild && body.firstChild.nodeType == 1) { 29 | range.setStartAtFirst(body.firstChild); 30 | } 31 | range.collapse(true); 32 | } 33 | range.select(true); 34 | }, 35 | notNeedUndo: 1 36 | }; 37 | 38 | //快捷键 39 | me.addshortcutkey({ 40 | selectAll: "ctrl+65" 41 | }); 42 | }; 43 | -------------------------------------------------------------------------------- /_src/plugins/shortcutmenu.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///commands 弹出菜单 3 | // commandsName popupmenu 4 | ///commandsTitle 弹出菜单 5 | /** 6 | * 弹出菜单 7 | * @function 8 | * @name baidu.editor.plugins.popupmenu 9 | * @author xuheng 10 | */ 11 | 12 | UE.plugins["shortcutmenu"] = function() { 13 | var me = this, 14 | menu, 15 | items = me.options.shortcutMenu || []; 16 | 17 | if (!items.length) { 18 | return; 19 | } 20 | 21 | me.addListener("contextmenu mouseup", function(type, e) { 22 | var me = this, 23 | customEvt = { 24 | type: type, 25 | target: e.target || e.srcElement, 26 | screenX: e.screenX, 27 | screenY: e.screenY, 28 | clientX: e.clientX, 29 | clientY: e.clientY 30 | }; 31 | 32 | setTimeout(function() { 33 | var rng = me.selection.getRange(); 34 | if (rng.collapsed === false || type == "contextmenu") { 35 | if (!menu) { 36 | menu = new baidu.editor.ui.ShortCutMenu({ 37 | editor: me, 38 | items: items, 39 | theme: me.options.theme, 40 | className: "edui-shortcutmenu" 41 | }); 42 | 43 | menu.render(); 44 | me.fireEvent("afterrendershortcutmenu", menu); 45 | } 46 | 47 | menu.show(customEvt, !!UE.plugins["contextmenu"]); 48 | } 49 | }); 50 | 51 | if (type == "contextmenu") { 52 | domUtils.preventDefault(e); 53 | if (browser.ie9below) { 54 | var ieRange; 55 | try { 56 | ieRange = me.selection.getNative().createRange(); 57 | } catch (e) { 58 | return; 59 | } 60 | if (ieRange.item) { 61 | var range = new dom.Range(me.document); 62 | range.selectNode(ieRange.item(0)).select(true, true); 63 | } 64 | } 65 | } 66 | }); 67 | 68 | me.addListener("keydown", function(type) { 69 | if (type == "keydown") { 70 | menu && !menu.isHidden && menu.hide(); 71 | } 72 | }); 73 | }; 74 | -------------------------------------------------------------------------------- /_src/plugins/template.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import plugins\inserthtml.js 3 | ///import plugins\cleardoc.js 4 | ///commands 模板 5 | ///commandsName template 6 | ///commandsTitle 模板 7 | ///commandsDialog dialogs\template 8 | UE.plugins["template"] = function() { 9 | UE.commands["template"] = { 10 | execCommand: function(cmd, obj) { 11 | obj.html && this.execCommand("inserthtml", obj.html); 12 | } 13 | }; 14 | this.addListener("click", function(type, evt) { 15 | var el = evt.target || evt.srcElement, 16 | range = this.selection.getRange(); 17 | var tnode = domUtils.findParent( 18 | el, 19 | function(node) { 20 | if (node.className && domUtils.hasClass(node, "ue_t")) { 21 | return node; 22 | } 23 | }, 24 | true 25 | ); 26 | tnode && range.selectNode(tnode).shrinkBoundary().select(); 27 | }); 28 | this.addListener("keydown", function(type, evt) { 29 | var range = this.selection.getRange(); 30 | if (!range.collapsed) { 31 | if (!evt.ctrlKey && !evt.metaKey && !evt.shiftKey && !evt.altKey) { 32 | var tnode = domUtils.findParent( 33 | range.startContainer, 34 | function(node) { 35 | if (node.className && domUtils.hasClass(node, "ue_t")) { 36 | return node; 37 | } 38 | }, 39 | true 40 | ); 41 | if (tnode) { 42 | domUtils.removeClasses(tnode, ["ue_t"]); 43 | } 44 | } 45 | } 46 | }); 47 | }; 48 | -------------------------------------------------------------------------------- /_src/plugins/time.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 插入时间和日期 3 | * @file 4 | * @since 1.2.6.1 5 | */ 6 | 7 | /** 8 | * 插入时间,默认格式:12:59:59 9 | * @command time 10 | * @method execCommand 11 | * @param { String } cmd 命令字符串 12 | * @example 13 | * ```javascript 14 | * editor.execCommand( 'time'); 15 | * ``` 16 | */ 17 | 18 | /** 19 | * 插入日期,默认格式:2013-08-30 20 | * @command date 21 | * @method execCommand 22 | * @param { String } cmd 命令字符串 23 | * @example 24 | * ```javascript 25 | * editor.execCommand( 'date'); 26 | * ``` 27 | */ 28 | UE.commands["time"] = UE.commands["date"] = { 29 | execCommand: function(cmd, format) { 30 | var date = new Date(); 31 | 32 | function formatTime(date, format) { 33 | var hh = ("0" + date.getHours()).slice(-2), 34 | ii = ("0" + date.getMinutes()).slice(-2), 35 | ss = ("0" + date.getSeconds()).slice(-2); 36 | format = format || "hh:ii:ss"; 37 | return format.replace(/hh/gi, hh).replace(/ii/gi, ii).replace(/ss/gi, ss); 38 | } 39 | function formatDate(date, format) { 40 | var yyyy = ("000" + date.getFullYear()).slice(-4), 41 | yy = yyyy.slice(-2), 42 | mm = ("0" + (date.getMonth() + 1)).slice(-2), 43 | dd = ("0" + date.getDate()).slice(-2); 44 | format = format || "yyyy-mm-dd"; 45 | return format 46 | .replace(/yyyy/gi, yyyy) 47 | .replace(/yy/gi, yy) 48 | .replace(/mm/gi, mm) 49 | .replace(/dd/gi, dd); 50 | } 51 | 52 | this.execCommand( 53 | "insertHtml", 54 | cmd == "time" ? formatTime(date, format) : formatDate(date, format) 55 | ); 56 | } 57 | }; 58 | -------------------------------------------------------------------------------- /_src/plugins/wordcount.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///commands 字数统计 3 | ///commandsName WordCount,wordCount 4 | ///commandsTitle 字数统计 5 | /* 6 | * Created by JetBrains WebStorm. 7 | * User: taoqili 8 | * Date: 11-9-7 9 | * Time: 下午8:18 10 | * To change this template use File | Settings | File Templates. 11 | */ 12 | 13 | UE.plugins["wordcount"] = function() { 14 | var me = this; 15 | me.setOpt("wordCount", true); 16 | me.addListener("contentchange", function() { 17 | me.fireEvent("wordcount"); 18 | }); 19 | var timer; 20 | me.addListener("ready", function() { 21 | var me = this; 22 | domUtils.on(me.body, "keyup", function(evt) { 23 | var code = evt.keyCode || evt.which, 24 | //忽略的按键,ctr,alt,shift,方向键 25 | ignores = { 26 | "16": 1, 27 | "18": 1, 28 | "20": 1, 29 | "37": 1, 30 | "38": 1, 31 | "39": 1, 32 | "40": 1 33 | }; 34 | if (code in ignores) return; 35 | clearTimeout(timer); 36 | timer = setTimeout(function() { 37 | me.fireEvent("wordcount"); 38 | }, 200); 39 | }); 40 | }); 41 | }; 42 | -------------------------------------------------------------------------------- /_src/plugins/wordimage.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///commands 本地图片引导上传 3 | ///commandsName WordImage 4 | ///commandsTitle 本地图片引导上传 5 | ///commandsDialog dialogs\wordimage 6 | 7 | UE.plugin.register("wordimage", function() { 8 | var me = this, 9 | images = []; 10 | return { 11 | commands: { 12 | wordimage: { 13 | execCommand: function() { 14 | var images = domUtils.getElementsByTagName(me.body, "img"); 15 | var urlList = []; 16 | for (var i = 0, ci; (ci = images[i++]); ) { 17 | var url = ci.getAttribute("word_img"); 18 | url && urlList.push(url); 19 | } 20 | return urlList; 21 | }, 22 | queryCommandState: function() { 23 | images = domUtils.getElementsByTagName(me.body, "img"); 24 | for (var i = 0, ci; (ci = images[i++]); ) { 25 | if (ci.getAttribute("word_img")) { 26 | return 1; 27 | } 28 | } 29 | return -1; 30 | }, 31 | notNeedUndo: true 32 | } 33 | }, 34 | inputRule: function(root) { 35 | utils.each(root.getNodesByTagName("img"), function(img) { 36 | var attrs = img.attrs, 37 | flag = parseInt(attrs.width) < 128 || parseInt(attrs.height) < 43, 38 | opt = me.options, 39 | src = opt.UEDITOR_HOME_URL + "themes/default/images/spacer.gif"; 40 | if (attrs["src"] && /^(?:(file:\/+))/.test(attrs["src"])) { 41 | img.setAttr({ 42 | width: attrs.width, 43 | height: attrs.height, 44 | alt: attrs.alt, 45 | word_img: attrs.src, 46 | src: src, 47 | style: 48 | "background:url(" + 49 | (flag 50 | ? opt.themePath + opt.theme + "/images/word.gif" 51 | : opt.langPath + opt.lang + "/images/localimage.png") + 52 | ") no-repeat center center;border:1px solid #ddd" 53 | }); 54 | } 55 | }); 56 | } 57 | }; 58 | }); 59 | -------------------------------------------------------------------------------- /_src/ui/breakline.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var utils = baidu.editor.utils, 3 | UIBase = baidu.editor.ui.UIBase, 4 | Breakline = (baidu.editor.ui.Breakline = function(options) { 5 | this.initOptions(options); 6 | this.initSeparator(); 7 | }); 8 | Breakline.prototype = { 9 | uiName: "Breakline", 10 | initSeparator: function() { 11 | this.initUIBase(); 12 | }, 13 | getHtmlTpl: function() { 14 | return "
"; 15 | } 16 | }; 17 | utils.inherits(Breakline, UIBase); 18 | })(); 19 | -------------------------------------------------------------------------------- /_src/ui/colorbutton.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import uicore 3 | ///import ui/colorpicker.js 4 | ///import ui/popup.js 5 | ///import ui/splitbutton.js 6 | (function() { 7 | var utils = baidu.editor.utils, 8 | uiUtils = baidu.editor.ui.uiUtils, 9 | ColorPicker = baidu.editor.ui.ColorPicker, 10 | Popup = baidu.editor.ui.Popup, 11 | SplitButton = baidu.editor.ui.SplitButton, 12 | ColorButton = (baidu.editor.ui.ColorButton = function(options) { 13 | this.initOptions(options); 14 | this.initColorButton(); 15 | }); 16 | ColorButton.prototype = { 17 | initColorButton: function() { 18 | var me = this; 19 | this.popup = new Popup({ 20 | content: new ColorPicker({ 21 | noColorText: me.editor.getLang("clearColor"), 22 | editor: me.editor, 23 | onpickcolor: function(t, color) { 24 | me._onPickColor(color); 25 | }, 26 | onpicknocolor: function(t, color) { 27 | me._onPickNoColor(color); 28 | } 29 | }), 30 | editor: me.editor 31 | }); 32 | this.initSplitButton(); 33 | }, 34 | _SplitButton_postRender: SplitButton.prototype.postRender, 35 | postRender: function() { 36 | this._SplitButton_postRender(); 37 | this.getDom("button_body").appendChild( 38 | uiUtils.createElementByHtml( 39 | '
' 40 | ) 41 | ); 42 | this.getDom().className += " edui-colorbutton"; 43 | }, 44 | setColor: function(color) { 45 | this.getDom("colorlump").style.backgroundColor = color; 46 | this.color = color; 47 | }, 48 | _onPickColor: function(color) { 49 | if (this.fireEvent("pickcolor", color) !== false) { 50 | this.setColor(color); 51 | this.popup.hide(); 52 | } 53 | }, 54 | _onPickNoColor: function(color) { 55 | if (this.fireEvent("picknocolor") !== false) { 56 | this.popup.hide(); 57 | } 58 | } 59 | }; 60 | utils.inherits(ColorButton, SplitButton); 61 | })(); 62 | -------------------------------------------------------------------------------- /_src/ui/mask.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import uicore 3 | (function() { 4 | var utils = baidu.editor.utils, 5 | domUtils = baidu.editor.dom.domUtils, 6 | UIBase = baidu.editor.ui.UIBase, 7 | uiUtils = baidu.editor.ui.uiUtils; 8 | 9 | var Mask = (baidu.editor.ui.Mask = function(options) { 10 | this.initOptions(options); 11 | this.initUIBase(); 12 | }); 13 | Mask.prototype = { 14 | getHtmlTpl: function() { 15 | return '
'; 16 | }, 17 | postRender: function() { 18 | var me = this; 19 | domUtils.on(window, "resize", function() { 20 | setTimeout(function() { 21 | if (!me.isHidden()) { 22 | me._fill(); 23 | } 24 | }); 25 | }); 26 | }, 27 | show: function(zIndex) { 28 | this._fill(); 29 | this.getDom().style.display = ""; 30 | this.getDom().style.zIndex = zIndex; 31 | }, 32 | hide: function() { 33 | this.getDom().style.display = "none"; 34 | this.getDom().style.zIndex = ""; 35 | }, 36 | isHidden: function() { 37 | return this.getDom().style.display == "none"; 38 | }, 39 | _onMouseDown: function() { 40 | return false; 41 | }, 42 | _onClick: function(e, target) { 43 | this.fireEvent("click", e, target); 44 | }, 45 | _fill: function() { 46 | var el = this.getDom(); 47 | var vpRect = uiUtils.getViewportRect(); 48 | el.style.width = vpRect.width + "px"; 49 | el.style.height = vpRect.height + "px"; 50 | } 51 | }; 52 | utils.inherits(Mask, UIBase); 53 | })(); 54 | -------------------------------------------------------------------------------- /_src/ui/menubutton.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import uicore 3 | ///import ui/menu.js 4 | ///import ui/splitbutton.js 5 | (function() { 6 | var utils = baidu.editor.utils, 7 | Menu = baidu.editor.ui.Menu, 8 | SplitButton = baidu.editor.ui.SplitButton, 9 | MenuButton = (baidu.editor.ui.MenuButton = function(options) { 10 | this.initOptions(options); 11 | this.initMenuButton(); 12 | }); 13 | MenuButton.prototype = { 14 | initMenuButton: function() { 15 | var me = this; 16 | this.uiName = "menubutton"; 17 | this.popup = new Menu({ 18 | items: me.items, 19 | className: me.className, 20 | editor: me.editor 21 | }); 22 | this.popup.addListener("show", function() { 23 | var list = this; 24 | for (var i = 0; i < list.items.length; i++) { 25 | list.items[i].removeState("checked"); 26 | if (list.items[i].value == me._value) { 27 | list.items[i].addState("checked"); 28 | this.value = me._value; 29 | } 30 | } 31 | }); 32 | this.initSplitButton(); 33 | }, 34 | setValue: function(value) { 35 | this._value = value; 36 | } 37 | }; 38 | utils.inherits(MenuButton, SplitButton); 39 | })(); 40 | -------------------------------------------------------------------------------- /_src/ui/multiMenu.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import uicore 3 | ///commands 表情 4 | (function() { 5 | var utils = baidu.editor.utils, 6 | Popup = baidu.editor.ui.Popup, 7 | SplitButton = baidu.editor.ui.SplitButton, 8 | MultiMenuPop = (baidu.editor.ui.MultiMenuPop = function(options) { 9 | this.initOptions(options); 10 | this.initMultiMenu(); 11 | }); 12 | 13 | MultiMenuPop.prototype = { 14 | initMultiMenu: function() { 15 | var me = this; 16 | this.popup = new Popup({ 17 | content: "", 18 | editor: me.editor, 19 | iframe_rendered: false, 20 | onshow: function() { 21 | if (!this.iframe_rendered) { 22 | this.iframe_rendered = true; 23 | this.getDom("content").innerHTML = 24 | ''; 29 | me.editor.container.style.zIndex && 30 | (this.getDom().style.zIndex = 31 | me.editor.container.style.zIndex * 1 + 1); 32 | } 33 | } 34 | // canSideUp:false, 35 | // canSideLeft:false 36 | }); 37 | this.onbuttonclick = function() { 38 | this.showPopup(); 39 | }; 40 | this.initSplitButton(); 41 | } 42 | }; 43 | 44 | utils.inherits(MultiMenuPop, SplitButton); 45 | })(); 46 | -------------------------------------------------------------------------------- /_src/ui/separator.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var utils = baidu.editor.utils, 3 | UIBase = baidu.editor.ui.UIBase, 4 | Separator = (baidu.editor.ui.Separator = function(options) { 5 | this.initOptions(options); 6 | this.initSeparator(); 7 | }); 8 | Separator.prototype = { 9 | uiName: "separator", 10 | initSeparator: function() { 11 | this.initUIBase(); 12 | }, 13 | getHtmlTpl: function() { 14 | return '
'; 15 | } 16 | }; 17 | utils.inherits(Separator, UIBase); 18 | })(); 19 | -------------------------------------------------------------------------------- /_src/ui/tablebutton.js: -------------------------------------------------------------------------------- 1 | ///import core 2 | ///import uicore 3 | ///import ui/popup.js 4 | ///import ui/tablepicker.js 5 | ///import ui/splitbutton.js 6 | (function() { 7 | var utils = baidu.editor.utils, 8 | Popup = baidu.editor.ui.Popup, 9 | TablePicker = baidu.editor.ui.TablePicker, 10 | SplitButton = baidu.editor.ui.SplitButton, 11 | TableButton = (baidu.editor.ui.TableButton = function(options) { 12 | this.initOptions(options); 13 | this.initTableButton(); 14 | }); 15 | TableButton.prototype = { 16 | initTableButton: function() { 17 | var me = this; 18 | this.popup = new Popup({ 19 | content: new TablePicker({ 20 | editor: me.editor, 21 | onpicktable: function(t, numCols, numRows) { 22 | me._onPickTable(numCols, numRows); 23 | } 24 | }), 25 | editor: me.editor 26 | }); 27 | this.initSplitButton(); 28 | }, 29 | _onPickTable: function(numCols, numRows) { 30 | if (this.fireEvent("picktable", numCols, numRows) !== false) { 31 | this.popup.hide(); 32 | } 33 | } 34 | }; 35 | utils.inherits(TableButton, SplitButton); 36 | })(); 37 | -------------------------------------------------------------------------------- /_src/ui/toolbar.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var utils = baidu.editor.utils, 3 | uiUtils = baidu.editor.ui.uiUtils, 4 | UIBase = baidu.editor.ui.UIBase, 5 | Toolbar = (baidu.editor.ui.Toolbar = function(options) { 6 | this.initOptions(options); 7 | this.initToolbar(); 8 | }); 9 | Toolbar.prototype = { 10 | items: null, 11 | initToolbar: function() { 12 | this.items = this.items || []; 13 | this.initUIBase(); 14 | }, 15 | add: function(item, index) { 16 | if (index === undefined) { 17 | this.items.push(item); 18 | } else { 19 | this.items.splice(index, 0, item); 20 | } 21 | }, 22 | getHtmlTpl: function() { 23 | var buff = []; 24 | for (var i = 0; i < this.items.length; i++) { 25 | buff[i] = this.items[i].renderHtml(); 26 | } 27 | return ( 28 | '
' + 29 | buff.join("") + 30 | "
" 31 | ); 32 | }, 33 | postRender: function() { 34 | var box = this.getDom(); 35 | for (var i = 0; i < this.items.length; i++) { 36 | this.items[i].postRender(); 37 | } 38 | uiUtils.makeUnselectable(box); 39 | }, 40 | _onMouseDown: function(e) { 41 | var target = e.target || e.srcElement, 42 | tagName = target && target.tagName && target.tagName.toLowerCase(); 43 | if (tagName == "input" || tagName == "object" || tagName == "object") { 44 | return false; 45 | } 46 | } 47 | }; 48 | utils.inherits(Toolbar, UIBase); 49 | })(); 50 | -------------------------------------------------------------------------------- /_src/ui/ui.js: -------------------------------------------------------------------------------- 1 | var baidu = baidu || {}; 2 | baidu.editor = baidu.editor || {}; 3 | UE.ui = baidu.editor.ui = {}; 4 | -------------------------------------------------------------------------------- /_test/core/ajax.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/core/localstorage.js: -------------------------------------------------------------------------------- 1 | module("core.localstorage"); 2 | 3 | test('用 UE.LocalStorage 对字符串做保存/读取/删除操作', function () { 4 | 5 | var str = '1234567890-=!@#$%^&*()_+qwertyuiopasdfghjklzxcvbnm,./<>?;\':"[]\\{}|'; 6 | UE.LocalStorage.saveLocalData('test_string1', str); 7 | equal(UE.LocalStorage.getLocalData('test_string1'), str, "保存内容,并读取内容"); 8 | 9 | UE.LocalStorage.saveLocalData('test_string2', str); 10 | UE.LocalStorage.removeItem('test_string2'); 11 | equal(UE.LocalStorage.getLocalData('test_string2'), undefined, "保存内容,并删除内容"); 12 | 13 | }); 14 | 15 | test('偏好设置相关方法setPreferencesue、getPreferences、removePreferences', function () { 16 | 17 | var editor = te.obj[1]; 18 | 19 | var str = '1234567890-=!@#$%^&*()_+qwertyuiopasdfghjklzxcvbnm,./<>?;\':"[]\\{}|'; 20 | editor.setPreferences('test_string', str); 21 | equal(editor.getPreferences('test_string'), str, "保存字符串,并读取内容"); 22 | 23 | var obj = { 24 | nul: null, 25 | boo1: true, 26 | boo2: false, 27 | str: 'aaa', 28 | arr: [1, '2', 'a'], 29 | obj: {k1:1, k2:'2', k3:'a'} 30 | }; 31 | editor.setPreferences('test_object', obj); 32 | same(editor.getPreferences('test_object'), obj, "保存键值对象,并读取内容"); 33 | 34 | editor.setPreferences('test_boolean', true); 35 | equal(editor.getPreferences('test_boolean'), true, "保存布尔值,并读取内容"); 36 | 37 | var arr = [1, '2', 'a']; 38 | editor.setPreferences('test_string', arr); 39 | same(editor.getPreferences('test_string'), arr, "保存数组,并读取内容"); 40 | 41 | var tmpStr = 'string_content'; 42 | editor.setPreferences('test_delete', tmpStr); 43 | editor.removePreferences('test_delete'); 44 | equal(editor.getPreferences('test_delete'), undefined, "保存字符串,并删除内容"); 45 | 46 | }); -------------------------------------------------------------------------------- /_test/core/plugin.js: -------------------------------------------------------------------------------- 1 | module( 'core.plugin' ); 2 | 3 | test( 'register', function() { 4 | UE.plugin.register('test',function(){ 5 | this.testplugin = true; 6 | }); 7 | $('
').appendTo(document.body); 8 | var editor = UE.getEditor('ue'); 9 | stop(); 10 | editor.ready(function () { 11 | ok(this.testplugin); 12 | editor.destroy(); 13 | $('#ue').remove() 14 | start(); 15 | }); 16 | }); 17 | test( 'load', function() { 18 | UE.plugin.register('test',function(){ 19 | this.testplugin = true; 20 | }); 21 | $('
').appendTo(document.body); 22 | var editor = UE.getEditor('ue',{ 23 | test:false 24 | }); 25 | stop(); 26 | editor.ready(function () { 27 | // ok(!this.testplugin); todo 28 | start(); 29 | }); 30 | }); -------------------------------------------------------------------------------- /_test/core/tools.js: -------------------------------------------------------------------------------- 1 | (function () { 2 | function mySetup() { 3 | for (var config in window.UEDITOR_CONFIG) { 4 | if (typeof(window.UEDITOR_CONFIG[config]) == 'string') 5 | window.UEDITOR_CONFIG[config] = window.UEDITOR_CONFIG[config].replace('_test/tools/br/', ''); 6 | } 7 | 8 | var div = document.body.appendChild(document.createElement('div')); 9 | div.id = 'test1'; 10 | var utils = baidu.editor.utils; 11 | var editor = new baidu.editor.Editor({'UEDITOR_HOME_URL':'../../../', 'autoFloatEnabled':false,initialContent:'tool'}); 12 | var iframe = document.createElement('iframe'); 13 | document.body.appendChild(iframe); 14 | iframe.id = 'iframe'; 15 | var range = new baidu.editor.dom.Range(document); 16 | var domUtils = baidu.editor.dom.domUtils; 17 | var div_dom = document.body.appendChild(document.createElement('div')); 18 | div_dom.id = 'test'; 19 | te.dom.push(div); 20 | te.dom.push(iframe); 21 | te.dom.push(div_dom); 22 | te.obj.push(utils); 23 | te.obj.push(editor); 24 | te.obj.push(range); 25 | te.obj.push(domUtils); 26 | } 27 | var _d = function () { 28 | 29 | if (te) { 30 | if (te.dom && te.dom.length) { 31 | for (var i = 0; i < te.dom.length; i++) { 32 | if (te.dom[i] && te.dom[i].parentNode) 33 | te.dom[i].parentNode.removeChild(te.dom[i]); 34 | } 35 | 36 | } 37 | } 38 | te.dom = []; 39 | te.obj = []; 40 | }; 41 | var s = QUnit.testStart, d = QUnit.testDone; 42 | QUnit.testStart = function () { 43 | s.apply(this, arguments); 44 | mySetup(); 45 | }; 46 | QUnit.testDone = function () { 47 | _d(); 48 | d.apply(this, arguments); 49 | }; 50 | })() -------------------------------------------------------------------------------- /_test/index.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/plugins/auto.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: lisisi01 4 | * Date: 12-11-8 5 | * Time: 下午3:37 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'plugins.autosubmit' ); 9 | 10 | //这个插件是针对非ie的,单测用例同样只针对非ie,仍需手动测试检验ie与非ie下效果是否一致 11 | test( '输入超链接后回车', function() { 12 | var form = document.body.appendChild( document.createElement( 'form' ) ); 13 | var editor = new baidu.editor.Editor({'initialContent':'

欢迎使用ueditor

','autoFloatEnabled':false}); 14 | editor.render(form); 15 | // form.body.appendChild(editor); 16 | editor.focus(); 17 | var range = new baidu.editor.dom.Range( editor.document ); 18 | range.setStart(editor.body.firstChild.firstChild,1).collapse(true).select(); 19 | editor.execCommand('autosubmit'); 20 | equal(editor.textarea.value,'

欢迎使用ueditor

',''); 21 | } ); -------------------------------------------------------------------------------- /_test/plugins/autoheight.js: -------------------------------------------------------------------------------- 1 | module('plugins.autoheight'); 2 | 3 | test('自动长高',function(){ 4 | var sc = document.createElement("script"); 5 | sc.id="sc"; 6 | sc.type = "text/plain"; 7 | document.body.appendChild(sc); 8 | var editor = new UE.ui.Editor({'autoFloatEnabled':true,'topOffset':60,'autoHeightEnabled':true,'scaleEnabled':false}); 9 | editor.render('sc'); 10 | te.dom[0].parentNode.removeChild(te.dom[0]); 11 | stop(); 12 | setTimeout(function(){ 13 | var height=editor.body.style.height; 14 | editor.setContent('
nmnmknmm,






















'); 15 | setTimeout(function(){ 16 | ok(height!=editor.body.style.height,'自动长高'); 17 | editor.disableAutoHeight(); 18 | editor.body.style.height=height; 19 | editor.setContent('
























'); 20 | stop(); 21 | setTimeout(function(){ 22 | ok(height==editor.body.style.height,'不长高'); 23 | 24 | start(); 25 | },200); 26 | },200); 27 | },800); 28 | }); -------------------------------------------------------------------------------- /_test/plugins/autosubmit.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by wangrui10 on 14-6-4. 3 | */ 4 | module('plugins.autosubmit'); 5 | 6 | test("自动提交",function(){ 7 | var form = document.body.appendChild(document.createElement('form')); 8 | form.id = 'formid'; 9 | form.action = './'; 10 | form.method = "post"; 11 | form.target = '_blank'; 12 | 13 | var text = document.createElement('input'); 14 | text.type = 'text'; 15 | form.appendChild(text); 16 | 17 | var btn = document.createElement('input'); 18 | btn.type = 'submit'; 19 | form.appendChild(btn); 20 | 21 | var div = form.appendChild(document.createElement('div')); 22 | div.id = 'ue'; 23 | var editor = UE.getEditor('ue'); 24 | editor.ready(function(){ 25 | editor.body.innerHTML='123123'; 26 | editor.focus(); 27 | editor.execCommand('autosubmit'); 28 | 29 | form = domUtils.findParentByTagName(this.iframe,"form", false); 30 | 31 | setTimeout(function(){ 32 | equal(editor.textarea.value,'123123','检查editor中准备同步的内容'); 33 | var d = $('#'+form.id).context.forms.formid[2].value; 34 | equal(d,'123123','editor中的内容同步到textarea中'); 35 | start(); 36 | },100); 37 | 38 | }); 39 | stop(); 40 | }); 41 | 42 | -------------------------------------------------------------------------------- /_test/plugins/autoupload.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: Jinqn 4 | * Date: 13-10-29 5 | * Time: 下午5:14 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module('plugins.autoupload'); 9 | 10 | test('拖放图片上传',function(){ 11 | equal('',''); 12 | }); 13 | 14 | test('粘贴QQ截图',function(){ 15 | equal('',''); 16 | }); 17 | -------------------------------------------------------------------------------- /_test/plugins/copy.js: -------------------------------------------------------------------------------- 1 | module('plugins.copy'); 2 | 3 | //需要点击授权弹出框,暂时去除 4 | //test('检查IE下复制命令是否执行正常', function () { 5 | // 6 | // if (browser.ie) { 7 | // var editor = te.obj[0]; 8 | // editor.setContent('

hello

'); 9 | // editor.focus(); 10 | // 11 | // editor.execCommand('selectall'); 12 | // editor.execCommand('copy'); 13 | // editor.body.innerHTML = ''; 14 | // editor.execCommand('selectall'); 15 | // editor.body.document.execCommand('paste'); 16 | // 17 | // equal(utils.trim(window.clipboardData.getData('text')), 'hello', '检查粘贴板内容,IE下成功复制内容'); 18 | // setTimeout(function(){ 19 | // equal(editor.getContent(), '

hello

', '检查原生粘贴命令,IE下成功复制内容'); 20 | // start(); 21 | // },100); 22 | // 23 | // stop(); 24 | // } 25 | // 26 | //}); 27 | 28 | test('检查非IE下是否正常加载zeroclipboard粘贴板插件', function () { 29 | te.dom[0].parentNode.removeChild(te.dom[0]); 30 | var sc = document.createElement("script"); 31 | sc.id="sc"; 32 | sc.type = "text/plain"; 33 | sc.style.height = "100px"; 34 | document.body.appendChild(sc); 35 | var me = UE.getEditor('sc',{'autoFloatEnabled':true,'topOffset':60,'autoHeightEnabled':true,'scaleEnabled':false}); 36 | me.ready(function(){ 37 | setTimeout(function(){ 38 | if (!browser.ie) { 39 | ok(window.ZeroClipboard, '是否正常加载zeroclipboard粘贴板插件'); 40 | } 41 | setTimeout(function () { 42 | UE.delEditor('sc'); 43 | document.getElementById('sc')&&document.getElementById('sc').parentNode.removeChild(document.getElementById('sc')); 44 | start(); 45 | }, 500); 46 | }, 300); 47 | }); 48 | stop(); 49 | 50 | }); -------------------------------------------------------------------------------- /_test/plugins/dragdrop.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created with JetBrains PhpStorm. 3 | * User: Administrator 4 | * Date: 13-4-29 5 | * Time: 上午11:40 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'plugins.dragdrop' ); 9 | test( 'trace 3385:拖拽图像不会把p切开', function () { 10 | var editor = te.obj[0]; 11 | var range = te.obj[1]; 12 | var body = editor.body; 13 | stop(); 14 | 15 | body.innerHTML = '

hel

lo

'; 16 | range.selectNode(body.childNodes[1]).select(); 17 | equal(body.childNodes.length,3,'img在两个p之间'); 18 | equal(body.firstChild.tagName.toLowerCase(),"p",'img在两个p之间'); 19 | equal(body.childNodes[1].tagName.toLowerCase(),"img",'img在两个p之间'); 20 | equal(body.childNodes[2].tagName.toLowerCase(),"p",'img在两个p之间'); 21 | 22 | ua.dragend(body); 23 | setTimeout(function(){ 24 | equal(body.childNodes.length,1,'img在p里面'); 25 | equal(body.firstChild.tagName.toLowerCase(),'p','img在p里面'); 26 | equal(body.firstChild.childNodes[1].tagName.toLowerCase(),'img','img在p里面'); 27 | body.innerHTML = '

asds

ad

'; 28 | range.selectNode(body.childNodes[1]).select(); 29 | ua.dragend(body); 30 | setTimeout(function(){ 31 | equal(body.childNodes.length,1,'拖拽图像不会把p切开,删除空span:img在p里面') 32 | equal(body.firstChild.tagName.toLowerCase(),'p','img在p里面'); 33 | equal(body.firstChild.childNodes[1].tagName.toLowerCase(),'img','img在p里面'); 34 | start(); 35 | },300); 36 | },100); 37 | } ); -------------------------------------------------------------------------------- /_test/plugins/iframe.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-9-17 5 | * Time: 下午2:55 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'plugins.iframe' ); 9 | test( '检查高亮和清除_iframe', function() { 10 | var sc = document.createElement("script"); 11 | sc.id="sc"; 12 | sc.type = "text/plain"; 13 | document.body.appendChild(sc); 14 | te.obj[2].render('sc'); 15 | 16 | te.obj[2].ready(function(){ 17 | equal( te.obj[2].queryCommandState( 'insertframe' ), 0, 'check insertframe state' ); 18 | var iframe = document.createElement('iframe'); 19 | $(iframe).attr('src','www.baidu.com'); 20 | this._iframe = iframe; 21 | this.setContent('

欢迎使用ueditor!

'); 22 | ok(te.obj[2]._iframe,'加入_iframe'); 23 | setTimeout(function(){ 24 | ok(!te.obj[2]._iframe,'检查selectionchanged会触发去掉_iframe'); 25 | document.getElementById('sc').parentNode.removeChild(document.getElementById('sc')); 26 | start(); 27 | },50); 28 | }); 29 | stop(); 30 | } ); -------------------------------------------------------------------------------- /_test/plugins/insertparagraph.js: -------------------------------------------------------------------------------- 1 | module( 'plugins.insertparagraph' ); 2 | 3 | test( '插入空行', function() { 4 | var editor = te.obj[0]; 5 | var range = te.obj[1]; 6 | var body = editor.body; 7 | editor.setContent( 'hello' ); 8 | range.setStart( body.firstChild, 0 ).collapse( 1 ).select(); 9 | editor.execCommand( 'insertparagraph', true ); 10 | var br = ua.browser.ie?'':'
' 11 | equal( ua.getChildHTML( body ), '

'+br+'

hello

', '插入空行' ); 12 | range.setStart( body.firstChild.nextSibling, 0 ).collapse( 1 ).select(); 13 | editor.execCommand( 'insertparagraph', false ); 14 | equal( ua.getChildHTML( body ), '

'+br+'

hello

'+br+'

', '' ); 15 | } ); -------------------------------------------------------------------------------- /_test/plugins/music.js: -------------------------------------------------------------------------------- 1 | module( 'plugins.music' ); 2 | 3 | test( ' trace 3745 3780 音乐', function () { 4 | var editor = te.obj[0]; 5 | var range = te.obj[1]; 6 | editor.setContent( '

hello

' ); 7 | range.setStart(editor.body.firstChild,0).collapse(true).select(); 8 | editor.execCommand( 'music',{url:"http://box.baidu.com/widget/flash/bdspacesong.swf?from=tiebasongwidget&url=…artist=%E5%BC%A0%E6%B6%A6%E8%B4%9E&extra=Vol.%202&autoPlay=false&loop=true"}); 9 | stop(); 10 | setTimeout(function(){ 11 | ua.manualDeleteFillData(editor.body); 12 | ua.checkSameHtml(editor.getContent(),'

hello

',''); 13 | equal(editor.body.firstChild.firstChild.tagName.toLowerCase(),'img'); 14 | equal(editor.body.firstChild.firstChild.className,'edui-faked-music'); 15 | start(); 16 | },50); 17 | } ); -------------------------------------------------------------------------------- /_test/plugins/print.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-9-28 5 | * Time: 下午1:34 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module('plugins.print'); 9 | 10 | test('print',function(){ 11 | // var editor = te.obj[0]; 12 | // var html = '

for print

'; 13 | // editor.setContent(html); 14 | // editor.execCommand('print'); 15 | // equal(editor.body.innerHTML,html,'打印不会对页面代码产生影响'); 16 | equal('',''); 17 | }); 18 | -------------------------------------------------------------------------------- /_test/plugins/scrawl.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created with JetBrains PhpStorm. 3 | * User: luqiong 4 | * Date: 12-11-13 5 | * Time: 下午2:13 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | 9 | module( 'plugins.scrawl' ); 10 | test( '检查高亮', function() { 11 | var editor = te.obj[0]; 12 | editor.focus(); 13 | equal( editor.queryCommandState( 'scrawl' ), ( browser.ie && browser.version <= 8 ) ? -1:0, 'check scrawl state' ); 14 | } ); 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /_test/plugins/serverparam.js: -------------------------------------------------------------------------------- 1 | module( 'plugins.serverparam' ); 2 | 3 | test( '检查是否能正常设置参数', function () { 4 | var editor = te.obj[0]; 5 | 6 | editor.execCommand('serverparam', {"a": 1, "b": 2}); 7 | same( editor.queryCommandValue('serverparam'), {"a": 1, "b": 2}, '传入对象设置参数'); 8 | 9 | editor.execCommand('serverparam', "c", 3); 10 | same( editor.queryCommandValue('serverparam'), {"a": 1, "b": 2, "c": 3}, '传入键和值设置参数'); 11 | 12 | editor.execCommand('serverparam', "c"); 13 | same( editor.queryCommandValue('serverparam'), {"a": 1, "b": 2}, '传入键删除参数'); 14 | 15 | editor.execCommand('serverparam'); 16 | same( editor.queryCommandValue('serverparam'), {}, '不传参数,清空参数表'); 17 | } ); -------------------------------------------------------------------------------- /_test/plugins/snapscreen.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-9-17 5 | * Time: 下午2:38 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module('plugins.snapscreen'); 9 | test('检查高亮', function () { 10 | var editor = te.obj[0]; 11 | editor.focus(); 12 | equal(editor.queryCommandState('snapscreen'), 0, 'check snapscreen state'); 13 | }); 14 | test('snapscreen', function () { 15 | var div = document.body.appendChild(document.createElement('script')); 16 | div.id = 'ue'; 17 | var editor = UE.getEditor('ue'); 18 | stop(); 19 | editor.ready(function () { 20 | setTimeout(function () { 21 | editor.execCommand('snapscreen'); 22 | editor.container.removeChild(editor.container.lastChild); 23 | setTimeout(function () { 24 | ok($('.edui-dialog .edui-for-snapscreen')[0] != null, ''); 25 | $EDITORUI[$('.edui-dialog .edui-for-snapscreen')[0].parentNode.id].close(); 26 | setTimeout(function () { 27 | 28 | UE.delEditor('ue'); 29 | te.dom.push(document.getElementById('ue')); 30 | start(); 31 | }, 1000); 32 | }, 300); 33 | 34 | 35 | }, 100); 36 | 37 | 38 | } 39 | 40 | ); 41 | }); -------------------------------------------------------------------------------- /_test/plugins/template.js: -------------------------------------------------------------------------------- 1 | module( 'plugins.template' ); 2 | 3 | test( '模板', function () { 4 | var editor = te.obj[0]; 5 | var range = te.obj[1]; 6 | editor.setContent( '

hello

' ); 7 | range.setStart(editor.body.firstChild,0).collapse(true).select(); 8 | editor.execCommand('template',{html:'

欢迎使用UEditor!

'}); 9 | ua.manualDeleteFillData(editor.body); 10 | equal(ua.getHTML(editor.body.firstChild),'

欢迎使用ueditor!

'); 11 | if(!(ua.browser.gecko||ua.browser.ie>8)){ 12 | if(ua.browser.webkit){ 13 | ua.click(editor.body.firstChild); 14 | equal(editor.selection.getRange().startContainer.firstChild.length,'12','检查选区'); 15 | ua.keydown(editor.body.firstChild); 16 | equal(editor.selection.getRange().startContainer.firstChild.length,'12','检查选区'); 17 | }else{ 18 | ua.click(editor.body.firstChild); 19 | equal(editor.selection.getRange().startContainer.length,'12','检查选区'); 20 | ua.keydown(editor.body.firstChild); 21 | equal(editor.selection.getRange().startContainer.length,'12','检查选区'); 22 | } 23 | } 24 | } ); -------------------------------------------------------------------------------- /_test/plugins/ueditor.config.js: -------------------------------------------------------------------------------- 1 | module( ".path" ); 2 | 3 | /*trace 3683*/ 4 | test( '路径查找测试', function () { 5 | // equal( UE.getUEBasePath( 'https://www.baidu.com/', './ueditor.config.js' ), 'https://www.baidu.com/', 'WEB路径-当前目录下' ); 6 | // equal( UE.getUEBasePath( 'https://www.baidu.com/abc/def/', '../ueditor.config.js' ), 'https://www.baidu.com/abc/', 'WEB路径-父目录1' ); 7 | // equal( UE.getUEBasePath( 'https://www.baidu.com/abc/def', '../ueditor.config.js' ), 'https://www.baidu.com/', 'WEB路径-父目录2' ); 8 | // 9 | // equal( UE.getUEBasePath( 'file:///home/hn/a/ueditor/_examples/completeDemo.html', './ueditor.config.js' ), 'file:///home/hn/a/ueditor/_examples/', '本地路径-linux-当前目录1' ); 10 | // equal( UE.getUEBasePath( 'file:///home/hn/a/ueditor/_examples/completeDemo.html', 'ueditor.config.js' ), 'file:///home/hn/a/ueditor/_examples/', '本地路径-linux-当前目录2' ); 11 | // equal( UE.getUEBasePath( 'file:///home/hn/a/ueditor/_examples/completeDemo.html', '../ueditor.config.js' ), 'file:///home/hn/a/ueditor/', '本地路径-linux-父目录1' ); 12 | // equal( UE.getUEBasePath( 'file:///home/hn/a/ueditor/_examples/completeDemo.html', './../ueditor.config.js' ), 'file:///home/hn/a/ueditor/', '本地路径-linux-父目录2' ); 13 | // 14 | // equal( UE.getUEBasePath( 'file://C:\\webroot\\ueditor\\_examples\\completeDemo.html', './ueditor.config.js' ), 'file://C:/webroot/ueditor/_examples/', '本地路径-windows-当前目录1' ); 15 | // equal( UE.getUEBasePath( 'file://C:\\webroot\\ueditor\\_examples\\completeDemo.html', 'ueditor.config.js' ), 'file://C:/webroot/ueditor/_examples/', '本地路径-windows-当前目录2' ); 16 | // equal( UE.getUEBasePath( 'file://C:\\webroot\\ueditor\\_examples\\completeDemo.html', '../ueditor.config.js' ), 'file://C:/webroot/ueditor/', '本地路径-windows-父目录1' ); 17 | // equal( UE.getUEBasePath( 'file://C:\\webroot\\ueditor\\_examples\\completeDemo.html', './../ueditor.config.js' ), 'file://C:/webroot/ueditor/', '本地路径-windows-父目录2' ); 18 | // 19 | // equal( UE.getUEBasePath( 'https://www.baidu.com/ueditor/completedemo.html', '/ueditorphp/ueditor.config.js' ), 'https://www.baidu.com/ueditorphp/', 'WEB路径-当前目录下' ); 20 | } ); -------------------------------------------------------------------------------- /_test/plugins/webapp.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created with JetBrains PhpStorm. 3 | * User: taoqili 4 | * Date: 12-6-5 5 | * Time: 下午2:52 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'plugins.webapp' ); 9 | test("插入一个webapp",function(){ 10 | stop(); 11 | expect(7); 12 | var editor = te.obj[0]; 13 | equal(editor.options.initialContent,editor.getContent(),"没插入webapp之前内容为空"); 14 | 15 | editor.execCommand( "webapp", { 16 | url:"http://app.baidu.com/app/enter?appid=152311&tn=app_canvas&app_spce_id=1&apikey=5r7SmiUici27lVfVBep1K7BA&api_key=5r7SmiUici27lVfVBep1K7BA", 17 | width:300, 18 | height:400, 19 | logo:'http://apps1.bdimg.com/store/static/kvt/2c86377ca162d93547aeeca6fe252696.jpgo', 20 | title:'测试' 21 | }); 22 | 23 | var backImg = editor.document.getElementsByTagName("img")[0]; 24 | var div = document.createElement("div"); 25 | div.innerHTML = editor.getContent(); 26 | var iframe = div.getElementsByTagName("iframe")[0]; 27 | ok(iframe,"插入webapp后获取到的内容中包含一个iframe"); 28 | if(iframe){ 29 | equal(iframe.className,"edui-faked-webapp","获取到的iframe中包含edui-faked-webapp类名"); 30 | ok(iframe.getAttribute("logo_url"),"包含一个logo_url属性"); 31 | } 32 | setTimeout( function () { 33 | editor.execCommand( 'source' ); 34 | setTimeout( function () { 35 | editor.execCommand( 'source' ); 36 | var newImg = editor.document.getElementsByTagName("img")[0]; 37 | ok(newImg.src ==backImg.src,"源码切换之后占位图片地址不变"); 38 | ok(newImg.className ==backImg.className,"源码切换之后占位图片样式类不变"); 39 | ok(newImg._url ==backImg._url,"源码切换之后占位图片_url数据不变"); 40 | start(); 41 | }, 200 ); 42 | }, 200 ); 43 | 44 | 45 | 46 | }); 47 | -------------------------------------------------------------------------------- /_test/plugins/wordcount.js: -------------------------------------------------------------------------------- 1 | module('plugins.wordcount'); 2 | 3 | test('trace 1743 右键删除后计算字数', function () { 4 | var editor = te.obj[0]; 5 | var range = te.obj[1]; 6 | editor.setContent('

hello

'); 7 | setTimeout(function () { 8 | range.setStart(editor.body.firstChild, 0).collapse(true).select(); 9 | editor.execCommand('selectall'); 10 | editor.execCommand('cleardoc'); 11 | equal(editor.getContentLength(true), 0, '插入成功'); 12 | 13 | start(); 14 | }, 50); 15 | stop(); 16 | }); 17 | 18 | test('空格', function () { 19 | var editor = te.obj[0]; 20 | var range = te.obj[1]; 21 | editor.setContent(' \ufeff\u200B\t\t \n\n\t\n\b\t\n\b\u200B\t\t\n\n '); 22 | if (ua.browser.ie) 23 | equal(editor.getContentLength(true), 23, '清空后编辑器中23个空格'); 24 | else 25 | equal(editor.getContentLength(true), 22, '清空后编辑器中22个空格'); 26 | }); 27 | 28 | test(' trace 3744 超出最大', function () { 29 | 30 | var div = document.body.appendChild(document.createElement('div')); 31 | div.id = 'ue'; 32 | var editor = UE.getEditor('ue', {'UEDITOR_HOME_URL': '../../../', 'wordCount': true, 'maximumWords': 10,'initialContent':'','autoFloatEnabled': false}); 33 | editor.ready(function () { 34 | 35 | expect(2); 36 | editor.addListener("wordcountoverflow", function () { 37 | ok(true, "超出最大"); 38 | setTimeout(function () { 39 | UE.delEditor('ue'); 40 | start(); 41 | }, 500); 42 | }); 43 | setTimeout(function () { 44 | editor.setContent('hello hello hello'); 45 | equal(editor.getContentLength(true), 17, '仅统计字数') 46 | 47 | }, 50); 48 | }); 49 | stop(); 50 | }); 51 | -------------------------------------------------------------------------------- /_test/testDesign/Manual regression cases.xmind: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/testDesign/Manual regression cases.xmind -------------------------------------------------------------------------------- /_test/testDesign/readme.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/testDesign/readme.txt -------------------------------------------------------------------------------- /_test/tools/br/batchrun.sh: -------------------------------------------------------------------------------- 1 | /home/work/.bash_profile 2 | cd /home/work/repos/Tangram-base 3 | /home/work/soft/git-1.7.3.5/bin-wrappers/git pull 4 | sh release/output.sh 5 | rm -rf test/tools/br/report 6 | wget -q -O /tmp/tmp.php http://10.32.34.115:8000/Tangram-base/test/tools/br/runall.php?clearreport=true&cov=true 7 | sleep 3m 8 | rm -rf test/tools/br/report 9 | wget -q -O /tmp/tmp.php http://10.32.34.115:8000/Tangram-base/test/tools/br/runall.php?release=true&clearreport=true 10 | cd - -------------------------------------------------------------------------------- /_test/tools/br/coverage/jscov.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/tools/br/coverage/jscoverage-highlight.css: -------------------------------------------------------------------------------- 1 | /* 2 | jscoverage-highlight.css - JSCoverage syntax highlighting style sheet 3 | Copyright (C) 2008, 2009, 2010 siliconforks.com 4 | 5 | This program is free software; you can redistribute it and/or modify 6 | it under the terms of the GNU General Public License as published by 7 | the Free Software Foundation; either version 2 of the License, or 8 | (at your option) any later version. 9 | 10 | This program is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | GNU General Public License for more details. 14 | 15 | You should have received a copy of the GNU General Public License along 16 | with this program; if not, write to the Free Software Foundation, Inc., 17 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 18 | */ 19 | 20 | /* keyword, type, symbol, cbracket */ 21 | #sourceTable .k { 22 | font-weight: bold; 23 | } 24 | 25 | /* string, regexp, number */ 26 | #sourceTable .s { 27 | color: #006400; 28 | } 29 | 30 | /* specialchar */ 31 | #sourceTable .t { 32 | color: #2e8b57; 33 | } 34 | 35 | /* comment */ 36 | #sourceTable .c { 37 | font-style: italic; 38 | } 39 | -------------------------------------------------------------------------------- /_test/tools/br/coverage/jscoverage-throbber.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/br/coverage/jscoverage-throbber.gif -------------------------------------------------------------------------------- /_test/tools/br/css/bg_button_a.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/br/css/bg_button_a.gif -------------------------------------------------------------------------------- /_test/tools/br/css/bg_button_span.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/br/css/bg_button_span.gif -------------------------------------------------------------------------------- /_test/tools/br/filehelper.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/tools/br/geneHistory.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/tools/br/js/UserAction manual.rar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/br/js/UserAction manual.rar -------------------------------------------------------------------------------- /_test/tools/br/js/ext_qunit.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 重载QUnit部分接口实现批量执行控制功能 3 | */ 4 | (function() { 5 | if (!QUnit) 6 | return; 7 | var ms = QUnit.moduleStart, d = QUnit.done; 8 | 9 | function _d(args /* failures, total */) { 10 | //默认展开失败用例 11 | $('li.fail ol').toggle(); 12 | if (parent && parent.brtest) { 13 | parent.$(parent.brtest).trigger('done', [ new Date().getTime(), { 14 | failed : args[0], 15 | passed : args[1], 16 | detail:args[2] 17 | }, window._$jscoverage || null ]); 18 | } 19 | } 20 | QUnit.moduleStart = function() { 21 | stop(); 22 | /* 为批量执行等待import.php正确返回 */ 23 | var h = setInterval(function() { 24 | if (window && window['baidu']) { 25 | clearInterval(h); 26 | ms.apply(this, arguments); 27 | start(); 28 | } 29 | }, 20); 30 | }; 31 | QUnit.done = function() { 32 | _d(arguments); 33 | d.apply(this, arguments); 34 | }; 35 | })(); 36 | -------------------------------------------------------------------------------- /_test/tools/br/lib/Staf.php: -------------------------------------------------------------------------------- 1 | ]] COMMAND [PARMS ] 25 | * @param $path 26 | * @param $params 27 | * @param $host 28 | */ 29 | public static function process_start($path, $params, $host='local', $wait=false){ 30 | $cmd = "start shell command \\\"\"$path\"\\\" parms \\\"\"$params\"\\\""; 31 | if($wait){ 32 | $cmd.=" wait returnstdout returnstderr"; 33 | } 34 | return self::process($cmd, $host); 35 | } 36 | 37 | /** 38 | * STOP | HANDLE > [USING ] 39 | * @param unknown_type $handle 40 | * @param unknown_type $host 41 | */ 42 | public static function process_stop($handle, $host='local', $all=0){ 43 | $cmd = $all ? "STOP ALL CONFIRM":"STOP HANDLE $handle"; 44 | return self::process($cmd, $host); 45 | } 46 | 47 | public static function queryHandle($browser){ 48 | $filename = "temp\\$browser"; 49 | if(file_exists($filename)){ 50 | $handle = file_get_contents($filename); 51 | delete($filename); 52 | return $handle; 53 | } 54 | return false; 55 | } 56 | 57 | public static function saveHandle($browser){ 58 | $filename = "temp\\$browser"; 59 | $fp = fopen($filename, 'w'); 60 | fwrite($fp, 'test'); 61 | fclose($fp); 62 | } 63 | } 64 | ?> -------------------------------------------------------------------------------- /_test/tools/br/lib/StafResult.php: -------------------------------------------------------------------------------- 1 | rc = $rc; 9 | $this->info = $info; 10 | } 11 | 12 | public function __toString() 13 | { 14 | return "return code : ".$rc.", return info : ".$info."\n"; 15 | } 16 | 17 | public static function parse($result){ 18 | return new StafResult(0, $result); 19 | } 20 | }?> -------------------------------------------------------------------------------- /_test/tools/br/log.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/tools/br/read.php: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_test/tools/br/run.php: -------------------------------------------------------------------------------- 1 | '; 6 | } 7 | ; 8 | require_once "case.class.php"; 9 | $c = new Kiss( '../../../' , $_GET[ 'case' ] ); 10 | $title = $c->name; 11 | $cov = array_key_exists( 'cov' , $_GET ); 12 | ?> 13 | 14 | 15 | 16 | <?php print( "run case $title" );?> 17 | print_js( $cov ); ?> 18 | 19 | 20 |

name );?>

21 | 22 |

23 | 24 |

25 |
    26 | 40 |
    41 | 42 | 43 | 44 |
    45 | 46 | -------------------------------------------------------------------------------- /_test/tools/br/runC.php: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/br/runC.php -------------------------------------------------------------------------------- /_test/tools/br/txt/test1_2.txt: -------------------------------------------------------------------------------- 1 |

    2 |

    3 | 4 |

    5 |

    6 | 欢迎使用ueditor! 7 | 8 | 9 |

    10 |

    11 | 12 |

    13 |

    14 | 欢迎使用ueditor! 15 | 16 | 17 |

    18 |

    19 | 欢迎使用ueditor! 20 | 21 | 22 |

    23 |

    24 | 欢迎使用ueditor! 25 | 26 | 27 |

    28 |

    29 | 欢迎使用ueditor! 30 | 31 | 32 |

    33 |

    34 | 欢迎使用ueditor! 35 | 36 | 37 |

    38 |

    -------------------------------------------------------------------------------- /_test/tools/coverage/cov.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | jscoverage.exe --encoding=UTF-8 ../../../_src ../../coverage -------------------------------------------------------------------------------- /_test/tools/coverage/jscoverage.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/coverage/jscoverage.exe -------------------------------------------------------------------------------- /_test/tools/data/frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 10 | -------------------------------------------------------------------------------- /_test/tools/data/frame.php: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | "; 10 | else 11 | print ""; 12 | ?> 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /_test/tools/data/test.JPG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/data/test.JPG -------------------------------------------------------------------------------- /_test/tools/data/test.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /_test/tools/data/testReady.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /_test/tools/lib/ant_tangram_ext.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/ant_tangram_ext.jar -------------------------------------------------------------------------------- /_test/tools/lib/js.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/js.jar -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/conf/custcheck.conf: -------------------------------------------------------------------------------- 1 | [command] 2 | -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/conf/ignore.list: -------------------------------------------------------------------------------- 1 | #there 3 level:ignore warning error 2 | [level] 3 | Unsafe character=ignore 4 | Mixed spaces and tabs=warning 5 | Too many var statements=ignore 6 | Unclosed string=ignore 7 | Missing semicolon=error 8 | Unexpected dangling=ignore 9 | to compare with=ignore 10 | is not defined=ignore 11 | Unexpected dangling=ignore 12 | A constructor name should start with an uppercase letter=warning 13 | Expected an assignment or function call and instead saw an expression=warning 14 | Mixed spaces and tabs=ignore 15 | -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/conf/omitfiles.conf: -------------------------------------------------------------------------------- 1 | #[config format]:REGULAR:true|false,true means set filtering enabeld and false means not 2 | #notice:REGULAR will be set in the command "find /top/dir -name REGULAR" 3 | [omitfils] 4 | *data*:true 5 | -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/core/customcheck/cust.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | echo $1'***222***444***555***666' 4 | -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/core/jshint/js.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/core/jshint/js.jar -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/core/tpl/htmlpart.html: -------------------------------------------------------------------------------- 1 |  2 | 3 |
    {$title}
    4 |
    5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | [---to be replaced 2---] 14 | 15 |
    -------------------------------------------------------------------------------- /_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/version: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/jshunter_1.2.0.1/jshunter_dev/jshunter/version -------------------------------------------------------------------------------- /_test/tools/lib/jslint4java-2.0.2.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/jslint4java-2.0.2.jar -------------------------------------------------------------------------------- /_test/tools/lib/jslint4java-ant-1.4.2.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/jslint4java-ant-1.4.2.jar -------------------------------------------------------------------------------- /_test/tools/lib/npPlugintest.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/tools/lib/npPlugintest.dll -------------------------------------------------------------------------------- /_test/ui/css/DEFAULT.css: -------------------------------------------------------------------------------- 1 | /* common layer */ 2 | .cssloaded { 3 | width: 20px; 4 | } 5 | /* for IE6 fixed */ 6 | body { 7 | background: url('about:blank') fixed; 8 | } 9 | 10 | .edui-editor { 11 | width: 843px; 12 | } 13 | -------------------------------------------------------------------------------- /_test/ui/editorui.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-4-12 5 | * Time: 下午4:45 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'ui.editorui' ); 9 | test( '', function() { 10 | equal('','',''); 11 | } ); -------------------------------------------------------------------------------- /_test/ui/mask.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-4-12 5 | * Time: 下午4:45 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'ui.mask' ); 9 | test( '', function() { 10 | equal('','',''); 11 | } ); -------------------------------------------------------------------------------- /_test/ui/separator.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-4-12 5 | * Time: 下午4:46 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'ui.separator' ); 9 | test( '', function() { 10 | equal('','',''); 11 | } ); -------------------------------------------------------------------------------- /_test/ui/stateful.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-4-12 5 | * Time: 下午4:46 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'ui.stateful' ); 9 | test( '', function() { 10 | equal('','',''); 11 | } ); -------------------------------------------------------------------------------- /_test/ui/uibase.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-4-12 5 | * Time: 下午4:46 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'ui.uibase' ); 9 | test( '', function() { 10 | equal('','',''); 11 | } ); -------------------------------------------------------------------------------- /_test/ui/uiutils.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by JetBrains PhpStorm. 3 | * User: dongyancen 4 | * Date: 12-4-12 5 | * Time: 下午4:46 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | module( 'ui.uiutils' ); 9 | test( '', function() { 10 | equal('','',''); 11 | } ); -------------------------------------------------------------------------------- /_test/关键字.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/_test/关键字.txt -------------------------------------------------------------------------------- /dialogs/anchor/anchor.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 13 | 14 | 15 |
    16 | 17 |
    18 | 19 | 39 | 40 | -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_chm.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_chm.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_default.png -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_doc.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_doc.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_exe.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_exe.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_jpg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_jpg.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_mp3.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_mp3.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_mv.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_mv.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_pdf.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_pdf.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_ppt.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_ppt.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_psd.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_psd.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_rar.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_rar.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_txt.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_txt.gif -------------------------------------------------------------------------------- /dialogs/attachment/fileTypeImages/icon_xls.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/fileTypeImages/icon_xls.gif -------------------------------------------------------------------------------- /dialogs/attachment/images/alignicon.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/alignicon.gif -------------------------------------------------------------------------------- /dialogs/attachment/images/alignicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/alignicon.png -------------------------------------------------------------------------------- /dialogs/attachment/images/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/bg.png -------------------------------------------------------------------------------- /dialogs/attachment/images/file-icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/file-icons.gif -------------------------------------------------------------------------------- /dialogs/attachment/images/file-icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/file-icons.png -------------------------------------------------------------------------------- /dialogs/attachment/images/icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/icons.gif -------------------------------------------------------------------------------- /dialogs/attachment/images/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/icons.png -------------------------------------------------------------------------------- /dialogs/attachment/images/image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/image.png -------------------------------------------------------------------------------- /dialogs/attachment/images/progress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/progress.png -------------------------------------------------------------------------------- /dialogs/attachment/images/success.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/success.gif -------------------------------------------------------------------------------- /dialogs/attachment/images/success.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/attachment/images/success.png -------------------------------------------------------------------------------- /dialogs/background/images/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/background/images/bg.png -------------------------------------------------------------------------------- /dialogs/background/images/success.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/background/images/success.png -------------------------------------------------------------------------------- /dialogs/charts/chart.config.js: -------------------------------------------------------------------------------- 1 | /* 2 | * 图表配置文件 3 | * */ 4 | 5 | 6 | //不同类型的配置 7 | var typeConfig = [ 8 | { 9 | chart: { 10 | type: 'line' 11 | }, 12 | plotOptions: { 13 | line: { 14 | dataLabels: { 15 | enabled: false 16 | }, 17 | enableMouseTracking: true 18 | } 19 | } 20 | }, { 21 | chart: { 22 | type: 'line' 23 | }, 24 | plotOptions: { 25 | line: { 26 | dataLabels: { 27 | enabled: true 28 | }, 29 | enableMouseTracking: false 30 | } 31 | } 32 | }, { 33 | chart: { 34 | type: 'area' 35 | } 36 | }, { 37 | chart: { 38 | type: 'bar' 39 | } 40 | }, { 41 | chart: { 42 | type: 'column' 43 | } 44 | }, { 45 | chart: { 46 | plotBackgroundColor: null, 47 | plotBorderWidth: null, 48 | plotShadow: false 49 | }, 50 | plotOptions: { 51 | pie: { 52 | allowPointSelect: true, 53 | cursor: 'pointer', 54 | dataLabels: { 55 | enabled: true, 56 | color: '#000000', 57 | connectorColor: '#000000', 58 | formatter: function() { 59 | return ''+ this.point.name +': '+ ( Math.round( this.point.percentage*100 ) / 100 ) +' %'; 60 | } 61 | } 62 | } 63 | } 64 | } 65 | ]; 66 | -------------------------------------------------------------------------------- /dialogs/charts/images/charts0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/charts/images/charts0.png -------------------------------------------------------------------------------- /dialogs/charts/images/charts1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/charts/images/charts1.png -------------------------------------------------------------------------------- /dialogs/charts/images/charts2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/charts/images/charts2.png -------------------------------------------------------------------------------- /dialogs/charts/images/charts3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/charts/images/charts3.png -------------------------------------------------------------------------------- /dialogs/charts/images/charts4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/charts/images/charts4.png -------------------------------------------------------------------------------- /dialogs/charts/images/charts5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/charts/images/charts5.png -------------------------------------------------------------------------------- /dialogs/emotion/emotion.css: -------------------------------------------------------------------------------- 1 | .jd img{ 2 | background:transparent url(images/jxface2.gif?v=1.1) no-repeat scroll left top; 3 | cursor:pointer;width:35px;height:35px;display:block; 4 | } 5 | .pp img{ 6 | background:transparent url(images/fface.gif?v=1.1) no-repeat scroll left top; 7 | cursor:pointer;width:25px;height:25px;display:block; 8 | } 9 | .ldw img{ 10 | background:transparent url(images/wface.gif?v=1.1) no-repeat scroll left top; 11 | cursor:pointer;width:35px;height:35px;display:block; 12 | } 13 | .tsj img{ 14 | background:transparent url(images/tface.gif?v=1.1) no-repeat scroll left top; 15 | cursor:pointer;width:35px;height:35px;display:block; 16 | } 17 | .cat img{ 18 | background:transparent url(images/cface.gif?v=1.1) no-repeat scroll left top; 19 | cursor:pointer;width:35px;height:35px;display:block; 20 | } 21 | .bb img{ 22 | background:transparent url(images/bface.gif?v=1.1) no-repeat scroll left top; 23 | cursor:pointer;width:35px;height:35px;display:block; 24 | } 25 | .youa img{ 26 | background:transparent url(images/yface.gif?v=1.1) no-repeat scroll left top; 27 | cursor:pointer;width:35px;height:35px;display:block; 28 | } 29 | 30 | .smileytable td {height: 37px;} 31 | #tabPanel{margin-left:5px;overflow: hidden;} 32 | #tabContent {float:left;background:#FFFFFF;} 33 | #tabContent div{display: none;width:480px;overflow:hidden;} 34 | #tabIconReview.show{left:17px;display:block;} 35 | .menuFocus{background:#ACCD3C;} 36 | .menuDefault{background:#FFFFFF;} 37 | #tabIconReview{position:absolute;left:406px;left:398px \9;top:41px;z-index:65533;width:90px;height:76px;} 38 | img.review{width:90px;height:76px;border:2px solid #9cb945;background:#FFFFFF;background-position:center;background-repeat:no-repeat;} 39 | 40 | .wrapper .tabbody{position:relative;float:left;clear:both;padding:10px;width: 95%;} 41 | .tabbody table{width: 100%;} 42 | .tabbody td{border:1px solid #BAC498;} 43 | .tabbody td span{display: block;zoom:1;padding:0 4px;} -------------------------------------------------------------------------------- /dialogs/emotion/images/0.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/0.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/bface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/bface.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/cface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/cface.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/fface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/fface.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/jxface2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/jxface2.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/neweditor-tab-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/neweditor-tab-bg.png -------------------------------------------------------------------------------- /dialogs/emotion/images/tface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/tface.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/wface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/wface.gif -------------------------------------------------------------------------------- /dialogs/emotion/images/yface.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/emotion/images/yface.gif -------------------------------------------------------------------------------- /dialogs/help/help.css: -------------------------------------------------------------------------------- 1 | .wrapper{width: 370px;margin: 10px auto;zoom: 1;} 2 | .tabbody{height: 360px;} 3 | .tabbody .panel{width:100%;height: 360px;position: absolute;background: #fff;} 4 | .tabbody .panel h1{font-size:26px;margin: 5px 0 0 5px;} 5 | .tabbody .panel p{font-size:12px;margin: 5px 0 0 5px;} 6 | .tabbody table{width:90%;line-height: 20px;margin: 5px 0 0 5px;;} 7 | .tabbody table thead{font-weight: bold;line-height: 25px;} -------------------------------------------------------------------------------- /dialogs/help/help.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created with JetBrains PhpStorm. 3 | * User: xuheng 4 | * Date: 12-9-26 5 | * Time: 下午1:06 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | /** 9 | * tab点击处理事件 10 | * @param tabHeads 11 | * @param tabBodys 12 | * @param obj 13 | */ 14 | function clickHandler( tabHeads,tabBodys,obj ) { 15 | //head样式更改 16 | for ( var k = 0, len = tabHeads.length; k < len; k++ ) { 17 | tabHeads[k].className = ""; 18 | } 19 | obj.className = "focus"; 20 | //body显隐 21 | var tabSrc = obj.getAttribute( "tabSrc" ); 22 | for ( var j = 0, length = tabBodys.length; j < length; j++ ) { 23 | var body = tabBodys[j], 24 | id = body.getAttribute( "id" ); 25 | body.onclick = function(){ 26 | this.style.zoom = 1; 27 | }; 28 | if ( id != tabSrc ) { 29 | body.style.zIndex = 1; 30 | } else { 31 | body.style.zIndex = 200; 32 | } 33 | } 34 | 35 | } 36 | 37 | /** 38 | * TAB切换 39 | * @param tabParentId tab的父节点ID或者对象本身 40 | */ 41 | function switchTab( tabParentId ) { 42 | var tabElements = $G( tabParentId ).children, 43 | tabHeads = tabElements[0].children, 44 | tabBodys = tabElements[1].children; 45 | 46 | for ( var i = 0, length = tabHeads.length; i < length; i++ ) { 47 | var head = tabHeads[i]; 48 | if ( head.className === "focus" )clickHandler(tabHeads,tabBodys, head ); 49 | head.onclick = function () { 50 | clickHandler(tabHeads,tabBodys,this); 51 | } 52 | } 53 | } 54 | switchTab("helptab"); 55 | 56 | document.getElementById('version').innerHTML = parent.UE.version; -------------------------------------------------------------------------------- /dialogs/image/images/alignicon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/alignicon.jpg -------------------------------------------------------------------------------- /dialogs/image/images/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/bg.png -------------------------------------------------------------------------------- /dialogs/image/images/icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/icons.gif -------------------------------------------------------------------------------- /dialogs/image/images/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/icons.png -------------------------------------------------------------------------------- /dialogs/image/images/image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/image.png -------------------------------------------------------------------------------- /dialogs/image/images/progress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/progress.png -------------------------------------------------------------------------------- /dialogs/image/images/success.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/success.gif -------------------------------------------------------------------------------- /dialogs/image/images/success.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/image/images/success.png -------------------------------------------------------------------------------- /dialogs/music/music.css: -------------------------------------------------------------------------------- 1 | .wrapper{margin: 5px 10px;} 2 | 3 | .searchBar{height:30px;padding:7px 0 3px;text-align:center;} 4 | .searchBtn{font-size:13px;height:24px;} 5 | 6 | .resultBar{width:460px;margin:5px auto;border: 1px solid #CCC;border-radius: 5px;box-shadow: 2px 2px 5px #D3D6DA;overflow: hidden;} 7 | 8 | .listPanel{overflow: hidden;} 9 | .panelon{display:block;} 10 | .paneloff{display:none} 11 | 12 | .page{width:220px;margin:20px auto;overflow: hidden;} 13 | .pageon{float:right;width:24px;line-height:24px;height:24px;margin-right: 5px;background: none;border: none;color: #000;font-weight: bold;text-align:center} 14 | .pageoff{float:right;width:24px;line-height:24px;height:24px;cursor:pointer;background-color: #fff; 15 | border: 1px solid #E7ECF0;color: #2D64B3;margin-right: 5px;text-decoration: none;text-align:center;} 16 | 17 | .m-box{width:460px;} 18 | .m-m{float: left;line-height: 20px;height: 20px;} 19 | .m-h{height:24px;line-height:24px;padding-left: 46px;background-color:#FAFAFA;border-bottom: 1px solid #DAD8D8;font-weight: bold;font-size: 12px;color: #333;} 20 | .m-l{float:left;width:40px; } 21 | .m-t{float:left;width:140px;} 22 | .m-s{float:left;width:110px;} 23 | .m-z{float:left;width:100px;} 24 | .m-try-t{float: left;width: 60px;;} 25 | 26 | .m-try{float:left;width:20px;height:20px;background:url('http://static.tieba.baidu.com/tb/editor/images/try_music.gif') no-repeat ;} 27 | .m-trying{float:left;width:20px;height:20px;background:url('http://static.tieba.baidu.com/tb/editor/images/stop_music.gif') no-repeat ;} 28 | 29 | .loading{width:95px;height:7px;font-size:7px;margin:60px auto;background:url(http://static.tieba.baidu.com/tb/editor/images/loading.gif) no-repeat} 30 | .empty{width:300px;height:40px;padding:2px;margin:50px auto;line-height:40px; color:#006699;text-align:center;} -------------------------------------------------------------------------------- /dialogs/music/music.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 插入音乐 6 | 7 | 8 | 9 | 10 |
    11 | 15 |
    16 | 17 |
    18 |
    19 |
    20 |
    21 | 22 | 31 | 32 | -------------------------------------------------------------------------------- /dialogs/preview/preview.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 21 | 22 | 23 | 24 | 25 | 26 |
    27 | 28 |
    29 | 30 | 40 | -------------------------------------------------------------------------------- /dialogs/scrawl/images/addimg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/addimg.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/brush.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/brush.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/delimg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/delimg.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/delimgH.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/delimgH.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/empty.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/emptyH.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/emptyH.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/eraser.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/eraser.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/redo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/redo.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/redoH.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/redoH.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/scale.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/scale.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/scaleH.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/scaleH.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/size.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/size.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/undo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/undo.png -------------------------------------------------------------------------------- /dialogs/scrawl/images/undoH.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/scrawl/images/undoH.png -------------------------------------------------------------------------------- /dialogs/spechars/spechars.html: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 14 | 15 | 16 |
    17 |
    18 |
    19 | 20 | 21 | -------------------------------------------------------------------------------- /dialogs/table/dragicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/table/dragicon.png -------------------------------------------------------------------------------- /dialogs/table/edittable.css: -------------------------------------------------------------------------------- 1 | body{ 2 | overflow: hidden; 3 | width: 540px; 4 | } 5 | .wrapper { 6 | margin: 10px auto 0; 7 | font-size: 12px; 8 | overflow: hidden; 9 | width: 520px; 10 | height: 315px; 11 | } 12 | 13 | .clear { 14 | clear: both; 15 | } 16 | 17 | .wrapper .left { 18 | float: left; 19 | margin-left: 10px;; 20 | } 21 | 22 | .wrapper .right { 23 | float: right; 24 | border-left: 2px dotted #EDEDED; 25 | padding-left: 15px; 26 | } 27 | 28 | .section { 29 | margin-bottom: 15px; 30 | width: 240px; 31 | overflow: hidden; 32 | } 33 | 34 | .section h3 { 35 | font-weight: bold; 36 | padding: 5px 0; 37 | margin-bottom: 10px; 38 | border-bottom: 1px solid #EDEDED; 39 | font-size: 12px; 40 | } 41 | 42 | .section ul { 43 | list-style: none; 44 | overflow: hidden; 45 | clear: both; 46 | 47 | } 48 | 49 | .section li { 50 | float: left; 51 | width: 120px;; 52 | } 53 | 54 | .section .tone { 55 | width: 80px;; 56 | } 57 | 58 | .section .preview { 59 | width: 220px; 60 | } 61 | 62 | .section .preview table { 63 | text-align: center; 64 | vertical-align: middle; 65 | color: #666; 66 | } 67 | 68 | .section .preview caption { 69 | font-weight: bold; 70 | } 71 | 72 | .section .preview td { 73 | border-width: 1px; 74 | border-style: solid; 75 | height: 22px; 76 | } 77 | 78 | .section .preview th { 79 | border-style: solid; 80 | border-color: #DDD; 81 | border-width: 2px 1px 1px 1px; 82 | height: 22px; 83 | background-color: #F7F7F7; 84 | } -------------------------------------------------------------------------------- /dialogs/table/edittd.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 16 | 17 | 18 |
    19 | 20 | 21 |
    22 | 60 | 61 | -------------------------------------------------------------------------------- /dialogs/table/edittip.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 表格删除提示 5 | 6 | 17 | 18 | 19 |
    20 |
    21 | 22 |
    23 |
    24 | 25 |
    26 |
    27 | 32 | 33 | -------------------------------------------------------------------------------- /dialogs/template/images/bg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/template/images/bg.gif -------------------------------------------------------------------------------- /dialogs/template/images/pre0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/template/images/pre0.png -------------------------------------------------------------------------------- /dialogs/template/images/pre1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/template/images/pre1.png -------------------------------------------------------------------------------- /dialogs/template/images/pre2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/template/images/pre2.png -------------------------------------------------------------------------------- /dialogs/template/images/pre3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/template/images/pre3.png -------------------------------------------------------------------------------- /dialogs/template/images/pre4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/template/images/pre4.png -------------------------------------------------------------------------------- /dialogs/template/template.css: -------------------------------------------------------------------------------- 1 | .wrap{ padding: 5px;font-size: 14px;} 2 | .left{width:425px;float: left;} 3 | .right{width:160px;border: 1px solid #ccc;float: right;padding: 5px;margin-right: 5px;} 4 | .right .pre{height: 332px;overflow-y: auto;} 5 | .right .preitem{border: white 1px solid;margin: 5px 0;padding: 2px 0;} 6 | .right .preitem:hover{background-color: lemonChiffon;cursor: pointer;border: #ccc 1px solid;} 7 | .right .preitem img{display: block;margin: 0 auto;width:100px;} 8 | .clear{clear: both;} 9 | .top{height:26px;line-height: 26px;padding: 5px;} 10 | .bottom{height:320px;width:100%;margin: 0 auto;} 11 | .transparent{ background: url("images/bg.gif") repeat;} 12 | .bottom table tr td{border:1px dashed #ccc;} 13 | #colorPicker{width: 17px;height: 17px;border: 1px solid #CCC;display: inline-block;border-radius: 3px;box-shadow: 2px 2px 5px #D3D6DA;} 14 | .border_style1{padding:2px;border: 1px solid #ccc;border-radius: 5px;box-shadow:2px 2px 5px #d3d6da;} 15 | p{margin: 5px 0} 16 | table{clear:both;margin-bottom:10px;border-collapse:collapse;word-break:break-all;} 17 | li{clear:both} 18 | ol{padding-left:40px; } -------------------------------------------------------------------------------- /dialogs/template/template.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
    11 |
    12 |
    13 | 14 |
    15 |
    16 |
    17 |
    18 | 19 |
    20 |
    21 |
    22 |
    23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /dialogs/template/template.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created with JetBrains PhpStorm. 3 | * User: xuheng 4 | * Date: 12-8-8 5 | * Time: 下午2:09 6 | * To change this template use File | Settings | File Templates. 7 | */ 8 | (function () { 9 | var me = editor, 10 | preview = $G( "preview" ), 11 | preitem = $G( "preitem" ), 12 | tmps = templates, 13 | currentTmp; 14 | var initPre = function () { 15 | var str = ""; 16 | for ( var i = 0, tmp; tmp = tmps[i++]; ) { 17 | str += '
    '; 18 | } 19 | preitem.innerHTML = str; 20 | }; 21 | var pre = function ( n ) { 22 | var tmp = tmps[n - 1]; 23 | currentTmp = tmp; 24 | clearItem(); 25 | domUtils.setStyles( preitem.childNodes[n - 1], { 26 | "background-color":"lemonChiffon", 27 | "border":"#ccc 1px solid" 28 | } ); 29 | preview.innerHTML = tmp.preHtml ? tmp.preHtml : ""; 30 | }; 31 | var clearItem = function () { 32 | var items = preitem.children; 33 | for ( var i = 0, item; item = items[i++]; ) { 34 | domUtils.setStyles( item, { 35 | "background-color":"", 36 | "border":"white 1px solid" 37 | } ); 38 | } 39 | }; 40 | dialog.onok = function () { 41 | if ( !$G( "issave" ).checked ){ 42 | me.execCommand( "cleardoc" ); 43 | } 44 | var obj = { 45 | html:currentTmp && currentTmp.html 46 | }; 47 | me.execCommand( "template", obj ); 48 | }; 49 | initPre(); 50 | window.pre = pre; 51 | pre(2) 52 | 53 | })(); -------------------------------------------------------------------------------- /dialogs/video/images/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/bg.png -------------------------------------------------------------------------------- /dialogs/video/images/center_focus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/center_focus.jpg -------------------------------------------------------------------------------- /dialogs/video/images/file-icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/file-icons.gif -------------------------------------------------------------------------------- /dialogs/video/images/file-icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/file-icons.png -------------------------------------------------------------------------------- /dialogs/video/images/icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/icons.gif -------------------------------------------------------------------------------- /dialogs/video/images/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/icons.png -------------------------------------------------------------------------------- /dialogs/video/images/image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/image.png -------------------------------------------------------------------------------- /dialogs/video/images/left_focus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/left_focus.jpg -------------------------------------------------------------------------------- /dialogs/video/images/none_focus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/none_focus.jpg -------------------------------------------------------------------------------- /dialogs/video/images/progress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/progress.png -------------------------------------------------------------------------------- /dialogs/video/images/right_focus.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/right_focus.jpg -------------------------------------------------------------------------------- /dialogs/video/images/success.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/success.gif -------------------------------------------------------------------------------- /dialogs/video/images/success.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/video/images/success.png -------------------------------------------------------------------------------- /dialogs/wordimage/fClipboard_ueditor.swf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/wordimage/fClipboard_ueditor.swf -------------------------------------------------------------------------------- /dialogs/wordimage/imageUploader.swf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/dialogs/wordimage/imageUploader.swf -------------------------------------------------------------------------------- /lang/en/images/addimage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/addimage.png -------------------------------------------------------------------------------- /lang/en/images/alldeletebtnhoverskin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/alldeletebtnhoverskin.png -------------------------------------------------------------------------------- /lang/en/images/alldeletebtnupskin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/alldeletebtnupskin.png -------------------------------------------------------------------------------- /lang/en/images/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/background.png -------------------------------------------------------------------------------- /lang/en/images/button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/button.png -------------------------------------------------------------------------------- /lang/en/images/copy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/copy.png -------------------------------------------------------------------------------- /lang/en/images/deletedisable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/deletedisable.png -------------------------------------------------------------------------------- /lang/en/images/deleteenable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/deleteenable.png -------------------------------------------------------------------------------- /lang/en/images/listbackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/listbackground.png -------------------------------------------------------------------------------- /lang/en/images/localimage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/localimage.png -------------------------------------------------------------------------------- /lang/en/images/music.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/music.png -------------------------------------------------------------------------------- /lang/en/images/rotateleftdisable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/rotateleftdisable.png -------------------------------------------------------------------------------- /lang/en/images/rotateleftenable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/rotateleftenable.png -------------------------------------------------------------------------------- /lang/en/images/rotaterightdisable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/rotaterightdisable.png -------------------------------------------------------------------------------- /lang/en/images/rotaterightenable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/rotaterightenable.png -------------------------------------------------------------------------------- /lang/en/images/upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/en/images/upload.png -------------------------------------------------------------------------------- /lang/zh-cn/images/copy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/zh-cn/images/copy.png -------------------------------------------------------------------------------- /lang/zh-cn/images/localimage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/zh-cn/images/localimage.png -------------------------------------------------------------------------------- /lang/zh-cn/images/music.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/zh-cn/images/music.png -------------------------------------------------------------------------------- /lang/zh-cn/images/upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/lang/zh-cn/images/upload.png -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ueditor", 3 | "title": "ueditor", 4 | "description": "UEditor富文本web编辑器", 5 | "version": "2.0.0", 6 | "homepage": "http://ueditor.baidu.com/", 7 | "author": { 8 | "name": "f-cube @ FEX", 9 | "url": "http://fex.baidu.com" 10 | }, 11 | "repository": { 12 | "type": "git", 13 | "url": "https://github.com/fex-team/ueditor.git" 14 | }, 15 | "keywords": [ 16 | "ueditor", 17 | "web editor", 18 | "javascript", 19 | "rich editor" 20 | ], 21 | "bugs": { 22 | "url": "https://github.com/fex-team/ueditor/issues" 23 | }, 24 | "dependencies": { 25 | "grunt": "~0.4.1", 26 | "grunt-contrib-clean": "~0.5.0", 27 | "grunt-contrib-concat": "~0.3.0", 28 | "grunt-contrib-copy": "~0.4.0", 29 | "grunt-contrib-cssmin": "~0.6.0", 30 | "grunt-contrib-uglify": "^1.0.1", 31 | "grunt-text-replace": "~0.3.9", 32 | "grunt-transcoding": "~0.1.1" 33 | }, 34 | "devDependencies": { 35 | "grunt": "~0.4.1" 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /themes/default/_css/autotypesetpicker.css: -------------------------------------------------------------------------------- 1 | /*自动排版弹出菜单*/ 2 | .edui-default .edui-autotypesetpicker .edui-autotypesetpicker-body { 3 | font-size: 12px; 4 | margin-bottom: 3px; 5 | clear: both; 6 | } 7 | 8 | .edui-default .edui-autotypesetpicker-body table { 9 | border-collapse: separate; 10 | border-spacing: 2px; 11 | } 12 | 13 | .edui-default .edui-autotypesetpicker-body td { 14 | font-size: 12px; 15 | word-wrap:break-word; 16 | } 17 | 18 | .edui-default .edui-autotypesetpicker-body td input { 19 | margin: 3px 3px 3px 4px; 20 | *margin: 1px 0 0 0; 21 | } -------------------------------------------------------------------------------- /themes/default/_css/button.css: -------------------------------------------------------------------------------- 1 | /*普通按钮样式及状态*/ 2 | .edui-default .edui-toolbar .edui-button .edui-icon, 3 | .edui-default .edui-toolbar .edui-menubutton .edui-icon, 4 | .edui-default .edui-toolbar .edui-splitbutton .edui-icon { 5 | height: 20px !important; 6 | width: 20px !important; 7 | background-image: url(../images/icons.png); 8 | background-image: url(../images/icons.gif) \9; 9 | } 10 | 11 | .edui-default .edui-toolbar .edui-button .edui-button-wrap { 12 | padding: 1px; 13 | position: relative; 14 | } 15 | 16 | .edui-default .edui-toolbar .edui-button .edui-state-hover .edui-button-wrap { 17 | background-color: #fff5d4; 18 | padding: 0; 19 | border: 1px solid #dcac6c; 20 | } 21 | 22 | .edui-default .edui-toolbar .edui-button .edui-state-checked .edui-button-wrap { 23 | background-color: #ffe69f; 24 | padding: 0; 25 | border: 1px solid #dcac6c; 26 | border-radius: 2px; 27 | -webkit-border-radius: 2px; 28 | -moz-border-radius: 2px; 29 | } 30 | 31 | .edui-default .edui-toolbar .edui-button .edui-state-active .edui-button-wrap { 32 | background-color: #ffffff; 33 | padding: 0; 34 | border: 1px solid gray; 35 | } 36 | .edui-default .edui-toolbar .edui-state-disabled .edui-label { 37 | color: #ccc; 38 | } 39 | .edui-default .edui-toolbar .edui-state-disabled .edui-icon { 40 | opacity: 0.3; 41 | filter: alpha(opacity = 30); 42 | } 43 | -------------------------------------------------------------------------------- /themes/default/_css/cellalignpicker.css: -------------------------------------------------------------------------------- 1 | /*自动排版弹出菜单*/ 2 | .edui-default .edui-cellalignpicker .edui-cellalignpicker-body { 3 | width: 70px; 4 | font-size: 12px; 5 | cursor: default; 6 | } 7 | 8 | .edui-default .edui-cellalignpicker-body table { 9 | border-collapse: separate; 10 | border-spacing: 0; 11 | } 12 | .edui-default .edui-cellalignpicker-body td{ 13 | padding: 1px; 14 | } 15 | .edui-default .edui-cellalignpicker-body .edui-icon{ 16 | height: 20px; 17 | width: 20px; 18 | padding: 1px; 19 | background-image: url(../images/table-cell-align.png); 20 | } 21 | 22 | .edui-default .edui-cellalignpicker-body .edui-left{ 23 | background-position: 0 0; 24 | } 25 | 26 | .edui-default .edui-cellalignpicker-body .edui-center{ 27 | background-position: -25px 0; 28 | } 29 | .edui-default .edui-cellalignpicker-body .edui-right{ 30 | background-position: -51px 0; 31 | } 32 | 33 | .edui-default .edui-cellalignpicker-body td.edui-state-hover .edui-left{ 34 | background-position: -73px 0; 35 | } 36 | 37 | .edui-default .edui-cellalignpicker-body td.edui-state-hover .edui-center{ 38 | background-position: -98px 0; 39 | } 40 | 41 | .edui-default .edui-cellalignpicker-body td.edui-state-hover .edui-right{ 42 | background-position: -124px 0; 43 | } 44 | 45 | .edui-default .edui-cellalignpicker-body td.edui-cellalign-selected .edui-left { 46 | background-position: -146px 0; 47 | background-color: #f1f4f5; 48 | } 49 | 50 | .edui-default .edui-cellalignpicker-body td.edui-cellalign-selected .edui-center { 51 | background-position: -245px 0; 52 | } 53 | 54 | .edui-default .edui-cellalignpicker-body td.edui-cellalign-selected .edui-right { 55 | background-position: -271px 0; 56 | } -------------------------------------------------------------------------------- /themes/default/_css/colorbutton.css: -------------------------------------------------------------------------------- 1 | /*颜色按钮 */ 2 | .edui-default .edui-toolbar .edui-colorbutton .edui-colorlump { 3 | position: absolute; 4 | overflow: hidden; 5 | bottom: 1px; 6 | left: 1px; 7 | width: 18px; 8 | height: 4px; 9 | } -------------------------------------------------------------------------------- /themes/default/_css/combox.css: -------------------------------------------------------------------------------- 1 | /*不可选中菜单按钮 */ 2 | .edui-default .edui-toolbar .edui-combox-body .edui-button-body { 3 | width: 60px; 4 | font-size: 12px; 5 | height: 20px; 6 | line-height: 20px; 7 | padding-left: 5px; 8 | white-space: nowrap; 9 | margin: 0 3px 0 0; 10 | } 11 | 12 | .edui-default .edui-toolbar .edui-combox-body .edui-arrow { 13 | background: url(../images/icons.png) -741px 0; 14 | _background: url(../images/icons.gif) -741px 0; 15 | height: 20px; 16 | width: 9px; 17 | } 18 | 19 | .edui-default .edui-toolbar .edui-combox .edui-combox-body { 20 | border: 1px solid #CCC; 21 | background-color: white; 22 | border-radius: 2px; 23 | -webkit-border-radius: 2px; 24 | -moz-border-radius: 2px; 25 | } 26 | 27 | .edui-default .edui-toolbar .edui-combox-body .edui-splitborder { 28 | display: none; 29 | } 30 | 31 | .edui-default .edui-toolbar .edui-combox-body .edui-arrow { 32 | border-left: 1px solid #CCC; 33 | } 34 | 35 | .edui-default .edui-toolbar .edui-state-hover .edui-combox-body { 36 | background-color: #fff5d4; 37 | border: 1px solid #dcac6c; 38 | } 39 | 40 | .edui-default .edui-toolbar .edui-state-hover .edui-combox-body .edui-arrow { 41 | border-left: 1px solid #dcac6c; 42 | } 43 | 44 | .edui-default .edui-toolbar .edui-state-checked .edui-combox-body { 45 | background-color: #FFE69F; 46 | border: 1px solid #DCAC6C; 47 | } 48 | 49 | .edui-toolbar .edui-state-checked .edui-combox-body .edui-arrow { 50 | border-left: 1px solid #DCAC6C; 51 | } 52 | 53 | .edui-toolbar .edui-state-disabled .edui-combox-body { 54 | background-color: #F0F0EE; 55 | opacity: 0.3; 56 | filter: alpha(opacity = 30); 57 | } 58 | 59 | .edui-toolbar .edui-state-opened .edui-combox-body { 60 | background-color: white; 61 | border: 1px solid gray; 62 | } -------------------------------------------------------------------------------- /themes/default/_css/contextmenu.css: -------------------------------------------------------------------------------- 1 | /*contextmenu*/ 2 | .edui-default .edui-hassubmenu .edui-arrow { 3 | height: 20px; 4 | width: 20px; 5 | float: right; 6 | background: url("../images/icons-all.gif") no-repeat 10px -233px; 7 | } 8 | 9 | .edui-default .edui-menu-body .edui-menuitem { 10 | padding: 1px; 11 | } 12 | 13 | .edui-default .edui-menuseparator { 14 | margin: 2px 0; 15 | height: 1px; 16 | overflow: hidden; 17 | } 18 | 19 | .edui-default .edui-menuseparator-inner { 20 | border-bottom: 1px solid #e2e3e3; 21 | margin-left: 29px; 22 | margin-right: 1px; 23 | } 24 | 25 | .edui-default .edui-menu-body .edui-state-hover { 26 | padding: 0 !important; 27 | background-color: #fff5d4; 28 | border: 1px solid #dcac6c; 29 | } -------------------------------------------------------------------------------- /themes/default/_css/menu.css: -------------------------------------------------------------------------------- 1 | /* 可选中按钮弹出菜单*/ 2 | .edui-default .edui-menu { 3 | z-index: 3000; 4 | } 5 | 6 | .edui-default .edui-menu .edui-popup-content { 7 | padding: 3px; 8 | } 9 | 10 | .edui-default .edui-menu-body { 11 | _width: 150px; 12 | min-width: 170px; 13 | background: url("../images/sparator_v.png") repeat-y 25px; 14 | } 15 | 16 | .edui-default .edui-menuitem-body { 17 | } 18 | 19 | .edui-default .edui-menuitem { 20 | height: 20px; 21 | cursor: default; 22 | vertical-align: top; 23 | } 24 | 25 | .edui-default .edui-menuitem .edui-icon { 26 | width: 20px !important; 27 | height: 20px !important; 28 | background: url(../images/icons.png) 0 -4000px; 29 | background: url(../images/icons.gif) 0 -4000px\9; 30 | } 31 | 32 | .edui-default .edui-menuitem .edui-label { 33 | font-size: 12px; 34 | line-height: 20px; 35 | height: 20px; 36 | padding-left: 10px; 37 | } 38 | 39 | .edui-default .edui-state-checked .edui-menuitem-body { 40 | background: url("../images/icons-all.gif") no-repeat 6px -205px; 41 | } 42 | 43 | .edui-default .edui-state-disabled .edui-menuitem-label { 44 | color: gray; 45 | } 46 | 47 | -------------------------------------------------------------------------------- /themes/default/_css/menubutton.css: -------------------------------------------------------------------------------- 1 | /*可选中菜单按钮*/ 2 | .edui-default .edui-list .edui-bordereraser { 3 | display: none; 4 | } 5 | 6 | .edui-default .edui-listitem { 7 | padding: 1px; 8 | white-space: nowrap; 9 | } 10 | 11 | .edui-default .edui-list .edui-state-hover { 12 | position: relative; 13 | background-color: #fff5d4; 14 | border: 1px solid #dcac6c; 15 | padding: 0; 16 | } 17 | 18 | .edui-default .edui-for-fontfamily .edui-listitem-label { 19 | min-width: 130px; 20 | _width: 120px; 21 | font-size: 12px; 22 | height: 22px; 23 | line-height: 22px; 24 | padding-left: 5px; 25 | } 26 | .edui-default .edui-for-insertcode .edui-listitem-label { 27 | min-width: 120px; 28 | _width: 120px; 29 | font-size: 12px; 30 | height: 22px; 31 | line-height: 22px; 32 | padding-left: 5px; 33 | } 34 | .edui-default .edui-for-underline .edui-listitem-label { 35 | min-width: 120px; 36 | _width: 120px; 37 | padding: 3px 5px; 38 | font-size: 12px; 39 | } 40 | 41 | .edui-default .edui-for-fontsize .edui-listitem-label { 42 | min-width: 120px; 43 | _width: 120px; 44 | padding: 3px 5px; 45 | 46 | } 47 | 48 | .edui-default .edui-for-paragraph .edui-listitem-label { 49 | min-width: 200px; 50 | _width: 200px; 51 | padding: 2px 5px; 52 | } 53 | 54 | .edui-default .edui-for-rowspacingtop .edui-listitem-label, 55 | .edui-default .edui-for-rowspacingbottom .edui-listitem-label { 56 | min-width: 53px; 57 | _width: 53px; 58 | padding: 2px 5px; 59 | } 60 | 61 | .edui-default .edui-for-lineheight .edui-listitem-label { 62 | min-width: 53px; 63 | _width: 53px; 64 | padding: 2px 5px; 65 | } 66 | 67 | .edui-default .edui-for-customstyle .edui-listitem-label { 68 | min-width: 200px; 69 | _width: 200px; 70 | width: 200px !important; 71 | padding: 2px 5px; 72 | } -------------------------------------------------------------------------------- /themes/default/_css/message.css: -------------------------------------------------------------------------------- 1 | .edui-default .edui-editor-messageholder { 2 | display: block; 3 | width: 150px; 4 | height: auto; 5 | border: 0; 6 | margin: 0; 7 | padding: 0; 8 | position: absolute; 9 | top: 28px; 10 | right: 3px; 11 | } 12 | 13 | .edui-default .edui-message{ 14 | min-height: 10px; 15 | text-shadow: 0 1px 0 rgba(255,255,255,0.5); 16 | padding: 0; 17 | margin-bottom: 3px; 18 | position: relative; 19 | } 20 | .edui-default .edui-message-body{ 21 | border-radius: 3px; 22 | padding: 8px 15px 8px 8px; 23 | color: #c09853; 24 | background-color: #fcf8e3; 25 | border: 1px solid #fbeed5; 26 | } 27 | .edui-default .edui-message-type-info{ 28 | color: #3a87ad; 29 | background-color: #d9edf7; 30 | border-color: #bce8f1 31 | } 32 | .edui-default .edui-message-type-success{ 33 | color: #468847; 34 | background-color: #dff0d8; 35 | border-color: #d6e9c6 36 | } 37 | .edui-default .edui-message-type-danger, 38 | .edui-default .edui-message-type-error{ 39 | color: #b94a48; 40 | background-color: #f2dede; 41 | border-color: #eed3d7 42 | } 43 | .edui-default .edui-message .edui-message-closer { 44 | display: block; 45 | width: 16px; 46 | height: 16px; 47 | line-height: 16px; 48 | position: absolute; 49 | top: 0; 50 | right: 0; 51 | padding: 0; 52 | cursor: pointer; 53 | background: transparent; 54 | border: 0; 55 | float: right; 56 | font-size: 20px; 57 | font-weight: bold; 58 | color: #999; 59 | text-shadow: 0 1px 0 #fff; 60 | font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; 61 | } 62 | .edui-default .edui-message .edui-message-content { 63 | font-size: 10pt; 64 | word-wrap: break-word; 65 | word-break: normal; 66 | } -------------------------------------------------------------------------------- /themes/default/_css/multiMenu.css: -------------------------------------------------------------------------------- 1 | /*表情按钮及弹出菜单*/ 2 | /*去除了表情的下拉箭头*/ 3 | .edui-default .edui-for-emotion .edui-icon { 4 | background-position: -60px -20px; 5 | } 6 | .edui-default .edui-for-emotion .edui-popup-content iframe 7 | { 8 | width: 514px; 9 | height: 380px; 10 | overflow: hidden; 11 | } 12 | .edui-default .edui-for-emotion .edui-popup-content 13 | { 14 | position: relative; 15 | z-index: 555 16 | } 17 | 18 | .edui-default .edui-for-emotion .edui-splitborder { 19 | display: none 20 | } 21 | 22 | .edui-default .edui-for-emotion .edui-splitbutton-body .edui-arrow 23 | { 24 | width: 0 25 | } 26 | .edui-default .edui-toolbar .edui-for-emotion .edui-state-active .edui-splitborder 27 | { 28 | border-left: 1px solid transparent; 29 | } -------------------------------------------------------------------------------- /themes/default/_css/paragraphpicker.css: -------------------------------------------------------------------------------- 1 | /*段落弹出菜单*/ 2 | .edui-default .edui-for-paragraph .edui-listitem-label { 3 | font-family: Tahoma, Verdana, Arial, Helvetica; 4 | } 5 | 6 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-p { 7 | font-size: 22px; 8 | line-height: 27px; 9 | } 10 | 11 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-h1 { 12 | font-weight: bolder; 13 | font-size: 32px; 14 | line-height: 36px; 15 | } 16 | 17 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-h2 { 18 | font-weight: bolder; 19 | font-size: 27px; 20 | line-height: 29px; 21 | } 22 | 23 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-h3 { 24 | font-weight: bolder; 25 | font-size: 19px; 26 | line-height: 23px; 27 | } 28 | 29 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-h4 { 30 | font-weight: bolder; 31 | font-size: 16px; 32 | line-height: 19px 33 | } 34 | 35 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-h5 { 36 | font-weight: bolder; 37 | font-size: 13px; 38 | line-height: 16px; 39 | } 40 | 41 | .edui-default .edui-for-paragraph .edui-listitem-label .edui-for-h6 { 42 | font-weight: bolder; 43 | font-size: 12px; 44 | line-height: 14px; 45 | } -------------------------------------------------------------------------------- /themes/default/_css/popup.css: -------------------------------------------------------------------------------- 1 | /* 弹出菜单 */ 2 | .edui-default .edui-popup { 3 | z-index: 3000; 4 | background-color: #ffffff; 5 | width:auto; 6 | height:auto; 7 | -webkit-border-radius: 6px; 8 | -moz-border-radius: 6px; 9 | border-radius: 6px; 10 | } 11 | 12 | .edui-default .edui-popup .edui-shadow { 13 | left: 0; 14 | top: 0; 15 | width: 100%; 16 | height: 100%; 17 | } 18 | 19 | .edui-default .edui-popup-content { 20 | border:1px solid #ccc; 21 | border: 1px solid rgba(0, 0, 0, 0.2); 22 | *border-right-width: 2px; 23 | *border-bottom-width: 2px; 24 | -webkit-border-radius: 6px; 25 | -moz-border-radius: 6px; 26 | border-radius: 6px; 27 | -webkit-box-shadow: 0 3px 4px rgba(0, 0, 0, 0.2); 28 | -moz-box-shadow: 0 3px 4px rgba(0, 0, 0, 0.2); 29 | box-shadow: 0 3px 4px rgba(0, 0, 0, 0.2); 30 | -webkit-background-clip: padding-box; 31 | -moz-background-clip: padding; 32 | background-clip: padding-box; 33 | padding: 5px; 34 | background:#ffffff; 35 | } 36 | 37 | .edui-default .edui-popup .edui-bordereraser { 38 | background-color: white; 39 | height: 3px; 40 | } 41 | 42 | .edui-default .edui-menu .edui-bordereraser { 43 | height: 3px; 44 | } 45 | 46 | .edui-default .edui-anchor-topleft .edui-bordereraser { 47 | left: 1px; 48 | top: -2px; 49 | } 50 | 51 | .edui-default .edui-anchor-topright .edui-bordereraser { 52 | right: 1px; 53 | top: -2px; 54 | } 55 | 56 | .edui-default .edui-anchor-bottomleft .edui-bordereraser { 57 | left: 0; 58 | bottom: -6px; 59 | height: 7px; 60 | border-left: 1px solid gray; 61 | border-right: 1px solid gray; 62 | } 63 | 64 | .edui-default .edui-anchor-bottomright .edui-bordereraser { 65 | right: 0; 66 | bottom: -6px; 67 | height: 7px; 68 | border-left: 1px solid gray; 69 | border-right: 1px solid gray; 70 | } 71 | 72 | .edui-popup div{ 73 | width:auto; 74 | height:auto; 75 | } -------------------------------------------------------------------------------- /themes/default/_css/separtor.css: -------------------------------------------------------------------------------- 1 | /*分隔线*/ 2 | .edui-default .edui-toolbar .edui-separator { 3 | width: 2px; 4 | height: 20px; 5 | margin: 2px 4px 2px 3px; 6 | background: url(../images/icons.png) -181px 0; 7 | background: url(../images/icons.gif) -181px 0 \9; 8 | } 9 | -------------------------------------------------------------------------------- /themes/default/_css/shortcutmenu.css: -------------------------------------------------------------------------------- 1 | /*弹出菜单*/ 2 | .edui-default .edui-shortcutmenu { 3 | padding: 2px; 4 | width: 190px; 5 | height: 50px; 6 | background-color: #fff; 7 | border: 1px solid #ccc; 8 | border-radius: 5px; 9 | } 10 | -------------------------------------------------------------------------------- /themes/default/_css/tablepicker.css: -------------------------------------------------------------------------------- 1 | /* 表格弹出菜单 */ 2 | .edui-default .edui-for-inserttable .edui-splitborder { 3 | display: none 4 | } 5 | .edui-default .edui-for-inserttable .edui-splitbutton-body .edui-arrow { 6 | width: 0 7 | } 8 | .edui-default .edui-toolbar .edui-for-inserttable .edui-state-active .edui-splitborder{ 9 | border-left: 1px solid transparent; 10 | } 11 | .edui-default .edui-tablepicker .edui-infoarea { 12 | height: 14px; 13 | line-height: 14px; 14 | font-size: 12px; 15 | width: 220px; 16 | margin-bottom: 3px; 17 | clear: both; 18 | } 19 | 20 | .edui-default .edui-tablepicker .edui-infoarea .edui-label { 21 | float: left; 22 | } 23 | 24 | .edui-default .edui-dialog-buttons .edui-label { 25 | line-height: 24px; 26 | } 27 | 28 | .edui-default .edui-tablepicker .edui-infoarea .edui-clickable { 29 | float: right; 30 | } 31 | 32 | .edui-default .edui-tablepicker .edui-pickarea { 33 | background: url("../images/unhighlighted.gif") repeat; 34 | height: 220px; 35 | width: 220px; 36 | } 37 | 38 | .edui-default .edui-tablepicker .edui-pickarea .edui-overlay { 39 | background: url("../images/highlighted.gif") repeat; 40 | } 41 | -------------------------------------------------------------------------------- /themes/default/_css/toolbar.css: -------------------------------------------------------------------------------- 1 | /* 工具栏 */ 2 | .edui-default .edui-toolbar { 3 | cursor: default; 4 | -webkit-user-select: none; 5 | -moz-user-select: none; 6 | padding: 1px; 7 | overflow: hidden; /*全屏下单独一行不占位*/ 8 | zoom: 1; 9 | width:auto; 10 | height:auto; 11 | } 12 | 13 | .edui-default .edui-toolbar .edui-button, 14 | .edui-default .edui-toolbar .edui-splitbutton, 15 | .edui-default .edui-toolbar .edui-menubutton, 16 | .edui-default .edui-toolbar .edui-combox { 17 | margin: 1px; 18 | } -------------------------------------------------------------------------------- /themes/default/_css/ueditor.css: -------------------------------------------------------------------------------- 1 | /*根据UI结构重写CSS,仅在相应UI组件创建时,加载对应css,顺序加载 2 | */ 3 | 4 | /*-------基础UI构建,必须加载-------*/ 5 | @import "uibase.css"; 6 | @import "toolbar.css"; 7 | @import "editor.css"; 8 | 9 | 10 | /*-------可选中菜单按钮,按需加载-------*/ 11 | /*可选中菜单按钮--依赖splitbutton*/ 12 | @import "menubutton.css"; 13 | /*可选中菜单按钮-弹出菜单*/ 14 | @import "menu.css"; 15 | 16 | 17 | /*-------不可选中菜单按钮,按需加载-------*/ 18 | /*不可选中菜单按钮--依赖splitbutton*/ 19 | @import "combox.css"; 20 | 21 | 22 | /*-------按钮类型,按需加载-------*/ 23 | /*普通按钮*/ 24 | @import "button.css"; 25 | /*按钮icon*/ 26 | @import "buttonicon.css"; 27 | /*弹出菜单按钮-附加按钮*/ 28 | @import "splitbutton.css"; 29 | /*弹出菜单*/ 30 | @import "popup.css"; 31 | /*提示消息*/ 32 | @import "message.css"; 33 | 34 | 35 | /*-------独立按钮样式,按需加载-------*/ 36 | /*弹出对话框样式*/ 37 | @import "dialog.css"; 38 | /*段落格式弹出菜单*/ 39 | @import "paragraphpicker.css"; 40 | /*表格弹出菜单*/ 41 | @import "tablepicker.css"; 42 | /*颜色弹出菜单*/ 43 | @import "colorpicker.css"; 44 | /*自动排版弹出菜单*/ 45 | @import "autotypesetpicker.css"; 46 | /*平均分布菜单*/ 47 | @import "cellalignpicker.css"; 48 | /*分隔线*/ 49 | @import "separtor.css"; 50 | /*颜色按钮--依赖splitbutton*/ 51 | @import "colorbutton.css"; 52 | /*表情按钮--依赖splitbutton*/ 53 | @import "multiMenu.css"; 54 | /*右键菜单*/ 55 | @import "contextmenu.css"; 56 | /*快捷菜单*/ 57 | @import "shortcutmenu.css"; 58 | /*粘贴提示*/ 59 | @import "pastepicker.css"; -------------------------------------------------------------------------------- /themes/default/images/anchor.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/anchor.gif -------------------------------------------------------------------------------- /themes/default/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/arrow.png -------------------------------------------------------------------------------- /themes/default/images/arrow_down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/arrow_down.png -------------------------------------------------------------------------------- /themes/default/images/arrow_up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/arrow_up.png -------------------------------------------------------------------------------- /themes/default/images/button-bg.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/button-bg.gif -------------------------------------------------------------------------------- /themes/default/images/cancelbutton.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/cancelbutton.gif -------------------------------------------------------------------------------- /themes/default/images/charts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/charts.png -------------------------------------------------------------------------------- /themes/default/images/cursor_h.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/cursor_h.gif -------------------------------------------------------------------------------- /themes/default/images/cursor_h.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/cursor_h.png -------------------------------------------------------------------------------- /themes/default/images/cursor_v.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/cursor_v.gif -------------------------------------------------------------------------------- /themes/default/images/cursor_v.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/cursor_v.png -------------------------------------------------------------------------------- /themes/default/images/dialog-title-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/dialog-title-bg.png -------------------------------------------------------------------------------- /themes/default/images/filescan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/filescan.png -------------------------------------------------------------------------------- /themes/default/images/highlighted.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/highlighted.gif -------------------------------------------------------------------------------- /themes/default/images/icons-all.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/icons-all.gif -------------------------------------------------------------------------------- /themes/default/images/icons.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/icons.gif -------------------------------------------------------------------------------- /themes/default/images/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/icons.png -------------------------------------------------------------------------------- /themes/default/images/img-cracked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/img-cracked.png -------------------------------------------------------------------------------- /themes/default/images/loaderror.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/loaderror.png -------------------------------------------------------------------------------- /themes/default/images/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/loading.gif -------------------------------------------------------------------------------- /themes/default/images/lock.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/lock.gif -------------------------------------------------------------------------------- /themes/default/images/neweditor-tab-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/neweditor-tab-bg.png -------------------------------------------------------------------------------- /themes/default/images/pagebreak.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/pagebreak.gif -------------------------------------------------------------------------------- /themes/default/images/scale.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/scale.png -------------------------------------------------------------------------------- /themes/default/images/sortable.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/sortable.png -------------------------------------------------------------------------------- /themes/default/images/spacer.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/spacer.gif -------------------------------------------------------------------------------- /themes/default/images/sparator_v.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/sparator_v.png -------------------------------------------------------------------------------- /themes/default/images/table-cell-align.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/table-cell-align.png -------------------------------------------------------------------------------- /themes/default/images/tangram-colorpicker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/tangram-colorpicker.png -------------------------------------------------------------------------------- /themes/default/images/toolbar_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/toolbar_bg.png -------------------------------------------------------------------------------- /themes/default/images/unhighlighted.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/unhighlighted.gif -------------------------------------------------------------------------------- /themes/default/images/upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/upload.png -------------------------------------------------------------------------------- /themes/default/images/videologo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/videologo.gif -------------------------------------------------------------------------------- /themes/default/images/word.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/word.gif -------------------------------------------------------------------------------- /themes/default/images/wordpaste.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/themes/default/images/wordpaste.png -------------------------------------------------------------------------------- /themes/iframe.css: -------------------------------------------------------------------------------- 1 | /*可以在这里添加你自己的css*/ 2 | -------------------------------------------------------------------------------- /third-party/highcharts/modules/funnel.js: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Highcharts funnel module, Beta 4 | 5 | (c) 2010-2012 Torstein Hønsi 6 | 7 | License: www.highcharts.com/license 8 | */ 9 | (function(d){var u=d.getOptions().plotOptions,p=d.seriesTypes,D=d.merge,z=function(){},A=d.each;u.funnel=D(u.pie,{center:["50%","50%"],width:"90%",neckWidth:"30%",height:"100%",neckHeight:"25%",dataLabels:{connectorWidth:1,connectorColor:"#606060"},size:!0,states:{select:{color:"#C0C0C0",borderColor:"#000000",shadow:!1}}});p.funnel=d.extendClass(p.pie,{type:"funnel",animate:z,translate:function(){var a=function(k,a){return/%$/.test(k)?a*parseInt(k,10)/100:parseInt(k,10)},g=0,e=this.chart,f=e.plotWidth, 10 | e=e.plotHeight,h=0,c=this.options,C=c.center,b=a(C[0],f),d=a(C[0],e),p=a(c.width,f),i,q,j=a(c.height,e),r=a(c.neckWidth,f),s=a(c.neckHeight,e),v=j-s,a=this.data,w,x,u=c.dataLabels.position==="left"?1:0,y,m,B,n,l,t,o;this.getWidthAt=q=function(k){return k>j-s||j===s?r:r+(p-r)*((j-s-k)/(j-s))};this.getX=function(k,a){return b+(a?-1:1)*(q(k)/2+c.dataLabels.distance)};this.center=[b,d,j];this.centerX=b;A(a,function(a){g+=a.y});A(a,function(a){o=null;x=g?a.y/g:0;m=d-j/2+h*j;l=m+x*j;i=q(m);y=b-i/2;B=y+ 11 | i;i=q(l);n=b-i/2;t=n+i;m>v?(y=n=b-r/2,B=t=b+r/2):l>v&&(o=l,i=q(v),n=b-i/2,t=n+i,l=v);w=["M",y,m,"L",B,m,t,l];o&&w.push(t,o,n,o);w.push(n,l,"Z");a.shapeType="path";a.shapeArgs={d:w};a.percentage=x*100;a.plotX=b;a.plotY=(m+(o||l))/2;a.tooltipPos=[b,a.plotY];a.slice=z;a.half=u;h+=x});this.setTooltipPoints()},drawPoints:function(){var a=this,g=a.options,e=a.chart.renderer;A(a.data,function(f){var h=f.graphic,c=f.shapeArgs;h?h.animate(c):f.graphic=e.path(c).attr({fill:f.color,stroke:g.borderColor,"stroke-width":g.borderWidth}).add(a.group)})}, 12 | sortByAngle:z,drawDataLabels:function(){var a=this.data,g=this.options.dataLabels.distance,e,f,h,c=a.length,d,b;for(this.center[2]-=2*g;c--;)h=a[c],f=(e=h.half)?1:-1,b=h.plotY,d=this.getX(b,e),h.labelPos=[0,b,d+(g-5)*f,b,d+g*f,b,e?"right":"left",0];p.pie.prototype.drawDataLabels.call(this)}})})(Highcharts); 13 | -------------------------------------------------------------------------------- /third-party/highcharts/modules/heatmap.js: -------------------------------------------------------------------------------- 1 | (function(b){var k=b.seriesTypes,l=b.each;k.heatmap=b.extendClass(k.map,{colorKey:"z",useMapGeometry:!1,pointArrayMap:["y","z"],translate:function(){var c=this,b=c.options,i=Number.MAX_VALUE,j=Number.MIN_VALUE;c.generatePoints();l(c.data,function(a){var e=a.x,f=a.y,d=a.z,g=(b.colsize||1)/2,h=(b.rowsize||1)/2;a.path=["M",e-g,f-h,"L",e+g,f-h,"L",e+g,f+h,"L",e-g,f+h,"Z"];a.shapeType="path";a.shapeArgs={d:c.translatePath(a.path)};typeof d==="number"&&(d>j?j=d:d dataMax) { 39 | dataMax = value; 40 | } else if (value < dataMin) { 41 | dataMin = value; 42 | } 43 | } 44 | }); 45 | 46 | series.translateColors(dataMin, dataMax); 47 | }, 48 | 49 | getBox: function () {} 50 | 51 | }); 52 | 53 | }(Highcharts)); 54 | -------------------------------------------------------------------------------- /third-party/highcharts/modules/no-data-to-display.js: -------------------------------------------------------------------------------- 1 | /* 2 | Highcharts JS v3.0.6 (2013-10-04) 3 | Plugin for displaying a message when there is no data visible in chart. 4 | 5 | (c) 2010-2013 Highsoft AS 6 | Author: Øystein Moseng 7 | 8 | License: www.highcharts.com/license 9 | */ 10 | (function(c){function f(){return!!this.points.length}function g(){this.hasData()?this.hideNoData():this.showNoData()}var d=c.seriesTypes,e=c.Chart.prototype,h=c.getOptions(),i=c.extend;i(h.lang,{noData:"No data to display"});h.noData={position:{x:0,y:0,align:"center",verticalAlign:"middle"},attr:{},style:{fontWeight:"bold",fontSize:"12px",color:"#60606a"}};d.pie.prototype.hasData=f;if(d.gauge)d.gauge.prototype.hasData=f;if(d.waterfall)d.waterfall.prototype.hasData=f;c.Series.prototype.hasData=function(){return this.dataMax!== 11 | void 0&&this.dataMin!==void 0};e.showNoData=function(a){var b=this.options,a=a||b.lang.noData,b=b.noData;if(!this.noDataLabel)this.noDataLabel=this.renderer.label(a,0,0,null,null,null,null,null,"no-data").attr(b.attr).css(b.style).add(),this.noDataLabel.align(i(this.noDataLabel.getBBox(),b.position),!1,"plotBox")};e.hideNoData=function(){if(this.noDataLabel)this.noDataLabel=this.noDataLabel.destroy()};e.hasData=function(){for(var a=this.series,b=a.length;b--;)if(a[b].hasData()&&!a[b].options.isInternal)return!0; 12 | return!1};e.callbacks.push(function(a){c.addEvent(a,"load",g);c.addEvent(a,"redraw",g)})})(Highcharts); 13 | -------------------------------------------------------------------------------- /third-party/snapscreen/UEditorSnapscreen.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/snapscreen/UEditorSnapscreen.exe -------------------------------------------------------------------------------- /third-party/video-js/font/vjs.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/video-js/font/vjs.eot -------------------------------------------------------------------------------- /third-party/video-js/font/vjs.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/video-js/font/vjs.ttf -------------------------------------------------------------------------------- /third-party/video-js/font/vjs.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/video-js/font/vjs.woff -------------------------------------------------------------------------------- /third-party/video-js/video-js.swf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/video-js/video-js.swf -------------------------------------------------------------------------------- /third-party/webuploader/Uploader.swf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/webuploader/Uploader.swf -------------------------------------------------------------------------------- /third-party/webuploader/webuploader.css: -------------------------------------------------------------------------------- 1 | .webuploader-container { 2 | position: relative; 3 | } 4 | .webuploader-element-invisible { 5 | position: absolute !important; 6 | clip: rect(1px 1px 1px 1px); /* IE6, IE7 */ 7 | clip: rect(1px,1px,1px,1px); 8 | } 9 | .webuploader-pick { 10 | position: relative; 11 | display: inline-block; 12 | cursor: pointer; 13 | background: #00b7ee; 14 | padding: 10px 15px; 15 | color: #fff; 16 | text-align: center; 17 | border-radius: 3px; 18 | overflow: hidden; 19 | } 20 | .webuploader-pick-hover { 21 | background: #00a2d4; 22 | } 23 | 24 | .webuploader-pick-disable { 25 | opacity: 0.6; 26 | pointer-events:none; 27 | } 28 | 29 | -------------------------------------------------------------------------------- /third-party/zeroclipboard/ZeroClipboard.swf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/fex-team/ueditor/ea2585b483b9d3ead85b090928d72503c7107baf/third-party/zeroclipboard/ZeroClipboard.swf -------------------------------------------------------------------------------- /ueditor.parse.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | var paths = [ 3 | 'parse.js', 4 | 'insertcode.js', 5 | 'table.js', 6 | 'charts.js', 7 | 'background.js', 8 | 'list.js', 9 | 'video.js' 10 | ]; 11 | 12 | function getUEBasePath(docUrl, confUrl) { 13 | return getBasePath( 14 | docUrl || self.document.URL || self.location.href, 15 | confUrl || getConfigFilePath() 16 | ); 17 | } 18 | 19 | function getConfigFilePath() { 20 | var configPath = document.getElementsByTagName("script"); 21 | 22 | return configPath[configPath.length - 1].src; 23 | } 24 | 25 | function getBasePath(docUrl, confUrl) { 26 | var basePath = confUrl; 27 | 28 | if (!/^[a-z]+:/i.test(confUrl)) { 29 | docUrl = docUrl.split("#")[0].split("?")[0].replace(/[^\\\/]+$/, ""); 30 | 31 | basePath = docUrl + "" + confUrl; 32 | } 33 | 34 | return optimizationPath(basePath); 35 | } 36 | 37 | function optimizationPath(path) { 38 | var protocol = /^[a-z]+:\/\//.exec(path)[0], 39 | tmp = null, 40 | res = []; 41 | 42 | path = path.replace(protocol, "").split("?")[0].split("#")[0]; 43 | 44 | path = path.replace(/\\/g, "/").split(/\//); 45 | 46 | path[path.length - 1] = ""; 47 | 48 | while (path.length) { 49 | if ((tmp = path.shift()) === "..") { 50 | res.pop(); 51 | } else if (tmp !== ".") { 52 | res.push(tmp); 53 | } 54 | } 55 | 56 | return protocol + res.join("/"); 57 | } 58 | var baseURL = getUEBasePath() + "_parse/"; 59 | for (var i = 0, pi; (pi = paths[i++]); ) { 60 | document.write( 61 | '' 62 | ); 63 | } 64 | })(); 65 | --------------------------------------------------------------------------------