tomusborne / generateblocks

GenerateBlocks is a small collection of lightweight WordPress blocks that can accomplish nearly anything.
https://generateblocks.com
188 stars 18 forks source link

Global Styles list reordering not working - GB Pro 1.9 alpha.2 #1211

Closed jakewoods-io closed 3 months ago

jakewoods-io commented 3 months ago

Description

On GB Pro 1.9.0-alpha.2, there's something weird going on when reordering the list of classes in Global Styles. If you manually reorder classes, leave and come back to the global styles page, the classes have moved to a different order than specified. This seems to happen whether or not any of the global styles have been amended since reordering.

Steps to reproduce

  1. Visit the GenerateBlocks global styles, and manually reorder classes.
  2. Leave the global styles page and return - the classes are showing in a different order than specified.

Expected behavior

The classes will remain in the order that I set

Actual behavior

The classes change to an unspecified order. This change in order appears to be fairly random, although sometimes you will see them reset to the same order as before changing.

Notes:

Note this is on a local install, and I have had other users confirm that this issue does not happen for them, which may make it hard to replicate. I do have about 65 global styles set, incase it's a volume thing? I also reordered my global styles, before adding more and amending existing global styles - just to give a broader idea of when the problem began.


tomusborne commented 3 months ago

Hey @jakewoods-io,

I'm not able to reproduce this. Any chance you can do up a super quick screencast so I can see?

Thanks!

jakewoods-io commented 3 months ago

Hey Tom, of course - https://www.loom.com/share/ade1c17f3bd241faa1400797d1246bbb?sid=8def0880-d7b3-431f-9a41-0840764c0ceb

Thanks for taking a look into this!

tomusborne commented 3 months ago

Thanks for that! A staging site would be great if you want to shoot it over to me via our contact form on the website.

iansvo commented 3 months ago

@jakewoods-io Also if you can provide a recording that shows your console output that would be helpful.

jakewoods-io commented 3 months ago

@iansvo Hey Ian, no problem at all - there's a Loom here: https://www.loom.com/share/38f5363179964919ac6025a34efee75b?sid=5b209cf0-79c9-46c8-a828-ee62b6cfd848

Hopefully I captured what you needed, please let me know if I've not given you the right thing and I'll happily re-record a video!

iansvo commented 3 months ago

@jakewoods-io Super helpful stuff, thanks. I was able to use the login creds from Tom as well and I can definitely see what's going on.

The problem you're having is due to the update running multiple times without finishing. This is really just a flaw in the way I set up the API calls here so I'm going to update this to work more efficiently. This will require you to "save changes" when you do reordering, but the idea is you'll do that, it'll show you a progress bar or something to indicate stuff is going on, and then it will work as expected.

In your sandbox site I was able to confirm the efficacy here, so I think we're on the right track. We should have an update for this soon in our next Alpha release or two.

jakewoods-io commented 3 months ago

@iansvo - great stuff, thanks so much for looking into that

tomusborne commented 3 months ago

This should be fixed in our latest alpha we released yesterday.

Thanks for help!