File tree Expand file tree Collapse file tree 1 file changed +39
-0
lines changed
Programming Tools/Blockly/blockly-1.20181105.0/blockly-1.20181105.0/tests/playgrounds Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Original file line number Diff line number Diff line change 1+ <!DOCTYPE html>
2+ < html >
3+ < head >
4+ < meta charset ="utf-8 ">
5+ < title > Blockly <iframe> Playground</ title >
6+ < style >
7+ html , body {
8+ border : 0 ;
9+ margin : 0 ;
10+ padding : 0 ;
11+ font-family : sans-serif;
12+ }
13+ h1 # title {
14+ border : 0 ;
15+ margin : 2px ;
16+ padding : 0 ;
17+ width: %100;
18+ }
19+ # playground-iframe {
20+ border : 0 ;
21+ width: %100;
22+ }
23+ </ style >
24+ < script type ="text/javascript ">
25+ var onWindowResize = function ( ) {
26+ var iframe = document . getElementById ( 'playground-iframe' ) ;
27+ var top = iframe . getBoundingClientRect ( ) . top ;
28+ iframe . height = window . innerHeight - top ;
29+ iframe . width = window . innerWidth ;
30+ } ;
31+ window . addEventListener ( "resize" , onWindowResize ) ;
32+ window . addEventListener ( "load" , onWindowResize ) ;
33+ </ script >
34+ </ head >
35+ < body >
36+ < h1 id ="title "> Outer Frame</ h1 >
37+ < iframe id ="playground-iframe " src ="../playground.html ">
38+ </ body >
39+ </ html >
You can’t perform that action at this time.
0 commit comments