diff --git a/www/layouts/partials/home_stories.html b/www/layouts/partials/home_stories.html index f45bbcc26..bbd129fc9 100644 --- a/www/layouts/partials/home_stories.html +++ b/www/layouts/partials/home_stories.html @@ -1,4 +1,5 @@ -{{- $stories := where .Site.RegularPages "Type" "==" "stories" -}} +{{- $featuredStories := .Site.Data.homepage.featured_stories.content | default slice -}} +{{- $stories := partial "filtered_pages" (dict "context" . "featuredPagesUid" $featuredStories) | default (where .Site.RegularPages "Type" "==" "stories") -}} {{- $storiesSection := .Site.GetPage "section" "stories" -}} {{- $breakdowns := dict "xs-sm" (dict "size" 1 "class" "d-flex d-md-none") diff --git a/www/layouts/stories/list.html b/www/layouts/stories/list.html index e2b350b34..d1bb8765b 100644 --- a/www/layouts/stories/list.html +++ b/www/layouts/stories/list.html @@ -1,14 +1,15 @@ {{ define "main" }} {{- $pages := .Site.RegularPages -}} -{{- $stories := where $pages "Type" "==" "stories" -}} +{{- $featuredStories := .Site.Data.homepage.featured_stories.content | default slice -}} +{{- $stories := partial "filtered_pages" (dict "context" . "featuredPagesUid" $featuredStories) | default (where $pages "Type" "==" "stories") -}}