File tree Expand file tree Collapse file tree 6 files changed +919
-10
lines changed
Expand file tree Collapse file tree 6 files changed +919
-10
lines changed Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ export default function AppPage({ params }: { params: Promise<{ id: string }> })
5757 const Component = toolState === 'configured' ? tool_comps . Dashboard : tool_comps . Readme ;
5858
5959 return (
60- < div className = "py-6" >
60+ < div className = "py-6 mb-6 pb-6 " >
6161 < div className = "flex flex-col gap-6" >
6262 < div className = "flex items-center gap-2" >
6363 < h1 className = "text-2xl font-bold" > { TOOLS [ id ] . name } </ h1 >
Original file line number Diff line number Diff line change @@ -93,9 +93,8 @@ export default function OrbDashboard() {
9393 { /* Charts Grid */ }
9494 < div className = "grid gap-4 grid-cols-1" >
9595 < SubsChart data = { subsTimeSeriesData } />
96-
9796 </ div >
98- < div className = "grid gap-4 md:grid-cols-2" >
97+ < div className = "grid gap-4 md:grid-cols-2 max-h-[400px] " >
9998 < SubsByPlanTsChart data = { subsByPlanTsData } />
10099 < SubsByPlanChart data = { subsByPlanData } />
101100 </ div >
Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ export function SubsByPlanChart({ data: rawData }: SubsByPlanChartData) {
6060 < CardContent className = "flex-1 pb-0" >
6161 < ChartContainer
6262 config = { chartConfig }
63- className = "mx-auto aspect-square max-h-[300px] "
63+ className = "mx-auto"
6464 >
6565 < PieChart >
6666 < Pie data = { data } dataKey = "subs" nameKey = "plan" />
Original file line number Diff line number Diff line change @@ -64,6 +64,8 @@ export function SubsByPlanTsChart({ data: rawData }: SubsByPlanTsChartData) {
6464 margin = { {
6565 left : 12 ,
6666 right : 12 ,
67+ top : 12 ,
68+ bottom : 12 ,
6769 } }
6870 >
6971 < XAxis
@@ -89,14 +91,15 @@ export function SubsByPlanTsChart({ data: rawData }: SubsByPlanTsChartData) {
8991 } }
9092 />
9193 < ChartTooltip cursor = { false } content = { < ChartTooltipContent /> } />
92- { planNames . map ( ( plan ) => (
94+ { planNames . map ( ( plan , i ) => (
9395 < Line
9496 key = { plan }
9597 type = "monotone"
9698 dataKey = { plan }
9799 name = { plan }
98100 strokeWidth = { 2 }
99101 dot = { false }
102+ stroke = { `hsl(var(--chart-${ i } ))` }
100103 />
101104 ) ) }
102105 </ LineChart >
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ export interface SubsChartProps {
2525
2626const chartConfig = {
2727 invoices : {
28- color : "hsl(var(--primary ))" ,
28+ color : "hsl(var(--chart-1 ))" ,
2929 label : "New Subscriptions" ,
3030 } ,
3131} satisfies ChartConfig
@@ -43,6 +43,8 @@ export function SubsChart({ data }: SubsChartProps) {
4343 margin = { {
4444 left : 12 ,
4545 right : 12 ,
46+ top : 12 ,
47+ bottom : 12
4648 } }
4749 >
4850 < XAxis
@@ -77,11 +79,9 @@ export function SubsChart({ data }: SubsChartProps) {
7779 strokeWidth = { 2 }
7880 activeDot = { {
7981 r : 4 ,
80- style : { fill : "hsl(var(--primary))" } ,
81- } }
82- style = { {
83- stroke : "hsl(var(--primary))" ,
82+ style : { fill : chartConfig . invoices . color } ,
8483 } }
84+ stroke = { chartConfig . invoices . color }
8585 />
8686 </ LineChart >
8787 </ ChartContainer >
You can’t perform that action at this time.
0 commit comments