Skip to content
Snippets Groups Projects
Commit edbf84e7 authored by julientaq's avatar julientaq
Browse files

blog and articles

parent e0f182e0
No related branches found
No related tags found
No related merge requests found
......@@ -30,6 +30,14 @@ module.exports = function (eleventyConfig) {
});
eleventyConfig.addCollection("blog", collectionApi => {
return collectionApi.getFilteredByGlob("src/blog/posts/*.md").sort((a, b) => a.data.date - b.data.date);
});
eleventyConfig.addCollection("articles", collectionApi => {
return collectionApi.getFilteredByGlob("src/articles/*.md").sort((a, b) => a.data.date - b.data.date);
});
// eleventyConfig.addFilter("search", searchFilter);
// eleventyConfig.addFilter("searchSingle", searchFilterSingle);
......
File added
---
title: Articles
layout: blog-index.njk
layout: articles-index.njk
permalink: /articles/index.html
menu: False
menu: true
menutitle: Articles
class: articles
heading: We explain.
chapeau:
---
The latest news from Aperture!
\ No newline at end of file
This is where the articles will be
\ No newline at end of file
......@@ -2,7 +2,8 @@
title: News
layout: blog-index.njk
permalink: /blog/index.html
menu: False
menu: true
menutitle: blog
class: blog
---
......
{
"author": "Coko"
}
\ No newline at end of file
---
title: Aperture is Proud to Announce Upcoming Transition to Kotahi, an Open Source Modern Scholarly Publishing Platform
date: 2021-06-20
layout: blogpost.njk
intro: Kotahi is now in production for eLife for publishing reviews, and is supported by a wide group of interesting partners like <a href="https://www.eko-konnect.org.ng/">Eko-Konnect</a>, <a href="https://enableoa.amnet.com/">Amnet Systems</a>, and <a href="https://cloud68.co/">Cloud68</a>.
author: john Lingo
tags:
- blog
tags:
- kotahi
- something
- something else
---
......@@ -13,7 +15,7 @@ tags:
<p>Kotahi solves many of our current publishing platform limitations and we are really excited about its features. Like Aperture, a community driven open access publishing platform, Kotahi is also community driven. </p>
> we are really excited about its features
## we are really excited about its features
<p>To learn more about this new partnership visit the <a href="https://www.humanbrainmapping.org/i4a/pages/index.cfm?pageid=4081" target="_blank">Aperture Booth in the Exhibitor Hall</a> during the <a href="http://www.humanbrainmapping.org/i4a/pages/index.cfm?pageid=4054" target="_blank">OHBM 2021 Annual Meeting</a> Exhibitor Hours. Our Journal Manager, Kay Vanda, will be staffing the booth and running demos during select scheduled hours. We hope to see you virtually!</p>
......
---
title: Ag test
date: 2021-06-20
layout: blogpost.njk
author: john Lingo
author: john Lango Sr
tags:
- blog
---
......
{
"author": "Coko",
"layout": "blogpost.njk",
"permalink": "/blog/{{title | slugify}}.html"
}
\ No newline at end of file
---
title: Homepage
permalink: /index.html
layout: home.njk
class: home
heading: We build, you publish.
chapeau: Brief general presentation. The Coko team and community has built over a dozen highly successful publishing platforms – making us the most experienced folks in the business.
---
{% extends "base.njk" %}
{% block bodyclass %}article{% endblock %}
{% block content %}
<main>
{# <header>
<h1>{{title}}</h1>
</header> #}
<article class="post-content">
<header>
<h1>{{title}}</h1>
<time>{{date | postDate}}</time>
{% if intro %}
<section class="intro">{{intro | markdownify | safe }}</section>
{% endif %}
</header>
<section class="content">
{{ content | safe }}
</section>
</article>
{% set previousPost = collections.articles | getPreviousCollectionItem(page) %}
{% set nextPost = collections.articles | getNextCollectionItem(page) %}
<aside class="paginator
{% if previousPost and nextPost %} both {% endif %}">
{% if previousPost %}
<a class="previous" href="{{ previousPost.url }}">{{ previousPost.data.title }}</a>
{% endif %}
{% if nextPost %}
<a class="next" href="{{ nextPost.url }}">{{ nextPost.data.title }}</a>
{% endif %}
{# <a class="next" href="https://www.pagedjs.org/search/">Looking for something?</a>
<a class="next" href="https://www.pagedjs.org/search/">Looking for something?</a> #}
</aside>
</main>
{% endblock %}
\ No newline at end of file
{% extends "base.njk" %}
{% block content %}
<main>
<header>
<h1>{{title}}</h1>
{{ content | safe }}
</header>
{% for item in collections.articles -%}
<article class="item">
<header>
<p class="meta">
<time datetime="{{item.date}}">{{item.data.date | itemDate}}</time>
<span class="tags">
{% for tag in tags %}
<span>#{{tag}}</span>
{% endfor %}
</div>
</span>
<h2 id="{{item.data.title | slug}}">{{item.data.title}}</h2>
{% if item.data.author %}
<p class="author">Written by {{ item.data.author }}</p>
{% endif %}
</header>
<section class="content">
<section>
{{ item.data.content | safe }}
</section>
</section>
</article>
{%- endfor %}
</main>
{% endblock %}
\ No newline at end of file
......@@ -107,13 +107,15 @@
<header>
<h1>{{heading}}</h1>
<section class="intro">
<h2>{{chapeau}}</h2>
<p>{{chapeau}}</p>
</section>
</header>
{% endblock %}
{% block content %}
<article>
{{content | safe}}
</article>
{% endblock %}
</main>
......
......@@ -9,9 +9,36 @@
<h1>{{title}}</h1>
</header> #}
<section class="chap-content">
{{ content | safe }}
</section>
<article class="post-content">
<header>
<h1>{{title}}</h1>
<time>{{date | postDate}}</time>
{% if intro %}
<section class="intro">{{intro | markdownify | safe }}</section>
{% endif %}
</header>
<section class="content">
{{ content | safe }}
</section>
</article>
{# nextprevious #}
{% set previousPost = collections.blog | getPreviousCollectionItem(page) %}
{% set nextPost = collections.blog | getNextCollectionItem(page) %}
<aside class="paginator
{% if previousPost and nextPost %} both {% endif %}">
{% if previousPost %}
<a class="previous" href="{{ previousPost.url }}">{{ previousPost.data.title }}</a>
{% endif %}
{% if nextPost %}
<a class="next" href="{{ nextPost.url }}">{{ nextPost.data.title }}</a>
{% endif %}
{# <a class="next" href="https://www.pagedjs.org/search/">Looking for something?</a>
<a class="next" href="https://www.pagedjs.org/search/">Looking for something?</a> #}
</aside>
</main>
{% endblock %}
\ No newline at end of file
......@@ -6,41 +6,28 @@
{% endif %}
{% endblock %}
{% block content %}
<section class="section-latest">
<h2 class="section-title">Latest articles</h2>
{% block content %}
</section>
<section class="section-latest">
<h2 class="section-title">Latest articles</h2>
<section class="section-blog">
<h2 class="section-title">Latest from the blog</h2>
{% for article in collections.blog %}
{{collections.articles | log}}
<article class="posts">
<h3><a href="{{article.url}}">{{article.data.title}}</a></h3>
{% if article.data.intro %}
{{article.data.intro | markdownify | safe }}
{% endif %}
{% for article in collections.articleQuery %}
{# {{article.templateContent | markdownify | safe}} #}
</article>
{% endfor %}
</section>
<article class="post">
<h3>{{article.title}}</h3>
<section class="metadata">
<ul>
<li>Author: {{article.parsedSubmission.name}}</li>
<li>Published: {{article.publishedDate}}</li>
<li>Filename: {{article.files[0].filename}}</li>
<li>Short ID: {{article.shortId}}</li>
<li>Methods: {{article.parsedSubmission.methods}}</li>
<li>Packages: {{article.parsedSubmission.packages}}</li>
</ul>
</section>
</article>
{% endfor %}
</section>
<section class="section-blog">
<h2 class="section-title">Latest from the blog</h2>
</section>
{% endblock %}
{% endblock %}
\ No newline at end of file
......@@ -164,7 +164,6 @@ html {
.topbar nav {
width: 100%;
font-size: .7em;
letter-spacing: .15ch;
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment