Просмотр исходного кода

:bug: Center the newsletter lede in the footer

.awesome-django-footer p set margin: 0.6rem 0. That selector outranks
the single-class rule on the lede, so its margin: auto never applied and
the paragraph sat left of everything else.

Use auto horizontal margins on the shared paragraph rule, and cap every
footer paragraph at the same 34rem as the signup form and the webring,
so the whole footer reads as one column.
Jeff Triplett 4 дней назад
Родитель
Сommit
a73674a1bc
1 измененных файлов с 6 добавлено и 4 удалено
  1. 6 4
      docs/stylesheets/django.css

+ 6 - 4
docs/stylesheets/django.css

@@ -88,8 +88,6 @@
 }
 
 .awesome-django-footer__lede {
-  margin: 0 auto 0.9rem;
-  max-width: 34rem;
   font-size: 0.72rem;
 }
 
@@ -104,7 +102,7 @@
 
 /* Capped to match the webring below it, so neither spans the whole footer. */
 .awesome-django-newsletter {
-  margin: 0 auto;
+  margin: 0.9rem auto 0;
   max-width: 34rem;
 }
 
@@ -114,8 +112,12 @@
   border: 1px solid #ccc;
 }
 
+/* auto, not 0, for the horizontal margins. This rule outranks the single-class
+   rules below it, so a 0 here would stop them centering themselves. Every
+   paragraph shares the 34rem column with the signup form and the webring. */
 .awesome-django-footer p {
-  margin: 0.6rem 0;
+  margin: 0.6rem auto;
+  max-width: 34rem;
 }
 
 /*