diff --git a/config.toml b/config.toml index 49382b1..4b4c414 100644 --- a/config.toml +++ b/config.toml @@ -6,87 +6,87 @@ favicon = true title = "Melora's tech and stuff" theme = "hello-friend-ng" paginate = 10 -rssLimit = 10 # Maximum number of items in the RSS feed. +rssLimit = 10 # Maximum number of items in the RSS feed. copyright = "This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License." # This message is only used by the RSS template. archetypeDir = "archetypes" -contentDir = "content" -dataDir = "data" -layoutDir = "layouts" -publishDir = "public" +contentDir = "content" +dataDir = "data" +layoutDir = "layouts" +publishDir = "public" [author] - name = "Melora Hugues" +name = "Melora Hugues" [taxonomies] - category = "blog" - tags = "tags" - series = "series" +category = "blog" +tags = "tags" +series = "series" [params] - dateform = "2 Jan 2006" - dateformShort = "2 Jan" - dateformNum = "02-01-2006" - dateformNumTime = "02-01-2006 15:04" +dateform = "2 Jan 2006" +dateformShort = "2 Jan" +dateformNum = "02-01-2006" +dateformNumTime = "02-01-2006 15:04" - disableReadOtherPosts = false - enableSharingButtons = true - enableGlobalLanguageMenu = true +disableReadOtherPosts = false +enableSharingButtons = true +enableGlobalLanguageMenu = true - description = "Personal website and tech blog for Melora Hugues" - keywords = "blog, tech, dev" - images = [""] +description = "Personal website and tech blog for Melora Hugues" +keywords = "blog, tech, dev" +images = [""] - # Enable to add comment support - # [params.commento] - # url = "" +# Enable to add comment support +# [params.commento] +# url = "" - # Integrate Plausible.io - plausibleDataDomain = 'faercol.me' - plausibleScriptSource = 'https://plausible.faercol.me/js/script.js' +# Integrate Plausible.io +plausibleDataDomain = 'faercol.me' +plausibleScriptSource = 'https://plausible.faercol.me/js/script.js' - [params.footer] - trademark = true - rss = true - copyright = false - author = true +[params.footer] +trademark = true +rss = true +copyright = false +author = true - [params.logo] - logoText = "Hello there!" - logoHomeLink = "/" +[params.logo] +logoText = "Hello there!" +logoHomeLink = "/" - [[params.social]] - name = "gitea" - url = "https://git.faercol.me" +[[params.social]] +name = "gitea" +url = "https://git.faercol.me" - [[params.social]] - name = "github" - url = "https://github.com/aHugues" +[[params.social]] +name = "github" +url = "https://github.com/aHugues" - [[params.social]] - name = "linkedin" - url = "https://www.linkedin.com/in/huguesmel/" +[[params.social]] +name = "linkedin" +url = "https://www.linkedin.com/in/huguesmel/" - [[params.social]] - name = "email" - url = "mailto:contact@faercol.me" +[[params.social]] +name = "email" +url = "mailto:contact@faercol.me" [languages] - [languages.en] - contentDir = "content/en" - [languages.en.params] - homeSubtitle = "This is where I mostly talk about tech... and stuff" - [languages.en.params.logo] - logoText = "Hello there!" - logoHomeLink = "/en/" +[languages.en] +contentDir = "content/en" +[languages.en.params] +homeSubtitle = "This is where I mostly talk about tech... and stuff" +[languages.en.params.logo] +logoText = "Hello there!" +logoHomeLink = "/en/" - [languages.fr] - contentDir = "content/fr" - [languages.fr.params] - homeSubtitle = "Là où je parle de tech... et d'autres trucs" - [languages.fr.params.logo] - logoText = "Hello there!" - logoHomeLink = "/fr/" +[languages.fr] +contentDir = "content/fr" +[languages.fr.params] +homeSubtitle = "Là où je parle de tech... et d'autres trucs" +[languages.fr.params.logo] +logoText = "Hello there!" +logoHomeLink = "/fr/" [menu] # [[menu.main]] @@ -95,14 +95,20 @@ publishDir = "public" # url = "/posts" # weight = 1 - [[menu.main]] - identifier = "about_me" - name = "About me" - url = "/about-me" - weight = 10 +[[menu.main]] +identifier = "about_me" +name = "About me" +url = "/about-me" +weight = 10 - [[menu.main]] - identifier = "resume" - name = "Resume" - url = "https://resume.faercol.me" - weight = 40 +[[menu.main]] +identifier = "resume" +name = "Resume" +url = "https://resume.faercol.me" +weight = 40 + +[module] +[[module.imports]] +path = "github.com/hugomods/icons" +[[module.imports]] +path = "github.com/hugomods/icons/vendors/lucide" diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..47d13df --- /dev/null +++ b/go.mod @@ -0,0 +1,8 @@ +module git.faercol.me/faercol/hugo-relie + +go 1.20 + +require ( + github.com/hugomods/icons v0.6.0 // indirect + github.com/hugomods/icons/vendors/lucide v0.3.16 // indirect +) diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..2728cf4 --- /dev/null +++ b/go.sum @@ -0,0 +1,4 @@ +github.com/hugomods/icons v0.6.0 h1:G6RU93okhPPRDh/jqcew9gwkcYpSpg0rCBv4S6yUAFw= +github.com/hugomods/icons v0.6.0/go.mod h1:cIkSvK6W0q6N4U6n9KGz+QfRWQXAW0INd+1P31gPNGg= +github.com/hugomods/icons/vendors/lucide v0.3.16 h1:IQqgped/4DIe+FGe7u7W3pXcGCl9iztzUPi00rmt2UI= +github.com/hugomods/icons/vendors/lucide v0.3.16/go.mod h1:92fL24fAnTYWIAnq8i3UbWyeERFA/bupS2uhe8btB64= diff --git a/layouts/shortcodes/callout.html b/layouts/shortcodes/callout.html new file mode 100644 index 0000000..e86e505 --- /dev/null +++ b/layouts/shortcodes/callout.html @@ -0,0 +1,149 @@ +{{ $type := .Get "type"}} +{{ $iconName := "pencil" }} +{{ $calloutTitle := $type | humanize }} +{{ $calloutColorClass := "callout-blue"}} + +{{ if (eq $type "info") }} + {{ $iconName = "info" }} +{{ end }} +{{ if (eq $type "note") }} +{{ end }} +{{ if (eq $type "warning") }} + {{ $iconName = "alert-triangle" }} + {{ $calloutTitle = "Warning" }} + {{ $calloutColorClass = "callout-orange" }} +{{ end }} +{{ if (eq $type "summary") }} + {{ $iconName = "clipboard-list" }} + {{ $calloutTitle = "Summary" }} + {{ $calloutColorClass = "callout-cyan" }} +{{ end }} +{{ if (eq $type "todo") }} + {{ $iconName = "check-circle-2" }} + {{ $calloutTitle = "TODO" }} + {{ $calloutColorClass = "callout-blue" }} +{{ end }} +{{ if (eq $type "hint") }} + {{ $iconName = "flame" }} + {{ $calloutTitle = "Hint" }} + {{ $calloutColorClass = "callout-cyan" }} +{{ end }} +{{ if (eq $type "success") }} + {{ $iconName = "check" }} + {{ $calloutTitle = "Done" }} + {{ $calloutColorClass = "callout-green" }} +{{ end }} +{{ if (eq $type "help") }} + {{ $iconName = "help-circle" }} + {{ $calloutTitle = "Help" }} + {{ $calloutColorClass = "callout-yellow" }} +{{ end }} +{{ if (eq $type "help") }} + {{ $iconName = "help-circle" }} + {{ $calloutTitle = "Help" }} + {{ $calloutColorClass = "callout-yellow" }} +{{ end }} +{{ if (eq $type "fail") }} + {{ $iconName = "x" }} + {{ $calloutTitle = "Fail" }} + {{ $calloutColorClass = "callout-red" }} +{{ end }} +{{ if (eq $type "danger") }} + {{ $iconName = "zap" }} + {{ $calloutTitle = "Danger" }} + {{ $calloutColorClass = "callout-red" }} +{{ end }} +{{ if (eq $type "bug") }} + {{ $iconName = "bug" }} + {{ $calloutTitle = "Bug" }} + {{ $calloutColorClass = "callout-red" }} +{{ end }} +{{ if (eq $type "example") }} + {{ $iconName = "list" }} + {{ $calloutTitle = "Example" }} + {{ $calloutColorClass = "callout-purple" }} +{{ end }} +{{ if (eq $type "quote") }} + {{ $iconName = "quote" }} + {{ $calloutTitle = "Quote" }} + {{ $calloutColorClass = "callout-grey" }} +{{ end }} + +{{ $context := dict + "vendor" "lucide" + "name" $iconName + "height" "1.5em" + "width" "1.5em" +}} + +