TinyMCE: remove reposition delay on showing the image toolbar. Not needed when no animation. Fixes #30670.
git-svn-id: https://develop.svn.wordpress.org/trunk@30829 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
1afbe9d6b3
commit
3fb7f40445
@ -165,6 +165,7 @@ div.mce-inline-toolbar-grp {
|
|||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
margin-bottom: 8px;
|
margin-bottom: 8px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
visibility: hidden;
|
||||||
-moz-user-select: none;
|
-moz-user-select: none;
|
||||||
-webkit-user-select: none;
|
-webkit-user-select: none;
|
||||||
-ms-user-select: none;
|
-ms-user-select: none;
|
||||||
@ -256,6 +257,10 @@ div.mce-inline-toolbar-grp.mce-arrow-full > div {
|
|||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
div.mce-inline-toolbar-grp-active {
|
||||||
|
visibility: visible;
|
||||||
|
}
|
||||||
|
|
||||||
div.mce-toolbar-grp > div {
|
div.mce-toolbar-grp > div {
|
||||||
padding: 3px;
|
padding: 3px;
|
||||||
}
|
}
|
||||||
|
@ -309,16 +309,12 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
floatingToolbar.on( 'show', function() {
|
floatingToolbar.on( 'show', function() {
|
||||||
var self = this;
|
|
||||||
|
|
||||||
toolbarIsHidden = false;
|
toolbarIsHidden = false;
|
||||||
|
|
||||||
setTimeout( function() {
|
if ( this._visible ) {
|
||||||
if ( self._visible ) {
|
this.reposition();
|
||||||
DOM.addClass( self.getEl(), 'mce-inline-toolbar-grp-active' );
|
DOM.addClass( this.getEl(), 'mce-inline-toolbar-grp-active' );
|
||||||
self.reposition();
|
}
|
||||||
}
|
|
||||||
}, 100 );
|
|
||||||
} );
|
} );
|
||||||
|
|
||||||
floatingToolbar.on( 'hide', function() {
|
floatingToolbar.on( 'hide', function() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user