Don't translate translate button

pull/25/head
Jan-Lukas Else 8 months ago
parent f42b3256a4
commit 80fb177d40
  1. 9
      ui.go

@ -886,7 +886,14 @@ func (a *goBlog) renderPost(hb *htmlBuilder, rd *renderData) {
hb.writeEscaped(a.ts.GetTemplateStringVariant(rd.Blog.Lang, "share"))
hb.writeElementClose("a")
// Translate button
hb.writeElementOpen("a", "id", "translateBtn", "class", "button", "href", fmt.Sprintf("https://translate.google.com/translate?u=%s", a.getFullAddress(p.Path)), "target", "_blank", "rel", "nofollow noopener noreferrer", "title", a.ts.GetTemplateStringVariant(rd.Blog.Lang, "translate"))
hb.writeElementOpen(
"a", "id", "translateBtn",
"class", "button",
"href", fmt.Sprintf("https://translate.google.com/translate?u=%s", a.getFullAddress(p.Path)),
"target", "_blank", "rel", "nofollow noopener noreferrer",
"title", a.ts.GetTemplateStringVariant(rd.Blog.Lang, "translate"),
"translate", "no",
)
hb.writeEscaped("A ⇄ 文")
hb.writeElementClose("a")
hb.writeElementOpen("script", "defer", "", "src", a.assetFileName("js/translate.js"))

Loading…
Cancel
Save