diff --git a/src/lib/components/AnalystEstimate.svelte b/src/lib/components/AnalystEstimate.svelte index 2314c5c4..3b75ba17 100644 --- a/src/lib/components/AnalystEstimate.svelte +++ b/src/lib/components/AnalystEstimate.svelte @@ -506,12 +506,22 @@ const high = highList[dataIndex]; const low = lowList[dataIndex]; - return ` - ${dates[dataIndex]}
- High: ${high ? high?.toFixed(2) : "N/A"}
- Avg: ${mainValue?.toFixed(2)}
- Low: ${low ? low?.toFixed(2) : "N/A"} - `; + // Only show High and Low if they are not "N/A" + let tooltipContent = `${dates[dataIndex]}
`; + + if (high && high !== "N/A") { + tooltipContent += `High: ${high.toFixed(2)}
`; + } + + if (mainValue && mainValue !== "N/A") { + tooltipContent += `Avg: ${mainValue.toFixed(2)}
`; + } + + if (low && low !== "N/A") { + tooltipContent += `Low: ${low.toFixed(2)}
`; + } + + return tooltipContent; }, }, };