Skip to content

Commit c263456

Browse files
fix changing url with featured posts (#83)
* Change featured post * Move News above presentations Add conditional to hide events if there are none * url: stop url from changing Add new frontmatter var (boolean) to ensure url will no longer change when de-featuring a post --------- Co-authored-by: James Riordon <jriordon@outofcontrol.ca>
1 parent a975b50 commit c263456

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

_layouts/blogs.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,14 @@ <h1 class="title">{{page.title}}</h1>
1414
</div>
1515
</div>
1616

17-
{% assign featured_posts = site.posts | where: "categories", "featured" %}
17+
{% assign featured_posts = site.posts | where: "featured", true %}
1818
{% assign category_posts = featured_posts | where: "categories", "blog" %}
1919
{% if category_posts and category_posts.size > 0 %}
2020
<div class="section">
2121
<div class="container">
2222
<div class="row">
2323
<h3>Featured Blog
24-
<hr>
24+
<hr>
2525
</h3>
2626

2727
<div class="">

_layouts/news.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ <h1 class="title">{{page.title}}</h1>
1414
</div>
1515
</div>
1616

17-
{% assign featured_posts = site.posts | where: "categories", "featured" %}
17+
{% assign featured_posts = site.posts | where: "featured", true %}
1818
{% assign category_posts = featured_posts | where: "categories", "news" %}
1919
{% if category_posts and category_posts.size > 0 %}
2020
<div class="section">

_posts/2024-11-03-khronos-hosts-open-source-slang-shading-language-and-compiler.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ layout: post
33
title: "Khronos Hosts Open Source Slang Shading Language and Compiler"
44
date: 2024-11-21 10:00:00 +0000
55
categories: [ "news" ]
6-
tags: [khronos]
6+
tags: [ "khronos" ]
7+
featured: false
78
author: "The Khronos Group"
89
image: /images/posts/khronos-slang-logo.webp
910
source_url: https://www.khronos.org/news/press/khronos-group-launches-slang-initiative-hosting-open-source-compiler-contributed-by-nvidia

_posts/2025-04-04-neural-gfx-in-an-afternoon.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ title: "Neural Graphics in an Afternoon"
44
date: 2025-04-04 17:00:00
55
categories: [ "blog", "featured" ]
66
tags: [slang]
7+
featured: true
78
author: "Shannon Woods, NVIDIA, Slang Working Group Chair"
89
image: /images/posts/2025-04-04-splatterjeep.webp
910
human_date: "April 4, 2025"

0 commit comments

Comments
 (0)