Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions src/components/benchmarks-page/BenchmarkDetail.astro
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,37 @@ const headlineKpi = metric.kpis[0]?.value ?? '';
</Panel>

<style>
@media (min-width: 721px) and (max-width: 1199px) {
.pk-bench-detail-head {
padding: var(--pk-pad-panel-y) var(--pk-pad-panel-x) 0 !important;
gap: 24px !important;
}
.pk-bench-detail-row {
padding: 36px var(--pk-pad-panel-x) 48px !important;
grid-template-columns: 1fr !important;
gap: 28px !important;
}
.pk-bench-detail-kpi {
padding: 28px 20px !important;
}
.pk-bench-detail-kpi-value {
font-size: 32px !important;
}
/* Scale down hardcoded h2 sizes */
.pk-bench-detail-head h2 {
font-size: 36px !important;
line-height: 1.15 !important;
}
.pk-bench-detail-head p {
font-size: 16px !important;
line-height: 1.5 !important;
}
.pk-bench-detail-headkpi {
font-size: 30px !important;
padding: 12px 18px !important;
}
}

@media (max-width: 720px) {
.pk-bench-detail-head {
padding: 32px 20px 0 !important;
Expand Down
21 changes: 21 additions & 0 deletions src/components/benchmarks-page/BenchmarksHero.astro
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,27 @@ import Panel from '~/components/panel/Panel.astro';
</Panel>

<style>
@media (min-width: 721px) and (max-width: 1199px) {
.pk-bench-hero-row {
flex-direction: column;
align-items: stretch !important;
gap: 28px !important;
}
.pk-bench-hero-cta {
flex-direction: row;
gap: 12px !important;
}
#benchmarks-hero-title {
font-size: 38px !important;
line-height: 1.15 !important;
white-space: normal !important;
}
.pk-bench-hero-copy p {
font-size: 16px !important;
line-height: 1.5 !important;
}
}

@media (max-width: 720px) {
.pk-bench-hero-row {
flex-direction: column;
Expand Down
27 changes: 27 additions & 0 deletions src/components/benchmarks-page/BenchmarksSummary.astro
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,33 @@ const summaryData = JSON.stringify({ rows: SUMMARY_ROWS, toolkits: SUMMARY_TOOLK
background: rgba(13, 116, 255, 0.06);
}

@media (min-width: 721px) and (max-width: 1199px) {
.pk-summary-head {
padding: var(--pk-pad-panel-y) var(--pk-pad-panel-x) 24px !important;
}
/* Scale down heading */
.pk-summary-head h2 {
font-size: 36px !important;
line-height: 1.15 !important;
}
.pk-summary-head p {
font-size: 16px !important;
line-height: 1.5 !important;
}
/* Narrow the 3 metric columns so they fit tablets without scroll */
.pk-summary-header,
.pk-summary-row {
grid-template-columns: 1fr repeat(3, minmax(0, 160px)) !important;
}
.pk-summary-cell-inner {
padding: 20px 16px !important;
font-size: 20px !important;
}
.pk-summary-row > div:first-child {
padding: 20px 24px !important;
}
}

@media (max-width: 720px) {
.pk-summary-head {
padding: 28px 20px 16px !important;
Expand Down
18 changes: 17 additions & 1 deletion src/components/benchmarks-page/ProvekitDemo.astro
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@
border: 0;
outline: 0;
background: transparent;
resize: vertical;
resize: none;
min-height: 64px;
font: 400 16px/1.45 var(--pk-font-mono);
color: var(--pk-ink);
Expand Down Expand Up @@ -598,6 +598,22 @@
}
}

@media (min-width: 721px) and (max-width: 1199px) {
#demo-title {
font-size: 36px !important;
line-height: 1.15 !important;
white-space: normal !important;
}
.pk-demo-sub {
font-size: 16px !important;
line-height: 1.5 !important;
}
.pk-demo-left {
padding: var(--pk-pad-panel-y) var(--pk-pad-panel-x);
gap: 28px;
}
}

@media (max-width: 720px) {
.pk-demo-grid {
grid-template-columns: 1fr;
Expand Down Expand Up @@ -1248,7 +1264,7 @@
const bootStart = performance.now();
runtime = await Verity.create(Backend.ProveKit, { threads });
runtimeBootMs = performance.now() - bootStart;
console.log(

Check warning on line 1267 in src/components/benchmarks-page/ProvekitDemo.astro

View workflow job for this annotation

GitHub Actions / build

Unexpected console statement. Only these console methods are allowed: warn, error
'[provekit-demo] runtime ready, threads:',
threads,
'· boot:',
Expand Down
59 changes: 47 additions & 12 deletions src/components/benchmarks/Benchmarks.astro
Original file line number Diff line number Diff line change
Expand Up @@ -93,17 +93,9 @@ const legend = [
<div class="pk-bench-sweep-rail" aria-hidden="true">
<div data-bench-sweep class="pk-bench-sweep-fill"></div>
</div>
<div
style="display:flex;align-items:center;justify-content:space-between;margin-bottom:24px;overflow:hidden"
>
<span
data-bench-label
class="pk-bench-chart-label pk-bench-anim"
style="font:400 14px/1 var(--pk-font-mono);letter-spacing:0.08em;text-transform:uppercase;color:var(--pk-mute-2)"
>
{labels[0]}
</span>
</div>
<span data-bench-label class="pk-bench-chart-label" aria-live="polite" style="display:none">
{labels[0]}
</span>
<div
class="pk-reveal"
style="flex:1;display:flex;flex-direction:column;justify-content:center;position:relative"
Expand Down Expand Up @@ -232,16 +224,25 @@ const legend = [
.pk-bench.is-exit .pk-bench-anim {
animation: pk-bench-out 220ms cubic-bezier(0.4, 0, 1, 1) forwards;
}
/* Stagger the enter animation to match the original design:
* legend+chart: 80ms delay, KPI strip: 160ms delay (per original animFor()). */
.pk-bench.is-enter .pk-bench-anim {
animation: pk-bench-in 620ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
.pk-bench.is-enter [data-bench-legend],
.pk-bench.is-enter [data-chart] {
animation-delay: 80ms;
}
.pk-bench.is-enter [data-kpis] {
animation-delay: 160ms;
}
.pk-bench.is-enter [data-bench-kpi] {
perspective: 600px;
display: inline-block;
}
.pk-bench.is-enter [data-bench-kpi] .pk-flip-num-char {
display: inline-block;
animation: pk-flip-num 600ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
animation-delay: 160ms;
transform-origin: center bottom;
}
@media (prefers-reduced-motion: reduce) {
Expand All @@ -252,6 +253,40 @@ const legend = [
}
}

@media (min-width: 721px) and (max-width: 1199px) {
.pk-bench {
flex-direction: column;
}
.pk-bench > div:first-child > div:nth-child(2) {
padding: var(--pk-pad-panel-y) var(--pk-pad-panel-x) !important;
gap: 28px !important;
}
.pk-bench > div:nth-child(2) {
border-left: 1px solid var(--pk-line) !important;
border-top: 0 !important;
}
.pk-bench > div:nth-child(2) > div:first-child {
padding: var(--pk-pad-panel-y) var(--pk-pad-panel-x) !important;
}
.pk-bench [data-kpis] > div {
padding: 28px 16px !important;
}
/* Scale down hardcoded h2 font size */
#benchmarks-title {
font-size: 36px !important;
line-height: 1.15 !important;
white-space: normal !important;
}
.pk-bench-num,
.pk-bench-title {
font-size: 20px !important;
}
.pk-bench-num + span,
.pk-bench-title + span {
font-size: 16px !important;
}
}

@media (max-width: 720px) {
.pk-bench {
flex-direction: column;
Expand Down
Loading
Loading