@@ -14,6 +14,7 @@ class Pictograph {
1414 constructor ( el ) {
1515 this . rootElement = _ . has ( el , 'length' ) ? el [ 0 ] : el
1616 d3 . select ( this . rootElement ) . attr ( `rhtmlwidget-status` , 'loading' )
17+ d3 . select ( this . rootElement ) . attr ( `rhtmlPictographs-status` , 'loading' ) // to be removed once regression testing code checks for rhtmlwidget-status
1718 const actualDimensions = this . getContainerDimensions ( )
1819 log . info ( 'Pictograph() called. Container dimensions:' , actualDimensions , 'element:' , el )
1920
@@ -41,6 +42,7 @@ class Pictograph {
4142 if ( error . type === InsufficientContainerSizeError . type ) {
4243 console . log ( error . message )
4344 d3 . select ( this . rootElement ) . attr ( `rhtmlwidget-status` , 'ready' )
45+ d3 . select ( this . rootElement ) . attr ( `rhtmlPictographs-status` , 'ready' ) // to be removed once regression testing code checks for rhtmlwidget-status
4446 } else {
4547 console . error ( `error in pictograph draw: ${ error . message } ` )
4648 console . error ( error . stack )
@@ -77,6 +79,7 @@ class Pictograph {
7779 if ( error . type === InsufficientContainerSizeError . type ) {
7880 console . log ( error . message )
7981 d3 . select ( this . rootElement ) . attr ( `rhtmlwidget-status` , 'ready' )
82+ d3 . select ( this . rootElement ) . attr ( `rhtmlPictographs-status` , 'ready' ) // to be removed once regression testing code checks for rhtmlwidget-status
8083 } else {
8184 console . error ( `error in pictograph resize: ${ error . message } ` )
8285 console . error ( error . stack )
@@ -494,8 +497,6 @@ class Pictograph {
494497 . attr ( 'class' , 'table-cell' )
495498 . attr ( 'transform' , d => `translate(${ d . x } ,${ d . y } )` )
496499
497- const cellDrawingPromises = [ ]
498-
499500 enteringCells . each ( function ( d ) {
500501 const instance = d . instance
501502 log . debug ( `rendering entering cell` , instance )
@@ -507,11 +508,11 @@ class Pictograph {
507508 instance . setWidth ( d . width )
508509 instance . setHeight ( d . height )
509510 instance . setDynamicMargins ( d . dynamicMargins )
510-
511- cellDrawingPromises . push ( instance . draw ( ) )
511+ instance . draw ( )
512512 } )
513513
514- Promise . all ( cellDrawingPromises ) . then ( ( ) => d3 . select ( this . rootElement ) . attr ( `rhtmlwidget-status` , 'ready' ) )
514+ d3 . select ( this . rootElement ) . attr ( `rhtmlwidget-status` , 'ready' )
515+ d3 . select ( this . rootElement ) . attr ( `rhtmlPictographs-status` , 'ready' ) // to be removed once regression testing code checks for rhtmlwidget-status
515516 }
516517
517518 // TODO Duplicated code from graphicCell
0 commit comments