Page summary view template
This commit is contained in:
parent
bc73df76cf
commit
11a677476b
2 changed files with 21 additions and 6 deletions
|
@ -2,24 +2,25 @@
|
|||
# COMPONENT: PAGE SUMMARY
|
||||
**************************/
|
||||
|
||||
.summary {
|
||||
.page-summary {
|
||||
&:not(:last-child) {
|
||||
margin-block-end: var(--space-l);
|
||||
}
|
||||
|
||||
.summary__post-title {
|
||||
.page-summary__title {
|
||||
margin-block: 0 var(--space-xs);
|
||||
}
|
||||
|
||||
.summary__post-subtitle {
|
||||
font-weight: 500;
|
||||
.page-summary__subtitle {
|
||||
font-family: var(--font-family-heading);
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.summary__content {
|
||||
.page-summary__content {
|
||||
margin-block-end: var(--space-m);
|
||||
}
|
||||
|
||||
:is(.summary__post-title, .summary__post-subtitle):last-child {
|
||||
:is(.page-summary__title, .page-summary__subtitle):last-child {
|
||||
margin-block-end: var(--space-m);
|
||||
}
|
||||
}
|
||||
|
|
14
layouts/_default/page_summary.html
Normal file
14
layouts/_default/page_summary.html
Normal file
|
@ -0,0 +1,14 @@
|
|||
<article class="page-summary">
|
||||
<header>
|
||||
<h2 class="page-summary__title">{{ .Title }}</h2>
|
||||
{{ with .Params.subtitle | default .Description | markdownify }}
|
||||
<p class="page-summary__subtitle">{{ . }}</p>
|
||||
{{ end }}
|
||||
</header>
|
||||
<div class="page-summary__content">
|
||||
{{ .Summary }}
|
||||
</div>
|
||||
<footer class="page-summary__footer">
|
||||
<a href="{{ .RelPermalink }}">More →</a>
|
||||
</footer>
|
||||
</article>
|
Loading…
Add table
Add a link
Reference in a new issue