-
-
Notifications
You must be signed in to change notification settings - Fork 10k
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
srcset missing for header images in new editor #17753
Comments
@cathysarisky stoked to work on this issue, can you please assign it to me? If there are any specific guidelines or tasks you'd like me to follow outside of the contributions doc, please let me know. |
I’m not the Ghost core team, sorry. :)
|
@daniellockyer hey, would be stoked to work on this issue, can you please assign it to me? I don't intend to muddy the issue thread |
I'll add onto this one instead of opening another bug - these header images are also missing the lazy loading attribute that other body content gets automagically. |
refs TryGhost/Ghost#17753 - added lazy loading attribute to header card renderer (v2+)
refs TryGhost/Ghost#17753 - added lazy loading attribute to header card renderer (v2+)
closes TryGhost/Ghost#17753 - added background image width and height attributes to `HeaderNode` - updated header node components to capture width and height when an image is uploaded - updated header node renderer to output `srcset` attribute on the `<picture>` element
closes TryGhost/Ghost#17753 - added background image width and height attributes to `HeaderNode` - updated header node components to capture width and height when an image is uploaded - updated header node renderer to output `srcset` attribute on the `<picture>` element
closes TryGhost/Product#4146 closes #17753 closes TryGhost/Product#4127 closes #18903 - 🐛 Fixed blank render output in some cases when using line breaks - 🐛 Fixed backspace at end of link sometimes deleting whole link in Firefox - 🐛 Fixed plain black generated video thumbnails in Safari - 🎨 Added `srcset` and `loading="lazy"` to header card images - 🎨 Improved accessibility of buttons in render output by adding `aria-role` attributes - 🎨 Removed Ctrl/Cmd+H shortcut as it clashed with expected OS shortcut
closes TryGhost/Product#4146 closes #17753 closes TryGhost/Product#4127 closes #18903 - 🐛 Fixed blank render output in some cases when using line breaks - 🐛 Fixed backspace at end of link sometimes deleting whole link in Firefox - 🐛 Fixed plain black generated video thumbnails in Safari - 🎨 Added `srcset` and `loading="lazy"` to header card images - 🎨 Improved accessibility of buttons in render output by adding `aria-role` attributes - 🎨 Removed Ctrl/Cmd+H shortcut as it clashed with expected OS shortcut
Issue Summary
Image content generated for the new split header layout does not include a srcset. Huge images load by default.
Steps to Reproduce
Create a new page with a header card with the new split layout.
Be lazy and drag a huge image into the image blog, assuming Ghost will resize it.
Publish. Inspect the result. Here's the outcome:
Because there's no srcset on image, it loads at 2000px wide. That's silly for anything less than a 4k screen, and really silly for the 1200px wide screen I prefer. My browser actually rendered it at ~500px.
Ghost Version
5.59.1
Node.js Version
Ghost Pro and 16.something
How did you install Ghost?
ghost-cli and ghost pro
Database type
MySQL 8
Browser & OS version
Chrome, recent, windows 10
Relevant log / error output
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: