Skip to content
This repository has been archived by the owner on Sep 26, 2023. It is now read-only.

On the second click, the popup-picker stays at bottom of the container. #246

Closed
DaniBedz opened this issue Sep 29, 2022 · 11 comments
Closed
Labels
bug Something isn't working pending Changes have been committed and will be included in the next release.

Comments

@DaniBedz
Copy link

I think I'm running into the same issue previously raised here: #217, that was closed by the reporter.

To recreate, set the showRecents: false picker option. When you open the picker the first time, it will display the 'smileys and emotions' category, at the top of the container. If you close and reopen the picker, the container's focus is at the bottom of the container, so you see the flags:

2022-09-29 12 37 05

Storybook also doesn't see to respect the value of the checkbox for this UI element, so I don't know if it can be reproduced in storybook alone at the moment:
2022-09-29 12 34 44

I tried to set the initialEmoji and initialCategory, to the first emoji, but that didn't resolve the issue.

Just let me know if you need any more info.

Thanks for the great project!

@joeattardi joeattardi added the bug Something isn't working label Oct 2, 2022
@joeattardi
Copy link
Owner

I just released 5.7.1 which should resolve this issue!

@DaniBedz
Copy link
Author

DaniBedz commented Oct 5, 2022

Uh oh, looks like it's still happening on 5.7.1 if showRecents: false is set.

@joeattardi joeattardi reopened this Oct 6, 2022
@joeattardi
Copy link
Owner

Reopening for now. I fixed the Storybook demo, so it now respects the flags in the popup picker. I can't seem to reproduce the behavior now - can you maybe put together a codepen or similar showing the issue? Maybe I am missing a scenario.

@joeattardi
Copy link
Owner

@DaniBedz Can you provide a reproducible example?

@tuannm151
Copy link

tuannm151 commented Nov 14, 2022

I had the same issue when using css display: none to toggle the visibility for the picker.
ezgif com-gif-maker (1)

@joeattardi
Copy link
Owner

@tuannm151 I can't tell for sure from your GIF but it looks like this is the core picker package, is that right? I haven't been able to reproduce this - I loaded it in https://picmojs.com/storybook/, selected the picker element, and toggled display: none as you have shown here - the scroll position did not change.

Can you provide a quick codepen or similar example showing the problem and let me know the browser you're using? Thanks.

@joeattardi joeattardi added the more info needed Waiting for additional information from the submitter label Nov 20, 2022
@joeattardi
Copy link
Owner

@tuannm151 Just following up with you, if you can create an example showcasing the issue I'd be happy to look into it deeper

@dEEpProjects
Copy link

@tuannm151 I can't tell for sure from your GIF but it looks like this is the core picker package, is that right? I haven't been able to reproduce this - I loaded it in https://picmojs.com/storybook/, selected the picker element, and toggled display: none as you have shown here - the scroll position did not change.

Can you provide a quick codepen or similar example showing the problem and let me know the browser you're using? Thanks.

I have the same issue and I can reproduce it in the storybook when the recents category is selected. On my project, instead, it happens with any category.

@joeattardi
Copy link
Owner

I can reproduce this now with the base (non-popup) picker. If I scroll up to select the recents category, and I apply display: none to the picker then remove it, it jumps to the last category. Or, if I disable the recents category, it happens with the first category.

Is this what you are referring to? Based on the description and GIFs above, it seems to be. I will take a look.

@joeattardi joeattardi removed the more info needed Waiting for additional information from the submitter label Jan 23, 2023
@joeattardi
Copy link
Owner

Finally found the cause for this! I think I have a proper fix, will hopefully have a new release out this week to address this.

Thanks for the additional details.

@joeattardi joeattardi added the pending Changes have been committed and will be included in the next release. label Jan 23, 2023
@joeattardi
Copy link
Owner

Just published a new release, 5.7.3, that should resolve this issue. Please let me know or reopen if you still have issues!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working pending Changes have been committed and will be included in the next release.
Projects
None yet
Development

No branches or pull requests

4 participants