From cff4a7b856abea17ccb04d6ea3e5d24c35764924 Mon Sep 17 00:00:00 2001 From: Fini Jastrow Date: Wed, 19 Jun 2024 09:50:39 +0200 Subject: [PATCH] Downloads: Make font name searchable [why] The download page is not searchable for font names (except in some cases where the font is RFN or something). Because the font name is just in the preview image (and thus an image) users can not quickly go to some download link by searching for the name. [how] Lay the font name invisible over the preview image. Fixes: #1660 Reported-by: @willhansen Signed-off-by: Fini Jastrow --- _includes/css/nerd-font-tweaks.scss | 4 ++++ _posts/2017-01-03-downloads.md | 1 + 2 files changed, 5 insertions(+) diff --git a/_includes/css/nerd-font-tweaks.scss b/_includes/css/nerd-font-tweaks.scss index 20108147e..5c9bec954 100644 --- a/_includes/css/nerd-font-tweaks.scss +++ b/_includes/css/nerd-font-tweaks.scss @@ -9,6 +9,10 @@ p { padding: 8px 18px; } +.nerd-font-invisible-text { + opacity: 0.0; +} + input.nerd-font-input { cursor: inherit; } diff --git a/_posts/2017-01-03-downloads.md b/_posts/2017-01-03-downloads.md index ad6d81537..3764885ed 100644 --- a/_posts/2017-01-03-downloads.md +++ b/_posts/2017-01-03-downloads.md @@ -13,6 +13,7 @@ page: font-downloads {% for font in site.data.fonts.fonts %}
+ {{ font.patchedName }} {% assign upN = font.unpatchedName | split: " " | join: "" %} {% assign pN = font.patchedName | split: " " | join: "" %}