diff --git a/assets/src/scripts/monitoring-location/components/hydrograph/time-series-graph.js b/assets/src/scripts/monitoring-location/components/hydrograph/time-series-graph.js index a4e9cf997a4584c83bd8de711f3420491dd99fc2..5305cf186aa72830a555e43d996e00843c188ab7 100644 --- a/assets/src/scripts/monitoring-location/components/hydrograph/time-series-graph.js +++ b/assets/src/scripts/monitoring-location/components/hydrograph/time-series-graph.js @@ -148,7 +148,7 @@ const plotAllFloodLevelPoints = function(elem, {visible, xscale, yscale, seriesP }; -const createTitle = function(elem, store, siteNo, showMLName) { +const createTitle = function(elem, store, siteNo, showMLName, showTooltip) { let titleDiv = elem.append('div') .classed('time-series-graph-title', true); @@ -164,8 +164,10 @@ const createTitle = function(elem, store, siteNo, showMLName) { } titleDiv.append('div') .call(link(store,(elem, {title, variable}) => { - elem.html(title) - .call(appendTooltip, variable ? variable.variableDescription : 'No description available'); + elem.html(title); + if (showTooltip) { + elem.call(appendTooltip, variable ? variable.variableDescription : 'No description available'); + } }, createStructuredSelector({ title: getTitle, variable: getCurrentVariable @@ -209,7 +211,7 @@ export const drawTimeSeriesGraph = function(elem, store, siteNo, showMLName, sho graphDiv = elem.append('div') .attr('class', 'hydrograph-container') .call(watermark, store) - .call(createTitle, store, siteNo, showMLName); + .call(createTitle, store, siteNo, showMLName, showTooltip); if (showTooltip) { graphDiv.call(drawTooltipText, store); } diff --git a/assets/src/styles/components/hydrograph/_graph.scss b/assets/src/styles/components/hydrograph/_graph.scss index 66eab18e191880cdc9d92f83744e72fe7e1a110c..5943f2ff017907465f82cac9a456801a9bdf69f0 100644 --- a/assets/src/styles/components/hydrograph/_graph.scss +++ b/assets/src/styles/components/hydrograph/_graph.scss @@ -9,7 +9,6 @@ @include u-text('bold'); @include at-media(tablet) { @include typeset('ui', 9, 2); - @include u-text('bold'); } text-align: center; }