GeneralMagicio / pairwise-rpgf5

https://pairwise-rpgf5.vercel.app
1 stars 0 forks source link

Transitions after selection #39

Open MoeNick opened 3 days ago

MoeNick commented 3 days ago

Use the loading modal for half of the second.

Meriem-BM commented 2 days ago

Use the loading modal for half of the second.

  • [ ] for loading 2 projects at the same time, loading modal for each[ ] if only one project loads or change, use the loading modal for that specific project.

@MoeNick I don't think it's possible to add loading for each project separately since we load both pairs together. We can only add a loading state for both. WDYT @mmahdigh ?

mmahdigh commented 2 days ago

Use the loading modal for half of the second.

  • [ ] for loading 2 projects at the same time, loading modal for each[ ] if only one project loads or change, use the loading modal for that specific project.

@MoeNick I don't think it's possible to add loading for each project separately since we load both pairs together. We can only add a loading state for both. WDYT @mmahdigh ?

Yeah, we don't know when the next pair comes, whether both projects have changed or only one. The next best thing we can do though:

1- Use the loading modal for both cards when using useGetPairwisePairs 2- Use the loading modal for only the card that's going to (most probably) change when calling getPairwisePairsForProject

P.S: These two endpoints might be a little confusing, the first one (useGetPairwisePairs) returns the next pair of projects with no precondition while the latter (getPairwisePairsForProject) accepts a project id argument and looks for a pair that necessarily has that id as one of the projects in the pair. (used when calling the conflict of interest button).

MoeNick commented 1 day ago

I meant we do that for each card if possible, choose your best possible solution guys I trust you.