##// END OF EJS Templates
Preserve layout for large isolated objects
Pablo de Oliveira -
Show More
@@ -334,8 +334,9 b' var IPython = (function (IPython) {'
334 if (md['isolated']) {
334 if (md['isolated']) {
335 // Create an iframe to isolate the subarea from the rest of the
335 // Create an iframe to isolate the subarea from the rest of the
336 // document
336 // document
337 var iframe = $('<iframe/>');
337 var iframe = $('<iframe/>').addClass('box-flex1');
338 iframe.attr('height', 1);
338 iframe.attr('height', 1);
339 iframe.css({'width':'100%', 'display':'block'});
339 iframe.attr('frameborder', 0);
340 iframe.attr('frameborder', 0);
340 iframe.attr('scrolling', 'auto');
341 iframe.attr('scrolling', 'auto');
341
342
@@ -355,8 +356,7 b' var IPython = (function (IPython) {'
355 this.contentDocument.close();
356 this.contentDocument.close();
356
357
357 var body = this.contentDocument.body;
358 var body = this.contentDocument.body;
358 // Adjust the iframe width and height
359 // Adjust the iframe height automatically
359 iframe.width(body.scrollWidth + 'px');
360 iframe.height(body.scrollHeight + 'px');
360 iframe.height(body.scrollHeight + 'px');
361 });
361 });
362
362
General Comments 0
You need to be logged in to leave comments. Login now