go.dev: turn off share button on golang.google.cn
Right now golang.google.cn serves a copy of golang.org. Eventually it will serve a copy of go.dev instead. Prepare for that by disabling the share button on the go.dev home page when the request is actually for golang.google.cn. Change-Id: I2b80d066ceb789cd188f6409694bccfed2a87c19 Reviewed-on: https://go-review.googlesource.com/c/website/+/362956 Trust: Russ Cox <rsc@golang.org> Reviewed-by: Jamal Carvalho <jamal@golang.org>
This commit is contained in:
Родитель
7008ea24bd
Коммит
7aec227803
|
@ -2,6 +2,7 @@
|
|||
title: go.dev
|
||||
---
|
||||
|
||||
{{$canShare := not googleCN}}
|
||||
<section class="Hero bluebg">
|
||||
<div class="Hero-gridContainer">
|
||||
<div class="Hero-blurb">
|
||||
|
@ -175,8 +176,10 @@ func main() {
|
|||
<div class="Playground-buttons">
|
||||
<button class="Button Button--primary js-playgroundRunEl" title="Run this code [shift-enter]">Run</button>
|
||||
<div class="Playground-secondaryButtons">
|
||||
{{- if $canShare}}
|
||||
<button class="Button js-playgroundShareEl" title="Share this code">Share</button>
|
||||
<a class="Button tour" href="https://tour.golang.org/" title="Playground Go from your browser">Tour</a>
|
||||
{{- end}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Загрузка…
Ссылка в новой задаче