Skip to content

Commit

Permalink
Ensure [hidden] works as expected (#4873)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamwathan authored Jul 2, 2021
1 parent dc0a063 commit a323030
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/plugins/css/preflight.css
Original file line number Diff line number Diff line change
Expand Up @@ -237,3 +237,11 @@ video {
max-width: 100%;
height: auto;
}

/**
* Ensure the default browser behavior of the `hidden` attribute.
*/

[hidden] {
display: none;
}
8 changes: 8 additions & 0 deletions tests/fixtures/tailwind-output-flagged.css
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,14 @@ video {
height: auto;
}

/**
* Ensure the default browser behavior of the `hidden` attribute.
*/

[hidden] {
display: none;
}

*, ::before, ::after {
--tw-border-opacity: 1;
border-color: rgba(229, 231, 235, var(--tw-border-opacity));
Expand Down
8 changes: 8 additions & 0 deletions tests/fixtures/tailwind-output-important.css
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,14 @@ video {
height: auto;
}

/**
* Ensure the default browser behavior of the `hidden` attribute.
*/

[hidden] {
display: none;
}

*, ::before, ::after {
--tw-border-opacity: 1;
border-color: rgba(229, 231, 235, var(--tw-border-opacity));
Expand Down
8 changes: 8 additions & 0 deletions tests/fixtures/tailwind-output-no-color-opacity.css
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,14 @@ video {
height: auto;
}

/**
* Ensure the default browser behavior of the `hidden` attribute.
*/

[hidden] {
display: none;
}

*, ::before, ::after {
border-color: #e5e7eb;
}
Expand Down
8 changes: 8 additions & 0 deletions tests/fixtures/tailwind-output.css
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,14 @@ video {
height: auto;
}

/**
* Ensure the default browser behavior of the `hidden` attribute.
*/

[hidden] {
display: none;
}

*, ::before, ::after {
--tw-border-opacity: 1;
border-color: rgba(229, 231, 235, var(--tw-border-opacity));
Expand Down

0 comments on commit a323030

Please sign in to comment.