@@ -303,7 +303,7 @@ void drawChart(
303303 tickLabel.setAttribute (
304304 'class' , 'downloads-chart-tick-label downloads-chart-tick-label-x' );
305305 }
306- tickLabel.text = formatAbbrMonthDay (date);
306+ tickLabel.textContent = formatAbbrMonthDay (date);
307307 tickLabel.setAttribute ('y' , '$tickLabelYCoordinate ' );
308308 tickLabel.setAttribute ('x' , '$x ' );
309309
@@ -321,7 +321,7 @@ void drawChart(
321321 final suffix = displayMode == DisplayMode .percentage
322322 ? '%'
323323 : compactFormat (i * interval).suffix;
324- tickLabel.text = '${compactFormat (i * interval ).value }$suffix ' ;
324+ tickLabel.textContent = '${compactFormat (i * interval ).value }$suffix ' ;
325325 tickLabel.setAttribute ('x' , '${xMax + marginPadding }' );
326326 tickLabel.setAttribute ('y' , '$y ' );
327327 chart.append (tickLabel);
@@ -439,7 +439,7 @@ void drawChart(
439439
440440 final legendLabel = SVGTextElement ();
441441 legendLabel.setAttribute ('class' , 'downloads-chart-tick-label' );
442- legendLabel.text = ranges[i];
442+ legendLabel.textContent = ranges[i];
443443 chart.append (legendLabel);
444444 chart.append (legend);
445445 legends.add ((legend, legendLabel));
@@ -629,7 +629,7 @@ void drawChart(
629629 'top:${e .y + toolTipOffsetFromMouse + document .scrollingElement !.scrollTop }px;$horizontalPosition ' );
630630 toolTip.replaceChildren (HTMLDivElement ()
631631 ..setAttribute ('class' , 'downloads-chart-tooltip-date' )
632- ..text =
632+ ..textContent =
633633 '${formatAbbrMonthDay (startDay )} - ${formatAbbrMonthDay (selectedDay )}' );
634634
635635 final downloads = values[nearestIndex];
@@ -641,14 +641,14 @@ void drawChart(
641641 final square = HTMLDivElement ()
642642 ..setAttribute ('class' ,
643643 'downloads-chart-tooltip-square ${squareColorClass (colorIndex (i ))}' );
644- final rangeText = HTMLSpanElement ()..text = '${ranges [i ]}: ' ;
644+ final rangeText = HTMLSpanElement ()..textContent = '${ranges [i ]}: ' ;
645645 final suffix = (displayMode == DisplayMode .percentage)
646646 ? ' (${(downloads [i ] * 100 / totals [nearestIndex ]).toStringAsPrecision (2 )}%)'
647647 : '' ;
648648 final text = '${formatWithThousandSeperators (downloads [i ])}$suffix ' ;
649649 final downloadsText = HTMLSpanElement ()
650650 ..setAttribute ('class' , 'downloads-chart-tooltip-downloads' )
651- ..text = text;
651+ ..textContent = text;
652652
653653 final tooltipRange = HTMLDivElement ()
654654 ..setAttribute ('class' , 'downloads-chart-tooltip-row' )
0 commit comments