feature/syasya/testlayout #6
@ -140,7 +140,7 @@ const EnergyLineChart = ({ siteId }: EnergyLineChartProps) => {
 | 
			
		||||
        setGeneration(res.generation);
 | 
			
		||||
 | 
			
		||||
        // ⬇️ ADD THIS here — fetch forecast
 | 
			
		||||
      const forecastData = await fetchForecast(3.15, 101.7, 37, 0, 5.67);
 | 
			
		||||
      const forecastData = await fetchForecast(3.15, 101.7, 37, 0, 20.67);
 | 
			
		||||
      const selectedDateStr = selectedDate.toISOString().split('T')[0];
 | 
			
		||||
 | 
			
		||||
      setForecast(
 | 
			
		||||
 | 
			
		||||
@ -127,10 +127,7 @@ const generationColor = isDark ? '#fcd913' : '#669bbc';
 | 
			
		||||
  if (loading || !siteId || chartData.length === 0) {
 | 
			
		||||
    return (
 | 
			
		||||
      <div className="bg-white p-3 rounded-lg shadow-md dark:bg-rtgray-800 dark:text-white-light">
 | 
			
		||||
        <div className="flex justify-between items-center mb-2">
 | 
			
		||||
          <h2 className="text-lg font-bold">Monthly Energy Yield</h2>
 | 
			
		||||
        </div>
 | 
			
		||||
        <div className="h-96 w-full flex items-center justify-center">
 | 
			
		||||
        <div className="h-[200px] w-full flex items-center justify-center">
 | 
			
		||||
          <p className="text-white/70">
 | 
			
		||||
            {loading ? 'Loading data...' : 'No data available for chart.'}
 | 
			
		||||
          </p>
 | 
			
		||||
 | 
			
		||||
@ -37,7 +37,7 @@ export default function KpiBottom({
 | 
			
		||||
        </div>
 | 
			
		||||
      </Panel>
 | 
			
		||||
 | 
			
		||||
      <Panel title="Monthly Yield">
 | 
			
		||||
      <Panel title="Yield Bar Chart">
 | 
			
		||||
        <div className="w-full h-48">
 | 
			
		||||
          {middle}
 | 
			
		||||
        </div>
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user