Skip to content

Commit

Permalink
Merge pull request #151 from techlore/featured-guides
Browse files Browse the repository at this point in the history
Add featured guides to /videos
  • Loading branch information
henry-fisher authored Dec 3, 2024
2 parents 216c0eb + e4bdc76 commit 9e3b434
Show file tree
Hide file tree
Showing 6 changed files with 56 additions and 194 deletions.
1 change: 1 addition & 0 deletions _data/_en/content.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ resources:
videos:
title: "Videos"
titleNewest: "Newest videos"
titleFeatured: "Featured guides"
titleArchive: "Older videos"
techlore:
title: "Techlore"
Expand Down
21 changes: 3 additions & 18 deletions _data/_en/navigation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,24 +66,9 @@ hiddenNav:
title: "Watch our explanation video"
url: "https://youtu.be/RbSy-lZHLYw"
external: true
allTechloreVideos:
title: "All Techlore videos"
url: "/videos/all-techlore-videos"
allTechloreClips:
title: "All Techlore clips"
url: "/videos/all-techlore-clips"
allSurveillanceReport:
title: "All SR Episodes"
url: "/videos/all-surveillance-report-episodes"
archivedTechloreVideos:
title: "Archived Techlore videos"
url: "/videos/archived-techlore-videos"
archivedTechloreClips:
title: "Archived Techlore Clips"
url: "/videos/archived-techlore-clips"
archivedSurveillanceReport:
title: "Archived SR episodes"
url: "/videos/archived-sr-episodes"
allTechloreGuides:
title: "All Techlore guides"
url: "/resources#techlore-guides"
affiliates:
title: "Techlore Tools & Affiliates"
url: "/affiliates"
Expand Down
52 changes: 0 additions & 52 deletions archive-videos-clips.html

This file was deleted.

52 changes: 0 additions & 52 deletions archive-videos-sr.html

This file was deleted.

52 changes: 0 additions & 52 deletions archive-videos-techlore.html

This file was deleted.

72 changes: 52 additions & 20 deletions videos.html
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,58 @@
</div>
</section>

<section>
<div class="container">
{%- include c_box-header.html title=t.videos.titleFeatured -%}
<div class="box has-footer">
<ul class="video-list marginless listless columns">
{% assign sortedVideos = site.guides | sort: "datePublished" | reverse %}
{% for video in sortedVideos limit: 4 %}
{% assign filename = video.path | split: "/" | last %}
{% assign videoThumbnail = "/guides/" | append: filename | replace: ".md", ".jpg" | relative_url %}

{%- include c_video.html
title=video.title
desc=video.description
link=video.linkForum
linkYouTube=video.linkYouTube
linkPeerTube=video.linkPeerTube
thumbnail=videoThumbnail
date=video.datePublished
tags=video.tags
-%}

{% endfor %}
</ul>
</div>
{% include c_box-footer.html
link=site.data._en.navigation.hiddenNav.allTechloreGuides.url
title=t.global.other.viewMore
%}
</div>
</section>

<section>
<div class="container is-max-tablet">
{% if t.goincognito.engageUser.title %}
<h2 class="has-text-centered">{{ t.goincognito.titleMore }}</h2>
{% endif %}

{% assign iconEngage = "iris-scan" %}
{% assign buttonLink = site.data._en.navigation.mainNav.goincognito.url | relative_url %}
{% include c_feature-box.html
icon=iconEngage
title=t.featureBox.tryIncognito.title
desc=t.featureBox.tryIncognito.desc
buttonText=t.featureBox.tryIncognito.buttonText
buttonLink=buttonLink
class="is-box-warning has-no-background has-border"
buttonClass="is-warning"
%}
</div>
</section>


<section>
<div class="container">
<div class="columns">
Expand Down Expand Up @@ -103,23 +155,3 @@
</div>
</div>
</section>

<section>
<div class="container is-max-tablet">
{% if t.goincognito.engageUser.title %}
<h2 class="has-text-centered">{{ t.goincognito.titleMore }}</h2>
{% endif %}

{% assign iconEngage = "iris-scan" %}
{% assign buttonLink = site.data._en.navigation.mainNav.goincognito.url | relative_url %}
{% include c_feature-box.html
icon=iconEngage
title=t.featureBox.tryIncognito.title
desc=t.featureBox.tryIncognito.desc
buttonText=t.featureBox.tryIncognito.buttonText
buttonLink=buttonLink
class="is-box-warning has-no-background has-border"
buttonClass="is-warning"
%}
</div>
</section>

0 comments on commit 9e3b434

Please sign in to comment.