Skip to content

Commit d28fa3f

Browse files
committed
feat: add breakdown charts
1 parent b08ce96 commit d28fa3f

File tree

3 files changed

+57
-12
lines changed

3 files changed

+57
-12
lines changed

docs/src/components/Insights.astro

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@ import featureImage from "../assets/features/build-insights.png";
77

88
<style>
99
section {
10-
padding: 8rem 0;
10+
margin-top: 4rem;
11+
margin-bottom: 4rem;
12+
13+
@media (min-width: 800px) {
14+
margin-top: 8rem;
15+
margin-bottom: 8rem;
16+
}
1117
}
1218

1319
.header-wrapper {

docs/src/components/InsightsBreakdown.astro

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,18 @@ const { title, chart, contentTitle } = Astro.props;
1414
---
1515

1616
<style>
17+
section {
18+
margin-top: 4rem;
19+
margin-bottom: 4rem;
20+
21+
@media (min-width: 800px) {
22+
margin-top: 8rem;
23+
margin-bottom: 8rem;
24+
}
25+
}
26+
1727
.content-wrapper {
28+
row-gap: 2rem;
1829
margin-top: 2rem;
1930

2031
@media (min-width: 800px) {
@@ -33,6 +44,7 @@ const { title, chart, contentTitle } = Astro.props;
3344
.description-wrapper {
3445
@media (min-width: 800px) {
3546
grid-column: span 6;
47+
align-content: center;
3648
}
3749
}
3850

@@ -121,7 +133,7 @@ const { title, chart, contentTitle } = Astro.props;
121133
<div
122134
class="bar"
123135
style={{ "--progress": `${item.width * 100}%` }}
124-
></div>
136+
/>
125137
<span class="value">{item.value}s</span>
126138
</div>
127139
</dd>
@@ -132,7 +144,7 @@ const { title, chart, contentTitle } = Astro.props;
132144
</figure>
133145
<div class="description-wrapper">
134146
<h3 class="title">{contentTitle}</h3>
135-
<slot/>
147+
<slot />
136148
</div>
137149
</div>
138150
</section>

docs/src/pages/team-insights.astro

Lines changed: 36 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -48,26 +48,53 @@ import logoImage from "../assets/rocketsim-insights-logo.svg";
4848
{
4949
title: "Mac Studio 2023 / M2 Ultra 24-core / 192 RAM",
5050
value: 12,
51-
width: 0.46,
51+
width: 0.36,
5252
},
5353
{
5454
title: 'MacBook Pro 16" 2023 / M3 Max 16-core / 64 RAM',
5555
value: 14,
56-
width: 0.54,
56+
width: 0.42,
5757
},
5858
{
5959
title: 'MacBook Pro 16" 2021 / M1 Pro 10-core / 32 RAM',
6060
value: 26,
61-
width: 1,
61+
width: 0.77,
6262
},
63-
]
63+
],
6464
}}
6565
contentTitle="Benchmark your team's project"
66-
>
67-
With team licenses, your builds will be synced. You'll find out{" "}
68-
<strong>which machine setup performs best</strong> for your Xcode
69-
project.
70-
</InsightsBreakdown>
66+
>
67+
With team licenses, your builds will be synced. You'll find out{" "}
68+
<strong>which machine setup performs best</strong> for your Xcode project.
69+
</InsightsBreakdown>
70+
<InsightsBreakdown
71+
title="Does Xcode 16 improve our project's build times?"
72+
chart={{
73+
title: "Build Duration by Xcode Version",
74+
data: [
75+
{
76+
title: "Xcode 16.0 (16F3233f)",
77+
value: 13.5,
78+
width: 0.68,
79+
},
80+
{
81+
title: "Xcode 15.4 (15F31d)",
82+
value: 15,
83+
width: 0.76,
84+
},
85+
{
86+
title: "Xcode 15.3 (15E204a)",
87+
value: 15.3,
88+
width: 0.78,
89+
},
90+
],
91+
}}
92+
contentTitle="Build duration grouped by Xcode version"
93+
>
94+
RocketSim Insights automatically benchmarks your team's build durations to
95+
tell you <strong>how much an Xcode version improves build times</strong> for
96+
your Xcode project.
97+
</InsightsBreakdown>
7198
</main>
7299
<Footer />
73100
</BaseLayout>

0 commit comments

Comments
 (0)