Closed miqrogroove closed 2 years ago
This one with 6 images (note it will revert to a single image tonight when the demo resets) works fine for me. https://demo.collectiveaccess.org/pawtucket/Detail/objects/34
That link doesn't work for me. Try these steps:
Expected result:
The selected image should load.
Actual result:
None of the previous images will load in any order unless the user returns to the 1st image and clicks the thumbnails in exactly the displayed order.
Workaround:
Reduce the number of representations to 2 or less.
I can get this intermittently to happen in Chrome. It does not happen in Safari. I'll look into why. Thanks for reporting.
I'm running v1.7.16.
With some more experimentation, it looks like there's an additional problem after the carousel is initialized. When clicking the left and right arrows on the Details page, rather than the thumbnails or the viewer, the image order is always wrong. It shows the "primary" image by default, and then subsequent clicks cause the images to display in the order originally uploaded (numerical ID order?) and never in the order listed nor the order of the thumbnails, unless they are still in the original uploaded order as well.
I just noticed there is a minor lingering issue with the arrows and thumbnails. I will test more and open a new issue when I can pinpoint it better.
After more testing, it looks like the carousel on the object Detail page is initialized incorrectly and as a result will only work when there are exactly 1 or 2 representations attached to an object. Any more than that and it is necessary to click through all of the slides before the carousel is properly initialized.
Note 1: The TileViewer is not affected by this bug. After clicking to enlarge, the little links at the bottom of the viewer will advance through the images as expected.
Note 2: The Gallery carousel is not affected by this bug. That one works as expected.
Note 3: Much of the carousel code lives in https://github.com/collectiveaccess/pawtucket2/blob/master/themes/default/views/bundles/representation_viewer_html.php
Note 4: The carousel is invoked by https://github.com/collectiveaccess/pawtucket2/blob/855d52732ce55ec8498b5ee8a22d921d0ee8584b/themes/default/views/Details/ca_objects_default_html.php#L49