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

[cds-search]: input in cds-search is styled with box-sizing: border box, making it appear as 1px smaller than other components #11917

Open
2 tasks done
AlessandroPomponio opened this issue Jul 10, 2024 · 0 comments
Labels
bug Something isn't working dev Needs some dev work

Comments

@AlessandroPomponio
Copy link

Description

We are using a cds-search component next to a cds-dropdown, both in the lg size. The search bar, however, visually appears as 1px smaller than the dropdown.

image

After some scavenging, this appears to happen because the input part of the cds-search has box-sizing: border-box, while other components (e.g., the dropdown) do not have this setting.

Using the following css:

cds-search::part(input) {
  box-sizing: unset;
}

Fixes it.

Component(s) impacted

cds-search

Browser

Microsoft Edge

Carbon for IBM.com version

2.10.0

Severity

Severity 3 = The problem is visible or noticeable to users but does not impede the usability or functionality. Affects minor functionality, has a workaround.

Application/website

ST4SD Registry UI

Package

@carbon/web-components

CodeSandbox example

https://web-components.carbondesignsystem.com/?path=/story/components-search--default

Steps to reproduce the issue (if applicable)

No response

Release date (if applicable)

No response

Code of Conduct

@AlessandroPomponio AlessandroPomponio added bug Something isn't working dev Needs some dev work labels Jul 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working dev Needs some dev work
Projects
Status: No status
Development

No branches or pull requests

1 participant