base setup
This commit is contained in:
commit
688d794dc7
30 changed files with 4362 additions and 0 deletions
15
src/components/AstroImage.astro
Normal file
15
src/components/AstroImage.astro
Normal file
|
@ -0,0 +1,15 @@
|
|||
---
|
||||
import { Picture } from "@astrojs/image/components";
|
||||
|
||||
const { src, alt, width, height, ...attrs } = Astro.props;
|
||||
---
|
||||
|
||||
<Picture
|
||||
src={src}
|
||||
widths={[320, 640, 768, attrs.width]}
|
||||
aspectRatio={`${width}:${height}`}
|
||||
sizes={`(max-width: ${attrs.width}px) 100vw, ${attrs.width}px`}
|
||||
formats={["avif", "webp"]}
|
||||
alt={alt ? alt : ""}
|
||||
{...attrs}
|
||||
/>
|
5
src/components/ContentPost.astro
Normal file
5
src/components/ContentPost.astro
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
const { title, url } = Astro.props;
|
||||
---
|
||||
|
||||
<a href={url}>{title}</a>
|
7
src/components/Header.astro
Normal file
7
src/components/Header.astro
Normal file
|
@ -0,0 +1,7 @@
|
|||
---
|
||||
import Navigation from '../components/Navigation.astro';
|
||||
---
|
||||
|
||||
<header role="banner">
|
||||
<Navigation />
|
||||
</header>
|
10
src/components/Navigation.astro
Normal file
10
src/components/Navigation.astro
Normal file
|
@ -0,0 +1,10 @@
|
|||
---
|
||||
|
||||
---
|
||||
<nav role="navigation" aria-label="Navigation principale">
|
||||
<ul>
|
||||
<li><a href="/">Accueil</a></li>
|
||||
<li><a href="/articles/">Articles</a></li>
|
||||
<li><a href="/tags/">Catégories</a></li>
|
||||
</ul>
|
||||
</nav>
|
Loading…
Add table
Add a link
Reference in a new issue