File size: 9,352 Bytes
c697336 0146ab9 c697336 1d7522f 0146ab9 c697336 0146ab9 c697336 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 e88bf38 0146ab9 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 |
<script lang="ts">
import { page } from '$app/stores';
import { slide } from 'svelte/transition';
import '@unocss/reset/normalize.css';
import 'uno.css';
$: path = $page.route.id ?? '';
let user: null = null;
let menuOpen = false;
let date = new Date();
</script>
<svelte:head>
<meta property="og:site_name" content="Bergère Enchantée" />
{#if $page.data.title}
<title>{$page.data.title}</title>
<meta property="og:title" content={$page.data.title} />
<meta property="twitter:title" content={$page.data.title} />
{/if}
{#if $page.data.description}
<meta name="description" content={$page.data.description} />
<meta property="og:description" content={$page.data.description} />
<meta property="twitter:description" content={$page.data.description} />
{/if}
<meta property="og:type" content={$page.data.type || 'website'} />
<!-- {#if pictures.length > 0}
<meta
property="og:image"
content="{origin}/photos/raw/{shownPicture.storage.slice(-2)[0]._id}"
/>
<meta name="twitter:image" content="{origin}/photos/raw/{shownPicture.storage[0]._id}" />
<meta name="twitter:card" content="summary_large_image" />
{/if} -->
<!-- <meta property="og:url" content="{origin}{path}" /> -->
{#if $page.data.price}
<meta property="product:price:amount" content={$page.data.price} />
<meta property="product:price:currency" content="€" />
{/if}
</svelte:head>
<header class="bg-oxford py-2 flex items-center" style="font-family: Aileron">
<nav
class="bg-oxford text-xl font-bold flex grow px-2 sm:px-0 sm:text-center items-center text-white"
>
<a href="/" style="line-height: 0;" class="grow"
><img
src="/logo.svg"
alt="Logo"
title="Accueil"
class="h-14 w-14 sm:h-18 sm:w-18 md:h-24 md:w-24 lg:h-32 lg:w-32"
/></a
>
<a
href="/atelier"
class:text-sunray={path === '/atelier'}
class="hidden sm:inline py-4 grow hover:text-sunray">L'atelier</a
>
<a
href="/realisations"
class:text-sunray={path === '/realisations'}
class="hidden sm:inline py-4 grow hover:text-sunray">Réalisations</a
>
<a
href="/vente"
class:text-sunray={path === '/vente'}
class="hidden sm:inline py-4 grow hover:text-sunray">e-shop</a
>
<a
href="/tissus-et-finitions"
class:text-sunray={path === '/tissus-et-finitions'}
class="hidden py-4 sm:inline grow hover:text-sunray">Tissus / Finitions</a
>
<a
href="/contact"
class:text-sunray={path === '/contact'}
class="hidden sm:inline py-4 grow hover:text-sunray">Contact</a
>
{#if user}
<a href="/compte" title="Espace client" class="hidden sm:inline grow text-sunray text-3xl">
<div class="inline-block i-ant-design-user-outlined" />
</a>
{:else}
<a
href="/connexion"
title="Connexion"
class="hidden sm:inline grow text-sunray text-3xl inline-block"
>
<div class="inline-block i-ant-design-login-outlined" />
</a>
{/if}
<button
class="inline-flex flex-col justify-center sm:hidden cursor-pointer text-4xl transition"
class:text-white={!menuOpen}
class:text-sunray={menuOpen}
class:rotate-90={menuOpen}
on:click={() => (menuOpen = !menuOpen)}
>
<div class="inline-block i-ant-design-holder-outlined" />
</button>
</nav>
</header>
<main>
{#if menuOpen}
<nav
transition:slide
class="bg-oxford flex flex-col sm:hidden text-xl border-x-0 border-b-0 border-opacity-25 border-t-1 border-white font-bold items-center text-white"
>
<a href="/" class:text-sunray={path === '/'} class="my-2 hover:text-sunray">Accueil</a>
<a href="/atelier" class:text-sunray={path === '/atelier'} class="my-2 hover:text-sunray"
>L'atelier</a
>
<a
href="/realisations"
class:text-sunray={path === '/realisations'}
class="my-2 hover:text-sunray">Réalisations</a
>
<a href="/vente" class:text-sunray={path === '/vente'} class="my-2 hover:text-sunray"
>e-shop</a
>
<a
href="/tissus-et-finitions"
class:text-sunray={path === '/tissus'}
class="my-2 hover:text-sunray">Tissus / Finitions</a
>
<a href="/contact" class:text-sunray={path === '/contact'} class="my-2 hover:text-sunray"
>Contact</a
>
{#if user}
<a
href="/compte"
title="Espace client"
class="my-2 hover:text-sunray flex items-center justify-center"
>
<div class="inline-block mr-2 i-ant-design-user-outlined" />
Espace client
</a>
{:else}
<a
href="/connexion"
title="Connexion"
class="my-2 hover:text-sunray flex items-center justify-center"
>
<div class="inline-block mr-2 i-ant-design-login-outlined" />
Connexion
</a>
{/if}
</nav>
{/if}
<slot />
</main>
{#if !path.startsWith('/admin/')}
<footer class="bg-oxford w-full h-sm relative overflow-x-hidden flex items-center justify-center">
<img
src="/logo-no-chair.svg"
alt="Logo sans fauteuil"
class="pointer-events-none absolute select-none opacity-50 md:opacity-100 left-0 top-0 bottom-0"
style="transform: translate(-50%, 0);"
/>
<img
src="/logo-no-chair.svg"
alt="Logo sans fauteuil"
class="pointer-events-none absolute select-none opacity-50 md:opacity-100 top-0 bottom-0 right-0"
style="transform: translate(50%, 0);"
/>
<div class="text-white z-1 inline-block">
<div class="flex justify-center">
<a
rel="external"
href="https://facebook.com/bergereenchantee"
class="opacity-80 hover:opacity-100 bg-sunray rounded-full box-border inline-block mx-10"
style="width: 2rem; height: 2rem; padding: 0.35rem; padding-bottom: 0.25rem; padding-right: 0.3rem"
>
<div class="i-il-facebook inline-block text-oxford w-full h-full">bergereenchantee</div>
</a>
<a
rel="external"
href="https://instagram.com/bergereenchantee"
class="opacity-80 hover:opacity-100 bg-sunray rounded-full inline-block box-border mx-10"
style="width: 2rem; height: 2rem; padding: 0.35rem; padding-bottom: 0.25rem; padding-right: 0.3rem"
>
<div class="i-il-instagram inline-block text-oxford w-full h-full">bergereenchantee</div>
</a>
<a
rel="external"
href="mailto:contact@bergereenchantee.fr"
class="opacity-80 hover:opacity-100 bg-sunray rounded-full inline-block box-border mx-10"
style="width: 2rem; height: 2rem; padding: 0.35rem; padding-right: 0.3rem"
>
<div class="i-ant-design-mail-outlined inline-block text-oxford w-full h-full" />
</a>
</div>
<div class="my-14">
<a href="/" class:text-sunray={path === '/'} class="hover:text-sunray">Accueil</a> |
<a href="/atelier" class:text-sunray={path === '/atelier'} class="hover:text-sunray"
>L'atelier</a
>
|
<a
href="/realisations"
class:text-sunray={path === '/realisations'}
class="hover:text-sunray">Réalisations</a
>
|
<a href="/vente" class:text-sunray={path === '/vente'} class="hover:text-sunray">E-shop</a>
|
<a
href="/tissus-et-finitions"
class:text-sunray={path === '/tissus-et-finitions'}
class="hover:text-sunray">Tissus / Finitions</a
>
|
<a href="/contact" class:text-sunray={path === '/contact'} class="hover:text-sunray"
>Contact</a
>
</div>
<div class="text-center">
<a rel="external" href="https://www.sentinellesduweb.com" class="hover:underline"
>Les Sentinelles du Web</a
>
/ <a rel="external" href="https://coyo.dev" class="hover:underline">Coyotech</a> © {date.getFullYear()}
- Tous droits réservés
</div>
</div>
</footer>
{/if}
<style global>
body,
html {
margin: 0;
padding: 0;
height: 100%;
font-family: 'Gotham', sans-serif;
scroll-behavior: smooth;
--sunray: #d3a95a;
}
body {
display: grid;
grid-template-rows: min-content 1fr min-content;
}
a {
color: unset;
text-decoration: none;
}
h1,
h2,
h3 {
font-family: 'RiotSquad', serif;
margin: 0;
}
nav {
font-family: 'Aileron', sans-serif;
margin: 0;
}
ol,
ul {
padding: 0;
margin: 0;
}
li {
list-style-type: none;
}
@font-face {
font-family: 'Aileron';
src: url(/Ailerons-Typeface.otf) format('opentype');
}
@font-face {
font-family: 'RiotSquad';
src: url('/RIOTSQUA.ttf') format('truetype');
font-weight: normal;
font-style: normal;
}
/*
@font-face {
font-family: "Raleway";
src: url(/Raleway-VariableFont_wght.ttf) format("truetype");
}
@font-face {
font-family: "Raleway";
font-style: italic;
src: url(/Raleway-Italic-VariableFont_wght.ttf) format("truetype");
}
*/
@font-face {
font-family: 'Gotham';
font-weight: 400;
src: url(/GothamBook.ttf) format('truetype');
}
@font-face {
font-family: 'Gotham';
font-weight: 700;
src: url(/GothamBold.ttf) format('truetype');
}
.drop-white {
filter: drop-shadow(2px 2px 2px white);
}
.marked ul li {
margin-left: 1.5rem;
list-style-type: disc;
}
.h-full-without-banner {
height: calc(100vh - 1rem - (14rem / 4));
}
@media (min-width: 640px) {
.h-full-without-banner {
height: calc(100vh - 1rem - (18rem / 4));
}
}
@media (min-width: 768px) {
.h-full-without-banner {
height: calc(100vh - 1rem - (24rem / 4));
}
}
@media (min-width: 1024px) {
.h-full-without-banner {
height: calc(100vh - 1rem - (32rem / 4));
}
}
/*
@media (min-width: 1280px) { ... }
@media (min-width: 1536px) { ... }
*/
</style>
|