@@ -34,7 +34,7 @@ require('./elements_style.css');
34
34
35
35
const DEF_BG = '#FFFFFF' ;
36
36
const DEF_LAYOUT = 'cose' ;
37
- const DEF_HEIGHT = '500px ' ;
37
+ const DEF_HEIGHT = '700px ' ;
38
38
39
39
const DEF_STYLE = [ {
40
40
selector : 'node' ,
@@ -302,14 +302,13 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
302
302
. css ( { 'font-size' : '16px' , 'margin-top' : '10px' } ) ;
303
303
304
304
that . $pyvipr = $ ( "<h1>PyViPR</h1>" )
305
- . css ( { 'font-size' : '1.3em' , 'margin-top ' : '10px ' , 'color ' : 'gray ' ,
305
+ . css ( { 'font-size' : '1.3em' , 'color ' : 'gray ' , 'margin ' : '0 ' ,
306
306
'font-family' : "\'Lucida console\', Lucida, monospace" , 'font-weight' : 'bold' } ) ;
307
307
308
308
that . $title = $ ( "<div id='title'></div>" )
309
309
. append ( that . $model_title ) ;
310
310
311
311
that . $pyviprdiv = $ ( "<div id='pyviprid'></div>" )
312
- . css ( { 'position' : 'absolute' , 'left' : '0.6em' , 'bottom' : '2em' } )
313
312
. append ( that . $pyvipr ) ;
314
313
315
314
// Searchbox elements
@@ -318,7 +317,8 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
318
317
that . $search_wrapper = $ ( "<div id='searchDiv'></div>" )
319
318
. append ( that . $search ) ;
320
319
321
- that . $info = $ ( "<div id='info'></div>" ) ;
320
+ that . $info = $ ( "<div id='info'></div>" )
321
+ . css ( { 'color' : 'black' } )
322
322
323
323
// Fit button to fit network to cell space
324
324
that . $fitButton = $ ( "<button id='fitbuttonid'><i class=\"fa fa-arrows-h\"></i></button>" ) ;
@@ -328,10 +328,11 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
328
328
. css ( {
329
329
"width" : "100%" ,
330
330
"height" : "5em" ,
331
- "bottom" : "500px" ,
332
- "position" : "relative" ,
333
331
"border" : "medium solid grey" ,
334
- "border-radius" : "10px"
332
+ "border-radius" : "10px" ,
333
+ "background-color" : "#FFFFFF" ,
334
+ "position" : "relative" ,
335
+ "bottom" : "700px"
335
336
} )
336
337
. append ( that . $downloadButton )
337
338
. append ( that . $fitButton )
@@ -431,7 +432,8 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
431
432
"width" : "100%" ,
432
433
"height" : "50px" ,
433
434
"bottom" : "0px" ,
434
- "position" : "relative"
435
+ "position" : "relative" ,
436
+ "background-color" : "white"
435
437
} )
436
438
. append ( that . $playButton )
437
439
. append ( that . $slider )
@@ -635,18 +637,14 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
635
637
// https://github.com/atomiks/tippyjs/issues/661
636
638
let dummyDomEle = document . createElement ( 'div' ) ;
637
639
node . tippy = tippy ( dummyDomEle , {
638
- onCreate : function ( instance ) { // mandatory
639
- // patch the tippy's popper reference so positioning works
640
- // https://atomiks.github.io/tippyjs/misc/#custom-position
641
- instance . popperInstance . reference = ref ;
642
- } ,
640
+ getReferenceClientRect : ref . getBoundingClientRect ,
643
641
lazy : false , // mandatory
644
642
trigger : 'manual' , // mandatory
645
643
// dom element inside the tippy:
646
644
content : function ( ) { // function can be better for performance
647
- let div = document . createElement ( 'div' ) ;
648
- div . innerHTML = text ;
649
- return div ;
645
+ let content = document . createElement ( 'div' ) ;
646
+ content . innerHTML = text ;
647
+ return content ;
650
648
} ,
651
649
// your own preferences:
652
650
arrow : true ,
@@ -910,7 +908,7 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
910
908
that . groupSelected = $ ( "<button id='groupSel'>Group</button>" )
911
909
. css ( {
912
910
'position' : 'absolute' ,
913
- 'right' : '9.4em ' ,
911
+ 'right' : '11em ' ,
914
912
'top' : '0' ,
915
913
'zIndex' : '999' ,
916
914
'height' : '1.8em' ,
@@ -987,7 +985,8 @@ let CytoscapeView = widgets.DOMWidgetView.extend({
987
985
988
986
that . $popup = $ ( "<div class='fragment'>" +
989
987
"</div>" )
990
- . css ( { 'border' : '1px solid #ccc' , 'background' : '#FF7F7F' } )
988
+ . css ( { 'border' : '1px solid #ccc' , 'background' : '#FF7F7F' ,
989
+ 'position' : 'relative' , 'bottom' :'0' , 'z-index' : '999' } )
991
990
. append ( that . $close )
992
991
. append ( that . $message )
993
992
. appendTo ( that . el . parentElement ) ;
0 commit comments