nanogallery2 icon indicating copy to clipboard operation
nanogallery2 copied to clipboard

Updating thumbnails without recreating gallery

Open Yves33 opened this issue 4 years ago • 1 comments

Hello, I use nanogallery2 for a personnal picture gallery.

  • The frontend allows me to select some pictures in thumbnail view
  • The server rotates, flip, (...) those images and generates new thumbnails
  • I now need to reload the thumbnails for these selected pitcures.

for now, I destroy and recreate everything:

jQuery("#nano").nanogallery2('destroy');
// render to <div id="nano></div> with jsrender
jQuery("#nano").nanogallery2(nanopt);

But I'm sure there must be a way to avoid recreating the gallery

Thanks

Yves33 avatar Apr 13 '20 14:04 Yves33

Have you tried the refresh method, as described in the documentation?

$('#your_nanogallery2').nanogallery2('refresh');

philipstratford avatar May 12 '20 23:05 philipstratford