-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEATURE REQUEST] Custom class for Country List in case of mobile or useFullscreenPopup. #1924
Comments
Hmm, why can't you just use the existing class |
Issue with Targeting Dropdown in Mobile View or Fullscreen PopupI'm facing a challenge with styling the dropdown for
In these cases, I cannot target the dropdown using Context and SolutionI am prefixing the existing styles of However, because the dropdown isn't wrapped in the custom class when it's ported out or in fullscreen mode, I'm unable to isolate and target it effectively. GoalI need a way to ensure that the dropdown, even when ported out or in fullscreen mode, can be targeted by my custom class so that my prefixed styles apply consistently without interfering with other plugins. For now, we don't have anyway or option to add our custom class to dropdown when it appears as popup. |
Thanks for the clear write-up. As I was reading it, I thought a simple solution would just be to apply the containerClass to the dropdown container when useFullscreenPopup/dropdownContainer options are used - what do you think? This would actually be more consistent, as in those cases, the dropdown container already has the main plugin classes |
I was thinking the same about applying it, but I was concerned it might cause other issues. If you believe applying the containerClass is the right approach, I agree we should proceed with it in this case. I will make the adjustments in the PR and push. |
Hi @jackocnr, |
Feature Request: Add Option to Customize Country List Popup via Custom Class
Problem
The
intl-tel-input
library currently provides a great default UI for the country list popup. However, applying custom styles to the popup container is challenging because there is no way to scope styles exclusively to it. This can result in style conflicts that affect other parts of the application or even other plugins.Proposed Solution
Add an option to specify a custom class for the popup container, similar to the existing
containerClass
option. This would allow developers to easily apply scoped styles to the popup without interfering with the library's default styles or those of other plugins.Example
Introduce a configuration option, such as
popupContainerClass
, which can be passed when initializingintl-tel-input
:The text was updated successfully, but these errors were encountered: