mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-16 19:46:21 +00:00
TinyMCE wpView: add sandbox iframe body styling to get proper height when resizing the iframe, fixes #29270.
Built from https://develop.svn.wordpress.org/trunk@29544 git-svn-id: http://core.svn.wordpress.org/trunk@29320 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
afdb25bd56
commit
51b307bcd3
@ -157,13 +157,15 @@ window.wp = window.wp || {};
|
||||
'<head>' +
|
||||
'<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />' +
|
||||
'<style>' +
|
||||
'html, body#wpview-iframe-sandbox {' +
|
||||
'html {' +
|
||||
'background: transparent;' +
|
||||
'padding: 0;' +
|
||||
'margin: 0;' +
|
||||
'}' +
|
||||
'body#wpview-iframe-sandbox {' +
|
||||
'background: transparent;' +
|
||||
'padding: 1px 0;' +
|
||||
'margin: -1px 0 0;' +
|
||||
'}' +
|
||||
'</style>' +
|
||||
'</head>' +
|
||||
@ -176,7 +178,7 @@ window.wp = window.wp || {};
|
||||
|
||||
resize = function() {
|
||||
// Make sure the iframe still exists.
|
||||
iframe.contentWindow && $( iframe ).height( $( iframeDoc.body ).outerHeight() );
|
||||
iframe.contentWindow && $( iframe ).height( $( iframeDoc.body ).height() );
|
||||
};
|
||||
|
||||
if ( MutationObserver ) {
|
||||
|
2
wp-includes/js/mce-view.min.js
vendored
2
wp-includes/js/mce-view.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user