Ticket #38850: 38850.3.patch
File 38850.3.patch, 3.9 KB (added by , 8 years ago) |
---|
-
src/wp-admin/css/edit.css
370 370 } 371 371 372 372 .wp-editor-expand #wp-content-editor-container { 373 -webkit-box-shadow: none;374 box-shadow: none;375 373 margin-top: -1px; 376 }377 378 .wp-editor-expand #wp-content-editor-container {379 374 border-bottom: 0 none; 380 375 } 381 376 382 .wp-editor-expand div.mce-statusbar {377 .wp-editor-expand.toolbar-open div.mce-statusbar { 383 378 z-index: 1; 379 position: sticky; 380 position: -webkit-sticky; 381 bottom: 23px; /* #post-status-info: height + border-top */ 384 382 } 385 383 386 .wp-editor-expand #post-status-info {384 .wp-editor-expand.toolbar-open #post-status-info { 387 385 border-top: 1px solid #e5e5e5; 386 position: sticky; 387 position: -webkit-sticky; 388 bottom: -1px; /* border-bottom */ 388 389 } 389 390 390 391 .wp-editor-expand div.mce-toolbar-grp { 391 392 z-index: 999; 392 393 } 393 394 395 .wp-editor-expand .wp-editor-tools { 396 position: sticky; 397 position: -webkit-sticky; 398 top: 32px; 399 } 400 401 .wp-editor-expand div.mce-toolbar-grp, 402 .wp-editor-expand .quicktags-toolbar { 403 position: sticky; 404 position: -webkit-sticky; 405 top: 87px; /* admin bar height + tools height */ 406 } 407 408 /* Buffer space */ 409 .wp-editor-expand .wp-editor-tools, 410 .wp-editor-expand div.mce-toolbar-grp, 411 .wp-editor-expand .quicktags-toolbar { 412 margin-bottom: 100px; 413 } 414 415 /* Pull container up for buffer space */ 416 .wp-editor-expand .wp-editor-container, 417 .wp-editor-expand .mce-edit-area, 418 .wp-editor-expand .wp-editor-container textarea.wp-editor-area { 419 margin-top: -100px; 420 } 421 422 .wp-editor-expand #wp-content-editor-container { 423 margin-top: -101px; /* +1 for double border */ 424 } 425 394 426 /* TinyMCE native fullscreen mode override */ 395 427 .mce-fullscreen #wp-content-wrap .mce-menubar, 396 428 .mce-fullscreen #wp-content-wrap .mce-toolbar-grp, -
src/wp-admin/js/editor-expand.js
53 53 sideSortablesHeight: 0 54 54 }; 55 55 56 var featureSticky = ( function() { 57 var element = document.createElement( 'div' ); 58 var style = element.style; 59 60 style.cssText = 'position:sticky;position:-webkit-sticky'; 61 62 return !! style.position; 63 } )(); 64 56 65 var shrinkTextarea = window._.throttle( function() { 57 66 var x = window.scrollX || document.documentElement.scrollLeft; 58 67 var y = window.scrollY || document.documentElement.scrollTop; … … 323 332 return; 324 333 } 325 334 335 if ( ! featureSticky ) { 336 326 337 topPos = $top.parent().offset().top; 327 338 editorPos = $editor.offset().top; 328 339 editorHeight = $editor.outerHeight(); … … 468 479 } 469 480 } 470 481 482 } // end ! featureSticky 483 471 484 // Sidebar pinning 472 485 if ( $postboxContainer.width() < 300 && heights.windowWidth > 600 && // sidebar position is changed with @media from CSS, make sure it is on the side 473 486 $document.height() > ( $sideSortables.height() + postBodyTop + 120 ) && // the sidebar is not the tallest element … … 558 571 fixedSideTop = fixedSideBottom = false; 559 572 } 560 573 561 if ( resize ) {574 if ( resize && ! featureSticky ) { 562 575 $contentWrap.css( { 563 576 paddingTop: heights.toolsHeight 564 577 } ); -
src/wp-includes/js/tinymce/plugins/wordpress/plugin.js
62 62 } 63 63 } 64 64 65 if ( editor.id === 'content' ) { 66 tinymce.$( '#postdivrich' ).toggleClass( 'toolbar-open', state !== 'hide' ) 67 } 68 65 69 editor.fire( 'wp-toolbar-toggle' ); 66 70 } 67 71 … … 72 76 onPostRender: function() { 73 77 wpAdvButton = this; 74 78 wpAdvButton.active( getUserSetting( 'hidetb' ) === '1' ? true : false ); 79 tinymce.$( '#postdivrich' ).toggleClass( 'toolbar-open', getUserSetting( 'hidetb' ) === '1' ) 75 80 } 76 81 }); 77 82