-
Notifications
You must be signed in to change notification settings - Fork 123
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
Faster fades on load and progressive display of images #3169
Conversation
Waht are you thinking about this @AWare. I'm keen not to pick up any more work like this, but if this is close to shippable then it makes sense to realise the value by getting it over the line rather than parking it to rot. |
const animationDuration = 200; // ms | ||
const revealAfter = 1500; // ms |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nit] think this indentation is accidental
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, the joys of prettier
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logic LGTM 👍
(i'm in the middle of a rebase of my grid work so I haven't tested it locally)
Currently the image fade in on load applies an element style using the angular digest loop. As this style stuff is done on the element directly there's no state here for angular to track. I've reorganised things to: - make the reveal happen before we do any $q promisey stuff, so no more waiting on the digest loop - set a timeout (which ironically will fire in the digest loop) so that after a while we just show the image some changes
a154a2a
to
b128594
Compare
Seen on auth, usage, cropper, collections, media-api, kahuna, image-loader, image-loader-projection, metadata-editor, leases (created by @AWare and merged by @paperboyo 15 minutes ago) Please check your changes! |
Faster fades on load and progressive display of images
What does this change?
We are using a very nice fading of thumbnails and main preview. Sadly, it depends on them being loaded in full. We have imgOps configured to provide progressive JPEGs.
This PR:
Currently, the image fade in on load applies an element style using the
angular digest loop. As this style stuff is done on the element directly
there's no state here for angular to track. I've reorganised things to:
How can success be measured?
I think this would work better with #3166 from @paperboyo than just dropping the fade. The app should feel more snappy.
Screenshots
(bottom: current situation)
Viewer:
Browser (played at 25% speed for effect):
Who should look at this?
@guardian/digital-cms
Tested?