@@ -622,14 +622,10 @@ module powerbi.extensibility.visual {
622622 }
623623
624624 private static lineDotChartPlayBtn : string = "lineDotChart__playBtn" ;
625- private static lineDotChartPlayBtnTranslate : ClassAndSelector = createClassAndSelector ( "lineDotChartPlayBtnTranslate" ) ;
626625
627626 private static gLineDotChartPayBtn : string = "g.lineDotChart__playBtn" ;
628627 private static playBtnGroupDiameter : number = 34 ;
629628 private static playBtnGroupLineValues : string = "M0 2l10 6-10 6z" ;
630- private static playBtnGroupPlayTranslate : string = "playBtnGroupPlayTranslate" ;
631- private static playBtnGroupPathTranslate : string = "playBtnGroupPathTranslate" ;
632- private static playBtnGroupRectTranslate : string = "playBtnGroupRectTranslate" ;
633629 private static playBtnGroupRectWidth : string = "2" ;
634630 private static playBtnGroupRectHeight : string = "12" ;
635631 private static StopButton : ClassAndSelector = createClassAndSelector ( "stop" ) ;
@@ -645,8 +641,8 @@ module powerbi.extensibility.visual {
645641 const playBtnGroup : d3 . Selection < string > = playBtn
646642 . enter ( )
647643 . append ( "g" )
648- . classed ( LineDotChart . lineDotChartPlayBtn , true )
649- . classed ( LineDotChart . lineDotChartPlayBtnTranslate . className , true ) ;
644+ . attr ( "transform" , "translate(40, 20)" )
645+ . classed ( LineDotChart . lineDotChartPlayBtn , true ) ;
650646
651647 playBtnGroup . style ( "opacity" , this . settings . play . opacity ) ;
652648
@@ -679,8 +675,10 @@ module powerbi.extensibility.visual {
679675 . enter ( )
680676 . append ( "path" )
681677 . classed ( "play" , true )
682- . classed ( LineDotChart . playBtnGroupPlayTranslate , true )
683- . attr ( "d" , LineDotChart . playBtnGroupLineValues )
678+ . attr ( {
679+ "d" : LineDotChart . playBtnGroupLineValues ,
680+ "transform" : "translate(-4, -8)" ,
681+ } )
684682 . style ( "pointer-events" , "none" ) ;
685683
686684 firstPathSelection . style ( "fill" , this . settings . play . innerColor ) ;
@@ -697,10 +695,12 @@ module powerbi.extensibility.visual {
697695 . enter ( )
698696 . append ( "path" )
699697 . classed ( LineDotChart . StopButton . className , true )
700- . classed ( LineDotChart . playBtnGroupPathTranslate , true )
701- . attr ( "d" , LineDotChart . playBtnGroupLineValues )
702- . attr ( "transform-origin" , "center" )
703- . attr ( "pointer-events" , "none" ) ;
698+ . attr ( {
699+ "d" : LineDotChart . playBtnGroupLineValues ,
700+ "pointer-events" : "none" ,
701+ "transform-origin" : "top left" ,
702+ "transform" : "translate(6, 8) rotate(180)"
703+ } ) ;
704704
705705 secondPathSelection . style ( "fill" , this . settings . play . innerColor ) ;
706706
@@ -716,10 +716,12 @@ module powerbi.extensibility.visual {
716716 . enter ( )
717717 . append ( "rect" )
718718 . classed ( LineDotChart . StopButton . className , true )
719- . classed ( LineDotChart . playBtnGroupRectTranslate , true )
720- . attr ( "width" , LineDotChart . playBtnGroupRectWidth )
721- . attr ( "height" , LineDotChart . playBtnGroupRectHeight )
722- . attr ( "pointer-events" , "none" ) ;
719+ . attr ( {
720+ "width" : LineDotChart . playBtnGroupRectWidth ,
721+ "height" : LineDotChart . playBtnGroupRectHeight ,
722+ "pointer-events" : "none" ,
723+ "transform" : "translate(-7, -6)" ,
724+ } ) ;
723725
724726 rectSelection . style ( "fill" , this . settings . play . innerColor ) ;
725727
@@ -889,10 +891,10 @@ module powerbi.extensibility.visual {
889891 ! dotPoint . selected && hasHighlights
890892 ) ;
891893 } ,
892- "r" : ( dotPoint : LineDotPoint ) => {
893- return this . settings . dotoptions . dotSizeMin
894- + dotPoint . dot * ( this . settings . dotoptions . dotSizeMax - this . settings . dotoptions . dotSizeMin ) ;
895- }
894+ } )
895+ . attr ( "r" , ( dotPoint : LineDotPoint ) => {
896+ return this . settings . dotoptions . dotSizeMin
897+ + dotPoint . dot * ( this . settings . dotoptions . dotSizeMax - this . settings . dotoptions . dotSizeMin ) ;
896898 } ) ;
897899
898900 if ( this . settings . misc . isAnimated ) {
0 commit comments