Hey. I have declared a variable called ‘title-font’ in Observable notebook, which is used to provide font-size to a TEXT appended to the SVG, which I have integrated in my React App using ObservableHQ Runtime. I am trying to update the font-size using module.redefine(“titleTextSize”, 12), but it is not working. When I try to do the same for other Font-sizes like tooltips, it works. My title text is coded as follow:
svg.append('text') .text(titleText) .attr('y', margin.top - 20) .attr('x', width/4) .style('font-size', titleTextSize);
When I change the size of SVG from my React code, the Text Size changes according to that. I understand that the reason behind this is that the text is appended directly to the SVG. Can someone help me out on this? Thanks.