rels
This commit is contained in:
parent
5750307f59
commit
6ab7fc8c27
10
links.yaml
10
links.yaml
@ -59,6 +59,9 @@ links:
|
||||
|
||||
- title: Gaming
|
||||
links:
|
||||
- text: Board Game Geek
|
||||
icon: fa-solid fa-dice
|
||||
href: https://boardgamegeek.com/user/tyrelsouza
|
||||
- text: Steam
|
||||
icon: fa fa-steam-square
|
||||
href: https://steamcommunity.com/id/tyrels
|
||||
@ -75,9 +78,10 @@ links:
|
||||
- text: Bluesky
|
||||
icon: fa-solid fa-cloud
|
||||
href: https://bsky.app/profile/tyrel.dev
|
||||
- text: Fediverse
|
||||
icon: fa fa-pleroma
|
||||
href: https://social.tyrel.dev/tyrel
|
||||
- text: Mastodon
|
||||
rels: me
|
||||
icon: fa fa-mastodon
|
||||
href: https://mastodon.social/@tyrel
|
||||
- text: Facebook
|
||||
icon: fa-brands fa-facebook
|
||||
href: https://www.facebook.com/tyrel.souza
|
||||
|
@ -34,4 +34,5 @@ pub struct Link {
|
||||
icon: String,
|
||||
href: Option<String>,
|
||||
copy: Option<String>,
|
||||
rels: Option<String>,
|
||||
}
|
||||
|
@ -60,7 +60,6 @@ fn write_file(html: String) {
|
||||
copy_recursively("./static", "./output").expect("Could not copy static directory");
|
||||
}
|
||||
fs::write("./output/index.html", html).expect("Could not write to index.html");
|
||||
println!("Yaml parsed, Template rendered, and all living in ./output/")
|
||||
}
|
||||
|
||||
fn main() {
|
||||
|
@ -41,7 +41,7 @@
|
||||
<div class="links">
|
||||
{% for link in section.links %}
|
||||
{% if link.href and link.copy %}
|
||||
<a class="link" href="{{link.href}}" target="_blank">
|
||||
<a class="link" {% if link.rels %}rel="{{link.rels}}"{% endif %} href="{{link.href}}" target="_blank">
|
||||
<i class="{{link.icon}}"></i> {{link.text}}
|
||||
<div class="tooltip">
|
||||
<span class="" href="#" onclick="copytext('{{link.copy}}','{{loop.index}}')" onmouseout="outFunc('{{loop.index}}')">
|
||||
@ -51,7 +51,7 @@
|
||||
</div>
|
||||
</a>
|
||||
{% elif link.href %}
|
||||
<a class="link" href="{{link.href}}" target="_blank">
|
||||
<a class="link" {% if link.rels %}rel="{{link.rels}}"{% endif %} href="{{link.href}}" target="_blank">
|
||||
<i class="{{link.icon}}"></i> {{link.text}}
|
||||
</a>
|
||||
{% elif link.copy %}
|
||||
|
Loading…
Reference in New Issue
Block a user