egjs-infinitegrid icon indicating copy to clipboard operation
egjs-infinitegrid copied to clipboard

Flickering when new items are added

Open H4xX0r1337 opened this issue 2 years ago • 3 comments

It seems to be the case that everytime you add a new item (containing images in my case), it gets visible at the top left for a frame or so. I tried it both with recycling on and off.

H4xX0r1337 avatar May 01 '22 00:05 H4xX0r1337

Currently I'm using this hotfix: <div class="item" style="z-index: {item.groupKey};">

H4xX0r1337 avatar May 01 '22 00:05 H4xX0r1337

@H4xX0r1337

all i can guess

  1. Have you set the key to the item?
  2. Sorry if the framework is svelte or angular. Because the rendering process is asynchronous, flickering may occur. In that case, setting the initial css is fine.
.item {
position: absolute;
left: -9999px;
top: -9999px;
}

daybrush avatar May 02 '22 03:05 daybrush

@daybrush Sorry for responding so late. The flickerign is gone using the css you posted, but now some images "pop in" between others, moving the others around. It seems to only add the images when they are fully loaded, however i know the width and height beforehand, so it would be cool if i was able to put a placeholder there. I did not find a way to use the built in placeholder feature in svelte and i also was not able to use css for that (it wont show up until the actual image has loaded)

H4xX0r1337 avatar Jun 06 '22 10:06 H4xX0r1337