From edb43558b86bb8b6d2a38b8f96eee20ed4178753 Mon Sep 17 00:00:00 2001 From: Samuel Clay Date: Fri, 29 Jun 2012 00:17:07 -0700 Subject: [PATCH] Adding pleasure border to blurblog posts. --- apps/reader/views.py | 8 +- media/css/social/social_page.css | 45 +++++--- templates/social/social_page.xhtml | 168 +++++++++++++++-------------- 3 files changed, 118 insertions(+), 103 deletions(-) diff --git a/apps/reader/views.py b/apps/reader/views.py index 9290b8d10..083f976bf 100644 --- a/apps/reader/views.py +++ b/apps/reader/views.py @@ -244,13 +244,11 @@ def load_feeds(request): def load_feed_favicons(request): user = get_user(request) feed_ids = request.REQUEST.getlist('feed_ids') - user_subs = UserSubscription.objects.select_related('feed').filter(user=user, active=True) - # Removed these lines because they check if the user is subscribed to the feed. - # if feed_ids and len(feed_ids) > 0: - # user_subs = user_subs.filter(feed__in=feed_ids) + if not feed_ids: + user_subs = UserSubscription.objects.select_related('feed').filter(user=user, active=True) + feed_ids = [sub['feed__pk'] for sub in user_subs.values('feed__pk')] - feed_ids = [sub['feed__pk'] for sub in user_subs.values('feed__pk')] feed_icons = dict([(i.feed_id, i.data) for i in MFeedIcon.objects(feed_id__in=feed_ids)]) return feed_icons diff --git a/media/css/social/social_page.css b/media/css/social/social_page.css index 3f264a0bd..42135a80d 100644 --- a/media/css/social/social_page.css +++ b/media/css/social/social_page.css @@ -160,8 +160,8 @@ header { .NB-mark { margin: 0 auto 36px; max-width: 800px; - background-color: #F6F6F6; - border-radius: 4px; + border-top-left-radius: 6px; + border-top-right-radius: 6px; overflow: hidden; } @@ -238,7 +238,13 @@ header { #E9EAEF 10%, #F5F8FA 84% ); + border-top: 1px solid #C0C0C0; +} + +.NB-story-header-wrapper { border-bottom: 1px solid #D0D0D0; + border-right: 1px solid #909090; + border-left: 1px solid #909090; } @media all and (max-width: 800px) { @@ -336,50 +342,59 @@ header { } .NB-story { - margin: 0 28px; - padding: 12px 200px 24px 0; + background-color: #FAFAFA; + padding: 0 28px; max-width: 800px; + border-right: 1px solid #909090; + border-bottom: 1px solid #909090; + border-left: 1px solid #909090; + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; } +.NB-story-content { + padding: 12px 200px 24px 0; +} @media all and (max-width: 800px) { - .NB-story { + .NB-story-content { padding-right: 100px; } } @media all and (max-width: 700px) { - .NB-story { + .NB-story-content { padding-right: 50px; } } @media all and (max-width: 600px) { - .NB-story { + .NB-story-content { padding-right: 0px; } } -.NB-story a { +.NB-story-content a { color: #1F4499; } -.NB-story a:hover { +.NB-story-content a:hover { color: #99481D; } -.NB-story img { +.NB-story-content img { max-width: 100%; + height: auto; } -.NB-story ins { +.NB-story-content ins { text-decoration: none; color: inherit; } -.NB-story del { +.NB-story-content del { display: none; } -.NB-pref-show-changes .NB-story ins { +.NB-pref-show-changes .NB-story-content ins { text-decoration: underline; color: #27452D; } -.NB-pref-show-changes .NB-story del { +.NB-pref-show-changes .NB-story-content del { display: block; color: #661616; } @@ -398,7 +413,7 @@ header { border: none; } .NB-story-comments { - margin: 0 28px 32px 28px; + margin: 0 0 32px 0; padding: 1px 0 0; max-width: 800px; border-top: 2px solid #353535; diff --git a/templates/social/social_page.xhtml b/templates/social/social_page.xhtml index f3332a253..3a390e23e 100644 --- a/templates/social/social_page.xhtml +++ b/templates/social/social_page.xhtml @@ -75,107 +75,109 @@ {% endif %} -
- {% if story.story_authors %} - - {% endif %} - {% if story.story_tags %} - - {% endif %} -
- {{ story.story_title }} -
-