aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--design/Main.hs2
-rw-r--r--src/Main.hs4
-rw-r--r--templates/index.html (renamed from templates/main.html)2
-rw-r--r--templates/recipe.html16
4 files changed, 20 insertions, 4 deletions
diff --git a/design/Main.hs b/design/Main.hs
index 0af225d..b057cb4 100644
--- a/design/Main.hs
+++ b/design/Main.hs
@@ -19,7 +19,7 @@ main = putCss $ do
mobile $ fontSize (px 14)
desktop $ fontSize (px 18)
- "a.header" ? do
+ ".header" ? do
display block
sym2 padding (px 15) (px 0)
sym2 margin (px 0) auto
diff --git a/src/Main.hs b/src/Main.hs
index 72a4de8..50a562d 100644
--- a/src/Main.hs
+++ b/src/Main.hs
@@ -30,7 +30,7 @@ main = hakyllWith configuration $ do
match "recettes/**" $ do
route $ setExtension "html"
compile $ pandocCompiler
- >>= loadAndApplyTemplate "templates/main.html" defaultContext
+ >>= loadAndApplyTemplate "templates/recipe.html" defaultContext
>>= relativizeUrls
match "index.html" $ do
@@ -44,7 +44,7 @@ main = hakyllWith configuration $ do
compile $
getResourceBody
>>= applyAsTemplate context
- >>= loadAndApplyTemplate "templates/main.html" context
+ >>= loadAndApplyTemplate "templates/index.html" context
>>= relativizeUrls
match "templates/*" $ compile templateBodyCompiler
diff --git a/templates/main.html b/templates/index.html
index 5957668..e6faafd 100644
--- a/templates/main.html
+++ b/templates/index.html
@@ -8,7 +8,7 @@
<link rel="icon" href="/images/icon.png">
</head>
<body>
- <a href="/" class="header">$title$</a>
+ <div class="header">$title$</div>
<div id="content">$body$</div>
<script src="/main.js"></script>
</body>
diff --git a/templates/recipe.html b/templates/recipe.html
new file mode 100644
index 0000000..6585f33
--- /dev/null
+++ b/templates/recipe.html
@@ -0,0 +1,16 @@
+<!DOCTYPE html>
+<html lang="fr">
+ <head>
+ <meta charset="utf-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <title>$title$</title>
+ <link rel="stylesheet" href="/main.css" />
+ <link rel="icon" href="/images/icon.png">
+ </head>
+ <body>
+ <div class="header">$title$</div>
+ <a href="/">тна Retour</a>
+ <div id="content">$body$</div>
+ <script src="/main.js"></script>
+ </body>
+</html>