diff --git a/bower.json b/bower.json index 49328821..cb4ac43e 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "simditor", - "version": "2.3.10", + "version": "2.3.11", "homepage": "http://simditor.tower.im/", "authors": [ "farthinker " diff --git a/lib/simditor.js b/lib/simditor.js index 9828e5a1..87a1cd90 100644 --- a/lib/simditor.js +++ b/lib/simditor.js @@ -1,5 +1,5 @@ /*! -* Simditor v2.3.10 +* Simditor v2.3.11 * http://simditor.tower.im/ * 2018-01-22 */ @@ -5112,8 +5112,9 @@ TableButton = (function(superClass) { }; TableButton.prototype.initResize = function($table) { - var $colgroup, $resizeHandle, $wrapper; + var $colgroup, $editor, $resizeHandle, $wrapper; $wrapper = $table.parent('.simditor-table'); + $editor = this.editor; $colgroup = $table.find('colgroup'); if ($colgroup.length < 1) { $colgroup = $('').prependTo($table); @@ -5188,6 +5189,7 @@ TableButton = (function(superClass) { return $handle.css('left', startHandleLeft + deltaX); }); $(document).one('mouseup.simditor-resize-table', function(e) { + $editor.sync(); $(document).off('.simditor-resize-table'); return $wrapper.removeClass('resizing'); }); diff --git a/package.json b/package.json index e4f8b6ac..2b489b09 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "simditor", - "version": "2.3.10", + "version": "2.3.11", "description": "A simple online editor", "keywords": "editor simditor", "repository": { diff --git a/site/assets/scripts/simditor.js b/site/assets/scripts/simditor.js index 791d0666..d4e95fa9 100644 --- a/site/assets/scripts/simditor.js +++ b/site/assets/scripts/simditor.js @@ -5107,8 +5107,9 @@ TableButton = (function(superClass) { }; TableButton.prototype.initResize = function($table) { - var $colgroup, $resizeHandle, $wrapper; + var $colgroup, $editor, $resizeHandle, $wrapper; $wrapper = $table.parent('.simditor-table'); + $editor = this.editor; $colgroup = $table.find('colgroup'); if ($colgroup.length < 1) { $colgroup = $('').prependTo($table); @@ -5183,6 +5184,7 @@ TableButton = (function(superClass) { return $handle.css('left', startHandleLeft + deltaX); }); $(document).one('mouseup.simditor-resize-table', function(e) { + $editor.sync(); $(document).off('.simditor-resize-table'); return $wrapper.removeClass('resizing'); }); diff --git a/src/buttons/table.coffee b/src/buttons/table.coffee index 3918ada8..c73fe0cc 100644 --- a/src/buttons/table.coffee +++ b/src/buttons/table.coffee @@ -99,6 +99,7 @@ class TableButton extends Button initResize: ($table) -> $wrapper = $table.parent '.simditor-table' + $editor = @editor $colgroup = $table.find 'colgroup' if $colgroup.length < 1 @@ -175,6 +176,7 @@ class TableButton extends Button $handle.css 'left', startHandleLeft + deltaX $(document).one 'mouseup.simditor-resize-table', (e) -> + $editor.sync() $(document).off '.simditor-resize-table' $wrapper.removeClass 'resizing' diff --git a/styles/simditor.css b/styles/simditor.css index ad692421..0d7bc453 100644 --- a/styles/simditor.css +++ b/styles/simditor.css @@ -1,5 +1,5 @@ /*! -* Simditor v2.3.10 +* Simditor v2.3.11 * http://simditor.tower.im/ * 2018-01-22 */