From 8ad74ede2fc495026a28fb8ec4753b54e9d8bb62 Mon Sep 17 00:00:00 2001 From: Cell <1024@lruihao.cn> Date: Tue, 12 Apr 2022 11:45:24 +0800 Subject: [PATCH] :bug: Fix: don't display external icon when links has icon suffix (#96) --- layouts/partials/plugin/link.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/layouts/partials/plugin/link.html b/layouts/partials/plugin/link.html index 6bc151ca..578b7cb6 100644 --- a/layouts/partials/plugin/link.html +++ b/layouts/partials/plugin/link.html @@ -31,7 +31,11 @@ {{- with .Content -}} {{- . | safeHTML -}} {{- end -}} - {{- if (.ExternalIcon | default false) | and $external | and (eq (hasPrefix .Content ``) | or (strings.HasSuffix .Content `):`)) false) + }} {{ if .Download }} {{ dict "Class" "fas fa-cloud-download-alt fa-fw fa-xs" | partial "plugin/icon.html" }} {{- else -}}