mirror of
https://github.com/by-jp/www.byjp.me.git
synced 2025-08-09 01:35:56 +01:00
List Gemini as alternative
This commit is contained in:
parent
ced97e265c
commit
8c681094a8
7 changed files with 16 additions and 9 deletions
|
@ -205,7 +205,6 @@ date = ["date", "publishDate", "lastmod", ":git"]
|
|||
protocol = 'gemini://'
|
||||
permalinkable = true
|
||||
noUgly = true
|
||||
notAlternative = true
|
||||
[outputFormats.api]
|
||||
name = 'JSON API'
|
||||
isPlainText = true
|
||||
|
|
|
@ -3,9 +3,9 @@ title: Calendar
|
|||
emoji: 🗓️
|
||||
outputs:
|
||||
- html
|
||||
- gemini
|
||||
- calendar
|
||||
- rss
|
||||
- gemini
|
||||
summary: Some events I'm thinking of going to — get in touch if you'd like to join me!
|
||||
---
|
||||
|
||||
|
|
|
@ -5,8 +5,8 @@ date: 2023-10-24 08:08:08 BST
|
|||
summary: The collection of RSS feeds I subscribe to, parcelled up so you can subscribe easily too.
|
||||
outputs:
|
||||
- html
|
||||
- gemini
|
||||
- opml
|
||||
- gemini
|
||||
sitemap:
|
||||
changefreq: monthly
|
||||
priority: 0.3
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
{{- if eq . "calendar"}}iCal
|
||||
{{- else if eq . "rss"}}RSS
|
||||
{{- else if eq . "opml" }}OPML Feed
|
||||
{{- else if eq . "gemini" }}Gemini
|
||||
{{- else }}Alternate
|
||||
{{- end -}}
|
||||
|
|
|
@ -2,11 +2,13 @@
|
|||
{{ $page := .}}
|
||||
<nav>
|
||||
<ul class="feedlinks">
|
||||
{{ range $page.AlternativeOutputFormats }}
|
||||
{{ if ne .Rel "alternate" }}{{ continue }}{{ end }}
|
||||
{{ $link := ($page.OutputFormats.Get .Name).RelPermalink }}
|
||||
<li><a href="{{ $link | safeURL }}" title="{{ partial "alternatename.txt" .Name }}">{{ partial "svg.html" (dict "name" .Name) }} {{ partial "alternatename.txt" .Name }}</a></li>
|
||||
{{ end }}
|
||||
{{- range $page.AlternativeOutputFormats -}}
|
||||
{{- if ne .Rel "alternate" }}{{ continue }}{{ end -}}
|
||||
{{- $target := $page.OutputFormats.Get .Name -}}
|
||||
{{- $link := $target.RelPermalink -}}
|
||||
{{- if not (hasPrefix $target.Permalink "http") }}{{ $link = (partial "noindex.gmi" $target.Permalink) }}{{ end -}}
|
||||
<li><a href="{{ $link | safeURL }}" title="{{ partial "alternatename.txt" .Name }}">{{ partial "svg.html" (dict "name" .Name) }}{{ partial "alternatename.txt" .Name }}</a></li>
|
||||
{{- end }}
|
||||
</ul>
|
||||
</nav>
|
||||
{{ end }}
|
||||
|
|
|
@ -2,4 +2,7 @@
|
|||
{{- if hasSuffix $url "/index.gmi" -}}
|
||||
{{- $url = strings.TrimSuffix "index.gmi" $url -}}
|
||||
{{- end -}}
|
||||
{{- if hasPrefix $url "gemini://www.byjp.me" -}}
|
||||
{{- $url = strings.Replace $url "gemini://www.byjp.me" "gemini://byjp.cc" -}}
|
||||
{{- end -}}
|
||||
{{- return $url -}}
|
||||
|
|
|
@ -65,7 +65,9 @@
|
|||
{{- else if (eq .name "fitbit") -}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="currentColor" stroke="none"><path d="M13.298 1.825c0 .976-.81 1.785-1.786 1.785-.972 0-1.784-.81-1.784-1.785 0-.973.813-1.785 1.784-1.785.976 0 1.786.813 1.786 1.785zm-1.786 3.243c-1.052 0-1.863.81-1.863 1.866 0 1.053.81 1.865 1.865 1.865 1.053 0 1.865-.811 1.865-1.865s-.825-1.866-1.875-1.866h.008zm0 5.029c-1.052 0-1.945.891-1.945 1.945s.894 1.945 1.947 1.945 1.946-.891 1.946-1.945-.894-1.945-1.946-1.945h-.002zm0 5.107c-1.052 0-1.863.81-1.863 1.864s.81 1.866 1.865 1.866c1.053 0 1.865-.811 1.865-1.866 0-.972-.825-1.864-1.875-1.864h.008zm0 5.191c-.972 0-1.784.809-1.784 1.784 0 .97.813 1.781 1.784 1.781.977 0 1.786-.809 1.786-1.784 0-.973-.81-1.781-1.786-1.781zM16.46 4.823c-1.136 0-2.108.977-2.108 2.111 0 1.134.973 2.107 2.108 2.107 1.135 0 2.106-.975 2.106-2.107 0-1.135-.972-2.109-2.106-2.109v-.002zm0 5.03c-1.216 0-2.19.973-2.19 2.19 0 1.216.975 2.187 2.19 2.187 1.215 0 2.189-.971 2.189-2.189 0-1.216-.974-2.188-2.189-2.188zm0 5.108c-1.136 0-2.108.976-2.108 2.107 0 1.135.973 2.109 2.108 2.109 1.135 0 2.106-.976 2.106-2.109s-.971-2.107-2.106-2.107zm5.106-5.353c-1.296 0-2.43 1.055-2.43 2.434 0 1.297 1.051 2.433 2.43 2.433 1.381 0 2.434-1.065 2.434-2.444-.082-1.382-1.135-2.431-2.434-2.431v.008zM6.486 5.312c-.892 0-1.62.73-1.62 1.623 0 .891.729 1.62 1.62 1.62.893 0 1.619-.729 1.619-1.62 0-.893-.727-1.62-1.619-1.62v-.003zm0 5.027c-.973 0-1.703.729-1.703 1.703 0 .975.721 1.703 1.695 1.703s1.695-.73 1.695-1.703c0-.975-.735-1.703-1.71-1.703h.023zm0 5.107c-.892 0-1.62.731-1.62 1.62 0 .895.729 1.623 1.62 1.623.893 0 1.619-.735 1.619-1.635s-.727-1.62-1.619-1.62v.012zm-5.025-4.863c-.813 0-1.461.646-1.461 1.459 0 .81.648 1.459 1.46 1.459.81 0 1.459-.648 1.459-1.459s-.648-1.459-1.458-1.459z"/></svg>
|
||||
{{- else if (eq .name "game") -}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 48 48"><g fill="none"><rect width="28" height="40" x="10" y="4" stroke="currentColor" stroke-width="4" rx="2"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="4" d="M16 12h16v10H16zm0 20h8m-4 4v-8"/><rect width="4" height="4" x="27" y="33" fill="currentColor" rx="2"/><rect width="4" height="4" x="30" y="26" fill="currentColor" rx="2"/></g></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 48 48"><g fill="none"><rect width="28" height="40" x="10" y="4" stroke="currentColor" stroke-width="4" rx="2"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="4" d="M16 12h16v10H16zm0 20h8m-4 4v-8"/><rect width="4" height="4" x="27" y="33" fill="currentColor" rx="2"/><rect width="4" height="4" x="30" y="26" fill="currentColor" rx="2"/></g></svg>
|
||||
{{- else if (eq .name "gemini") -}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="currentColor" d="M18 5.3c1.35-.33 2.66-.76 3.94-1.3l-.76-1.86a23.75 23.75 0 0 1-18.36.03L2.06 4c1.28.54 2.59.97 3.94 1.3v13.4c-1.35.33-2.66.76-3.94 1.3l.76 1.86a23.94 23.94 0 0 1 18.36 0l.76-1.86c-1.28-.54-2.59-.97-3.94-1.3zm-10 13V5.69c1.32.2 2.66.31 4 .31s2.68-.11 4-.31v12.62a26.2 26.2 0 0 0-8 0z"/></svg>
|
||||
{{- else if (eq .name "git") -}}
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-git-pull-request"><circle cx="18" cy="18" r="3"></circle><circle cx="6" cy="6" r="3"></circle><path d="M13 6h3a2 2 0 0 1 2 2v7"></path><line x1="6" y1="9" x2="6" y2="21"></line></svg>
|
||||
{{- else if (eq .name "gitea") -}}
|
||||
|
|
Loading…
Reference in a new issue