Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/pkgsite: is too restrictive on what constitutes a wide screen #47207

Open
89z opened this issue Jul 14, 2021 · 3 comments
Open

x/pkgsite: is too restrictive on what constitutes a wide screen #47207

89z opened this issue Jul 14, 2021 · 3 comments

Comments

@89z
Copy link

@89z 89z commented Jul 14, 2021

It seems pkg.go.dev looks at your current window width, and decides if you should see the "normal" version or "mobile" version, were the sidebar is removed. From my testing, the sidebar is not shown, unless the body width is at least 1263 pixels. That seems too high to me. On a normal day, my browser width is about 1188 pixels, and I use a variety of websites with no problem. I dont think I should have to increase my width just for Go package site.

Before the move from golang.org, I never had to do anything like that. Its only now with the new pkg.go.dev, and must be a recent change as well. Example page:

https://pkg.go.dev/image

@gopherbot gopherbot added this to the Unreleased milestone Jul 14, 2021
@89z
Copy link
Author

@89z 89z commented Jul 15, 2021

Workaround:

/* ==userstyle==
@version 1.0.0
@namespace Steven Penny
@name go.dev
==/userstyle== */
@-moz-document domain("go.dev") {
   .go-Main-navDesktop {
      display: block;
   }
   .go-Main-navMobile {
      display: none;
   }
   .go-Main {
      grid-template-areas: 'header header' 'aside aside' 'nav article';
      grid-template-columns: 25% 75%;
   }
}

@jamalc jamalc added the UX label Jul 15, 2021
@jamalc jamalc removed this from the Unreleased milestone Jul 15, 2021
@jamalc jamalc added this to the pkgsite/frontend milestone Jul 15, 2021
@jamalc jamalc removed the UX label Jul 15, 2021
@jamalc jamalc assigned jamalc and unassigned jamalc Jul 16, 2021
@jamalc
Copy link

@jamalc jamalc commented Jul 16, 2021

/cc @jinhongy, we've adjusted the breakpoints on pkg.go.dev in response to feedback in #45073, #44365, #44172, #42487, and #4055. There might be room for adjustments.

Here are the numbers on pkg.go.dev visitor browser width for the previous month.

Screens >= 960px Screens >= 1280px Screens >=1520px Screens >= 1792px
88.32% 87.20% 66.70% 53.28%

and page layouts at the current breakpoints.

< 1280px 1280px - 1791px >= 1792px
1 column 2 column 3 column

@wxolp

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants