From d4e9219641389fa63b8095026ac466bf0f4aa8a3 Mon Sep 17 00:00:00 2001 From: razonyang Date: Tue, 25 Jul 2023 12:26:52 +0800 Subject: [PATCH] feat(icon-grid): add the linkText parameter --- layouts/partials/bootstrap/icon-grid.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/layouts/partials/bootstrap/icon-grid.html b/layouts/partials/bootstrap/icon-grid.html index 06a1767..650c552 100644 --- a/layouts/partials/bootstrap/icon-grid.html +++ b/layouts/partials/bootstrap/icon-grid.html @@ -1,6 +1,8 @@ {{- $key := "" }} +{{- $linkText := i18n "learn_more" }} {{- if .IsNamedParams }} {{- $key = .Get "data" }} + {{- with .Get "linkText" }}{{ $linkText = . }}{{ end }} {{- else }} {{- $key = .Get 0 }} {{- end }} @@ -39,7 +41,7 @@ class="text-decoration-none" href="{{ $link }}" {{ if $url.Scheme }}target="_blank" rel="external"{{ end }}> - {{- i18n "learn_more" -}} + {{- $linkText -}} {{ partial "icons/icon" (dict "vendor" "bootstrap" "name" "arrow-right"