@@ -26,37 +26,40 @@ const saveModules = () => {
2626
2727const init = ( ) => {
2828 var moduleWrappers = saveModules ( ) ;
29+ var check = $ ( '.sandbox_container' ) ;
30+ if ( ! check . length ) {
31+ util . clearModules ( ) ;
2932
30- util . clearModules ( ) ;
31- $ ( '.workspace' ) . append ( "<div class='sandbox_container '>\
32- <section class='close_bar '>\
33- <div class='btn' id='btn_close '>\
34- <div class='wrapper' >\
35- <i class='fa fa-times' aria-hidden='true'></i >\
33+ $ ( '.workspace' ) . append ( "<div class='sandbox_container'>\
34+ <section class='close_bar '>\
35+ <div class='btn' id='btn_close '>\
36+ <div class='wrapper '>\
37+ <i class='fa fa-times' aria-hidden='true'></i >\
38+ </div >\
3639 </div>\
37- </div>\
38- </section>\
39- <section class='auto-gen auto-gen-tracers'>\
40- <button class='sb-button' id='button-2DMatrix'>Create 2DMatrix</button>\
41- </section>\
42- <section class='auto-gen auto-gen-options'>\
43- <div>\
44- # of Rows: <input class='inputs'id='numRows' type='number' value='5'>\
45- </div>\
46- <div>\
47- # of Columns: <input class='inputs'id='numColumns' type='number' value='5'>\
48- </div>\
49- <div>\
50- Tracer Name: <input class='inputs'id='tracerName' type='text' value='default'>\
51- </div>\
52- </section>\
53- <section class='auto-gen auto-gen-generate'>\
54- <button class='sb-button' id='button-generateJS'>Generate Javascript</button>\
55- </section>\
56- </div>" ) ;
57- array2d . setup ( ) ;
40+ </section>\
41+ <section class='auto-gen auto-gen-tracers'>\
42+ <button class='sb-button' id='button-2DMatrix'>Create 2DMatrix</button>\
43+ </section>\
44+ <section class='auto-gen auto-gen-options'>\
45+ <div>\
46+ # of Rows: <input class='inputs'id='numRows' type='number' value='5'>\
47+ </div>\
48+ <div>\
49+ # of Columns: <input class='inputs'id='numColumns' type='number' value='5'>\
50+ </div>\
51+ <div>\
52+ Tracer Name: <input class='inputs'id='tracerName' type='text' value='default'>\
53+ </div>\
54+ </section>\
55+ <section class='auto-gen auto-gen-generate'>\
56+ <button class='sb-button' id='button-generateJS'>Generate Javascript</button>\
57+ </section>\
58+ </div>" ) ;
59+ array2d . setup ( ) ;
5860
59- closeCreate ( moduleWrappers ) ;
61+ closeCreate ( moduleWrappers ) ;
62+ }
6063} ;
6164
6265module . exports = {
0 commit comments