Better blog detail pages
parent
ee8860a953
commit
020ede3a15
|
@ -14,6 +14,23 @@
|
|||
window.blog_post = true;
|
||||
{% endblock %}
|
||||
|
||||
{% block header %}
|
||||
<header class="main">
|
||||
<div class="inner group">
|
||||
<h1>
|
||||
<a href="/">
|
||||
{% if blog_user.username == 'nick' %}
|
||||
Nick Sergeant
|
||||
{% elif blog_user.username == 'blog' %}
|
||||
Snipt Blog
|
||||
{% else %}
|
||||
{{ blog_user.username }}
|
||||
{% endif %}
|
||||
</a>
|
||||
</h1>
|
||||
</div>
|
||||
</header>
|
||||
{% endblock %}
|
||||
{% block sub-header %}
|
||||
<header class="sub">
|
||||
<div class="inner group">
|
||||
|
@ -29,7 +46,6 @@
|
|||
</header>
|
||||
{% endblock %}
|
||||
{% block aside %}
|
||||
{% if not detail %}
|
||||
<aside class="main">
|
||||
{% if sidebar %}
|
||||
<section class="sidebar">
|
||||
|
@ -57,23 +73,4 @@
|
|||
</ul>
|
||||
</nav>
|
||||
</aside>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
{% block header %}
|
||||
<header class="main">
|
||||
<div class="inner group">
|
||||
<h1>
|
||||
<a href="/">
|
||||
{% if blog_user.username == 'nick' %}
|
||||
Nick Sergeant
|
||||
{% elif blog_user.username == 'blog' %}
|
||||
Snipt Blog
|
||||
{% else %}
|
||||
{{ blog_user.username }}
|
||||
{% endif %}
|
||||
</a>
|
||||
</h1>
|
||||
</div>
|
||||
</header>
|
||||
{% endblock %}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{% extends "blogs/themes/default/base.html" %}
|
||||
|
||||
{% block html-class %}detail blog-site blog-detail{% endblock %}
|
||||
{% block body-class %}detail blog-site blog-detail{% endblock %}
|
||||
{% block html-class %}blog-site blog-detail{% endblock %}
|
||||
{% block body-class %}blog-site blog-detail{% endblock %}
|
||||
|
||||
{% block js %}
|
||||
{{ block.super }}
|
||||
|
|
|
@ -41,11 +41,16 @@ def blog_post(request, username_or_custom_slug):
|
|||
slug=username_or_custom_slug,
|
||||
)
|
||||
|
||||
sidebar = get_object_or_None(Snipt,
|
||||
user=request.blog_user,
|
||||
title='Blog Sidebar')
|
||||
|
||||
context = {
|
||||
'blog_user': request.blog_user,
|
||||
'detail': True,
|
||||
'has_snipts': True,
|
||||
'public': True,
|
||||
'sidebar': sidebar,
|
||||
'snipt': snipt,
|
||||
}
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
body.blog-site article.snipt div.group div.container {
|
||||
width: 708px;
|
||||
width: 718px;
|
||||
}
|
||||
body.blog-site article.snipt div.group div.container header {
|
||||
min-height: 0;
|
||||
|
@ -78,12 +78,21 @@ body.blog-site header.sub div.inner {
|
|||
z-index: 51;
|
||||
}
|
||||
|
||||
body.blog-detail section.main div.inner {
|
||||
width: 718px;
|
||||
}
|
||||
body.blog-detail section.main div.inner section.snipts article.snipt {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
body.blog-detail section.main div.inner section.snipts article.snipt div.container {
|
||||
width: 939px;
|
||||
width: 100%;
|
||||
}
|
||||
body.blog-detail section.main div.inner section.snipts article.snipt div.container section.code {
|
||||
height: auto;
|
||||
}
|
||||
body.blog-detail div#disqus_thread {
|
||||
width: 925px;
|
||||
width: 704px;
|
||||
}
|
||||
body.blog-detail header.sub div.inner ul.bcrumb {
|
||||
width: 923px;
|
||||
body.blog-detail div#disqus_thread #dsq-content {
|
||||
margin-top: -38px;
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ body.blog-site {
|
|||
article.snipt {
|
||||
div.group {
|
||||
div.container {
|
||||
width: 708px;
|
||||
width: 718px;
|
||||
|
||||
header {
|
||||
min-height: 0;
|
||||
|
@ -114,23 +114,28 @@ body.blog-site {
|
|||
body.blog-detail {
|
||||
section.main {
|
||||
div.inner {
|
||||
width: 718px;
|
||||
|
||||
section.snipts {
|
||||
article.snipt {
|
||||
margin-bottom: 0;
|
||||
|
||||
div.container {
|
||||
width: 939px;
|
||||
width: 100%;
|
||||
|
||||
section.code {
|
||||
height: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
div#disqus_thread {
|
||||
width: 925px;
|
||||
}
|
||||
header.sub {
|
||||
div.inner {
|
||||
ul.bcrumb {
|
||||
width: 923px;
|
||||
}
|
||||
width: 704px;
|
||||
|
||||
#dsq-content {
|
||||
margin-top: -38px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue