Skip to content

Commit

Permalink
add 1.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
machuanjia committed Mar 23, 2018
1 parent bbb6e92 commit 3f28136
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 71 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "angular-wt-editor",
"version": "1.3.7",
"version": "1.3.4.1",
"homepage": "https://github.com/WorktileTech/angular-wt-editor",
"authors": [
"YCTech"
Expand Down
8 changes: 4 additions & 4 deletions dist/wt-editor-min.js

Large diffs are not rendered by default.

13 changes: 1 addition & 12 deletions dist/wt-editor.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,3 @@
;(function(root, factory) {
if (typeof define === 'function' && define.amd) {
define(['jquery', 'marked'], factory);
} else if (typeof exports === 'object') {
module.exports = factory(require('jquery'), require('marked'));
} else {
root.wtEditor = factory(root.jQuery, root.marked);
}
}(this, function($, marked) {
var wtEditor = angular.module("wt-editor", ["wt.editor.tpl",'ui.bootstrap','monospaced.elastic']);

// Some browsers don't support repeat, for example, Safari
Expand Down Expand Up @@ -1399,6 +1390,4 @@ angular.module("wt-editor")
}
};
}]);
angular.module("wt.editor.tpl", []).run(["$templateCache", function($templateCache) {$templateCache.put("wt-editor/editor.html","<div class=\"wt-editor {{vm.className}}\" ng-class=\"{true: \'wt-editor-full-screen\', false: \'\'}[vm.isFullscreen]\">\r <div class=\"wt-editor-toobar\">\r <div class=\"noselect\">\r <ul class=\"wtEditorToolBarUl\">\r <li class=\"wtEditorToolBarli\" ng-repeat=\"item in vm.toolbars track by $index\" name=\"{{item.name}}\" ng-class=\"(item.id == 0 && vm.header_action)?\'active\':\'\'\">\r <!--自定义toolbar-->\r <i ng-if=\"item.type === \'custom\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"item.action($event,vm)\"></i>\r\r <i ng-if=\"item.type === \'headingFns\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.setHeaderLi(item.id)\"></i>\r\r <div ng-if=\"item.type === \'headingFns\'\" ng-show=\"vm.header_action\" class=\"toolbar-menu\" flag=\"h\">\r <ul flag=\"h\">\r <li ng-repeat=\"n in vm.headers\" ng-class=\"n.className\" ng-click=\"vm.styleFn(n.name,$event)\" flag=\"h\">\r {{n.title}}\r </li>\r </ul>\r </div>\r\r <i ng-if=\"item.type === \'styleFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <!--<i ng-if=\"item.type === \'headingFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\">h{{item.level}}</i>-->\r\r <i ng-if=\"item.type === \'tableFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\"\r ng-click=\"vm.styleFn(item.name,$event)\"></i>\r\r\r <div ng-if=\"item.type === \'tableFn\'\" ng-show=\"vm.table_action\" class=\"table-menu\" flag=\"table\" ng-mouseleave=\"vm.tableActiveX=1;vm.tableActiveY=1;vm.table_action=false\">\r <ul flag=\"table\">\r <li flag=\"table\" ng-repeat=\"n in vm.tableMenu\">\r <i ng-repeat=\"s in n\" flag=\"table\" ng-click=\"vm.insertTable()\" ng-mouseenter=\"vm.setTableMemu(s[0],s[1])\" ng-mouseleave=\"\" ng-class=\"{true: \'active\', false: \'\'}[s[0]<=vm.tableActiveX && s[1] <= vm.tableActiveY]\"></i>\r </li>\r </ul>\r </div>\r\r\r <i ng-if=\"item.type === \'emoji\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" data-toggle=\"modal\" data-target=\"#{{item.target}}\"></i>\r\r <i ng-if=\"item.type === \'mathFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'flowchart\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'diagram\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'gantt\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'help\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" data-toggle=\"modal\" data-target=\"#{{item.target}}\"></i>\r <i ng-if=\"item.type === \'preview\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.togglePreview()\"></i>\r <i ng-if=\"item.type === \'expand\'\" title=\"{{vm.isFullscreen?item.title2:item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-class=\"{true: \'fa-compress\', false: \'fa-expand\'}[vm.isFullscreen]\" ng-click=\"vm.toggleFullScreen()\"></i>\r <i ng-if=\"item.type === \'divider\'\" class=\"divider\"></i>\r </li>\r </ul>\r </div>\r </div>\r <div class=\"wt-editor-container\" ng-class=\"{true:\'height-auto\',false:\'\'}[vm.autoHeight]\">\r <div class=\"wt-editor-container-code\">\r <textarea class=\"wt-editor-textarea\" msd-elastic ng-model=\"value\" max-height=\"maxHeight\"></textarea>\r </div>\r <div class=\"wt-editor-container-preview\" ng-style=\"vm.editorHeight\" ng-show=\"vm.isPreview\">\r <article class=\"markdown-body\" data-open-title=\"Hide Preview\" data-closed-title=\"Show Preview\"></article> <!-- 实时预览 -->\r </div>\r </div>\r</div>\r");}]);
return wtEditor;
}));
angular.module("wt.editor.tpl", []).run(["$templateCache", function($templateCache) {$templateCache.put("wt-editor/editor.html","<div class=\"wt-editor {{vm.className}}\" ng-class=\"{true: \'wt-editor-full-screen\', false: \'\'}[vm.isFullscreen]\">\r <div class=\"wt-editor-toobar\">\r <div class=\"noselect\">\r <ul class=\"wtEditorToolBarUl\">\r <li class=\"wtEditorToolBarli\" ng-repeat=\"item in vm.toolbars track by $index\" name=\"{{item.name}}\" ng-class=\"(item.id == 0 && vm.header_action)?\'active\':\'\'\">\r <!--自定义toolbar-->\r <i ng-if=\"item.type === \'custom\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"item.action($event,vm)\"></i>\r\r <i ng-if=\"item.type === \'headingFns\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.setHeaderLi(item.id)\"></i>\r\r <div ng-if=\"item.type === \'headingFns\'\" ng-show=\"vm.header_action\" class=\"toolbar-menu\" flag=\"h\">\r <ul flag=\"h\">\r <li ng-repeat=\"n in vm.headers\" ng-class=\"n.className\" ng-click=\"vm.styleFn(n.name,$event)\" flag=\"h\">\r {{n.title}}\r </li>\r </ul>\r </div>\r\r <i ng-if=\"item.type === \'styleFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <!--<i ng-if=\"item.type === \'headingFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\">h{{item.level}}</i>-->\r\r <i ng-if=\"item.type === \'tableFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\"\r ng-click=\"vm.styleFn(item.name,$event)\"></i>\r\r\r <div ng-if=\"item.type === \'tableFn\'\" ng-show=\"vm.table_action\" class=\"table-menu\" flag=\"table\" ng-mouseleave=\"vm.tableActiveX=1;vm.tableActiveY=1;vm.table_action=false\">\r <ul flag=\"table\">\r <li flag=\"table\" ng-repeat=\"n in vm.tableMenu\">\r <i ng-repeat=\"s in n\" flag=\"table\" ng-click=\"vm.insertTable()\" ng-mouseenter=\"vm.setTableMemu(s[0],s[1])\" ng-mouseleave=\"\" ng-class=\"{true: \'active\', false: \'\'}[s[0]<=vm.tableActiveX && s[1] <= vm.tableActiveY]\"></i>\r </li>\r </ul>\r </div>\r\r\r <i ng-if=\"item.type === \'emoji\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" data-toggle=\"modal\" data-target=\"#{{item.target}}\"></i>\r\r <i ng-if=\"item.type === \'mathFn\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'flowchart\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'diagram\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'gantt\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.styleFn(item.name,$event)\"></i>\r <i ng-if=\"item.type === \'help\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" data-toggle=\"modal\" data-target=\"#{{item.target}}\"></i>\r <i ng-if=\"item.type === \'preview\'\" title=\"{{item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-click=\"vm.togglePreview()\"></i>\r <i ng-if=\"item.type === \'expand\'\" title=\"{{vm.isFullscreen?item.title2:item.title}}\" class=\"{{item.className}} toolbar-icon\" ng-class=\"{true: \'fa-compress\', false: \'fa-expand\'}[vm.isFullscreen]\" ng-click=\"vm.toggleFullScreen()\"></i>\r <i ng-if=\"item.type === \'divider\'\" class=\"divider\"></i>\r </li>\r </ul>\r </div>\r </div>\r <div class=\"wt-editor-container\" ng-class=\"{true:\'height-auto\',false:\'\'}[vm.autoHeight]\">\r <div class=\"wt-editor-container-code\">\r <textarea class=\"wt-editor-textarea\" msd-elastic ng-model=\"value\" max-height=\"maxHeight\"></textarea>\r </div>\r <div class=\"wt-editor-container-preview\" ng-style=\"vm.editorHeight\" ng-show=\"vm.isPreview\">\r <article class=\"markdown-body\" data-open-title=\"Hide Preview\" data-closed-title=\"Show Preview\"></article> <!-- 实时预览 -->\r </div>\r </div>\r</div>\r");}]);
53 changes: 0 additions & 53 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ var ngTemplate = require('gulp-angular-templatecache');
var merge = require('merge-stream');
var autoprefixer = require('gulp-autoprefixer');
var minifycss = require('gulp-minify-css');
var umd = require('gulp-umd');

var paths = {
scripts: ['src/js/*.js'],
Expand Down Expand Up @@ -59,62 +58,10 @@ gulp.task('scripts:dev', function () {
gulp.task('scripts:dist', ['templates:dev'],function () {
return gulp.src(paths.scripts.concat(["src/wt-editor.tpl.js"]))
.pipe(concat('wt-editor.js'))
.pipe(umd({
exports: function(file) {
return 'wtEditor';
},
namespace: function(file) {
return 'wtEditor';
},
dependencies: function(file) {
return [
{
name: '$',
amd: 'jquery',
cjs: 'jquery',
global: 'jQuery',
param: '$'
},
{
name: 'marked',
amd: 'marked',
cjs: 'marked',
global: 'marked',
param: 'marked'
}
];
}
}))
.pipe(gulp.dest('dist'));
});
gulp.task('scripts:dist_all_min', ['templates:dev'],function () {
return gulp.src(paths.scripts.concat(["src/wt-editor.tpl.js"]))
.pipe(umd({
exports: function(file) {
return 'wtEditor';
},
namespace: function(file) {
return 'wtEditor';
},
dependencies: function(file) {
return [
{
name: '$',
amd: 'jquery',
cjs: 'jquery',
global: 'jQuery',
param: '$'
},
{
name: 'marked',
amd: 'marked',
cjs: 'marked',
global: 'marked',
param: 'marked'
}
];
}
}))
.pipe(uglify())
.pipe(concat('wt-editor-min.js'))
.pipe(gulp.dest('dist'));
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "angular-wt-editor",
"version": "1.3.7",
"version": "1.3.4.1",
"description": "angular-wt-editor =================",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit 3f28136

Please sign in to comment.