• Resolved savenia

    (@savenia)


    Hello!

    I am having an issue with your justified gallery. The last row tries to justify itself even if set to no justify option. Furthermore, when it doesn’t get justified, the images there do not get the same size as the images above, which does not look great equal square sized images.

    Could you please help me fix that?

    The page I need help with: [log in to see the link]

Viewing 10 replies - 1 through 10 (of 10 total)
  • Hi @savenia,

    Are you able to take a screenshot of your Justified Gallery settings and send us a link where we can look at it so we can review them for you and make suggestions?

    Thanks in advance,

    Phill

    Thread Starter savenia

    (@savenia)

    Hi @savenia,

    Thanks for the screenshot.

    Why do you have such a large value for the Max Row Height? Note that you can use a negative value (-1 etc) if you want an unlimited max row height.

    Would you please edit your gallery and go to the right hand column and click “Clear Thumbnail Cache” for me? It appears you’re also using another HTML/CSS caching plugin? Would you please also clear that cache and then let me know if the images have started showing up at 400 by 400 px in the gallery?

    Thanks in advance,

    Phill

    Thread Starter savenia

    (@savenia)

    @phillcoxon, with ‘-1’ value all the other images but the last one do not show up for me. I have set the value to 200%.

    Cleared all the possible cache I could get to, did not help with the issue.

    @steveush – are you able to review this and give your thoughts please?

    • This reply was modified 4 years, 10 months ago by phillcoxon.
    Thread Starter savenia

    (@savenia)

    Have just tested the justified gallery on a completely fresh localhost site with no plugins and default 2020 theme, the problem persists. Seems like an internal plugin issue. The last row images should be justified to an average height

    @steveush – another shoulder tap to remind you to review this support request please.

    Just to add some more info that might help the developer debug this issue:

    I am also experiencing the same issue, but it depends on the number of items in the last row.
    It seems that (for me anyway) if the last row has one image less than the rest of the rows, It doesn’t matter what option I choose for “last row”… the last row is always justified.

    For example, I’ve a gallery with 7 images and the following settings:

    Thumb Height: 250
    Row Height: 250
    Max Row Height: 100%

    This displays the 7 photos as 4 in the top row and 3 in the bottom, and the bottom row is always justified, no matter what.
    However if I remove one photo (so there are just 2 on the bottom) the “last row” setting works as expected.

    I’ve replicated this behaviour with different settings & number of photos that result in the last row having one less photo. e.g.
    if I change the settings to Thumb Height: 200 and Row Height: 200, this puts 5 photos on top and 2 on the bottom, and the last row displays as per the option in the settings.
    Adding 1 more photo (8 in total: 5 on top, 3 on the bottom) still works.
    However adding another (9 in total: 5 on top, 4 on bottom) causes the last row to be justified.
    10, 11, 12 and 13 photos all work fine, 14 results in the last row being justified again, etc. Some other results:

    • All rows have 4 photos except last row has 1 or 2 => as expected
    • All rows have 4 photos except last row has 3 => last row is always justified
    • All rows have 5 photos except last row has 1, 2 or 3 => as expected
    • All rows have 5 photos except last row has 3 => last row is always justified
    • All rows have 6 photos except last row has 1, 2, 3 or 4 => as expected
    • All rows have 6 photos except last row has 5 => last row is always justified
    • etc.

    This is a on new install of Foo Gallery 1.8.18 on a brand new site using the latest version of WP (5.3.2).

    • This reply was modified 4 years, 10 months ago by meeee2.
    • This reply was modified 4 years, 10 months ago by meeee2.

    @steveush – reminder to review this support request please.

    Plugin Author steveush

    (@steveush)

    Hi all,

    Internally the JavaScript for the justified template has an option called justifyThreshold. What this option does at the moment is override the lastRow value and forces it to be justified if the total width of all images in that last row exceeds 50% of the maximum width of the gallery. This is what is leading to the issues you are currently experiencing.

    Unfortunately in the free version there is no easy way to adjust this option. I’ll look at upping the default value to something closer to 75-80% or more than likely simply remove the option entirely as it has definitely caused some confusion.

    If you have a method of enqueueing custom JavaScript in your page this behavior can be disabled using the following script:

    (function(fg){
    
    	if (!fg || !fg.Justified) return;
    	fg.Justified.defaults.justifyThreshold = 1;
    
    })(FooGallery);

    This should effectively make the lastRow option behave as expected.

    Thanks
    Steve

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Justified gallery last row’ is closed to new replies.