From 5fd34beb40f82c6365b3623a29ba63ba46cfda17 Mon Sep 17 00:00:00 2001 From: abdelrhmanahmed Date: Sun, 27 Sep 2026 01:38:45 +0300 Subject: [PATCH] fix(sr-only): ensure table caption elements are clipped in Firefox (#20510) --- packages/tailwindcss/preflight.css | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/tailwindcss/preflight.css b/packages/tailwindcss/preflight.css index 04e87905c..396622d28 100644 --- a/packages/tailwindcss/preflight.css +++ b/packages/tailwindcss/preflight.css @@ -171,6 +171,16 @@ table { border-collapse: collapse; /* 3 */ } +/* + Ensure table captions inside visually hidden tables are properly clipped in Firefox. + (https://github.com/tailwindlabs/tailwindcss/issues/20510) +*/ + +:where(table.sr-only, .sr-only > table) > caption { + clip-path: inherit; + overflow: hidden; +} + /* Use the modern Firefox focus style for all focusable elements. */