aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlban Gruin2017-09-09 15:37:05 +0200
committerAlban Gruin2017-09-09 15:37:05 +0200
commit163352652f5d0150a10e56496b1b772d17411466 (patch)
treeb8faf3fa4c045c4db56933db4aa4416f72b667c2
parent98242cad296b36423daf77e572d7735478d33f1d (diff)
Déplacement du style dans un fichier dédié
-rw-r--r--static/celcatsanitizer/style.css47
-rw-r--r--templates/index.html52
2 files changed, 49 insertions, 50 deletions
diff --git a/static/celcatsanitizer/style.css b/static/celcatsanitizer/style.css
new file mode 100644
index 0000000..825d140
--- /dev/null
+++ b/static/celcatsanitizer/style.css
@@ -0,0 +1,47 @@
+body {
+ max-width: 60em;
+ margin: 1em auto;
+ padding: 0 .62em;
+ font: 1.2em/1.62em sans-serif;
+ word-wrap: break-word;
+}
+
+h1, h2, h3 {
+ line-height: 1.2em;
+}
+
+a {
+ text-decoration: none;
+}
+
+a:hover, a:focus {
+ text-decoration: underline;
+}
+
+h1 a, h3 a, a.text {
+ color: #31363b;
+}
+
+.content {
+ max-width: 50em;
+ margin: 0 auto;
+}
+
+li {
+ line-height: 1.2em;
+ margin-bottom: 5px;
+}
+
+li.course {
+ margin-bottom: 20px;
+}
+
+@media print {
+ body, .content {
+ max-width: none;
+ }
+
+ header, footer, p.subscribe {
+ display: none;
+ }
+}
diff --git a/templates/index.html b/templates/index.html
index b30b5e1..f4b105c 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -1,58 +1,10 @@
-<!DOCTYPE html>
+{% load static %}<!DOCTYPE html>
<html lang="fr">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>{% block title %}{% endblock %}celcatsanitizer</title>
- <style>
-body {
- max-width: 60em;
- margin: 1em auto;
- padding: 0 .62em;
- font: 1.2em/1.62em sans-serif;
- word-wrap: break-word;
-}
-
-h1, h2, h3 {
- line-height: 1.2em;
-}
-
-a {
- text-decoration: none;
-}
-
-a:hover, a:focus {
- text-decoration: underline;
-}
-
-h1 a, h3 a, a.text {
- color: #31363b;
-}
-
-.content {
- max-width: 50em;
- margin: 0 auto;
-}
-
-li {
- line-height: 1.2em;
- margin-bottom: 5px;
-}
-
-li.course {
- margin-bottom: 20px;
-}
-
-@media print {
- body, .content {
- max-width: none;
- }
-
- header, footer, p.subscribe {
- display: none;
- }
-}
- </style>
+ <link rel="stylesheet" href="{% static "celcatsanitizer/style.css" %}">
</head>
<body>
<header>