Customized CSS, footer

This commit is contained in:
Christoph Haas 2024-10-21 23:37:58 +02:00
parent 4d9df2bc30
commit 2fdf2840cb
5 changed files with 57 additions and 32 deletions

View file

@ -2,5 +2,8 @@
"editor.defaultFormatter": "esbenp.prettier-vscode", "editor.defaultFormatter": "esbenp.prettier-vscode",
"[javascript]": { "[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode" "editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[astro]": {
"editor.defaultFormatter": "astro-build.astro-vscode"
} }
} }

View file

@ -5,29 +5,36 @@ import sitemap from '@astrojs/sitemap';
// https://astro.build/config // https://astro.build/config
export default defineConfig({ export default defineConfig({
site: 'https://workaround.org', site: "https://workaround.org",
integrations: [ integrations: [
starlight({ starlight({
title: 'ISPmail Guide', lastUpdated: true,
sidebar: [ title: "ISPmail Guide",
{ components: {
label: 'Guides', Footer: "./src/components/Footer.astro",
items: [ },
// Each item here is one entry in the navigation menu. customCss: [
{ label: 'Start Here', slug: 'ispmail-bookworm' }, "./src/styles/custom.css",
], ],
}, sidebar: [
{ {
label: 'Reference', label: "Guides",
autogenerate: { directory: 'reference' }, items: [
}, // Each item here is one entry in the navigation menu.
], { label: "Start Here", slug: "ispmail-bookworm" },
logo: { ],
light: './src/assets/logo.svg', },
dark: './src/assets/logo-dark.svg', {
replacesTitle: true, label: "Reference",
}, autogenerate: { directory: "reference" },
}), },
sitemap() ],
], logo: {
light: "./src/assets/logo.svg",
dark: "./src/assets/logo-dark.svg",
replacesTitle: true,
},
}),
sitemap(),
],
}); });

View file

@ -1,3 +1,13 @@
---
import type { Props } from "@astrojs/starlight/props";
import Default from "@astrojs/starlight/components/Footer.astro";
---
<footer> <footer>
<p>&copy; 2024 Your Company Name. All rights reserved.</p> <Default {...Astro.props}><slot /></Default>
<div class="myfooter">
Copyright © 2024 Christoph Haas. All content on workaround.org can be used under the terms of the
<a href="https://creativecommons.org/licenses/by-nc-sa/4.0/" target="_blank">Creative Commons BY-NC-SA license</a>. Penguin images
based on AI art because I suck at drawing.
</div>
</footer> </footer>

View file

@ -7,9 +7,9 @@ hero:
image: image:
file: /public/large-pingu.jpg file: /public/large-pingu.jpg
actions: actions:
- text: Let's get into it - text: Let's build your mail server…
link: /ispmail-bookworm link: /ispmail-bookworm
icon: right-arrow icon: rocket
--- ---
import { Card, CardGrid } from '@astrojs/starlight/components'; import { Card, CardGrid } from '@astrojs/starlight/components';
@ -17,11 +17,11 @@ import { Card, CardGrid } from '@astrojs/starlight/components';
## Next steps ## Next steps
<CardGrid stagger> <CardGrid stagger>
<Card title="Update content" icon="pencil"> <Card title="Educational" icon="open-book">
Edit `src/content/docs/index.mdx` to see this page change. This is not a simple copy/paste walkthrough. You will learn the technical details of email exchange on the internet. And you will understand how the different pieces of software work and interact.
</Card> </Card>
<Card title="Add new content" icon="add-document"> <Card title="Free" icon="heart">
Add Markdown or MDX files to `src/content/docs` to create new pages. This guide is a not-for-profit fun project. You only need to get an internet domain and a cheap virtual server (~5€/$ per month). Powered by the desire to make the internet a bit more decentralized.
</Card> </Card>
<Card title="Configure your site" icon="setting"> <Card title="Configure your site" icon="setting">
Edit your `sidebar` and other config in `astro.config.mjs`. Edit your `sidebar` and other config in `astro.config.mjs`.

5
src/styles/custom.css Normal file
View file

@ -0,0 +1,5 @@
.myfooter {
color: darkgray;
padding-top: 1em;
font-size: 60%;
}