@@ -382,6 +382,15 @@ h5, | |||||
h6 { | h6 { | ||||
font-weight: 400; | font-weight: 400; | ||||
} | } | ||||
h1 a, | |||||
h2 a, | |||||
h3 a, | |||||
h4 a, | |||||
h5 a, | |||||
h6 a { | |||||
color: inherit !important; | |||||
text-decoration: none; | |||||
} | |||||
.navbar-brand { | .navbar-brand { | ||||
max-width: none; | max-width: none; | ||||
} | } | ||||
@@ -590,15 +599,6 @@ fieldset { | |||||
.web-list-item h3 { | .web-list-item h3 { | ||||
margin-top: 10px; | margin-top: 10px; | ||||
} | } | ||||
.web-list-item h1 a, | |||||
.web-list-item h2 a, | |||||
.web-list-item h3 a, | |||||
.web-list-item h4 a, | |||||
.web-list-item h5 a, | |||||
.web-list-item h6 a { | |||||
color: inherit !important; | |||||
text-decoration: none; | |||||
} | |||||
.web-list-item:last-child { | .web-list-item:last-child { | ||||
border-bottom: 0px; | border-bottom: 0px; | ||||
} | } | ||||
@@ -607,7 +607,6 @@ fieldset { | |||||
margin-top: 30px; | margin-top: 30px; | ||||
} | } | ||||
.post-description { | .post-description { | ||||
padding-top: 8px; | |||||
padding-bottom: 8px; | padding-bottom: 8px; | ||||
} | } | ||||
.post-description p { | .post-description p { | ||||
@@ -654,9 +653,8 @@ fieldset { | |||||
font-weight: 700; | font-weight: 700; | ||||
font-size: 2em; | font-size: 2em; | ||||
} | } | ||||
.blog-comments, | |||||
.help-article-comments { | |||||
padding: 0px 15px 15px 0px; | |||||
.add-comment-section { | |||||
padding-bottom: 30px; | |||||
} | } | ||||
.blog-comments { | .blog-comments { | ||||
background-color: #fafbfc; | background-color: #fafbfc; | ||||
@@ -916,7 +914,7 @@ body { | |||||
.your-account-info { | .your-account-info { | ||||
margin-top: 50px; | margin-top: 50px; | ||||
} | } | ||||
.page-content { | |||||
.page-content.with-sidebar { | |||||
padding-left: 50px; | padding-left: 50px; | ||||
padding-right: 50px; | padding-right: 50px; | ||||
} | } | ||||
@@ -952,11 +950,12 @@ li .social-child-item { | |||||
margin-bottom: 0px; | margin-bottom: 0px; | ||||
margin-top: 0px; | margin-top: 0px; | ||||
} | } | ||||
.comment-view { | |||||
padding: 30px 0px; | |||||
} | |||||
.comment-header { | .comment-header { | ||||
font-size: 20px; | |||||
padding-top: 30px; | |||||
padding-bottom: 20px; | padding-bottom: 20px; | ||||
border-bottom: 1px solid #d1d8dd; | |||||
border-bottom: 1px solid #EBEFF2; | |||||
} | } | ||||
.item-search { | .item-search { | ||||
border-bottom: 1px solid #d1d8dd; | border-bottom: 1px solid #d1d8dd; | ||||
@@ -25,7 +25,7 @@ frappe.ui.form.quick_entry = function(doctype, success) { | |||||
return; | return; | ||||
} | } | ||||
if(meta.autoname.toLowerCase()==='prompt') { | |||||
if(meta.autoname && meta.autoname.toLowerCase()==='prompt') { | |||||
mandatory = [{fieldname:'__name', label:__('{0} Name', [meta.name]), | mandatory = [{fieldname:'__name', label:__('{0} Name', [meta.name]), | ||||
reqd: 1, fieldtype:'Data'}].concat(mandatory); | reqd: 1, fieldtype:'Data'}].concat(mandatory); | ||||
} | } | ||||
@@ -20,6 +20,13 @@ a& { | |||||
h1, h2, h3, h4, h5, h6 { | h1, h2, h3, h4, h5, h6 { | ||||
font-weight: 400; | font-weight: 400; | ||||
// anchor inside header should not be styled | |||||
a { | |||||
color: inherit !important; | |||||
text-decoration: none; | |||||
} | |||||
} | } | ||||
@@ -275,13 +282,6 @@ fieldset { | |||||
h1, h2, h3 { | h1, h2, h3 { | ||||
margin-top: 10px; | margin-top: 10px; | ||||
} | } | ||||
h1, h2, h3, h4, h5, h6 { | |||||
a { | |||||
color: inherit !important; | |||||
text-decoration: none; | |||||
} | |||||
} | |||||
} | } | ||||
.web-list-item:last-child { | .web-list-item:last-child { | ||||
@@ -298,7 +298,6 @@ fieldset { | |||||
} | } | ||||
.post-description { | .post-description { | ||||
padding-top: 8px; | |||||
padding-bottom: 8px; | padding-bottom: 8px; | ||||
p { | p { | ||||
margin-bottom: 8px; | margin-bottom: 8px; | ||||
@@ -344,8 +343,8 @@ fieldset { | |||||
} | } | ||||
.blog-list-item { | .blog-list-item { | ||||
margin-top:30px; | |||||
margin-bottom:30px; | |||||
margin-top: 30px; | |||||
margin-bottom: 30px; | |||||
.blog-header { | .blog-header { | ||||
font-size: 1.6em; | font-size: 1.6em; | ||||
@@ -357,18 +356,21 @@ fieldset { | |||||
font-size: 2em; | font-size: 2em; | ||||
} | } | ||||
.add-comment-section { | |||||
padding-bottom: 30px; | |||||
} | |||||
.blog-comments, | .blog-comments, | ||||
.help-article-comments { | .help-article-comments { | ||||
padding: 0px 15px 15px 0px; | |||||
} | } | ||||
.blog-comments { | .blog-comments { | ||||
background-color: #fafbfc; | |||||
background-color: @light-bg; | |||||
position: relative; | position: relative; | ||||
} | } | ||||
.blog-comments:before { | .blog-comments:before { | ||||
content:""; | content:""; | ||||
background-color:#fafbfc; | |||||
background-color: @light-bg; | |||||
position: absolute; | position: absolute; | ||||
height: 100%; | height: 100%; | ||||
width: 4000px; | width: 4000px; | ||||
@@ -517,7 +519,8 @@ a.active { | |||||
.your-account-info { | .your-account-info { | ||||
margin-top: 50px; | margin-top: 50px; | ||||
} | } | ||||
.page-content { | |||||
.page-content.with-sidebar { | |||||
padding-left: 50px; | padding-left: 50px; | ||||
padding-right: 50px; | padding-right: 50px; | ||||
} | } | ||||
@@ -559,11 +562,13 @@ li .social-child-item { | |||||
margin-top:0px; | margin-top:0px; | ||||
} | } | ||||
.comment-view { | |||||
padding: 30px 0px; | |||||
} | |||||
.comment-header{ | .comment-header{ | ||||
font-size:20px; | |||||
padding-top:30px; | |||||
padding-bottom:20px; | padding-bottom:20px; | ||||
border-bottom: 1px solid @border-color; | |||||
border-bottom: 1px solid @light-border-color; | |||||
} | } | ||||
.item-search { | .item-search { | ||||
@@ -1,16 +1,17 @@ | |||||
{% extends "templates/web.html" %} | {% extends "templates/web.html" %} | ||||
{% block page_content %} | {% block page_content %} | ||||
<div class="blog-container"> | |||||
<article class="blog-content" itemscope itemtype="http://schema.org/BlogPosting"> | <article class="blog-content" itemscope itemtype="http://schema.org/BlogPosting"> | ||||
<meta itemprop="datePublished" content="{{ frappe.format_date(published_on) }}"></meta> | <meta itemprop="datePublished" content="{{ frappe.format_date(published_on) }}"></meta> | ||||
<meta itemprop="publisher" content="{{brand_html}}"></meta> | <meta itemprop="publisher" content="{{brand_html}}"></meta> | ||||
<!-- begin blog content --> | <!-- begin blog content --> | ||||
<div class="blog-info"> | <div class="blog-info"> | ||||
<h1 itemprop="headline" class="blog-header">{{ title }}</h1> | <h1 itemprop="headline" class="blog-header">{{ title }}</h1> | ||||
<p class="post-by text-muted small"> | |||||
<p class="post-by text-muted"> | |||||
<a href="/blog?by={{ blogger }}&by_name={{ full_name }}" class="no-decoration">By {{ blogger_info and blogger_info.full_name or full_name }}</a> | <a href="/blog?by={{ blogger }}&by_name={{ full_name }}" class="no-decoration">By {{ blogger_info and blogger_info.full_name or full_name }}</a> | ||||
<i class="blog-dot"></i> {{ frappe.format_date(published_on) }} | |||||
<i class="blog-dot"></i> <a href="/{{ parent_website_route }}" class="no-decoration">{{ blog_category }}</a> | |||||
<i class="blog-dot"></i> {{ frappe.format_date(published_on) }} | |||||
<i class="blog-dot"></i> <a href="/{{ parent_website_route }}" class="no-decoration">{{ blog_category }}</a> | |||||
<i class="blog-dot"></i> {{ comment_text }} | <i class="blog-dot"></i> {{ comment_text }} | ||||
</p> | </p> | ||||
</div> | </div> | ||||
@@ -25,12 +26,17 @@ | |||||
<div class="blog-comments"> | <div class="blog-comments"> | ||||
{% include 'templates/includes/comments/comments.html' %} | {% include 'templates/includes/comments/comments.html' %} | ||||
</div> | </div> | ||||
</div> | |||||
<script> | <script> | ||||
frappe.ready(function() { frappe.set_search_path("/blog"); }) | frappe.ready(function() { frappe.set_search_path("/blog"); }) | ||||
</script> | </script> | ||||
{% endblock %} | {% endblock %} | ||||
{% block style %} | {% block style %} | ||||
<style> | <style> | ||||
.blog-container { | |||||
width: 720px; | |||||
margin: auto; | |||||
} | |||||
.page-content { | .page-content { | ||||
padding-bottom: 0px; | padding-bottom: 0px; | ||||
} | } | ||||
@@ -16,12 +16,4 @@ | |||||
{% block script %} | {% block script %} | ||||
<script>{% include "templates/includes/list/list.js" %}</script> | <script>{% include "templates/includes/list/list.js" %}</script> | ||||
{% endblock %} | |||||
{% block style %} | |||||
<style> | |||||
.page-content { | |||||
padding: 0px; | |||||
} | |||||
</style> | |||||
{% endblock %} | |||||
{% endblock %} |
@@ -4,13 +4,12 @@ | |||||
<img itemprop="thumbnailUrl" src="{{ frappe.get_gravatar(comment.sender) }}" /> | <img itemprop="thumbnailUrl" src="{{ frappe.get_gravatar(comment.sender) }}" /> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
<div class="inline-block" style="width: calc(100% - 100px)"> | |||||
<h4 itemprop="name">{{ comment.sender_full_name }} | |||||
<small class="text-muted pull-right"> | |||||
<span itemprop="commentTime">{{ comment.creation|global_date_format }}</span> | |||||
</small> | |||||
</h4> | |||||
<div class="inline-block" style="width: calc(100% - 50px)"> | |||||
<h6 itemprop="name">{{ comment.sender_full_name }} | |||||
<span class="text-muted pull-right" itemprop="commentTime"> | |||||
{{ comment.creation|global_date_format }} | |||||
</span> | |||||
</h6> | |||||
<div itemprop="commentText">{{ comment.content|markdown }}</div> | <div itemprop="commentText">{{ comment.content|markdown }}</div> | ||||
</div> | </div> | ||||
</div> | </div> |
@@ -10,7 +10,7 @@ | |||||
{% include "templates/includes/web_sidebar.html" %} | {% include "templates/includes/web_sidebar.html" %} | ||||
</div> | </div> | ||||
{% endif %} | {% endif %} | ||||
<div class="{% if show_sidebar %}page-content col-sm-9{% else %} page-content col-sm-12 {% endif %}"> | |||||
<div class="{% if show_sidebar %}page-content with-sidebar col-sm-9{% else %} page-content col-sm-12 {% endif %}"> | |||||
<div class="page-content-wrapper"> | <div class="page-content-wrapper"> | ||||
<div class="row page-head"> | <div class="row page-head"> | ||||
<div class="col-sm-8"> | <div class="col-sm-8"> | ||||
@@ -75,7 +75,10 @@ class BlogPost(WebsiteGenerator): | |||||
if not context.comment_list: | if not context.comment_list: | ||||
context.comment_text = _('No comments yet') | context.comment_text = _('No comments yet') | ||||
else: | else: | ||||
context.comment_text = _('{0} comments').format(len(context.comment_list)) | |||||
if(len(context.comment_list)) == 1: | |||||
context.comment_text = _('1 comment') | |||||
else: | |||||
context.comment_text = _('{0} comments').format(len(context.comment_list)) | |||||
context.children = get_children() | context.children = get_children() | ||||