Skip to content

Weird border when using Angular Material #9993

Answered by wongjn
shadow1349 asked this question in Help
Discussion options

You must be logged in to vote

The following element, .mdc-notched-outline__notch:

is responsible for the border. This is because of the following rule:

.mdc-text-field--focused .mdc-notched-outline__leading,
.mdc-text-field--focused .mdc-notched-outline__notch,
.mdc-text-field--focused .mdc-notched-outline__trailing {
  border-width: 2px;
}

It seems like the library assumes that its elements would have default border-style: none but as you point out, Tailwind preflight sets border-style: solid for all elements. To resolve your problem you could consider:

Replies: 2 comments 7 replies

Comment options

You must be logged in to vote
3 replies
@shadow1349
Comment options

@elvince
Comment options

@wongjn
Comment options

Answer selected by shadow1349
Comment options

You must be logged in to vote
4 replies
@shadow1349
Comment options

@jhourlad01
Comment options

@SippieCup
Comment options

@DouglasDiaz
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
6 participants
Converted from issue

This discussion was converted from issue #9992 on December 02, 2022 21:25.