From 0ac365657bd161b2cfa3875d3da7e41da5564155 Mon Sep 17 00:00:00 2001 From: squidfunk Date: Wed, 4 Feb 2026 16:29:07 +0100 Subject: [PATCH] fix: view button invalid if `blob` or `edit` contained in path (#52) Signed-off-by: squidfunk --- dist/partials/actions.html | 6 +++--- src/partials/actions.html | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/dist/partials/actions.html b/dist/partials/actions.html index b14348ba..c8db35b8 100644 --- a/dist/partials/actions.html +++ b/dist/partials/actions.html @@ -10,11 +10,11 @@ {% endif %} {% if "content.action.view" in features %} {% if "/blob/" in page.edit_url %} - {% set part = "blob" %} + {% set part = "/blob/" %} {% else %} - {% set part = "edit" %} + {% set part = "/edit/" %} {% endif %} - + {% set icon = config.theme.icon.view or "material/file-eye-outline" %} {% include ".icons/" ~ icon ~ ".svg" %} diff --git a/src/partials/actions.html b/src/partials/actions.html index d4291a61..94b336c2 100644 --- a/src/partials/actions.html +++ b/src/partials/actions.html @@ -42,12 +42,12 @@ {% if "content.action.view" in features %} {% if "/blob/" in page.edit_url %} - {% set part = "blob" %} + {% set part = "/blob/" %} {% else %} - {% set part = "edit" %} + {% set part = "/edit/" %} {% endif %}