Skip to content
This repository has been archived by the owner on Apr 18, 2024. It is now read-only.

Commit

Permalink
fix: LEAP-344: View all annotation tab is not loading (#1657)
Browse files Browse the repository at this point in the history
  • Loading branch information
juliosgarbi authored and jombooth committed Jan 26, 2024
1 parent ee2873a commit 4bc983d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/components/App/Grid.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ This triggers next rerender with next annotation until all the annotations are r
class Item extends Component {
componentDidMount() {
Promise.all(this.props.annotation.objects.map(o => {
// as the image has lazy load, and the image is not being added to the viewport
// until it's loaded we need to skip the validation assuming that it's always ready,
// otherwise we'll get a blank canvas
if (o.type === 'image') return Promise.resolve();

return o.isReady
? Promise.resolve(o.isReady)
: new Promise(resolve => {
Expand Down

0 comments on commit 4bc983d

Please sign in to comment.