diff --git a/index.html b/index.html index 889d919..977140d 100644 --- a/index.html +++ b/index.html @@ -1,5 +1,5 @@ - + @@ -141,15 +141,16 @@ border-color: var(--kt-blue); } .chart-container { - height: 320px; + height: 360px; position: relative; + padding-top: 40px; } .bar-chart { display: flex; align-items: flex-end; justify-content: space-between; height: 280px; - padding: 20px 10px 40px; + padding: 0 10px 40px; gap: 4px; } .bar-item { @@ -604,13 +605,13 @@ const maxValue = Math.max(...chartData.map(d => d.value)); container.innerHTML = chartData.map((d, i) => { - const height = (d.value / maxValue) * 240; - const color = colors[i % colors.length]; - return ` -
-
-
${formatNumber(d.value / 1000)}K
-
+ const height = (d.value / maxValue) * 200; + const color = colors[i % colors.length]; + return ` +
+
+
${formatNumber(d.value / 1000)}K
+
${d.name.length > 15 ? d.name.substring(0, 15) + '...' : d.name}
`; @@ -648,13 +649,13 @@ const colors = ['#0096D7', '#00C4B4', '#3B82F6', '#8B5CF6', '#EC4899', '#F59E0B']; container.innerHTML = data.map((d, i) => { - const height = (d[1] / maxValue) * 240; + const height = (d[1] / maxValue) * 200; const color = colors[i % colors.length]; const percent = ((d[1] / rawData.reduce((s, r) => s + r.purchases, 0)) * 100).toFixed(1); return `
-
${percent}%
+
${percent}%
${d[0]}