Skip to content

Commit e164e54

Browse files
authored
Merge pull request #1 from makerforgetech/feature/theme_upgrade
Feature/theme upgrade
2 parents 677ee11 + 0df8611 commit e164e54

File tree

157 files changed

+860
-101417
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+860
-101417
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
_site/*
1+
_site

_config.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ timezone: Europe/London
2020

2121
title: Maker Forge # the main title
2222

23-
tagline: Open source robotics and technology # it will display as the sub-title
23+
tagline: We forge makers # it will display as the sub-title
2424

2525
description: >- # used by seo meta and the atom feed
2626
Guides and news relating to Maker Forge projects and videos.
@@ -60,7 +60,7 @@ google_analytics:
6060
# light - Use the light color scheme
6161
# dark - Use the dark color scheme
6262
#
63-
theme_mode: # [light|dark]
63+
theme_mode: light # [light|dark]
6464

6565
# The CDN endpoint for images.
6666
# Notice that once it is assigned, the CDN url

_includes/head.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<meta name="google-adsense-account" content="ca-pub-2442495657220975">
1414
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-2442495657220975"
1515
crossorigin="anonymous"></script>
16-
16+
1717
{% capture seo_tags %}
1818
{% seo title=false %}
1919
{% endcapture %}
@@ -82,6 +82,8 @@
8282
{% if site.toc and page.toc %}
8383
<link rel="stylesheet" href="{{ site.data.origin[type].toc.css | relative_url }}">
8484
{% endif %}
85+
86+
<link rel="stylesheet" href="/assets/css/makerforge.css" />
8587
<!--
8688
{% if page.layout == 'post' or page.layout == 'page' or page.layout == 'home' %}
8789
<link rel="stylesheet" href="{{ site.data.origin[type]['lazy-polyfill'].css | relative_url }}">

_includes/intro.html

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
<article class="px-1">
2+
<p>
3+
The mission of Maker Forge is to inspire and empower makers, hobbyists, and
4+
enthusiasts to explore the world of open-source robotics, electronics & 3D
5+
printing. Whether you're a seasoned pro or just starting out, the projects
6+
and resources here are designed to help you unleash your creativity and
7+
bring your ideas to life.
8+
</p>
9+
</article>
10+
11+
<section class="projects-section px-1">
12+
<h2>Check out the Projects</h2>
13+
<div class="project-grid">
14+
<article class="project-card">
15+
<a href="/cm5-carrier-board">
16+
<img
17+
src="/assets/project_thumb_cm5.png"
18+
alt="CM5 Carrier Board"
19+
/>
20+
<h3>CM5 Carrier Board</h3>
21+
</a>
22+
<p>
23+
Streamline the Raspberry Pi 5 for robotics with this custom carrier board designed for the Compute Module 5.
24+
</p>
25+
</article>
26+
<article class="project-card">
27+
<a href="/modular-biped">
28+
<img
29+
src="/assets/project_thumb_buddy.jpg"
30+
alt="Modular Biped Robot"
31+
/>
32+
<h3>Modular Biped Robot</h3>
33+
</a>
34+
<p>
35+
A walking robot built using 3D-printed parts and Arduino, designed for
36+
modular experimentation.
37+
</p>
38+
</article>
39+
40+
<article class="project-card">
41+
<a href="/lightsaber">
42+
<img
43+
src="/assets/project_thumb_lightsaber.jpg"
44+
alt="Raspberry Pi Pico Lightsaber"
45+
/>
46+
<h3>Raspberry Pi Pico Lightsaber</h3>
47+
</a>
48+
<p>Build a lightsaber hilt with a Raspberry Pi Pico and Neopixels</p>
49+
</article>
50+
51+
<article class="project-card">
52+
<a href="/magic-map">
53+
<img
54+
src="/assets/project_thumb_map.jpg"
55+
alt="Magic Map"
56+
/>
57+
<h3>Magic Map</h3>
58+
</a>
59+
<p>
60+
Build a Harry Potter style map that shows the location of a user using a
61+
hidden LED matrix
62+
</p>
63+
</article>
64+
</div>
65+
</section>
66+
67+
<h2>Read the Articles</h2>

_includes/sidebar.html

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
<!-- The Side Bar -->
2+
3+
<aside aria-label="Sidebar" id="sidebar" class="d-flex flex-column align-items-end">
4+
<header class="profile-wrapper">
5+
<a href="{{ '/' | relative_url }}" id="avatar" class="rounded-circle">
6+
{% if site.avatar != empty and site.avatar %}
7+
{% capture avatar_url %}
8+
{% if site.avatar contains '://' %}
9+
{{ site.avatar }}
10+
{% elsif site.img_cdn != empty and site.img_cdn %}
11+
{{ site.avatar | prepend: site.img_cdn }}
12+
{% else %}
13+
{{ site.avatar | relative_url }}
14+
{% endif %}
15+
{% endcapture %}
16+
<img src="{{ avatar_url | strip }}" width="112" height="112" alt="avatar" onerror="this.style.display='none'">
17+
{% endif %}
18+
</a>
19+
20+
<h1 class="site-title">
21+
<a href="{{ '/' | relative_url }}"><img src="/assets/makerforge_logo_horizontal_cropped.svg" width="200" /></a>
22+
</h1>
23+
<p class="site-subtitle fst-italic mb-0">{{ site.tagline }}</p>
24+
</header>
25+
<!-- .profile-wrapper -->
26+
27+
<nav class="flex-column flex-grow-1 w-100 ps-0">
28+
<ul class="nav">
29+
<!-- home -->
30+
<li class="nav-item{% if page.layout == 'home' %}{{ " active" }}{% endif %}">
31+
<a href="{{ '/' | relative_url }}" class="nav-link">
32+
<i class="fa-fw fas fa-home"></i>
33+
<span>{{ site.data.locales[include.lang].tabs.home | upcase }}</span>
34+
</a>
35+
</li>
36+
<!-- the real tabs -->
37+
{% for tab in site.tabs %}
38+
<li class="nav-item{% if tab.url == page.url %}{{ " active" }}{% endif %}">
39+
<a href="{{ tab.url | relative_url }}" class="nav-link">
40+
<i class="fa-fw {{ tab.icon }}"></i>
41+
{% capture tab_name %}{{ tab.url | split: '/' }}{% endcapture %}
42+
43+
<span>{{ site.data.locales[include.lang].tabs.[tab_name] | default: tab.title | upcase }}</span>
44+
</a>
45+
</li>
46+
<!-- .nav-item -->
47+
{% endfor %}
48+
</ul>
49+
</nav>
50+
51+
<div class="sidebar-bottom d-flex flex-wrap align-items-center w-100">
52+
<!-- {% unless site.theme_mode %}
53+
<button type="button" class="mode-toggle btn" aria-label="Switch Mode">
54+
<i class="fas fa-adjust"></i>
55+
</button>
56+
57+
{% if site.data.contact.size > 0 %}
58+
<span class="icon-border"></span>
59+
{% endif %}
60+
{% endunless %} -->
61+
62+
{% for entry in site.data.contact %}
63+
{% case entry.type %}
64+
{% when 'github', 'twitter' %}
65+
{%- capture url -%}
66+
https://{{ entry.type }}.com/{{ site[entry.type].username }}
67+
{%- endcapture -%}
68+
{% when 'email' %}
69+
{% assign email = site.social.email | split: '@' %}
70+
{%- capture url -%}
71+
javascript:location.href = 'mailto:' + ['{{ email[0] }}','{{ email[1] }}'].join('@')
72+
{%- endcapture -%}
73+
{% when 'rss' %}
74+
{% assign url = '/feed.xml' | relative_url %}
75+
{% else %}
76+
{% assign url = entry.url %}
77+
{% endcase %}
78+
79+
{% if url %}
80+
<a
81+
href="{{ url }}"
82+
aria-label="{{ entry.type }}"
83+
{% assign link_types = '' %}
84+
85+
{% unless entry.noblank %}
86+
target="_blank"
87+
{% assign link_types = 'noopener noreferrer' %}
88+
{% endunless %}
89+
90+
{% if entry.type == 'mastodon' %}
91+
{% assign link_types = link_types | append: ' me' | strip %}
92+
{% endif %}
93+
94+
{% unless link_types == empty %}
95+
rel="{{ link_types }}"
96+
{% endunless %}
97+
>
98+
<i class="{{ entry.icon }}"></i>
99+
</a>
100+
{% endif %}
101+
{% endfor %}
102+
</div>
103+
<!-- .sidebar-bottom -->
104+
</aside>
105+
<!-- #sidebar -->

_layouts/home.html

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
---
2+
layout: default
3+
---
4+
5+
{% include lang.html %}
6+
7+
{% assign pinned = site.posts | where: 'pin', 'true' %}
8+
{% assign default = site.posts | where_exp: 'item', 'item.pin != true and item.hidden != true' %}
9+
10+
{% assign posts = '' | split: '' %}
11+
12+
<!-- Get pinned posts -->
13+
14+
{% assign offset = paginator.page | minus: 1 | times: paginator.per_page %}
15+
{% assign pinned_num = pinned.size | minus: offset %}
16+
17+
{% if pinned_num > 0 %}
18+
{% for i in (offset..pinned.size) limit: pinned_num %}
19+
{% assign posts = posts | push: pinned[i] %}
20+
{% endfor %}
21+
{% else %}
22+
{% assign pinned_num = 0 %}
23+
{% endif %}
24+
25+
<!-- Get default posts -->
26+
27+
{% assign default_beg = offset | minus: pinned.size %}
28+
29+
{% if default_beg < 0 %}
30+
{% assign default_beg = 0 %}
31+
{% endif %}
32+
33+
{% assign default_num = paginator.posts | size | minus: pinned_num %}
34+
{% assign default_end = default_beg | plus: default_num | minus: 1 %}
35+
36+
{% if default_num > 0 %}
37+
{% for i in (default_beg..default_end) %}
38+
{% assign posts = posts | push: default[i] %}
39+
{% endfor %}
40+
{% endif %}
41+
42+
{% include intro.html %}
43+
44+
45+
{% capture content %}
46+
{% for post in posts %}
47+
<article class="card-wrapper">
48+
<a href="{{ post.url | relative_url }}" class="card post-preview flex-md-row-reverse">
49+
{% if post.image %}
50+
{% if post.image.lqip %}
51+
{% capture lqip %}lqip="{{ post.image.lqip }}"{% endcapture %}
52+
{% endif %}
53+
54+
{% assign src = post.image.path | default: post.image %}
55+
{% unless src contains '//' %}
56+
{% assign src = post.img_path | append: '/' | append: src | replace: '//', '/' %}
57+
{% endunless %}
58+
59+
{% assign alt = post.image.alt | xml_escape | default: 'Preview Image' %}
60+
61+
<img src="{{ src }}" w="17" h="10" alt="{{ alt }}" {{ lqip }}>
62+
{% endif %}
63+
64+
<div class="card-body d-flex flex-column">
65+
<h1 class="card-title my-2 mt-md-0">{{ post.title }}</h1>
66+
67+
<div class="card-text content mt-0 mb-2">
68+
<p>
69+
{% include no-linenos.html content=post.content %}
70+
{{ content | markdownify | strip_html | truncate: 200 | escape }}
71+
</p>
72+
</div>
73+
74+
<div class="post-meta flex-grow-1 d-flex align-items-end">
75+
<div class="me-auto">
76+
<!-- posted date -->
77+
<i class="far fa-calendar fa-fw me-1"></i>
78+
{% include datetime.html date=post.date lang=lang %}
79+
80+
<!-- categories -->
81+
{% if post.categories.size > 0 %}
82+
<i class="far fa-folder-open fa-fw me-1"></i>
83+
<span class="categories">
84+
{% for category in post.categories %}
85+
{{ category }}
86+
{%- unless forloop.last -%},{%- endunless -%}
87+
{% endfor %}
88+
</span>
89+
{% endif %}
90+
</div>
91+
92+
{% if post.pin %}
93+
<div class="pin ms-1">
94+
<i class="fas fa-thumbtack fa-fw"></i>
95+
<span>{{ site.data.locales[lang].post.pin_prompt }}</span>
96+
</div>
97+
{% endif %}
98+
</div>
99+
<!-- .post-meta -->
100+
</div>
101+
<!-- .card-body -->
102+
</a>
103+
</article>
104+
{% endfor %}
105+
{% endcapture %}
106+
107+
<div id="post-list" class="flex-grow-1 pe-xl-2">
108+
{% include refactor-content.html content=content lang=lang %}
109+
</div>
110+
<!-- #post-list -->
111+
112+
{% if paginator.total_pages > 1 %}
113+
{% include post-paginator.html %}
114+
{% endif %}

_posts/2023-10-26-reinforcement-learning-pt2.md

Lines changed: 0 additions & 30 deletions
This file was deleted.

0 commit comments

Comments
 (0)