Extract a partial, update spacing
This commit is contained in:
parent
d5028b9110
commit
8cdf0dfc6e
|
@ -1,11 +1,11 @@
|
|||
<div class="spaced-y-1">
|
||||
<div class="spaced-y-px">
|
||||
<div class="spaced-y-2">
|
||||
<div class="spaced-y-2px">
|
||||
<h2 class="text-inherit text-lg m-0">
|
||||
{{ post.draft ? 'Draft: '|upper }}{{ post.title }}
|
||||
</h2>
|
||||
|
||||
{% if show_date %}
|
||||
<time class="text-sm mb-1 block" datetime="{{ post.date|date('Y-m-d') }}">{{ post.date|date('jS F Y') }}</time>
|
||||
{% include 'posts/post-date' with { class: 'text-sm block mb-1' } %}
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
|
|
|
@ -2,6 +2,6 @@
|
|||
<h1 class="leading-tight mb-2">{{ page.title }}</h1>
|
||||
|
||||
<p class="text-grey-dark">
|
||||
<span class="visuallyhidden">Posted on </span>{{ page.date|date('jS F Y') }}
|
||||
{% include 'posts/post-date' %}
|
||||
</p>
|
||||
</div>
|
||||
|
|
4
source/_partials/posts/post-date.html.twig
Normal file
4
source/_partials/posts/post-date.html.twig
Normal file
|
@ -0,0 +1,4 @@
|
|||
<time class="{{ class }}" datetime="{{ post.date|date('Y-m-d') }}">
|
||||
<span class="visuallyhidden">Posted on </span>
|
||||
{{ post.date|date('jS F Y') }}
|
||||
</time>
|
|
@ -31,6 +31,10 @@ module.exports = {
|
|||
'mono': ['Roboto Mono', ...defaultConfig.fonts.mono],
|
||||
},
|
||||
fontWeights: _.pick(defaultConfig.fontWeights, ['normal', 'medium', 'bold']),
|
||||
margin: {
|
||||
...defaultConfig.margin,
|
||||
'2px': '2px',
|
||||
},
|
||||
borderWidths: {
|
||||
...defaultConfig.borderWidths,
|
||||
'3': '3px',
|
||||
|
|
Reference in a new issue