fix: base path pour gitlab pages

main
Jalil Arfaoui 2023-01-30 23:07:02 +01:00
parent 1ad74002d2
commit ccf6421596
3 changed files with 5 additions and 4 deletions

View File

@ -3,5 +3,6 @@ import { defineConfig } from 'astro/config';
// https://astro.build/config // https://astro.build/config
export default defineConfig({ export default defineConfig({
publicDir: "./static", publicDir: "./static",
outDir: "./public" outDir: "./public",
base: "/les-particules-org"
}); });

View File

@ -11,11 +11,11 @@ const { title } = Astro.props;
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width" /> <meta name="viewport" content="width=device-width" />
<link rel="icon" type="image/svg+xml" href="/favicon.jpg" /> <link rel="icon" type="image/svg+xml" href="./favicon.jpg" />
<meta name="generator" content={Astro.generator} /> <meta name="generator" content={Astro.generator} />
<title>{title}</title> <title>{title}</title>
</head> </head>
<body style="background-image: url('logo_les-particules_orange.jpg'); min-height:100%"> <body style="background-image: url('${import.meta.env.BASE_URL}/logo_les-particules_orange.jpg'); min-height:100%">
<slot /> <slot />
</body> </body>
</html> </html>

View File

@ -6,7 +6,7 @@ import Card from '../components/Card.astro';
<Layout title="Welcome to Astro."> <Layout title="Welcome to Astro.">
<main> <main>
<h1 style="a"> <h1 style="a">
<img alt="Logo" src="/logo_les-particules_noir.jpg" style="width:80px; vertical-align: middle" /> <img alt="Logo" src="./logo_les-particules_noir.jpg" style="width:80px; vertical-align: middle" />
Les particules Les particules
</h1> </h1>
<p class="instructions"> <p class="instructions">