-
Notifications
You must be signed in to change notification settings - Fork 17.9k
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/blog/content: images and embedded YouTube content in pkgsite-redesign.article renders poorly on mobile #42493
Comments
/cc @dmitshur |
It looks like that particular blog post inlines some markup that isn't mobile-friendly. For example, removing the hardcoded "height" attribute from <img> tags helps images scale gracefully as the viewport width becomes narrower than the original image size. Something similar needs to be done for the <iframe> that embeds the youtube video. Perhaps some older blog posts can be used as reference. For example, https://blog.golang.org/go.dev embeds images in a mobile-friendly way. I didn't find blog posts that embed YouTube videos in a mobile-friendly way though (e.g., https://blog.golang.org/why-generics, https://blog.golang.org/fosdem14, https://blog.golang.org/go1-path, all have a similar problem at narrow widths). CC @julieqiu. |
Change https://golang.org/cl/270804 mentions this issue: |
The "height" attribute is removed from <img> tags so that images will scale gracefully as the viewport width becomes narrower than the original image size. For golang/go#42493 Change-Id: I951a1d82a119f55d22cd564e871203d07a0a5f28 Reviewed-on: https://go-review.googlesource.com/c/blog/+/270804 Trust: Julie Qiu <julie@golang.org> Run-TryBot: Julie Qiu <julie@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
The "height" attribute is removed from <img> tags so that images will scale gracefully as the viewport width becomes narrower than the original image size. For golang/go#42493 Change-Id: I951a1d82a119f55d22cd564e871203d07a0a5f28 Reviewed-on: https://go-review.googlesource.com/c/blog/+/270804 Trust: Julie Qiu <julie@golang.org> Run-TryBot: Julie Qiu <julie@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org> X-Blog-Commit: 5d7660a8674f3c659ded6a2f49c151c26c5eb282
The "height" attribute is removed from <img> tags so that images will scale gracefully as the viewport width becomes narrower than the original image size. For golang/go#42493 Change-Id: I951a1d82a119f55d22cd564e871203d07a0a5f28 Reviewed-on: https://go-review.googlesource.com/c/blog/+/270804 Trust: Julie Qiu <julie@golang.org> Run-TryBot: Julie Qiu <julie@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org> X-Blog-Commit: 5d7660a8674f3c659ded6a2f49c151c26c5eb282
The recent blog post on pkg.go.dev renders poorly on mobile browsers.
The text was updated successfully, but these errors were encountered: