Skip to content

Worktrunk is a CLI for Git worktree management, designed for parallel AI agent workflows

docs: simplify page footer (#3876)

Maximilian Roos952a40293cae
diff --git a/docs/astro.config.mjs b/docs/astro.config.mjs
index 50231b946..4c88ac234 100644
--- a/docs/astro.config.mjs
+++ b/docs/astro.config.mjs
@@ -49,9 +49,9 @@ export default defineConfig({
},
customCss: ['./src/styles/custom.css'],
components: {
- Footer: './src/components/Footer.astro',
Head: './src/components/Head.astro',
PageTitle: './src/components/PageTitle.astro',
+ Pagination: './src/components/Pagination.astro',
SocialIcons: './src/components/SocialIcons.astro',
ThemeSelect: './src/components/ThemeSelect.astro',
},
diff --git a/docs/src/components/Footer.astro b/docs/src/components/Footer.astro
deleted file mode 100644
index fb3efc32b..000000000
--- a/docs/src/components/Footer.astro
+++ /dev/null
@@ -1,51 +0,0 @@
----
-import DefaultFooter from '@astrojs/starlight/components/Footer.astro';
-
-const links = [
- ['GitHub', 'https://github.com/max-sixty/worktrunk'],
- ['crates.io', 'https://crates.io/crates/worktrunk'],
- [
- 'Share on X',
- 'https://twitter.com/intent/tweet?text=Worktrunk%20%E2%80%94%20CLI%20for%20git%20worktree%20management&url=https%3A%2F%2Fworktrunk.dev',
- ],
- [
- 'Reddit',
- 'https://www.reddit.com/submit?url=https%3A%2F%2Fworktrunk.dev&title=Worktrunk%20%E2%80%94%20CLI%20for%20git%20worktree%20management',
- ],
- ['LinkedIn', 'https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fworktrunk.dev'],
-] as const;
----
-
-<div class="wt-footer-stack">
- <DefaultFooter><slot /></DefaultFooter>
- <nav class="wt-project-links" data-contract="project-links" aria-label="Project links">
- {links.map(([label, href]) => <a href={href}>{label}</a>)}
- </nav>
-</div>
-
-<style>
- .wt-project-links {
- box-sizing: border-box;
- display: flex;
- flex-wrap: wrap;
- gap: 0.45rem 1.15rem;
- width: min(calc(100% - 2rem), 53.75rem);
- margin: 2rem auto 0;
- border-block-start: 1px solid var(--wt-line);
- padding-block: 1rem 2rem;
- font-family: var(--sl-font-mono);
- font-size: 0.68rem;
- letter-spacing: 0.045em;
- }
-
- .wt-project-links a {
- color: var(--wt-ink-muted);
- text-decoration: none;
- }
-
- .wt-project-links a:hover {
- color: var(--wt-copper);
- text-decoration: underline;
- text-underline-offset: 0.2em;
- }
-</style>
diff --git a/docs/src/components/Pagination.astro b/docs/src/components/Pagination.astro
new file mode 100644
index 000000000..7617b9f6b
--- /dev/null
+++ b/docs/src/components/Pagination.astro
@@ -0,0 +1,3 @@
+---
+// The persistent sidebar provides page navigation without a second sequence at the page end.
+---
diff --git a/docs/src/styles/custom.css b/docs/src/styles/custom.css
index 1b08bef84..3613a855e 100644
--- a/docs/src/styles/custom.css
+++ b/docs/src/styles/custom.css
@@ -97,53 +97,6 @@ h4 {
letter-spacing: -0.025em;
}
-/* Page sequence is quiet editorial navigation, not a pair of feature cards. */
-.pagination-links {
- grid-template-columns: repeat(2, minmax(0, 1fr));
- gap: 1rem;
- border-block-start: 1px solid var(--wt-line);
- padding-block-start: 0.9rem;
-}
-
-.pagination-links:empty {
- display: none;
-}
-
-.pagination-links a {
- min-width: 0;
- border: 0;
- border-radius: 0;
- padding: 0.25rem 0;
- background: transparent;
- color: var(--wt-ink-muted);
- font-family: var(--sl-font-mono);
- font-size: 0.66rem;
- font-weight: 500;
- letter-spacing: 0.08em;
- line-height: 1.35;
- text-transform: uppercase;
- box-shadow: none;
-}
-
-.pagination-links a:hover {
- color: var(--wt-copper);
-}
-
-.pagination-links .link-title {
- color: var(--wt-ink);
- font-family: var(--sl-font);
- font-size: 0.92rem;
- font-weight: 500;
- letter-spacing: 0;
- line-height: 1.3;
- text-transform: none;
-}
-
-.pagination-links svg {
- width: 1rem;
- color: var(--wt-copper);
-}
-
.site-title {
color: var(--wt-ink);
font-family: 'Inter', system-ui, sans-serif;
@@ -163,7 +116,7 @@ h4 {
header.header {
border-block-end-color: color-mix(in srgb, var(--wt-line) 75%, transparent);
- background: color-mix(in srgb, var(--wt-paper-raised) 92%, transparent);
+ background: var(--wt-paper-raised);
}
.right-group .social-icons::after {
diff --git a/docs/tests/built-site.test.mjs b/docs/tests/built-site.test.mjs
index b8daea194..3ad80d2cb 100644
--- a/docs/tests/built-site.test.mjs
+++ b/docs/tests/built-site.test.mjs
@@ -172,12 +172,6 @@ test('build preserves the public route contract', async () => {
assert.equal(comparison.match(/<td data-label="Plain git">/g)?.length, 4);
assert.match(homepage, /class="wt-positive"/);
assert.match(homepage, /class="wt-negative"/);
- assert.match(homepage, /<nav\b[^>]*data-contract="project-links"[^>]*aria-label="Project links"/);
- assert.match(homepage, /href="https:\/\/crates\.io\/crates\/worktrunk"/);
- assert.match(homepage, /href="https:\/\/twitter\.com\/intent\/tweet\?/);
- assert.match(homepage, /href="https:\/\/www\.reddit\.com\/submit\?/);
- assert.match(homepage, /href="https:\/\/www\.linkedin\.com\/sharing\/share-offsite\/\?/);
-
const switchPage = await readFile(routeFile('/switch/'), 'utf8');
assert.match(switchPage, /<nav aria-labelledby="starlight__on-this-page">/);
assert.match(
@@ -228,6 +222,22 @@ test('build preserves the public route contract', async () => {
}
});
+test('built pages omit low-value footer navigation', async () => {
+ for (const page of renderedPages) {
+ const html = await readFile(page, 'utf8');
+ assert.doesNotMatch(
+ html,
+ /class="[^"]*\bpagination-links\b/,
+ `${page} renders previous/next pagination`,
+ );
+ assert.doesNotMatch(
+ html,
+ /data-contract="project-links"/,
+ `${page} renders duplicate project links`,
+ );
+ }
+});
+
test('nested command references expose unique search-only fragment titles', async () => {
const stepPage = await readFile(routeFile('/step/'), 'utf8');
assert.match(stepPage, /<h2 id="command-reference">Command reference<\/h2>/);