Skip to content
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

CDatePicker inside CInputGroup should render correctly like other form elements #417

Open
niksajanjic opened this issue Dec 3, 2024 · 0 comments

Comments

@niksajanjic
Copy link

This is how basic form elements render inside input group:
Screenshot 2024-12-03 at 17 28 08

Unfortunately, that doesn't work with PRO form elements like CDatePicker:
Screenshot 2024-12-03 at 17 27 48

Basically, we are not applying form-control class to the CDatePicker component and even if we do it wouldn't work out of the box. We could add similar class as form-control to the parent date-picker element but we also need to reset rules:

border: 0;
border-radius: 0;
padding: 0;

Than inside we need to add these rules to the element with date-picker-input-group class:

border-bottom-left-radius: 0;
border-top-left-radius: 0;

Still, there are some differences with variables, where date picker uses it's own variables like -cui-date-picker-border-color, while other form elements use variables like -cui-border-color.

Lastly, this CSS rule:

.input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback)

might also have to include:

:not(.date-picker)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant