Skip to content

Commit d4adf62

Browse files
committed
fix(preflight): exclude iframes from :-moz-focusring outline
Prevent Firefox from applying auto outline to iframes when :focus-visible is triggered. This fixes an issue where iframes would show an unwanted outline when focused. Fixes #19795
1 parent d7fc281 commit d4adf62

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

integrations/cli/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2392,7 +2392,7 @@ test(
23922392
border-color: inherit;
23932393
border-collapse: collapse;
23942394
}
2395-
:-moz-focusring {
2395+
:-moz-focusring:where(:not(iframe)) {
23962396
outline: auto;
23972397
}
23982398
progress {

packages/tailwindcss/preflight.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ table {
170170
Use the modern Firefox focus style for all focusable elements.
171171
*/
172172

173-
:-moz-focusring {
173+
:-moz-focusring:where(:not(iframe)) {
174174
outline: auto;
175175
}
176176

0 commit comments

Comments
 (0)