34 lines
		
	
	
		
			943 B
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			34 lines
		
	
	
		
			943 B
		
	
	
	
		
			HTML
		
	
	
	
	
	
{% extends "_default/base.html" %}
 | 
						|
<!-- News template
 | 
						|
the template for displaying the news page.
 | 
						|
consists of a featured news row, 
 | 
						|
a paginated list of posts (sorted by date), 
 | 
						|
and a side nav for category and featured post navigation
 | 
						|
-->
 | 
						|
 | 
						|
{% block content %}
 | 
						|
 | 
						|
<main>
 | 
						|
 | 
						|
    <!--sets global featured variable as the most recent post with the isFeatured tag-->
 | 
						|
    {%- set section = get_section(path="newsroom/_index.md") %}
 | 
						|
    {% for page in section.pages %}
 | 
						|
    {% if page.extra.isFeatured %}
 | 
						|
        {%- set_global featured = page %}
 | 
						|
        {% break %}
 | 
						|
    {% endif %}
 | 
						|
    {% if not featured %} 
 | 
						|
        {%- set_global featured = section.pages[0] %}
 | 
						|
    {% endif %}
 | 
						|
    {% endfor %}
 | 
						|
    
 | 
						|
    {% include "partials/featuredNews.html" %}
 | 
						|
 | 
						|
    <div class="flex flex-col md:flex-row container mx-auto">
 | 
						|
        {% include "partials/newsPosts.html" %}
 | 
						|
        {% include "partials/newsSidebar.html" %}
 | 
						|
    </div>
 | 
						|
 </main> 
 | 
						|
 
 | 
						|
 {% endblock content %}
 |