Skip to content

Conversation

joseph-bayer
Copy link
Contributor

@joseph-bayer joseph-bayer commented Feb 14, 2025

Howdy!

This is part 2 of our efforts to change how the Viewer loading state looks.

The pull request to support custom components for the loading state can be found here.

This pull request is focused on updating the default loading state with a loading skeleton!
The skeleton will even adjust when the information panel is open by default.

If you'd like for me to update the way it looks or further modify the skeleton based on the configuration, just let me know!

@mathewjordan
Copy link
Member

Hey @joseph-bayer . Apologies that I'm just now looking at this. This is a really good start.
I feel it flickers a bit too much if the manifest load is short, so I'm hesitant to merge it in right now. I'm going to take a deeper look at it and develop it a bit more.

As a thought experiment, I'm kind of thinking that the loading component should wrap Viewer here: https://github.com/samvera-labs/clover-iiif/blob/main/src/components/Viewer/index.tsx#L234-L241 In this model, the children would be the Viewer, and Skeleton could handle the transition more seamlessly through an isLoaded prop.

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

Successfully merging this pull request may close these issues.

2 participants