Skip to content

Commit

Permalink
static/frontend: fix for button to be consistent on page scroll.
Browse files Browse the repository at this point in the history
added fix for 'Go to main link' button to not shift from left to right  when user scrolls the page.

https://screenshot.googleplex.com/3wuQEP5G8dEJkXr.png

Change-Id: I723dedbbcd7ff9d28005b2139f5130ac4af0d55d
Reviewed-on: https://go-review.googlesource.com/c/pkgsite/+/513477
Reviewed-by: Alice Merrick <[email protected]>
Run-TryBot: Hyang-Ah Hana Kim <[email protected]>
Reviewed-by: Jamal Carvalho <[email protected]>
kokoro-CI: kokoro <[email protected]>
Auto-Submit: Hyang-Ah Hana Kim <[email protected]>
TryBot-Result: Gopher Robot <[email protected]>
  • Loading branch information
prudhvikrishna authored and gopherbot committed Aug 24, 2023
1 parent a224e84 commit e9097fe
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 4 deletions.
3 changes: 3 additions & 0 deletions static/frontend/unit/_header.css
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ a.UnitHeader-backLink {
color: var(--color-text);
display: block;
font-size: 1rem;
position: absolute;
right: 0.625rem;
top: 1.25rem;
}

.UnitHeader-backLink img {
Expand Down
2 changes: 1 addition & 1 deletion static/frontend/unit/_header.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@
{{end}}

{{define "detail-page-nav"}}
<span class="go-Main-headerDetailItem">
<span>
<a class="UnitHeader-backLink" href="{{.URLPath}}" data-gtmc="header link">
<img class="go-Icon" height="24" width="24" src="/static/shared/icon/arrow_left_alt_gm_grey_24dp.svg" alt="">
Go to main page
Expand Down
2 changes: 1 addition & 1 deletion static/frontend/unit/unit.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e9097fe

Please sign in to comment.