Skip to content
Open
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
21 changes: 21 additions & 0 deletions packages/docs/src/components/BackLink.astro
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
---

<a href="/" class="back-link">← All frameworks</a>

<style>
.back-link {
display: inline-block;
margin-bottom: 1.5em;
color: var(--ft-accent);
text-decoration: none;
font-weight: 500;
transition: color 0.2s;
}

.back-link:hover {
color: var(--ft-accent-hover);
text-decoration: underline;
}
</style>
19 changes: 3 additions & 16 deletions packages/docs/src/components/FrameworkDetail.astro
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
import type { CollectionEntry } from 'astro:content'
import { formatBytesToMB, formatTimeMs } from '../lib/utils'
import DevTimeChart from './DevTimeChart.astro'
import '../styles/shared.css'
import BackLink from './BackLink.astro'
import DevTimeChart from './DevTimeChart.astro'

interface Props {
devtime: CollectionEntry<'devtime'>['data']
Expand All @@ -20,7 +21,7 @@ const measuredDateDisplay = (() => {
---

<div class="detail">
<a href="/" class="back-link">← All frameworks</a>
<BackLink />

<header class="detail-header">
<h1 class="detail-title">{devtime.name}</h1>
Expand Down Expand Up @@ -220,20 +221,6 @@ const measuredDateDisplay = (() => {
line-height: 1.5;
}

.back-link {
display: inline-block;
margin-bottom: 1.5em;
color: var(--ft-accent);
text-decoration: none;
font-weight: 500;
transition: color 0.2s;
}

.back-link:hover {
color: var(--ft-accent-hover);
text-decoration: underline;
}

.detail-header {
margin-bottom: 2em;
}
Expand Down
Loading
Loading