From 53a24004d2d6423c68d9c0a12cd6e20852d736e2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Je=CC=81re=CC=81my=20Fabre?= Date: Wed, 8 Feb 2017 10:25:06 +0100 Subject: [PATCH] Add Twitter feeds styling --- app/static/src/sass/modules/_all.scss | 1 + app/static/src/sass/modules/_tweets.scss | 73 ++++++++++++++++++++++++ app/templates/twitter/tweets.html | 31 +++++----- 3 files changed, 91 insertions(+), 14 deletions(-) create mode 100644 app/static/src/sass/modules/_tweets.scss diff --git a/app/static/src/sass/modules/_all.scss b/app/static/src/sass/modules/_all.scss index 51a4da38..bb234c3e 100755 --- a/app/static/src/sass/modules/_all.scss +++ b/app/static/src/sass/modules/_all.scss @@ -65,6 +65,7 @@ @import 'map-legend'; @import 'linked-organizations'; @import 'newsletter'; +@import 'tweets'; @import 'hero'; // Typography modules diff --git a/app/static/src/sass/modules/_tweets.scss b/app/static/src/sass/modules/_tweets.scss new file mode 100644 index 00000000..f103fe63 --- /dev/null +++ b/app/static/src/sass/modules/_tweets.scss @@ -0,0 +1,73 @@ +$module: ".tweets"; + +#{$module} { + + list-style-type: none; + margin: 0; + padding: 0; + + &__tweet { + + @include margin-bottom(1); + + } + + &__tweet-image { + + width: 100%; + border-radius: 10px; + + } + + &__tweet-content { + + text-align: left; + + } + + &__tweet-author { + + margin: 0; + @include margin-bottom(.5); + color: white; + @include typeface(sans-serif); + @include font-size(m); + font-weight: weight(regular); + + a { + display: inline-block; + @include margin-left(.5); + color: white; + + &:hover { + color: $color-main; + } + } + + span { + display: inline-block; + @include margin-left(.5); + font-weight: weight(light); + } + + } + + &__tweet-body { + + @include typeface(sans-serif); + @include font-size(m); + font-weight: weight(light); + a { + display: inline-block; + @include margin-right(.25); + color: white; + font-weight: weight(regular); + + &:hover { + color: $color-main; + } + } + + } + +} diff --git a/app/templates/twitter/tweets.html b/app/templates/twitter/tweets.html index adba410e..739b89bd 100644 --- a/app/templates/twitter/tweets.html +++ b/app/templates/twitter/tweets.html @@ -4,21 +4,24 @@ {% tweets_default as tweets %} {% if tweets %} -

{% trans "Recent Tweets" %}

-